@sisense/sdk-ui 2.31.1 → 2.32.0

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 (149) hide show
  1. package/dist/ai.cjs +2 -2
  2. package/dist/ai.js +9 -9
  3. package/dist/analytics-composer/node.cjs +1 -1
  4. package/dist/analytics-composer/node.js +5 -5
  5. package/dist/analytics-composer.cjs +1 -1
  6. package/dist/analytics-composer.js +6 -6
  7. package/dist/apply-styled-options-to-query-CE3WQwRs.cjs +1 -0
  8. package/dist/{apply-styled-options-to-query-lFlufwrB.js → apply-styled-options-to-query-TW3CqofD.js} +209 -207
  9. package/dist/{flow-DHowZLKN.cjs → const-BLmTd3gM.cjs} +1 -1
  10. package/dist/{flow-Cs53Uv2Y.js → const-vJfedJf9.js} +15 -15
  11. package/dist/execute-query-CZOWu-Fh.cjs +1 -0
  12. package/dist/{execute-query-4_76L7Ax.js → execute-query-D-gXk-LI.js} +908 -906
  13. package/dist/index-Boixy7N4.cjs +1 -0
  14. package/dist/{index-C2A2EHoh.cjs → index-C6ytYe3A.cjs} +1 -1
  15. package/dist/{index-eIOG6LP6.js → index-Ct7mA7YB.js} +1 -1
  16. package/dist/{index-CyVSfJ-B.js → index-D3DsBxkp.js} +22 -22
  17. package/dist/{index-DCYw3JUB.js → index-DrI_xqvr.js} +14 -0
  18. package/dist/{index-DTvxJdqZ.cjs → index-UssOwVVX.cjs} +1 -1
  19. package/dist/index.cjs +340 -340
  20. package/dist/index.js +12477 -12340
  21. package/dist/index.umd.js +805 -690
  22. package/dist/packages/sdk-ui/src/domains/dashboarding/common-filters/utils.d.ts +1 -1
  23. package/dist/packages/sdk-ui/src/domains/dashboarding/types.d.ts +22 -6
  24. package/dist/packages/sdk-ui/src/domains/query-execution/types.d.ts +2 -0
  25. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/components/regular-chart/has-no-results.d.ts +12 -0
  26. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/components/sisense-chart/sisense-chart.d.ts +1 -1
  27. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/components/sisense-chart/types.d.ts +8 -0
  28. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/helpers/use-chart-on-ready.d.ts +38 -0
  29. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/helpers/use-chart-renderer-props.d.ts +1 -0
  30. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/highcharts-based-chart-renderer/highcharts-based-chart-renderer.d.ts +8 -0
  31. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/helpers/on-ready-state.d.ts +17 -0
  32. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/highchart-based-charts/sankey-chart/sankey-chart-builder.d.ts +8 -1
  33. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data/comparison.d.ts +22 -0
  34. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data/data.d.ts +17 -0
  35. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data/index.d.ts +4 -0
  36. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data/load-data.d.ts +64 -0
  37. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data/value-colors.d.ts +27 -0
  38. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data-options/data-options.d.ts +30 -0
  39. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/data-options/index.d.ts +1 -0
  40. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/design-options/design-options.d.ts +31 -0
  41. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/design-options/index.d.ts +1 -0
  42. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/kpi-chart-builder.d.ts +9 -0
  43. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/helpers.d.ts +139 -0
  44. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/index.d.ts +1 -0
  45. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-card-styles.d.ts +154 -0
  46. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-card.d.ts +41 -0
  47. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-chart-renderer.d.ts +46 -0
  48. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-comparison.d.ts +60 -0
  49. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-sparkline.d.ts +23 -0
  50. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-title.d.ts +28 -0
  51. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/kpi-value.d.ts +55 -0
  52. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/on-color.d.ts +70 -0
  53. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/sparkline-options.d.ts +51 -0
  54. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/use-auto-fit-font-size.d.ts +98 -0
  55. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/use-element-size.d.ts +26 -0
  56. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/renderer/use-size-tier.d.ts +19 -0
  57. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/kpi-chart/types.d.ts +62 -0
  58. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/restructured-charts/types.d.ts +47 -9
  59. package/dist/packages/sdk-ui/src/domains/visualizations/components/chart/types.d.ts +9 -0
  60. package/dist/packages/sdk-ui/src/domains/visualizations/components/kpi-chart.d.ts +23 -0
  61. package/dist/packages/sdk-ui/src/domains/visualizations/core/apply-on-ready-to-highcharts-options.d.ts +11 -0
  62. package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data/types.d.ts +2 -1
  63. package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-data-options/types.d.ts +108 -2
  64. package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/chart-options-service.d.ts +1 -0
  65. package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/design-options.d.ts +41 -1
  66. package/dist/packages/sdk-ui/src/domains/visualizations/core/chart-options-processor/translations/types.d.ts +17 -3
  67. package/dist/packages/sdk-ui/src/domains/visualizations/core/highcharts-renderer.d.ts +7 -1
  68. package/dist/packages/sdk-ui/src/domains/visualizations/core/query-definition/query-definition-style-constants.d.ts +1 -1
  69. package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/types.d.ts +1 -2
  70. package/dist/packages/sdk-ui/src/domains/widgets/components/chart-widget/use-chart-widget-excel-download.d.ts +1 -1
  71. package/dist/packages/sdk-ui/src/domains/widgets/components/custom-widget/types.d.ts +1 -2
  72. package/dist/packages/sdk-ui/src/domains/widgets/components/filter-widget/filter-widget-dropdown.d.ts +16 -0
  73. package/dist/packages/sdk-ui/src/domains/widgets/components/filter-widget/types.d.ts +17 -23
  74. package/dist/packages/sdk-ui/src/domains/widgets/components/pivot-table-widget/types.d.ts +1 -2
  75. package/dist/packages/sdk-ui/src/domains/widgets/components/widget/types.d.ts +18 -4
  76. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-dashboard-filters.d.ts +447 -447
  77. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-panel-color-format.d.ts +8 -0
  78. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-filters.d.ts +56 -56
  79. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/categorical-labels-style.d.ts +3 -3
  80. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/series-label-affix-style.d.ts +1 -1
  81. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/translate-widget-style-options/to-widget-dto-style.d.ts +11 -2
  82. package/dist/packages/sdk-ui/src/domains/widgets/components/widget-by-id/types.d.ts +28 -5
  83. package/dist/packages/sdk-ui/src/domains/widgets/hooks/use-fire-on-ready.d.ts +14 -0
  84. package/dist/packages/sdk-ui/src/domains/widgets/widget-model/widget-model-translator/to-widget-dto-panels.d.ts +11 -1
  85. package/dist/packages/sdk-ui/src/infra/api/rest-api.d.ts +9 -2
  86. package/dist/packages/sdk-ui/src/infra/app/helpers.d.ts +23 -2
  87. package/dist/packages/sdk-ui/src/infra/app/settings/settings.d.ts +6 -3
  88. package/dist/packages/sdk-ui/src/infra/app/types.d.ts +14 -1
  89. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/de-de.d.ts +14 -0
  90. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/en-us.d.ts +14 -0
  91. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-ar.d.ts +14 -0
  92. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/es-es.d.ts +14 -0
  93. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/fr-fr.d.ts +14 -0
  94. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/it-it.d.ts +14 -0
  95. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ja-jp.d.ts +14 -0
  96. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ko-kr.d.ts +14 -0
  97. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/nl-nl.d.ts +14 -0
  98. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/pt-br.d.ts +14 -0
  99. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/ru-ru.d.ts +14 -0
  100. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/tr-tr.d.ts +14 -0
  101. package/dist/packages/sdk-ui/src/infra/translation/resources/__external__/zh-cn.d.ts +14 -0
  102. package/dist/packages/sdk-ui/src/infra/translation/resources/en.d.ts +14 -0
  103. package/dist/packages/sdk-ui/src/infra/translation/resources/index.d.ts +28 -0
  104. package/dist/packages/sdk-ui/src/props.d.ts +77 -5
  105. package/dist/packages/sdk-ui/src/public-api/beta.d.ts +4 -0
  106. package/dist/packages/sdk-ui/src/types.d.ts +296 -5
  107. package/dist/query.cjs +1 -1
  108. package/dist/query.js +3 -3
  109. package/dist/quota-notification-CdcItYEO.cjs +665 -0
  110. package/dist/{quota-notification-mCXOSF0U.js → quota-notification-DJPs09UQ.js} +17392 -15866
  111. package/dist/translations/de-de.cjs +1 -1
  112. package/dist/translations/de-de.js +15 -1
  113. package/dist/translations/en-us.cjs +1 -1
  114. package/dist/translations/en-us.js +1 -1
  115. package/dist/translations/es-ar.cjs +1 -1
  116. package/dist/translations/es-ar.js +15 -1
  117. package/dist/translations/es-es.cjs +1 -1
  118. package/dist/translations/es-es.js +15 -1
  119. package/dist/translations/fr-fr.cjs +1 -1
  120. package/dist/translations/fr-fr.js +17 -3
  121. package/dist/translations/it-it.cjs +1 -1
  122. package/dist/translations/it-it.js +15 -1
  123. package/dist/translations/ja-jp.cjs +1 -1
  124. package/dist/translations/ja-jp.js +15 -1
  125. package/dist/translations/ko-kr.cjs +1 -1
  126. package/dist/translations/ko-kr.js +15 -1
  127. package/dist/translations/nl-nl.cjs +1 -1
  128. package/dist/translations/nl-nl.js +15 -1
  129. package/dist/translations/pt-br.cjs +1 -1
  130. package/dist/translations/pt-br.js +15 -1
  131. package/dist/translations/ru-ru.cjs +1 -1
  132. package/dist/translations/ru-ru.js +15 -1
  133. package/dist/translations/tr-tr.cjs +1 -1
  134. package/dist/translations/tr-tr.js +15 -1
  135. package/dist/translations/zh-cn.cjs +1 -1
  136. package/dist/translations/zh-cn.js +15 -1
  137. package/dist/{types-CzQiy3kx.js → types-B60QjE1r.js} +1 -1
  138. package/dist/{types-pkCiWY_S.cjs → types-BAIldf5u.cjs} +1 -1
  139. package/dist/{use-execute-csv-query-DnTVUxCj.cjs → use-execute-csv-query-DAJqBzR5.cjs} +2 -2
  140. package/dist/{use-execute-csv-query-LtQrd2A4.js → use-execute-csv-query-tLJmsnwg.js} +6 -6
  141. package/dist/{utils-Bqaxp0gq.cjs → utils-BIAAcoFt.cjs} +12 -12
  142. package/dist/{utils-DHLPgrHF.js → utils-D2c9kOce.js} +1544 -1541
  143. package/dist/{widget-composer-CSkR-kBh.js → widget-composer-VWvON_Hi.js} +4 -4
  144. package/dist/{widget-composer-BUq7QhlK.cjs → widget-composer-srdW7lV4.cjs} +1 -1
  145. package/package.json +8 -8
  146. package/dist/apply-styled-options-to-query-siyJXPed.cjs +0 -1
  147. package/dist/execute-query-9rwu12er.cjs +0 -1
  148. package/dist/index-BGVJyEgp.cjs +0 -1
  149. package/dist/quota-notification-C49kSTz5.cjs +0 -550
@@ -0,0 +1,665 @@
1
+ "use strict";var g4=Object.defineProperty,v4=Object.defineProperties;var y4=Object.getOwnPropertyDescriptors;var Gl=Object.getOwnPropertySymbols;var Vv=Object.prototype.hasOwnProperty,Uv=Object.prototype.propertyIsEnumerable;var Gv=Math.pow,yh=(e,t,r)=>t in e?g4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,D=(e,t)=>{for(var r in t||(t={}))Vv.call(t,r)&&yh(e,r,t[r]);if(Gl)for(var r of Gl(t))Uv.call(t,r)&&yh(e,r,t[r]);return e},z=(e,t)=>v4(e,y4(t));var Ye=(e,t)=>{var r={};for(var n in e)Vv.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Gl)for(var n of Gl(e))t.indexOf(n)<0&&Uv.call(e,n)&&(r[n]=e[n]);return r};var gt=(e,t,r)=>yh(e,typeof t!="symbol"?t+"":t,r);var ht=(e,t,r)=>new Promise((n,i)=>{var a=u=>{try{s(r.next(u))}catch(c){i(c)}},o=u=>{try{s(r.throw(u))}catch(c){i(c)}},s=u=>u.done?n(u.value):Promise.resolve(u.value).then(a,o);s((r=r.apply(e,t)).next())});const O=require("./const-BLmTd3gM.cjs"),N=require("react"),V=require("./execute-query-CZOWu-Fh.cjs"),y=require("./use-execute-csv-query-DAJqBzR5.cjs"),E=require("./utils-BIAAcoFt.cjs"),H=require("./apply-styled-options-to-query-CE3WQwRs.cjs"),_e=require("react/jsx-runtime"),Jn=require("react-dom");function b4(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const de=b4(N);function zi(e,t){if(typeof e!="string")throw new Error("URL must be a string");if(!e.trim())throw new Error("URL cannot be empty");try{const r=new URL(e);return r.origin+(r.pathname.endsWith("/")?r.pathname:r.pathname+"/")+(t&&r.search?r.search:"")}catch(r){throw new Error(`Connection string ${e} is not a valid URL`)}}function qv(e,t){if(!e)throw new Error("Base URL is required");let r;try{r=new URL(e)}catch(u){throw new Error("Base URL is not valid")}if(!t||t==="/")return r.toString();try{return new URL(t).toString()}catch(u){}const n=new URL(r.toString()),[i="",a=""]=t.split(/\?(.+)/),o=r.pathname.replace(/\/$/,""),s=i.replace(/^\/+/,"").replace(/\/+$/,"").replace(/\/+/g,"/");if(n.pathname=s?`${o}/${s}`:o,a){const u=new URLSearchParams(a);for(const[c,d]of u.entries())n.searchParams.set(c,d)}return zi(n.toString(),!0)}function _4(e){return y.generateUtilityClass("MuiPagination",e)}y.generateUtilityClasses("MuiPagination",["root","ul","outlined","text"]);function Xm({controlled:e,default:t,name:r,state:n="value"}){const{current:i}=de.useRef(e!==void 0),[a,o]=de.useState(t),s=i?e:a;if(process.env.NODE_ENV!=="production"){de.useEffect(()=>{i!==(e!==void 0)&&console.error([`MUI: A component is changing the ${i?"":"un"}controlled ${n} state of ${r} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
2
+ `))},[n,r,e]);const{current:c}=de.useRef(t);de.useEffect(()=>{!i&&!Object.is(c,t)&&console.error([`MUI: A component is changing the default ${n} state of an uncontrolled ${r} after being initialized. To suppress this warning opt to use a controlled ${r}.`].join(`
3
+ `))},[JSON.stringify(t)])}const u=de.useCallback(c=>{i||o(c)},[]);return[s,u]}function w4(e={}){const I=e,{boundaryCount:t=1,componentName:r="usePagination",count:n=1,defaultPage:i=1,disabled:a=!1,hideNextButton:o=!1,hidePrevButton:s=!1,onChange:u,page:c,showFirstButton:d=!1,showLastButton:h=!1,siblingCount:p=1}=I,m=Ye(I,["boundaryCount","componentName","count","defaultPage","disabled","hideNextButton","hidePrevButton","onChange","page","showFirstButton","showLastButton","siblingCount"]),[g,b]=Xm({controlled:c,default:i,name:r,state:"page"}),_=($,G)=>{c||b(G),u&&u($,G)},w=($,G)=>{const Y=G-$+1;return Array.from({length:Y},(B,X)=>$+X)},C=w(1,Math.min(t,n)),S=w(Math.max(n-t+1,t+1),n),T=Math.max(Math.min(g-p,n-t-p*2-1),t+2),M=Math.min(Math.max(g+p,t+p*2+2),n-t-1),P=[...d?["first"]:[],...s?[]:["previous"],...C,...T>t+2?["start-ellipsis"]:t+1<n-t?[t+1]:[],...w(T,M),...M<n-t-1?["end-ellipsis"]:n-t>t?[n-t]:[],...S,...o?[]:["next"],...h?["last"]:[]],R=$=>{switch($){case"first":return 1;case"previous":return g-1;case"next":return g+1;case"last":return n;default:return null}},k=P.map($=>typeof $=="number"?{onClick:G=>{_(G,$)},type:"page",page:$,selected:$===g,disabled:a,"aria-current":$===g?"page":void 0}:{onClick:G=>{_(G,R($))},type:$,page:R($),selected:!1,disabled:a||!$.includes("ellipsis")&&($==="next"||$==="last"?g>=n:g<=1)});return D({items:k},m)}function C4(e){return y.generateUtilityClass("MuiPaginationItem",e)}const nr=y.generateUtilityClasses("MuiPaginationItem",["root","page","sizeSmall","sizeLarge","text","textPrimary","textSecondary","outlined","outlinedPrimary","outlinedSecondary","rounded","ellipsis","firstLast","previousNext","focusVisible","disabled","selected","icon","colorPrimary","colorSecondary"]),x4=e=>{var n,i;const t={systemProps:{},otherProps:{}},r=(i=(n=e==null?void 0:e.theme)==null?void 0:n.unstable_sxConfig)!=null?i:y.defaultSxConfig;return Object.keys(e).forEach(a=>{r[a]?t.systemProps[a]=e[a]:t.otherProps[a]=e[a]}),t};function N_(e){const o=e,{sx:t}=o,r=Ye(o,["sx"]),{systemProps:n,otherProps:i}=x4(r);let a;return Array.isArray(t)?a=[n,...t]:typeof t=="function"?a=(...s)=>{const u=t(...s);return y.isPlainObject(u)?D(D({},n),u):n}:a=D(D({},n),t),z(D({},i),{sx:a})}function T4(e){return e==null||Object.keys(e).length===0}function k_(e){const{styles:t,defaultTheme:r={}}=e,n=typeof t=="function"?i=>t(T4(i)?r:i):t;return _e.jsx(y.Global,{styles:n})}process.env.NODE_ENV!=="production"&&(k_.propTypes={defaultTheme:y.PropTypes.object,styles:y.PropTypes.oneOfType([y.PropTypes.array,y.PropTypes.string,y.PropTypes.object,y.PropTypes.func])});function L_({styles:e,themeId:t,defaultTheme:r={}}){const n=y.useTheme$1(r),i=typeof e=="function"?e(t&&n[t]||n):e;return _e.jsx(k_,{styles:i})}process.env.NODE_ENV!=="production"&&(L_.propTypes={defaultTheme:y.PropTypes.object,styles:y.PropTypes.oneOfType([y.PropTypes.array,y.PropTypes.func,y.PropTypes.number,y.PropTypes.object,y.PropTypes.string,y.PropTypes.bool]),themeId:y.PropTypes.string});let Yv=0;function S4(e){const[t,r]=de.useState(e),n=e||t;return de.useEffect(()=>{t==null&&(Yv+=1,r(`mui-${Yv}`))},[t]),n}const M4=D({},de),Xv=M4.useId;function Mc(e){if(Xv!==void 0){const t=Xv();return e!=null?e:t}return S4(e)}function O_(e){return _e.jsx(L_,z(D({},e),{defaultTheme:y.defaultTheme,themeId:y.THEME_ID}))}process.env.NODE_ENV!=="production"&&(O_.propTypes={styles:y.PropTypes.oneOfType([y.PropTypes.array,y.PropTypes.func,y.PropTypes.number,y.PropTypes.object,y.PropTypes.string,y.PropTypes.bool])});function P4(e){return function(r){return _e.jsx(O_,{styles:typeof e=="function"?n=>e(D({theme:n},r)):e})}}function E4(){return N_}function A4(e){return typeof e.main=="string"}function R4(e,t=[]){if(!A4(e))return!1;for(const r of t)if(!e.hasOwnProperty(r)||typeof e[r]!="string")return!1;return!0}function ri(e=[]){return([,t])=>t&&R4(t,e)}function D4(e){return y.generateUtilityClass("MuiSvgIcon",e)}y.generateUtilityClasses("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const N4=e=>{const{color:t,fontSize:r,classes:n}=e,i={root:["root",t!=="inherit"&&`color${y.capitalize(t)}`,`fontSize${y.capitalize(r)}`]};return y.composeClasses(i,D4,n)},k4=y.styled("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.color!=="inherit"&&t[`color${y.capitalize(r.color)}`],t[`fontSize${y.capitalize(r.fontSize)}`]]}})(y.memoTheme(({theme:e})=>{var t,r,n,i,a,o,s,u,c,d,h,p,m,g,b,_,w,C;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(a=(t=e.transitions)==null?void 0:t.create)==null?void 0:a.call(t,"fill",{duration:(i=(n=((r=e.vars)!=null?r:e).transitions)==null?void 0:n.duration)==null?void 0:i.shorter}),variants:[{props:S=>!S.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((s=(o=e.typography)==null?void 0:o.pxToRem)==null?void 0:s.call(o,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((c=(u=e.typography)==null?void 0:u.pxToRem)==null?void 0:c.call(u,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((h=(d=e.typography)==null?void 0:d.pxToRem)==null?void 0:h.call(d,35))||"2.1875rem"}},...Object.entries(((p=e.vars)!=null?p:e).palette).filter(([,S])=>S&&S.main).map(([S])=>{var T,M,P;return{props:{color:S},style:{color:(P=(M=((T=e.vars)!=null?T:e).palette)==null?void 0:M[S])==null?void 0:P.main}}}),{props:{color:"action"},style:{color:(b=(g=((m=e.vars)!=null?m:e).palette)==null?void 0:g.action)==null?void 0:b.active}},{props:{color:"disabled"},style:{color:(C=(w=((_=e.vars)!=null?_:e).palette)==null?void 0:w.action)==null?void 0:C.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Xu=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiSvgIcon"}),C=n,{children:i,className:a,color:o="inherit",component:s="svg",fontSize:u="medium",htmlColor:c,inheritViewBox:d=!1,titleAccess:h,viewBox:p="0 0 24 24"}=C,m=Ye(C,["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"]),g=de.isValidElement(i)&&i.type==="svg",b=z(D({},n),{color:o,component:s,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:d,viewBox:p,hasSvgAsChild:g}),_={};d||(_.viewBox=p);const w=N4(b);return _e.jsxs(k4,z(D(D(D({as:s,className:y.clsx(w.root,a),focusable:"false",color:c,"aria-hidden":h?void 0:!0,role:h?"img":void 0,ref:r},_),m),g&&i.props),{ownerState:b,children:[g?i.props.children:i,h?_e.jsx("title",{children:h}):null]}))});process.env.NODE_ENV!=="production"&&(Xu.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),y.PropTypes.string]),component:y.PropTypes.elementType,fontSize:y.PropTypes.oneOfType([y.PropTypes.oneOf(["inherit","large","medium","small"]),y.PropTypes.string]),htmlColor:y.PropTypes.string,inheritViewBox:y.PropTypes.bool,shapeRendering:y.PropTypes.string,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),titleAccess:y.PropTypes.string,viewBox:y.PropTypes.string});Xu.muiName="SvgIcon";function Qa(e,t){function r(n,i){return _e.jsx(Xu,z(D({"data-testid":`${t}Icon`,ref:i},n),{children:e}))}return process.env.NODE_ENV!=="production"&&(r.displayName=`${t}Icon`),r.muiName=Xu.muiName,de.memo(de.forwardRef(r))}const L4=Qa(_e.jsx("path",{d:"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"}),"FirstPage"),O4=Qa(_e.jsx("path",{d:"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"}),"LastPage"),I4=Qa(_e.jsx("path",{d:"M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"NavigateBefore"),F4=Qa(_e.jsx("path",{d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext"),I_=(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`size${y.capitalize(r.size)}`],r.variant==="text"&&t[`text${y.capitalize(r.color)}`],r.variant==="outlined"&&t[`outlined${y.capitalize(r.color)}`],r.shape==="rounded"&&t.rounded,r.type==="page"&&t.page,(r.type==="start-ellipsis"||r.type==="end-ellipsis")&&t.ellipsis,(r.type==="previous"||r.type==="next")&&t.previousNext,(r.type==="first"||r.type==="last")&&t.firstLast]},$4=e=>{const{classes:t,color:r,disabled:n,selected:i,size:a,shape:o,type:s,variant:u}=e,c={root:["root",`size${y.capitalize(a)}`,u,o,r!=="standard"&&`color${y.capitalize(r)}`,r!=="standard"&&`${u}${y.capitalize(r)}`,n&&"disabled",i&&"selected",{page:"page",first:"firstLast",last:"firstLast","start-ellipsis":"ellipsis","end-ellipsis":"ellipsis",previous:"previousNext",next:"previousNext"}[s]],icon:["icon"]};return y.composeClasses(c,C4,t)},B4=y.styled("div",{name:"MuiPaginationItem",slot:"Root",overridesResolver:I_})(y.memoTheme(({theme:e})=>z(D({},e.typography.body2),{borderRadius:32/2,textAlign:"center",boxSizing:"border-box",minWidth:32,padding:"0 6px",margin:"0 3px",color:(e.vars||e).palette.text.primary,height:"auto",[`&.${nr.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},variants:[{props:{size:"small"},style:{minWidth:26,borderRadius:26/2,margin:"0 1px",padding:"0 4px"}},{props:{size:"large"},style:{minWidth:40,borderRadius:40/2,padding:"0 10px",fontSize:e.typography.pxToRem(15)}}]}))),z4=y.styled(y.ButtonBase,{name:"MuiPaginationItem",slot:"Root",overridesResolver:I_})(y.memoTheme(({theme:e})=>z(D({},e.typography.body2),{borderRadius:32/2,textAlign:"center",boxSizing:"border-box",minWidth:32,height:32,padding:"0 6px",margin:"0 3px",color:(e.vars||e).palette.text.primary,[`&.${nr.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${nr.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},transition:e.transitions.create(["color","background-color"],{duration:e.transitions.duration.short}),"&:hover":{backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${nr.selected}`]:{backgroundColor:(e.vars||e).palette.action.selected,"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:y.alpha(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:(e.vars||e).palette.action.selected}},[`&.${nr.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.action.selectedChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:y.alpha(e.palette.action.selected,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)},[`&.${nr.disabled}`]:{opacity:1,color:(e.vars||e).palette.action.disabled,backgroundColor:(e.vars||e).palette.action.selected}},variants:[{props:{size:"small"},style:{minWidth:26,height:26,borderRadius:26/2,margin:"0 1px",padding:"0 4px"}},{props:{size:"large"},style:{minWidth:40,height:40,borderRadius:40/2,padding:"0 10px",fontSize:e.typography.pxToRem(15)}},{props:{shape:"rounded"},style:{borderRadius:(e.vars||e).shape.borderRadius}},{props:{variant:"outlined"},style:{border:e.vars?`1px solid rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:`1px solid ${e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)"}`,[`&.${nr.selected}`]:{[`&.${nr.disabled}`]:{borderColor:(e.vars||e).palette.action.disabledBackground,color:(e.vars||e).palette.action.disabled}}}},{props:{variant:"text"},style:{[`&.${nr.selected}`]:{[`&.${nr.disabled}`]:{color:(e.vars||e).palette.action.disabled}}}},...Object.entries(e.palette).filter(ri(["dark","contrastText"])).map(([t])=>({props:{variant:"text",color:t},style:{[`&.${nr.selected}`]:{color:(e.vars||e).palette[t].contrastText,backgroundColor:(e.vars||e).palette[t].main,"&:hover":{backgroundColor:(e.vars||e).palette[t].dark,"@media (hover: none)":{backgroundColor:(e.vars||e).palette[t].main}},[`&.${nr.focusVisible}`]:{backgroundColor:(e.vars||e).palette[t].dark},[`&.${nr.disabled}`]:{color:(e.vars||e).palette.action.disabled}}}})),...Object.entries(e.palette).filter(ri(["light"])).map(([t])=>({props:{variant:"outlined",color:t},style:{[`&.${nr.selected}`]:{color:(e.vars||e).palette[t].main,border:`1px solid ${e.vars?`rgba(${e.vars.palette[t].mainChannel} / 0.5)`:y.alpha(e.palette[t].main,.5)}`,backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / ${e.vars.palette.action.activatedOpacity})`:y.alpha(e.palette[t].main,e.palette.action.activatedOpacity),"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / calc(${e.vars.palette.action.activatedOpacity} + ${e.vars.palette.action.focusOpacity}))`:y.alpha(e.palette[t].main,e.palette.action.activatedOpacity+e.palette.action.focusOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${nr.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette[t].mainChannel} / calc(${e.vars.palette.action.activatedOpacity} + ${e.vars.palette.action.focusOpacity}))`:y.alpha(e.palette[t].main,e.palette.action.activatedOpacity+e.palette.action.focusOpacity)}}}}))]}))),H4=y.styled("div",{name:"MuiPaginationItem",slot:"Icon",overridesResolver:(e,t)=>t.icon})(y.memoTheme(({theme:e})=>({fontSize:e.typography.pxToRem(20),margin:"0 -8px",variants:[{props:{size:"small"},style:{fontSize:e.typography.pxToRem(18)}},{props:{size:"large"},style:{fontSize:e.typography.pxToRem(22)}}]}))),F_=de.forwardRef(function(t,r){var q,ee,Z,J;const n=y.useDefaultProps({props:t,name:"MuiPaginationItem"}),W=n,{className:i,color:a="standard",component:o,components:s={},disabled:u=!1,page:c,selected:d=!1,shape:h="circular",size:p="medium",slots:m={},slotProps:g={},type:b="page",variant:_="text"}=W,w=Ye(W,["className","color","component","components","disabled","page","selected","shape","size","slots","slotProps","type","variant"]),C=z(D({},n),{color:a,disabled:u,selected:d,shape:h,size:p,type:b,variant:_}),S=y.useRtl(),T=$4(C),M={slots:{previous:(q=m.previous)!=null?q:s.previous,next:(ee=m.next)!=null?ee:s.next,first:(Z=m.first)!=null?Z:s.first,last:(J=m.last)!=null?J:s.last},slotProps:g},[P,R]=y.useSlot("previous",{elementType:I4,externalForwardedProps:M,ownerState:C}),[k,I]=y.useSlot("next",{elementType:F4,externalForwardedProps:M,ownerState:C}),[$,G]=y.useSlot("first",{elementType:L4,externalForwardedProps:M,ownerState:C}),[Y,B]=y.useSlot("last",{elementType:O4,externalForwardedProps:M,ownerState:C}),X=S?{previous:"next",next:"previous",first:"last",last:"first"}[b]:b,U={previous:P,next:k,first:$,last:Y}[X],Q={previous:R,next:I,first:G,last:B}[X];return b==="start-ellipsis"||b==="end-ellipsis"?_e.jsx(B4,{ref:r,ownerState:C,className:y.clsx(T.root,i),children:"…"}):_e.jsxs(z4,z(D({ref:r,ownerState:C,component:o,disabled:u,className:y.clsx(T.root,i)},w),{children:[b==="page"&&c,U?_e.jsx(H4,z(D({},Q),{className:T.icon,as:U})):null]}))});process.env.NODE_ENV!=="production"&&(F_.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["primary","secondary","standard"]),y.PropTypes.string]),component:y.PropTypes.elementType,components:y.PropTypes.shape({first:y.PropTypes.elementType,last:y.PropTypes.elementType,next:y.PropTypes.elementType,previous:y.PropTypes.elementType}),disabled:y.PropTypes.bool,page:y.PropTypes.node,selected:y.PropTypes.bool,shape:y.PropTypes.oneOf(["circular","rounded"]),size:y.PropTypes.oneOfType([y.PropTypes.oneOf(["small","medium","large"]),y.PropTypes.string]),slotProps:y.PropTypes.shape({first:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),last:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),next:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),previous:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({first:y.PropTypes.elementType,last:y.PropTypes.elementType,next:y.PropTypes.elementType,previous:y.PropTypes.elementType}),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),type:y.PropTypes.oneOf(["end-ellipsis","first","last","next","page","previous","start-ellipsis"]),variant:y.PropTypes.oneOfType([y.PropTypes.oneOf(["outlined","text"]),y.PropTypes.string])});const W4=e=>{const{classes:t,variant:r}=e,n={root:["root",r],ul:["ul"]};return y.composeClasses(n,_4,t)},j4=y.styled("nav",{name:"MuiPagination",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant]]}})({}),V4=y.styled("ul",{name:"MuiPagination",slot:"Ul",overridesResolver:(e,t)=>t.ul})({display:"flex",flexWrap:"wrap",alignItems:"center",padding:0,margin:0,listStyle:"none"});function U4(e,t,r){return e==="page"?`${r?"":"Go to "}page ${t}`:`Go to ${e} page`}const $_=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiPagination"}),$=n,{boundaryCount:i=1,className:a,color:o="standard",count:s=1,defaultPage:u=1,disabled:c=!1,getItemAriaLabel:d=U4,hideNextButton:h=!1,hidePrevButton:p=!1,onChange:m,page:g,renderItem:b=G=>_e.jsx(F_,D({},G)),shape:_="circular",showFirstButton:w=!1,showLastButton:C=!1,siblingCount:S=1,size:T="medium",variant:M="text"}=$,P=Ye($,["boundaryCount","className","color","count","defaultPage","disabled","getItemAriaLabel","hideNextButton","hidePrevButton","onChange","page","renderItem","shape","showFirstButton","showLastButton","siblingCount","size","variant"]),{items:R}=w4(z(D({},n),{componentName:"Pagination"})),k=z(D({},n),{boundaryCount:i,color:o,count:s,defaultPage:u,disabled:c,getItemAriaLabel:d,hideNextButton:h,hidePrevButton:p,renderItem:b,shape:_,showFirstButton:w,showLastButton:C,siblingCount:S,size:T,variant:M}),I=W4(k);return _e.jsx(j4,z(D({"aria-label":"pagination navigation",className:y.clsx(I.root,a),ownerState:k,ref:r},P),{children:_e.jsx(V4,{className:I.ul,ownerState:k,children:R.map((G,Y)=>_e.jsx("li",{children:b(z(D({},G),{color:o,"aria-label":d(G.type,G.page,G.selected),shape:_,size:T,variant:M}))},Y))})}))});process.env.NODE_ENV!=="production"&&($_.propTypes={boundaryCount:y.integerPropType,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["primary","secondary","standard"]),y.PropTypes.string]),count:y.integerPropType,defaultPage:y.integerPropType,disabled:y.PropTypes.bool,getItemAriaLabel:y.PropTypes.func,hideNextButton:y.PropTypes.bool,hidePrevButton:y.PropTypes.bool,onChange:y.PropTypes.func,page:y.integerPropType,renderItem:y.PropTypes.func,shape:y.PropTypes.oneOf(["circular","rounded"]),showFirstButton:y.PropTypes.bool,showLastButton:y.PropTypes.bool,siblingCount:y.integerPropType,size:y.PropTypes.oneOfType([y.PropTypes.oneOf(["small","medium","large"]),y.PropTypes.string]),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),variant:y.PropTypes.oneOfType([y.PropTypes.oneOf(["outlined","text"]),y.PropTypes.string])});const lr={BOX_MIN_VALUE_NAME:"Box Min",BOX_MEDIAN_VALUE_NAME:"Box Median",BOX_MAX_VALUE_NAME:"Box Max",WHISKER_MIN_VALUE_NAME:"Whisker Min",WHISKER_MAX_VALUE_NAME:"Whisker Max",OUTLIER_COUNT_VALUE_NAME:"Outlier Count",OUTLIER_MIN_VALUE_NAME:"Outlier Min",OUTLIER_MAX_VALUE_NAME:"Outlier Max"};function Zm(e){return[V.customFormula(lr.BOX_MIN_VALUE_NAME,"QUARTILE([Attr], 1)",{Attr:e}),V.customFormula(lr.BOX_MEDIAN_VALUE_NAME,"MEDIAN([Attr])",{Attr:e}),V.customFormula(lr.BOX_MAX_VALUE_NAME,"QUARTILE([Attr], 3)",{Attr:e})]}function G4(e){return[...Zm(e),V.customFormula(lr.WHISKER_MIN_VALUE_NAME,"LOWERWHISKERMAX_IQR([Attr])",{Attr:e}),V.customFormula(lr.WHISKER_MAX_VALUE_NAME,"UPPERWHISKERMIN_IQR([Attr])",{Attr:e}),V.customFormula(lr.OUTLIER_COUNT_VALUE_NAME,"OUTLIERSCOUNT_IQR([Attr])",{Attr:e})]}function q4(e){return[...Zm(e),V.customFormula(lr.WHISKER_MIN_VALUE_NAME,"MIN([Attr])",{Attr:e}),V.customFormula(lr.WHISKER_MAX_VALUE_NAME,"MAX([Attr])",{Attr:e})]}function Y4(e){return[...Zm(e),V.customFormula(lr.WHISKER_MIN_VALUE_NAME,"LOWERWHISKERMAX_STDEVP([Attr])",{Attr:e}),V.customFormula(lr.WHISKER_MAX_VALUE_NAME,"UPPERWHISKERMIN_STDEVP([Attr])",{Attr:e}),V.customFormula(lr.OUTLIER_COUNT_VALUE_NAME,"OUTLIERSCOUNT_STDEVP([Attr])",{Attr:e})]}const X4=V.withComposeCodeForAnalytics(e=>{const t=V.cloneDeep(e),r=V.customFormula(lr.OUTLIER_MAX_VALUE_NAME,"(UPPERWHISKERMIN_IQR([Attr]), all([Attr]))",{Attr:e}),n=V.customFormula(lr.OUTLIER_MIN_VALUE_NAME,"(LOWERWHISKERMAX_IQR([Attr]), all([Attr]))",{Attr:e});return t.name=`${t.name} (Outliers)`,t.jaql=i=>{const a=Object.assign(Object.assign({},e.jaql(!0)),{filter:{or:[{fromNotEqual:r.jaql(!0)},{toNotEqual:n.jaql(!0)}]}});return i?a:{jaql:a}},t},"boxWhiskerIqrOutliers"),Z4=V.withComposeCodeForAnalytics(e=>{const t=V.cloneDeep(e),r=V.customFormula(lr.OUTLIER_MAX_VALUE_NAME,"(UPPERWHISKERMIN_STDEVP([Attr]), all([Attr]))",{Attr:e}),n=V.customFormula(lr.OUTLIER_MIN_VALUE_NAME,"(LOWERWHISKERMAX_STDEVP([Attr]), all([Attr]))",{Attr:e});return t.jaql=i=>{const a=Object.assign(Object.assign({},e.jaql(!0)),{filter:{or:[{fromNotEqual:r.jaql(!0)},{toNotEqual:n.jaql(!0)}]}});return i?a:{jaql:a}},t},"boxWhiskerStdDevOutliers"),K4=(e,t,r)=>({width:(t==null?void 0:t.width)||(e==null?void 0:e.width)||r.width,height:(t==null?void 0:t.height)||(e==null?void 0:e.height)||r.height}),Pc=({children:e,defaultSize:t,size:r,rerenderOnResize:n=!1,useContentSize:i,onSizeChange:a,debounceMs:o=300})=>{const s=N.useRef(null),[u,c]=N.useState(),d=N.useRef(null),h=N.useCallback(()=>{var P,R;const M={width:(P=s.current)==null?void 0:P.offsetWidth,height:(R=s.current)==null?void 0:R.offsetHeight};c(k=>{const I=(k==null?void 0:k.width)===0&&M.width===t.width,$=(k==null?void 0:k.height)===0&&M.height===t.height,G={width:I?k.width:M.width,height:$?k.height:M.height};return V.isEqual(k,G)?k:G})},[t]),p=N.useCallback(()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>{h()},o)},[h,o]);N.useLayoutEffect(()=>{h()},[h]),N.useEffect(()=>{const M=s.current;if(!M)return;const P=new ResizeObserver(()=>{p()});return P.observe(M),()=>{P.disconnect(),d.current&&clearTimeout(d.current)}},[p]);const m=N.useMemo(()=>K4(u,r,t),[u,t,r]),g=!!u;N.useEffect(()=>{g&&a&&a(m)},[m,g,a]);const b={width:r!=null&&r.width&&!(i!=null&&i.width)?`${r.width}px`:"100%",height:r!=null&&r.height&&!(i!=null&&i.height)?`${r.height}px`:"100%"},_=(u==null?void 0:u.width)||(u==null?void 0:u.width)===void 0,w=(u==null?void 0:u.height)||(u==null?void 0:u.width)===void 0,C={width:_||i!=null&&i.width?"100%":`${m.width}px`,height:w||i!=null&&i.height?"100%":`${m.height}px`,position:"relative"},S=i!=null&&i.width||i!=null&&i.height?{position:"static",width:"100%",height:"100%"}:{position:"absolute",top:0,right:0,bottom:0,left:0},T=n?`${m==null?void 0:m.width}${m==null?void 0:m.height}`:"";return O.jsx("div",{style:b,ref:s,children:O.jsx("div",{style:C,children:O.jsx("div",{style:S,children:typeof e=="function"?e(m):e})},T)})},B_=32,z_={width:400,height:500},Q4={width:400,height:400},J4={width:400,height:500},eA={width:200,height:200},Ec=e=>H.isTable(e)?J4:H.isIndicator(e)?eA:Q4,H_=(e,{hasHeader:t}={})=>{const r=e==="pivot"?z_:Ec(e);return t?{width:r.width,height:r.height+B_}:r},tA=e=>{const{absolute:t,children:r,classes:n,flexItem:i,light:a,orientation:o,textAlign:s,variant:u}=e,c={root:["root",t&&"absolute",u,a&&"light",o==="vertical"&&"vertical",i&&"flexItem",r&&"withChildren",r&&o==="vertical"&&"withChildrenVertical",s==="right"&&o!=="vertical"&&"textAlignRight",s==="left"&&o!=="vertical"&&"textAlignLeft"],wrapper:["wrapper",o==="vertical"&&"wrapperVertical"]};return y.composeClasses(c,y.getDividerUtilityClass,n)},rA=y.styled("div",{name:"MuiDivider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.absolute&&t.absolute,t[r.variant],r.light&&t.light,r.orientation==="vertical"&&t.vertical,r.flexItem&&t.flexItem,r.children&&t.withChildren,r.children&&r.orientation==="vertical"&&t.withChildrenVertical,r.textAlign==="right"&&r.orientation!=="vertical"&&t.textAlignRight,r.textAlign==="left"&&r.orientation!=="vertical"&&t.textAlignLeft]}})(y.memoTheme(({theme:e})=>({margin:0,flexShrink:0,borderWidth:0,borderStyle:"solid",borderColor:(e.vars||e).palette.divider,borderBottomWidth:"thin",variants:[{props:{absolute:!0},style:{position:"absolute",bottom:0,left:0,width:"100%"}},{props:{light:!0},style:{borderColor:e.vars?`rgba(${e.vars.palette.dividerChannel} / 0.08)`:y.alpha(e.palette.divider,.08)}},{props:{variant:"inset"},style:{marginLeft:72}},{props:{variant:"middle",orientation:"horizontal"},style:{marginLeft:e.spacing(2),marginRight:e.spacing(2)}},{props:{variant:"middle",orientation:"vertical"},style:{marginTop:e.spacing(1),marginBottom:e.spacing(1)}},{props:{orientation:"vertical"},style:{height:"100%",borderBottomWidth:0,borderRightWidth:"thin"}},{props:{flexItem:!0},style:{alignSelf:"stretch",height:"auto"}},{props:({ownerState:t})=>!!t.children,style:{display:"flex",textAlign:"center",border:0,borderTopStyle:"solid",borderLeftStyle:"solid","&::before, &::after":{content:'""',alignSelf:"center"}}},{props:({ownerState:t})=>t.children&&t.orientation!=="vertical",style:{"&::before, &::after":{width:"100%",borderTop:`thin solid ${(e.vars||e).palette.divider}`,borderTopStyle:"inherit"}}},{props:({ownerState:t})=>t.orientation==="vertical"&&t.children,style:{flexDirection:"column","&::before, &::after":{height:"100%",borderLeft:`thin solid ${(e.vars||e).palette.divider}`,borderLeftStyle:"inherit"}}},{props:({ownerState:t})=>t.textAlign==="right"&&t.orientation!=="vertical",style:{"&::before":{width:"90%"},"&::after":{width:"10%"}}},{props:({ownerState:t})=>t.textAlign==="left"&&t.orientation!=="vertical",style:{"&::before":{width:"10%"},"&::after":{width:"90%"}}}]}))),nA=y.styled("span",{name:"MuiDivider",slot:"Wrapper",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.wrapper,r.orientation==="vertical"&&t.wrapperVertical]}})(y.memoTheme(({theme:e})=>({display:"inline-block",paddingLeft:`calc(${e.spacing(1)} * 1.2)`,paddingRight:`calc(${e.spacing(1)} * 1.2)`,whiteSpace:"nowrap",variants:[{props:{orientation:"vertical"},style:{paddingTop:`calc(${e.spacing(1)} * 1.2)`,paddingBottom:`calc(${e.spacing(1)} * 1.2)`}}]}))),Si=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiDivider"}),w=n,{absolute:i=!1,children:a,className:o,orientation:s="horizontal",component:u=a||s==="vertical"?"div":"hr",flexItem:c=!1,light:d=!1,role:h=u!=="hr"?"separator":void 0,textAlign:p="center",variant:m="fullWidth"}=w,g=Ye(w,["absolute","children","className","orientation","component","flexItem","light","role","textAlign","variant"]),b=z(D({},n),{absolute:i,component:u,flexItem:c,light:d,orientation:s,role:h,textAlign:p,variant:m}),_=tA(b);return _e.jsx(rA,z(D({as:u,className:y.clsx(_.root,o),role:h,ref:r,ownerState:b,"aria-orientation":h==="separator"&&(u!=="hr"||s==="vertical")?s:void 0},g),{children:a?_e.jsx(nA,{className:_.wrapper,ownerState:b,children:a}):null}))});Si&&(Si.muiSkipListHighlight=!0);process.env.NODE_ENV!=="production"&&(Si.propTypes={absolute:y.PropTypes.bool,children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,component:y.PropTypes.elementType,flexItem:y.PropTypes.bool,light:y.PropTypes.bool,orientation:y.PropTypes.oneOf(["horizontal","vertical"]),role:y.PropTypes.string,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),textAlign:y.PropTypes.oneOf(["center","left","right"]),variant:y.PropTypes.oneOfType([y.PropTypes.oneOf(["fullWidth","inset","middle"]),y.PropTypes.string])});function iA(e){return y.generateUtilityClass("MuiTypography",e)}const aA=y.generateUtilityClasses("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]),oA={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},sA=E4(),lA=e=>{const{align:t,gutterBottom:r,noWrap:n,paragraph:i,variant:a,classes:o}=e,s={root:["root",a,e.align!=="inherit"&&`align${y.capitalize(t)}`,r&&"gutterBottom",n&&"noWrap",i&&"paragraph"]};return y.composeClasses(s,iA,o)},uA=y.styled("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.variant&&t[r.variant],r.align!=="inherit"&&t[`align${y.capitalize(r.align)}`],r.noWrap&&t.noWrap,r.gutterBottom&&t.gutterBottom,r.paragraph&&t.paragraph]}})(y.memoTheme(({theme:e})=>{var t;return{margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(e.typography).filter(([r,n])=>r!=="inherit"&&n&&typeof n=="object").map(([r,n])=>({props:{variant:r},style:n})),...Object.entries(e.palette).filter(ri()).map(([r])=>({props:{color:r},style:{color:(e.vars||e).palette[r].main}})),...Object.entries(((t=e.palette)==null?void 0:t.text)||{}).filter(([,r])=>typeof r=="string").map(([r])=>({props:{color:`text${y.capitalize(r)}`},style:{color:(e.vars||e).palette.text[r]}})),{props:({ownerState:r})=>r.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:r})=>r.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:r})=>r.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:r})=>r.paragraph,style:{marginBottom:16}}]}})),Zv={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},_r=de.forwardRef(function(t,r){const S=y.useDefaultProps({props:t,name:"MuiTypography"}),{color:n}=S,i=Ye(S,["color"]),a=!oA[n],o=sA(D(D({},i),a&&{color:n})),T=o,{align:s="inherit",className:u,component:c,gutterBottom:d=!1,noWrap:h=!1,paragraph:p=!1,variant:m="body1",variantMapping:g=Zv}=T,b=Ye(T,["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"]),_=z(D({},o),{align:s,color:n,className:u,component:c,gutterBottom:d,noWrap:h,paragraph:p,variant:m,variantMapping:g}),w=c||(p?"p":g[m]||Zv[m])||"span",C=lA(_);return _e.jsx(uA,z(D({as:w,ref:r,className:y.clsx(C.root,u)},b),{ownerState:_,style:D(D({},s!=="inherit"&&{"--Typography-textAlign":s}),b.style)}))});process.env.NODE_ENV!=="production"&&(_r.propTypes={align:y.PropTypes.oneOf(["center","inherit","justify","left","right"]),children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),y.PropTypes.string]),component:y.PropTypes.elementType,gutterBottom:y.PropTypes.bool,noWrap:y.PropTypes.bool,paragraph:y.PropTypes.bool,style:y.PropTypes.object,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),variant:y.PropTypes.oneOfType([y.PropTypes.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),y.PropTypes.string]),variantMapping:y.PropTypes.object});function cA(e){return t=>{var r;t.type==="rule"&&((r=t.root)==null?void 0:r.type)!==O.KEYFRAMES&&(t.props=t.props.map(n=>`${e} ${n}`))}}const Kv=N.createContext(void 0),W_=({children:e,cssSelectorPrefix:t})=>{const r=N.useMemo(()=>y.getNonceFromMetaTag(),[]),n=N.useContext(Kv),i=!n,a=n==null?void 0:n.cssSelectorPrefix,o=N.useMemo(()=>i&&r||t!==a?O.createCache(D(D({key:"css"},r&&{nonce:r}),t&&{stylisPlugins:[O.prefixer,cA(t)]})):null,[i,t,a,r]);return i||o?O.jsx(Kv.Provider,{value:{cssSelectorPrefix:t},children:o?O.jsx(O.CacheProvider,{value:o,children:e}):O.jsx(O.Fragment,{children:e})}):O.jsx(O.Fragment,{children:e})};function Qv(e){return`${e.fontFamily}|${e.fontWeight}|${e.fontStyle}`}function dA(e,t){const[r,n]=N.useState([]),[i,a]=N.useState(!1),o=N.useMemo(()=>e.filter(s=>!t.includes(Qv(s))),[e,t]);return N.useEffect(()=>{if(o.length===0){a(!0);return}let s=!1;const u=o.map(c=>{const d=c.src.map(p=>Object.entries(p).map(([g,b])=>`${g}('${b}')`).join(" ")).join(", ");return new FontFace(c.fontFamily,d,{style:c.fontStyle,weight:c.fontWeight.toString()}).load().then(p=>(s||document.fonts.add(p),Qv(c)))});return Promise.all(u).then(c=>{s||(n(d=>[...d,...c]),a(!0))}).catch(c=>{console.error("Failed to load fonts:",c),a(!0)}),()=>{s=!0}},[o]),{loadedFonts:r,areAllFontsLoaded:i}}const Jv=N.createContext({loadedFonts:[]}),hA=({fonts:e,children:t})=>{var o;const{loadedFonts:r}=N.useContext(Jv),{themeSettings:n}=y.useThemeContext(),{loadedFonts:i,areAllFontsLoaded:a}=dA(e||((o=n.typography.fontsLoader)==null?void 0:o.fonts)||[],r);return O.jsx(Jv.Provider,{value:{loadedFonts:[...r,...i]},children:a&&t})},es={none:"None",small:"Small",medium:"Medium",large:"Large",left:"Left",center:"Center",right:"Right",light:"Light",dark:"Dark"};function j_(e,t,r){const n={chart:{textColor:e.dashboards.widgetTextColor,backgroundColor:e.dashboards.widgetBackgroundColor,secondaryTextColor:e.dashboards.widgetSecondaryTextColor,animation:{init:{duration:"auto"},redraw:{duration:"auto"}}},typography:{fontFamily:e.typography.fontFamily,primaryTextColor:e.typography.primaryTextColor,secondaryTextColor:e.typography.secondaryTextColor,hyperlinkColor:e.typography.hyperlinkColor,hyperlinkHoverColor:e.typography.hyperlinkHoverColor,fontsLoader:{fonts:fA(e.typography.fontFamily,r,e.typography.customFontSelected)}},palette:{variantColors:t.colors},general:{brandColor:e.general.brandColor,backgroundColor:e.general.backgroundColor,primaryButtonTextColor:e.general.primaryButtonTextColor,primaryButtonHoverColor:e.general.primaryButtonHoverColor,popover:y.getDefaultThemeSettings().general.popover,buttons:{primary:{backgroundColor:{default:e.general.brandColor,hover:e.general.primaryButtonHoverColor,focus:e.general.primaryButtonHoverColor},textColor:e.general.primaryButtonTextColor},cancel:{backgroundColor:{default:e.general.secondaryButtonBaseColor,hover:e.general.secondaryButtonHoverColor,focus:e.general.secondaryButtonHoverColor},textColor:e.general.secondaryButtonTextColor}}},widget:{spaceAround:es[e.dashboards.widgetSpacing],cornerRadius:es[e.dashboards.widgetCornerRadius],shadow:es[e.dashboards.widgetShadow],border:e.dashboards.widgetBorderEnabled,borderColor:e.dashboards.widgetBorderColor,header:{titleTextColor:e.dashboards.widgetTitleColor,titleAlignment:es[e.dashboards.widgetTitleAlignment],titleFontSize:y.DEFAULT_TITLE_FONT_SIZE,dividerLine:e.dashboards.widgetTitleDividerEnabled,dividerLineColor:e.dashboards.widgetTitleDividerColor,backgroundColor:e.dashboards.widgetTitleBackgroundColor}},dashboard:{backgroundColor:e.dashboards.layoutBackgroundColor,dividerLineWidth:y.DEFAULT_DIVIDER_WIDTH,dividerLineColor:y.DEFAULT_DIVIDER_COLOR,borderWidth:y.DEFAULT_DASHBOARD_BORDER_WIDTH,borderColor:y.DEFAULT_DASHBOARD_BORDER_COLOR,toolbar:{primaryTextColor:e.dashboards.toolbarTextColor,secondaryTextColor:e.dashboards.toolbarSecondaryTextColor,backgroundColor:e.dashboards.toolbarBackgroundColor,dividerLineColor:y.DEFAULT_DASHBOARD_TOOLBAR_DIVIDER_LINE_COLOR,dividerLineWidth:y.DEFAULT_DASHBOARD_TOOLBAR_DIVIDER_LINE_WIDTH}},filter:{panel:{titleColor:e.dashboards.panelTitleTextColor,backgroundColor:e.dashboards.panelBackgroundColor,dividerLineColor:y.DEFAULT_FILTER_PANEL_DIVIDER_LINE_COLOR,dividerLineWidth:y.DEFAULT_FILTER_PANEL_DIVIDER_LINE_WIDTH,borderColor:y.DEFAULT_FILTER_PANEL_BORDER_COLOR,borderWidth:y.DEFAULT_FILTER_PANEL_BORDER_WIDTH}}};return E.merge.withOptions({mergeArrays:!1},y.getDefaultThemeSettings(),n)}function V_(e){return e.dashboards.colorPaletteName}function fA(e,t,r){const a=r?"fonts/":"resources/base/fonts/";return[{fontFamily:e,fontWeight:"normal",fontStyle:"normal",src:[{url:`${t}${a}${e}-Regular.eot`},{local:`${e}-Regular`},{url:`${t}${a}${e}-Regular.eot?#iefix`,format:"embedded-opentype"},{url:`${t}${a}${e}-Regular.ttf`,format:"truetype"}]},{fontFamily:e,fontWeight:600,fontStyle:"normal",src:[{url:`${t}${a}${e}-SemiBold.eot`},{local:`${e}-SemiBold`},{url:`${t}${a}${e}-SemiBold.eot?#iefix`,format:"embedded-opentype"},{url:`${t}${a}${e}-SemiBold.ttf`,format:"truetype"}]},{fontFamily:e,fontWeight:"bold",fontStyle:"normal",src:[{url:`${t}${a}${e}-Bold.eot`},{local:`${e}-Bold`},{url:`${t}${a}${e}-Bold.eot?#iefix`,format:"embedded-opentype"},{url:`${t}${a}${e}-Bold.ttf`,format:"truetype"}]}]}function U_(e,t){return ht(this,null,function*(){const r=yield pA(e,t);if(!r)throw new V.TranslatableError("errors.themeNotFound",{themeOid:e});const n=V_(r),i=yield G_(n,t);return j_(r,i,t.url)})}function pA(e,t){return ht(this,null,function*(){return t.get(`api/v1/themes/${e}`).catch(()=>{throw new V.TranslatableError("errors.themeNotFound",{themeOid:e})})})}function G_(e,t){return ht(this,null,function*(){const r=yield t.get(`api/palettes/${e}`);if(r&&"status"in r&&r.status==="error")throw new V.TranslatableError("errors.paletteNotFound",{paletteName:e});return r})}var q_=(e=>(e.DEFAULT="default",e.HOVER="hover",e.FOCUS="focus",e))(q_||{});function bh(e){return typeof e=="string"}function mA(e){var u;const t=y.useThemeContext().themeSettings,[r,n]=N.useState(null),[i,a]=N.useState(null),o=(u=y.useSisenseContext().app)==null?void 0:u.httpClient;N.useEffect(()=>{e&&bh(e)&&o&&U_(e,o).then(c=>{n(c)}).catch(a)},[o,e]),N.useEffect(()=>{(!e||!bh(e))&&(n(null),a(null))},[e]);const s=N.useMemo(()=>r?e1(t,r):e&&!bh(e)?e1(t,e):t,[r,t,e]);return i?[null,i]:[s,null]}function e1(e,t){return E.merge.withOptions({mergeArrays:!1},e,t)}const Y_=y.asSisenseComponent({componentName:"ThemeProvider",trackingConfig:{skip:e=>!!e.skipTracking,transparent:!0},shouldSkipSisenseContextWaiting:!0})(e=>{var c;const{theme:t,children:r,config:n}=e,[i,a]=mA(t),o=y.useThemeContext().config,s=N.useMemo(()=>n&&o?E.merge.withOptions({mergeArrays:!1},o,n):n||o,[o,n]),u=(c=s==null?void 0:s.cssSelectorPrefix)!=null&&c.enabled?s.cssSelectorPrefix.value:void 0;if(a)throw a;return i?O.jsx(W_,{cssSelectorPrefix:u,children:O.jsx(y.ThemeContext.Provider,{value:{themeSettings:i,config:s},children:O.jsx(hA,{children:r})})}):null}),t1="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3crect%20x='50.5'%20y='558.5'%20fill='%23E4E4E4'%20width='466'%20height='2'/%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M487.5,531.5h-410v-68.9l0.3-0.3l144-155.7l104.2,88.1l161.6-179.5V531.5z%20M79.5,529.5h406V220.4%20L326.1,397.5l-104.2-88.2l-142.4,154V529.5z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",gA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3crect%20x='64.5'%20y='201.5'%20fill='%23E4E4E4'%20width='2'%20height='381'/%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M447.5,560.5h-357v-60h357V560.5z%20M92.5,558.5h353v-56h-353V558.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M292.5,468.5h-202v-60h202V468.5z%20M92.5,466.5h198v-56h-198V466.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M526.5,377.5h-436v-60h436V377.5z%20M92.5,375.5h432v-56h-432V375.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M368.5,285.5h-278v-59h278V285.5z%20M92.5,283.5h274v-55h-274V283.5z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",vA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='477px'%20height='689px'%20viewBox='0%200%20477%20689'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3c!--%20Generator:%20sketchtool%2040.1%20(33804)%20-%20http://www.bohemiancoding.com/sketch%20--%3e%3ctitle%3eD5222DCB-A5E7-4783-ABD3-E5AAF56D153F%3c/title%3e%3cdesc%3eCreated%20with%20sketchtool.%3c/desc%3e%3cdefs%3e%3crect%20id='path-1'%20x='0.760775862'%20y='88.8671642'%20width='90'%20height='138'%3e%3c/rect%3e%3cmask%20id='mask-2'%20maskContentUnits='userSpaceOnUse'%20maskUnits='objectBoundingBox'%20x='0'%20y='0'%20width='90'%20height='138'%20fill='white'%3e%3cuse%20xlink:href='%23path-1'%3e%3c/use%3e%3c/mask%3e%3c/defs%3e%3cg%20id='Page-1'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='box-and-whiskers-plot'%20transform='translate(-1362.000000,%20-6618.000000)'%20stroke='%23E5E5E5'%3e%3cg%20id='boxplot_small'%20transform='translate(1362.000000,%206618.000000)'%3e%3cg%20id='Group-40'%20transform='translate(193.000000,%20187.000000)'%3e%3cg%20id='Group-39'%20transform='translate(0.239224,%200.132836)'%3e%3cuse%20id='Rectangle-32'%20mask='url(%23mask-2)'%20stroke-width='2'%20xlink:href='%23path-1'%3e%3c/use%3e%3cpath%20d='M0.760775862,185.367164%20L90.7607759,185.367164'%20id='Path-63'%20fill='%23D8D8D8'%3e%3c/path%3e%3cpath%20d='M0.760775862,313.367164%20L90.7607759,313.367164'%20id='Path-63'%20fill='%23D8D8D8'%3e%3c/path%3e%3cpath%20d='M0.760775862,1.36716418%20L90.7607759,1.36716418'%20id='Path-63-Copy'%20fill='%23D8D8D8'%3e%3c/path%3e%3cpath%20d='M46.2607759,0.867164179%20L46.2607759,88.8671642'%20id='Path-64'%20fill='%23D8D8D8'%3e%3c/path%3e%3cpath%20d='M46.2607759,225.867164%20L46.2607759,313.867164'%20id='Path-64'%20fill='%23D8D8D8'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",yA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cpath%20fill='%23E4E4E4'%20d='M419,192.5h-2h-88h-2h-88h-2h-92v80H55v246h276v-80h180v-246H419z%20M507,196.5v78h-88v-78H507z%20M327,434.5%20h-88v-78h88V434.5z%20M149,434.5v-78h88v78H149z%20M237,436.5v78h-88v-78H237z%20M147,434.5H59v-78h88V434.5z%20M149,354.5v-78h88v78H149z%20M239,354.5v-78h88v78H239z%20M329,276.5h88v78h-88V276.5z%20M419,276.5h88v78h-88V276.5z%20M417,196.5v78h-88v-78H417z%20M327,196.5v78%20h-88v-78H327z%20M149,196.5h88v78h-88v-2V196.5z%20M145,276.5h2v78H59v-78H145z%20M59,436.5h88v78H59V436.5z%20M327,438.5v76h-88v-78h88%20V438.5z%20M329,434.5v-78h88v78h-86H329z%20M419,434.5v-78h88v78H419z'/%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",bA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3crect%20x='78'%20y='558.5'%20fill='%23E4E4E4'%20width='410'%20height='2'/%3e%3cg%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M463,533.5h-61v-207h61V533.5z%20M404,531.5h57v-203h-57V531.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M363,533.5h-61v-152h61V533.5z%20M304,531.5h57v-148h-57V531.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M263,533.5h-61v-316h61V533.5z%20M204,531.5h57v-312h-57V531.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M163,533.5h-62v-248h62V533.5z%20M103,531.5h58v-244h-58V531.5z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",_A="data:image/svg+xml,%3csvg%20width='616'%20height='559'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%3e%3cpath%20fill='none'%20stroke='%23E4E4E4'%20id='svg_1'%20stroke-width='2'%20d='m97.44781,156.99998l419.1042,0l-24.42354,59.30477l-370.25707,0l-24.42359,-59.30477zm29.93028,72.6737l359.24347,0l-24.42354,59.30458l-310.39633,0l-24.42361,-59.30458zm54.35357,131.97891l-24.4232,-59.30521l299.38335,0l-24.42422,59.30521l-250.53593,0zm220.60617,72.6737l-190.67573,0l-24.42491,-59.30458l239.52554,0l-24.42491,59.30458zm-3.92305,72.6737l-182.82963,0l1.26325,-59.30458l180.30313,0l1.26325,59.30458z'/%3e%3c/g%3e%3c/svg%3e",r1="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M307.6,337.5h-28.6l-3.4,41.7h28.6L307.6,337.5z%20M278.4,376.7l3-36.7h23.5l-3,36.7H278.4z'/%3e%3cpath%20fill='%23E4E4E4'%20d='M262.9,415.9h12l2.4-28.6h23.5l-2.4,28.6h12l2.4-28.6h18.6v-10.5h-17.5l3-36.7h17.7v-10.5h-16.8l2.4-28.6%20h-12l-2.4,28.6h-23.5l2.4-28.6h-12l-2.4,28.6h-18.5V340h17.5l-3,36.7h-17.7v10.5h16.8L262.9,415.9z%20M251.1,384.7v-5.5h17.5%20l3.4-41.7h-17.8V332h18.3l2.4-28.6h7l-2.4,28.6h28.6l2.4-28.6h7l-2.4,28.6h17v5.5h-17.5l-3.4,41.7H329v5.5h-18.4l-2.4,28.6h-7%20l2.4-28.6h-28.6l-2.4,28.6h-7l2.4-28.6H251.1z'/%3e%3cpath%20fill='%23E4E4E4'%20d='M84,269.1v178.8h396.6V269.1H84z%20M478.2,445.4H86.5V271.6h391.6V445.4z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",n1="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3crect%20x='25.5'%20y='558.5'%20fill='%23E4E4E4'%20width='516'%20height='2'/%3e%3cpath%20fill='%23E4E4E4'%20d='M518.9,188.1c-18.1,0-32.8,14.7-32.8,32.8c0,10,4.5,19,11.7,25.1l-129,162.8c-5.5-4.1-12.2-6.5-19.6-6.5%20c-10.4,0-19.7,4.9-25.7,12.5l-96.4-71.5c3.7-5.3,5.9-11.8,5.9-18.7c0-18.1-14.7-32.8-32.8-32.8c-18.1,0-32.8,14.7-32.8,32.8%20c0,9.2,3.8,17.5,9.9,23.5L69.5,465.4c-5.8-5-13.2-8-21.4-8c-18.1,0-32.8,14.7-32.8,32.8S30,523,48.1,523s32.8-14.7,32.8-32.8%20c0-9.2-3.8-17.5-9.9-23.5l107.8-117.4c5.8,5,13.2,8,21.4,8c10.4,0,19.7-4.9,25.7-12.5l96.4,71.5c-3.7,5.3-5.9,11.8-5.9,18.7%20c0,18.1,14.7,32.8,32.8,32.8s32.8-14.7,32.8-32.8c0-10-4.5-19-11.7-25.1l129-162.8c5.5,4.1,12.2,6.5,19.6,6.5%20c18.1,0,32.8-14.7,32.8-32.8S537,188.1,518.9,188.1z%20M48.1,521c-17,0-30.8-13.8-30.8-30.8s13.8-30.8,30.8-30.8%20c7.7,0,14.7,2.8,20.1,7.5c0.5,0.4,1,0.9,1.5,1.4c5.7,5.6,9.3,13.4,9.3,22C78.9,507.2,65,521,48.1,521z%20M200.2,355.4%20c-7.7,0-14.7-2.8-20.1-7.5c-0.5-0.4-1-0.9-1.5-1.4c-5.7-5.6-9.3-13.4-9.3-22c0-17,13.8-30.8,30.8-30.8c17,0,30.8,13.8,30.8,30.8%20c0,6.5-2,12.5-5.5,17.5c-0.4,0.5-0.8,1.1-1.2,1.6C218.7,350.8,210,355.4,200.2,355.4z%20M349.3,465.9c-17,0-30.8-13.8-30.8-30.8%20c0-6.5,2-12.5,5.5-17.5c0.4-0.5,0.8-1.1,1.2-1.6c5.6-7.1,14.4-11.7,24.1-11.7c6.9,0,13.2,2.3,18.3,6.1c0.5,0.4,1.1,0.8,1.6,1.2%20c6.7,5.7,10.9,14.1,10.9,23.5C380.1,452,366.3,465.9,349.3,465.9z%20M518.9,251.7c-6.9,0-13.2-2.3-18.3-6.1c-0.5-0.4-1.1-0.8-1.6-1.2%20c-6.7-5.7-10.9-14.1-10.9-23.5c0-17,13.8-30.8,30.8-30.8s30.8,13.8,30.8,30.8S535.9,251.7,518.9,251.7z'/%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",wA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cg%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M480.4,506.2l-162.3-106L509.4,431l-0.2,1c-4.3,26.5-13.8,51.2-28.4,73.4L480.4,506.2z%20M327,403.7%20l152.7,99.8c13.9-21.5,23.1-45.3,27.3-70.8L327,403.7z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M275.3,586.8C170.9,586.8,86,502,86,397.7c0-50.6,19.6-98.1,55.1-133.8c35.6-35.7,83-55.5,133.5-55.5h1%20v188.7l158.3,103.1l-0.5,0.8C398.1,554.8,339.1,586.8,275.3,586.8z%20M273.5,210.7c-49.6,0.3-96.1,19.7-131.1,54.8%20C107.3,300.7,88,347.7,88,397.7c0,103.2,84,187.1,187.4,187.1c62.7,0,120.9-31.4,155.7-83.9L273.5,398.3V210.7z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M482.8,408.7l-1-0.2l-187.3-30V188.5h1c74.8,0,142.7,44.1,173.1,112.2c15.2,34.1,20.2,71.1,14.4,107%20L482.8,408.7z%20M296.5,376.9l184.6,29.5c5.5-35.2,0.5-71.4-14.4-104.9c-29.9-67.1-96.6-110.5-170.2-110.9V376.9z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",CA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M298.5,607.2c-12.6,0-25.3-1.1-37.6-3.2l-1-0.2l29.6-198l-27.1,61l-20.3-12.1l45.2-52.6L126.8,524.6%20l-0.6-0.8c-12.1-15.5-21.8-32.7-29-50.9l-0.4-0.9l0.9-0.4l181.4-70.1l-149.6,20.9v-47.1l158.4,22.1L97.5,323.8l0.4-0.9%20c7.3-18,17.1-34.9,29.3-50.4l0.6-0.8L282,389.2l-76.9-89.5l34.5-20.2l49.9,112.2l-29.6-198l1-0.2c12.4-2.1,25-3.2,37.6-3.2%20c8,0,16.1,0.4,23.9,1.3l1,0.1l-0.2,1l-29.7,198.8l83.2-187.1l0.9,0.3c19.5,7.5,37.7,17.7,54.3,30.3l0.8,0.6L301.2,389.2l132.5-101%20l28,44.9l-166,64.2L511.5,367l0.1,1c1.6,10.2,2.4,20.6,2.4,30.8c0,10.2-0.8,20.6-2.4,30.8l-0.1,1l-207.1-29l95.5,36.9l-18.5,28.9%20l-85.5-65.1l108.5,126.3l-45.5,23.8l-65.1-146.5l29.9,199.9l-1,0.1C314.4,606.8,306.4,607.2,298.5,607.2z%20M262.2,602.2%20c12,2,24.2,3,36.3,3c7.4,0,15.1-0.4,22.7-1.2l-29.7-198.5L262.2,602.2z%20M295.3,404.7l64.5,144.9l41.4-21.7L295.3,404.7l0.1,0.1%20L295.3,404.7z%20M99.4,473.1c7,17.4,16.3,33.8,27.8,48.7l158.3-120.6L99.4,473.1z%20M297.8,401.2l83.1,63.3l16-25L297.8,401.2z%20M245.2,454.3l16.3,9.7l26.4-59.4L245.2,454.3z%20M298.8,398.8l211,29.5c1.4-9.8,2.2-19.7,2.2-29.5c0-9.8-0.7-19.7-2.2-29.5%20L298.8,398.8z%20M131.5,377.6V420l152.2-21.2L131.5,377.6z%20M433.2,291.1L297.8,394.2l160.9-62.2L433.2,291.1z%20M100.1,322.6%20l185.2,71.6L128.2,274.5C116.6,289.3,107.2,305.5,100.1,322.6z%20M377.9,207.1L295.3,393l0,0l0,0L430,236.1%20C414,224.1,396.5,214.3,377.9,207.1z%20M287.9,393L287.9,393l-49.2-110.6l-30.5,17.8L287.9,393L287.9,393z%20M262.2,195.3L291.6,392%20l29.6-198.5c-7.5-0.8-15.1-1.2-22.7-1.2C286.4,192.3,274.2,193.4,262.2,195.3z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",xA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cpolygon%20fill='%23E4E4E4'%20points='80,575%2080,233%2078,233%2078,575%2078,577%2080,577%20497,577%20497,575%20'/%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M374.7,480.1c-29.7,0-53.9-24.2-53.9-53.9c0-29.7,24.2-53.9,53.9-53.9s53.9,24.2,53.9,53.9%20C428.6,455.9,404.4,480.1,374.7,480.1z%20M374.7,374.3c-28.6,0-51.9,23.3-51.9,51.9s23.3,51.9,51.9,51.9s51.9-23.3,51.9-51.9%20S403.3,374.3,374.7,374.3z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M264.2,395.2c-22,0-40-17.9-40-40c0-22,17.9-40,40-40s40,17.9,40,40C304.2,377.3,286.2,395.2,264.2,395.2z%20M264.2,317.3c-20.9,0-38,17-38,38c0,20.9,17,38,38,38s38-17,38-38C302.2,334.3,285.1,317.3,264.2,317.3z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M413.7,351.2c-38.8,0-70.3-31.6-70.3-70.3c0-38.8,31.6-70.3,70.3-70.3s70.3,31.5,70.3,70.3%20C484,319.6,452.4,351.2,413.7,351.2z%20M413.7,212.5c-37.7,0-68.3,30.7-68.3,68.3c0,37.7,30.7,68.3,68.3,68.3%20c37.7,0,68.3-30.7,68.3-68.3C482,243.2,451.3,212.5,413.7,212.5z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M228.9,489C228.9,489,228.9,489,228.9,489c-15.8,0-29.7-10.1-34.5-25.2c-3-9.2-2.2-19,2.3-27.7%20c4.4-8.6,11.9-15,21.2-18c3.6-1.2,7.4-1.8,11.1-1.8c15.8,0,29.7,10.1,34.5,25.2c3,9.2,2.2,19.1-2.3,27.7c-4.4,8.6-11.9,15-21.2,18%20C236.4,488.4,232.6,489,228.9,489z%20M228.9,418.4c-3.6,0-7.1,0.6-10.5,1.7c-8.7,2.8-15.8,8.8-20,17c-4.2,8.1-4.9,17.4-2.1,26.1%20c4.6,14.2,17.7,23.8,32.6,23.8c3.6,0,7.1-0.6,10.5-1.7c8.7-2.8,15.8-8.8,20-17c4.2-8.1,4.9-17.4,2.1-26.2%20C256.9,428,243.8,418.4,228.9,418.4z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M147.5,548C147.5,548,147.5,548,147.5,548c-9.4,0-17.6-6-20.4-14.9c-3.6-11.3,2.6-23.4,13.9-27%20c2.1-0.7,4.4-1,6.6-1c9.3,0,17.6,6,20.4,14.9c3.6,11.3-2.6,23.3-13.9,27C152,547.7,149.7,548,147.5,548z%20M147.5,507.1%20c-2,0-4,0.3-6,0.9c-10.2,3.3-15.9,14.2-12.6,24.4c2.6,8.1,10,13.5,18.5,13.5c0,0,0,0,0,0c2,0,4-0.3,6-0.9%20c10.2-3.3,15.8-14.3,12.6-24.5C163.4,512.5,156,507.1,147.5,507.1z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",TA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M148.3,490.8l-1-1.3c-25.5-31.2-39.6-70.6-39.6-111c0-40.4,14.1-79.8,39.6-111l1-1.3l26.9,26.9l-0.8,1%20c-38.6,49.6-38.6,118.9,0,168.6l0.8,1L148.3,490.8z%20M148.5,270.8c-24.4,30.4-37.9,68.6-37.9,107.8c0,39.1,13.4,77.4,37.9,107.8%20l22.7-22.7c-38.4-50.3-38.4-119.9,0-170.2L148.5,270.8z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M368.3,270.8l-1-0.8c-23.9-18.6-53.9-28.9-84.3-28.9c-30.4,0-60.3,10.2-84.3,28.9l-1,0.8l-26.9-26.9%20l1.3-1c31.2-25.5,70.6-39.6,111-39.6c40.4,0,79.8,14.1,111,39.6l1.3,1L368.3,270.8z%20M283,238.1c30.6,0,60.8,10.2,85.1,28.7%20l22.7-22.7c-30.4-24.4-68.6-37.9-107.8-37.9c-39.2,0-77.4,13.4-107.8,37.9l22.7,22.7C222.2,248.3,252.4,238.1,283,238.1z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M417.7,490.8l-26.9-26.9l0.8-1c38.6-49.6,38.6-118.9,0-168.6l-0.8-1l26.9-26.9l1,1.3%20c25.5,31.2,39.6,70.6,39.6,111c0,40.4-14.1,79.8-39.6,111L417.7,490.8z%20M394.8,463.7l22.7,22.7c24.4-30.4,37.9-68.6,37.9-107.8%20c0-39.1-13.4-77.3-37.9-107.8l-22.7,22.7C433.1,343.8,433.1,413.4,394.8,463.7z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M283,553.9L283,553.9c-40.4,0-79.8-14.1-111-39.6l-1.3-1l26.9-26.9l1,0.8c23.9,18.6,53.9,28.9,84.3,28.9%20c30.4,0,60.4-10.2,84.3-28.9l1-0.8l26.9,26.9l-1.3,1C362.8,539.9,323.4,553.9,283,553.9z%20M175.2,513.1%20c30.4,24.4,68.6,37.9,107.7,37.9h0.1c39.1,0,77.3-13.4,107.8-37.9l-22.7-22.7c-24.3,18.5-54.4,28.7-85.1,28.7%20c-30.6,0-60.8-10.2-85.1-28.7L175.2,513.1z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M283,458c-43.8,0-79.4-35.6-79.4-79.4c0-43.8,35.6-79.4,79.4-79.4c43.8,0,79.4,35.6,79.4,79.4%20C362.4,422.4,326.8,458,283,458z%20M283,302.2c-42.1,0-76.4,34.3-76.4,76.4c0,42.1,34.3,76.4,76.4,76.4c42.1,0,76.4-34.3,76.4-76.4%20C359.4,336.5,325.1,302.2,283,302.2z'/%3e%3c/g%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M283,493c-63.1,0-114.4-51.3-114.4-114.4S219.9,264.2,283,264.2c63.1,0,114.4,51.3,114.4,114.4%20S346.1,493,283,493z%20M283,267.2c-61.4,0-111.4,50-111.4,111.4S221.6,490,283,490c61.4,0,111.4-50,111.4-111.4%20S344.4,267.2,283,267.2z'/%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e",SA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2018.1.1,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566.5%20700.5'%20enable-background='new%200%200%20566.5%20700.5'%20xml:space='preserve'%3e%3cg%20id='Layer_2'%3e%3crect%20x='-5057'%20y='-6963'%20fill='transparent'%20stroke='%23000000'%20stroke-miterlimit='10'%20width='16156.4'%20height='16115.1'/%3e%3c/g%3e%3cg%20id='Layer_1'%3e%3cpath%20fill='%23E4E4E4'%20d='M399,207h-2H284h-2H170h-2H53v35v4v31v2v31v2v30v2v31v2v30v2v31v2v31v2v34h115h2h112h2h113h2h116v-34v-2%20v-31v-2v-31v-2v-30v-2v-31v-2v-30v-2v-31v-2v-31v-4v-35H399z%20M397,211v31H284v-31H397z%20M282,279v31H170v-31H282z%20M170,277v-31h112%20v31H170z%20M282,312v30H170v-30H282z%20M282,344v31H170v-31H282z%20M282,377v30H170v-30H282z%20M282,409v31H170v-31H282z%20M282,442v31H170%20v-31H282z%20M284,442h113v31H284V442z%20M284,440v-31h113v31H284z%20M284,407v-30h113v30H284z%20M284,375v-31h113v31H284z%20M284,342v-30h113%20v30H284z%20M284,310v-31h113v31H284z%20M284,277v-31h113v31H284z%20M282,211v31H170v-31H282z%20M57,211h111v31H57V211z%20M57,246h111v31H57%20V246z%20M57,279h111v31H57V279z%20M57,312h111v30H57V312z%20M57,344h111v31H57V344z%20M57,377h111v30H57V377z%20M57,409h111v31H57V409z%20M57,442h111v31H57V442z%20M57,505v-30h111v30H57z%20M170,505v-30h112v30H170z%20M284,505v-30h113v30H284z%20M511,505H399v-30h112V505z%20M511,473H399v-31h112V473z%20M511,440H399v-31h112V440z%20M511,407H399v-30h112V407z%20M511,375H399v-31h112V375z%20M511,342H399v-30h112%20V342z%20M511,310H399v-31h112V310z%20M511,277H399v-31h112V277z%20M399,242v-31h112v31H399z'/%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",MA="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3cpath%20fill='%23E4E4E4'%20d='M52,202.5v200v2v104h462v-306H52z%20M510,402.5H225v-196h285V402.5z%20M56,206.5h167v196H56V206.5z%20M56,404.5%20h298v100H56V404.5z%20M356,504.5v-100h154v100H356z'/%3e%3c/g%3e%3c/g%3e%3c/svg%3e",i1="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='utf-8'?%3e%3c!--%20Generator:%20Adobe%20Illustrator%2017.1.0,%20SVG%20Export%20Plug-In%20.%20SVG%20Version:%206.00%20Build%200)%20--%3e%3c!DOCTYPE%20svg%20PUBLIC%20'-//W3C//DTD%20SVG%201.1//EN'%20'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd'%3e%3csvg%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%20x='0px'%20y='0px'%20viewBox='0%200%20566%20700'%20enable-background='new%200%200%20566%20700'%20xml:space='preserve'%3e%3cg%20id='Layer_1'%3e%3cg%3e%3cpath%20fill='%23E4E4E4'%20d='M276.8,521.3c-0.5,0-0.9-0.1-1.3-0.2l-0.3-0.1l-0.2-0.2c-0.5-0.6-1-1.3-0.8-1.9c-1-0.6-2.6-0.6-4-0.6%20c-1,0-1.8,0-2.5-0.2l-0.3-0.1l-0.2-0.2c-0.5-0.6-2.8-1.7-4.5-2.5c-1.9-0.9-3.8-1.7-4.8-2.5l-0.2-0.2l-0.1-0.3c-2-5-2.7-6.5-3-7%20c-0.1-0.3-0.2-0.4-0.2-0.6c-0.1-0.6,0-1.1,0.1-1.4c0.1-0.5,0.2-1-1.2-3.5c-0.4-0.6-2.4-2.7-3.6-3.8l-0.2-0.2l-1.1-3%20c-1.8-1.6-3.5-5.2-5.1-8.3c-0.7-1.4-1.3-2.6-1.8-3.5c-1.1-1.6-2-2.4-2.9-3.2c-1.1-1-2.2-2-3.8-4.3c-2.1-0.3-3.7,0-5.3,0.4%20c-2,0.4-3.9,0.8-6-0.3c-0.4,0.5-1.1,1.8-1.6,2.7c-1.6,2.9-3.4,6.3-5.8,5.3c-12.1-4.7-13.8-9.4-14.9-12.4c-0.1-0.3-0.2-0.6-0.3-0.8%20l-0.1-0.2l0-0.2c0.2-2.3,0.1-2.4-0.3-3.1c-0.4-0.7-1-1.7-1.9-4.2c-4.3-2.4-8.1-7.1-10.8-10.5c-1.1-1.3-2-2.5-2.7-3.2%20c-0.1,0-0.2-0.1-0.4-0.1l0,0.2l-0.9-0.1c-2.4-0.3-7.4-0.9-14.7-1.2l-1,4.1l-0.4,0.2c-2.2,1-6.3,1.8-8.9,0.7l0,0l-9.4-1.9%20c-5.6,0.2-10.8-2.5-14.6-4.5l-0.9-0.5c-4.7-2.3-8.4-4.5-11.4-6.3c-1.2-0.7-2.2-1.3-3.2-1.9c-5.5-3.1-9.2-5.2-15.9-8.5l-0.5-0.2%20l-0.1-0.5c-0.1-0.7-0.1-1.2-0.1-1.6c0-0.1,0-0.3,0-0.4l-5.3-0.6c-6-0.7-12.2-1.3-16.2-1.5l-0.1,0.1l-0.7-0.1l0.1-1.1l-0.5-0.7%20c-0.3,0.2-0.4,0.5-0.4,0.6c0.1-1-1.4-8.7-2.7-10.8c-1.4-2.1-3.1-3.5-5.6-4.5l-0.3-0.1l-0.2-0.2c-0.7-0.9-0.8-2.2-0.8-3.1%20c-0.3-0.1-0.6-0.2-1.1-0.3c-1.8-0.6-6.9-4.8-7.6-6.2c-0.8-0.8-2.2-1.9-3.2-1.9c-2.7,0-4.7-0.8-5.8-2.4c-1.7-2.4-0.9-5.9-0.1-8%20c-1.4-2.2-2.9-5.5-4.2-8.4c-1.2-2.7-2.5-5.4-3.2-6.3l-0.2-0.2l0-0.3c-0.2-1.6-0.5-4.7,2.1-6.5c0.1-0.9-0.3-1.2-1.2-1.8%20c-0.9-0.7-2.2-1.6-2.8-3.6c-0.3-0.9-0.1-3.3,0.1-5.1c0,0-0.1,0-0.1,0c-0.2-0.1-0.5-0.4-0.7-0.9l-0.1-0.3l0.1-0.3%20c0.3-0.8,0.4-1.2,0.4-1.4c-0.1-0.1-0.3-0.4-0.4-0.7l-0.1-0.5l0,0c0,0-0.1-0.1-0.1-0.1c-0.6-0.6-1.3-1.2-1.7-2.2l-0.3-0.5l0.4-0.5%20c0.4-0.6,0.3-1.1-0.1-2.5c-0.2-0.6-0.4-1.3-0.5-2c0,0,0,0,0,0c-1.3-0.9-4-2.8-3.1-9.6c0.4-2.6,0.5-4.7,0.6-6.6%20c0.1-0.8,0.1-1.6,0.2-2.5c-0.8-1-2.8-4.1-2.3-7.1c0.3-1.6,1.2-2.9,2.8-3.9c1.5-2.9,3.3-8.8,3.6-12.7c-0.7-1.2-0.5-2.7-0.2-4.7%20c0.1-0.7,0.2-1.5,0.3-2.4c0.4-4.3,2.4-8.3,5.1-10.4c3.3-8.1,7.8-19.4,11.2-28.6l-0.4-0.3l0.3-0.9c-1-0.6-0.9-2-0.9-2.5%20c0.1-1.4,1.1-2.6,1.8-3.4c0,0,0,0,0.1-0.1c-0.6-1.6-0.6-1.9-0.4-3.7c0.2-1,0.9-1.5,1.4-1.7c0-0.9-0.2-2.8-0.3-4.4%20c-0.3-3.2-0.7-7.2-0.5-10.1c0.1-2.1,0.9-3.4,2.2-3.8c3.8-1.2,10.8,7.2,12.9,9.7l0.5,0.6l-0.4,0.6c-1.2,1.7-0.2,6.3,0.8,8.6%20c0.3-1.3,0.9-3.2,2.7-3.7l0.2-3.6l0.1,0c0-0.4-0.1-1.3-0.2-2c-0.4-2.8-0.5-4.3,0-5.1c0-0.3-0.4-1.1-0.6-1.6%20c-0.6-1.1-1.2-2.4-0.8-3.7l0.3-1.1l1,0.4c2.4,1,29.9,7.4,44.2,10.6c2.8,0.3,7.6,1.6,8.4,1.8c0.4,0,1.5,0.2,4.9,0.8%20c7.5,1.3,23.2,4,42.1,6.6c14.2,2,31.3,3.6,47.7,5.1l54.2,1.4c2.1-0.3,4.4-0.4,14.5-0.4v-1c0-2.1,0.8-2.3,2.8-2.8l0.3-0.1%20c1.4-0.2,3.3,2.6,3.6,4c0.1,0.7,0.7,2.1,1.3,2.6c1.1,0.9,1.9,1,2.7,1.1c0.4,0.1,0.8,0.1,1.2,0.2c0.1,0,0.4,0.1,0.7,0.2%20c0.8,0.2,2.8,0.7,3.3,0.6c8.4-1,8.6-0.5,9.1,0c0.1,0.1,0.1,0.4,0.1,0.9v0.2l-0.1,0.3c-0.2,0.2-0.3,0.5-0.4,0.7%20c3.4,0.4,6.8,2.2,8,3c2.4-1.1,4.4-1.3,7.2-1.6c1-0.1,2.2-0.2,3.5-0.4l5.5-0.3c3-1,6.7-2.1,7.8-1.8l0.2,0.1l0.2,0.2%20c0.6,0.5,1.3,2.4,0.5,4.1c-1,2.2-3.8,3.1-8.4,2.6l-0.2,0l-0.2-0.1c-1-0.6-6.7,1.9-8.1,2.9c-0.8,0.6-6.6,6.7-9.9,10.4%20c1.5-0.3,3.2-1,4.7-1.7c1.3-0.6,2.5-1.1,3.4-1.2l0.6-0.1l0.8,1.4c0.2,0.2,0.3,0.4,0.4,0.5c0.2,0.6-0.2,1-0.4,1.2%20c-0.1,0.1-0.1,0.1-0.2,0.2c1,0.2,1.8,0.4,2.4,0.6c0.5-0.1,2.4-0.4,2.6-1.5c0-0.2,0.1-0.5,0.2-0.7l2.1-2.9l-0.2,2.3%20c2.1-0.8,6.4-2.8,8.6-5.2c0.6-1.8,3.7-3.6,4.4-3.9c0.2-0.1,0.4-0.2,0.5-0.3c0.7-0.4,1.8-1,2.7-0.6c0.6,0.2,1,0.7,1.3,1.4l0.1,0.2%20l0,0.2c-0.2,2.4-2.1,2.5-2.8,2.6c-0.1,0-0.2,0-0.2,0c-0.1,0-0.4,0.3-0.7,0.7c0.2,0.7-0.1,1.5-0.5,2.1c2-0.2,4.5,0.4,8.1,3.9%20c0.5-0.1,1.2-0.2,1.9-0.3l0.3,0l0.3,0.2c1.3,0.9,4.8-1.3,6.3-2.2c0.8-0.5,1.2-0.7,1.6-0.8l0.1,0c0.7-0.1,1.4-0.2,2-0.3%20c1.9-0.3,3.4-0.5,4.4-1.1l1.1-0.6l0.4,1.5c0.2,0.8,0.5,1.7,1,1.9c0.6,0.3,1.8,0,3.3-0.7l1.3-0.6l0.1,1.4c0.1,0.5,1.6,2.4,2.4,3.4%20c0.5,0.7,1.1,1.6,1.4,2l1.1,1.8h-1.9c-1.3,0-3.1-0.1-4.7,0c0,0,0-0.1,0-0.1c-0.1,0.1-0.1,0.1-0.3,0.6l11.1,4.2l0.2,0.2%20c0.1,0.1,1.4,1.6,2.3,3.9l0,0.1c0.6,2.6,1.3,7.7,1.3,7.8l0.1,0.9l-0.9,0.2c-0.3,0.1-0.5,0.1-0.6,0.1c0,0,0,0,0,0%20c-0.6,2.3-1.2,3.9-2.8,4.3c-0.5,1.4-0.2,1.9-0.1,2.1c0.2,0.2,0.5,0.3,0.7,0.3l1.6-1.3c0.2-0.9,0.8-2.9,3.5-4.5l0.3-0.2l0.3,0%20c2.8,0.1,4,2.2,4.5,3.1l0.2,0.5c1.2,5.7,3.2,7.3,3.2,7.3l0.4,0.3l0,0.5c-0.1,1.8-0.3,3.9-0.2,4.4c0.2,0.8,0,2.1-0.2,2.6%20c-0.2,0.6-0.4,1-0.7,1.2c0,0.2,0.2,0.3,0.2,0.6v0.7l-0.8,0.3c-0.2,0.1-0.4,0.1-0.5,0.2c0,0,0,0,0,0l0.1,0.5l-0.3,0.4%20c-0.5,0.6-1.1,0.7-1.5,0.9c-0.4,0.1-0.4,0.1-0.5,0.2c-0.1,0.3-0.1,0.4-0.1,0.4c0,0.1,0.2,0.3,0.3,0.5l0.7,0.9l-0.7,0.6%20c-0.6,0.5-2,2.2-2.6,3.7c2.2,0.5,5.9,1.4,7.4,1.7c1.2-1.3,2.6-1.7,3.5-2c0.1,0,0.2-0.1,0.3-0.1l0-0.2l2.8-1.1l1.8-2.1%20c0.1-0.1,2.4-3.3,5.5-4.1l0.3-0.2l2.1-0.7c0.3-0.1,0.8-0.3,1.3-0.4c0.8-0.2,1.7-0.5,2.2-0.8l0.2-0.1l0.2,0c0,0,1-0.2,2.5-0.2%20c0.2-0.3,0.4-0.7,0.7-1.1c1.1-1.6,3.3-4.9,3.6-5.7l0.3-0.8l0.6,0.1c0-0.1,0.1-0.2,0.1-0.3c0.2-0.4,0.4-0.8,0.7-1.4%20c0-0.7-0.3-1.2-0.7-2c-0.4-0.7-0.9-1.4-1.1-2.4c-0.1-0.2-0.3-0.4-0.3-0.5v0c0-0.1,0.2-0.2,0.2-0.2l-0.1-0.1c0-0.3-0.1-0.5-0.1-0.7%20V291l1.6,5.8c0.1-0.1,0.3-0.1,0.5-0.2c1.3-0.5,5-1,9.2-1.5c1.5-0.2,2.8-0.3,3.4-0.4c1.8-0.4,4.6-1.2,5.3-1.7%20c0.8-0.6,1.7-1.8,2.2-2.3c0.1-1.5,0-3.8-0.6-4.4c-0.1-0.1-0.3-0.2-0.6-0.1l-1.1,0.2l-0.1-1.1c-0.1-1.6,0.9-2.8,1.3-3.1%20c5-7.8,9-11.1,9.2-11.2l0.2-0.1l12-3l0-0.4l0.8-0.2c4.5-0.9,8.2-2,11.2-2.8c1-0.3,1.9-0.6,2.7-0.8c0-0.3,0-0.6,0-0.8%20c0.2-1.4,1.6-2.8,3.3-3.3c0.1,0,0.1-0.1,0.2-0.1l1.3-3v-1.5c-0.4-0.5-0.8-1.3-0.5-2c0.2-0.4,0.6-0.9,1.7-0.8%20c0.5-0.6,1-2.9,1.2-10.6c0-0.8,0-1.5,0.1-1.8l0-0.4l0.3-0.3c0.7-0.6,1.2-2.3,1.7-3.7c0.6-2,1.2-3.9,2.6-4.7l0.8-0.4l0.5,0.8%20c0.2,0.4,1.1,1.4,2,1.3c0.9-0.2,1.5-0.7,2.1-1.3c0.8-0.7,1.7-1.5,3-1.5h0.3l0.3,0.2c3.6,2.8,4.2,3.6,4.9,4.9%20c0.2,0.3,0.4,0.7,0.7,1.1l0.1,0.3c0.2,0.6,0.6,2.1,1.1,4c0.8,2.7,1.8,6.3,2.2,7.5c0.2,0.1,0.7,0.1,1.1,0c2-0.2,2.5,1.3,2.8,2.4%20c0.1,0.4,0.3,0.9,0.6,1.4c0.1,0,0.3,0.1,0.4,0.2c0.9,0.6,1.2,2.1,1.5,3.6c0.1,0.5,0.2,1.2,0.3,1.5l0.5,0.4l-0.3,0.7%20c-0.4,0.9-1.5,2.5-2.5,4c-0.2,0.4-0.4,0.6-0.5,0.8c-0.9,2.3-2.9,4-5.4,4.7c-1.3,0.3-2.4,0.3-3.2-0.1c-0.2,1.2-0.4,2.5-0.3,3.2%20l0,0.8l-1.8,0.6c-0.4,2-2.1,4-3.6,4.9c0.1,0.7,0.4,1.6,0.6,2.5c0.6,2.3,1.3,4.7,0.8,6.3l-0.1,0.4l-0.4,0.2%20c-1.8,0.8-3.9,1.4-5.5,1.6c0.3,0.4,0.9,0.8,2,1.4l0.9,0.4l-0.5,0.9c-0.2,0.4,0.1,2.1,0.2,2.9c0.1,0.5,0.1,0.9,0.2,1.2%20c1.7,2.5,3,3.3,3.6,3.1c0.5-0.1,0.9-0.9,0.9-1.3l0.1-0.7l0.7-0.2c2.2-0.5,3.5,1.3,4.2,2.4c0.1,0.2,0.3,0.4,0.4,0.6%20c1.4,0.2,4,0.4,4.9,0.3l1.1-0.2v1.2c0,0.5,0,1.4-4.1,2.5c-1.4,0.3-2.7,0.1-3.8-0.5c-0.6,0.5-1.3,0.7-1.9,0.6%20c-0.5-0.1-0.8-0.3-1.1-0.5c-0.4,0.3-1,0.7-1.5,0.9l-1.7,0.5l0.2-0.8c-0.9-0.1-2.3-0.2-3.8-0.2c0.6,1.1,1.5,2.5,2.1,3.5l0.4,0.6%20l-0.4,0.6c-2.1,2.8-5.7,4.7-5.9,4.8l-0.2,0.1c-3,0.8-14.2,8-19.4,11.4l1.3,0.1l0.2,0.7c0,0.2,1.1,4.6,0,9%20c-1.1,4.2-3.8,8.9-3.9,9.1l-0.9,1.6l-1.5-3l-2-0.4l-2.3-1.3c0.6,1.2,1.3,2.7,1.6,3.3l0.1,0.2c0.4,3.5,1.5,5.4,1.5,5.4l0.2,0.3%20l-0.3,4.6l0.2,0.1l-0.1,0.9c0,0,0,0.2-0.1,0.4l-0.1,1.6h-0.9c-0.1,0.1-0.4,0.4-0.7,0.8c-1.1,1.2-2.5,0.8-3.4,0.4%20c-0.1,0.2-0.3,0.4-0.6,0.5c-0.3,0.1-0.6,0.1-0.8,0.1c0,0,0,0,0,0c-0.6,0.4-1.5,0.2-2.7-0.6c0.2,0.6,0.1,1.2,0,1.7%20c0,0.2-0.1,0.6-0.1,0.7c0.3,0.4,0.4,0.8,0.5,1c0.1,0.2,0.1,0.3,0.4,0.5c0.5,0.4,0.6,0.8,0.6,1.1c0,0.6-0.4,1-0.7,1.2%20c0,0-0.1,0.1-0.1,0.1c0.1,0.1,0.4,0.4,1,0.8c0.4,0.3,1.3,0.9,1.1,1.8c-0.2,0.9-1.1,1-1.9,1.2c-0.2,0-0.5,0.1-0.8,0.2%20c0.2,0.3,0.6,0.8,1.6,1.6c0.9,0.8,1.5,1.9,1.7,2.8h1.1c0.8,0,1.4,0.4,1.7,0.8c2.3-0.2,6.4-0.4,8.7,5.2c1.3,3.1-2.5,8-2.9,8.6%20l-0.1,0.1c-0.7,0.6-1.8,0.5-3,0.5c-0.1,0-0.2,0-0.3,0l0.4,0.3l-0.1,0.6c0,0.2-0.1,0.5-0.2,0.7c-0.1,0.5-0.2,0.8-0.1,1.1%20c0.1,0,0.2,0,0.2,0c0.5-0.1,1.3-0.3,2,0.2c0.5,0.4,0.7,0.9,0.8,1.8c0.2,1-0.8,2.4-1.2,2.9l-0.7,0.9l-0.7-0.7c-0.2,0-1.2,0-4.3,1.7%20c-3.3,1.4-5.3,5.8-6,9.1l-0.1,0.2l-0.2,0.2c-0.6,0.7-1.8,1.5-2,1.5l-0.2,0.1l-0.2,0c-1.7,0.1-2.5,0.5-3.1,0.9%20c-0.3,0.2-0.7,0.4-1.1,0.4c-0.2,0.4-0.6,0.9-1.1,1.5c-0.4,0.5-0.8,1-1.1,1.5c-2.2,5.6-4.7,9.1-4.8,9.3l-0.1,0.2%20c-0.1,0.1-1.3,1.2-2.8,2.1c-0.4,1.3-0.7,2.4-0.7,2.4l-0.2,0.6l-0.6,0.1c-0.8,0.1-1.9,0.5-2.7,0.8c0.6,1.4,0.2,2.4-0.2,2.9%20c-0.7,0.8-1.8,1.2-2.7,1.2c-0.3,0.8-0.7,1.5-1.1,2.1c-1.8,4-3.6,10.4-3.6,15.2c1.1,1.2,1.8,3.4,2.5,5.6c0.3,0.9,0.6,1.9,0.9,2.7%20c1.3,3.1,6.4,11.1,7.5,12.4c0.5,0.1,1.4,0.3,2.2,1.1c1.4,1.3,2.1,3.6,2.1,6.8c0,0.2,0,0.4-0.1,0.6c1.3,2.8,4.1,8.3,7.1,11.1%20l0.2,0.2l0,0.2c1.1,2.9,2.3,11,2.3,13.3v0.5l-0.4,0.3c-1.5,1-1.5,4.8-1.5,6.6c0,1.4,0,1.8-0.5,2.2l-0.4,0.3l-0.5-0.1%20c-0.7-0.2-1.5,0.3-2.3,0.7c-1,0.6-2.4,1.4-3.6,0.1c-0.4-0.4-0.3-0.9-0.3-1.1c0-0.1,0-0.1,0.1-0.2c0-0.1-0.1-0.1-0.1-0.2%20c-0.1-0.1-0.2-0.3-0.2-0.4c-0.1,0-0.4,0.1-0.8,0.5l-1.1,0.8l-0.5-1.3c-1-2.9-4.9-5.2-8.6-7.1l-0.5-0.2l-0.1-0.5%20c-0.2-1.6-1-2.9-2.1-3.5c-1.1-0.6-1.5-1.9-1.7-3c-0.5,0.1-0.9-0.1-1.1-0.2l-0.7-0.2l0-0.5c-2.6-1.4-3.9-4.2-5.2-7.1l-0.1-0.2%20l0-0.3c0.1-0.7,0.4-1.4,0.7-2.2c-0.1,0.1-0.2,0.2-0.3,0.3c-0.4,0.3-1,0.3-1.6,0.1l-0.3-0.1l-0.2-0.2c-0.3-0.3-0.5-0.4-0.6-0.5%20c-0.4-0.3-0.9-0.7-0.7-1.7c0.2-3.5,0.6-6.1,0.6-6.2c0.3-1.7,0.4-4.6-0.5-5.3l-0.1-0.1l-0.1-0.1c-0.7-1.1-1.3-1.8-2.2-2.1%20c-3.3-1-5.5-2.7-6.7-5c-1.3-0.5-2.5-1.8-3.1-2.9c-1.6-0.3-5.1-0.6-6.2,0.8l-0.1,0.1l-0.1,0.1c-1.1,0.7-1.9,1.4-2.6,2%20c-1.6,1.4-2.8,2.4-6.5,2.3c-2.6-0.2-3.3-0.9-4-2c-0.4-0.7-0.9-1.4-3.5-1.9c-1.1-0.2-1.9-0.4-2.4-0.4c0,0.2,0,0.4-0.1,0.6%20c-0.4,0.8-1.3,0.8-1.6,0.9c-2.1,0.2-2.8-0.8-3.2-1.4c-2.9,1-5.4-0.8-7.1-2c0,0-0.1-0.1-0.1-0.1c0,0,0,0-0.1,0.1l-0.2,0.3%20c0,0.1,0,0.1,0,0.2l0,0.4l-0.2,0.3c-1.1,1.3-3.5,1.8-3.7,1.8l-0.8,0.2l-0.3-0.7c-0.2-0.6-0.8-1.7-1.3-2.7c0,0.2-0.1,0.4-0.1,0.6%20c-0.2,1.2-0.3,2.2-1.1,2.6c-0.1,0.1-0.1,0.3-0.2,0.4c-0.1,0.3-0.4,1-1.1,1c-0.4,0-0.7-0.1-0.9-0.3h-0.4c-0.8,0-1-0.6-1.1-1.4%20c-2.4,0.5-7,1.7-10,3.8c0.1,0.1,0.1,0.3,0.1,0.4c0,0.8-0.6,1.2-1.3,1.5c-0.7,0.4-1.4,0.8-1.3,1.2l0,0.3c0,0.1,0,0.2,0,0.2%20c0.3,0.1,0.7,0.4,1.3,0.8l0.1-0.1l0.6,0.2c6,2.4,6.5,3.4,6.6,3.8c0.1,0.2,0.2,0.5,0.2,0.7v0c0,0.5-0.2,1.8-1.4,2.3%20c-1.3,0.6-3.3-0.3-6.3-2.7c-0.2-0.2-0.4-0.2-0.4-0.2c0,0-0.2,0.1-0.3,0.1c-0.3,0.2-1,0.5-1.7,0.2c-0.1,0.7-0.4,1.5-1.2,2.2%20l-0.5,0.4l-0.6-0.3c-3.4-1.6-4.1-1.2-4.1-1.2c0,0.1-0.1,0.3-0.1,0.4c0,0.1,0,0.3,0,0.4l-0.1,0.7l-0.7,0.1%20c-2.3,0.4-4.2,0.3-6.2-1.1l-0.3-0.2l0-0.2c-0.3-0.4-0.8-1-1.3-2.2c-0.3-0.2-0.7-0.3-1.2-0.5c-0.9-0.2-2-0.3-2.6-1.7%20c-0.3-0.1-0.8-0.1-1.2-0.1h-0.3l-0.2-0.3c-0.4-0.2-1.2-0.4-1.5-0.1c-0.2,0.2-0.1,0.5-0.1,0.8l0.2,0.7l-0.6,0.4%20c-2.9,1.9-6.9,0.5-10.8-0.9c-0.9-0.3-1.8-0.6-2.6-0.9c-2,0.7-4.3,1.2-6,1.2l-0.2,0c-0.1,0-0.1,0-0.2-0.1c-1.4,1-5.1,2.4-6.8,3%20c-0.2,0.8-0.6,2-1.8,2.6l-3.8,3.4l-4.1,2.9l-5,2.2c-0.5,0.5-1.1,0.9-1.6,1.3l0.6,0.4l-1.1,0.8c-0.5,0.3-1,0.7-1.7,1.2%20c-1.6,1.1-4,2.7-4.4,3.9l-0.5,1.9l-0.7-1c0.2,0.9-0.5,1.8-0.9,2.5c-0.1,0.2-0.2,0.3-0.3,0.4l-0.3,0.6l-0.7-0.1l-0.3,1.8%20c-0.1,0.5-0.3,2.1-0.3,2.7c0,0.6,0.3,1.8,0.6,3.1c0.6,2.7,1.4,6,1.2,8.2c0.4,0.1,0.7,0.4,0.9,0.6c0.7,0.9,0.2,2.1,0.1,2.4%20l-0.1,0.1c0,0.1-0.1,0.2-0.1,0.3c-0.1,0.3-0.3,0.8-0.9,1.1c-0.4,0.2-0.8,0.1-1.2,0C278.8,521,277.8,521.3,276.8,521.3z%20M274.9,519.6c0.1,0.2,0.3,0.3,0.4,0.3c0.2,0.1,0.4,0,0.5,0l-0.4-0.5L274.9,519.6z%20M275.5,519.3l0.5,0.4l0.2-0.5c0,0,0,0,0,0%20c0-0.1,0-0.2,0-0.3L275.5,519.3z%20M276.3,519.3c0.9,0.1,2.2-0.3,2.6-0.5l0.4-0.2l0.4,0.2c0-0.1,0.1-0.3,0.2-0.4%20c0-0.1,0-0.1,0.1-0.2c-0.1,0-0.2,0-0.3,0l-1.8,0.3l0.7-1.6c0.6-1.6-0.3-5.6-1-8.3c-0.4-1.5-0.7-2.7-0.7-3.5c0-0.3,0-0.7,0.1-1.1%20l-1.4,0.7l2.7-6.3l1,0.1l0,0c0.2-0.3,0.5-0.8,0.6-1c0,0-0.1,0-0.1-0.1l-0.9-0.4l0.4-0.9c0.3-0.7,1.3-1.3,2.2-1.4%20c0.1,0,0.1,0,0.2,0c0.9-1.5,2.9-2.8,4.8-4.1c0.1-0.1,0.3-0.2,0.4-0.3l-0.4-0.7l0.6-0.6c0.2-0.2,0.4-0.3,0.6-0.3%20c0.5-0.3,1.4-0.9,2.3-1.7l0.1-0.1l5.2-2.3l3.8-2.7l4-3.6c0.7-0.3,0.9-1.5,0.9-1.7l0.1-0.6l0.6-0.2c3-1.1,6.5-2.3,7-2.8l0.5,0.8%20h1.2v-1.1c0-0.1-0.3-0.2-0.4-0.2c0.1,0,0.2,0.1,0.3,0.1c1.5,0,3.7-0.5,5.5-1.2l0.3-0.1l0.3,0.1c1,0.3,2,0.7,3,1%20c3.1,1.1,6.3,2.2,8.5,1.3c-0.1-1.2,0.5-1.8,0.9-2.1c1-0.8,2.5-0.7,3.5-0.3c1.1,0.1,2.1,0.6,2.2,0.6l0.4,0.2l0.1,0.4%20c0.2,0.7,0.5,0.8,1.4,1c0.6,0.2,1.4,0.4,2.1,1l0.2,0.2l0.1,0.2c0.6,1.3,1,1.9,1.2,2.1c0,0,0,0,0,0c1.1,0.7,2.1,0.9,3.8,0.7%20c0.1-0.5,0.4-1.1,1-1.4c1.1-0.6,2.7-0.3,5.3,0.8c0.1-0.3,0.1-0.8,0-1.3c-0.1-0.4-0.2-1.2,0.5-1.6c0.7-0.4,1.4,0.2,1.8,0.6%20c0.2,0.2,0.3,0.2,0.3,0.2c0,0,0.1-0.1,0.2-0.1c0.2-0.1,0.6-0.3,1-0.3c-0.2-0.1-0.3-0.3-0.5-0.5c-0.3-0.2-0.5-0.4-0.6-0.5%20c-0.2,0-0.4-0.1-0.6-0.2c-0.7-0.4-0.8-1.2-0.8-1.9c-0.1-0.6-0.1-1.1,0.1-1.5c-0.3,0-0.6,0-0.9-0.1c-0.9-0.3-1.6-1.1-2.2-2.3%20l-0.2-0.4l0.2-0.4c0.3-0.5,0.6-1,0.8-1.4c0-0.1,0.1-0.1,0.1-0.2l-0.1-0.2l0.5-0.6c0.5-0.5,1.1-0.5,2.6,0.1c0.3,0,0.6,0.1,0.9,0.3%20l0.8,0.3l-0.1,0.4c0.1,0.1,0.2,0.2,0.2,0.3c0.2,0.2,0.4,0.5,0.6,0.7c3.7-2.6,9.3-3.9,11.5-4.3l0.6-0.1l0.1,0.5l0.3-0.6%20c-0.3-0.1-0.6-0.1-0.8,0l0.4-0.2l0.5,0.1c0.2,0.1,0.5,0.2,0.7,0.7l0.2,0.5c0.1-0.1,0.2-0.2,0.4-0.3c0.1-0.2,0.2-0.8,0.2-1.3%20c0.2-1.1,0.3-2.4,1.1-3.2l0.7-0.7l0.7,0.7c0.9,0.9,1.9,2.9,2.4,4c0.6-0.2,1-0.4,1.4-0.8c0-0.4,0.1-0.7,0.1-1v-0.3%20c0-0.1,0.1-0.2,0.1-0.3l0-0.1l0-0.1c0-0.2,0-0.4,0-0.5c-0.2-0.6-0.7-1.4-0.9-1.7l1.6-1.2c0.4,0.4,1,1.2,1.3,2.4%20c0.1,0.2,0.1,0.3,0.1,0.5c0.4,0.2,0.8,0.5,1.3,0.8c1.6,1.1,3.5,2.5,5.5,1.7c0.9-0.4,1.7-0.1,2.2,0.9c0.2,0.3,0.3,0.5,0.9,0.5%20c-0.1-0.3-0.1-0.6,0.1-1c0.5-0.7,1.4-0.7,5,0c3.2,0.7,4.1,1.7,4.8,2.8c0.4,0.6,0.6,0.9,2.4,1c2.9,0.2,3.6-0.4,5.1-1.8%20c0.7-0.6,1.5-1.3,2.6-2.1c2.3-2.7,7.9-1.4,8.6-1.3l0.5,0.1l0.2,0.5c0.4,0.9,1.5,2.2,2.5,2.4l0.5,0.1l0.2,0.4%20c0.8,2,2.7,3.4,5.6,4.3l0.1,0c1.2,0.5,2.2,1.4,3.1,2.8c1.9,1.8,1.2,6.2,1,7l0,0c0,0-0.4,2.6-0.6,6c0.1,0.1,0.2,0.2,0.4,0.3%20c0-0.1,0.1-0.2,0.1-0.3c0.1-0.5,0.4-1.3,1.2-1.7c0.8-0.3,1.6,0.1,2.2,0.5c0.3,0.1,0.5,0.3,0.6,0.6c0.4,0.7-0.1,1.6-0.7,2.8%20c-0.3,0.6-0.6,1.3-0.8,1.8c1.2,2.8,2.5,5.1,4.7,6.1l0.4,0.1l0-0.1l1,0l1,0l0,1c0,1,0.3,2.3,0.9,2.7c1.5,0.8,2.6,2.5,3,4.5%20c3.4,1.8,7,4.1,8.6,6.9c0.4-0.2,0.9-0.3,1.4-0.2c0.8,0.2,1.2,0.9,1.5,1.4c0.1,0.2,0.2,0.3,0.3,0.5c0.1,0.1,0.2,0.3,0.3,0.4%20c0.2-0.1,0.4-0.2,0.6-0.3c0.7-0.4,1.6-0.9,2.6-1c0-0.1,0-0.3,0-0.4c0-2.3,0.1-6,2-7.8c-0.1-2.4-1.2-9.2-2.2-11.9%20c-3.4-3.3-6.4-9.6-7.6-12.2l-2.4-5.1l2.4,2.4c-0.2-2-0.9-3-1.4-3.5c-0.6-0.5-1.1-0.6-1.1-0.6l0,0l-0.1,0l-0.1,0%20c-1.7-0.4-8-11.7-8.8-13.6c-0.4-0.9-0.7-1.9-1-2.9c-0.6-1.8-1.3-3.9-2-4.8l-0.5-0.4l0.4-0.5l-0.5,0c-0.1-5.2,1.9-12.1,3.8-16.6%20l0.1-0.2c0.5-0.7,1-1.5,1.1-2.3l0.2-1.3l1.2,0.5c0.2,0.1,1.2,0,1.5-0.4c0.3-0.4-0.2-1.2-0.5-1.5l-0.8-1.1l1.3-0.4%20c0,0,0.2-0.1,0.3-0.1c0.7-0.3,2-0.8,3.2-1.1c0.2-0.5,0.4-1.3,0.6-2.2l0.1-0.4l0.4-0.2c1.2-0.7,2.4-1.7,2.7-2%20c0.4-0.6,2.5-3.9,4.5-8.9l0.1-0.2c0.3-0.5,0.8-1.1,1.2-1.7c0.3-0.4,0.7-0.9,0.9-1.2c-0.2-0.4-0.2-0.8,0.1-1.2%20c0.5-0.6,1.2-0.3,1.6,0c0.1,0,0.1-0.1,0.2-0.1c0.6-0.4,1.7-1,3.7-1.1c0.4-0.2,0.8-0.6,1.1-0.8c0.4-1.9,2.3-8.2,7.1-10.2%20c2.3-1.3,4.2-2,5.4-1.9c0.2-0.4,0.4-0.7,0.4-0.8c0-0.2,0-0.3,0-0.3c-0.1,0-0.2,0-0.3,0.1c-0.5,0.1-1,0.2-1.6,0l-0.3-0.1l-0.2-0.2%20c-0.9-1.2-0.6-2.4-0.4-3.2c0,0,0,0,0-0.1c-0.4-0.5-0.8-1.2-0.7-1.8c0-0.5,0.3-0.9,0.8-1.1l0.3-0.1c0.5-0.1,1.2-0.1,1.9,0%20c0.5,0,1.3,0,1.6,0c1.7-2.2,3.1-5.1,2.5-6.4c-1.8-4.5-4.9-4.2-6.9-4c-0.1,0-0.3,0-0.4,0c-0.3,0.1-0.5,0.1-0.8,0%20c-0.5,0-1-0.2-1.2-0.8l0.1-0.1l-1,0v-2c-1,0-1.1,0.5-1.1,0.8c0-0.3-0.3-1.4-1.1-2.1c-1.9-1.6-2.7-2.7-2.4-3.8%20c0.2-0.9,1-1.2,1.8-1.4c-0.8-0.7-1.3-1.3-1.3-2c0-0.6,0.2-1,0.5-1.3c-0.3-0.4-0.5-0.7-0.6-1c-0.1-0.2-0.1-0.3-0.2-0.5%20c-0.5-0.8-0.4-1.6-0.3-2.2c0-0.2,0.1-0.4,0.1-0.5c-0.6-0.7-0.9-1.3-1.3-1.9l-0.6-1l1.2-0.5c0.6-0.3,1.7-0.7,2.6,0.1%20c0.5,0.4,0.9,0.7,1.2,0.9l0.4-0.3c0.2-0.1,0.4-0.2,0.7-0.1l0-0.1l0.5-0.4c0.6-0.3,1.1-0.1,1.5,0.2c1,0.6,1.4,0.7,1.7,0.4%20c0.5-0.5,0.7-0.8,0.9-0.9l0,0c0.1-0.2,0.2-0.4,0.3-0.7l0.1-1.8l0.2-3c-0.4-0.7-1.3-2.7-1.6-5.8c-0.4-1-2-4-2.5-5.1l-0.7-1.3%20l2.6-0.3l4.2,2.3l2.5,0.5l0.2,0.5c0.9-1.7,2.2-4.5,2.8-6.9c0.7-2.9,0.4-6,0.1-7.3l-2.7-0.2l0.5-2.5l0.3-0.2%20c0.7-0.5,16.6-11,20.9-12.4c0.5-0.3,3-1.7,4.7-3.7c-1.2-1.9-2.6-4.4-2.7-4.5l-0.8-1.5l1.7,0c4.2,0.1,6,0.3,6.8,0.5%20c0.4-0.2,0.9-0.6,1.2-0.9l0.4-0.4c-0.2,0.1-0.4,0.2-0.7,0.3c-1.9,0.5-3.8-1-5.9-4.2l-0.1-0.2l0-0.3c0-0.3-0.1-0.8-0.2-1.3%20c-0.2-1.3-0.4-2.3-0.3-3.1c-1.5-0.8-2.2-1.6-2.5-2.2l-0.2-0.2c-0.2-0.2-0.4-0.6-0.2-1.2c0,0,0,0,0,0c0,0.1-0.1,0.1-0.1,0.1%20c0,0,0-0.2-0.2-0.5c-0.1-0.1-0.9-1.5-0.4-2.3l0.3-0.5l0.6,0.1c0.6,0.1,0.8,0.5,1.4,2c1.1-0.1,3-0.5,4.9-1.3%20c0.1-1.1-0.5-3.1-0.9-4.7c-0.4-1.3-0.7-2.5-0.8-3.5l-0.1-0.9l0.9-0.2c1-0.2,2.9-2.4,3.1-4.1l0-0.7l1.7-0.5%20c0.1-1.6,0.5-3.9,0.7-4.7c0-0.1,0-0.2,0-0.2l0.1-0.6l0.6-0.2l1.6-0.5l-0.3,1.4c0.1,0.1,0.2,0.3,0.5,0.5c0.1,0,1,0.2,2.3-0.3%20c1-0.3,2.7-1.2,3.5-3.2c0-0.2,0.2-0.4,0.7-1.2c0.6-0.9,1.6-2.3,2.1-3.3c-0.2-0.5-0.3-1.1-0.4-1.9c-0.1-0.6-0.3-1.7-0.5-2.1%20l-0.4,0.1l-0.4-0.6c-0.5-0.8-0.8-1.6-1-2.3c-0.4-1.1-0.4-1.1-0.7-1c-0.7,0.1-2.6,0.2-3.1-1c-0.4-1-1.5-4.7-2.4-7.9%20c-0.5-1.7-0.9-3.1-1.1-3.8c-0.3-0.4-0.5-0.8-0.7-1.1c-0.6-1-0.9-1.5-4.1-4.1c-0.4,0.1-0.8,0.4-1.4,0.9c-0.8,0.7-1.7,1.5-3.1,1.8%20c-1.4,0.2-2.5-0.6-3.2-1.3c-0.4,0.7-0.8,1.9-1.1,2.9c-0.5,1.7-1,3.4-2,4.4c0,0.3,0,0.7,0,1.3c-0.1,6.6-0.5,11-2,12.2%20c-0.2,0.1-0.4,0.2-0.6,0.3l0.1,0.1l0,2.6l-3.9,8.7l0.2-3.8c-0.7,0.4-1.1,0.9-1.2,1.3l0.6-0.2l-0.1,0.8l0.4,0.2l-0.4,0.8%20c0,0,0,0,0,0.1c0,0.1,0,0.3,0,0.4c0,0,0,0,0,0.1l-1.1-0.1c-1,0.3-2.2,0.6-3.5,1c-2.8,0.8-6.3,1.9-10.5,2.7c0,0.1,0,0.2,0,0.2l0,0%20c0,0.7-0.2,1-0.9,1.1c-0.5,0-0.8-0.2-0.9-0.5l-11.3,2.8c-0.8,0.7-4.4,4-8.7,10.7l-0.2,0.2c0,0-0.3,0.3-0.6,0.8%20c0.4,0.1,0.7,0.3,1,0.6c1.7,1.6,1.3,5.6,1.2,6.4l0,0.2l-0.1,0.2c-0.1,0.1-1.4,2-2.7,3c-1.3,1-5.4,1.9-6.2,2.1%20c-0.8,0.1-2,0.3-3.6,0.5c-3,0.4-7.5,0.9-8.7,1.4c-0.4,0.2-0.5,0.3-0.5,0.4c0,0,0,0.1,0,0.2c0,0.1,0.1,0.3,0.1,0.4%20c0.1,0.7,0.4,1.3,0.8,1.9c0.5,0.9,1,1.9,0.9,3.3l0,0.3l-0.1,0.2c-0.4,0.5-0.6,1-0.8,1.4c-0.2,0.5-0.6,1.2-1.2,1.4%20c-0.6,1.1-2,3.2-3.5,5.5c0,0,0,0,0,0h0.3l-1.3,1.6c-0.5,0.6-1,0.5-1.3,0.4c-1,0-1.8,0.1-2.1,0.1c-0.7,0.3-1.6,0.6-2.4,0.9%20c-0.5,0.1-0.9,0.3-1.2,0.4l-1.5,0.5v0.1l-0.8,0.2c-2.1,0.4-4.2,2.6-4.8,3.5l-2.2,2.5l-2.5,1c-0.3,0.3-0.8,0.4-1.2,0.6%20c-0.8,0.3-2,0.6-2.9,1.8l-0.3,0.4l-0.6-0.1c-1.3-0.2-7.7-1.7-8.9-2h-1.1l0.1-1.1c0.2-1.9,1.8-4.1,2.9-5.2%20c-0.4-0.6-0.5-1.2-0.1-2.3c0.4-1,1.3-1.2,1.8-1.4c0,0,0,0,0,0c0-0.2,0-0.3,0.1-0.5c0.2-0.4,0.5-0.7,0.9-0.9c-0.2-0.5,0-1,0.4-1.4%20l0.2-0.2l0.3,0c0.2-0.1,0.4-1,0.4-1.5c-0.2-0.5-0.1-1.5,0.1-4.7c-0.8-0.8-2.4-3-3.5-7.9l0-0.1c-0.4-0.8-1-1.9-2.5-2.1%20c-2.2,1.5-2.3,3.1-2.3,3.1l0,0.5l-0.3,0.3l-2.4,2l-0.3,0c-0.2,0-1.8,0.2-2.8-1c-0.8-1-0.8-2.7,0-4.8l0.2-0.8h0.7%20c0.5,0,0.9,0.2,1.7-3.2l0.1-0.4l0.5-0.2c0.2-0.1,0.4-0.1,0.5-0.2c-0.2-1.8-0.7-4.8-1.1-6.6c-0.6-1.5-1.4-2.6-1.7-3.1l-10.5-4%20l-0.3,0.4l-1.2,1.9c0.1,0.5,0.2,1,0.3,1.3l0.3,0.8l-0.8,0.4c-0.7,0.4-1.1,0.9-1.4,1.2c0.1,0.1,0.2,0.2,0.2,0.4%20c0.6,1.2,0.8,3.8-1.4,5.5l-0.2,0.1c-1.4,0.6-2.3,0.3-2.7-0.1c-0.4-0.3-0.6-0.7-0.7-1c-3.1,4.5-2.7,8.2-2.4,10.7%20c0.1,0.5,0.1,0.9,0.1,1.3l0,0.1l0,0.1c-0.1,1.6-0.4,2.2-0.7,2.6c0,0,0,0.1,0,0.1c0.2,0.7,0.7,2,1.3,3.3c0.8,1.9,1.8,4,2.1,5.8%20c0.9,6.1-0.1,9.9-2.7,16.2l-0.3,0.6h-0.7c-0.2,0-5.4,0.3-8.5-0.4l-0.8-0.2v-0.4c-2.2-1.7-3.3-4.9-3.1-9.9h0l-0.2-0.9l0.4-0.2%20c-0.7-2.8-1.3-6-0.8-11.6l0.8-6.6c0,0,0.3-2.3,1.6-7.5c-0.2,0-0.4,0-0.6,0c-0.5,0.7-0.9,1.3-1.2,1.8c-0.5,0.9-1.1,1.9-2.3,1.6%20c-0.7-0.1-1.2-0.4-1.5-1c-0.4-1,0.2-1.9,1-3.2c0.7-1.1,1.6-2.5,1.6-3.7c0,0,0,0,0,0c0,0,0,0,0,0c0-0.1,0-0.1,0-0.2l0.4,0l0.4-0.4%20l-0.3-0.7c0.4-0.3,1.4-2.1,2-3.4c0.6-1.3,1.3-2.6,1.9-3.5l0.4-0.6l0.7,0.1c0.5,0.1,0.6,0.1,0.6,0.1h0c0,0,0.1-0.1,0.1-0.2%20c0.3-0.4,0.8-1,2-1.5l1.7-0.7l-0.2,1.1c1.1-1.6,3.7-2.2,5.3-2.6c0.3-0.1,0.5-0.1,0.7-0.2c0.1-0.1,0.2,0,0.3-0.2%20c0.3-0.4,0.8-0.9,2-0.9c0,0,0,0,0,0c2.8,0,3.9,0.3,5.2,1.2c0.1-0.2,0.2-0.4,0.3-0.6c0.1-0.1,0.1-0.2,0.2-0.3l0.3-0.4l0.5-0.1%20c1.1-0.1,2.3-0.2,3.4-0.2c-0.1-0.1-0.1-0.1-0.2-0.2c-1.2-1.5-1.9-2.5-2.4-3.3c-1.7,0.6-3,0.7-4,0.2c-1.1-0.5-1.6-1.5-1.9-2.4%20c-1.1,0.4-2.4,0.6-3.9,0.8c-0.6,0.1-1.2,0.2-1.9,0.3c-0.2,0.1-0.7,0.4-1.1,0.6c-2.2,1.3-5.7,3.5-8.1,2.3c-0.9,0.1-1.9,0.3-1.9,0.3%20l-0.5,0.1l-0.4-0.4c-4.5-4.6-6.5-4-8.8-3.2l-1.1,0.3l-0.3-1c-0.3-1.1-0.5-1.9,0-2.5c0.2-0.2,0.4-0.3,0.6-0.4l0.9-1.4%20c0.5-0.9,1-1.4,1.4-1.8c-1.3,0.7-2.7,2-2.8,2.5l-0.1,0.3l-0.2,0.2c-2,2.2-7.7,5.6-10.6,6.2c-0.8,2.2-3.9,2.7-4.6,2.7h-0.2%20l-0.2-0.1c-0.8-0.3-1.7-0.5-3.1-0.8l-0.5-0.1l-0.2-0.5c-0.4-1-0.2-1.8,0.1-2.2c-0.6,0.2-1.4,0.5-2.2,0.9c-2.2,1-4.9,2.2-7.3,1.9%20l-0.5,0.5l-1.5-1.3c0.8-1.1,11.6-12.7,12.7-13.3c0,0,7.2-4.4,10.1-3c3.3,0.3,5.4-0.1,6.1-1.3c0.4-0.6,0.3-1.3,0.1-1.7%20c-1.1,0.2-4,1-6.5,1.8l-0.3,0.1l-5.5,0.3c-1.2,0.2-2.4,0.3-3.4,0.4c-2.8,0.3-4.7,0.5-7,1.6l-0.5,0.2l-0.5-0.3c0,0-4.6-3-8.4-3%20c-0.5,0-0.9-0.2-1.1-0.7c-0.1-0.2-0.4-0.7,0.3-1.9c-1,0-2.9,0.1-6.4,0.6c-0.8,0.2-2.2-0.2-4.1-0.6c-0.3-0.1-0.5-0.1-0.7-0.2%20c-0.3-0.1-0.6-0.1-0.9-0.2c-0.9-0.1-2.2-0.3-3.7-1.6c-1.1-1-1.8-2.9-1.9-3.7c-0.2-0.8-1.1-2-1.6-2.3c-0.5,0.1-1,0.2-1.2,0.3%20c0,0.1,0,0.2,0,0.5v2.8h-1c-10.9,0-13.2,0.1-15.2,0.5l-0.1,0.1l-0.1,0l-54.3-1.4c-16.4-1.5-33.6-3.1-47.8-5.1%20c-19-2.7-34.7-5.3-42.2-6.6c-2.5-0.4-4.5-0.8-4.8-0.8l-0.2,0c-0.1,0-5.4-1.6-8.2-1.8l0.1-0.6l-0.1,0.6c-1.6-0.4-35.1-8-43.1-10.3%20c0.1,0.4,0.3,0.8,0.5,1.2c0.5,1.1,1.1,2.2,0.7,3.2l-0.1,0.3c-0.1,0.6,0.1,2.6,0.3,3.8c0.2,1.7,0.3,2.5,0.1,3.1l-0.2,4.6l-0.9,0.1%20c-1.1,0.1-1.4,0.9-1.8,2.7c-0.1,0.7-0.3,1.3-0.6,1.8c-0.2,0.4-0.6,0.6-1,0.6c-0.8,0-1.3-0.8-1.8-1.7c-1.2-2.4-2.7-7.6-1.3-10.6%20c-3.7-4.6-8.6-9.1-10.3-8.6c-0.4,0.1-0.7,0.9-0.8,2c-0.2,2.7,0.2,6.6,0.5,9.7c0.5,4.7,0.5,5.7-0.2,6.2c-0.2,0.1-0.4,0.2-0.5,0.2%20c-0.1,0.1-0.2,0.2-0.2,0.2c-0.2,1.6-0.2,1.6,0.4,3.1l0,0.1c0.2,0.6-0.2,1-0.7,1.5c-0.5,0.5-1.3,1.4-1.3,2.1c0,0.2,0,0.3,0,0.4%20L61,246l-0.9,3.3l0.5,0.4l-0.2,0.7c-3.4,9.5-8.2,21.3-11.6,29.6l-0.1,0.3l-0.2,0.2c-2.4,1.7-4.2,5.3-4.5,9.1%20c-0.1,0.9-0.2,1.7-0.3,2.4c-0.2,1.7-0.4,2.9,0,3.5l-1,0.6l1.3,0.1c-0.2,4.3-2.2,11-4,14.2l-0.1,0.2l-0.2,0.1%20c-1.2,0.7-1.9,1.6-2.1,2.7c-0.5,2.7,2.1,5.8,2.1,5.8l0.3,0.3l0,0.4c-0.1,1-0.1,1.9-0.2,2.8c-0.1,2-0.3,4.1-0.7,6.8%20c-0.7,5.6,1.2,7,2.3,7.7c0.1,0.1,0.3,0.2,0.4,0.3l0.3,0.2l0.1,0.4c0.1,0.8,0.4,1.6,0.5,2.2c0.4,1.3,0.8,2.5,0.2,3.7%20c0.3,0.4,0.7,0.7,1,1.1c0.4,0.4,0.8,0.7,1.1,1.2l0.2,0.2l0.1,0.8l-0.2,0.2c0,0.3,0,0.6-0.1,1.1l1.2-0.2l-0.6,1.6%20c-0.4,1.2-0.7,4.7-0.4,5.4c0.4,1.4,1.1,2,2,2.5c1.1,0.8,2.5,1.7,1.9,4.2l-0.1,0.5l-0.4,0.2c-1.6,0.8-1.8,2.3-1.6,4.5%20c0.9,1.2,2.1,3.7,3.3,6.5c1.4,3,2.9,6.5,4.4,8.5l0.3,0.4l-0.2,0.5c-1.1,2.8-1.3,5.3-0.3,6.6c0.7,1,2.1,1.5,4.1,1.5%20c2.3,0,4.7,2.6,4.9,2.9l1.6,1.8c1.5,1.4,3.8,3.3,4.9,3.6c0.2,0.1,0.3,0.1,0.4,0.1c0.4-0.2,0.9-0.1,1.3-0.1l1,0.2l-0.2,1%20c-0.1,0.7-0.1,2,0.2,2.7c2.7,1.1,4.7,2.7,6.2,5.1c1.1,1.7,2.8,8.1,3,11.1c4.1,0.2,10.1,0.8,16,1.5l6.9,0.8l0.1,0.8%20c0.1,0.6,0.1,1,0.1,1.5c0,0.3,0,0.5,0,0.9c6.5,3.2,10.1,5.3,15.5,8.4c1,0.5,2,1.2,3.2,1.9c2.9,1.8,6.6,4,11.2,6.2l0.9,0.5%20c3.9,2,8.7,4.5,13.8,4.2l0.1,0l9.9,2.1c1.6,0.8,4.8,0.4,7-0.5l1.1-4.7l0.8,0c6.7,0.2,11.6,0.7,14.7,1.1l0-0.2l1,0.2%20c0.7,0,1.3,0.1,1.9,0.3l0.2,0.1l0.2,0.2c0.8,0.8,1.9,2.1,3.1,3.6c2.7,3.4,6.5,8,10.5,10.2l0.4,0.2l0.1,0.4%20c0.8,2.6,1.4,3.6,1.8,4.2c0.7,1.1,0.8,1.6,0.6,4.1c0.1,0.2,0.2,0.4,0.2,0.7c1,2.9,2.5,6.9,13.7,11.3c0.8,0.3,2.6-3,3.4-4.4%20c1.2-2.3,2-3.8,3.2-3.9l0.4,0l0.3,0.2c1.7,1.1,3.1,0.8,5.1,0.4c1.7-0.4,3.8-0.8,6.4-0.3l0.4,0.1l0.2,0.4c1.6,2.4,2.6,3.3,3.7,4.4%20c0.9,0.9,1.9,1.8,3.2,3.6c0.6,1,1.2,2.3,1.9,3.7c1.4,2.9,3.2,6.6,4.8,7.9l0.2,0.2l1.1,3c0.8,0.8,3.2,3.1,3.7,4.1%20c1.7,2.9,1.7,3.8,1.5,4.9c0,0.2-0.1,0.4-0.1,0.7c0,0,0,0.1,0.1,0.1c0.3,0.6,1,2,3,6.9c1,0.7,2.6,1.4,4.2,2.2%20c2.5,1.2,4.2,2,5.1,2.8c0.4,0.1,1,0,1.6,0c2.1,0,5-0.1,6.4,2.2c0,0.1,0.1,0.1,0.1,0.1l-0.5,0.3C276.2,519,276.3,519.2,276.3,519.3%20z%20M358.2,474.6c0.2,0.1,0.5,0.3,0.8,0.5c3.2,2.7,4.1,2.5,4.1,2.5c0-0.1,0-0.5,0-0.6c0,0,0-0.1,0-0.1c-0.7-0.5-2.8-1.5-4.7-2.3%20C358.4,474.6,358.3,474.6,358.2,474.6z%20M353.7,467.1c0.3,0.5,0.6,0.8,0.8,0.8c0.1,0,0.1,0,0.1,0l0.2-0.1l0.2,0%20c0.2,0,0.5-0.1,0.8-0.2c0.1-0.1,0.3-0.1,0.5-0.2c-0.1-0.2-0.3-0.3-0.4-0.5c-0.1-0.2-0.3-0.4-0.4-0.5c-0.4-0.2-0.8-0.3-1-0.3%20c-0.1,0.1-0.1,0.2-0.2,0.3C354,466.6,353.9,466.9,353.7,467.1z%20M365.3,327.2c2.3,0.4,5.4,0.3,6.7,0.3c2.3-5.7,3.1-9.1,2.3-14.5%20c-0.3-1.5-1.2-3.5-2-5.3c-0.7-1.5-1.2-2.8-1.5-3.7c-0.1-0.8,0-1.2,0.3-1.7c0.1-0.1,0.2-0.3,0.3-1.5c0-0.3-0.1-0.7-0.1-1.1%20c-0.3-2.7-0.8-7.1,3-12.4l0.2-0.2l3.3-2.5l-0.3,2.4c-0.1,0.5,0,1.2,0.2,1.3c0,0,0.2,0.1,0.6-0.1c0.7-0.6,0.9-1.3,1-1.7%20c0-0.4,0-0.7-0.1-1l-1.3,0.4l0.5-1.8c0-0.1,0.4-1.5,2-2.7c-0.1-0.6-0.2-1.1-0.3-1.2l-0.1-0.4l2-3.2l-0.1-0.1%20c-1.3-1-1.9-1.4-4.4-1.4c-0.3,0-0.3,0-0.5,0.3c-0.2,0.2-0.4,0.6-0.9,0.9l-0.2,0.1c-0.3,0.1-0.6,0.2-1.1,0.3%20c-1.2,0.3-3.6,0.8-4.2,1.8c0.1,1.4-0.8,2.6-1.9,3.2c-0.3,0.2-0.6,0.3-0.9,0.3l-0.1,0.2l-0.9-0.3l-0.9-0.4l0.4-0.9%20c0,0,0-0.1,0.1-0.1c-0.3,0.2-0.7,0.2-1.3,0.2c-0.5,0.8-1,1.8-1.5,2.8c-0.9,1.8-1.6,3.2-2.3,3.9c0,0.9-0.3,1.7-0.6,2.5l0.3-0.1%20c0.2,0,1.8-0.3,3,0.5l0.6,0.4l-0.2,0.7c-1.4,5.7-1.7,8.1-1.7,8.1l-0.8,6.5c-0.5,5.9,0.2,8.9,1,11.8l0.3,1l-0.7,0.2%20c-0.1,4.2,0.8,7.1,2.6,8.1L365.3,327.2z%20M517,298.6l0.6,1.2c0.1,0.2,0.3,0.4,0.4,0.4c0.1,0,0.4-0.1,0.8-0.5l0.6-0.6l0.5,0.3%20c-0.1-0.2-0.3-0.4-0.4-0.6c-0.6-0.9-1-1.4-1.5-1.6C517.7,297.8,517.4,298.2,517,298.6z%20M356.1,260.5c-0.2,0-0.8,0.3-1.1,0.5%20c-0.1,0.1-0.2,0.1-0.3,0.1c0,0,0.1,0,0.1,0c0.1,0,0.3,0,0.4,0C355.9,261,356.1,261,356.1,260.5%20C356.2,260.5,356.2,260.5,356.1,260.5C356.2,260.5,356.1,260.5,356.1,260.5z'/%3e%3c/g%3e%3c/g%3e%3cg%20id='specctr'%3e%3cg%20id='Dimensions'%3e%3c/g%3e%3c/g%3e%3c/svg%3e",a1={area:t1,arearange:t1,line:n1,bar:gA,column:bA,polar:CA,funnel:_A,pie:wA,scatter:xA,indicator:r1,table:SA,treemap:MA,areamap:i1,scattermap:i1,boxplot:vA,sunburst:TA,"calendar-heatmap":yA,sankey:n1,kpi:r1};function PA(e){var r;return(r=a1[e])!=null?r:a1["bar"]}const EA="_wrapper_1lpzp_1",AA="_title_1lpzp_7",RA="_image_1lpzp_17",_h={wrapper:EA,title:AA,image:RA},Ac=({iconType:e})=>{var s,u;const{themeSettings:t}=y.useThemeContext(),r=N.useRef(null),[n,i]=N.useState({width:null,height:null});N.useEffect(()=>{r.current&&i({width:r.current.offsetWidth,height:r.current.offsetHeight})},[]);const a=PA(e),{t:o}=O.useTranslation();return O.jsxs("div",{ref:r,className:_h.wrapper,children:[O.jsx("div",{className:_h.title,style:{fontFamily:(s=t.typography)==null?void 0:s.fontFamily,fontSize:DA(n.width,n.height),color:(u=t.typography)==null?void 0:u.secondaryTextColor},children:o("chartNoData")}),a?O.jsx("img",{className:_h.image,src:a,alt:o("chartNoData")}):null]})};function DA(e,t){return!e||!t?"18px":e<300?`${Math.max(Math.sqrt(e*e+t*t)*.045,18)}px`:`${Math.min(Math.max(t*.09,18),60)}px`}function X_(e,t,r,n){if(!V.isObject(e))return e;t=V.castPath(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i<a;){var u=V.toKey(t[i]),c=r;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(i!=o){var d=s[u];c=void 0,c===void 0&&(c=V.isObject(d)?d:V.isIndex(t[i+1])?[]:{})}V.assignValue(s,u,c),s=s[u]}return e}function Z_(e,t,r){for(var n=-1,i=t.length,a={};++n<i;){var o=t[n],s=V.baseGet(e,o);r(s,o)&&X_(a,V.castPath(o,e),s)}return a}function NA(e,t){return Z_(e,t,function(r,n){return V.hasIn(e,n)})}var kA=V.flatRest(function(e,t){return e==null?{}:NA(e,t)});const LA={translateDataOptionsToInternal:function(e){return{geo:e.geo&&E.normalizeColumn(e.geo[0]),color:e.color&&E.normalizeMeasureColumn(e.color[0])}},getAttributes:function(e){return[e.geo.column].filter(t=>!E.isMeasureColumn(t))},getMeasures:function(e){var r;const t=(r=e.color)==null?void 0:r.column;return t&&E.isMeasureColumn(t)?[t]:[]},isCorrectDataOptions:function(e){return"geo"in e&&V.isArray(e.geo)},isCorrectDataOptionsInternal:function(e){return"geo"in e&&!!e.geo.column}},OA={errors:{invalidAttribute:"Invalid attribute {{attributeName}}. Hint: attributes for query should be extracted from the data model generated by the CLI tool.",noDimensionsOrMeasures:"Neither dimensions nor measures found. Query should have at least one dimension or measure.",invalidMeasure:'Invalid measure "{{measureName}}". Hint: measures for the query can be constructed using the "measureFactory" functions.',invalidFilter:'Invalid filter "{{filterName}}". Hint: filters for the query can be constructed using the "filterFactory" functions.',invalidHighlight:'Invalid highlight "{{highlightName}}". Hint: highlights for the query can be constructed using the "filterFactory" functions.',invalidCountNegative:'Invalid count "{{count}}" in query. Count should be non-negative.',invalidOffset:'Invalid offset "{{offset}}" in query. Offset should be non-negative.',missingHttpClient:"Query was unable to load httpClient.",missingPostMethod:'httpClient must provide "post" method.',noJaqlResponse:"No jaql response received from the server",invalidCountRowsResponse:"Invalid row count response received from the server.",dataSourceNotFound:'Failed to get fields for data source "{{dataSource}}". Please make sure the data source exists and is accessible.',calculatedDimensionParseNotSupported:"The connected data source does not support resolving calculated dimension formulas.",calculatedDimensionFormulaInvalid:"Invalid calculated dimension formula. {{message}}"}},IA={errors:{invalidAttribute:"Недійсний атрибут {{attributeName}}. Підказка: атрибути для запиту повинні бути витягнуті з моделі даних, створеної за допомогою CLI-інструменту.",noDimensionsOrMeasures:"Не знайдено ні вимірів, ні показників. Запит повинен мати щонайменше один вимір або показник.",invalidMeasure:'Недійсний показник "{{measureName}}". Підказка: показники для запиту можна створити за допомогою функцій "measureFactory".',invalidFilter:'Недійсний фільтр "{{filterName}}". Підказка: фільтри для запиту можна створити за допомогою функцій "filterFactory".',invalidHighlight:'Недійсне виділення "{{highlightName}}". Підказка: виділення для запиту можна створити за допомогою функцій "filterFactory".',invalidCountNegative:`Недійсний count "{{count}}". Count повинен бути не від'ємним.`,invalidOffset:`Недійсний offset "{{offset}}". Offset повинен бути не від'ємним.`,missingHttpClient:"Для запиту потрібен httpClient, щоб працювати належним чином.",missingPostMethod:'httpClient повинен мати метод "post".',noJaqlResponse:"Відповіді, що містить jaql, від сервера не отримано",invalidCountRowsResponse:"Від сервера отримано недійсну відповідь із кількістю рядків.",dataSourceNotFound:'Не вдалося отримати поля для джерела даних "{{dataSource}}". Переконайтесь що джерело існує і доступне.',calculatedDimensionParseNotSupported:"Підключене джерело даних не підтримує визначення типу даних формул обчислюваних вимірів.",calculatedDimensionFormulaInvalid:"Недійсна формула обчислюваного виміру. {{message}}"}},K_="sdkQueryClient",FA={en:OA,uk:IA};function $A(){return V.initI18next({resource:FA,language:"en",namespace:K_})}const{i18nextInstance:BA}=$A();var Km={exports:{}},ka=typeof Reflect=="object"?Reflect:null,o1=ka&&typeof ka.apply=="function"?ka.apply:function(t,r,n){return Function.prototype.apply.call(t,r,n)},Eu;ka&&typeof ka.ownKeys=="function"?Eu=ka.ownKeys:Object.getOwnPropertySymbols?Eu=function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Eu=function(t){return Object.getOwnPropertyNames(t)};function zA(e){console&&console.warn&&console.warn(e)}var Q_=Number.isNaN||function(t){return t!==t};function Je(){Je.init.call(this)}Km.exports=Je;Km.exports.once=VA;Je.EventEmitter=Je;Je.prototype._events=void 0;Je.prototype._eventsCount=0;Je.prototype._maxListeners=void 0;var s1=10;function Rc(e){if(typeof e!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}Object.defineProperty(Je,"defaultMaxListeners",{enumerable:!0,get:function(){return s1},set:function(e){if(typeof e!="number"||e<0||Q_(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");s1=e}});Je.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};Je.prototype.setMaxListeners=function(t){if(typeof t!="number"||t<0||Q_(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this};function J_(e){return e._maxListeners===void 0?Je.defaultMaxListeners:e._maxListeners}Je.prototype.getMaxListeners=function(){return J_(this)};Je.prototype.emit=function(t){for(var r=[],n=1;n<arguments.length;n++)r.push(arguments[n]);var i=t==="error",a=this._events;if(a!==void 0)i=i&&a.error===void 0;else if(!i)return!1;if(i){var o;if(r.length>0&&(o=r[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var u=a[t];if(u===void 0)return!1;if(typeof u=="function")o1(u,this,r);else for(var c=u.length,d=iw(u,c),n=0;n<c;++n)o1(d[n],this,r);return!0};function ew(e,t,r,n){var i,a,o;if(Rc(r),a=e._events,a===void 0?(a=e._events=Object.create(null),e._eventsCount=0):(a.newListener!==void 0&&(e.emit("newListener",t,r.listener?r.listener:r),a=e._events),o=a[t]),o===void 0)o=a[t]=r,++e._eventsCount;else if(typeof o=="function"?o=a[t]=n?[r,o]:[o,r]:n?o.unshift(r):o.push(r),i=J_(e),i>0&&o.length>i&&!o.warned){o.warned=!0;var s=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");s.name="MaxListenersExceededWarning",s.emitter=e,s.type=t,s.count=o.length,zA(s)}return e}Je.prototype.addListener=function(t,r){return ew(this,t,r,!1)};Je.prototype.on=Je.prototype.addListener;Je.prototype.prependListener=function(t,r){return ew(this,t,r,!0)};function HA(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function tw(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=HA.bind(n);return i.listener=r,n.wrapFn=i,i}Je.prototype.once=function(t,r){return Rc(r),this.on(t,tw(this,t,r)),this};Je.prototype.prependOnceListener=function(t,r){return Rc(r),this.prependListener(t,tw(this,t,r)),this};Je.prototype.removeListener=function(t,r){var n,i,a,o,s;if(Rc(r),i=this._events,i===void 0)return this;if(n=i[t],n===void 0)return this;if(n===r||n.listener===r)--this._eventsCount===0?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit("removeListener",t,n.listener||r));else if(typeof n!="function"){for(a=-1,o=n.length-1;o>=0;o--)if(n[o]===r||n[o].listener===r){s=n[o].listener,a=o;break}if(a<0)return this;a===0?n.shift():WA(n,a),n.length===1&&(i[t]=n[0]),i.removeListener!==void 0&&this.emit("removeListener",t,s||r)}return this};Je.prototype.off=Je.prototype.removeListener;Je.prototype.removeAllListeners=function(t){var r,n,i;if(n=this._events,n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[t]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[t]),this;if(arguments.length===0){var a=Object.keys(n),o;for(i=0;i<a.length;++i)o=a[i],o!=="removeListener"&&this.removeAllListeners(o);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(r=n[t],typeof r=="function")this.removeListener(t,r);else if(r!==void 0)for(i=r.length-1;i>=0;i--)this.removeListener(t,r[i]);return this};function rw(e,t,r){var n=e._events;if(n===void 0)return[];var i=n[t];return i===void 0?[]:typeof i=="function"?r?[i.listener||i]:[i]:r?jA(i):iw(i,i.length)}Je.prototype.listeners=function(t){return rw(this,t,!0)};Je.prototype.rawListeners=function(t){return rw(this,t,!1)};Je.listenerCount=function(e,t){return typeof e.listenerCount=="function"?e.listenerCount(t):nw.call(e,t)};Je.prototype.listenerCount=nw;function nw(e){var t=this._events;if(t!==void 0){var r=t[e];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}Je.prototype.eventNames=function(){return this._eventsCount>0?Eu(this._events):[]};function iw(e,t){for(var r=new Array(t),n=0;n<t;++n)r[n]=e[n];return r}function WA(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function jA(e){for(var t=new Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}function VA(e,t){return new Promise(function(r,n){function i(o){e.removeListener(t,a),n(o)}function a(){typeof e.removeListener=="function"&&e.removeListener("error",i),r([].slice.call(arguments))}aw(e,t,a,{once:!0}),t!=="error"&&UA(e,i,{once:!0})})}function UA(e,t,r){typeof e.on=="function"&&aw(e,"error",t,r)}function aw(e,t,r,n){if(typeof e.on=="function")n.once?e.once(t,r):e.on(t,r);else if(typeof e.addEventListener=="function")e.addEventListener(t,function i(a){n.once&&e.removeEventListener(t,i),r(a)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}var GA=Km.exports;const Qm=O.getDefaultExportFromCjs(GA),De={HEADERS:"headers",METADATA:"metadata",DATA:"data",GRAND:"grand",FINISH:"finish",ERROR:"error",TOTAL_ROWS:"totalRows",DATA_FINISH:"dataFinish",DATABARS:"dataBars",RANGE_MIN_MAX:"rangeMinMax"},qA=[De.ERROR,De.HEADERS,De.GRAND,De.METADATA,De.DATA,De.DATA_FINISH,De.TOTAL_ROWS,De.DATABARS,De.RANGE_MIN_MAX,De.FINISH];class ql extends Error{constructor(t="Loading canceled"){super(t),this.name="LoadingCanceledError";const r=new.target.prototype;Object.setPrototypeOf&&Object.setPrototypeOf(this,r)}}class YA{constructor(t,r,n,i){this.childColCells=[],this.childRowCells=[],this.indexInParent=-1,this.siblingCount=0,this.rowIndex=t,this.colIndex=r,this.node=n,this.parent=i}isChild(){return!this.node}hasChildren(){return!!(this.childColCells.length||this.childRowCells.length)}hasColCell(){return this.childColCells.length>0}addColCell(t){this.childColCells.push(t)}getColCell(){return this.childColCells||[]}hasRowCell(){return this.childRowCells.length>0}addRowCell(t){this.childRowCells.push(t)}getRowCell(){return this.childRowCells||[]}getStopRowIndex(){return this.hasRowCell()?this.rowIndex+this.getRowCell().length:this.rowIndex}getStopColIndex(){return this.hasColCell()?this.colIndex+this.getColCell().length:this.colIndex}setIndexInParent(t,r){this.indexInParent=t,this.siblingCount=r}getIndexInParent(){return{indexInParent:this.indexInParent,siblingCount:this.siblingCount}}getParenPosition(){if(!this.parent)return;const t=(this.parent||"").match(/\d+/g)||[];return[Number(t[0]),Number(t[1])]}}const rn={FIRST:"first",LAST:"last",EVEN:"even",ODD:"odd"};var XA=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r};const ow=[Date,Error,RegExp,Promise];function sw(e,t=ow){return t.some(r=>e instanceof r)}function l1(e,t=[]){let r=!1;return t.forEach(n=>{e.includes(n)&&(r=!0)}),r}function lw(e=[],t,r){const n=[];return r&&e.forEach(i=>{n.push(`${i}.$`)}),e.length?e.forEach(i=>{n.push(`${i}.${t}`)}):n.push(t),n}function ls(e){return!(e===null||typeof e=="undefined"||typeof e!="object")}function ZA(e,t){return ls(e)&&e?Array.isArray(e)?!e.length:sw(e,t)?!1:!Object.keys(e).length:e==null}function KA(e=""){const t=e.split(".");return t.length>1?(t.pop(),t.join(".")):t[0]}function u1(e,t,r){return e.length?l1(e,r):t.length?!l1(t,r):!0}function uw(e,t=[],r=[],n=[],i={},a={},o=[],s=[]){if(!ls(e))return{commonIncludeKeys:[],commonExcludeKeys:[]};const u=o.indexOf(e);if(u!==-1)return s[u];o.push(e);const c=Object.keys(e),d=Array.isArray(e);let h=[],p=[];const m=[],g=[];if(c.forEach(b=>{const _=e[b],w=lw(n,b,d),C=n[0]||"&";i[C]=i[C]||[],a[C]=a[C]||[],w.forEach(S=>{(t||[]).includes(S)&&(i[C].push(S),h.push(S)),(t||[]).forEach(T=>{const M=KA(T);(`${M}.$`===C||M===C)&&(i[C].includes(T)||i[C].push(T),h.includes(T)||h.push(T))}),(r||[]).includes(S)&&(a[C].push(S),p.push(S))}),ls(_)&&uw(_,t,r,w,i,a,o,s)}),ls(e)){let b=n[0]||"&";Array.isArray(e)&&(b=`${b}.$`),i[b]=(i[b]||[]).concat(m),h=h.concat(m),a[b]=(a[b]||[]).concat(g),p=h.concat(g)}return s.push({commonIncludeKeys:h,commonExcludeKeys:p}),{commonIncludeKeys:h,commonExcludeKeys:p}}function cw(e,t,r=new WeakMap){const{includeKeys:n,includeKeysObj:i,excludeKeys:a,excludeKeysObj:o,parentKeys:s=[],excludeEmpty:u,referenceClone:c}=t||{};if(!ls(e)||sw(e,c))return e;if(r.has(e))return r.get(e);const d=Object.keys(e),h=Array.isArray(e),p=h?[]:{};r.set(e,p);const m=s[0]||"&",g=(i||{})[m]||[],b=(o||{})[m]||[];return d.forEach(_=>{const w=e[_];let C=[],S=!0;if(n||a?S=u1(n||[],a||[],[_]):(i||o)&&(C=lw(s,_,h),S=u1(g,b,C)),S){const T=cw(w,Object.assign(Object.assign({},t),{parentKeys:C}),r);(!u||!ZA(T,c))&&(h?p.push(T):p[_]=T)}}),p}function pr(e,t){const r=t||{},{include:n,exclude:i}=r,a=XA(r,["include","exclude"]);let o,s;(n||i)&&(o={},s={},uw(e,n,i,[],o,s));const u=Object.assign(Object.assign({},a),{includeKeysObj:o,excludeKeysObj:s});return cw(e,u)}pr.REFERENCE_CLONE_TYPES=ow;function c1(e,t,r=0){for(let n=r;n<e.length;n+=1){const i=e[n];if(!!t(i,n,e))return n}return-1}const QA=(e,t)=>{let r,n,i=null;const a=(...o)=>{r?i=o:(e(...o),r=!0,i=null,n=setTimeout(()=>{r=!1,i&&(e(...i),i=null)},t))};return a.cancel=()=>{clearTimeout(n),r=!1},a},_s="$*$root$*$";function JA(e,t,r,n){const i={value:e};return t&&(i.children=t),r&&(i.data=r),typeof n!="undefined"&&(i.index=n),i}function Dc(e){return!!(e&&e.children&&e.children.length)}function Ur(e){return e&&e.children||[]}function Df(e,t){e&&t&&Array.isArray(t)&&(e.children=t)}function e5(e,t){e&&(e.level=t)}function t5(e){return e&&typeof e.level!="undefined"?e.level||0:-1}function va(e){if(!e)return;if(e&&!Array.isArray(e)&&e.value===_s)return e;const t={value:_s,children:[]};return Array.isArray(e)?t.children=e:(t.children||[])[0]=e,t}function dw(e,t,r=0){let n;if(!e||!t)return n;if(t(e,r)&&(n=e),Dc(e)){const i=Ur(e),a=i.length;for(let o=0;o<a;o+=1){const s=dw(i[o],t,r+1);if(s){n=s;break}}}return n}function r5(e,t){if(!e&&!t)return;if(!e&&t)return va(t);if(e&&!t)return va(e);const r=va(e),n=va(t),i=r&&r.children||[],a=n&&n.children||[],o=i.concat(a);return va(o)}const hw=(e,t=0)=>{if(!e||!e.isPart)return;e.level=t;const r=Ur(e),n=r[r.length-1];return n&&hw(n,t+1)||e},fw=(e,t,r=0)=>{if(!e||!e.isPart)return;if(e.level=r,e&&t&&e.value===t.value&&e.level===t.level)return e;const i=Ur(e)[0];return i&&fw(i,t,r+1)||e};function n5(e,t){let r=hw(e),n=fw(t,r);r&&r.children&&Array.isArray(r.children)&&n&&n.children&&Array.isArray(n.children)&&n.children.length>0&&(r.children=r.children.concat(n.children),n.isHandled=!0);let i=!1;for(r=e,n=t;r&&r.children&&Array.isArray(r.children)&&n&&n.children&&Array.isArray(n.children)&&!n.isHandled;){const a=r.children;r=r.children[r.children.length-1];let o=0;for(n.children[0]&&!i&&(i=!Ur(n.children[0]).some(s=>s.isPart),o=1);o<n.children.length;)a.push(n.children[o]),o+=1;n=n.children[0]}return e}function pw(e,t,r){!e||!t||e.forEach(n=>{t(n,r),Dc(n)&&pw(Ur(n),t,n)})}function mw(e,t=[],r=0,n={maxLevel:0}){return e.forEach(i=>{n.maxLevel<r&&(n.maxLevel=r),Dc(i)?mw(Ur(i),t,r+1,n):t.push(i)}),t}function Nc(e,t={}){if(t||(t={}),typeof t.callCount!="number"?t.callCount=1:t.callCount+=1,!e)return 0;let r=t.clearCache||!1;!Array.isArray(e)&&e.value===_s&&(r=!0);let n=1,i=[];return Array.isArray(e)?(n=0,i=e):e.children&&(i=Ur(e)),i&&i.length&&(!r&&!Array.isArray(e)&&typeof e.childCount=="number"?n=e.childCount:(n=0,i.forEach(a=>{n+=Nc(a,t)}),Array.isArray(e)||(e.childCount=n))),n}function gw(e,t={}){if(t||(t={}),typeof t.callCount!="number"?t.callCount=1:t.callCount+=1,!e)return 0;let r=t.clearCache||!1;!Array.isArray(e)&&e.value===_s&&(r=!0);let n=0,i=[];if(e&&!Array.isArray(e)&&typeof e.value!="undefined"&&(n=1),Array.isArray(e)?(n=0,i=e):e.children&&(i=Ur(e)),i&&i.length)if(!r&&!Array.isArray(e)&&typeof e.childDeep=="number")n+=e.childDeep;else{let a=0;i.forEach(o=>{const s=gw(o,t);s>a&&(a=s)}),n+=a,Array.isArray(e)||(e.childDeep=a)}return n}function vw(e=[],t=0,r){const n=[];let i=0,a=-1,o=-1;const s=e.length;if(typeof t=="number"&&typeof r=="number"&&t>r)throw new Error('Wrong "getNodesByChildCount" diapason');if(typeof t=="number"&&t<0)throw new Error('Wrong "from" index for "getNodesByChildCount"');for(let u=0;u<s;u+=1){const c=e[u],d=Nc(c);if(i+d>t&&(a<0&&(a=i),n.push(c),typeof r=="number"&&i+d>=r)){o=i+d;break}o=i+d,i+=d}return{nodes:n,start:a,stop:o}}function i5(e){e.isMapped!==void 0&&(e.isMapped=void 0),e.minLevel!==void 0&&(e.minLevel=void 0),e.childCount!==void 0&&(e.childCount=void 0),e.childDeep!==void 0&&(e.childDeep=void 0)}function Nf(e=[],t=0,r,n){const{cloneFn:i=pr}=n||{},a=[],{nodes:o,start:s,stop:u}=vw(e,t,r),c=o.length;let d,h,p=!0;if(s<t){const m=o[0]||{},g=t-s;let b;c===1&&typeof r=="number"&&(b=r-s,p=!1),d=i(m,!0);const _=Nf(Ur(m),g,b,n);Df(d,_)}if(typeof r=="number"&&u>r&&p){const m=o[c-1]||{},g=0,b=Nc(m)-(u-r);h=i(m,!0);const _=Nf(Ur(m),g,b,n);Df(h,_)}return o.forEach((m,g)=>{if(d&&g===0)a.push(d);else if(h&&g===c-1)a.push(h);else{const b=i(m);a.push(b)}}),a}const ve={ROOT:_s,create:JA,hasChildren:Dc,getChildren:Ur,setChildren:Df,setLevel:e5,getLevel:t5,getLastLevelNodes:mw,iterateThroughTree:pw,wrapInRootNode:va,findNode:dw,merge:r5,deepMerge:n5,getChildLength:Nc,getDeepLength:gw,getNodesByChildCount:vw,getCutNodesByChildCount:Nf,clearNodeCache:i5},sa=(e,t)=>`${e}-${t}`;class a5{constructor(t,r=!1,n){this.hasGrandTotals=!1,this.isVertical=!1,this.columns=[],this.lastLevel=[],this.map={},this.metadataCache={},this.isVertical=r,this.deep=n,t&&(this.tree=t,this.columns=this.cacheLevels(ve.getChildren(this.tree)))}destroy(){this.tree=void 0,this.columns=[],this.lastLevel=[],this.map={},this.metadataCache={},this.valueNode=void 0,this.grid=void 0}getMainCellWidth(t,r,n,i,a={offsetTop:-1,columnsOffset:0}){const{columnsOffset:o=0}=a,s=this.getItem(t,r),u=s&&s.hasChildren()&&s.hasColCell();let c=Number.NaN,d=!0;if(s&&u){const h=s.getColCell(),p=n({index:r+o});c=h.reduce((m,g)=>{const b=n({index:g.colIndex+o});return b||(d=!1),m+b},p),c-=i,c=Math.ceil(c)}return d?c:Number.NaN}extend(t){t&&(this.grid=void 0,this.tree=ve.merge(this.tree,t),this.columns=this.cacheLevels(ve.getChildren(t),this.columns))}getGrid(){if(this.grid)return this.grid;let t=this.getTreeDeepsLength(),r=this.getTreeChildLength();return this.isVertical?([t,r]=[r,t],this.map=this.fillMapVertical(ve.getChildren(this.tree),r,this.map)):this.map=this.fillMap(ve.getChildren(this.tree),t,this.map),this.grid=Array.from(Array(t)).map((n,i)=>Array.from(Array(r)).map((a,o)=>{const s=sa(i,o),u=this.map[s];if(!u)throw new Error(`Key "${s}" does not found in TreeService`);return u.node?u.node:u.parent})),this.grid}getPartialGrid(t,r){if(!this.isVertical)throw new Error('"getPartialGrid" can only be used for "vertical" tree');const n=this.getTreeDeepsLength(),i=ve.getChildren(this.tree),{nodes:a,start:o,stop:s}=ve.getNodesByChildCount(i,t,r);this.fillMapVertical(a,n,this.map,{parentRowIndex:o,parentColIndex:0,prevChildren:0,parentKey:""});const u=Math.max(o,t),c=Math.min(s,r),d=Math.max(0,c-t);return Array.from(Array(d)).map((h,p)=>Array.from(Array(n)).map((m,g)=>{const b=u+p,_=sa(b,g),w=this.map[_];if(!w)throw new Error(`Key "${_}" does not found in TreeService`);return w.node?w.node:w.parent||""}))}getPartialTree(t,r,n){const i=ve.getChildren(this.tree);return ve.getCutNodesByChildCount(i,t,r,n)}getTreeNode(t,r){const n=this.getItem(t,r);if(n&&n.node)return n.node}isChildren(t,r){const n=this.getItem(t,r);if(n)return n.isChild();if(typeof this.deep=="number"&&(this.isVertical?r:t)<this.deep)return!0;throw new Error(`Item "${t}-${r}" does not found in TreeService`)}hasChildren(t,r){const n=this.getItem(t,r);if(n)return n.hasChildren();throw new Error(`Item "${t}-${r}" does not found in TreeService`)}getMainCellSpans(t,r){const n={},i=this.getItem(t,r);return i&&i.hasColCell()&&(n.colSpan=i.getColCell().length+1),i&&i.hasRowCell()&&(n.rowSpan=i.getRowCell().length+1),n}alignStartIndex(t,r=!1){let n=0,i=t;if(r&&(n=t,i=0),this.isVertical===r){let a=this.getItem(n,i);if(a&&a.isChild()&&(a=this.getItemByKey(a.parent||"")),a)return r?a.rowIndex:a.colIndex}return t}alignStopIndex(t,r=!1){let n=0,i=t;if(r&&(n=t,i=0),this.isVertical===r){let a=this.getItem(n,i);if(a&&a.isChild()&&(a=this.getItemByKey(a.parent||"")),a)return r?a.getStopRowIndex():a.getStopColIndex()}return t}getTreeChildLength(t=ve.getChildren(this.tree),r){return ve.getChildLength(t,r)}getTreeDeepsLength(t=ve.getChildren(this.tree),r){return typeof this.deep!="undefined"&&this.deep!==void 0?this.deep:ve.getDeepLength(t,r)}getLastLevelNodes(){return this.lastLevel}extractData(t){if(!t)return[];const n=t.getLastLevelNodes().map(i=>i.index);return this.getLastLevelNodes().map(i=>typeof i.data=="undefined"?[i.data]:n?n.map(a=>{let o;return typeof a!="undefined"&&i.data&&(o=i.data[a]),o}):i.data)}getMetadata(t,r,n){const i=this.getTreeDeepsLength();t===1/0&&(t=i&&i-1),r===1/0&&(r=i&&i-1);const a=`${t}-${r}`;if(this.metadataCache[a])return this.metadataCache[a];let o=this.getItemByKey(a);if(!o)throw new Error(`Can not find metadata info for ${a} cell`);let s=o?o.node:void 0;if(s||(o=this.getItemByKey(o.parent||"")),!o)throw new Error(`Can not find metadata info for parent ${a} cell`);s=o?o.node:void 0;const u=this.getItemByKey(`${t+1}-${r}`),c=u?u.node:void 0,d=s&&s.level||0,h=this.isVertical?o.getStopColIndex():o.getStopRowIndex();let{indexInParent:p,siblingCount:m}=o.getIndexInParent(),g=p;if(d===0&&(m=this.getTreeChildLength(),p=this.isVertical?o.rowIndex:o.colIndex,g=p+(this.isVertical?o.getRowCell().length:o.getColCell().length)),n){const C=n.to-n.from;m<=C&&g>C-1&&(g=C-1)}const b={levels:[],siblings:[],root:void 0,parent:void 0,valueNode:this.valueNode,nextNode:c},{indexDivergence:_}=s||{};if(typeof _=="number"){const C=_===0?rn.EVEN:rn.ODD;b.siblings.push(C)}if(d===0&&b.levels.push(rn.FIRST),h===i-1&&b.levels.push(rn.LAST),p===0&&b.siblings.push(rn.FIRST),g===m-1&&b.siblings.push(rn.LAST),s&&d!==0){const C=this.isVertical?t:0,S=this.isVertical?0:r;b.root=this.getMetadata(C,S,n)}const w=this.getItemByKey(o.parent||"");if(w&&d!==0&&(b.parent=this.getMetadata(w.rowIndex,w.colIndex,n)),n){const C=this.isVertical?o.rowIndex:o.colIndex,S=this.isVertical?o.getStopRowIndex():o.getStopColIndex();let T;w&&(T=this.isVertical?w.getStopRowIndex():w.getStopColIndex()),T!==void 0&&T>=n.to-n.from&&S>=n.to-n.from-1&&!b.siblings.includes(rn.LAST)&&b.siblings.push(rn.LAST),C===0&&!b.siblings.includes(rn.FIRST)&&b.siblings.push(rn.FIRST)}return this.metadataCache[a]=b,b}setValueNode(t){typeof t=="object"&&(this.valueNode=t)}cacheLevels(t,r=[],n={level:0}){const{level:i}=n;return t.forEach(a=>{if(r[i]||(r[i]=[]),ve.setLevel(a,i),r[i].push(a),ve.hasChildren(a)){const o=i+1;this.cacheLevels(ve.getChildren(a),r,{level:o})}else this.lastLevel.push(a)}),r}fillMap(t,r,n={},i){const a=i||{parentRowIndex:0,parentColIndex:0,prevChildren:0,parentKey:""},o=t.length;return t.forEach((s,u)=>{const{parentRowIndex:c,parentColIndex:d,prevChildren:h,parentKey:p}=a,g=ve.getLevel(s)+c,b=u+d+h,_=sa(g,b),w=this.createTreeCellMap({rowIndex:g,colIndex:b,node:s,parent:p});w.setIndexInParent(u,o),n[_]=w;let C=0,S=0;if(ve.hasChildren(s)?(C=this.getTreeChildLength(s),typeof s.minLevel=="number"&&(S=s.minLevel+1-g||0)):S=(r||0)-(g||0),(C>1||S>1)&&this.fillChildMap(n,_,g,b,S,C),ve.hasChildren(s)){const T=Object.assign(Object.assign({},a),{parentRowIndex:S>1?S-1:0,parentColIndex:u+d,parentKey:_});this.fillMap(ve.getChildren(s),r,n,T),C>1&&(a.prevChildren+=C-1)}}),n}fillMapVertical(t,r,n={},i){const a=i||{parentRowIndex:0,parentColIndex:0,prevChildren:0,parentKey:""},o=t.length;return t.forEach((s,u)=>{if(s.isMapped){a.parentRowIndex+=ve.getChildLength(s)-1;return}s.isMapped=!0;const{parentRowIndex:c,prevChildren:d,parentKey:h}=a,p=ve.getLevel(s),m=u+c+d,g=sa(m,p),b=this.createTreeCellMap({rowIndex:m,colIndex:p,node:s,parent:h});b.setIndexInParent(u,o),n[g]=b;let _=0,w=0;if(ve.hasChildren(s)?w=this.getTreeChildLength(s):_=(r||0)-(p||0),(_>1||w>1)&&this.fillChildMap(n,g,m,p,w,_),ve.hasChildren(s)){const C=Object.assign(Object.assign({},a),{parentRowIndex:u+c,parentKey:g});this.fillMapVertical(ve.getChildren(s),r,n,C),w>1&&(a.prevChildren+=w-1)}}),n}fillChildMap(t,r,n,i,a,o){const s=t[r],u=Math.max(1,a),c=Math.max(1,o);Array.from(Array(u)).forEach((d,h)=>{Array.from(Array(c)).forEach((p,m)=>{if(h===0&&m===0)return;const g=n+h,b=i+m,_=sa(g,b),w=this.createTreeCellMap({rowIndex:g,colIndex:b,parent:r});t[_]=w,!(h!==0&&m!==0)&&(m===0&&s.addRowCell(w),h===0&&s.addColCell(w))})})}createTreeCellMap({rowIndex:t,colIndex:r,node:n,parent:i}){return new YA(t,r,n,i)}getItemByKey(t){return this.map[t]}getItem(t,r){const n=sa(t,r);return this.getItemByKey(n)}}class gi extends a5{}const Ne={ROWS:"rows",COLUMNS:"columns",MEASURES:"measures",SCOPE:"scope"},Yl={ASC:"asc",DESC:"desc"},Et={SUB_TOTAL:"subTotal",GRAND_TOTAL:"grandTotal",MEASURE_TOP:"measureTop",MEASURE_BOTTOM:"measureBottom",CORNER:"corner"},d1={COLOR:"color",CONDITION:"condition"},Jm={DATETIME:"datetime",TEXT:"text",NUMERIC:"numeric"},la={MEMBER:"member",VALUE:"value",SUB_TOTAL:"subtotal",GRAND_TOTAL:"grandtotal"},Yn={MEMBER:"member",INDEX:"index",TITLE:"title",NAME:"name",AGG:"agg",DIM:"dim"};class h1{constructor(t=[],r){this.divergence=0;const n=r?r.getDivergence():0,i=ve.getLastLevelNodes(t);this.divergence=(n+i.length)%2;for(let a=0;a<i.length;a+=1)i[a].indexDivergence=(a+n)%2}getDivergence(){return this.divergence}}const cn=(e,t)=>{const r=e;return t&&(r.metadataType=t),r};function Ys(e=[]){const t={};return e.forEach(r=>{const{index:n=1/0}=r.field||{},i=`${n}`;t[i]=r.jaql.datatype||Jm.TEXT}),t}function kf(e,t){if(e&&t===Jm.DATETIME)try{return new Date(e).toISOString()}catch(r){return e}return e}function f1(e){if(e!==null&&!V.isEqual(e,{}))return e}function Ai(e,t,r={}){const n=f1(e),i=f1(t);let a=!1;if(typeof n=="object"&&n!==null&&typeof i=="object"&&i!==null){a=!0;const o=Object.keys(n),s=Object.keys(i);o.length!==s.length?a=!1:o.forEach(u=>{const c=r[u]||"";let d=(n||{})[u],h=(i||{})[u];if(typeof d=="undefined"||typeof h=="undefined"){a=!1;return}c===Jm.DATETIME&&(d=kf(d,c),h=kf(h,c)),d!==h&&(a=!1)})}else a=n===i;return a}function yw(e,t,r=kf){if(!e||typeof e!="object")return e;const n={};return Object.keys(e).forEach(i=>{const a=t[i],o=(e||{})[i],s=r(o,a);n[i]=s}),n}const Gr=(e,t)=>{let r=e&&e.metadata||[];return t&&(r=r.filter(n=>n.panel===t)),r.sort((n,i)=>{const a={index:1/0},o=n.field||a,s=i.field||a;return o.index-s.index}),r},Hi=(e,t,r)=>typeof t=="undefined"?void 0:Gr(e,r).filter(a=>(a.field||{index:1/0}).index===t)[0],o5=(e,t)=>{const r=e.field||{index:1/0};if(e.panel===Ne.MEASURES)return!0;if(e.panel===Ne.ROWS){const n=Gr(t,Ne.ROWS),a=(n[n.length-1]||{}).field||{index:1/0};if(n.length&&a.index===r.index)return!0;n.length||console.error("Missing rows panel in jaql!")}return!1};function s5(e,t){return!e||typeof e.field!="number"?!1:e.field!==t}const e0=(e,t=Ne.ROWS)=>{const n=Gr(e,t).map((i,a)=>{const o=ve.create(i.jaql.title,void 0,void 0,a),s=cn(o,t);switch(s.jaqlIndex=i.field?i.field.index:void 0,t){case Ne.ROWS:{s.measurePath=void 0;const u=s5(i.jaql.sortDetails,s.jaqlIndex);i.jaql.sort&&!u?s.dir=i.jaql.sort:s.dir=null;break}case Ne.MEASURES:s.databars=i.format?i.format.databars:!1,s.measureJaqlIndex=s.jaqlIndex,Gr(e,Ne.COLUMNS).length||(s.measurePath=void 0,i.jaql.sortDetails&&i.jaql.sortDetails.measurePath===null?s.dir=i.jaql.sortDetails.dir:s.dir=null);break}return s});return ve.wrapInRootNode(n)},bw=e=>{(e&&e.metadata?e.metadata:[]).forEach(r=>{r&&r.jaql&&r.jaql.sort&&r.jaql.sortDetails&&r.jaql.sortDetails.sortingLastDimension&&(r.jaql.sort=null,delete r.jaql.sortDetails)})},_w=e=>{e&&e.jaql&&(e.jaql.sort=null,delete e.jaql.sortDetails)},ww=e=>{(e&&e.metadata?e.metadata:[]).forEach(r=>_w(r))},l5=e=>(e.metadata||[]).reverse().find(t=>!!t.jaql.sortDetails),u5=e=>(e.metadata||[]).find(t=>!!(t.jaql.sortDetails&&t.jaql.sortDetails.isLastApplied)),c5=e=>{const t=u5(e)||l5(e);if(!t)return;const r=t.field&&t.field.index;(e.metadata||[]).forEach(n=>{(n.field&&n.field.index)!==r&&_w(n)})},Cw=(e,t)=>{e.metadata.forEach(r=>{const n=r.field&&r.field.index;if(t.field===n){r.jaql.sortDetails=r.jaql.sortDetails||t,r.jaql.sortDetails.isLastApplied=!0;return}r.jaql.sortDetails&&r.jaql.sortDetails&&delete r.jaql.sortDetails.isLastApplied})},d5=(e,t,r)=>{const{isSingleRowTree:n=!1,formatter:i}=r||{};if(!t){console.warn("jaql is undefined or null!");return}const a=Hi(t,e.field);if(a&&a.panel===Ne.COLUMNS){console.warn('Should not be sorted by "COLUMN" type panels!');return}if(!a)return;const o=o5(a,t);switch(n?ww(t):o&&bw(t),e.dir){case Yl.DESC:case null:a.jaql.sort=Yl.ASC;break;case Yl.ASC:a.jaql.sort=Yl.DESC;break;default:a.jaql.sort=void 0}const s=a.field||{index:1/0};if(a.jaql.sort){let{measurePath:u}=e;if(u){const c=Gr(t),d=Ys(c);u=yw(u,d,i)}a.jaql.sortDetails={field:s.index,dir:a.jaql.sort,sortingLastDimension:o,measurePath:u,initialized:!0}}else a.jaql.sortDetails=void 0;t&&t.metadata&&s.index!==void 0&&(t.metadata[s.index]=a),Cw(t,e)},h5=(e,t,r)=>{if(!e)return;const n=Hi(e,t);n&&(n.format=n.format||{},n.format.width=r)},f5=e=>{const t={};return e&&Gr(e).forEach(n=>{const i=n.field||{index:1/0};n.format&&typeof n.format.width!="undefined"&&typeof i.index!="undefined"&&(t[i.index]=n.format.width)}),t},xw=(e,t)=>{if(typeof t.measureJaqlIndex!="undefined"){const r=Gr(e),n=Ys(r),i=r.filter(o=>o.panel===Ne.ROWS).find(o=>{const s=o.jaql.sortDetails;return!s||!(s.field===t.measureJaqlIndex)?!1:!!Ai(t.measurePath,s.measurePath,n)});if(i){t.dir=i.jaql.sort?i.jaql.sort:null;return}const a=Hi(e,t.measureJaqlIndex);if(a&&a.jaql.sortDetails){const o=a.jaql.sortDetails.measurePath,s=t.measurePath;if(Ai(o,s,n)){t.dir=a.jaql.sort||null;return}}}t.dir=null};function p5(e,t,r,n){const{isSingleRowTree:i,formatter:a}=n;i&&ww(e),e.metadata.forEach(o=>{o.jaql.sortDetails&&delete o.jaql.sortDetails.isLastApplied}),t.forEach((o,s)=>{let u;s===t.length-1?(o.selected&&bw(e),u=r.field):u=o.indexInJaql;const c=Hi(e,u);if(!c){console.warn(new Error("Panel not found"));return}o.selected&&!o.direction&&console.warn(new Error("Direction should be defined and equal to 'asc' or 'desc'"));const d=Gr(e),h=Ys(d);if(!o.direction||!o.selected){const{sortDetails:p}=c.jaql;!!(p&&r.field===p.field&&Ai(r.measurePath,p.measurePath,h))&&(delete c.jaql.sort,delete c.jaql.sortDetails)}if(o.selected&&o.direction){c.jaql.sort=o.direction;let{measurePath:p}=r;p&&(p=yw(p,h,a)),r.measurePath===void 0&&c.field&&c.panel==="rows"&&r.field!==c.field.index&&(p={}),c.jaql.sortDetails={field:r.field,dir:o.direction,sortingLastDimension:!1,measurePath:p,isLastApplied:!0,initialized:!0}}})}function m5(e,t,r,n){return e.jaql.sortDetails?!1:r?Ai(t.measurePath,r.measurePath,n):!1}function Lf(e){const t=e&&e.dir;switch(t){case"asc":case"desc":return t;default:return null}}function g5(e,t){var r,n;const i=e.metadata.filter(g=>g.panel==="rows"),a=Hi(e,t.field),o=a.jaql.datatype,s=a.jaql.sortDetails,u=Ys(Gr(e)),c=[];for(let g=0;g<i.length-1;g+=1){const b=i[g],_=!!(b.jaql.sortDetails&&b.jaql.sortDetails.field===t.field&&Ai(t.measurePath,b.jaql.sortDetails.measurePath,u)),w=Lf(b.jaql.sortDetails);c.push({title:b.jaql.title,datatype:o,selected:_,direction:w,indexInJaql:(r=b.field)===null||r===void 0?void 0:r.index})}const d=i[i.length-1],h=m5(d,t,s,u),p=Lf(s),m={title:d.jaql.title,datatype:o,selected:h,direction:p,indexInJaql:(n=a.field)===null||n===void 0?void 0:n.index};return c.push(m),c}function v5(e,t,r){return e.filter(i=>i.field&&t.field===i.field.index).map(i=>{const{sortDetails:a}=i.jaql,o=!!(a&&Ai(t.measurePath,a.measurePath,r)),s=o?Lf(a):null;return{title:i.jaql.title,datatype:i.jaql.datatype,selected:o,direction:s}})[0]}const ua={isMeasurePathEqual:Ai,getDataTypes:Ys,updatePanelsSortingMetadata:d5,getMetadataTree:e0,getMetadataPanels:Gr,getMetadataPanelByIndex:Hi,setResizeWidthToJaql:h5,getResizeWidthFromJaql:f5,markSortedNode:xw,normalizeSingleBranchTreeSortDetails:c5,updateLastAppliedSortingFlag:Cw,handleComplexSortingSettingsUpdate:p5,mapWidgetJaqlToSimpleSortingSettings:v5,mapWidgetJaqlToComplexSortingSettings:g5};function Tw(e,t){if(!ve.hasChildren(e))return!1;let r=!1;t===Ne.COLUMNS&&e&&e.isPart&&(r=!0);const n=ve.getChildren(e);if(n.length>1||r)return!0;const[i]=n;return Tw(i)}function y5(e){return e==null}const t0=(e,t,r,n,i)=>{const a=[];return e.forEach(o=>{if(a.push(o),ve.hasChildren(o)){const s=ve.getChildren(o),u=t0(s,t,r,n,i);ve.setChildren(o,u);let c=!1;if((i||Tw(o,r))&&(r===Ne.COLUMNS?typeof o.index!="undefined"&&o.index>-1&&(c=!0):r===Ne.ROWS&&typeof o.data!="undefined"&&(c=!0)),c){const{value:d,index:h,data:p,jaqlIndex:m,measurePath:g}=o;let b;if(r===Ne.COLUMNS?b=ve.create(d,void 0,void 0,h):r===Ne.ROWS&&(b=ve.create(d,void 0,p)),b){const _=cn(b,r);_.userType=Et.SUB_TOTAL,_.jaqlIndex=m,_.measurePath=g,_.master=o,a.push(_)}}}}),a},Sw=(e,t)=>{e.userType===Et.SUB_TOTAL&&e.master&&(e.measurePath=e.master.measurePath)},Mw=(e,t,r,n)=>{const i=e;if(r===Ne.COLUMNS&&t){const a=cn(t);if(typeof a.index=="number"){const s=e0(n,Ne.MEASURES);ve.getChildren(s).forEach((u,c)=>{const d=Object.assign(Object.assign({},u),{index:(a.index||0)+c}),h=cn(d,r);h.userType=Et.GRAND_TOTAL,h.measureJaqlIndex=h.jaqlIndex,i.push(h)})}}return i},Pw=(e,t)=>{e.userType===Et.GRAND_TOTAL&&(e.measurePath=void 0,e.metadataType===Ne.ROWS&&(e.parent=void 0,e.jaqlIndex=0))},Ew=(e,t,r,n)=>{let i=e;if(r===Ne.COLUMNS){const a=e0(n,Ne.MEASURES),o=ve.getChildLength(a),s={maxLevel:0},u=ve.getLastLevelNodes(i,[],0,s);if(o>1)u.forEach(c=>{if(c.userType===Et.GRAND_TOTAL)return;const d=ve.getChildren(a),h=[];for(let p=0;p<d.length;p+=1){if(typeof c.maxChilds=="number"&&p>=c.maxChilds)continue;const m=Object.assign(Object.assign({},d[p]),{index:(c.index||0)+p,measurePath:c.measurePath}),g=cn(m,Ne.MEASURES);g.userType=Et.MEASURE_BOTTOM,g.measureJaqlIndex=g.jaqlIndex,h.push(g)}c.minLevel=s.maxLevel,ve.setChildren(c,h)});else if(o===1){const c=ve.getChildren(a)[0];if(c){const d=Object.assign({},c),h=cn(d,Ne.MEASURES);h.userType=Et.MEASURE_TOP,ve.setChildren(h,i),i=[h],u.forEach(p=>{p.measureJaqlIndex=c.jaqlIndex})}}}return i},Aw=(e,t)=>{!ve.hasChildren(e)&&typeof e.measureJaqlIndex!="undefined"&&xw(t,e)},b5=(e,t,r,n)=>{let i={};if(t.userType===Et.SUB_TOTAL||t.userType===Et.GRAND_TOTAL||r.userType===Et.SUB_TOTAL||r.userType===Et.GRAND_TOTAL||r.parent&&r.parent.userType===Et.SUB_TOTAL||r.parent&&r.parent.userType===Et.GRAND_TOTAL)return;const a=n&&n.format&&n.format.color||null;if(!a)return;const{value:o,cf:s=-1}=e;if(a.type===d1.COLOR&&a.color&&a.color!=="transparent"&&(i.backgroundColor=a.color),a.type===d1.CONDITION&&a.conditions&&a.conditions.length)for(let u=0,c=a.conditions.length;u<c&&!y5(o);u+=1){const d=a.conditions||[],{color:h}=d[u]||{};if(h&&s===u){i.backgroundColor=h;break}}Object.keys(i).length>0&&(e.style=e.style||{},Object.assign(e.style,i)),i=void 0},Rw=(e,t,r,n)=>{const i=[],{level:a=0,measurePath:o={}}=n||{};let s;Array.isArray(e)?s=e:s=ve.getChildren(e);const c=Gr(r,t)[a],d=c?(c.field||{index:1/0}).index:void 0;return s.forEach(h=>{const p=cn(h,t);if(p.jaqlIndex=d,typeof d!="undefined"&&(p.measurePath=Object.assign(Object.assign({},o),{[d]:p.value})),i.push(p),ve.hasChildren(p)){const m=ve.getChildren(p),g={level:a+1,measurePath:p.measurePath},b=Rw(m,t,r,g);ve.setChildren(p,b)}}),i},Dw=(e,t,r)=>{const{skipFormatEvent:n=!1,onlyFormatEvents:i=!1,iterateFn:a,emitFn:o}=r||{};e.forEach(s=>{if(a&&a(s),(n||!i)&&(Sw(s),Pw(s),Aw(s,t)),o&&(i||!n)){const u=Hi(t,s.jaqlIndex,s.metadataType||"");o(s,u,t)}if(ve.hasChildren(s)){const u=ve.getChildren(s);Dw(u,t,r)}})},_5=(e,t,r,n)=>{const{originalData:i,applyIndexDivergence:a,subtotalsForSingleRow:o}=n||{};a&&a(e);let s=t0(e,i,t,r,o);return s=Mw(s,i,t,r),s=Ew(s,i,t,r),ve.iterateThroughTree(s,(u,c)=>{u.parent=c}),s},$o={insertSubTotals:t0,postProcessSubTotal:Sw,insertGrandTotals:Mw,postProcessGrandTotal:Pw,insertMeasureNodes:Ew,postProcessMeasureNode:Aw,applyColorFormatting:b5,preProcessTree:Rw,modifyTree:_5,postProcessTree:Dw};var w5=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r};const C5=(e,t)=>e.metadata.find(r=>r.field&&r.field.index===t),Au=(e,t,r=[],n=[])=>{if(!t||!e||typeof e.jaqlIndex=="undefined")return{dimensionsMeta:r,type:n};const i=C5(t,e.jaqlIndex);if(i&&i.jaql&&e.metadataType!==Ne.MEASURES&&r.unshift({title:i.jaql.title,name:i.jaql.dim,member:e.value,index:e.jaqlIndex}),e&&e.userType&&(e.userType===Et.SUB_TOTAL||e.userType===Et.GRAND_TOTAL)){const a=e.userType.toLowerCase();n.push(a)}return e.parent&&e.parent.metadataType!==Ne.MEASURES?Au(e.parent,t,r,n):{dimensionsMeta:r,type:n}},p1=e=>{let t={};if(e){const r=e.jaql;t=w5(r,["type","datatype","table","column"]),e.field&&(t.index=e.field.index)}return t};function La(e,t,r){return!t||!t.length?!1:t.some(n=>{let i=!0;return r&&r.fields&&r.fields.length&&r.fields.forEach(a=>{const o=e,s=n;o[a]!==void 0&&s[a]===void 0?i=!1:o[a]!==void 0&&s[a]!==void 0&&(Array.isArray(o[a])?i=i&&o[a].indexOf(s[a])!==-1:i=i&&o[a]===s[a])}),i})}const x5=(e,t=[])=>{let r=!1;return!t||!t.length?!1:e.length===0?!0:(e.forEach(n=>{t.includes(n)&&(r=!0)}),r)},m1=(e,t)=>{let r=!0;return!t||!t.length?r=!1:e.forEach(n=>{if(n.index){const i=t[t.length-1];r=r&&La(n,[i],{fields:[Yn.INDEX]})}if(n.dim&&(n.name=n.dim,n.members&&(n.member=n.members),r=r&&La(n,t,{fields:[Yn.NAME,Yn.MEMBER]})),n.title){const i=t[t.length-1];r=r&&La(n,[i],{fields:[Yn.TITLE]})}}),r},T5=(e,t)=>{let r=!0;return!t||!t.length?r=!1:e.forEach(n=>{n.index&&(r=r&&La(n,t,{fields:[Yn.INDEX]})),n.dim&&(n.name=n.dim,r=r&&La(n,t,{fields:[Yn.DIM,Yn.AGG]})),n.title&&(r=r&&La(n,t,{fields:[Yn.TITLE]}))}),r},S5=(e,t)=>{let r=!0;if(e.type&&r&&(r=r&&x5(e.type,t.type)),e.rows&&e.rows.length&&r){const n=t.rows?t.rows:[];r=r&&m1(e.rows,n)}if(e.columns&&r){const n=t.columns?t.columns:[];r=r&&m1(e.columns,n)}if(e.values&&r){const n=t.measure?[t.measure]:[];r=r&&T5(e.values,n)}return r},M5=e=>{const t={};return Object.keys(e).forEach(r=>{(!r.startsWith("border")||r==="borderColor")&&(t[r]=e[r])}),t},Bo="text";class r0{constructor(t,r,n){this.plugins=[],this.columnsMetadata=[],this.metadataCache=new Map,this.plugins=t,this.jaql=r,this.globalStyles=n,this.indexHelper={measuresLevel:this.getMeasuresLevel(),columnStartFrom:0,rowStartFrom:0},this.globalStyles&&(this.globalStyles=M5(this.globalStyles))}getJaqlPanels(t){if(!this.jaql)throw new Error("No Jaql in Plugin service!");return this.jaql.metadata.filter(r=>r.panel===t)}getMeasuresLevel(){const t=this.getJaqlPanels(Ne.COLUMNS);return this.getJaqlPanels(Ne.MEASURES).length>1?t.length:0}getRowsColumnLength(){return this.getJaqlPanels(Ne.ROWS).length}getTotalTypes(t){const r=t.filter(n=>n===la.SUB_TOTAL||n===la.GRAND_TOTAL);return r&&r.length?r.filter((n,i,a)=>a.indexOf(n)===i):[]}getMeasureMetaByIndex(t){const r=this.getJaqlPanels(Ne.MEASURES);if(r.length===1)return p1(r[0]);const n=t%r.length;return p1(r[n])}resetRowStartFrom(){this.indexHelper.rowStartFrom=1}applyToColumns(t){t.length!==0&&(this.indexHelper.columnStartFrom===0&&(this.indexHelper.columnStartFrom=this.getRowsColumnLength()),this._applyToColumns(t,{row:-1}))}_applyToColumns(t,r){t.forEach((n,i)=>{const{dimensionsMeta:a,type:o}=Au(n,this.jaql);o.push(la.MEMBER);let s=r.row>=0?r.row+1:0;s>=this.indexHelper.rowStartFrom&&(this.indexHelper.rowStartFrom=s+1),n.metadataType===Ne.MEASURES&&(s=this.indexHelper.measuresLevel);let u=i===0?0:1;u+=this.indexHelper.columnStartFrom;const c={type:o,rowIndex:s,colIndex:u,index:n.jaqlIndex,columns:a};n.metadataType===Ne.MEASURES&&(c.measure=this.getMeasureMetaByIndex(n.index||0));const d={value:n.value||"",content:n.content||"",contentType:n.contentType||Bo,style:n.style||{},store:n.store||{},state:n.state};if(this.applyGlobal(d),this.apply(c,d),this.addToMetadata(c,d,c.rowIndex,c.colIndex),Object.assign(n,d),this.indexHelper.columnStartFrom=u,n.children){const h={row:s,column:u};this._applyToColumns(n.children,h)}else this.columnsMetadata.push({type:o,metadata:a});return!0})}applyToHeaders(t){!t||!t.children||t.children.length===0||t.children.forEach(r=>{const{dimensionsMeta:n}=Au(r,this.jaql),i={type:[la.MEMBER],rowIndex:0,colIndex:r.index||0,index:r.jaqlIndex,rows:n},a={value:r.value,content:r.content||"",contentType:r.contentType||Bo,style:r.style?r.style:{},store:r.store||{},state:r.state};this.applyGlobal(a),this.apply(i,a),this.addToMetadata(i,a,i.rowIndex,i.colIndex),Object.assign(r,a)})}applyToRows(t){if(t.length===0)return;const r=this.getJaqlPanels(Ne.ROWS),n=this.getJaqlPanels(Ne.MEASURES),i=this.getJaqlPanels(Ne.COLUMNS);this.indexHelper.rowStartFrom=r0.getRowStartFromForPage(r.length,n.length,i.length),this._applyToRows(t)}static getRowStartFromForPage(t,r,n){if(t===0&&n===0)return 0;const i=n+(r===0?0:1);return i===0?1:i}_applyToRows(t){t.forEach((r,n)=>{const{dimensionsMeta:i,type:a}=Au(r,this.jaql);a.push(la.MEMBER);const o=r.level?r.level:0,s=n===0?this.indexHelper.rowStartFrom:this.indexHelper.rowStartFrom+1,u={type:a,rowIndex:s,colIndex:o,index:r.jaqlIndex,rows:i},c={value:r.value,content:r.content||"",contentType:r.contentType||Bo,style:r.style||{},store:r.store||{},state:r.state};return this.applyGlobal(c),this.apply(u,c),this.addToMetadata(u,c,u.rowIndex,u.colIndex),this.indexHelper.rowStartFrom=s,r.children?this._applyToRows(r.children):r.data&&r.data.length&&this.applyToValues(r.data,{type:a,metadata:i},{rowIndex:s,colIndex:this.getRowsColumnLength()}),Object.assign(r,c),!0})}applyToValues(t,r,n){t.length&&t.forEach((i,a)=>{const o=[la.VALUE],s=this.columnsMetadata[a];if(!s)return;const u=this.getTotalTypes([...r.type,...s.type]),c=this.getMeasureMetaByIndex(a),d={type:o.concat(u),rows:r.metadata,columns:s.metadata,measure:c,colIndex:a+n.colIndex,rowIndex:n.rowIndex,index:c&&c.index?c.index:0};let h={value:i,content:i,contentType:Bo,style:{},store:i&&i.store||{},state:i&&i.state||void 0};i!=null&&typeof i=="object"&&(h={value:i.value?i.value:null,content:i.content||"",contentType:i.contentType||Bo,style:i.style||{},store:i.store||{},state:i.state}),this.applyGlobal(h),this.apply(d,h),this.addToMetadata(d,h,d.rowIndex,d.colIndex),t[a]=h})}addToMetadata(t,r,n,i){const a=Object.assign({cellData:{value:r.value,content:r.content}},t);this.metadataCache.set(`${n}-${i}`,a)}applyGlobal(t){const{globalStyles:r}=this;r&&(t.style=Object.assign(Object.assign({},t.style),r))}apply(t,r){this.plugins&&this.plugins.length&&this.plugins.forEach(n=>{if(S5(n.target,t)){const a=n.handler;a(t,r)}})}}var P5=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r};const wh=(e,t)=>{const r=e||{metadata:[],grandTotals:null};let{metadata:n}=r;return n=n.map(i=>{const a=i.field||{},o=t.find(({field:u})=>u&&u.index===a.index),s=o?o.format:null;return s?Object.assign(Object.assign({},i),{format:s}):i}),Object.assign(Object.assign({},r),{metadata:n})},g1=100,E5="dataLoad",A5="dataChunkLoaded",R5="dataBarChunkLoaded",D5="rangeMinMaxChunkLoaded",N5="grandChunkLoaded",k5="dataFinishChunkLoaded",L5="finishChunkLoaded",O5="progressError",Of="headerCellFormat",Nw="dataCellFormat",I5="totalRowsCountLoaded",F5="totalColumnsCountLoaded",v1=1e3,$5=0,B5={throttle:QA,throttleTime:$5,PluginService:r0,skipInternalColorFormatting:!1,subtotalsForSingleRow:!1};class br{constructor(t,r,n){this.tempDataChunks=[],this.lastNotHandledChunkIndex=0,this.lastReadyNotHandledChunkIndex=0,this.rowsGrand=void 0,this.rowsTreeService=void 0,this.columnsTreeService=void 0,this.cornerTreeService=void 0,this.pageSize=g1,this.isPaginated=!1,this.loadedPagesCount=0,this.isLoadInProgress=!1,this.loadAllPromise=void 0,this.loadAllPromiseResolve=void 0,this.loadAllPromiseReject=void 0,this.isWholeDataLoaded=!1,this.hasDataFinishEvent=!1,this.isDataHandlerThrottled=!1,this.metadata=[],this.divergenceComparator=new h1,this.rawJaql=void 0,this.triggeredEventsData={},this.callPlugins=[],this.onMetadataHandler=()=>{const i={metadata:this.getMetadata()};this.isSingleRowTree()&&ua.normalizeSingleBranchTreeSortDetails(i)},this.onHeadersHandler=i=>{const a=this.getJaql.bind(this),o=this.getRawJaql.bind(this),s=this.applyIndexDivergence.bind(this),u=(m,g,b)=>this.emit(Of,m,g,b,this.options),d=br.createColumnsTreeServiceBuilder({getJaql:a,getRawJaql:o,pluginService:this.pluginService,applyIndexDivergence:s},{emitHeaderCellFormatEvent:u})(i);this.columnsTreeService=d.columnsTreeService,this.columnsCount=d.columnsCount,this.totalColumnsCount=d.totalColumnsCount,this.emit(F5,{columnsCount:this.columnsCount||0,totalColumnsCount:this.totalColumnsCount||0});const h=br.createCornerTreeServiceBuilder({getJaql:a,getRawJaql:o,pluginService:this.pluginService,columnsTreeService:this.columnsTreeService},{emitHeaderCellFormatEvent:u}),{cornerTreeService:p}=h();this.cornerTreeService=p},this.onDataHandler=i=>{this.tempDataChunks=this.tempDataChunks||[],Array.isArray(i)?(i||[]).forEach(a=>{br.fillDataChunks(this.tempDataChunks,a,this.pageSize)}):br.fillDataChunks(this.tempDataChunks,i,this.pageSize),this.tempDataChunks.length&&(this.isDataHandlerThrottled=!0,this.onDataHandlerThrottle())},this.onGrandHandler=i=>{const o=this.preProcessTree([i],Ne.ROWS)[0],s="Rows grand total",u=o?o.data:[],c=ve.create(s,void 0,u),d=cn(c,Ne.ROWS);d.userType=Et.GRAND_TOTAL,this.postProcessTree([d]),this.postProcessData([d]),this.rowsGrand=d,this.emit(N5,ve.wrapInRootNode(this.rowsGrand))},this.onFinishHandler=()=>{this.emit(L5,{totalRows:typeof this.totalRowsCount=="number"?this.totalRowsCount:this.getTotalItemsCount(),totalColumns:typeof this.totalColumnsCount=="number"?this.totalColumnsCount:this.getLoadedColumnsCount()})},this.onTotalRowsHandler=i=>{const{rowsCount:a,queryRowsCount:o,limitReached:s}=i||{};this.totalRowsCount=a,this.totalRecordsCount=o,this.limitReached=s,this.emit(I5,i)},this.onDataBarsHandler=i=>{const{data:a=[]}=i;let o=0;this.cornerTreeService&&(o=this.cornerTreeService.getTreeChildLength()),this.dataBars=[...Array(o),...a],this.emit(R5,this.dataBars)},this.onRangeMinMaxHandler=i=>{const{data:a=[]}=i,o=this.getJaql(),s=ua.getMetadataTree(o,Ne.MEASURES),u=ve.getChildren(s),c=[];u.forEach((d,h)=>{c[d.measureJaqlIndex||0]=a[h]}),this.rangeMinMax=c,this.emit(D5,this.rangeMinMax)},this.onDataFinishHandler=({rowsCount:i}={})=>{if(this.finishRequest(),this.rowsCount=i,this.tempDataChunks.length){const a=this.tempDataChunks[this.tempDataChunks.length-1];a.ready=!0}this.onDataHandlerThrottle(),this.checkLoadPromise(),this.emit(k5,{limitedRows:this.rowsCount,limitedColumns:this.columnsCount})},this.onErrorHandler=i=>{process.env.NODE_ENV!=="production"&&console.warn(`DataService data loading error "${JSON.stringify(i)}"`),!this.isLoadInProgress&&!this.isWholeDataLoaded&&!(i instanceof ql)&&this.emit(O5,i)},this.loadService=t,this.events=r||new Qm,this.options=Object.assign(Object.assign({},B5),n),this.attachEvent(),this.onDataHandlerThrottle=this.options.throttle(()=>{const i=c1(this.tempDataChunks,d=>d.ready&&!d.handled,this.lastReadyNotHandledChunkIndex);if(i===-1)return;this.lastReadyNotHandledChunkIndex=i;const a=this.tempDataChunks[i],o=this.preProcessTree(a.list,Ne.ROWS),s=this.modifyTree(o,Ne.ROWS);this.postProcessTree(s,{skipFormatEvent:!0}),this.postProcessData(s,{skipFormatEvent:!0});const u=ve.wrapInRootNode(s);this.rowsTreeService?this.rowsTreeService.extend(u):this.rowsTreeService=new gi(u,!0),this.emit(A5,this.getLoadedElementsCount()),a.handled=!0;const c=c1(this.tempDataChunks,d=>!d.handled,this.lastNotHandledChunkIndex);if(c!==-1?(this.lastNotHandledChunkIndex=c,this.onDataHandlerThrottle()):this.isDataHandlerThrottled=!1,this.hasDataFinishEvent&&this.tempDataChunks.length){const d=this.tempDataChunks[this.tempDataChunks.length-1];d.ready=!0}this.hasDataFinishEvent&&c===-1?(this.finishRequest(),this.checkLoadPromise()):this.checkLoadPromise()},this.options.throttleTime)}destroy(){this.detachEvent(),this.rowsGrand=void 0,this.rowsTreeService=void 0,this.columnsTreeService=void 0,this.cornerTreeService=void 0,this.tempDataChunks=[],this.lastNotHandledChunkIndex=0,this.lastReadyNotHandledChunkIndex=0,this.events.removeAllListeners()}on(t,r){this.events.on(t,r),this.triggeredEventsData[t]&&(this.triggeredEventsData[t].forEach(n=>{this.events.emit(t,...n)}),delete this.triggeredEventsData[t])}emit(t,...r){this.events.listeners(t).length===0?(this.triggeredEventsData[t]=this.triggeredEventsData[t]||[],this.triggeredEventsData[t].push(r)):this.events.emit(t,...r)}off(t,r){this.events.removeListener(t,r),this.triggeredEventsData[t]&&delete this.triggeredEventsData[t]}loadData(t,r){const{pageSize:n=g1,isPaginated:i=!1,cacheResult:a=!1,metadata:o}=r||{},s=this.pageSize===n;if(this.clearLoadAllPromise(),t&&this.clearCache(),this.pageSize=n,this.isPaginated=i,this.emit(E5),this.loadPromiseCache&&s){const c=Promise.resolve(this.loadPromiseCache);return this.loadPromiseCache=void 0,c}this.isLoadInProgress=!0,t&&(this.metadata=o||[],this.rawJaql=wh(t,this.metadata),this.initPluginService(this.rawJaql),this.loadService.load(t).then(c=>{if(c==null)return;const d=!("data"in c);if(c.dataFinish[0]&&d)throw{error:{error:!0,details:"metadata undefined."}}}).catch(c=>{this.loadPromiseReject&&this.loadPromiseReject(c.error)}));const u=new Promise((c,d)=>{this.loadPromiseResolve=c,this.loadPromiseReject=d}).then(c=>this.sendInitPage(c)).then(c=>(a&&(this.loadPromiseCache=c),this.loadedPagesCount=1,c)).catch(c=>{throw c instanceof ql&&this.clearLoadPromise(),c});return this.checkLoadPromise(),u}loadAllData(){if(this.isWholeDataLoaded){const t={loadedRowsCount:this.getLoadedElementsCount(),totalItemsCount:typeof this.totalRowsCount=="number"?this.totalRowsCount:this.getTotalItemsCount(),totalRecordsCount:this.totalRecordsCount,limitReached:this.limitReached,dataBars:this.dataBars,rangeMinMax:this.rangeMinMax};return this.columnsCount!==0&&this.totalColumnsCount!==0&&(t.columnsCount=this.columnsCount,t.totalColumnsCount=this.totalColumnsCount),Promise.resolve(t)}return this.loadAllPromise||(this.loadAllPromise=new Promise((t,r)=>{this.loadAllPromiseResolve=t,this.loadAllPromiseReject=r}).then(()=>({loadedRowsCount:this.getLoadedElementsCount(),totalItemsCount:typeof this.totalRowsCount=="number"?this.totalRowsCount:this.getTotalItemsCount(),totalRecordsCount:this.totalRecordsCount,limitReached:this.limitReached,dataBars:this.dataBars,rangeMinMax:this.rangeMinMax})).catch(t=>{throw t instanceof ql&&this.clearLoadAllPromise(),t})),this.loadAllPromise}getSelectedPageData(t,r){return Promise.resolve(this.sendPaginatedPage(t,r))}getIndexedPageData(t,r,n=!1){return Promise.resolve(this.sendPartialPage(t,r,n))}getJaql(){return this.loadService.getJaql()||{metadata:[],grandTotals:null}}isSingleRowTree(){return this.loadService.isSingleRowTree()}setPluginHandlers(t){this.callPlugins=t}setGlobalStyles(t){this.globalStyles=t}getRawJaql(){return this.rawJaql||this.getJaql()}getMetadata(){return this.metadata.length>0?this.metadata:this.getJaql().metadata}preProcessTree(t,r,n){return $o.preProcessTree(t,r,this.getJaql(),n)}postProcessTree(t,r){const n=(a,o,s)=>this.emit(Of,a,o,s,this.options),i=Object.assign(Object.assign({},r||{}),{emitFn:n});return $o.postProcessTree(t,this.getRawJaql(),i)}postProcessData(t,r){const{skipFormatEvent:n=!1,onlyFormatEvents:i=!1}=r||{},a=this.columnsTreeService?this.columnsTreeService.getLastLevelNodes():[],o=ve.getLastLevelNodes(t),s=this.getRawJaql();n||o.forEach(u=>{const c=cn(u);a.forEach(d=>{const h=cn(d),p=ua.getMetadataPanelByIndex(s,h.measureJaqlIndex,Ne.MEASURES);if(typeof c.data!="undefined"&&typeof h.index!="undefined"){const{data:m=[]}=c,{index:g}=h,b=m[g],_=typeof b=="object"&&b!==null&&b!==void 0?b:{value:b};if(m[g]=_,i||!n){const{skipInternalColorFormatting:w=!1}=this.options;w||$o.applyColorFormatting(_,c,h,p),this.emit(Nw,_,c,h,p,s,this.options)}}})})}modifyTree(t,r,n){const i=this.getJaql();return $o.modifyTree(t,r,i,{originalData:n,applyIndexDivergence:this.applyIndexDivergence.bind(this),subtotalsForSingleRow:this.options.subtotalsForSingleRow})}applyIndexDivergence(t){this.divergenceComparator=new h1(t,this.divergenceComparator)}initPluginService(t){this.pluginService=new this.options.PluginService(this.callPlugins,t,this.globalStyles)}cancelLoading(){const t=new ql;this.loadPromiseReject&&typeof this.loadPromiseReject=="function"&&this.loadPromiseReject(t),this.loadAllPromiseReject&&typeof this.loadAllPromiseReject=="function"&&this.loadAllPromiseReject(t),this.detachEvent()}getPageSize(){return this.pageSize}sendInitPage(t){if(this.loadService.hasError()||!this.loadService.hasData())return br.getEmptyPage();let r,n;const i=this.getPageSize();if(this.rowsTreeService){const s=i>t?t:i,u=br.cloneTreeNode,c=this.rowsTreeService.getPartialTree(0,s,{cloneFn:u});this.rowsGrand&&c.push(pr(this.rowsGrand)),this.postProcessTree(c,{onlyFormatEvents:!0,iterateFn:ve.clearNodeCache}),this.postProcessData(c,{onlyFormatEvents:!0});const d=this.rowsTreeService?this.rowsTreeService.getTreeDeepsLength():0,h=ve.wrapInRootNode(c);this.pluginService&&h&&h.children&&(this.pluginService.applyToRows(h.children),n=this.pluginService.metadataCache),r=new gi(h,!0,d),r.hasGrandTotals=!!this.rowsGrand}const a=this.isWholeDataLoaded&&i>=t;return{rowsTreeService:r,columnsTreeService:this.columnsTreeService,cornerTreeService:this.cornerTreeService,isLastPage:a,cellsMetadata:n}}sendPaginatedPage(t,r){if(this.loadService.hasError()||!this.loadService.hasData())return br.getEmptyPage();r&&(this.pageSize=r);const n=this.getPageSize(),i=this.getLoadedElementsCount();if(t*n>=i)throw new Error("Selected page is out of elements range!");if(t<0)throw new Error("Selected page must be >= 0");let a,o;if(this.rowsTreeService){const s=t>=0?t*n:0,u=(t+1)*n>i?i:(t+1)*n,c=br.cloneTreeNode,d=this.rowsTreeService.getPartialTree(s,u,{cloneFn:c});this.rowsGrand&&d.push(pr(this.rowsGrand)),this.postProcessTree(d,{onlyFormatEvents:!0,iterateFn:ve.clearNodeCache}),this.postProcessData(d,{onlyFormatEvents:!0});const h=this.rowsTreeService?this.rowsTreeService.getTreeDeepsLength():0,p=ve.wrapInRootNode(d);this.pluginService&&p&&p.children&&(this.pluginService.applyToRows(p.children),o=this.pluginService.metadataCache),a=new gi(p,!0,h),a.hasGrandTotals=!!this.rowsGrand}return{rowsTreeService:a,columnsTreeService:this.columnsTreeService,cornerTreeService:this.cornerTreeService,isLastPage:!0,cellsMetadata:o}}sendPartialPage(t,r,n){if(this.loadService.hasError()||!this.loadService.hasData())return br.getEmptyPage();const i=this.getLoadedElementsCount();let[a,o]=[Math.min(t,r),Math.max(t,r)];a=a>=0?a:0,o=o>=0?o:0,o=o<i?o:i;let s,u;if(a>i)s=void 0;else{let c;if(this.rowsTreeService){const p=br.cloneTreeNode;c=this.rowsTreeService.getPartialTree(a,o,{cloneFn:p}),n&&this.rowsGrand&&c.push(pr(this.rowsGrand)),this.postProcessTree(c,{onlyFormatEvents:!0,iterateFn:ve.clearNodeCache}),this.postProcessData(c,{onlyFormatEvents:!0})}const d=this.rowsTreeService?this.rowsTreeService.getTreeDeepsLength():0,h=ve.wrapInRootNode(c);this.pluginService&&h&&h.children&&(this.pluginService.applyToRows(h.children),u=this.pluginService.metadataCache),s=new gi(h,!0,d),s.hasGrandTotals=!!(n&&this.rowsGrand)}return{rowsTreeService:s,columnsTreeService:this.columnsTreeService,cornerTreeService:this.cornerTreeService,isLastPage:!0,cellsMetadata:u}}getLoadedElementsCount(){return this.rowsTreeService?this.rowsTreeService.getTreeChildLength():0}getTotalItemsCount(){return this.loadService.getTotalItemsCount()}getLoadedColumnsCount(){return this.columnsTreeService?this.columnsTreeService.getTreeChildLength():0}attachEvent(){this.loadService.listenerCount(De.HEADERS)&&this.loadService.offAll(De.HEADERS),this.loadService.on(De.HEADERS,this.onHeadersHandler),this.loadService.on(De.METADATA,this.onMetadataHandler),this.loadService.on(De.DATA,this.onDataHandler),this.loadService.on(De.GRAND,this.onGrandHandler),this.loadService.on(De.DATA_FINISH,this.onDataFinishHandler),this.loadService.on(De.TOTAL_ROWS,this.onTotalRowsHandler),this.loadService.on(De.DATABARS,this.onDataBarsHandler),this.loadService.on(De.RANGE_MIN_MAX,this.onRangeMinMaxHandler),this.loadService.on(De.FINISH,this.onFinishHandler),this.loadService.on(De.ERROR,this.onErrorHandler)}detachEvent(){this.loadService.off(De.HEADERS,this.onHeadersHandler),this.loadService.off(De.METADATA,this.onMetadataHandler),this.loadService.off(De.DATA,this.onDataHandler),this.loadService.off(De.GRAND,this.onGrandHandler),this.loadService.off(De.DATA_FINISH,this.onDataFinishHandler),this.loadService.off(De.TOTAL_ROWS,this.onTotalRowsHandler),this.loadService.off(De.DATABARS,this.onDataBarsHandler),this.loadService.off(De.RANGE_MIN_MAX,this.onRangeMinMaxHandler),this.loadService.off(De.FINISH,this.onFinishHandler),this.loadService.off(De.ERROR,this.onErrorHandler)}checkLoadPromise(){if(!this.isLoadInProgress)return;const t=this.getLoadedElementsCount();(t>=this.getPageSize()||this.isWholeDataLoaded)&&(this.isLoadInProgress=!1,typeof this.loadPromiseResolve=="function"&&(this.loadPromiseResolve(t),this.clearLoadPromise()))}clearLoadAllPromise(){this.loadAllPromise=void 0,this.loadAllPromiseReject=void 0,this.loadAllPromiseResolve=void 0}clearLoadPromise(){this.loadPromiseReject=void 0,this.loadPromiseResolve=void 0}finishRequest(){this.hasDataFinishEvent=!0,!this.isDataHandlerThrottled&&(this.isWholeDataLoaded=!0,this.loadAllPromiseResolve&&typeof this.loadAllPromiseResolve=="function"&&(this.loadAllPromiseResolve(),this.clearLoadAllPromise()))}clearCache(){this.rowsGrand=void 0,this.rowsTreeService=void 0,this.columnsTreeService=void 0,this.loadedPagesCount=0,this.hasDataFinishEvent=!1,this.isWholeDataLoaded=!1,this.isLoadInProgress=!1,this.tempDataChunks=[],this.lastNotHandledChunkIndex=0,this.lastReadyNotHandledChunkIndex=0,this.isDataHandlerThrottled=!1}static getEmptyPage(){return{isLastPage:!0}}static fillDataChunks(t,r,n=v1,i=v1){const o=t.length<2?n:i;let s=t[Math.max(0,t.length-1)],u,c=!s;if(!r||typeof r.children=="undefined"&&typeof r.value=="undefined"&&r.data&&!r.data.length){s&&(s.ready=!0);return}if(s){const d=Math.max(0,s.list.length-1);u=s.list[d];const h=s.size?`${s.size}`:"0",m=parseInt(h,10)+(r.size||1);(s.handled||m>o&&!(u.isPart&&u.value===r.value))&&(c=!0)}r&&r.isPart&&u&&(!u.isPart||u.value!==r.value)&&(c=!0,u.value!==r.value&&(u=void 0)),c&&(s&&(s.ready=!0),s={list:[],size:0,ready:!1,handled:!1},t.push(s)),s&&(u&&u.isPart&&r&&r.isPart?(ve.deepMerge(u,r),s.size+=r.size||1):(s.list.push(r),s.size+=r.size||1))}static cloneTreeNode(t,r){const n=t,{children:i,isMapped:a,minLevel:o,childCount:s,childDeep:u,parent:c,master:d,data:h,state:p,style:m,store:g}=n,b=P5(n,["children","isMapped","minLevel","childCount","childDeep","parent","master","data","state","style","store"]),_=pr(b);return c&&(_.parent=c),d&&(_.master=d),h&&(_.data=pr(h)),p&&(_.state=pr(p)),m&&(_.style=pr(m)),g&&(_.store=pr(g)),!r&&i&&(_.children=i.map(w=>{const C=br.cloneTreeNode(w);return C.parent=_,C})),_}static createColumnsTreeServiceBuilder(t,r){return n=>{const i=t.getJaql(),a=t.getRawJaql?t.getRawJaql():wh(i,i.metadata||[]),o=ua.getMetadataTree(i,Ne.MEASURES),s=ve.getChildren(o),{preProcessTree:u,modifyTree:c,postProcessTree:d}=$o;let h,p,m=0,g=0;if(ve.hasChildren(n)){n.columnsCount&&n.totalColumnsCount&&(m=n.columnsCount,g=n.totalColumnsCount);const b=u(n,Ne.COLUMNS,i),_=c(b,Ne.COLUMNS,i,{originalData:n,applyIndexDivergence:t.applyIndexDivergence});d(_,a,{emitFn:r&&r.emitHeaderCellFormatEvent});const w=ve.wrapInRootNode(_);t.pluginService&&w&&w.children&&t.pluginService.applyToColumns(w.children),h=w,p=new gi(w),s.length===1&&p.setValueNode(s[0])}else ve.hasChildren(o)?(n.columnsCount&&n.totalColumnsCount&&(m=n.columnsCount,g=n.totalColumnsCount),typeof n.maxChilds=="number"&&(m=n.maxChilds,o.children=ve.getChildren(o).filter((b,_)=>_<n.maxChilds)),t.pluginService&&o.children&&t.pluginService.applyToColumns(o.children),d(ve.getChildren(o),a,{emitFn:r&&r.emitHeaderCellFormatEvent}),h=o,p=new gi(o)):(t.pluginService&&t.pluginService.resetRowStartFrom(),h=void 0,p=void 0,m=0,g=0);return{columnsTree:h,columnsTreeService:p,columnsCount:m,totalColumnsCount:g}}}static createCornerTreeServiceBuilder(t,r){return()=>{const n=t.getJaql(),i=t.getRawJaql?t.getRawJaql():wh(n,n.metadata||[]),a=ua.getMetadataTree(n,Ne.ROWS);let o;if(ve.hasChildren(a)){ve.iterateThroughTree(ve.getChildren(a),u=>{u.userType=Et.CORNER;const c=ua.getMetadataPanelByIndex(i,u.jaqlIndex,u.metadataType||"");r&&r.emitHeaderCellFormatEvent&&r.emitHeaderCellFormatEvent(u,c,i)});let s;t.columnsTreeService&&(s=t.columnsTreeService.getTreeDeepsLength()),t.pluginService&&t.pluginService.applyToHeaders(a),o=new gi(a,!1,s)}return{cornerTree:a,cornerTreeService:o}}}}const Xl={INCLUDE:["metadata.$.jaql","metadata.$.field","metadata.$.panel","metadata.$.hierarchies","metadata.$.format","metadata.$.disabled","metadata.$.distinctTotals"],EXCLUDE:["metadata.$.jaql.title","metadata.$.format.mask","metadata.$.format.width","queryGuid","widget","dashboard","grandTotals.title"]};class z5{constructor(t){this.jaql=void 0,this.data=void 0,this.isLoadInProgress=!1,this.loadPromiseResolve=void 0,this.loadPromiseReject=void 0,this.loadFromCacheState=void 0,this.loadFromCacheInitialTimer=void 0,this.loadFromCacheTimer=void 0,this.isSingleBranchTree=!1,this.loadedItemsCount=0,this.totalItemsCount=0,this.isLimited=!1,this.isFinishEventReceived=!1,this.events=t||new Qm}destroy(){this.data=void 0,this.events.removeAllListeners()}clone(){throw new Error('"AbstractDataLoadService.clone" should be overridden in subclass')}load(t){if(!t)throw new Error('AbstractDataLoadService "jaql" is not defined for "load" method');const r=!!this.data,n=this.jaql;this.jaql=t,r&&n&&(this.jaql.queryGuid=n.queryGuid),this.isLoadInProgress=!0;const i=new Promise((a,o)=>{this.loadPromiseResolve=a,this.loadPromiseReject=o});this.loadFromCacheInitialTimer&&clearTimeout(this.loadFromCacheInitialTimer);try{r?this.loadFromCache():this.loadFromServer()}catch(a){this.notifyAboutDataError(a)}return i}clear(){this.data=void 0}getJaql(){return this.jaql}isSingleRowTree(){return this.isSingleBranchTree}getTotalItemsCount(){return this.totalItemsCount}isFormattingChanges(t){const r=pr(this.jaql,{include:Xl.INCLUDE,exclude:Xl.EXCLUDE,excludeEmpty:!0}),n=pr(t,{include:Xl.INCLUDE,exclude:Xl.EXCLUDE,excludeEmpty:!0});return[...(r==null?void 0:r.metadata)||[],...(n==null?void 0:n.metadata)||[]].forEach(i=>{i&&i.panel===Ne.SCOPE&&delete i.field}),JSON.stringify(r)===JSON.stringify(n)}hasData(){return!!(this.data&&this.data[De.DATA])}hasError(){return this.data?!!this.data[De.ERROR]:!1}loadFromServer(){throw new Error('"AbstractDataLoadService.loadFromServer" should be overridden in subclass')}cancelQuery(){const t=new Error('"AbstractDataLoadService.cancelQuery" should be overridden in subclass.');return Promise.reject(t)}isCancelQueryNeeded(){return!this.isFinishEventReceived}loadFromCache(){return Promise.resolve().then(()=>(this.loadFromCacheInitialTimer&&clearTimeout(this.loadFromCacheInitialTimer),new Promise(t=>{this.loadFromCacheInitialTimer=setTimeout(t)}))).then(()=>new Promise(t=>{this.loadFromCacheTimer&&clearImmediate(this.loadFromCacheTimer),this.loadFromCacheState=void 0,this.loadMessageFromCache(()=>{this.loadFromCacheState=void 0,this.loadFromCacheTimer&&clearImmediate(this.loadFromCacheTimer),t()})}))}loadMessageFromCache(t){this.loadFromCacheState=this.loadFromCacheState||{};const r=this.loadFromCacheState;let n="",i=0;if(qA.forEach(a=>{if(n)return;r[a]=r[a]||0,r[a]<((this.data||{})[a]||[]).length&&(n=a,i=r[a])}),n){const a=((this.data||{})[n]||[])[i];this.notifyAboutDataChunk(n||"",a,!0),r[n]=i+1,this.loadMessageFromCache(t)}else t&&t()}cacheData(t,r){this.data=this.data||{};const n=this.data;n&&(n[t]=n[t]||[],n[t].push(r||!0))}notifyAboutDataChunk(t,r,n=!1){const i=r&&r.data&&t===De.DATA?r.data:r;if(n||this.cacheData(t,r),!n&&this.loadFromCacheState)return;t===De.METADATA&&(this.isSingleBranchTree=!!(i&&i.isSingleBranchTree)),t===De.ERROR&&this.notifyAboutDataError(i),t===De.DATA_FINISH&&(this.loadedItemsCount=i?i.rowsCount:0,this.notifyAboutDataLoaded(this.data)),t===De.TOTAL_ROWS&&(this.totalItemsCount=i?i.rowsCount:0,this.totalItemsCount!==this.loadedItemsCount&&(this.isLimited=!0)),t===De.FINISH&&(this.isFinishEventReceived=!0);const a=pr(i);this.events.emit(t,a)}notifyAboutDataLoaded(t){this.isLoadInProgress&&(this.isLoadInProgress=!1,typeof this.loadPromiseResolve=="function"&&this.loadPromiseResolve(t),this.loadPromiseReject=void 0,this.loadPromiseResolve=void 0)}notifyAboutDataError(t){this.isLoadInProgress&&(this.isLoadInProgress=!1,typeof this.loadPromiseReject=="function"&&this.loadPromiseReject(t),this.loadPromiseReject=void 0,this.loadPromiseResolve=void 0)}on(t,r){this.events.on(t,r)}off(t,r){this.events.removeListener(t,r)}offAll(t){this.events.removeAllListeners(t)}listenerCount(t){return this.events.listenerCount(t)}emit(t,...r){this.events.emit(t,...r)}}class n0 extends z5{constructor(t,r){if(super(r),this.initPromise=void 0,this.isInitInProgress=!1,this.onMessageCancel=void 0,this.onSocketError=n=>{this.emit("error",{error:!0,type:500,details:`Socket error: ${n.message}`})},this.onSocketDisconnect=()=>{this.emit("error",{error:!0,type:500,details:"Socket disconnected"})},!t)throw new Error('DataLoadService "socket" not defined.');this.socket=t,this.socket.on("error",this.onSocketError),this.socket.on("disconnect",this.onSocketDisconnect),this.on(De.ERROR,n=>{const i=JSON.stringify(n,null,4);process.env.NODE_ENV!=="production"&&console.warn(`DataLoadService error message:
4
+ ${i}`)})}destroy(){super.destroy(),this.onMessageCancel&&(this.onMessageCancel(),this.onMessageCancel=void 0),this.socket.off("error",this.onSocketError),this.socket.off("disconnect",this.onSocketDisconnect)}clone(){const t=pr(this.data);t[De.HEADERS]||(t[De.HEADERS]=[{}]);const r=new n0(this.socket);return r.data=t,r.jaql=this.jaql,r.isFinishEventReceived=this.isFinishEventReceived,r.isSingleBranchTree=this.isSingleBranchTree,r.loadedItemsCount=this.loadedItemsCount,r.totalItemsCount=this.totalItemsCount,r.isLimited=this.isLimited,r}loadFromServer(){this.waitForSocketReady().then(()=>{this.onMessageCancel&&this.onMessageCancel(),this.onMessageCancel=this.socket.onMessage(void 0,void 0,(t,r)=>{this.notifyAboutDataChunk(t,r)}),this.socket.send("pivot",this.jaql)})}cancelQuery(){return this.isCancelQueryNeeded()?this.waitForSocketReady().then(()=>{this.socket.send("pivot/cancel-query",{queryGuid:this.jaql&&this.jaql.queryGuid})}):Promise.resolve()}waitForSocketReady(){return this.socket.isReady()?Promise.resolve():this.isInitInProgress&&this.initPromise?this.initPromise:(this.isInitInProgress=!0,this.initPromise=new Promise((t,r)=>{this.socket.on("open",()=>{this.socket&&this.socket.isReady()?t():r(new Error("Can not open WebSocket connection"))})}),this.initPromise)}}class H5 extends n0{constructor(t,r,n={}){super(t,r),this.onMessageCancels=[],this.options=n}destroy(){super.destroy(),this.onMessageCancels.length&&(this.onMessageCancels.forEach(t=>{t&&t()}),this.onMessageCancels.length=0)}loadFromServer(){this.waitForSocketReady().then(()=>{const t=Object.assign({queryGuid:V.v4()},this.jaql),{queryGuid:r}=t;this.onMessageCancels.length&&(this.onMessageCancels.forEach(n=>{n&&n()}),this.onMessageCancels.length=0),Object.values(De).forEach(n=>{const i=this.socket.onMessage(n,r,(a,o)=>{this.notifyAboutDataChunk(a,o)});this.onMessageCancels.push(i)}),this.socket.send("pivot",t)})}waitForSocketReady(){return this.socket.isReady()?Promise.resolve():new Promise(t=>{const{socketRegisterCheckInterval:r=100}=this.options;this.registrationWaitTimer&&clearInterval(this.registrationWaitTimer);const n=()=>{this.socket.isReady()&&(clearInterval(this.registrationWaitTimer),t())};this.registrationWaitTimer=setInterval(n,r)})}}var If={exports:{}},W5=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,j5=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"],kw=function(t){var r=t,n=t.indexOf("["),i=t.indexOf("]");n!=-1&&i!=-1&&(t=t.substring(0,n)+t.substring(n,i).replace(/:/g,";")+t.substring(i,t.length));for(var a=W5.exec(t||""),o={},s=14;s--;)o[j5[s]]=a[s]||"";return n!=-1&&i!=-1&&(o.source=r,o.host=o.host.substring(1,o.host.length-1).replace(/;/g,":"),o.authority=o.authority.replace("[","").replace("]","").replace(/;/g,":"),o.ipv6uri=!0),o.pathNames=V5(o,o.path),o.queryKey=U5(o,o.query),o};function V5(e,t){var r=/\/{2,9}/g,n=t.replace(r,"/").split("/");return(t.substr(0,1)=="/"||t.length===0)&&n.splice(0,1),t.substr(t.length-1,1)=="/"&&n.splice(n.length-1,1),n}function U5(e,t){var r={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(n,i,a){i&&(r[i]=a)}),r}var Ff={exports:{}},$f={exports:{}},ws=1e3,Cs=ws*60,xs=Cs*60,Ts=xs*24,G5=Ts*365.25,q5=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return Y5(e);if(r==="number"&&isNaN(e)===!1)return t.long?Z5(e):X5(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function Y5(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*G5;case"days":case"day":case"d":return r*Ts;case"hours":case"hour":case"hrs":case"hr":case"h":return r*xs;case"minutes":case"minute":case"mins":case"min":case"m":return r*Cs;case"seconds":case"second":case"secs":case"sec":case"s":return r*ws;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function X5(e){return e>=Ts?Math.round(e/Ts)+"d":e>=xs?Math.round(e/xs)+"h":e>=Cs?Math.round(e/Cs)+"m":e>=ws?Math.round(e/ws)+"s":e+"ms"}function Z5(e){return Zl(e,Ts,"day")||Zl(e,xs,"hour")||Zl(e,Cs,"minute")||Zl(e,ws,"second")||e+" ms"}function Zl(e,t,r){if(!(e<t))return e<t*1.5?Math.floor(e/t)+" "+r:Math.ceil(e/t)+" "+r+"s"}(function(e,t){t=e.exports=n.debug=n.default=n,t.coerce=u,t.disable=o,t.enable=a,t.enabled=s,t.humanize=q5,t.instances=[],t.names=[],t.skips=[],t.formatters={};function r(c){var d=0,h;for(h in c)d=(d<<5)-d+c.charCodeAt(h),d|=0;return t.colors[Math.abs(d)%t.colors.length]}function n(c){var d;function h(){if(h.enabled){var p=h,m=+new Date,g=m-(d||m);p.diff=g,p.prev=d,p.curr=m,d=m;for(var b=new Array(arguments.length),_=0;_<b.length;_++)b[_]=arguments[_];b[0]=t.coerce(b[0]),typeof b[0]!="string"&&b.unshift("%O");var w=0;b[0]=b[0].replace(/%([a-zA-Z%])/g,function(S,T){if(S==="%%")return S;w++;var M=t.formatters[T];if(typeof M=="function"){var P=b[w];S=M.call(p,P),b.splice(w,1),w--}return S}),t.formatArgs.call(p,b);var C=h.log||t.log||console.log.bind(console);C.apply(p,b)}}return h.namespace=c,h.enabled=t.enabled(c),h.useColors=t.useColors(),h.color=r(c),h.destroy=i,typeof t.init=="function"&&t.init(h),t.instances.push(h),h}function i(){var c=t.instances.indexOf(this);return c!==-1?(t.instances.splice(c,1),!0):!1}function a(c){t.save(c),t.names=[],t.skips=[];var d,h=(typeof c=="string"?c:"").split(/[\s,]+/),p=h.length;for(d=0;d<p;d++)h[d]&&(c=h[d].replace(/\*/g,".*?"),c[0]==="-"?t.skips.push(new RegExp("^"+c.substr(1)+"$")):t.names.push(new RegExp("^"+c+"$")));for(d=0;d<t.instances.length;d++){var m=t.instances[d];m.enabled=t.enabled(m.namespace)}}function o(){t.enable("")}function s(c){if(c[c.length-1]==="*")return!0;var d,h;for(d=0,h=t.skips.length;d<h;d++)if(t.skips[d].test(c))return!1;for(d=0,h=t.names.length;d<h;d++)if(t.names[d].test(c))return!0;return!1}function u(c){return c instanceof Error?c.stack||c.message:c}})($f,$f.exports);var K5=$f.exports;(function(e,t){t=e.exports=K5,t.log=i,t.formatArgs=n,t.save=a,t.load=o,t.useColors=r,t.storage=typeof chrome!="undefined"&&typeof chrome.storage!="undefined"?chrome.storage.local:s(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function r(){return typeof window!="undefined"&&window.process&&window.process.type==="renderer"?!0:typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}t.formatters.j=function(u){try{return JSON.stringify(u)}catch(c){return"[UnexpectedJSONParseError]: "+c.message}};function n(u){var c=this.useColors;if(u[0]=(c?"%c":"")+this.namespace+(c?" %c":" ")+u[0]+(c?"%c ":" ")+"+"+t.humanize(this.diff),!!c){var d="color: "+this.color;u.splice(1,0,d,"color: inherit");var h=0,p=0;u[0].replace(/%[a-zA-Z%]/g,function(m){m!=="%%"&&(h++,m==="%c"&&(p=h))}),u.splice(p,0,d)}}function i(){return typeof console=="object"&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(u){try{u==null?t.storage.removeItem("debug"):t.storage.debug=u}catch(c){}}function o(){var u;try{u=t.storage.debug}catch(c){}return!u&&typeof process!="undefined"&&"env"in process&&(u=process.env.DEBUG),u}t.enable(o());function s(){try{return window.localStorage}catch(u){}}})(Ff,Ff.exports);var kc=Ff.exports,Q5=kw,y1=kc("socket.io-client:url"),J5=eR;function eR(e,t){var r=e;t=t||typeof location!="undefined"&&location,e==null&&(e=t.protocol+"//"+t.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=t.protocol+e:e=t.host+e),/^(https?|wss?):\/\//.test(e)||(y1("protocol-less url %s",e),typeof t!="undefined"?e=t.protocol+"//"+e:e="https://"+e),y1("parse %s",e),r=Q5(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";var n=r.host.indexOf(":")!==-1,i=n?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+i+":"+r.port,r.href=r.protocol+"://"+i+(t&&t.port===r.port?"":":"+r.port),r}var Lc={},Bf={exports:{}},Ch,b1;function tR(){if(b1)return Ch;b1=1;var e=1e3,t=e*60,r=t*60,n=r*24,i=n*7,a=n*365.25;Ch=function(d,h){h=h||{};var p=typeof d;if(p==="string"&&d.length>0)return o(d);if(p==="number"&&isFinite(d))return h.long?u(d):s(d);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(d))};function o(d){if(d=String(d),!(d.length>100)){var h=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(d);if(h){var p=parseFloat(h[1]),m=(h[2]||"ms").toLowerCase();switch(m){case"years":case"year":case"yrs":case"yr":case"y":return p*a;case"weeks":case"week":case"w":return p*i;case"days":case"day":case"d":return p*n;case"hours":case"hour":case"hrs":case"hr":case"h":return p*r;case"minutes":case"minute":case"mins":case"min":case"m":return p*t;case"seconds":case"second":case"secs":case"sec":case"s":return p*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return p;default:return}}}}function s(d){var h=Math.abs(d);return h>=n?Math.round(d/n)+"d":h>=r?Math.round(d/r)+"h":h>=t?Math.round(d/t)+"m":h>=e?Math.round(d/e)+"s":d+"ms"}function u(d){var h=Math.abs(d);return h>=n?c(d,h,n,"day"):h>=r?c(d,h,r,"hour"):h>=t?c(d,h,t,"minute"):h>=e?c(d,h,e,"second"):d+" ms"}function c(d,h,p,m){var g=h>=p*1.5;return Math.round(d/p)+" "+m+(g?"s":"")}return Ch}function rR(e){r.debug=r,r.default=r,r.coerce=c,r.disable=o,r.enable=a,r.enabled=s,r.humanize=tR(),Object.keys(e).forEach(d=>{r[d]=e[d]}),r.instances=[],r.names=[],r.skips=[],r.formatters={};function t(d){let h=0;for(let p=0;p<d.length;p++)h=(h<<5)-h+d.charCodeAt(p),h|=0;return r.colors[Math.abs(h)%r.colors.length]}r.selectColor=t;function r(d){let h;function p(...m){if(!p.enabled)return;const g=p,b=Number(new Date),_=b-(h||b);g.diff=_,g.prev=h,g.curr=b,h=b,m[0]=r.coerce(m[0]),typeof m[0]!="string"&&m.unshift("%O");let w=0;m[0]=m[0].replace(/%([a-zA-Z%])/g,(S,T)=>{if(S==="%%")return S;w++;const M=r.formatters[T];if(typeof M=="function"){const P=m[w];S=M.call(g,P),m.splice(w,1),w--}return S}),r.formatArgs.call(g,m),(g.log||r.log).apply(g,m)}return p.namespace=d,p.enabled=r.enabled(d),p.useColors=r.useColors(),p.color=t(d),p.destroy=n,p.extend=i,typeof r.init=="function"&&r.init(p),r.instances.push(p),p}function n(){const d=r.instances.indexOf(this);return d!==-1?(r.instances.splice(d,1),!0):!1}function i(d,h){const p=r(this.namespace+(typeof h=="undefined"?":":h)+d);return p.log=this.log,p}function a(d){r.save(d),r.names=[],r.skips=[];let h;const p=(typeof d=="string"?d:"").split(/[\s,]+/),m=p.length;for(h=0;h<m;h++)p[h]&&(d=p[h].replace(/\*/g,".*?"),d[0]==="-"?r.skips.push(new RegExp("^"+d.substr(1)+"$")):r.names.push(new RegExp("^"+d+"$")));for(h=0;h<r.instances.length;h++){const g=r.instances[h];g.enabled=r.enabled(g.namespace)}}function o(){const d=[...r.names.map(u),...r.skips.map(u).map(h=>"-"+h)].join(",");return r.enable(""),d}function s(d){if(d[d.length-1]==="*")return!0;let h,p;for(h=0,p=r.skips.length;h<p;h++)if(r.skips[h].test(d))return!1;for(h=0,p=r.names.length;h<p;h++)if(r.names[h].test(d))return!0;return!1}function u(d){return d.toString().substring(2,d.toString().length-2).replace(/\.\*\?$/,"*")}function c(d){return d instanceof Error?d.stack||d.message:d}return r.enable(r.load()),r}var nR=rR;(function(e,t){t.log=i,t.formatArgs=n,t.save=a,t.load=o,t.useColors=r,t.storage=s(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function r(){return typeof window!="undefined"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs)?!0:typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}function n(c){if(c[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+c[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const d="color: "+this.color;c.splice(1,0,d,"color: inherit");let h=0,p=0;c[0].replace(/%[a-zA-Z%]/g,m=>{m!=="%%"&&(h++,m==="%c"&&(p=h))}),c.splice(p,0,d)}function i(...c){return typeof console=="object"&&console.log&&console.log(...c)}function a(c){try{c?t.storage.setItem("debug",c):t.storage.removeItem("debug")}catch(d){}}function o(){let c;try{c=t.storage.getItem("debug")}catch(d){}return!c&&typeof process!="undefined"&&"env"in process&&(c=process.env.DEBUG),c}function s(){try{return localStorage}catch(c){}}e.exports=nR(t);const{formatters:u}=e.exports;u.j=function(c){try{return JSON.stringify(c)}catch(d){return"[UnexpectedJSONParseError]: "+d.message}}})(Bf,Bf.exports);var iR=Bf.exports,Lw={exports:{}};(function(e){e.exports=t;function t(n){if(n)return r(n)}function r(n){for(var i in t.prototype)n[i]=t.prototype[i];return n}t.prototype.on=t.prototype.addEventListener=function(n,i){return this._callbacks=this._callbacks||{},(this._callbacks["$"+n]=this._callbacks["$"+n]||[]).push(i),this},t.prototype.once=function(n,i){function a(){this.off(n,a),i.apply(this,arguments)}return a.fn=i,this.on(n,a),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(n,i){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var a=this._callbacks["$"+n];if(!a)return this;if(arguments.length==1)return delete this._callbacks["$"+n],this;for(var o,s=0;s<a.length;s++)if(o=a[s],o===i||o.fn===i){a.splice(s,1);break}return this},t.prototype.emit=function(n){this._callbacks=this._callbacks||{};var i=[].slice.call(arguments,1),a=this._callbacks["$"+n];if(a){a=a.slice(0);for(var o=0,s=a.length;o<s;++o)a[o].apply(this,i)}return this},t.prototype.listeners=function(n){return this._callbacks=this._callbacks||{},this._callbacks["$"+n]||[]},t.prototype.hasListeners=function(n){return!!this.listeners(n).length}})(Lw);var aR=Lw.exports,Oc={},oR={}.toString,Ow=Array.isArray||function(e){return oR.call(e)=="[object Array]"},Iw=cR,sR=typeof Buffer=="function"&&typeof Buffer.isBuffer=="function",lR=typeof ArrayBuffer=="function",uR=function(e){return typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer};function cR(e){return sR&&Buffer.isBuffer(e)||lR&&(e instanceof ArrayBuffer||uR(e))}var i0=Ow,Fw=Iw,$w=Object.prototype.toString,dR=typeof Blob=="function"||typeof Blob!="undefined"&&$w.call(Blob)==="[object BlobConstructor]",hR=typeof File=="function"||typeof File!="undefined"&&$w.call(File)==="[object FileConstructor]";Oc.deconstructPacket=function(e){var t=[],r=e.data,n=e;return n.data=zf(r,t),n.attachments=t.length,{packet:n,buffers:t}};function zf(e,t){if(!e)return e;if(Fw(e)){var r={_placeholder:!0,num:t.length};return t.push(e),r}else if(i0(e)){for(var n=new Array(e.length),i=0;i<e.length;i++)n[i]=zf(e[i],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){var n={};for(var a in e)n[a]=zf(e[a],t);return n}return e}Oc.reconstructPacket=function(e,t){return e.data=Hf(e.data,t),e.attachments=void 0,e};function Hf(e,t){if(!e)return e;if(e&&e._placeholder)return t[e.num];if(i0(e))for(var r=0;r<e.length;r++)e[r]=Hf(e[r],t);else if(typeof e=="object")for(var n in e)e[n]=Hf(e[n],t);return e}Oc.removeBlobs=function(e,t){function r(a,o,s){if(!a)return a;if(dR&&a instanceof Blob||hR&&a instanceof File){n++;var u=new FileReader;u.onload=function(){s?s[o]=this.result:i=this.result,--n||t(i)},u.readAsArrayBuffer(a)}else if(i0(a))for(var c=0;c<a.length;c++)r(a[c],c,a);else if(typeof a=="object"&&!Fw(a))for(var d in a)r(a[d],d,a)}var n=0,i=e;r(i),n||t(i)};(function(e){var t=iR("socket.io-parser"),r=aR,n=Oc,i=Ow,a=Iw;e.protocol=4,e.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],e.CONNECT=0,e.DISCONNECT=1,e.EVENT=2,e.ACK=3,e.ERROR=4,e.BINARY_EVENT=5,e.BINARY_ACK=6,e.Encoder=o,e.Decoder=h;function o(){}var s=e.ERROR+'"encode error"';o.prototype.encode=function(_,w){if(t("encoding packet %j",_),e.BINARY_EVENT===_.type||e.BINARY_ACK===_.type)d(_,w);else{var C=u(_);w([C])}};function u(_){var w=""+_.type;if((e.BINARY_EVENT===_.type||e.BINARY_ACK===_.type)&&(w+=_.attachments+"-"),_.nsp&&_.nsp!=="/"&&(w+=_.nsp+","),_.id!=null&&(w+=_.id),_.data!=null){var C=c(_.data);if(C!==!1)w+=C;else return s}return t("encoded %j as %s",_,w),w}function c(_){try{return JSON.stringify(_)}catch(w){return!1}}function d(_,w){function C(S){var T=n.deconstructPacket(S),M=u(T.packet),P=T.buffers;P.unshift(M),w(P)}n.removeBlobs(_,C)}function h(){this.reconstructor=null}r(h.prototype),h.prototype.add=function(_){var w;if(typeof _=="string")w=p(_),e.BINARY_EVENT===w.type||e.BINARY_ACK===w.type?(this.reconstructor=new g(w),this.reconstructor.reconPack.attachments===0&&this.emit("decoded",w)):this.emit("decoded",w);else if(a(_)||_.base64)if(this.reconstructor)w=this.reconstructor.takeBinaryData(_),w&&(this.reconstructor=null,this.emit("decoded",w));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+_)};function p(_){var w=0,C={type:Number(_.charAt(0))};if(e.types[C.type]==null)return b("unknown packet type "+C.type);if(e.BINARY_EVENT===C.type||e.BINARY_ACK===C.type){for(var S=w+1;_.charAt(++w)!=="-"&&w!=_.length;);var T=_.substring(S,w);if(T!=Number(T)||_.charAt(w)!=="-")throw new Error("Illegal attachments");C.attachments=Number(T)}if(_.charAt(w+1)==="/"){for(var S=w+1;++w;){var M=_.charAt(w);if(M===","||w===_.length)break}C.nsp=_.substring(S,w)}else C.nsp="/";var P=_.charAt(w+1);if(P!==""&&Number(P)==P){for(var S=w+1;++w;){var M=_.charAt(w);if(M==null||Number(M)!=M){--w;break}if(w===_.length)break}C.id=Number(_.substring(S,w+1))}if(_.charAt(++w)){var R=m(_.substr(w)),k=R!==!1&&(C.type===e.ERROR||i(R));if(k)C.data=R;else return b("invalid payload")}return t("decoded %s as %j",_,C),C}function m(_){try{return JSON.parse(_)}catch(w){return!1}}h.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()};function g(_){this.reconPack=_,this.buffers=[]}g.prototype.takeBinaryData=function(_){if(this.buffers.push(_),this.buffers.length===this.reconPack.attachments){var w=n.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),w}return null},g.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]};function b(_){return{type:e.ERROR,data:"parser error: "+_}}})(Lc);var a0={exports:{}},Ic={},Wf={exports:{}};try{Wf.exports=typeof XMLHttpRequest!="undefined"&&"withCredentials"in new XMLHttpRequest}catch(e){Wf.exports=!1}var fR=Wf.exports,o0=function(){return typeof self!="undefined"?self:typeof window!="undefined"?window:Function("return this")()}(),pR=fR,mR=o0,s0=function(e){var t=e.xdomain,r=e.xscheme,n=e.enablesXDR;try{if(typeof XMLHttpRequest!="undefined"&&(!t||pR))return new XMLHttpRequest}catch(i){}try{if(typeof XDomainRequest!="undefined"&&!r&&n)return new XDomainRequest}catch(i){}if(!t)try{return new mR[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(i){}},l0={exports:{}},Wi={},gR=Object.keys||function(t){var r=[],n=Object.prototype.hasOwnProperty;for(var i in t)n.call(t,i)&&r.push(i);return r},vR={}.toString,yR=Array.isArray||function(e){return vR.call(e)=="[object Array]"},bR=yR,Bw=Object.prototype.toString,_R=typeof Blob=="function"||typeof Blob!="undefined"&&Bw.call(Blob)==="[object BlobConstructor]",wR=typeof File=="function"||typeof File!="undefined"&&Bw.call(File)==="[object FileConstructor]",zw=Ru;function Ru(e){if(!e||typeof e!="object")return!1;if(bR(e)){for(var t=0,r=e.length;t<r;t++)if(Ru(e[t]))return!0;return!1}if(typeof Buffer=="function"&&Buffer.isBuffer&&Buffer.isBuffer(e)||typeof ArrayBuffer=="function"&&e instanceof ArrayBuffer||_R&&e instanceof Blob||wR&&e instanceof File)return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return Ru(e.toJSON(),!0);for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&Ru(e[n]))return!0;return!1}var CR=function(e,t,r){var n=e.byteLength;if(t=t||0,r=r||n,e.slice)return e.slice(t,r);if(t<0&&(t+=n),r<0&&(r+=n),r>n&&(r=n),t>=n||t>=r||n===0)return new ArrayBuffer(0);for(var i=new Uint8Array(e),a=new Uint8Array(r-t),o=t,s=0;o<r;o++,s++)a[s]=i[o];return a.buffer},xR=TR;function TR(e,t,r){var n=!1;return r=r||SR,i.count=e,e===0?t():i;function i(a,o){if(i.count<=0)throw new Error("after called too many times");--i.count,a?(n=!0,t(a),t=r):i.count===0&&!n&&t(null,o)}}function SR(){}/*! https://mths.be/utf8js v2.1.2 by @mathias */var Gn=String.fromCharCode;function Hw(e){for(var t=[],r=0,n=e.length,i,a;r<n;)i=e.charCodeAt(r++),i>=55296&&i<=56319&&r<n?(a=e.charCodeAt(r++),(a&64512)==56320?t.push(((i&1023)<<10)+(a&1023)+65536):(t.push(i),r--)):t.push(i);return t}function MR(e){for(var t=e.length,r=-1,n,i="";++r<t;)n=e[r],n>65535&&(n-=65536,i+=Gn(n>>>10&1023|55296),n=56320|n&1023),i+=Gn(n);return i}function Ww(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function xh(e,t){return Gn(e>>t&63|128)}function PR(e,t){if(!(e&4294967168))return Gn(e);var r="";return e&4294965248?e&4294901760?e&4292870144||(r=Gn(e>>18&7|240),r+=xh(e,12),r+=xh(e,6)):(Ww(e,t)||(e=65533),r=Gn(e>>12&15|224),r+=xh(e,6)):r=Gn(e>>6&31|192),r+=Gn(e&63|128),r}function ER(e,t){t=t||{};for(var r=t.strict!==!1,n=Hw(e),i=n.length,a=-1,o,s="";++a<i;)o=n[a],s+=PR(o,r);return s}function ca(){if(Xn>=Ku)throw Error("Invalid byte index");var e=Zu[Xn]&255;if(Xn++,(e&192)==128)return e&63;throw Error("Invalid continuation byte")}function AR(e){var t,r,n,i,a;if(Xn>Ku)throw Error("Invalid byte index");if(Xn==Ku)return!1;if(t=Zu[Xn]&255,Xn++,!(t&128))return t;if((t&224)==192){if(r=ca(),a=(t&31)<<6|r,a>=128)return a;throw Error("Invalid continuation byte")}if((t&240)==224){if(r=ca(),n=ca(),a=(t&15)<<12|r<<6|n,a>=2048)return Ww(a,e)?a:65533;throw Error("Invalid continuation byte")}if((t&248)==240&&(r=ca(),n=ca(),i=ca(),a=(t&7)<<18|r<<12|n<<6|i,a>=65536&&a<=1114111))return a;throw Error("Invalid UTF-8 detected")}var Zu,Ku,Xn;function RR(e,t){t=t||{};var r=t.strict!==!1;Zu=Hw(e),Ku=Zu.length,Xn=0;for(var n=[],i;(i=AR(r))!==!1;)n.push(i);return MR(n)}var DR={version:"2.1.2",encode:ER,decode:RR},Kl={},_1;function NR(){return _1||(_1=1,function(e){Kl.encode=function(t){var r=new Uint8Array(t),n,i=r.length,a="";for(n=0;n<i;n+=3)a+=e[r[n]>>2],a+=e[(r[n]&3)<<4|r[n+1]>>4],a+=e[(r[n+1]&15)<<2|r[n+2]>>6],a+=e[r[n+2]&63];return i%3===2?a=a.substring(0,a.length-1)+"=":i%3===1&&(a=a.substring(0,a.length-2)+"=="),a},Kl.decode=function(t){var r=t.length*.75,n=t.length,i,a=0,o,s,u,c;t[t.length-1]==="="&&(r--,t[t.length-2]==="="&&r--);var d=new ArrayBuffer(r),h=new Uint8Array(d);for(i=0;i<n;i+=4)o=e.indexOf(t[i]),s=e.indexOf(t[i+1]),u=e.indexOf(t[i+2]),c=e.indexOf(t[i+3]),h[a++]=o<<2|s>>4,h[a++]=(s&15)<<4|u>>2,h[a++]=(u&3)<<6|c&63;return d}}("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/")),Kl}var Th,w1;function kR(){if(w1)return Th;w1=1;var e=typeof e!="undefined"?e:typeof WebKitBlobBuilder!="undefined"?WebKitBlobBuilder:typeof MSBlobBuilder!="undefined"?MSBlobBuilder:typeof MozBlobBuilder!="undefined"?MozBlobBuilder:!1,t=function(){try{var s=new Blob(["hi"]);return s.size===2}catch(u){return!1}}(),r=t&&function(){try{var s=new Blob([new Uint8Array([1,2])]);return s.size===2}catch(u){return!1}}(),n=e&&e.prototype.append&&e.prototype.getBlob;function i(s){return s.map(function(u){if(u.buffer instanceof ArrayBuffer){var c=u.buffer;if(u.byteLength!==c.byteLength){var d=new Uint8Array(u.byteLength);d.set(new Uint8Array(c,u.byteOffset,u.byteLength)),c=d.buffer}return c}return u})}function a(s,u){u=u||{};var c=new e;return i(s).forEach(function(d){c.append(d)}),u.type?c.getBlob(u.type):c.getBlob()}function o(s,u){return new Blob(i(s),u||{})}return typeof Blob!="undefined"&&(a.prototype=Blob.prototype,o.prototype=Blob.prototype),Th=function(){return t?r?Blob:o:n?a:void 0}(),Th}(function(e){var t=gR,r=zw,n=CR,i=xR,a=DR,o;typeof ArrayBuffer!="undefined"&&(o=NR());var s=typeof navigator!="undefined"&&/Android/i.test(navigator.userAgent),u=typeof navigator!="undefined"&&/PhantomJS/i.test(navigator.userAgent),c=s||u;e.protocol=3;var d=e.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},h=t(d),p={type:"error",data:"parser error"},m=kR();e.encodePacket=function(T,M,P,R){typeof M=="function"&&(R=M,M=!1),typeof P=="function"&&(R=P,P=null);var k=T.data===void 0?void 0:T.data.buffer||T.data;if(typeof ArrayBuffer!="undefined"&&k instanceof ArrayBuffer)return b(T,M,R);if(typeof m!="undefined"&&k instanceof m)return w(T,M,R);if(k&&k.base64)return g(T,R);var I=d[T.type];return T.data!==void 0&&(I+=P?a.encode(String(T.data),{strict:!1}):String(T.data)),R(""+I)};function g(T,M){var P="b"+e.packets[T.type]+T.data.data;return M(P)}function b(T,M,P){if(!M)return e.encodeBase64Packet(T,P);var R=T.data,k=new Uint8Array(R),I=new Uint8Array(1+R.byteLength);I[0]=d[T.type];for(var $=0;$<k.length;$++)I[$+1]=k[$];return P(I.buffer)}function _(T,M,P){if(!M)return e.encodeBase64Packet(T,P);var R=new FileReader;return R.onload=function(){e.encodePacket({type:T.type,data:R.result},M,!0,P)},R.readAsArrayBuffer(T.data)}function w(T,M,P){if(!M)return e.encodeBase64Packet(T,P);if(c)return _(T,M,P);var R=new Uint8Array(1);R[0]=d[T.type];var k=new m([R.buffer,T.data]);return P(k)}e.encodeBase64Packet=function(T,M){var P="b"+e.packets[T.type];if(typeof m!="undefined"&&T.data instanceof m){var R=new FileReader;return R.onload=function(){var Y=R.result.split(",")[1];M(P+Y)},R.readAsDataURL(T.data)}var k;try{k=String.fromCharCode.apply(null,new Uint8Array(T.data))}catch(Y){for(var I=new Uint8Array(T.data),$=new Array(I.length),G=0;G<I.length;G++)$[G]=I[G];k=String.fromCharCode.apply(null,$)}return P+=btoa(k),M(P)},e.decodePacket=function(T,M,P){if(T===void 0)return p;if(typeof T=="string"){if(T.charAt(0)==="b")return e.decodeBase64Packet(T.substr(1),M);if(P&&(T=C(T),T===!1))return p;var k=T.charAt(0);return Number(k)!=k||!h[k]?p:T.length>1?{type:h[k],data:T.substring(1)}:{type:h[k]}}var R=new Uint8Array(T),k=R[0],I=n(T,1);return m&&M==="blob"&&(I=new m([I])),{type:h[k],data:I}};function C(T){try{T=a.decode(T,{strict:!1})}catch(M){return!1}return T}e.decodeBase64Packet=function(T,M){var P=h[T.charAt(0)];if(!o)return{type:P,data:{base64:!0,data:T.substr(1)}};var R=o.decode(T.substr(1));return M==="blob"&&m&&(R=new m([R])),{type:P,data:R}},e.encodePayload=function(T,M,P){typeof M=="function"&&(P=M,M=null);var R=r(T);if(M&&R)return m&&!c?e.encodePayloadAsBlob(T,P):e.encodePayloadAsArrayBuffer(T,P);if(!T.length)return P("0:");function k($){return $.length+":"+$}function I($,G){e.encodePacket($,R?M:!1,!1,function(Y){G(null,k(Y))})}S(T,I,function($,G){return P(G.join(""))})};function S(T,M,P){for(var R=new Array(T.length),k=i(T.length,P),I=function(G,Y,B){M(Y,function(X,U){R[G]=U,B(X,R)})},$=0;$<T.length;$++)I($,T[$],k)}e.decodePayload=function(T,M,P){if(typeof T!="string")return e.decodePayloadAsBinary(T,M,P);typeof M=="function"&&(P=M,M=null);var R;if(T==="")return P(p,0,1);for(var k="",I,$,G=0,Y=T.length;G<Y;G++){var B=T.charAt(G);if(B!==":"){k+=B;continue}if(k===""||k!=(I=Number(k))||($=T.substr(G+1,I),k!=$.length))return P(p,0,1);if($.length){if(R=e.decodePacket($,M,!1),p.type===R.type&&p.data===R.data)return P(p,0,1);var X=P(R,G+I,Y);if(X===!1)return}G+=I,k=""}if(k!=="")return P(p,0,1)},e.encodePayloadAsArrayBuffer=function(T,M){if(!T.length)return M(new ArrayBuffer(0));function P(R,k){e.encodePacket(R,!0,!0,function(I){return k(null,I)})}S(T,P,function(R,k){var I=k.reduce(function(Y,B){var X;return typeof B=="string"?X=B.length:X=B.byteLength,Y+X.toString().length+X+2},0),$=new Uint8Array(I),G=0;return k.forEach(function(Y){var B=typeof Y=="string",X=Y;if(B){for(var W=new Uint8Array(Y.length),U=0;U<Y.length;U++)W[U]=Y.charCodeAt(U);X=W.buffer}B?$[G++]=0:$[G++]=1;for(var Q=X.byteLength.toString(),U=0;U<Q.length;U++)$[G++]=parseInt(Q[U]);$[G++]=255;for(var W=new Uint8Array(X),U=0;U<W.length;U++)$[G++]=W[U]}),M($.buffer)})},e.encodePayloadAsBlob=function(T,M){function P(R,k){e.encodePacket(R,!0,!0,function(I){var $=new Uint8Array(1);if($[0]=1,typeof I=="string"){for(var G=new Uint8Array(I.length),Y=0;Y<I.length;Y++)G[Y]=I.charCodeAt(Y);I=G.buffer,$[0]=0}for(var B=I instanceof ArrayBuffer?I.byteLength:I.size,X=B.toString(),U=new Uint8Array(X.length+1),Y=0;Y<X.length;Y++)U[Y]=parseInt(X[Y]);if(U[X.length]=255,m){var Q=new m([$.buffer,U.buffer,I]);k(null,Q)}})}S(T,P,function(R,k){return M(new m(k))})},e.decodePayloadAsBinary=function(T,M,P){typeof M=="function"&&(P=M,M=null);for(var R=T,k=[];R.byteLength>0;){for(var I=new Uint8Array(R),$=I[0]===0,G="",Y=1;I[Y]!==255;Y++){if(G.length>310)return P(p,0,1);G+=I[Y]}R=n(R,2+G.length),G=parseInt(G);var B=n(R,0,G);if($)try{B=String.fromCharCode.apply(null,new Uint8Array(B))}catch(Q){var X=new Uint8Array(B);B="";for(var Y=0;Y<X.length;Y++)B+=String.fromCharCode(X[Y])}k.push(B),R=n(R,G)}var U=k.length;k.forEach(function(Q,W){P(e.decodePacket(Q,M,!0),W,U)})}})(Wi);var jw={exports:{}};(function(e){e.exports=t;function t(n){if(n)return r(n)}function r(n){for(var i in t.prototype)n[i]=t.prototype[i];return n}t.prototype.on=t.prototype.addEventListener=function(n,i){return this._callbacks=this._callbacks||{},(this._callbacks["$"+n]=this._callbacks["$"+n]||[]).push(i),this},t.prototype.once=function(n,i){function a(){this.off(n,a),i.apply(this,arguments)}return a.fn=i,this.on(n,a),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(n,i){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var a=this._callbacks["$"+n];if(!a)return this;if(arguments.length==1)return delete this._callbacks["$"+n],this;for(var o,s=0;s<a.length;s++)if(o=a[s],o===i||o.fn===i){a.splice(s,1);break}return a.length===0&&delete this._callbacks["$"+n],this},t.prototype.emit=function(n){this._callbacks=this._callbacks||{};for(var i=new Array(arguments.length-1),a=this._callbacks["$"+n],o=1;o<arguments.length;o++)i[o-1]=arguments[o];if(a){a=a.slice(0);for(var o=0,s=a.length;o<s;++o)a[o].apply(this,i)}return this},t.prototype.listeners=function(n){return this._callbacks=this._callbacks||{},this._callbacks["$"+n]||[]},t.prototype.hasListeners=function(n){return!!this.listeners(n).length}})(jw);var Xs=jw.exports,Sh,C1;function u0(){if(C1)return Sh;C1=1;var e=Wi,t=Xs;Sh=r;function r(n){this.path=n.path,this.hostname=n.hostname,this.port=n.port,this.secure=n.secure,this.query=n.query,this.timestampParam=n.timestampParam,this.timestampRequests=n.timestampRequests,this.readyState="",this.agent=n.agent||!1,this.socket=n.socket,this.enablesXDR=n.enablesXDR,this.withCredentials=n.withCredentials,this.pfx=n.pfx,this.key=n.key,this.passphrase=n.passphrase,this.cert=n.cert,this.ca=n.ca,this.ciphers=n.ciphers,this.rejectUnauthorized=n.rejectUnauthorized,this.forceNode=n.forceNode,this.isReactNative=n.isReactNative,this.extraHeaders=n.extraHeaders,this.localAddress=n.localAddress}return t(r.prototype),r.prototype.onError=function(n,i){var a=new Error(n);return a.type="TransportError",a.description=i,this.emit("error",a),this},r.prototype.open=function(){return(this.readyState==="closed"||this.readyState==="")&&(this.readyState="opening",this.doOpen()),this},r.prototype.close=function(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this},r.prototype.send=function(n){if(this.readyState==="open")this.write(n);else throw new Error("Transport not open")},r.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},r.prototype.onData=function(n){var i=e.decodePacket(n,this.socket.binaryType);this.onPacket(i)},r.prototype.onPacket=function(n){this.emit("packet",n)},r.prototype.onClose=function(){this.readyState="closed",this.emit("close")},Sh}var Ja={};Ja.encode=function(e){var t="";for(var r in e)e.hasOwnProperty(r)&&(t.length&&(t+="&"),t+=encodeURIComponent(r)+"="+encodeURIComponent(e[r]));return t};Ja.decode=function(e){for(var t={},r=e.split("&"),n=0,i=r.length;n<i;n++){var a=r[n].split("=");t[decodeURIComponent(a[0])]=decodeURIComponent(a[1])}return t};var Fc=function(e,t){var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e},Vw="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),Qu=64,Uw={},x1=0,Zn=0,T1;function jf(e){var t="";do t=Vw[e%Qu]+t,e=Math.floor(e/Qu);while(e>0);return t}function LR(e){var t=0;for(Zn=0;Zn<e.length;Zn++)t=t*Qu+Uw[e.charAt(Zn)];return t}function c0(){var e=jf(+new Date);return e!==T1?(x1=0,T1=e):e+"."+jf(x1++)}for(;Zn<Qu;Zn++)Uw[Vw[Zn]]=Zn;c0.encode=jf;c0.decode=LR;var Gw=c0,Vf={exports:{}},Uf={exports:{}},Ss=1e3,Ms=Ss*60,Ps=Ms*60,Es=Ps*24,OR=Es*365.25,IR=function(e,t){t=t||{};var r=typeof e;if(r==="string"&&e.length>0)return FR(e);if(r==="number"&&isNaN(e)===!1)return t.long?BR(e):$R(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function FR(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var r=parseFloat(t[1]),n=(t[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return r*OR;case"days":case"day":case"d":return r*Es;case"hours":case"hour":case"hrs":case"hr":case"h":return r*Ps;case"minutes":case"minute":case"mins":case"min":case"m":return r*Ms;case"seconds":case"second":case"secs":case"sec":case"s":return r*Ss;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}function $R(e){return e>=Es?Math.round(e/Es)+"d":e>=Ps?Math.round(e/Ps)+"h":e>=Ms?Math.round(e/Ms)+"m":e>=Ss?Math.round(e/Ss)+"s":e+"ms"}function BR(e){return Ql(e,Es,"day")||Ql(e,Ps,"hour")||Ql(e,Ms,"minute")||Ql(e,Ss,"second")||e+" ms"}function Ql(e,t,r){if(!(e<t))return e<t*1.5?Math.floor(e/t)+" "+r:Math.ceil(e/t)+" "+r+"s"}(function(e,t){t=e.exports=n.debug=n.default=n,t.coerce=u,t.disable=o,t.enable=a,t.enabled=s,t.humanize=IR,t.instances=[],t.names=[],t.skips=[],t.formatters={};function r(c){var d=0,h;for(h in c)d=(d<<5)-d+c.charCodeAt(h),d|=0;return t.colors[Math.abs(d)%t.colors.length]}function n(c){var d;function h(){if(h.enabled){var p=h,m=+new Date,g=m-(d||m);p.diff=g,p.prev=d,p.curr=m,d=m;for(var b=new Array(arguments.length),_=0;_<b.length;_++)b[_]=arguments[_];b[0]=t.coerce(b[0]),typeof b[0]!="string"&&b.unshift("%O");var w=0;b[0]=b[0].replace(/%([a-zA-Z%])/g,function(S,T){if(S==="%%")return S;w++;var M=t.formatters[T];if(typeof M=="function"){var P=b[w];S=M.call(p,P),b.splice(w,1),w--}return S}),t.formatArgs.call(p,b);var C=h.log||t.log||console.log.bind(console);C.apply(p,b)}}return h.namespace=c,h.enabled=t.enabled(c),h.useColors=t.useColors(),h.color=r(c),h.destroy=i,typeof t.init=="function"&&t.init(h),t.instances.push(h),h}function i(){var c=t.instances.indexOf(this);return c!==-1?(t.instances.splice(c,1),!0):!1}function a(c){t.save(c),t.names=[],t.skips=[];var d,h=(typeof c=="string"?c:"").split(/[\s,]+/),p=h.length;for(d=0;d<p;d++)h[d]&&(c=h[d].replace(/\*/g,".*?"),c[0]==="-"?t.skips.push(new RegExp("^"+c.substr(1)+"$")):t.names.push(new RegExp("^"+c+"$")));for(d=0;d<t.instances.length;d++){var m=t.instances[d];m.enabled=t.enabled(m.namespace)}}function o(){t.enable("")}function s(c){if(c[c.length-1]==="*")return!0;var d,h;for(d=0,h=t.skips.length;d<h;d++)if(t.skips[d].test(c))return!1;for(d=0,h=t.names.length;d<h;d++)if(t.names[d].test(c))return!0;return!1}function u(c){return c instanceof Error?c.stack||c.message:c}})(Uf,Uf.exports);var zR=Uf.exports;(function(e,t){t=e.exports=zR,t.log=i,t.formatArgs=n,t.save=a,t.load=o,t.useColors=r,t.storage=typeof chrome!="undefined"&&typeof chrome.storage!="undefined"?chrome.storage.local:s(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function r(){return typeof window!="undefined"&&window.process&&window.process.type==="renderer"?!0:typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)?!1:typeof document!="undefined"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window!="undefined"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||typeof navigator!="undefined"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}t.formatters.j=function(u){try{return JSON.stringify(u)}catch(c){return"[UnexpectedJSONParseError]: "+c.message}};function n(u){var c=this.useColors;if(u[0]=(c?"%c":"")+this.namespace+(c?" %c":" ")+u[0]+(c?"%c ":" ")+"+"+t.humanize(this.diff),!!c){var d="color: "+this.color;u.splice(1,0,d,"color: inherit");var h=0,p=0;u[0].replace(/%[a-zA-Z%]/g,function(m){m!=="%%"&&(h++,m==="%c"&&(p=h))}),u.splice(p,0,d)}}function i(){return typeof console=="object"&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(u){try{u==null?t.storage.removeItem("debug"):t.storage.debug=u}catch(c){}}function o(){var u;try{u=t.storage.debug}catch(c){}return!u&&typeof process!="undefined"&&"env"in process&&(u=process.env.DEBUG),u}t.enable(o());function s(){try{return window.localStorage}catch(u){}}})(Vf,Vf.exports);var $c=Vf.exports,qw=u0(),HR=Ja,Yw=Wi,WR=Fc,jR=Gw,jr=$c("engine.io-client:polling"),Xw=yn,VR=function(){var e=s0,t=new e({xdomain:!1});return t.responseType!=null}();function yn(e){var t=e&&e.forceBase64;(!VR||t)&&(this.supportsBinary=!1),qw.call(this,e)}WR(yn,qw);yn.prototype.name="polling";yn.prototype.doOpen=function(){this.poll()};yn.prototype.pause=function(e){var t=this;this.readyState="pausing";function r(){jr("paused"),t.readyState="paused",e()}if(this.polling||!this.writable){var n=0;this.polling&&(jr("we are currently polling - waiting to pause"),n++,this.once("pollComplete",function(){jr("pre-pause polling complete"),--n||r()})),this.writable||(jr("we are currently writing - waiting to pause"),n++,this.once("drain",function(){jr("pre-pause writing complete"),--n||r()}))}else r()};yn.prototype.poll=function(){jr("polling"),this.polling=!0,this.doPoll(),this.emit("poll")};yn.prototype.onData=function(e){var t=this;jr("polling got data %s",e);var r=function(n,i,a){if(t.readyState==="opening"&&n.type==="open"&&t.onOpen(),n.type==="close")return t.onClose(),!1;t.onPacket(n)};Yw.decodePayload(e,this.socket.binaryType,r),this.readyState!=="closed"&&(this.polling=!1,this.emit("pollComplete"),this.readyState==="open"?this.poll():jr('ignoring poll - transport state "%s"',this.readyState))};yn.prototype.doClose=function(){var e=this;function t(){jr("writing close packet"),e.write([{type:"close"}])}this.readyState==="open"?(jr("transport open - closing"),t()):(jr("transport not open - deferring close"),this.once("open",t))};yn.prototype.write=function(e){var t=this;this.writable=!1;var r=function(){t.writable=!0,t.emit("drain")};Yw.encodePayload(e,this.supportsBinary,function(n){t.doWrite(n,r)})};yn.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",r="";this.timestampRequests!==!1&&(e[this.timestampParam]=jR()),!this.supportsBinary&&!e.sid&&(e.b64=1),e=HR.encode(e),this.port&&(t==="https"&&Number(this.port)!==443||t==="http"&&Number(this.port)!==80)&&(r=":"+this.port),e.length&&(e="?"+e);var n=this.hostname.indexOf(":")!==-1;return t+"://"+(n?"["+this.hostname+"]":this.hostname)+r+this.path+e};var UR=s0,Zw=Xw,GR=Xs,qR=Fc,Gf=$c("engine.io-client:polling-xhr"),YR=o0;l0.exports=eo;l0.exports.Request=At;function S1(){}function eo(e){if(Zw.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,typeof location!="undefined"){var t=location.protocol==="https:",r=location.port;r||(r=t?443:80),this.xd=typeof location!="undefined"&&e.hostname!==location.hostname||r!==e.port,this.xs=e.secure!==t}}qR(eo,Zw);eo.prototype.supportsBinary=!0;eo.prototype.request=function(e){return e=e||{},e.uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.withCredentials=this.withCredentials,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new At(e)};eo.prototype.doWrite=function(e,t){var r=typeof e!="string"&&e!==void 0,n=this.request({method:"POST",data:e,isBinary:r}),i=this;n.on("success",t),n.on("error",function(a){i.onError("xhr post error",a)}),this.sendXhr=n};eo.prototype.doPoll=function(){Gf("xhr poll");var e=this.request(),t=this;e.on("data",function(r){t.onData(r)}),e.on("error",function(r){t.onError("xhr poll error",r)}),this.pollXhr=e};function At(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=e.async!==!1,this.data=e.data!==void 0?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.withCredentials=e.withCredentials,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}GR(At.prototype);At.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var t=this.xhr=new UR(e),r=this;try{Gf("xhr open %s: %s",this.method,this.uri),t.open(this.method,this.uri,this.async);try{if(this.extraHeaders){t.setDisableHeaderCheck&&t.setDisableHeaderCheck(!0);for(var n in this.extraHeaders)this.extraHeaders.hasOwnProperty(n)&&t.setRequestHeader(n,this.extraHeaders[n])}}catch(i){}if(this.method==="POST")try{this.isBinary?t.setRequestHeader("Content-type","application/octet-stream"):t.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(i){}try{t.setRequestHeader("Accept","*/*")}catch(i){}"withCredentials"in t&&(t.withCredentials=this.withCredentials),this.requestTimeout&&(t.timeout=this.requestTimeout),this.hasXDR()?(t.onload=function(){r.onLoad()},t.onerror=function(){r.onError(t.responseText)}):t.onreadystatechange=function(){if(t.readyState===2)try{var i=t.getResponseHeader("Content-Type");(r.supportsBinary&&i==="application/octet-stream"||i==="application/octet-stream; charset=UTF-8")&&(t.responseType="arraybuffer")}catch(a){}t.readyState===4&&(t.status===200||t.status===1223?r.onLoad():setTimeout(function(){r.onError(typeof t.status=="number"?t.status:0)},0))},Gf("xhr data %s",this.data),t.send(this.data)}catch(i){setTimeout(function(){r.onError(i)},0);return}typeof document!="undefined"&&(this.index=At.requestsCount++,At.requests[this.index]=this)};At.prototype.onSuccess=function(){this.emit("success"),this.cleanup()};At.prototype.onData=function(e){this.emit("data",e),this.onSuccess()};At.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)};At.prototype.cleanup=function(e){if(!(typeof this.xhr=="undefined"||this.xhr===null)){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=S1:this.xhr.onreadystatechange=S1,e)try{this.xhr.abort()}catch(t){}typeof document!="undefined"&&delete At.requests[this.index],this.xhr=null}};At.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(r){}t==="application/octet-stream"||t==="application/octet-stream; charset=UTF-8"?e=this.xhr.response||this.xhr.responseText:e=this.xhr.responseText}catch(r){this.onError(r)}e!=null&&this.onData(e)};At.prototype.hasXDR=function(){return typeof XDomainRequest!="undefined"&&!this.xs&&this.enablesXDR};At.prototype.abort=function(){this.cleanup()};At.requestsCount=0;At.requests={};if(typeof document!="undefined"){if(typeof attachEvent=="function")attachEvent("onunload",M1);else if(typeof addEventListener=="function"){var XR="onpagehide"in YR?"pagehide":"unload";addEventListener(XR,M1,!1)}}function M1(){for(var e in At.requests)At.requests.hasOwnProperty(e)&&At.requests[e].abort()}var ZR=l0.exports,d0=Xw,KR=Fc,P1=o0,QR=to,JR=/\n/g,e6=/\\n/g,Jl;function t6(){}function to(e){d0.call(this,e),this.query=this.query||{},Jl||(Jl=P1.___eio=P1.___eio||[]),this.index=Jl.length;var t=this;Jl.push(function(r){t.onData(r)}),this.query.j=this.index,typeof addEventListener=="function"&&addEventListener("beforeunload",function(){t.script&&(t.script.onerror=t6)},!1)}KR(to,d0);to.prototype.supportsBinary=!1;to.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),d0.prototype.doClose.call(this)};to.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(i){e.onError("jsonp poll error",i)};var r=document.getElementsByTagName("script")[0];r?r.parentNode.insertBefore(t,r):(document.head||document.body).appendChild(t),this.script=t;var n=typeof navigator!="undefined"&&/gecko/i.test(navigator.userAgent);n&&setTimeout(function(){var i=document.createElement("iframe");document.body.appendChild(i),document.body.removeChild(i)},100)};to.prototype.doWrite=function(e,t){var r=this;if(!this.form){var n=document.createElement("form"),i=document.createElement("textarea"),a=this.iframeId="eio_iframe_"+this.index,o;n.className="socketio",n.style.position="absolute",n.style.top="-1000px",n.style.left="-1000px",n.target=a,n.method="POST",n.setAttribute("accept-charset","utf-8"),i.name="d",n.appendChild(i),document.body.appendChild(n),this.form=n,this.area=i}this.form.action=this.uri();function s(){u(),t()}function u(){if(r.iframe)try{r.form.removeChild(r.iframe)}catch(d){r.onError("jsonp polling iframe removal error",d)}try{var c='<iframe src="javascript:0" name="'+r.iframeId+'">';o=document.createElement(c)}catch(d){o=document.createElement("iframe"),o.name=r.iframeId,o.src="javascript:0"}o.id=r.iframeId,r.form.appendChild(o),r.iframe=o}u(),e=e.replace(e6,`\\
5
+ `),this.area.value=e.replace(JR,"\\n");try{this.form.submit()}catch(c){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){r.iframe.readyState==="complete"&&s()}:this.iframe.onload=s};const r6={},n6=Object.freeze(Object.defineProperty({__proto__:null,default:r6},Symbol.toStringTag,{value:"Module"})),i6=O.getAugmentedNamespace(n6);var h0=u0(),a6=Wi,o6=Ja,s6=Fc,l6=Gw,u6=$c("engine.io-client:websocket"),Ju,f0;typeof WebSocket!="undefined"?Ju=WebSocket:typeof self!="undefined"&&(Ju=self.WebSocket||self.MozWebSocket);if(typeof window=="undefined")try{f0=i6}catch(e){}var Oa=Ju||f0,c6=Or;function Or(e){var t=e&&e.forceBase64;t&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=Ju&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(Oa=f0),h0.call(this,e)}s6(Or,h0);Or.prototype.name="websocket";Or.prototype.supportsBinary=!0;Or.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,r={};this.isReactNative||(r.agent=this.agent,r.perMessageDeflate=this.perMessageDeflate,r.pfx=this.pfx,r.key=this.key,r.passphrase=this.passphrase,r.cert=this.cert,r.ca=this.ca,r.ciphers=this.ciphers,r.rejectUnauthorized=this.rejectUnauthorized),this.extraHeaders&&(r.headers=this.extraHeaders),this.localAddress&&(r.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?t?new Oa(e,t):new Oa(e):new Oa(e,t,r)}catch(n){return this.emit("error",n)}this.ws.binaryType===void 0&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}};Or.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}};Or.prototype.write=function(e){var t=this;this.writable=!1;for(var r=e.length,n=0,i=r;n<i;n++)(function(o){a6.encodePacket(o,t.supportsBinary,function(s){if(!t.usingBrowserWebSocket){var u={};if(o.options&&(u.compress=o.options.compress),t.perMessageDeflate){var c=typeof s=="string"?Buffer.byteLength(s):s.length;c<t.perMessageDeflate.threshold&&(u.compress=!1)}}try{t.usingBrowserWebSocket?t.ws.send(s):t.ws.send(s,u)}catch(d){u6("websocket closed before onclose event")}--r||a()})})(e[n]);function a(){t.emit("flush"),setTimeout(function(){t.writable=!0,t.emit("drain")},0)}};Or.prototype.onClose=function(){h0.prototype.onClose.call(this)};Or.prototype.doClose=function(){typeof this.ws!="undefined"&&this.ws.close()};Or.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",r="";this.port&&(t==="wss"&&Number(this.port)!==443||t==="ws"&&Number(this.port)!==80)&&(r=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=l6()),this.supportsBinary||(e.b64=1),e=o6.encode(e),e.length&&(e="?"+e);var n=this.hostname.indexOf(":")!==-1;return t+"://"+(n?"["+this.hostname+"]":this.hostname)+r+this.path+e};Or.prototype.check=function(){return!!Oa&&!("__initialize"in Oa&&this.name===Or.prototype.name)};var d6=s0,h6=ZR,f6=QR,p6=c6;Ic.polling=m6;Ic.websocket=p6;function m6(e){var t,r=!1,n=!1,i=e.jsonp!==!1;if(typeof location!="undefined"){var a=location.protocol==="https:",o=location.port;o||(o=a?443:80),r=e.hostname!==location.hostname||o!==e.port,n=e.secure!==a}if(e.xdomain=r,e.xscheme=n,t=new d6(e),"open"in t&&!e.forceJSONP)return new h6(e);if(!i)throw new Error("JSONP disabled");return new f6(e)}var g6=[].indexOf,Kw=function(e,t){if(g6)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1},v6=Ic,y6=Xs,xt=$c("engine.io-client:socket"),b6=Kw,Qw=Wi,E1=kw,_6=Ja,w6=ze;function ze(e,t){if(!(this instanceof ze))return new ze(e,t);t=t||{},e&&typeof e=="object"&&(t=e,e=null),e?(e=E1(e),t.hostname=e.host,t.secure=e.protocol==="https"||e.protocol==="wss",t.port=e.port,e.query&&(t.query=e.query)):t.host&&(t.hostname=E1(t.host).host),this.secure=t.secure!=null?t.secure:typeof location!="undefined"&&location.protocol==="https:",t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.agent=t.agent||!1,this.hostname=t.hostname||(typeof location!="undefined"?location.hostname:"localhost"),this.port=t.port||(typeof location!="undefined"&&location.port?location.port:this.secure?443:80),this.query=t.query||{},typeof this.query=="string"&&(this.query=_6.decode(this.query)),this.upgrade=t.upgrade!==!1,this.path=(t.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!t.forceJSONP,this.jsonp=t.jsonp!==!1,this.forceBase64=!!t.forceBase64,this.enablesXDR=!!t.enablesXDR,this.withCredentials=t.withCredentials!==!1,this.timestampParam=t.timestampParam||"t",this.timestampRequests=t.timestampRequests,this.transports=t.transports||["polling","websocket"],this.transportOptions=t.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=t.policyPort||843,this.rememberUpgrade=t.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=t.onlyBinaryUpgrades,this.perMessageDeflate=t.perMessageDeflate!==!1?t.perMessageDeflate||{}:!1,this.perMessageDeflate===!0&&(this.perMessageDeflate={}),this.perMessageDeflate&&this.perMessageDeflate.threshold==null&&(this.perMessageDeflate.threshold=1024),this.pfx=t.pfx||void 0,this.key=t.key||void 0,this.passphrase=t.passphrase||void 0,this.cert=t.cert||void 0,this.ca=t.ca||void 0,this.ciphers=t.ciphers||void 0,this.rejectUnauthorized=t.rejectUnauthorized===void 0?!0:t.rejectUnauthorized,this.forceNode=!!t.forceNode,this.isReactNative=typeof navigator!="undefined"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative",(typeof self=="undefined"||this.isReactNative)&&(t.extraHeaders&&Object.keys(t.extraHeaders).length>0&&(this.extraHeaders=t.extraHeaders),t.localAddress&&(this.localAddress=t.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}ze.priorWebsocketSuccess=!1;y6(ze.prototype);ze.protocol=Qw.protocol;ze.Socket=ze;ze.Transport=u0();ze.transports=Ic;ze.parser=Wi;ze.prototype.createTransport=function(e){xt('creating transport "%s"',e);var t=C6(this.query);t.EIO=Qw.protocol,t.transport=e;var r=this.transportOptions[e]||{};this.id&&(t.sid=this.id);var n=new v6[e]({query:t,socket:this,agent:r.agent||this.agent,hostname:r.hostname||this.hostname,port:r.port||this.port,secure:r.secure||this.secure,path:r.path||this.path,forceJSONP:r.forceJSONP||this.forceJSONP,jsonp:r.jsonp||this.jsonp,forceBase64:r.forceBase64||this.forceBase64,enablesXDR:r.enablesXDR||this.enablesXDR,withCredentials:r.withCredentials||this.withCredentials,timestampRequests:r.timestampRequests||this.timestampRequests,timestampParam:r.timestampParam||this.timestampParam,policyPort:r.policyPort||this.policyPort,pfx:r.pfx||this.pfx,key:r.key||this.key,passphrase:r.passphrase||this.passphrase,cert:r.cert||this.cert,ca:r.ca||this.ca,ciphers:r.ciphers||this.ciphers,rejectUnauthorized:r.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:r.perMessageDeflate||this.perMessageDeflate,extraHeaders:r.extraHeaders||this.extraHeaders,forceNode:r.forceNode||this.forceNode,localAddress:r.localAddress||this.localAddress,requestTimeout:r.requestTimeout||this.requestTimeout,protocols:r.protocols||void 0,isReactNative:this.isReactNative});return n};function C6(e){var t={};for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);return t}ze.prototype.open=function(){var e;if(this.rememberUpgrade&&ze.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1)e="websocket";else if(this.transports.length===0){var t=this;setTimeout(function(){t.emit("error","No transports available")},0);return}else e=this.transports[0];this.readyState="opening";try{e=this.createTransport(e)}catch(r){this.transports.shift(),this.open();return}e.open(),this.setTransport(e)};ze.prototype.setTransport=function(e){xt("setting transport %s",e.name);var t=this;this.transport&&(xt("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",function(){t.onDrain()}).on("packet",function(r){t.onPacket(r)}).on("error",function(r){t.onError(r)}).on("close",function(){t.onClose("transport close")})};ze.prototype.probe=function(e){xt('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),r=!1,n=this;ze.priorWebsocketSuccess=!1;function i(){if(n.onlyBinaryUpgrades){var h=!this.supportsBinary&&n.transport.supportsBinary;r=r||h}r||(xt('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",function(p){if(!r)if(p.type==="pong"&&p.data==="probe"){if(xt('probe transport "%s" pong',e),n.upgrading=!0,n.emit("upgrading",t),!t)return;ze.priorWebsocketSuccess=t.name==="websocket",xt('pausing current transport "%s"',n.transport.name),n.transport.pause(function(){r||n.readyState!=="closed"&&(xt("changing transport and sending upgrade packet"),d(),n.setTransport(t),t.send([{type:"upgrade"}]),n.emit("upgrade",t),t=null,n.upgrading=!1,n.flush())})}else{xt('probe transport "%s" failed',e);var m=new Error("probe error");m.transport=t.name,n.emit("upgradeError",m)}}))}function a(){r||(r=!0,d(),t.close(),t=null)}function o(h){var p=new Error("probe error: "+h);p.transport=t.name,a(),xt('probe transport "%s" failed because of error: %s',e,h),n.emit("upgradeError",p)}function s(){o("transport closed")}function u(){o("socket closed")}function c(h){t&&h.name!==t.name&&(xt('"%s" works - aborting "%s"',h.name,t.name),a())}function d(){t.removeListener("open",i),t.removeListener("error",o),t.removeListener("close",s),n.removeListener("close",u),n.removeListener("upgrading",c)}t.once("open",i),t.once("error",o),t.once("close",s),this.once("close",u),this.once("upgrading",c),t.open()};ze.prototype.onOpen=function(){if(xt("socket open"),this.readyState="open",ze.priorWebsocketSuccess=this.transport.name==="websocket",this.emit("open"),this.flush(),this.readyState==="open"&&this.upgrade&&this.transport.pause){xt("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}};ze.prototype.onPacket=function(e){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(xt('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data);break}else xt('packet received with socket readyState "%s"',this.readyState)};ze.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),this.readyState!=="closed"&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))};ze.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout(function(){t.readyState!=="closed"&&t.onClose("ping timeout")},e||t.pingInterval+t.pingTimeout)};ze.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout(function(){xt("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)},e.pingInterval)};ze.prototype.ping=function(){var e=this;this.sendPacket("ping",function(){e.emit("ping")})};ze.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,this.writeBuffer.length===0?this.emit("drain"):this.flush()};ze.prototype.flush=function(){this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(xt("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))};ze.prototype.write=ze.prototype.send=function(e,t,r){return this.sendPacket("message",e,t,r),this};ze.prototype.sendPacket=function(e,t,r,n){if(typeof t=="function"&&(n=t,t=void 0),typeof r=="function"&&(n=r,r=null),!(this.readyState==="closing"||this.readyState==="closed")){r=r||{},r.compress=r.compress!==!1;var i={type:e,data:t,options:r};this.emit("packetCreate",i),this.writeBuffer.push(i),n&&this.once("flush",n),this.flush()}};ze.prototype.close=function(){if(this.readyState==="opening"||this.readyState==="open"){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",function(){this.upgrading?n():t()}):this.upgrading?n():t()}function t(){e.onClose("forced close"),xt("socket closing - telling transport to close"),e.transport.close()}function r(){e.removeListener("upgrade",r),e.removeListener("upgradeError",r),t()}function n(){e.once("upgrade",r),e.once("upgradeError",r)}return this};ze.prototype.onError=function(e){xt("socket error %j",e),ze.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)};ze.prototype.onClose=function(e,t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){xt('socket close with reason: "%s"',e);var r=this;clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),r.writeBuffer=[],r.prevBufferLen=0}};ze.prototype.filterUpgrades=function(e){for(var t=[],r=0,n=e.length;r<n;r++)~b6(this.transports,e[r])&&t.push(e[r]);return t};a0.exports=w6;a0.exports.parser=Wi;var x6=a0.exports,Jw={exports:{}},T6=S6;function S6(e,t){var r=[];t=t||0;for(var n=t||0;n<e.length;n++)r[n-t]=e[n];return r}var eC=M6;function M6(e,t,r){return e.on(t,r),{destroy:function(){e.removeListener(t,r)}}}var A1=[].slice,tC=function(e,t){if(typeof t=="string"&&(t=e[t]),typeof t!="function")throw new Error("bind() requires a function");var r=A1.call(arguments,2);return function(){return t.apply(e,r.concat(A1.call(arguments)))}};(function(e,t){var r=Lc,n=Xs,i=T6,a=eC,o=tC,s=kc("socket.io-client:socket"),u=Ja,c=zw;e.exports=p;var d={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},h=n.prototype.emit;function p(m,g,b){this.io=m,this.nsp=g,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,this.flags={},b&&b.query&&(this.query=b.query),this.io.autoConnect&&this.open()}n(p.prototype),p.prototype.subEvents=function(){if(!this.subs){var m=this.io;this.subs=[a(m,"open",o(this,"onopen")),a(m,"packet",o(this,"onpacket")),a(m,"close",o(this,"onclose"))]}},p.prototype.open=p.prototype.connect=function(){return this.connected?this:(this.subEvents(),this.io.reconnecting||this.io.open(),this.io.readyState==="open"&&this.onopen(),this.emit("connecting"),this)},p.prototype.send=function(){var m=i(arguments);return m.unshift("message"),this.emit.apply(this,m),this},p.prototype.emit=function(m){if(d.hasOwnProperty(m))return h.apply(this,arguments),this;var g=i(arguments),b={type:(this.flags.binary!==void 0?this.flags.binary:c(g))?r.BINARY_EVENT:r.EVENT,data:g};return b.options={},b.options.compress=!this.flags||this.flags.compress!==!1,typeof g[g.length-1]=="function"&&(s("emitting packet with ack id %d",this.ids),this.acks[this.ids]=g.pop(),b.id=this.ids++),this.connected?this.packet(b):this.sendBuffer.push(b),this.flags={},this},p.prototype.packet=function(m){m.nsp=this.nsp,this.io.packet(m)},p.prototype.onopen=function(){if(s("transport is open - connecting"),this.nsp!=="/")if(this.query){var m=typeof this.query=="object"?u.encode(this.query):this.query;s("sending connect packet with query %s",m),this.packet({type:r.CONNECT,query:m})}else this.packet({type:r.CONNECT})},p.prototype.onclose=function(m){s("close (%s)",m),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",m)},p.prototype.onpacket=function(m){var g=m.nsp===this.nsp,b=m.type===r.ERROR&&m.nsp==="/";if(!(!g&&!b))switch(m.type){case r.CONNECT:this.onconnect();break;case r.EVENT:this.onevent(m);break;case r.BINARY_EVENT:this.onevent(m);break;case r.ACK:this.onack(m);break;case r.BINARY_ACK:this.onack(m);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",m.data);break}},p.prototype.onevent=function(m){var g=m.data||[];s("emitting event %j",g),m.id!=null&&(s("attaching ack callback to event"),g.push(this.ack(m.id))),this.connected?h.apply(this,g):this.receiveBuffer.push(g)},p.prototype.ack=function(m){var g=this,b=!1;return function(){if(!b){b=!0;var _=i(arguments);s("sending ack %j",_),g.packet({type:c(_)?r.BINARY_ACK:r.ACK,id:m,data:_})}}},p.prototype.onack=function(m){var g=this.acks[m.id];typeof g=="function"?(s("calling ack %s with %j",m.id,m.data),g.apply(this,m.data),delete this.acks[m.id]):s("bad ack %s",m.id)},p.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emitBuffered(),this.emit("connect")},p.prototype.emitBuffered=function(){var m;for(m=0;m<this.receiveBuffer.length;m++)h.apply(this,this.receiveBuffer[m]);for(this.receiveBuffer=[],m=0;m<this.sendBuffer.length;m++)this.packet(this.sendBuffer[m]);this.sendBuffer=[]},p.prototype.ondisconnect=function(){s("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},p.prototype.destroy=function(){if(this.subs){for(var m=0;m<this.subs.length;m++)this.subs[m].destroy();this.subs=null}this.io.destroy(this)},p.prototype.close=p.prototype.disconnect=function(){return this.connected&&(s("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},p.prototype.compress=function(m){return this.flags.compress=m,this},p.prototype.binary=function(m){return this.flags.binary=m,this}})(Jw);var rC=Jw.exports,P6=ro;function ro(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}ro.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),r=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+r:e-r}return Math.min(e,this.max)|0};ro.prototype.reset=function(){this.attempts=0};ro.prototype.setMin=function(e){this.ms=e};ro.prototype.setMax=function(e){this.max=e};ro.prototype.setJitter=function(e){this.jitter=e};var E6=x6,A6=rC,R6=Xs,D6=Lc,Wn=eC,da=tC,Zt=kc("socket.io-client:manager"),nC=Kw,N6=P6,iC=Object.prototype.hasOwnProperty,R1=Ue;function Ue(e,t){if(!(this instanceof Ue))return new Ue(e,t);e&&typeof e=="object"&&(t=e,e=void 0),t=t||{},t.path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(t.reconnection!==!1),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new N6({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(t.timeout==null?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var r=t.parser||D6;this.encoder=new r.Encoder,this.decoder=new r.Decoder,this.autoConnect=t.autoConnect!==!1,this.autoConnect&&this.open()}Ue.prototype.emitAll=function(){this.emit.apply(this,arguments);for(var e in this.nsps)iC.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)};Ue.prototype.updateSocketIds=function(){for(var e in this.nsps)iC.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))};Ue.prototype.generateId=function(e){return(e==="/"?"":e+"#")+this.engine.id};R6(Ue.prototype);Ue.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection};Ue.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts};Ue.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay};Ue.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor};Ue.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax};Ue.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout};Ue.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()};Ue.prototype.open=Ue.prototype.connect=function(e,t){if(Zt("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;Zt("opening %s",this.uri),this.engine=E6(this.uri,this.opts);var r=this.engine,n=this;this.readyState="opening",this.skipReconnect=!1;var i=Wn(r,"open",function(){n.onopen(),e&&e()}),a=Wn(r,"error",function(u){if(Zt("connect_error"),n.cleanup(),n.readyState="closed",n.emitAll("connect_error",u),e){var c=new Error("Connection error");c.data=u,e(c)}else n.maybeReconnectOnOpen()});if(this._timeout!==!1){var o=this._timeout;Zt("connect attempt will timeout after %d",o),o===0&&i.destroy();var s=setTimeout(function(){Zt("connect attempt timed out after %d",o),i.destroy(),r.close(),r.emit("error","timeout"),n.emitAll("connect_timeout",o)},o);this.subs.push({destroy:function(){clearTimeout(s)}})}return this.subs.push(i),this.subs.push(a),this};Ue.prototype.onopen=function(){Zt("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(Wn(e,"data",da(this,"ondata"))),this.subs.push(Wn(e,"ping",da(this,"onping"))),this.subs.push(Wn(e,"pong",da(this,"onpong"))),this.subs.push(Wn(e,"error",da(this,"onerror"))),this.subs.push(Wn(e,"close",da(this,"onclose"))),this.subs.push(Wn(this.decoder,"decoded",da(this,"ondecoded")))};Ue.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")};Ue.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)};Ue.prototype.ondata=function(e){this.decoder.add(e)};Ue.prototype.ondecoded=function(e){this.emit("packet",e)};Ue.prototype.onerror=function(e){Zt("error",e),this.emitAll("error",e)};Ue.prototype.socket=function(e,t){var r=this.nsps[e];if(!r){r=new A6(this,e,t),this.nsps[e]=r;var n=this;r.on("connecting",i),r.on("connect",function(){r.id=n.generateId(e)}),this.autoConnect&&i()}function i(){~nC(n.connecting,r)||n.connecting.push(r)}return r};Ue.prototype.destroy=function(e){var t=nC(this.connecting,e);~t&&this.connecting.splice(t,1),!this.connecting.length&&this.close()};Ue.prototype.packet=function(e){Zt("writing packet %j",e);var t=this;e.query&&e.type===0&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,function(r){for(var n=0;n<r.length;n++)t.engine.write(r[n],e.options);t.encoding=!1,t.processPacketQueue()}))};Ue.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}};Ue.prototype.cleanup=function(){Zt("cleanup");for(var e=this.subs.length,t=0;t<e;t++){var r=this.subs.shift();r.destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()};Ue.prototype.close=Ue.prototype.disconnect=function(){Zt("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,this.readyState==="opening"&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()};Ue.prototype.onclose=function(e){Zt("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()};Ue.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)Zt("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();Zt("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var r=setTimeout(function(){e.skipReconnect||(Zt("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),!e.skipReconnect&&e.open(function(n){n?(Zt("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",n.data)):(Zt("reconnect success"),e.onreconnect())}))},t);this.subs.push({destroy:function(){clearTimeout(r)}})}};Ue.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)};(function(e,t){var r=J5,n=Lc,i=R1,a=kc("socket.io-client");e.exports=t=s;var o=t.managers={};function s(u,c){typeof u=="object"&&(c=u,u=void 0),c=c||{};var d=r(u),h=d.source,p=d.id,m=d.path,g=o[p]&&m in o[p].nsps,b=c.forceNew||c["force new connection"]||c.multiplex===!1||g,_;return b?(a("ignoring socket cache for %s",h),_=i(h,c)):(o[p]||(a("new io instance for %s",h),o[p]=i(h,c)),_=o[p]),d.query&&!c.query&&(c.query=d.query),_.socket(d.path,c)}t.protocol=n.protocol,t.connect=s,t.Manager=R1,t.Socket=rC})(If,If.exports);var k6=If.exports;const L6=O.getDefaultExportFromCjs(k6);function O6(e=document.cookie){const t="XSRF-TOKEN",r=e.match(new RegExp(`(^| )${t}=([^;]+)`));return r!==null&&r[2]?r[2]:null}function I6(){const e=O6(),t={};return e&&(t["X-XSRF-TOKEN"]=e),t}class p0{constructor(t,r,n){this.isRegistered=!1,this.isListening=!1,typeof t=="string"?(this.socket=p0.createNewSocket(t,r,n),this.subcribeOnSocketReadiness()):this.socket=t}subcribeOnSocketReadiness(){this.socket.on("register",()=>{this.isRegistered=!0}),this.socket.on("listen",()=>{this.isListening=!0})}isReady(){return this.isRegistered&&this.isListening}on(t,r){this.socket.on(t,r)}off(t,r){this.socket.off(t,r)}send(t,...r){const n=r[0];this.socket.emit(t,JSON.stringify(n))}onMessage(t,r,n){this.onMessageCallback=n;const i=t||"",a=r||"",o=a?`${i}-${a}`:i,s=u=>{let c=null;try{c=JSON.parse(u)}catch(d){throw new Error("Error parsing response message")}n(i,c)};return this.on(o,s),()=>{this.off(o,s)}}trigger(t,r){this.onMessageCallback&&this.onMessageCallback(t,r)}static createNewSocket(t,r,n){const i=new URL("./gateway",new URL(zi(t))),a=i.origin+(n?`/${n}`:""),o=L6.connect(a,{path:i.pathname,transports:["websocket"],reconnection:!0,query:r});return o.on("connect_error",s=>{console.log(`connect_error due to ${s.message}`)}),o.on("csrf",()=>{o.emit("csrf",I6())}),o.on("listen",()=>{o.emit("register",{})}),o.on("register",()=>{o.emit('{"eventName": "_registerEvent", "data": "pivot2"}')}),o.on("error",s=>{console.warn(`"SisenseSocket" socket error "${s}"`)}),o}}var F6=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};class $6{constructor(t){this.socket=t}destroy(){}prepareRequest(t){return Promise.resolve(t)}prepareLoadService(t,r=!1){return this.dataLoadService&&(r||this.dataLoadService.isFormattingChanges(t))?this.dataLoadService:new H5(this.socket)}prepareDataService(t){const r=new br(t);return{loadData:(n,i,a)=>{if(!r)throw new Error('No DataService defined during "prepareDataService"');return r.loadData(n,{pageSize:i,isPaginated:a})}}}loadInitData(t){return F6(this,arguments,void 0,function*(r,n=!0,i=100,a=!1){const o=n?i:void 0;try{const s=yield this.prepareRequest(r);this.dataLoadService=this.prepareLoadService(s,a);const{loadData:u}=this.prepareDataService(this.dataLoadService),{rowsTreeService:c,columnsTreeService:d,cornerTreeService:h,isLastPage:p}=yield u(a?void 0:s,o,n);return this.transformTreeStructuresToResultData({rowsTreeService:c,columnsTreeService:d,cornerTreeService:h,isLastPage:p})}catch(s){console.error('Error during loading initial page"',s)}return H.EMPTY_PIVOT_QUERY_RESULT_DATA})}buildColumnsHelper(t,r,n,i){var a;const o=`${n}${n===""?"":" | "}${(a=i.value)===null||a===void 0?void 0:a.toString()}`;i.children?i.children.forEach(s=>{this.buildColumnsHelper(t,r,o,s)}):r.push({name:o,type:t})}transformGridToColumns(t,r){if(!r||r.length===0)return[];const n=[];return r==null||r[0].forEach(i=>{typeof i!="string"&&this.buildColumnsHelper(t,n,"",i)}),n||[]}transformTreeStructuresToResultData(t){const{rowsTreeService:r,columnsTreeService:n,cornerTreeService:i}=t;if(!r&&!n&&!i)return H.EMPTY_PIVOT_QUERY_RESULT_DATA;const a=i?i.getGrid():[],o=n?n.getGrid():[],s=r?r.getGrid():[],u=this.transformGridToColumns("string",a),c=this.transformGridToColumns("number",o),d=[...u,...c],h=r?r.extractData(n):[],p=s.length,m=d.length,g=[];let b=0,_=0;return Array.from(Array(p)).map((w,C)=>{const S=[];Array.from(Array(m)).map((T,M)=>{var P,R;let k;if(M<u.length){b=C,_=M;try{k=s[b][_]}catch($){throw new Error(`Can't find data item for ${b}-${_}`)}}else{b=C,_=M-u.length;try{k=h[b][_]}catch($){throw new Error(`Can't find data item for ${b}-${_}`)}}let I;if(typeof k=="string"){const $=k.split("-");if($.length===2){const G=Number($[0]),Y=Number($[1]);k=s[G][Y],I=((P=k.value)===null||P===void 0?void 0:P.toString())||""}else I=""}else I=((R=k.value)===null||R===void 0?void 0:R.toString())||"";S.push({data:I,text:I})}),g.push(S)}),{table:{columns:d,rows:g},grids:{corner:a,rows:s,columns:o,values:h}}}}const B6={errorPrefix:"[request-error]",errors:{networkError:"Network error. Check browser console for further details.",authFailed:"Failed to authenticate.",ssoNotEnabled:"SSO is not enabled on target instance, please choose another authentication method.",ssoNoLoginUrl:"Unable to fetch SSO login URL from target instance. Check SSO settings.",passwordAuthFailed:"$t(errorPrefix) Username and password authentication was not successful. Check credentials.",tokenAuthFailed:"$t(errorPrefix) Token authentication was not successful. Check credentials.",authRedirectLimitExceeded:"SSO redirect limit reached. Authentication may be blocked by browser privacy settings or third-party cookie restrictions. Please check your SSO configuration or try a different browser."}},z6={errorPrefix:"[request-error]",errors:{networkError:"Помилка мережі. Можливо ви забули додати свій домен до «CORS Allowed Origins» в панелі адміністратора Sisense -> Security Settings.",authFailed:"Автентифікація не вдалася.",ssoNotEnabled:"SSO не ввімкнено на цьому сервері, будь ласка, виберіть інший метод аутентифікації",ssoNoLoginUrl:"Неможливо отримати SSO login URL з сервера. Перевірте налаштування SSO.",passwordAuthFailed:"$t(errorPrefix) Помилка автентифікації за допомогою імені користувача та пароля. Перевірте дані для входу.",tokenAuthFailed:"$t(errorPrefix) Помилка автентифікації за допомогою токена. Перевірте дані для входу.",authRedirectLimitExceeded:"Досягнуто ліміт перенаправлень SSO. Автентифікацію може блокувати налаштування конфіденційності браузера або обмеження сторонніх cookie. Перевірте конфігурацію SSO або спробуйте інший браузер."}},aC="sdkRestClient",H6={en:B6,uk:z6};function W6(){return V.initI18next({resource:H6,language:"en",namespace:aC})}const{i18nextInstance:j6}=W6();class Zs{constructor(t){this._valid=!0,this._authenticating=!1,this._tried=!1,this._result=new Promise(r=>{this._resolve=r}),this.type=t}isValid(){return this._valid}invalidate(){this._valid=!1}authenticate(){return this._result}isAuthenticating(){return this._authenticating}authenticated(){return this._result}applyHeaders(t){}}const Bc=(e,t)=>{if(Array.isArray(e)){for(const[n,i]of Object.entries(t))e.push([n,i]);return}if(e instanceof Headers){for(const[n,i]of Object.entries(t))e.set(n,i);return}const r=e;for(const[n,i]of Object.entries(t))r[n]=i},oC=(e,t)=>{if(!e||typeof e!="string")return e;const r=new URL(e);for(const[n,i]of Object.entries(t))r.searchParams.set(n,i);return r.toString()},V6=(e,t)=>e===null||t===null,U6=(e,t)=>{if(!e||typeof e!="string")throw new Error("URL must be a non-empty string");let r;try{r=new URL(e)}catch(i){throw new Error(`Invalid URL format: ${e}`)}let n;try{n=new URL(t)}catch(i){throw new Error(`Invalid url origin format: ${t}`)}if(r.origin!==n.origin)throw new Error(`URL origin ${r.origin} does not match allowed origin ${n.origin}. SSRF protection: requests must be to the configured base URL only.`)};class G6 extends Zs{constructor(t,r){super("bearer"),this.bearer=r,this._resolve(!0)}applyHeaders(t){const r="Bearer "+this.bearer;Bc(t,{Authorization:r})}authenticate(){return this._result}authenticated(){return this._result}}function sC(e){return e.type==="bearer"}let En=class extends V.AbstractTranslatableError{constructor(t,r){super(aC,{key:t,interpolationOptions:r},j6.t)}get status(){return this.interpolationOptions.status}};var Mh=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};const q6="sisense_sso_redirect_attempts_",Y6="sisense_sso_redirect_last_at_",X6=3,Z6=1e4;class K6 extends Zs{constructor(t,r=!1,n="",i=X6,a=Z6){super("sso"),this.url=zi(t,!0),this._enableSilentPreAuth=r,this._alternativeSsoHost=n,this._ssoMaxAuthRedirectAttempts=Math.max(1,i),this._ssoRedirectAttemptsTtlMs=Math.max(0,a)}getRedirectCountStorageKey(){return q6+encodeURIComponent(this.url)}getRedirectLastAtStorageKey(){return Y6+encodeURIComponent(this.url)}getRedirectAttempts(){try{if(typeof window=="undefined"||typeof window.localStorage=="undefined")return 0;const t=window.localStorage.getItem(this.getRedirectCountStorageKey()),r=window.localStorage.getItem(this.getRedirectLastAtStorageKey());if(t==null&&r==null)return 0;const n=parseInt(t!=null?t:"",10),i=parseInt(r!=null?r:"",10);return isNaN(n)||isNaN(i)||n<0?(this.clearRedirectAttempts(),0):this._ssoRedirectAttemptsTtlMs>0&&Date.now()-i>this._ssoRedirectAttemptsTtlMs?(this.clearRedirectAttempts(),0):Math.max(0,n)}catch(t){return 0}}clearRedirectAttempts(){try{typeof window!="undefined"&&typeof window.localStorage!="undefined"&&(window.localStorage.removeItem(this.getRedirectCountStorageKey()),window.localStorage.removeItem(this.getRedirectLastAtStorageKey()))}catch(t){}}persistRedirectAttempts(t){try{if(typeof window=="undefined"||typeof window.localStorage=="undefined")return;const r=Date.now();window.localStorage.setItem(this.getRedirectCountStorageKey(),String(t)),window.localStorage.setItem(this.getRedirectLastAtStorageKey(),String(r))}catch(r){}}authenticate(){return Mh(this,arguments,void 0,function*(t=!0){var r;try{this._authenticating=!0;const{isAuthenticated:n,loginUrl:i}=yield this.checkAuthentication();if(n)return this.clearRedirectAttempts(),this._resolve(!0),yield this._result;let a="";try{new URL(i),a=i}catch(u){a=qv(this._alternativeSsoHost||this.url,i)}const o=Object.fromEntries(new URL(this.url).searchParams.entries());a=oC(a,Object.assign(Object.assign({},o),{return_to:window.location.href}));const s=this.getRedirectAttempts();if(s>=this._ssoMaxAuthRedirectAttempts)throw new En("errors.authRedirectLimitExceeded");if(this._enableSilentPreAuth&&t){yield this.authenticateSilent(a);const{isAuthenticated:u}=yield this.checkAuthentication();if(u)return this.clearRedirectAttempts(),this._resolve(!0),yield this._result}this.persistRedirectAttempts(s+1),(r=window==null?void 0:window.location)===null||r===void 0||r.replace(a)}finally{this._resolve(!1),this._authenticating=!1}return this._result})}authenticateSilent(t){return Mh(this,void 0,void 0,function*(){const r=document.createElement("iframe");r.style.display="none",document.body.appendChild(r),r.src=t,yield new Promise(n=>{r.onload=()=>{n(!0)}}),document.body.removeChild(r)})}checkAuthentication(){return Mh(this,void 0,void 0,function*(){var t,r;const n=qv(this.url,"api/auth/isauth"),i=yield fetch(n,{headers:{Internal:"true"},credentials:"include"}).catch(zc);if(i.status===200&&!(!((r=(t=i.headers)===null||t===void 0?void 0:t.get("Content-Type"))===null||r===void 0)&&r.includes("application/json")))throw new En("errors.authFailed");const a=yield i.json();if(!a.isAuthenticated){if(!a.ssoEnabled)throw new En("errors.ssoNotEnabled");if(!a.loginUrl)throw new En("errors.ssoNoLoginUrl")}return{isAuthenticated:a.isAuthenticated,loginUrl:a.loginUrl||""}})}}function m0(e){return e.type==="sso"}var Q6=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};class J6 extends Zs{constructor(t,r){super("wat"),this.url=`${zi(t)}api/v1/wat/sessionToken`,this.body=`{"webAccessToken": "${r}"}`}authenticate(){return Q6(this,void 0,void 0,function*(){if(this._tried)return this._result;this._tried=!0;try{this._authenticating=!0;const t=yield fetch(this.url,{method:"POST",headers:{accept:"application/json","Content-Type":"application/json"},body:this.body}).catch(zc);if(t.ok){const r=yield t.json();this._initialiser=r.initialiser,this._webSessionToken=r.webSessionToken,this._resolve(!0)}}catch(t){throw new En("errors.tokenAuthFailed")}finally{this._resolve(!1),this._authenticating=!1}return this._result})}applyHeaders(t){if(this._webSessionToken&&this._initialiser){const r=this._webSessionToken,n=this._initialiser;Bc(t,{Authorization:r,Initialiser:n})}}}function lC(e){return e.type==="wat"}var uC=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};function eD(e){return uC(this,void 0,void 0,function*(){var t,r,n;if(!e.ok){const i=(t=e.headers)===null||t===void 0?void 0:t.get("Content-Type"),a=i&&i.includes("application/json")?yield e.json().catch(()=>({})):{};throw new En("errors.responseError",{status:e.status.toString(),statusText:e.statusText,errorCode:(r=a.error)===null||r===void 0?void 0:r.code,errorMessage:(n=a.error)===null||n===void 0?void 0:n.message,context:e.statusText?"withStatusText":"onlyStatus"})}return e})}function tD(e,t){if(t.invalidate(),sD(t))throw new En("errors.passwordAuthFailed");if(sC(t)||lC(t))throw new En("errors.tokenAuthFailed");return m0(t)&&!t.isAuthenticating()&&t.authenticate(),e}function rD(e){return e.message==="Failed to fetch"&&e.name==="TypeError"}function nD(){return console.warn("Network error. Verify server is accessible and your domain is added to 'CORS Allowed Origins' in Sisense Admin Panel -> Security Settings."),Promise.reject(new En("errors.networkError"))}const iD=e=>t=>uC(void 0,void 0,void 0,function*(){return t.status===401?tD(t,e):t.ok?t:eD(t)}),zc=e=>rD(e)?nD():Promise.reject(e);var aD=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};class oD extends Zs{constructor(t,r,n){super("password"),this._authheader="",this.url=`${zi(t)}api/v1/authentication/login`;const i=encodeURIComponent(r),a=encodeURIComponent(n);this.body=`username=${i}&password=${a}`}authenticate(){return aD(this,void 0,void 0,function*(){if(this._tried)return this._result;this._tried=!0;try{this._authenticating=!0;const t=yield fetch(this.url,{method:"POST",headers:{accept:"application/json","Content-Type":"application/x-www-form-urlencoded"},body:this.body}).catch(zc);if(t.ok){const r=yield t.json();this._authheader=r.access_token}}finally{this._resolve(!!this._authheader),this._authenticating=!1}return this._result})}applyHeaders(t){const r="Bearer "+this._authheader;Bc(t,{Authorization:r})}}function sD(e){return e.type==="password"}class lD{constructor(){this.ready=!0,this.events=new Qm,this.ready=!0}isReady(){return this.ready}on(t,r){this.events.on(t,r)}off(t,r){this.events.removeListener(t,r)}send(t,...r){const n=t||r;this.ready=!!n||!0}onMessage(t,r,n){this.onMessageCallback=n;const i=()=>{};return this.on("message",i),()=>{this.off("message",i)}}trigger(t,r){return new Promise(n=>{setTimeout(()=>{this.onMessageCallback&&this.onMessageCallback(t,r),n()},10)})}}const uD="pivot2";class cD{constructor(t,r,n=!1){this._url=t,this._auth=r,this._mockSocket=n}getQueryOptionsSso(t){return{}}getQueryOptionsBearer(t){const r=t.bearer;if(!r)throw new Error("Missing bearer token");return{token:r}}getQueryOptionsWat(t){const r=new Headers;t.applyHeaders(r);const n=r.get("Authorization"),i=r.get("Initialiser");if(!n||!i)throw new Error("Missing auth header");return{authorization:n,initialiser:i}}get socket(){if(!this._socket){if(this._mockSocket)return this._socket=new lD,this._socket;const t=this._auth,r=this._url;let n={};sC(t)?n=this.getQueryOptionsBearer(t):lC(t)?n=this.getQueryOptionsWat(t):m0(t)&&(n=this.getQueryOptionsSso(t)),this._socket=new p0(r,n,uD)}return this._socket}}var dD=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};class cC{constructor(t,r,n=!1){this.socketBuilder=new cD(zi(t),r,n)}queryData(t,r,n,i){return dD(this,void 0,void 0,function*(){return new $6(this.socketBuilder.socket).loadInitData(t,r,n,i)})}}var Yt={},dC={},Hc={},g0={};(function(e){var t=O.commonjsGlobal&&O.commonjsGlobal.__awaiter||function(i,a,o,s){function u(c){return c instanceof o?c:new o(function(d){d(c)})}return new(o||(o=Promise))(function(c,d){function h(g){try{m(s.next(g))}catch(b){d(b)}}function p(g){try{m(s.throw(g))}catch(b){d(b)}}function m(g){g.done?c(g.value):u(g.value).then(h,p)}m((s=s.apply(i,a||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.Task=e.ExecutionResultStatus=void 0;var r;(function(i){i.SUCCESS="SUCCESS",i.ERROR="ERROR"})(r=e.ExecutionResultStatus||(e.ExecutionResultStatus={}));class n{constructor(a,o,s){this.steps=a,this.passport=o,this.addons=s,this.statistics={startTime:new Date,steps:[],runtimeInfo:{}},this.currentStep=void 0}run(a){return t(this,void 0,void 0,function*(){let o=a,s;for(let c=0;c<this.steps.length;c+=1){this.currentStep=this.steps[c];const{resultValue:d,info:h}=yield this.currentStep.run(this,o);if(this.statistics.steps.push(h),h.success)o=d;else{s=h.error;break}}const u=this.statistics.steps.length===this.steps.length&&this.statistics.steps.every(c=>c.success);return this.statistics.endTime=new Date,{status:u?r.SUCCESS:r.ERROR,error:s,result:u?o:void 0,statistics:this.statistics}})}cancel(a){var o;return t(this,void 0,void 0,function*(){yield(o=this.currentStep)===null||o===void 0?void 0:o.cancel(this,a)})}addRuntimeInfo(a,o){this.statistics.runtimeInfo[a]=o}emitAddonEvent(a,...o){var s;const u=a.split("."),c=u[0],d=u[1],h=(s=this.addons)===null||s===void 0?void 0:s.find(m=>m.addonName===c),p=(h==null?void 0:h.events)[d];p(...o)}}e.Task=n})(g0);var Ph=O.commonjsGlobal&&O.commonjsGlobal.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(Hc,"__esModule",{value:!0});Hc.AbstractTaskManager=void 0;const hD=g0;class fD{constructor(t){this.runningTasks=new Map,this.addons=t||[]}runTask(t){return Ph(this,void 0,void 0,function*(){const{taskId:r}=t.passport;this.runningTasks.set(r,t);const n=yield t.run();return this.runningTasks.delete(r),n})}createFlow(t){return r=>Ph(this,void 0,void 0,function*(){const n=new hD.Task(t,r,this.addons);return this.runTask(n)})}cancel(t,r){return Ph(this,void 0,void 0,function*(){const n=this.runningTasks.get(t);n&&(yield n.cancel(r))})}}Hc.AbstractTaskManager=fD;var Wc={},Ks={};Object.defineProperty(Ks,"__esModule",{value:!0});Ks.TaskCanceledError=void 0;class pD extends Error{constructor(t){const r=`Task was canceled due to: "${t}"`;super(r)}}Ks.TaskCanceledError=pD;var D1=O.commonjsGlobal&&O.commonjsGlobal.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};Object.defineProperty(Wc,"__esModule",{value:!0});Wc.Step=void 0;const mD=Ks;class gD{constructor(t,r,n){this.taskSelfResolvers=new Map,this.taskStepInfos=new Map,this.name=t,this.runLogic=r,this.cancelLogic=n}run(t,r){return D1(this,void 0,void 0,function*(){return this.addStepInfo(t,{name:this.name}),new Promise(n=>{const i=new Date,a=(o,s)=>{const u=new Date,c=u.getTime()-i.getTime();this.addStepInfo(t,{startTime:i,endTime:u,duration:c}),this.addStepInfo(t,s?{success:!1,error:s}:{success:!0}),n({resultValue:o,info:this.getStepInfo(t)})};this.taskSelfResolvers.set(t,a),this.runLogic(t,r).then(o=>a(o)).finally(()=>{this.taskSelfResolvers.delete(t),this.taskStepInfos.delete(t)}).catch(o=>a(void 0,o))})})}cancel(t,r){return D1(this,void 0,void 0,function*(){this.addStepInfo(t,{wasCanceled:!0,cancelingReason:r});const n=this.taskSelfResolvers.get(t);n==null||n(void 0,new mD.TaskCanceledError(r)),this.taskSelfResolvers.delete(t),this.taskStepInfos.delete(t),yield this.cancelLogic(t,r)})}addStepInfo(t,r){const n=this.taskStepInfos.get(t)||{},i=Object.assign(Object.assign({},n),r);this.taskStepInfos.set(t,i)}getStepInfo(t){return this.taskStepInfos.get(t)}}Wc.Step=gD;var jc={};Object.defineProperty(jc,"__esModule",{value:!0});jc.Addon=void 0;class vD{constructor(){this.events={}}}jc.Addon=vD;var Vc={},eu,yD=new Uint8Array(16);function hC(){if(!eu&&(eu=typeof crypto!="undefined"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto!="undefined"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),!eu))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return eu(yD)}const bD=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function Uc(e){return typeof e=="string"&&bD.test(e)}var Bt=[];for(var Eh=0;Eh<256;++Eh)Bt.push((Eh+256).toString(16).substr(1));function Gc(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=(Bt[e[t+0]]+Bt[e[t+1]]+Bt[e[t+2]]+Bt[e[t+3]]+"-"+Bt[e[t+4]]+Bt[e[t+5]]+"-"+Bt[e[t+6]]+Bt[e[t+7]]+"-"+Bt[e[t+8]]+Bt[e[t+9]]+"-"+Bt[e[t+10]]+Bt[e[t+11]]+Bt[e[t+12]]+Bt[e[t+13]]+Bt[e[t+14]]+Bt[e[t+15]]).toLowerCase();if(!Uc(r))throw TypeError("Stringified UUID is invalid");return r}var N1,Ah,Rh=0,Dh=0;function _D(e,t,r){var n=t&&r||0,i=t||new Array(16);e=e||{};var a=e.node||N1,o=e.clockseq!==void 0?e.clockseq:Ah;if(a==null||o==null){var s=e.random||(e.rng||hC)();a==null&&(a=N1=[s[0]|1,s[1],s[2],s[3],s[4],s[5]]),o==null&&(o=Ah=(s[6]<<8|s[7])&16383)}var u=e.msecs!==void 0?e.msecs:Date.now(),c=e.nsecs!==void 0?e.nsecs:Dh+1,d=u-Rh+(c-Dh)/1e4;if(d<0&&e.clockseq===void 0&&(o=o+1&16383),(d<0||u>Rh)&&e.nsecs===void 0&&(c=0),c>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");Rh=u,Dh=c,Ah=o,u+=122192928e5;var h=((u&268435455)*1e4+c)%4294967296;i[n++]=h>>>24&255,i[n++]=h>>>16&255,i[n++]=h>>>8&255,i[n++]=h&255;var p=u/4294967296*1e4&268435455;i[n++]=p>>>8&255,i[n++]=p&255,i[n++]=p>>>24&15|16,i[n++]=p>>>16&255,i[n++]=o>>>8|128,i[n++]=o&255;for(var m=0;m<6;++m)i[n+m]=a[m];return t||Gc(i)}function fC(e){if(!Uc(e))throw TypeError("Invalid UUID");var t,r=new Uint8Array(16);return r[0]=(t=parseInt(e.slice(0,8),16))>>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=t&255,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=t&255,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=t&255,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=t&255,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=t&255,r}function wD(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r<e.length;++r)t.push(e.charCodeAt(r));return t}var CD="6ba7b810-9dad-11d1-80b4-00c04fd430c8",xD="6ba7b811-9dad-11d1-80b4-00c04fd430c8";function pC(e,t,r){function n(i,a,o,s){if(typeof i=="string"&&(i=wD(i)),typeof a=="string"&&(a=fC(a)),a.length!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");var u=new Uint8Array(16+i.length);if(u.set(a),u.set(i,a.length),u=r(u),u[6]=u[6]&15|t,u[8]=u[8]&63|128,o){s=s||0;for(var c=0;c<16;++c)o[s+c]=u[c];return o}return Gc(u)}try{n.name=e}catch(i){}return n.DNS=CD,n.URL=xD,n}function TD(e){if(typeof e=="string"){var t=unescape(encodeURIComponent(e));e=new Uint8Array(t.length);for(var r=0;r<t.length;++r)e[r]=t.charCodeAt(r)}return SD(MD(PD(e),e.length*8))}function SD(e){for(var t=[],r=e.length*32,n="0123456789abcdef",i=0;i<r;i+=8){var a=e[i>>5]>>>i%32&255,o=parseInt(n.charAt(a>>>4&15)+n.charAt(a&15),16);t.push(o)}return t}function mC(e){return(e+64>>>9<<4)+14+1}function MD(e,t){e[t>>5]|=128<<t%32,e[mC(t)-1]=t;for(var r=1732584193,n=-271733879,i=-1732584194,a=271733878,o=0;o<e.length;o+=16){var s=r,u=n,c=i,d=a;r=Vt(r,n,i,a,e[o],7,-680876936),a=Vt(a,r,n,i,e[o+1],12,-389564586),i=Vt(i,a,r,n,e[o+2],17,606105819),n=Vt(n,i,a,r,e[o+3],22,-1044525330),r=Vt(r,n,i,a,e[o+4],7,-176418897),a=Vt(a,r,n,i,e[o+5],12,1200080426),i=Vt(i,a,r,n,e[o+6],17,-1473231341),n=Vt(n,i,a,r,e[o+7],22,-45705983),r=Vt(r,n,i,a,e[o+8],7,1770035416),a=Vt(a,r,n,i,e[o+9],12,-1958414417),i=Vt(i,a,r,n,e[o+10],17,-42063),n=Vt(n,i,a,r,e[o+11],22,-1990404162),r=Vt(r,n,i,a,e[o+12],7,1804603682),a=Vt(a,r,n,i,e[o+13],12,-40341101),i=Vt(i,a,r,n,e[o+14],17,-1502002290),n=Vt(n,i,a,r,e[o+15],22,1236535329),r=Ut(r,n,i,a,e[o+1],5,-165796510),a=Ut(a,r,n,i,e[o+6],9,-1069501632),i=Ut(i,a,r,n,e[o+11],14,643717713),n=Ut(n,i,a,r,e[o],20,-373897302),r=Ut(r,n,i,a,e[o+5],5,-701558691),a=Ut(a,r,n,i,e[o+10],9,38016083),i=Ut(i,a,r,n,e[o+15],14,-660478335),n=Ut(n,i,a,r,e[o+4],20,-405537848),r=Ut(r,n,i,a,e[o+9],5,568446438),a=Ut(a,r,n,i,e[o+14],9,-1019803690),i=Ut(i,a,r,n,e[o+3],14,-187363961),n=Ut(n,i,a,r,e[o+8],20,1163531501),r=Ut(r,n,i,a,e[o+13],5,-1444681467),a=Ut(a,r,n,i,e[o+2],9,-51403784),i=Ut(i,a,r,n,e[o+7],14,1735328473),n=Ut(n,i,a,r,e[o+12],20,-1926607734),r=Gt(r,n,i,a,e[o+5],4,-378558),a=Gt(a,r,n,i,e[o+8],11,-2022574463),i=Gt(i,a,r,n,e[o+11],16,1839030562),n=Gt(n,i,a,r,e[o+14],23,-35309556),r=Gt(r,n,i,a,e[o+1],4,-1530992060),a=Gt(a,r,n,i,e[o+4],11,1272893353),i=Gt(i,a,r,n,e[o+7],16,-155497632),n=Gt(n,i,a,r,e[o+10],23,-1094730640),r=Gt(r,n,i,a,e[o+13],4,681279174),a=Gt(a,r,n,i,e[o],11,-358537222),i=Gt(i,a,r,n,e[o+3],16,-722521979),n=Gt(n,i,a,r,e[o+6],23,76029189),r=Gt(r,n,i,a,e[o+9],4,-640364487),a=Gt(a,r,n,i,e[o+12],11,-421815835),i=Gt(i,a,r,n,e[o+15],16,530742520),n=Gt(n,i,a,r,e[o+2],23,-995338651),r=qt(r,n,i,a,e[o],6,-198630844),a=qt(a,r,n,i,e[o+7],10,1126891415),i=qt(i,a,r,n,e[o+14],15,-1416354905),n=qt(n,i,a,r,e[o+5],21,-57434055),r=qt(r,n,i,a,e[o+12],6,1700485571),a=qt(a,r,n,i,e[o+3],10,-1894986606),i=qt(i,a,r,n,e[o+10],15,-1051523),n=qt(n,i,a,r,e[o+1],21,-2054922799),r=qt(r,n,i,a,e[o+8],6,1873313359),a=qt(a,r,n,i,e[o+15],10,-30611744),i=qt(i,a,r,n,e[o+6],15,-1560198380),n=qt(n,i,a,r,e[o+13],21,1309151649),r=qt(r,n,i,a,e[o+4],6,-145523070),a=qt(a,r,n,i,e[o+11],10,-1120210379),i=qt(i,a,r,n,e[o+2],15,718787259),n=qt(n,i,a,r,e[o+9],21,-343485551),r=Kn(r,s),n=Kn(n,u),i=Kn(i,c),a=Kn(a,d)}return[r,n,i,a]}function PD(e){if(e.length===0)return[];for(var t=e.length*8,r=new Uint32Array(mC(t)),n=0;n<t;n+=8)r[n>>5]|=(e[n/8]&255)<<n%32;return r}function Kn(e,t){var r=(e&65535)+(t&65535),n=(e>>16)+(t>>16)+(r>>16);return n<<16|r&65535}function ED(e,t){return e<<t|e>>>32-t}function qc(e,t,r,n,i,a){return Kn(ED(Kn(Kn(t,e),Kn(n,a)),i),r)}function Vt(e,t,r,n,i,a,o){return qc(t&r|~t&n,e,t,i,a,o)}function Ut(e,t,r,n,i,a,o){return qc(t&n|r&~n,e,t,i,a,o)}function Gt(e,t,r,n,i,a,o){return qc(t^r^n,e,t,i,a,o)}function qt(e,t,r,n,i,a,o){return qc(r^(t|~n),e,t,i,a,o)}var AD=pC("v3",48,TD);function RD(e,t,r){e=e||{};var n=e.random||(e.rng||hC)();if(n[6]=n[6]&15|64,n[8]=n[8]&63|128,t){r=r||0;for(var i=0;i<16;++i)t[r+i]=n[i];return t}return Gc(n)}function DD(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:return t^r^n;case 2:return t&r^t&n^r&n;case 3:return t^r^n}}function Nh(e,t){return e<<t|e>>>32-t}function ND(e){var t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof e=="string"){var n=unescape(encodeURIComponent(e));e=[];for(var i=0;i<n.length;++i)e.push(n.charCodeAt(i))}else Array.isArray(e)||(e=Array.prototype.slice.call(e));e.push(128);for(var a=e.length/4+2,o=Math.ceil(a/16),s=new Array(o),u=0;u<o;++u){for(var c=new Uint32Array(16),d=0;d<16;++d)c[d]=e[u*64+d*4]<<24|e[u*64+d*4+1]<<16|e[u*64+d*4+2]<<8|e[u*64+d*4+3];s[u]=c}s[o-1][14]=(e.length-1)*8/Math.pow(2,32),s[o-1][14]=Math.floor(s[o-1][14]),s[o-1][15]=(e.length-1)*8&4294967295;for(var h=0;h<o;++h){for(var p=new Uint32Array(80),m=0;m<16;++m)p[m]=s[h][m];for(var g=16;g<80;++g)p[g]=Nh(p[g-3]^p[g-8]^p[g-14]^p[g-16],1);for(var b=r[0],_=r[1],w=r[2],C=r[3],S=r[4],T=0;T<80;++T){var M=Math.floor(T/20),P=Nh(b,5)+DD(M,_,w,C)+S+t[M]+p[T]>>>0;S=C,C=w,w=Nh(_,30)>>>0,_=b,b=P}r[0]=r[0]+b>>>0,r[1]=r[1]+_>>>0,r[2]=r[2]+w>>>0,r[3]=r[3]+C>>>0,r[4]=r[4]+S>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,r[0]&255,r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,r[1]&255,r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,r[2]&255,r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,r[3]&255,r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,r[4]&255]}var kD=pC("v5",80,ND);const LD="00000000-0000-0000-0000-000000000000";function OD(e){if(!Uc(e))throw TypeError("Invalid UUID");return parseInt(e.substr(14,1),16)}const ID=Object.freeze(Object.defineProperty({__proto__:null,NIL:LD,parse:fC,stringify:Gc,v1:_D,v3:AD,v4:RD,v5:kD,validate:Uc,version:OD},Symbol.toStringTag,{value:"Module"})),FD=O.getAugmentedNamespace(ID);Object.defineProperty(Vc,"__esModule",{value:!0});Vc.TaskPassport=void 0;const $D=FD;class BD{constructor(){this.taskId=(0,$D.v4)()}}Vc.TaskPassport=BD;(function(e){var t=O.commonjsGlobal&&O.commonjsGlobal.__createBinding||(Object.create?function(n,i,a,o){o===void 0&&(o=a);var s=Object.getOwnPropertyDescriptor(i,a);(!s||("get"in s?!i.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,o,s)}:function(n,i,a,o){o===void 0&&(o=a),n[o]=i[a]}),r=O.commonjsGlobal&&O.commonjsGlobal.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(Hc,e),r(Wc,e),r(g0,e),r(jc,e),r(Vc,e),r(Ks,e)})(dC);(function(e){var t=O.commonjsGlobal&&O.commonjsGlobal.__createBinding||(Object.create?function(n,i,a,o){o===void 0&&(o=a);var s=Object.getOwnPropertyDescriptor(i,a);(!s||("get"in s?!i.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,o,s)}:function(n,i,a,o){o===void 0&&(o=a),n[o]=i[a]}),r=O.commonjsGlobal&&O.commonjsGlobal.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(dC,e)})(Yt);class Mt extends V.AbstractTranslatableError{constructor(t,r){super(K_,{key:t,interpolationOptions:r},BA.t)}get status(){return this.interpolationOptions.status}}var kh=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};const Ci="api/datasources",zD="api/v2/datamodels";class gC{constructor(t){this.httpClient=t}getDataSourceFields(t){return kh(this,arguments,void 0,function*(r,n={}){var i,a;const{count:o=9999,offset:s=0,term:u,displayNameConfig:c}=n,d=V.getDataSourceName(r),h=HD(c);let p;if(h){const g=(i=n.live)!==null&&i!==void 0?i:((a=yield this.getDataSourceByTitle(d))===null||a===void 0?void 0:a.live)===!0;p=`${Ci}/${encodeURIComponent(d)}/fields/searchByDisplayName?isLive=${g}`}else p=`${Ci}/${encodeURIComponent(d)}/fields/search`;const m={offset:s,count:o};return u!==void 0&&(m.term=u),this.httpClient.post(p,m).catch(()=>{throw new Mt("errors.dataSourceNotFound",{dataSource:typeof r=="string"?r:r.title})})})}getDataSourceList(){const t=`${Ci}/?sharedWith=r,w`;return this.httpClient.get(t)}parseCalculatedDimension(t,r,n){const i=encodeURIComponent(V.getDataSourceName(t)),a=`${Ci}/${i}/calculated-dimension/parse`;return this.httpClient.post(a,{formula:r,context:n,isMaskedResponse:!1}).catch(o=>{throw o&&typeof o=="object"&&"status"in o&&o.status==="404"?new Mt("errors.calculatedDimensionParseNotSupported"):o})}getDataSourceByTitle(t){return kh(this,void 0,void 0,function*(){var r,n;return(n=((r=yield this.getDataSourceList())!==null&&r!==void 0?r:[]).find(a=>a.title===t))!==null&&n!==void 0?n:null})}getDataSourceSchema(t){const r=`${zD}/schema?title=${encodeURIComponent(t)}`;return this.httpClient.get(r)}sendJaqlRequest(t,r){const n=v0(t),i=new AbortController;return{responsePromise:this.httpClient.post(n,r,void 0,i.signal).then(a=>Array.isArray(a)?{values:[],metadata:[]}:a),abortHttpRequest:a=>i.abort(a)}}sendCountRowsRequest(t,r){const n=UD(t),i=new AbortController;return{responsePromise:this.httpClient.post(n,r,void 0,i.signal),abortHttpRequest:a=>i.abort(a)}}sendDownloadCsvRequest(t,r){const n=VD(t),i=new AbortController,a=new URLSearchParams;return a.append("data",encodeURIComponent(JSON.stringify(r))),{responsePromise:this.httpClient.post(n,a,{headers:{"Content-Type":"application/x-www-form-urlencoded"}},i.signal,{nonJSONBody:!0,returnBlob:!0}),abortHttpRequest:o=>i.abort(o)}}sendCancelJaqlQueryRequest(t,r){return this.sendCancelMultipleJaqlQueriesRequest([t],r)}sendCancelMultipleJaqlQueriesRequest(t,r){return kh(this,void 0,void 0,function*(){const n={queries:t.join(";")},i=WD(r);try{yield this.httpClient.post(i,n)}catch(a){if(a.status==="404"){const o=jD(r);yield this.httpClient.post(o,n)}else throw a}})}}function HD(e){return!!(e!=null&&e.enabled&&(e!=null&&e.useNewSearchByDisplayNameApi))}function WD(e){const t=encodeURIComponent(V.getDataSourceName(e));return`${Ci}/localhost/${t}/cancel_queries`}function jD(e){const t=encodeURIComponent(V.getDataSourceName(e));return`${Ci}/live/${t}/cancel_queries`}function v0(e){const t=encodeURIComponent(V.getDataSourceName(e));return`${Ci}/${t}/jaql`}function VD(e){return`${v0(e)}/csv`}function UD(e){return`${v0(e)}/countrows`}const GD=500;function qD(e,t=GD){const r=new Map;return(n,i,a)=>{const o=YD(n,i,a),s=r.get(o);if(s)return s;const u=e(n,i,a).catch(c=>{throw r.delete(o),c});if(r.size>=t){const c=r.keys().next().value;c!==void 0&&r.delete(c)}return r.set(o,u),u}}function YD(e,t,r){return[V.getDataSourceName(e),t,JSON.stringify(r)].join("\0")}var k1=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};const XD="text";function ZD(e,t,r){return k1(this,void 0,void 0,function*(){const n=e.metadata.filter(KD);yield Promise.all(n.map(i=>k1(this,void 0,void 0,function*(){var a;const{formula:o,context:s}=i.jaql,u=yield r(t,o!=null?o:"",s!=null?s:{});if(u!=null&&u.error)throw new Mt("errors.calculatedDimensionFormulaInvalid",{message:(a=u.message)!==null&&a!==void 0?a:""});i.jaql.datatype=(u==null?void 0:u.dataType)||XD})))})}function KD(e){var t;return((t=e.jaql)===null||t===void 0?void 0:t.type)===V.CALCULATED_DIMENSION_JAQL_TYPE&&e.jaql.formula!==void 0&&!!e.jaql.filter&&!e.jaql.datatype}var vC={exports:{}};/*! @preserve
6
+ * numeral.js
7
+ * version : 2.0.6
8
+ * author : Adam Draper
9
+ * license : MIT
10
+ * http://adamwdraper.github.com/Numeral-js/
11
+ */(function(e){(function(t,r){e.exports?e.exports=r():t.numeral=r()})(O.commonjsGlobal,function(){var t,r,n="2.0.6",i={},a={},o={currentLocale:"en",zeroFormat:null,nullFormat:null,defaultFormat:"0,0",scalePercentBy100:!0},s={currentLocale:o.currentLocale,zeroFormat:o.zeroFormat,nullFormat:o.nullFormat,defaultFormat:o.defaultFormat,scalePercentBy100:o.scalePercentBy100};function u(c,d){this._input=c,this._value=d}return t=function(c){var d,h,p,m;if(t.isNumeral(c))d=c.value();else if(c===0||typeof c=="undefined")d=0;else if(c===null||r.isNaN(c))d=null;else if(typeof c=="string")if(s.zeroFormat&&c===s.zeroFormat)d=0;else if(s.nullFormat&&c===s.nullFormat||!c.replace(/[^0-9]+/g,"").length)d=null;else{for(h in i)if(m=typeof i[h].regexps.unformat=="function"?i[h].regexps.unformat():i[h].regexps.unformat,m&&c.match(m)){p=i[h].unformat;break}p=p||t._.stringToNumber,d=p(c)}else d=Number(c)||null;return new u(c,d)},t.version=n,t.isNumeral=function(c){return c instanceof u},t._=r={numberToFormat:function(c,d,h){var p=a[t.options.currentLocale],m=!1,g=!1,b=0,_="",w=1e12,C=1e9,S=1e6,T=1e3,M="",P=!1,R,k,I,$,G,Y,B;if(c=c||0,k=Math.abs(c),t._.includes(d,"(")?(m=!0,d=d.replace(/[\(|\)]/g,"")):(t._.includes(d,"+")||t._.includes(d,"-"))&&(G=t._.includes(d,"+")?d.indexOf("+"):c<0?d.indexOf("-"):-1,d=d.replace(/[\+|\-]/g,"")),t._.includes(d,"a")&&(R=d.match(/a(k|m|b|t)?/),R=R?R[1]:!1,t._.includes(d," a")&&(_=" "),d=d.replace(new RegExp(_+"a[kmbt]?"),""),k>=w&&!R||R==="t"?(_+=p.abbreviations.trillion,c=c/w):k<w&&k>=C&&!R||R==="b"?(_+=p.abbreviations.billion,c=c/C):k<C&&k>=S&&!R||R==="m"?(_+=p.abbreviations.million,c=c/S):(k<S&&k>=T&&!R||R==="k")&&(_+=p.abbreviations.thousand,c=c/T)),t._.includes(d,"[.]")&&(g=!0,d=d.replace("[.]",".")),I=c.toString().split(".")[0],$=d.split(".")[1],Y=d.indexOf(","),b=(d.split(".")[0].split(",")[0].match(/0/g)||[]).length,$?(t._.includes($,"[")?($=$.replace("]",""),$=$.split("["),M=t._.toFixed(c,$[0].length+$[1].length,h,$[1].length)):M=t._.toFixed(c,$.length,h),I=M.split(".")[0],t._.includes(M,".")?M=p.delimiters.decimal+M.split(".")[1]:M="",g&&Number(M.slice(1))===0&&(M="")):I=t._.toFixed(c,0,h),_&&!R&&Number(I)>=1e3&&_!==p.abbreviations.trillion)switch(I=String(Number(I)/1e3),_){case p.abbreviations.thousand:_=p.abbreviations.million;break;case p.abbreviations.million:_=p.abbreviations.billion;break;case p.abbreviations.billion:_=p.abbreviations.trillion;break}if(t._.includes(I,"-")&&(I=I.slice(1),P=!0),I.length<b)for(var X=b-I.length;X>0;X--)I="0"+I;return Y>-1&&(I=I.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+p.delimiters.thousands)),d.indexOf(".")===0&&(I=""),B=I+M+(_||""),m?B=(m&&P?"(":"")+B+(m&&P?")":""):G>=0?B=G===0?(P?"-":"+")+B:B+(P?"-":"+"):P&&(B="-"+B),B},stringToNumber:function(c){var d=a[s.currentLocale],h=c,p={thousand:3,million:6,billion:9,trillion:12},m,g,b;if(s.zeroFormat&&c===s.zeroFormat)g=0;else if(s.nullFormat&&c===s.nullFormat||!c.replace(/[^0-9]+/g,"").length)g=null;else{g=1,d.delimiters.decimal!=="."&&(c=c.replace(/\./g,"").replace(d.delimiters.decimal,"."));for(m in p)if(b=new RegExp("[^a-zA-Z]"+d.abbreviations[m]+"(?:\\)|(\\"+d.currency.symbol+")?(?:\\))?)?$"),h.match(b)){g*=Math.pow(10,p[m]);break}g*=(c.split("-").length+Math.min(c.split("(").length-1,c.split(")").length-1))%2?1:-1,c=c.replace(/[^0-9\.]+/g,""),g*=Number(c)}return g},isNaN:function(c){return typeof c=="number"&&isNaN(c)},includes:function(c,d){return c.indexOf(d)!==-1},insert:function(c,d,h){return c.slice(0,h)+d+c.slice(h)},reduce:function(c,d){if(this===null)throw new TypeError("Array.prototype.reduce called on null or undefined");if(typeof d!="function")throw new TypeError(d+" is not a function");var h=Object(c),p=h.length>>>0,m=0,g;if(arguments.length===3)g=arguments[2];else{for(;m<p&&!(m in h);)m++;if(m>=p)throw new TypeError("Reduce of empty array with no initial value");g=h[m++]}for(;m<p;m++)m in h&&(g=d(g,h[m],m,h));return g},multiplier:function(c){var d=c.toString().split(".");return d.length<2?1:Math.pow(10,d[1].length)},correctionFactor:function(){var c=Array.prototype.slice.call(arguments);return c.reduce(function(d,h){var p=r.multiplier(h);return d>p?d:p},1)},toFixed:function(c,d,h,p){var m=c.toString().split("."),g=d-(p||0),b,_,w,C;return m.length===2?b=Math.min(Math.max(m[1].length,g),d):b=g,w=Math.pow(10,b),C=(h(c+"e+"+b)/w).toFixed(b),p>d-b&&(_=new RegExp("\\.?0{1,"+(p-(d-b))+"}$"),C=C.replace(_,"")),C}},t.options=s,t.formats=i,t.locales=a,t.locale=function(c){return c&&(s.currentLocale=c.toLowerCase()),s.currentLocale},t.localeData=function(c){if(!c)return a[s.currentLocale];if(c=c.toLowerCase(),!a[c])throw new Error("Unknown locale : "+c);return a[c]},t.reset=function(){for(var c in o)s[c]=o[c]},t.zeroFormat=function(c){s.zeroFormat=typeof c=="string"?c:null},t.nullFormat=function(c){s.nullFormat=typeof c=="string"?c:null},t.defaultFormat=function(c){s.defaultFormat=typeof c=="string"?c:"0.0"},t.register=function(c,d,h){if(d=d.toLowerCase(),this[c+"s"][d])throw new TypeError(d+" "+c+" already registered.");return this[c+"s"][d]=h,h},t.validate=function(c,d){var h,p,m,g,b,_,w,C;if(typeof c!="string"&&(c+="",console.warn&&console.warn("Numeral.js: Value is not string. It has been co-erced to: ",c)),c=c.trim(),c.match(/^\d+$/))return!0;if(c==="")return!1;try{w=t.localeData(d)}catch(S){w=t.localeData(t.locale())}return m=w.currency.symbol,b=w.abbreviations,h=w.delimiters.decimal,w.delimiters.thousands==="."?p="\\.":p=w.delimiters.thousands,C=c.match(/^[^\d]+/),C!==null&&(c=c.substr(1),C[0]!==m)||(C=c.match(/[^\d]+$/),C!==null&&(c=c.slice(0,-1),C[0]!==b.thousand&&C[0]!==b.million&&C[0]!==b.billion&&C[0]!==b.trillion))?!1:(_=new RegExp(p+"{2}"),c.match(/[^\d.,]/g)?!1:(g=c.split(h),g.length>2?!1:g.length<2?!!g[0].match(/^\d+.*\d$/)&&!g[0].match(_):g[0].length===1?!!g[0].match(/^\d+$/)&&!g[0].match(_)&&!!g[1].match(/^\d+$/):!!g[0].match(/^\d+.*\d$/)&&!g[0].match(_)&&!!g[1].match(/^\d+$/)))},t.fn=u.prototype={clone:function(){return t(this)},format:function(c,d){var h=this._value,p=c||s.defaultFormat,m,g,b;if(d=d||Math.round,h===0&&s.zeroFormat!==null)g=s.zeroFormat;else if(h===null&&s.nullFormat!==null)g=s.nullFormat;else{for(m in i)if(p.match(i[m].regexps.format)){b=i[m].format;break}b=b||t._.numberToFormat,g=b(h,p,d)}return g},value:function(){return this._value},input:function(){return this._input},set:function(c){return this._value=Number(c),this},add:function(c){var d=r.correctionFactor.call(null,this._value,c);function h(p,m,g,b){return p+Math.round(d*m)}return this._value=r.reduce([this._value,c],h,0)/d,this},subtract:function(c){var d=r.correctionFactor.call(null,this._value,c);function h(p,m,g,b){return p-Math.round(d*m)}return this._value=r.reduce([c],h,Math.round(this._value*d))/d,this},multiply:function(c){function d(h,p,m,g){var b=r.correctionFactor(h,p);return Math.round(h*b)*Math.round(p*b)/Math.round(b*b)}return this._value=r.reduce([this._value,c],d,1),this},divide:function(c){function d(h,p,m,g){var b=r.correctionFactor(h,p);return Math.round(h*b)/Math.round(p*b)}return this._value=r.reduce([this._value,c],d),this},difference:function(c){return Math.abs(t(this._value).subtract(c).value())}},t.register("locale","en",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(c){var d=c%10;return~~(c%100/10)===1?"th":d===1?"st":d===2?"nd":d===3?"rd":"th"},currency:{symbol:"$"}}),function(){t.register("format","bps",{regexps:{format:/(BPS)/,unformat:/(BPS)/},format:function(c,d,h){var p=t._.includes(d," BPS")?" ":"",m;return c=c*1e4,d=d.replace(/\s?BPS/,""),m=t._.numberToFormat(c,d,h),t._.includes(m,")")?(m=m.split(""),m.splice(-1,0,p+"BPS"),m=m.join("")):m=m+p+"BPS",m},unformat:function(c){return+(t._.stringToNumber(c)*1e-4).toFixed(15)}})}(),function(){var c={base:1e3,suffixes:["B","KB","MB","GB","TB","PB","EB","ZB","YB"]},d={base:1024,suffixes:["B","KiB","MiB","GiB","TiB","PiB","EiB","ZiB","YiB"]},h=c.suffixes.concat(d.suffixes.filter(function(m){return c.suffixes.indexOf(m)<0})),p=h.join("|");p="("+p.replace("B","B(?!PS)")+")",t.register("format","bytes",{regexps:{format:/([0\s]i?b)/,unformat:new RegExp(p)},format:function(m,g,b){var _,w=t._.includes(g,"ib")?d:c,C=t._.includes(g," b")||t._.includes(g," ib")?" ":"",S,T,M;for(g=g.replace(/\s?i?b/,""),S=0;S<=w.suffixes.length;S++)if(T=Math.pow(w.base,S),M=Math.pow(w.base,S+1),m===null||m===0||m>=T&&m<M){C+=w.suffixes[S],T>0&&(m=m/T);break}return _=t._.numberToFormat(m,g,b),_+C},unformat:function(m){var g=t._.stringToNumber(m),b,_;if(g){for(b=c.suffixes.length-1;b>=0;b--){if(t._.includes(m,c.suffixes[b])){_=Math.pow(c.base,b);break}if(t._.includes(m,d.suffixes[b])){_=Math.pow(d.base,b);break}}g*=_||1}return g}})}(),function(){t.register("format","currency",{regexps:{format:/(\$)/},format:function(c,d,h){var p=t.locales[t.options.currentLocale],m={before:d.match(/^([\+|\-|\(|\s|\$]*)/)[0],after:d.match(/([\+|\-|\)|\s|\$]*)$/)[0]},g,b,_;for(d=d.replace(/\s?\$\s?/,""),g=t._.numberToFormat(c,d,h),c>=0?(m.before=m.before.replace(/[\-\(]/,""),m.after=m.after.replace(/[\-\)]/,"")):c<0&&!t._.includes(m.before,"-")&&!t._.includes(m.before,"(")&&(m.before="-"+m.before),_=0;_<m.before.length;_++)switch(b=m.before[_],b){case"$":g=t._.insert(g,p.currency.symbol,_);break;case" ":g=t._.insert(g," ",_+p.currency.symbol.length-1);break}for(_=m.after.length-1;_>=0;_--)switch(b=m.after[_],b){case"$":g=_===m.after.length-1?g+p.currency.symbol:t._.insert(g,p.currency.symbol,-(m.after.length-(1+_)));break;case" ":g=_===m.after.length-1?g+" ":t._.insert(g," ",-(m.after.length-(1+_)+p.currency.symbol.length-1));break}return g}})}(),function(){t.register("format","exponential",{regexps:{format:/(e\+|e-)/,unformat:/(e\+|e-)/},format:function(c,d,h){var p,m=typeof c=="number"&&!t._.isNaN(c)?c.toExponential():"0e+0",g=m.split("e");return d=d.replace(/e[\+|\-]{1}0/,""),p=t._.numberToFormat(Number(g[0]),d,h),p+"e"+g[1]},unformat:function(c){var d=t._.includes(c,"e+")?c.split("e+"):c.split("e-"),h=Number(d[0]),p=Number(d[1]);p=t._.includes(c,"e-")?p*=-1:p;function m(g,b,_,w){var C=t._.correctionFactor(g,b),S=g*C*(b*C)/(C*C);return S}return t._.reduce([h,Math.pow(10,p)],m,1)}})}(),function(){t.register("format","ordinal",{regexps:{format:/(o)/},format:function(c,d,h){var p=t.locales[t.options.currentLocale],m,g=t._.includes(d," o")?" ":"";return d=d.replace(/\s?o/,""),g+=p.ordinal(c),m=t._.numberToFormat(c,d,h),m+g}})}(),function(){t.register("format","percentage",{regexps:{format:/(%)/,unformat:/(%)/},format:function(c,d,h){var p=t._.includes(d," %")?" ":"",m;return t.options.scalePercentBy100&&(c=c*100),d=d.replace(/\s?\%/,""),m=t._.numberToFormat(c,d,h),t._.includes(m,")")?(m=m.split(""),m.splice(-1,0,p+"%"),m=m.join("")):m=m+p+"%",m},unformat:function(c){var d=t._.stringToNumber(c);return t.options.scalePercentBy100?d*.01:d}})}(),function(){t.register("format","time",{regexps:{format:/(:)/,unformat:/(:)/},format:function(c,d,h){var p=Math.floor(c/60/60),m=Math.floor((c-p*60*60)/60),g=Math.round(c-p*60*60-m*60);return p+":"+(m<10?"0"+m:m)+":"+(g<10?"0"+g:g)},unformat:function(c){var d=c.split(":"),h=0;return d.length===3?(h=h+Number(d[0])*60*60,h=h+Number(d[1])*60,h=h+Number(d[2])):d.length===2&&(h=h+Number(d[0])*60,h=h+Number(d[1])),Number(h)}})}(),t})})(vC);var QD=vC.exports;const JD=O.getDefaultExportFromCjs(QD),eN=(e,t)=>{const r=nN(e);return tN(r,t)};function tN(e,t){return{columns:t==null?void 0:t.map(r=>({name:r.name,type:V.simpleColumnType(r.type)})),rows:rN(e)}}function rN(e){var t;let r=!1;const n=(t=e[0])===null||t===void 0?void 0:t.map((i,a)=>{const o=e.some(s=>"selected"in s[a]);return o&&(r=!0),o});return e.map(i=>{const a=r?n.some((o,s)=>o&&!i[s].selected):void 0;return i.map(o=>a!==void 0?{data:o.data,text:o.text,blur:a}:{data:o.data,text:o.text})})}function nN({values:e=[],metadata:t=[]}){var r,n,i,a;e[0]&&!Array.isArray(e[0])&&(e=[e]);for(let o=0;o<e.length;o++){const s=e[o];for(let u=0;u<s.length;u++)t[u].format&&(!((n=(r=t[u])===null||r===void 0?void 0:r.format)===null||n===void 0)&&n.number)&&(s[u].text=JD(s[u].data).format((a=(i=t[u])===null||i===void 0?void 0:i.format)===null||a===void 0?void 0:a.number))}return e}var Wr=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};class iN extends Yt.AbstractTaskManager{constructor(t,r){super(),this.sentRequestsAbortersMap=new Map,this.executeQuerySending=super.createFlow([new Yt.Step("PREPARE_JAQL_PAYLOAD",this.prepareJaqlPayload.bind(this),()=>Wr(this,void 0,void 0,function*(){})),new Yt.Step("SEND_JAQL_QUERY",this.sendJaqlQuery.bind(this),this.cancelDataRetrievalQuery.bind(this))]),this.executeCountRowsSending=super.createFlow([new Yt.Step("PREPARE_JAQL_PAYLOAD",this.prepareCountRowsJaqlPayload.bind(this),()=>Wr(this,void 0,void 0,function*(){})),new Yt.Step("SEND_COUNT_ROWS_QUERY",this.sendCountRowsQuery.bind(this),this.cancelDataRetrievalQuery.bind(this))]),this.executeDownloadCsvSending=super.createFlow([new Yt.Step("PREPARE_JAQL_PAYLOAD",this.prepareJaqlPayload.bind(this),()=>Wr(this,void 0,void 0,function*(){})),new Yt.Step("SEND_DOWNLOAD_CSV_QUERY",this.sendCsvQuery.bind(this),this.cancelDataRetrievalQuery.bind(this))]),this.executePivotQuerySending=super.createFlow([new Yt.Step("PREPARE_JAQL_PAYLOAD",this.preparePivotJaqlPayload.bind(this),()=>Wr(this,void 0,void 0,function*(){})),new Yt.Step("SEND_JAQL_QUERY",this.sendPivotJaqlQuery.bind(this),this.cancelPivotJaqlQuery.bind(this))]),this.queryApi=t,this.pivotQueryClient=r,this.parseCalculatedDimension=qD(this.queryApi.parseCalculatedDimension.bind(this.queryApi))}enrichJaqlPayload(t,r){return Wr(this,void 0,void 0,function*(){return yield ZD(t,r,this.parseCalculatedDimension),t})}prepareJaqlPayload(t){return Wr(this,void 0,void 0,function*(){const{queryDescription:r,executionConfig:n}=t.passport,i=yield this.enrichJaqlPayload(V.getJaqlQueryPayload(r,n.shouldSkipHighlightsWithoutAttributes),r.dataSource),a=t.passport.executionConfig.onBeforeQuery;return a?a(i):i})}sendJaqlQuery(t,r){return Wr(this,void 0,void 0,function*(){const{queryDescription:n,taskId:i}=t.passport,{responsePromise:a,abortHttpRequest:o}=this.queryApi.sendJaqlRequest(t.passport.queryDescription.dataSource,r);this.sentRequestsAbortersMap.set(i,o);const s=yield a.finally(()=>{this.sentRequestsAbortersMap.delete(i)});aN(s);const u=[...n.attributes,...n.measures],c=(s.headers||[]).slice(u.length).map(d=>({name:d,type:"number"}));return eN(s,[...u,...c])})}prepareCountRowsJaqlPayload(t){return Wr(this,void 0,void 0,function*(){const{queryDescription:r,executionConfig:n}=t.passport,i=Object.assign(Object.assign({},r),{count:void 0,offset:void 0}),a=yield this.enrichJaqlPayload(V.getJaqlQueryPayload(i,n.shouldSkipHighlightsWithoutAttributes),r.dataSource),o=n.onBeforeQuery;return o?o(a):a})}sendCountRowsQuery(t,r){return Wr(this,void 0,void 0,function*(){const{taskId:n}=t.passport,{responsePromise:i,abortHttpRequest:a}=this.queryApi.sendCountRowsRequest(t.passport.queryDescription.dataSource,r);this.sentRequestsAbortersMap.set(n,a);const o=yield i.finally(()=>{this.sentRequestsAbortersMap.delete(n)});return oN(o),o.countRows})}sendCsvQuery(t,r){return Wr(this,void 0,void 0,function*(){const{taskId:n}=t.passport,{responsePromise:i,abortHttpRequest:a}=this.queryApi.sendDownloadCsvRequest(t.passport.queryDescription.dataSource,r);return this.sentRequestsAbortersMap.set(n,a),i.finally(()=>{this.sentRequestsAbortersMap.delete(n)})})}cancelDataRetrievalQuery(t){const r=t.passport.taskId,n=this.sentRequestsAbortersMap.get(r);return n&&(n(),this.sentRequestsAbortersMap.delete(r)),this.queryApi.sendCancelJaqlQueryRequest(r,t.passport.queryDescription.dataSource)}preparePivotJaqlPayload(t){return Wr(this,void 0,void 0,function*(){const{pivotQueryDescription:r,executionConfig:n}=t.passport,i=yield this.enrichJaqlPayload(V.getPivotJaqlQueryPayload(r,n.shouldSkipHighlightsWithoutAttributes),r.dataSource),a=t.passport.executionConfig.onBeforeQuery;return a?a(i):i})}sendPivotJaqlQuery(t,r){var n;const{pivotQueryDescription:i}=t.passport;return this.pivotQueryClient.queryData(r,!0,(n=i.count)!==null&&n!==void 0?n:lN,!1)}cancelPivotJaqlQuery(t){const r=t.passport.taskId,n=this.sentRequestsAbortersMap.get(r);return n&&(n(),this.sentRequestsAbortersMap.delete(r)),this.queryApi.sendCancelJaqlQueryRequest(r,t.passport.pivotQueryDescription.dataSource)}}function aN(e){if(!e)throw new Mt("errors.noJaqlResponse");if(e.error){const t=[e.details,e.database].filter(Boolean).join(" ");throw new Error(t)}}function oN(e){if(!e||typeof e.countRows!="number")throw new Mt("errors.invalidCountRowsResponse")}class Lh extends Yt.TaskPassport{constructor(t,r,n){super(),this.queryDescription=r,this.type=t,this.executionConfig=n}}class sN extends Yt.TaskPassport{constructor(t,r,n){super(),this.pivotQueryDescription=r,this.type=t,this.executionConfig=n}}var L1=function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{c(n.next(d))}catch(h){o(h)}}function u(d){try{c(n.throw(d))}catch(h){o(h)}}function c(d){d.done?a(d.value):i(d.value).then(s,u)}c((n=n.apply(e,t||[])).next())})};const lN=2e4,tu="Unspecified reason";class uN{constructor(t,r=new cC(t.url,t.auth),n){cN(t),this.queryApi=new gC(t),this.taskManager=new iN(this.queryApi,r),this.shouldSkipHighlightsWithoutAttributes=n!=null?n:!1}executeQuery(t,r){const n=new Lh("SEND_JAQL_QUERY",t,Object.assign(Object.assign({},r||{}),{shouldSkipHighlightsWithoutAttributes:this.shouldSkipHighlightsWithoutAttributes||!1}));return{resultPromise:new Promise((i,a)=>{Oh(t),this.taskManager.executeQuerySending(n).then(o=>{o.status===Yt.ExecutionResultStatus.SUCCESS?i(o.result):a(o.error)})}),cancel:i=>this.taskManager.cancel(n.taskId,i||tu)}}executeCountRowsQuery(t,r){const n=new Lh("SEND_COUNT_ROWS_QUERY",t,Object.assign(Object.assign({},r||{}),{shouldSkipHighlightsWithoutAttributes:this.shouldSkipHighlightsWithoutAttributes||!1}));return{resultPromise:new Promise((i,a)=>{Oh(t),this.taskManager.executeCountRowsSending(n).then(o=>{o.status===Yt.ExecutionResultStatus.SUCCESS?i(o.result):a(o.error)})}),cancel:i=>this.taskManager.cancel(n.taskId,i||tu)}}executeCsvQuery(t,r){const n=new Lh("SEND_DOWNLOAD_CSV_QUERY",t,Object.assign(Object.assign({},r||{}),{shouldSkipHighlightsWithoutAttributes:this.shouldSkipHighlightsWithoutAttributes||!1}));return{resultPromise:new Promise((i,a)=>{Oh(t),this.taskManager.executeDownloadCsvSending(n).then(o=>{o.status===Yt.ExecutionResultStatus.SUCCESS?i(o.result):a(o.error)})}),cancel:i=>this.taskManager.cancel(n.taskId,i||tu)}}executePivotQuery(t,r){const n=new sN("SEND_JAQL_QUERY",t,Object.assign(Object.assign({},r||{}),{shouldSkipHighlightsWithoutAttributes:this.shouldSkipHighlightsWithoutAttributes||!1}));return{resultPromise:new Promise((i,a)=>{yC(t),this.taskManager.executePivotQuerySending(n).then(o=>{o.status===Yt.ExecutionResultStatus.SUCCESS?i(o.result):a(o.error)})}),cancel:i=>this.taskManager.cancel(n.taskId,i||tu)}}getDataSourceFields(t){return L1(this,arguments,void 0,function*(r,n=9999,i=0){return(yield this.queryApi.getDataSourceFields(r,{count:n,offset:i}))||[]})}getDataSourceSchema(t){return this.queryApi.getDataSourceSchema(t)}getDataSourceList(){return L1(this,void 0,void 0,function*(){return(yield this.queryApi.getDataSourceList())||[]})}}function Oh(e){const{attributes:t,measures:r,filters:n,highlights:i,count:a,offset:o}=e;if(a&&a<0)throw new Mt("errors.invalidCountNegative",{count:a.toString()});if(o&&o<0)throw new Mt("errors.invalidOffset",{offset:o.toString()});if(t.length+r.length===0)throw new Mt("errors.noDimensionsOrMeasures");t.forEach(s=>{if(!s.skipValidation&&!V.MetadataTypes.isAttribute(s)){const{name:u}=s;throw new Mt("errors.invalidAttribute",{attributeName:u})}}),r.forEach(s=>{if(!s.skipValidation&&!V.MetadataTypes.isMeasure(s))throw new Mt("errors.invalidMeasure",{measureName:s.name})}),n.forEach(s=>{if(!s.skipValidation&&!V.MetadataTypes.isFilter(s))throw new Mt("errors.invalidFilter",{filterName:s.name})}),i.forEach(s=>{if(!s.skipValidation&&!V.MetadataTypes.isFilter(s))throw new Mt("errors.invalidHighlight",{highlightName:s.name})})}function yC(e){const{rowsAttributes:t,columnsAttributes:r,measures:n,filters:i,highlights:a,count:o,offset:s}=e;if(o&&o<0)throw new Mt("errors.invalidCountNegative",{count:o.toString()});if(s&&s<0)throw new Mt("errors.invalidOffset",{offset:s.toString()});if(t.length+r.length+n.length===0)throw new Mt("errors.noDimensionsOrMeasures");i.forEach(u=>{if(!u.skipValidation&&!V.MetadataTypes.isFilter(u))throw new Mt("errors.invalidFilter",{filterName:u.name})}),a.forEach(u=>{if(!u.skipValidation&&!V.MetadataTypes.isFilter(u))throw new Mt("errors.invalidHighlight",{highlightName:u.name})})}function cN(e){if(!e)throw new Mt("errors.missingHttpClient");if(!e.post)throw new Mt("errors.missingPostMethod")}function ur(e){var o,s;const{app:t,queryDescription:r,executionConfig:n}=e;return(((s=(o=t==null?void 0:t.settings.queryCacheConfig)==null?void 0:o.enabled)!=null?s:!1)?V.executeQueryWithCache:V.executeQuery)(r,t,n)}const dN=(e,t)=>{const r=E.getPaletteColor(t,0),n=E.toGray(r),i=E.scaleBrightness(r,-.2),a=e.minColor===E.DEFAULT_COLOR||e.minColor===n,o=e.maxColor===E.DEFAULT_COLOR||e.maxColor===i;return a&&o?"auto":a?"max":o?"min":"both"},hN=(e,t)=>{let r={type:"range",steps:e.steps};if(e.rangeMode!=="auto"){const o=parseFloat(`${e.minvalue}`),s=parseFloat(`${e.midvalue}`),u=parseFloat(`${e.maxvalue}`);r=D(D(D(D({},r),o&&{minValue:o}),s&&{midValue:s}),u&&{maxValue:u})}const n=E.getPaletteColor(t,0),i=E.scaleBrightness(n,.2),a=E.scaleBrightness(n,-.2);switch(e.rangeMode){case"auto":return z(D({},r),{minColor:E.toGray(n),maxColor:a});case"both":return z(D({},r),{minColor:e.min||i,maxColor:e.max||a});case"min":return z(D({},r),{minColor:e.min||i,maxColor:E.DEFAULT_COLOR});case"max":return z(D({},r),{minColor:E.DEFAULT_COLOR,maxColor:e.max||a})}},bC=(e,t)=>{if(e!==void 0)switch(e.type){case"color":return D({type:"uniform",color:e.color||E.getPaletteColor(t,e.colorIndex||0)},e.colorIndex!==void 0&&{colorIndex:e.colorIndex});case"range":return hN(e,t);case"condition":return{type:"conditional",conditions:e.conditions.filter(r=>typeof r.expression=="string").map(({color:r,expression:n,operator:i})=>({color:r,expression:n,operator:i})),defaultColor:E.getPaletteColor(t,0)};default:return E.getUniformColorOptionsFromString(E.getPaletteColor(t,0))}},_C=e=>e.replace(/%46/g,".").replace(/%36/g,"$"),wC=e=>Object.entries(e).reduce((t,[r,{color:n}])=>(t[_C(r)]=n,t),{}),fN=e=>Object.entries(e).reduce((t,[r,{color:n,isHandPickedColor:i}])=>(i&&n&&(t[_C(r)]=n),t),{}),pN=(e,t)=>{if(e===void 0)return;const r=E.getPaletteColor(t,0);if(typeof e=="string")return{type:"color",color:e};switch(e.type){case"uniform":return z(D({type:"color",color:e.color},e.colorIndex!==void 0&&{colorIndex:e.colorIndex}),{isHandPickedColor:e.colorIndex===void 0});case"range":{const n=E.getPaletteColor(t,0),i=E.toGray(n),a=E.scaleBrightness(n,-.2),o=dN(e,t),s={type:"range",steps:e.steps||5,rangeMode:o,min:o==="max"?i:e.minColor,max:o==="min"?a:e.maxColor};return s.rangeMode!=="auto"&&(e.minValue!==void 0&&(s.minvalue=e.minValue.toString()),e.midValue!==void 0&&(s.midvalue=e.midValue.toString()),e.maxValue!==void 0&&(s.maxvalue=e.maxValue.toString())),s}case"conditional":return{type:"condition",conditions:(e.conditions||[]).filter(n=>typeof n.expression=="string").map(({color:n,expression:i,operator:a})=>({color:n||r,expression:i,operator:a}))};default:return{type:"color",color:r,colorIndex:0}}},mN=e=>e.reduce((t,r)=>{var n,i;return(n=r.format)!=null&&n.members&&(t[V.normalizeName(r.jaql.title)]=wC((i=r.format)==null?void 0:i.members)),t},{}),gN=E.createDataColoringFunction({getValueFromDataStructure:e=>e.originalValue,applyColorToDataStructure:(e,t)=>z(D({},e),{color:t})}),vN=bC({type:"range",steps:5,rangeMode:"auto"}),yN=(e,t,r)=>{var u,c,d;const n=E.getColumnByName(t,e.geo.column.name),i=E.getColumnByName(t,(c=(u=e.color)==null?void 0:u.column.name)!=null?c:e.geo.column.name);if(!n||!i)throw new V.TranslatableError("errors.requiredColumnMissing",{hint:"geo or color column is missing for Areamap"});const a=(d=r==null?void 0:r.defaultNumberFormattingEnabled)!=null?d:!0,o=t.rows.map(h=>{var g;const p=E.getValue(h,i),m=E.formatNumberWithFallback(p,(g=e.color)==null?void 0:g.numberFormatConfig,a,E.applyFormatPlainText);return{geoName:E.getValue(h,n),originalValue:p,formattedOriginalValue:m}});let s;return e.color&&(s=gN(o,e.color.color||vN)),{type:"areamap",geoData:s||o}},bN={loadData:ur,getChartData:yN},y0=50,_N=1e3,wN=500,ec=1e5,Kt={lineType:"straight",stackType:"classic",legend:{enabled:!0,position:"bottom"},lineWidth:2,marker:{enabled:!1,size:"small",fill:"full"},xAxis:{type:"linear",enabled:!0,titleEnabled:!0,title:"X Axis title",gridLine:!0,labels:!0,min:null,max:null,tickInterval:null},yAxis:{type:"linear",enabled:!0,titleEnabled:!0,title:"Y Axis title",gridLine:!0,labels:!0,min:null,max:null,tickInterval:null},autoZoom:{enabled:!0},pieType:E.DefaultPieType,funnelType:E.DefaultFunnelType,funnelSize:E.DefaultFunnelSize,funnelDirection:E.DefaultFunnelDirection,indicatorType:"numeric",numericSubtype:"numericSimple",skin:"vertical",indicatorComponents:{title:{shouldBeShown:!1,text:""},secondaryTitle:{text:""},ticks:{shouldBeShown:!0},labels:{shouldBeShown:!0}},dataLimits:{seriesCapacity:y0,categoriesCapacity:ec}},CN={translateStyleOptionsToDesignOptions:function(e){return z(D({},Kt),{mapType:e.mapType||"world"})},isCorrectStyleOptions:function(e){return typeof e=="object"&&e!==null}};var qf={exports:{}};/* @preserve
12
+ * Leaflet 1.9.4, a JS library for interactive maps. https://leafletjs.com
13
+ * (c) 2010-2023 Vladimir Agafonkin, (c) 2010-2011 CloudMade
14
+ */(function(e,t){(function(r,n){n(t)})(O.commonjsGlobal,function(r){var n="1.9.4";function i(l){var f,v,x,A;for(v=1,x=arguments.length;v<x;v++){A=arguments[v];for(f in A)l[f]=A[f]}return l}var a=Object.create||function(){function l(){}return function(f){return l.prototype=f,new l}}();function o(l,f){var v=Array.prototype.slice;if(l.bind)return l.bind.apply(l,v.call(arguments,1));var x=v.call(arguments,2);return function(){return l.apply(f,x.length?x.concat(v.call(arguments)):arguments)}}var s=0;function u(l){return"_leaflet_id"in l||(l._leaflet_id=++s),l._leaflet_id}function c(l,f,v){var x,A,F,K;return K=function(){x=!1,A&&(F.apply(v,A),A=!1)},F=function(){x?A=arguments:(l.apply(v,arguments),setTimeout(K,f),x=!0)},F}function d(l,f,v){var x=f[1],A=f[0],F=x-A;return l===x&&v?l:((l-A)%F+F)%F+A}function h(){return!1}function p(l,f){if(f===!1)return l;var v=Math.pow(10,f===void 0?6:f);return Math.round(l*v)/v}function m(l){return l.trim?l.trim():l.replace(/^\s+|\s+$/g,"")}function g(l){return m(l).split(/\s+/)}function b(l,f){Object.prototype.hasOwnProperty.call(l,"options")||(l.options=l.options?a(l.options):{});for(var v in f)l.options[v]=f[v];return l.options}function _(l,f,v){var x=[];for(var A in l)x.push(encodeURIComponent(v?A.toUpperCase():A)+"="+encodeURIComponent(l[A]));return(!f||f.indexOf("?")===-1?"?":"&")+x.join("&")}var w=/\{ *([\w_ -]+) *\}/g;function C(l,f){return l.replace(w,function(v,x){var A=f[x];if(A===void 0)throw new Error("No value provided for variable "+v);return typeof A=="function"&&(A=A(f)),A})}var S=Array.isArray||function(l){return Object.prototype.toString.call(l)==="[object Array]"};function T(l,f){for(var v=0;v<l.length;v++)if(l[v]===f)return v;return-1}var M="data:image/gif;base64,R0lGODlhAQABAAD/ACwAAAAAAQABAAACADs=";function P(l){return window["webkit"+l]||window["moz"+l]||window["ms"+l]}var R=0;function k(l){var f=+new Date,v=Math.max(0,16-(f-R));return R=f+v,window.setTimeout(l,v)}var I=window.requestAnimationFrame||P("RequestAnimationFrame")||k,$=window.cancelAnimationFrame||P("CancelAnimationFrame")||P("CancelRequestAnimationFrame")||function(l){window.clearTimeout(l)};function G(l,f,v){if(v&&I===k)l.call(f);else return I.call(window,o(l,f))}function Y(l){l&&$.call(window,l)}var B={__proto__:null,extend:i,create:a,bind:o,get lastId(){return s},stamp:u,throttle:c,wrapNum:d,falseFn:h,formatNum:p,trim:m,splitWords:g,setOptions:b,getParamString:_,template:C,isArray:S,indexOf:T,emptyImageUrl:M,requestFn:I,cancelFn:$,requestAnimFrame:G,cancelAnimFrame:Y};function X(){}X.extend=function(l){var f=function(){b(this),this.initialize&&this.initialize.apply(this,arguments),this.callInitHooks()},v=f.__super__=this.prototype,x=a(v);x.constructor=f,f.prototype=x;for(var A in this)Object.prototype.hasOwnProperty.call(this,A)&&A!=="prototype"&&A!=="__super__"&&(f[A]=this[A]);return l.statics&&i(f,l.statics),l.includes&&(U(l.includes),i.apply(null,[x].concat(l.includes))),i(x,l),delete x.statics,delete x.includes,x.options&&(x.options=v.options?a(v.options):{},i(x.options,l.options)),x._initHooks=[],x.callInitHooks=function(){if(!this._initHooksCalled){v.callInitHooks&&v.callInitHooks.call(this),this._initHooksCalled=!0;for(var F=0,K=x._initHooks.length;F<K;F++)x._initHooks[F].call(this)}},f},X.include=function(l){var f=this.prototype.options;return i(this.prototype,l),l.options&&(this.prototype.options=f,this.mergeOptions(l.options)),this},X.mergeOptions=function(l){return i(this.prototype.options,l),this},X.addInitHook=function(l){var f=Array.prototype.slice.call(arguments,1),v=typeof l=="function"?l:function(){this[l].apply(this,f)};return this.prototype._initHooks=this.prototype._initHooks||[],this.prototype._initHooks.push(v),this};function U(l){if(!(typeof L=="undefined"||!L||!L.Mixin)){l=S(l)?l:[l];for(var f=0;f<l.length;f++)l[f]===L.Mixin.Events&&console.warn("Deprecated include of L.Mixin.Events: this property will be removed in future releases, please inherit from L.Evented instead.",new Error().stack)}}var Q={on:function(l,f,v){if(typeof l=="object")for(var x in l)this._on(x,l[x],f);else{l=g(l);for(var A=0,F=l.length;A<F;A++)this._on(l[A],f,v)}return this},off:function(l,f,v){if(!arguments.length)delete this._events;else if(typeof l=="object")for(var x in l)this._off(x,l[x],f);else{l=g(l);for(var A=arguments.length===1,F=0,K=l.length;F<K;F++)A?this._off(l[F]):this._off(l[F],f,v)}return this},_on:function(l,f,v,x){if(typeof f!="function"){console.warn("wrong listener type: "+typeof f);return}if(this._listens(l,f,v)===!1){v===this&&(v=void 0);var A={fn:f,ctx:v};x&&(A.once=!0),this._events=this._events||{},this._events[l]=this._events[l]||[],this._events[l].push(A)}},_off:function(l,f,v){var x,A,F;if(this._events&&(x=this._events[l],!!x)){if(arguments.length===1){if(this._firingCount)for(A=0,F=x.length;A<F;A++)x[A].fn=h;delete this._events[l];return}if(typeof f!="function"){console.warn("wrong listener type: "+typeof f);return}var K=this._listens(l,f,v);if(K!==!1){var te=x[K];this._firingCount&&(te.fn=h,this._events[l]=x=x.slice()),x.splice(K,1)}}},fire:function(l,f,v){if(!this.listens(l,v))return this;var x=i({},f,{type:l,target:this,sourceTarget:f&&f.sourceTarget||this});if(this._events){var A=this._events[l];if(A){this._firingCount=this._firingCount+1||1;for(var F=0,K=A.length;F<K;F++){var te=A[F],re=te.fn;te.once&&this.off(l,re,te.ctx),re.call(te.ctx||this,x)}this._firingCount--}}return v&&this._propagateEvent(x),this},listens:function(l,f,v,x){typeof l!="string"&&console.warn('"string" type argument expected');var A=f;typeof f!="function"&&(x=!!f,A=void 0,v=void 0);var F=this._events&&this._events[l];if(F&&F.length&&this._listens(l,A,v)!==!1)return!0;if(x){for(var K in this._eventParents)if(this._eventParents[K].listens(l,f,v,x))return!0}return!1},_listens:function(l,f,v){if(!this._events)return!1;var x=this._events[l]||[];if(!f)return!!x.length;v===this&&(v=void 0);for(var A=0,F=x.length;A<F;A++)if(x[A].fn===f&&x[A].ctx===v)return A;return!1},once:function(l,f,v){if(typeof l=="object")for(var x in l)this._on(x,l[x],f,!0);else{l=g(l);for(var A=0,F=l.length;A<F;A++)this._on(l[A],f,v,!0)}return this},addEventParent:function(l){return this._eventParents=this._eventParents||{},this._eventParents[u(l)]=l,this},removeEventParent:function(l){return this._eventParents&&delete this._eventParents[u(l)],this},_propagateEvent:function(l){for(var f in this._eventParents)this._eventParents[f].fire(l.type,i({layer:l.target,propagatedFrom:l.target},l),!0)}};Q.addEventListener=Q.on,Q.removeEventListener=Q.clearAllEventListeners=Q.off,Q.addOneTimeEventListener=Q.once,Q.fireEvent=Q.fire,Q.hasEventListeners=Q.listens;var W=X.extend(Q);function q(l,f,v){this.x=v?Math.round(l):l,this.y=v?Math.round(f):f}var ee=Math.trunc||function(l){return l>0?Math.floor(l):Math.ceil(l)};q.prototype={clone:function(){return new q(this.x,this.y)},add:function(l){return this.clone()._add(Z(l))},_add:function(l){return this.x+=l.x,this.y+=l.y,this},subtract:function(l){return this.clone()._subtract(Z(l))},_subtract:function(l){return this.x-=l.x,this.y-=l.y,this},divideBy:function(l){return this.clone()._divideBy(l)},_divideBy:function(l){return this.x/=l,this.y/=l,this},multiplyBy:function(l){return this.clone()._multiplyBy(l)},_multiplyBy:function(l){return this.x*=l,this.y*=l,this},scaleBy:function(l){return new q(this.x*l.x,this.y*l.y)},unscaleBy:function(l){return new q(this.x/l.x,this.y/l.y)},round:function(){return this.clone()._round()},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},floor:function(){return this.clone()._floor()},_floor:function(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this},ceil:function(){return this.clone()._ceil()},_ceil:function(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this},trunc:function(){return this.clone()._trunc()},_trunc:function(){return this.x=ee(this.x),this.y=ee(this.y),this},distanceTo:function(l){l=Z(l);var f=l.x-this.x,v=l.y-this.y;return Math.sqrt(f*f+v*v)},equals:function(l){return l=Z(l),l.x===this.x&&l.y===this.y},contains:function(l){return l=Z(l),Math.abs(l.x)<=Math.abs(this.x)&&Math.abs(l.y)<=Math.abs(this.y)},toString:function(){return"Point("+p(this.x)+", "+p(this.y)+")"}};function Z(l,f,v){return l instanceof q?l:S(l)?new q(l[0],l[1]):l==null?l:typeof l=="object"&&"x"in l&&"y"in l?new q(l.x,l.y):new q(l,f,v)}function J(l,f){if(l)for(var v=f?[l,f]:l,x=0,A=v.length;x<A;x++)this.extend(v[x])}J.prototype={extend:function(l){var f,v;if(!l)return this;if(l instanceof q||typeof l[0]=="number"||"x"in l)f=v=Z(l);else if(l=ne(l),f=l.min,v=l.max,!f||!v)return this;return!this.min&&!this.max?(this.min=f.clone(),this.max=v.clone()):(this.min.x=Math.min(f.x,this.min.x),this.max.x=Math.max(v.x,this.max.x),this.min.y=Math.min(f.y,this.min.y),this.max.y=Math.max(v.y,this.max.y)),this},getCenter:function(l){return Z((this.min.x+this.max.x)/2,(this.min.y+this.max.y)/2,l)},getBottomLeft:function(){return Z(this.min.x,this.max.y)},getTopRight:function(){return Z(this.max.x,this.min.y)},getTopLeft:function(){return this.min},getBottomRight:function(){return this.max},getSize:function(){return this.max.subtract(this.min)},contains:function(l){var f,v;return typeof l[0]=="number"||l instanceof q?l=Z(l):l=ne(l),l instanceof J?(f=l.min,v=l.max):f=v=l,f.x>=this.min.x&&v.x<=this.max.x&&f.y>=this.min.y&&v.y<=this.max.y},intersects:function(l){l=ne(l);var f=this.min,v=this.max,x=l.min,A=l.max,F=A.x>=f.x&&x.x<=v.x,K=A.y>=f.y&&x.y<=v.y;return F&&K},overlaps:function(l){l=ne(l);var f=this.min,v=this.max,x=l.min,A=l.max,F=A.x>f.x&&x.x<v.x,K=A.y>f.y&&x.y<v.y;return F&&K},isValid:function(){return!!(this.min&&this.max)},pad:function(l){var f=this.min,v=this.max,x=Math.abs(f.x-v.x)*l,A=Math.abs(f.y-v.y)*l;return ne(Z(f.x-x,f.y-A),Z(v.x+x,v.y+A))},equals:function(l){return l?(l=ne(l),this.min.equals(l.getTopLeft())&&this.max.equals(l.getBottomRight())):!1}};function ne(l,f){return!l||l instanceof J?l:new J(l,f)}function oe(l,f){if(l)for(var v=f?[l,f]:l,x=0,A=v.length;x<A;x++)this.extend(v[x])}oe.prototype={extend:function(l){var f=this._southWest,v=this._northEast,x,A;if(l instanceof se)x=l,A=l;else if(l instanceof oe){if(x=l._southWest,A=l._northEast,!x||!A)return this}else return l?this.extend(ue(l)||ae(l)):this;return!f&&!v?(this._southWest=new se(x.lat,x.lng),this._northEast=new se(A.lat,A.lng)):(f.lat=Math.min(x.lat,f.lat),f.lng=Math.min(x.lng,f.lng),v.lat=Math.max(A.lat,v.lat),v.lng=Math.max(A.lng,v.lng)),this},pad:function(l){var f=this._southWest,v=this._northEast,x=Math.abs(f.lat-v.lat)*l,A=Math.abs(f.lng-v.lng)*l;return new oe(new se(f.lat-x,f.lng-A),new se(v.lat+x,v.lng+A))},getCenter:function(){return new se((this._southWest.lat+this._northEast.lat)/2,(this._southWest.lng+this._northEast.lng)/2)},getSouthWest:function(){return this._southWest},getNorthEast:function(){return this._northEast},getNorthWest:function(){return new se(this.getNorth(),this.getWest())},getSouthEast:function(){return new se(this.getSouth(),this.getEast())},getWest:function(){return this._southWest.lng},getSouth:function(){return this._southWest.lat},getEast:function(){return this._northEast.lng},getNorth:function(){return this._northEast.lat},contains:function(l){typeof l[0]=="number"||l instanceof se||"lat"in l?l=ue(l):l=ae(l);var f=this._southWest,v=this._northEast,x,A;return l instanceof oe?(x=l.getSouthWest(),A=l.getNorthEast()):x=A=l,x.lat>=f.lat&&A.lat<=v.lat&&x.lng>=f.lng&&A.lng<=v.lng},intersects:function(l){l=ae(l);var f=this._southWest,v=this._northEast,x=l.getSouthWest(),A=l.getNorthEast(),F=A.lat>=f.lat&&x.lat<=v.lat,K=A.lng>=f.lng&&x.lng<=v.lng;return F&&K},overlaps:function(l){l=ae(l);var f=this._southWest,v=this._northEast,x=l.getSouthWest(),A=l.getNorthEast(),F=A.lat>f.lat&&x.lat<v.lat,K=A.lng>f.lng&&x.lng<v.lng;return F&&K},toBBoxString:function(){return[this.getWest(),this.getSouth(),this.getEast(),this.getNorth()].join(",")},equals:function(l,f){return l?(l=ae(l),this._southWest.equals(l.getSouthWest(),f)&&this._northEast.equals(l.getNorthEast(),f)):!1},isValid:function(){return!!(this._southWest&&this._northEast)}};function ae(l,f){return l instanceof oe?l:new oe(l,f)}function se(l,f,v){if(isNaN(l)||isNaN(f))throw new Error("Invalid LatLng object: ("+l+", "+f+")");this.lat=+l,this.lng=+f,v!==void 0&&(this.alt=+v)}se.prototype={equals:function(l,f){if(!l)return!1;l=ue(l);var v=Math.max(Math.abs(this.lat-l.lat),Math.abs(this.lng-l.lng));return v<=(f===void 0?1e-9:f)},toString:function(l){return"LatLng("+p(this.lat,l)+", "+p(this.lng,l)+")"},distanceTo:function(l){return pe.distance(this,ue(l))},wrap:function(){return pe.wrapLatLng(this)},toBounds:function(l){var f=180*l/40075017,v=f/Math.cos(Math.PI/180*this.lat);return ae([this.lat-f,this.lng-v],[this.lat+f,this.lng+v])},clone:function(){return new se(this.lat,this.lng,this.alt)}};function ue(l,f,v){return l instanceof se?l:S(l)&&typeof l[0]!="object"?l.length===3?new se(l[0],l[1],l[2]):l.length===2?new se(l[0],l[1]):null:l==null?l:typeof l=="object"&&"lat"in l?new se(l.lat,"lng"in l?l.lng:l.lon,l.alt):f===void 0?null:new se(l,f,v)}var me={latLngToPoint:function(l,f){var v=this.projection.project(l),x=this.scale(f);return this.transformation._transform(v,x)},pointToLatLng:function(l,f){var v=this.scale(f),x=this.transformation.untransform(l,v);return this.projection.unproject(x)},project:function(l){return this.projection.project(l)},unproject:function(l){return this.projection.unproject(l)},scale:function(l){return 256*Math.pow(2,l)},zoom:function(l){return Math.log(l/256)/Math.LN2},getProjectedBounds:function(l){if(this.infinite)return null;var f=this.projection.bounds,v=this.scale(l),x=this.transformation.transform(f.min,v),A=this.transformation.transform(f.max,v);return new J(x,A)},infinite:!1,wrapLatLng:function(l){var f=this.wrapLng?d(l.lng,this.wrapLng,!0):l.lng,v=this.wrapLat?d(l.lat,this.wrapLat,!0):l.lat,x=l.alt;return new se(v,f,x)},wrapLatLngBounds:function(l){var f=l.getCenter(),v=this.wrapLatLng(f),x=f.lat-v.lat,A=f.lng-v.lng;if(x===0&&A===0)return l;var F=l.getSouthWest(),K=l.getNorthEast(),te=new se(F.lat-x,F.lng-A),re=new se(K.lat-x,K.lng-A);return new oe(te,re)}},pe=i({},me,{wrapLng:[-180,180],R:6371e3,distance:function(l,f){var v=Math.PI/180,x=l.lat*v,A=f.lat*v,F=Math.sin((f.lat-l.lat)*v/2),K=Math.sin((f.lng-l.lng)*v/2),te=F*F+Math.cos(x)*Math.cos(A)*K*K,re=2*Math.atan2(Math.sqrt(te),Math.sqrt(1-te));return this.R*re}}),Ce=6378137,ke={R:Ce,MAX_LATITUDE:85.0511287798,project:function(l){var f=Math.PI/180,v=this.MAX_LATITUDE,x=Math.max(Math.min(v,l.lat),-v),A=Math.sin(x*f);return new q(this.R*l.lng*f,this.R*Math.log((1+A)/(1-A))/2)},unproject:function(l){var f=180/Math.PI;return new se((2*Math.atan(Math.exp(l.y/this.R))-Math.PI/2)*f,l.x*f/this.R)},bounds:function(){var l=Ce*Math.PI;return new J([-l,-l],[l,l])}()};function we(l,f,v,x){if(S(l)){this._a=l[0],this._b=l[1],this._c=l[2],this._d=l[3];return}this._a=l,this._b=f,this._c=v,this._d=x}we.prototype={transform:function(l,f){return this._transform(l.clone(),f)},_transform:function(l,f){return f=f||1,l.x=f*(this._a*l.x+this._b),l.y=f*(this._c*l.y+this._d),l},untransform:function(l,f){return f=f||1,new q((l.x/f-this._b)/this._a,(l.y/f-this._d)/this._c)}};function le(l,f,v,x){return new we(l,f,v,x)}var He=i({},pe,{code:"EPSG:3857",projection:ke,transformation:function(){var l=.5/(Math.PI*ke.R);return le(l,.5,-l,.5)}()}),Te=i({},He,{code:"EPSG:900913"});function Ae(l){return document.createElementNS("http://www.w3.org/2000/svg",l)}function $e(l,f){var v="",x,A,F,K,te,re;for(x=0,F=l.length;x<F;x++){for(te=l[x],A=0,K=te.length;A<K;A++)re=te[A],v+=(A?"L":"M")+re.x+" "+re.y;v+=f?xe.svg?"z":"x":""}return v||"M0 0"}var Ge=document.documentElement.style,qe="ActiveXObject"in window,jt=qe&&!document.addEventListener,pt="msLaunchUri"in navigator&&!("documentMode"in document),St=Qr("webkit"),Ft=Qr("android"),Qt=Qr("android 2")||Qr("android 3"),bt=parseInt(/WebKit\/([0-9]+)|$/.exec(navigator.userAgent)[1],10),Jt=Ft&&Qr("Google")&&bt<537&&!("AudioNode"in window),Mr=!!window.opera,Pr=!pt&&Qr("chrome"),Zr=Qr("gecko")&&!St&&!Mr&&!qe,Br=!Pr&&Qr("safari"),Cn=Qr("phantom"),Nt="OTransition"in Ge,Kr=navigator.platform.indexOf("Win")===0,We=qe&&"transition"in Ge,_t="WebKitCSSMatrix"in window&&"m11"in new window.WebKitCSSMatrix&&!Qt,ci="MozPerspective"in Ge,So=!window.L_DISABLE_3D&&(We||_t||ci)&&!Nt&&!Cn,xn=typeof orientation!="undefined"||Qr("mobile"),Zi=xn&&St,Hd=xn&&_t,wl=!window.PointerEvent&&window.MSPointerEvent,Cl=!!(window.PointerEvent||wl),xl="ontouchstart"in window||!!window.TouchEvent,Wd=!window.L_NO_TOUCH&&(xl||Cl),jd=xn&&Mr,Vd=xn&&Zr,Ud=(window.devicePixelRatio||window.screen.deviceXDPI/window.screen.logicalXDPI)>1,Tl=function(){var l=!1;try{var f=Object.defineProperty({},"passive",{get:function(){l=!0}});window.addEventListener("testPassiveEventSupport",h,f),window.removeEventListener("testPassiveEventSupport",h,f)}catch(v){}return l}(),Sl=function(){return!!document.createElement("canvas").getContext}(),Ki=!!(document.createElementNS&&Ae("svg").createSVGRect),Ml=!!Ki&&function(){var l=document.createElement("div");return l.innerHTML="<svg/>",(l.firstChild&&l.firstChild.namespaceURI)==="http://www.w3.org/2000/svg"}(),Re=!Ki&&function(){try{var l=document.createElement("div");l.innerHTML='<v:shape adj="1"/>';var f=l.firstChild;return f.style.behavior="url(#default#VML)",f&&typeof f.adj=="object"}catch(v){return!1}}(),yr=navigator.platform.indexOf("Mac")===0,Pl=navigator.platform.indexOf("Linux")===0;function Qr(l){return navigator.userAgent.toLowerCase().indexOf(l)>=0}var xe={ie:qe,ielt9:jt,edge:pt,webkit:St,android:Ft,android23:Qt,androidStock:Jt,opera:Mr,chrome:Pr,gecko:Zr,safari:Br,phantom:Cn,opera12:Nt,win:Kr,ie3d:We,webkit3d:_t,gecko3d:ci,any3d:So,mobile:xn,mobileWebkit:Zi,mobileWebkit3d:Hd,msPointer:wl,pointer:Cl,touch:Wd,touchNative:xl,mobileOpera:jd,mobileGecko:Vd,retina:Ud,passiveEvents:Tl,canvas:Sl,svg:Ki,vml:Re,inlineSvg:Ml,mac:yr,linux:Pl},Xg=xe.msPointer?"MSPointerDown":"pointerdown",Zg=xe.msPointer?"MSPointerMove":"pointermove",Kg=xe.msPointer?"MSPointerUp":"pointerup",Qg=xe.msPointer?"MSPointerCancel":"pointercancel",Gd={touchstart:Xg,touchmove:Zg,touchend:Kg,touchcancel:Qg},Jg={touchstart:gE,touchmove:El,touchend:El,touchcancel:El},Qi={},ev=!1;function dE(l,f,v){return f==="touchstart"&&mE(),Jg[f]?(v=Jg[f].bind(this,v),l.addEventListener(Gd[f],v,!1),v):(console.warn("wrong event specified:",f),h)}function hE(l,f,v){if(!Gd[f]){console.warn("wrong event specified:",f);return}l.removeEventListener(Gd[f],v,!1)}function fE(l){Qi[l.pointerId]=l}function pE(l){Qi[l.pointerId]&&(Qi[l.pointerId]=l)}function tv(l){delete Qi[l.pointerId]}function mE(){ev||(document.addEventListener(Xg,fE,!0),document.addEventListener(Zg,pE,!0),document.addEventListener(Kg,tv,!0),document.addEventListener(Qg,tv,!0),ev=!0)}function El(l,f){if(f.pointerType!==(f.MSPOINTER_TYPE_MOUSE||"mouse")){f.touches=[];for(var v in Qi)f.touches.push(Qi[v]);f.changedTouches=[f],l(f)}}function gE(l,f){f.MSPOINTER_TYPE_TOUCH&&f.pointerType===f.MSPOINTER_TYPE_TOUCH&&$t(f),El(l,f)}function vE(l){var f={},v,x;for(x in l)v=l[x],f[x]=v&&v.bind?v.bind(l):v;return l=f,f.type="dblclick",f.detail=2,f.isTrusted=!1,f._simulated=!0,f}var yE=200;function bE(l,f){l.addEventListener("dblclick",f);var v=0,x;function A(F){if(F.detail!==1){x=F.detail;return}if(!(F.pointerType==="mouse"||F.sourceCapabilities&&!F.sourceCapabilities.firesTouchEvents)){var K=ov(F);if(!(K.some(function(re){return re instanceof HTMLLabelElement&&re.attributes.for})&&!K.some(function(re){return re instanceof HTMLInputElement||re instanceof HTMLSelectElement}))){var te=Date.now();te-v<=yE?(x++,x===2&&f(vE(F))):x=1,v=te}}}return l.addEventListener("click",A),{dblclick:f,simDblclick:A}}function _E(l,f){l.removeEventListener("dblclick",f.dblclick),l.removeEventListener("click",f.simDblclick)}var qd=Dl(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),Mo=Dl(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),rv=Mo==="webkitTransition"||Mo==="OTransition"?Mo+"End":"transitionend";function nv(l){return typeof l=="string"?document.getElementById(l):l}function Po(l,f){var v=l.style[f]||l.currentStyle&&l.currentStyle[f];if((!v||v==="auto")&&document.defaultView){var x=document.defaultView.getComputedStyle(l,null);v=x?x[f]:null}return v==="auto"?null:v}function Ve(l,f,v){var x=document.createElement(l);return x.className=f||"",v&&v.appendChild(x),x}function lt(l){var f=l.parentNode;f&&f.removeChild(l)}function Al(l){for(;l.firstChild;)l.removeChild(l.firstChild)}function Ji(l){var f=l.parentNode;f&&f.lastChild!==l&&f.appendChild(l)}function ea(l){var f=l.parentNode;f&&f.firstChild!==l&&f.insertBefore(l,f.firstChild)}function Yd(l,f){if(l.classList!==void 0)return l.classList.contains(f);var v=Rl(l);return v.length>0&&new RegExp("(^|\\s)"+f+"(\\s|$)").test(v)}function Oe(l,f){if(l.classList!==void 0)for(var v=g(f),x=0,A=v.length;x<A;x++)l.classList.add(v[x]);else if(!Yd(l,f)){var F=Rl(l);Xd(l,(F?F+" ":"")+f)}}function mt(l,f){l.classList!==void 0?l.classList.remove(f):Xd(l,m((" "+Rl(l)+" ").replace(" "+f+" "," ")))}function Xd(l,f){l.className.baseVal===void 0?l.className=f:l.className.baseVal=f}function Rl(l){return l.correspondingElement&&(l=l.correspondingElement),l.className.baseVal===void 0?l.className:l.className.baseVal}function Er(l,f){"opacity"in l.style?l.style.opacity=f:"filter"in l.style&&wE(l,f)}function wE(l,f){var v=!1,x="DXImageTransform.Microsoft.Alpha";try{v=l.filters.item(x)}catch(A){if(f===1)return}f=Math.round(f*100),v?(v.Enabled=f!==100,v.Opacity=f):l.style.filter+=" progid:"+x+"(opacity="+f+")"}function Dl(l){for(var f=document.documentElement.style,v=0;v<l.length;v++)if(l[v]in f)return l[v];return!1}function di(l,f,v){var x=f||new q(0,0);l.style[qd]=(xe.ie3d?"translate("+x.x+"px,"+x.y+"px)":"translate3d("+x.x+"px,"+x.y+"px,0)")+(v?" scale("+v+")":"")}function wt(l,f){l._leaflet_pos=f,xe.any3d?di(l,f):(l.style.left=f.x+"px",l.style.top=f.y+"px")}function hi(l){return l._leaflet_pos||new q(0,0)}var Eo,Ao,Zd;if("onselectstart"in document)Eo=function(){Le(window,"selectstart",$t)},Ao=function(){et(window,"selectstart",$t)};else{var Ro=Dl(["userSelect","WebkitUserSelect","OUserSelect","MozUserSelect","msUserSelect"]);Eo=function(){if(Ro){var l=document.documentElement.style;Zd=l[Ro],l[Ro]="none"}},Ao=function(){Ro&&(document.documentElement.style[Ro]=Zd,Zd=void 0)}}function Kd(){Le(window,"dragstart",$t)}function Qd(){et(window,"dragstart",$t)}var Nl,Jd;function eh(l){for(;l.tabIndex===-1;)l=l.parentNode;l.style&&(kl(),Nl=l,Jd=l.style.outlineStyle,l.style.outlineStyle="none",Le(window,"keydown",kl))}function kl(){Nl&&(Nl.style.outlineStyle=Jd,Nl=void 0,Jd=void 0,et(window,"keydown",kl))}function iv(l){do l=l.parentNode;while((!l.offsetWidth||!l.offsetHeight)&&l!==document.body);return l}function th(l){var f=l.getBoundingClientRect();return{x:f.width/l.offsetWidth||1,y:f.height/l.offsetHeight||1,boundingClientRect:f}}var CE={__proto__:null,TRANSFORM:qd,TRANSITION:Mo,TRANSITION_END:rv,get:nv,getStyle:Po,create:Ve,remove:lt,empty:Al,toFront:Ji,toBack:ea,hasClass:Yd,addClass:Oe,removeClass:mt,setClass:Xd,getClass:Rl,setOpacity:Er,testProp:Dl,setTransform:di,setPosition:wt,getPosition:hi,get disableTextSelection(){return Eo},get enableTextSelection(){return Ao},disableImageDrag:Kd,enableImageDrag:Qd,preventOutline:eh,restoreOutline:kl,getSizedParentNode:iv,getScale:th};function Le(l,f,v,x){if(f&&typeof f=="object")for(var A in f)nh(l,A,f[A],v);else{f=g(f);for(var F=0,K=f.length;F<K;F++)nh(l,f[F],v,x)}return this}var Jr="_leaflet_events";function et(l,f,v,x){if(arguments.length===1)av(l),delete l[Jr];else if(f&&typeof f=="object")for(var A in f)ih(l,A,f[A],v);else if(f=g(f),arguments.length===2)av(l,function(te){return T(f,te)!==-1});else for(var F=0,K=f.length;F<K;F++)ih(l,f[F],v,x);return this}function av(l,f){for(var v in l[Jr]){var x=v.split(/\d/)[0];(!f||f(x))&&ih(l,x,null,null,v)}}var rh={mouseenter:"mouseover",mouseleave:"mouseout",wheel:!("onwheel"in window)&&"mousewheel"};function nh(l,f,v,x){var A=f+u(v)+(x?"_"+u(x):"");if(l[Jr]&&l[Jr][A])return this;var F=function(te){return v.call(x||l,te||window.event)},K=F;!xe.touchNative&&xe.pointer&&f.indexOf("touch")===0?F=dE(l,f,F):xe.touch&&f==="dblclick"?F=bE(l,F):"addEventListener"in l?f==="touchstart"||f==="touchmove"||f==="wheel"||f==="mousewheel"?l.addEventListener(rh[f]||f,F,xe.passiveEvents?{passive:!1}:!1):f==="mouseenter"||f==="mouseleave"?(F=function(te){te=te||window.event,oh(l,te)&&K(te)},l.addEventListener(rh[f],F,!1)):l.addEventListener(f,K,!1):l.attachEvent("on"+f,F),l[Jr]=l[Jr]||{},l[Jr][A]=F}function ih(l,f,v,x,A){A=A||f+u(v)+(x?"_"+u(x):"");var F=l[Jr]&&l[Jr][A];if(!F)return this;!xe.touchNative&&xe.pointer&&f.indexOf("touch")===0?hE(l,f,F):xe.touch&&f==="dblclick"?_E(l,F):"removeEventListener"in l?l.removeEventListener(rh[f]||f,F,!1):l.detachEvent("on"+f,F),l[Jr][A]=null}function fi(l){return l.stopPropagation?l.stopPropagation():l.originalEvent?l.originalEvent._stopped=!0:l.cancelBubble=!0,this}function ah(l){return nh(l,"wheel",fi),this}function Do(l){return Le(l,"mousedown touchstart dblclick contextmenu",fi),l._leaflet_disable_click=!0,this}function $t(l){return l.preventDefault?l.preventDefault():l.returnValue=!1,this}function pi(l){return $t(l),fi(l),this}function ov(l){if(l.composedPath)return l.composedPath();for(var f=[],v=l.target;v;)f.push(v),v=v.parentNode;return f}function sv(l,f){if(!f)return new q(l.clientX,l.clientY);var v=th(f),x=v.boundingClientRect;return new q((l.clientX-x.left)/v.x-f.clientLeft,(l.clientY-x.top)/v.y-f.clientTop)}var xE=xe.linux&&xe.chrome?window.devicePixelRatio:xe.mac?window.devicePixelRatio*3:window.devicePixelRatio>0?2*window.devicePixelRatio:1;function lv(l){return xe.edge?l.wheelDeltaY/2:l.deltaY&&l.deltaMode===0?-l.deltaY/xE:l.deltaY&&l.deltaMode===1?-l.deltaY*20:l.deltaY&&l.deltaMode===2?-l.deltaY*60:l.deltaX||l.deltaZ?0:l.wheelDelta?(l.wheelDeltaY||l.wheelDelta)/2:l.detail&&Math.abs(l.detail)<32765?-l.detail*20:l.detail?l.detail/-32765*60:0}function oh(l,f){var v=f.relatedTarget;if(!v)return!0;try{for(;v&&v!==l;)v=v.parentNode}catch(x){return!1}return v!==l}var TE={__proto__:null,on:Le,off:et,stopPropagation:fi,disableScrollPropagation:ah,disableClickPropagation:Do,preventDefault:$t,stop:pi,getPropagationPath:ov,getMousePosition:sv,getWheelDelta:lv,isExternalTarget:oh,addListener:Le,removeListener:et},uv=W.extend({run:function(l,f,v,x){this.stop(),this._el=l,this._inProgress=!0,this._duration=v||.25,this._easeOutPower=1/Math.max(x||.5,.2),this._startPos=hi(l),this._offset=f.subtract(this._startPos),this._startTime=+new Date,this.fire("start"),this._animate()},stop:function(){this._inProgress&&(this._step(!0),this._complete())},_animate:function(){this._animId=G(this._animate,this),this._step()},_step:function(l){var f=+new Date-this._startTime,v=this._duration*1e3;f<v?this._runFrame(this._easeOut(f/v),l):(this._runFrame(1),this._complete())},_runFrame:function(l,f){var v=this._startPos.add(this._offset.multiplyBy(l));f&&v._round(),wt(this._el,v),this.fire("step")},_complete:function(){Y(this._animId),this._inProgress=!1,this.fire("end")},_easeOut:function(l){return 1-Math.pow(1-l,this._easeOutPower)}}),je=W.extend({options:{crs:He,center:void 0,zoom:void 0,minZoom:void 0,maxZoom:void 0,layers:[],maxBounds:void 0,renderer:void 0,zoomAnimation:!0,zoomAnimationThreshold:4,fadeAnimation:!0,markerZoomAnimation:!0,transform3DLimit:8388608,zoomSnap:1,zoomDelta:1,trackResize:!0},initialize:function(l,f){f=b(this,f),this._handlers=[],this._layers={},this._zoomBoundLayers={},this._sizeChanged=!0,this._initContainer(l),this._initLayout(),this._onResize=o(this._onResize,this),this._initEvents(),f.maxBounds&&this.setMaxBounds(f.maxBounds),f.zoom!==void 0&&(this._zoom=this._limitZoom(f.zoom)),f.center&&f.zoom!==void 0&&this.setView(ue(f.center),f.zoom,{reset:!0}),this.callInitHooks(),this._zoomAnimated=Mo&&xe.any3d&&!xe.mobileOpera&&this.options.zoomAnimation,this._zoomAnimated&&(this._createAnimProxy(),Le(this._proxy,rv,this._catchTransitionEnd,this)),this._addLayers(this.options.layers)},setView:function(l,f,v){if(f=f===void 0?this._zoom:this._limitZoom(f),l=this._limitCenter(ue(l),f,this.options.maxBounds),v=v||{},this._stop(),this._loaded&&!v.reset&&v!==!0){v.animate!==void 0&&(v.zoom=i({animate:v.animate},v.zoom),v.pan=i({animate:v.animate,duration:v.duration},v.pan));var x=this._zoom!==f?this._tryAnimatedZoom&&this._tryAnimatedZoom(l,f,v.zoom):this._tryAnimatedPan(l,v.pan);if(x)return clearTimeout(this._sizeTimer),this}return this._resetView(l,f,v.pan&&v.pan.noMoveStart),this},setZoom:function(l,f){return this._loaded?this.setView(this.getCenter(),l,{zoom:f}):(this._zoom=l,this)},zoomIn:function(l,f){return l=l||(xe.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom+l,f)},zoomOut:function(l,f){return l=l||(xe.any3d?this.options.zoomDelta:1),this.setZoom(this._zoom-l,f)},setZoomAround:function(l,f,v){var x=this.getZoomScale(f),A=this.getSize().divideBy(2),F=l instanceof q?l:this.latLngToContainerPoint(l),K=F.subtract(A).multiplyBy(1-1/x),te=this.containerPointToLatLng(A.add(K));return this.setView(te,f,{zoom:v})},_getBoundsCenterZoom:function(l,f){f=f||{},l=l.getBounds?l.getBounds():ae(l);var v=Z(f.paddingTopLeft||f.padding||[0,0]),x=Z(f.paddingBottomRight||f.padding||[0,0]),A=this.getBoundsZoom(l,!1,v.add(x));if(A=typeof f.maxZoom=="number"?Math.min(f.maxZoom,A):A,A===1/0)return{center:l.getCenter(),zoom:A};var F=x.subtract(v).divideBy(2),K=this.project(l.getSouthWest(),A),te=this.project(l.getNorthEast(),A),re=this.unproject(K.add(te).divideBy(2).add(F),A);return{center:re,zoom:A}},fitBounds:function(l,f){if(l=ae(l),!l.isValid())throw new Error("Bounds are not valid.");var v=this._getBoundsCenterZoom(l,f);return this.setView(v.center,v.zoom,f)},fitWorld:function(l){return this.fitBounds([[-90,-180],[90,180]],l)},panTo:function(l,f){return this.setView(l,this._zoom,{pan:f})},panBy:function(l,f){if(l=Z(l).round(),f=f||{},!l.x&&!l.y)return this.fire("moveend");if(f.animate!==!0&&!this.getSize().contains(l))return this._resetView(this.unproject(this.project(this.getCenter()).add(l)),this.getZoom()),this;if(this._panAnim||(this._panAnim=new uv,this._panAnim.on({step:this._onPanTransitionStep,end:this._onPanTransitionEnd},this)),f.noMoveStart||this.fire("movestart"),f.animate!==!1){Oe(this._mapPane,"leaflet-pan-anim");var v=this._getMapPanePos().subtract(l).round();this._panAnim.run(this._mapPane,v,f.duration||.25,f.easeLinearity)}else this._rawPanBy(l),this.fire("move").fire("moveend");return this},flyTo:function(l,f,v){if(v=v||{},v.animate===!1||!xe.any3d)return this.setView(l,f,v);this._stop();var x=this.project(this.getCenter()),A=this.project(l),F=this.getSize(),K=this._zoom;l=ue(l),f=f===void 0?K:f;var te=Math.max(F.x,F.y),re=te*this.getZoomScale(K,f),ce=A.distanceTo(x)||1,ye=1.42,Se=ye*ye;function Ie(Ct){var Ul=Ct?-1:1,h4=Ct?re:te,f4=re*re-te*te+Ul*Se*Se*ce*ce,p4=2*h4*Se*ce,vh=f4/p4,jv=Math.sqrt(vh*vh+1)-vh,m4=jv<1e-9?-18:Math.log(jv);return m4}function er(Ct){return(Math.exp(Ct)-Math.exp(-Ct))/2}function kt(Ct){return(Math.exp(Ct)+Math.exp(-Ct))/2}function Rr(Ct){return er(Ct)/kt(Ct)}var dr=Ie(0);function oa(Ct){return te*(kt(dr)/kt(dr+ye*Ct))}function l4(Ct){return te*(kt(dr)*Rr(dr+ye*Ct)-er(dr))/Se}function u4(Ct){return 1-Math.pow(1-Ct,1.5)}var c4=Date.now(),Hv=(Ie(1)-dr)/ye,d4=v.duration?1e3*v.duration:1e3*Hv*.8;function Wv(){var Ct=(Date.now()-c4)/d4,Ul=u4(Ct)*Hv;Ct<=1?(this._flyToFrame=G(Wv,this),this._move(this.unproject(x.add(A.subtract(x).multiplyBy(l4(Ul)/ce)),K),this.getScaleZoom(te/oa(Ul),K),{flyTo:!0})):this._move(l,f)._moveEnd(!0)}return this._moveStart(!0,v.noMoveStart),Wv.call(this),this},flyToBounds:function(l,f){var v=this._getBoundsCenterZoom(l,f);return this.flyTo(v.center,v.zoom,f)},setMaxBounds:function(l){return l=ae(l),this.listens("moveend",this._panInsideMaxBounds)&&this.off("moveend",this._panInsideMaxBounds),l.isValid()?(this.options.maxBounds=l,this._loaded&&this._panInsideMaxBounds(),this.on("moveend",this._panInsideMaxBounds)):(this.options.maxBounds=null,this)},setMinZoom:function(l){var f=this.options.minZoom;return this.options.minZoom=l,this._loaded&&f!==l&&(this.fire("zoomlevelschange"),this.getZoom()<this.options.minZoom)?this.setZoom(l):this},setMaxZoom:function(l){var f=this.options.maxZoom;return this.options.maxZoom=l,this._loaded&&f!==l&&(this.fire("zoomlevelschange"),this.getZoom()>this.options.maxZoom)?this.setZoom(l):this},panInsideBounds:function(l,f){this._enforcingBounds=!0;var v=this.getCenter(),x=this._limitCenter(v,this._zoom,ae(l));return v.equals(x)||this.panTo(x,f),this._enforcingBounds=!1,this},panInside:function(l,f){f=f||{};var v=Z(f.paddingTopLeft||f.padding||[0,0]),x=Z(f.paddingBottomRight||f.padding||[0,0]),A=this.project(this.getCenter()),F=this.project(l),K=this.getPixelBounds(),te=ne([K.min.add(v),K.max.subtract(x)]),re=te.getSize();if(!te.contains(F)){this._enforcingBounds=!0;var ce=F.subtract(te.getCenter()),ye=te.extend(F).getSize().subtract(re);A.x+=ce.x<0?-ye.x:ye.x,A.y+=ce.y<0?-ye.y:ye.y,this.panTo(this.unproject(A),f),this._enforcingBounds=!1}return this},invalidateSize:function(l){if(!this._loaded)return this;l=i({animate:!1,pan:!0},l===!0?{animate:!0}:l);var f=this.getSize();this._sizeChanged=!0,this._lastCenter=null;var v=this.getSize(),x=f.divideBy(2).round(),A=v.divideBy(2).round(),F=x.subtract(A);return!F.x&&!F.y?this:(l.animate&&l.pan?this.panBy(F):(l.pan&&this._rawPanBy(F),this.fire("move"),l.debounceMoveend?(clearTimeout(this._sizeTimer),this._sizeTimer=setTimeout(o(this.fire,this,"moveend"),200)):this.fire("moveend")),this.fire("resize",{oldSize:f,newSize:v}))},stop:function(){return this.setZoom(this._limitZoom(this._zoom)),this.options.zoomSnap||this.fire("viewreset"),this._stop()},locate:function(l){if(l=this._locateOptions=i({timeout:1e4,watch:!1},l),!("geolocation"in navigator))return this._handleGeolocationError({code:0,message:"Geolocation not supported."}),this;var f=o(this._handleGeolocationResponse,this),v=o(this._handleGeolocationError,this);return l.watch?this._locationWatchId=navigator.geolocation.watchPosition(f,v,l):navigator.geolocation.getCurrentPosition(f,v,l),this},stopLocate:function(){return navigator.geolocation&&navigator.geolocation.clearWatch&&navigator.geolocation.clearWatch(this._locationWatchId),this._locateOptions&&(this._locateOptions.setView=!1),this},_handleGeolocationError:function(l){if(this._container._leaflet_id){var f=l.code,v=l.message||(f===1?"permission denied":f===2?"position unavailable":"timeout");this._locateOptions.setView&&!this._loaded&&this.fitWorld(),this.fire("locationerror",{code:f,message:"Geolocation error: "+v+"."})}},_handleGeolocationResponse:function(l){if(this._container._leaflet_id){var f=l.coords.latitude,v=l.coords.longitude,x=new se(f,v),A=x.toBounds(l.coords.accuracy*2),F=this._locateOptions;if(F.setView){var K=this.getBoundsZoom(A);this.setView(x,F.maxZoom?Math.min(K,F.maxZoom):K)}var te={latlng:x,bounds:A,timestamp:l.timestamp};for(var re in l.coords)typeof l.coords[re]=="number"&&(te[re]=l.coords[re]);this.fire("locationfound",te)}},addHandler:function(l,f){if(!f)return this;var v=this[l]=new f(this);return this._handlers.push(v),this.options[l]&&v.enable(),this},remove:function(){if(this._initEvents(!0),this.options.maxBounds&&this.off("moveend",this._panInsideMaxBounds),this._containerId!==this._container._leaflet_id)throw new Error("Map container is being reused by another instance");try{delete this._container._leaflet_id,delete this._containerId}catch(f){this._container._leaflet_id=void 0,this._containerId=void 0}this._locationWatchId!==void 0&&this.stopLocate(),this._stop(),lt(this._mapPane),this._clearControlPos&&this._clearControlPos(),this._resizeRequest&&(Y(this._resizeRequest),this._resizeRequest=null),this._clearHandlers(),this._loaded&&this.fire("unload");var l;for(l in this._layers)this._layers[l].remove();for(l in this._panes)lt(this._panes[l]);return this._layers=[],this._panes=[],delete this._mapPane,delete this._renderer,this},createPane:function(l,f){var v="leaflet-pane"+(l?" leaflet-"+l.replace("Pane","")+"-pane":""),x=Ve("div",v,f||this._mapPane);return l&&(this._panes[l]=x),x},getCenter:function(){return this._checkIfLoaded(),this._lastCenter&&!this._moved()?this._lastCenter.clone():this.layerPointToLatLng(this._getCenterLayerPoint())},getZoom:function(){return this._zoom},getBounds:function(){var l=this.getPixelBounds(),f=this.unproject(l.getBottomLeft()),v=this.unproject(l.getTopRight());return new oe(f,v)},getMinZoom:function(){return this.options.minZoom===void 0?this._layersMinZoom||0:this.options.minZoom},getMaxZoom:function(){return this.options.maxZoom===void 0?this._layersMaxZoom===void 0?1/0:this._layersMaxZoom:this.options.maxZoom},getBoundsZoom:function(l,f,v){l=ae(l),v=Z(v||[0,0]);var x=this.getZoom()||0,A=this.getMinZoom(),F=this.getMaxZoom(),K=l.getNorthWest(),te=l.getSouthEast(),re=this.getSize().subtract(v),ce=ne(this.project(te,x),this.project(K,x)).getSize(),ye=xe.any3d?this.options.zoomSnap:1,Se=re.x/ce.x,Ie=re.y/ce.y,er=f?Math.max(Se,Ie):Math.min(Se,Ie);return x=this.getScaleZoom(er,x),ye&&(x=Math.round(x/(ye/100))*(ye/100),x=f?Math.ceil(x/ye)*ye:Math.floor(x/ye)*ye),Math.max(A,Math.min(F,x))},getSize:function(){return(!this._size||this._sizeChanged)&&(this._size=new q(this._container.clientWidth||0,this._container.clientHeight||0),this._sizeChanged=!1),this._size.clone()},getPixelBounds:function(l,f){var v=this._getTopLeftPoint(l,f);return new J(v,v.add(this.getSize()))},getPixelOrigin:function(){return this._checkIfLoaded(),this._pixelOrigin},getPixelWorldBounds:function(l){return this.options.crs.getProjectedBounds(l===void 0?this.getZoom():l)},getPane:function(l){return typeof l=="string"?this._panes[l]:l},getPanes:function(){return this._panes},getContainer:function(){return this._container},getZoomScale:function(l,f){var v=this.options.crs;return f=f===void 0?this._zoom:f,v.scale(l)/v.scale(f)},getScaleZoom:function(l,f){var v=this.options.crs;f=f===void 0?this._zoom:f;var x=v.zoom(l*v.scale(f));return isNaN(x)?1/0:x},project:function(l,f){return f=f===void 0?this._zoom:f,this.options.crs.latLngToPoint(ue(l),f)},unproject:function(l,f){return f=f===void 0?this._zoom:f,this.options.crs.pointToLatLng(Z(l),f)},layerPointToLatLng:function(l){var f=Z(l).add(this.getPixelOrigin());return this.unproject(f)},latLngToLayerPoint:function(l){var f=this.project(ue(l))._round();return f._subtract(this.getPixelOrigin())},wrapLatLng:function(l){return this.options.crs.wrapLatLng(ue(l))},wrapLatLngBounds:function(l){return this.options.crs.wrapLatLngBounds(ae(l))},distance:function(l,f){return this.options.crs.distance(ue(l),ue(f))},containerPointToLayerPoint:function(l){return Z(l).subtract(this._getMapPanePos())},layerPointToContainerPoint:function(l){return Z(l).add(this._getMapPanePos())},containerPointToLatLng:function(l){var f=this.containerPointToLayerPoint(Z(l));return this.layerPointToLatLng(f)},latLngToContainerPoint:function(l){return this.layerPointToContainerPoint(this.latLngToLayerPoint(ue(l)))},mouseEventToContainerPoint:function(l){return sv(l,this._container)},mouseEventToLayerPoint:function(l){return this.containerPointToLayerPoint(this.mouseEventToContainerPoint(l))},mouseEventToLatLng:function(l){return this.layerPointToLatLng(this.mouseEventToLayerPoint(l))},_initContainer:function(l){var f=this._container=nv(l);if(f){if(f._leaflet_id)throw new Error("Map container is already initialized.")}else throw new Error("Map container not found.");Le(f,"scroll",this._onScroll,this),this._containerId=u(f)},_initLayout:function(){var l=this._container;this._fadeAnimated=this.options.fadeAnimation&&xe.any3d,Oe(l,"leaflet-container"+(xe.touch?" leaflet-touch":"")+(xe.retina?" leaflet-retina":"")+(xe.ielt9?" leaflet-oldie":"")+(xe.safari?" leaflet-safari":"")+(this._fadeAnimated?" leaflet-fade-anim":""));var f=Po(l,"position");f!=="absolute"&&f!=="relative"&&f!=="fixed"&&f!=="sticky"&&(l.style.position="relative"),this._initPanes(),this._initControlPos&&this._initControlPos()},_initPanes:function(){var l=this._panes={};this._paneRenderers={},this._mapPane=this.createPane("mapPane",this._container),wt(this._mapPane,new q(0,0)),this.createPane("tilePane"),this.createPane("overlayPane"),this.createPane("shadowPane"),this.createPane("markerPane"),this.createPane("tooltipPane"),this.createPane("popupPane"),this.options.markerZoomAnimation||(Oe(l.markerPane,"leaflet-zoom-hide"),Oe(l.shadowPane,"leaflet-zoom-hide"))},_resetView:function(l,f,v){wt(this._mapPane,new q(0,0));var x=!this._loaded;this._loaded=!0,f=this._limitZoom(f),this.fire("viewprereset");var A=this._zoom!==f;this._moveStart(A,v)._move(l,f)._moveEnd(A),this.fire("viewreset"),x&&this.fire("load")},_moveStart:function(l,f){return l&&this.fire("zoomstart"),f||this.fire("movestart"),this},_move:function(l,f,v,x){f===void 0&&(f=this._zoom);var A=this._zoom!==f;return this._zoom=f,this._lastCenter=l,this._pixelOrigin=this._getNewPixelOrigin(l),x?v&&v.pinch&&this.fire("zoom",v):((A||v&&v.pinch)&&this.fire("zoom",v),this.fire("move",v)),this},_moveEnd:function(l){return l&&this.fire("zoomend"),this.fire("moveend")},_stop:function(){return Y(this._flyToFrame),this._panAnim&&this._panAnim.stop(),this},_rawPanBy:function(l){wt(this._mapPane,this._getMapPanePos().subtract(l))},_getZoomSpan:function(){return this.getMaxZoom()-this.getMinZoom()},_panInsideMaxBounds:function(){this._enforcingBounds||this.panInsideBounds(this.options.maxBounds)},_checkIfLoaded:function(){if(!this._loaded)throw new Error("Set map center and zoom first.")},_initEvents:function(l){this._targets={},this._targets[u(this._container)]=this;var f=l?et:Le;f(this._container,"click dblclick mousedown mouseup mouseover mouseout mousemove contextmenu keypress keydown keyup",this._handleDOMEvent,this),this.options.trackResize&&f(window,"resize",this._onResize,this),xe.any3d&&this.options.transform3DLimit&&(l?this.off:this.on).call(this,"moveend",this._onMoveEnd)},_onResize:function(){Y(this._resizeRequest),this._resizeRequest=G(function(){this.invalidateSize({debounceMoveend:!0})},this)},_onScroll:function(){this._container.scrollTop=0,this._container.scrollLeft=0},_onMoveEnd:function(){var l=this._getMapPanePos();Math.max(Math.abs(l.x),Math.abs(l.y))>=this.options.transform3DLimit&&this._resetView(this.getCenter(),this.getZoom())},_findEventTargets:function(l,f){for(var v=[],x,A=f==="mouseout"||f==="mouseover",F=l.target||l.srcElement,K=!1;F;){if(x=this._targets[u(F)],x&&(f==="click"||f==="preclick")&&this._draggableMoved(x)){K=!0;break}if(x&&x.listens(f,!0)&&(A&&!oh(F,l)||(v.push(x),A))||F===this._container)break;F=F.parentNode}return!v.length&&!K&&!A&&this.listens(f,!0)&&(v=[this]),v},_isClickDisabled:function(l){for(;l&&l!==this._container;){if(l._leaflet_disable_click)return!0;l=l.parentNode}},_handleDOMEvent:function(l){var f=l.target||l.srcElement;if(!(!this._loaded||f._leaflet_disable_events||l.type==="click"&&this._isClickDisabled(f))){var v=l.type;v==="mousedown"&&eh(f),this._fireDOMEvent(l,v)}},_mouseEvents:["click","dblclick","mouseover","mouseout","contextmenu"],_fireDOMEvent:function(l,f,v){if(l.type==="click"){var x=i({},l);x.type="preclick",this._fireDOMEvent(x,x.type,v)}var A=this._findEventTargets(l,f);if(v){for(var F=[],K=0;K<v.length;K++)v[K].listens(f,!0)&&F.push(v[K]);A=F.concat(A)}if(A.length){f==="contextmenu"&&$t(l);var te=A[0],re={originalEvent:l};if(l.type!=="keypress"&&l.type!=="keydown"&&l.type!=="keyup"){var ce=te.getLatLng&&(!te._radius||te._radius<=10);re.containerPoint=ce?this.latLngToContainerPoint(te.getLatLng()):this.mouseEventToContainerPoint(l),re.layerPoint=this.containerPointToLayerPoint(re.containerPoint),re.latlng=ce?te.getLatLng():this.layerPointToLatLng(re.layerPoint)}for(K=0;K<A.length;K++)if(A[K].fire(f,re,!0),re.originalEvent._stopped||A[K].options.bubblingMouseEvents===!1&&T(this._mouseEvents,f)!==-1)return}},_draggableMoved:function(l){return l=l.dragging&&l.dragging.enabled()?l:this,l.dragging&&l.dragging.moved()||this.boxZoom&&this.boxZoom.moved()},_clearHandlers:function(){for(var l=0,f=this._handlers.length;l<f;l++)this._handlers[l].disable()},whenReady:function(l,f){return this._loaded?l.call(f||this,{target:this}):this.on("load",l,f),this},_getMapPanePos:function(){return hi(this._mapPane)||new q(0,0)},_moved:function(){var l=this._getMapPanePos();return l&&!l.equals([0,0])},_getTopLeftPoint:function(l,f){var v=l&&f!==void 0?this._getNewPixelOrigin(l,f):this.getPixelOrigin();return v.subtract(this._getMapPanePos())},_getNewPixelOrigin:function(l,f){var v=this.getSize()._divideBy(2);return this.project(l,f)._subtract(v)._add(this._getMapPanePos())._round()},_latLngToNewLayerPoint:function(l,f,v){var x=this._getNewPixelOrigin(v,f);return this.project(l,f)._subtract(x)},_latLngBoundsToNewLayerBounds:function(l,f,v){var x=this._getNewPixelOrigin(v,f);return ne([this.project(l.getSouthWest(),f)._subtract(x),this.project(l.getNorthWest(),f)._subtract(x),this.project(l.getSouthEast(),f)._subtract(x),this.project(l.getNorthEast(),f)._subtract(x)])},_getCenterLayerPoint:function(){return this.containerPointToLayerPoint(this.getSize()._divideBy(2))},_getCenterOffset:function(l){return this.latLngToLayerPoint(l).subtract(this._getCenterLayerPoint())},_limitCenter:function(l,f,v){if(!v)return l;var x=this.project(l,f),A=this.getSize().divideBy(2),F=new J(x.subtract(A),x.add(A)),K=this._getBoundsOffset(F,v,f);return Math.abs(K.x)<=1&&Math.abs(K.y)<=1?l:this.unproject(x.add(K),f)},_limitOffset:function(l,f){if(!f)return l;var v=this.getPixelBounds(),x=new J(v.min.add(l),v.max.add(l));return l.add(this._getBoundsOffset(x,f))},_getBoundsOffset:function(l,f,v){var x=ne(this.project(f.getNorthEast(),v),this.project(f.getSouthWest(),v)),A=x.min.subtract(l.min),F=x.max.subtract(l.max),K=this._rebound(A.x,-F.x),te=this._rebound(A.y,-F.y);return new q(K,te)},_rebound:function(l,f){return l+f>0?Math.round(l-f)/2:Math.max(0,Math.ceil(l))-Math.max(0,Math.floor(f))},_limitZoom:function(l){var f=this.getMinZoom(),v=this.getMaxZoom(),x=xe.any3d?this.options.zoomSnap:1;return x&&(l=Math.round(l/x)*x),Math.max(f,Math.min(v,l))},_onPanTransitionStep:function(){this.fire("move")},_onPanTransitionEnd:function(){mt(this._mapPane,"leaflet-pan-anim"),this.fire("moveend")},_tryAnimatedPan:function(l,f){var v=this._getCenterOffset(l)._trunc();return(f&&f.animate)!==!0&&!this.getSize().contains(v)?!1:(this.panBy(v,f),!0)},_createAnimProxy:function(){var l=this._proxy=Ve("div","leaflet-proxy leaflet-zoom-animated");this._panes.mapPane.appendChild(l),this.on("zoomanim",function(f){var v=qd,x=this._proxy.style[v];di(this._proxy,this.project(f.center,f.zoom),this.getZoomScale(f.zoom,1)),x===this._proxy.style[v]&&this._animatingZoom&&this._onZoomTransitionEnd()},this),this.on("load moveend",this._animMoveEnd,this),this._on("unload",this._destroyAnimProxy,this)},_destroyAnimProxy:function(){lt(this._proxy),this.off("load moveend",this._animMoveEnd,this),delete this._proxy},_animMoveEnd:function(){var l=this.getCenter(),f=this.getZoom();di(this._proxy,this.project(l,f),this.getZoomScale(f,1))},_catchTransitionEnd:function(l){this._animatingZoom&&l.propertyName.indexOf("transform")>=0&&this._onZoomTransitionEnd()},_nothingToAnimate:function(){return!this._container.getElementsByClassName("leaflet-zoom-animated").length},_tryAnimatedZoom:function(l,f,v){if(this._animatingZoom)return!0;if(v=v||{},!this._zoomAnimated||v.animate===!1||this._nothingToAnimate()||Math.abs(f-this._zoom)>this.options.zoomAnimationThreshold)return!1;var x=this.getZoomScale(f),A=this._getCenterOffset(l)._divideBy(1-1/x);return v.animate!==!0&&!this.getSize().contains(A)?!1:(G(function(){this._moveStart(!0,v.noMoveStart||!1)._animateZoom(l,f,!0)},this),!0)},_animateZoom:function(l,f,v,x){this._mapPane&&(v&&(this._animatingZoom=!0,this._animateToCenter=l,this._animateToZoom=f,Oe(this._mapPane,"leaflet-zoom-anim")),this.fire("zoomanim",{center:l,zoom:f,noUpdate:x}),this._tempFireZoomEvent||(this._tempFireZoomEvent=this._zoom!==this._animateToZoom),this._move(this._animateToCenter,this._animateToZoom,void 0,!0),setTimeout(o(this._onZoomTransitionEnd,this),250))},_onZoomTransitionEnd:function(){this._animatingZoom&&(this._mapPane&&mt(this._mapPane,"leaflet-zoom-anim"),this._animatingZoom=!1,this._move(this._animateToCenter,this._animateToZoom,void 0,!0),this._tempFireZoomEvent&&this.fire("zoom"),delete this._tempFireZoomEvent,this.fire("move"),this._moveEnd(!0))}});function SE(l,f){return new je(l,f)}var zr=X.extend({options:{position:"topright"},initialize:function(l){b(this,l)},getPosition:function(){return this.options.position},setPosition:function(l){var f=this._map;return f&&f.removeControl(this),this.options.position=l,f&&f.addControl(this),this},getContainer:function(){return this._container},addTo:function(l){this.remove(),this._map=l;var f=this._container=this.onAdd(l),v=this.getPosition(),x=l._controlCorners[v];return Oe(f,"leaflet-control"),v.indexOf("bottom")!==-1?x.insertBefore(f,x.firstChild):x.appendChild(f),this._map.on("unload",this.remove,this),this},remove:function(){return this._map?(lt(this._container),this.onRemove&&this.onRemove(this._map),this._map.off("unload",this.remove,this),this._map=null,this):this},_refocusOnMap:function(l){this._map&&l&&l.screenX>0&&l.screenY>0&&this._map.getContainer().focus()}}),No=function(l){return new zr(l)};je.include({addControl:function(l){return l.addTo(this),this},removeControl:function(l){return l.remove(),this},_initControlPos:function(){var l=this._controlCorners={},f="leaflet-",v=this._controlContainer=Ve("div",f+"control-container",this._container);function x(A,F){var K=f+A+" "+f+F;l[A+F]=Ve("div",K,v)}x("top","left"),x("top","right"),x("bottom","left"),x("bottom","right")},_clearControlPos:function(){for(var l in this._controlCorners)lt(this._controlCorners[l]);lt(this._controlContainer),delete this._controlCorners,delete this._controlContainer}});var cv=zr.extend({options:{collapsed:!0,position:"topright",autoZIndex:!0,hideSingleBase:!1,sortLayers:!1,sortFunction:function(l,f,v,x){return v<x?-1:x<v?1:0}},initialize:function(l,f,v){b(this,v),this._layerControlInputs=[],this._layers=[],this._lastZIndex=0,this._handlingClick=!1,this._preventClick=!1;for(var x in l)this._addLayer(l[x],x);for(x in f)this._addLayer(f[x],x,!0)},onAdd:function(l){this._initLayout(),this._update(),this._map=l,l.on("zoomend",this._checkDisabledLayers,this);for(var f=0;f<this._layers.length;f++)this._layers[f].layer.on("add remove",this._onLayerChange,this);return this._container},addTo:function(l){return zr.prototype.addTo.call(this,l),this._expandIfNotCollapsed()},onRemove:function(){this._map.off("zoomend",this._checkDisabledLayers,this);for(var l=0;l<this._layers.length;l++)this._layers[l].layer.off("add remove",this._onLayerChange,this)},addBaseLayer:function(l,f){return this._addLayer(l,f),this._map?this._update():this},addOverlay:function(l,f){return this._addLayer(l,f,!0),this._map?this._update():this},removeLayer:function(l){l.off("add remove",this._onLayerChange,this);var f=this._getLayer(u(l));return f&&this._layers.splice(this._layers.indexOf(f),1),this._map?this._update():this},expand:function(){Oe(this._container,"leaflet-control-layers-expanded"),this._section.style.height=null;var l=this._map.getSize().y-(this._container.offsetTop+50);return l<this._section.clientHeight?(Oe(this._section,"leaflet-control-layers-scrollbar"),this._section.style.height=l+"px"):mt(this._section,"leaflet-control-layers-scrollbar"),this._checkDisabledLayers(),this},collapse:function(){return mt(this._container,"leaflet-control-layers-expanded"),this},_initLayout:function(){var l="leaflet-control-layers",f=this._container=Ve("div",l),v=this.options.collapsed;f.setAttribute("aria-haspopup",!0),Do(f),ah(f);var x=this._section=Ve("section",l+"-list");v&&(this._map.on("click",this.collapse,this),Le(f,{mouseenter:this._expandSafely,mouseleave:this.collapse},this));var A=this._layersLink=Ve("a",l+"-toggle",f);A.href="#",A.title="Layers",A.setAttribute("role","button"),Le(A,{keydown:function(F){F.keyCode===13&&this._expandSafely()},click:function(F){$t(F),this._expandSafely()}},this),v||this.expand(),this._baseLayersList=Ve("div",l+"-base",x),this._separator=Ve("div",l+"-separator",x),this._overlaysList=Ve("div",l+"-overlays",x),f.appendChild(x)},_getLayer:function(l){for(var f=0;f<this._layers.length;f++)if(this._layers[f]&&u(this._layers[f].layer)===l)return this._layers[f]},_addLayer:function(l,f,v){this._map&&l.on("add remove",this._onLayerChange,this),this._layers.push({layer:l,name:f,overlay:v}),this.options.sortLayers&&this._layers.sort(o(function(x,A){return this.options.sortFunction(x.layer,A.layer,x.name,A.name)},this)),this.options.autoZIndex&&l.setZIndex&&(this._lastZIndex++,l.setZIndex(this._lastZIndex)),this._expandIfNotCollapsed()},_update:function(){if(!this._container)return this;Al(this._baseLayersList),Al(this._overlaysList),this._layerControlInputs=[];var l,f,v,x,A=0;for(v=0;v<this._layers.length;v++)x=this._layers[v],this._addItem(x),f=f||x.overlay,l=l||!x.overlay,A+=x.overlay?0:1;return this.options.hideSingleBase&&(l=l&&A>1,this._baseLayersList.style.display=l?"":"none"),this._separator.style.display=f&&l?"":"none",this},_onLayerChange:function(l){this._handlingClick||this._update();var f=this._getLayer(u(l.target)),v=f.overlay?l.type==="add"?"overlayadd":"overlayremove":l.type==="add"?"baselayerchange":null;v&&this._map.fire(v,f)},_createRadioElement:function(l,f){var v='<input type="radio" class="leaflet-control-layers-selector" name="'+l+'"'+(f?' checked="checked"':"")+"/>",x=document.createElement("div");return x.innerHTML=v,x.firstChild},_addItem:function(l){var f=document.createElement("label"),v=this._map.hasLayer(l.layer),x;l.overlay?(x=document.createElement("input"),x.type="checkbox",x.className="leaflet-control-layers-selector",x.defaultChecked=v):x=this._createRadioElement("leaflet-base-layers_"+u(this),v),this._layerControlInputs.push(x),x.layerId=u(l.layer),Le(x,"click",this._onInputClick,this);var A=document.createElement("span");A.innerHTML=" "+l.name;var F=document.createElement("span");f.appendChild(F),F.appendChild(x),F.appendChild(A);var K=l.overlay?this._overlaysList:this._baseLayersList;return K.appendChild(f),this._checkDisabledLayers(),f},_onInputClick:function(){if(!this._preventClick){var l=this._layerControlInputs,f,v,x=[],A=[];this._handlingClick=!0;for(var F=l.length-1;F>=0;F--)f=l[F],v=this._getLayer(f.layerId).layer,f.checked?x.push(v):f.checked||A.push(v);for(F=0;F<A.length;F++)this._map.hasLayer(A[F])&&this._map.removeLayer(A[F]);for(F=0;F<x.length;F++)this._map.hasLayer(x[F])||this._map.addLayer(x[F]);this._handlingClick=!1,this._refocusOnMap()}},_checkDisabledLayers:function(){for(var l=this._layerControlInputs,f,v,x=this._map.getZoom(),A=l.length-1;A>=0;A--)f=l[A],v=this._getLayer(f.layerId).layer,f.disabled=v.options.minZoom!==void 0&&x<v.options.minZoom||v.options.maxZoom!==void 0&&x>v.options.maxZoom},_expandIfNotCollapsed:function(){return this._map&&!this.options.collapsed&&this.expand(),this},_expandSafely:function(){var l=this._section;this._preventClick=!0,Le(l,"click",$t),this.expand();var f=this;setTimeout(function(){et(l,"click",$t),f._preventClick=!1})}}),ME=function(l,f,v){return new cv(l,f,v)},sh=zr.extend({options:{position:"topleft",zoomInText:'<span aria-hidden="true">+</span>',zoomInTitle:"Zoom in",zoomOutText:'<span aria-hidden="true">&#x2212;</span>',zoomOutTitle:"Zoom out"},onAdd:function(l){var f="leaflet-control-zoom",v=Ve("div",f+" leaflet-bar"),x=this.options;return this._zoomInButton=this._createButton(x.zoomInText,x.zoomInTitle,f+"-in",v,this._zoomIn),this._zoomOutButton=this._createButton(x.zoomOutText,x.zoomOutTitle,f+"-out",v,this._zoomOut),this._updateDisabled(),l.on("zoomend zoomlevelschange",this._updateDisabled,this),v},onRemove:function(l){l.off("zoomend zoomlevelschange",this._updateDisabled,this)},disable:function(){return this._disabled=!0,this._updateDisabled(),this},enable:function(){return this._disabled=!1,this._updateDisabled(),this},_zoomIn:function(l){!this._disabled&&this._map._zoom<this._map.getMaxZoom()&&this._map.zoomIn(this._map.options.zoomDelta*(l.shiftKey?3:1))},_zoomOut:function(l){!this._disabled&&this._map._zoom>this._map.getMinZoom()&&this._map.zoomOut(this._map.options.zoomDelta*(l.shiftKey?3:1))},_createButton:function(l,f,v,x,A){var F=Ve("a",v,x);return F.innerHTML=l,F.href="#",F.title=f,F.setAttribute("role","button"),F.setAttribute("aria-label",f),Do(F),Le(F,"click",pi),Le(F,"click",A,this),Le(F,"click",this._refocusOnMap,this),F},_updateDisabled:function(){var l=this._map,f="leaflet-disabled";mt(this._zoomInButton,f),mt(this._zoomOutButton,f),this._zoomInButton.setAttribute("aria-disabled","false"),this._zoomOutButton.setAttribute("aria-disabled","false"),(this._disabled||l._zoom===l.getMinZoom())&&(Oe(this._zoomOutButton,f),this._zoomOutButton.setAttribute("aria-disabled","true")),(this._disabled||l._zoom===l.getMaxZoom())&&(Oe(this._zoomInButton,f),this._zoomInButton.setAttribute("aria-disabled","true"))}});je.mergeOptions({zoomControl:!0}),je.addInitHook(function(){this.options.zoomControl&&(this.zoomControl=new sh,this.addControl(this.zoomControl))});var PE=function(l){return new sh(l)},dv=zr.extend({options:{position:"bottomleft",maxWidth:100,metric:!0,imperial:!0},onAdd:function(l){var f="leaflet-control-scale",v=Ve("div",f),x=this.options;return this._addScales(x,f+"-line",v),l.on(x.updateWhenIdle?"moveend":"move",this._update,this),l.whenReady(this._update,this),v},onRemove:function(l){l.off(this.options.updateWhenIdle?"moveend":"move",this._update,this)},_addScales:function(l,f,v){l.metric&&(this._mScale=Ve("div",f,v)),l.imperial&&(this._iScale=Ve("div",f,v))},_update:function(){var l=this._map,f=l.getSize().y/2,v=l.distance(l.containerPointToLatLng([0,f]),l.containerPointToLatLng([this.options.maxWidth,f]));this._updateScales(v)},_updateScales:function(l){this.options.metric&&l&&this._updateMetric(l),this.options.imperial&&l&&this._updateImperial(l)},_updateMetric:function(l){var f=this._getRoundNum(l),v=f<1e3?f+" m":f/1e3+" km";this._updateScale(this._mScale,v,f/l)},_updateImperial:function(l){var f=l*3.2808399,v,x,A;f>5280?(v=f/5280,x=this._getRoundNum(v),this._updateScale(this._iScale,x+" mi",x/v)):(A=this._getRoundNum(f),this._updateScale(this._iScale,A+" ft",A/f))},_updateScale:function(l,f,v){l.style.width=Math.round(this.options.maxWidth*v)+"px",l.innerHTML=f},_getRoundNum:function(l){var f=Math.pow(10,(Math.floor(l)+"").length-1),v=l/f;return v=v>=10?10:v>=5?5:v>=3?3:v>=2?2:1,f*v}}),EE=function(l){return new dv(l)},AE='<svg aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="12" height="8" viewBox="0 0 12 8" class="leaflet-attribution-flag"><path fill="#4C7BE1" d="M0 0h12v4H0z"/><path fill="#FFD500" d="M0 4h12v3H0z"/><path fill="#E0BC00" d="M0 7h12v1H0z"/></svg>',lh=zr.extend({options:{position:"bottomright",prefix:'<a href="https://leafletjs.com" title="A JavaScript library for interactive maps">'+(xe.inlineSvg?AE+" ":"")+"Leaflet</a>"},initialize:function(l){b(this,l),this._attributions={}},onAdd:function(l){l.attributionControl=this,this._container=Ve("div","leaflet-control-attribution"),Do(this._container);for(var f in l._layers)l._layers[f].getAttribution&&this.addAttribution(l._layers[f].getAttribution());return this._update(),l.on("layeradd",this._addAttribution,this),this._container},onRemove:function(l){l.off("layeradd",this._addAttribution,this)},_addAttribution:function(l){l.layer.getAttribution&&(this.addAttribution(l.layer.getAttribution()),l.layer.once("remove",function(){this.removeAttribution(l.layer.getAttribution())},this))},setPrefix:function(l){return this.options.prefix=l,this._update(),this},addAttribution:function(l){return l?(this._attributions[l]||(this._attributions[l]=0),this._attributions[l]++,this._update(),this):this},removeAttribution:function(l){return l?(this._attributions[l]&&(this._attributions[l]--,this._update()),this):this},_update:function(){if(this._map){var l=[];for(var f in this._attributions)this._attributions[f]&&l.push(f);var v=[];this.options.prefix&&v.push(this.options.prefix),l.length&&v.push(l.join(", ")),this._container.innerHTML=v.join(' <span aria-hidden="true">|</span> ')}}});je.mergeOptions({attributionControl:!0}),je.addInitHook(function(){this.options.attributionControl&&new lh().addTo(this)});var RE=function(l){return new lh(l)};zr.Layers=cv,zr.Zoom=sh,zr.Scale=dv,zr.Attribution=lh,No.layers=ME,No.zoom=PE,No.scale=EE,No.attribution=RE;var en=X.extend({initialize:function(l){this._map=l},enable:function(){return this._enabled?this:(this._enabled=!0,this.addHooks(),this)},disable:function(){return this._enabled?(this._enabled=!1,this.removeHooks(),this):this},enabled:function(){return!!this._enabled}});en.addTo=function(l,f){return l.addHandler(f,this),this};var DE={Events:Q},hv=xe.touch?"touchstart mousedown":"mousedown",$n=W.extend({options:{clickTolerance:3},initialize:function(l,f,v,x){b(this,x),this._element=l,this._dragStartTarget=f||l,this._preventOutline=v},enable:function(){this._enabled||(Le(this._dragStartTarget,hv,this._onDown,this),this._enabled=!0)},disable:function(){this._enabled&&($n._dragging===this&&this.finishDrag(!0),et(this._dragStartTarget,hv,this._onDown,this),this._enabled=!1,this._moved=!1)},_onDown:function(l){if(this._enabled&&(this._moved=!1,!Yd(this._element,"leaflet-zoom-anim"))){if(l.touches&&l.touches.length!==1){$n._dragging===this&&this.finishDrag();return}if(!($n._dragging||l.shiftKey||l.which!==1&&l.button!==1&&!l.touches)&&($n._dragging=this,this._preventOutline&&eh(this._element),Kd(),Eo(),!this._moving)){this.fire("down");var f=l.touches?l.touches[0]:l,v=iv(this._element);this._startPoint=new q(f.clientX,f.clientY),this._startPos=hi(this._element),this._parentScale=th(v);var x=l.type==="mousedown";Le(document,x?"mousemove":"touchmove",this._onMove,this),Le(document,x?"mouseup":"touchend touchcancel",this._onUp,this)}}},_onMove:function(l){if(this._enabled){if(l.touches&&l.touches.length>1){this._moved=!0;return}var f=l.touches&&l.touches.length===1?l.touches[0]:l,v=new q(f.clientX,f.clientY)._subtract(this._startPoint);!v.x&&!v.y||Math.abs(v.x)+Math.abs(v.y)<this.options.clickTolerance||(v.x/=this._parentScale.x,v.y/=this._parentScale.y,$t(l),this._moved||(this.fire("dragstart"),this._moved=!0,Oe(document.body,"leaflet-dragging"),this._lastTarget=l.target||l.srcElement,window.SVGElementInstance&&this._lastTarget instanceof window.SVGElementInstance&&(this._lastTarget=this._lastTarget.correspondingUseElement),Oe(this._lastTarget,"leaflet-drag-target")),this._newPos=this._startPos.add(v),this._moving=!0,this._lastEvent=l,this._updatePosition())}},_updatePosition:function(){var l={originalEvent:this._lastEvent};this.fire("predrag",l),wt(this._element,this._newPos),this.fire("drag",l)},_onUp:function(){this._enabled&&this.finishDrag()},finishDrag:function(l){mt(document.body,"leaflet-dragging"),this._lastTarget&&(mt(this._lastTarget,"leaflet-drag-target"),this._lastTarget=null),et(document,"mousemove touchmove",this._onMove,this),et(document,"mouseup touchend touchcancel",this._onUp,this),Qd(),Ao();var f=this._moved&&this._moving;this._moving=!1,$n._dragging=!1,f&&this.fire("dragend",{noInertia:l,distance:this._newPos.distanceTo(this._startPos)})}});function fv(l,f,v){var x,A=[1,4,2,8],F,K,te,re,ce,ye,Se,Ie;for(F=0,ye=l.length;F<ye;F++)l[F]._code=mi(l[F],f);for(te=0;te<4;te++){for(Se=A[te],x=[],F=0,ye=l.length,K=ye-1;F<ye;K=F++)re=l[F],ce=l[K],re._code&Se?ce._code&Se||(Ie=Ll(ce,re,Se,f,v),Ie._code=mi(Ie,f),x.push(Ie)):(ce._code&Se&&(Ie=Ll(ce,re,Se,f,v),Ie._code=mi(Ie,f),x.push(Ie)),x.push(re));l=x}return l}function pv(l,f){var v,x,A,F,K,te,re,ce,ye;if(!l||l.length===0)throw new Error("latlngs not passed");Ar(l)||(console.warn("latlngs are not flat! Only the first ring will be used"),l=l[0]);var Se=ue([0,0]),Ie=ae(l),er=Ie.getNorthWest().distanceTo(Ie.getSouthWest())*Ie.getNorthEast().distanceTo(Ie.getNorthWest());er<1700&&(Se=uh(l));var kt=l.length,Rr=[];for(v=0;v<kt;v++){var dr=ue(l[v]);Rr.push(f.project(ue([dr.lat-Se.lat,dr.lng-Se.lng])))}for(te=re=ce=0,v=0,x=kt-1;v<kt;x=v++)A=Rr[v],F=Rr[x],K=A.y*F.x-F.y*A.x,re+=(A.x+F.x)*K,ce+=(A.y+F.y)*K,te+=K*3;te===0?ye=Rr[0]:ye=[re/te,ce/te];var oa=f.unproject(Z(ye));return ue([oa.lat+Se.lat,oa.lng+Se.lng])}function uh(l){for(var f=0,v=0,x=0,A=0;A<l.length;A++){var F=ue(l[A]);f+=F.lat,v+=F.lng,x++}return ue([f/x,v/x])}var NE={__proto__:null,clipPolygon:fv,polygonCenter:pv,centroid:uh};function mv(l,f){if(!f||!l.length)return l.slice();var v=f*f;return l=OE(l,v),l=LE(l,v),l}function gv(l,f,v){return Math.sqrt(ko(l,f,v,!0))}function kE(l,f,v){return ko(l,f,v)}function LE(l,f){var v=l.length,x=typeof Uint8Array!="undefined"?Uint8Array:Array,A=new x(v);A[0]=A[v-1]=1,ch(l,A,f,0,v-1);var F,K=[];for(F=0;F<v;F++)A[F]&&K.push(l[F]);return K}function ch(l,f,v,x,A){var F=0,K,te,re;for(te=x+1;te<=A-1;te++)re=ko(l[te],l[x],l[A],!0),re>F&&(K=te,F=re);F>v&&(f[K]=1,ch(l,f,v,x,K),ch(l,f,v,K,A))}function OE(l,f){for(var v=[l[0]],x=1,A=0,F=l.length;x<F;x++)IE(l[x],l[A])>f&&(v.push(l[x]),A=x);return A<F-1&&v.push(l[F-1]),v}var vv;function yv(l,f,v,x,A){var F=x?vv:mi(l,v),K=mi(f,v),te,re,ce;for(vv=K;;){if(!(F|K))return[l,f];if(F&K)return!1;te=F||K,re=Ll(l,f,te,v,A),ce=mi(re,v),te===F?(l=re,F=ce):(f=re,K=ce)}}function Ll(l,f,v,x,A){var F=f.x-l.x,K=f.y-l.y,te=x.min,re=x.max,ce,ye;return v&8?(ce=l.x+F*(re.y-l.y)/K,ye=re.y):v&4?(ce=l.x+F*(te.y-l.y)/K,ye=te.y):v&2?(ce=re.x,ye=l.y+K*(re.x-l.x)/F):v&1&&(ce=te.x,ye=l.y+K*(te.x-l.x)/F),new q(ce,ye,A)}function mi(l,f){var v=0;return l.x<f.min.x?v|=1:l.x>f.max.x&&(v|=2),l.y<f.min.y?v|=4:l.y>f.max.y&&(v|=8),v}function IE(l,f){var v=f.x-l.x,x=f.y-l.y;return v*v+x*x}function ko(l,f,v,x){var A=f.x,F=f.y,K=v.x-A,te=v.y-F,re=K*K+te*te,ce;return re>0&&(ce=((l.x-A)*K+(l.y-F)*te)/re,ce>1?(A=v.x,F=v.y):ce>0&&(A+=K*ce,F+=te*ce)),K=l.x-A,te=l.y-F,x?K*K+te*te:new q(A,F)}function Ar(l){return!S(l[0])||typeof l[0][0]!="object"&&typeof l[0][0]!="undefined"}function bv(l){return console.warn("Deprecated use of _flat, please use L.LineUtil.isFlat instead."),Ar(l)}function _v(l,f){var v,x,A,F,K,te,re,ce;if(!l||l.length===0)throw new Error("latlngs not passed");Ar(l)||(console.warn("latlngs are not flat! Only the first ring will be used"),l=l[0]);var ye=ue([0,0]),Se=ae(l),Ie=Se.getNorthWest().distanceTo(Se.getSouthWest())*Se.getNorthEast().distanceTo(Se.getNorthWest());Ie<1700&&(ye=uh(l));var er=l.length,kt=[];for(v=0;v<er;v++){var Rr=ue(l[v]);kt.push(f.project(ue([Rr.lat-ye.lat,Rr.lng-ye.lng])))}for(v=0,x=0;v<er-1;v++)x+=kt[v].distanceTo(kt[v+1])/2;if(x===0)ce=kt[0];else for(v=0,F=0;v<er-1;v++)if(K=kt[v],te=kt[v+1],A=K.distanceTo(te),F+=A,F>x){re=(F-x)/A,ce=[te.x-re*(te.x-K.x),te.y-re*(te.y-K.y)];break}var dr=f.unproject(Z(ce));return ue([dr.lat+ye.lat,dr.lng+ye.lng])}var FE={__proto__:null,simplify:mv,pointToSegmentDistance:gv,closestPointOnSegment:kE,clipSegment:yv,_getEdgeIntersection:Ll,_getBitCode:mi,_sqClosestPointOnSegment:ko,isFlat:Ar,_flat:bv,polylineCenter:_v},dh={project:function(l){return new q(l.lng,l.lat)},unproject:function(l){return new se(l.y,l.x)},bounds:new J([-180,-90],[180,90])},hh={R:6378137,R_MINOR:6356752314245179e-9,bounds:new J([-2003750834279e-5,-1549657073972e-5],[2003750834279e-5,1876465623138e-5]),project:function(l){var f=Math.PI/180,v=this.R,x=l.lat*f,A=this.R_MINOR/v,F=Math.sqrt(1-A*A),K=F*Math.sin(x),te=Math.tan(Math.PI/4-x/2)/Math.pow((1-K)/(1+K),F/2);return x=-v*Math.log(Math.max(te,1e-10)),new q(l.lng*f*v,x)},unproject:function(l){for(var f=180/Math.PI,v=this.R,x=this.R_MINOR/v,A=Math.sqrt(1-x*x),F=Math.exp(-l.y/v),K=Math.PI/2-2*Math.atan(F),te=0,re=.1,ce;te<15&&Math.abs(re)>1e-7;te++)ce=A*Math.sin(K),ce=Math.pow((1-ce)/(1+ce),A/2),re=Math.PI/2-2*Math.atan(F*ce)-K,K+=re;return new se(K*f,l.x*f/v)}},$E={__proto__:null,LonLat:dh,Mercator:hh,SphericalMercator:ke},BE=i({},pe,{code:"EPSG:3395",projection:hh,transformation:function(){var l=.5/(Math.PI*hh.R);return le(l,.5,-l,.5)}()}),wv=i({},pe,{code:"EPSG:4326",projection:dh,transformation:le(1/180,1,-1/180,.5)}),zE=i({},me,{projection:dh,transformation:le(1,0,-1,0),scale:function(l){return Math.pow(2,l)},zoom:function(l){return Math.log(l)/Math.LN2},distance:function(l,f){var v=f.lng-l.lng,x=f.lat-l.lat;return Math.sqrt(v*v+x*x)},infinite:!0});me.Earth=pe,me.EPSG3395=BE,me.EPSG3857=He,me.EPSG900913=Te,me.EPSG4326=wv,me.Simple=zE;var Hr=W.extend({options:{pane:"overlayPane",attribution:null,bubblingMouseEvents:!0},addTo:function(l){return l.addLayer(this),this},remove:function(){return this.removeFrom(this._map||this._mapToAdd)},removeFrom:function(l){return l&&l.removeLayer(this),this},getPane:function(l){return this._map.getPane(l?this.options[l]||l:this.options.pane)},addInteractiveTarget:function(l){return this._map._targets[u(l)]=this,this},removeInteractiveTarget:function(l){return delete this._map._targets[u(l)],this},getAttribution:function(){return this.options.attribution},_layerAdd:function(l){var f=l.target;if(f.hasLayer(this)){if(this._map=f,this._zoomAnimated=f._zoomAnimated,this.getEvents){var v=this.getEvents();f.on(v,this),this.once("remove",function(){f.off(v,this)},this)}this.onAdd(f),this.fire("add"),f.fire("layeradd",{layer:this})}}});je.include({addLayer:function(l){if(!l._layerAdd)throw new Error("The provided object is not a Layer.");var f=u(l);return this._layers[f]?this:(this._layers[f]=l,l._mapToAdd=this,l.beforeAdd&&l.beforeAdd(this),this.whenReady(l._layerAdd,l),this)},removeLayer:function(l){var f=u(l);return this._layers[f]?(this._loaded&&l.onRemove(this),delete this._layers[f],this._loaded&&(this.fire("layerremove",{layer:l}),l.fire("remove")),l._map=l._mapToAdd=null,this):this},hasLayer:function(l){return u(l)in this._layers},eachLayer:function(l,f){for(var v in this._layers)l.call(f,this._layers[v]);return this},_addLayers:function(l){l=l?S(l)?l:[l]:[];for(var f=0,v=l.length;f<v;f++)this.addLayer(l[f])},_addZoomLimit:function(l){(!isNaN(l.options.maxZoom)||!isNaN(l.options.minZoom))&&(this._zoomBoundLayers[u(l)]=l,this._updateZoomLevels())},_removeZoomLimit:function(l){var f=u(l);this._zoomBoundLayers[f]&&(delete this._zoomBoundLayers[f],this._updateZoomLevels())},_updateZoomLevels:function(){var l=1/0,f=-1/0,v=this._getZoomSpan();for(var x in this._zoomBoundLayers){var A=this._zoomBoundLayers[x].options;l=A.minZoom===void 0?l:Math.min(l,A.minZoom),f=A.maxZoom===void 0?f:Math.max(f,A.maxZoom)}this._layersMaxZoom=f===-1/0?void 0:f,this._layersMinZoom=l===1/0?void 0:l,v!==this._getZoomSpan()&&this.fire("zoomlevelschange"),this.options.maxZoom===void 0&&this._layersMaxZoom&&this.getZoom()>this._layersMaxZoom&&this.setZoom(this._layersMaxZoom),this.options.minZoom===void 0&&this._layersMinZoom&&this.getZoom()<this._layersMinZoom&&this.setZoom(this._layersMinZoom)}});var ta=Hr.extend({initialize:function(l,f){b(this,f),this._layers={};var v,x;if(l)for(v=0,x=l.length;v<x;v++)this.addLayer(l[v])},addLayer:function(l){var f=this.getLayerId(l);return this._layers[f]=l,this._map&&this._map.addLayer(l),this},removeLayer:function(l){var f=l in this._layers?l:this.getLayerId(l);return this._map&&this._layers[f]&&this._map.removeLayer(this._layers[f]),delete this._layers[f],this},hasLayer:function(l){var f=typeof l=="number"?l:this.getLayerId(l);return f in this._layers},clearLayers:function(){return this.eachLayer(this.removeLayer,this)},invoke:function(l){var f=Array.prototype.slice.call(arguments,1),v,x;for(v in this._layers)x=this._layers[v],x[l]&&x[l].apply(x,f);return this},onAdd:function(l){this.eachLayer(l.addLayer,l)},onRemove:function(l){this.eachLayer(l.removeLayer,l)},eachLayer:function(l,f){for(var v in this._layers)l.call(f,this._layers[v]);return this},getLayer:function(l){return this._layers[l]},getLayers:function(){var l=[];return this.eachLayer(l.push,l),l},setZIndex:function(l){return this.invoke("setZIndex",l)},getLayerId:function(l){return u(l)}}),HE=function(l,f){return new ta(l,f)},Tn=ta.extend({addLayer:function(l){return this.hasLayer(l)?this:(l.addEventParent(this),ta.prototype.addLayer.call(this,l),this.fire("layeradd",{layer:l}))},removeLayer:function(l){return this.hasLayer(l)?(l in this._layers&&(l=this._layers[l]),l.removeEventParent(this),ta.prototype.removeLayer.call(this,l),this.fire("layerremove",{layer:l})):this},setStyle:function(l){return this.invoke("setStyle",l)},bringToFront:function(){return this.invoke("bringToFront")},bringToBack:function(){return this.invoke("bringToBack")},getBounds:function(){var l=new oe;for(var f in this._layers){var v=this._layers[f];l.extend(v.getBounds?v.getBounds():v.getLatLng())}return l}}),WE=function(l,f){return new Tn(l,f)},ra=X.extend({options:{popupAnchor:[0,0],tooltipAnchor:[0,0],crossOrigin:!1},initialize:function(l){b(this,l)},createIcon:function(l){return this._createIcon("icon",l)},createShadow:function(l){return this._createIcon("shadow",l)},_createIcon:function(l,f){var v=this._getIconUrl(l);if(!v){if(l==="icon")throw new Error("iconUrl not set in Icon options (see the docs).");return null}var x=this._createImg(v,f&&f.tagName==="IMG"?f:null);return this._setIconStyles(x,l),(this.options.crossOrigin||this.options.crossOrigin==="")&&(x.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),x},_setIconStyles:function(l,f){var v=this.options,x=v[f+"Size"];typeof x=="number"&&(x=[x,x]);var A=Z(x),F=Z(f==="shadow"&&v.shadowAnchor||v.iconAnchor||A&&A.divideBy(2,!0));l.className="leaflet-marker-"+f+" "+(v.className||""),F&&(l.style.marginLeft=-F.x+"px",l.style.marginTop=-F.y+"px"),A&&(l.style.width=A.x+"px",l.style.height=A.y+"px")},_createImg:function(l,f){return f=f||document.createElement("img"),f.src=l,f},_getIconUrl:function(l){return xe.retina&&this.options[l+"RetinaUrl"]||this.options[l+"Url"]}});function jE(l){return new ra(l)}var Lo=ra.extend({options:{iconUrl:"marker-icon.png",iconRetinaUrl:"marker-icon-2x.png",shadowUrl:"marker-shadow.png",iconSize:[25,41],iconAnchor:[12,41],popupAnchor:[1,-34],tooltipAnchor:[16,-28],shadowSize:[41,41]},_getIconUrl:function(l){return typeof Lo.imagePath!="string"&&(Lo.imagePath=this._detectIconPath()),(this.options.imagePath||Lo.imagePath)+ra.prototype._getIconUrl.call(this,l)},_stripUrl:function(l){var f=function(v,x,A){var F=x.exec(v);return F&&F[A]};return l=f(l,/^url\((['"])?(.+)\1\)$/,2),l&&f(l,/^(.*)marker-icon\.png$/,1)},_detectIconPath:function(){var l=Ve("div","leaflet-default-icon-path",document.body),f=Po(l,"background-image")||Po(l,"backgroundImage");if(document.body.removeChild(l),f=this._stripUrl(f),f)return f;var v=document.querySelector('link[href$="leaflet.css"]');return v?v.href.substring(0,v.href.length-11-1):""}}),Cv=en.extend({initialize:function(l){this._marker=l},addHooks:function(){var l=this._marker._icon;this._draggable||(this._draggable=new $n(l,l,!0)),this._draggable.on({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).enable(),Oe(l,"leaflet-marker-draggable")},removeHooks:function(){this._draggable.off({dragstart:this._onDragStart,predrag:this._onPreDrag,drag:this._onDrag,dragend:this._onDragEnd},this).disable(),this._marker._icon&&mt(this._marker._icon,"leaflet-marker-draggable")},moved:function(){return this._draggable&&this._draggable._moved},_adjustPan:function(l){var f=this._marker,v=f._map,x=this._marker.options.autoPanSpeed,A=this._marker.options.autoPanPadding,F=hi(f._icon),K=v.getPixelBounds(),te=v.getPixelOrigin(),re=ne(K.min._subtract(te).add(A),K.max._subtract(te).subtract(A));if(!re.contains(F)){var ce=Z((Math.max(re.max.x,F.x)-re.max.x)/(K.max.x-re.max.x)-(Math.min(re.min.x,F.x)-re.min.x)/(K.min.x-re.min.x),(Math.max(re.max.y,F.y)-re.max.y)/(K.max.y-re.max.y)-(Math.min(re.min.y,F.y)-re.min.y)/(K.min.y-re.min.y)).multiplyBy(x);v.panBy(ce,{animate:!1}),this._draggable._newPos._add(ce),this._draggable._startPos._add(ce),wt(f._icon,this._draggable._newPos),this._onDrag(l),this._panRequest=G(this._adjustPan.bind(this,l))}},_onDragStart:function(){this._oldLatLng=this._marker.getLatLng(),this._marker.closePopup&&this._marker.closePopup(),this._marker.fire("movestart").fire("dragstart")},_onPreDrag:function(l){this._marker.options.autoPan&&(Y(this._panRequest),this._panRequest=G(this._adjustPan.bind(this,l)))},_onDrag:function(l){var f=this._marker,v=f._shadow,x=hi(f._icon),A=f._map.layerPointToLatLng(x);v&&wt(v,x),f._latlng=A,l.latlng=A,l.oldLatLng=this._oldLatLng,f.fire("move",l).fire("drag",l)},_onDragEnd:function(l){Y(this._panRequest),delete this._oldLatLng,this._marker.fire("moveend").fire("dragend",l)}}),Ol=Hr.extend({options:{icon:new Lo,interactive:!0,keyboard:!0,title:"",alt:"Marker",zIndexOffset:0,opacity:1,riseOnHover:!1,riseOffset:250,pane:"markerPane",shadowPane:"shadowPane",bubblingMouseEvents:!1,autoPanOnFocus:!0,draggable:!1,autoPan:!1,autoPanPadding:[50,50],autoPanSpeed:10},initialize:function(l,f){b(this,f),this._latlng=ue(l)},onAdd:function(l){this._zoomAnimated=this._zoomAnimated&&l.options.markerZoomAnimation,this._zoomAnimated&&l.on("zoomanim",this._animateZoom,this),this._initIcon(),this.update()},onRemove:function(l){this.dragging&&this.dragging.enabled()&&(this.options.draggable=!0,this.dragging.removeHooks()),delete this.dragging,this._zoomAnimated&&l.off("zoomanim",this._animateZoom,this),this._removeIcon(),this._removeShadow()},getEvents:function(){return{zoom:this.update,viewreset:this.update}},getLatLng:function(){return this._latlng},setLatLng:function(l){var f=this._latlng;return this._latlng=ue(l),this.update(),this.fire("move",{oldLatLng:f,latlng:this._latlng})},setZIndexOffset:function(l){return this.options.zIndexOffset=l,this.update()},getIcon:function(){return this.options.icon},setIcon:function(l){return this.options.icon=l,this._map&&(this._initIcon(),this.update()),this._popup&&this.bindPopup(this._popup,this._popup.options),this},getElement:function(){return this._icon},update:function(){if(this._icon&&this._map){var l=this._map.latLngToLayerPoint(this._latlng).round();this._setPos(l)}return this},_initIcon:function(){var l=this.options,f="leaflet-zoom-"+(this._zoomAnimated?"animated":"hide"),v=l.icon.createIcon(this._icon),x=!1;v!==this._icon&&(this._icon&&this._removeIcon(),x=!0,l.title&&(v.title=l.title),v.tagName==="IMG"&&(v.alt=l.alt||"")),Oe(v,f),l.keyboard&&(v.tabIndex="0",v.setAttribute("role","button")),this._icon=v,l.riseOnHover&&this.on({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&Le(v,"focus",this._panOnFocus,this);var A=l.icon.createShadow(this._shadow),F=!1;A!==this._shadow&&(this._removeShadow(),F=!0),A&&(Oe(A,f),A.alt=""),this._shadow=A,l.opacity<1&&this._updateOpacity(),x&&this.getPane().appendChild(this._icon),this._initInteraction(),A&&F&&this.getPane(l.shadowPane).appendChild(this._shadow)},_removeIcon:function(){this.options.riseOnHover&&this.off({mouseover:this._bringToFront,mouseout:this._resetZIndex}),this.options.autoPanOnFocus&&et(this._icon,"focus",this._panOnFocus,this),lt(this._icon),this.removeInteractiveTarget(this._icon),this._icon=null},_removeShadow:function(){this._shadow&&lt(this._shadow),this._shadow=null},_setPos:function(l){this._icon&&wt(this._icon,l),this._shadow&&wt(this._shadow,l),this._zIndex=l.y+this.options.zIndexOffset,this._resetZIndex()},_updateZIndex:function(l){this._icon&&(this._icon.style.zIndex=this._zIndex+l)},_animateZoom:function(l){var f=this._map._latLngToNewLayerPoint(this._latlng,l.zoom,l.center).round();this._setPos(f)},_initInteraction:function(){if(this.options.interactive&&(Oe(this._icon,"leaflet-interactive"),this.addInteractiveTarget(this._icon),Cv)){var l=this.options.draggable;this.dragging&&(l=this.dragging.enabled(),this.dragging.disable()),this.dragging=new Cv(this),l&&this.dragging.enable()}},setOpacity:function(l){return this.options.opacity=l,this._map&&this._updateOpacity(),this},_updateOpacity:function(){var l=this.options.opacity;this._icon&&Er(this._icon,l),this._shadow&&Er(this._shadow,l)},_bringToFront:function(){this._updateZIndex(this.options.riseOffset)},_resetZIndex:function(){this._updateZIndex(0)},_panOnFocus:function(){var l=this._map;if(l){var f=this.options.icon.options,v=f.iconSize?Z(f.iconSize):Z(0,0),x=f.iconAnchor?Z(f.iconAnchor):Z(0,0);l.panInside(this._latlng,{paddingTopLeft:x,paddingBottomRight:v.subtract(x)})}},_getPopupAnchor:function(){return this.options.icon.options.popupAnchor},_getTooltipAnchor:function(){return this.options.icon.options.tooltipAnchor}});function VE(l,f){return new Ol(l,f)}var Bn=Hr.extend({options:{stroke:!0,color:"#3388ff",weight:3,opacity:1,lineCap:"round",lineJoin:"round",dashArray:null,dashOffset:null,fill:!1,fillColor:null,fillOpacity:.2,fillRule:"evenodd",interactive:!0,bubblingMouseEvents:!0},beforeAdd:function(l){this._renderer=l.getRenderer(this)},onAdd:function(){this._renderer._initPath(this),this._reset(),this._renderer._addPath(this)},onRemove:function(){this._renderer._removePath(this)},redraw:function(){return this._map&&this._renderer._updatePath(this),this},setStyle:function(l){return b(this,l),this._renderer&&(this._renderer._updateStyle(this),this.options.stroke&&l&&Object.prototype.hasOwnProperty.call(l,"weight")&&this._updateBounds()),this},bringToFront:function(){return this._renderer&&this._renderer._bringToFront(this),this},bringToBack:function(){return this._renderer&&this._renderer._bringToBack(this),this},getElement:function(){return this._path},_reset:function(){this._project(),this._update()},_clickTolerance:function(){return(this.options.stroke?this.options.weight/2:0)+(this._renderer.options.tolerance||0)}}),Il=Bn.extend({options:{fill:!0,radius:10},initialize:function(l,f){b(this,f),this._latlng=ue(l),this._radius=this.options.radius},setLatLng:function(l){var f=this._latlng;return this._latlng=ue(l),this.redraw(),this.fire("move",{oldLatLng:f,latlng:this._latlng})},getLatLng:function(){return this._latlng},setRadius:function(l){return this.options.radius=this._radius=l,this.redraw()},getRadius:function(){return this._radius},setStyle:function(l){var f=l&&l.radius||this._radius;return Bn.prototype.setStyle.call(this,l),this.setRadius(f),this},_project:function(){this._point=this._map.latLngToLayerPoint(this._latlng),this._updateBounds()},_updateBounds:function(){var l=this._radius,f=this._radiusY||l,v=this._clickTolerance(),x=[l+v,f+v];this._pxBounds=new J(this._point.subtract(x),this._point.add(x))},_update:function(){this._map&&this._updatePath()},_updatePath:function(){this._renderer._updateCircle(this)},_empty:function(){return this._radius&&!this._renderer._bounds.intersects(this._pxBounds)},_containsPoint:function(l){return l.distanceTo(this._point)<=this._radius+this._clickTolerance()}});function UE(l,f){return new Il(l,f)}var fh=Il.extend({initialize:function(l,f,v){if(typeof f=="number"&&(f=i({},v,{radius:f})),b(this,f),this._latlng=ue(l),isNaN(this.options.radius))throw new Error("Circle radius cannot be NaN");this._mRadius=this.options.radius},setRadius:function(l){return this._mRadius=l,this.redraw()},getRadius:function(){return this._mRadius},getBounds:function(){var l=[this._radius,this._radiusY||this._radius];return new oe(this._map.layerPointToLatLng(this._point.subtract(l)),this._map.layerPointToLatLng(this._point.add(l)))},setStyle:Bn.prototype.setStyle,_project:function(){var l=this._latlng.lng,f=this._latlng.lat,v=this._map,x=v.options.crs;if(x.distance===pe.distance){var A=Math.PI/180,F=this._mRadius/pe.R/A,K=v.project([f+F,l]),te=v.project([f-F,l]),re=K.add(te).divideBy(2),ce=v.unproject(re).lat,ye=Math.acos((Math.cos(F*A)-Math.sin(f*A)*Math.sin(ce*A))/(Math.cos(f*A)*Math.cos(ce*A)))/A;(isNaN(ye)||ye===0)&&(ye=F/Math.cos(Math.PI/180*f)),this._point=re.subtract(v.getPixelOrigin()),this._radius=isNaN(ye)?0:re.x-v.project([ce,l-ye]).x,this._radiusY=re.y-K.y}else{var Se=x.unproject(x.project(this._latlng).subtract([this._mRadius,0]));this._point=v.latLngToLayerPoint(this._latlng),this._radius=this._point.x-v.latLngToLayerPoint(Se).x}this._updateBounds()}});function GE(l,f,v){return new fh(l,f,v)}var Sn=Bn.extend({options:{smoothFactor:1,noClip:!1},initialize:function(l,f){b(this,f),this._setLatLngs(l)},getLatLngs:function(){return this._latlngs},setLatLngs:function(l){return this._setLatLngs(l),this.redraw()},isEmpty:function(){return!this._latlngs.length},closestLayerPoint:function(l){for(var f=1/0,v=null,x=ko,A,F,K=0,te=this._parts.length;K<te;K++)for(var re=this._parts[K],ce=1,ye=re.length;ce<ye;ce++){A=re[ce-1],F=re[ce];var Se=x(l,A,F,!0);Se<f&&(f=Se,v=x(l,A,F))}return v&&(v.distance=Math.sqrt(f)),v},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return _v(this._defaultShape(),this._map.options.crs)},getBounds:function(){return this._bounds},addLatLng:function(l,f){return f=f||this._defaultShape(),l=ue(l),f.push(l),this._bounds.extend(l),this.redraw()},_setLatLngs:function(l){this._bounds=new oe,this._latlngs=this._convertLatLngs(l)},_defaultShape:function(){return Ar(this._latlngs)?this._latlngs:this._latlngs[0]},_convertLatLngs:function(l){for(var f=[],v=Ar(l),x=0,A=l.length;x<A;x++)v?(f[x]=ue(l[x]),this._bounds.extend(f[x])):f[x]=this._convertLatLngs(l[x]);return f},_project:function(){var l=new J;this._rings=[],this._projectLatlngs(this._latlngs,this._rings,l),this._bounds.isValid()&&l.isValid()&&(this._rawPxBounds=l,this._updateBounds())},_updateBounds:function(){var l=this._clickTolerance(),f=new q(l,l);this._rawPxBounds&&(this._pxBounds=new J([this._rawPxBounds.min.subtract(f),this._rawPxBounds.max.add(f)]))},_projectLatlngs:function(l,f,v){var x=l[0]instanceof se,A=l.length,F,K;if(x){for(K=[],F=0;F<A;F++)K[F]=this._map.latLngToLayerPoint(l[F]),v.extend(K[F]);f.push(K)}else for(F=0;F<A;F++)this._projectLatlngs(l[F],f,v)},_clipPoints:function(){var l=this._renderer._bounds;if(this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(l))){if(this.options.noClip){this._parts=this._rings;return}var f=this._parts,v,x,A,F,K,te,re;for(v=0,A=0,F=this._rings.length;v<F;v++)for(re=this._rings[v],x=0,K=re.length;x<K-1;x++)te=yv(re[x],re[x+1],l,x,!0),te&&(f[A]=f[A]||[],f[A].push(te[0]),(te[1]!==re[x+1]||x===K-2)&&(f[A].push(te[1]),A++))}},_simplifyPoints:function(){for(var l=this._parts,f=this.options.smoothFactor,v=0,x=l.length;v<x;v++)l[v]=mv(l[v],f)},_update:function(){this._map&&(this._clipPoints(),this._simplifyPoints(),this._updatePath())},_updatePath:function(){this._renderer._updatePoly(this)},_containsPoint:function(l,f){var v,x,A,F,K,te,re=this._clickTolerance();if(!this._pxBounds||!this._pxBounds.contains(l))return!1;for(v=0,F=this._parts.length;v<F;v++)for(te=this._parts[v],x=0,K=te.length,A=K-1;x<K;A=x++)if(!(!f&&x===0)&&gv(l,te[A],te[x])<=re)return!0;return!1}});function qE(l,f){return new Sn(l,f)}Sn._flat=bv;var na=Sn.extend({options:{fill:!0},isEmpty:function(){return!this._latlngs.length||!this._latlngs[0].length},getCenter:function(){if(!this._map)throw new Error("Must add layer to map before using getCenter()");return pv(this._defaultShape(),this._map.options.crs)},_convertLatLngs:function(l){var f=Sn.prototype._convertLatLngs.call(this,l),v=f.length;return v>=2&&f[0]instanceof se&&f[0].equals(f[v-1])&&f.pop(),f},_setLatLngs:function(l){Sn.prototype._setLatLngs.call(this,l),Ar(this._latlngs)&&(this._latlngs=[this._latlngs])},_defaultShape:function(){return Ar(this._latlngs[0])?this._latlngs[0]:this._latlngs[0][0]},_clipPoints:function(){var l=this._renderer._bounds,f=this.options.weight,v=new q(f,f);if(l=new J(l.min.subtract(v),l.max.add(v)),this._parts=[],!(!this._pxBounds||!this._pxBounds.intersects(l))){if(this.options.noClip){this._parts=this._rings;return}for(var x=0,A=this._rings.length,F;x<A;x++)F=fv(this._rings[x],l,!0),F.length&&this._parts.push(F)}},_updatePath:function(){this._renderer._updatePoly(this,!0)},_containsPoint:function(l){var f=!1,v,x,A,F,K,te,re,ce;if(!this._pxBounds||!this._pxBounds.contains(l))return!1;for(F=0,re=this._parts.length;F<re;F++)for(v=this._parts[F],K=0,ce=v.length,te=ce-1;K<ce;te=K++)x=v[K],A=v[te],x.y>l.y!=A.y>l.y&&l.x<(A.x-x.x)*(l.y-x.y)/(A.y-x.y)+x.x&&(f=!f);return f||Sn.prototype._containsPoint.call(this,l,!0)}});function YE(l,f){return new na(l,f)}var Mn=Tn.extend({initialize:function(l,f){b(this,f),this._layers={},l&&this.addData(l)},addData:function(l){var f=S(l)?l:l.features,v,x,A;if(f){for(v=0,x=f.length;v<x;v++)A=f[v],(A.geometries||A.geometry||A.features||A.coordinates)&&this.addData(A);return this}var F=this.options;if(F.filter&&!F.filter(l))return this;var K=Fl(l,F);return K?(K.feature=zl(l),K.defaultOptions=K.options,this.resetStyle(K),F.onEachFeature&&F.onEachFeature(l,K),this.addLayer(K)):this},resetStyle:function(l){return l===void 0?this.eachLayer(this.resetStyle,this):(l.options=i({},l.defaultOptions),this._setLayerStyle(l,this.options.style),this)},setStyle:function(l){return this.eachLayer(function(f){this._setLayerStyle(f,l)},this)},_setLayerStyle:function(l,f){l.setStyle&&(typeof f=="function"&&(f=f(l.feature)),l.setStyle(f))}});function Fl(l,f){var v=l.type==="Feature"?l.geometry:l,x=v?v.coordinates:null,A=[],F=f&&f.pointToLayer,K=f&&f.coordsToLatLng||ph,te,re,ce,ye;if(!x&&!v)return null;switch(v.type){case"Point":return te=K(x),xv(F,l,te,f);case"MultiPoint":for(ce=0,ye=x.length;ce<ye;ce++)te=K(x[ce]),A.push(xv(F,l,te,f));return new Tn(A);case"LineString":case"MultiLineString":return re=$l(x,v.type==="LineString"?0:1,K),new Sn(re,f);case"Polygon":case"MultiPolygon":return re=$l(x,v.type==="Polygon"?1:2,K),new na(re,f);case"GeometryCollection":for(ce=0,ye=v.geometries.length;ce<ye;ce++){var Se=Fl({geometry:v.geometries[ce],type:"Feature",properties:l.properties},f);Se&&A.push(Se)}return new Tn(A);case"FeatureCollection":for(ce=0,ye=v.features.length;ce<ye;ce++){var Ie=Fl(v.features[ce],f);Ie&&A.push(Ie)}return new Tn(A);default:throw new Error("Invalid GeoJSON object.")}}function xv(l,f,v,x){return l?l(f,v):new Ol(v,x&&x.markersInheritOptions&&x)}function ph(l){return new se(l[1],l[0],l[2])}function $l(l,f,v){for(var x=[],A=0,F=l.length,K;A<F;A++)K=f?$l(l[A],f-1,v):(v||ph)(l[A]),x.push(K);return x}function mh(l,f){return l=ue(l),l.alt!==void 0?[p(l.lng,f),p(l.lat,f),p(l.alt,f)]:[p(l.lng,f),p(l.lat,f)]}function Bl(l,f,v,x){for(var A=[],F=0,K=l.length;F<K;F++)A.push(f?Bl(l[F],Ar(l[F])?0:f-1,v,x):mh(l[F],x));return!f&&v&&A.length>0&&A.push(A[0].slice()),A}function ia(l,f){return l.feature?i({},l.feature,{geometry:f}):zl(f)}function zl(l){return l.type==="Feature"||l.type==="FeatureCollection"?l:{type:"Feature",properties:{},geometry:l}}var gh={toGeoJSON:function(l){return ia(this,{type:"Point",coordinates:mh(this.getLatLng(),l)})}};Ol.include(gh),fh.include(gh),Il.include(gh),Sn.include({toGeoJSON:function(l){var f=!Ar(this._latlngs),v=Bl(this._latlngs,f?1:0,!1,l);return ia(this,{type:(f?"Multi":"")+"LineString",coordinates:v})}}),na.include({toGeoJSON:function(l){var f=!Ar(this._latlngs),v=f&&!Ar(this._latlngs[0]),x=Bl(this._latlngs,v?2:f?1:0,!0,l);return f||(x=[x]),ia(this,{type:(v?"Multi":"")+"Polygon",coordinates:x})}}),ta.include({toMultiPoint:function(l){var f=[];return this.eachLayer(function(v){f.push(v.toGeoJSON(l).geometry.coordinates)}),ia(this,{type:"MultiPoint",coordinates:f})},toGeoJSON:function(l){var f=this.feature&&this.feature.geometry&&this.feature.geometry.type;if(f==="MultiPoint")return this.toMultiPoint(l);var v=f==="GeometryCollection",x=[];return this.eachLayer(function(A){if(A.toGeoJSON){var F=A.toGeoJSON(l);if(v)x.push(F.geometry);else{var K=zl(F);K.type==="FeatureCollection"?x.push.apply(x,K.features):x.push(K)}}}),v?ia(this,{geometries:x,type:"GeometryCollection"}):{type:"FeatureCollection",features:x}}});function Tv(l,f){return new Mn(l,f)}var XE=Tv,Hl=Hr.extend({options:{opacity:1,alt:"",interactive:!1,crossOrigin:!1,errorOverlayUrl:"",zIndex:1,className:""},initialize:function(l,f,v){this._url=l,this._bounds=ae(f),b(this,v)},onAdd:function(){this._image||(this._initImage(),this.options.opacity<1&&this._updateOpacity()),this.options.interactive&&(Oe(this._image,"leaflet-interactive"),this.addInteractiveTarget(this._image)),this.getPane().appendChild(this._image),this._reset()},onRemove:function(){lt(this._image),this.options.interactive&&this.removeInteractiveTarget(this._image)},setOpacity:function(l){return this.options.opacity=l,this._image&&this._updateOpacity(),this},setStyle:function(l){return l.opacity&&this.setOpacity(l.opacity),this},bringToFront:function(){return this._map&&Ji(this._image),this},bringToBack:function(){return this._map&&ea(this._image),this},setUrl:function(l){return this._url=l,this._image&&(this._image.src=l),this},setBounds:function(l){return this._bounds=ae(l),this._map&&this._reset(),this},getEvents:function(){var l={zoom:this._reset,viewreset:this._reset};return this._zoomAnimated&&(l.zoomanim=this._animateZoom),l},setZIndex:function(l){return this.options.zIndex=l,this._updateZIndex(),this},getBounds:function(){return this._bounds},getElement:function(){return this._image},_initImage:function(){var l=this._url.tagName==="IMG",f=this._image=l?this._url:Ve("img");if(Oe(f,"leaflet-image-layer"),this._zoomAnimated&&Oe(f,"leaflet-zoom-animated"),this.options.className&&Oe(f,this.options.className),f.onselectstart=h,f.onmousemove=h,f.onload=o(this.fire,this,"load"),f.onerror=o(this._overlayOnError,this,"error"),(this.options.crossOrigin||this.options.crossOrigin==="")&&(f.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),this.options.zIndex&&this._updateZIndex(),l){this._url=f.src;return}f.src=this._url,f.alt=this.options.alt},_animateZoom:function(l){var f=this._map.getZoomScale(l.zoom),v=this._map._latLngBoundsToNewLayerBounds(this._bounds,l.zoom,l.center).min;di(this._image,v,f)},_reset:function(){var l=this._image,f=new J(this._map.latLngToLayerPoint(this._bounds.getNorthWest()),this._map.latLngToLayerPoint(this._bounds.getSouthEast())),v=f.getSize();wt(l,f.min),l.style.width=v.x+"px",l.style.height=v.y+"px"},_updateOpacity:function(){Er(this._image,this.options.opacity)},_updateZIndex:function(){this._image&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._image.style.zIndex=this.options.zIndex)},_overlayOnError:function(){this.fire("error");var l=this.options.errorOverlayUrl;l&&this._url!==l&&(this._url=l,this._image.src=l)},getCenter:function(){return this._bounds.getCenter()}}),ZE=function(l,f,v){return new Hl(l,f,v)},Sv=Hl.extend({options:{autoplay:!0,loop:!0,keepAspectRatio:!0,muted:!1,playsInline:!0},_initImage:function(){var l=this._url.tagName==="VIDEO",f=this._image=l?this._url:Ve("video");if(Oe(f,"leaflet-image-layer"),this._zoomAnimated&&Oe(f,"leaflet-zoom-animated"),this.options.className&&Oe(f,this.options.className),f.onselectstart=h,f.onmousemove=h,f.onloadeddata=o(this.fire,this,"load"),l){for(var v=f.getElementsByTagName("source"),x=[],A=0;A<v.length;A++)x.push(v[A].src);this._url=v.length>0?x:[f.src];return}S(this._url)||(this._url=[this._url]),!this.options.keepAspectRatio&&Object.prototype.hasOwnProperty.call(f.style,"objectFit")&&(f.style.objectFit="fill"),f.autoplay=!!this.options.autoplay,f.loop=!!this.options.loop,f.muted=!!this.options.muted,f.playsInline=!!this.options.playsInline;for(var F=0;F<this._url.length;F++){var K=Ve("source");K.src=this._url[F],f.appendChild(K)}}});function KE(l,f,v){return new Sv(l,f,v)}var Mv=Hl.extend({_initImage:function(){var l=this._image=this._url;Oe(l,"leaflet-image-layer"),this._zoomAnimated&&Oe(l,"leaflet-zoom-animated"),this.options.className&&Oe(l,this.options.className),l.onselectstart=h,l.onmousemove=h}});function QE(l,f,v){return new Mv(l,f,v)}var tn=Hr.extend({options:{interactive:!1,offset:[0,0],className:"",pane:void 0,content:""},initialize:function(l,f){l&&(l instanceof se||S(l))?(this._latlng=ue(l),b(this,f)):(b(this,l),this._source=f),this.options.content&&(this._content=this.options.content)},openOn:function(l){return l=arguments.length?l:this._source._map,l.hasLayer(this)||l.addLayer(this),this},close:function(){return this._map&&this._map.removeLayer(this),this},toggle:function(l){return this._map?this.close():(arguments.length?this._source=l:l=this._source,this._prepareOpen(),this.openOn(l._map)),this},onAdd:function(l){this._zoomAnimated=l._zoomAnimated,this._container||this._initLayout(),l._fadeAnimated&&Er(this._container,0),clearTimeout(this._removeTimeout),this.getPane().appendChild(this._container),this.update(),l._fadeAnimated&&Er(this._container,1),this.bringToFront(),this.options.interactive&&(Oe(this._container,"leaflet-interactive"),this.addInteractiveTarget(this._container))},onRemove:function(l){l._fadeAnimated?(Er(this._container,0),this._removeTimeout=setTimeout(o(lt,void 0,this._container),200)):lt(this._container),this.options.interactive&&(mt(this._container,"leaflet-interactive"),this.removeInteractiveTarget(this._container))},getLatLng:function(){return this._latlng},setLatLng:function(l){return this._latlng=ue(l),this._map&&(this._updatePosition(),this._adjustPan()),this},getContent:function(){return this._content},setContent:function(l){return this._content=l,this.update(),this},getElement:function(){return this._container},update:function(){this._map&&(this._container.style.visibility="hidden",this._updateContent(),this._updateLayout(),this._updatePosition(),this._container.style.visibility="",this._adjustPan())},getEvents:function(){var l={zoom:this._updatePosition,viewreset:this._updatePosition};return this._zoomAnimated&&(l.zoomanim=this._animateZoom),l},isOpen:function(){return!!this._map&&this._map.hasLayer(this)},bringToFront:function(){return this._map&&Ji(this._container),this},bringToBack:function(){return this._map&&ea(this._container),this},_prepareOpen:function(l){var f=this._source;if(!f._map)return!1;if(f instanceof Tn){f=null;var v=this._source._layers;for(var x in v)if(v[x]._map){f=v[x];break}if(!f)return!1;this._source=f}if(!l)if(f.getCenter)l=f.getCenter();else if(f.getLatLng)l=f.getLatLng();else if(f.getBounds)l=f.getBounds().getCenter();else throw new Error("Unable to get source layer LatLng.");return this.setLatLng(l),this._map&&this.update(),!0},_updateContent:function(){if(this._content){var l=this._contentNode,f=typeof this._content=="function"?this._content(this._source||this):this._content;if(typeof f=="string")l.innerHTML=f;else{for(;l.hasChildNodes();)l.removeChild(l.firstChild);l.appendChild(f)}this.fire("contentupdate")}},_updatePosition:function(){if(this._map){var l=this._map.latLngToLayerPoint(this._latlng),f=Z(this.options.offset),v=this._getAnchor();this._zoomAnimated?wt(this._container,l.add(v)):f=f.add(l).add(v);var x=this._containerBottom=-f.y,A=this._containerLeft=-Math.round(this._containerWidth/2)+f.x;this._container.style.bottom=x+"px",this._container.style.left=A+"px"}},_getAnchor:function(){return[0,0]}});je.include({_initOverlay:function(l,f,v,x){var A=f;return A instanceof l||(A=new l(x).setContent(f)),v&&A.setLatLng(v),A}}),Hr.include({_initOverlay:function(l,f,v,x){var A=v;return A instanceof l?(b(A,x),A._source=this):(A=f&&!x?f:new l(x,this),A.setContent(v)),A}});var Wl=tn.extend({options:{pane:"popupPane",offset:[0,7],maxWidth:300,minWidth:50,maxHeight:null,autoPan:!0,autoPanPaddingTopLeft:null,autoPanPaddingBottomRight:null,autoPanPadding:[5,5],keepInView:!1,closeButton:!0,autoClose:!0,closeOnEscapeKey:!0,className:""},openOn:function(l){return l=arguments.length?l:this._source._map,!l.hasLayer(this)&&l._popup&&l._popup.options.autoClose&&l.removeLayer(l._popup),l._popup=this,tn.prototype.openOn.call(this,l)},onAdd:function(l){tn.prototype.onAdd.call(this,l),l.fire("popupopen",{popup:this}),this._source&&(this._source.fire("popupopen",{popup:this},!0),this._source instanceof Bn||this._source.on("preclick",fi))},onRemove:function(l){tn.prototype.onRemove.call(this,l),l.fire("popupclose",{popup:this}),this._source&&(this._source.fire("popupclose",{popup:this},!0),this._source instanceof Bn||this._source.off("preclick",fi))},getEvents:function(){var l=tn.prototype.getEvents.call(this);return(this.options.closeOnClick!==void 0?this.options.closeOnClick:this._map.options.closePopupOnClick)&&(l.preclick=this.close),this.options.keepInView&&(l.moveend=this._adjustPan),l},_initLayout:function(){var l="leaflet-popup",f=this._container=Ve("div",l+" "+(this.options.className||"")+" leaflet-zoom-animated"),v=this._wrapper=Ve("div",l+"-content-wrapper",f);if(this._contentNode=Ve("div",l+"-content",v),Do(f),ah(this._contentNode),Le(f,"contextmenu",fi),this._tipContainer=Ve("div",l+"-tip-container",f),this._tip=Ve("div",l+"-tip",this._tipContainer),this.options.closeButton){var x=this._closeButton=Ve("a",l+"-close-button",f);x.setAttribute("role","button"),x.setAttribute("aria-label","Close popup"),x.href="#close",x.innerHTML='<span aria-hidden="true">&#215;</span>',Le(x,"click",function(A){$t(A),this.close()},this)}},_updateLayout:function(){var l=this._contentNode,f=l.style;f.width="",f.whiteSpace="nowrap";var v=l.offsetWidth;v=Math.min(v,this.options.maxWidth),v=Math.max(v,this.options.minWidth),f.width=v+1+"px",f.whiteSpace="",f.height="";var x=l.offsetHeight,A=this.options.maxHeight,F="leaflet-popup-scrolled";A&&x>A?(f.height=A+"px",Oe(l,F)):mt(l,F),this._containerWidth=this._container.offsetWidth},_animateZoom:function(l){var f=this._map._latLngToNewLayerPoint(this._latlng,l.zoom,l.center),v=this._getAnchor();wt(this._container,f.add(v))},_adjustPan:function(){if(this.options.autoPan){if(this._map._panAnim&&this._map._panAnim.stop(),this._autopanning){this._autopanning=!1;return}var l=this._map,f=parseInt(Po(this._container,"marginBottom"),10)||0,v=this._container.offsetHeight+f,x=this._containerWidth,A=new q(this._containerLeft,-v-this._containerBottom);A._add(hi(this._container));var F=l.layerPointToContainerPoint(A),K=Z(this.options.autoPanPadding),te=Z(this.options.autoPanPaddingTopLeft||K),re=Z(this.options.autoPanPaddingBottomRight||K),ce=l.getSize(),ye=0,Se=0;F.x+x+re.x>ce.x&&(ye=F.x+x-ce.x+re.x),F.x-ye-te.x<0&&(ye=F.x-te.x),F.y+v+re.y>ce.y&&(Se=F.y+v-ce.y+re.y),F.y-Se-te.y<0&&(Se=F.y-te.y),(ye||Se)&&(this.options.keepInView&&(this._autopanning=!0),l.fire("autopanstart").panBy([ye,Se]))}},_getAnchor:function(){return Z(this._source&&this._source._getPopupAnchor?this._source._getPopupAnchor():[0,0])}}),JE=function(l,f){return new Wl(l,f)};je.mergeOptions({closePopupOnClick:!0}),je.include({openPopup:function(l,f,v){return this._initOverlay(Wl,l,f,v).openOn(this),this},closePopup:function(l){return l=arguments.length?l:this._popup,l&&l.close(),this}}),Hr.include({bindPopup:function(l,f){return this._popup=this._initOverlay(Wl,this._popup,l,f),this._popupHandlersAdded||(this.on({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!0),this},unbindPopup:function(){return this._popup&&(this.off({click:this._openPopup,keypress:this._onKeyPress,remove:this.closePopup,move:this._movePopup}),this._popupHandlersAdded=!1,this._popup=null),this},openPopup:function(l){return this._popup&&(this instanceof Tn||(this._popup._source=this),this._popup._prepareOpen(l||this._latlng)&&this._popup.openOn(this._map)),this},closePopup:function(){return this._popup&&this._popup.close(),this},togglePopup:function(){return this._popup&&this._popup.toggle(this),this},isPopupOpen:function(){return this._popup?this._popup.isOpen():!1},setPopupContent:function(l){return this._popup&&this._popup.setContent(l),this},getPopup:function(){return this._popup},_openPopup:function(l){if(!(!this._popup||!this._map)){pi(l);var f=l.layer||l.target;if(this._popup._source===f&&!(f instanceof Bn)){this._map.hasLayer(this._popup)?this.closePopup():this.openPopup(l.latlng);return}this._popup._source=f,this.openPopup(l.latlng)}},_movePopup:function(l){this._popup.setLatLng(l.latlng)},_onKeyPress:function(l){l.originalEvent.keyCode===13&&this._openPopup(l)}});var jl=tn.extend({options:{pane:"tooltipPane",offset:[0,0],direction:"auto",permanent:!1,sticky:!1,opacity:.9},onAdd:function(l){tn.prototype.onAdd.call(this,l),this.setOpacity(this.options.opacity),l.fire("tooltipopen",{tooltip:this}),this._source&&(this.addEventParent(this._source),this._source.fire("tooltipopen",{tooltip:this},!0))},onRemove:function(l){tn.prototype.onRemove.call(this,l),l.fire("tooltipclose",{tooltip:this}),this._source&&(this.removeEventParent(this._source),this._source.fire("tooltipclose",{tooltip:this},!0))},getEvents:function(){var l=tn.prototype.getEvents.call(this);return this.options.permanent||(l.preclick=this.close),l},_initLayout:function(){var l="leaflet-tooltip",f=l+" "+(this.options.className||"")+" leaflet-zoom-"+(this._zoomAnimated?"animated":"hide");this._contentNode=this._container=Ve("div",f),this._container.setAttribute("role","tooltip"),this._container.setAttribute("id","leaflet-tooltip-"+u(this))},_updateLayout:function(){},_adjustPan:function(){},_setPosition:function(l){var f,v,x=this._map,A=this._container,F=x.latLngToContainerPoint(x.getCenter()),K=x.layerPointToContainerPoint(l),te=this.options.direction,re=A.offsetWidth,ce=A.offsetHeight,ye=Z(this.options.offset),Se=this._getAnchor();te==="top"?(f=re/2,v=ce):te==="bottom"?(f=re/2,v=0):te==="center"?(f=re/2,v=ce/2):te==="right"?(f=0,v=ce/2):te==="left"?(f=re,v=ce/2):K.x<F.x?(te="right",f=0,v=ce/2):(te="left",f=re+(ye.x+Se.x)*2,v=ce/2),l=l.subtract(Z(f,v,!0)).add(ye).add(Se),mt(A,"leaflet-tooltip-right"),mt(A,"leaflet-tooltip-left"),mt(A,"leaflet-tooltip-top"),mt(A,"leaflet-tooltip-bottom"),Oe(A,"leaflet-tooltip-"+te),wt(A,l)},_updatePosition:function(){var l=this._map.latLngToLayerPoint(this._latlng);this._setPosition(l)},setOpacity:function(l){this.options.opacity=l,this._container&&Er(this._container,l)},_animateZoom:function(l){var f=this._map._latLngToNewLayerPoint(this._latlng,l.zoom,l.center);this._setPosition(f)},_getAnchor:function(){return Z(this._source&&this._source._getTooltipAnchor&&!this.options.sticky?this._source._getTooltipAnchor():[0,0])}}),e4=function(l,f){return new jl(l,f)};je.include({openTooltip:function(l,f,v){return this._initOverlay(jl,l,f,v).openOn(this),this},closeTooltip:function(l){return l.close(),this}}),Hr.include({bindTooltip:function(l,f){return this._tooltip&&this.isTooltipOpen()&&this.unbindTooltip(),this._tooltip=this._initOverlay(jl,this._tooltip,l,f),this._initTooltipInteractions(),this._tooltip.options.permanent&&this._map&&this._map.hasLayer(this)&&this.openTooltip(),this},unbindTooltip:function(){return this._tooltip&&(this._initTooltipInteractions(!0),this.closeTooltip(),this._tooltip=null),this},_initTooltipInteractions:function(l){if(!(!l&&this._tooltipHandlersAdded)){var f=l?"off":"on",v={remove:this.closeTooltip,move:this._moveTooltip};this._tooltip.options.permanent?v.add=this._openTooltip:(v.mouseover=this._openTooltip,v.mouseout=this.closeTooltip,v.click=this._openTooltip,this._map?this._addFocusListeners():v.add=this._addFocusListeners),this._tooltip.options.sticky&&(v.mousemove=this._moveTooltip),this[f](v),this._tooltipHandlersAdded=!l}},openTooltip:function(l){return this._tooltip&&(this instanceof Tn||(this._tooltip._source=this),this._tooltip._prepareOpen(l)&&(this._tooltip.openOn(this._map),this.getElement?this._setAriaDescribedByOnLayer(this):this.eachLayer&&this.eachLayer(this._setAriaDescribedByOnLayer,this))),this},closeTooltip:function(){if(this._tooltip)return this._tooltip.close()},toggleTooltip:function(){return this._tooltip&&this._tooltip.toggle(this),this},isTooltipOpen:function(){return this._tooltip.isOpen()},setTooltipContent:function(l){return this._tooltip&&this._tooltip.setContent(l),this},getTooltip:function(){return this._tooltip},_addFocusListeners:function(){this.getElement?this._addFocusListenersOnLayer(this):this.eachLayer&&this.eachLayer(this._addFocusListenersOnLayer,this)},_addFocusListenersOnLayer:function(l){var f=typeof l.getElement=="function"&&l.getElement();f&&(Le(f,"focus",function(){this._tooltip._source=l,this.openTooltip()},this),Le(f,"blur",this.closeTooltip,this))},_setAriaDescribedByOnLayer:function(l){var f=typeof l.getElement=="function"&&l.getElement();f&&f.setAttribute("aria-describedby",this._tooltip._container.id)},_openTooltip:function(l){if(!(!this._tooltip||!this._map)){if(this._map.dragging&&this._map.dragging.moving()&&!this._openOnceFlag){this._openOnceFlag=!0;var f=this;this._map.once("moveend",function(){f._openOnceFlag=!1,f._openTooltip(l)});return}this._tooltip._source=l.layer||l.target,this.openTooltip(this._tooltip.options.sticky?l.latlng:void 0)}},_moveTooltip:function(l){var f=l.latlng,v,x;this._tooltip.options.sticky&&l.originalEvent&&(v=this._map.mouseEventToContainerPoint(l.originalEvent),x=this._map.containerPointToLayerPoint(v),f=this._map.layerPointToLatLng(x)),this._tooltip.setLatLng(f)}});var Pv=ra.extend({options:{iconSize:[12,12],html:!1,bgPos:null,className:"leaflet-div-icon"},createIcon:function(l){var f=l&&l.tagName==="DIV"?l:document.createElement("div"),v=this.options;if(v.html instanceof Element?(Al(f),f.appendChild(v.html)):f.innerHTML=v.html!==!1?v.html:"",v.bgPos){var x=Z(v.bgPos);f.style.backgroundPosition=-x.x+"px "+-x.y+"px"}return this._setIconStyles(f,"icon"),f},createShadow:function(){return null}});function t4(l){return new Pv(l)}ra.Default=Lo;var Oo=Hr.extend({options:{tileSize:256,opacity:1,updateWhenIdle:xe.mobile,updateWhenZooming:!0,updateInterval:200,zIndex:1,bounds:null,minZoom:0,maxZoom:void 0,maxNativeZoom:void 0,minNativeZoom:void 0,noWrap:!1,pane:"tilePane",className:"",keepBuffer:2},initialize:function(l){b(this,l)},onAdd:function(){this._initContainer(),this._levels={},this._tiles={},this._resetView()},beforeAdd:function(l){l._addZoomLimit(this)},onRemove:function(l){this._removeAllTiles(),lt(this._container),l._removeZoomLimit(this),this._container=null,this._tileZoom=void 0},bringToFront:function(){return this._map&&(Ji(this._container),this._setAutoZIndex(Math.max)),this},bringToBack:function(){return this._map&&(ea(this._container),this._setAutoZIndex(Math.min)),this},getContainer:function(){return this._container},setOpacity:function(l){return this.options.opacity=l,this._updateOpacity(),this},setZIndex:function(l){return this.options.zIndex=l,this._updateZIndex(),this},isLoading:function(){return this._loading},redraw:function(){if(this._map){this._removeAllTiles();var l=this._clampZoom(this._map.getZoom());l!==this._tileZoom&&(this._tileZoom=l,this._updateLevels()),this._update()}return this},getEvents:function(){var l={viewprereset:this._invalidateAll,viewreset:this._resetView,zoom:this._resetView,moveend:this._onMoveEnd};return this.options.updateWhenIdle||(this._onMove||(this._onMove=c(this._onMoveEnd,this.options.updateInterval,this)),l.move=this._onMove),this._zoomAnimated&&(l.zoomanim=this._animateZoom),l},createTile:function(){return document.createElement("div")},getTileSize:function(){var l=this.options.tileSize;return l instanceof q?l:new q(l,l)},_updateZIndex:function(){this._container&&this.options.zIndex!==void 0&&this.options.zIndex!==null&&(this._container.style.zIndex=this.options.zIndex)},_setAutoZIndex:function(l){for(var f=this.getPane().children,v=-l(-1/0,1/0),x=0,A=f.length,F;x<A;x++)F=f[x].style.zIndex,f[x]!==this._container&&F&&(v=l(v,+F));isFinite(v)&&(this.options.zIndex=v+l(-1,1),this._updateZIndex())},_updateOpacity:function(){if(this._map&&!xe.ielt9){Er(this._container,this.options.opacity);var l=+new Date,f=!1,v=!1;for(var x in this._tiles){var A=this._tiles[x];if(!(!A.current||!A.loaded)){var F=Math.min(1,(l-A.loaded)/200);Er(A.el,F),F<1?f=!0:(A.active?v=!0:this._onOpaqueTile(A),A.active=!0)}}v&&!this._noPrune&&this._pruneTiles(),f&&(Y(this._fadeFrame),this._fadeFrame=G(this._updateOpacity,this))}},_onOpaqueTile:h,_initContainer:function(){this._container||(this._container=Ve("div","leaflet-layer "+(this.options.className||"")),this._updateZIndex(),this.options.opacity<1&&this._updateOpacity(),this.getPane().appendChild(this._container))},_updateLevels:function(){var l=this._tileZoom,f=this.options.maxZoom;if(l!==void 0){for(var v in this._levels)v=Number(v),this._levels[v].el.children.length||v===l?(this._levels[v].el.style.zIndex=f-Math.abs(l-v),this._onUpdateLevel(v)):(lt(this._levels[v].el),this._removeTilesAtZoom(v),this._onRemoveLevel(v),delete this._levels[v]);var x=this._levels[l],A=this._map;return x||(x=this._levels[l]={},x.el=Ve("div","leaflet-tile-container leaflet-zoom-animated",this._container),x.el.style.zIndex=f,x.origin=A.project(A.unproject(A.getPixelOrigin()),l).round(),x.zoom=l,this._setZoomTransform(x,A.getCenter(),A.getZoom()),this._onCreateLevel(x)),this._level=x,x}},_onUpdateLevel:h,_onRemoveLevel:h,_onCreateLevel:h,_pruneTiles:function(){if(this._map){var l,f,v=this._map.getZoom();if(v>this.options.maxZoom||v<this.options.minZoom){this._removeAllTiles();return}for(l in this._tiles)f=this._tiles[l],f.retain=f.current;for(l in this._tiles)if(f=this._tiles[l],f.current&&!f.active){var x=f.coords;this._retainParent(x.x,x.y,x.z,x.z-5)||this._retainChildren(x.x,x.y,x.z,x.z+2)}for(l in this._tiles)this._tiles[l].retain||this._removeTile(l)}},_removeTilesAtZoom:function(l){for(var f in this._tiles)this._tiles[f].coords.z===l&&this._removeTile(f)},_removeAllTiles:function(){for(var l in this._tiles)this._removeTile(l)},_invalidateAll:function(){for(var l in this._levels)lt(this._levels[l].el),this._onRemoveLevel(Number(l)),delete this._levels[l];this._removeAllTiles(),this._tileZoom=void 0},_retainParent:function(l,f,v,x){var A=Math.floor(l/2),F=Math.floor(f/2),K=v-1,te=new q(+A,+F);te.z=+K;var re=this._tileCoordsToKey(te),ce=this._tiles[re];return ce&&ce.active?(ce.retain=!0,!0):(ce&&ce.loaded&&(ce.retain=!0),K>x?this._retainParent(A,F,K,x):!1)},_retainChildren:function(l,f,v,x){for(var A=2*l;A<2*l+2;A++)for(var F=2*f;F<2*f+2;F++){var K=new q(A,F);K.z=v+1;var te=this._tileCoordsToKey(K),re=this._tiles[te];if(re&&re.active){re.retain=!0;continue}else re&&re.loaded&&(re.retain=!0);v+1<x&&this._retainChildren(A,F,v+1,x)}},_resetView:function(l){var f=l&&(l.pinch||l.flyTo);this._setView(this._map.getCenter(),this._map.getZoom(),f,f)},_animateZoom:function(l){this._setView(l.center,l.zoom,!0,l.noUpdate)},_clampZoom:function(l){var f=this.options;return f.minNativeZoom!==void 0&&l<f.minNativeZoom?f.minNativeZoom:f.maxNativeZoom!==void 0&&f.maxNativeZoom<l?f.maxNativeZoom:l},_setView:function(l,f,v,x){var A=Math.round(f);this.options.maxZoom!==void 0&&A>this.options.maxZoom||this.options.minZoom!==void 0&&A<this.options.minZoom?A=void 0:A=this._clampZoom(A);var F=this.options.updateWhenZooming&&A!==this._tileZoom;(!x||F)&&(this._tileZoom=A,this._abortLoading&&this._abortLoading(),this._updateLevels(),this._resetGrid(),A!==void 0&&this._update(l),v||this._pruneTiles(),this._noPrune=!!v),this._setZoomTransforms(l,f)},_setZoomTransforms:function(l,f){for(var v in this._levels)this._setZoomTransform(this._levels[v],l,f)},_setZoomTransform:function(l,f,v){var x=this._map.getZoomScale(v,l.zoom),A=l.origin.multiplyBy(x).subtract(this._map._getNewPixelOrigin(f,v)).round();xe.any3d?di(l.el,A,x):wt(l.el,A)},_resetGrid:function(){var l=this._map,f=l.options.crs,v=this._tileSize=this.getTileSize(),x=this._tileZoom,A=this._map.getPixelWorldBounds(this._tileZoom);A&&(this._globalTileRange=this._pxBoundsToTileRange(A)),this._wrapX=f.wrapLng&&!this.options.noWrap&&[Math.floor(l.project([0,f.wrapLng[0]],x).x/v.x),Math.ceil(l.project([0,f.wrapLng[1]],x).x/v.y)],this._wrapY=f.wrapLat&&!this.options.noWrap&&[Math.floor(l.project([f.wrapLat[0],0],x).y/v.x),Math.ceil(l.project([f.wrapLat[1],0],x).y/v.y)]},_onMoveEnd:function(){!this._map||this._map._animatingZoom||this._update()},_getTiledPixelBounds:function(l){var f=this._map,v=f._animatingZoom?Math.max(f._animateToZoom,f.getZoom()):f.getZoom(),x=f.getZoomScale(v,this._tileZoom),A=f.project(l,this._tileZoom).floor(),F=f.getSize().divideBy(x*2);return new J(A.subtract(F),A.add(F))},_update:function(l){var f=this._map;if(f){var v=this._clampZoom(f.getZoom());if(l===void 0&&(l=f.getCenter()),this._tileZoom!==void 0){var x=this._getTiledPixelBounds(l),A=this._pxBoundsToTileRange(x),F=A.getCenter(),K=[],te=this.options.keepBuffer,re=new J(A.getBottomLeft().subtract([te,-te]),A.getTopRight().add([te,-te]));if(!(isFinite(A.min.x)&&isFinite(A.min.y)&&isFinite(A.max.x)&&isFinite(A.max.y)))throw new Error("Attempted to load an infinite number of tiles");for(var ce in this._tiles){var ye=this._tiles[ce].coords;(ye.z!==this._tileZoom||!re.contains(new q(ye.x,ye.y)))&&(this._tiles[ce].current=!1)}if(Math.abs(v-this._tileZoom)>1){this._setView(l,v);return}for(var Se=A.min.y;Se<=A.max.y;Se++)for(var Ie=A.min.x;Ie<=A.max.x;Ie++){var er=new q(Ie,Se);if(er.z=this._tileZoom,!!this._isValidTile(er)){var kt=this._tiles[this._tileCoordsToKey(er)];kt?kt.current=!0:K.push(er)}}if(K.sort(function(dr,oa){return dr.distanceTo(F)-oa.distanceTo(F)}),K.length!==0){this._loading||(this._loading=!0,this.fire("loading"));var Rr=document.createDocumentFragment();for(Ie=0;Ie<K.length;Ie++)this._addTile(K[Ie],Rr);this._level.el.appendChild(Rr)}}}},_isValidTile:function(l){var f=this._map.options.crs;if(!f.infinite){var v=this._globalTileRange;if(!f.wrapLng&&(l.x<v.min.x||l.x>v.max.x)||!f.wrapLat&&(l.y<v.min.y||l.y>v.max.y))return!1}if(!this.options.bounds)return!0;var x=this._tileCoordsToBounds(l);return ae(this.options.bounds).overlaps(x)},_keyToBounds:function(l){return this._tileCoordsToBounds(this._keyToTileCoords(l))},_tileCoordsToNwSe:function(l){var f=this._map,v=this.getTileSize(),x=l.scaleBy(v),A=x.add(v),F=f.unproject(x,l.z),K=f.unproject(A,l.z);return[F,K]},_tileCoordsToBounds:function(l){var f=this._tileCoordsToNwSe(l),v=new oe(f[0],f[1]);return this.options.noWrap||(v=this._map.wrapLatLngBounds(v)),v},_tileCoordsToKey:function(l){return l.x+":"+l.y+":"+l.z},_keyToTileCoords:function(l){var f=l.split(":"),v=new q(+f[0],+f[1]);return v.z=+f[2],v},_removeTile:function(l){var f=this._tiles[l];f&&(lt(f.el),delete this._tiles[l],this.fire("tileunload",{tile:f.el,coords:this._keyToTileCoords(l)}))},_initTile:function(l){Oe(l,"leaflet-tile");var f=this.getTileSize();l.style.width=f.x+"px",l.style.height=f.y+"px",l.onselectstart=h,l.onmousemove=h,xe.ielt9&&this.options.opacity<1&&Er(l,this.options.opacity)},_addTile:function(l,f){var v=this._getTilePos(l),x=this._tileCoordsToKey(l),A=this.createTile(this._wrapCoords(l),o(this._tileReady,this,l));this._initTile(A),this.createTile.length<2&&G(o(this._tileReady,this,l,null,A)),wt(A,v),this._tiles[x]={el:A,coords:l,current:!0},f.appendChild(A),this.fire("tileloadstart",{tile:A,coords:l})},_tileReady:function(l,f,v){f&&this.fire("tileerror",{error:f,tile:v,coords:l});var x=this._tileCoordsToKey(l);v=this._tiles[x],v&&(v.loaded=+new Date,this._map._fadeAnimated?(Er(v.el,0),Y(this._fadeFrame),this._fadeFrame=G(this._updateOpacity,this)):(v.active=!0,this._pruneTiles()),f||(Oe(v.el,"leaflet-tile-loaded"),this.fire("tileload",{tile:v.el,coords:l})),this._noTilesToLoad()&&(this._loading=!1,this.fire("load"),xe.ielt9||!this._map._fadeAnimated?G(this._pruneTiles,this):setTimeout(o(this._pruneTiles,this),250)))},_getTilePos:function(l){return l.scaleBy(this.getTileSize()).subtract(this._level.origin)},_wrapCoords:function(l){var f=new q(this._wrapX?d(l.x,this._wrapX):l.x,this._wrapY?d(l.y,this._wrapY):l.y);return f.z=l.z,f},_pxBoundsToTileRange:function(l){var f=this.getTileSize();return new J(l.min.unscaleBy(f).floor(),l.max.unscaleBy(f).ceil().subtract([1,1]))},_noTilesToLoad:function(){for(var l in this._tiles)if(!this._tiles[l].loaded)return!1;return!0}});function r4(l){return new Oo(l)}var aa=Oo.extend({options:{minZoom:0,maxZoom:18,subdomains:"abc",errorTileUrl:"",zoomOffset:0,tms:!1,zoomReverse:!1,detectRetina:!1,crossOrigin:!1,referrerPolicy:!1},initialize:function(l,f){this._url=l,f=b(this,f),f.detectRetina&&xe.retina&&f.maxZoom>0?(f.tileSize=Math.floor(f.tileSize/2),f.zoomReverse?(f.zoomOffset--,f.minZoom=Math.min(f.maxZoom,f.minZoom+1)):(f.zoomOffset++,f.maxZoom=Math.max(f.minZoom,f.maxZoom-1)),f.minZoom=Math.max(0,f.minZoom)):f.zoomReverse?f.minZoom=Math.min(f.maxZoom,f.minZoom):f.maxZoom=Math.max(f.minZoom,f.maxZoom),typeof f.subdomains=="string"&&(f.subdomains=f.subdomains.split("")),this.on("tileunload",this._onTileRemove)},setUrl:function(l,f){return this._url===l&&f===void 0&&(f=!0),this._url=l,f||this.redraw(),this},createTile:function(l,f){var v=document.createElement("img");return Le(v,"load",o(this._tileOnLoad,this,f,v)),Le(v,"error",o(this._tileOnError,this,f,v)),(this.options.crossOrigin||this.options.crossOrigin==="")&&(v.crossOrigin=this.options.crossOrigin===!0?"":this.options.crossOrigin),typeof this.options.referrerPolicy=="string"&&(v.referrerPolicy=this.options.referrerPolicy),v.alt="",v.src=this.getTileUrl(l),v},getTileUrl:function(l){var f={r:xe.retina?"@2x":"",s:this._getSubdomain(l),x:l.x,y:l.y,z:this._getZoomForUrl()};if(this._map&&!this._map.options.crs.infinite){var v=this._globalTileRange.max.y-l.y;this.options.tms&&(f.y=v),f["-y"]=v}return C(this._url,i(f,this.options))},_tileOnLoad:function(l,f){xe.ielt9?setTimeout(o(l,this,null,f),0):l(null,f)},_tileOnError:function(l,f,v){var x=this.options.errorTileUrl;x&&f.getAttribute("src")!==x&&(f.src=x),l(v,f)},_onTileRemove:function(l){l.tile.onload=null},_getZoomForUrl:function(){var l=this._tileZoom,f=this.options.maxZoom,v=this.options.zoomReverse,x=this.options.zoomOffset;return v&&(l=f-l),l+x},_getSubdomain:function(l){var f=Math.abs(l.x+l.y)%this.options.subdomains.length;return this.options.subdomains[f]},_abortLoading:function(){var l,f;for(l in this._tiles)if(this._tiles[l].coords.z!==this._tileZoom&&(f=this._tiles[l].el,f.onload=h,f.onerror=h,!f.complete)){f.src=M;var v=this._tiles[l].coords;lt(f),delete this._tiles[l],this.fire("tileabort",{tile:f,coords:v})}},_removeTile:function(l){var f=this._tiles[l];if(f)return f.el.setAttribute("src",M),Oo.prototype._removeTile.call(this,l)},_tileReady:function(l,f,v){if(!(!this._map||v&&v.getAttribute("src")===M))return Oo.prototype._tileReady.call(this,l,f,v)}});function Ev(l,f){return new aa(l,f)}var Av=aa.extend({defaultWmsParams:{service:"WMS",request:"GetMap",layers:"",styles:"",format:"image/jpeg",transparent:!1,version:"1.1.1"},options:{crs:null,uppercase:!1},initialize:function(l,f){this._url=l;var v=i({},this.defaultWmsParams);for(var x in f)x in this.options||(v[x]=f[x]);f=b(this,f);var A=f.detectRetina&&xe.retina?2:1,F=this.getTileSize();v.width=F.x*A,v.height=F.y*A,this.wmsParams=v},onAdd:function(l){this._crs=this.options.crs||l.options.crs,this._wmsVersion=parseFloat(this.wmsParams.version);var f=this._wmsVersion>=1.3?"crs":"srs";this.wmsParams[f]=this._crs.code,aa.prototype.onAdd.call(this,l)},getTileUrl:function(l){var f=this._tileCoordsToNwSe(l),v=this._crs,x=ne(v.project(f[0]),v.project(f[1])),A=x.min,F=x.max,K=(this._wmsVersion>=1.3&&this._crs===wv?[A.y,A.x,F.y,F.x]:[A.x,A.y,F.x,F.y]).join(","),te=aa.prototype.getTileUrl.call(this,l);return te+_(this.wmsParams,te,this.options.uppercase)+(this.options.uppercase?"&BBOX=":"&bbox=")+K},setParams:function(l,f){return i(this.wmsParams,l),f||this.redraw(),this}});function n4(l,f){return new Av(l,f)}aa.WMS=Av,Ev.wms=n4;var Pn=Hr.extend({options:{padding:.1},initialize:function(l){b(this,l),u(this),this._layers=this._layers||{}},onAdd:function(){this._container||(this._initContainer(),Oe(this._container,"leaflet-zoom-animated")),this.getPane().appendChild(this._container),this._update(),this.on("update",this._updatePaths,this)},onRemove:function(){this.off("update",this._updatePaths,this),this._destroyContainer()},getEvents:function(){var l={viewreset:this._reset,zoom:this._onZoom,moveend:this._update,zoomend:this._onZoomEnd};return this._zoomAnimated&&(l.zoomanim=this._onAnimZoom),l},_onAnimZoom:function(l){this._updateTransform(l.center,l.zoom)},_onZoom:function(){this._updateTransform(this._map.getCenter(),this._map.getZoom())},_updateTransform:function(l,f){var v=this._map.getZoomScale(f,this._zoom),x=this._map.getSize().multiplyBy(.5+this.options.padding),A=this._map.project(this._center,f),F=x.multiplyBy(-v).add(A).subtract(this._map._getNewPixelOrigin(l,f));xe.any3d?di(this._container,F,v):wt(this._container,F)},_reset:function(){this._update(),this._updateTransform(this._center,this._zoom);for(var l in this._layers)this._layers[l]._reset()},_onZoomEnd:function(){for(var l in this._layers)this._layers[l]._project()},_updatePaths:function(){for(var l in this._layers)this._layers[l]._update()},_update:function(){var l=this.options.padding,f=this._map.getSize(),v=this._map.containerPointToLayerPoint(f.multiplyBy(-l)).round();this._bounds=new J(v,v.add(f.multiplyBy(1+l*2)).round()),this._center=this._map.getCenter(),this._zoom=this._map.getZoom()}}),Rv=Pn.extend({options:{tolerance:0},getEvents:function(){var l=Pn.prototype.getEvents.call(this);return l.viewprereset=this._onViewPreReset,l},_onViewPreReset:function(){this._postponeUpdatePaths=!0},onAdd:function(){Pn.prototype.onAdd.call(this),this._draw()},_initContainer:function(){var l=this._container=document.createElement("canvas");Le(l,"mousemove",this._onMouseMove,this),Le(l,"click dblclick mousedown mouseup contextmenu",this._onClick,this),Le(l,"mouseout",this._handleMouseOut,this),l._leaflet_disable_events=!0,this._ctx=l.getContext("2d")},_destroyContainer:function(){Y(this._redrawRequest),delete this._ctx,lt(this._container),et(this._container),delete this._container},_updatePaths:function(){if(!this._postponeUpdatePaths){var l;this._redrawBounds=null;for(var f in this._layers)l=this._layers[f],l._update();this._redraw()}},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Pn.prototype._update.call(this);var l=this._bounds,f=this._container,v=l.getSize(),x=xe.retina?2:1;wt(f,l.min),f.width=x*v.x,f.height=x*v.y,f.style.width=v.x+"px",f.style.height=v.y+"px",xe.retina&&this._ctx.scale(2,2),this._ctx.translate(-l.min.x,-l.min.y),this.fire("update")}},_reset:function(){Pn.prototype._reset.call(this),this._postponeUpdatePaths&&(this._postponeUpdatePaths=!1,this._updatePaths())},_initPath:function(l){this._updateDashArray(l),this._layers[u(l)]=l;var f=l._order={layer:l,prev:this._drawLast,next:null};this._drawLast&&(this._drawLast.next=f),this._drawLast=f,this._drawFirst=this._drawFirst||this._drawLast},_addPath:function(l){this._requestRedraw(l)},_removePath:function(l){var f=l._order,v=f.next,x=f.prev;v?v.prev=x:this._drawLast=x,x?x.next=v:this._drawFirst=v,delete l._order,delete this._layers[u(l)],this._requestRedraw(l)},_updatePath:function(l){this._extendRedrawBounds(l),l._project(),l._update(),this._requestRedraw(l)},_updateStyle:function(l){this._updateDashArray(l),this._requestRedraw(l)},_updateDashArray:function(l){if(typeof l.options.dashArray=="string"){var f=l.options.dashArray.split(/[, ]+/),v=[],x,A;for(A=0;A<f.length;A++){if(x=Number(f[A]),isNaN(x))return;v.push(x)}l.options._dashArray=v}else l.options._dashArray=l.options.dashArray},_requestRedraw:function(l){this._map&&(this._extendRedrawBounds(l),this._redrawRequest=this._redrawRequest||G(this._redraw,this))},_extendRedrawBounds:function(l){if(l._pxBounds){var f=(l.options.weight||0)+1;this._redrawBounds=this._redrawBounds||new J,this._redrawBounds.extend(l._pxBounds.min.subtract([f,f])),this._redrawBounds.extend(l._pxBounds.max.add([f,f]))}},_redraw:function(){this._redrawRequest=null,this._redrawBounds&&(this._redrawBounds.min._floor(),this._redrawBounds.max._ceil()),this._clear(),this._draw(),this._redrawBounds=null},_clear:function(){var l=this._redrawBounds;if(l){var f=l.getSize();this._ctx.clearRect(l.min.x,l.min.y,f.x,f.y)}else this._ctx.save(),this._ctx.setTransform(1,0,0,1,0,0),this._ctx.clearRect(0,0,this._container.width,this._container.height),this._ctx.restore()},_draw:function(){var l,f=this._redrawBounds;if(this._ctx.save(),f){var v=f.getSize();this._ctx.beginPath(),this._ctx.rect(f.min.x,f.min.y,v.x,v.y),this._ctx.clip()}this._drawing=!0;for(var x=this._drawFirst;x;x=x.next)l=x.layer,(!f||l._pxBounds&&l._pxBounds.intersects(f))&&l._updatePath();this._drawing=!1,this._ctx.restore()},_updatePoly:function(l,f){if(this._drawing){var v,x,A,F,K=l._parts,te=K.length,re=this._ctx;if(te){for(re.beginPath(),v=0;v<te;v++){for(x=0,A=K[v].length;x<A;x++)F=K[v][x],re[x?"lineTo":"moveTo"](F.x,F.y);f&&re.closePath()}this._fillStroke(re,l)}}},_updateCircle:function(l){if(!(!this._drawing||l._empty())){var f=l._point,v=this._ctx,x=Math.max(Math.round(l._radius),1),A=(Math.max(Math.round(l._radiusY),1)||x)/x;A!==1&&(v.save(),v.scale(1,A)),v.beginPath(),v.arc(f.x,f.y/A,x,0,Math.PI*2,!1),A!==1&&v.restore(),this._fillStroke(v,l)}},_fillStroke:function(l,f){var v=f.options;v.fill&&(l.globalAlpha=v.fillOpacity,l.fillStyle=v.fillColor||v.color,l.fill(v.fillRule||"evenodd")),v.stroke&&v.weight!==0&&(l.setLineDash&&l.setLineDash(f.options&&f.options._dashArray||[]),l.globalAlpha=v.opacity,l.lineWidth=v.weight,l.strokeStyle=v.color,l.lineCap=v.lineCap,l.lineJoin=v.lineJoin,l.stroke())},_onClick:function(l){for(var f=this._map.mouseEventToLayerPoint(l),v,x,A=this._drawFirst;A;A=A.next)v=A.layer,v.options.interactive&&v._containsPoint(f)&&(!(l.type==="click"||l.type==="preclick")||!this._map._draggableMoved(v))&&(x=v);this._fireEvent(x?[x]:!1,l)},_onMouseMove:function(l){if(!(!this._map||this._map.dragging.moving()||this._map._animatingZoom)){var f=this._map.mouseEventToLayerPoint(l);this._handleMouseHover(l,f)}},_handleMouseOut:function(l){var f=this._hoveredLayer;f&&(mt(this._container,"leaflet-interactive"),this._fireEvent([f],l,"mouseout"),this._hoveredLayer=null,this._mouseHoverThrottled=!1)},_handleMouseHover:function(l,f){if(!this._mouseHoverThrottled){for(var v,x,A=this._drawFirst;A;A=A.next)v=A.layer,v.options.interactive&&v._containsPoint(f)&&(x=v);x!==this._hoveredLayer&&(this._handleMouseOut(l),x&&(Oe(this._container,"leaflet-interactive"),this._fireEvent([x],l,"mouseover"),this._hoveredLayer=x)),this._fireEvent(this._hoveredLayer?[this._hoveredLayer]:!1,l),this._mouseHoverThrottled=!0,setTimeout(o(function(){this._mouseHoverThrottled=!1},this),32)}},_fireEvent:function(l,f,v){this._map._fireDOMEvent(f,v||f.type,l)},_bringToFront:function(l){var f=l._order;if(f){var v=f.next,x=f.prev;if(v)v.prev=x;else return;x?x.next=v:v&&(this._drawFirst=v),f.prev=this._drawLast,this._drawLast.next=f,f.next=null,this._drawLast=f,this._requestRedraw(l)}},_bringToBack:function(l){var f=l._order;if(f){var v=f.next,x=f.prev;if(x)x.next=v;else return;v?v.prev=x:x&&(this._drawLast=x),f.prev=null,f.next=this._drawFirst,this._drawFirst.prev=f,this._drawFirst=f,this._requestRedraw(l)}}});function Dv(l){return xe.canvas?new Rv(l):null}var Io=function(){try{return document.namespaces.add("lvml","urn:schemas-microsoft-com:vml"),function(l){return document.createElement("<lvml:"+l+' class="lvml">')}}catch(l){}return function(l){return document.createElement("<"+l+' xmlns="urn:schemas-microsoft.com:vml" class="lvml">')}}(),i4={_initContainer:function(){this._container=Ve("div","leaflet-vml-container")},_update:function(){this._map._animatingZoom||(Pn.prototype._update.call(this),this.fire("update"))},_initPath:function(l){var f=l._container=Io("shape");Oe(f,"leaflet-vml-shape "+(this.options.className||"")),f.coordsize="1 1",l._path=Io("path"),f.appendChild(l._path),this._updateStyle(l),this._layers[u(l)]=l},_addPath:function(l){var f=l._container;this._container.appendChild(f),l.options.interactive&&l.addInteractiveTarget(f)},_removePath:function(l){var f=l._container;lt(f),l.removeInteractiveTarget(f),delete this._layers[u(l)]},_updateStyle:function(l){var f=l._stroke,v=l._fill,x=l.options,A=l._container;A.stroked=!!x.stroke,A.filled=!!x.fill,x.stroke?(f||(f=l._stroke=Io("stroke")),A.appendChild(f),f.weight=x.weight+"px",f.color=x.color,f.opacity=x.opacity,x.dashArray?f.dashStyle=S(x.dashArray)?x.dashArray.join(" "):x.dashArray.replace(/( *, *)/g," "):f.dashStyle="",f.endcap=x.lineCap.replace("butt","flat"),f.joinstyle=x.lineJoin):f&&(A.removeChild(f),l._stroke=null),x.fill?(v||(v=l._fill=Io("fill")),A.appendChild(v),v.color=x.fillColor||x.color,v.opacity=x.fillOpacity):v&&(A.removeChild(v),l._fill=null)},_updateCircle:function(l){var f=l._point.round(),v=Math.round(l._radius),x=Math.round(l._radiusY||v);this._setPath(l,l._empty()?"M0 0":"AL "+f.x+","+f.y+" "+v+","+x+" 0,"+65535*360)},_setPath:function(l,f){l._path.v=f},_bringToFront:function(l){Ji(l._container)},_bringToBack:function(l){ea(l._container)}},Vl=xe.vml?Io:Ae,Fo=Pn.extend({_initContainer:function(){this._container=Vl("svg"),this._container.setAttribute("pointer-events","none"),this._rootGroup=Vl("g"),this._container.appendChild(this._rootGroup)},_destroyContainer:function(){lt(this._container),et(this._container),delete this._container,delete this._rootGroup,delete this._svgSize},_update:function(){if(!(this._map._animatingZoom&&this._bounds)){Pn.prototype._update.call(this);var l=this._bounds,f=l.getSize(),v=this._container;(!this._svgSize||!this._svgSize.equals(f))&&(this._svgSize=f,v.setAttribute("width",f.x),v.setAttribute("height",f.y)),wt(v,l.min),v.setAttribute("viewBox",[l.min.x,l.min.y,f.x,f.y].join(" ")),this.fire("update")}},_initPath:function(l){var f=l._path=Vl("path");l.options.className&&Oe(f,l.options.className),l.options.interactive&&Oe(f,"leaflet-interactive"),this._updateStyle(l),this._layers[u(l)]=l},_addPath:function(l){this._rootGroup||this._initContainer(),this._rootGroup.appendChild(l._path),l.addInteractiveTarget(l._path)},_removePath:function(l){lt(l._path),l.removeInteractiveTarget(l._path),delete this._layers[u(l)]},_updatePath:function(l){l._project(),l._update()},_updateStyle:function(l){var f=l._path,v=l.options;f&&(v.stroke?(f.setAttribute("stroke",v.color),f.setAttribute("stroke-opacity",v.opacity),f.setAttribute("stroke-width",v.weight),f.setAttribute("stroke-linecap",v.lineCap),f.setAttribute("stroke-linejoin",v.lineJoin),v.dashArray?f.setAttribute("stroke-dasharray",v.dashArray):f.removeAttribute("stroke-dasharray"),v.dashOffset?f.setAttribute("stroke-dashoffset",v.dashOffset):f.removeAttribute("stroke-dashoffset")):f.setAttribute("stroke","none"),v.fill?(f.setAttribute("fill",v.fillColor||v.color),f.setAttribute("fill-opacity",v.fillOpacity),f.setAttribute("fill-rule",v.fillRule||"evenodd")):f.setAttribute("fill","none"))},_updatePoly:function(l,f){this._setPath(l,$e(l._parts,f))},_updateCircle:function(l){var f=l._point,v=Math.max(Math.round(l._radius),1),x=Math.max(Math.round(l._radiusY),1)||v,A="a"+v+","+x+" 0 1,0 ",F=l._empty()?"M0 0":"M"+(f.x-v)+","+f.y+A+v*2+",0 "+A+-v*2+",0 ";this._setPath(l,F)},_setPath:function(l,f){l._path.setAttribute("d",f)},_bringToFront:function(l){Ji(l._path)},_bringToBack:function(l){ea(l._path)}});xe.vml&&Fo.include(i4);function Nv(l){return xe.svg||xe.vml?new Fo(l):null}je.include({getRenderer:function(l){var f=l.options.renderer||this._getPaneRenderer(l.options.pane)||this.options.renderer||this._renderer;return f||(f=this._renderer=this._createRenderer()),this.hasLayer(f)||this.addLayer(f),f},_getPaneRenderer:function(l){if(l==="overlayPane"||l===void 0)return!1;var f=this._paneRenderers[l];return f===void 0&&(f=this._createRenderer({pane:l}),this._paneRenderers[l]=f),f},_createRenderer:function(l){return this.options.preferCanvas&&Dv(l)||Nv(l)}});var kv=na.extend({initialize:function(l,f){na.prototype.initialize.call(this,this._boundsToLatLngs(l),f)},setBounds:function(l){return this.setLatLngs(this._boundsToLatLngs(l))},_boundsToLatLngs:function(l){return l=ae(l),[l.getSouthWest(),l.getNorthWest(),l.getNorthEast(),l.getSouthEast()]}});function a4(l,f){return new kv(l,f)}Fo.create=Vl,Fo.pointsToPath=$e,Mn.geometryToLayer=Fl,Mn.coordsToLatLng=ph,Mn.coordsToLatLngs=$l,Mn.latLngToCoords=mh,Mn.latLngsToCoords=Bl,Mn.getFeature=ia,Mn.asFeature=zl,je.mergeOptions({boxZoom:!0});var Lv=en.extend({initialize:function(l){this._map=l,this._container=l._container,this._pane=l._panes.overlayPane,this._resetStateTimeout=0,l.on("unload",this._destroy,this)},addHooks:function(){Le(this._container,"mousedown",this._onMouseDown,this)},removeHooks:function(){et(this._container,"mousedown",this._onMouseDown,this)},moved:function(){return this._moved},_destroy:function(){lt(this._pane),delete this._pane},_resetState:function(){this._resetStateTimeout=0,this._moved=!1},_clearDeferredResetState:function(){this._resetStateTimeout!==0&&(clearTimeout(this._resetStateTimeout),this._resetStateTimeout=0)},_onMouseDown:function(l){if(!l.shiftKey||l.which!==1&&l.button!==1)return!1;this._clearDeferredResetState(),this._resetState(),Eo(),Kd(),this._startPoint=this._map.mouseEventToContainerPoint(l),Le(document,{contextmenu:pi,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseMove:function(l){this._moved||(this._moved=!0,this._box=Ve("div","leaflet-zoom-box",this._container),Oe(this._container,"leaflet-crosshair"),this._map.fire("boxzoomstart")),this._point=this._map.mouseEventToContainerPoint(l);var f=new J(this._point,this._startPoint),v=f.getSize();wt(this._box,f.min),this._box.style.width=v.x+"px",this._box.style.height=v.y+"px"},_finish:function(){this._moved&&(lt(this._box),mt(this._container,"leaflet-crosshair")),Ao(),Qd(),et(document,{contextmenu:pi,mousemove:this._onMouseMove,mouseup:this._onMouseUp,keydown:this._onKeyDown},this)},_onMouseUp:function(l){if(!(l.which!==1&&l.button!==1)&&(this._finish(),!!this._moved)){this._clearDeferredResetState(),this._resetStateTimeout=setTimeout(o(this._resetState,this),0);var f=new oe(this._map.containerPointToLatLng(this._startPoint),this._map.containerPointToLatLng(this._point));this._map.fitBounds(f).fire("boxzoomend",{boxZoomBounds:f})}},_onKeyDown:function(l){l.keyCode===27&&(this._finish(),this._clearDeferredResetState(),this._resetState())}});je.addInitHook("addHandler","boxZoom",Lv),je.mergeOptions({doubleClickZoom:!0});var Ov=en.extend({addHooks:function(){this._map.on("dblclick",this._onDoubleClick,this)},removeHooks:function(){this._map.off("dblclick",this._onDoubleClick,this)},_onDoubleClick:function(l){var f=this._map,v=f.getZoom(),x=f.options.zoomDelta,A=l.originalEvent.shiftKey?v-x:v+x;f.options.doubleClickZoom==="center"?f.setZoom(A):f.setZoomAround(l.containerPoint,A)}});je.addInitHook("addHandler","doubleClickZoom",Ov),je.mergeOptions({dragging:!0,inertia:!0,inertiaDeceleration:3400,inertiaMaxSpeed:1/0,easeLinearity:.2,worldCopyJump:!1,maxBoundsViscosity:0});var Iv=en.extend({addHooks:function(){if(!this._draggable){var l=this._map;this._draggable=new $n(l._mapPane,l._container),this._draggable.on({dragstart:this._onDragStart,drag:this._onDrag,dragend:this._onDragEnd},this),this._draggable.on("predrag",this._onPreDragLimit,this),l.options.worldCopyJump&&(this._draggable.on("predrag",this._onPreDragWrap,this),l.on("zoomend",this._onZoomEnd,this),l.whenReady(this._onZoomEnd,this))}Oe(this._map._container,"leaflet-grab leaflet-touch-drag"),this._draggable.enable(),this._positions=[],this._times=[]},removeHooks:function(){mt(this._map._container,"leaflet-grab"),mt(this._map._container,"leaflet-touch-drag"),this._draggable.disable()},moved:function(){return this._draggable&&this._draggable._moved},moving:function(){return this._draggable&&this._draggable._moving},_onDragStart:function(){var l=this._map;if(l._stop(),this._map.options.maxBounds&&this._map.options.maxBoundsViscosity){var f=ae(this._map.options.maxBounds);this._offsetLimit=ne(this._map.latLngToContainerPoint(f.getNorthWest()).multiplyBy(-1),this._map.latLngToContainerPoint(f.getSouthEast()).multiplyBy(-1).add(this._map.getSize())),this._viscosity=Math.min(1,Math.max(0,this._map.options.maxBoundsViscosity))}else this._offsetLimit=null;l.fire("movestart").fire("dragstart"),l.options.inertia&&(this._positions=[],this._times=[])},_onDrag:function(l){if(this._map.options.inertia){var f=this._lastTime=+new Date,v=this._lastPos=this._draggable._absPos||this._draggable._newPos;this._positions.push(v),this._times.push(f),this._prunePositions(f)}this._map.fire("move",l).fire("drag",l)},_prunePositions:function(l){for(;this._positions.length>1&&l-this._times[0]>50;)this._positions.shift(),this._times.shift()},_onZoomEnd:function(){var l=this._map.getSize().divideBy(2),f=this._map.latLngToLayerPoint([0,0]);this._initialWorldOffset=f.subtract(l).x,this._worldWidth=this._map.getPixelWorldBounds().getSize().x},_viscousLimit:function(l,f){return l-(l-f)*this._viscosity},_onPreDragLimit:function(){if(!(!this._viscosity||!this._offsetLimit)){var l=this._draggable._newPos.subtract(this._draggable._startPos),f=this._offsetLimit;l.x<f.min.x&&(l.x=this._viscousLimit(l.x,f.min.x)),l.y<f.min.y&&(l.y=this._viscousLimit(l.y,f.min.y)),l.x>f.max.x&&(l.x=this._viscousLimit(l.x,f.max.x)),l.y>f.max.y&&(l.y=this._viscousLimit(l.y,f.max.y)),this._draggable._newPos=this._draggable._startPos.add(l)}},_onPreDragWrap:function(){var l=this._worldWidth,f=Math.round(l/2),v=this._initialWorldOffset,x=this._draggable._newPos.x,A=(x-f+v)%l+f-v,F=(x+f+v)%l-f-v,K=Math.abs(A+v)<Math.abs(F+v)?A:F;this._draggable._absPos=this._draggable._newPos.clone(),this._draggable._newPos.x=K},_onDragEnd:function(l){var f=this._map,v=f.options,x=!v.inertia||l.noInertia||this._times.length<2;if(f.fire("dragend",l),x)f.fire("moveend");else{this._prunePositions(+new Date);var A=this._lastPos.subtract(this._positions[0]),F=(this._lastTime-this._times[0])/1e3,K=v.easeLinearity,te=A.multiplyBy(K/F),re=te.distanceTo([0,0]),ce=Math.min(v.inertiaMaxSpeed,re),ye=te.multiplyBy(ce/re),Se=ce/(v.inertiaDeceleration*K),Ie=ye.multiplyBy(-Se/2).round();!Ie.x&&!Ie.y?f.fire("moveend"):(Ie=f._limitOffset(Ie,f.options.maxBounds),G(function(){f.panBy(Ie,{duration:Se,easeLinearity:K,noMoveStart:!0,animate:!0})}))}}});je.addInitHook("addHandler","dragging",Iv),je.mergeOptions({keyboard:!0,keyboardPanDelta:80});var Fv=en.extend({keyCodes:{left:[37],right:[39],down:[40],up:[38],zoomIn:[187,107,61,171],zoomOut:[189,109,54,173]},initialize:function(l){this._map=l,this._setPanDelta(l.options.keyboardPanDelta),this._setZoomDelta(l.options.zoomDelta)},addHooks:function(){var l=this._map._container;l.tabIndex<=0&&(l.tabIndex="0"),Le(l,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.on({focus:this._addHooks,blur:this._removeHooks},this)},removeHooks:function(){this._removeHooks(),et(this._map._container,{focus:this._onFocus,blur:this._onBlur,mousedown:this._onMouseDown},this),this._map.off({focus:this._addHooks,blur:this._removeHooks},this)},_onMouseDown:function(){if(!this._focused){var l=document.body,f=document.documentElement,v=l.scrollTop||f.scrollTop,x=l.scrollLeft||f.scrollLeft;this._map._container.focus(),window.scrollTo(x,v)}},_onFocus:function(){this._focused=!0,this._map.fire("focus")},_onBlur:function(){this._focused=!1,this._map.fire("blur")},_setPanDelta:function(l){var f=this._panKeys={},v=this.keyCodes,x,A;for(x=0,A=v.left.length;x<A;x++)f[v.left[x]]=[-1*l,0];for(x=0,A=v.right.length;x<A;x++)f[v.right[x]]=[l,0];for(x=0,A=v.down.length;x<A;x++)f[v.down[x]]=[0,l];for(x=0,A=v.up.length;x<A;x++)f[v.up[x]]=[0,-1*l]},_setZoomDelta:function(l){var f=this._zoomKeys={},v=this.keyCodes,x,A;for(x=0,A=v.zoomIn.length;x<A;x++)f[v.zoomIn[x]]=l;for(x=0,A=v.zoomOut.length;x<A;x++)f[v.zoomOut[x]]=-l},_addHooks:function(){Le(document,"keydown",this._onKeyDown,this)},_removeHooks:function(){et(document,"keydown",this._onKeyDown,this)},_onKeyDown:function(l){if(!(l.altKey||l.ctrlKey||l.metaKey)){var f=l.keyCode,v=this._map,x;if(f in this._panKeys){if(!v._panAnim||!v._panAnim._inProgress)if(x=this._panKeys[f],l.shiftKey&&(x=Z(x).multiplyBy(3)),v.options.maxBounds&&(x=v._limitOffset(Z(x),v.options.maxBounds)),v.options.worldCopyJump){var A=v.wrapLatLng(v.unproject(v.project(v.getCenter()).add(x)));v.panTo(A)}else v.panBy(x)}else if(f in this._zoomKeys)v.setZoom(v.getZoom()+(l.shiftKey?3:1)*this._zoomKeys[f]);else if(f===27&&v._popup&&v._popup.options.closeOnEscapeKey)v.closePopup();else return;pi(l)}}});je.addInitHook("addHandler","keyboard",Fv),je.mergeOptions({scrollWheelZoom:!0,wheelDebounceTime:40,wheelPxPerZoomLevel:60});var $v=en.extend({addHooks:function(){Le(this._map._container,"wheel",this._onWheelScroll,this),this._delta=0},removeHooks:function(){et(this._map._container,"wheel",this._onWheelScroll,this)},_onWheelScroll:function(l){var f=lv(l),v=this._map.options.wheelDebounceTime;this._delta+=f,this._lastMousePos=this._map.mouseEventToContainerPoint(l),this._startTime||(this._startTime=+new Date);var x=Math.max(v-(+new Date-this._startTime),0);clearTimeout(this._timer),this._timer=setTimeout(o(this._performZoom,this),x),pi(l)},_performZoom:function(){var l=this._map,f=l.getZoom(),v=this._map.options.zoomSnap||0;l._stop();var x=this._delta/(this._map.options.wheelPxPerZoomLevel*4),A=4*Math.log(2/(1+Math.exp(-Math.abs(x))))/Math.LN2,F=v?Math.ceil(A/v)*v:A,K=l._limitZoom(f+(this._delta>0?F:-F))-f;this._delta=0,this._startTime=null,K&&(l.options.scrollWheelZoom==="center"?l.setZoom(f+K):l.setZoomAround(this._lastMousePos,f+K))}});je.addInitHook("addHandler","scrollWheelZoom",$v);var o4=600;je.mergeOptions({tapHold:xe.touchNative&&xe.safari&&xe.mobile,tapTolerance:15});var Bv=en.extend({addHooks:function(){Le(this._map._container,"touchstart",this._onDown,this)},removeHooks:function(){et(this._map._container,"touchstart",this._onDown,this)},_onDown:function(l){if(clearTimeout(this._holdTimeout),l.touches.length===1){var f=l.touches[0];this._startPos=this._newPos=new q(f.clientX,f.clientY),this._holdTimeout=setTimeout(o(function(){this._cancel(),this._isTapValid()&&(Le(document,"touchend",$t),Le(document,"touchend touchcancel",this._cancelClickPrevent),this._simulateEvent("contextmenu",f))},this),o4),Le(document,"touchend touchcancel contextmenu",this._cancel,this),Le(document,"touchmove",this._onMove,this)}},_cancelClickPrevent:function l(){et(document,"touchend",$t),et(document,"touchend touchcancel",l)},_cancel:function(){clearTimeout(this._holdTimeout),et(document,"touchend touchcancel contextmenu",this._cancel,this),et(document,"touchmove",this._onMove,this)},_onMove:function(l){var f=l.touches[0];this._newPos=new q(f.clientX,f.clientY)},_isTapValid:function(){return this._newPos.distanceTo(this._startPos)<=this._map.options.tapTolerance},_simulateEvent:function(l,f){var v=new MouseEvent(l,{bubbles:!0,cancelable:!0,view:window,screenX:f.screenX,screenY:f.screenY,clientX:f.clientX,clientY:f.clientY});v._simulated=!0,f.target.dispatchEvent(v)}});je.addInitHook("addHandler","tapHold",Bv),je.mergeOptions({touchZoom:xe.touch,bounceAtZoomLimits:!0});var zv=en.extend({addHooks:function(){Oe(this._map._container,"leaflet-touch-zoom"),Le(this._map._container,"touchstart",this._onTouchStart,this)},removeHooks:function(){mt(this._map._container,"leaflet-touch-zoom"),et(this._map._container,"touchstart",this._onTouchStart,this)},_onTouchStart:function(l){var f=this._map;if(!(!l.touches||l.touches.length!==2||f._animatingZoom||this._zooming)){var v=f.mouseEventToContainerPoint(l.touches[0]),x=f.mouseEventToContainerPoint(l.touches[1]);this._centerPoint=f.getSize()._divideBy(2),this._startLatLng=f.containerPointToLatLng(this._centerPoint),f.options.touchZoom!=="center"&&(this._pinchStartLatLng=f.containerPointToLatLng(v.add(x)._divideBy(2))),this._startDist=v.distanceTo(x),this._startZoom=f.getZoom(),this._moved=!1,this._zooming=!0,f._stop(),Le(document,"touchmove",this._onTouchMove,this),Le(document,"touchend touchcancel",this._onTouchEnd,this),$t(l)}},_onTouchMove:function(l){if(!(!l.touches||l.touches.length!==2||!this._zooming)){var f=this._map,v=f.mouseEventToContainerPoint(l.touches[0]),x=f.mouseEventToContainerPoint(l.touches[1]),A=v.distanceTo(x)/this._startDist;if(this._zoom=f.getScaleZoom(A,this._startZoom),!f.options.bounceAtZoomLimits&&(this._zoom<f.getMinZoom()&&A<1||this._zoom>f.getMaxZoom()&&A>1)&&(this._zoom=f._limitZoom(this._zoom)),f.options.touchZoom==="center"){if(this._center=this._startLatLng,A===1)return}else{var F=v._add(x)._divideBy(2)._subtract(this._centerPoint);if(A===1&&F.x===0&&F.y===0)return;this._center=f.unproject(f.project(this._pinchStartLatLng,this._zoom).subtract(F),this._zoom)}this._moved||(f._moveStart(!0,!1),this._moved=!0),Y(this._animRequest);var K=o(f._move,f,this._center,this._zoom,{pinch:!0,round:!1},void 0);this._animRequest=G(K,this,!0),$t(l)}},_onTouchEnd:function(){if(!this._moved||!this._zooming){this._zooming=!1;return}this._zooming=!1,Y(this._animRequest),et(document,"touchmove",this._onTouchMove,this),et(document,"touchend touchcancel",this._onTouchEnd,this),this._map.options.zoomAnimation?this._map._animateZoom(this._center,this._map._limitZoom(this._zoom),!0,this._map.options.zoomSnap):this._map._resetView(this._center,this._map._limitZoom(this._zoom))}});je.addInitHook("addHandler","touchZoom",zv),je.BoxZoom=Lv,je.DoubleClickZoom=Ov,je.Drag=Iv,je.Keyboard=Fv,je.ScrollWheelZoom=$v,je.TapHold=Bv,je.TouchZoom=zv,r.Bounds=J,r.Browser=xe,r.CRS=me,r.Canvas=Rv,r.Circle=fh,r.CircleMarker=Il,r.Class=X,r.Control=zr,r.DivIcon=Pv,r.DivOverlay=tn,r.DomEvent=TE,r.DomUtil=CE,r.Draggable=$n,r.Evented=W,r.FeatureGroup=Tn,r.GeoJSON=Mn,r.GridLayer=Oo,r.Handler=en,r.Icon=ra,r.ImageOverlay=Hl,r.LatLng=se,r.LatLngBounds=oe,r.Layer=Hr,r.LayerGroup=ta,r.LineUtil=FE,r.Map=je,r.Marker=Ol,r.Mixin=DE,r.Path=Bn,r.Point=q,r.PolyUtil=NE,r.Polygon=na,r.Polyline=Sn,r.Popup=Wl,r.PosAnimation=uv,r.Projection=$E,r.Rectangle=kv,r.Renderer=Pn,r.SVG=Fo,r.SVGOverlay=Mv,r.TileLayer=aa,r.Tooltip=jl,r.Transformation=we,r.Util=B,r.VideoOverlay=Sv,r.bind=o,r.bounds=ne,r.canvas=Dv,r.circle=GE,r.circleMarker=UE,r.control=No,r.divIcon=t4,r.extend=i,r.featureGroup=WE,r.geoJSON=Tv,r.geoJson=XE,r.gridLayer=r4,r.icon=jE,r.imageOverlay=ZE,r.latLng=ue,r.latLngBounds=ae,r.layerGroup=HE,r.map=SE,r.marker=VE,r.point=Z,r.polygon=YE,r.polyline=qE,r.popup=JE,r.rectangle=a4,r.setOptions=b,r.stamp=u,r.svg=Nv,r.svgOverlay=QE,r.tileLayer=Ev,r.tooltip=e4,r.transformation=le,r.version=n,r.videoOverlay=KE;var s4=window.L;r.noConflict=function(){return window.L=s4,this},window.L=r})})(qf,qf.exports);var CC=qf.exports;const Rn=O.getDefaultExportFromCjs(CC);var xC={exports:{}};function xN(e){e("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),e("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),e("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),e.WGS84=e["EPSG:4326"],e["EPSG:3785"]=e["EPSG:3857"],e.GOOGLE=e["EPSG:3857"],e["EPSG:900913"]=e["EPSG:3857"],e["EPSG:102113"]=e["EPSG:3857"]}var Ri=1,Di=2,Ia=3,TN=4,Yf=5,O1=6378137,SN=6356752314e-3,I1=.0066943799901413165,us=484813681109536e-20,fe=Math.PI/2,MN=.16666666666666666,PN=.04722222222222222,EN=.022156084656084655,ge=1e-10,Ht=.017453292519943295,ln=57.29577951308232,Xe=Math.PI/4,As=Math.PI*2,vt=3.14159265359,vr={};vr.greenwich=0;vr.lisbon=-9.131906111111;vr.paris=2.337229166667;vr.bogota=-74.080916666667;vr.madrid=-3.687938888889;vr.rome=12.452333333333;vr.bern=7.439583333333;vr.jakarta=106.807719444444;vr.ferro=-17.666666666667;vr.brussels=4.367975;vr.stockholm=18.058277777778;vr.athens=23.7163375;vr.oslo=10.722916666667;const AN={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}};var F1=/[\s_\-\/\(\)]/g;function ni(e,t){if(e[t])return e[t];for(var r=Object.keys(e),n=t.toLowerCase().replace(F1,""),i=-1,a,o;++i<r.length;)if(a=r[i],o=a.toLowerCase().replace(F1,""),o===n)return e[a]}function Xf(e){var t={},r=e.split("+").map(function(s){return s.trim()}).filter(function(s){return s}).reduce(function(s,u){var c=u.split("=");return c.push(!0),s[c[0].toLowerCase()]=c[1],s},{}),n,i,a,o={proj:"projName",datum:"datumCode",rf:function(s){t.rf=parseFloat(s)},lat_0:function(s){t.lat0=s*Ht},lat_1:function(s){t.lat1=s*Ht},lat_2:function(s){t.lat2=s*Ht},lat_ts:function(s){t.lat_ts=s*Ht},lon_0:function(s){t.long0=s*Ht},lon_1:function(s){t.long1=s*Ht},lon_2:function(s){t.long2=s*Ht},alpha:function(s){t.alpha=parseFloat(s)*Ht},gamma:function(s){t.rectified_grid_angle=parseFloat(s)},lonc:function(s){t.longc=s*Ht},x_0:function(s){t.x0=parseFloat(s)},y_0:function(s){t.y0=parseFloat(s)},k_0:function(s){t.k0=parseFloat(s)},k:function(s){t.k0=parseFloat(s)},a:function(s){t.a=parseFloat(s)},b:function(s){t.b=parseFloat(s)},r:function(s){t.a=t.b=parseFloat(s)},r_a:function(){t.R_A=!0},zone:function(s){t.zone=parseInt(s,10)},south:function(){t.utmSouth=!0},towgs84:function(s){t.datum_params=s.split(",").map(function(u){return parseFloat(u)})},to_meter:function(s){t.to_meter=parseFloat(s)},units:function(s){t.units=s;var u=ni(AN,s);u&&(t.to_meter=u.to_meter)},from_greenwich:function(s){t.from_greenwich=s*Ht},pm:function(s){var u=ni(vr,s);t.from_greenwich=(u||parseFloat(s))*Ht},nadgrids:function(s){s==="@null"?t.datumCode="none":t.nadgrids=s},axis:function(s){var u="ewnsud";s.length===3&&u.indexOf(s.substr(0,1))!==-1&&u.indexOf(s.substr(1,1))!==-1&&u.indexOf(s.substr(2,1))!==-1&&(t.axis=s)},approx:function(){t.approx=!0}};for(n in r)i=r[n],n in o?(a=o[n],typeof a=="function"?a(i):t[a]=i):t[n]=i;return typeof t.datumCode=="string"&&t.datumCode!=="WGS84"&&(t.datumCode=t.datumCode.toLowerCase()),t}var Rs=1,TC=2,SC=3,tc=4,MC=5,b0=-1,RN=/\s/,DN=/[A-Za-z]/,NN=/[A-Za-z84_]/,Yc=/[,\]]/,PC=/[\d\.E\-\+]/;function In(e){if(typeof e!="string")throw new Error("not a string");this.text=e.trim(),this.level=0,this.place=0,this.root=null,this.stack=[],this.currentObject=null,this.state=Rs}In.prototype.readCharicter=function(){var e=this.text[this.place++];if(this.state!==tc)for(;RN.test(e);){if(this.place>=this.text.length)return;e=this.text[this.place++]}switch(this.state){case Rs:return this.neutral(e);case TC:return this.keyword(e);case tc:return this.quoted(e);case MC:return this.afterquote(e);case SC:return this.number(e);case b0:return}};In.prototype.afterquote=function(e){if(e==='"'){this.word+='"',this.state=tc;return}if(Yc.test(e)){this.word=this.word.trim(),this.afterItem(e);return}throw new Error(`havn't handled "`+e+'" in afterquote yet, index '+this.place)};In.prototype.afterItem=function(e){if(e===","){this.word!==null&&this.currentObject.push(this.word),this.word=null,this.state=Rs;return}if(e==="]"){this.level--,this.word!==null&&(this.currentObject.push(this.word),this.word=null),this.state=Rs,this.currentObject=this.stack.pop(),this.currentObject||(this.state=b0);return}};In.prototype.number=function(e){if(PC.test(e)){this.word+=e;return}if(Yc.test(e)){this.word=parseFloat(this.word),this.afterItem(e);return}throw new Error(`havn't handled "`+e+'" in number yet, index '+this.place)};In.prototype.quoted=function(e){if(e==='"'){this.state=MC;return}this.word+=e};In.prototype.keyword=function(e){if(NN.test(e)){this.word+=e;return}if(e==="["){var t=[];t.push(this.word),this.level++,this.root===null?this.root=t:this.currentObject.push(t),this.stack.push(this.currentObject),this.currentObject=t,this.state=Rs;return}if(Yc.test(e)){this.afterItem(e);return}throw new Error(`havn't handled "`+e+'" in keyword yet, index '+this.place)};In.prototype.neutral=function(e){if(DN.test(e)){this.word=e,this.state=TC;return}if(e==='"'){this.word="",this.state=tc;return}if(PC.test(e)){this.word=e,this.state=SC;return}if(Yc.test(e)){this.afterItem(e);return}throw new Error(`havn't handled "`+e+'" in neutral yet, index '+this.place)};In.prototype.output=function(){for(;this.place<this.text.length;)this.readCharicter();if(this.state===b0)return this.root;throw new Error('unable to parse string "'+this.text+'". State is '+this.state)};function kN(e){var t=new In(e);return t.output()}function $1(e,t,r){Array.isArray(t)&&(r.unshift(t),t=null);var n=t?{}:e,i=r.reduce(function(a,o){return Ma(o,a),a},n);t&&(e[t]=i)}function Ma(e,t){if(!Array.isArray(e)){t[e]=!0;return}var r=e.shift();if(r==="PARAMETER"&&(r=e.shift()),e.length===1){if(Array.isArray(e[0])){t[r]={},Ma(e[0],t[r]);return}t[r]=e[0];return}if(!e.length){t[r]=!0;return}if(r==="TOWGS84"){t[r]=e;return}if(r==="AXIS"){r in t||(t[r]=[]),t[r].push(e);return}Array.isArray(r)||(t[r]={});var n;switch(r){case"UNIT":case"PRIMEM":case"VERT_DATUM":t[r]={name:e[0].toLowerCase(),convert:e[1]},e.length===3&&Ma(e[2],t[r]);return;case"SPHEROID":case"ELLIPSOID":t[r]={name:e[0],a:e[1],rf:e[2]},e.length===4&&Ma(e[3],t[r]);return;case"PROJECTEDCRS":case"PROJCRS":case"GEOGCS":case"GEOCCS":case"PROJCS":case"LOCAL_CS":case"GEODCRS":case"GEODETICCRS":case"GEODETICDATUM":case"EDATUM":case"ENGINEERINGDATUM":case"VERT_CS":case"VERTCRS":case"VERTICALCRS":case"COMPD_CS":case"COMPOUNDCRS":case"ENGINEERINGCRS":case"ENGCRS":case"FITTED_CS":case"LOCAL_DATUM":case"DATUM":e[0]=["name",e[0]],$1(t,r,e);return;default:for(n=-1;++n<e.length;)if(!Array.isArray(e[n]))return Ma(e,t[r]);return $1(t,r,e)}}var LN=.017453292519943295;function ON(e,t){var r=t[0],n=t[1];!(r in e)&&n in e&&(e[r]=e[n],t.length===3&&(e[r]=t[2](e[r])))}function nn(e){return e*LN}function IN(e){if(e.type==="GEOGCS"?e.projName="longlat":e.type==="LOCAL_CS"?(e.projName="identity",e.local=!0):typeof e.PROJECTION=="object"?e.projName=Object.keys(e.PROJECTION)[0]:e.projName=e.PROJECTION,e.AXIS){for(var t="",r=0,n=e.AXIS.length;r<n;++r){var i=[e.AXIS[r][0].toLowerCase(),e.AXIS[r][1].toLowerCase()];i[0].indexOf("north")!==-1||(i[0]==="y"||i[0]==="lat")&&i[1]==="north"?t+="n":i[0].indexOf("south")!==-1||(i[0]==="y"||i[0]==="lat")&&i[1]==="south"?t+="s":i[0].indexOf("east")!==-1||(i[0]==="x"||i[0]==="lon")&&i[1]==="east"?t+="e":(i[0].indexOf("west")!==-1||(i[0]==="x"||i[0]==="lon")&&i[1]==="west")&&(t+="w")}t.length===2&&(t+="u"),t.length===3&&(e.axis=t)}e.UNIT&&(e.units=e.UNIT.name.toLowerCase(),e.units==="metre"&&(e.units="meter"),e.UNIT.convert&&(e.type==="GEOGCS"?e.DATUM&&e.DATUM.SPHEROID&&(e.to_meter=e.UNIT.convert*e.DATUM.SPHEROID.a):e.to_meter=e.UNIT.convert));var a=e.GEOGCS;e.type==="GEOGCS"&&(a=e),a&&(a.DATUM?e.datumCode=a.DATUM.name.toLowerCase():e.datumCode=a.name.toLowerCase(),e.datumCode.slice(0,2)==="d_"&&(e.datumCode=e.datumCode.slice(2)),(e.datumCode==="new_zealand_geodetic_datum_1949"||e.datumCode==="new_zealand_1949")&&(e.datumCode="nzgd49"),(e.datumCode==="wgs_1984"||e.datumCode==="world_geodetic_system_1984")&&(e.PROJECTION==="Mercator_Auxiliary_Sphere"&&(e.sphere=!0),e.datumCode="wgs84"),e.datumCode.slice(-6)==="_ferro"&&(e.datumCode=e.datumCode.slice(0,-6)),e.datumCode.slice(-8)==="_jakarta"&&(e.datumCode=e.datumCode.slice(0,-8)),~e.datumCode.indexOf("belge")&&(e.datumCode="rnb72"),a.DATUM&&a.DATUM.SPHEROID&&(e.ellps=a.DATUM.SPHEROID.name.replace("_19","").replace(/[Cc]larke\_18/,"clrk"),e.ellps.toLowerCase().slice(0,13)==="international"&&(e.ellps="intl"),e.a=a.DATUM.SPHEROID.a,e.rf=parseFloat(a.DATUM.SPHEROID.rf,10)),a.DATUM&&a.DATUM.TOWGS84&&(e.datum_params=a.DATUM.TOWGS84),~e.datumCode.indexOf("osgb_1936")&&(e.datumCode="osgb36"),~e.datumCode.indexOf("osni_1952")&&(e.datumCode="osni52"),(~e.datumCode.indexOf("tm65")||~e.datumCode.indexOf("geodetic_datum_of_1965"))&&(e.datumCode="ire65"),e.datumCode==="ch1903+"&&(e.datumCode="ch1903"),~e.datumCode.indexOf("israel")&&(e.datumCode="isr93")),e.b&&!isFinite(e.b)&&(e.b=e.a);function o(c){var d=e.to_meter||1;return c*d}var s=function(c){return ON(e,c)},u=[["standard_parallel_1","Standard_Parallel_1"],["standard_parallel_1","Latitude of 1st standard parallel"],["standard_parallel_2","Standard_Parallel_2"],["standard_parallel_2","Latitude of 2nd standard parallel"],["false_easting","False_Easting"],["false_easting","False easting"],["false-easting","Easting at false origin"],["false_northing","False_Northing"],["false_northing","False northing"],["false_northing","Northing at false origin"],["central_meridian","Central_Meridian"],["central_meridian","Longitude of natural origin"],["central_meridian","Longitude of false origin"],["latitude_of_origin","Latitude_Of_Origin"],["latitude_of_origin","Central_Parallel"],["latitude_of_origin","Latitude of natural origin"],["latitude_of_origin","Latitude of false origin"],["scale_factor","Scale_Factor"],["k0","scale_factor"],["latitude_of_center","Latitude_Of_Center"],["latitude_of_center","Latitude_of_center"],["lat0","latitude_of_center",nn],["longitude_of_center","Longitude_Of_Center"],["longitude_of_center","Longitude_of_center"],["longc","longitude_of_center",nn],["x0","false_easting",o],["y0","false_northing",o],["long0","central_meridian",nn],["lat0","latitude_of_origin",nn],["lat0","standard_parallel_1",nn],["lat1","standard_parallel_1",nn],["lat2","standard_parallel_2",nn],["azimuth","Azimuth"],["alpha","azimuth",nn],["srsCode","name"]];u.forEach(s),!e.long0&&e.longc&&(e.projName==="Albers_Conic_Equal_Area"||e.projName==="Lambert_Azimuthal_Equal_Area")&&(e.long0=e.longc),!e.lat_ts&&e.lat1&&(e.projName==="Stereographic_South_Pole"||e.projName==="Polar Stereographic (variant B)")?(e.lat0=nn(e.lat1>0?90:-90),e.lat_ts=e.lat1):!e.lat_ts&&e.lat0&&e.projName==="Polar_Stereographic"&&(e.lat_ts=e.lat0,e.lat0=nn(e.lat0>0?90:-90))}function EC(e){var t=kN(e),r=t.shift(),n=t.shift();t.unshift(["name",n]),t.unshift(["type",r]);var i={};return Ma(t,i),IN(i),i}function ir(e){var t=this;if(arguments.length===2){var r=arguments[1];typeof r=="string"?r.charAt(0)==="+"?ir[e]=Xf(arguments[1]):ir[e]=EC(arguments[1]):ir[e]=r}else if(arguments.length===1){if(Array.isArray(e))return e.map(function(n){Array.isArray(n)?ir.apply(t,n):ir(n)});if(typeof e=="string"){if(e in ir)return ir[e]}else"EPSG"in e?ir["EPSG:"+e.EPSG]=e:"ESRI"in e?ir["ESRI:"+e.ESRI]=e:"IAU2000"in e?ir["IAU2000:"+e.IAU2000]=e:console.log(e);return}}xN(ir);function FN(e){return typeof e=="string"}function $N(e){return e in ir}var BN=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];function zN(e){return BN.some(function(t){return e.indexOf(t)>-1})}var HN=["3857","900913","3785","102113"];function WN(e){var t=ni(e,"authority");if(t){var r=ni(t,"epsg");return r&&HN.indexOf(r)>-1}}function jN(e){var t=ni(e,"extension");if(t)return ni(t,"proj4")}function VN(e){return e[0]==="+"}function UN(e){if(FN(e)){if($N(e))return ir[e];if(zN(e)){var t=EC(e);if(WN(t))return ir["EPSG:3857"];var r=jN(t);return r?Xf(r):t}if(VN(e))return Xf(e)}else return e}function B1(e,t){e=e||{};var r,n;if(!t)return e;for(n in t)r=t[n],r!==void 0&&(e[n]=r);return e}function pn(e,t,r){var n=e*t;return r/Math.sqrt(1-n*n)}function Qs(e){return e<0?-1:1}function be(e){return Math.abs(e)<=vt?e:e-Qs(e)*As}function Vr(e,t,r){var n=e*r,i=.5*e;return n=Math.pow((1-n)/(1+n),i),Math.tan(.5*(fe-t))/n}function Ds(e,t){for(var r=.5*e,n,i,a=fe-2*Math.atan(t),o=0;o<=15;o++)if(n=e*Math.sin(a),i=fe-2*Math.atan(t*Math.pow((1-n)/(1+n),r))-a,a+=i,Math.abs(i)<=1e-10)return a;return-9999}function GN(){var e=this.b/this.a;this.es=1-e*e,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=pn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function qN(e){var t=e.x,r=e.y;if(r*ln>90&&r*ln<-90&&t*ln>180&&t*ln<-180)return null;var n,i;if(Math.abs(Math.abs(r)-fe)<=ge)return null;if(this.sphere)n=this.x0+this.a*this.k0*be(t-this.long0),i=this.y0+this.a*this.k0*Math.log(Math.tan(Xe+.5*r));else{var a=Math.sin(r),o=Vr(this.e,r,a);n=this.x0+this.a*this.k0*be(t-this.long0),i=this.y0-this.a*this.k0*Math.log(o)}return e.x=n,e.y=i,e}function YN(e){var t=e.x-this.x0,r=e.y-this.y0,n,i;if(this.sphere)i=fe-2*Math.atan(Math.exp(-r/(this.a*this.k0)));else{var a=Math.exp(-r/(this.a*this.k0));if(i=Ds(this.e,a),i===-9999)return null}return n=be(this.long0+t/(this.a*this.k0)),e.x=n,e.y=i,e}var XN=["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"];const ZN={init:GN,forward:qN,inverse:YN,names:XN};function KN(){}function z1(e){return e}var QN=["longlat","identity"];const JN={init:KN,forward:z1,inverse:z1,names:QN};var e8=[ZN,JN],Du={},rc=[];function AC(e,t){var r=rc.length;return e.names?(rc[r]=e,e.names.forEach(function(n){Du[n.toLowerCase()]=r}),this):(console.log(t),!0)}function t8(e){if(!e)return!1;var t=e.toLowerCase();if(typeof Du[t]!="undefined"&&rc[Du[t]])return rc[Du[t]]}function r8(){e8.forEach(AC)}const n8={start:r8,add:AC,get:t8};var Ee={};Ee.MERIT={a:6378137,rf:298.257,ellipseName:"MERIT 1983"};Ee.SGS85={a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"};Ee.GRS80={a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"};Ee.IAU76={a:6378140,rf:298.257,ellipseName:"IAU 1976"};Ee.airy={a:6377563396e-3,b:635625691e-2,ellipseName:"Airy 1830"};Ee.APL4={a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"};Ee.NWL9D={a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"};Ee.mod_airy={a:6377340189e-3,b:6356034446e-3,ellipseName:"Modified Airy"};Ee.andrae={a:637710443e-2,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"};Ee.aust_SA={a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"};Ee.GRS67={a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"};Ee.bessel={a:6377397155e-3,rf:299.1528128,ellipseName:"Bessel 1841"};Ee.bess_nam={a:6377483865e-3,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"};Ee.clrk66={a:63782064e-1,b:63565838e-1,ellipseName:"Clarke 1866"};Ee.clrk80={a:6378249145e-3,rf:293.4663,ellipseName:"Clarke 1880 mod."};Ee.clrk80ign={a:63782492e-1,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"};Ee.clrk58={a:6378293645208759e-9,rf:294.2606763692654,ellipseName:"Clarke 1858"};Ee.CPM={a:63757387e-1,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"};Ee.delmbr={a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"};Ee.engelis={a:637813605e-2,rf:298.2566,ellipseName:"Engelis 1985"};Ee.evrst30={a:6377276345e-3,rf:300.8017,ellipseName:"Everest 1830"};Ee.evrst48={a:6377304063e-3,rf:300.8017,ellipseName:"Everest 1948"};Ee.evrst56={a:6377301243e-3,rf:300.8017,ellipseName:"Everest 1956"};Ee.evrst69={a:6377295664e-3,rf:300.8017,ellipseName:"Everest 1969"};Ee.evrstSS={a:6377298556e-3,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"};Ee.fschr60={a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"};Ee.fschr60m={a:6378155,rf:298.3,ellipseName:"Fischer 1960"};Ee.fschr68={a:6378150,rf:298.3,ellipseName:"Fischer 1968"};Ee.helmert={a:6378200,rf:298.3,ellipseName:"Helmert 1906"};Ee.hough={a:6378270,rf:297,ellipseName:"Hough"};Ee.intl={a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"};Ee.kaula={a:6378163,rf:298.24,ellipseName:"Kaula 1961"};Ee.lerch={a:6378139,rf:298.257,ellipseName:"Lerch 1979"};Ee.mprts={a:6397300,rf:191,ellipseName:"Maupertius 1738"};Ee.new_intl={a:63781575e-1,b:63567722e-1,ellipseName:"New International 1967"};Ee.plessis={a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"};Ee.krass={a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"};Ee.SEasia={a:6378155,b:63567733205e-4,ellipseName:"Southeast Asia"};Ee.walbeck={a:6376896,b:63558348467e-4,ellipseName:"Walbeck"};Ee.WGS60={a:6378165,rf:298.3,ellipseName:"WGS 60"};Ee.WGS66={a:6378145,rf:298.25,ellipseName:"WGS 66"};Ee.WGS7={a:6378135,rf:298.26,ellipseName:"WGS 72"};var i8=Ee.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};Ee.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};function a8(e,t,r,n){var i=e*e,a=t*t,o=(i-a)/i,s=0;n?(e*=1-o*(MN+o*(PN+o*EN)),i=e*e,o=0):s=Math.sqrt(o);var u=(i-a)/a;return{es:o,e:s,ep2:u}}function o8(e,t,r,n,i){if(!e){var a=ni(Ee,n);a||(a=i8),e=a.a,t=a.b,r=a.rf}return r&&!t&&(t=(1-1/r)*e),(r===0||Math.abs(e-t)<ge)&&(i=!0,t=e),{a:e,b:t,rf:r,sphere:i}}var Dt={};Dt.wgs84={towgs84:"0,0,0",ellipse:"WGS84",datumName:"WGS84"};Dt.ch1903={towgs84:"674.374,15.056,405.346",ellipse:"bessel",datumName:"swiss"};Dt.ggrs87={towgs84:"-199.87,74.79,246.62",ellipse:"GRS80",datumName:"Greek_Geodetic_Reference_System_1987"};Dt.nad83={towgs84:"0,0,0",ellipse:"GRS80",datumName:"North_American_Datum_1983"};Dt.nad27={nadgrids:"@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",ellipse:"clrk66",datumName:"North_American_Datum_1927"};Dt.potsdam={towgs84:"598.1,73.7,418.2,0.202,0.045,-2.455,6.7",ellipse:"bessel",datumName:"Potsdam Rauenberg 1950 DHDN"};Dt.carthage={towgs84:"-263.0,6.0,431.0",ellipse:"clark80",datumName:"Carthage 1934 Tunisia"};Dt.hermannskogel={towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Hermannskogel"};Dt.militargeographische_institut={towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Militar-Geographische Institut"};Dt.osni52={towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"airy",datumName:"Irish National"};Dt.ire65={towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"mod_airy",datumName:"Ireland 1965"};Dt.rassadiran={towgs84:"-133.63,-157.5,-158.62",ellipse:"intl",datumName:"Rassadiran"};Dt.nzgd49={towgs84:"59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",ellipse:"intl",datumName:"New Zealand Geodetic Datum 1949"};Dt.osgb36={towgs84:"446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",ellipse:"airy",datumName:"Airy 1830"};Dt.s_jtsk={towgs84:"589,76,480",ellipse:"bessel",datumName:"S-JTSK (Ferro)"};Dt.beduaram={towgs84:"-106,-87,188",ellipse:"clrk80",datumName:"Beduaram"};Dt.gunung_segara={towgs84:"-403,684,41",ellipse:"bessel",datumName:"Gunung Segara Jakarta"};Dt.rnb72={towgs84:"106.869,-52.2978,103.724,-0.33657,0.456955,-1.84218,1",ellipse:"intl",datumName:"Reseau National Belge 1972"};function s8(e,t,r,n,i,a,o){var s={};return e===void 0||e==="none"?s.datum_type=Yf:s.datum_type=TN,t&&(s.datum_params=t.map(parseFloat),(s.datum_params[0]!==0||s.datum_params[1]!==0||s.datum_params[2]!==0)&&(s.datum_type=Ri),s.datum_params.length>3&&(s.datum_params[3]!==0||s.datum_params[4]!==0||s.datum_params[5]!==0||s.datum_params[6]!==0)&&(s.datum_type=Di,s.datum_params[3]*=us,s.datum_params[4]*=us,s.datum_params[5]*=us,s.datum_params[6]=s.datum_params[6]/1e6+1)),o&&(s.datum_type=Ia,s.grids=o),s.a=r,s.b=n,s.es=i,s.ep2=a,s}var RC={};function l8(e,t){var r=new DataView(t),n=d8(r),i=h8(r,n),a=f8(r,i,n),o={header:i,subgrids:a};return RC[e]=o,o}function u8(e){if(e===void 0)return null;var t=e.split(",");return t.map(c8)}function c8(e){if(e.length===0)return null;var t=e[0]==="@";return t&&(e=e.slice(1)),e==="null"?{name:"null",mandatory:!t,grid:null,isNull:!0}:{name:e,mandatory:!t,grid:RC[e]||null,isNull:!1}}function Pa(e){return e/3600*Math.PI/180}function d8(e){var t=e.getInt32(8,!1);return t===11?!1:(t=e.getInt32(8,!0),t!==11&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian"),!0)}function h8(e,t){return{nFields:e.getInt32(8,t),nSubgridFields:e.getInt32(24,t),nSubgrids:e.getInt32(40,t),shiftType:Zf(e,56,64).trim(),fromSemiMajorAxis:e.getFloat64(120,t),fromSemiMinorAxis:e.getFloat64(136,t),toSemiMajorAxis:e.getFloat64(152,t),toSemiMinorAxis:e.getFloat64(168,t)}}function Zf(e,t,r){return String.fromCharCode.apply(null,new Uint8Array(e.buffer.slice(t,r)))}function f8(e,t,r){for(var n=176,i=[],a=0;a<t.nSubgrids;a++){var o=m8(e,n,r),s=g8(e,n,o,r),u=Math.round(1+(o.upperLongitude-o.lowerLongitude)/o.longitudeInterval),c=Math.round(1+(o.upperLatitude-o.lowerLatitude)/o.latitudeInterval);i.push({ll:[Pa(o.lowerLongitude),Pa(o.lowerLatitude)],del:[Pa(o.longitudeInterval),Pa(o.latitudeInterval)],lim:[u,c],count:o.gridNodeCount,cvs:p8(s)}),n+=176+o.gridNodeCount*16}return i}function p8(e){return e.map(function(t){return[Pa(t.longitudeShift),Pa(t.latitudeShift)]})}function m8(e,t,r){return{name:Zf(e,t+8,t+16).trim(),parent:Zf(e,t+24,t+24+8).trim(),lowerLatitude:e.getFloat64(t+72,r),upperLatitude:e.getFloat64(t+88,r),lowerLongitude:e.getFloat64(t+104,r),upperLongitude:e.getFloat64(t+120,r),latitudeInterval:e.getFloat64(t+136,r),longitudeInterval:e.getFloat64(t+152,r),gridNodeCount:e.getInt32(t+168,r)}}function g8(e,t,r,n){for(var i=t+176,a=16,o=[],s=0;s<r.gridNodeCount;s++){var u={latitudeShift:e.getFloat32(i+s*a,n),longitudeShift:e.getFloat32(i+s*a+4,n),latitudeAccuracy:e.getFloat32(i+s*a+8,n),longitudeAccuracy:e.getFloat32(i+s*a+12,n)};o.push(u)}return o}function dn(e,t){if(!(this instanceof dn))return new dn(e);t=t||function(c){if(c)throw c};var r=UN(e);if(typeof r!="object"){t(e);return}var n=dn.projections.get(r.projName);if(!n){t(e);return}if(r.datumCode&&r.datumCode!=="none"){var i=ni(Dt,r.datumCode);i&&(r.datum_params=r.datum_params||(i.towgs84?i.towgs84.split(","):null),r.ellps=i.ellipse,r.datumName=i.datumName?i.datumName:r.datumCode)}r.k0=r.k0||1,r.axis=r.axis||"enu",r.ellps=r.ellps||"wgs84",r.lat1=r.lat1||r.lat0;var a=o8(r.a,r.b,r.rf,r.ellps,r.sphere),o=a8(a.a,a.b,a.rf,r.R_A),s=u8(r.nadgrids),u=r.datum||s8(r.datumCode,r.datum_params,a.a,a.b,o.es,o.ep2,s);B1(this,r),B1(this,n),this.a=a.a,this.b=a.b,this.rf=a.rf,this.sphere=a.sphere,this.es=o.es,this.e=o.e,this.ep2=o.ep2,this.datum=u,this.init(),t(null,this)}dn.projections=n8;dn.projections.start();function v8(e,t){return e.datum_type!==t.datum_type||e.a!==t.a||Math.abs(e.es-t.es)>5e-11?!1:e.datum_type===Ri?e.datum_params[0]===t.datum_params[0]&&e.datum_params[1]===t.datum_params[1]&&e.datum_params[2]===t.datum_params[2]:e.datum_type===Di?e.datum_params[0]===t.datum_params[0]&&e.datum_params[1]===t.datum_params[1]&&e.datum_params[2]===t.datum_params[2]&&e.datum_params[3]===t.datum_params[3]&&e.datum_params[4]===t.datum_params[4]&&e.datum_params[5]===t.datum_params[5]&&e.datum_params[6]===t.datum_params[6]:!0}function DC(e,t,r){var n=e.x,i=e.y,a=e.z?e.z:0,o,s,u,c;if(i<-fe&&i>-1.001*fe)i=-fe;else if(i>fe&&i<1.001*fe)i=fe;else{if(i<-fe)return{x:-1/0,y:-1/0,z:e.z};if(i>fe)return{x:1/0,y:1/0,z:e.z}}return n>Math.PI&&(n-=2*Math.PI),s=Math.sin(i),c=Math.cos(i),u=s*s,o=r/Math.sqrt(1-t*u),{x:(o+a)*c*Math.cos(n),y:(o+a)*c*Math.sin(n),z:(o*(1-t)+a)*s}}function NC(e,t,r,n){var i=1e-12,a=i*i,o=30,s,u,c,d,h,p,m,g,b,_,w,C,S,T=e.x,M=e.y,P=e.z?e.z:0,R,k,I;if(s=Math.sqrt(T*T+M*M),u=Math.sqrt(T*T+M*M+P*P),s/r<i){if(R=0,u/r<i)return k=fe,I=-n,{x:e.x,y:e.y,z:e.z}}else R=Math.atan2(M,T);c=P/u,d=s/u,h=1/Math.sqrt(1-t*(2-t)*d*d),g=d*(1-t)*h,b=c*h,S=0;do S++,m=r/Math.sqrt(1-t*b*b),I=s*g+P*b-m*(1-t*b*b),p=t*m/(m+I),h=1/Math.sqrt(1-p*(2-p)*d*d),_=d*(1-p)*h,w=c*h,C=w*g-_*b,g=_,b=w;while(C*C>a&&S<o);return k=Math.atan(w/Math.abs(_)),{x:R,y:k,z:I}}function y8(e,t,r){if(t===Ri)return{x:e.x+r[0],y:e.y+r[1],z:e.z+r[2]};if(t===Di){var n=r[0],i=r[1],a=r[2],o=r[3],s=r[4],u=r[5],c=r[6];return{x:c*(e.x-u*e.y+s*e.z)+n,y:c*(u*e.x+e.y-o*e.z)+i,z:c*(-s*e.x+o*e.y+e.z)+a}}}function b8(e,t,r){if(t===Ri)return{x:e.x-r[0],y:e.y-r[1],z:e.z-r[2]};if(t===Di){var n=r[0],i=r[1],a=r[2],o=r[3],s=r[4],u=r[5],c=r[6],d=(e.x-n)/c,h=(e.y-i)/c,p=(e.z-a)/c;return{x:d+u*h-s*p,y:-u*d+h+o*p,z:s*d-o*h+p}}}function ru(e){return e===Ri||e===Di}function _8(e,t,r){if(v8(e,t)||e.datum_type===Yf||t.datum_type===Yf)return r;var n=e.a,i=e.es;if(e.datum_type===Ia){var a=H1(e,!1,r);if(a!==0)return;n=O1,i=I1}var o=t.a,s=t.b,u=t.es;if(t.datum_type===Ia&&(o=O1,s=SN,u=I1),i===u&&n===o&&!ru(e.datum_type)&&!ru(t.datum_type))return r;if(r=DC(r,i,n),ru(e.datum_type)&&(r=y8(r,e.datum_type,e.datum_params)),ru(t.datum_type)&&(r=b8(r,t.datum_type,t.datum_params)),r=NC(r,u,o,s),t.datum_type===Ia){var c=H1(t,!0,r);if(c!==0)return}return r}function H1(e,t,r){if(e.grids===null||e.grids.length===0)return console.log("Grid shift grids not found"),-1;var n={x:-r.x,y:r.y},i={x:Number.NaN,y:Number.NaN},a=[];e:for(var o=0;o<e.grids.length;o++){var s=e.grids[o];if(a.push(s.name),s.isNull){i=n;break}if(s.grid===null){if(s.mandatory)return console.log("Unable to find mandatory grid '"+s.name+"'"),-1;continue}for(var u=s.grid.subgrids,c=0,d=u.length;c<d;c++){var h=u[c],p=(Math.abs(h.del[1])+Math.abs(h.del[0]))/1e4,m=h.ll[0]-p,g=h.ll[1]-p,b=h.ll[0]+(h.lim[0]-1)*h.del[0]+p,_=h.ll[1]+(h.lim[1]-1)*h.del[1]+p;if(!(g>n.y||m>n.x||_<n.y||b<n.x)&&(i=w8(n,t,h),!isNaN(i.x)))break e}}return isNaN(i.x)?(console.log("Failed to find a grid shift table for location '"+-n.x*ln+" "+n.y*ln+" tried: '"+a+"'"),-1):(r.x=-i.x,r.y=i.y,0)}function w8(e,t,r){var n={x:Number.NaN,y:Number.NaN};if(isNaN(e.x))return n;var i={x:e.x,y:e.y};i.x-=r.ll[0],i.y-=r.ll[1],i.x=be(i.x-Math.PI)+Math.PI;var a=W1(i,r);if(t){if(isNaN(a.x))return n;a.x=i.x-a.x,a.y=i.y-a.y;var o=9,s=1e-12,u,c;do{if(c=W1(a,r),isNaN(c.x)){console.log("Inverse grid shift iteration failed, presumably at grid edge. Using first approximation.");break}u={x:i.x-(c.x+a.x),y:i.y-(c.y+a.y)},a.x+=u.x,a.y+=u.y}while(o--&&Math.abs(u.x)>s&&Math.abs(u.y)>s);if(o<0)return console.log("Inverse grid shift iterator failed to converge."),n;n.x=be(a.x+r.ll[0]),n.y=a.y+r.ll[1]}else isNaN(a.x)||(n.x=e.x+a.x,n.y=e.y+a.y);return n}function W1(e,t){var r={x:e.x/t.del[0],y:e.y/t.del[1]},n={x:Math.floor(r.x),y:Math.floor(r.y)},i={x:r.x-1*n.x,y:r.y-1*n.y},a={x:Number.NaN,y:Number.NaN},o;if(n.x<0||n.x>=t.lim[0]||n.y<0||n.y>=t.lim[1])return a;o=n.y*t.lim[0]+n.x;var s={x:t.cvs[o][0],y:t.cvs[o][1]};o++;var u={x:t.cvs[o][0],y:t.cvs[o][1]};o+=t.lim[0];var c={x:t.cvs[o][0],y:t.cvs[o][1]};o--;var d={x:t.cvs[o][0],y:t.cvs[o][1]},h=i.x*i.y,p=i.x*(1-i.y),m=(1-i.x)*(1-i.y),g=(1-i.x)*i.y;return a.x=m*s.x+p*u.x+g*d.x+h*c.x,a.y=m*s.y+p*u.y+g*d.y+h*c.y,a}function j1(e,t,r){var n=r.x,i=r.y,a=r.z||0,o,s,u,c={};for(u=0;u<3;u++)if(!(t&&u===2&&r.z===void 0))switch(u===0?(o=n,"ew".indexOf(e.axis[u])!==-1?s="x":s="y"):u===1?(o=i,"ns".indexOf(e.axis[u])!==-1?s="y":s="x"):(o=a,s="z"),e.axis[u]){case"e":c[s]=o;break;case"w":c[s]=-o;break;case"n":c[s]=o;break;case"s":c[s]=-o;break;case"u":r[s]!==void 0&&(c.z=o);break;case"d":r[s]!==void 0&&(c.z=-o);break;default:return null}return c}function kC(e){var t={x:e[0],y:e[1]};return e.length>2&&(t.z=e[2]),e.length>3&&(t.m=e[3]),t}function C8(e){V1(e.x),V1(e.y)}function V1(e){if(typeof Number.isFinite=="function"){if(Number.isFinite(e))return;throw new TypeError("coordinates must be finite numbers")}if(typeof e!="number"||e!==e||!isFinite(e))throw new TypeError("coordinates must be finite numbers")}function x8(e,t){return(e.datum.datum_type===Ri||e.datum.datum_type===Di||e.datum.datum_type===Ia)&&t.datumCode!=="WGS84"||(t.datum.datum_type===Ri||t.datum.datum_type===Di||t.datum.datum_type===Ia)&&e.datumCode!=="WGS84"}function nc(e,t,r,n){var i;Array.isArray(r)?r=kC(r):r={x:r.x,y:r.y,z:r.z,m:r.m};var a=r.z!==void 0;if(C8(r),e.datum&&t.datum&&x8(e,t)&&(i=new dn("WGS84"),r=nc(e,i,r,n),e=i),n&&e.axis!=="enu"&&(r=j1(e,!1,r)),e.projName==="longlat")r={x:r.x*Ht,y:r.y*Ht,z:r.z||0};else if(e.to_meter&&(r={x:r.x*e.to_meter,y:r.y*e.to_meter,z:r.z||0}),r=e.inverse(r),!r)return;if(e.from_greenwich&&(r.x+=e.from_greenwich),r=_8(e.datum,t.datum,r),!!r)return t.from_greenwich&&(r={x:r.x-t.from_greenwich,y:r.y,z:r.z||0}),t.projName==="longlat"?r={x:r.x*ln,y:r.y*ln,z:r.z||0}:(r=t.forward(r),t.to_meter&&(r={x:r.x/t.to_meter,y:r.y/t.to_meter,z:r.z||0})),n&&t.axis!=="enu"?j1(t,!0,r):(r&&!a&&delete r.z,r)}var U1=dn("WGS84");function Ih(e,t,r,n){var i,a,o;return Array.isArray(r)?(i=nc(e,t,r,n)||{x:NaN,y:NaN},r.length>2?typeof e.name!="undefined"&&e.name==="geocent"||typeof t.name!="undefined"&&t.name==="geocent"?typeof i.z=="number"?[i.x,i.y,i.z].concat(r.splice(3)):[i.x,i.y,r[2]].concat(r.splice(3)):[i.x,i.y].concat(r.splice(2)):[i.x,i.y]):(a=nc(e,t,r,n),o=Object.keys(r),o.length===2||o.forEach(function(s){if(typeof e.name!="undefined"&&e.name==="geocent"||typeof t.name!="undefined"&&t.name==="geocent"){if(s==="x"||s==="y"||s==="z")return}else if(s==="x"||s==="y")return;a[s]=r[s]}),a)}function G1(e){return e instanceof dn?e:e.oProj?e.oProj:dn(e)}function Cr(e,t,r){e=G1(e);var n=!1,i;return typeof t=="undefined"?(t=e,e=U1,n=!0):(typeof t.x!="undefined"||Array.isArray(t))&&(r=t,t=e,e=U1,n=!0),t=G1(t),r?Ih(e,t,r):(i={forward:function(a,o){return Ih(e,t,a,o)},inverse:function(a,o){return Ih(t,e,a,o)}},n&&(i.oProj=t),i)}var q1=6,LC="AJSAJS",OC="AFAFAF",Ea=65,fr=73,Dr=79,ts=86,rs=90;const T8={forward:IC,inverse:S8,toPoint:FC};function IC(e,t){return t=t||5,E8(M8({lat:e[1],lon:e[0]}),t)}function S8(e){var t=_0(BC(e.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat,t.lon,t.lat]:[t.left,t.bottom,t.right,t.top]}function FC(e){var t=_0(BC(e.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat]:[(t.left+t.right)/2,(t.top+t.bottom)/2]}function Fh(e){return e*(Math.PI/180)}function Y1(e){return 180*(e/Math.PI)}function M8(e){var t=e.lat,r=e.lon,n=6378137,i=.00669438,a=.9996,o,s,u,c,d,h,p,m=Fh(t),g=Fh(r),b,_;_=Math.floor((r+180)/6)+1,r===180&&(_=60),t>=56&&t<64&&r>=3&&r<12&&(_=32),t>=72&&t<84&&(r>=0&&r<9?_=31:r>=9&&r<21?_=33:r>=21&&r<33?_=35:r>=33&&r<42&&(_=37)),o=(_-1)*6-180+3,b=Fh(o),s=i/(1-i),u=n/Math.sqrt(1-i*Math.sin(m)*Math.sin(m)),c=Math.tan(m)*Math.tan(m),d=s*Math.cos(m)*Math.cos(m),h=Math.cos(m)*(g-b),p=n*((1-i/4-3*i*i/64-5*i*i*i/256)*m-(3*i/8+3*i*i/32+45*i*i*i/1024)*Math.sin(2*m)+(15*i*i/256+45*i*i*i/1024)*Math.sin(4*m)-35*i*i*i/3072*Math.sin(6*m));var w=a*u*(h+(1-c+d)*h*h*h/6+(5-18*c+c*c+72*d-58*s)*h*h*h*h*h/120)+5e5,C=a*(p+u*Math.tan(m)*(h*h/2+(5-c+9*d+4*d*d)*h*h*h*h/24+(61-58*c+c*c+600*d-330*s)*h*h*h*h*h*h/720));return t<0&&(C+=1e7),{northing:Math.round(C),easting:Math.round(w),zoneNumber:_,zoneLetter:P8(t)}}function _0(e){var t=e.northing,r=e.easting,n=e.zoneLetter,i=e.zoneNumber;if(i<0||i>60)return null;var a=.9996,o=6378137,s=.00669438,u,c=(1-Math.sqrt(1-s))/(1+Math.sqrt(1-s)),d,h,p,m,g,b,_,w,C,S=r-5e5,T=t;n<"N"&&(T-=1e7),_=(i-1)*6-180+3,u=s/(1-s),b=T/a,w=b/(o*(1-s/4-3*s*s/64-5*s*s*s/256)),C=w+(3*c/2-27*c*c*c/32)*Math.sin(2*w)+(21*c*c/16-55*c*c*c*c/32)*Math.sin(4*w)+151*c*c*c/96*Math.sin(6*w),d=o/Math.sqrt(1-s*Math.sin(C)*Math.sin(C)),h=Math.tan(C)*Math.tan(C),p=u*Math.cos(C)*Math.cos(C),m=o*(1-s)/Math.pow(1-s*Math.sin(C)*Math.sin(C),1.5),g=S/(d*a);var M=C-d*Math.tan(C)/m*(g*g/2-(5+3*h+10*p-4*p*p-9*u)*g*g*g*g/24+(61+90*h+298*p+45*h*h-252*u-3*p*p)*g*g*g*g*g*g/720);M=Y1(M);var P=(g-(1+2*h+p)*g*g*g/6+(5-2*p+28*h-3*p*p+8*u+24*h*h)*g*g*g*g*g/120)/Math.cos(C);P=_+Y1(P);var R;if(e.accuracy){var k=_0({northing:e.northing+e.accuracy,easting:e.easting+e.accuracy,zoneLetter:e.zoneLetter,zoneNumber:e.zoneNumber});R={top:k.lat,right:k.lon,bottom:M,left:P}}else R={lat:M,lon:P};return R}function P8(e){var t="Z";return 84>=e&&e>=72?t="X":72>e&&e>=64?t="W":64>e&&e>=56?t="V":56>e&&e>=48?t="U":48>e&&e>=40?t="T":40>e&&e>=32?t="S":32>e&&e>=24?t="R":24>e&&e>=16?t="Q":16>e&&e>=8?t="P":8>e&&e>=0?t="N":0>e&&e>=-8?t="M":-8>e&&e>=-16?t="L":-16>e&&e>=-24?t="K":-24>e&&e>=-32?t="J":-32>e&&e>=-40?t="H":-40>e&&e>=-48?t="G":-48>e&&e>=-56?t="F":-56>e&&e>=-64?t="E":-64>e&&e>=-72?t="D":-72>e&&e>=-80&&(t="C"),t}function E8(e,t){var r="00000"+e.easting,n="00000"+e.northing;return e.zoneNumber+e.zoneLetter+A8(e.easting,e.northing,e.zoneNumber)+r.substr(r.length-5,t)+n.substr(n.length-5,t)}function A8(e,t,r){var n=$C(r),i=Math.floor(e/1e5),a=Math.floor(t/1e5)%20;return R8(i,a,n)}function $C(e){var t=e%q1;return t===0&&(t=q1),t}function R8(e,t,r){var n=r-1,i=LC.charCodeAt(n),a=OC.charCodeAt(n),o=i+e-1,s=a+t,u=!1;o>rs&&(o=o-rs+Ea-1,u=!0),(o===fr||i<fr&&o>fr||(o>fr||i<fr)&&u)&&o++,(o===Dr||i<Dr&&o>Dr||(o>Dr||i<Dr)&&u)&&(o++,o===fr&&o++),o>rs&&(o=o-rs+Ea-1),s>ts?(s=s-ts+Ea-1,u=!0):u=!1,(s===fr||a<fr&&s>fr||(s>fr||a<fr)&&u)&&s++,(s===Dr||a<Dr&&s>Dr||(s>Dr||a<Dr)&&u)&&(s++,s===fr&&s++),s>ts&&(s=s-ts+Ea-1);var c=String.fromCharCode(o)+String.fromCharCode(s);return c}function BC(e){if(e&&e.length===0)throw"MGRSPoint coverting from nothing";for(var t=e.length,r=null,n="",i,a=0;!/[A-Z]/.test(i=e.charAt(a));){if(a>=2)throw"MGRSPoint bad conversion from: "+e;n+=i,a++}var o=parseInt(n,10);if(a===0||a+3>t)throw"MGRSPoint bad conversion from: "+e;var s=e.charAt(a++);if(s<="A"||s==="B"||s==="Y"||s>="Z"||s==="I"||s==="O")throw"MGRSPoint zone letter "+s+" not handled: "+e;r=e.substring(a,a+=2);for(var u=$C(o),c=D8(r.charAt(0),u),d=N8(r.charAt(1),u);d<k8(s);)d+=2e6;var h=t-a;if(h%2!==0)throw`MGRSPoint has to have an even number
15
+ of digits after the zone letter and two 100km letters - front
16
+ half for easting meters, second half for
17
+ northing meters`+e;var p=h/2,m=0,g=0,b,_,w,C,S;return p>0&&(b=1e5/Math.pow(10,p),_=e.substring(a,a+p),m=parseFloat(_)*b,w=e.substring(a+p),g=parseFloat(w)*b),C=m+c,S=g+d,{easting:C,northing:S,zoneLetter:s,zoneNumber:o,accuracy:b}}function D8(e,t){for(var r=LC.charCodeAt(t-1),n=1e5,i=!1;r!==e.charCodeAt(0);){if(r++,r===fr&&r++,r===Dr&&r++,r>rs){if(i)throw"Bad character: "+e;r=Ea,i=!0}n+=1e5}return n}function N8(e,t){if(e>"V")throw"MGRSPoint given invalid Northing "+e;for(var r=OC.charCodeAt(t-1),n=0,i=!1;r!==e.charCodeAt(0);){if(r++,r===fr&&r++,r===Dr&&r++,r>ts){if(i)throw"Bad character: "+e;r=Ea,i=!0}n+=1e5}return n}function k8(e){var t;switch(e){case"C":t=11e5;break;case"D":t=2e6;break;case"E":t=28e5;break;case"F":t=37e5;break;case"G":t=46e5;break;case"H":t=55e5;break;case"J":t=64e5;break;case"K":t=73e5;break;case"L":t=82e5;break;case"M":t=91e5;break;case"N":t=0;break;case"P":t=8e5;break;case"Q":t=17e5;break;case"R":t=26e5;break;case"S":t=35e5;break;case"T":t=44e5;break;case"U":t=53e5;break;case"V":t=62e5;break;case"W":t=7e6;break;case"X":t=79e5;break;default:t=-1}if(t>=0)return t;throw"Invalid zone letter: "+e}function Ha(e,t,r){if(!(this instanceof Ha))return new Ha(e,t,r);if(Array.isArray(e))this.x=e[0],this.y=e[1],this.z=e[2]||0;else if(typeof e=="object")this.x=e.x,this.y=e.y,this.z=e.z||0;else if(typeof e=="string"&&typeof t=="undefined"){var n=e.split(",");this.x=parseFloat(n[0],10),this.y=parseFloat(n[1],10),this.z=parseFloat(n[2],10)||0}else this.x=e,this.y=t,this.z=r||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}Ha.fromMGRS=function(e){return new Ha(FC(e))};Ha.prototype.toMGRS=function(e){return IC([this.x,this.y],e)};var L8=1,O8=.25,X1=.046875,Z1=.01953125,K1=.01068115234375,I8=.75,F8=.46875,$8=.013020833333333334,B8=.007120768229166667,z8=.3645833333333333,H8=.005696614583333333,W8=.3076171875;function zC(e){var t=[];t[0]=L8-e*(O8+e*(X1+e*(Z1+e*K1))),t[1]=e*(I8-e*(X1+e*(Z1+e*K1)));var r=e*e;return t[2]=r*(F8-e*($8+e*B8)),r*=e,t[3]=r*(z8-e*H8),t[4]=r*e*W8,t}function Xc(e,t,r,n){return r*=t,t*=t,n[0]*e-r*(n[1]+t*(n[2]+t*(n[3]+t*n[4])))}var j8=20;function HC(e,t,r){for(var n=1/(1-t),i=e,a=j8;a;--a){var o=Math.sin(i),s=1-t*o*o;if(s=(Xc(i,o,Math.cos(i),r)-e)*(s*Math.sqrt(s))*n,i-=s,Math.abs(s)<ge)return i}return i}function V8(){this.x0=this.x0!==void 0?this.x0:0,this.y0=this.y0!==void 0?this.y0:0,this.long0=this.long0!==void 0?this.long0:0,this.lat0=this.lat0!==void 0?this.lat0:0,this.es&&(this.en=zC(this.es),this.ml0=Xc(this.lat0,Math.sin(this.lat0),Math.cos(this.lat0),this.en))}function U8(e){var t=e.x,r=e.y,n=be(t-this.long0),i,a,o,s=Math.sin(r),u=Math.cos(r);if(this.es){var d=u*n,h=Math.pow(d,2),p=this.ep2*Math.pow(u,2),m=Math.pow(p,2),g=Math.abs(u)>ge?Math.tan(r):0,b=Math.pow(g,2),_=Math.pow(b,2);i=1-this.es*Math.pow(s,2),d=d/Math.sqrt(i);var w=Xc(r,s,u,this.en);a=this.a*(this.k0*d*(1+h/6*(1-b+p+h/20*(5-18*b+_+14*p-58*b*p+h/42*(61+179*_-_*b-479*b)))))+this.x0,o=this.a*(this.k0*(w-this.ml0+s*n*d/2*(1+h/12*(5-b+9*p+4*m+h/30*(61+_-58*b+270*p-330*b*p+h/56*(1385+543*_-_*b-3111*b))))))+this.y0}else{var c=u*Math.sin(n);if(Math.abs(Math.abs(c)-1)<ge)return 93;if(a=.5*this.a*this.k0*Math.log((1+c)/(1-c))+this.x0,o=u*Math.cos(n)/Math.sqrt(1-Math.pow(c,2)),c=Math.abs(o),c>=1){if(c-1>ge)return 93;o=0}else o=Math.acos(o);r<0&&(o=-o),o=this.a*this.k0*(o-this.lat0)+this.y0}return e.x=a,e.y=o,e}function G8(e){var t,r,n,i,a=(e.x-this.x0)*(1/this.a),o=(e.y-this.y0)*(1/this.a);if(this.es)if(t=this.ml0+o/this.k0,r=HC(t,this.es,this.en),Math.abs(r)<fe){var h=Math.sin(r),p=Math.cos(r),m=Math.abs(p)>ge?Math.tan(r):0,g=this.ep2*Math.pow(p,2),b=Math.pow(g,2),_=Math.pow(m,2),w=Math.pow(_,2);t=1-this.es*Math.pow(h,2);var C=a*Math.sqrt(t)/this.k0,S=Math.pow(C,2);t=t*m,n=r-t*S/(1-this.es)*.5*(1-S/12*(5+3*_-9*g*_+g-4*b-S/30*(61+90*_-252*g*_+45*w+46*g-S/56*(1385+3633*_+4095*w+1574*w*_)))),i=be(this.long0+C*(1-S/6*(1+2*_+g-S/20*(5+28*_+24*w+8*g*_+6*g-S/42*(61+662*_+1320*w+720*w*_))))/p)}else n=fe*Qs(o),i=0;else{var s=Math.exp(a/this.k0),u=.5*(s-1/s),c=this.lat0+o/this.k0,d=Math.cos(c);t=Math.sqrt((1-Math.pow(d,2))/(1+Math.pow(u,2))),n=Math.asin(t),o<0&&(n=-n),u===0&&d===0?i=0:i=be(Math.atan2(u,d)+this.long0)}return e.x=i,e.y=n,e}var q8=["Fast_Transverse_Mercator","Fast Transverse Mercator"];const Nu={init:V8,forward:U8,inverse:G8,names:q8};function WC(e){var t=Math.exp(e);return t=(t-1/t)/2,t}function kr(e,t){e=Math.abs(e),t=Math.abs(t);var r=Math.max(e,t),n=Math.min(e,t)/(r||1);return r*Math.sqrt(1+Math.pow(n,2))}function Y8(e){var t=1+e,r=t-1;return r===0?e:e*Math.log(t)/r}function X8(e){var t=Math.abs(e);return t=Y8(t*(1+t/(kr(1,t)+1))),e<0?-t:t}function w0(e,t){for(var r=2*Math.cos(2*t),n=e.length-1,i=e[n],a=0,o;--n>=0;)o=-a+r*i+e[n],a=i,i=o;return t+o*Math.sin(2*t)}function Z8(e,t){for(var r=2*Math.cos(t),n=e.length-1,i=e[n],a=0,o;--n>=0;)o=-a+r*i+e[n],a=i,i=o;return Math.sin(t)*o}function K8(e){var t=Math.exp(e);return t=(t+1/t)/2,t}function jC(e,t,r){for(var n=Math.sin(t),i=Math.cos(t),a=WC(r),o=K8(r),s=2*i*o,u=-2*n*a,c=e.length-1,d=e[c],h=0,p=0,m=0,g,b;--c>=0;)g=p,b=h,p=d,h=m,d=-g+s*p-u*h+e[c],m=-b+u*p+s*h;return s=n*o,u=i*a,[s*d-u*m,s*m+u*d]}function Q8(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&(Nu.init.apply(this),this.forward=Nu.forward,this.inverse=Nu.inverse),this.x0=this.x0!==void 0?this.x0:0,this.y0=this.y0!==void 0?this.y0:0,this.long0=this.long0!==void 0?this.long0:0,this.lat0=this.lat0!==void 0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var e=this.es/(1+Math.sqrt(1-this.es)),t=e/(2-e),r=t;this.cgb[0]=t*(2+t*(-2/3+t*(-2+t*(116/45+t*(26/45+t*(-2854/675)))))),this.cbg[0]=t*(-2+t*(2/3+t*(4/3+t*(-82/45+t*(32/45+t*(4642/4725)))))),r=r*t,this.cgb[1]=r*(7/3+t*(-8/5+t*(-227/45+t*(2704/315+t*(2323/945))))),this.cbg[1]=r*(5/3+t*(-16/15+t*(-13/9+t*(904/315+t*(-1522/945))))),r=r*t,this.cgb[2]=r*(56/15+t*(-136/35+t*(-1262/105+t*(73814/2835)))),this.cbg[2]=r*(-26/15+t*(34/21+t*(8/5+t*(-12686/2835)))),r=r*t,this.cgb[3]=r*(4279/630+t*(-332/35+t*(-399572/14175))),this.cbg[3]=r*(1237/630+t*(-12/5+t*(-24832/14175))),r=r*t,this.cgb[4]=r*(4174/315+t*(-144838/6237)),this.cbg[4]=r*(-734/315+t*(109598/31185)),r=r*t,this.cgb[5]=r*(601676/22275),this.cbg[5]=r*(444337/155925),r=Math.pow(t,2),this.Qn=this.k0/(1+t)*(1+r*(1/4+r*(1/64+r/256))),this.utg[0]=t*(-.5+t*(2/3+t*(-37/96+t*(1/360+t*(81/512+t*(-96199/604800)))))),this.gtu[0]=t*(.5+t*(-2/3+t*(5/16+t*(41/180+t*(-127/288+t*(7891/37800)))))),this.utg[1]=r*(-1/48+t*(-1/15+t*(437/1440+t*(-46/105+t*(1118711/3870720))))),this.gtu[1]=r*(13/48+t*(-3/5+t*(557/1440+t*(281/630+t*(-1983433/1935360))))),r=r*t,this.utg[2]=r*(-17/480+t*(37/840+t*(209/4480+t*(-5569/90720)))),this.gtu[2]=r*(61/240+t*(-103/140+t*(15061/26880+t*(167603/181440)))),r=r*t,this.utg[3]=r*(-4397/161280+t*(11/504+t*(830251/7257600))),this.gtu[3]=r*(49561/161280+t*(-179/168+t*(6601661/7257600))),r=r*t,this.utg[4]=r*(-4583/161280+t*(108847/3991680)),this.gtu[4]=r*(34729/80640+t*(-3418889/1995840)),r=r*t,this.utg[5]=r*(-20648693/638668800),this.gtu[5]=r*(212378941/319334400);var n=w0(this.cbg,this.lat0);this.Zb=-this.Qn*(n+Z8(this.gtu,2*n))}function J8(e){var t=be(e.x-this.long0),r=e.y;r=w0(this.cbg,r);var n=Math.sin(r),i=Math.cos(r),a=Math.sin(t),o=Math.cos(t);r=Math.atan2(n,o*i),t=Math.atan2(a*i,kr(n,i*o)),t=X8(Math.tan(t));var s=jC(this.gtu,2*r,2*t);r=r+s[0],t=t+s[1];var u,c;return Math.abs(t)<=2.623395162778?(u=this.a*(this.Qn*t)+this.x0,c=this.a*(this.Qn*r+this.Zb)+this.y0):(u=1/0,c=1/0),e.x=u,e.y=c,e}function ek(e){var t=(e.x-this.x0)*(1/this.a),r=(e.y-this.y0)*(1/this.a);r=(r-this.Zb)/this.Qn,t=t/this.Qn;var n,i;if(Math.abs(t)<=2.623395162778){var a=jC(this.utg,2*r,2*t);r=r+a[0],t=t+a[1],t=Math.atan(WC(t));var o=Math.sin(r),s=Math.cos(r),u=Math.sin(t),c=Math.cos(t);r=Math.atan2(o*c,kr(u,c*s)),t=Math.atan2(u,c*s),n=be(t+this.long0),i=w0(this.cgb,r)}else n=1/0,i=1/0;return e.x=n,e.y=i,e}var tk=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"];const ku={init:Q8,forward:J8,inverse:ek,names:tk};function rk(e,t){if(e===void 0){if(e=Math.floor((be(t)+Math.PI)*30/Math.PI)+1,e<0)return 0;if(e>60)return 60}return e}var nk="etmerc";function ik(){var e=rk(this.zone,this.long0);if(e===void 0)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(e)-183)*Ht,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,ku.init.apply(this),this.forward=ku.forward,this.inverse=ku.inverse}var ak=["Universal Transverse Mercator System","utm"];const ok={init:ik,names:ak,dependsOn:nk};function C0(e,t){return Math.pow((1-e)/(1+e),t)}var sk=20;function lk(){var e=Math.sin(this.lat0),t=Math.cos(this.lat0);t*=t,this.rc=Math.sqrt(1-this.es)/(1-this.es*e*e),this.C=Math.sqrt(1+this.es*t*t/(1-this.es)),this.phic0=Math.asin(e/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+Xe)/(Math.pow(Math.tan(.5*this.lat0+Xe),this.C)*C0(this.e*e,this.ratexp))}function uk(e){var t=e.x,r=e.y;return e.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*r+Xe),this.C)*C0(this.e*Math.sin(r),this.ratexp))-fe,e.x=this.C*t,e}function ck(e){for(var t=1e-14,r=e.x/this.C,n=e.y,i=Math.pow(Math.tan(.5*n+Xe)/this.K,1/this.C),a=sk;a>0&&(n=2*Math.atan(i*C0(this.e*Math.sin(e.y),-.5*this.e))-fe,!(Math.abs(n-e.y)<t));--a)e.y=n;return a?(e.x=r,e.y=n,e):null}var dk=["gauss"];const x0={init:lk,forward:uk,inverse:ck,names:dk};function hk(){x0.init.apply(this),this.rc&&(this.sinc0=Math.sin(this.phic0),this.cosc0=Math.cos(this.phic0),this.R2=2*this.rc,this.title||(this.title="Oblique Stereographic Alternative"))}function fk(e){var t,r,n,i;return e.x=be(e.x-this.long0),x0.forward.apply(this,[e]),t=Math.sin(e.y),r=Math.cos(e.y),n=Math.cos(e.x),i=this.k0*this.R2/(1+this.sinc0*t+this.cosc0*r*n),e.x=i*r*Math.sin(e.x),e.y=i*(this.cosc0*t-this.sinc0*r*n),e.x=this.a*e.x+this.x0,e.y=this.a*e.y+this.y0,e}function pk(e){var t,r,n,i,a;if(e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,e.x/=this.k0,e.y/=this.k0,a=kr(e.x,e.y)){var o=2*Math.atan2(a,this.R2);t=Math.sin(o),r=Math.cos(o),i=Math.asin(r*this.sinc0+e.y*t*this.cosc0/a),n=Math.atan2(e.x*t,a*this.cosc0*r-e.y*this.sinc0*t)}else i=this.phic0,n=0;return e.x=n,e.y=i,x0.inverse.apply(this,[e]),e.x=be(e.x+this.long0),e}var mk=["Stereographic_North_Pole","Oblique_Stereographic","sterea","Oblique Stereographic Alternative","Double_Stereographic"];const gk={init:hk,forward:fk,inverse:pk,names:mk};function vk(e,t,r){return t*=r,Math.tan(.5*(fe+e))*Math.pow((1-t)/(1+t),.5*r)}function yk(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.coslat0=Math.cos(this.lat0),this.sinlat0=Math.sin(this.lat0),this.sphere?this.k0===1&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=ge&&(this.k0=.5*(1+Qs(this.lat0)*Math.sin(this.lat_ts))):(Math.abs(this.coslat0)<=ge&&(this.lat0>0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),this.k0===1&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=ge&&Math.abs(Math.cos(this.lat_ts))>ge&&(this.k0=.5*this.cons*pn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/Vr(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=pn(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-fe,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function bk(e){var t=e.x,r=e.y,n=Math.sin(r),i=Math.cos(r),a,o,s,u,c,d,h=be(t-this.long0);return Math.abs(Math.abs(t-this.long0)-Math.PI)<=ge&&Math.abs(r+this.lat0)<=ge?(e.x=NaN,e.y=NaN,e):this.sphere?(a=2*this.k0/(1+this.sinlat0*n+this.coslat0*i*Math.cos(h)),e.x=this.a*a*i*Math.sin(h)+this.x0,e.y=this.a*a*(this.coslat0*n-this.sinlat0*i*Math.cos(h))+this.y0,e):(o=2*Math.atan(this.ssfn_(r,n,this.e))-fe,u=Math.cos(o),s=Math.sin(o),Math.abs(this.coslat0)<=ge?(c=Vr(this.e,r*this.con,this.con*n),d=2*this.a*this.k0*c/this.cons,e.x=this.x0+d*Math.sin(t-this.long0),e.y=this.y0-this.con*d*Math.cos(t-this.long0),e):(Math.abs(this.sinlat0)<ge?(a=2*this.a*this.k0/(1+u*Math.cos(h)),e.y=a*s):(a=2*this.a*this.k0*this.ms1/(this.cosX0*(1+this.sinX0*s+this.cosX0*u*Math.cos(h))),e.y=a*(this.cosX0*s-this.sinX0*u*Math.cos(h))+this.y0),e.x=a*u*Math.sin(h)+this.x0,e))}function _k(e){e.x-=this.x0,e.y-=this.y0;var t,r,n,i,a,o=Math.sqrt(e.x*e.x+e.y*e.y);if(this.sphere){var s=2*Math.atan(o/(2*this.a*this.k0));return t=this.long0,r=this.lat0,o<=ge?(e.x=t,e.y=r,e):(r=Math.asin(Math.cos(s)*this.sinlat0+e.y*Math.sin(s)*this.coslat0/o),Math.abs(this.coslat0)<ge?this.lat0>0?t=be(this.long0+Math.atan2(e.x,-1*e.y)):t=be(this.long0+Math.atan2(e.x,e.y)):t=be(this.long0+Math.atan2(e.x*Math.sin(s),o*this.coslat0*Math.cos(s)-e.y*this.sinlat0*Math.sin(s))),e.x=t,e.y=r,e)}else if(Math.abs(this.coslat0)<=ge){if(o<=ge)return r=this.lat0,t=this.long0,e.x=t,e.y=r,e;e.x*=this.con,e.y*=this.con,n=o*this.cons/(2*this.a*this.k0),r=this.con*Ds(this.e,n),t=this.con*be(this.con*this.long0+Math.atan2(e.x,-1*e.y))}else i=2*Math.atan(o*this.cosX0/(2*this.a*this.k0*this.ms1)),t=this.long0,o<=ge?a=this.X0:(a=Math.asin(Math.cos(i)*this.sinX0+e.y*Math.sin(i)*this.cosX0/o),t=be(this.long0+Math.atan2(e.x*Math.sin(i),o*this.cosX0*Math.cos(i)-e.y*this.sinX0*Math.sin(i)))),r=-1*Ds(this.e,Math.tan(.5*(fe+a)));return e.x=t,e.y=r,e}var wk=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"];const Ck={init:yk,forward:bk,inverse:_k,names:wk,ssfn_:vk};function xk(){var e=this.lat0;this.lambda0=this.long0;var t=Math.sin(e),r=this.a,n=this.rf,i=1/n,a=2*i-Math.pow(i,2),o=this.e=Math.sqrt(a);this.R=this.k0*r*Math.sqrt(1-a)/(1-a*Math.pow(t,2)),this.alpha=Math.sqrt(1+a/(1-a)*Math.pow(Math.cos(e),4)),this.b0=Math.asin(t/this.alpha);var s=Math.log(Math.tan(Math.PI/4+this.b0/2)),u=Math.log(Math.tan(Math.PI/4+e/2)),c=Math.log((1+o*t)/(1-o*t));this.K=s-this.alpha*u+this.alpha*o/2*c}function Tk(e){var t=Math.log(Math.tan(Math.PI/4-e.y/2)),r=this.e/2*Math.log((1+this.e*Math.sin(e.y))/(1-this.e*Math.sin(e.y))),n=-this.alpha*(t+r)+this.K,i=2*(Math.atan(Math.exp(n))-Math.PI/4),a=this.alpha*(e.x-this.lambda0),o=Math.atan(Math.sin(a)/(Math.sin(this.b0)*Math.tan(i)+Math.cos(this.b0)*Math.cos(a))),s=Math.asin(Math.cos(this.b0)*Math.sin(i)-Math.sin(this.b0)*Math.cos(i)*Math.cos(a));return e.y=this.R/2*Math.log((1+Math.sin(s))/(1-Math.sin(s)))+this.y0,e.x=this.R*o+this.x0,e}function Sk(e){for(var t=e.x-this.x0,r=e.y-this.y0,n=t/this.R,i=2*(Math.atan(Math.exp(r/this.R))-Math.PI/4),a=Math.asin(Math.cos(this.b0)*Math.sin(i)+Math.sin(this.b0)*Math.cos(i)*Math.cos(n)),o=Math.atan(Math.sin(n)/(Math.cos(this.b0)*Math.cos(n)-Math.sin(this.b0)*Math.tan(i))),s=this.lambda0+o/this.alpha,u=0,c=a,d=-1e3,h=0;Math.abs(c-d)>1e-7;){if(++h>20)return;u=1/this.alpha*(Math.log(Math.tan(Math.PI/4+a/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(c))/2)),d=c,c=2*Math.atan(Math.exp(u))-Math.PI/2}return e.x=s,e.y=c,e}var Mk=["somerc"];const Pk={init:xk,forward:Tk,inverse:Sk,names:Mk};var ya=1e-7;function Ek(e){var t=["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"],r=typeof e.PROJECTION=="object"?Object.keys(e.PROJECTION)[0]:e.PROJECTION;return"no_uoff"in e||"no_off"in e||t.indexOf(r)!==-1}function Ak(){var e,t,r,n,i,a,o,s,u,c,d=0,h,p=0,m=0,g=0,b=0,_=0,w=0;this.no_off=Ek(this),this.no_rot="no_rot"in this;var C=!1;"alpha"in this&&(C=!0);var S=!1;if("rectified_grid_angle"in this&&(S=!0),C&&(w=this.alpha),S&&(d=this.rectified_grid_angle*Ht),C||S)p=this.longc;else if(m=this.long1,b=this.lat1,g=this.long2,_=this.lat2,Math.abs(b-_)<=ya||(e=Math.abs(b))<=ya||Math.abs(e-fe)<=ya||Math.abs(Math.abs(this.lat0)-fe)<=ya||Math.abs(Math.abs(_)-fe)<=ya)throw new Error;var T=1-this.es;t=Math.sqrt(T),Math.abs(this.lat0)>ge?(s=Math.sin(this.lat0),r=Math.cos(this.lat0),e=1-this.es*s*s,this.B=r*r,this.B=Math.sqrt(1+this.es*this.B*this.B/T),this.A=this.B*this.k0*t/e,n=this.B*t/(r*Math.sqrt(e)),i=n*n-1,i<=0?i=0:(i=Math.sqrt(i),this.lat0<0&&(i=-i)),this.E=i+=n,this.E*=Math.pow(Vr(this.e,this.lat0,s),this.B)):(this.B=1/t,this.A=this.k0,this.E=n=i=1),C||S?(C?(h=Math.asin(Math.sin(w)/n),S||(d=w)):(h=d,w=Math.asin(n*Math.sin(h))),this.lam0=p-Math.asin(.5*(i-1/i)*Math.tan(h))/this.B):(a=Math.pow(Vr(this.e,b,Math.sin(b)),this.B),o=Math.pow(Vr(this.e,_,Math.sin(_)),this.B),i=this.E/a,u=(o-a)/(o+a),c=this.E*this.E,c=(c-o*a)/(c+o*a),e=m-g,e<-Math.pi?g-=As:e>Math.pi&&(g+=As),this.lam0=be(.5*(m+g)-Math.atan(c*Math.tan(.5*this.B*(m-g))/u)/this.B),h=Math.atan(2*Math.sin(this.B*be(m-this.lam0))/(i-1/i)),d=w=Math.asin(n*Math.sin(h))),this.singam=Math.sin(h),this.cosgam=Math.cos(h),this.sinrot=Math.sin(d),this.cosrot=Math.cos(d),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(n*n-1)/Math.cos(w))),this.lat0<0&&(this.u_0=-this.u_0)),i=.5*h,this.v_pole_n=this.ArB*Math.log(Math.tan(Xe-i)),this.v_pole_s=this.ArB*Math.log(Math.tan(Xe+i))}function Rk(e){var t={},r,n,i,a,o,s,u,c;if(e.x=e.x-this.lam0,Math.abs(Math.abs(e.y)-fe)>ge){if(o=this.E/Math.pow(Vr(this.e,e.y,Math.sin(e.y)),this.B),s=1/o,r=.5*(o-s),n=.5*(o+s),a=Math.sin(this.B*e.x),i=(r*this.singam-a*this.cosgam)/n,Math.abs(Math.abs(i)-1)<ge)throw new Error;c=.5*this.ArB*Math.log((1-i)/(1+i)),s=Math.cos(this.B*e.x),Math.abs(s)<ya?u=this.A*e.x:u=this.ArB*Math.atan2(r*this.cosgam+a*this.singam,s)}else c=e.y>0?this.v_pole_n:this.v_pole_s,u=this.ArB*e.y;return this.no_rot?(t.x=u,t.y=c):(u-=this.u_0,t.x=c*this.cosrot+u*this.sinrot,t.y=u*this.cosrot-c*this.sinrot),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function Dk(e){var t,r,n,i,a,o,s,u={};if(e.x=(e.x-this.x0)*(1/this.a),e.y=(e.y-this.y0)*(1/this.a),this.no_rot?(r=e.y,t=e.x):(r=e.x*this.cosrot-e.y*this.sinrot,t=e.y*this.cosrot+e.x*this.sinrot+this.u_0),n=Math.exp(-this.BrA*r),i=.5*(n-1/n),a=.5*(n+1/n),o=Math.sin(this.BrA*t),s=(o*this.cosgam+i*this.singam)/a,Math.abs(Math.abs(s)-1)<ge)u.x=0,u.y=s<0?-fe:fe;else{if(u.y=this.E/Math.sqrt((1+s)/(1-s)),u.y=Ds(this.e,Math.pow(u.y,1/this.B)),u.y===1/0)throw new Error;u.x=-this.rB*Math.atan2(i*this.cosgam-o*this.singam,Math.cos(this.BrA*t))}return u.x+=this.lam0,u}var Nk=["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Two_Point_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","Oblique_Mercator","omerc"];const kk={init:Ak,forward:Rk,inverse:Dk,names:Nk};function Lk(){if(this.lat2||(this.lat2=this.lat1),this.k0||(this.k0=1),this.x0=this.x0||0,this.y0=this.y0||0,!(Math.abs(this.lat1+this.lat2)<ge)){var e=this.b/this.a;this.e=Math.sqrt(1-e*e);var t=Math.sin(this.lat1),r=Math.cos(this.lat1),n=pn(this.e,t,r),i=Vr(this.e,this.lat1,t),a=Math.sin(this.lat2),o=Math.cos(this.lat2),s=pn(this.e,a,o),u=Vr(this.e,this.lat2,a),c=Vr(this.e,this.lat0,Math.sin(this.lat0));Math.abs(this.lat1-this.lat2)>ge?this.ns=Math.log(n/s)/Math.log(i/u):this.ns=t,isNaN(this.ns)&&(this.ns=t),this.f0=n/(this.ns*Math.pow(i,this.ns)),this.rh=this.a*this.f0*Math.pow(c,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function Ok(e){var t=e.x,r=e.y;Math.abs(2*Math.abs(r)-Math.PI)<=ge&&(r=Qs(r)*(fe-2*ge));var n=Math.abs(Math.abs(r)-fe),i,a;if(n>ge)i=Vr(this.e,r,Math.sin(r)),a=this.a*this.f0*Math.pow(i,this.ns);else{if(n=r*this.ns,n<=0)return null;a=0}var o=this.ns*be(t-this.long0);return e.x=this.k0*(a*Math.sin(o))+this.x0,e.y=this.k0*(this.rh-a*Math.cos(o))+this.y0,e}function Ik(e){var t,r,n,i,a,o=(e.x-this.x0)/this.k0,s=this.rh-(e.y-this.y0)/this.k0;this.ns>0?(t=Math.sqrt(o*o+s*s),r=1):(t=-Math.sqrt(o*o+s*s),r=-1);var u=0;if(t!==0&&(u=Math.atan2(r*o,r*s)),t!==0||this.ns>0){if(r=1/this.ns,n=Math.pow(t/(this.a*this.f0),r),i=Ds(this.e,n),i===-9999)return null}else i=-fe;return a=be(u/this.ns+this.long0),e.x=a,e.y=i,e}var Fk=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"];const $k={init:Lk,forward:Ok,inverse:Ik,names:Fk};function Bk(){this.a=6377397155e-3,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.7417649320975901-.308341501185665),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function zk(e){var t,r,n,i,a,o,s,u=e.x,c=e.y,d=be(u-this.long0);return t=Math.pow((1+this.e*Math.sin(c))/(1-this.e*Math.sin(c)),this.alfa*this.e/2),r=2*(Math.atan(this.k*Math.pow(Math.tan(c/2+this.s45),this.alfa)/t)-this.s45),n=-d*this.alfa,i=Math.asin(Math.cos(this.ad)*Math.sin(r)+Math.sin(this.ad)*Math.cos(r)*Math.cos(n)),a=Math.asin(Math.cos(r)*Math.sin(n)/Math.cos(i)),o=this.n*a,s=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(i/2+this.s45),this.n),e.y=s*Math.cos(o)/1,e.x=s*Math.sin(o)/1,this.czech||(e.y*=-1,e.x*=-1),e}function Hk(e){var t,r,n,i,a,o,s,u,c=e.x;e.x=e.y,e.y=c,this.czech||(e.y*=-1,e.x*=-1),o=Math.sqrt(e.x*e.x+e.y*e.y),a=Math.atan2(e.y,e.x),i=a/Math.sin(this.s0),n=2*(Math.atan(Math.pow(this.ro0/o,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),t=Math.asin(Math.cos(this.ad)*Math.sin(n)-Math.sin(this.ad)*Math.cos(n)*Math.cos(i)),r=Math.asin(Math.cos(n)*Math.sin(i)/Math.cos(t)),e.x=this.long0-r/this.alfa,s=t,u=0;var d=0;do e.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(t/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(s))/(1-this.e*Math.sin(s)),this.e/2))-this.s45),Math.abs(s-e.y)<1e-10&&(u=1),s=e.y,d+=1;while(u===0&&d<15);return d>=15?null:e}var Wk=["Krovak","krovak"];const jk={init:Bk,forward:zk,inverse:Hk,names:Wk};function sr(e,t,r,n,i){return e*i-t*Math.sin(2*i)+r*Math.sin(4*i)-n*Math.sin(6*i)}function Js(e){return 1-.25*e*(1+e/16*(3+1.25*e))}function el(e){return .375*e*(1+.25*e*(1+.46875*e))}function tl(e){return .05859375*e*e*(1+.75*e)}function rl(e){return e*e*e*(35/3072)}function Wa(e,t,r){var n=t*r;return e/Math.sqrt(1-n*n)}function no(e){return Math.abs(e)<fe?e:e-Qs(e)*Math.PI}function ic(e,t,r,n,i){var a,o;a=e/t;for(var s=0;s<15;s++)if(o=(e-(t*a-r*Math.sin(2*a)+n*Math.sin(4*a)-i*Math.sin(6*a)))/(t-2*r*Math.cos(2*a)+4*n*Math.cos(4*a)-6*i*Math.cos(6*a)),a+=o,Math.abs(o)<=1e-10)return a;return NaN}function Vk(){this.sphere||(this.e0=Js(this.es),this.e1=el(this.es),this.e2=tl(this.es),this.e3=rl(this.es),this.ml0=this.a*sr(this.e0,this.e1,this.e2,this.e3,this.lat0))}function Uk(e){var t,r,n=e.x,i=e.y;if(n=be(n-this.long0),this.sphere)t=this.a*Math.asin(Math.cos(i)*Math.sin(n)),r=this.a*(Math.atan2(Math.tan(i),Math.cos(n))-this.lat0);else{var a=Math.sin(i),o=Math.cos(i),s=Wa(this.a,this.e,a),u=Math.tan(i)*Math.tan(i),c=n*Math.cos(i),d=c*c,h=this.es*o*o/(1-this.es),p=this.a*sr(this.e0,this.e1,this.e2,this.e3,i);t=s*c*(1-d*u*(1/6-(8-u+8*h)*d/120)),r=p-this.ml0+s*a/o*d*(.5+(5-u+6*h)*d/24)}return e.x=t+this.x0,e.y=r+this.y0,e}function Gk(e){e.x-=this.x0,e.y-=this.y0;var t=e.x/this.a,r=e.y/this.a,n,i;if(this.sphere){var a=r+this.lat0;n=Math.asin(Math.sin(a)*Math.cos(t)),i=Math.atan2(Math.tan(t),Math.cos(a))}else{var o=this.ml0/this.a+r,s=ic(o,this.e0,this.e1,this.e2,this.e3);if(Math.abs(Math.abs(s)-fe)<=ge)return e.x=this.long0,e.y=fe,r<0&&(e.y*=-1),e;var u=Wa(this.a,this.e,Math.sin(s)),c=u*u*u/this.a/this.a*(1-this.es),d=Math.pow(Math.tan(s),2),h=t*this.a/u,p=h*h;n=s-u*Math.tan(s)/c*h*h*(.5-(1+3*d)*h*h/24),i=h*(1-p*(d/3+(1+3*d)*d*p/15))/Math.cos(s)}return e.x=be(i+this.long0),e.y=no(n),e}var qk=["Cassini","Cassini_Soldner","cass"];const Yk={init:Vk,forward:Uk,inverse:Gk,names:qk};function ei(e,t){var r;return e>1e-7?(r=e*t,(1-e*e)*(t/(1-r*r)-.5/e*Math.log((1-r)/(1+r)))):2*t}var Xk=1,Zk=2,Kk=3,Qk=4;function Jk(){var e=Math.abs(this.lat0);if(Math.abs(e-fe)<ge?this.mode=this.lat0<0?this.S_POLE:this.N_POLE:Math.abs(e)<ge?this.mode=this.EQUIT:this.mode=this.OBLIQ,this.es>0){var t;switch(this.qp=ei(this.e,1),this.mmf=.5/(1-this.es),this.apa=lL(this.es),this.mode){case this.N_POLE:this.dd=1;break;case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=ei(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(1-this.es*t*t)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd;break}}else this.mode===this.OBLIQ&&(this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function eL(e){var t,r,n,i,a,o,s,u,c,d,h=e.x,p=e.y;if(h=be(h-this.long0),this.sphere){if(a=Math.sin(p),d=Math.cos(p),n=Math.cos(h),this.mode===this.OBLIQ||this.mode===this.EQUIT){if(r=this.mode===this.EQUIT?1+d*n:1+this.sinph0*a+this.cosph0*d*n,r<=ge)return null;r=Math.sqrt(2/r),t=r*d*Math.sin(h),r*=this.mode===this.EQUIT?a:this.cosph0*a-this.sinph0*d*n}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(n=-n),Math.abs(p+this.lat0)<ge)return null;r=Xe-p*.5,r=2*(this.mode===this.S_POLE?Math.cos(r):Math.sin(r)),t=r*Math.sin(h),r*=n}}else{switch(s=0,u=0,c=0,n=Math.cos(h),i=Math.sin(h),a=Math.sin(p),o=ei(this.e,a),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(s=o/this.qp,u=Math.sqrt(1-s*s)),this.mode){case this.OBLIQ:c=1+this.sinb1*s+this.cosb1*u*n;break;case this.EQUIT:c=1+u*n;break;case this.N_POLE:c=fe+p,o=this.qp-o;break;case this.S_POLE:c=p-fe,o=this.qp+o;break}if(Math.abs(c)<ge)return null;switch(this.mode){case this.OBLIQ:case this.EQUIT:c=Math.sqrt(2/c),this.mode===this.OBLIQ?r=this.ymf*c*(this.cosb1*s-this.sinb1*u*n):r=(c=Math.sqrt(2/(1+u*n)))*s*this.ymf,t=this.xmf*c*u*i;break;case this.N_POLE:case this.S_POLE:o>=0?(t=(c=Math.sqrt(o))*i,r=n*(this.mode===this.S_POLE?c:-c)):t=r=0;break}}return e.x=this.a*t+this.x0,e.y=this.a*r+this.y0,e}function tL(e){e.x-=this.x0,e.y-=this.y0;var t=e.x/this.a,r=e.y/this.a,n,i,a,o,s,u,c;if(this.sphere){var d=0,h,p=0;if(h=Math.sqrt(t*t+r*r),i=h*.5,i>1)return null;switch(i=2*Math.asin(i),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(p=Math.sin(i),d=Math.cos(i)),this.mode){case this.EQUIT:i=Math.abs(h)<=ge?0:Math.asin(r*p/h),t*=p,r=d*h;break;case this.OBLIQ:i=Math.abs(h)<=ge?this.lat0:Math.asin(d*this.sinph0+r*p*this.cosph0/h),t*=p*this.cosph0,r=(d-Math.sin(i)*this.sinph0)*h;break;case this.N_POLE:r=-r,i=fe-i;break;case this.S_POLE:i-=fe;break}n=r===0&&(this.mode===this.EQUIT||this.mode===this.OBLIQ)?0:Math.atan2(t,r)}else{if(c=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(t/=this.dd,r*=this.dd,u=Math.sqrt(t*t+r*r),u<ge)return e.x=this.long0,e.y=this.lat0,e;o=2*Math.asin(.5*u/this.rq),a=Math.cos(o),t*=o=Math.sin(o),this.mode===this.OBLIQ?(c=a*this.sinb1+r*o*this.cosb1/u,s=this.qp*c,r=u*this.cosb1*a-r*this.sinb1*o):(c=r*o/u,s=this.qp*c,r=u*a)}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(r=-r),s=t*t+r*r,!s)return e.x=this.long0,e.y=this.lat0,e;c=1-s/this.qp,this.mode===this.S_POLE&&(c=-c)}n=Math.atan2(t,r),i=uL(Math.asin(c),this.apa)}return e.x=be(this.long0+n),e.y=i,e}var rL=.3333333333333333,nL=.17222222222222222,iL=.10257936507936508,aL=.06388888888888888,oL=.0664021164021164,sL=.016415012942191543;function lL(e){var t,r=[];return r[0]=e*rL,t=e*e,r[0]+=t*nL,r[1]=t*aL,t*=e,r[0]+=t*iL,r[1]+=t*oL,r[2]=t*sL,r}function uL(e,t){var r=e+e;return e+t[0]*Math.sin(r)+t[1]*Math.sin(r+r)+t[2]*Math.sin(r+r+r)}var cL=["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"];const dL={init:Jk,forward:eL,inverse:tL,names:cL,S_POLE:Xk,N_POLE:Zk,EQUIT:Kk,OBLIQ:Qk};function ii(e){return Math.abs(e)>1&&(e=e>1?1:-1),Math.asin(e)}function hL(){Math.abs(this.lat1+this.lat2)<ge||(this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e3=Math.sqrt(this.es),this.sin_po=Math.sin(this.lat1),this.cos_po=Math.cos(this.lat1),this.t1=this.sin_po,this.con=this.sin_po,this.ms1=pn(this.e3,this.sin_po,this.cos_po),this.qs1=ei(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat2),this.cos_po=Math.cos(this.lat2),this.t2=this.sin_po,this.ms2=pn(this.e3,this.sin_po,this.cos_po),this.qs2=ei(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat0),this.cos_po=Math.cos(this.lat0),this.t3=this.sin_po,this.qs0=ei(this.e3,this.sin_po),Math.abs(this.lat1-this.lat2)>ge?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function fL(e){var t=e.x,r=e.y;this.sin_phi=Math.sin(r),this.cos_phi=Math.cos(r);var n=ei(this.e3,this.sin_phi),i=this.a*Math.sqrt(this.c-this.ns0*n)/this.ns0,a=this.ns0*be(t-this.long0),o=i*Math.sin(a)+this.x0,s=this.rh-i*Math.cos(a)+this.y0;return e.x=o,e.y=s,e}function pL(e){var t,r,n,i,a,o;return e.x-=this.x0,e.y=this.rh-e.y+this.y0,this.ns0>=0?(t=Math.sqrt(e.x*e.x+e.y*e.y),n=1):(t=-Math.sqrt(e.x*e.x+e.y*e.y),n=-1),i=0,t!==0&&(i=Math.atan2(n*e.x,n*e.y)),n=t*this.ns0/this.a,this.sphere?o=Math.asin((this.c-n*n)/(2*this.ns0)):(r=(this.c-n*n)/this.ns0,o=this.phi1z(this.e3,r)),a=be(i/this.ns0+this.long0),e.x=a,e.y=o,e}function mL(e,t){var r,n,i,a,o,s=ii(.5*t);if(e<ge)return s;for(var u=e*e,c=1;c<=25;c++)if(r=Math.sin(s),n=Math.cos(s),i=e*r,a=1-i*i,o=.5*a*a/n*(t/(1-u)-r/a+.5/e*Math.log((1-i)/(1+i))),s=s+o,Math.abs(o)<=1e-7)return s;return null}var gL=["Albers_Conic_Equal_Area","Albers","aea"];const vL={init:hL,forward:fL,inverse:pL,names:gL,phi1z:mL};function yL(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0),this.infinity_dist=1e3*this.a,this.rc=1}function bL(e){var t,r,n,i,a,o,s,u,c=e.x,d=e.y;return n=be(c-this.long0),t=Math.sin(d),r=Math.cos(d),i=Math.cos(n),o=this.sin_p14*t+this.cos_p14*r*i,a=1,o>0||Math.abs(o)<=ge?(s=this.x0+this.a*a*r*Math.sin(n)/o,u=this.y0+this.a*a*(this.cos_p14*t-this.sin_p14*r*i)/o):(s=this.x0+this.infinity_dist*r*Math.sin(n),u=this.y0+this.infinity_dist*(this.cos_p14*t-this.sin_p14*r*i)),e.x=s,e.y=u,e}function _L(e){var t,r,n,i,a,o;return e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,e.x/=this.k0,e.y/=this.k0,(t=Math.sqrt(e.x*e.x+e.y*e.y))?(i=Math.atan2(t,this.rc),r=Math.sin(i),n=Math.cos(i),o=ii(n*this.sin_p14+e.y*r*this.cos_p14/t),a=Math.atan2(e.x*r,t*this.cos_p14*n-e.y*this.sin_p14*r),a=be(this.long0+a)):(o=this.phic0,a=0),e.x=a,e.y=o,e}var wL=["gnom"];const CL={init:yL,forward:bL,inverse:_L,names:wL};function xL(e,t){var r=1-(1-e*e)/(2*e)*Math.log((1-e)/(1+e));if(Math.abs(Math.abs(t)-r)<1e-6)return t<0?-1*fe:fe;for(var n=Math.asin(.5*t),i,a,o,s,u=0;u<30;u++)if(a=Math.sin(n),o=Math.cos(n),s=e*a,i=Math.pow(1-s*s,2)/(2*o)*(t/(1-e*e)-a/(1-s*s)+.5/e*Math.log((1-s)/(1+s))),n+=i,Math.abs(i)<=1e-10)return n;return NaN}function TL(){this.sphere||(this.k0=pn(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function SL(e){var t=e.x,r=e.y,n,i,a=be(t-this.long0);if(this.sphere)n=this.x0+this.a*a*Math.cos(this.lat_ts),i=this.y0+this.a*Math.sin(r)/Math.cos(this.lat_ts);else{var o=ei(this.e,Math.sin(r));n=this.x0+this.a*this.k0*a,i=this.y0+this.a*o*.5/this.k0}return e.x=n,e.y=i,e}function ML(e){e.x-=this.x0,e.y-=this.y0;var t,r;return this.sphere?(t=be(this.long0+e.x/this.a/Math.cos(this.lat_ts)),r=Math.asin(e.y/this.a*Math.cos(this.lat_ts))):(r=xL(this.e,2*e.y*this.k0/this.a),t=be(this.long0+e.x/(this.a*this.k0))),e.x=t,e.y=r,e}var PL=["cea"];const EL={init:TL,forward:SL,inverse:ML,names:PL};function AL(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=Math.cos(this.lat_ts)}function RL(e){var t=e.x,r=e.y,n=be(t-this.long0),i=no(r-this.lat0);return e.x=this.x0+this.a*n*this.rc,e.y=this.y0+this.a*i,e}function DL(e){var t=e.x,r=e.y;return e.x=be(this.long0+(t-this.x0)/(this.a*this.rc)),e.y=no(this.lat0+(r-this.y0)/this.a),e}var NL=["Equirectangular","Equidistant_Cylindrical","eqc"];const kL={init:AL,forward:RL,inverse:DL,names:NL};var Q1=20;function LL(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=Js(this.es),this.e1=el(this.es),this.e2=tl(this.es),this.e3=rl(this.es),this.ml0=this.a*sr(this.e0,this.e1,this.e2,this.e3,this.lat0)}function OL(e){var t=e.x,r=e.y,n,i,a,o=be(t-this.long0);if(a=o*Math.sin(r),this.sphere)Math.abs(r)<=ge?(n=this.a*o,i=-1*this.a*this.lat0):(n=this.a*Math.sin(a)/Math.tan(r),i=this.a*(no(r-this.lat0)+(1-Math.cos(a))/Math.tan(r)));else if(Math.abs(r)<=ge)n=this.a*o,i=-1*this.ml0;else{var s=Wa(this.a,this.e,Math.sin(r))/Math.tan(r);n=s*Math.sin(a),i=this.a*sr(this.e0,this.e1,this.e2,this.e3,r)-this.ml0+s*(1-Math.cos(a))}return e.x=n+this.x0,e.y=i+this.y0,e}function IL(e){var t,r,n,i,a,o,s,u,c;if(n=e.x-this.x0,i=e.y-this.y0,this.sphere)if(Math.abs(i+this.a*this.lat0)<=ge)t=be(n/this.a+this.long0),r=0;else{o=this.lat0+i/this.a,s=n*n/this.a/this.a+o*o,u=o;var d;for(a=Q1;a;--a)if(d=Math.tan(u),c=-1*(o*(u*d+1)-u-.5*(u*u+s)*d)/((u-o)/d-1),u+=c,Math.abs(c)<=ge){r=u;break}t=be(this.long0+Math.asin(n*Math.tan(u)/this.a)/Math.sin(r))}else if(Math.abs(i+this.ml0)<=ge)r=0,t=be(this.long0+n/this.a);else{o=(this.ml0+i)/this.a,s=n*n/this.a/this.a+o*o,u=o;var h,p,m,g,b;for(a=Q1;a;--a)if(b=this.e*Math.sin(u),h=Math.sqrt(1-b*b)*Math.tan(u),p=this.a*sr(this.e0,this.e1,this.e2,this.e3,u),m=this.e0-2*this.e1*Math.cos(2*u)+4*this.e2*Math.cos(4*u)-6*this.e3*Math.cos(6*u),g=p/this.a,c=(o*(h*g+1)-g-.5*h*(g*g+s))/(this.es*Math.sin(2*u)*(g*g+s-2*o*g)/(4*h)+(o-g)*(h*m-2/Math.sin(2*u))-m),u-=c,Math.abs(c)<=ge){r=u;break}h=Math.sqrt(1-this.es*Math.pow(Math.sin(r),2))*Math.tan(r),t=be(this.long0+Math.asin(n*h/this.a)/Math.sin(r))}return e.x=t,e.y=r,e}var FL=["Polyconic","poly"];const $L={init:LL,forward:OL,inverse:IL,names:FL};function BL(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013}function zL(e){var t,r=e.x,n=e.y,i=n-this.lat0,a=r-this.long0,o=i/us*1e-5,s=a,u=1,c=0;for(t=1;t<=10;t++)u=u*o,c=c+this.A[t]*u;var d=c,h=s,p=1,m=0,g,b,_=0,w=0;for(t=1;t<=6;t++)g=p*d-m*h,b=m*d+p*h,p=g,m=b,_=_+this.B_re[t]*p-this.B_im[t]*m,w=w+this.B_im[t]*p+this.B_re[t]*m;return e.x=w*this.a+this.x0,e.y=_*this.a+this.y0,e}function HL(e){var t,r=e.x,n=e.y,i=r-this.x0,a=n-this.y0,o=a/this.a,s=i/this.a,u=1,c=0,d,h,p=0,m=0;for(t=1;t<=6;t++)d=u*o-c*s,h=c*o+u*s,u=d,c=h,p=p+this.C_re[t]*u-this.C_im[t]*c,m=m+this.C_im[t]*u+this.C_re[t]*c;for(var g=0;g<this.iterations;g++){var b=p,_=m,w,C,S=o,T=s;for(t=2;t<=6;t++)w=b*p-_*m,C=_*p+b*m,b=w,_=C,S=S+(t-1)*(this.B_re[t]*b-this.B_im[t]*_),T=T+(t-1)*(this.B_im[t]*b+this.B_re[t]*_);b=1,_=0;var M=this.B_re[1],P=this.B_im[1];for(t=2;t<=6;t++)w=b*p-_*m,C=_*p+b*m,b=w,_=C,M=M+t*(this.B_re[t]*b-this.B_im[t]*_),P=P+t*(this.B_im[t]*b+this.B_re[t]*_);var R=M*M+P*P;p=(S*M+T*P)/R,m=(T*M-S*P)/R}var k=p,I=m,$=1,G=0;for(t=1;t<=9;t++)$=$*k,G=G+this.D[t]*$;var Y=this.lat0+G*us*1e5,B=this.long0+I;return e.x=B,e.y=Y,e}var WL=["New_Zealand_Map_Grid","nzmg"];const jL={init:BL,forward:zL,inverse:HL,names:WL};function VL(){}function UL(e){var t=e.x,r=e.y,n=be(t-this.long0),i=this.x0+this.a*n,a=this.y0+this.a*Math.log(Math.tan(Math.PI/4+r/2.5))*1.25;return e.x=i,e.y=a,e}function GL(e){e.x-=this.x0,e.y-=this.y0;var t=be(this.long0+e.x/this.a),r=2.5*(Math.atan(Math.exp(.8*e.y/this.a))-Math.PI/4);return e.x=t,e.y=r,e}var qL=["Miller_Cylindrical","mill"];const YL={init:VL,forward:UL,inverse:GL,names:qL};var XL=20;function ZL(){this.sphere?(this.n=1,this.m=0,this.es=0,this.C_y=Math.sqrt((this.m+1)/this.n),this.C_x=this.C_y/(this.m+1)):this.en=zC(this.es)}function KL(e){var t,r,n=e.x,i=e.y;if(n=be(n-this.long0),this.sphere){if(!this.m)i=this.n!==1?Math.asin(this.n*Math.sin(i)):i;else for(var a=this.n*Math.sin(i),o=XL;o;--o){var s=(this.m*i+Math.sin(i)-a)/(this.m+Math.cos(i));if(i-=s,Math.abs(s)<ge)break}t=this.a*this.C_x*n*(this.m+Math.cos(i)),r=this.a*this.C_y*i}else{var u=Math.sin(i),c=Math.cos(i);r=this.a*Xc(i,u,c,this.en),t=this.a*n*c/Math.sqrt(1-this.es*u*u)}return e.x=t,e.y=r,e}function QL(e){var t,r,n,i;return e.x-=this.x0,n=e.x/this.a,e.y-=this.y0,t=e.y/this.a,this.sphere?(t/=this.C_y,n=n/(this.C_x*(this.m+Math.cos(t))),this.m?t=ii((this.m*t+Math.sin(t))/this.n):this.n!==1&&(t=ii(Math.sin(t)/this.n)),n=be(n+this.long0),t=no(t)):(t=HC(e.y/this.a,this.es,this.en),i=Math.abs(t),i<fe?(i=Math.sin(t),r=this.long0+e.x*Math.sqrt(1-this.es*i*i)/(this.a*Math.cos(t)),n=be(r)):i-ge<fe&&(n=this.long0)),e.x=n,e.y=t,e}var JL=["Sinusoidal","sinu"];const eO={init:ZL,forward:KL,inverse:QL,names:JL};function tO(){}function rO(e){for(var t=e.x,r=e.y,n=be(t-this.long0),i=r,a=Math.PI*Math.sin(r);;){var o=-(i+Math.sin(i)-a)/(1+Math.cos(i));if(i+=o,Math.abs(o)<ge)break}i/=2,Math.PI/2-Math.abs(r)<ge&&(n=0);var s=.900316316158*this.a*n*Math.cos(i)+this.x0,u=1.4142135623731*this.a*Math.sin(i)+this.y0;return e.x=s,e.y=u,e}function nO(e){var t,r;e.x-=this.x0,e.y-=this.y0,r=e.y/(1.4142135623731*this.a),Math.abs(r)>.999999999999&&(r=.999999999999),t=Math.asin(r);var n=be(this.long0+e.x/(.900316316158*this.a*Math.cos(t)));n<-Math.PI&&(n=-Math.PI),n>Math.PI&&(n=Math.PI),r=(2*t+Math.sin(2*t))/Math.PI,Math.abs(r)>1&&(r=1);var i=Math.asin(r);return e.x=n,e.y=i,e}var iO=["Mollweide","moll"];const aO={init:tO,forward:rO,inverse:nO,names:iO};function oO(){Math.abs(this.lat1+this.lat2)<ge||(this.lat2=this.lat2||this.lat1,this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=Js(this.es),this.e1=el(this.es),this.e2=tl(this.es),this.e3=rl(this.es),this.sinphi=Math.sin(this.lat1),this.cosphi=Math.cos(this.lat1),this.ms1=pn(this.e,this.sinphi,this.cosphi),this.ml1=sr(this.e0,this.e1,this.e2,this.e3,this.lat1),Math.abs(this.lat1-this.lat2)<ge?this.ns=this.sinphi:(this.sinphi=Math.sin(this.lat2),this.cosphi=Math.cos(this.lat2),this.ms2=pn(this.e,this.sinphi,this.cosphi),this.ml2=sr(this.e0,this.e1,this.e2,this.e3,this.lat2),this.ns=(this.ms1-this.ms2)/(this.ml2-this.ml1)),this.g=this.ml1+this.ms1/this.ns,this.ml0=sr(this.e0,this.e1,this.e2,this.e3,this.lat0),this.rh=this.a*(this.g-this.ml0))}function sO(e){var t=e.x,r=e.y,n;if(this.sphere)n=this.a*(this.g-r);else{var i=sr(this.e0,this.e1,this.e2,this.e3,r);n=this.a*(this.g-i)}var a=this.ns*be(t-this.long0),o=this.x0+n*Math.sin(a),s=this.y0+this.rh-n*Math.cos(a);return e.x=o,e.y=s,e}function lO(e){e.x-=this.x0,e.y=this.rh-e.y+this.y0;var t,r,n,i;this.ns>=0?(r=Math.sqrt(e.x*e.x+e.y*e.y),t=1):(r=-Math.sqrt(e.x*e.x+e.y*e.y),t=-1);var a=0;if(r!==0&&(a=Math.atan2(t*e.x,t*e.y)),this.sphere)return i=be(this.long0+a/this.ns),n=no(this.g-r/this.a),e.x=i,e.y=n,e;var o=this.g-r/this.a;return n=ic(o,this.e0,this.e1,this.e2,this.e3),i=be(this.long0+a/this.ns),e.x=i,e.y=n,e}var uO=["Equidistant_Conic","eqdc"];const cO={init:oO,forward:sO,inverse:lO,names:uO};function dO(){this.R=this.a}function hO(e){var t=e.x,r=e.y,n=be(t-this.long0),i,a;Math.abs(r)<=ge&&(i=this.x0+this.R*n,a=this.y0);var o=ii(2*Math.abs(r/Math.PI));(Math.abs(n)<=ge||Math.abs(Math.abs(r)-fe)<=ge)&&(i=this.x0,r>=0?a=this.y0+Math.PI*this.R*Math.tan(.5*o):a=this.y0+Math.PI*this.R*-Math.tan(.5*o));var s=.5*Math.abs(Math.PI/n-n/Math.PI),u=s*s,c=Math.sin(o),d=Math.cos(o),h=d/(c+d-1),p=h*h,m=h*(2/c-1),g=m*m,b=Math.PI*this.R*(s*(h-g)+Math.sqrt(u*(h-g)*(h-g)-(g+u)*(p-g)))/(g+u);n<0&&(b=-b),i=this.x0+b;var _=u+h;return b=Math.PI*this.R*(m*_-s*Math.sqrt((g+u)*(u+1)-_*_))/(g+u),r>=0?a=this.y0+b:a=this.y0-b,e.x=i,e.y=a,e}function fO(e){var t,r,n,i,a,o,s,u,c,d,h,p,m;return e.x-=this.x0,e.y-=this.y0,h=Math.PI*this.R,n=e.x/h,i=e.y/h,a=n*n+i*i,o=-Math.abs(i)*(1+a),s=o-2*i*i+n*n,u=-2*o+1+2*i*i+a*a,m=i*i/u+(2*s*s*s/u/u/u-9*o*s/u/u)/27,c=(o-s*s/3/u)/u,d=2*Math.sqrt(-c/3),h=3*m/c/d,Math.abs(h)>1&&(h>=0?h=1:h=-1),p=Math.acos(h)/3,e.y>=0?r=(-d*Math.cos(p+Math.PI/3)-s/3/u)*Math.PI:r=-(-d*Math.cos(p+Math.PI/3)-s/3/u)*Math.PI,Math.abs(n)<ge?t=this.long0:t=be(this.long0+Math.PI*(a-1+Math.sqrt(1+2*(n*n-i*i)+a*a))/2/n),e.x=t,e.y=r,e}var pO=["Van_der_Grinten_I","VanDerGrinten","vandg"];const mO={init:dO,forward:hO,inverse:fO,names:pO};function gO(){this.sin_p12=Math.sin(this.lat0),this.cos_p12=Math.cos(this.lat0)}function vO(e){var t=e.x,r=e.y,n=Math.sin(e.y),i=Math.cos(e.y),a=be(t-this.long0),o,s,u,c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k,I,$,G,Y;return this.sphere?Math.abs(this.sin_p12-1)<=ge?(e.x=this.x0+this.a*(fe-r)*Math.sin(a),e.y=this.y0-this.a*(fe-r)*Math.cos(a),e):Math.abs(this.sin_p12+1)<=ge?(e.x=this.x0+this.a*(fe+r)*Math.sin(a),e.y=this.y0+this.a*(fe+r)*Math.cos(a),e):(R=this.sin_p12*n+this.cos_p12*i*Math.cos(a),M=Math.acos(R),P=M?M/Math.sin(M):1,e.x=this.x0+this.a*P*i*Math.sin(a),e.y=this.y0+this.a*P*(this.cos_p12*n-this.sin_p12*i*Math.cos(a)),e):(o=Js(this.es),s=el(this.es),u=tl(this.es),c=rl(this.es),Math.abs(this.sin_p12-1)<=ge?(d=this.a*sr(o,s,u,c,fe),h=this.a*sr(o,s,u,c,r),e.x=this.x0+(d-h)*Math.sin(a),e.y=this.y0-(d-h)*Math.cos(a),e):Math.abs(this.sin_p12+1)<=ge?(d=this.a*sr(o,s,u,c,fe),h=this.a*sr(o,s,u,c,r),e.x=this.x0+(d+h)*Math.sin(a),e.y=this.y0+(d+h)*Math.cos(a),e):(p=n/i,m=Wa(this.a,this.e,this.sin_p12),g=Wa(this.a,this.e,n),b=Math.atan((1-this.es)*p+this.es*m*this.sin_p12/(g*i)),_=Math.atan2(Math.sin(a),this.cos_p12*Math.tan(b)-this.sin_p12*Math.cos(a)),_===0?k=Math.asin(this.cos_p12*Math.sin(b)-this.sin_p12*Math.cos(b)):Math.abs(Math.abs(_)-Math.PI)<=ge?k=-Math.asin(this.cos_p12*Math.sin(b)-this.sin_p12*Math.cos(b)):k=Math.asin(Math.sin(a)*Math.cos(b)/Math.sin(_)),w=this.e*this.sin_p12/Math.sqrt(1-this.es),C=this.e*this.cos_p12*Math.cos(_)/Math.sqrt(1-this.es),S=w*C,T=C*C,I=k*k,$=I*k,G=$*k,Y=G*k,M=m*k*(1-I*T*(1-T)/6+$/8*S*(1-2*T)+G/120*(T*(4-7*T)-3*w*w*(1-7*T))-Y/48*S),e.x=this.x0+M*Math.sin(_),e.y=this.y0+M*Math.cos(_),e))}function yO(e){e.x-=this.x0,e.y-=this.y0;var t,r,n,i,a,o,s,u,c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k;return this.sphere?(t=Math.sqrt(e.x*e.x+e.y*e.y),t>2*fe*this.a?void 0:(r=t/this.a,n=Math.sin(r),i=Math.cos(r),a=this.long0,Math.abs(t)<=ge?o=this.lat0:(o=ii(i*this.sin_p12+e.y*n*this.cos_p12/t),s=Math.abs(this.lat0)-fe,Math.abs(s)<=ge?this.lat0>=0?a=be(this.long0+Math.atan2(e.x,-e.y)):a=be(this.long0-Math.atan2(-e.x,e.y)):a=be(this.long0+Math.atan2(e.x*n,t*this.cos_p12*i-e.y*this.sin_p12*n))),e.x=a,e.y=o,e)):(u=Js(this.es),c=el(this.es),d=tl(this.es),h=rl(this.es),Math.abs(this.sin_p12-1)<=ge?(p=this.a*sr(u,c,d,h,fe),t=Math.sqrt(e.x*e.x+e.y*e.y),m=p-t,o=ic(m/this.a,u,c,d,h),a=be(this.long0+Math.atan2(e.x,-1*e.y)),e.x=a,e.y=o,e):Math.abs(this.sin_p12+1)<=ge?(p=this.a*sr(u,c,d,h,fe),t=Math.sqrt(e.x*e.x+e.y*e.y),m=t-p,o=ic(m/this.a,u,c,d,h),a=be(this.long0+Math.atan2(e.x,e.y)),e.x=a,e.y=o,e):(t=Math.sqrt(e.x*e.x+e.y*e.y),_=Math.atan2(e.x,e.y),g=Wa(this.a,this.e,this.sin_p12),w=Math.cos(_),C=this.e*this.cos_p12*w,S=-C*C/(1-this.es),T=3*this.es*(1-S)*this.sin_p12*this.cos_p12*w/(1-this.es),M=t/g,P=M-S*(1+S)*Math.pow(M,3)/6-T*(1+3*S)*Math.pow(M,4)/24,R=1-S*P*P/2-M*P*P*P/6,b=Math.asin(this.sin_p12*Math.cos(P)+this.cos_p12*Math.sin(P)*w),a=be(this.long0+Math.asin(Math.sin(_)*Math.sin(P)/Math.cos(b))),k=Math.sin(b),o=Math.atan2((k-this.es*R*this.sin_p12)*Math.tan(b),k*(1-this.es)),e.x=a,e.y=o,e))}var bO=["Azimuthal_Equidistant","aeqd"];const _O={init:gO,forward:vO,inverse:yO,names:bO};function wO(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function CO(e){var t,r,n,i,a,o,s,u,c=e.x,d=e.y;return n=be(c-this.long0),t=Math.sin(d),r=Math.cos(d),i=Math.cos(n),o=this.sin_p14*t+this.cos_p14*r*i,a=1,(o>0||Math.abs(o)<=ge)&&(s=this.a*a*r*Math.sin(n),u=this.y0+this.a*a*(this.cos_p14*t-this.sin_p14*r*i)),e.x=s,e.y=u,e}function xO(e){var t,r,n,i,a,o,s;return e.x-=this.x0,e.y-=this.y0,t=Math.sqrt(e.x*e.x+e.y*e.y),r=ii(t/this.a),n=Math.sin(r),i=Math.cos(r),o=this.long0,Math.abs(t)<=ge?(s=this.lat0,e.x=o,e.y=s,e):(s=ii(i*this.sin_p14+e.y*n*this.cos_p14/t),a=Math.abs(this.lat0)-fe,Math.abs(a)<=ge?(this.lat0>=0?o=be(this.long0+Math.atan2(e.x,-e.y)):o=be(this.long0-Math.atan2(-e.x,e.y)),e.x=o,e.y=s,e):(o=be(this.long0+Math.atan2(e.x*n,t*this.cos_p14*i-e.y*this.sin_p14*n)),e.x=o,e.y=s,e))}var TO=["ortho"];const SO={init:wO,forward:CO,inverse:xO,names:TO};var ct={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},Ze={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4};function MO(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.lat0>=fe-Xe/2?this.face=ct.TOP:this.lat0<=-(fe-Xe/2)?this.face=ct.BOTTOM:Math.abs(this.long0)<=Xe?this.face=ct.FRONT:Math.abs(this.long0)<=fe+Xe?this.face=this.long0>0?ct.RIGHT:ct.LEFT:this.face=ct.BACK,this.es!==0&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)}function PO(e){var t={x:0,y:0},r,n,i,a,o,s,u={value:0};if(e.x-=this.long0,this.es!==0?r=Math.atan(this.one_minus_f_squared*Math.tan(e.y)):r=e.y,n=e.x,this.face===ct.TOP)a=fe-r,n>=Xe&&n<=fe+Xe?(u.value=Ze.AREA_0,i=n-fe):n>fe+Xe||n<=-(fe+Xe)?(u.value=Ze.AREA_1,i=n>0?n-vt:n+vt):n>-(fe+Xe)&&n<=-Xe?(u.value=Ze.AREA_2,i=n+fe):(u.value=Ze.AREA_3,i=n);else if(this.face===ct.BOTTOM)a=fe+r,n>=Xe&&n<=fe+Xe?(u.value=Ze.AREA_0,i=-n+fe):n<Xe&&n>=-Xe?(u.value=Ze.AREA_1,i=-n):n<-Xe&&n>=-(fe+Xe)?(u.value=Ze.AREA_2,i=-n-fe):(u.value=Ze.AREA_3,i=n>0?-n+vt:-n-vt);else{var c,d,h,p,m,g,b;this.face===ct.RIGHT?n=Fa(n,+fe):this.face===ct.BACK?n=Fa(n,+vt):this.face===ct.LEFT&&(n=Fa(n,-fe)),p=Math.sin(r),m=Math.cos(r),g=Math.sin(n),b=Math.cos(n),c=m*b,d=m*g,h=p,this.face===ct.FRONT?(a=Math.acos(c),i=nu(a,h,d,u)):this.face===ct.RIGHT?(a=Math.acos(d),i=nu(a,h,-c,u)):this.face===ct.BACK?(a=Math.acos(-c),i=nu(a,h,-d,u)):this.face===ct.LEFT?(a=Math.acos(-d),i=nu(a,h,c,u)):(a=i=0,u.value=Ze.AREA_0)}return s=Math.atan(12/vt*(i+Math.acos(Math.sin(i)*Math.cos(Xe))-fe)),o=Math.sqrt((1-Math.cos(a))/(Math.cos(s)*Math.cos(s))/(1-Math.cos(Math.atan(1/Math.cos(i))))),u.value===Ze.AREA_1?s+=fe:u.value===Ze.AREA_2?s+=vt:u.value===Ze.AREA_3&&(s+=1.5*vt),t.x=o*Math.cos(s),t.y=o*Math.sin(s),t.x=t.x*this.a+this.x0,t.y=t.y*this.a+this.y0,e.x=t.x,e.y=t.y,e}function EO(e){var t={lam:0,phi:0},r,n,i,a,o,s,u,c,d,h={value:0};if(e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a,n=Math.atan(Math.sqrt(e.x*e.x+e.y*e.y)),r=Math.atan2(e.y,e.x),e.x>=0&&e.x>=Math.abs(e.y)?h.value=Ze.AREA_0:e.y>=0&&e.y>=Math.abs(e.x)?(h.value=Ze.AREA_1,r-=fe):e.x<0&&-e.x>=Math.abs(e.y)?(h.value=Ze.AREA_2,r=r<0?r+vt:r-vt):(h.value=Ze.AREA_3,r+=fe),d=vt/12*Math.tan(r),o=Math.sin(d)/(Math.cos(d)-1/Math.sqrt(2)),s=Math.atan(o),i=Math.cos(r),a=Math.tan(n),u=1-i*i*a*a*(1-Math.cos(Math.atan(1/Math.cos(s)))),u<-1?u=-1:u>1&&(u=1),this.face===ct.TOP)c=Math.acos(u),t.phi=fe-c,h.value===Ze.AREA_0?t.lam=s+fe:h.value===Ze.AREA_1?t.lam=s<0?s+vt:s-vt:h.value===Ze.AREA_2?t.lam=s-fe:t.lam=s;else if(this.face===ct.BOTTOM)c=Math.acos(u),t.phi=c-fe,h.value===Ze.AREA_0?t.lam=-s+fe:h.value===Ze.AREA_1?t.lam=-s:h.value===Ze.AREA_2?t.lam=-s-fe:t.lam=s<0?-s-vt:-s+vt;else{var p,m,g;p=u,d=p*p,d>=1?g=0:g=Math.sqrt(1-d)*Math.sin(s),d+=g*g,d>=1?m=0:m=Math.sqrt(1-d),h.value===Ze.AREA_1?(d=m,m=-g,g=d):h.value===Ze.AREA_2?(m=-m,g=-g):h.value===Ze.AREA_3&&(d=m,m=g,g=-d),this.face===ct.RIGHT?(d=p,p=-m,m=d):this.face===ct.BACK?(p=-p,m=-m):this.face===ct.LEFT&&(d=p,p=m,m=-d),t.phi=Math.acos(-g)-fe,t.lam=Math.atan2(m,p),this.face===ct.RIGHT?t.lam=Fa(t.lam,-fe):this.face===ct.BACK?t.lam=Fa(t.lam,-vt):this.face===ct.LEFT&&(t.lam=Fa(t.lam,+fe))}if(this.es!==0){var b,_,w;b=t.phi<0?1:0,_=Math.tan(t.phi),w=this.b/Math.sqrt(_*_+this.one_minus_f_squared),t.phi=Math.atan(Math.sqrt(this.a*this.a-w*w)/(this.one_minus_f*w)),b&&(t.phi=-t.phi)}return t.lam+=this.long0,e.x=t.lam,e.y=t.phi,e}function nu(e,t,r,n){var i;return e<ge?(n.value=Ze.AREA_0,i=0):(i=Math.atan2(t,r),Math.abs(i)<=Xe?n.value=Ze.AREA_0:i>Xe&&i<=fe+Xe?(n.value=Ze.AREA_1,i-=fe):i>fe+Xe||i<=-(fe+Xe)?(n.value=Ze.AREA_2,i=i>=0?i-vt:i+vt):(n.value=Ze.AREA_3,i+=fe)),i}function Fa(e,t){var r=e+t;return r<-vt?r+=As:r>+vt&&(r-=As),r}var AO=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"];const RO={init:MO,forward:PO,inverse:EO,names:AO};var Kf=[[1,22199e-21,-715515e-10,31103e-10],[.9986,-482243e-9,-24897e-9,-13309e-10],[.9954,-83103e-8,-448605e-10,-986701e-12],[.99,-.00135364,-59661e-9,36777e-10],[.9822,-.00167442,-449547e-11,-572411e-11],[.973,-.00214868,-903571e-10,18736e-12],[.96,-.00305085,-900761e-10,164917e-11],[.9427,-.00382792,-653386e-10,-26154e-10],[.9216,-.00467746,-10457e-8,481243e-11],[.8962,-.00536223,-323831e-10,-543432e-11],[.8679,-.00609363,-113898e-9,332484e-11],[.835,-.00698325,-640253e-10,934959e-12],[.7986,-.00755338,-500009e-10,935324e-12],[.7597,-.00798324,-35971e-9,-227626e-11],[.7186,-.00851367,-701149e-10,-86303e-10],[.6732,-.00986209,-199569e-9,191974e-10],[.6213,-.010418,883923e-10,624051e-11],[.5722,-.00906601,182e-6,624051e-11],[.5322,-.00677797,275608e-9,624051e-11]],ns=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-126793e-14,422642e-15],[.124,.0124,507171e-14,-160604e-14],[.186,.0123999,-190189e-13,600152e-14],[.248,.0124002,710039e-13,-224e-10],[.31,.0123992,-264997e-12,835986e-13],[.372,.0124029,988983e-12,-311994e-12],[.434,.0123893,-369093e-11,-435621e-12],[.4958,.0123198,-102252e-10,-345523e-12],[.5571,.0121916,-154081e-10,-582288e-12],[.6176,.0119938,-241424e-10,-525327e-12],[.6769,.011713,-320223e-10,-516405e-12],[.7346,.0113541,-397684e-10,-609052e-12],[.7903,.0109107,-489042e-10,-104739e-11],[.8435,.0103431,-64615e-9,-140374e-14],[.8936,.00969686,-64636e-9,-8547e-9],[.9394,.00840947,-192841e-9,-42106e-10],[.9761,.00616527,-256e-6,-42106e-10],[1,.00328947,-319159e-9,-42106e-10]],VC=.8487,UC=1.3523,GC=ln/5,DO=1/GC,Aa=18,ac=function(e,t){return e[0]+t*(e[1]+t*(e[2]+t*e[3]))},NO=function(e,t){return e[1]+t*(2*e[2]+t*3*e[3])};function kO(e,t,r,n){for(var i=t;n;--n){var a=e(i);if(i-=a,Math.abs(a)<r)break}return i}function LO(){this.x0=this.x0||0,this.y0=this.y0||0,this.long0=this.long0||0,this.es=0,this.title=this.title||"Robinson"}function OO(e){var t=be(e.x-this.long0),r=Math.abs(e.y),n=Math.floor(r*GC);n<0?n=0:n>=Aa&&(n=Aa-1),r=ln*(r-DO*n);var i={x:ac(Kf[n],r)*t,y:ac(ns[n],r)};return e.y<0&&(i.y=-i.y),i.x=i.x*this.a*VC+this.x0,i.y=i.y*this.a*UC+this.y0,i}function IO(e){var t={x:(e.x-this.x0)/(this.a*VC),y:Math.abs(e.y-this.y0)/(this.a*UC)};if(t.y>=1)t.x/=Kf[Aa][0],t.y=e.y<0?-fe:fe;else{var r=Math.floor(t.y*Aa);for(r<0?r=0:r>=Aa&&(r=Aa-1);;)if(ns[r][0]>t.y)--r;else if(ns[r+1][0]<=t.y)++r;else break;var n=ns[r],i=5*(t.y-n[0])/(ns[r+1][0]-n[0]);i=kO(function(a){return(ac(n,a)-t.y)/NO(n,a)},i,ge,100),t.x/=ac(Kf[r],i),t.y=(5*r+i)*Ht,e.y<0&&(t.y=-t.y)}return t.x=be(t.x+this.long0),t}var FO=["Robinson","robin"];const $O={init:LO,forward:OO,inverse:IO,names:FO};function BO(){this.name="geocent"}function zO(e){var t=DC(e,this.es,this.a);return t}function HO(e){var t=NC(e,this.es,this.a,this.b);return t}var WO=["Geocentric","geocentric","geocent","Geocent"];const jO={init:BO,forward:zO,inverse:HO,names:WO};var Xt={N_POLE:0,S_POLE:1,EQUIT:2,OBLIQ:3},zo={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};function VO(){if(Object.keys(zo).forEach(function(r){if(typeof this[r]=="undefined")this[r]=zo[r].def;else{if(zo[r].num&&isNaN(this[r]))throw new Error("Invalid parameter value, must be numeric "+r+" = "+this[r]);zo[r].num&&(this[r]=parseFloat(this[r]))}zo[r].degrees&&(this[r]=this[r]*Ht)}.bind(this)),Math.abs(Math.abs(this.lat0)-fe)<ge?this.mode=this.lat0<0?Xt.S_POLE:Xt.N_POLE:Math.abs(this.lat0)<ge?this.mode=Xt.EQUIT:(this.mode=Xt.OBLIQ,this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0)),this.pn1=this.h/this.a,this.pn1<=0||this.pn1>1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var e=this.tilt,t=this.azi;this.cg=Math.cos(t),this.sg=Math.sin(t),this.cw=Math.cos(e),this.sw=Math.sin(e)}function UO(e){e.x-=this.long0;var t=Math.sin(e.y),r=Math.cos(e.y),n=Math.cos(e.x),i,a;switch(this.mode){case Xt.OBLIQ:a=this.sinph0*t+this.cosph0*r*n;break;case Xt.EQUIT:a=r*n;break;case Xt.S_POLE:a=-t;break;case Xt.N_POLE:a=t;break}switch(a=this.pn1/(this.p-a),i=a*r*Math.sin(e.x),this.mode){case Xt.OBLIQ:a*=this.cosph0*t-this.sinph0*r*n;break;case Xt.EQUIT:a*=t;break;case Xt.N_POLE:a*=-(r*n);break;case Xt.S_POLE:a*=r*n;break}var o,s;return o=a*this.cg+i*this.sg,s=1/(o*this.sw*this.h1+this.cw),i=(i*this.cg-a*this.sg)*this.cw*s,a=o*s,e.x=i*this.a,e.y=a*this.a,e}function GO(e){e.x/=this.a,e.y/=this.a;var t={x:e.x,y:e.y},r,n,i;i=1/(this.pn1-e.y*this.sw),r=this.pn1*e.x*i,n=this.pn1*e.y*this.cw*i,e.x=r*this.cg+n*this.sg,e.y=n*this.cg-r*this.sg;var a=kr(e.x,e.y);if(Math.abs(a)<ge)t.x=0,t.y=e.y;else{var o,s;switch(s=1-a*a*this.pfact,s=(this.p-Math.sqrt(s))/(this.pn1/a+a/this.pn1),o=Math.sqrt(1-s*s),this.mode){case Xt.OBLIQ:t.y=Math.asin(o*this.sinph0+e.y*s*this.cosph0/a),e.y=(o-this.sinph0*Math.sin(t.y))*a,e.x*=s*this.cosph0;break;case Xt.EQUIT:t.y=Math.asin(e.y*s/a),e.y=o*a,e.x*=s;break;case Xt.N_POLE:t.y=Math.asin(o),e.y=-e.y;break;case Xt.S_POLE:t.y=-Math.asin(o);break}t.x=Math.atan2(e.x,e.y)}return e.x=t.x+this.long0,e.y=t.y,e}var qO=["Tilted_Perspective","tpers"];const YO={init:VO,forward:UO,inverse:GO,names:qO};function XO(){if(this.flip_axis=this.sweep==="x"?1:0,this.h=Number(this.h),this.radius_g_1=this.h/this.a,this.radius_g_1<=0||this.radius_g_1>1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,this.es!==0){var e=1-this.es,t=1/e;this.radius_p=Math.sqrt(e),this.radius_p2=e,this.radius_p_inv2=t,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")}function ZO(e){var t=e.x,r=e.y,n,i,a,o;if(t=t-this.long0,this.shape==="ellipse"){r=Math.atan(this.radius_p2*Math.tan(r));var s=this.radius_p/kr(this.radius_p*Math.cos(r),Math.sin(r));if(i=s*Math.cos(t)*Math.cos(r),a=s*Math.sin(t)*Math.cos(r),o=s*Math.sin(r),(this.radius_g-i)*i-a*a-o*o*this.radius_p_inv2<0)return e.x=Number.NaN,e.y=Number.NaN,e;n=this.radius_g-i,this.flip_axis?(e.x=this.radius_g_1*Math.atan(a/kr(o,n)),e.y=this.radius_g_1*Math.atan(o/n)):(e.x=this.radius_g_1*Math.atan(a/n),e.y=this.radius_g_1*Math.atan(o/kr(a,n)))}else this.shape==="sphere"&&(n=Math.cos(r),i=Math.cos(t)*n,a=Math.sin(t)*n,o=Math.sin(r),n=this.radius_g-i,this.flip_axis?(e.x=this.radius_g_1*Math.atan(a/kr(o,n)),e.y=this.radius_g_1*Math.atan(o/n)):(e.x=this.radius_g_1*Math.atan(a/n),e.y=this.radius_g_1*Math.atan(o/kr(a,n))));return e.x=e.x*this.a,e.y=e.y*this.a,e}function KO(e){var t=-1,r=0,n=0,i,a,o,s;if(e.x=e.x/this.a,e.y=e.y/this.a,this.shape==="ellipse"){this.flip_axis?(n=Math.tan(e.y/this.radius_g_1),r=Math.tan(e.x/this.radius_g_1)*kr(1,n)):(r=Math.tan(e.x/this.radius_g_1),n=Math.tan(e.y/this.radius_g_1)*kr(1,r));var u=n/this.radius_p;if(i=r*r+u*u+t*t,a=2*this.radius_g*t,o=a*a-4*i*this.C,o<0)return e.x=Number.NaN,e.y=Number.NaN,e;s=(-a-Math.sqrt(o))/(2*i),t=this.radius_g+s*t,r*=s,n*=s,e.x=Math.atan2(r,t),e.y=Math.atan(n*Math.cos(e.x)/t),e.y=Math.atan(this.radius_p_inv2*Math.tan(e.y))}else if(this.shape==="sphere"){if(this.flip_axis?(n=Math.tan(e.y/this.radius_g_1),r=Math.tan(e.x/this.radius_g_1)*Math.sqrt(1+n*n)):(r=Math.tan(e.x/this.radius_g_1),n=Math.tan(e.y/this.radius_g_1)*Math.sqrt(1+r*r)),i=r*r+n*n+t*t,a=2*this.radius_g*t,o=a*a-4*i*this.C,o<0)return e.x=Number.NaN,e.y=Number.NaN,e;s=(-a-Math.sqrt(o))/(2*i),t=this.radius_g+s*t,r*=s,n*=s,e.x=Math.atan2(r,t),e.y=Math.atan(n*Math.cos(e.x)/t)}return e.x=e.x+this.long0,e}var QO=["Geostationary Satellite View","Geostationary_Satellite","geos"];const JO={init:XO,forward:ZO,inverse:KO,names:QO};var cs=1.340264,ds=-.081106,hs=893e-6,fs=.003796,oc=Math.sqrt(3)/2;function e7(){this.es=0,this.long0=this.long0!==void 0?this.long0:0}function t7(e){var t=be(e.x-this.long0),r=e.y,n=Math.asin(oc*Math.sin(r)),i=n*n,a=i*i*i;return e.x=t*Math.cos(n)/(oc*(cs+3*ds*i+a*(7*hs+9*fs*i))),e.y=n*(cs+ds*i+a*(hs+fs*i)),e.x=this.a*e.x+this.x0,e.y=this.a*e.y+this.y0,e}function r7(e){e.x=(e.x-this.x0)/this.a,e.y=(e.y-this.y0)/this.a;var t=1e-9,r=12,n=e.y,i,a,o,s,u,c;for(c=0;c<r&&(i=n*n,a=i*i*i,o=n*(cs+ds*i+a*(hs+fs*i))-e.y,s=cs+3*ds*i+a*(7*hs+9*fs*i),n-=u=o/s,!(Math.abs(u)<t));++c);return i=n*n,a=i*i*i,e.x=oc*e.x*(cs+3*ds*i+a*(7*hs+9*fs*i))/Math.cos(n),e.y=Math.asin(Math.sin(n)/oc),e.x=be(e.x+this.long0),e}var n7=["eqearth","Equal Earth","Equal_Earth"];const i7={init:e7,forward:t7,inverse:r7,names:n7};function a7(e){e.Proj.projections.add(Nu),e.Proj.projections.add(ku),e.Proj.projections.add(ok),e.Proj.projections.add(gk),e.Proj.projections.add(Ck),e.Proj.projections.add(Pk),e.Proj.projections.add(kk),e.Proj.projections.add($k),e.Proj.projections.add(jk),e.Proj.projections.add(Yk),e.Proj.projections.add(dL),e.Proj.projections.add(vL),e.Proj.projections.add(CL),e.Proj.projections.add(EL),e.Proj.projections.add(kL),e.Proj.projections.add($L),e.Proj.projections.add(jL),e.Proj.projections.add(YL),e.Proj.projections.add(eO),e.Proj.projections.add(aO),e.Proj.projections.add(cO),e.Proj.projections.add(mO),e.Proj.projections.add(_O),e.Proj.projections.add(SO),e.Proj.projections.add(RO),e.Proj.projections.add($O),e.Proj.projections.add(jO),e.Proj.projections.add(YO),e.Proj.projections.add(JO),e.Proj.projections.add(i7)}Cr.defaultDatum="WGS84";Cr.Proj=dn;Cr.WGS84=new Cr.Proj("WGS84");Cr.Point=Ha;Cr.toPoint=kC;Cr.defs=ir;Cr.nadgrid=l8;Cr.transform=nc;Cr.mgrs=T8;Cr.version="__VERSION__";a7(Cr);const o7=Object.freeze(Object.defineProperty({__proto__:null,default:Cr},Symbol.toStringTag,{value:"Module"})),s7=O.getAugmentedNamespace(o7);(function(e){(function(t){var r,n;r=CC,n=s7,e.exports=t(r,n)})(function(t,r){return r.__esModule&&r.default&&(r=r.default),t.Proj={},t.Proj._isProj4Obj=function(n){return typeof n.inverse!="undefined"&&typeof n.forward!="undefined"},t.Proj.Projection=t.Class.extend({initialize:function(n,i,a){var o=t.Proj._isProj4Obj(n);this._proj=o?n:this._projFromCodeDef(n,i),this.bounds=o?i:a},project:function(n){var i=this._proj.forward([n.lng,n.lat]);return new t.Point(i[0],i[1])},unproject:function(n,i){var a=this._proj.inverse([n.x,n.y]);return new t.LatLng(a[1],a[0],i)},_projFromCodeDef:function(n,i){if(i)r.defs(n,i);else if(r.defs[n]===void 0){var a=n.split(":");if(a.length>3&&(n=a[a.length-3]+":"+a[a.length-1]),r.defs[n]===void 0)throw"No projection definition for code "+n}return r(n)}}),t.Proj.CRS=t.Class.extend({includes:t.CRS,options:{transformation:new t.Transformation(1,0,-1,0)},initialize:function(n,i,a){var o,s,u,c;if(t.Proj._isProj4Obj(n)?(s=n,o=s.srsCode,c=i||{},this.projection=new t.Proj.Projection(s,c.bounds)):(o=n,u=i,c=a||{},this.projection=new t.Proj.Projection(o,u,c.bounds)),t.Util.setOptions(this,c),this.code=o,this.transformation=this.options.transformation,this.options.origin&&(this.transformation=new t.Transformation(1,-this.options.origin[0],-1,this.options.origin[1])),this.options.scales)this._scales=this.options.scales;else if(this.options.resolutions){this._scales=[];for(var d=this.options.resolutions.length-1;d>=0;d--)this.options.resolutions[d]&&(this._scales[d]=1/this.options.resolutions[d])}this.infinite=!this.options.bounds},scale:function(n){var i=Math.floor(n),a,o,s,u;return n===i?this._scales[n]:(a=this._scales[i],o=this._scales[i+1],s=o-a,u=n-i,a+s*u)},zoom:function(n){var i=this._closestElement(this._scales,n),a=this._scales.indexOf(i),o,s,u;return n===i?a:i===void 0?-1/0:(s=a+1,o=this._scales[s],o===void 0?1/0:(u=o-i,(n-i)/u+a))},distance:t.CRS.Earth.distance,R:t.CRS.Earth.R,_closestElement:function(n,i){for(var a,o=n.length;o--;)n[o]<=i&&(a===void 0||a<n[o])&&(a=n[o]);return a}}),t.Proj.GeoJSON=t.GeoJSON.extend({initialize:function(n,i){this._callLevel=0,t.GeoJSON.prototype.initialize.call(this,n,i)},addData:function(n){var i;n&&(n.crs&&n.crs.type==="name"?i=new t.Proj.CRS(n.crs.properties.name):n.crs&&n.crs.type&&(i=new t.Proj.CRS(n.crs.type+":"+n.crs.properties.code)),i!==void 0&&(this.options.coordsToLatLng=function(a){var o=t.point(a[0],a[1]);return i.projection.unproject(o)})),this._callLevel++;try{t.GeoJSON.prototype.addData.call(this,n)}finally{this._callLevel--,this._callLevel===0&&delete this.options.coordsToLatLng}}}),t.Proj.geoJson=function(n,i){return new t.Proj.GeoJSON(n,i)},t.Proj.ImageOverlay=t.ImageOverlay.extend({initialize:function(n,i,a){t.ImageOverlay.prototype.initialize.call(this,n,null,a),this._projectedBounds=i},_animateZoom:function(n){var i=this._map.getZoomScale(n.zoom),a=t.point(this._projectedBounds.min.x,this._projectedBounds.max.y),o=this._projectedToNewLayerPoint(a,n.zoom,n.center);t.DomUtil.setTransform(this._image,o,i)},_reset:function(){var n=this._map.getZoom(),i=this._map.getPixelOrigin(),a=t.bounds(this._transform(this._projectedBounds.min,n)._subtract(i),this._transform(this._projectedBounds.max,n)._subtract(i)),o=a.getSize();t.DomUtil.setPosition(this._image,a.min),this._image.style.width=o.x+"px",this._image.style.height=o.y+"px"},_projectedToNewLayerPoint:function(n,i,a){var o=this._map.getSize()._divideBy(2),s=this._map.project(a,i)._subtract(o)._round(),u=s.add(this._map._getMapPanePos());return this._transform(n,i)._subtract(u)},_transform:function(n,i){var a=this._map.options.crs,o=a.transformation,s=a.scale(i);return o.transform(n,s)}}),t.Proj.imageOverlay=function(n,i,a){return new t.Proj.ImageOverlay(n,i,a)},t.Proj})})(xC);var l7=xC.exports;const u7=250;function qC(e){const t=e.chart.animation.init.duration==="auto"?u7:e.chart.animation.init.duration;return{animate:t!==0,duration:t/1e3}}function c7(e,t,r={}){t.length&&e.fitBounds(t.map(n=>[n.getLatLng().lat,n.getLatLng().lng]),D({maxZoom:4},r))}const d7=[{officialName:"Afghanistan",allNames:["af","afġānistān","afghanistan","afg"],id:"AFG"},{id:"ALA",officialName:"Åland Islands",allNames:["ax","ala","åland islands","aland islands"]},{officialName:"Albania",allNames:["al","shqipëri","shqipëria","shqipnia","albania","alb"],id:"ALB"},{officialName:"Algeria",allNames:["dz","dzayer","algérie","algeria","dza"],id:"DZA"},{officialName:"American Samoa",allNames:["as","amerika sāmoa","amelika sāmoa","sāmoa amelika","american samoa","asm"],id:"ASM"},{id:"AND",officialName:"Andorra",allNames:["ad","and","andorra"]},{officialName:"Angola",allNames:["ao","república de angola","ʁɛpublika de an'ɡɔla","angola","ago"],id:"AGO"},{officialName:"Anguilla",allNames:["ai","anguilla","aia"],id:"AIA"},{id:"ATA",officialName:"Antarctica",allNames:["aq","ata","antarctica"]},{officialName:"Antigua and Barbuda",allNames:["ag","antigua and barbuda","atg"],id:"ATG"},{officialName:"Argentina",allNames:["ar","argentine republic","república argentina","argentina","arg"],id:"ARG"},{officialName:"Armenia",allNames:["am","hayastan","republic of armenia","հայաստանի հանրապետություն","armenia","arm"],id:"ARM"},{officialName:"Aruba",allNames:["aw","aruba","abw"],id:"ABW"},{officialName:"Australia",allNames:["au","australia","aus"],id:"AUS"},{officialName:"Austria",allNames:["at","österreich","osterreich","oesterreich","austria","aut"],id:"AUT"},{officialName:"Azerbaijan",allNames:["az","republic of azerbaijan","azərbaycan respublikası","azerbaijan","aze","azerbaijan republic"],id:"AZE"},{officialName:"Bahrain",allNames:["bh","kingdom of bahrain","mamlakat al-baḥrayn","bahrain","bhr"],id:"BHR"},{officialName:"Bangladesh",allNames:["bd","people's republic of bangladesh","gônôprôjatôntri bangladesh","bangladesh","bgd"],id:"BGD"},{officialName:"Barbados",allNames:["bb","barbados","brb"],id:"BRB"},{officialName:"Belarus",allNames:["by","bielaruś","republic of belarus","белоруссия","республика беларусь","belorussiya","respublika belarus’","belarus","blr"],id:"BLR"},{officialName:"Belgium",allNames:["be","belgië","belgie","belgien","belgique","kingdom of belgium","koninkrijk belgië","royaume de belgique","königreich belgien","belgium","bel"],id:"BEL"},{officialName:"Belize",allNames:["bz","belize","blz"],id:"BLZ"},{officialName:"Benin",allNames:["bj","republic of benin","république du bénin","benin","ben"],id:"BEN"},{officialName:"Bermuda",allNames:["bm","the islands ofbermuda","the bermudas","somers isles","bermuda","bmu"],id:"BMU"},{officialName:"Bhutan",allNames:["bt","kingdom of bhutan","bhutan","btn"],id:"BTN"},{officialName:"Bolivia",allNames:["bo","buliwya","wuliwya","plurinational state of bolivia","estado plurinacional de bolivia","buliwya mamallaqta","wuliwya suyu","tetã volívia","bolivia","bol","plurinational state of"],id:"BOL"},{id:"BES",officialName:"Bonaire",allNames:["bq","bes","bonaire","sint eustatius and saba","caribbean netherlands"]},{officialName:"Bosnia and Herzegovina",allNames:["ba","bosnia-herzegovina","босна и херцеговина","bosnia and herzegovina","bih"],id:"BIH"},{officialName:"Botswana",allNames:["bw","republic of botswana","lefatshe la botswana","botswana","bwa"],id:"BWA"},{id:"BVT",officialName:"Bouvet Island",allNames:["bv","bvt","bouvet island"]},{officialName:"Brazil",allNames:["br","brasil","federative republic of brazil","república federativa do brasil","brazil","bra"],id:"BRA"},{officialName:"British Indian Ocean Territory",allNames:["io","british indian ocean territory","iot"],id:"IOT"},{officialName:"Brunei",allNames:["bn","nation of brunei","the abode of peace","brunei","brn","brunei darussalam"],id:"BRN"},{officialName:"Bulgaria",allNames:["bg","republic of bulgaria","република българия","bulgaria","bgr"],id:"BGR"},{officialName:"Burkina Faso",allNames:["bf","burkina faso","bfa"],id:"BFA"},{officialName:"Burundi",allNames:["bi","republic of burundi","republika y'uburundi","république du burundi","burundi","bdi"],id:"BDI"},{officialName:"Cambodia",allNames:["kh","kingdom of cambodia","cambodia","khm"],id:"KHM"},{officialName:"Cameroon",allNames:["cm","republic of cameroon","république du cameroun","cameroon","cmr"],id:"CMR"},{officialName:"Canada",allNames:["ca","canada","can"],id:"CAN"},{officialName:"Cape Verde",allNames:["cv","republic of cabo verde","república de cabo verde","cape verde","cpv"],id:"CPV"},{officialName:"Cayman Islands",allNames:["ky","cayman islands","cym"],id:"CYM"},{officialName:"Central African Republic",allNames:["cf","central african republic","république centrafricaine","central african republic","caf"],id:"CAF"},{officialName:"Chad",allNames:["td","tchad","republic of chad","république du tchad","chad","tcd"],id:"TCD"},{officialName:"Chile",allNames:["cl","republic of chile","república de chile","chile","chl"],id:"CHL"},{officialName:"China",allNames:["cn","zhōngguó","zhongguo","zhonghua","people's republic of china","中华人民共和国","zhōnghuá rénmín gònghéguó","china","chn"],id:"CHN"},{officialName:"Christmas Island",allNames:["cx","territory of christmas island","christmas island","cxr"],id:"CXR"},{officialName:"Cocos (Keeling) Islands",allNames:["cc","territoryof the cocos (keeling) islands","keeling islands","cocos (keeling) islands","cck","cocos islands","cocos [keeling] islands"],id:"CCK"},{officialName:"Colombia",allNames:["co","republic of colombia","república de colombia","colombia","col"],id:"COL"},{officialName:"Comoros",allNames:["km","union of the comoros","union des comores","udzima wa komori","al-ittiḥād al-qumurī","comoros","com"],id:"COM"},{officialName:"Cook Islands",allNames:["ck","kūki 'āirani","cook islands","cok"],id:"COK"},{officialName:"Costa Rica",allNames:["cr","republic of costa rica","república de costa rica","costa rica","cri"],id:"CRI"},{officialName:"Croatia",allNames:["hr","hrvatska","republic of croatia","republika hrvatska","croatia","hrv","croatia, republic of","croatia democratic republic of the"],id:"HRV"},{officialName:"Cuba",allNames:["cu","republic of cuba","república de cuba","cuba","cub"],id:"CUB"},{id:"CUW",officialName:"Curaçao",allNames:["cw","cuw","curaçao","curacao"]},{officialName:"Cyprus",allNames:["cy","kýpros","kıbrıs","republic of cyprus","κυπριακή δημοκρατία","kıbrıs cumhuriyeti","cyprus","cyp"],id:"CYP"},{officialName:"Czech Republic",allNames:["cz","česká republika","česko","czech republic","cze"],id:"CZE"},{officialName:"Democratic Republic of the Congo",allNames:["cd","dr congo","congo-kinshasa","drc","democratic republic of the congo","cod","congo (kinshasa)","the democratic republic of the congo","congo, the democratic republic of the","congo [drc]","congo, dem. rep."],id:"COD"},{officialName:"Denmark",allNames:["dk","danmark","kingdom of denmark","kongeriget danmark","denmark","dnk"],id:"DNK"},{officialName:"Djibouti",allNames:["dj","jabuuti","gabuuti","republic of djibouti","république de djibouti","gabuutih ummuuno","jamhuuriyadda jabuuti","djibouti","dji"],id:"DJI"},{officialName:"Dominica",allNames:["dm","dominique","wai‘tu kubuli","commonwealth of dominica","dominica","dma"],id:"DMA"},{officialName:"Dominican Republic",allNames:["do","dominican republic","dom"],id:"DOM"},{officialName:"East Timor",allNames:["tl","east timor","democratic republic of timor-leste","república democrática de timor-leste","repúblika demokrátika timór-leste","east timor","tls","timor-leste"],id:"TLS"},{officialName:"Ecuador",allNames:["ec","republic of ecuador","república del ecuador","ecuador","ecu"],id:"ECU"},{officialName:"Egypt",allNames:["eg","arab republic of egypt","egypt","egy"],id:"EGY"},{officialName:"El Salvador",allNames:["sv","republic of el salvador","república de el salvador","el salvador","slv"],id:"SLV"},{officialName:"Equatorial Guinea",allNames:["gq","republic of equatorial guinea","república de guinea ecuatorial","république de guinée équatoriale","república da guiné equatorial","equatorial guinea","gnq"],id:"GNQ"},{officialName:"Eritrea",allNames:["er","state of eritrea","ሃገረ ኤርትራ","dawlatiritriyá","ʾertrā","iritriyā","eritrea","eri"],id:"ERI"},{officialName:"Estonia",allNames:["ee","eesti","republic of estonia","eesti vabariik","estonia","est"],id:"EST"},{officialName:"Ethiopia",allNames:["et","ʾītyōṗṗyā","federal democratic republic of ethiopia","የኢትዮጵያ ፌዴራላዊ ዲሞክራሲያዊ ሪፐብሊክ","ethiopia","eth"],id:"ETH"},{officialName:"Falkland Islands",allNames:["fk","islas malvinas","falkland islands","flk","falkland islands (malvinas)","falkland islands (islas malvinas)","falkland islands [malvinas]","falkland islands [islas malvinas]"],id:"FLK"},{officialName:"Faroe Islands",allNames:["fo","føroyar","færøerne","faroe islands","fro"],id:"FRO"},{officialName:"Federated States of Micronesia",allNames:["fm","federated states of micronesia","federated states of micronesia","fsm","micronesia","federated states of"],id:"FSM"},{officialName:"Fiji",allNames:["fj","viti","republic of fiji","matanitu ko viti","fijī gaṇarājya","fiji","fji"],id:"FJI"},{officialName:"Finland",allNames:["fi","suomi","republic of finland","suomen tasavalta","republiken finland","finland","fin"],id:"FIN"},{officialName:"France",allNames:["fr","french republic","république française","france","fra"],id:"FRA"},{officialName:"French Guiana",allNames:["gf","guiana","guyane","french guiana","guf"],id:"GUF"},{officialName:"French Polynesia",allNames:["pf","polynésie française","french polynesia","pōrīnetia farāni","french polynesia","pyf"],id:"PYF"},{officialName:"French Southern and Antarctic Lands",allNames:["tf","french southern andantarctic lands","atf","french southern territories"],id:"ATF"},{officialName:"Gabon",allNames:["ga","gabonese republic","république gabonaise","gabon","gab","gabon republic"],id:"GAB"},{officialName:"Georgia",allNames:["ge","sakartvelo","georgia","geo"],id:"GEO"},{officialName:"Germany",allNames:["de","federal republic of germany","bundesrepublik deutschland","germany","deu"],id:"DEU"},{officialName:"Ghana",allNames:["gh","ghana","gha"],id:"GHA"},{officialName:"Gibraltar",allNames:["gi","gibraltar","gib"],id:"GIB"},{officialName:"Greece",allNames:["gr","elláda","hellenic republic","ελληνική δημοκρατία","greece","grc"],id:"GRC"},{officialName:"Greenland",allNames:["gl","grønland","greenland","grl"],id:"GRL"},{officialName:"Grenada",allNames:["gd","grenada","grd"],id:"GRD"},{officialName:"Guadeloupe",allNames:["gp","gwadloup","guadeloupe","glp"],id:"GLP"},{officialName:"Guam",allNames:["gu","guåhån","guam","gum"],id:"GUM"},{officialName:"Guatemala",allNames:["gt","guatemala","gtm"],id:"GTM"},{officialName:"Guernsey",allNames:["gg","bailiwick of guernsey","bailliage de guernesey","guernsey","ggy"],id:"GGY"},{officialName:"Guinea",allNames:["gn","republic of guinea","république de guinée","guinea","gin"],id:"GIN"},{officialName:"Guinea-Bissau",allNames:["gw","republic of guinea-bissau","república da guiné-bissau","guinea-bissau","gnb"],id:"GNB"},{officialName:"Guyana",allNames:["gy","co-operative republic of guyana","guyana","guy"],id:"GUY"},{officialName:"Haiti",allNames:["ht","republic of haiti","république d'haïti","repiblik ayiti","haiti","hti"],id:"HTI"},{officialName:"Heard Island and McDonald Islands",allNames:["hm","heard island and mcdonald islands","hmd","heard and mcdonald islands"],id:"HMD"},{officialName:"Honduras",allNames:["hn","republic of honduras","república de honduras","honduras","hnd"],id:"HND"},{officialName:"Hong Kong",allNames:["hk","香港","hongkong","hkg","hong kong","hong kong, china"],id:"HKG"},{officialName:"Hungary",allNames:["hu","hungary","hun"],id:"HUN"},{officialName:"Iceland",allNames:["is","island","republic of iceland","lýðveldið ísland","iceland","isl"],id:"ISL"},{officialName:"India",allNames:["in","bhārat","republic of india","bharat ganrajya","india","ind"],id:"IND"},{officialName:"Indonesia",allNames:["id","republic of indonesia","republik indonesia","indonesia","idn"],id:"IDN"},{officialName:"Iran",allNames:["ir","islamic republic of iran","jomhuri-ye eslāmi-ye irān","iran","irn","islamic republic of"],id:"IRN"},{officialName:"Iraq",allNames:["iq","republic of iraq","jumhūriyyat al-‘irāq","iraq","irq"],id:"IRQ"},{officialName:"Ireland",allNames:["ie","éire","republic of ireland","poblacht na héireann","ireland","irl"],id:"IRL"},{officialName:"Isle of Man",allNames:["im","ellan vannin","mann","mannin","isle of man","imn"],id:"IMN"},{officialName:"Israel",allNames:["il","state of israel","medīnat yisrā'el","israel","isr"],id:"ISR"},{officialName:"Italy",allNames:["it","italian republic","repubblica italiana","italy","ita"],id:"ITA"},{officialName:"Ivory Coast",allNames:["ci","ivory coast","republic of côte d'ivoire","république de côte d'ivoire","ivory coast","civ","côte d'ivoire","cote d'ivoire","cote divoire","cã´te d'ivoire","cote d'lvoire"],id:"CIV"},{officialName:"Jamaica",allNames:["jm","jamaica","jam"],id:"JAM"},{officialName:"Japan",allNames:["jp","nippon","nihon","japan","jpn"],id:"JPN"},{officialName:"Jersey",allNames:["je","bailiwick of jersey","bailliage de jersey","bailliage dé jèrri","jersey","jey"],id:"JEY"},{officialName:"Jordan",allNames:["jo","hashemite kingdomof jordan","al-mamlakah al-urdunīyah al-hāshimīyah","jordan","jor"],id:"JOR"},{officialName:"Kazakhstan",allNames:["kz","qazaqstan","казахстан","republic of kazakhstan","қазақстан республикасы","qazaqstan respublïkası","республика казахстан","respublika kazakhstan","kazakhstan","kaz"],id:"KAZ"},{officialName:"Kenya",allNames:["ke","republic of kenya","jamhuri ya kenya","kenya","ken"],id:"KEN"},{officialName:"Kiribati",allNames:["ki","republic of kiribati","ribaberiki kiribati","kiribati","kir"],id:"KIR"},{officialName:"Kuwait",allNames:["kw","state of kuwait","dawlat al-kuwait","kuwait","kwt"],id:"KWT"},{officialName:"Kyrgyzstan",allNames:["kg","киргизия","kyrgyz republic","кыргыз республикасы","kyrgyz respublikasy","kyrgyzstan","kgz"],id:"KGZ"},{officialName:"Laos",allNames:["la","lao","lao people's democratic republic","sathalanalat paxathipatai paxaxon lao","laos","lao"],id:"LAO"},{officialName:"Latvia",allNames:["lv","republic of latvia","latvijas republika","latvia","lva"],id:"LVA"},{officialName:"Lebanon",allNames:["lb","lebanese republic","al-jumhūrīyah al-libnānīyah","lebanon","lbn"],id:"LBN"},{officialName:"Lesotho",allNames:["ls","kingdom of lesotho","muso oa lesotho","lesotho","lso"],id:"LSO"},{officialName:"Liberia",allNames:["lr","republic of liberia","liberia","lbr"],id:"LBR"},{officialName:"Libya",allNames:["ly","state of libya","dawlat libya","libya","lby"],id:"LBY"},{officialName:"Liechtenstein",allNames:["li","principality of liechtenstein","fürstentum liechtenstein","liechtenstein","lie"],id:"LIE"},{officialName:"Lithuania",allNames:["lt","republic of lithuania","lietuvos respublika","lithuania","ltu"],id:"LTU"},{officialName:"Luxembourg",allNames:["lu","grand duchy of luxembourg","grand-duché de luxembourg","großherzogtum luxemburg","groussherzogtum lëtzebuerg","luxembourg","lux"],id:"LUX"},{officialName:"Macau",allNames:["mo","澳门","macao special administrative region of the people's republic of china","中華人民共和國澳門特別行政區","região administrativa especial de macau da república popular da china","macau","mac","macao","macao, china","macau, china"],id:"MAC"},{officialName:"Madagascar",allNames:["mg","republic of madagascar","repoblikan'i madagasikara","république de madagascar","madagascar","mdg"],id:"MDG"},{officialName:"Malawi",allNames:["mw","republic of malawi","malawi","mwi"],id:"MWI"},{officialName:"Malaysia",allNames:["my","malaysia","mys"],id:"MYS"},{officialName:"Maldives",allNames:["mv","maldive islands","republic of the maldives","dhivehi raajjeyge jumhooriyya","maldives","mdv"],id:"MDV"},{officialName:"Mali",allNames:["ml","republic of mali","république du mali","mali","mli"],id:"MLI"},{officialName:"Malta",allNames:["mt","republic of malta","repubblika ta' malta","malta","mlt"],id:"MLT"},{officialName:"Marshall Islands",allNames:["mh","republic of the marshall islands","aolepān aorōkin m̧ajeļ","marshall islands","mhl"],id:"MHL"},{officialName:"Martinique",allNames:["mq","martinique","mtq"],id:"MTQ"},{officialName:"Mauritania",allNames:["mr","islamic republic of mauritania","al-jumhūriyyah al-ʾislāmiyyah al-mūrītāniyyah","mauritania","mrt"],id:"MRT"},{officialName:"Mauritius",allNames:["mu","republic of mauritius","république de maurice","mauritius","mus"],id:"MUS"},{officialName:"Mayotte",allNames:["yt","department of mayotte","département de mayotte","mayotte","myt"],id:"MYT"},{officialName:"Mexico",allNames:["mx","mexicanos","united mexican states","estados unidos mexicanos","mexico","mex"],id:"MEX"},{officialName:"Moldova",allNames:["md","republic of moldova","republica moldova","moldova","mda","republic of"],id:"MDA"},{officialName:"Monaco",allNames:["mc","principality of monaco","principauté de monaco","monaco","mco"],id:"MCO"},{officialName:"Mongolia",allNames:["mn","mongolia","mng"],id:"MNG"},{id:"MNE",officialName:"Montenegro",allNames:["me","mne","montenegro"]},{officialName:"Montserrat",allNames:["ms","montserrat","msr"],id:"MSR"},{officialName:"Morocco",allNames:["ma","kingdom of morocco","al-mamlakah al-maġribiyah","morocco","mar","morroco"],id:"MAR"},{officialName:"Mozambique",allNames:["mz","republic of mozambique","república de moçambique","mozambique","moz"],id:"MOZ"},{id:"MMR",officialName:"Myanmar",allNames:["mm","mmr","myanmar","myanmar (burma)","myanmar [burma]","burma"]},{officialName:"Namibia",allNames:["na","namibië","republic of namibia","namibia","nam"],id:"NAM"},{officialName:"Nauru",allNames:["nr","naoero","pleasant island","republic of nauru","ripublik naoero","nauru","nru"],id:"NRU"},{officialName:"Nepal",allNames:["np","federal democratic republic of nepal","loktāntrik ganatantra nepāl","nepal","npl"],id:"NPL"},{officialName:"Netherlands",allNames:["nl","holland","nederland","netherlands","nld","the netherlands"],id:"NLD"},{officialName:"New Caledonia",allNames:["nc","new caledonia","ncl"],id:"NCL"},{officialName:"New Zealand",allNames:["nz","aotearoa","new zealand","nzl"],id:"NZL"},{officialName:"Nicaragua",allNames:["ni","republic of nicaragua","república de nicaragua","nicaragua","nic"],id:"NIC"},{officialName:"Niger",allNames:["ne","nijar","republic of niger","république du niger","niger","ner"],id:"NER"},{officialName:"Nigeria",allNames:["ng","nijeriya","naíjíríà","federal republic of nigeria","nigeria","nga"],id:"NGA"},{officialName:"Niue",allNames:["nu","niue","niu"],id:"NIU"},{officialName:"Norfolk Island",allNames:["nf","territory of norfolk island","teratri of norf'k ailen","norfolk island","nfk"],id:"NFK"},{officialName:"North Korea",allNames:["kp","democratic people's republic of korea","조선민주주의인민공화국","chosŏn minjujuŭi inmin konghwaguk","north korea","prk","korea, democratic people's republic of","korea, north"],id:"PRK"},{officialName:"Northern Mariana Islands",allNames:["mp","commonwealth of the northern mariana islands","sankattan siha na islas mariånas","northern mariana islands","mnp"],id:"MNP"},{officialName:"Norway",allNames:["no","norge","noreg","kingdom of norway","kongeriket norge","kongeriket noreg","norway","nor"],id:"NOR"},{officialName:"Oman",allNames:["om","sultanate of oman","salṭanat ʻumān","oman","omn"],id:"OMN"},{officialName:"Pakistan",allNames:["pk","pākistān","islamic republic of pakistan","islāmī jumhūriya'eh pākistān","pakistan","pak"],id:"PAK"},{officialName:"Palau",allNames:["pw","republic of palau","beluuer a belau","palau","plw"],id:"PLW"},{id:"PSE",officialName:"Palestinian Authority",allNames:["ps","pse","palestinian authority","palestinian territory"]},{officialName:"Panama",allNames:["pa","republic of panama","república de panamá","panama","pan"],id:"PAN"},{officialName:"Papua New Guinea",allNames:["pg","independent state of papua new guinea","independen stet bilong papua niugini","papua new guinea","png"],id:"PNG"},{officialName:"Paraguay",allNames:["py","republic of paraguay","república del paraguay","tetã paraguái","paraguay","pry"],id:"PRY"},{officialName:"Peru",allNames:["pe","republic of peru","república del perú","peru","per"],id:"PER"},{officialName:"Philippines",allNames:["ph","republic of the philippines","repúblika ng pilipinas","philippines","phl"],id:"PHL"},{officialName:"Pitcairn Islands",allNames:["pn","pitcairn henderson ducie and oeno islands","pitcairn islands","pcn","pitcairn"],id:"PCN"},{officialName:"Poland",allNames:["pl","republic of poland","rzeczpospolita polska","poland","pol"],id:"POL"},{officialName:"Portugal",allNames:["pt","portuguesa","portuguese republic","república portuguesa","portugal","prt"],id:"PRT"},{officialName:"Puerto Rico",allNames:["pr","commonwealth of puerto rico","estado libre asociado de puerto rico","puerto rico","pri"],id:"PRI"},{officialName:"Qatar",allNames:["qa","state of qatar","dawlat qaṭar","qatar","qat"],id:"QAT"},{officialName:"Republic of Macedonia",allNames:["mk","republic of macedonia","република македонија","republic of macedonia","mkd","macedonia","macedonia (fyrom)","macedonia [fyrom]","the former yugoslav republic of","the former yugoslav republic of macedonia"],id:"MKD"},{officialName:"Republic of the Congo",allNames:["cg","congo-brazzaville","republic of the congo","cog","congo (brazzaville)","congo [republic]","congo","congo, rep."],id:"COG"},{officialName:"Réunion",allNames:["re","reunion","réunion","reu","rã©union"],id:"REU"},{officialName:"Romania",allNames:["ro","rumania","roumania","românia","romania","rou"],id:"ROU"},{officialName:"Russia",allNames:["ru","rossiya","russian federation","российская федерация","rossiyskaya federatsiya","russia","rus"],id:"RUS"},{officialName:"Rwanda",allNames:["rw","republic of rwanda","repubulika y'u rwanda","république du rwanda","rwanda","rwa"],id:"RWA"},{id:"BLM",officialName:"Saint Barthélemy",allNames:["bl","blm","saint barthélemy","saint barthelemy","st barthelemy"]},{officialName:"Saint Helena",allNames:["sh","saint helena","shn","st helena","ascension and tristan da cunha"],id:"SHN"},{officialName:"Saint Kitts and Nevis",allNames:["kn","federation of saint christopher and nevis","saint kitts and nevis","kna","st kitts and nevis","saint kitts-nevis","st kitts-nevis"],id:"KNA"},{officialName:"Saint Lucia",allNames:["lc","saint lucia","lca","st lucia"],id:"LCA"},{officialName:"Saint Pierre and Miquelon",allNames:["pm","collectivité territoriale de saint-pierre-et-miquelon","saint pierre andmiquelon","spm","st pierre and miquelon","saint pierre and miquelon","st. pierre and miquelon"],id:"SPM"},{officialName:"Saint Vincent and the Grenadines",allNames:["vc","saint vincent and the grenadines","vct","st vincent and the grenadines"],id:"VCT"},{officialName:"Samoa",allNames:["ws","independent state of samoa","malo saʻoloto tutoʻatasi o sāmoa","samoa","wsm","western samoa"],id:"WSM"},{officialName:"San Marino",allNames:["sm","republic of san marino","repubblica di san marino","san marino","smr"],id:"SMR"},{officialName:"São Tomé and Príncipe",allNames:["st","democratic republic of são tomé and príncipe","república democrática de são tomé e príncipe","são tomé and príncipe","stp","sao tome and principe","sã£o tomã© and prã­ncipe"],id:"STP"},{officialName:"Saudi Arabia",allNames:["sa","kingdom of saudi arabia","al-mamlakah al-‘arabiyyah as-su‘ūdiyyah","saudi arabia","sau"],id:"SAU"},{officialName:"Senegal",allNames:["sn","republic of senegal","république du sénégal","senegal","sen"],id:"SEN"},{id:"SRB",officialName:"Serbia",allNames:["rs","srb","serbia"]},{officialName:"Seychelles",allNames:["sc","republic of seychelles","repiblik sesel","république des seychelles","seychelles","syc"],id:"SYC"},{officialName:"Sierra Leone",allNames:["sl","republic of sierra leone","sierra leone","sle"],id:"SLE"},{officialName:"Singapore",allNames:["sg","singapura","republik singapura","新加坡共和国","singapore","sgp"],id:"SGP"},{officialName:"Slovakia",allNames:["sk","slovak republic","slovenská republika","slovakia","svk","slovakia (slovak republic)"],id:"SVK"},{officialName:"Slovenia",allNames:["si","republic of slovenia","republika slovenija","slovenia","svn"],id:"SVN"},{officialName:"Solomon Islands",allNames:["sb","solomon islands","slb"],id:"SLB"},{officialName:"Somalia",allNames:["so","aṣ-ṣūmāl","federal republic of somalia","jamhuuriyadda federaalka soomaaliya","jumhūriyyat aṣ-ṣūmāl al-fiderāliyya","somalia","som"],id:"SOM"},{officialName:"South Africa",allNames:["za","rsa","suid-afrika","republic of south africa","south africa","zaf"],id:"ZAF"},{officialName:"South Georgia",allNames:["gs","south georgia and the south sandwich islands","south georgia","sgs"],id:"SGS"},{officialName:"South Korea",allNames:["kr","republic of korea","south korea","kor","korea, republic of","korea, south"],id:"KOR"},{officialName:"South Sudan",allNames:["ss","south sudan","ssd"],id:"SSD"},{officialName:"Spain",allNames:["es","kingdom of spain","reino deespaña","spain","esp"],id:"ESP"},{officialName:"Sri Lanka",allNames:["lk","ilaṅkai","democraticsocialist republic of sri lanka","sri lanka","lka"],id:"LKA"},{id:"SXM",officialName:"St Maarten",allNames:["sx","sxm","st maarten","sint maarten","sint maarten (dutch part)","saint-martin (pays-bas)"]},{id:"MAF",officialName:"St Martin (French part)",allNames:["mf","maf","st martin (french part)","saint martin (french part)","saint-martin (france)"]},{officialName:"Sudan",allNames:["sd","republic of the sudan","jumhūrīyat as-sūdān","sudan","sdn"],id:"SDN"},{officialName:"Suriname",allNames:["sr","sarnam","sranangron","republic of suriname","republiek suriname","suriname","sur"],id:"SUR"},{officialName:"Svalbard and Jan Mayen",allNames:["sj","svalbard and jan mayen islands","svalbard and jan mayen","sjm"],id:"SJM"},{officialName:"Swaziland",allNames:["sz","weswatini","swatini","ngwane","kingdom of swaziland","umbuso waseswatini","swaziland","swz"],id:"SWZ"},{officialName:"Sweden",allNames:["se","kingdom of sweden","konungariket sverige","sweden","swe"],id:"SWE"},{officialName:"Switzerland",allNames:["ch","swiss confederation","schweiz","suisse","svizzera","svizra","switzerland","che"],id:"CHE"},{officialName:"Syria",allNames:["sy","syrian arab republic","al-jumhūrīyah al-ʻarabīyah as-sūrīyah","syria","syr"],id:"SYR"},{officialName:"Taiwan",allNames:["tw","táiwān","republic of china","中華民國","zhōnghuá mínguó","taiwan","twn","taiwan, province of china"],id:"TWN"},{officialName:"Tajikistan",allNames:["tj","toçikiston","republic of tajikistan","ҷумҳурии тоҷикистон","çumhuriyi toçikiston","tajikistan","tjk"],id:"TJK"},{officialName:"Tanzania",allNames:["tz","united republic of tanzania","jamhuri ya muungano wa tanzania","tanzania","tza","united republic of"],id:"TZA"},{officialName:"Thailand",allNames:["th","prathet","thai","kingdom of thailand","ราชอาณาจักรไทย","ratcha anachak thai","thailand","tha"],id:"THA"},{officialName:"The Bahamas",allNames:["bs","commonwealth of the bahamas","the bahamas","bhs","bahamas"],id:"BHS"},{officialName:"The Gambia",allNames:["gm","republic of the gambia","the gambia","gmb","gambia"],id:"GMB"},{officialName:"Togo",allNames:["tg","togolese","togolese republic","république togolaise","togo","tgo"],id:"TGO"},{officialName:"Tokelau",allNames:["tk","tokelau","tkl"],id:"TKL"},{officialName:"Tonga",allNames:["to","tonga","ton"],id:"TON"},{officialName:"Trinidad and Tobago",allNames:["tt","republic of trinidad and tobago","trinidad and tobago","tto"],id:"TTO"},{officialName:"Tunisia",allNames:["tn","republic of tunisia","al-jumhūriyyah at-tūnisiyyah","tunisia","tun"],id:"TUN"},{officialName:"Turkey",allNames:["tr","turkiye","republic of turkey","türkiye cumhuriyeti","turkey","tur"],id:"TUR"},{officialName:"Turkmenistan",allNames:["tm","turkmenistan","tkm"],id:"TKM"},{id:"TCA",officialName:"Turks and Caicos Islands",allNames:["tc","tca","turks and caicos islands"]},{officialName:"Tuvalu",allNames:["tv","tuvalu","tuv"],id:"TUV"},{officialName:"Uganda",allNames:["ug","republic of uganda","jamhuri ya uganda","uganda","uga"],id:"UGA"},{officialName:"Ukraine",allNames:["ua","ukrayina","ukraine","ukr"],id:"UKR"},{officialName:"United Arab Emirates",allNames:["ae","uae","united arab emirates","are"],id:"ARE"},{officialName:"United Kingdom",allNames:["gb","uk","great britain","united kingdom","gbr","britain","england"],id:"GBR"},{officialName:"United States",allNames:["us","usa","united states of america","united states","usa"],id:"USA"},{id:"UMI",officialName:"United States Minor Outlying Islands",allNames:["um","umi","united states minor outlying islands"]},{officialName:"Uruguay",allNames:["uy","oriental republic of uruguay","república oriental del uruguay","uruguay","ury"],id:"URY"},{officialName:"Uzbekistan",allNames:["uz","republic of uzbekistan","o‘zbekiston respublikasi","ўзбекистон республикаси","uzbekistan","uzb"],id:"UZB"},{officialName:"Vanuatu",allNames:["vu","republic of vanuatu","ripablik blong vanuatu","république de vanuatu","vanuatu","vut"],id:"VUT"},{id:"VAT",officialName:"Vatican",allNames:["va","vat","vatican","vatican city","vatican city state","holy see (vatican city state)","holy see [vatican city state]"]},{officialName:"Venezuela",allNames:["ve","bolivarian republic of venezuela","república bolivariana de venezuela","venezuela","ven","bolivarian republic of"],id:"VEN"},{officialName:"Vietnam",allNames:["vn","socialist republic of vietnam","cộng hòa xã hội chủ nghĩa việt nam","vietnam","vnm","viet nam"],id:"VNM"},{id:"VGB",officialName:"Virgin Islands",allNames:["vg","vgb","virgin islands","british","british virgin islands","virgin islands (british)"]},{id:"VIR",officialName:"Virgin Islands",allNames:["vi","vir","virgin islands","u.s.","us virgin islands","u.s. virgin islands","virgin islands (u.s.)"]},{officialName:"Wallis and Futuna",allNames:["wf","territory of the wallis and futuna islands","territoire des îles wallis et futuna","wallis and futuna","wlf","wallis and futuna islands"],id:"WLF"},{officialName:"Western Sahara",allNames:["eh","taneẓroft tutrimt","western sahara","esh"],id:"ESH"},{officialName:"Yemen",allNames:["ye","yemeni republic","al-jumhūriyyah al-yamaniyyah","yemen","yem"],id:"YEM"},{officialName:"Zambia",allNames:["zm","republic of zambia","zambia","zmb"],id:"ZMB"},{officialName:"Zimbabwe",allNames:["zw","republic of zimbabwe","zimbabwe","zwe"],id:"ZWE"}],h7="#d6d9dc",f7="#FBFAFA";function p7(e,t,r){return e.reduce((i,a)=>{const o=a.id;let s;if(r==="world"){const u=d7.find(c=>c.id===o);u?s=t.find(c=>u.allNames.includes(c.geoName.trim().toLowerCase())):s=t.find(c=>c.geoName.trim().toLowerCase()===a.properties.name.trim().toLowerCase())}else s=t.find(u=>u.geoName.trim().toLowerCase()===a.properties.name.trim().toLowerCase());return i[o]={geoDataElement:s,style:{color:h7,weight:1,opacity:1,fillColor:s&&s.color||f7,fillOpacity:1},displayName:(s==null?void 0:s.geoName)||a.properties.name},i},{})}const m7=l7.CRS,g7=({geoJson:e,geoData:t,dataOptions:r,mapType:n})=>{const{themeSettings:i}=y.useThemeContext(),a=N.useRef(null),o=N.useRef(null),[s]=N.useState(Rn.layerGroup()),u=N.useMemo(()=>p7(e.features,t,n),[e,t,n]);return N.useEffect(()=>{a.current&&!o.current&&(o.current=_7(a.current,n),s.addTo(o.current))},[s,n]),N.useEffect(()=>{const c=Rn.geoJSON(w7(e,u),{style:d=>u[d.id].style,onEachFeature:(d,h)=>{h.bindTooltip(b7(d,u,r.originalValueTitle),{sticky:!0}),h.on({mouseover:p=>{const m=p.target;v7(m,d.id,u)},mouseout:p=>{const m=p.target;y7(m,d.id,u)}}),r.onAreaClick&&h.on({click:p=>{const m=u[d.id].geoDataElement;m&&r.onAreaClick(m,p.originalEvent)}})}});o.current&&(s.clearLayers(),s.addLayer(c),o.current.fitBounds(c.getBounds(),qC(i)))},[r,u,e,s,i]),O.jsx("div",{ref:a,className:"csdk-map-container",style:{width:"100%",height:"100%",minWidth:"300px",minHeight:"400px",backgroundColor:"#c2dbe9"}})};function v7(e,t,r){if(r[t]){const i=r[t].style.fillColor;e.setStyle({weight:2,color:E.scaleBrightness(i,-.2),fillColor:E.scaleBrightness(i,.05),dashArray:"",fillOpacity:1,opacity:1}),e.bringToFront()}}function y7(e,t,r){e.setStyle(r[t].style)}function b7(e,t,r){const n=t[e.id],{formattedOriginalValue:i}=n.geoDataElement||{},a=`
18
+ <div>
19
+ <span>${n.displayName}<span>
20
+ ${n.geoDataElement&&i!==void 0?`<br/>${r}: <span>${i}<span>`:""}
21
+ </div>`;return E.purify.sanitize(a)}function _7(e,t){return t==="world"?Rn.map(e,{attributionControl:!1,scrollWheelZoom:!0,minZoom:1,zoom:1,maxZoom:5,center:[0,0]}):Rn.map(e,{crs:new m7("EPSG:5070","+proj=aea +lat_1=29.5 +lat_2=45.5 +lat_0=23 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs",{resolutions:[16384,10240,8192,4096]}),center:[35.96852047262865,-96.96520768859223],zoom:.4,maxZoom:3,attributionControl:!1})}function w7(e,t){if(t.ATA&&t.ATA.geoDataElement)return e;{const r=e.features.filter(n=>n.id!=="ATA");return z(D({},e),{features:r})}}var C7="[object Date]";function x7(e){return V.isObjectLike(e)&&V.baseGetTag(e)==C7}var J1=V.nodeUtil&&V.nodeUtil.isDate,T7=J1?V.baseUnary(J1):x7,Qf={exports:{}},YC={exports:{}};(function(e){function t(r){return r&&r.__esModule?r:{default:r}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(YC);var dt=YC.exports,Jf={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n,i){if(n==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a]);return n}e.exports=t.default})(Jf,Jf.exports);var S7=Jf.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=i;var n=r(S7);function i(a){return(0,n.default)({},a)}e.exports=t.default})(Qf,Qf.exports);var M7=Qf.exports;const P7=O.getDefaultExportFromCjs(M7);var ep={exports:{}},tp={exports:{}},rp={exports:{}},XC={exports:{}};(function(e){function t(r){"@babel/helpers - typeof";return e.exports=t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},e.exports.__esModule=!0,e.exports.default=e.exports,t(r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(XC);var ZC=XC.exports,np={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n,i){if(i.length<n)throw new TypeError(n+" argument"+(n>1?"s":"")+" required, but only "+i.length+" present")}e.exports=t.default})(np,np.exports);var cr=np.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(ZC),i=r(cr);function a(o){return(0,i.default)(1,arguments),o instanceof Date||(0,n.default)(o)==="object"&&Object.prototype.toString.call(o)==="[object Date]"}e.exports=t.default})(rp,rp.exports);var E7=rp.exports,ip={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(ZC),i=r(cr);function a(o){(0,i.default)(1,arguments);var s=Object.prototype.toString.call(o);return o instanceof Date||(0,n.default)(o)==="object"&&s==="[object Date]"?new Date(o.getTime()):typeof o=="number"||s==="[object Number]"?new Date(o):((typeof o=="string"||s==="[object String]")&&typeof console!="undefined"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}e.exports=t.default})(ip,ip.exports);var bn=ip.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(E7),i=r(bn),a=r(cr);function o(s){if((0,a.default)(1,arguments),!(0,n.default)(s)&&typeof s!="number")return!1;var u=(0,i.default)(s);return!isNaN(Number(u))}e.exports=t.default})(tp,tp.exports);var A7=tp.exports,ap={exports:{}},op={exports:{}},sp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){if(n===null||n===!0||n===!1)return NaN;var i=Number(n);return isNaN(i)?i:i<0?Math.ceil(i):Math.floor(i)}e.exports=t.default})(sp,sp.exports);var ji=sp.exports;const R7=O.getDefaultExportFromCjs(ji);(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(ji),i=r(bn),a=r(cr);function o(s,u){(0,a.default)(2,arguments);var c=(0,i.default)(s).getTime(),d=(0,n.default)(u);return new Date(c+d)}e.exports=t.default})(op,op.exports);var D7=op.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(D7),i=r(cr),a=r(ji);function o(s,u){(0,i.default)(2,arguments);var c=(0,a.default)(u);return(0,n.default)(s,-c)}e.exports=t.default})(ap,ap.exports);var N7=ap.exports,lp={exports:{}},up={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(bn),i=r(cr),a=864e5;function o(s){(0,i.default)(1,arguments);var u=(0,n.default)(s),c=u.getTime();u.setUTCMonth(0,1),u.setUTCHours(0,0,0,0);var d=u.getTime(),h=c-d;return Math.floor(h/a)+1}e.exports=t.default})(up,up.exports);var k7=up.exports,cp={exports:{}},dp={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=a;var n=r(bn),i=r(cr);function a(o){(0,i.default)(1,arguments);var s=1,u=(0,n.default)(o),c=u.getUTCDay(),d=(c<s?7:0)+c-s;return u.setUTCDate(u.getUTCDate()-d),u.setUTCHours(0,0,0,0),u}e.exports=t.default})(dp,dp.exports);var T0=dp.exports,hp={exports:{}},fp={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(bn),i=r(cr),a=r(T0);function o(s){(0,i.default)(1,arguments);var u=(0,n.default)(s),c=u.getUTCFullYear(),d=new Date(0);d.setUTCFullYear(c+1,0,4),d.setUTCHours(0,0,0,0);var h=(0,a.default)(d),p=new Date(0);p.setUTCFullYear(c,0,4),p.setUTCHours(0,0,0,0);var m=(0,a.default)(p);return u.getTime()>=h.getTime()?c+1:u.getTime()>=m.getTime()?c:c-1}e.exports=t.default})(fp,fp.exports);var KC=fp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=o;var n=r(KC),i=r(T0),a=r(cr);function o(s){(0,a.default)(1,arguments);var u=(0,n.default)(s),c=new Date(0);c.setUTCFullYear(u,0,4),c.setUTCHours(0,0,0,0);var d=(0,i.default)(c);return d}e.exports=t.default})(hp,hp.exports);var L7=hp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var n=r(bn),i=r(T0),a=r(L7),o=r(cr),s=6048e5;function u(c){(0,o.default)(1,arguments);var d=(0,n.default)(c),h=(0,i.default)(d).getTime()-(0,a.default)(d).getTime();return Math.round(h/s)+1}e.exports=t.default})(cp,cp.exports);var O7=cp.exports,pp={exports:{}},mp={exports:{}},Vi={};Object.defineProperty(Vi,"__esModule",{value:!0});Vi.getDefaultOptions=I7;Vi.setDefaultOptions=F7;var QC={};function I7(){return QC}function F7(e){QC=e}(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var n=r(bn),i=r(cr),a=r(ji),o=Vi;function s(u,c){var d,h,p,m,g,b,_,w;(0,i.default)(1,arguments);var C=(0,o.getDefaultOptions)(),S=(0,a.default)((d=(h=(p=(m=c==null?void 0:c.weekStartsOn)!==null&&m!==void 0?m:c==null||(g=c.locale)===null||g===void 0||(b=g.options)===null||b===void 0?void 0:b.weekStartsOn)!==null&&p!==void 0?p:C.weekStartsOn)!==null&&h!==void 0?h:(_=C.locale)===null||_===void 0||(w=_.options)===null||w===void 0?void 0:w.weekStartsOn)!==null&&d!==void 0?d:0);if(!(S>=0&&S<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var T=(0,n.default)(u),M=T.getUTCDay(),P=(M<S?7:0)+M-S;return T.setUTCDate(T.getUTCDate()-P),T.setUTCHours(0,0,0,0),T}e.exports=t.default})(mp,mp.exports);var S0=mp.exports,gp={exports:{}},vp={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var n=r(bn),i=r(cr),a=r(S0),o=r(ji),s=Vi;function u(c,d){var h,p,m,g,b,_,w,C;(0,i.default)(1,arguments);var S=(0,n.default)(c),T=S.getUTCFullYear(),M=(0,s.getDefaultOptions)(),P=(0,o.default)((h=(p=(m=(g=d==null?void 0:d.firstWeekContainsDate)!==null&&g!==void 0?g:d==null||(b=d.locale)===null||b===void 0||(_=b.options)===null||_===void 0?void 0:_.firstWeekContainsDate)!==null&&m!==void 0?m:M.firstWeekContainsDate)!==null&&p!==void 0?p:(w=M.locale)===null||w===void 0||(C=w.options)===null||C===void 0?void 0:C.firstWeekContainsDate)!==null&&h!==void 0?h:1);if(!(P>=1&&P<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var R=new Date(0);R.setUTCFullYear(T+1,0,P),R.setUTCHours(0,0,0,0);var k=(0,a.default)(R,d),I=new Date(0);I.setUTCFullYear(T,0,P),I.setUTCHours(0,0,0,0);var $=(0,a.default)(I,d);return S.getTime()>=k.getTime()?T+1:S.getTime()>=$.getTime()?T:T-1}e.exports=t.default})(vp,vp.exports);var JC=vp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var n=r(JC),i=r(cr),a=r(S0),o=r(ji),s=Vi;function u(c,d){var h,p,m,g,b,_,w,C;(0,i.default)(1,arguments);var S=(0,s.getDefaultOptions)(),T=(0,o.default)((h=(p=(m=(g=d==null?void 0:d.firstWeekContainsDate)!==null&&g!==void 0?g:d==null||(b=d.locale)===null||b===void 0||(_=b.options)===null||_===void 0?void 0:_.firstWeekContainsDate)!==null&&m!==void 0?m:S.firstWeekContainsDate)!==null&&p!==void 0?p:(w=S.locale)===null||w===void 0||(C=w.options)===null||C===void 0?void 0:C.firstWeekContainsDate)!==null&&h!==void 0?h:1),M=(0,n.default)(c,d),P=new Date(0);P.setUTCFullYear(M,0,T),P.setUTCHours(0,0,0,0);var R=(0,a.default)(P,d);return R}e.exports=t.default})(gp,gp.exports);var $7=gp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var n=r(bn),i=r(S0),a=r($7),o=r(cr),s=6048e5;function u(c,d){(0,o.default)(1,arguments);var h=(0,n.default)(c),p=(0,i.default)(h,d).getTime()-(0,a.default)(h,d).getTime();return Math.round(p/s)+1}e.exports=t.default})(pp,pp.exports);var B7=pp.exports,yp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n,i){for(var a=n<0?"-":"",o=Math.abs(n).toString();o.length<i;)o="0"+o;return a+o}e.exports=t.default})(yp,yp.exports);var ex=yp.exports,bp={exports:{}};(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(ex),i={y:function(s,u){var c=s.getUTCFullYear(),d=c>0?c:1-c;return(0,n.default)(u==="yy"?d%100:d,u.length)},M:function(s,u){var c=s.getUTCMonth();return u==="M"?String(c+1):(0,n.default)(c+1,2)},d:function(s,u){return(0,n.default)(s.getUTCDate(),u.length)},a:function(s,u){var c=s.getUTCHours()/12>=1?"pm":"am";switch(u){case"a":case"aa":return c.toUpperCase();case"aaa":return c;case"aaaaa":return c[0];case"aaaa":default:return c==="am"?"a.m.":"p.m."}},h:function(s,u){return(0,n.default)(s.getUTCHours()%12||12,u.length)},H:function(s,u){return(0,n.default)(s.getUTCHours(),u.length)},m:function(s,u){return(0,n.default)(s.getUTCMinutes(),u.length)},s:function(s,u){return(0,n.default)(s.getUTCSeconds(),u.length)},S:function(s,u){var c=u.length,d=s.getUTCMilliseconds(),h=Math.floor(d*Math.pow(10,c-3));return(0,n.default)(h,u.length)}},a=i;t.default=a,e.exports=t.default})(bp,bp.exports);var z7=bp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(k7),i=r(O7),a=r(KC),o=r(B7),s=r(JC),u=r(ex),c=r(z7),d={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},h={G:function(w,C,S){var T=w.getUTCFullYear()>0?1:0;switch(C){case"G":case"GG":case"GGG":return S.era(T,{width:"abbreviated"});case"GGGGG":return S.era(T,{width:"narrow"});case"GGGG":default:return S.era(T,{width:"wide"})}},y:function(w,C,S){if(C==="yo"){var T=w.getUTCFullYear(),M=T>0?T:1-T;return S.ordinalNumber(M,{unit:"year"})}return c.default.y(w,C)},Y:function(w,C,S,T){var M=(0,s.default)(w,T),P=M>0?M:1-M;if(C==="YY"){var R=P%100;return(0,u.default)(R,2)}return C==="Yo"?S.ordinalNumber(P,{unit:"year"}):(0,u.default)(P,C.length)},R:function(w,C){var S=(0,a.default)(w);return(0,u.default)(S,C.length)},u:function(w,C){var S=w.getUTCFullYear();return(0,u.default)(S,C.length)},Q:function(w,C,S){var T=Math.ceil((w.getUTCMonth()+1)/3);switch(C){case"Q":return String(T);case"QQ":return(0,u.default)(T,2);case"Qo":return S.ordinalNumber(T,{unit:"quarter"});case"QQQ":return S.quarter(T,{width:"abbreviated",context:"formatting"});case"QQQQQ":return S.quarter(T,{width:"narrow",context:"formatting"});case"QQQQ":default:return S.quarter(T,{width:"wide",context:"formatting"})}},q:function(w,C,S){var T=Math.ceil((w.getUTCMonth()+1)/3);switch(C){case"q":return String(T);case"qq":return(0,u.default)(T,2);case"qo":return S.ordinalNumber(T,{unit:"quarter"});case"qqq":return S.quarter(T,{width:"abbreviated",context:"standalone"});case"qqqqq":return S.quarter(T,{width:"narrow",context:"standalone"});case"qqqq":default:return S.quarter(T,{width:"wide",context:"standalone"})}},M:function(w,C,S){var T=w.getUTCMonth();switch(C){case"M":case"MM":return c.default.M(w,C);case"Mo":return S.ordinalNumber(T+1,{unit:"month"});case"MMM":return S.month(T,{width:"abbreviated",context:"formatting"});case"MMMMM":return S.month(T,{width:"narrow",context:"formatting"});case"MMMM":default:return S.month(T,{width:"wide",context:"formatting"})}},L:function(w,C,S){var T=w.getUTCMonth();switch(C){case"L":return String(T+1);case"LL":return(0,u.default)(T+1,2);case"Lo":return S.ordinalNumber(T+1,{unit:"month"});case"LLL":return S.month(T,{width:"abbreviated",context:"standalone"});case"LLLLL":return S.month(T,{width:"narrow",context:"standalone"});case"LLLL":default:return S.month(T,{width:"wide",context:"standalone"})}},w:function(w,C,S,T){var M=(0,o.default)(w,T);return C==="wo"?S.ordinalNumber(M,{unit:"week"}):(0,u.default)(M,C.length)},I:function(w,C,S){var T=(0,i.default)(w);return C==="Io"?S.ordinalNumber(T,{unit:"week"}):(0,u.default)(T,C.length)},d:function(w,C,S){return C==="do"?S.ordinalNumber(w.getUTCDate(),{unit:"date"}):c.default.d(w,C)},D:function(w,C,S){var T=(0,n.default)(w);return C==="Do"?S.ordinalNumber(T,{unit:"dayOfYear"}):(0,u.default)(T,C.length)},E:function(w,C,S){var T=w.getUTCDay();switch(C){case"E":case"EE":case"EEE":return S.day(T,{width:"abbreviated",context:"formatting"});case"EEEEE":return S.day(T,{width:"narrow",context:"formatting"});case"EEEEEE":return S.day(T,{width:"short",context:"formatting"});case"EEEE":default:return S.day(T,{width:"wide",context:"formatting"})}},e:function(w,C,S,T){var M=w.getUTCDay(),P=(M-T.weekStartsOn+8)%7||7;switch(C){case"e":return String(P);case"ee":return(0,u.default)(P,2);case"eo":return S.ordinalNumber(P,{unit:"day"});case"eee":return S.day(M,{width:"abbreviated",context:"formatting"});case"eeeee":return S.day(M,{width:"narrow",context:"formatting"});case"eeeeee":return S.day(M,{width:"short",context:"formatting"});case"eeee":default:return S.day(M,{width:"wide",context:"formatting"})}},c:function(w,C,S,T){var M=w.getUTCDay(),P=(M-T.weekStartsOn+8)%7||7;switch(C){case"c":return String(P);case"cc":return(0,u.default)(P,C.length);case"co":return S.ordinalNumber(P,{unit:"day"});case"ccc":return S.day(M,{width:"abbreviated",context:"standalone"});case"ccccc":return S.day(M,{width:"narrow",context:"standalone"});case"cccccc":return S.day(M,{width:"short",context:"standalone"});case"cccc":default:return S.day(M,{width:"wide",context:"standalone"})}},i:function(w,C,S){var T=w.getUTCDay(),M=T===0?7:T;switch(C){case"i":return String(M);case"ii":return(0,u.default)(M,C.length);case"io":return S.ordinalNumber(M,{unit:"day"});case"iii":return S.day(T,{width:"abbreviated",context:"formatting"});case"iiiii":return S.day(T,{width:"narrow",context:"formatting"});case"iiiiii":return S.day(T,{width:"short",context:"formatting"});case"iiii":default:return S.day(T,{width:"wide",context:"formatting"})}},a:function(w,C,S){var T=w.getUTCHours(),M=T/12>=1?"pm":"am";switch(C){case"a":case"aa":return S.dayPeriod(M,{width:"abbreviated",context:"formatting"});case"aaa":return S.dayPeriod(M,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return S.dayPeriod(M,{width:"narrow",context:"formatting"});case"aaaa":default:return S.dayPeriod(M,{width:"wide",context:"formatting"})}},b:function(w,C,S){var T=w.getUTCHours(),M;switch(T===12?M=d.noon:T===0?M=d.midnight:M=T/12>=1?"pm":"am",C){case"b":case"bb":return S.dayPeriod(M,{width:"abbreviated",context:"formatting"});case"bbb":return S.dayPeriod(M,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return S.dayPeriod(M,{width:"narrow",context:"formatting"});case"bbbb":default:return S.dayPeriod(M,{width:"wide",context:"formatting"})}},B:function(w,C,S){var T=w.getUTCHours(),M;switch(T>=17?M=d.evening:T>=12?M=d.afternoon:T>=4?M=d.morning:M=d.night,C){case"B":case"BB":case"BBB":return S.dayPeriod(M,{width:"abbreviated",context:"formatting"});case"BBBBB":return S.dayPeriod(M,{width:"narrow",context:"formatting"});case"BBBB":default:return S.dayPeriod(M,{width:"wide",context:"formatting"})}},h:function(w,C,S){if(C==="ho"){var T=w.getUTCHours()%12;return T===0&&(T=12),S.ordinalNumber(T,{unit:"hour"})}return c.default.h(w,C)},H:function(w,C,S){return C==="Ho"?S.ordinalNumber(w.getUTCHours(),{unit:"hour"}):c.default.H(w,C)},K:function(w,C,S){var T=w.getUTCHours()%12;return C==="Ko"?S.ordinalNumber(T,{unit:"hour"}):(0,u.default)(T,C.length)},k:function(w,C,S){var T=w.getUTCHours();return T===0&&(T=24),C==="ko"?S.ordinalNumber(T,{unit:"hour"}):(0,u.default)(T,C.length)},m:function(w,C,S){return C==="mo"?S.ordinalNumber(w.getUTCMinutes(),{unit:"minute"}):c.default.m(w,C)},s:function(w,C,S){return C==="so"?S.ordinalNumber(w.getUTCSeconds(),{unit:"second"}):c.default.s(w,C)},S:function(w,C){return c.default.S(w,C)},X:function(w,C,S,T){var M=T._originalDate||w,P=M.getTimezoneOffset();if(P===0)return"Z";switch(C){case"X":return m(P);case"XXXX":case"XX":return g(P);case"XXXXX":case"XXX":default:return g(P,":")}},x:function(w,C,S,T){var M=T._originalDate||w,P=M.getTimezoneOffset();switch(C){case"x":return m(P);case"xxxx":case"xx":return g(P);case"xxxxx":case"xxx":default:return g(P,":")}},O:function(w,C,S,T){var M=T._originalDate||w,P=M.getTimezoneOffset();switch(C){case"O":case"OO":case"OOO":return"GMT"+p(P,":");case"OOOO":default:return"GMT"+g(P,":")}},z:function(w,C,S,T){var M=T._originalDate||w,P=M.getTimezoneOffset();switch(C){case"z":case"zz":case"zzz":return"GMT"+p(P,":");case"zzzz":default:return"GMT"+g(P,":")}},t:function(w,C,S,T){var M=T._originalDate||w,P=Math.floor(M.getTime()/1e3);return(0,u.default)(P,C.length)},T:function(w,C,S,T){var M=T._originalDate||w,P=M.getTime();return(0,u.default)(P,C.length)}};function p(_,w){var C=_>0?"-":"+",S=Math.abs(_),T=Math.floor(S/60),M=S%60;if(M===0)return C+String(T);var P=w;return C+String(T)+P+(0,u.default)(M,2)}function m(_,w){if(_%60===0){var C=_>0?"-":"+";return C+(0,u.default)(Math.abs(_)/60,2)}return g(_,w)}function g(_,w){var C=w||"",S=_>0?"-":"+",T=Math.abs(_),M=(0,u.default)(Math.floor(T/60),2),P=(0,u.default)(T%60,2);return S+M+C+P}var b=h;t.default=b,e.exports=t.default})(lp,lp.exports);var H7=lp.exports,_p={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(u,c){switch(u){case"P":return c.date({width:"short"});case"PP":return c.date({width:"medium"});case"PPP":return c.date({width:"long"});case"PPPP":default:return c.date({width:"full"})}},n=function(u,c){switch(u){case"p":return c.time({width:"short"});case"pp":return c.time({width:"medium"});case"ppp":return c.time({width:"long"});case"pppp":default:return c.time({width:"full"})}},i=function(u,c){var d=u.match(/(P+)(p+)?/)||[],h=d[1],p=d[2];if(!p)return r(u,c);var m;switch(h){case"P":m=c.dateTime({width:"short"});break;case"PP":m=c.dateTime({width:"medium"});break;case"PPP":m=c.dateTime({width:"long"});break;case"PPPP":default:m=c.dateTime({width:"full"});break}return m.replace("{{date}}",r(h,c)).replace("{{time}}",n(p,c))},a={p:n,P:i},o=a;t.default=o,e.exports=t.default})(_p,_p.exports);var W7=_p.exports,wp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){var i=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return i.setUTCFullYear(n.getFullYear()),n.getTime()-i.getTime()}e.exports=t.default})(wp,wp.exports);var tx=wp.exports;const ey=O.getDefaultExportFromCjs(tx);var nl={};Object.defineProperty(nl,"__esModule",{value:!0});nl.isProtectedDayOfYearToken=U7;nl.isProtectedWeekYearToken=G7;nl.throwProtectedError=q7;var j7=["D","DD"],V7=["YY","YYYY"];function U7(e){return j7.indexOf(e)!==-1}function G7(e){return V7.indexOf(e)!==-1}function q7(e,t,r){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Cp={exports:{}},xp={exports:{}},Tp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},n=function(o,s,u){var c,d=r[o];return typeof d=="string"?c=d:s===1?c=d.one:c=d.other.replace("{{count}}",s.toString()),u!=null&&u.addSuffix?u.comparison&&u.comparison>0?"in "+c:c+" ago":c},i=n;t.default=i,e.exports=t.default})(Tp,Tp.exports);var Y7=Tp.exports,Sp={exports:{}},Mp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){return function(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=i.width?String(i.width):n.defaultWidth,o=n.formats[a]||n.formats[n.defaultWidth];return o}}e.exports=t.default})(Mp,Mp.exports);var X7=Mp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(X7),i={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},a={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},o={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},s={date:(0,n.default)({formats:i,defaultWidth:"full"}),time:(0,n.default)({formats:a,defaultWidth:"full"}),dateTime:(0,n.default)({formats:o,defaultWidth:"full"})},u=s;t.default=u,e.exports=t.default})(Sp,Sp.exports);var Z7=Sp.exports,Pp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},n=function(o,s,u,c){return r[o]},i=n;t.default=i,e.exports=t.default})(Pp,Pp.exports);var K7=Pp.exports,Ep={exports:{}},Ap={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){return function(i,a){var o=a!=null&&a.context?String(a.context):"standalone",s;if(o==="formatting"&&n.formattingValues){var u=n.defaultFormattingWidth||n.defaultWidth,c=a!=null&&a.width?String(a.width):u;s=n.formattingValues[c]||n.formattingValues[u]}else{var d=n.defaultWidth,h=a!=null&&a.width?String(a.width):n.defaultWidth;s=n.values[h]||n.values[d]}var p=n.argumentCallback?n.argumentCallback(i):i;return s[p]}}e.exports=t.default})(Ap,Ap.exports);var Q7=Ap.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(Q7),i={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},a={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},o={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},s={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},u={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},c={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},d=function(g,b){var _=Number(g),w=_%100;if(w>20||w<10)switch(w%10){case 1:return _+"st";case 2:return _+"nd";case 3:return _+"rd"}return _+"th"},h={ordinalNumber:d,era:(0,n.default)({values:i,defaultWidth:"wide"}),quarter:(0,n.default)({values:a,defaultWidth:"wide",argumentCallback:function(g){return g-1}}),month:(0,n.default)({values:o,defaultWidth:"wide"}),day:(0,n.default)({values:s,defaultWidth:"wide"}),dayPeriod:(0,n.default)({values:u,defaultWidth:"wide",formattingValues:c,defaultFormattingWidth:"wide"})},p=h;t.default=p,e.exports=t.default})(Ep,Ep.exports);var J7=Ep.exports,Rp={exports:{}},Dp={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(a){return function(o){var s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},u=s.width,c=u&&a.matchPatterns[u]||a.matchPatterns[a.defaultMatchWidth],d=o.match(c);if(!d)return null;var h=d[0],p=u&&a.parsePatterns[u]||a.parsePatterns[a.defaultParseWidth],m=Array.isArray(p)?i(p,function(_){return _.test(h)}):n(p,function(_){return _.test(h)}),g;g=a.valueCallback?a.valueCallback(m):m,g=s.valueCallback?s.valueCallback(g):g;var b=o.slice(h.length);return{value:g,rest:b}}}function n(a,o){for(var s in a)if(a.hasOwnProperty(s)&&o(a[s]))return s}function i(a,o){for(var s=0;s<a.length;s++)if(o(a[s]))return s}e.exports=t.default})(Dp,Dp.exports);var eI=Dp.exports,Np={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){return function(i){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=i.match(n.matchPattern);if(!o)return null;var s=o[0],u=i.match(n.parsePattern);if(!u)return null;var c=n.valueCallback?n.valueCallback(u[0]):u[0];c=a.valueCallback?a.valueCallback(c):c;var d=i.slice(s.length);return{value:c,rest:d}}}e.exports=t.default})(Np,Np.exports);var tI=Np.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(eI),i=r(tI),a=/^(\d+)(th|st|nd|rd)?/i,o=/\d+/i,s={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},u={any:[/^b/i,/^(a|c)/i]},c={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},d={any:[/1/i,/2/i,/3/i,/4/i]},h={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},p={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},m={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},g={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},b={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},_={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},w={ordinalNumber:(0,i.default)({matchPattern:a,parsePattern:o,valueCallback:function(T){return parseInt(T,10)}}),era:(0,n.default)({matchPatterns:s,defaultMatchWidth:"wide",parsePatterns:u,defaultParseWidth:"any"}),quarter:(0,n.default)({matchPatterns:c,defaultMatchWidth:"wide",parsePatterns:d,defaultParseWidth:"any",valueCallback:function(T){return T+1}}),month:(0,n.default)({matchPatterns:h,defaultMatchWidth:"wide",parsePatterns:p,defaultParseWidth:"any"}),day:(0,n.default)({matchPatterns:m,defaultMatchWidth:"wide",parsePatterns:g,defaultParseWidth:"any"}),dayPeriod:(0,n.default)({matchPatterns:b,defaultMatchWidth:"any",parsePatterns:_,defaultParseWidth:"any"})},C=w;t.default=C,e.exports=t.default})(Rp,Rp.exports);var rI=Rp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(Y7),i=r(Z7),a=r(K7),o=r(J7),s=r(rI),u={code:"en-US",formatDistance:n.default,formatLong:i.default,formatRelative:a.default,localize:o.default,match:s.default,options:{weekStartsOn:0,firstWeekContainsDate:1}},c=u;t.default=c,e.exports=t.default})(xp,xp.exports);var nI=xp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=r(nI),i=n.default;t.default=i,e.exports=t.default})(Cp,Cp.exports);var iI=Cp.exports;(function(e,t){var r=dt.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=S;var n=r(A7),i=r(N7),a=r(bn),o=r(H7),s=r(W7),u=r(tx),c=nl,d=r(ji),h=r(cr),p=Vi,m=r(iI),g=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,b=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,_=/^'([^]*?)'?$/,w=/''/g,C=/[a-zA-Z]/;function S(M,P,R){var k,I,$,G,Y,B,X,U,Q,W,q,ee,Z,J,ne,oe,ae,se;(0,h.default)(2,arguments);var ue=String(P),me=(0,p.getDefaultOptions)(),pe=(k=(I=R==null?void 0:R.locale)!==null&&I!==void 0?I:me.locale)!==null&&k!==void 0?k:m.default,Ce=(0,d.default)(($=(G=(Y=(B=R==null?void 0:R.firstWeekContainsDate)!==null&&B!==void 0?B:R==null||(X=R.locale)===null||X===void 0||(U=X.options)===null||U===void 0?void 0:U.firstWeekContainsDate)!==null&&Y!==void 0?Y:me.firstWeekContainsDate)!==null&&G!==void 0?G:(Q=me.locale)===null||Q===void 0||(W=Q.options)===null||W===void 0?void 0:W.firstWeekContainsDate)!==null&&$!==void 0?$:1);if(!(Ce>=1&&Ce<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var ke=(0,d.default)((q=(ee=(Z=(J=R==null?void 0:R.weekStartsOn)!==null&&J!==void 0?J:R==null||(ne=R.locale)===null||ne===void 0||(oe=ne.options)===null||oe===void 0?void 0:oe.weekStartsOn)!==null&&Z!==void 0?Z:me.weekStartsOn)!==null&&ee!==void 0?ee:(ae=me.locale)===null||ae===void 0||(se=ae.options)===null||se===void 0?void 0:se.weekStartsOn)!==null&&q!==void 0?q:0);if(!(ke>=0&&ke<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!pe.localize)throw new RangeError("locale must contain localize property");if(!pe.formatLong)throw new RangeError("locale must contain formatLong property");var we=(0,a.default)(M);if(!(0,n.default)(we))throw new RangeError("Invalid time value");var le=(0,u.default)(we),He=(0,i.default)(we,le),Te={firstWeekContainsDate:Ce,weekStartsOn:ke,locale:pe,_originalDate:we},Ae=ue.match(b).map(function($e){var Ge=$e[0];if(Ge==="p"||Ge==="P"){var qe=s.default[Ge];return qe($e,pe.formatLong)}return $e}).join("").match(g).map(function($e){if($e==="''")return"'";var Ge=$e[0];if(Ge==="'")return T($e);var qe=o.default[Ge];if(qe)return!(R!=null&&R.useAdditionalWeekYearTokens)&&(0,c.isProtectedWeekYearToken)($e)&&(0,c.throwProtectedError)($e,P,String(M)),!(R!=null&&R.useAdditionalDayOfYearTokens)&&(0,c.isProtectedDayOfYearToken)($e)&&(0,c.throwProtectedError)($e,P,String(M)),qe(He,$e,pe.localize,Te);if(Ge.match(C))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Ge+"`");return $e}).join("");return Ae}function T(M){var P=M.match(_);return P?P[1].replace(w,"'"):M}e.exports=t.default})(ep,ep.exports);var aI=ep.exports;const oI=O.getDefaultExportFromCjs(aI);function ty(e,t,r){var n=uI(e,r.timeZone,r.locale);return n.formatToParts?sI(n,t):lI(n,t)}function sI(e,t){for(var r=e.formatToParts(t),n=r.length-1;n>=0;--n)if(r[n].type==="timeZoneName")return r[n].value}function lI(e,t){var r=e.format(t).replace(/\u200E/g,""),n=/ [\w-+ ]+$/.exec(r);return n?n[0].substr(1):""}function uI(e,t,r){if(r&&!r.code)throw new Error("date-fns-tz error: Please set a language code on the locale object imported from date-fns, e.g. `locale.code = 'en-US'`");return new Intl.DateTimeFormat(r?[r.code,"en-US"]:void 0,{timeZone:t,timeZoneName:e})}function cI(e,t){var r=pI(t);return r.formatToParts?hI(r,e):fI(r,e)}var dI={year:0,month:1,day:2,hour:3,minute:4,second:5};function hI(e,t){try{for(var r=e.formatToParts(t),n=[],i=0;i<r.length;i++){var a=dI[r[i].type];a>=0&&(n[a]=parseInt(r[i].value,10))}return n}catch(o){if(o instanceof RangeError)return[NaN];throw o}}function fI(e,t){var r=e.format(t),n=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(r);return[n[3],n[1],n[2],n[4],n[5],n[6]]}var $h={};function pI(e){if(!$h[e]){var t=new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:"America/New_York",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),r=t==="06/25/2014, 00:00:00"||t==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";$h[e]=r?new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}return $h[e]}function rx(e,t,r,n,i,a,o){var s=new Date(0);return s.setUTCFullYear(e,t,r),s.setUTCHours(n,i,a,o),s}var ry=36e5,mI=6e4,Bh={timezone:/([Z+-].*)$/,timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-])(\d{2}):?(\d{2})$/};function M0(e,t,r){var n,i;if(!e||(n=Bh.timezoneZ.exec(e),n))return 0;var a;if(n=Bh.timezoneHH.exec(e),n)return a=parseInt(n[1],10),ny(a)?-(a*ry):NaN;if(n=Bh.timezoneHHMM.exec(e),n){a=parseInt(n[2],10);var o=parseInt(n[3],10);return ny(a,o)?(i=Math.abs(a)*ry+o*mI,n[1]==="+"?-i:i):NaN}if(yI(e)){t=new Date(t||Date.now());var s=r?t:gI(t),u=kp(s,e),c=r?u:vI(t,u,e);return-c}return NaN}function gI(e){return rx(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function kp(e,t){var r=cI(e,t),n=rx(r[0],r[1]-1,r[2],r[3]%24,r[4],r[5],0).getTime(),i=e.getTime(),a=i%1e3;return i-=a>=0?a:1e3+a,n-i}function vI(e,t,r){var n=e.getTime(),i=n-t,a=kp(new Date(i),r);if(t===a)return t;i-=a-t;var o=kp(new Date(i),r);return a===o?a:Math.max(a,o)}function ny(e,t){return-23<=e&&e<=23&&(t==null||0<=t&&t<=59)}var iy={};function yI(e){if(iy[e])return!0;try{return iy[e]=!0,!0}catch(t){return!1}}var bI=60*1e3,_I={X:function(e,t,r,n){var i=zh(n.timeZone,e);if(i===0)return"Z";switch(t){case"X":return ay(i);case"XXXX":case"XX":return ba(i);case"XXXXX":case"XXX":default:return ba(i,":")}},x:function(e,t,r,n){var i=zh(n.timeZone,e);switch(t){case"x":return ay(i);case"xxxx":case"xx":return ba(i);case"xxxxx":case"xxx":default:return ba(i,":")}},O:function(e,t,r,n){var i=zh(n.timeZone,e);switch(t){case"O":case"OO":case"OOO":return"GMT"+wI(i,":");case"OOOO":default:return"GMT"+ba(i,":")}},z:function(e,t,r,n){switch(t){case"z":case"zz":case"zzz":return ty("short",e,n);case"zzzz":default:return ty("long",e,n)}}};function zh(e,t){var r=e?M0(e,t,!0)/bI:t.getTimezoneOffset();if(Number.isNaN(r))throw new RangeError("Invalid time zone specified: "+e);return r}function sc(e,t){for(var r=e<0?"-":"",n=Math.abs(e).toString();n.length<t;)n="0"+n;return r+n}function ba(e,t){var r=t||"",n=e>0?"-":"+",i=Math.abs(e),a=sc(Math.floor(i/60),2),o=sc(Math.floor(i%60),2);return n+a+r+o}function ay(e,t){if(e%60===0){var r=e>0?"-":"+";return r+sc(Math.abs(e)/60,2)}return ba(e,t)}function wI(e,t){var r=e>0?"-":"+",n=Math.abs(e),i=Math.floor(n/60),a=n%60;if(a===0)return r+String(i);var o=t;return r+String(i)+o+sc(a,2)}var CI=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,Hh=36e5,oy=6e4,xI=2,or={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,plainTime:/:/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:CI};function nx(e,t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(e===null)return new Date(NaN);var r=t||{},n=r.additionalDigits==null?xI:R7(r.additionalDigits);if(n!==2&&n!==1&&n!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]")return new Date(e.getTime());if(typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]")return new Date(e);if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var i=TI(e),a=SI(i.date,n),o=a.year,s=a.restDateString,u=MI(s,o);if(isNaN(u))return new Date(NaN);if(u){var c=u.getTime(),d=0,h;if(i.time&&(d=PI(i.time),isNaN(d)))return new Date(NaN);if(i.timeZone||r.timeZone){if(h=M0(i.timeZone||r.timeZone,new Date(c+d)),isNaN(h))return new Date(NaN)}else h=ey(new Date(c+d)),h=ey(new Date(c+d+h));return new Date(c+d+h)}else return new Date(NaN)}function TI(e){var t={},r=or.dateTimePattern.exec(e),n;if(r?(t.date=r[1],n=r[3]):(r=or.datePattern.exec(e),r?(t.date=r[1],n=r[2]):(t.date=null,n=e)),n){var i=or.timeZone.exec(n);i?(t.time=n.replace(i[1],""),t.timeZone=i[1].trim()):t.time=n}return t}function SI(e,t){var r=or.YYY[t],n=or.YYYYY[t],i;if(i=or.YYYY.exec(e)||n.exec(e),i){var a=i[1];return{year:parseInt(a,10),restDateString:e.slice(a.length)}}if(i=or.YY.exec(e)||r.exec(e),i){var o=i[1];return{year:parseInt(o,10)*100,restDateString:e.slice(o.length)}}return{year:null}}function MI(e,t){if(t===null)return null;var r,n,i,a;if(e.length===0)return n=new Date(0),n.setUTCFullYear(t),n;if(r=or.MM.exec(e),r)return n=new Date(0),i=parseInt(r[1],10)-1,ly(t,i)?(n.setUTCFullYear(t,i),n):new Date(NaN);if(r=or.DDD.exec(e),r){n=new Date(0);var o=parseInt(r[1],10);return RI(t,o)?(n.setUTCFullYear(t,0,o),n):new Date(NaN)}if(r=or.MMDD.exec(e),r){n=new Date(0),i=parseInt(r[1],10)-1;var s=parseInt(r[2],10);return ly(t,i,s)?(n.setUTCFullYear(t,i,s),n):new Date(NaN)}if(r=or.Www.exec(e),r)return a=parseInt(r[1],10)-1,uy(t,a)?sy(t,a):new Date(NaN);if(r=or.WwwD.exec(e),r){a=parseInt(r[1],10)-1;var u=parseInt(r[2],10)-1;return uy(t,a,u)?sy(t,a,u):new Date(NaN)}return null}function PI(e){var t,r,n;if(t=or.HH.exec(e),t)return r=parseFloat(t[1].replace(",",".")),Wh(r)?r%24*Hh:NaN;if(t=or.HHMM.exec(e),t)return r=parseInt(t[1],10),n=parseFloat(t[2].replace(",",".")),Wh(r,n)?r%24*Hh+n*oy:NaN;if(t=or.HHMMSS.exec(e),t){r=parseInt(t[1],10),n=parseInt(t[2],10);var i=parseFloat(t[3].replace(",","."));return Wh(r,n,i)?r%24*Hh+n*oy+i*1e3:NaN}return null}function sy(e,t,r){t=t||0,r=r||0;var n=new Date(0);n.setUTCFullYear(e,0,4);var i=n.getUTCDay()||7,a=t*7+r+1-i;return n.setUTCDate(n.getUTCDate()+a),n}var EI=[31,28,31,30,31,30,31,31,30,31,30,31],AI=[31,29,31,30,31,30,31,31,30,31,30,31];function ix(e){return e%400===0||e%4===0&&e%100!==0}function ly(e,t,r){if(t<0||t>11)return!1;if(r!=null){if(r<1)return!1;var n=ix(e);if(n&&r>AI[t]||!n&&r>EI[t])return!1}return!0}function RI(e,t){if(t<1)return!1;var r=ix(e);return!(r&&t>366||!r&&t>365)}function uy(e,t,r){return!(t<0||t>52||r!=null&&(r<0||r>6))}function Wh(e,t,r){return!(e!=null&&(e<0||e>=25)||t!=null&&(t<0||t>=60)||r!=null&&(r<0||r>=60))}var DI=/([xXOz]+)|''|'(''|[^'])+('|$)/g;function NI(e,t,r){var n=String(t),i=r||{},a=n.match(DI);if(a){var o=nx(i.originalDate||e,i);n=a.reduce(function(s,u){if(u[0]==="'")return s;var c=s.indexOf(u),d=s[c-1]==="'",h=s.replace(u,"'"+_I[u[0]](o,u,null,i)+"'");return d?h.substring(0,c-1)+h.substring(c+1):h},n)}return oI(e,n,i)}function kI(e,t,r){var n=nx(e,r),i=M0(t,n,!0),a=new Date(n.getTime()-i),o=new Date(0);return o.setFullYear(a.getUTCFullYear(),a.getUTCMonth(),a.getUTCDate()),o.setHours(a.getUTCHours(),a.getUTCMinutes(),a.getUTCSeconds(),a.getUTCMilliseconds()),o}function Ni(e,t,r,n){var i=P7(n);return i.timeZone=t,i.originalDate=e,NI(kI(e,t),r,i)}function cy(e,t){H.requiredArgs(2,arguments);var r=H.toDate(e),n=H.toInteger(t);return isNaN(r.getTime())?new Date(NaN):(r.setFullYear(n),r)}function LI(e,t){H.requiredArgs(2,arguments);var r=H.toDate(e),n=H.toInteger(t);if(isNaN(n))return new Date(NaN);if(!n)return r;var i=r.getDate(),a=new Date(r.getTime());a.setMonth(r.getMonth()+n+1,0);var o=a.getDate();return i>=o?a:(r.setFullYear(a.getFullYear(),a.getMonth(),i),r)}function ax(e,t){H.requiredArgs(2,arguments);var r=H.toInteger(t);return LI(e,r*12)}function OI(e){H.requiredArgs(1,arguments);var t=H.toDate(e),r=t.getFullYear(),n=t.getMonth(),i=new Date(0);return i.setFullYear(r,n+1,0),i.setHours(0,0,0,0),i.getDate()}function II(e,t){H.requiredArgs(2,arguments);var r=H.toDate(e),n=H.toInteger(t),i=r.getFullYear(),a=r.getDate(),o=new Date(0);o.setFullYear(i,n,15),o.setHours(0,0,0,0);var s=OI(o);return r.setMonth(n,Math.min(a,s)),r}function ox(e,t){H.requiredArgs(2,arguments);var r=H.toInteger(t);return ax(e,-r)}function ki(e,t,r){H.requiredArgs(2,arguments);var n=H.startOfUTCWeek(e,r),i=H.startOfUTCWeek(t,r);return n.getTime()===i.getTime()}var dy={lessThanXSeconds:{standalone:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"},withPreposition:{one:"weniger als 1 Sekunde",other:"weniger als {{count}} Sekunden"}},xSeconds:{standalone:{one:"1 Sekunde",other:"{{count}} Sekunden"},withPreposition:{one:"1 Sekunde",other:"{{count}} Sekunden"}},halfAMinute:{standalone:"halbe Minute",withPreposition:"halben Minute"},lessThanXMinutes:{standalone:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"},withPreposition:{one:"weniger als 1 Minute",other:"weniger als {{count}} Minuten"}},xMinutes:{standalone:{one:"1 Minute",other:"{{count}} Minuten"},withPreposition:{one:"1 Minute",other:"{{count}} Minuten"}},aboutXHours:{standalone:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"},withPreposition:{one:"etwa 1 Stunde",other:"etwa {{count}} Stunden"}},xHours:{standalone:{one:"1 Stunde",other:"{{count}} Stunden"},withPreposition:{one:"1 Stunde",other:"{{count}} Stunden"}},xDays:{standalone:{one:"1 Tag",other:"{{count}} Tage"},withPreposition:{one:"1 Tag",other:"{{count}} Tagen"}},aboutXWeeks:{standalone:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"},withPreposition:{one:"etwa 1 Woche",other:"etwa {{count}} Wochen"}},xWeeks:{standalone:{one:"1 Woche",other:"{{count}} Wochen"},withPreposition:{one:"1 Woche",other:"{{count}} Wochen"}},aboutXMonths:{standalone:{one:"etwa 1 Monat",other:"etwa {{count}} Monate"},withPreposition:{one:"etwa 1 Monat",other:"etwa {{count}} Monaten"}},xMonths:{standalone:{one:"1 Monat",other:"{{count}} Monate"},withPreposition:{one:"1 Monat",other:"{{count}} Monaten"}},aboutXYears:{standalone:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahre"},withPreposition:{one:"etwa 1 Jahr",other:"etwa {{count}} Jahren"}},xYears:{standalone:{one:"1 Jahr",other:"{{count}} Jahre"},withPreposition:{one:"1 Jahr",other:"{{count}} Jahren"}},overXYears:{standalone:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahre"},withPreposition:{one:"mehr als 1 Jahr",other:"mehr als {{count}} Jahren"}},almostXYears:{standalone:{one:"fast 1 Jahr",other:"fast {{count}} Jahre"},withPreposition:{one:"fast 1 Jahr",other:"fast {{count}} Jahren"}}},FI=function(t,r,n){var i,a=n!=null&&n.addSuffix?dy[t].withPreposition:dy[t].standalone;return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",String(r)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+i:"vor "+i:i},$I={full:"EEEE, do MMMM y",long:"do MMMM y",medium:"do MMM y",short:"dd.MM.y"},BI={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},zI={full:"{{date}} 'um' {{time}}",long:"{{date}} 'um' {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},HI={date:H.buildFormatLongFn({formats:$I,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:BI,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:zI,defaultWidth:"full"})},WI={lastWeek:"'letzten' eeee 'um' p",yesterday:"'gestern um' p",today:"'heute um' p",tomorrow:"'morgen um' p",nextWeek:"eeee 'um' p",other:"P"},jI=function(t,r,n,i){return WI[t]},VI={narrow:["v.Chr.","n.Chr."],abbreviated:["v.Chr.","n.Chr."],wide:["vor Christus","nach Christus"]},UI={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1. Quartal","2. Quartal","3. Quartal","4. Quartal"]},Lp={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mär","Apr","Mai","Jun","Jul","Aug","Sep","Okt","Nov","Dez"],wide:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]},GI={narrow:Lp.narrow,abbreviated:["Jan.","Feb.","März","Apr.","Mai","Juni","Juli","Aug.","Sep.","Okt.","Nov.","Dez."],wide:Lp.wide},qI={narrow:["S","M","D","M","D","F","S"],short:["So","Mo","Di","Mi","Do","Fr","Sa"],abbreviated:["So.","Mo.","Di.","Mi.","Do.","Fr.","Sa."],wide:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"]},YI={narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachm.",evening:"Abend",night:"Nacht"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"Morgen",afternoon:"Nachmittag",evening:"Abend",night:"Nacht"}},XI={narrow:{am:"vm.",pm:"nm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachm.",evening:"abends",night:"nachts"},abbreviated:{am:"vorm.",pm:"nachm.",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"},wide:{am:"vormittags",pm:"nachmittags",midnight:"Mitternacht",noon:"Mittag",morning:"morgens",afternoon:"nachmittags",evening:"abends",night:"nachts"}},ZI=function(t){var r=Number(t);return r+"."},KI={ordinalNumber:ZI,era:H.buildLocalizeFn({values:VI,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:UI,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:Lp,formattingValues:GI,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:qI,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:YI,defaultWidth:"wide",formattingValues:XI,defaultFormattingWidth:"wide"})},QI=/^(\d+)(\.)?/i,JI=/\d+/i,e9={narrow:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,abbreviated:/^(v\.? ?Chr\.?|n\.? ?Chr\.?)/i,wide:/^(vor Christus|vor unserer Zeitrechnung|nach Christus|unserer Zeitrechnung)/i},t9={any:[/^v/i,/^n/i]},r9={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](\.)? Quartal/i},n9={any:[/1/i,/2/i,/3/i,/4/i]},i9={narrow:/^[jfmasond]/i,abbreviated:/^(j[aä]n|feb|mär[z]?|apr|mai|jun[i]?|jul[i]?|aug|sep|okt|nov|dez)\.?/i,wide:/^(januar|februar|märz|april|mai|juni|juli|august|september|oktober|november|dezember)/i},a9={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^j[aä]/i,/^f/i,/^mär/i,/^ap/i,/^mai/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},o9={narrow:/^[smdmf]/i,short:/^(so|mo|di|mi|do|fr|sa)/i,abbreviated:/^(son?|mon?|die?|mit?|don?|fre?|sam?)\.?/i,wide:/^(sonntag|montag|dienstag|mittwoch|donnerstag|freitag|samstag)/i},s9={any:[/^so/i,/^mo/i,/^di/i,/^mi/i,/^do/i,/^f/i,/^sa/i]},l9={narrow:/^(vm\.?|nm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,abbreviated:/^(vorm\.?|nachm\.?|Mitternacht|Mittag|morgens|nachm\.?|abends|nachts)/i,wide:/^(vormittags|nachmittags|Mitternacht|Mittag|morgens|nachmittags|abends|nachts)/i},u9={any:{am:/^v/i,pm:/^n/i,midnight:/^Mitte/i,noon:/^Mitta/i,morning:/morgens/i,afternoon:/nachmittags/i,evening:/abends/i,night:/nachts/i}},c9={ordinalNumber:H.buildMatchPatternFn({matchPattern:QI,parsePattern:JI,valueCallback:function(t){return parseInt(t)}}),era:H.buildMatchFn({matchPatterns:e9,defaultMatchWidth:"wide",parsePatterns:t9,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:r9,defaultMatchWidth:"wide",parsePatterns:n9,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:i9,defaultMatchWidth:"wide",parsePatterns:a9,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:o9,defaultMatchWidth:"wide",parsePatterns:s9,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:l9,defaultMatchWidth:"wide",parsePatterns:u9,defaultParseWidth:"any"})},d9={code:"de",formatDistance:FI,formatLong:HI,formatRelative:jI,localize:KI,match:c9,options:{weekStartsOn:1,firstWeekContainsDate:4}},h9={full:"EEEE, d MMMM yyyy",long:"d MMMM yyyy",medium:"d MMM yyyy",short:"dd/MM/yyyy"},f9={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},p9={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},m9={date:H.buildFormatLongFn({formats:h9,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:f9,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:p9,defaultWidth:"full"})},g9={code:"en-GB",formatDistance:H.formatDistance,formatLong:m9,formatRelative:H.formatRelative,localize:H.localize,match:H.match,options:{weekStartsOn:1,firstWeekContainsDate:4}},v9={lessThanXSeconds:{one:"menos de un segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"medio minuto",lessThanXMinutes:{one:"menos de un minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"alrededor de 1 hora",other:"alrededor de {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 día",other:"{{count}} días"},aboutXWeeks:{one:"alrededor de 1 semana",other:"alrededor de {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"alrededor de 1 mes",other:"alrededor de {{count}} meses"},xMonths:{one:"1 mes",other:"{{count}} meses"},aboutXYears:{one:"alrededor de 1 año",other:"alrededor de {{count}} años"},xYears:{one:"1 año",other:"{{count}} años"},overXYears:{one:"más de 1 año",other:"más de {{count}} años"},almostXYears:{one:"casi 1 año",other:"casi {{count}} años"}},y9=function(t,r,n){var i,a=v9[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",r.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"en "+i:"hace "+i:i},b9={full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d MMM y",short:"dd/MM/y"},_9={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},w9={full:"{{date}} 'a las' {{time}}",long:"{{date}} 'a las' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},C9={date:H.buildFormatLongFn({formats:b9,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:_9,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:w9,defaultWidth:"full"})},x9={lastWeek:"'el' eeee 'pasado a la' p",yesterday:"'ayer a la' p",today:"'hoy a la' p",tomorrow:"'mañana a la' p",nextWeek:"eeee 'a la' p",other:"P"},T9={lastWeek:"'el' eeee 'pasado a las' p",yesterday:"'ayer a las' p",today:"'hoy a las' p",tomorrow:"'mañana a las' p",nextWeek:"eeee 'a las' p",other:"P"},S9=function(t,r,n,i){return r.getUTCHours()!==1?T9[t]:x9[t]},M9={narrow:["AC","DC"],abbreviated:["AC","DC"],wide:["antes de cristo","después de cristo"]},P9={narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},E9={narrow:["e","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["ene","feb","mar","abr","may","jun","jul","ago","sep","oct","nov","dic"],wide:["enero","febrero","marzo","abril","mayo","junio","julio","agosto","septiembre","octubre","noviembre","diciembre"]},A9={narrow:["d","l","m","m","j","v","s"],short:["do","lu","ma","mi","ju","vi","sá"],abbreviated:["dom","lun","mar","mié","jue","vie","sáb"],wide:["domingo","lunes","martes","miércoles","jueves","viernes","sábado"]},R9={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"},abbreviated:{am:"AM",pm:"PM",midnight:"medianoche",noon:"mediodia",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"},wide:{am:"a.m.",pm:"p.m.",midnight:"medianoche",noon:"mediodia",morning:"mañana",afternoon:"tarde",evening:"tarde",night:"noche"}},D9={narrow:{am:"a",pm:"p",midnight:"mn",noon:"md",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"},abbreviated:{am:"AM",pm:"PM",midnight:"medianoche",noon:"mediodia",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"},wide:{am:"a.m.",pm:"p.m.",midnight:"medianoche",noon:"mediodia",morning:"de la mañana",afternoon:"de la tarde",evening:"de la tarde",night:"de la noche"}},N9=function(t,r){var n=Number(t);return n+"º"},k9={ordinalNumber:N9,era:H.buildLocalizeFn({values:M9,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:P9,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:H.buildLocalizeFn({values:E9,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:A9,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:R9,defaultWidth:"wide",formattingValues:D9,defaultFormattingWidth:"wide"})},L9=/^(\d+)(º)?/i,O9=/\d+/i,I9={narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|a\.?\s?e\.?\s?c\.?|d\.?\s?c\.?|e\.?\s?c\.?)/i,wide:/^(antes de cristo|antes de la era com[uú]n|despu[eé]s de cristo|era com[uú]n)/i},F9={any:[/^ac/i,/^dc/i],wide:[/^(antes de cristo|antes de la era com[uú]n)/i,/^(despu[eé]s de cristo|era com[uú]n)/i]},$9={narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º)? trimestre/i},B9={any:[/1/i,/2/i,/3/i,/4/i]},z9={narrow:/^[efmajsond]/i,abbreviated:/^(ene|feb|mar|abr|may|jun|jul|ago|sep|oct|nov|dic)/i,wide:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i},H9={narrow:[/^e/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^en/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i]},W9={narrow:/^[dlmjvs]/i,short:/^(do|lu|ma|mi|ju|vi|s[áa])/i,abbreviated:/^(dom|lun|mar|mi[ée]|jue|vie|s[áa]b)/i,wide:/^(domingo|lunes|martes|mi[ée]rcoles|jueves|viernes|s[áa]bado)/i},j9={narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^j/i,/^v/i,/^s/i],any:[/^do/i,/^lu/i,/^ma/i,/^mi/i,/^ju/i,/^vi/i,/^sa/i]},V9={narrow:/^(a|p|mn|md|(de la|a las) (mañana|tarde|noche))/i,any:/^([ap]\.?\s?m\.?|medianoche|mediodia|(de la|a las) (mañana|tarde|noche))/i},U9={any:{am:/^a/i,pm:/^p/i,midnight:/^mn/i,noon:/^md/i,morning:/mañana/i,afternoon:/tarde/i,evening:/tarde/i,night:/noche/i}},G9={ordinalNumber:H.buildMatchPatternFn({matchPattern:L9,parsePattern:O9,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:I9,defaultMatchWidth:"wide",parsePatterns:F9,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:$9,defaultMatchWidth:"wide",parsePatterns:B9,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:z9,defaultMatchWidth:"wide",parsePatterns:H9,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:W9,defaultMatchWidth:"wide",parsePatterns:j9,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:V9,defaultMatchWidth:"any",parsePatterns:U9,defaultParseWidth:"any"})},q9={code:"es",formatDistance:y9,formatLong:C9,formatRelative:S9,localize:k9,match:G9,options:{weekStartsOn:1,firstWeekContainsDate:1}},Y9={lessThanXSeconds:{one:"moins d’une seconde",other:"moins de {{count}} secondes"},xSeconds:{one:"1 seconde",other:"{{count}} secondes"},halfAMinute:"30 secondes",lessThanXMinutes:{one:"moins d’une minute",other:"moins de {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"environ 1 heure",other:"environ {{count}} heures"},xHours:{one:"1 heure",other:"{{count}} heures"},xDays:{one:"1 jour",other:"{{count}} jours"},aboutXWeeks:{one:"environ 1 semaine",other:"environ {{count}} semaines"},xWeeks:{one:"1 semaine",other:"{{count}} semaines"},aboutXMonths:{one:"environ 1 mois",other:"environ {{count}} mois"},xMonths:{one:"1 mois",other:"{{count}} mois"},aboutXYears:{one:"environ 1 an",other:"environ {{count}} ans"},xYears:{one:"1 an",other:"{{count}} ans"},overXYears:{one:"plus d’un an",other:"plus de {{count}} ans"},almostXYears:{one:"presqu’un an",other:"presque {{count}} ans"}},X9=function(t,r,n){var i,a=Y9[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",String(r)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"dans "+i:"il y a "+i:i},Z9={full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd/MM/y"},K9={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},Q9={full:"{{date}} 'à' {{time}}",long:"{{date}} 'à' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},J9={date:H.buildFormatLongFn({formats:Z9,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:K9,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:Q9,defaultWidth:"full"})},eF={lastWeek:"eeee 'dernier à' p",yesterday:"'hier à' p",today:"'aujourd’hui à' p",tomorrow:"'demain à' p'",nextWeek:"eeee 'prochain à' p",other:"P"},tF=function(t,r,n,i){return eF[t]},rF={narrow:["av. J.-C","ap. J.-C"],abbreviated:["av. J.-C","ap. J.-C"],wide:["avant Jésus-Christ","après Jésus-Christ"]},nF={narrow:["T1","T2","T3","T4"],abbreviated:["1er trim.","2ème trim.","3ème trim.","4ème trim."],wide:["1er trimestre","2ème trimestre","3ème trimestre","4ème trimestre"]},iF={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["janv.","févr.","mars","avr.","mai","juin","juil.","août","sept.","oct.","nov.","déc."],wide:["janvier","février","mars","avril","mai","juin","juillet","août","septembre","octobre","novembre","décembre"]},aF={narrow:["D","L","M","M","J","V","S"],short:["di","lu","ma","me","je","ve","sa"],abbreviated:["dim.","lun.","mar.","mer.","jeu.","ven.","sam."],wide:["dimanche","lundi","mardi","mercredi","jeudi","vendredi","samedi"]},oF={narrow:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"mat.",afternoon:"ap.m.",evening:"soir",night:"mat."},abbreviated:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"matin",afternoon:"après-midi",evening:"soir",night:"matin"},wide:{am:"AM",pm:"PM",midnight:"minuit",noon:"midi",morning:"du matin",afternoon:"de l’après-midi",evening:"du soir",night:"du matin"}},sF=function(t,r){var n=Number(t),i=r==null?void 0:r.unit;if(n===0)return"0";var a=["year","week","hour","minute","second"],o;return n===1?o=i&&a.includes(i)?"ère":"er":o="ème",n+o},lF={ordinalNumber:sF,era:H.buildLocalizeFn({values:rF,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:nF,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:iF,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:aF,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:oF,defaultWidth:"wide"})},uF=/^(\d+)(ième|ère|ème|er|e)?/i,cF=/\d+/i,dF={narrow:/^(av\.J\.C|ap\.J\.C|ap\.J\.-C)/i,abbreviated:/^(av\.J\.-C|av\.J-C|apr\.J\.-C|apr\.J-C|ap\.J-C)/i,wide:/^(avant Jésus-Christ|après Jésus-Christ)/i},hF={any:[/^av/i,/^ap/i]},fF={narrow:/^T?[1234]/i,abbreviated:/^[1234](er|ème|e)? trim\.?/i,wide:/^[1234](er|ème|e)? trimestre/i},pF={any:[/1/i,/2/i,/3/i,/4/i]},mF={narrow:/^[jfmasond]/i,abbreviated:/^(janv|févr|mars|avr|mai|juin|juill|juil|août|sept|oct|nov|déc)\.?/i,wide:/^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i},gF={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^av/i,/^ma/i,/^juin/i,/^juil/i,/^ao/i,/^s/i,/^o/i,/^n/i,/^d/i]},vF={narrow:/^[lmjvsd]/i,short:/^(di|lu|ma|me|je|ve|sa)/i,abbreviated:/^(dim|lun|mar|mer|jeu|ven|sam)\.?/i,wide:/^(dimanche|lundi|mardi|mercredi|jeudi|vendredi|samedi)/i},yF={narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^j/i,/^v/i,/^s/i],any:[/^di/i,/^lu/i,/^ma/i,/^me/i,/^je/i,/^ve/i,/^sa/i]},bF={narrow:/^(a|p|minuit|midi|mat\.?|ap\.?m\.?|soir|nuit)/i,any:/^([ap]\.?\s?m\.?|du matin|de l'après[-\s]midi|du soir|de la nuit)/i},_F={any:{am:/^a/i,pm:/^p/i,midnight:/^min/i,noon:/^mid/i,morning:/mat/i,afternoon:/ap/i,evening:/soir/i,night:/nuit/i}},wF={ordinalNumber:H.buildMatchPatternFn({matchPattern:uF,parsePattern:cF,valueCallback:function(t){return parseInt(t)}}),era:H.buildMatchFn({matchPatterns:dF,defaultMatchWidth:"wide",parsePatterns:hF,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:fF,defaultMatchWidth:"wide",parsePatterns:pF,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:mF,defaultMatchWidth:"wide",parsePatterns:gF,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:vF,defaultMatchWidth:"wide",parsePatterns:yF,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:bF,defaultMatchWidth:"any",parsePatterns:_F,defaultParseWidth:"any"})},CF={code:"fr",formatDistance:X9,formatLong:J9,formatRelative:tF,localize:lF,match:wF,options:{weekStartsOn:1,firstWeekContainsDate:4}},xF={lessThanXSeconds:{one:"meno di un secondo",other:"meno di {{count}} secondi"},xSeconds:{one:"un secondo",other:"{{count}} secondi"},halfAMinute:"alcuni secondi",lessThanXMinutes:{one:"meno di un minuto",other:"meno di {{count}} minuti"},xMinutes:{one:"un minuto",other:"{{count}} minuti"},aboutXHours:{one:"circa un'ora",other:"circa {{count}} ore"},xHours:{one:"un'ora",other:"{{count}} ore"},xDays:{one:"un giorno",other:"{{count}} giorni"},aboutXWeeks:{one:"circa una settimana",other:"circa {{count}} settimane"},xWeeks:{one:"una settimana",other:"{{count}} settimane"},aboutXMonths:{one:"circa un mese",other:"circa {{count}} mesi"},xMonths:{one:"un mese",other:"{{count}} mesi"},aboutXYears:{one:"circa un anno",other:"circa {{count}} anni"},xYears:{one:"un anno",other:"{{count}} anni"},overXYears:{one:"più di un anno",other:"più di {{count}} anni"},almostXYears:{one:"quasi un anno",other:"quasi {{count}} anni"}},TF=function(t,r,n){var i,a=xF[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",r.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"tra "+i:i+" fa":i},SF={full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd/MM/y"},MF={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},PF={full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},EF={date:H.buildFormatLongFn({formats:SF,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:MF,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:PF,defaultWidth:"full"})},P0=["domenica","lunedì","martedì","mercoledì","giovedì","venerdì","sabato"];function AF(e){switch(e){case 0:return"'domenica scorsa alle' p";default:return"'"+P0[e]+" scorso alle' p"}}function hy(e){return"'"+P0[e]+" alle' p"}function RF(e){switch(e){case 0:return"'domenica prossima alle' p";default:return"'"+P0[e]+" prossimo alle' p"}}var DF={lastWeek:function(t,r,n){var i=t.getUTCDay();return ki(t,r,n)?hy(i):AF(i)},yesterday:"'ieri alle' p",today:"'oggi alle' p",tomorrow:"'domani alle' p",nextWeek:function(t,r,n){var i=t.getUTCDay();return ki(t,r,n)?hy(i):RF(i)},other:"P"},NF=function(t,r,n,i){var a=DF[t];return typeof a=="function"?a(r,n,i):a},kF={narrow:["aC","dC"],abbreviated:["a.C.","d.C."],wide:["avanti Cristo","dopo Cristo"]},LF={narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},OF={narrow:["G","F","M","A","M","G","L","A","S","O","N","D"],abbreviated:["gen","feb","mar","apr","mag","giu","lug","ago","set","ott","nov","dic"],wide:["gennaio","febbraio","marzo","aprile","maggio","giugno","luglio","agosto","settembre","ottobre","novembre","dicembre"]},IF={narrow:["D","L","M","M","G","V","S"],short:["dom","lun","mar","mer","gio","ven","sab"],abbreviated:["dom","lun","mar","mer","gio","ven","sab"],wide:["domenica","lunedì","martedì","mercoledì","giovedì","venerdì","sabato"]},FF={narrow:{am:"m.",pm:"p.",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"},abbreviated:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"},wide:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"mattina",afternoon:"pomeriggio",evening:"sera",night:"notte"}},$F={narrow:{am:"m.",pm:"p.",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"},abbreviated:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"},wide:{am:"AM",pm:"PM",midnight:"mezzanotte",noon:"mezzogiorno",morning:"di mattina",afternoon:"del pomeriggio",evening:"di sera",night:"di notte"}},BF=function(t,r){var n=Number(t);return String(n)},zF={ordinalNumber:BF,era:H.buildLocalizeFn({values:kF,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:LF,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:OF,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:IF,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:FF,defaultWidth:"wide",formattingValues:$F,defaultFormattingWidth:"wide"})},HF=/^(\d+)(º)?/i,WF=/\d+/i,jF={narrow:/^(aC|dC)/i,abbreviated:/^(a\.?\s?C\.?|a\.?\s?e\.?\s?v\.?|d\.?\s?C\.?|e\.?\s?v\.?)/i,wide:/^(avanti Cristo|avanti Era Volgare|dopo Cristo|Era Volgare)/i},VF={any:[/^a/i,/^(d|e)/i]},UF={narrow:/^[1234]/i,abbreviated:/^t[1234]/i,wide:/^[1234](º)? trimestre/i},GF={any:[/1/i,/2/i,/3/i,/4/i]},qF={narrow:/^[gfmalsond]/i,abbreviated:/^(gen|feb|mar|apr|mag|giu|lug|ago|set|ott|nov|dic)/i,wide:/^(gennaio|febbraio|marzo|aprile|maggio|giugno|luglio|agosto|settembre|ottobre|novembre|dicembre)/i},YF={narrow:[/^g/i,/^f/i,/^m/i,/^a/i,/^m/i,/^g/i,/^l/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ge/i,/^f/i,/^mar/i,/^ap/i,/^mag/i,/^gi/i,/^l/i,/^ag/i,/^s/i,/^o/i,/^n/i,/^d/i]},XF={narrow:/^[dlmgvs]/i,short:/^(do|lu|ma|me|gi|ve|sa)/i,abbreviated:/^(dom|lun|mar|mer|gio|ven|sab)/i,wide:/^(domenica|luned[i|ì]|marted[i|ì]|mercoled[i|ì]|gioved[i|ì]|venerd[i|ì]|sabato)/i},ZF={narrow:[/^d/i,/^l/i,/^m/i,/^m/i,/^g/i,/^v/i,/^s/i],any:[/^d/i,/^l/i,/^ma/i,/^me/i,/^g/i,/^v/i,/^s/i]},KF={narrow:/^(a|m\.|p|mezzanotte|mezzogiorno|(di|del) (mattina|pomeriggio|sera|notte))/i,any:/^([ap]\.?\s?m\.?|mezzanotte|mezzogiorno|(di|del) (mattina|pomeriggio|sera|notte))/i},QF={any:{am:/^a/i,pm:/^p/i,midnight:/^mezza/i,noon:/^mezzo/i,morning:/mattina/i,afternoon:/pomeriggio/i,evening:/sera/i,night:/notte/i}},JF={ordinalNumber:H.buildMatchPatternFn({matchPattern:HF,parsePattern:WF,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:jF,defaultMatchWidth:"wide",parsePatterns:VF,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:UF,defaultMatchWidth:"wide",parsePatterns:GF,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:qF,defaultMatchWidth:"wide",parsePatterns:YF,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:XF,defaultMatchWidth:"wide",parsePatterns:ZF,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:KF,defaultMatchWidth:"any",parsePatterns:QF,defaultParseWidth:"any"})},e$={code:"it",formatDistance:TF,formatLong:EF,formatRelative:NF,localize:zF,match:JF,options:{weekStartsOn:1,firstWeekContainsDate:4}},t$={lessThanXSeconds:{one:"1秒未満",other:"{{count}}秒未満",oneWithSuffix:"約1秒",otherWithSuffix:"約{{count}}秒"},xSeconds:{one:"1秒",other:"{{count}}秒"},halfAMinute:"30秒",lessThanXMinutes:{one:"1分未満",other:"{{count}}分未満",oneWithSuffix:"約1分",otherWithSuffix:"約{{count}}分"},xMinutes:{one:"1分",other:"{{count}}分"},aboutXHours:{one:"約1時間",other:"約{{count}}時間"},xHours:{one:"1時間",other:"{{count}}時間"},xDays:{one:"1日",other:"{{count}}日"},aboutXWeeks:{one:"約1週間",other:"約{{count}}週間"},xWeeks:{one:"1週間",other:"{{count}}週間"},aboutXMonths:{one:"約1か月",other:"約{{count}}か月"},xMonths:{one:"1か月",other:"{{count}}か月"},aboutXYears:{one:"約1年",other:"約{{count}}年"},xYears:{one:"1年",other:"{{count}}年"},overXYears:{one:"1年以上",other:"{{count}}年以上"},almostXYears:{one:"1年近く",other:"{{count}}年近く"}},r$=function(t,r,n){n=n||{};var i,a=t$[t];return typeof a=="string"?i=a:r===1?n.addSuffix&&a.oneWithSuffix?i=a.oneWithSuffix:i=a.one:n.addSuffix&&a.otherWithSuffix?i=a.otherWithSuffix.replace("{{count}}",String(r)):i=a.other.replace("{{count}}",String(r)),n.addSuffix?n.comparison&&n.comparison>0?i+"後":i+"前":i},n$={full:"y年M月d日EEEE",long:"y年M月d日",medium:"y/MM/dd",short:"y/MM/dd"},i$={full:"H時mm分ss秒 zzzz",long:"H:mm:ss z",medium:"H:mm:ss",short:"H:mm"},a$={full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},o$={date:H.buildFormatLongFn({formats:n$,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:i$,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:a$,defaultWidth:"full"})},s$={lastWeek:"先週のeeeeのp",yesterday:"昨日のp",today:"今日のp",tomorrow:"明日のp",nextWeek:"翌週のeeeeのp",other:"P"},l$=function(t,r,n,i){return s$[t]},u$={narrow:["BC","AC"],abbreviated:["紀元前","西暦"],wide:["紀元前","西暦"]},c$={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["第1四半期","第2四半期","第3四半期","第4四半期"]},d$={narrow:["1","2","3","4","5","6","7","8","9","10","11","12"],abbreviated:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],wide:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"]},h$={narrow:["日","月","火","水","木","金","土"],short:["日","月","火","水","木","金","土"],abbreviated:["日","月","火","水","木","金","土"],wide:["日曜日","月曜日","火曜日","水曜日","木曜日","金曜日","土曜日"]},f$={narrow:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},abbreviated:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},wide:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"}},p$={narrow:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},abbreviated:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"},wide:{am:"午前",pm:"午後",midnight:"深夜",noon:"正午",morning:"朝",afternoon:"午後",evening:"夜",night:"深夜"}},m$=function(t,r){var n=Number(t),i=String(r==null?void 0:r.unit);switch(i){case"year":return"".concat(n,"年");case"quarter":return"第".concat(n,"四半期");case"month":return"".concat(n,"月");case"week":return"第".concat(n,"週");case"date":return"".concat(n,"日");case"hour":return"".concat(n,"時");case"minute":return"".concat(n,"分");case"second":return"".concat(n,"秒");default:return"".concat(n)}},g$={ordinalNumber:m$,era:H.buildLocalizeFn({values:u$,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:c$,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:H.buildLocalizeFn({values:d$,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:h$,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:f$,defaultWidth:"wide",formattingValues:p$,defaultFormattingWidth:"wide"})},v$=/^第?\d+(年|四半期|月|週|日|時|分|秒)?/i,y$=/\d+/i,b$={narrow:/^(B\.?C\.?|A\.?D\.?)/i,abbreviated:/^(紀元[前後]|西暦)/i,wide:/^(紀元[前後]|西暦)/i},_$={narrow:[/^B/i,/^A/i],any:[/^(紀元前)/i,/^(西暦|紀元後)/i]},w$={narrow:/^[1234]/i,abbreviated:/^Q[1234]/i,wide:/^第[1234一二三四1234]四半期/i},C$={any:[/(1|一|1)/i,/(2|二|2)/i,/(3|三|3)/i,/(4|四|4)/i]},x$={narrow:/^([123456789]|1[012])/,abbreviated:/^([123456789]|1[012])月/i,wide:/^([123456789]|1[012])月/i},T$={any:[/^1\D/,/^2/,/^3/,/^4/,/^5/,/^6/,/^7/,/^8/,/^9/,/^10/,/^11/,/^12/]},S$={narrow:/^[日月火水木金土]/,short:/^[日月火水木金土]/,abbreviated:/^[日月火水木金土]/,wide:/^[日月火水木金土]曜日/},M$={any:[/^日/,/^月/,/^火/,/^水/,/^木/,/^金/,/^土/]},P$={any:/^(AM|PM|午前|午後|正午|深夜|真夜中|夜|朝)/i},E$={any:{am:/^(A|午前)/i,pm:/^(P|午後)/i,midnight:/^深夜|真夜中/i,noon:/^正午/i,morning:/^朝/i,afternoon:/^午後/i,evening:/^夜/i,night:/^深夜/i}},A$={ordinalNumber:H.buildMatchPatternFn({matchPattern:v$,parsePattern:y$,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:b$,defaultMatchWidth:"wide",parsePatterns:_$,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:w$,defaultMatchWidth:"wide",parsePatterns:C$,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:x$,defaultMatchWidth:"wide",parsePatterns:T$,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:S$,defaultMatchWidth:"wide",parsePatterns:M$,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:P$,defaultMatchWidth:"any",parsePatterns:E$,defaultParseWidth:"any"})},R$={code:"ja",formatDistance:r$,formatLong:o$,formatRelative:l$,localize:g$,match:A$,options:{weekStartsOn:0,firstWeekContainsDate:1}},D$={lessThanXSeconds:{one:"1초 미만",other:"{{count}}초 미만"},xSeconds:{one:"1초",other:"{{count}}초"},halfAMinute:"30초",lessThanXMinutes:{one:"1분 미만",other:"{{count}}분 미만"},xMinutes:{one:"1분",other:"{{count}}분"},aboutXHours:{one:"약 1시간",other:"약 {{count}}시간"},xHours:{one:"1시간",other:"{{count}}시간"},xDays:{one:"1일",other:"{{count}}일"},aboutXWeeks:{one:"약 1주",other:"약 {{count}}주"},xWeeks:{one:"1주",other:"{{count}}주"},aboutXMonths:{one:"약 1개월",other:"약 {{count}}개월"},xMonths:{one:"1개월",other:"{{count}}개월"},aboutXYears:{one:"약 1년",other:"약 {{count}}년"},xYears:{one:"1년",other:"{{count}}년"},overXYears:{one:"1년 이상",other:"{{count}}년 이상"},almostXYears:{one:"거의 1년",other:"거의 {{count}}년"}},N$=function(t,r,n){var i,a=D$[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",r.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?i+" 후":i+" 전":i},k$={full:"y년 M월 d일 EEEE",long:"y년 M월 d일",medium:"y.MM.dd",short:"y.MM.dd"},L$={full:"a H시 mm분 ss초 zzzz",long:"a H:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},O$={full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},I$={date:H.buildFormatLongFn({formats:k$,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:L$,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:O$,defaultWidth:"full"})},F$={lastWeek:"'지난' eeee p",yesterday:"'어제' p",today:"'오늘' p",tomorrow:"'내일' p",nextWeek:"'다음' eeee p",other:"P"},$$=function(t,r,n,i){return F$[t]},B$={narrow:["BC","AD"],abbreviated:["BC","AD"],wide:["기원전","서기"]},z$={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1분기","2분기","3분기","4분기"]},H$={narrow:["1","2","3","4","5","6","7","8","9","10","11","12"],abbreviated:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"],wide:["1월","2월","3월","4월","5월","6월","7월","8월","9월","10월","11월","12월"]},W$={narrow:["일","월","화","수","목","금","토"],short:["일","월","화","수","목","금","토"],abbreviated:["일","월","화","수","목","금","토"],wide:["일요일","월요일","화요일","수요일","목요일","금요일","토요일"]},j$={narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},V$={narrow:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},abbreviated:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"},wide:{am:"오전",pm:"오후",midnight:"자정",noon:"정오",morning:"아침",afternoon:"오후",evening:"저녁",night:"밤"}},U$=function(t,r){var n=Number(t),i=String(r==null?void 0:r.unit);switch(i){case"minute":case"second":return String(n);case"date":return n+"일";default:return n+"번째"}},G$={ordinalNumber:U$,era:H.buildLocalizeFn({values:B$,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:z$,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:H$,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:W$,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:j$,defaultWidth:"wide",formattingValues:V$,defaultFormattingWidth:"wide"})},q$=/^(\d+)(일|번째)?/i,Y$=/\d+/i,X$={narrow:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(기원전|서기)/i},Z$={any:[/^(bc|기원전)/i,/^(ad|서기)/i]},K$={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234]사?분기/i},Q$={any:[/1/i,/2/i,/3/i,/4/i]},J$={narrow:/^(1[012]|[123456789])/,abbreviated:/^(1[012]|[123456789])월/i,wide:/^(1[012]|[123456789])월/i},eB={any:[/^1월?$/,/^2/,/^3/,/^4/,/^5/,/^6/,/^7/,/^8/,/^9/,/^10/,/^11/,/^12/]},tB={narrow:/^[일월화수목금토]/,short:/^[일월화수목금토]/,abbreviated:/^[일월화수목금토]/,wide:/^[일월화수목금토]요일/},rB={any:[/^일/,/^월/,/^화/,/^수/,/^목/,/^금/,/^토/]},nB={any:/^(am|pm|오전|오후|자정|정오|아침|저녁|밤)/i},iB={any:{am:/^(am|오전)/i,pm:/^(pm|오후)/i,midnight:/^자정/i,noon:/^정오/i,morning:/^아침/i,afternoon:/^오후/i,evening:/^저녁/i,night:/^밤/i}},aB={ordinalNumber:H.buildMatchPatternFn({matchPattern:q$,parsePattern:Y$,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:X$,defaultMatchWidth:"wide",parsePatterns:Z$,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:K$,defaultMatchWidth:"wide",parsePatterns:Q$,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:J$,defaultMatchWidth:"wide",parsePatterns:eB,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:tB,defaultMatchWidth:"wide",parsePatterns:rB,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:nB,defaultMatchWidth:"any",parsePatterns:iB,defaultParseWidth:"any"})},oB={code:"ko",formatDistance:N$,formatLong:I$,formatRelative:$$,localize:G$,match:aB,options:{weekStartsOn:0,firstWeekContainsDate:1}},sB={lessThanXSeconds:{one:"minder dan een seconde",other:"minder dan {{count}} seconden"},xSeconds:{one:"1 seconde",other:"{{count}} seconden"},halfAMinute:"een halve minuut",lessThanXMinutes:{one:"minder dan een minuut",other:"minder dan {{count}} minuten"},xMinutes:{one:"een minuut",other:"{{count}} minuten"},aboutXHours:{one:"ongeveer 1 uur",other:"ongeveer {{count}} uur"},xHours:{one:"1 uur",other:"{{count}} uur"},xDays:{one:"1 dag",other:"{{count}} dagen"},aboutXWeeks:{one:"ongeveer 1 week",other:"ongeveer {{count}} weken"},xWeeks:{one:"1 week",other:"{{count}} weken"},aboutXMonths:{one:"ongeveer 1 maand",other:"ongeveer {{count}} maanden"},xMonths:{one:"1 maand",other:"{{count}} maanden"},aboutXYears:{one:"ongeveer 1 jaar",other:"ongeveer {{count}} jaar"},xYears:{one:"1 jaar",other:"{{count}} jaar"},overXYears:{one:"meer dan 1 jaar",other:"meer dan {{count}} jaar"},almostXYears:{one:"bijna 1 jaar",other:"bijna {{count}} jaar"}},lB=function(t,r,n){var i,a=sB[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",String(r)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"over "+i:i+" geleden":i},uB={full:"EEEE d MMMM y",long:"d MMMM y",medium:"d MMM y",short:"dd-MM-y"},cB={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},dB={full:"{{date}} 'om' {{time}}",long:"{{date}} 'om' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},hB={date:H.buildFormatLongFn({formats:uB,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:cB,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:dB,defaultWidth:"full"})},fB={lastWeek:"'afgelopen' eeee 'om' p",yesterday:"'gisteren om' p",today:"'vandaag om' p",tomorrow:"'morgen om' p",nextWeek:"eeee 'om' p",other:"P"},pB=function(t,r,n,i){return fB[t]},mB={narrow:["v.C.","n.C."],abbreviated:["v.Chr.","n.Chr."],wide:["voor Christus","na Christus"]},gB={narrow:["1","2","3","4"],abbreviated:["K1","K2","K3","K4"],wide:["1e kwartaal","2e kwartaal","3e kwartaal","4e kwartaal"]},vB={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["jan.","feb.","mrt.","apr.","mei","jun.","jul.","aug.","sep.","okt.","nov.","dec."],wide:["januari","februari","maart","april","mei","juni","juli","augustus","september","oktober","november","december"]},yB={narrow:["Z","M","D","W","D","V","Z"],short:["zo","ma","di","wo","do","vr","za"],abbreviated:["zon","maa","din","woe","don","vri","zat"],wide:["zondag","maandag","dinsdag","woensdag","donderdag","vrijdag","zaterdag"]},bB={narrow:{am:"AM",pm:"PM",midnight:"middernacht",noon:"het middaguur",morning:"'s ochtends",afternoon:"'s middags",evening:"'s avonds",night:"'s nachts"},abbreviated:{am:"AM",pm:"PM",midnight:"middernacht",noon:"het middaguur",morning:"'s ochtends",afternoon:"'s middags",evening:"'s avonds",night:"'s nachts"},wide:{am:"AM",pm:"PM",midnight:"middernacht",noon:"het middaguur",morning:"'s ochtends",afternoon:"'s middags",evening:"'s avonds",night:"'s nachts"}},_B=function(t,r){var n=Number(t);return n+"e"},wB={ordinalNumber:_B,era:H.buildLocalizeFn({values:mB,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:gB,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:vB,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:yB,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:bB,defaultWidth:"wide"})},CB=/^(\d+)e?/i,xB=/\d+/i,TB={narrow:/^([vn]\.? ?C\.?)/,abbreviated:/^([vn]\. ?Chr\.?)/,wide:/^((voor|na) Christus)/},SB={any:[/^v/,/^n/]},MB={narrow:/^[1234]/i,abbreviated:/^K[1234]/i,wide:/^[1234]e kwartaal/i},PB={any:[/1/i,/2/i,/3/i,/4/i]},EB={narrow:/^[jfmasond]/i,abbreviated:/^(jan.|feb.|mrt.|apr.|mei|jun.|jul.|aug.|sep.|okt.|nov.|dec.)/i,wide:/^(januari|februari|maart|april|mei|juni|juli|augustus|september|oktober|november|december)/i},AB={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^jan/i,/^feb/i,/^m(r|a)/i,/^apr/i,/^mei/i,/^jun/i,/^jul/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i]},RB={narrow:/^[zmdwv]/i,short:/^(zo|ma|di|wo|do|vr|za)/i,abbreviated:/^(zon|maa|din|woe|don|vri|zat)/i,wide:/^(zondag|maandag|dinsdag|woensdag|donderdag|vrijdag|zaterdag)/i},DB={narrow:[/^z/i,/^m/i,/^d/i,/^w/i,/^d/i,/^v/i,/^z/i],any:[/^zo/i,/^ma/i,/^di/i,/^wo/i,/^do/i,/^vr/i,/^za/i]},NB={any:/^(am|pm|middernacht|het middaguur|'s (ochtends|middags|avonds|nachts))/i},kB={any:{am:/^am/i,pm:/^pm/i,midnight:/^middernacht/i,noon:/^het middaguur/i,morning:/ochtend/i,afternoon:/middag/i,evening:/avond/i,night:/nacht/i}},LB={ordinalNumber:H.buildMatchPatternFn({matchPattern:CB,parsePattern:xB,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:TB,defaultMatchWidth:"wide",parsePatterns:SB,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:MB,defaultMatchWidth:"wide",parsePatterns:PB,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:EB,defaultMatchWidth:"wide",parsePatterns:AB,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:RB,defaultMatchWidth:"wide",parsePatterns:DB,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:NB,defaultMatchWidth:"any",parsePatterns:kB,defaultParseWidth:"any"})},OB={code:"nl",formatDistance:lB,formatLong:hB,formatRelative:pB,localize:wB,match:LB,options:{weekStartsOn:1,firstWeekContainsDate:4}},IB={lessThanXSeconds:{one:"menos de um segundo",other:"menos de {{count}} segundos"},xSeconds:{one:"1 segundo",other:"{{count}} segundos"},halfAMinute:"meio minuto",lessThanXMinutes:{one:"menos de um minuto",other:"menos de {{count}} minutos"},xMinutes:{one:"1 minuto",other:"{{count}} minutos"},aboutXHours:{one:"aproximadamente 1 hora",other:"aproximadamente {{count}} horas"},xHours:{one:"1 hora",other:"{{count}} horas"},xDays:{one:"1 dia",other:"{{count}} dias"},aboutXWeeks:{one:"aproximadamente 1 semana",other:"aproximadamente {{count}} semanas"},xWeeks:{one:"1 semana",other:"{{count}} semanas"},aboutXMonths:{one:"aproximadamente 1 mês",other:"aproximadamente {{count}} meses"},xMonths:{one:"1 mês",other:"{{count}} meses"},aboutXYears:{one:"aproximadamente 1 ano",other:"aproximadamente {{count}} anos"},xYears:{one:"1 ano",other:"{{count}} anos"},overXYears:{one:"mais de 1 ano",other:"mais de {{count}} anos"},almostXYears:{one:"quase 1 ano",other:"quase {{count}} anos"}},FB=function(t,r,n){var i,a=IB[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",String(r)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"daqui a "+i:"há "+i:i},$B={full:"EEEE, d 'de' MMMM 'de' y",long:"d 'de' MMMM 'de' y",medium:"d 'de' MMM 'de' y",short:"dd/MM/y"},BB={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},zB={full:"{{date}} 'às' {{time}}",long:"{{date}} 'às' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},HB={date:H.buildFormatLongFn({formats:$B,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:BB,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:zB,defaultWidth:"full"})},WB={lastWeek:function(t){var r=t.getUTCDay(),n=r===0||r===6?"último":"última";return"'"+n+"' eeee 'às' p"},yesterday:"'ontem às' p",today:"'hoje às' p",tomorrow:"'amanhã às' p",nextWeek:"eeee 'às' p",other:"P"},jB=function(t,r,n,i){var a=WB[t];return typeof a=="function"?a(r):a},VB={narrow:["aC","dC"],abbreviated:["a.C.","d.C."],wide:["antes de Cristo","depois de Cristo"]},UB={narrow:["1","2","3","4"],abbreviated:["T1","T2","T3","T4"],wide:["1º trimestre","2º trimestre","3º trimestre","4º trimestre"]},GB={narrow:["j","f","m","a","m","j","j","a","s","o","n","d"],abbreviated:["jan","fev","mar","abr","mai","jun","jul","ago","set","out","nov","dez"],wide:["janeiro","fevereiro","março","abril","maio","junho","julho","agosto","setembro","outubro","novembro","dezembro"]},qB={narrow:["d","s","t","q","q","s","s"],short:["dom","seg","ter","qua","qui","sex","sáb"],abbreviated:["dom","seg","ter","qua","qui","sex","sáb"],wide:["domingo","segunda-feira","terça-feira","quarta-feira","quinta-feira","sexta-feira","sábado"]},YB={narrow:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"},wide:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"manhã",afternoon:"tarde",evening:"noite",night:"madrugada"}},XB={narrow:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"},abbreviated:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"},wide:{am:"AM",pm:"PM",midnight:"meia-noite",noon:"meio-dia",morning:"da manhã",afternoon:"da tarde",evening:"da noite",night:"da madrugada"}},ZB=function(t,r){var n=Number(t);return n+"º"},KB={ordinalNumber:ZB,era:H.buildLocalizeFn({values:VB,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:UB,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:GB,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:qB,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:YB,defaultWidth:"wide",formattingValues:XB,defaultFormattingWidth:"wide"})},QB=/^(\d+)(º|ª)?/i,JB=/\d+/i,ez={narrow:/^(ac|dc|a|d)/i,abbreviated:/^(a\.?\s?c\.?|a\.?\s?e\.?\s?c\.?|d\.?\s?c\.?|e\.?\s?c\.?)/i,wide:/^(antes de cristo|antes da era comum|depois de cristo|era comum)/i},tz={any:[/^ac/i,/^dc/i],wide:[/^(antes de cristo|antes da era comum)/i,/^(depois de cristo|era comum)/i]},rz={narrow:/^[1234]/i,abbreviated:/^T[1234]/i,wide:/^[1234](º|ª)? trimestre/i},nz={any:[/1/i,/2/i,/3/i,/4/i]},iz={narrow:/^[jfmasond]/i,abbreviated:/^(jan|fev|mar|abr|mai|jun|jul|ago|set|out|nov|dez)/i,wide:/^(janeiro|fevereiro|março|abril|maio|junho|julho|agosto|setembro|outubro|novembro|dezembro)/i},az={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ab/i,/^mai/i,/^jun/i,/^jul/i,/^ag/i,/^s/i,/^o/i,/^n/i,/^d/i]},oz={narrow:/^[dstq]/i,short:/^(dom|seg|ter|qua|qui|sex|s[áa]b)/i,abbreviated:/^(dom|seg|ter|qua|qui|sex|s[áa]b)/i,wide:/^(domingo|segunda-?\s?feira|terça-?\s?feira|quarta-?\s?feira|quinta-?\s?feira|sexta-?\s?feira|s[áa]bado)/i},sz={narrow:[/^d/i,/^s/i,/^t/i,/^q/i,/^q/i,/^s/i,/^s/i],any:[/^d/i,/^seg/i,/^t/i,/^qua/i,/^qui/i,/^sex/i,/^s[áa]/i]},lz={narrow:/^(a|p|meia-?\s?noite|meio-?\s?dia|(da) (manh[ãa]|tarde|noite|madrugada))/i,any:/^([ap]\.?\s?m\.?|meia-?\s?noite|meio-?\s?dia|(da) (manh[ãa]|tarde|noite|madrugada))/i},uz={any:{am:/^a/i,pm:/^p/i,midnight:/^meia/i,noon:/^meio/i,morning:/manh[ãa]/i,afternoon:/tarde/i,evening:/noite/i,night:/madrugada/i}},cz={ordinalNumber:H.buildMatchPatternFn({matchPattern:QB,parsePattern:JB,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:ez,defaultMatchWidth:"wide",parsePatterns:tz,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:rz,defaultMatchWidth:"wide",parsePatterns:nz,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:iz,defaultMatchWidth:"wide",parsePatterns:az,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:oz,defaultMatchWidth:"wide",parsePatterns:sz,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:lz,defaultMatchWidth:"any",parsePatterns:uz,defaultParseWidth:"any"})},dz={code:"pt",formatDistance:FB,formatLong:HB,formatRelative:jB,localize:KB,match:cz,options:{weekStartsOn:1,firstWeekContainsDate:4}};function Ho(e,t){if(e.one!==void 0&&t===1)return e.one;var r=t%10,n=t%100;return r===1&&n!==11?e.singularNominative.replace("{{count}}",String(t)):r>=2&&r<=4&&(n<10||n>20)?e.singularGenitive.replace("{{count}}",String(t)):e.pluralGenitive.replace("{{count}}",String(t))}function tr(e){return function(t,r){return r!=null&&r.addSuffix?r.comparison&&r.comparison>0?e.future?Ho(e.future,t):"через "+Ho(e.regular,t):e.past?Ho(e.past,t):Ho(e.regular,t)+" назад":Ho(e.regular,t)}}var hz={lessThanXSeconds:tr({regular:{one:"меньше секунды",singularNominative:"меньше {{count}} секунды",singularGenitive:"меньше {{count}} секунд",pluralGenitive:"меньше {{count}} секунд"},future:{one:"меньше, чем через секунду",singularNominative:"меньше, чем через {{count}} секунду",singularGenitive:"меньше, чем через {{count}} секунды",pluralGenitive:"меньше, чем через {{count}} секунд"}}),xSeconds:tr({regular:{singularNominative:"{{count}} секунда",singularGenitive:"{{count}} секунды",pluralGenitive:"{{count}} секунд"},past:{singularNominative:"{{count}} секунду назад",singularGenitive:"{{count}} секунды назад",pluralGenitive:"{{count}} секунд назад"},future:{singularNominative:"через {{count}} секунду",singularGenitive:"через {{count}} секунды",pluralGenitive:"через {{count}} секунд"}}),halfAMinute:function(t,r){return r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"через полминуты":"полминуты назад":"полминуты"},lessThanXMinutes:tr({regular:{one:"меньше минуты",singularNominative:"меньше {{count}} минуты",singularGenitive:"меньше {{count}} минут",pluralGenitive:"меньше {{count}} минут"},future:{one:"меньше, чем через минуту",singularNominative:"меньше, чем через {{count}} минуту",singularGenitive:"меньше, чем через {{count}} минуты",pluralGenitive:"меньше, чем через {{count}} минут"}}),xMinutes:tr({regular:{singularNominative:"{{count}} минута",singularGenitive:"{{count}} минуты",pluralGenitive:"{{count}} минут"},past:{singularNominative:"{{count}} минуту назад",singularGenitive:"{{count}} минуты назад",pluralGenitive:"{{count}} минут назад"},future:{singularNominative:"через {{count}} минуту",singularGenitive:"через {{count}} минуты",pluralGenitive:"через {{count}} минут"}}),aboutXHours:tr({regular:{singularNominative:"около {{count}} часа",singularGenitive:"около {{count}} часов",pluralGenitive:"около {{count}} часов"},future:{singularNominative:"приблизительно через {{count}} час",singularGenitive:"приблизительно через {{count}} часа",pluralGenitive:"приблизительно через {{count}} часов"}}),xHours:tr({regular:{singularNominative:"{{count}} час",singularGenitive:"{{count}} часа",pluralGenitive:"{{count}} часов"}}),xDays:tr({regular:{singularNominative:"{{count}} день",singularGenitive:"{{count}} дня",pluralGenitive:"{{count}} дней"}}),aboutXWeeks:tr({regular:{singularNominative:"около {{count}} недели",singularGenitive:"около {{count}} недель",pluralGenitive:"около {{count}} недель"},future:{singularNominative:"приблизительно через {{count}} неделю",singularGenitive:"приблизительно через {{count}} недели",pluralGenitive:"приблизительно через {{count}} недель"}}),xWeeks:tr({regular:{singularNominative:"{{count}} неделя",singularGenitive:"{{count}} недели",pluralGenitive:"{{count}} недель"}}),aboutXMonths:tr({regular:{singularNominative:"около {{count}} месяца",singularGenitive:"около {{count}} месяцев",pluralGenitive:"около {{count}} месяцев"},future:{singularNominative:"приблизительно через {{count}} месяц",singularGenitive:"приблизительно через {{count}} месяца",pluralGenitive:"приблизительно через {{count}} месяцев"}}),xMonths:tr({regular:{singularNominative:"{{count}} месяц",singularGenitive:"{{count}} месяца",pluralGenitive:"{{count}} месяцев"}}),aboutXYears:tr({regular:{singularNominative:"около {{count}} года",singularGenitive:"около {{count}} лет",pluralGenitive:"около {{count}} лет"},future:{singularNominative:"приблизительно через {{count}} год",singularGenitive:"приблизительно через {{count}} года",pluralGenitive:"приблизительно через {{count}} лет"}}),xYears:tr({regular:{singularNominative:"{{count}} год",singularGenitive:"{{count}} года",pluralGenitive:"{{count}} лет"}}),overXYears:tr({regular:{singularNominative:"больше {{count}} года",singularGenitive:"больше {{count}} лет",pluralGenitive:"больше {{count}} лет"},future:{singularNominative:"больше, чем через {{count}} год",singularGenitive:"больше, чем через {{count}} года",pluralGenitive:"больше, чем через {{count}} лет"}}),almostXYears:tr({regular:{singularNominative:"почти {{count}} год",singularGenitive:"почти {{count}} года",pluralGenitive:"почти {{count}} лет"},future:{singularNominative:"почти через {{count}} год",singularGenitive:"почти через {{count}} года",pluralGenitive:"почти через {{count}} лет"}})},fz=function(t,r,n){return hz[t](r,n)},pz={full:"EEEE, d MMMM y 'г.'",long:"d MMMM y 'г.'",medium:"d MMM y 'г.'",short:"dd.MM.y"},mz={full:"H:mm:ss zzzz",long:"H:mm:ss z",medium:"H:mm:ss",short:"H:mm"},gz={any:"{{date}}, {{time}}"},vz={date:H.buildFormatLongFn({formats:pz,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:mz,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:gz,defaultWidth:"any"})},E0=["воскресенье","понедельник","вторник","среду","четверг","пятницу","субботу"];function yz(e){var t=E0[e];switch(e){case 0:return"'в прошлое "+t+" в' p";case 1:case 2:case 4:return"'в прошлый "+t+" в' p";case 3:case 5:case 6:return"'в прошлую "+t+" в' p"}}function fy(e){var t=E0[e];return e===2?"'во "+t+" в' p":"'в "+t+" в' p"}function bz(e){var t=E0[e];switch(e){case 0:return"'в следующее "+t+" в' p";case 1:case 2:case 4:return"'в следующий "+t+" в' p";case 3:case 5:case 6:return"'в следующую "+t+" в' p"}}var _z={lastWeek:function(t,r,n){var i=t.getUTCDay();return ki(t,r,n)?fy(i):yz(i)},yesterday:"'вчера в' p",today:"'сегодня в' p",tomorrow:"'завтра в' p",nextWeek:function(t,r,n){var i=t.getUTCDay();return ki(t,r,n)?fy(i):bz(i)},other:"P"},wz=function(t,r,n,i){var a=_z[t];return typeof a=="function"?a(r,n,i):a},Cz={narrow:["до н.э.","н.э."],abbreviated:["до н. э.","н. э."],wide:["до нашей эры","нашей эры"]},xz={narrow:["1","2","3","4"],abbreviated:["1-й кв.","2-й кв.","3-й кв.","4-й кв."],wide:["1-й квартал","2-й квартал","3-й квартал","4-й квартал"]},Tz={narrow:["Я","Ф","М","А","М","И","И","А","С","О","Н","Д"],abbreviated:["янв.","фев.","март","апр.","май","июнь","июль","авг.","сент.","окт.","нояб.","дек."],wide:["январь","февраль","март","апрель","май","июнь","июль","август","сентябрь","октябрь","ноябрь","декабрь"]},Sz={narrow:["Я","Ф","М","А","М","И","И","А","С","О","Н","Д"],abbreviated:["янв.","фев.","мар.","апр.","мая","июн.","июл.","авг.","сент.","окт.","нояб.","дек."],wide:["января","февраля","марта","апреля","мая","июня","июля","августа","сентября","октября","ноября","декабря"]},Mz={narrow:["В","П","В","С","Ч","П","С"],short:["вс","пн","вт","ср","чт","пт","сб"],abbreviated:["вск","пнд","втр","срд","чтв","птн","суб"],wide:["воскресенье","понедельник","вторник","среда","четверг","пятница","суббота"]},Pz={narrow:{am:"ДП",pm:"ПП",midnight:"полн.",noon:"полд.",morning:"утро",afternoon:"день",evening:"веч.",night:"ночь"},abbreviated:{am:"ДП",pm:"ПП",midnight:"полн.",noon:"полд.",morning:"утро",afternoon:"день",evening:"веч.",night:"ночь"},wide:{am:"ДП",pm:"ПП",midnight:"полночь",noon:"полдень",morning:"утро",afternoon:"день",evening:"вечер",night:"ночь"}},Ez={narrow:{am:"ДП",pm:"ПП",midnight:"полн.",noon:"полд.",morning:"утра",afternoon:"дня",evening:"веч.",night:"ночи"},abbreviated:{am:"ДП",pm:"ПП",midnight:"полн.",noon:"полд.",morning:"утра",afternoon:"дня",evening:"веч.",night:"ночи"},wide:{am:"ДП",pm:"ПП",midnight:"полночь",noon:"полдень",morning:"утра",afternoon:"дня",evening:"вечера",night:"ночи"}},Az=function(t,r){var n=Number(t),i=r==null?void 0:r.unit,a;return i==="date"?a="-е":i==="week"||i==="minute"||i==="second"?a="-я":a="-й",n+a},Rz={ordinalNumber:Az,era:H.buildLocalizeFn({values:Cz,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:xz,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:Tz,defaultWidth:"wide",formattingValues:Sz,defaultFormattingWidth:"wide"}),day:H.buildLocalizeFn({values:Mz,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:Pz,defaultWidth:"any",formattingValues:Ez,defaultFormattingWidth:"wide"})},Dz=/^(\d+)(-?(е|я|й|ое|ье|ая|ья|ый|ой|ий|ый))?/i,Nz=/\d+/i,kz={narrow:/^((до )?н\.?\s?э\.?)/i,abbreviated:/^((до )?н\.?\s?э\.?)/i,wide:/^(до нашей эры|нашей эры|наша эра)/i},Lz={any:[/^д/i,/^н/i]},Oz={narrow:/^[1234]/i,abbreviated:/^[1234](-?[ыои]?й?)? кв.?/i,wide:/^[1234](-?[ыои]?й?)? квартал/i},Iz={any:[/1/i,/2/i,/3/i,/4/i]},Fz={narrow:/^[яфмаисонд]/i,abbreviated:/^(янв|фев|март?|апр|ма[йя]|июн[ья]?|июл[ья]?|авг|сент?|окт|нояб?|дек)\.?/i,wide:/^(январ[ья]|феврал[ья]|марта?|апрел[ья]|ма[йя]|июн[ья]|июл[ья]|августа?|сентябр[ья]|октябр[ья]|октябр[ья]|ноябр[ья]|декабр[ья])/i},$z={narrow:[/^я/i,/^ф/i,/^м/i,/^а/i,/^м/i,/^и/i,/^и/i,/^а/i,/^с/i,/^о/i,/^н/i,/^я/i],any:[/^я/i,/^ф/i,/^мар/i,/^ап/i,/^ма[йя]/i,/^июн/i,/^июл/i,/^ав/i,/^с/i,/^о/i,/^н/i,/^д/i]},Bz={narrow:/^[впсч]/i,short:/^(вс|во|пн|по|вт|ср|чт|че|пт|пя|сб|су)\.?/i,abbreviated:/^(вск|вос|пнд|пон|втр|вто|срд|сре|чтв|чет|птн|пят|суб).?/i,wide:/^(воскресень[ея]|понедельника?|вторника?|сред[аы]|четверга?|пятниц[аы]|суббот[аы])/i},zz={narrow:[/^в/i,/^п/i,/^в/i,/^с/i,/^ч/i,/^п/i,/^с/i],any:[/^в[ос]/i,/^п[он]/i,/^в/i,/^ср/i,/^ч/i,/^п[ят]/i,/^с[уб]/i]},Hz={narrow:/^([дп]п|полн\.?|полд\.?|утр[оа]|день|дня|веч\.?|ноч[ьи])/i,abbreviated:/^([дп]п|полн\.?|полд\.?|утр[оа]|день|дня|веч\.?|ноч[ьи])/i,wide:/^([дп]п|полночь|полдень|утр[оа]|день|дня|вечера?|ноч[ьи])/i},Wz={any:{am:/^дп/i,pm:/^пп/i,midnight:/^полн/i,noon:/^полд/i,morning:/^у/i,afternoon:/^д[ен]/i,evening:/^в/i,night:/^н/i}},jz={ordinalNumber:H.buildMatchPatternFn({matchPattern:Dz,parsePattern:Nz,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:kz,defaultMatchWidth:"wide",parsePatterns:Lz,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:Oz,defaultMatchWidth:"wide",parsePatterns:Iz,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:Fz,defaultMatchWidth:"wide",parsePatterns:$z,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:Bz,defaultMatchWidth:"wide",parsePatterns:zz,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:Hz,defaultMatchWidth:"wide",parsePatterns:Wz,defaultParseWidth:"any"})},Vz={code:"ru",formatDistance:fz,formatLong:vz,formatRelative:wz,localize:Rz,match:jz,options:{weekStartsOn:1,firstWeekContainsDate:1}},Uz={lessThanXSeconds:{one:"bir saniyeden az",other:"{{count}} saniyeden az"},xSeconds:{one:"1 saniye",other:"{{count}} saniye"},halfAMinute:"yarım dakika",lessThanXMinutes:{one:"bir dakikadan az",other:"{{count}} dakikadan az"},xMinutes:{one:"1 dakika",other:"{{count}} dakika"},aboutXHours:{one:"yaklaşık 1 saat",other:"yaklaşık {{count}} saat"},xHours:{one:"1 saat",other:"{{count}} saat"},xDays:{one:"1 gün",other:"{{count}} gün"},aboutXWeeks:{one:"yaklaşık 1 hafta",other:"yaklaşık {{count}} hafta"},xWeeks:{one:"1 hafta",other:"{{count}} hafta"},aboutXMonths:{one:"yaklaşık 1 ay",other:"yaklaşık {{count}} ay"},xMonths:{one:"1 ay",other:"{{count}} ay"},aboutXYears:{one:"yaklaşık 1 yıl",other:"yaklaşık {{count}} yıl"},xYears:{one:"1 yıl",other:"{{count}} yıl"},overXYears:{one:"1 yıldan fazla",other:"{{count}} yıldan fazla"},almostXYears:{one:"neredeyse 1 yıl",other:"neredeyse {{count}} yıl"}},Gz=function(t,r,n){var i,a=Uz[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",r.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?i+" sonra":i+" önce":i},qz={full:"d MMMM y EEEE",long:"d MMMM y",medium:"d MMM y",short:"dd.MM.yyyy"},Yz={full:"HH:mm:ss zzzz",long:"HH:mm:ss z",medium:"HH:mm:ss",short:"HH:mm"},Xz={full:"{{date}} 'saat' {{time}}",long:"{{date}} 'saat' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},Zz={date:H.buildFormatLongFn({formats:qz,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:Yz,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:Xz,defaultWidth:"full"})},Kz={lastWeek:"'geçen hafta' eeee 'saat' p",yesterday:"'dün saat' p",today:"'bugün saat' p",tomorrow:"'yarın saat' p",nextWeek:"eeee 'saat' p",other:"P"},Qz=function(t,r,n,i){return Kz[t]},Jz={narrow:["MÖ","MS"],abbreviated:["MÖ","MS"],wide:["Milattan Önce","Milattan Sonra"]},eH={narrow:["1","2","3","4"],abbreviated:["1Ç","2Ç","3Ç","4Ç"],wide:["İlk çeyrek","İkinci Çeyrek","Üçüncü çeyrek","Son çeyrek"]},tH={narrow:["O","Ş","M","N","M","H","T","A","E","E","K","A"],abbreviated:["Oca","Şub","Mar","Nis","May","Haz","Tem","Ağu","Eyl","Eki","Kas","Ara"],wide:["Ocak","Şubat","Mart","Nisan","Mayıs","Haziran","Temmuz","Ağustos","Eylül","Ekim","Kasım","Aralık"]},rH={narrow:["P","P","S","Ç","P","C","C"],short:["Pz","Pt","Sa","Ça","Pe","Cu","Ct"],abbreviated:["Paz","Pzt","Sal","Çar","Per","Cum","Cts"],wide:["Pazar","Pazartesi","Salı","Çarşamba","Perşembe","Cuma","Cumartesi"]},nH={narrow:{am:"öö",pm:"ös",midnight:"gy",noon:"ö",morning:"sa",afternoon:"ös",evening:"ak",night:"ge"},abbreviated:{am:"ÖÖ",pm:"ÖS",midnight:"gece yarısı",noon:"öğle",morning:"sabah",afternoon:"öğleden sonra",evening:"akşam",night:"gece"},wide:{am:"Ö.Ö.",pm:"Ö.S.",midnight:"gece yarısı",noon:"öğle",morning:"sabah",afternoon:"öğleden sonra",evening:"akşam",night:"gece"}},iH={narrow:{am:"öö",pm:"ös",midnight:"gy",noon:"ö",morning:"sa",afternoon:"ös",evening:"ak",night:"ge"},abbreviated:{am:"ÖÖ",pm:"ÖS",midnight:"gece yarısı",noon:"öğlen",morning:"sabahleyin",afternoon:"öğleden sonra",evening:"akşamleyin",night:"geceleyin"},wide:{am:"ö.ö.",pm:"ö.s.",midnight:"gece yarısı",noon:"öğlen",morning:"sabahleyin",afternoon:"öğleden sonra",evening:"akşamleyin",night:"geceleyin"}},aH=function(t,r){var n=Number(t);return n+"."},oH={ordinalNumber:aH,era:H.buildLocalizeFn({values:Jz,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:eH,defaultWidth:"wide",argumentCallback:function(t){return Number(t)-1}}),month:H.buildLocalizeFn({values:tH,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:rH,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:nH,defaultWidth:"wide",formattingValues:iH,defaultFormattingWidth:"wide"})},sH=/^(\d+)(\.)?/i,lH=/\d+/i,uH={narrow:/^(mö|ms)/i,abbreviated:/^(mö|ms)/i,wide:/^(milattan önce|milattan sonra)/i},cH={any:[/(^mö|^milattan önce)/i,/(^ms|^milattan sonra)/i]},dH={narrow:/^[1234]/i,abbreviated:/^[1234]ç/i,wide:/^((i|İ)lk|(i|İ)kinci|üçüncü|son) çeyrek/i},hH={any:[/1/i,/2/i,/3/i,/4/i],abbreviated:[/1ç/i,/2ç/i,/3ç/i,/4ç/i],wide:[/^(i|İ)lk çeyrek/i,/(i|İ)kinci çeyrek/i,/üçüncü çeyrek/i,/son çeyrek/i]},fH={narrow:/^[oşmnhtaek]/i,abbreviated:/^(oca|şub|mar|nis|may|haz|tem|ağu|eyl|eki|kas|ara)/i,wide:/^(ocak|şubat|mart|nisan|mayıs|haziran|temmuz|ağustos|eylül|ekim|kasım|aralık)/i},pH={narrow:[/^o/i,/^ş/i,/^m/i,/^n/i,/^m/i,/^h/i,/^t/i,/^a/i,/^e/i,/^e/i,/^k/i,/^a/i],any:[/^o/i,/^ş/i,/^mar/i,/^n/i,/^may/i,/^h/i,/^t/i,/^ağ/i,/^ey/i,/^ek/i,/^k/i,/^ar/i]},mH={narrow:/^[psçc]/i,short:/^(pz|pt|sa|ça|pe|cu|ct)/i,abbreviated:/^(paz|pzt|sal|çar|per|cum|cts)/i,wide:/^(pazar(?!tesi)|pazartesi|salı|çarşamba|perşembe|cuma(?!rtesi)|cumartesi)/i},gH={narrow:[/^p/i,/^p/i,/^s/i,/^ç/i,/^p/i,/^c/i,/^c/i],any:[/^pz/i,/^pt/i,/^sa/i,/^ça/i,/^pe/i,/^cu/i,/^ct/i],wide:[/^pazar(?!tesi)/i,/^pazartesi/i,/^salı/i,/^çarşamba/i,/^perşembe/i,/^cuma(?!rtesi)/i,/^cumartesi/i]},vH={narrow:/^(öö|ös|gy|ö|sa|ös|ak|ge)/i,any:/^(ö\.?\s?[ös]\.?|öğleden sonra|gece yarısı|öğle|(sabah|öğ|akşam|gece)(leyin))/i},yH={any:{am:/^ö\.?ö\.?/i,pm:/^ö\.?s\.?/i,midnight:/^(gy|gece yarısı)/i,noon:/^öğ/i,morning:/^sa/i,afternoon:/^öğleden sonra/i,evening:/^ak/i,night:/^ge/i}},bH={ordinalNumber:H.buildMatchPatternFn({matchPattern:sH,parsePattern:lH,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:uH,defaultMatchWidth:"wide",parsePatterns:cH,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:dH,defaultMatchWidth:"wide",parsePatterns:hH,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:fH,defaultMatchWidth:"wide",parsePatterns:pH,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:mH,defaultMatchWidth:"wide",parsePatterns:gH,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:vH,defaultMatchWidth:"any",parsePatterns:yH,defaultParseWidth:"any"})},_H={code:"tr",formatDistance:Gz,formatLong:Zz,formatRelative:Qz,localize:oH,match:bH,options:{weekStartsOn:1,firstWeekContainsDate:1}};function Wo(e,t){if(e.one!==void 0&&t===1)return e.one;var r=t%10,n=t%100;return r===1&&n!==11?e.singularNominative.replace("{{count}}",String(t)):r>=2&&r<=4&&(n<10||n>20)?e.singularGenitive.replace("{{count}}",String(t)):e.pluralGenitive.replace("{{count}}",String(t))}function rr(e){return function(t,r){return r&&r.addSuffix?r.comparison&&r.comparison>0?e.future?Wo(e.future,t):"за "+Wo(e.regular,t):e.past?Wo(e.past,t):Wo(e.regular,t)+" тому":Wo(e.regular,t)}}var wH=function(t,r){return r&&r.addSuffix?r.comparison&&r.comparison>0?"за півхвилини":"півхвилини тому":"півхвилини"},CH={lessThanXSeconds:rr({regular:{one:"менше секунди",singularNominative:"менше {{count}} секунди",singularGenitive:"менше {{count}} секунд",pluralGenitive:"менше {{count}} секунд"},future:{one:"менше, ніж за секунду",singularNominative:"менше, ніж за {{count}} секунду",singularGenitive:"менше, ніж за {{count}} секунди",pluralGenitive:"менше, ніж за {{count}} секунд"}}),xSeconds:rr({regular:{singularNominative:"{{count}} секунда",singularGenitive:"{{count}} секунди",pluralGenitive:"{{count}} секунд"},past:{singularNominative:"{{count}} секунду тому",singularGenitive:"{{count}} секунди тому",pluralGenitive:"{{count}} секунд тому"},future:{singularNominative:"за {{count}} секунду",singularGenitive:"за {{count}} секунди",pluralGenitive:"за {{count}} секунд"}}),halfAMinute:wH,lessThanXMinutes:rr({regular:{one:"менше хвилини",singularNominative:"менше {{count}} хвилини",singularGenitive:"менше {{count}} хвилин",pluralGenitive:"менше {{count}} хвилин"},future:{one:"менше, ніж за хвилину",singularNominative:"менше, ніж за {{count}} хвилину",singularGenitive:"менше, ніж за {{count}} хвилини",pluralGenitive:"менше, ніж за {{count}} хвилин"}}),xMinutes:rr({regular:{singularNominative:"{{count}} хвилина",singularGenitive:"{{count}} хвилини",pluralGenitive:"{{count}} хвилин"},past:{singularNominative:"{{count}} хвилину тому",singularGenitive:"{{count}} хвилини тому",pluralGenitive:"{{count}} хвилин тому"},future:{singularNominative:"за {{count}} хвилину",singularGenitive:"за {{count}} хвилини",pluralGenitive:"за {{count}} хвилин"}}),aboutXHours:rr({regular:{singularNominative:"близько {{count}} години",singularGenitive:"близько {{count}} годин",pluralGenitive:"близько {{count}} годин"},future:{singularNominative:"приблизно за {{count}} годину",singularGenitive:"приблизно за {{count}} години",pluralGenitive:"приблизно за {{count}} годин"}}),xHours:rr({regular:{singularNominative:"{{count}} годину",singularGenitive:"{{count}} години",pluralGenitive:"{{count}} годин"}}),xDays:rr({regular:{singularNominative:"{{count}} день",singularGenitive:"{{count}} днi",pluralGenitive:"{{count}} днів"}}),aboutXWeeks:rr({regular:{singularNominative:"близько {{count}} тижня",singularGenitive:"близько {{count}} тижнів",pluralGenitive:"близько {{count}} тижнів"},future:{singularNominative:"приблизно за {{count}} тиждень",singularGenitive:"приблизно за {{count}} тижні",pluralGenitive:"приблизно за {{count}} тижнів"}}),xWeeks:rr({regular:{singularNominative:"{{count}} тиждень",singularGenitive:"{{count}} тижні",pluralGenitive:"{{count}} тижнів"}}),aboutXMonths:rr({regular:{singularNominative:"близько {{count}} місяця",singularGenitive:"близько {{count}} місяців",pluralGenitive:"близько {{count}} місяців"},future:{singularNominative:"приблизно за {{count}} місяць",singularGenitive:"приблизно за {{count}} місяці",pluralGenitive:"приблизно за {{count}} місяців"}}),xMonths:rr({regular:{singularNominative:"{{count}} місяць",singularGenitive:"{{count}} місяці",pluralGenitive:"{{count}} місяців"}}),aboutXYears:rr({regular:{singularNominative:"близько {{count}} року",singularGenitive:"близько {{count}} років",pluralGenitive:"близько {{count}} років"},future:{singularNominative:"приблизно за {{count}} рік",singularGenitive:"приблизно за {{count}} роки",pluralGenitive:"приблизно за {{count}} років"}}),xYears:rr({regular:{singularNominative:"{{count}} рік",singularGenitive:"{{count}} роки",pluralGenitive:"{{count}} років"}}),overXYears:rr({regular:{singularNominative:"більше {{count}} року",singularGenitive:"більше {{count}} років",pluralGenitive:"більше {{count}} років"},future:{singularNominative:"більше, ніж за {{count}} рік",singularGenitive:"більше, ніж за {{count}} роки",pluralGenitive:"більше, ніж за {{count}} років"}}),almostXYears:rr({regular:{singularNominative:"майже {{count}} рік",singularGenitive:"майже {{count}} роки",pluralGenitive:"майже {{count}} років"},future:{singularNominative:"майже за {{count}} рік",singularGenitive:"майже за {{count}} роки",pluralGenitive:"майже за {{count}} років"}})},xH=function(t,r,n){return n=n||{},CH[t](r,n)},TH={full:"EEEE, do MMMM y 'р.'",long:"do MMMM y 'р.'",medium:"d MMM y 'р.'",short:"dd.MM.y"},SH={full:"H:mm:ss zzzz",long:"H:mm:ss z",medium:"H:mm:ss",short:"H:mm"},MH={full:"{{date}} 'о' {{time}}",long:"{{date}} 'о' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},PH={date:H.buildFormatLongFn({formats:TH,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:SH,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:MH,defaultWidth:"full"})},A0=["неділю","понеділок","вівторок","середу","четвер","п’ятницю","суботу"];function EH(e){var t=A0[e];switch(e){case 0:case 3:case 5:case 6:return"'у минулу "+t+" о' p";case 1:case 2:case 4:return"'у минулий "+t+" о' p"}}function sx(e){var t=A0[e];return"'у "+t+" о' p"}function AH(e){var t=A0[e];switch(e){case 0:case 3:case 5:case 6:return"'у наступну "+t+" о' p";case 1:case 2:case 4:return"'у наступний "+t+" о' p"}}var RH=function(t,r,n){var i=H.toDate(t),a=i.getUTCDay();return ki(i,r,n)?sx(a):EH(a)},DH=function(t,r,n){var i=H.toDate(t),a=i.getUTCDay();return ki(i,r,n)?sx(a):AH(a)},NH={lastWeek:RH,yesterday:"'вчора о' p",today:"'сьогодні о' p",tomorrow:"'завтра о' p",nextWeek:DH,other:"P"},kH=function(t,r,n,i){var a=NH[t];return typeof a=="function"?a(r,n,i):a},LH={narrow:["до н.е.","н.е."],abbreviated:["до н. е.","н. е."],wide:["до нашої ери","нашої ери"]},OH={narrow:["1","2","3","4"],abbreviated:["1-й кв.","2-й кв.","3-й кв.","4-й кв."],wide:["1-й квартал","2-й квартал","3-й квартал","4-й квартал"]},IH={narrow:["С","Л","Б","К","Т","Ч","Л","С","В","Ж","Л","Г"],abbreviated:["січ.","лют.","берез.","квіт.","трав.","черв.","лип.","серп.","верес.","жовт.","листоп.","груд."],wide:["січень","лютий","березень","квітень","травень","червень","липень","серпень","вересень","жовтень","листопад","грудень"]},FH={narrow:["С","Л","Б","К","Т","Ч","Л","С","В","Ж","Л","Г"],abbreviated:["січ.","лют.","берез.","квіт.","трав.","черв.","лип.","серп.","верес.","жовт.","листоп.","груд."],wide:["січня","лютого","березня","квітня","травня","червня","липня","серпня","вересня","жовтня","листопада","грудня"]},$H={narrow:["Н","П","В","С","Ч","П","С"],short:["нд","пн","вт","ср","чт","пт","сб"],abbreviated:["нед","пон","вів","сер","чтв","птн","суб"],wide:["неділя","понеділок","вівторок","середа","четвер","п’ятниця","субота"]},BH={narrow:{am:"ДП",pm:"ПП",midnight:"півн.",noon:"пол.",morning:"ранок",afternoon:"день",evening:"веч.",night:"ніч"},abbreviated:{am:"ДП",pm:"ПП",midnight:"півн.",noon:"пол.",morning:"ранок",afternoon:"день",evening:"веч.",night:"ніч"},wide:{am:"ДП",pm:"ПП",midnight:"північ",noon:"полудень",morning:"ранок",afternoon:"день",evening:"вечір",night:"ніч"}},zH={narrow:{am:"ДП",pm:"ПП",midnight:"півн.",noon:"пол.",morning:"ранку",afternoon:"дня",evening:"веч.",night:"ночі"},abbreviated:{am:"ДП",pm:"ПП",midnight:"півн.",noon:"пол.",morning:"ранку",afternoon:"дня",evening:"веч.",night:"ночі"},wide:{am:"ДП",pm:"ПП",midnight:"північ",noon:"полудень",morning:"ранку",afternoon:"дня",evening:"веч.",night:"ночі"}},HH=function(t,r){var n=String(r==null?void 0:r.unit),i=Number(t),a;return n==="date"?i===3||i===23?a="-є":a="-е":n==="minute"||n==="second"||n==="hour"?a="-а":a="-й",i+a},WH={ordinalNumber:HH,era:H.buildLocalizeFn({values:LH,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:OH,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:IH,defaultWidth:"wide",formattingValues:FH,defaultFormattingWidth:"wide"}),day:H.buildLocalizeFn({values:$H,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:BH,defaultWidth:"any",formattingValues:zH,defaultFormattingWidth:"wide"})},jH=/^(\d+)(-?(е|й|є|а|я))?/i,VH=/\d+/i,UH={narrow:/^((до )?н\.?\s?е\.?)/i,abbreviated:/^((до )?н\.?\s?е\.?)/i,wide:/^(до нашої ери|нашої ери|наша ера)/i},GH={any:[/^д/i,/^н/i]},qH={narrow:/^[1234]/i,abbreviated:/^[1234](-?[иі]?й?)? кв.?/i,wide:/^[1234](-?[иі]?й?)? квартал/i},YH={any:[/1/i,/2/i,/3/i,/4/i]},XH={narrow:/^[слбктчвжг]/i,abbreviated:/^(січ|лют|бер(ез)?|квіт|трав|черв|лип|серп|вер(ес)?|жовт|лис(топ)?|груд)\.?/i,wide:/^(січень|січня|лютий|лютого|березень|березня|квітень|квітня|травень|травня|червня|червень|липень|липня|серпень|серпня|вересень|вересня|жовтень|жовтня|листопад[а]?|грудень|грудня)/i},ZH={narrow:[/^с/i,/^л/i,/^б/i,/^к/i,/^т/i,/^ч/i,/^л/i,/^с/i,/^в/i,/^ж/i,/^л/i,/^г/i],any:[/^сі/i,/^лю/i,/^б/i,/^к/i,/^т/i,/^ч/i,/^лип/i,/^се/i,/^в/i,/^ж/i,/^лис/i,/^г/i]},KH={narrow:/^[нпвсч]/i,short:/^(нд|пн|вт|ср|чт|пт|сб)\.?/i,abbreviated:/^(нед|пон|вів|сер|че?тв|птн?|суб)\.?/i,wide:/^(неділ[яі]|понеділ[ок][ка]|вівтор[ок][ка]|серед[аи]|четвер(га)?|п\W*?ятниц[яі]|субот[аи])/i},QH={narrow:[/^н/i,/^п/i,/^в/i,/^с/i,/^ч/i,/^п/i,/^с/i],any:[/^н/i,/^п[он]/i,/^в/i,/^с[ер]/i,/^ч/i,/^п\W*?[ят]/i,/^с[уб]/i]},JH={narrow:/^([дп]п|півн\.?|пол\.?|ранок|ранку|день|дня|веч\.?|ніч|ночі)/i,abbreviated:/^([дп]п|півн\.?|пол\.?|ранок|ранку|день|дня|веч\.?|ніч|ночі)/i,wide:/^([дп]п|північ|полудень|ранок|ранку|день|дня|вечір|вечора|ніч|ночі)/i},eW={any:{am:/^дп/i,pm:/^пп/i,midnight:/^півн/i,noon:/^пол/i,morning:/^р/i,afternoon:/^д[ен]/i,evening:/^в/i,night:/^н/i}},tW={ordinalNumber:H.buildMatchPatternFn({matchPattern:jH,parsePattern:VH,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:UH,defaultMatchWidth:"wide",parsePatterns:GH,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:qH,defaultMatchWidth:"wide",parsePatterns:YH,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:XH,defaultMatchWidth:"wide",parsePatterns:ZH,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:KH,defaultMatchWidth:"wide",parsePatterns:QH,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:JH,defaultMatchWidth:"wide",parsePatterns:eW,defaultParseWidth:"any"})},rW={code:"uk",formatDistance:xH,formatLong:PH,formatRelative:kH,localize:WH,match:tW,options:{weekStartsOn:1,firstWeekContainsDate:1}},nW={lessThanXSeconds:{one:"不到 1 秒",other:"不到 {{count}} 秒"},xSeconds:{one:"1 秒",other:"{{count}} 秒"},halfAMinute:"半分钟",lessThanXMinutes:{one:"不到 1 分钟",other:"不到 {{count}} 分钟"},xMinutes:{one:"1 分钟",other:"{{count}} 分钟"},xHours:{one:"1 小时",other:"{{count}} 小时"},aboutXHours:{one:"大约 1 小时",other:"大约 {{count}} 小时"},xDays:{one:"1 天",other:"{{count}} 天"},aboutXWeeks:{one:"大约 1 个星期",other:"大约 {{count}} 个星期"},xWeeks:{one:"1 个星期",other:"{{count}} 个星期"},aboutXMonths:{one:"大约 1 个月",other:"大约 {{count}} 个月"},xMonths:{one:"1 个月",other:"{{count}} 个月"},aboutXYears:{one:"大约 1 年",other:"大约 {{count}} 年"},xYears:{one:"1 年",other:"{{count}} 年"},overXYears:{one:"超过 1 年",other:"超过 {{count}} 年"},almostXYears:{one:"将近 1 年",other:"将近 {{count}} 年"}},iW=function(t,r,n){var i,a=nW[t];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",String(r)),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?i+"内":i+"前":i},aW={full:"y'年'M'月'd'日' EEEE",long:"y'年'M'月'd'日'",medium:"yyyy-MM-dd",short:"yy-MM-dd"},oW={full:"zzzz a h:mm:ss",long:"z a h:mm:ss",medium:"a h:mm:ss",short:"a h:mm"},sW={full:"{{date}} {{time}}",long:"{{date}} {{time}}",medium:"{{date}} {{time}}",short:"{{date}} {{time}}"},lW={date:H.buildFormatLongFn({formats:aW,defaultWidth:"full"}),time:H.buildFormatLongFn({formats:oW,defaultWidth:"full"}),dateTime:H.buildFormatLongFn({formats:sW,defaultWidth:"full"})};function py(e,t,r){var n="eeee p";return ki(e,t,r)?n:e.getTime()>t.getTime()?"'下个'"+n:"'上个'"+n}var uW={lastWeek:py,yesterday:"'昨天' p",today:"'今天' p",tomorrow:"'明天' p",nextWeek:py,other:"PP p"},cW=function(t,r,n,i){var a=uW[t];return typeof a=="function"?a(r,n,i):a},dW={narrow:["前","公元"],abbreviated:["前","公元"],wide:["公元前","公元"]},hW={narrow:["1","2","3","4"],abbreviated:["第一季","第二季","第三季","第四季"],wide:["第一季度","第二季度","第三季度","第四季度"]},fW={narrow:["一","二","三","四","五","六","七","八","九","十","十一","十二"],abbreviated:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],wide:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]},pW={narrow:["日","一","二","三","四","五","六"],short:["日","一","二","三","四","五","六"],abbreviated:["周日","周一","周二","周三","周四","周五","周六"],wide:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"]},mW={narrow:{am:"上",pm:"下",midnight:"凌晨",noon:"午",morning:"早",afternoon:"下午",evening:"晚",night:"夜"},abbreviated:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"},wide:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"}},gW={narrow:{am:"上",pm:"下",midnight:"凌晨",noon:"午",morning:"早",afternoon:"下午",evening:"晚",night:"夜"},abbreviated:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"},wide:{am:"上午",pm:"下午",midnight:"凌晨",noon:"中午",morning:"早晨",afternoon:"中午",evening:"晚上",night:"夜间"}},vW=function(t,r){var n=Number(t);switch(r==null?void 0:r.unit){case"date":return n.toString()+"日";case"hour":return n.toString()+"时";case"minute":return n.toString()+"分";case"second":return n.toString()+"秒";default:return"第 "+n.toString()}},yW={ordinalNumber:vW,era:H.buildLocalizeFn({values:dW,defaultWidth:"wide"}),quarter:H.buildLocalizeFn({values:hW,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:H.buildLocalizeFn({values:fW,defaultWidth:"wide"}),day:H.buildLocalizeFn({values:pW,defaultWidth:"wide"}),dayPeriod:H.buildLocalizeFn({values:mW,defaultWidth:"wide",formattingValues:gW,defaultFormattingWidth:"wide"})},bW=/^(第\s*)?\d+(日|时|分|秒)?/i,_W=/\d+/i,wW={narrow:/^(前)/i,abbreviated:/^(前)/i,wide:/^(公元前|公元)/i},CW={any:[/^(前)/i,/^(公元)/i]},xW={narrow:/^[1234]/i,abbreviated:/^第[一二三四]刻/i,wide:/^第[一二三四]刻钟/i},TW={any:[/(1|一)/i,/(2|二)/i,/(3|三)/i,/(4|四)/i]},SW={narrow:/^(一|二|三|四|五|六|七|八|九|十[二一])/i,abbreviated:/^(一|二|三|四|五|六|七|八|九|十[二一]|\d|1[12])月/i,wide:/^(一|二|三|四|五|六|七|八|九|十[二一])月/i},MW={narrow:[/^一/i,/^二/i,/^三/i,/^四/i,/^五/i,/^六/i,/^七/i,/^八/i,/^九/i,/^十(?!(一|二))/i,/^十一/i,/^十二/i],any:[/^一|1/i,/^二|2/i,/^三|3/i,/^四|4/i,/^五|5/i,/^六|6/i,/^七|7/i,/^八|8/i,/^九|9/i,/^十(?!(一|二))|10/i,/^十一|11/i,/^十二|12/i]},PW={narrow:/^[一二三四五六日]/i,short:/^[一二三四五六日]/i,abbreviated:/^周[一二三四五六日]/i,wide:/^星期[一二三四五六日]/i},EW={any:[/日/i,/一/i,/二/i,/三/i,/四/i,/五/i,/六/i]},AW={any:/^(上午?|下午?|午夜|[中正]午|早上?|下午|晚上?|凌晨|)/i},RW={any:{am:/^上午?/i,pm:/^下午?/i,midnight:/^午夜/i,noon:/^[中正]午/i,morning:/^早上/i,afternoon:/^下午/i,evening:/^晚上?/i,night:/^凌晨/i}},DW={ordinalNumber:H.buildMatchPatternFn({matchPattern:bW,parsePattern:_W,valueCallback:function(t){return parseInt(t,10)}}),era:H.buildMatchFn({matchPatterns:wW,defaultMatchWidth:"wide",parsePatterns:CW,defaultParseWidth:"any"}),quarter:H.buildMatchFn({matchPatterns:xW,defaultMatchWidth:"wide",parsePatterns:TW,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:H.buildMatchFn({matchPatterns:SW,defaultMatchWidth:"wide",parsePatterns:MW,defaultParseWidth:"any"}),day:H.buildMatchFn({matchPatterns:PW,defaultMatchWidth:"wide",parsePatterns:EW,defaultParseWidth:"any"}),dayPeriod:H.buildMatchFn({matchPatterns:AW,defaultMatchWidth:"any",parsePatterns:RW,defaultParseWidth:"any"})},NW={code:"zh-CN",formatDistance:iW,formatLong:lW,formatRelative:cW,localize:yW,match:DW,options:{weekStartsOn:1,firstWeekContainsDate:4}},kW=Math.ceil,LW=Math.max;function OW(e,t,r,n){for(var i=-1,a=LW(kW((t-e)/(r||1)),0),o=Array(a);a--;)o[++i]=e,e+=r;return o}function IW(e){return function(t,r,n){return n&&typeof n!="number"&&V.isIterateeCall(t,r,n)&&(r=n=void 0),t=E.toFinite(t),r===void 0?(r=t,t=0):r=E.toFinite(r),n=n===void 0?t<r?1:-1:E.toFinite(n),OW(t,r,n)}}var iu=IW();const il=e=>{switch(e){case"de":case"de-DE":return d9;case"en":case"en-US":return H.locale;case"gb":case"en-GB":return g9;case"es":case"es-ES":case"es-AR":return q9;case"fr":case"fr-FR":return CF;case"it":case"it-IT":return e$;case"ja":case"ja-JP":return R$;case"ko":case"ko-KR":return oB;case"nl":case"nl-NL":return OB;case"pt":case"pt-BR":return dz;case"ru":case"ru-RU":return Vz;case"tr":case"tr-TR":return _H;case"zh":case"zh-CN":return NW;case"uk":return rW;default:return H.locale}};var lx=(e=>(e.YEAR="years",e.QUARTER="quarters",e.MONTH="months",e.WEEK="weeks",e.DATE="dates",e))(lx||{});const FW={dates:e=>H.startOfDay(e),months:e=>H.startOfMonth(e),quarters:e=>H.startOfQuarter(e),weeks:(e,t)=>H.startOfWeek(e,{locale:t}),years:e=>H.startOfYear(e)},$W=(e,t,r)=>FW[e](t,r),BW=e=>E.parseISOWithTimezoneCheck(e);iu(4),iu(12),iu(7),iu(24);function ai(e,t,r){const n=new RegExp("'[^']+'|("+t+")","g");return e.replace(n,function(a,o){return o?r(a):a})}const zW=["shortDate","shortTime","short","mediumDate","mediumTime","medium","longDate","fullDate"],HW=Object.freeze({fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a",short:"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"});function WW(e,t){if(!t.formatLong)return console.warn("Locale does not have formatLong property. Using default date formats."),HW[e];switch(e){case"fullDate":return t.formatLong.date({width:"full"});case"longDate":return t.formatLong.date({width:"long"});case"mediumDate":return t.formatLong.date({width:"medium"});case"shortDate":return t.formatLong.date({width:"short"});case"mediumTime":return t.formatLong.time({width:"medium"});case"shortTime":return t.formatLong.time({width:"short"});case"medium":return t.formatLong.dateTime({width:"medium"}).replace("{{date}}",t.formatLong.date({width:"medium"})).replace("{{time}}",t.formatLong.time({width:"medium"}));case"short":return t.formatLong.dateTime({width:"short"}).replace("{{date}}",t.formatLong.date({width:"short"})).replace("{{time}}",t.formatLong.time({width:"short"}))}}function jW(e,t){if(!(e.includes("short")||e.includes("medium")||e.includes("long")||e.includes("full")))return e;let r=e;return zW.forEach(n=>{const i=WW(n,t);r=ai(r,n,function(){return i})}),r}const ux="Etc/GMT-14";function VW(e,t,r){return cx(e,t,r)?ox(e,1):e}function UW(e,t){return t<=e.getMonth()}function cx(e,t,r){const n=![rj,R0].includes(t);return r>px&&n&&UW(e,r)}function GW(e,t,r,n){return!n&&cx(e,t,r)?ax(e,1):e}function qW(e,t){if(t>0){const r=(e.getMonth()+t)%12;return II(e,r)}return e}function YW(e,t,r,n,i,a){if(!e.includes("y"))return e;const o=GW(t,n,a,i);let s=e;if(["yyyy","yy","y","yp","yyyp"].some(c=>e.includes(c))&&(r=ux),e.includes("yp")){const c=ox(o,1);s=ai(e,"yp|yyyp",function(h){const p="y".repeat(h.length);return Ni(c,r,p)})}return ai(s,"yyyy|yy|y",function(d){return Ni(o,r,d)})}function XW(e,t,r,n){if(!e.includes("Q"))return e;const i=Ni(t,ux,"M");let a=parseInt(i,10)-1;n&&[R0,nj,ij,fx].includes(r)&&(a-=n>a?n-12:n);const o=parseInt(String(a/3))+1;return ai(e,"QQ|Q",function(c){return`${c.length===2?"'Quarter '":"'Q'"}${o}`})}function ZW(e){return e.includes("sss")?ai(e,"sss",function(){return"SSS"}):e}function KW(e,t,r){if(!(e.includes("a")||e.includes("A")))return e;let n=ai(e,"a",function(){return`\0${Ni(t,r,"a").toLowerCase()}\0`});return n=ai(n,"A",function(){return`\0${Ni(t,r,"a").toUpperCase()}\0`}),n=n.replace(/\0\0/g,""),n=n.replace(/\0/g,"'"),n}const dx=new Set(["y","yy","yyy","yyyy","M","MM","MMM","MMMM","d","dd","EEE","EEEE","EEEEE","H","HH","h","hh","k","kk","m","mm","s","ss","S","SS","SSS","w","ww","o"]),QW=/^([a-zA-Z])\1*/;function hx(e){var t;return(t=e.match(QW))==null?void 0:t[0]}function JW(e,t){let r="",n=t;for(;n<e.length&&e[n]!=="'";){const i=hx(e.slice(n));if(i){if(dx.has(i))break;r+=i,n+=i.length}else r+=e[n],n++}return{literal:r,endIndex:n}}function ej(e){const t=[];let r=0;for(;r<e.length;){if(e[r]==="'"){const i=e.indexOf("'",r+1);if(i===-1){t.push(e.slice(r));break}t.push(e.slice(r,i+1)),r=i+1;continue}const n=hx(e.slice(r));if(n&&dx.has(n)){t.push(n),r+=n.length;continue}if(n){const{literal:i,endIndex:a}=JW(e,r);t.push(`'${i.replace(/'/g,"''")}'`),r=a;continue}t.push(e[r]),r++}return t.join("")}function tj(e,t,r,n){return e.includes("Z")?ai(e,"Z",function(){return Ni(t,r,"xx",{locale:n})}):e}const rj="years",R0="quarters",nj="months",ij="weeks",fx="days",px=0,aj=1,al=Object.freeze({weekFirstDay:aj,isFiscalOn:!1,fiscalMonth:px,selectedDateLevel:fx,timeZone:"UTC"});function ol(e,t,r=il(),n=al){if(e===O.NOT_AVAILABLE_DATA_VALUE)return e;const i=e instanceof Date?e:E.parseISOWithTimezoneCheck(e);return oj(i,t,r,n)}function oj(e,t,r=il(),n=al){return e.getFullYear()<100?e=cy(e,1900+e.getFullYear()):e.getFullYear()===1111&&(e=cy(e,1970)),n.isFiscalOn||(e=VW(e,n.selectedDateLevel,n.fiscalMonth)),t=jW(t,r),t=ZW(t),t=KW(t,e,n.timeZone),t=tj(t,e,n.timeZone,r),t=YW(t,e,n.timeZone,n.selectedDateLevel,n.isFiscalOn,n.fiscalMonth),!n.isFiscalOn&&n.selectedDateLevel===R0&&(e=qW(e,n.fiscalMonth)),t=XW(t,e,n.selectedDateLevel,n.fiscalMonth),t=ej(t),Ni(e,n.timeZone,t,{locale:r,weekStartsOn:n.weekFirstDay})}function sj(e){switch(e){case V.DateLevels.Years:return"yyyy";case V.DateLevels.Quarters:return"Q yyyy";case V.DateLevels.Months:return"MM/yyyy";case V.DateLevels.Weeks:return"ww yyyy";case V.DateLevels.Days:return"shortDate";case V.DateLevels.Hours:case V.DateLevels.Minutes:case V.DateLevels.MinutesRoundTo15:case V.DateLevels.MinutesRoundTo30:case V.DateLevels.AggMinutesRoundTo1:case V.DateLevels.AggMinutesRoundTo15:case V.DateLevels.AggMinutesRoundTo30:case V.DateLevels.AggHours:return"HH:mm";case V.DateLevels.Seconds:return"HH:mm:ss";default:return"fullDate"}}const mx=(e,t=-1)=>{var n,i,a;return[...(n=e.rows)!=null?n:[],...(i=e.columns)!=null?i:[],...(a=e.values)!=null?a:[]][t]},lj=(e,t=-1)=>{const{rows:r=[],columns:n=[],values:i=[]}=e,a=Number(r.length)||0,o=Number(n.length)||0,s=Number(i.length)||0;if(t!==-1){if(t<a)return`rows.${t}`;if(t<a+o)return`columns.${t-a}`;if(t<a+o+s)return`values.${t-a-o}`}},uj=e=>{const t=E.normalizeColumn(e),r=E.getDataOptionGranularity(t);return(t==null?void 0:t.dateFormat)||E.getDefaultDateFormat(r)},cj=(e,t,r=!0)=>(n,i)=>{var d,h;const a=(i==null?void 0:i.panel)==="measures",o=n.userType===Et.CORNER,s=mx(e,(d=i==null?void 0:i.field)==null?void 0:d.index);if(a||o||!s){n.content=n.value;return}const c="type"in s||"column"in s&&"type"in s.column?uj(s):void 0;switch((h=i==null?void 0:i.jaql)==null?void 0:h.datatype){case"numeric":{const p="numberFormatConfig"in s?s.numberFormatConfig:void 0,m=parseFloat(`${n.value}`);n.content=Number.isNaN(m)?"":E.formatNumberWithFallback(m,p,r,E.applyFormatPlainText);break}case"datetime":n.content=D0(n.value,t,c);break;default:n.content=n.value}s&&"isHtml"in s&&s.isHtml&&(n.contentType="html"),n.content===""&&(n.content=O.NOT_AVAILABLE_DATA_VALUE)};function D0(e,t,r){if(e===O.NOT_AVAILABLE_DATA_VALUE)return e;if(!r)return typeof e=="string"?e:e.toISOString();const n=typeof e=="string"?E.parseISOWithTimezoneCheck(e):e;return dj(n)?typeof e=="string"?e:e.toISOString():t(n,r)}function dj(e){return e.toString()==="Invalid Date"}function Rt(e){const t="type"in e.column?e.column.type:"numeric";let r=n=>`${n}`;if(V.isNumber(t)){const n=E.getCompleteNumberFormatConfig(e&&"numberFormatConfig"in e?e.numberFormatConfig:void 0);r=i=>E.applyFormatPlainText(n,parseFloat(`${i}`))}if(V.isDatetime(t)){const n=e.dateFormat||E.getDefaultDateFormat(E.getDataOptionGranularity(e)),i=(a,o)=>ol(a,o);r=a=>D0(T7(a)?a.toISOString():a,i,n)}return n=>n===void 0?"":r(n)}function Fe(e,t){return D(D(D({dataOption:e},t&&{dataOptionLocation:t}),V.MetadataTypes.isAttribute(e.column)&&{attribute:e.column}),V.MetadataTypes.isMeasure(e.column)&&{measure:e.column})}const Zc=e=>{var t,r,n,i,a,o,s,u;return{value:(t=e.custom)==null?void 0:t.rawValue,categoryValue:(n=(r=e.custom)==null?void 0:r.xValue)==null?void 0:n[0],seriesValue:(s=(o=(a=(i=e.series)==null?void 0:i.options)==null?void 0:a.custom)==null?void 0:o.rawValue)==null?void 0:s[0],categoryDisplayValue:(u=e.name)!=null?u:e.category}},hj=(e,t)=>{const r=t.x.map((s,u)=>{var d,h;const c=(h=(d=e.custom)==null?void 0:d.xValue)==null?void 0:h[u];return z(D({},Fe(s)),{value:c,displayValue:Rt(s)(c)})}),n=t.y.length>=2,i=t.y.filter((s,u)=>!n||e.series.index===u).flatMap(s=>{const u=e.custom.rawValue;return z(D({},Fe(s)),{value:u,displayValue:Rt(s)(u)})}),a=t.breakBy.map(s=>{var c,d,h;const u=(h=(d=(c=e.series)==null?void 0:c.options.custom)==null?void 0:d.rawValue)==null?void 0:h[0];return z(D({},Fe(s)),{value:u,displayValue:Rt(s)(u)})}),o={category:r,value:i,breakBy:a};return z(D({},Zc(e)),{entries:o})},fj=(e,t)=>{const r=t.x.map((s,u)=>{var d,h;const c=(h=(d=e.custom)==null?void 0:d.xValue)==null?void 0:h[u];return z(D({},Fe(s)),{value:c,displayValue:Rt(s)(c)})}),n=t.rangeValues.length>=2,i=t.rangeValues.filter((s,u)=>!n||e.series.index===u).flatMap(s=>s.map((u,c)=>{var p,m;const h=c===0?(p=e.options)==null?void 0:p.low:(m=e.options)==null?void 0:m.high;return z(D({},Fe(u)),{value:h,displayValue:Rt(u)(h)})})),a=t.breakBy.map(s=>{var c,d,h;const u=(h=(d=(c=e.series)==null?void 0:c.options.custom)==null?void 0:d.rawValue)==null?void 0:h[0];return z(D({},Fe(s)),{value:u,displayValue:Rt(s)(u)})}),o={category:r,value:i,breakBy:a};return z(D({},Zc(e)),{entries:o})},pj=(e,t)=>{var n,i,a,o,s;const r={};if(t.x){const u=e.custom.maskedX;r.x=z(D({},Fe(t.x)),{value:u,displayValue:u})}if(t.y){const u=e.custom.maskedY;r.y=z(D({},Fe(t.y)),{value:u,displayValue:u})}if(t.breakByPoint){const u=(n=e.custom)==null?void 0:n.maskedBreakByPoint;r.breakByPoint=z(D({},Fe(t.breakByPoint)),{value:(i=e.custom)==null?void 0:i.maskedBreakByPoint,displayValue:u})}if(t.breakByColor){const u=(a=e.custom)==null?void 0:a.maskedBreakByColor;r.breakByColor=z(D({},Fe(t.breakByColor)),{value:u,displayValue:u})}if(t.size){const u=e.custom.maskedSize;r.size=z(D({},Fe(t.size)),{value:u,displayValue:u})}return{x:e.x,y:e.y,size:e.z,breakByPoint:(o=e.custom)==null?void 0:o.maskedBreakByPoint,breakByColor:(s=e.custom)==null?void 0:s.maskedBreakByColor,entries:r}},mj=(e,t)=>{const r=t.breakBy.map((a,o)=>{var u,c;const s=(c=(u=e.custom)==null?void 0:u.xValue)==null?void 0:c[o];return z(D({},Fe(a)),{value:s,displayValue:Rt(a)(s)})}),n=t.y.map(a=>{var s;const o=(s=e.custom)==null?void 0:s.rawValue;return z(D({},Fe(a)),{value:o,displayValue:Rt(a)(o)})}),i={category:r,value:n};return{value:e.options.custom.number1,categoryValue:e.options.name,categoryDisplayValue:e.name,entries:i}},gj=(e,t)=>{const r=t.breakBy.map((o,s)=>{var c,d;const u=(d=(c=e.custom)==null?void 0:c.xValue)==null?void 0:d[s];return z(D({},Fe(o)),{value:u,displayValue:Rt(o)(u)})}),n=t.y.length>=2,i=t.y.filter((o,s)=>!n||e.series.index===s).map(o=>{var u;const s=(u=e.custom)==null?void 0:u.rawValue;return z(D({},Fe(o)),{value:s,displayValue:Rt(o)(s)})}),a={category:r,value:i};return z(D({},Zc(e)),{entries:a})},vj=(e,t)=>{const r=e.options.custom.level,n=r!==e.options.custom.levelsCount,i=t.breakBy.slice(0,r).map((u,c)=>{var h,p,m,g;const d=n?(p=(h=e.custom)==null?void 0:h.rawValues)==null?void 0:p[c]:(g=(m=e.custom)==null?void 0:m.xValue)==null?void 0:g[c];return z(D({},Fe(u)),{value:d,displayValue:d})}),a=t.y.length>=2,o=t.y.filter((u,c)=>!a||e.series.index===c).map(u=>{var d;const c=n?e.value:(d=e.custom)==null?void 0:d.rawValue;return z(D({},Fe(u)),{value:c,displayValue:Rt(u)(c)})}),s={category:i,value:o};return z(D({},Zc(e)),{entries:s})},yj=(e,t)=>{var i;const r=e.series.type==="scatter",n={};if(r){const a=e.options.y;n.value=[z(D({},Fe(t.outliers)),{value:a,displayValue:Rt(t.outliers)(a)})]}else{const a=(o,s)=>o?z(D({},Fe(o)),{value:s,displayValue:Rt(o)(s)}):void 0;n.value=[a(t.boxMin,e.options.q1),a(t.boxMedian,e.options.median),a(t.boxMax,e.options.q3),a(t.whiskerMin,e.options.low),a(t.whiskerMax,e.options.high)].filter(o=>o!==void 0)}if(t.category){const a=(i=e.custom.xValue)==null?void 0:i[0];n.category=[z(D({},Fe(t.category)),{value:a,displayValue:Rt(t.category)(a)})]}return{boxMin:e.options.q1,boxMedian:e.options.median,boxMax:e.options.q3,whiskerMin:e.options.low,whiskerMax:e.options.high,outlier:e.options.y,categoryValue:e.category,categoryDisplayValue:e.category,entries:n}},bj=(e,t)=>{const r=new Date(e.options.date),n=e.options.dateString,i=e.options.value,a=z(D({},Fe(t.date)),{value:n,displayValue:Rt(t.date)(r)}),o=typeof i=="number",s=t.value&&o?z(D({},Fe(t.value)),{value:typeof i=="number"?i:0,displayValue:Rt(t.value)(i)}):void 0;return{entries:{date:a,value:s}}},_j=(e,t)=>{var m,g,b,_,w,C,S,T,M,P,R,k,I,$,G,Y,B,X,U,Q,W,q,ee,Z,J,ne,oe,ae,se,ue,me,pe,Ce;const r=e;if(!!r.isNode){const ke=(g=(m=r.name)!=null?m:r.id)!=null?g:"",we=typeof r.column=="number"?r.column:0,le=(b=t.category[we])!=null?b:t.category[0],He=typeof((w=(_=r.options)==null?void 0:_.custom)==null?void 0:w.rawValue)=="string"||typeof((S=(C=r.options)==null?void 0:C.custom)==null?void 0:S.rawValue)=="number"?r.options.custom.rawValue:ke,Te=[z(D({},Fe(le)),{value:He,displayValue:ke})],Ae=(T=r.sum)!=null?T:0,$e=z(D({},Fe(t.value)),{value:Ae,displayValue:Rt(t.value)(Ae)});return{value:Ae,categoryValue:He,categoryDisplayValue:ke,entries:{category:Te,value:[$e]}}}const i=(k=(R=(M=r.fromNode)==null?void 0:M.name)!=null?R:(P=r.fromNode)==null?void 0:P.id)!=null?k:"",a=(Y=(G=(I=r.toNode)==null?void 0:I.name)!=null?G:($=r.toNode)==null?void 0:$.id)!=null?Y:"",o=(B=r.weight)!=null?B:0,s=typeof((X=r.fromNode)==null?void 0:X.column)=="number"?r.fromNode.column:0,u=typeof((U=r.toNode)==null?void 0:U.column)=="number"?r.toNode.column:s+1,c=(Q=t.category[s])!=null?Q:t.category[0],d=(W=t.category[u])!=null?W:t.category[t.category.length-1],h=typeof((Z=(ee=(q=r.fromNode)==null?void 0:q.options)==null?void 0:ee.custom)==null?void 0:Z.rawValue)=="string"||typeof((oe=(ne=(J=r.fromNode)==null?void 0:J.options)==null?void 0:ne.custom)==null?void 0:oe.rawValue)=="number"?r.fromNode.options.custom.rawValue:i,p=typeof((ue=(se=(ae=r.toNode)==null?void 0:ae.options)==null?void 0:se.custom)==null?void 0:ue.rawValue)=="string"||typeof((Ce=(pe=(me=r.toNode)==null?void 0:me.options)==null?void 0:pe.custom)==null?void 0:Ce.rawValue)=="number"?r.toNode.options.custom.rawValue:a;return{value:o,categoryValue:i,categoryDisplayValue:`${i} → ${a}`,entries:{category:[z(D({},Fe(c)),{value:h,displayValue:i}),z(D({},Fe(d)),{value:p,displayValue:a})],value:[z(D({},Fe(t.value)),{value:o,displayValue:Rt(t.value)(o)})]}}};function jh(e,t){switch(e.series.chart.options.chart.type){case"bubble":case"scatter":return pj(e,t);case"funnel":return mj(e,t);case"pie":return gj(e,t);case"treemap":case"sunburst":return vj(e,t);case"boxplot":return yj(e,t);case"arearange":return fj(e,t);case"heatmap":return bj(e,t);case"sankey":return _j(e,t);default:return hj(e,t)}}function wj(e,t){const r={};return t.geo&&(r.geo=[z(D({},Fe(t.geo)),{value:e.geoName})]),t.color&&(r.color=[z(D({},Fe(t.color)),{value:e.originalValue})]),z(D({},e),{entries:r})}class Kc{constructor(t,r){gt(this,"httpClient");gt(this,"defaultDataSource");gt(this,"queryApi");gt(this,"getDashboards",(...r)=>ht(this,[...r],function*(t={}){const{fields:n,expand:i,searchByTitle:a}=t,o=new URLSearchParams(D(D(D({},a&&{name:a}),(n==null?void 0:n.length)&&{fields:n==null?void 0:n.join(",")}),(i==null?void 0:i.length)&&{expand:i==null?void 0:i.join(",")})).toString(),s=yield this.httpClient.get(`api/v1/dashboards?${o}`);if(!s)return[];const u=s.map(c=>ht(this,null,function*(){if(c.oid&&!c.datasource){const d=yield this.getDashboard(c.oid,{fields:["datasource"]});return d!=null&&d.datasource?z(D({},c),{datasource:d.datasource}):c}return c}));return Promise.all(u)}));gt(this,"getDashboard",(t,r={})=>{const{fields:n,sharedMode:i,adminAccess:a}=r,o=new URLSearchParams(D(D(D({},(n==null?void 0:n.length)&&{fields:n==null?void 0:n.join(",")}),i&&{sharedMode:"true"}),a&&{adminAccess:"true"})).toString();return this.httpClient.get(`api/v1/dashboards/${t}?${o}`).catch(()=>{throw new V.TranslatableError("errors.dashboardInvalidIdentifier",{dashboardOid:t})})});gt(this,"getDashboardLegacy",(t,r={})=>{const{adminAccess:n}=r,i=new URLSearchParams(D({},n&&{adminAccess:"true"})).toString();return this.httpClient.get(`api/dashboards/${t}?${i}`).catch(()=>{throw new V.TranslatableError("errors.dashboardInvalidIdentifier",{dashboardOid:t})})});gt(this,"getDashboardWidgets",(t,r)=>{const n=new URLSearchParams(D({},r&&{sharedMode:"true"})).toString();return this.httpClient.get(`api/v1/dashboards/${t}/widgets?${n}`).catch(()=>{throw new V.TranslatableError("errors.dashboardWidgetsInvalidIdentifiers",{dashboardOid:t})})});gt(this,"getWidget",(t,r,n)=>{const i=new URLSearchParams(D({},n&&{sharedMode:"true"})).toString();return this.httpClient.get(`api/v1/dashboards/${r}/widgets/${t}?${i}`).catch(()=>{throw new V.TranslatableError("errors.widgetByIdInvalidIdentifier",{dashboardOid:r,widgetOid:t})})});gt(this,"getCountriesGeoJson",()=>this.httpClient.get("api/v1/geo/geojson/world"));gt(this,"getUsaStatesGeoJson",()=>this.httpClient.get("api/v1/geo/geojson/usa"));gt(this,"getPalettes",()=>this.httpClient.get("api/palettes"));gt(this,"getHierarchies",({dataSource:t=this.defaultDataSource,dimension:r,ids:n,alwaysIncluded:i})=>{var u,c;const a="granularity"in r;let o="";if(!t)throw new V.TranslatableError("errors.missingDataSource");if(a){const{level:d,dateTimeLevel:h,dateTimePart:p}=r.translateGranularityToJaql();o=(c=(u=d!=null?d:h)!=null?u:p)!=null?c:""}const s=new URLSearchParams(D(D(D({elasticube:V.getDataSourceName(t),table:V.getTableNameFromAttribute(r),column:V.getColumnNameFromAttribute(r)},o&&{dateLevel:o}),i&&{alwaysIncluded:`${i}`}),(n==null?void 0:n.length)&&{ids:n.join(",")})).toString();return this.httpClient.get(`api/elasticubes/hierarchies?${s}`).then((d=[])=>E.isUndefined(i)&&(n==null?void 0:n.length)?d.filter(({_id:p})=>n.includes(p)):d)});gt(this,"patchDashboard",(t,r,n)=>{const i=new URLSearchParams(D({},n&&{sharedMode:"true"})).toString();return this.httpClient.patch(`api/v1/dashboards/${t}?${i}`,r)});gt(this,"addWidgetToDashboard",(t,r,n)=>{const i=new URLSearchParams(D({},n&&{sharedMode:"true"})).toString();return this.httpClient.post(`api/v1/dashboards/${t}/widgets?${i}`,r)});gt(this,"deleteWidgetFromDashboard",(t,r,n)=>{const i=new URLSearchParams(D({},n&&{sharedMode:"true"})).toString();return this.httpClient.delete(`api/v1/dashboards/${t}/widgets/${r}?${i}`)});gt(this,"patchWidgetInDashboard",(t,r,n,i)=>{const a=new URLSearchParams(D({},i&&{sharedMode:"true"})).toString();return this.httpClient.patch(`api/v1/dashboards/${t}/widgets/${r}?${a}`,n)});gt(this,"getSharedFormulas",t=>ht(this,null,function*(){return(yield Promise.all(t.map(this.getSharedFormula))).filter(Cj).reduce((n,i)=>(n[i.oid]=i,n),{})}));gt(this,"getSharedFormula",t=>ht(this,null,function*(){return this.httpClient.get(`api/v1/formulas/${t}?flat=true`)}));gt(this,"getDataSourceFields",(t,r)=>{const{offset:n=0,count:i=9999,searchValue:a,live:o,displayNameConfig:s}=r||{};return this.queryApi.getDataSourceFields(t,{offset:n,count:i,term:a,live:o,displayNameConfig:s})});gt(this,"exportJaqlToXlsx",t=>this.httpClient.post("api/v1/export/jaql/xlsx",t,{},void 0,{returnBlob:!0}));if(!t)throw new V.TranslatableError("errors.httpClientNotFound");this.httpClient=t,this.defaultDataSource=r,this.queryApi=new gC(t)}}function Cj(e){return!!e}const gx=()=>{const{app:e}=y.useSisenseContext();return{restApi:N.useMemo(()=>e&&new Kc(e.httpClient,e.defaultDataSource),[e]),isReady:!!e}};class xj extends V.TranslatableError{constructor(){super("errors.restApiNotReady")}}const Tj=e=>{const{isReady:t,restApi:r}=gx(),[n,i]=N.useState(),[a,o]=N.useState(),s=Ej();return N.useEffect(()=>{if(!s||!t||!r)return;ht(exports,null,function*(){try{const c=Aj(e,s),d=Sj(c);if(d)i(d);else{Rj(e);let h;switch(e){case"world":h=r.getCountriesGeoJson;break;case"usa":h=r.getUsaStatesGeoJson;break;default:throw new V.TranslatableError("errors.unsupportedMapType",{mapType:e})}const p=yield h();if(!p)throw new V.TranslatableError("errors.mapLoadingFailed");const m=e==="world"?Pj(p):p;Mj(m,c),i(m)}}catch(c){o(c)}})},[r,t,e,s]),{geoJson:n,error:a}};function Sj(e){const t=localStorage.getItem(e);if(t)return JSON.parse(t)}function Mj(e,t){localStorage.setItem(t,JSON.stringify(e))}function Pj(e){const t=V.cloneDeep(e);return t.features.forEach(r=>{var n;r.id==="-99"&&(r.id=(n=r.properties)==null?void 0:n.name)}),t}function Ej(){const{app:e}=y.useSisenseContext();return e==null?void 0:e.settings.serverVersion}function Aj(e,t){return`geoJson_${e}_${t}`}function Rj(e){Object.keys(localStorage).forEach(r=>{r.startsWith(`geoJson_${e}`)&&localStorage.removeItem(r)})}const Dj=({chartData:e,dataOptions:t,designOptions:r,onDataPointClick:n})=>{const{themeSettings:i}=y.useThemeContext(),{geoJson:a}=Tj(r.mapType),o=N.useMemo(()=>t.color?e.geoData:e.geoData.map(u=>z(D({},u),{color:E.getPaletteColor(i.palette.variantColors,0)})),[e.geoData,t,i]),s=N.useCallback((u,c)=>{if(!n)return;const d=wj(u,t);n(d,c)},[t,n]);return O.jsx(O.Fragment,{children:a&&O.jsx(g7,{geoJson:a,geoData:o,dataOptions:{originalValueTitle:t.color?E.getDataOptionTitle(t.color):"",onAreaClick:s},mapType:r.mapType})})},vx=e=>e.type==="areamap"&&"geoData"in e,Nj=e=>"geo"in e,kj=e=>"mapType"in e,Lj=e=>!!e.chartData&&vx(e.chartData)&&Nj(e.dataOptions)&&kj(e.designOptions),Oj={dataOptions:LA,data:bN,designOptions:CN,renderer:{ChartRendererComponent:Dj,isCorrectRendererProps:Lj}},Ij={[V.DateLevels.Years]:"attribute.datetimeName.years",[V.DateLevels.Quarters]:"attribute.datetimeName.quarters",[V.DateLevels.Months]:"attribute.datetimeName.months",[V.DateLevels.Weeks]:"attribute.datetimeName.weeks",[V.DateLevels.Days]:"attribute.datetimeName.days",[V.DateLevels.AggHours]:"attribute.datetimeName.hours",[V.DateLevels.AggMinutesRoundTo15]:"attribute.datetimeName.minutes"};function yx(e,t,r){return r?e(Ij[r],{columnName:t}):t}function bx(e,t,r){const n=V.getColumnNameFromAttribute(e),i=r?yx(r,n,t):n;return new V.DimensionalLevelAttribute(i,e.expression,t,V.DimensionalLevelAttribute.getDefaultFormatForGranularity(t),void 0,void 0,e.dataSource)}const Ui=e=>{var t;return{x:e.category.map(r=>E.normalizeColumn(r)),y:e.value.map(r=>E.normalizeMeasureColumn(r)),breakBy:((t=e.breakBy)==null?void 0:t.map(r=>E.normalizeColumn(r)))||[],seriesToColorMap:e.seriesToColorMap}};function io(e){return[...e.x.map(Op),...e.breakBy.map(Op)].filter(N0)}function ao(e){return e.y.map(Op).filter(E.isMeasureColumn)}function oo(e){return"category"in e&&V.isArray(e.category)&&"value"in e&&V.isArray(e.value)&&"breakBy"in e&&V.isArray(e.breakBy)}function so(e){return"x"in e&&V.isArray(e.x)&&e.x.every(E.isStyledColumn)&&"y"in e&&V.isArray(e.y)&&e.y.every(E.isStyledColumn)&&"breakBy"in e&&V.isArray(e.breakBy)&&e.breakBy.every(E.isStyledColumn)}function Op(e){return e.column}function N0(e){return!E.isMeasureColumn(e)}function Qc(e){return e.y.some(t=>t.showOnRightAxis)}function Fj(e){const t=E.normalizeColumn(e.date),r=E.normalizeMeasureColumn(e.value),n=t.column;return V.isDimensionalLevelAttribute(n)&&n.granularity!==V.DateLevels.Days&&(console.warn('The calendar heatmap chart’s "date" data option supports only day level granularity. Converted to day level.'),t.column=bx(n,V.DateLevels.Days)),{date:t,value:r}}function $j(e){const t=e.date.column;return N0(t)?[t]:[]}function Bj(e){const t=e.value.column;return E.isMeasureColumn(t)?[t]:[]}function zj(e){if(!("date"in e)||!e.date||!("value"in e)||!e.value)return!1;const t=E.normalizeColumn(e.date);return V.isDatetime(t.column.type)}function _x(e){return"date"in e&&"value"in e&&typeof e.date=="object"&&typeof e.value=="object"}function Hj(e){const t=new Date(e);return new Date(t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate())}function Wj(e,t){const r=E.getColumnByName(t,e.date.column.name),n=E.getColumnByName(t,e.value.column.name);if(!r||!n)return{type:E.CALENDAR_HEATMAP_DATA_TYPE,values:[]};const i=t.rows.map(a=>{const o=E.getValue(a,r),s=E.getValue(a,n),{compareValue:u,color:c}=E.getValues(a,[n])[0],h=!(u!=null&&u.valueIsNaN)&&!(u!=null&&u.valueUndefined)?s:void 0,p=E.isBlurred(a,n);return{date:Hj(o),value:h,color:c,blur:p}});return{type:E.CALENDAR_HEATMAP_DATA_TYPE,values:i}}function wx(e){return e.type===E.CALENDAR_HEATMAP_DATA_TYPE}function jj(e){var t,r,n,i,a,o,s,u,c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k;return z(D({},Kt),{width:e.width,height:e.height,subtype:e.subtype||E.CALENDAR_HEATMAP_DEFAULTS.SUBTYPE,viewType:e.viewType||E.CALENDAR_HEATMAP_DEFAULTS.VIEW_TYPE,startOfWeek:e.startOfWeek||E.CALENDAR_HEATMAP_DEFAULTS.START_OF_WEEK,cellLabels:{enabled:(r=(t=e.cellLabels)==null?void 0:t.enabled)!=null?r:E.CALENDAR_HEATMAP_DEFAULTS.SHOW_CELL_LABEL,style:((n=e.cellLabels)==null?void 0:n.textStyle)||((i=e.cellLabels)==null?void 0:i.style)},dayLabels:{enabled:(o=(a=e.dayLabels)==null?void 0:a.enabled)!=null?o:E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL,style:((s=e.dayLabels)==null?void 0:s.textStyle)||((u=e.dayLabels)==null?void 0:u.style)},monthLabels:{enabled:(d=(c=e.monthLabels)==null?void 0:c.enabled)!=null?d:E.CALENDAR_HEATMAP_DEFAULTS.SHOW_MONTH_LABEL,style:((h=e.monthLabels)==null?void 0:h.textStyle)||((p=e.monthLabels)==null?void 0:p.style)},weekends:{enabled:(g=(m=e.weekends)==null?void 0:m.enabled)!=null?g:E.CALENDAR_HEATMAP_DEFAULTS.WEEKEND_ENABLED,days:(_=(b=e.weekends)==null?void 0:b.days)!=null?_:[...E.CALENDAR_HEATMAP_DEFAULTS.WEEKEND_DAYS],cellColor:(C=(w=e.weekends)==null?void 0:w.cellColor)!=null?C:E.CALENDAR_HEATMAP_DEFAULTS.WEEKEND_CELL_COLOR,hideValues:(T=(S=e.weekends)==null?void 0:S.hideValues)!=null?T:E.CALENDAR_HEATMAP_DEFAULTS.WEEKEND_HIDE_VALUES},pagination:{enabled:(P=(M=e.pagination)==null?void 0:M.enabled)!=null?P:E.CALENDAR_HEATMAP_DEFAULTS.SHOW_PAGINATION,style:(R=e.pagination)==null?void 0:R.textStyle,startMonth:(k=e.pagination)==null?void 0:k.startMonth}})}function Vj(e){return typeof e=="object"&&e!==null}function Uj(e=il(),t=al){return(r,n)=>ol(r,n,e,t)}function Jc(){const{app:e}=y.useSisenseContext();return N.useCallback((t,r)=>Uj(e==null?void 0:e.settings.locale,e==null?void 0:e.settings.dateConfig)(t,r),[e==null?void 0:e.settings.locale,e==null?void 0:e.settings.dateConfig])}var Cx={exports:{}};(function(e,t){(function(r,n){e.exports=n(N)})(typeof self!="undefined"?self:O.commonjsGlobal,function(r){return function(n){function i(o){if(a[o])return a[o].exports;var s=a[o]={i:o,l:!1,exports:{}};return n[o].call(s.exports,s,s.exports,i),s.l=!0,s.exports}var a={};return i.m=n,i.c=a,i.d=function(o,s,u){i.o(o,s)||Object.defineProperty(o,s,{configurable:!1,enumerable:!0,get:u})},i.n=function(o){var s=o&&o.__esModule?function(){return o.default}:function(){return o};return i.d(s,"a",s),s},i.o=function(o,s){return Object.prototype.hasOwnProperty.call(o,s)},i.p="",i(i.s=0)}([function(n,i,a){function o(){return o=Object.assign?Object.assign.bind():function(C){for(var S=1;S<arguments.length;S++){var T=arguments[S];for(var M in T)Object.prototype.hasOwnProperty.call(T,M)&&(C[M]=T[M])}return C},o.apply(this,arguments)}function s(C){return h(C)||d(C)||c(C)||u()}function u(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
22
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function c(C,S){if(C){if(typeof C=="string")return p(C,S);var T=Object.prototype.toString.call(C).slice(8,-1);return T==="Object"&&C.constructor&&(T=C.constructor.name),T==="Map"||T==="Set"?Array.from(C):T==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(T)?p(C,S):void 0}}function d(C){if(typeof Symbol!="undefined"&&C[Symbol.iterator]!=null||C["@@iterator"]!=null)return Array.from(C)}function h(C){if(Array.isArray(C))return p(C)}function p(C,S){(S==null||S>C.length)&&(S=C.length);for(var T=0,M=new Array(S);T<S;T++)M[T]=C[T];return M}function m(C){"@babel/helpers - typeof";return(m=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(S){return typeof S}:function(S){return S&&typeof Symbol=="function"&&S.constructor===Symbol&&S!==Symbol.prototype?"symbol":typeof S})(C)}Object.defineProperty(i,"__esModule",{value:!0}),a.d(i,"HighchartsReact",function(){return w});var g=a(1),b=a.n(g),_=typeof window!="undefined"?g.useLayoutEffect:g.useEffect,w=Object(g.memo)(Object(g.forwardRef)(function(C,S){var T=Object(g.useRef)(),M=Object(g.useRef)(),P=Object(g.useRef)(C.constructorType),R=Object(g.useRef)(C.highcharts);return _(function(){function k(){var $=C.highcharts||(typeof window=="undefined"?"undefined":m(window))==="object"&&window.Highcharts,G=C.constructorType||"chart";$?$[G]?C.options?M.current=$[G](T.current,C.options,C.callback):console.warn('The "options" property was not passed.'):console.warn('The "constructorType" property is incorrect or some required module is not imported.'):console.warn('The "highcharts" property was not passed.')}if(M.current){if(C.allowChartUpdate!==!1)if(C.constructorType!==P.current||C.highcharts!==R.current)P.current=C.constructorType,R.current=C.highcharts,k();else if(!C.immutable&&M.current){var I;(I=M.current).update.apply(I,[C.options].concat(s(C.updateArgs||[!0,!0])))}else k()}else k()},[C.options,C.allowChartUpdate,C.updateArgs,C.containerProps,C.highcharts,C.constructorType]),_(function(){return function(){M.current&&(M.current.destroy(),M.current=null)}},[]),Object(g.useImperativeHandle)(S,function(){return{get chart(){return M.current},container:T}},[]),b.a.createElement("div",o({},C.containerProps,{ref:T}))}));i.default=w},function(n,i){n.exports=r}])})})(Cx);var Gj=Cx.exports;const xx=O.getDefaultExportFromCjs(Gj);function qj(e,t){var a;const r=(a=e.chart.events)!=null?a:{},n=r.load,i=r.render;return z(D({},e),{chart:z(D({},e.chart),{events:z(D({},r),{load:function(){n==null||n.call(this),t()},render:function(){i==null||i.call(this),t()}})})})}var Tx={exports:{}};(function(e){(function(t){e.exports?e.exports=t:t(Highcharts)})(function(t){var r=t.relativeLength;t.wrap(t.seriesTypes.column.prototype,"translate",function(n){var i=this.options,a=i.topMargin||0,o=i.bottomMargin||0;n.call(this),this.points.forEach(function(s){var u=s.shapeArgs,c=u.width,d=u.height,h=u.x,p=u.y,m=r(i.borderRadiusTopLeft||0,c),g=r(i.borderRadiusTopRight||0,c),b=r(i.borderRadiusBottomRight||0,c),_=r(i.borderRadiusBottomLeft||0,c);if(m||g||b||_){var w=Math.min(c,d)/2;m>w&&(m=w),g>w&&(g=w),b>w&&(b=w),_>w&&(_=w),s.dlBox=s.shapeArgs,s.shapeType="path",s.shapeArgs={d:[["M",h+m,p+a],["L",h+c-g,p+a],["C",h+c-g/2,p,h+c,p+g/2,h+c,p+g],["L",h+c,p+d-b],["C",h+c,p+d-b/2,h+c-b/2,p+d,h+c-b,p+d+o],["L",h+_,p+d+o],["C",h+_/2,p+d,h,p+d-_/2,h,p+d-_],["L",h,p+m],["C",h,p+m/2,h+m/2,p,h+m,p],["Z"]]}}})})})})(Tx);var Yj=Tx.exports;const Xj=O.getDefaultExportFromCjs(Yj);var Sx={exports:{}};(function(e){(function(t){e.exports?(t.default=t,e.exports=t):t(typeof Highcharts!="undefined"?Highcharts:void 0)})(function(t){function r(n,i,a,o){n.hasOwnProperty(i)||(n[i]=o.apply(null,a),typeof CustomEvent=="function"&&window.dispatchEvent(new CustomEvent("HighchartsModuleLoaded",{detail:{path:i,module:n[i]}})))}t=t?t._modules:{},r(t,"Series/NodesComposition.js",[t["Core/Series/SeriesRegistry.js"],t["Core/Utilities.js"]],function(n,i){n=n.series;var a=n.prototype,o=n.prototype.pointClass.prototype,s=i.defined,u=i.extend,c=i.find,d=i.merge,h=i.pick,p;return function(m){function g(){return this.data=[].concat(this.points||[],this.nodes),a.destroy.apply(this,arguments)}function b(){this.nodes&&(this.nodes.forEach(function(S){S.destroy()}),this.nodes.length=0),a.setData.apply(this,arguments)}function _(S){var T=arguments,M=this.isNode?this.linksTo.concat(this.linksFrom):[this.fromNode,this.toNode];S!=="select"&&M.forEach(function(P){P&&P.series&&(o.setState.apply(P,T),P.isNode||(P.fromNode.graphic&&o.setState.apply(P.fromNode,T),P.toNode&&P.toNode.graphic&&o.setState.apply(P.toNode,T)))}),o.setState.apply(this,T)}function w(S,T,M,P){var R=this,k=this.series.options.nodes,I=this.series.options.data,$=I&&I.length||0,G=I&&I[this.index];o.update.call(this,S,this.isNode?!1:T,M,P),this.isNode&&(S=(k||[]).reduce(function(Y,B,X){return R.id===B.id?X:Y},-1),P=d(k&&k[S]||{},I&&I[this.index]||{}),I&&(G?I[this.index]=G:I.length=$),k?0<=S?k[S]=P:k.push(P):this.series.options.nodes=[P],h(T,!0)&&this.series.chart.redraw(M))}var C=[];m.compose=function(S,T){return C.indexOf(S)===-1&&(C.push(S),S=S.prototype,S.setNodeState=_,S.setState=_,S.update=w),C.indexOf(T)===-1&&(C.push(T),S=T.prototype,S.destroy=g,S.setData=b),T},m.createNode=function(S){var T=this.pointClass,M=function(k,I){return c(k,function($){return $.id===I})},P=M(this.nodes,S);if(!P){M=this.options.nodes&&M(this.options.nodes,S);var R=new T().init(this,u({className:"highcharts-node",isNode:!0,id:S,y:1},M));R.linksTo=[],R.linksFrom=[],R.getSum=function(){var k=0,I=0;return R.linksTo.forEach(function($){k+=$.weight||0}),R.linksFrom.forEach(function($){I+=$.weight||0}),Math.max(k,I)},R.offset=function(k,I){for(var $=0,G=0;G<R[I].length;G++){if(R[I][G]===k)return $;$+=R[I][G].weight}},R.hasShape=function(){var k=0;return R.linksTo.forEach(function(I){I.outgoing&&k++}),!R.linksTo.length||k!==R.linksTo.length},R.index=this.nodes.push(R)-1,P=R}return P.formatPrefix="node",P.name=P.name||P.options.id||"",P.mass=h(P.options.mass,P.options.marker&&P.options.marker.radius,this.options.marker&&this.options.marker.radius,4),P},m.destroy=g,m.generatePoints=function(){var S=this,T=this.chart,M={};a.generatePoints.call(this),this.nodes||(this.nodes=[]),this.colorCounter=0,this.nodes.forEach(function(P){P.linksFrom.length=0,P.linksTo.length=0,P.level=P.options.level}),this.points.forEach(function(P){s(P.from)&&(M[P.from]||(M[P.from]=S.createNode(P.from)),M[P.from].linksFrom.push(P),P.fromNode=M[P.from],T.styledMode?P.colorIndex=h(P.options.colorIndex,M[P.from].colorIndex):P.color=P.options.color||M[P.from].color),s(P.to)&&(M[P.to]||(M[P.to]=S.createNode(P.to)),M[P.to].linksTo.push(P),P.toNode=M[P.to]),P.name=P.name||P.id},this),this.nodeLookup=M},m.setNodeState=_,m.updateNode=w}(p||(p={})),p}),r(t,"Series/Sankey/SankeyPoint.js",[t["Core/Series/Point.js"],t["Core/Series/SeriesRegistry.js"],t["Core/Utilities.js"]],function(n,i,a){var o=this&&this.__extends||function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var m in p)p.hasOwnProperty(m)&&(h[m]=p[m])},u(c,d)};return function(c,d){function h(){this.constructor=c}u(c,d),c.prototype=d===null?Object.create(d):(h.prototype=d.prototype,new h)}}(),s=a.defined;return function(u){function c(){var d=u!==null&&u.apply(this,arguments)||this;return d.className=void 0,d.fromNode=void 0,d.level=void 0,d.linkBase=void 0,d.linksFrom=void 0,d.linksTo=void 0,d.mass=void 0,d.nodeX=void 0,d.nodeY=void 0,d.options=void 0,d.series=void 0,d.toNode=void 0,d}return o(c,u),c.prototype.applyOptions=function(d,h){return n.prototype.applyOptions.call(this,d,h),s(this.options.level)&&(this.options.column=this.column=this.options.level),this},c.prototype.getClassName=function(){return(this.isNode?"highcharts-node ":"highcharts-link ")+n.prototype.getClassName.call(this)},c.prototype.getFromNode=function(){for(var d=-1,h,p=0;p<this.linksTo.length;p++){var m=this.linksTo[p];m.fromNode.column>d&&m.fromNode!==this&&(h=m.fromNode,d=h.column)}return{fromNode:h,fromColumn:d}},c.prototype.setNodeColumn=function(){s(this.options.column)||(this.column=this.linksTo.length===0?0:this.getFromNode().fromColumn+1)},c.prototype.isValid=function(){return this.isNode||typeof this.weight=="number"},c}(i.seriesTypes.column.prototype.pointClass)}),r(t,"Series/Sankey/SankeySeriesDefaults.js",[],function(){return{borderWidth:0,colorByPoint:!0,curveFactor:.33,dataLabels:{enabled:!0,backgroundColor:"none",crop:!1,nodeFormat:void 0,nodeFormatter:function(){return this.point.name},format:void 0,formatter:function(){},inside:!0},inactiveOtherPoints:!0,linkOpacity:.5,opacity:1,minLinkWidth:0,nodeWidth:20,nodePadding:10,showInLegend:!1,states:{hover:{linkOpacity:1,opacity:1},inactive:{linkOpacity:.1,opacity:.1,animation:{duration:50}}},tooltip:{followPointer:!0,headerFormat:'<span style="font-size: 10px">{series.name}</span><br/>',pointFormat:"{point.fromNode.name} → {point.toNode.name}: <b>{point.weight}</b><br/>",nodeFormat:"{point.name}: <b>{point.sum}</b><br/>"}}}),r(t,"Series/Sankey/SankeyColumnComposition.js",[t["Core/Utilities.js"]],function(n){var i=n.defined,a=n.relativeLength,o;return function(s){s.compose=function(c,d){return c.sankeyColumn=new u(c,d),c};var u=function(){function c(d,h){this.points=d,this.series=h}return c.prototype.getTranslationFactor=function(d){for(var h=this.points,p=h.slice(),m=d.options.minLinkWidth||0,g=0,b,_=(d.chart.plotSizeY||0)-(d.options.borderWidth||0)-(h.length-1)*d.nodePadding;h.length;){for(g=_/h.sankeyColumn.sum(),d=!1,b=h.length;b--;)h[b].getSum()*g<m&&(h.splice(b,1),_-=m,d=!0);if(!d)break}return h.length=0,p.forEach(function(w){h.push(w)}),g},c.prototype.top=function(d){var h=this.series,p=h.nodePadding,m=this.points.reduce(function(g,b){return 0<g&&(g+=p),b=Math.max(b.getSum()*d,h.options.minLinkWidth||0),g+b},0);return((h.chart.plotSizeY||0)-m)/2},c.prototype.left=function(d){var h=this.series,p=h.chart,m=h.options.equalNodes,g=p.inverted?p.plotHeight:p.plotWidth,b=h.nodePadding,_=this.points.reduce(function(w,C){return 0<w&&(w+=b),C=m?g/C.series.nodes.length-b:Math.max(C.getSum()*d,h.options.minLinkWidth||0),w+C},0);return((p.plotSizeX||0)-Math.round(_))/2},c.prototype.sum=function(){return this.points.reduce(function(d,h){return d+h.getSum()},0)},c.prototype.offset=function(d,h){var p=this.points,m=this.series,g=m.nodePadding,b=0;if(m.is("organization")&&d.hangsFrom)return{absoluteTop:d.hangsFrom.nodeY};for(var _=0;_<p.length;_++){var w=p[_].getSum(),C=Math.max(w*h,m.options.minLinkWidth||0),S=d.options[m.chart.inverted?"offsetHorizontal":"offsetVertical"],T=d.options.offset||0;if(w=w?C+g:0,p[_]===d)return{relativeTop:b+(i(S)?a(S,C):a(T,w))};b+=w}},c}();s.SankeyColumnAdditions=u}(o||(o={})),o}),r(t,"Series/TreeUtilities.js",[t["Core/Color/Color.js"],t["Core/Utilities.js"]],function(n,i){function a(p,m){var g=m.before,b=m.idRoot,_=m.mapIdToNode[b],w=m.points[p.i],C=w&&w.options||{},S=[],T=0;return p.levelDynamic=p.level-(m.levelIsConstant!==!1?0:_.level),p.name=h(w&&w.name,""),p.visible=b===p.id||m.visible===!0,typeof g=="function"&&(p=g(p,m)),p.children.forEach(function(M,P){var R=o({},m);o(R,{index:P,siblings:p.children.length,visible:p.visible}),M=a(M,R),S.push(M),M.visible&&(T+=M.val)}),g=h(C.value,T),p.visible=0<=g&&(0<T||p.visible),p.children=S,p.childrenTotal=T,p.isLeaf=p.visible&&!T,p.val=g,p}var o=i.extend,s=i.isArray,u=i.isNumber,c=i.isObject,d=i.merge,h=i.pick;return{getColor:function(p,m){var g=m.index,b=m.mapOptionsToLevel,_=m.parentColor,w=m.parentColorIndex,C=m.series,S=m.colors,T=m.siblings,M=C.points,P=C.chart.options.chart,R;if(p){if(M=M[p.i],p=b[p.level]||{},b=M&&p.colorByPoint)var k=M.index%(S?S.length:P.colorCount),I=S&&S[k];C.chart.styledMode||(S=M&&M.options.color,P=p&&p.color,(R=_)&&(R=(R=p&&p.colorVariation)&&R.key==="brightness"&&g&&T?n.parse(_).brighten(g/T*R.to).get():_),R=h(S,P,I,R,C.color));var $=h(M&&M.options.colorIndex,p&&p.colorIndex,k,w,m.colorIndex)}return{color:R,colorIndex:$}},getLevelOptions:function(p){var m={};if(c(p)){var g=u(p.from)?p.from:1,b=p.levels,_={},w=c(p.defaults)?p.defaults:{};for(s(b)&&(_=b.reduce(function(C,S){if(c(S)&&u(S.level)){var T=d({},S),M=h(T.levelIsConstant,w.levelIsConstant);delete T.levelIsConstant,delete T.level,S=S.level+(M?0:g-1),c(C[S])?d(!0,C[S],T):C[S]=T}return C},{})),b=u(p.to)?p.to:1,p=0;p<=b;p++)m[p]=d({},w,c(_[p])?_[p]:{})}return m},setTreeValues:a,updateRootId:function(p){if(c(p)){var m=c(p.options)?p.options:{};m=h(p.rootNode,m.rootId,""),c(p.userOptions)&&(p.userOptions.rootId=m),p.rootNode=m}return m}}}),r(t,"Series/Sankey/SankeySeries.js",[t["Core/Color/Color.js"],t["Core/Globals.js"],t["Series/NodesComposition.js"],t["Series/Sankey/SankeyPoint.js"],t["Series/Sankey/SankeySeriesDefaults.js"],t["Core/Series/SeriesRegistry.js"],t["Series/Sankey/SankeyColumnComposition.js"],t["Series/TreeUtilities.js"],t["Core/Utilities.js"]],function(n,i,a,o,s,u,c,d,h){var p=this&&this.__extends||function(){var M=function(P,R){return M=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(k,I){k.__proto__=I}||function(k,I){for(var $ in I)I.hasOwnProperty($)&&(k[$]=I[$])},M(P,R)};return function(P,R){function k(){this.constructor=P}M(P,R),P.prototype=R===null?Object.create(R):(k.prototype=R.prototype,new k)}}(),m=u.series,g=u.seriesTypes.column,b=d.getLevelOptions;d=h.extend;var _=h.isObject,w=h.merge,C=h.pick,S=h.relativeLength,T=h.stableSort;return h=function(M){function P(){var R=M!==null&&M.apply(this,arguments)||this;return R.colDistance=void 0,R.data=void 0,R.group=void 0,R.nodeLookup=void 0,R.nodePadding=void 0,R.nodes=void 0,R.nodeWidth=void 0,R.options=void 0,R.points=void 0,R.translationFactor=void 0,R}return p(P,M),P.getDLOptions=function(R){var k=_(R.optionsPoint)?R.optionsPoint.dataLabels:{};return R=_(R.level)?R.level.dataLabels:{},w({style:{}},R,k)},P.prototype.createNodeColumns=function(){var R=[];this.nodes.forEach(function(I){I.setNodeColumn(),R[I.column]||(R[I.column]=c.compose([],this)),R[I.column].push(I)},this);for(var k=0;k<R.length;k++)typeof R[k]=="undefined"&&(R[k]=c.compose([],this));return R},P.prototype.order=function(R,k){var I=this;typeof R.level=="undefined"&&(R.level=k,R.linksFrom.forEach(function($){$.toNode&&I.order($.toNode,k+1)}))},P.prototype.generatePoints=function(){a.generatePoints.apply(this,arguments);var R=this;this.orderNodes&&(this.nodes.filter(function(k){return k.linksTo.length===0}).forEach(function(k){R.order(k,0)}),T(this.nodes,function(k,I){return k.level-I.level}))},P.prototype.getNodePadding=function(){var R=this.options.nodePadding||0;if(this.nodeColumns){var k=this.nodeColumns.reduce(function(I,$){return Math.max(I,$.length)},0);k*R>this.chart.plotSizeY&&(R=this.chart.plotSizeY/k)}return R},P.prototype.hasData=function(){return!!this.processedXData.length},P.prototype.pointAttribs=function(R,k){if(!R)return{};var I=this,$=I.mapOptionsToLevel[(R.isNode?R.level:R.fromNode.level)||0]||{},G=R.options,Y=$.states&&$.states[k||""]||{};k=["colorByPoint","borderColor","borderWidth","linkOpacity","opacity"].reduce(function(X,U){return X[U]=C(Y[U],G[U],$[U],I.options[U]),X},{});var B=C(Y.color,G.color,k.colorByPoint?R.color:$.color);return R.isNode?{fill:B,stroke:k.borderColor,"stroke-width":k.borderWidth,opacity:k.opacity}:{fill:n.parse(B).setOpacity(k.linkOpacity).get()}},P.prototype.drawTracker=function(){g.prototype.drawTracker.call(this,this.points),g.prototype.drawTracker.call(this,this.nodes)},P.prototype.drawPoints=function(){g.prototype.drawPoints.call(this,this.points),g.prototype.drawPoints.call(this,this.nodes)},P.prototype.drawDataLabels=function(){g.prototype.drawDataLabels.call(this,this.points),g.prototype.drawDataLabels.call(this,this.nodes)},P.prototype.translate=function(){this.processedXData||this.processData(),this.generatePoints(),this.nodeColumns=this.createNodeColumns(),this.nodeWidth=S(this.options.nodeWidth,this.chart.plotSizeX);var R=this,k=this.chart,I=this.options,$=this.nodeWidth,G=this.nodeColumns;this.nodePadding=this.getNodePadding(),this.translationFactor=G.reduce(function(Y,B){return Math.min(Y,B.sankeyColumn.getTranslationFactor(R))},1/0),this.colDistance=(k.plotSizeX-$-I.borderWidth)/Math.max(1,G.length-1),R.mapOptionsToLevel=b({from:1,levels:I.levels,to:G.length-1,defaults:{borderColor:I.borderColor,borderRadius:I.borderRadius,borderWidth:I.borderWidth,color:R.color,colorByPoint:I.colorByPoint,levelIsConstant:!0,linkColor:I.linkColor,linkLineWidth:I.linkLineWidth,linkOpacity:I.linkOpacity,states:I.states}}),G.forEach(function(Y){Y.forEach(function(B){R.translateNode(B,Y)})},this),this.nodes.forEach(function(Y){Y.linksFrom.forEach(function(B){(B.weight||B.isNull)&&B.to&&(R.translateLink(B),B.allowShadow=!1)})})},P.prototype.translateLink=function(R){var k=function(Te,Ae){return Ae=Te.offset(R,Ae)*Y,Math.min(Te.nodeY+Ae,Te.nodeY+(Te.shapeArgs&&Te.shapeArgs.height||0)-B)},I=R.fromNode,$=R.toNode,G=this.chart,Y=this.translationFactor,B=Math.max(R.weight*Y,this.options.minLinkWidth),X=(G.inverted?-this.colDistance:this.colDistance)*this.options.curveFactor,U=k(I,"linksFrom");k=k($,"linksTo");var Q=I.nodeX,W=this.nodeWidth;$=$.nodeX;var q=R.outgoing,ee=$>Q+W;if(G.inverted&&(U=G.plotSizeY-U,k=(G.plotSizeY||0)-k,W=-W,B=-B,ee=Q>$),R.shapeType="path",R.linkBase=[U,U+B,k,k+B],ee&&typeof k=="number")R.shapeArgs={d:[["M",Q+W,U],["C",Q+W+X,U,$-X,k,$,k],["L",$+(q?W:0),k+B/2],["L",$,k+B],["C",$-X,k+B,Q+W+X,U+B,Q+W,U+B],["Z"]]};else if(typeof k=="number"){X=$-20-B,q=$-20,ee=Q+W;var Z=ee+20,J=Z+B,ne=U,oe=U+B,ae=oe+20,se=ae+(G.plotHeight-U-B),ue=se+20,me=ue+B,pe=k,Ce=pe+B,ke=Ce+20,we=ue+.7*B,le=$-.7*B,He=ee+.7*B;R.shapeArgs={d:[["M",ee,ne],["C",He,ne,J,oe-.7*B,J,ae],["L",J,se],["C",J,we,He,me,ee,me],["L",$,me],["C",le,me,X,we,X,se],["L",X,ke],["C",X,Ce-.7*B,le,pe,$,pe],["L",$,Ce],["C",q,Ce,q,Ce,q,ke],["L",q,se],["C",q,ue,q,ue,$,ue],["L",ee,ue],["C",Z,ue,Z,ue,Z,se],["L",Z,ae],["C",Z,oe,Z,oe,ee,oe],["Z"]]}}R.dlBox={x:Q+($-Q+W)/2,y:U+(k-U)/2,height:B,width:0},R.tooltipPos=G.inverted?[G.plotSizeY-R.dlBox.y-B/2,G.plotSizeX-R.dlBox.x]:[R.dlBox.x,R.dlBox.y+B/2],R.y=R.plotY=1,R.x=R.plotX=1,R.color||(R.color=I.color)},P.prototype.translateNode=function(R,k){var I=this.translationFactor,$=this.chart,G=this.options,Y=R.getSum(),B=Math.max(Math.round(Y*I),this.options.minLinkWidth),X=Math.round(this.nodeWidth),U=Math.round(G.borderWidth)%2/2,Q=k.sankeyColumn.offset(R,I);if(k=Math.floor(C(Q.absoluteTop,k.sankeyColumn.top(I)+Q.relativeTop))+U,U=Math.floor(this.colDistance*R.column+G.borderWidth/2)+S(R.options.offsetHorizontal||0,X)+U,U=$.inverted?$.plotSizeX-U:U,R.sum=Y){R.shapeType="rect",R.nodeX=U,R.nodeY=k,Y=U,I=k,Q=R.options.width||G.width||X;var W=R.options.height||G.height||B;$.inverted&&(Y=U-X,I=$.plotSizeY-k-B,Q=R.options.height||G.height||X,W=R.options.width||G.width||B),R.dlOptions=P.getDLOptions({level:this.mapOptionsToLevel[R.level],optionsPoint:R.options}),R.plotX=1,R.plotY=1,R.tooltipPos=$.inverted?[$.plotSizeY-I-W/2,$.plotSizeX-Y-Q/2]:[Y+Q/2,I+W/2],R.shapeArgs={x:Y,y:I,width:Q,height:W,display:R.hasShape()?"":"none"}}else R.dlOptions={enabled:!1}},P.defaultOptions=w(g.defaultOptions,s),P}(g),a.compose(o,h),d(h.prototype,{animate:m.prototype.animate,createNode:a.createNode,forceDL:!0,invertible:!0,isCartesian:!1,orderNodes:!0,noSharedTooltip:!0,pointArrayMap:["from","to","weight"],pointClass:o,searchPoint:i.noop}),u.registerSeriesType("sankey",h),h}),r(t,"masters/modules/sankey.src.js",[],function(){})})})(Sx);var Zj=Sx.exports;const Kj=O.getDefaultExportFromCjs(Zj);var Mx={exports:{}};(function(e){(function(t){e.exports?(t.default=t,e.exports=t):t(typeof Highcharts!="undefined"?Highcharts:void 0)})(function(t){function r(n,i,a,o){n.hasOwnProperty(i)||(n[i]=o.apply(null,a),typeof CustomEvent=="function"&&window.dispatchEvent(new CustomEvent("HighchartsModuleLoaded",{detail:{path:i,module:n[i]}})))}t=t?t._modules:{},r(t,"Extensions/SeriesLabel/SeriesLabelDefaults.js",[],function(){return{enabled:!0,connectorAllowed:!1,connectorNeighbourDistance:24,format:void 0,formatter:void 0,minFontSize:null,maxFontSize:null,onArea:null,style:{fontWeight:"bold"},useHTML:!1,boxesToAvoid:[]}}),r(t,"Extensions/SeriesLabel/SeriesLabelUtilities.js",[],function(){function n(a,o,s,u,c,d){return a=(d-o)*(s-a)-(u-o)*(c-a),0<a?!0:!(0>a)}function i(a,o,s,u,c,d,h,p){return n(a,o,c,d,h,p)!==n(s,u,c,d,h,p)&&n(a,o,s,u,c,d)!==n(a,o,s,u,h,p)}return{boxIntersectLine:function(a,o,s,u,c,d,h,p){return i(a,o,a+s,o,c,d,h,p)||i(a+s,o,a+s,o+u,c,d,h,p)||i(a,o+u,a+s,o+u,c,d,h,p)||i(a,o,a,o+u,c,d,h,p)},intersectRect:function(a,o){return!(o.left>a.right||o.right<a.left||o.top>a.bottom||o.bottom<a.top)}}}),r(t,"Extensions/SeriesLabel/SeriesLabel.js",[t["Core/Animation/AnimationUtilities.js"],t["Core/Chart/Chart.js"],t["Core/FormatUtilities.js"],t["Core/Defaults.js"],t["Extensions/SeriesLabel/SeriesLabelDefaults.js"],t["Extensions/SeriesLabel/SeriesLabelUtilities.js"],t["Core/Utilities.js"]],function(n,i,a,o,s,u,c){function d(Y,B,X,U,Q){var W=Y.chart,q=Y.options.label||{},ee=I(q.onArea,!!Y.area),Z=ee||q.connectorAllowed,J=W.boxesToAvoid,ne=Number.MAX_VALUE,oe=Number.MAX_VALUE,ae,se,ue;for(ue=0;J&&ue<J.length;ue+=1)if(T(J[ue],{left:B,right:B+U.width,top:X,bottom:X+U.height}))return!1;for(ue=0;ue<W.series.length;ue+=1){var me=W.series[ue];if(J=me.interpolatedPoints&&b([],me.interpolatedPoints,!0),me.visible&&J){var pe=W.plotHeight/10;for(se=W.plotTop;se<=W.plotTop+W.plotHeight;se+=pe)J.unshift({chartX:W.plotLeft,chartY:se}),J.push({chartX:W.plotLeft+W.plotWidth,chartY:se});for(pe=1;pe<J.length;pe+=1){if(J[pe].chartX>=B-16&&J[pe-1].chartX<=B+U.width+16){if(S(B,X,U.width,U.height,J[pe-1].chartX,J[pe-1].chartY,J[pe].chartX,J[pe].chartY))return!1;Y===me&&!ae&&Q&&(ae=S(B-16,X-16,U.width+32,U.height+32,J[pe-1].chartX,J[pe-1].chartY,J[pe].chartX,J[pe].chartY))}if((Z||ae)&&(Y!==me||ee)){se=B+U.width/2-J[pe].chartX;var Ce=X+U.height/2-J[pe].chartY;ne=Math.min(ne,se*se+Ce*Ce)}}if(!ee&&Z&&Y===me&&(Q&&!ae||ne<Math.pow(q.connectorNeighbourDistance||1,2))){for(pe=1;pe<J.length;pe+=1)if(ae=Math.min(Math.pow(B+U.width/2-J[pe].chartX,2)+Math.pow(X+U.height/2-J[pe].chartY,2),Math.pow(B-J[pe].chartX,2)+Math.pow(X-J[pe].chartY,2),Math.pow(B+U.width-J[pe].chartX,2)+Math.pow(X-J[pe].chartY,2),Math.pow(B+U.width-J[pe].chartX,2)+Math.pow(X+U.height-J[pe].chartY,2),Math.pow(B-J[pe].chartX,2)+Math.pow(X+U.height-J[pe].chartY,2)),ae<oe){oe=ae;var ke=J[pe]}ae=!0}}}return!Q||ae?{x:B,y:X,weight:ne-(ke?oe:0),connectorPoint:ke}:!1}function h(Y){Y.boxesToAvoid=[];var B=Y.labelSeries||[],X=Y.boxesToAvoid;Y.series.forEach(function(U){return(U.points||[]).forEach(function(Q){return(Q.dataLabels||[]).forEach(function(W){var q=W.getBBox(),ee=W.translateX+(U.xAxis?U.xAxis.pos:U.chart.plotLeft);W=W.translateY+(U.yAxis?U.yAxis.pos:U.chart.plotTop),X.push({left:ee,top:W,right:ee+q.width,bottom:W+q.height})})})}),B.forEach(function(U){var Q=U.options.label||{};U.interpolatedPoints=p(U),X.push.apply(X,Q.boxesToAvoid||[])}),Y.series.forEach(function(U){function Q(Ae,$e,Ge){var qe=Math.max(oe,I(He,-1/0)),jt=Math.min(oe+se,I(Te,1/0));return Ae>qe&&Ae<=jt-Ge.width&&$e>=ae&&$e<=ae+ue-Ge.height}var W=U.options.label;if(W&&(U.xAxis||U.yAxis)){var q="highcharts-color-"+I(U.colorIndex,"none"),ee=!U.labelBySeries,Z=W.minFontSize,J=W.maxFontSize,ne=Y.inverted,oe=ne?U.yAxis.pos:U.xAxis.pos,ae=ne?U.xAxis.pos:U.yAxis.pos,se=Y.inverted?U.yAxis.len:U.xAxis.len,ue=Y.inverted?U.xAxis.len:U.yAxis.len,me=U.interpolatedPoints,pe=I(W.onArea,!!U.area),Ce=[],ke=U.xData||[],we,le=U.labelBySeries;if(pe&&!ne){ne=[U.xAxis.toPixels(ke[0]),U.xAxis.toPixels(ke[ke.length-1])];var He=Math.min.apply(Math,ne),Te=Math.max.apply(Math,ne)}if(U.visible&&!U.boosted&&me){for(le||(le=U.name,typeof W.format=="string"?le=w(W.format,U,Y):W.formatter&&(le=W.formatter.call(U)),U.labelBySeries=le=Y.renderer.label(le,0,0,"connector",0,0,W.useHTML).addClass("highcharts-series-label highcharts-series-label-"+U.index+" "+(U.options.className||"")+" "+q),Y.renderer.styledMode||(q=typeof U.color=="string"?U.color:"#666666",le.css(P({color:pe?Y.renderer.getContrast(q):q},W.style||{})),le.attr({opacity:Y.renderer.forExport?1:0,stroke:U.color,"stroke-width":1})),Z&&J&&le.css({fontSize:Z+(U.sum||0)/(U.chart.labelSeriesMaxSum||0)*(J-Z)+"px"}),le.attr({padding:0,zIndex:3}).add()),Z=le.getBBox(),Z.width=Math.round(Z.width),ne=me.length-1;0<ne;--ne)pe?(J=me[ne].chartX-Z.width/2,q=(me[ne].chartCenterY||0)-Z.height/2,Q(J,q,Z)&&(we=d(U,J,q,Z))):(J=me[ne].chartX+3,q=me[ne].chartY-Z.height-3,Q(J,q,Z)&&(we=d(U,J,q,Z,!0)),we&&Ce.push(we),J=me[ne].chartX+3,q=me[ne].chartY+3,Q(J,q,Z)&&(we=d(U,J,q,Z,!0)),we&&Ce.push(we),J=me[ne].chartX-Z.width-3,q=me[ne].chartY+3,Q(J,q,Z)&&(we=d(U,J,q,Z,!0)),we&&Ce.push(we),J=me[ne].chartX-Z.width-3,q=me[ne].chartY-Z.height-3,Q(J,q,Z)&&(we=d(U,J,q,Z,!0))),we&&Ce.push(we);if(W.connectorAllowed&&!Ce.length&&!pe)for(J=oe+se-Z.width;J>=oe;J-=16)for(q=ae;q<ae+ue-Z.height;q+=16)(we=d(U,J,q,Z,!0))&&Ce.push(we);Ce.length?(Ce.sort(function(Ae,$e){return $e.weight-Ae.weight}),we=Ce[0],(Y.boxesToAvoid||[]).push({left:we.x,right:we.x+Z.width,top:we.y,bottom:we.y+Z.height}),(me=Math.sqrt(Math.pow(Math.abs(we.x-(le.x||0)),2)+Math.pow(Math.abs(we.y-(le.y||0)),2)))&&U.labelBySeries&&(Ce={opacity:Y.renderer.forExport?1:0,x:we.x,y:we.y},W={opacity:1},10>=me&&(W={x:Ce.x,y:Ce.y},Ce={}),me=void 0,ee&&(me=_(U.options.animation),me.duration*=.2),U.labelBySeries.attr(P(Ce,{anchorX:we.connectorPoint&&(we.connectorPoint.plotX||0)+oe,anchorY:we.connectorPoint&&(we.connectorPoint.plotY||0)+ae})).animate(W,me),U.options.kdNow=!0,U.buildKDTree(),U=U.searchPoint({chartX:we.x,chartY:we.y},!0))&&(le.closest=[U,we.x-(U.plotX||0),we.y-(U.plotY||0)])):le&&(U.labelBySeries=le.destroy())}else le&&(U.labelBySeries=le.destroy())}}),R(Y,"afterDrawSeriesLabels")}function p(Y){function B(pe){var Ce=Math.round((pe.plotX||0)/8)+","+Math.round((pe.plotY||0)/8);oe[Ce]||(oe[Ce]=1,U.push(pe))}if(Y.xAxis||Y.yAxis){var X=Y.points,U=[],Q=Y.graph||Y.area,W=Q&&Q.element,q=Y.chart.inverted,ee=Y.xAxis,Z=Y.yAxis,J=q?Z.pos:ee.pos;q=q?ee.pos:Z.pos,ee=I((Y.options.label||{}).onArea,!!Y.area);var ne=Z.getThreshold(Y.options.threshold),oe={};if(Y.getPointSpline&&W&&W.getPointAtLength&&!ee&&X.length<(Y.chart.plotSizeX||0)/16){for(ee=Q.toD&&Q.attr("d"),Q.toD&&Q.attr({d:Q.toD}),Z=W.getTotalLength(),Y=0;Y<Z;Y+=16)ne=W.getPointAtLength(Y),B({chartX:J+ne.x,chartY:q+ne.y,plotX:ne.x,plotY:ne.y});ee&&Q.attr({d:ee});var ae=X[X.length-1];B({chartX:J+(ae.plotX||0),chartY:q+(ae.plotY||0)})}else for(Z=X.length,Q=void 0,Y=0;Y<Z;Y+=1){ae=X[Y],W=ae.plotX;var se=ae.plotY;if(k(W)&&k(se)){var ue={plotX:W,plotY:se,chartX:J+W,chartY:q+se};if(ee&&(ue.chartCenterY=q+(se+I(ae.yBottom,ne))/2),Q){ae=Math.abs(ue.chartX-Q.chartX);var me=Math.abs(ue.chartY-Q.chartY);if(ae=Math.max(ae,me),16<ae)for(ae=Math.ceil(ae/16),me=1;me<ae;me+=1)B({chartX:Q.chartX+me/ae*(ue.chartX-Q.chartX),chartY:Q.chartY+me/ae*(ue.chartY-Q.chartY),chartCenterY:(Q.chartCenterY||0)+me/ae*((ue.chartCenterY||0)-(Q.chartCenterY||0)),plotX:(Q.plotX||0)+me/ae*(W-(Q.plotX||0)),plotY:(Q.plotY||0)+me/ae*(se-(Q.plotY||0))})}B(ue),Q=ue}}return U}}function m(Y){if(this.renderer){var B=this,X=_(B.renderer.globalAnimation).duration;B.labelSeries=[],B.labelSeriesMaxSum=0,B.seriesLabelTimer&&c.clearTimeout(B.seriesLabelTimer),B.series.forEach(function(U){var Q=U.options.label||{},W=U.labelBySeries,q=W&&W.closest;Q.enabled&&U.visible&&(U.graph||U.area)&&!U.boosted&&B.labelSeries&&(B.labelSeries.push(U),Q.minFontSize&&Q.maxFontSize&&U.yData&&(U.sum=U.yData.reduce(function(ee,Z){return(ee||0)+(Z||0)},0),B.labelSeriesMaxSum=Math.max(B.labelSeriesMaxSum||0,U.sum||0)),Y.type==="load"&&(X=Math.max(X,_(U.options.animation).duration)),q&&(typeof q[0].plotX!="undefined"?W.animate({x:q[0].plotX+q[1],y:q[0].plotY+q[2]}):W.attr({opacity:0})))}),B.seriesLabelTimer=$(function(){B.series&&B.labelSeries&&h(B)},B.renderer.forExport||!X?0:X)}}function g(Y,B,X,U,Q){var W=Q&&Q.anchorX;Q=Q&&Q.anchorY;var q=X/2;if(k(W)&&k(Q)){var ee=[["M",W,Q]],Z=B-Q;0>Z&&(Z=-U-Z),Z<X&&(q=W<Y+X/2?Z:X-Z),Q>B+U?ee.push(["L",Y+q,B+U]):Q<B?ee.push(["L",Y+q,B]):W<Y?ee.push(["L",Y,B+U/2]):W>Y+X&&ee.push(["L",Y+X,B+U/2])}return ee||[]}var b=this&&this.__spreadArray||function(Y,B,X){if(X||arguments.length===2)for(var U=0,Q=B.length,W;U<Q;U++)!W&&U in B||(W||(W=Array.prototype.slice.call(B,0,U)),W[U]=B[U]);return Y.concat(W||Array.prototype.slice.call(B))},_=n.animObject,w=a.format,C=o.setOptions,S=u.boxIntersectLine,T=u.intersectRect,M=c.addEvent,P=c.extend,R=c.fireEvent,k=c.isNumber,I=c.pick,$=c.syncTimeout,G=[];return{compose:function(Y,B){G.indexOf(Y)===-1&&(G.push(Y),M(i,"load",m),M(i,"redraw",m)),G.indexOf(B)===-1&&(G.push(B),B.prototype.symbols.connector=g),G.indexOf(C)===-1&&(G.push(C),C({plotOptions:{series:{label:s}}}))}}}),r(t,"masters/modules/series-label.src.js",[t["Core/Globals.js"],t["Extensions/SeriesLabel/SeriesLabel.js"]],function(n,i){i.compose(n.Chart,n.SVGRenderer)})})})(Mx);var Qj=Mx.exports;const Jj=O.getDefaultExportFromCjs(Qj);var Px={exports:{}};(function(e){(function(t){e.exports?(t.default=t,e.exports=t):t(typeof Highcharts!="undefined"?Highcharts:void 0)})(function(t){function r(n,i,a,o){n.hasOwnProperty(i)||(n[i]=o.apply(null,a),typeof CustomEvent=="function"&&window.dispatchEvent(new CustomEvent("HighchartsModuleLoaded",{detail:{path:i,module:n[i]}})))}t=t?t._modules:{},r(t,"Series/Streamgraph/StreamgraphSeries.js",[t["Core/Series/SeriesRegistry.js"],t["Core/Utilities.js"]],function(n,i){var a=this&&this.__extends||function(){var c=function(d,h){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,m){p.__proto__=m}||function(p,m){for(var g in m)m.hasOwnProperty(g)&&(p[g]=m[g])},c(d,h)};return function(d,h){function p(){this.constructor=d}c(d,h),d.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}}(),o=n.seriesTypes.areaspline,s=i.merge;i=i.extend;var u=function(c){function d(){var h=c!==null&&c.apply(this,arguments)||this;return h.data=void 0,h.points=void 0,h.options=void 0,h}return a(d,c),d.prototype.streamStacker=function(h,p,m){h[0]-=p.total/2,h[1]-=p.total/2,this.stackedYData[m]=h},d.defaultOptions=s(o.defaultOptions,{fillOpacity:1,lineWidth:0,marker:{enabled:!1},stacking:"stream"}),d}(o);return i(u.prototype,{negStacks:!1}),n.registerSeriesType("streamgraph",u),u}),r(t,"masters/modules/streamgraph.src.js",[],function(){})})})(Px);var eV=Px.exports;const tV=O.getDefaultExportFromCjs(eV),rV=()=>{typeof E.Highcharts=="object"&&(Jj(E.Highcharts),tV(E.Highcharts),Kj(E.Highcharts)),function(e){e.seriesTypes.line.prototype.drawLegendSymbol=e.seriesTypes.area.prototype.drawLegendSymbol,E.Highcharts.wrap(E.Highcharts.Series.types.treemap.prototype,"pointAttribs",function(t,...r){var a;const n=t.call(this,...r),i=r[0];return(a=i.options.custom)!=null&&a.blur&&(n.fill=E.Highcharts.color(i.color).setOpacity(.2).get("rgba"),n.stroke=E.Highcharts.color(n.stroke).setOpacity(.2).get("rgba")),n})}(E.Highcharts),function(e){e.Point.prototype.importEvents=function(){const t=this;this.importedEvents&&this.importedEvents.forEach(function(i){i()}),this.importedEvents=[];const r=e.merge(t.series.options.point,t.options),n=r.events;t.events=n,e.objectEach(n,function(i,a){e.isFunction(i)&&t.importedEvents.push(e.addEvent(t,a,i))})}}(E.Highcharts),Xj(E.Highcharts),E.Highcharts.setOptions({plotOptions:{sankey:{dataLabels:{align:"center",verticalAlign:"middle"}}}})};rV();function my(e){var i,a,o,s;if(!e)return;const t=(a=(i=e.plotOptions)==null?void 0:i.series)==null?void 0:a.dataLabels,r=(s=(o=e.series)==null?void 0:o[0])==null?void 0:s.dataLabels,n=r&&typeof r=="object"?r:t&&typeof t=="object"?t:void 0;if(n)return{backgroundColor:n.backgroundColor,borderColor:n.borderColor}}function nV(e,t){return e?JSON.stringify(my(e))!==JSON.stringify(my(t)):!1}const iV={style:{height:"100%",width:"100%"}},k0=({options:e,onReady:t})=>{var g,b,_,w,C,S,T,M,P,R,k,I,$,G,Y,B,X,U,Q;const r=y.usePrevious(e),n=N.useCallback(W=>{var ee,Z,J,ne,oe,ae,se,ue;const q=e;!((ne=(J=(Z=(ee=q==null?void 0:q.plotOptions)==null?void 0:ee.series)==null?void 0:Z.point)==null?void 0:J.events)!=null&&ne.click)&&!((ue=(se=(ae=(oe=q==null?void 0:q.plotOptions)==null?void 0:oe.series)==null?void 0:ae.point)==null?void 0:se.events)!=null&&ue.contextmenu)&&(W.container.onclick=null)},[e]),i=W=>W==null?void 0:W.some(({data:q})=>q.some(ee=>!!ee.marker)),a=(r==null?void 0:r.xAxis)&&(e==null?void 0:e.xAxis)&&((g=r==null?void 0:r.xAxis[0])==null?void 0:g.type)!==((b=e==null?void 0:e.xAxis[0])==null?void 0:b.type),o=!!r&&((_=r==null?void 0:r.navigator)==null?void 0:_.enabled)!==((w=e==null?void 0:e.navigator)==null?void 0:w.enabled),s=i(r==null?void 0:r.series)&&!i(e==null?void 0:e.series),u=!!r&&((C=r==null?void 0:r.chart)==null?void 0:C.type)!==((S=e==null?void 0:e.chart)==null?void 0:S.type),c=!!r&&((R=(P=(M=(T=r==null?void 0:r.xAxis)==null?void 0:T[0])==null?void 0:M.categories)==null?void 0:P.length)!=null?R:0)!==((G=($=(I=(k=e==null?void 0:e.xAxis)==null?void 0:k[0])==null?void 0:I.categories)==null?void 0:$.length)!=null?G:0),d=!!r&&((Y=r==null?void 0:r.series)!=null?Y:[]).some((W,q)=>{var ee,Z,J,ne,oe,ae;return((Z=(ee=W==null?void 0:W.data)==null?void 0:ee.length)!=null?Z:0)!==((ae=(oe=(ne=(J=e==null?void 0:e.series)==null?void 0:J[q])==null?void 0:ne.data)==null?void 0:oe.length)!=null?ae:0)}),h=!!r&&((X=(B=r==null?void 0:r.series)==null?void 0:B.length)!=null?X:0)!==((Q=(U=e==null?void 0:e.series)==null?void 0:U.length)!=null?Q:0),p=a||o||u||s||c||d||h||nV(r,e),m=N.useMemo(()=>{const W=V.cloneDeep(e);return t?qj(W,t):W},[e,t]);return O.jsx(xx,{highcharts:E.Highcharts,options:m,containerProps:iV,immutable:p,callback:n})};function aV(e,t,r,n){return V.baseForOwn(e,function(i,a,o){t(n,r(i),a,o)}),n}function oV(e,t){return function(r,n){return aV(r,e,t(n),{})}}var sV=Object.prototype,lV=sV.toString,uV=oV(function(e,t,r){t!=null&&typeof t.toString!="function"&&(t=lV.call(t)),e[t]=r},V.constant(V.identity)),L0=(e=>(e.SUNDAY="sunday",e.MONDAY="monday",e.TUESDAY="tuesday",e.WEDNESDAY="wednesday",e.THURSDAY="thursday",e.FRIDAY="friday",e.SATURDAY="saturday",e))(L0||{});const Ex={sunday:0,monday:1,tuesday:2,wednesday:3,thursday:4,friday:5,saturday:6},cV=uV(Ex);function sl(e){return Ex[e]}function dV(e){return cV[e]}function O0(e,t,r=E.SINGLE_LETTER_DAY_DATE_FORMAT){const n=new Date(E.REFERENCE_SUNDAY_DATE),i=sl(e),a=[];for(let o=i;o<i+E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK;o++){const s=new Date(n);s.setDate(n.getDate()+o);const u=t(s,r);a.push(u)}return a}function hV(e){const t=E.getPaletteColor(e.palette.variantColors,0),r=E.scaleBrightness(t,E.CALENDAR_HEATMAP_COLORS.MIN_COLOR_BRIGHTNESS_PERCENT),n=E.scaleBrightness(r,E.CALENDAR_HEATMAP_COLORS.MAX_COLOR_BRIGHTNESS_PERCENT);return{type:"range",minColor:r,maxColor:n}}function fV(e){if(!e)return r=>r;const t=E.createDataColoringFunction({getValueFromDataStructure:r=>{var n;return(n=r.value)!=null?n:0},applyColorToDataStructure:(r,n)=>z(D({},r),{color:r.color||n})});return r=>z(D({},r),{values:t(r.values,e)})}function Ax(e,t){if(e==="calendar-heatmap/continuous"){let r;switch(t){case E.ViewType.MONTH:r=1;break;case E.ViewType.QUARTER:r=3;break;case E.ViewType.HALF_YEAR:r=6;break;case E.ViewType.YEAR:r=6;break;default:r=1}const n=Math.ceil(r*5);return{rows:E.CALENDAR_HEATMAP_SIZING.ROWS,cols:n}}else return{rows:E.CALENDAR_HEATMAP_SIZING.ROWS,cols:E.CALENDAR_HEATMAP_SIZING.COLUMNS}}function Rx(e,t,r){if(r==="calendar-heatmap/continuous")return e===E.ViewType.YEAR?{cols:1,rows:2}:{cols:1,rows:1};const n=t.height>t.width;switch(e){case E.ViewType.MONTH:return{cols:1,rows:1};case E.ViewType.QUARTER:return n?{cols:1,rows:3}:{cols:3,rows:1};case E.ViewType.HALF_YEAR:return n?{cols:2,rows:3}:{cols:3,rows:2};case E.ViewType.YEAR:return n?{cols:3,rows:4}:t.width/t.height>2.5?{cols:6,rows:2}:{cols:4,rows:3};default:return{cols:1,rows:1}}}function pV(e,t,r){const n=Rx(t,e,r),i=e.height-E.CALENDAR_HEATMAP_SIZING.PAGINATION_HEIGHT,a=(n.cols-1)*E.CALENDAR_HEATMAP_SIZING.GAP_WIDTH,o=(n.rows-1)*E.CALENDAR_HEATMAP_SIZING.GAP_HEIGHT,s=(e.width-a-E.CALENDAR_HEATMAP_SIZING.MARGINS.LEFT-E.CALENDAR_HEATMAP_SIZING.MARGINS.RIGHT)/n.cols,u=t!==E.ViewType.MONTH?E.CALENDAR_HEATMAP_SIZING.TITLE_HEIGHT:0,c=(i-o-E.CALENDAR_HEATMAP_SIZING.MARGINS.TOP-E.CALENDAR_HEATMAP_SIZING.MARGINS.BOTTOM)/n.rows-u;return{width:s,height:c}}function mV(e,t,r,n){var d;if(!((d=e.values)!=null&&d.length)){const h=Ax(r,n);return{rows:h.rows,cols:h.cols}}const i=e.values.map(h=>new Date(h.date)).sort((h,p)=>h.getTime()-p.getTime()),a=i[0],o=sl(t),u=(a.getDay()-o+E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK)%E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK,c=Math.ceil((i.length+u)/E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK);return{rows:E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK,cols:c}}function gV(e,t){if(e==="calendar-heatmap/split")return{left:0,top:0,right:0};const r=t.width>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL_CHART_SIZE_THRESHOLD;return{left:r?60:0,top:r?30:0,right:10}}function vV(e,t,r,n){const i=e/r,a=t/n,o=Math.min(i,a);return Math.max(E.CALENDAR_HEATMAP_SIZING.MIN_CELL_SIZE,Math.min(E.CALENDAR_HEATMAP_SIZING.MAX_CELL_SIZE,o))}function yV(e,t,r,n,i){const a=pV(e,r,t),o=t==="calendar-heatmap/continuous"?mV(n,i,t,r):Ax(t,r),s=gV(t,e),u=a.width-s.left-s.right,c=a.height-s.top,d=vV(u,c,o.cols,o.rows),h=o.cols*d,p=o.rows*d,m=Math.min(u,h)+s.left+s.right,g=Math.min(c,p)+s.top;if(t==="calendar-heatmap/continuous")return{width:Math.floor(m),height:Math.floor(g),cellSize:Math.floor(d)};const b=Math.floor(Math.min(m,g));return{width:b,height:b,cellSize:Math.floor(d)}}function bV(e){return new Date(e.year,e.month,2)}function Vh(e){return{year:e.getFullYear(),month:e.getMonth()}}function Nn(e,t){return e.year!==t.year?e.year-t.year:e.month-t.month}function _V(e,t,r){const n=Nn(e,t)>=0,i=Nn(e,r)<=0;return n&&i}function ps(e,t){let{year:r,month:n}=e;for(n+=t;n>11;)n-=12,r++;for(;n<0;)n+=12,r--;return{year:r,month:n}}function Uh(e,t,r){if(e.length>=t)return e;if(e.length===0){const s=new Date,u={year:s.getFullYear(),month:s.getMonth()},c=ps(u,t-1);return Li(u,c,r)}const n=e[e.length-1],i=t-e.length,a=ps(n,i),o=Li(ps(n,1),a,r);return[...e,...o]}function Li(e,t,r){const n=[],i={year:e.year,month:e.month};for(;Nn(i,t)<=0;){const a=bV(i);n.push({year:i.year,month:i.month,monthName:r(a,E.FULL_MONTH_DATE_FORMAT),shortMonthName:r(a,E.SHORT_MONTH_DATE_FORMAT)}),i.month++,i.month>11&&(i.month=0,i.year++)}return n}function wV(e,t,r){if(e.length===0)return Li(t,t,r);const n=e[0];if(Nn(t,n)>=0)return e;const i={year:n.month===0?n.year-1:n.year,month:n.month===0?11:n.month-1};return[...Li(t,i,r),...e]}function CV(e,t,r){if(e.length===0)return Li(t,t,r);const n=e[e.length-1];if(Nn(t,n)<=0)return e;const i={year:n.month===11?n.year+1:n.year,month:n.month===11?0:n.month+1},a=Li(i,t,r);return[...e,...a]}function xV(e){return e<=E.CALENDAR_HEATMAP_DEFAULTS.SHORT_MONTH_NAME_SPLIT_LAYOUT_WIDTH_THRESHOLD}function TV(e,t){if(!e.values||e.values.length===0)return[];const r=new Set,n=[];return e.values.forEach(i=>{const a=i.date.getFullYear(),o=i.date.getMonth(),s=`${a}-${o}`;r.has(s)||(r.add(s),n.push({year:a,month:o,monthName:t(i.date,E.FULL_MONTH_DATE_FORMAT),shortMonthName:t(i.date,E.SHORT_MONTH_DATE_FORMAT)}))}),n.sort((i,a)=>Nn(i,a))}function SV(e,t,r,n){const i=TV(e,t),a=n?I0(n):1;if(!r)return Uh(i,a,t);if(i.length===0){const c=ps(r,a-1);return Li(r,c,t)}const o=i[0],s=i[i.length-1];if(_V(r,o,s))return Uh(i,a,t);let u;if(Nn(r,o)<0)u=wV(i,r,t);else{const c=ps(r,a-1);u=CV(i,c,t)}return Uh(u,a,t)}function I0(e){switch(e){case E.ViewType.MONTH:return 1;case E.ViewType.QUARTER:return 3;case E.ViewType.HALF_YEAR:return 6;case E.ViewType.YEAR:return 12;default:return 1}}function F0(e,t,r){const n=I0(r),i=e.findIndex(u=>Nn(u,t)===0),a=i>=0?i:0;if(n===1)return e.slice(a,a+1);let o=a,s=Math.min(o+n,e.length);return s-o<n&&e.length>=n&&(o=Math.max(0,e.length-n),s=e.length),e.slice(o,s)}const MV=y.newStyled.div`
23
+ display: grid;
24
+ column-gap: 30px;
25
+ row-gap: 10px;
26
+ grid-template-columns: repeat(${e=>e.gridCols}, 1fr);
27
+ grid-template-rows: repeat(${e=>e.gridRows}, 1fr);
28
+ background-color: transparent;
29
+ place-items: center; /* Center each grid item horizontally and vertically */
30
+ `,PV=y.newStyled.div`
31
+ display: flex;
32
+ flex-direction: column;
33
+ align-items: center;
34
+ `,EV=y.newStyled.h3`
35
+ font-size: 13px;
36
+ font-weight: 400;
37
+ color: #333;
38
+ text-align: center;
39
+ text-transform: capitalize;
40
+ margin: 0;
41
+ height: ${E.CALENDAR_HEATMAP_SIZING.TITLE_HEIGHT}px;
42
+ `,AV=({monthCharts:e,availableMonths:t,currentMonth:r,subtype:n,viewType:i,monthLabels:a,size:o})=>{const{themeSettings:s}=y.useThemeContext(),u=N.useMemo(()=>Rx(i,o,n),[i,n,o]);if(t.length===0)return null;const c=F0(t,r,i);return O.jsx(MV,{viewType:i,gridCols:u.cols,gridRows:u.rows,children:e.map((d,h)=>{var g,b,_;if(!d)return null;const p=c[h];if(!p)return null;const m=xV((g=d.chart.width)!=null?g:0);return O.jsxs(PV,{children:[(a==null?void 0:a.enabled)&&i!==E.ViewType.MONTH&&n==="calendar-heatmap/split"&&O.jsx(EV,{style:z(D({},a.style),{color:((b=a.style)==null?void 0:b.color)||(s==null?void 0:s.chart.textColor),fontFamily:((_=a.style)==null?void 0:_.fontFamily)||(s==null?void 0:s.typography.fontFamily)}),children:m?p.shortMonthName:p.monthName}),O.jsx(k0,{options:d})]},`${p.year}-${p.month}`)})})},Ip=e=>{var n;const t=e.direction==="left"?"csdk-scale-x-[-1]":"",r=e.disabled?"csdk-opacity-0":"";return O.jsx("svg",z(D({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},e),{className:[e.className,t,r].join(" "),children:O.jsx("path",{fill:(n=e.fill)!=null?n:e.theme.typography.primaryTextColor,fillRule:"nonzero",d:"M13.34 12.5l-2.72-3.175a.5.5 0 1 1 .76-.65l2.998 3.5a.5.5 0 0 1 0 .65l-2.998 3.5a.5.5 0 1 1-.76-.65l2.72-3.175z"})}))},Fp=e=>{var n;const t=e.direction==="left"?"csdk-scale-x-[-1]":"",r=e.disabled?"csdk-opacity-0":"";return O.jsx("svg",z(D({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},e),{className:[e.className,t,r].join(" "),children:O.jsx("path",{fill:(n=e.fill)!=null?n:e.theme.typography.primaryTextColor,fillRule:"nonzero",d:"M11.34 12.5L8.62 9.325a.5.5 0 0 1 .76-.65l2.998 3.5a.5.5 0 0 1 0 .65l-2.998 3.5a.5.5 0 1 1-.76-.65l2.72-3.175zm.279-3.175a.5.5 0 0 1 .76-.65l2.998 3.5a.5.5 0 0 1 0 .65l-2.999 3.5a.5.5 0 1 1-.76-.65l2.72-3.175-2.72-3.175z"})}))},gy=e=>{var n;const t=e.direction==="left"?"csdk-scale-x-[-1]":"",r=e.disabled?"csdk-opacity-0":"";return O.jsx("svg",z(D({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},e),{className:[e.className,t,r].join(" "),children:O.jsxs("g",{fill:(n=e.fill)!=null?n:e.theme.typography.primaryTextColor,fillRule:"nonzero",children:[O.jsx("path",{d:"M11.61 15.62l2.97-3.33-2.83-3.16a.39.39 0 1 1 .59-.5l3.05 3.42a.39.39 0 0 1 0 .5l-3.19 3.58a.39.39 0 1 1-.59-.5zm-3.87 0l2.97-3.33-2.83-3.16a.39.39 0 1 1 .59-.5l3.05 3.42a.39.39 0 0 1 0 .5l-3.19 3.58a.39.39 0 1 1-.59-.5z"}),O.jsx("path",{d:"M16.26 15.86a.39.39 0 0 1-.77 0v-6.97a.39.39 0 0 1 .77 0v6.97z"})]})}))};function RV(e,t,r){const n=F0(e,t,r);if(n.length===0)return"";if(r==="month"){const o=n[0];return o?`${o.monthName} ${o.year}`:""}const i=n[0].year,a=n[n.length-1].year;return i===a?`${i}`:`${i} - ${a}`}const DV=y.newStyled.div`
43
+ display: flex;
44
+ justify-content: center;
45
+ align-items: center;
46
+ padding: 10px 20px;
47
+ background-color: transparent;
48
+ height: ${E.CALENDAR_HEATMAP_SIZING.PAGINATION_HEIGHT}px;
49
+ opacity: 1;
50
+ transition: opacity 0.3s ease;
51
+ box-sizing: border-box;
52
+ `,ha=y.newStyled.button`
53
+ padding: 0;
54
+ background-color: transparent;
55
+ border: none;
56
+ border-radius: 4px;
57
+ cursor: ${e=>e.disabled?"not-allowed":"pointer"};
58
+ display: flex;
59
+ align-items: center;
60
+ justify-content: center;
61
+ transition: all 0.2s ease;
62
+ opacity: ${e=>e.disabled?.3:1};
63
+
64
+ &:hover {
65
+ background-color: ${e=>e.disabled?"transparent":"rgba(0, 0, 0, 0.05)"};
66
+ }
67
+ `,NV=y.newStyled.div`
68
+ font-size: 15px;
69
+ font-weight: 400;
70
+ color: ${({theme:e})=>e.chart.textColor};
71
+ font-family: ${({theme:e})=>e.typography.fontFamily};
72
+ min-width: 110px;
73
+ text-align: center;
74
+ margin: 0 10px;
75
+ text-transform: capitalize;
76
+ `,kV=({value:e,availableMonths:t,viewType:r,onChange:n,labelStyle:i})=>{const{themeSettings:a}=y.useThemeContext(),{t:o}=O.useTranslation(),s=I0(r),u=t.findIndex(G=>Nn(G,e)===0),c=()=>{const G=t[0];G&&n({year:G.year,month:G.month})},d=()=>{if(u>0){const G=t[u-1];n({year:G.year,month:G.month})}},h=()=>{if(u<t.length-1){const G=t[u+1];n({year:G.year,month:G.month})}},p=()=>{const G=Math.max(0,t.length-s),Y=t[G];Y&&n({year:Y.year,month:Y.month})},m=()=>{const G=Math.max(0,u-s),Y=t[G];Y&&n({year:Y.year,month:Y.month})},g=()=>{const G=Math.min(t.length-s,u+s),Y=t[G];Y&&n({year:Y.year,month:Y.month})},b=u===0,_=s===1?t.length-1:Math.max(0,t.length-s),w=u>=_,C=u>0,S=u<_,T=RV(t,e,r),M=o("calendarHeatmap.navigation.firstMonth"),P=o("calendarHeatmap.navigation.lastMonth"),R=o("calendarHeatmap.navigation.previousMonth"),k=o("calendarHeatmap.navigation.nextMonth"),I=o("calendarHeatmap.navigation.previousGroup"),$=o("calendarHeatmap.navigation.nextGroup");return O.jsxs(DV,{children:[O.jsx(ha,{disabled:b,onClick:c,title:M,"aria-label":M,theme:a,children:O.jsx(gy,{direction:"left",disabled:b,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})}),r!==E.ViewType.MONTH&&O.jsx(ha,{disabled:b,onClick:m,title:I,"aria-label":I,children:O.jsx(Fp,{direction:"left",disabled:b,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})}),O.jsx(ha,{disabled:r===E.ViewType.MONTH?b:!C,onClick:d,title:R,"aria-label":R,children:O.jsx(Ip,{direction:"left",disabled:r===E.ViewType.MONTH?b:!C,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})}),O.jsx(NV,{theme:a,style:i,children:T}),O.jsx(ha,{disabled:r===E.ViewType.MONTH?w:!S,onClick:h,title:k,"aria-label":k,children:O.jsx(Ip,{direction:"right",disabled:r===E.ViewType.MONTH?w:!S,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})}),r!==E.ViewType.MONTH&&O.jsx(ha,{disabled:w,onClick:g,title:$,"aria-label":$,children:O.jsx(Fp,{direction:"right",disabled:w,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})}),O.jsx(ha,{disabled:w,onClick:p,title:P,"aria-label":P,children:O.jsx(gy,{direction:"right",disabled:w,theme:a,fill:a.chart.secondaryTextColor,width:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.WIDTH,height:E.CALENDAR_HEATMAP_SIZING.PAGINATION_BUTTON_SIZE.HEIGHT})})]})};function Lu(e){return e===null}const LV=e=>typeof e=="object"&&e!==null,vy=(e,t)=>{if(!LV(e))return;const r=e[t];return typeof r=="string"?r:void 0},OV=function(){const e=this.name,t=vy(this.options,"id"),r=!this.visible;this.chart.series.filter(i=>{if(i===this)return!1;const a=vy(i.options,"statisticalSeriesRelatesToSeries");return a===void 0?!1:a===e||t!==void 0&&a===t}).forEach(i=>i.setVisible(r,!1))},Dx=(e,t,{onDataPointClick:r,onDataPointContextMenu:n,onDataPointsSelected:i}={})=>{var o,s;const a={chart:{events:{drilldown:function(){var u,c;((c=(u=this.options)==null?void 0:u.chart)==null?void 0:c.type)==="pie"&&(this.isDrillingDownAction=!0)},redraw:function(){var u,c;((c=(u=this.options)==null?void 0:u.chart)==null?void 0:c.type)==="pie"&&(this.isDrillingDownAction?delete this.isDrillingDownAction:this.drillUp())}}},plotOptions:{series:{events:{legendItemClick:OV},point:{events:{click:()=>{}}}}}};return i&&(((o=e.chart)==null?void 0:o.type)!=="heatmap"&&(a.chart.zoomType="x"),["scatter","bubble"].includes((s=e.chart)==null?void 0:s.type)&&(a.chart.zoomType="xy"),a.chart.events.selection=u=>{u.preventDefault();const{xAxis:c,yAxis:d,originalEvent:h}=u,p=FV(c[0],d[0]);p.forEach(m=>{m.state=""}),i(p.map(m=>jh(m,t)),h)}),r&&(a.plotOptions.series.point.events.click=u=>{!!u.point.options&&(u.point.state="hover",r(jh(u.point,t),u))}),n&&(a.plotOptions.series.point.events.contextmenu=u=>{u.preventDefault(),n(jh(u.point,t),u)}),E.merge$1(e,a)};function IV(e,{onDataPointClick:t,onDataPointContextMenu:r,onDataPointsSelected:n}={}){return i=>Dx(i,e,{onDataPointClick:t,onDataPointContextMenu:r,onDataPointsSelected:n})}const FV=(e,t)=>{const r=e.axis.series.flatMap(i=>i.points).filter(({x:i,y:a})=>{const o=i>=e.min&&i<=e.max,s=!Lu(a);return o&&s});if(!t)return r;const n=t.axis.series.flatMap(i=>i.points).filter(({y:i})=>i>=t.min&&i<=t.max);return r.filter(i=>n.includes(i))},$V=600,BV=300,Nx=(e,t,r)=>{const n={duration:t.chart.animation.init.duration==="auto"?$V:t.chart.animation.init.duration},i={duration:t.chart.animation.redraw.duration==="auto"?BV:t.chart.animation.redraw.duration};return E.merge(e,{accessibility:{enabled:r},chart:{animation:i},plotOptions:{series:{animation:n}},boost:{useGPUTranslations:!0,usePreAllocated:!0}})};function zV(e,t){return r=>Nx(r,e,t)}const kx=(e,t)=>{var p;if(!t)return e;const r={backgroundColor:t.chart.backgroundColor},n={style:{fontFamily:t.typography.fontFamily}},i={itemStyle:{color:t.chart.textColor,fontFamily:t.typography.fontFamily}},o={series:{dataLabels:{style:{color:t.chart.textColor,fontFamily:t.typography.fontFamily}}}},s={activeDataLabelStyle:{color:t.chart.textColor},breadcrumbs:{buttonTheme:{fill:t.general.brandColor,stroke:t.general.brandColor,style:{color:t.general.primaryButtonTextColor},states:{hover:{fill:t.general.primaryButtonHoverColor,stroke:t.general.primaryButtonHoverColor}}}}},u={chart:r,tooltip:n,legend:i,plotOptions:o,drilldown:s},c={labels:{style:{color:t.chart.textColor,fontFamily:t.typography.fontFamily}},title:{style:{color:t.chart.textColor,fontFamily:t.typography.fontFamily}}},d={color:t==null?void 0:t.chart.backgroundColor,label:{style:{color:t.chart.textColor,fontFamily:t.typography.fontFamily}}},h=E.merge(u,e);return h.xAxis=(p=h.xAxis)==null?void 0:p.map(m=>{var b;m.plotBands=(b=m.plotBands)==null?void 0:b.map(_=>E.merge(_,z(D({},d),{color:t==null?void 0:t.chart.backgroundColor})));const g=E.merge(m,c);return g.stackLabels&&(g.stackLabels.style=D({color:t.chart.textColor,fontFamily:t.typography.fontFamily},g.stackLabels.style)),g}),h.yAxis&&(h.yAxis=h.yAxis.map(m=>{var b;m.plotBands=(b=m.plotBands)==null?void 0:b.map(_=>E.merge(_,z(D({},d),{color:_.color||(t==null?void 0:t.chart.backgroundColor)})));const g=E.merge(m,c);return g.stackLabels&&(g.stackLabels.style=D({color:t.chart.textColor,fontFamily:t.typography.fontFamily},g.stackLabels.style)),g})),h};function HV(e){return t=>kx(t,e)}const Lx=({highchartsOptionsBuilder:e,chartData:t,dataOptions:r,designOptions:n,extraConfig:i,dataPointsEventHandlers:a,onBeforeRender:o})=>{const s={chartData:t,dataOptions:r,designOptions:n,extraConfig:i};return O.flow(zV(i.themeSettings,i.accessibilityEnabled),IV(r,a),HV(i.themeSettings),WV(o))(D(z(D({chart:e.getChart(s),series:e.getSeries(s)},e.getAxes(s)),{legend:e.getLegend(s),plotOptions:e.getPlotOptions(s),tooltip:e.getTooltip(s)}),e.getExtras(s)))};function WV(e){return e||(t=>t)}function Ox(){var i,a,o,s,u;const{app:e}=y.useSisenseContext(),{t}=O.useTranslation(),{themeSettings:r}=y.useThemeContext(),n=Jc();return N.useMemo(()=>{var c,d,h,p,m,g;return{translate:t,themeSettings:r,dateFormatter:n,accessibilityEnabled:((d=(c=e==null?void 0:e.settings)==null?void 0:c.accessibilityConfig)==null?void 0:d.enabled)||!1,defaultNumberFormattingEnabled:(g=(m=(p=(h=e==null?void 0:e.settings)==null?void 0:h.chartConfig)==null?void 0:p.defaultNumberFormatting)==null?void 0:m.enabled)!=null?g:!0}},[t,r,n,(a=(i=e==null?void 0:e.settings)==null?void 0:i.accessibilityConfig)==null?void 0:a.enabled,(u=(s=(o=e==null?void 0:e.settings)==null?void 0:o.chartConfig)==null?void 0:s.defaultNumberFormatting)==null?void 0:u.enabled])}function $p(e){const t=e*E.CALENDAR_TYPOGRAPHY.FONT_SIZE_RATIO;return Math.max(E.CALENDAR_TYPOGRAPHY.MIN_AXIS_FONT_SIZE,Math.min(E.CALENDAR_TYPOGRAPHY.MAX_FONT_SIZE,t))}function jV(e){return e<30?e*.5:0}function VV(e,t,r,n=0){if(!e.values||e.values.length===0)return[];const i=e.values.map(m=>new Date(m.date)).sort((m,g)=>m.getTime()-g.getTime()),a=i[0],o=sl(r),u=(a.getDay()-o+E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK)%E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK,c=new Map;i.forEach((m,g)=>{const b=`${m.getFullYear()}-${m.getMonth()}`,_=Math.floor((g+u)/E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK);if(!c.has(b))c.set(b,{firstDate:m,lastDate:m,firstColumn:_,lastColumn:_});else{const w=c.get(b);w.lastDate=m,w.lastColumn=_}});const d=i.length,h=Math.ceil((d+u)/E.CALENDAR_HEATMAP_DEFAULTS.DAYS_IN_WEEK),p=new Array(h).fill("");return Array.from(c.entries()).forEach(([m,g])=>{const{firstDate:b,firstColumn:_,lastColumn:w}=g,C=(w-_)*n,S=_+Math.floor((w-_)/2),T=t(b,C>E.CALENDAR_HEATMAP_DEFAULTS.SHORT_MONTH_NAME_CONTINUES_LAYOUT_WIDTH_THRESHOLD?E.FULL_MONTH_DATE_FORMAT:E.SHORT_MONTH_DATE_FORMAT);S>=0&&S<p.length&&(p[S]=T)}),p}function UV(e){var g,b,_,w,C,S,T,M,P,R,k,I,$,G,Y,B,X,U,Q,W,q;const t=(g=e.designOptions.cellSize)!=null?g:0,r=e.designOptions.startOfWeek,n=e.designOptions.dayLabels,i=e.designOptions.monthLabels,a=e.designOptions.viewType,o=O0(r,e.extraConfig.dateFormatter,E.THREE_LETTER_DAY_DATE_FORMAT).reverse(),s=((b=n.style)==null?void 0:b.color)||((_=e.extraConfig.themeSettings)==null?void 0:_.chart.textColor),u=((w=n.style)==null?void 0:w.fontFamily)||((C=e.extraConfig.themeSettings)==null?void 0:C.typography.fontFamily),c=(T=(S=n.style)==null?void 0:S.fontSize)!=null?T:`${$p(t)}px`,d=((M=i.style)==null?void 0:M.color)||((P=e.extraConfig.themeSettings)==null?void 0:P.chart.textColor),h=((R=i.style)==null?void 0:R.fontFamily)||((k=e.extraConfig.themeSettings)==null?void 0:k.typography.fontFamily),p=($=(I=i.style)==null?void 0:I.fontSize)!=null?$:`${$p(t)}px`;return{xAxis:[{categories:VV(e.chartData,e.extraConfig.dateFormatter,r,e.designOptions.cellSize),opposite:!0,lineWidth:0,gridLineWidth:0,offset:0,labels:{enabled:i.enabled&&a!==E.ViewType.MONTH,rotation:0,overflow:"justify",style:D(D({fontSize:p,color:d,fontFamily:h,textOverflow:"none"},((G=i.style)==null?void 0:G.fontWeight)&&{fontWeight:i.style.fontWeight}),((Y=i.style)==null?void 0:Y.fontStyle)&&{fontStyle:i.style.fontStyle})},accessibility:{description:"months",rangeDescription:"X Axis shows months in chronological order."}}],yAxis:[{categories:n.enabled?[...o]:[],opposite:!1,lineWidth:0,gridLineWidth:0,offset:15,title:{text:null},labels:{rotation:0,style:D(D(D(D(D({fontSize:c,color:s,fontFamily:u},((B=n.style)==null?void 0:B.fontWeight)&&{fontWeight:n.style.fontWeight}),((X=n.style)==null?void 0:X.fontStyle)&&{fontStyle:n.style.fontStyle}),((U=n.style)==null?void 0:U.textOutline)&&{textOutline:n.style.textOutline}),((Q=n.style)==null?void 0:Q.pointerEvents)&&{pointerEvents:n.style.pointerEvents}),((W=n.style)==null?void 0:W.textOverflow)&&{textOverflow:n.style.textOverflow}),enabled:n.enabled&&((q=e.designOptions.height)!=null?q:0)>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL_CHART_SIZE_THRESHOLD},accessibility:{description:"days of week",rangeDescription:`Y Axis shows days of the week, starting with ${r===L0.MONDAY?"Monday":"Sunday"}.`}}]}}function GV(e){var c,d,h,p,m,g,b,_,w,C,S,T,M;const t=(c=e.designOptions.cellSize)!=null?c:0,r=e.designOptions.startOfWeek,n=e.designOptions.dayLabels,i=jV(t),a=O0(r,e.extraConfig.dateFormatter,E.SINGLE_LETTER_DAY_DATE_FORMAT),o=((d=n.style)==null?void 0:d.color)||((h=e.extraConfig.themeSettings)==null?void 0:h.chart.textColor),s=((p=n.style)==null?void 0:p.fontFamily)||((m=e.extraConfig.themeSettings)==null?void 0:m.typography.fontFamily),u=(b=(g=n.style)==null?void 0:g.fontSize)!=null?b:`${$p(t)}px`;return{xAxis:[{categories:n.enabled?[...a]:[],opposite:!0,lineWidth:0,offset:0,labels:{rotation:0,y:i,style:D(D(D(D(D({fontSize:u,color:o,fontFamily:s},((_=n.style)==null?void 0:_.fontWeight)&&{fontWeight:n.style.fontWeight}),((w=n.style)==null?void 0:w.fontStyle)&&{fontStyle:n.style.fontStyle}),((C=n.style)==null?void 0:C.textOutline)&&{textOutline:n.style.textOutline}),((S=n.style)==null?void 0:S.pointerEvents)&&{pointerEvents:n.style.pointerEvents}),((T=n.style)==null?void 0:T.textOverflow)&&{textOverflow:n.style.textOverflow}),enabled:n.enabled&&((M=e.designOptions.width)!=null?M:0)>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL_CHART_SIZE_THRESHOLD},accessibility:{description:"weekdays",rangeDescription:`X Axis is showing all 7 days of the week, starting with ${r===L0.MONDAY?"Monday":"Sunday"}.`}}],yAxis:[{categories:[],min:0,max:5,tickInterval:1,gridLineWidth:0,title:{text:null},accessibility:{description:"weeks"},visible:!1}]}}function Ix(e){var n,i;const t=(n=e.designOptions.width)!=null?n:0,r=(i=e.designOptions.height)!=null?i:0;return{type:"heatmap",plotBorderWidth:E.CALENDAR_HEATMAP_DEFAULTS.BORDER_WIDTH,backgroundColor:"transparent",marginTop:0,marginBottom:0,marginLeft:0,marginRight:0,spacing:[0,0,0,0],width:t,height:r,polar:!1}}function qV(e){var i,a;const t=(i=e.designOptions.cellSize)!=null?i:0,n=((a=e.designOptions.width)!=null?a:0)>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL_CHART_SIZE_THRESHOLD;return z(D({},Ix(e)),{marginTop:n?t:0})}function YV(e){var n;const r=((n=e.designOptions.width)!=null?n:0)>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_DAY_LABEL_CHART_SIZE_THRESHOLD;return z(D({},Ix(e)),{marginLeft:r?60:0,marginTop:r?30:0,marginRight:10})}function Fx(){return{title:{text:null},accessibility:{landmarkVerbosity:"one"}}}function $x(){return{enabled:!1}}function XV(e){const t=e*E.CALENDAR_TYPOGRAPHY.FONT_SIZE_RATIO;return Math.max(E.CALENDAR_TYPOGRAPHY.MIN_FONT_SIZE,Math.min(E.CALENDAR_TYPOGRAPHY.MAX_FONT_SIZE,t))}function Bx(e){var u,c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k;const t=e.designOptions.cellLabels,r=(c=(u=e.designOptions)==null?void 0:u.cellSize)!=null?c:0,n=((d=t==null?void 0:t.style)==null?void 0:d.fontSize)||`${XV(r)}px`,i=(p=(h=t==null?void 0:t.style)==null?void 0:h.fontWeight)!=null?p:"normal",a=(g=(m=t==null?void 0:t.style)==null?void 0:m.textOutline)!=null?g:"none",o=(w=(b=t==null?void 0:t.style)==null?void 0:b.fontFamily)!=null?w:(_=e.extraConfig.themeSettings)==null?void 0:_.typography.fontFamily,s=((C=t==null?void 0:t.style)==null?void 0:C.color)||((S=e.extraConfig.themeSettings)==null?void 0:S.chart.textColor);return{series:{},heatmap:{dataLabels:{enabled:t.enabled&&((M=(T=e.designOptions)==null?void 0:T.cellSize)!=null?M:0)>=E.CALENDAR_HEATMAP_DEFAULTS.SHOW_CELL_LABEL_SIZE_THRESHOLD,style:D(D(D({color:s,fontSize:n,fontWeight:i,textOutline:a,fontFamily:o},((P=t.style)==null?void 0:P.fontStyle)&&{fontStyle:t.style.fontStyle}),((R=t.style)==null?void 0:R.pointerEvents)&&{pointerEvents:t.style.pointerEvents}),((k=t.style)==null?void 0:k.textOverflow)&&{textOverflow:t.style.textOverflow}),formatter:function(){const I=this.point;return I.custom&&I.custom.monthDay?I.custom.monthDay.toString():""}}}}}const ZV="yyyy-MM-dd'T'HH:mm:ss";function KV(e,t){const r=dV(e.getDay());return t.includes(r)}function zx(e,t,r,n){if(e.values.length===0)return[];const i=new Date(e.values[0].date),a=i.getFullYear(),o=i.getMonth(),u=new Date(a,o,1).getDay(),c=sl(r),d=(u-c+7)%7,h=O0(r,t),p=[];return e.values.forEach(m=>{var k;const g=new Date(m.date),b=g.getDate(),_=t(g,ZV),w=(d+b-1)%h.length,C=Math.floor((d+b-1)/h.length),S=(k=m.value)!=null?k:null,T=m.value!==void 0,M=KV(g,n.days);let P;T?n.enabled&&n.days.length>0&&M?P=n.cellColor||E.CALENDAR_HEATMAP_DEFAULTS.WEEKEND_CELL_COLOR:m.color&&(P=m.color):P=E.CALENDAR_HEATMAP_DEFAULTS.NO_DATA_COLOR;const R=n.enabled&&n.hideValues&&M;p.push({x:w,y:5-C,value:S,date:g.getTime(),dateString:_,color:P,custom:{monthDay:b,hasData:!R&&T,blur:m.blur},className:T&&m.blur?"csdk-highcharts-point-blured":""})}),p}function QV(e,t,r,n){if(e.values.length===0)return[];const i=e.values.map(_=>new Date(_.date)).sort((_,w)=>_.getTime()-w.getTime()),a=i[0],o=i[i.length-1],s=new Date(a.getFullYear(),a.getMonth(),1),u=new Date(o.getFullYear(),o.getMonth()+1,0),c=new Map;for(let _=new Date(s);_<=u;_.setMonth(_.getMonth()+1)){const w=`${_.getFullYear()}-${_.getMonth()}`;c.set(w,[])}e.values.forEach(_=>{const w=new Date(_.date),C=`${w.getFullYear()}-${w.getMonth()}`;c.has(C)&&c.get(C).push(_)});const d=[],h=sl(r),p=new Date(s),m=(s.getDay()-h+7)%7;p.setDate(s.getDate()-m);for(const[_,w]of c){const[C,S]=_.split("-"),T=parseInt(C,10),M=parseInt(S,10),P={type:"calendar-heatmap",values:w.length>0?w:[{date:new Date(T,M,1),value:void 0}]},R=zx(P,t,r,n);d.push(...R)}let g=E.CALENDAR_HEATMAP_SIZING.ROWS-1-d[0].x,b=0;for(let _=0;_<d.length;_++)d[_].y=g,d[_].x=b,g--,g<0&&(g=E.CALENDAR_HEATMAP_SIZING.ROWS-1,b++);return d}function JV(e){const t=e.designOptions.startOfWeek,r=e.designOptions.weekends,n=zx(e.chartData,e.extraConfig.dateFormatter,t,r);return[{name:"Calendar Heatmap",type:"heatmap",keys:["x","y","value","date","color","custom"],data:n,nullColor:E.CALENDAR_HEATMAP_DEFAULTS.NO_DATA_COLOR,borderWidth:E.CALENDAR_HEATMAP_DEFAULTS.BORDER_WIDTH,borderColor:"transparent",colsize:1,rowsize:1}]}function eU(e){const t=e.designOptions.startOfWeek,r=e.designOptions.weekends,n=QV(e.chartData,e.extraConfig.dateFormatter,t,r);return[{name:"Calendar Heatmap",type:"heatmap",keys:["x","y","value","date","color","custom"],data:n,nullColor:E.CALENDAR_HEATMAP_DEFAULTS.NO_DATA_COLOR,borderWidth:1,borderColor:"white",colsize:1,rowsize:1}]}function Hx(e){const{dateFormatter:t}=e.extraConfig,r=e.dataOptions.value.column.title||e.dataOptions.value.column.name,n=e.designOptions.width&&e.designOptions.width<E.CALENDAR_HEATMAP_SIZING.MIN_TOOLTIP_WIDTH;return{animation:!1,backgroundColor:E.colorWhite,borderColor:E.colorChineseSilver,borderRadius:10,borderWidth:1,useHTML:!0,style:{width:n?E.CALENDAR_HEATMAP_SIZING.MIN_TOOLTIP_WIDTH:void 0},position:{relativeTo:"chart"},followPointer:!0,outside:!0,formatter:function(){var m;const i=this.point,a=i.date&&new Date(i.date);if(!(a&&!isNaN(a.getTime())))return!1;const s=e.dataOptions.date,u=E.getDataOptionGranularity(s),c=s.dateFormat||E.getDefaultDateFormat(u),d=t(a,c);let h="";if(i.value!==null&&i.value!==void 0&&((m=i.custom)!=null&&m.hasData)){const g=e.dataOptions.value.numberFormatConfig,b=g!==void 0;if(e.extraConfig.defaultNumberFormattingEnabled||b){const _=E.getCompleteNumberFormatConfig(g);h=E.applyFormat(_,i.value)}else h=String(i.value)}else h="—";const p=i.color&&E.scaleBrightness(i.color,E.CALENDAR_HEATMAP_COLORS.TOOLTIP_COLOR_BRIGHTNESS_PERCENT);return E.tooltipWrapper(`
77
+ ${r}
78
+ <br />
79
+ <span style="color: ${p!=null?p:"inherit"}">${h}</span>
80
+ ${E.tooltipSeparator()}
81
+ ${d}
82
+ `)}}}const tU={getChart:qV,getSeries:JV,getAxes:GV,getLegend:$x,getPlotOptions:Bx,getTooltip:Hx,getExtras:Fx},rU={getChart:YV,getSeries:eU,getAxes:UV,getLegend:$x,getPlotOptions:Bx,getTooltip:Hx,getExtras:Fx};function nU(e){return e==="calendar-heatmap/continuous"?rU:tU}function yy(e,t){const r=new Map;e.values.forEach(a=>{if(a.date.getFullYear()===t.year&&a.date.getMonth()===t.month){const o=`${t.year}-${t.month}-${a.date.getDate()}`;r.set(o,a)}});const n=new Date(t.year,t.month+1,0).getDate(),i=[];for(let a=1;a<=n;a++){const o=`${t.year}-${t.month}-${a}`,s=r.get(o);s?i.push(s):i.push({date:new Date(t.year,t.month,a)})}return z(D({},e),{values:i})}function by(e,t){if(!e.values||e.values.length===0){const r=z(D({},e),{values:[]});return yy(r,t)}return yy(e,t)}function iU(e,t,r,n){if(e==="calendar-heatmap/continuous"){let i=[];switch(t){case"month":i=[r.slice(0,1)];break;case"quarter":i=[r.slice(0,3)];break;case"half-year":i=[r.slice(0,6)];break;case"year":i=[r.slice(0,6),r.slice(6,12)].filter(a=>a.length>0);break;default:i=[r]}return i.map(a=>a.reduce((o,s)=>{const u=by(n,s);return z(D({},o),{values:[...o.values,...u.values]})},{type:"calendar-heatmap",values:[]}))}else return r.map(i=>by(n,i))}const aU=()=>{const e=Ox();return N.useMemo(()=>z(D({},e),{themeSettings:z(D({},e.themeSettings),{chart:z(D({},e.themeSettings.chart),{animation:z(D({},e.themeSettings.chart.animation),{redraw:z(D({},e.themeSettings.chart.animation.redraw),{duration:0})})})})}),[e])};function oU({chartData:e,dataOptions:t,designOptions:r,availableMonths:n,currentMonth:i,subtype:a,viewType:o,containerSize:s,eventHandlers:u,onBeforeRender:c}){const d=aU(),h=N.useMemo(()=>{var m;const p=(m=t.value.color)!=null?m:hV(d.themeSettings);return fV(p)(e)},[e,t.value.color,d.themeSettings]);return N.useMemo(()=>{if(n.length===0)return[];const p=F0(n,i,o);return iU(a,o,p,h).map(g=>{const b=yV(s,a,o,g,r.startOfWeek),_=nU(a);return Lx({highchartsOptionsBuilder:_,chartData:g,dataOptions:t,designOptions:z(D({},r),{width:b.width,height:b.height,cellSize:b.cellSize}),dataPointsEventHandlers:{onDataPointClick:u.onDataPointClick,onDataPointContextMenu:u.onDataPointContextMenu,onDataPointsSelected:u.onDataPointsSelected},extraConfig:d,onBeforeRender:c})})},[n,i,o,a,h,t,r,s,u.onDataPointClick,u.onDataPointContextMenu,u.onDataPointsSelected,d,c])}const sU=e=>{const{chartData:t,startMonth:r}=e,n=y.usePrevious(r),i=r?Vh(r):t.values.length>0?Vh(t.values[0].date):{year:new Date().getFullYear(),month:new Date().getMonth()},[a,o]=N.useState(i);return N.useEffect(()=>{r&&(!n||r.getTime()!==n.getTime())&&o(Vh(r))},[r,n,o]),{currentMonth:a,setCurrentMonth:o}},lU=y.newStyled.div`
83
+ display: flex;
84
+ flex-direction: column;
85
+ width: 100%;
86
+ height: 100%;
87
+ margin: 0 auto;
88
+ background-color: ${({theme:e})=>e.chart.backgroundColor};
89
+ `,uU=y.newStyled.div`
90
+ display: flex;
91
+ flex-direction: column;
92
+ align-items: center;
93
+ justify-content: center;
94
+ flex: 1;
95
+ `;function cU({chartData:e,dataOptions:t,designOptions:r,onDataPointClick:n,onDataPointContextMenu:i,onDataPointsSelected:a,onBeforeRender:o,size:s}){var _,w,C;const{themeSettings:u}=y.useThemeContext(),c=Jc(),d=r.subtype,h=r.viewType,{currentMonth:p,setCurrentMonth:m}=sU({chartData:e,startMonth:(_=r.pagination)==null?void 0:_.startMonth}),g=N.useMemo(()=>SV(e,c,p,h),[e,c,p,h]),b=oU({chartData:e,dataOptions:t,designOptions:r,availableMonths:g,currentMonth:p,subtype:d,viewType:h,containerSize:s,eventHandlers:{onDataPointClick:n,onDataPointContextMenu:i,onDataPointsSelected:a},onBeforeRender:o});return O.jsxs(lU,{theme:u,children:[g.length>0&&((w=r.pagination)==null?void 0:w.enabled)&&O.jsx(kV,{value:p,availableMonths:g,viewType:h,onChange:m,labelStyle:(C=r.pagination)==null?void 0:C.style}),O.jsx(uU,{children:O.jsx(AV,{monthCharts:b,availableMonths:g,currentMonth:p,viewType:h,subtype:d,monthLabels:r.monthLabels,size:s})})]})}const dU=e=>!!e.chartData&&wx(e.chartData)&&_x(e.dataOptions),hU={dataOptions:{translateDataOptionsToInternal:Fj,getAttributes:$j,getMeasures:Bj,isCorrectDataOptions:zj,isCorrectDataOptionsInternal:_x},data:{loadData:ur,getChartData:Wj},designOptions:{translateStyleOptionsToDesignOptions:jj,isCorrectStyleOptions:Vj},renderer:{ChartRendererComponent:cU,isCorrectRendererProps:dU}};var Wx=O.metaMap?function(e,t){return O.metaMap.set(e,t),e}:V.identity;function Ns(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var r=V.baseCreate(e.prototype),n=e.apply(r,t);return V.isObject(n)?n:r}}var fU=1;function pU(e,t,r){var n=t&fU,i=Ns(e);function a(){var o=this&&this!==V.root&&this instanceof a?i:e;return o.apply(n?r:this,arguments)}return a}var mU=Math.max;function jx(e,t,r,n){for(var i=-1,a=e.length,o=r.length,s=-1,u=t.length,c=mU(a-o,0),d=Array(u+c),h=!n;++s<u;)d[s]=t[s];for(;++i<o;)(h||i<a)&&(d[r[i]]=e[i]);for(;c--;)d[s++]=e[i++];return d}var gU=Math.max;function Vx(e,t,r,n){for(var i=-1,a=e.length,o=-1,s=r.length,u=-1,c=t.length,d=gU(a-s,0),h=Array(d+c),p=!n;++i<d;)h[i]=e[i];for(var m=i;++u<c;)h[m+u]=t[u];for(;++o<s;)(p||i<a)&&(h[m+r[o]]=e[i++]);return h}function vU(e,t){for(var r=e.length,n=0;r--;)e[r]===t&&++n;return n}var Ux=V.shortOut(Wx),yU=/\{\n\/\* \[wrapped with (.+)\] \*/,bU=/,? & /;function _U(e){var t=e.match(yU);return t?t[1].split(bU):[]}var wU=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function CU(e,t){var r=t.length;if(!r)return e;var n=r-1;return t[n]=(r>1?"& ":"")+t[n],t=t.join(r>2?", ":" "),e.replace(wU,`{
96
+ /* [wrapped with `+t+`] */
97
+ `)}function xU(e,t,r,n){for(var i=e.length,a=r+-1;++a<i;)if(t(e[a],a,e))return a;return-1}function TU(e){return e!==e}function SU(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}function $0(e,t,r){return t===t?SU(e,t,r):xU(e,TU,r)}function Gx(e,t){var r=e==null?0:e.length;return!!r&&$0(e,t,0)>-1}var MU=1,PU=2,EU=8,AU=16,RU=32,DU=64,NU=128,kU=256,LU=512,OU=[["ary",NU],["bind",MU],["bindKey",PU],["curry",EU],["curryRight",AU],["flip",LU],["partial",RU],["partialRight",DU],["rearg",kU]];function IU(e,t){return V.arrayEach(OU,function(r){var n="_."+r[0];t&r[1]&&!Gx(e,n)&&e.push(n)}),e.sort()}function qx(e,t,r){var n=t+"";return V.setToString(e,CU(n,IU(_U(n),r)))}var FU=1,$U=2,BU=4,zU=8,_y=32,wy=64;function Yx(e,t,r,n,i,a,o,s,u,c){var d=t&zU,h=d?o:void 0,p=d?void 0:o,m=d?a:void 0,g=d?void 0:a;t|=d?_y:wy,t&=~(d?wy:_y),t&BU||(t&=~(FU|$U));var b=[e,t,i,m,h,g,p,s,u,c],_=r.apply(void 0,b);return O.isLaziable(e)&&Ux(_,b),_.placeholder=n,qx(_,e,t)}function Xx(e){var t=e;return t.placeholder}var HU=Math.min;function WU(e,t){for(var r=e.length,n=HU(t.length,r),i=V.copyArray(e);n--;){var a=t[n];e[n]=V.isIndex(a,r)?i[a]:void 0}return e}var Cy="__lodash_placeholder__";function lc(e,t){for(var r=-1,n=e.length,i=0,a=[];++r<n;){var o=e[r];(o===t||o===Cy)&&(e[r]=Cy,a[i++]=r)}return a}var jU=1,VU=2,UU=8,GU=16,qU=128,YU=512;function B0(e,t,r,n,i,a,o,s,u,c){var d=t&qU,h=t&jU,p=t&VU,m=t&(UU|GU),g=t&YU,b=p?void 0:Ns(e);function _(){for(var w=arguments.length,C=Array(w),S=w;S--;)C[S]=arguments[S];if(m)var T=Xx(_),M=vU(C,T);if(n&&(C=jx(C,n,i,m)),a&&(C=Vx(C,a,o,m)),w-=M,m&&w<c){var P=lc(C,T);return Yx(e,t,B0,_.placeholder,r,C,P,s,u,c-w)}var R=h?r:this,k=p?R[e]:e;return w=C.length,s?C=WU(C,s):g&&w>1&&C.reverse(),d&&u<w&&(C.length=u),this&&this!==V.root&&this instanceof _&&(k=b||Ns(k)),k.apply(R,C)}return _}function XU(e,t,r){var n=Ns(e);function i(){for(var a=arguments.length,o=Array(a),s=a,u=Xx(i);s--;)o[s]=arguments[s];var c=a<3&&o[0]!==u&&o[a-1]!==u?[]:lc(o,u);if(a-=c.length,a<r)return Yx(e,t,B0,i.placeholder,void 0,o,c,void 0,void 0,r-a);var d=this&&this!==V.root&&this instanceof i?n:e;return V.apply(d,this,o)}return i}var ZU=1;function KU(e,t,r,n){var i=t&ZU,a=Ns(e);function o(){for(var s=-1,u=arguments.length,c=-1,d=n.length,h=Array(d+u),p=this&&this!==V.root&&this instanceof o?a:e;++c<d;)h[c]=n[c];for(;u--;)h[c++]=arguments[++s];return V.apply(p,i?r:this,h)}return o}var xy="__lodash_placeholder__",Gh=1,QU=2,JU=4,Ty=8,jo=128,Sy=256,eG=Math.min;function tG(e,t){var r=e[1],n=t[1],i=r|n,a=i<(Gh|QU|jo),o=n==jo&&r==Ty||n==jo&&r==Sy&&e[7].length<=t[8]||n==(jo|Sy)&&t[7].length<=t[8]&&r==Ty;if(!(a||o))return e;n&Gh&&(e[2]=t[2],i|=r&Gh?0:JU);var s=t[3];if(s){var u=e[3];e[3]=u?jx(u,s,t[4]):s,e[4]=u?lc(e[3],xy):t[4]}return s=t[5],s&&(u=e[5],e[5]=u?Vx(u,s,t[6]):s,e[6]=u?lc(e[5],xy):t[6]),s=t[7],s&&(e[7]=s),n&jo&&(e[8]=e[8]==null?t[8]:eG(e[8],t[8])),e[9]==null&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e}var rG="Expected a function",My=1,nG=2,qh=8,Yh=16,Xh=32,Py=64,Ey=Math.max;function iG(e,t,r,n,i,a,o,s){var u=t&nG;if(!u&&typeof e!="function")throw new TypeError(rG);var c=n?n.length:0;if(c||(t&=~(Xh|Py),n=i=void 0),o=o===void 0?o:Ey(E.toInteger(o),0),s=s===void 0?s:E.toInteger(s),c-=i?i.length:0,t&Py){var d=n,h=i;n=i=void 0}var p=u?void 0:O.getData(e),m=[e,t,r,n,i,d,h,a,o,s];if(p&&tG(m,p),e=m[0],t=m[1],r=m[2],n=m[3],i=m[4],s=m[9]=m[9]===void 0?u?0:e.length:Ey(m[9]-c,0),!s&&t&(qh|Yh)&&(t&=~(qh|Yh)),!t||t==My)var g=pU(e,t,r);else t==qh||t==Yh?g=XU(e,t,s):(t==Xh||t==(My|Xh))&&!i.length?g=KU(e,t,r,n):g=B0.apply(void 0,m);var b=p?Wx:Ux;return qx(b(g,m),e,t)}var aG=8;function ll(e,t,r){t=r?void 0:t;var n=iG(e,aG,void 0,void 0,void 0,void 0,void 0,t);return n.placeholder=ll.placeholder,n}ll.placeholder={};const oG="_alert_box_10ttx_1",sG="_content_10ttx_8",lG="_alert_10ttx_1",Zh={alert_box:oG,content:sG,alert:lG},Zx=({alerts:e=[]})=>O.jsx("div",{className:Zh.alert_box,children:O.jsx("div",{className:Zh.content,children:[...new Set(e)].map((t,r)=>O.jsx("div",{className:Zh.alert,children:t},`alert-${r}`))})}),uG=e=>["column","bar","line","area","polar","pie","funnel","treemap","calendar-heatmap","sunburst","streamgraph","sankey"].includes(e);function qr({highchartsOptionsBuilder:e,getAlerts:t}){return function({chartData:n,dataOptions:i,designOptions:a,onDataPointClick:o,onDataPointContextMenu:s,onDataPointsSelected:u,onBeforeRender:c,onReady:d,size:h}){const{t:p}=O.useTranslation(),m=Ox(),g=N.useMemo(()=>Lx({highchartsOptionsBuilder:e,chartData:n,dataOptions:i,designOptions:a,dataPointsEventHandlers:{onDataPointClick:o,onDataPointContextMenu:s,onDataPointsSelected:u},extraConfig:m,onBeforeRender:c}),[n,i,a,o,s,u,m,c]),b=N.useMemo(()=>g?z(D({},g),{chart:D(D(D({},g.chart),(h==null?void 0:h.width)&&{width:h.width}),(h==null?void 0:h.height)&&{height:h.height})}):null,[g,h]),_=t({chartData:n,dataOptions:i,designOptions:a,extraConfig:m});return b&&O.jsxs("div",{"data-testid":"chart-root",role:"img","aria-label":p("chart.visualization.label"),style:{display:"flex",justifyContent:"center",height:"100%",width:"100%"},children:[!!_.length&&O.jsx(Zx,{alerts:_}),O.jsx(k0,{options:b,onReady:d})]})}}function Yr(e){return!!e.chartData&&!!e.chartType&&uG(e.chartType)}var cG="[object String]";function ed(e){return typeof e=="string"||!V.isArray(e)&&V.isObjectLike(e)&&V.baseGetTag(e)==cG}const lo=e=>{const{chartData:t,designOptions:r}=e,{seriesCapacity:n,categoriesCapacity:i}=r.dataLimits,a=t.xValues.length>i?E.categoriesSliceWarning("x",t.xValues.length,i):null,o=t.series.length>n?E.seriesSliceWarning(t.series.length,n):null;return[a,o].filter(ed)};function uo(e,t,r){return E.cartesianData(e,t,r==null?void 0:r.defaultNumberFormattingEnabled)}const td=Object.freeze({"area/basic":{lineType:"straight",stackType:"classic"},"area/stacked":{lineType:"straight",stackType:"stacked"},"area/stacked100":{lineType:"straight",stackType:"stack100"},"area/spline":{lineType:"smooth",stackType:"classic"},"area/stackedspline":{lineType:"smooth",stackType:"stacked"},"area/stackedspline100":{lineType:"smooth",stackType:"stack100"},"arearange/basic":{lineType:"straight",stackType:"classic"},"arearange/spline":{lineType:"smooth",stackType:"classic"},"bar/classic":{stackType:"classic"},"bar/stacked":{stackType:"stacked"},"bar/stacked100":{stackType:"stack100"},"column/classic":{stackType:"classic"},"column/stackedcolumn":{stackType:"stacked"},"column/stackedcolumn100":{stackType:"stack100"},"line/basic":{lineType:"straight"},"line/spline":{lineType:"smooth"},"line/step":{lineType:"straight"},"pie/classic":{pieType:"classic"},"pie/donut":{pieType:"donut"},"pie/ring":{pieType:"ring"},"polar/column":{polarType:"column"},"polar/area":{polarType:"area"},"polar/line":{polarType:"line"},"indicator/numeric":{indicatorType:"numeric"},"indicator/gauge":{indicatorType:"gauge"},treemap:{},sunburst:{},"boxplot/full":{boxplotType:"full"},"boxplot/hollow":{boxplotType:"hollow"},scattermap:{},"areamap/world":{mapType:"world"},"areamap/usa":{mapType:"usa"}}),Bp=(e,t)=>{var r,n,i,a,o;return e?{enabled:e.enabled,gridLine:e.gridLines,labels:(r=e.labels)==null?void 0:r.enabled,type:e.logarithmic?"logarithmic":"linear",titleEnabled:(n=e.title)==null?void 0:n.enabled,title:((i=e==null?void 0:e.title)==null?void 0:i.text)||null,min:(a=e.min)!=null?a:null,max:(o=e.max)!=null?o:null,tickInterval:e.isIntervalEnabled&&(e!=null&&e.intervalJumps)?e==null?void 0:e.intervalJumps:null}:t},dG=e=>e!=null&&e.enabled?{enabled:!0,scrollerLocation:e==null?void 0:e.scrollerLocation,onScrollerChange:e==null?void 0:e.onScrollerChange}:{enabled:!1},hG=e=>{const t=Bp(e,Kt.yAxis);return t.gridLine=e.templateMainYHasGridLines||!1,t},z0=e=>{let t=1;switch(e.width){case"thin":t=1;break;case"bold":t=3;break;case"thick":t=5;break}return t},Kx="classic",Xr=(e,t)=>{var u,c,d,h;const r=vG(),n=Bp(e.xAxis,Kt.xAxis);let i=null;(c=(u=e==null?void 0:e.xAxis)==null?void 0:u.x2Title)!=null&&c.enabled&&((h=(d=e==null?void 0:e.xAxis)==null?void 0:d.x2Title)!=null&&h.text)&&(i=z(D({},Kt.xAxis),{title:e.xAxis.x2Title.text}));const a=Bp(e.yAxis,Kt.yAxis),o=t&&e.y2Axis?D({type:"linear",enabled:!0,titleEnabled:!0,title:"Y2 Axis title",gridLine:!0,labels:!0,min:null,max:null,tickInterval:null},hG(e.y2Axis)):void 0,s=dG(e.navigator);return z(D(D(z(D(z(D({},Kt),{legend:e.legend,autoZoom:s}),e.seriesLabels&&{seriesLabels:e.seriesLabels}),{xAxis:n,yAxis:a}),o&&{y2Axis:o}),i&&{x2Axis:i}),{dataLimits:r})},rd=e=>({enabled:e.enabled,fill:e.fill==="filled"?"full":"hollow",size:e.size==="small"?"small":"large"}),fG=(e,t,r,n)=>{const i=Xr(e,r),a=mn(e!=null?e:{},E.getDefaultStyleOptions()),o=si(t,n,a);return z(D({},i),{designPerSeries:o,stackType:Kx,totalLabels:e.totalLabels})},pG=(e,t)=>{var n,i,a,o,s,u,c;const r=Xr(t,!1);if(e==="line"){const d=t;d.line&&(r.line={width:(a=(n=d.line)==null?void 0:n.width)!=null?a:z0((i=d.lineWidth)!=null?i:{width:"bold"}),dashStyle:(o=d.line)==null?void 0:o.dashStyle,endCap:(s=d.line)==null?void 0:s.endCap,shadow:(u=d.line)==null?void 0:u.shadow}),r.marker=rd((c=d==null?void 0:d.markers)!=null?c:{enabled:!0,fill:"filled",size:"small"}),d.subtype==="line/step"&&(r.step=d.stepPosition||"left")}return r},mG=(e,t,r)=>{var s,u,c,d,h,p,m;const n=Xr(e,r);n.marker=rd((s=e==null?void 0:e.markers)!=null?s:{enabled:!0,fill:"filled",size:"small"});const i=mn(e!=null?e:{},E.getDefaultStyleOptions()),a=si(t,"line",i),o=z(D({},n),{designPerSeries:a,line:{width:(d=(u=e.line)==null?void 0:u.width)!=null?d:z0((c=e.lineWidth)!=null?c:{width:"bold"}),dashStyle:(h=e.line)==null?void 0:h.dashStyle,endCap:(p=e.line)==null?void 0:p.endCap,shadow:(m=e.line)==null?void 0:m.shadow}});return e.subtype==="line/step"&&(o.step=e.stepPosition||"left"),o},gG=(e,t,r)=>{var n,i,a,o,s,u,c;return z(D({},fG(e,t,r,"area")),{marker:rd((n=e==null?void 0:e.markers)!=null?n:{enabled:!0,fill:"filled",size:"small"}),line:{width:(o=(i=e.line)==null?void 0:i.width)!=null?o:z0((a=e.lineWidth)!=null?a:{width:"thin"}),dashStyle:(s=e.line)==null?void 0:s.dashStyle,endCap:(u=e.line)==null?void 0:u.endCap,shadow:(c=e.line)==null?void 0:c.shadow}})},H0=(e,t)=>{var i;const r={seriesCapacity:t==="categorical"?ec:t==="pie"?_N:y0,categoriesCapacity:t==="scatter"?wN:ec},n=(i=e==null?void 0:e.dataLimits)!=null?i:{};return"categoriesCapacity"in n&&(n==null?void 0:n.categoriesCapacity)!==void 0&&(r.categoriesCapacity=n==null?void 0:n.categoriesCapacity),(n==null?void 0:n.seriesCapacity)!==void 0&&(r.seriesCapacity=n==null?void 0:n.seriesCapacity),r};function vG(){return{seriesCapacity:y0,categoriesCapacity:ec}}const fa={enabled:!0,showCategory:!0,showValue:!0,percentageLabels:{enabled:!0,showDecimals:!1}},yG="classic",bG=e=>{var d,h,p,m,g,b,_,w,C,S,T,M,P,R,k,I;const{legend:t,labels:r,subtype:n,seriesLabels:i}=e;let a=fa;(i||r)&&(a=z(D({},i),{enabled:(h=(d=i==null?void 0:i.enabled)!=null?d:r==null?void 0:r.enabled)!=null?h:fa.enabled,showCategory:(m=(p=i==null?void 0:i.showCategory)!=null?p:r==null?void 0:r.categories)!=null?m:fa.showCategory,showValue:(b=(g=i==null?void 0:i.showValue)!=null?g:r==null?void 0:r.value)!=null?b:fa.showValue,percentageLabels:z(D({},i==null?void 0:i.percentageLabels),{enabled:(T=(S=(w=(_=i==null?void 0:i.percentageLabels)==null?void 0:_.enabled)!=null?w:r==null?void 0:r.percent)!=null?S:(C=fa.percentageLabels)==null?void 0:C.enabled)!=null?T:!1,showDecimals:(I=(k=(P=(M=i==null?void 0:i.percentageLabels)==null?void 0:M.showDecimals)!=null?P:r==null?void 0:r.decimals)!=null?k:(R=fa.percentageLabels)==null?void 0:R.showDecimals)!=null?I:!1})}));const o=n?td[n]:void 0,s=(o==null?void 0:o.pieType)||yG,u=e!=null&&e.convolution?e.convolution:{enabled:!1},c=H0(e,"pie");return z(D({},Kt),{seriesLabels:a,pieType:s,convolution:u,legend:t,dataLimits:c})},_G=e=>{var u,c,d,h,p,m,g,b,_,w;const{funnelType:t=E.DefaultFunnelType,funnelSize:r=E.DefaultFunnelSize,funnelDirection:n=E.DefaultFunnelDirection,legend:i,labels:a,seriesLabels:o}=e,s=H0(e,"categorical");return z(D({},Kt),{funnelSize:r,funnelType:t,funnelDirection:n,legend:i,dataLimits:s,seriesLabels:z(D({},o!=null?o:{}),{enabled:(c=(u=o==null?void 0:o.enabled)!=null?u:a==null?void 0:a.enabled)!=null?c:E.DefaultFunnelSeriesLabels.enabled,showCategory:(h=(d=o==null?void 0:o.showCategory)!=null?d:a==null?void 0:a.categories)!=null?h:E.DefaultFunnelSeriesLabels.showCategory,showValue:(m=(p=o==null?void 0:o.showValue)!=null?p:a==null?void 0:a.value)!=null?m:E.DefaultFunnelSeriesLabels.showValue,showPercentage:(b=(g=o==null?void 0:o.showPercentage)!=null?g:a==null?void 0:a.percent)!=null?b:E.DefaultFunnelSeriesLabels.showPercentage,showPercentDecimals:(w=(_=o==null?void 0:o.showPercentDecimals)!=null?_:a==null?void 0:a.decimals)!=null?w:E.DefaultFunnelSeriesLabels.showPercentDecimals})})},Qx=e=>e,Jx=e=>e,wG="column",CG=(e,t)=>{const r=Xr(e,!1),n=mn(e!=null?e:{},E.getDefaultStyleOptions()),i=si(t,"polar",n),a=z(D({},r),{polarType:wG,designPerSeries:i});return E.withYAxisNormalizationForPolar(a)},xG=e=>D(D({},E.defaultScatterMarkerSize),e),TG=e=>{var t;return z(D({},Xr(e,!1)),{lineWidth:0,marker:rd((t=e==null?void 0:e.markers)!=null?t:{enabled:!0,fill:"filled",size:"small"}),dataLimits:H0(e,"scatter"),markerSize:xG(e.markerSize),legend:e.legend})},SG=e=>z(D({},Xr(e,!1)),{boxplotType:e.subtype==="boxplot/hollow"?"hollow":"full"}),MG={fill:"filled",size:{defaultSize:4,minSize:4,maxSize:24}},PG=e=>z(D({},Kt),{markers:E.merge(MG,e.markers||{})}),EG={"line/basic":"straight","line/spline":"smooth","line/step":"straight"},AG=e=>({thin:1,bold:3,thick:5})[e.width],RG=e=>({enabled:e.enabled,fill:e.fill==="filled"?"full":"hollow",size:e.size==="small"?"small":"large"}),DG=(e,t)=>Xr(e,Qc(t)),NG=e=>t=>{var r,n,i,a,o,s;return z(D({},t),{line:{width:(n=(r=e.line)==null?void 0:r.width)!=null?n:AG(e.lineWidth||{width:"bold"}),dashStyle:(i=e.line)==null?void 0:i.dashStyle,endCap:(a=e.line)==null?void 0:a.endCap,shadow:(o=e.line)==null?void 0:o.shadow},marker:RG((s=e==null?void 0:e.markers)!=null?s:{enabled:!0,fill:"filled",size:"small"})})},kG=(e,t)=>r=>{const n=mn(e!=null?e:{},E.getDefaultStyleOptions()),i=si(t,"line",n);return z(D({},r),{designPerSeries:i})},LG=e=>t=>{const r=e.subtype||"line/basic",n=EG[r];return n?z(D({},t),{lineType:n}):t},OG=e=>t=>{const r=e.subtype==="line/step"?{step:e.stepPosition||"left"}:{};return D(D({},t),r)};function IG(e,t){const r=DG(e,t);return O.flow(NG(e),kG(e,t),LG(e),OG(e))(r)}const FG=["line/basic","line/spline","line/step"];function $G(e){return"subtype"in e&&e.subtype?FG.includes(e.subtype):!0}const st=(e,t)=>E.getCartesianChartOptions(e.chartData,t,e.designOptions,e.dataOptions,e.extraConfig.translate,e.extraConfig.themeSettings,e.extraConfig.dateFormatter).options,BG={fontSize:"13px",fontWeight:"normal",textOutline:"none",pointerEvents:"auto"},zG=e=>{switch(e){case"bottom":return{enabled:!0,align:"center",verticalAlign:"bottom",layout:"horizontal"};case"left":return{enabled:!0,align:"left",verticalAlign:"middle",layout:"vertical"};case"right":return{enabled:!0,align:"right",verticalAlign:"middle",layout:"vertical"};case"top":return{enabled:!0,align:"center",verticalAlign:"top",layout:"horizontal"};default:return{enabled:!0,align:"center",verticalAlign:"bottom",layout:"horizontal"}}},HG=e=>{if((e==null?void 0:e.enabled)===!1||!e)return;const{text:t,textStyle:r}=e;return{title:{text:t,style:r}}},WG=e=>{if(!e)return;const{layout:t,textStyle:r,marginBottom:n,marginTop:i,distance:a,width:o,hoverTextStyle:s,hiddenTextStyle:u}=e||{};return{layout:t,itemStyle:r,itemMarginBottom:n,itemMarginTop:i,itemDistance:a,itemWidth:o,itemHoverStyle:s,itemHiddenStyle:u}},jG=e=>{if(!e)return;const{radius:t,height:r,width:n,padding:i,squared:a}=e;return{symbolRadius:t,symbolHeight:r,symbolWidth:n,symbolPadding:i,squareSymbol:a}},VG=e=>{const c=e,{title:t,items:r,symbols:n,xOffset:i,yOffset:a,backgroundColor:o,borderColor:s}=c,u=Ye(c,["title","items","symbols","xOffset","yOffset","backgroundColor","borderColor"]);return E.omitUndefinedAndEmpty(z(D(D(D(D({},u),HG(t)),WG(r)),jG(n)),{x:i,y:a,backgroundColor:E.withGradientConversion(o),borderColor:E.withGradientConversion(s)}))},co=e=>{const t={enabled:!1,symbolRadius:0,backgroundColor:"transparent",borderColor:"transparent",borderWidth:0,align:"center",verticalAlign:"bottom",layout:"horizontal"};if(!e)return t;const o=e,{position:r}=o,n=Ye(o,["position"]),i=zG(r||null),a=VG(n);return E.omitUndefinedAndEmpty(z(D(D(D({},t),i),a),{itemStyle:D(D({},BG),a.itemStyle)}))},ho=e=>E.getCartesianTooltipSettings(e.dataOptions,e.extraConfig.translate),fo=(e,t)=>{var i;const r=E.buildCategoriesMeta(e.chartData,e.dataOptions,e.designOptions,E.isContinuousDatetimeXAxis(e.dataOptions.x),e.extraConfig.dateFormatter),n=E.buildXAxisSettings({designOptions:e.designOptions,dataOptions:e.dataOptions,chartData:e.chartData,categoriesMeta:r,orientation:t,isContinuous:E.isContinuousDatetimeXAxis(e.dataOptions.x),dateFormatter:e.extraConfig.dateFormatter});return E.withScrollerEvent((i=e.designOptions.autoZoom)==null?void 0:i.onScrollerChange)(n)},po=(e,t)=>{const r=E.buildYAxisMeta(e.chartData,e.dataOptions),n=E.buildYAxisMinMax(0,t,e.chartData,e.designOptions,r.side,r.treatNullAsZero),i=E.hasSecondaryYAxis(r.side)?E.buildYAxisMinMax(1,t,e.chartData,e.designOptions,r.side,r.treatNullAsZero):void 0;return E.getYAxisSettings(e.designOptions.yAxis,e.designOptions.y2Axis,n,i,e.dataOptions,e.extraConfig.themeSettings)},UG=e=>{const t=fo(e,"horizontal"),r=po(e,"line");return{xAxis:t,yAxis:r}},GG={getChart:function(e){return st(e,"line").chart},getSeries:function(e){return st(e,"line").series},getAxes:UG,getLegend:function(e){return co(e.designOptions.legend)},getPlotOptions:function(e){return st(e,"line").plotOptions},getTooltip:ho,getExtras:function(e){const t=st(e,"line");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},qG={dataOptions:{translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},data:{loadData:ur,getChartData:uo},designOptions:{translateStyleOptionsToDesignOptions:ll(IG),isCorrectStyleOptions:$G},renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:GG,getAlerts:lo}),isCorrectRendererProps:Yr}},YG={translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},XG={loadData:ur,getChartData:uo};function ZG(e,t){const r=Xr(e,!1),n=mn(e,E.getDefaultStyleOptions()),i=si(t,"polar",n),a=e.subtype||"polar/column",o=td[a],s=(o==null?void 0:o.polarType)||"column",u=z(D({},r),{polarType:s,designPerSeries:i});return E.withYAxisNormalizationForPolar(u)}function KG(e){return typeof e=="object"&&e!==null&&(!("subtype"in e)||!e.subtype||e.subtype.startsWith("polar/"))}const QG={translateStyleOptionsToDesignOptions:ZG,isCorrectStyleOptions:KG};function JG(e){const t=fo(e,"horizontal"),r=po(e,"polar");return{xAxis:E.withPolarSpecificAxisSettings(t),yAxis:r}}const eq={getChart:function(e){const t=st(e,"polar");return z(D({},t.chart),{polar:!0})},getSeries:function(e){return st(e,"polar").series},getAxes:JG,getLegend:function(e){return co(e.designOptions.legend)},getPlotOptions:function(e){return st(e,"polar").plotOptions},getTooltip:ho,getExtras:function(e){const t=st(e,"polar");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},tq={dataOptions:YG,data:XG,designOptions:QG,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:eq,getAlerts:lo}),isCorrectRendererProps:Yr}},rq={"area/basic":{lineType:"straight",stackType:"classic"},"area/stacked":{lineType:"straight",stackType:"stacked"},"area/stacked100":{lineType:"straight",stackType:"stack100"},"area/spline":{lineType:"smooth",stackType:"classic"},"area/stackedspline":{lineType:"smooth",stackType:"stacked"},"area/stackedspline100":{lineType:"smooth",stackType:"stack100"}},nq=e=>({thin:1,bold:3,thick:5})[e.width],iq=e=>({enabled:e.enabled,fill:e.fill==="filled"?"full":"hollow",size:e.size==="small"?"small":"large"}),aq=(e,t)=>Xr(e,Qc(t)),oq=e=>t=>{var r,n,i,a,o,s;return z(D({},t),{line:{width:(n=(r=e.line)==null?void 0:r.width)!=null?n:nq(e.lineWidth||{width:"thin"}),dashStyle:(i=e.line)==null?void 0:i.dashStyle,endCap:(a=e.line)==null?void 0:a.endCap,shadow:(o=e.line)==null?void 0:o.shadow},marker:iq((s=e==null?void 0:e.markers)!=null?s:{enabled:!0,fill:"filled",size:"small"})})},sq=(e,t)=>r=>{const n=mn(e!=null?e:{},E.getDefaultStyleOptions()),i=si(t,"area",n);return z(D({},r),{designPerSeries:i})},lq=e=>t=>{const r=e.subtype||"area/basic",n=rq[r];return n?z(D({},t),{lineType:n.lineType,stackType:n.stackType}):t},uq=e=>t=>{var r;return z(D({},t),{totalLabels:(r=e.totalLabels)!=null?r:{enabled:!1,rotation:0}})};function cq(e,t){const r=aq(e,t);return O.flow(oq(e),sq(e,t),lq(e),uq(e))(r)}const dq=["area/basic","area/stacked","area/stacked100","area/spline","area/stackedspline","area/stackedspline100"];function hq(e){return"subtype"in e&&e.subtype?dq.includes(e.subtype):!0}const fq=e=>{var r,n;const t={enabled:!1};switch(e.stackType){case"stacked":return{stacking:"normal",totalLabels:(r=e.totalLabels)!=null?r:t};case"stack100":return{stacking:"percent",totalLabels:(n=e.totalLabels)!=null?n:t};default:return{totalLabels:t}}},W0=e=>t=>{const r=e.designOptions,n=fq(r),{stacking:i,totalLabels:a}=n;if(!(a!=null&&a.enabled)&&!i)return t;const{defaultNumberFormattingEnabled:o}=e.extraConfig,s=e.dataOptions,u=s.y.find(({showOnRightAxis:h})=>!h),c=s.y.find(({showOnRightAxis:h})=>!!h);function d(h,p,m=!1){return function(){var C,S;const g=typeof this.value=="number"?this.value:parseFloat(this.value),b=m&&this.total||g,_=E.formatNumberWithFallback(b,h,o,E.applyFormatPlainText),w=p==="percent"?`${_}%`:_;return m?`${(C=a==null?void 0:a.prefix)!=null?C:""}${w}${(S=a==null?void 0:a.suffix)!=null?S:""}`:w}}return t.map((h,p)=>{var b;const g=(b=p===1?c:u)==null?void 0:b.numberFormatConfig;return z(D({},h),{labels:i?z(D({},h.labels),{formatter:d(g,i)}):h.labels,stackLabels:a!=null&&a.enabled?z(D(D({},h.stackLabels),E.prepareStackLabels(a)),{formatter:d(g,"normal",!0),style:D(D(D({},E.stackTotalFontStyleDefault),e.extraConfig.themeSettings?{color:e.extraConfig.themeSettings.typography.primaryTextColor}:null),E.prepareStackLabels(a).style),crop:!0,allowOverlap:!1,labelrank:99999}):h.stackLabels})})},au={HORIZONTAL:20,DIAGONAL:70,VERTICAL:110,INVERTED_DIAGONAL:160},pq={FULL_ROTATION:180};function e3(e){var n;let r=0;if((n=e.totalLabels)!=null&&n.enabled&&e.stackType==="stack100"){const i=Math.abs(e.totalLabels.rotation||0)%pq.FULL_ROTATION;i<au.HORIZONTAL?r=10:i<au.DIAGONAL?r=30:i<au.VERTICAL?r=40:i<au.INVERTED_DIAGONAL?r=30:r=10}return{rightSpacing:0,topSpacing:r}}const mq=e=>{const t=fo(e,"horizontal"),r=po(e,"area");return{xAxis:gq(e)(t),yAxis:O.flow(W0(e),vq(e))(r)}};function gq(e){const{rightSpacing:t,topSpacing:r}=e3(e.designOptions);return E.withXAxisLabelPositioning({totalLabelRightSpacing:t,totalLabelTopSpacing:r})}function vq(e){const t=yq(e);return E.withYAxisLabelPositioning({rightShift:0,topShift:t})}function yq(e){var i;const t=e.designOptions;if(!(((i=t.totalLabels)==null?void 0:i.enabled)&&t.stackType==="stack100"))return 0;const{topSpacing:n}=e3(e.designOptions);return-1*(n/2)}const bq={getChart:function(e){return st(e,"area").chart},getSeries:function(e){return st(e,"area").series},getAxes:mq,getLegend:function(e){return co(e.designOptions.legend)},getPlotOptions:function(e){return st(e,"area").plotOptions},getTooltip:ho,getExtras:function(e){const t=st(e,"area");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},_q={dataOptions:{translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},data:{loadData:ur,getChartData:uo},designOptions:{translateStyleOptionsToDesignOptions:cq,isCorrectStyleOptions:hq},renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:bq,getAlerts:lo}),isCorrectRendererProps:Yr}};function t3(e,t,r){var o,s,u,c,d,h;const n=Xr(t,Qc(r)),i=mn(t!=null?t:{},E.getDefaultStyleOptions()),a=si(r,e,i);return z(D({},n),{designPerSeries:a,stackType:t.subtype?r3[t.subtype]:Kx,totalLabels:t.totalLabels,itemPadding:(s=(o=t.series)==null?void 0:o.padding)!=null?s:.01,groupPadding:(c=(u=t.series)==null?void 0:u.groupPadding)!=null?c:.1,borderRadius:(h=(d=t.series)==null?void 0:d.borderRadius)!=null?h:0})}const r3={"bar/classic":"classic","bar/stacked":"stacked","bar/stacked100":"stack100","column/classic":"classic","column/stackedcolumn":"stacked","column/stackedcolumn100":"stack100"};function n3(e){return"subtype"in e&&e.subtype?Object.keys(r3).includes(e.subtype):!0}const ou={HORIZONTAL:20,DIAGONAL:70,VERTICAL:110,INVERTED_DIAGONAL:160},wq={FULL_ROTATION:180};function Cq(e){var n;let t=0;const r=0;if((n=e.totalLabels)!=null&&n.enabled&&e.stackType==="stack100"){const i=Math.abs(e.totalLabels.rotation||0)%wq.FULL_ROTATION;i<ou.HORIZONTAL?t=40:i<ou.DIAGONAL?t=25:i<ou.VERTICAL?t=15:i<ou.INVERTED_DIAGONAL?t=25:t=40}return{rightSpacing:t,topSpacing:r}}const xq=e=>{const t=fo(e,"vertical"),r=po(e,"bar");return{xAxis:Tq(e)(t),yAxis:O.flow(W0(e),Sq(e))(r)}};function Tq(e){const{rightSpacing:t,topSpacing:r}=Cq(e.designOptions);return E.withXAxisLabelPositioning({totalLabelRightSpacing:t,totalLabelTopSpacing:r})}function Sq(e){var a;const t=e.designOptions,n=((a=t.totalLabels)==null?void 0:a.enabled)&&t.stackType==="stack100"?.1:0;return E.withYAxisLabelPositioning({rightShift:n,topShift:0})}const Mq=e=>Pq(e)(co(e.designOptions.legend));function Pq(e){return r=>{var n,i;return e.dataOptions.x.length>1&&E.isLegendOnRight(e.designOptions.legend)?z(D({},r),{margin:(i=(n=e.designOptions.legend)==null?void 0:n.margin)!=null?i:80}):r}}const Eq={getChart:function(e){return st(e,"bar").chart},getSeries:function(e){return st(e,"bar").series},getAxes:xq,getLegend:Mq,getPlotOptions:function(e){return st(e,"bar").plotOptions},getTooltip:ho,getExtras:function(e){const t=st(e,"bar");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},Aq={dataOptions:{translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},data:{loadData:ur,getChartData:uo},designOptions:{translateStyleOptionsToDesignOptions:ll(t3)("bar"),isCorrectStyleOptions:n3},renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:Eq,getAlerts:lo}),isCorrectRendererProps:Yr}},su={HORIZONTAL:20,DIAGONAL:70,VERTICAL:110,INVERTED_DIAGONAL:160},Rq={FULL_ROTATION:180};function i3(e){var n;let r=0;if((n=e.totalLabels)!=null&&n.enabled&&e.stackType==="stack100"){const i=Math.abs(e.totalLabels.rotation||0)%Rq.FULL_ROTATION;i<su.HORIZONTAL?r=10:i<su.DIAGONAL?r=30:i<su.VERTICAL?r=40:i<su.INVERTED_DIAGONAL?r=30:r=10}return{rightSpacing:0,topSpacing:r}}const Dq=e=>{const t=fo(e,"horizontal"),r=po(e,"column");return{xAxis:Nq(e)(t),yAxis:O.flow(W0(e),kq(e))(r)}};function Nq(e){const{rightSpacing:t,topSpacing:r}=i3(e.designOptions);return E.withXAxisLabelPositioning({totalLabelRightSpacing:t,totalLabelTopSpacing:r})}function kq(e){var a;const t=e.designOptions,r=((a=t.totalLabels)==null?void 0:a.enabled)&&t.stackType==="stack100";let n=0;if(r){const{topSpacing:o}=i3(e.designOptions);n=-1*(o/2)}return E.withYAxisLabelPositioning({rightShift:0,topShift:n})}const Lq={getChart:function(e){return st(e,"column").chart},getSeries:function(e){return st(e,"column").series},getAxes:Dq,getLegend:function(e){return co(e.designOptions.legend)},getPlotOptions:function(e){return st(e,"column").plotOptions},getTooltip:ho,getExtras:function(e){const t=st(e,"column");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},Oq={dataOptions:{translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},data:{loadData:ur,getChartData:uo},designOptions:{translateStyleOptionsToDesignOptions:ll(t3)("column"),isCorrectStyleOptions:n3},renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:Lq,getAlerts:lo}),isCorrectRendererProps:Yr}},Iq=e=>{const t=n=>typeof n=="number"&&Number.isNaN(n)||n==null?0:n,r=n=>{const i=t(n.value);return z(D({},n),{value:i})};return z(D({},e),{series:e.series.map(n=>z(D({},n),{data:n.data.map(r)}))})},Fq=O.flow(uo,Iq),$q=e=>({thin:1,bold:3,thick:5})[e.width],Bq=e=>({enabled:e.enabled,fill:e.fill==="filled"?"full":"hollow",size:e.size==="small"?"small":"large"}),zq=(e,t)=>Xr(e,Qc(t)),Hq=e=>t=>{var r,n,i,a,o,s,u,c,d;return z(D({},t),{seriesTitles:{enabled:(n=(r=e.seriesTitles)==null?void 0:r.enabled)!=null?n:!0,textStyle:(i=e.seriesTitles)==null?void 0:i.textStyle},line:{width:(o=(a=e.line)==null?void 0:a.width)!=null?o:$q(e.lineWidth||{width:"thin"}),dashStyle:(s=e.line)==null?void 0:s.dashStyle,endCap:(u=e.line)==null?void 0:u.endCap,shadow:(c=e.line)==null?void 0:c.shadow},marker:Bq((d=e==null?void 0:e.markers)!=null?d:{enabled:!1,fill:"filled",size:"small"})})},Wq=(e,t)=>r=>{const n=si(t,"area",e);return z(D({},r),{designPerSeries:n})},jq=e=>t=>{var r,n,i,a,o,s,u,c,d,h,p,m;return z(D({},t),{seriesLabels:z(D({},e.seriesLabels),{enabled:(n=(r=e.seriesLabels)==null?void 0:r.enabled)!=null?n:!1,rotation:(a=(i=e.seriesLabels)==null?void 0:i.rotation)!=null?a:0,showValue:(c=(u=(o=e.seriesLabels)==null?void 0:o.showValue)!=null?u:(s=e.seriesLabels)==null?void 0:s.enabled)!=null?c:!1,textStyle:z(D({},(d=e.seriesLabels)==null?void 0:d.textStyle),{color:(m=(p=(h=e.seriesLabels)==null?void 0:h.textStyle)==null?void 0:p.color)!=null?m:"#000000"})})})};function Vq(e,t){const r=zq(e,t);return O.flow(Hq(e),Wq(e,t),jq(e))(r)}function Uq(e){return!0}function Gq(){const e=E.getDefaultStyleOptions();return E.merge(e,{yAxis:{enabled:!0,gridLines:!0,labels:{enabled:!1},title:{enabled:!1,text:""}},xAxis:{gridLines:!1},legend:{enabled:!1}})}const qq=e=>{const t=fo(e,"horizontal"),r=po(e,"area"),n=t.map(a=>{var o;return z(D({},a),{gridLineWidth:e.designOptions.xAxis.gridLine?1:0,labels:z(D({},a.labels),{enabled:(o=e.designOptions.xAxis.labels)!=null?o:!0})})}),i=r.map(a=>z(D({},a),{visible:e.designOptions.yAxis.enabled,gridLineWidth:e.designOptions.yAxis.gridLine?1:0,labels:z(D({},a.labels),{enabled:e.designOptions.yAxis.labels}),startOnTick:!1,endOnTick:!1,minPadding:.1,maxPadding:.15,min:void 0,max:void 0}));return{xAxis:n,yAxis:i}},Yq=e=>{var n,i,a,o,s;const t=st(e,"area").plotOptions,r=(i=(n=e.designOptions.line)==null?void 0:n.width)!=null?i:1;return z(D({},t),{series:z(D({},t.series),{stacking:"stream",lineWidth:r,fillOpacity:1,label:{enabled:(o=(a=e.designOptions.seriesTitles)==null?void 0:a.enabled)!=null?o:!0,minFontSize:5,maxFontSize:15,style:(s=e.designOptions.seriesTitles)==null?void 0:s.textStyle}})})},Xq={getChart:function(e){const t=st(e,"area");return z(D({},t.chart),{type:"streamgraph"})},getSeries:function(e){return st(e,"area").series},getAxes:qq,getLegend:function(e){return co(e.designOptions.legend)},getPlotOptions:Yq,getTooltip:ho,getExtras:function(e){const t=st(e,"area");return V.omit(t,["chart","series","xAxis","yAxis","legend","plotOptions","tooltip"])}},Zq={dataOptions:{translateDataOptionsToInternal:Ui,getAttributes:io,getMeasures:ao,isCorrectDataOptions:oo,isCorrectDataOptionsInternal:so},data:{loadData:ur,getChartData:Fq},designOptions:{translateStyleOptionsToDesignOptions:Vq,isCorrectStyleOptions:Uq,getDefaultStyleOptions:Gq},renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:Xq,getAlerts:lo}),isCorrectRendererProps:Yr}},Kq=e=>E.getAlerts(e.chartData,e.designOptions);function Qq(e,t){const r=Jq[e],n=e!=="pie"||t.category.length>0,i=[a3(r.category),n?o3(r.value):a=>a];return O.flow(...i)(t)}const Jq={pie:{category:3,value:1},funnel:{category:1,value:1},treemap:{category:3,value:1},sunburst:{category:6,value:1}};function a3(e){return t=>(t.category.length>e&&console.warn(`Maximum 'category' length is limited to ${e}. Taken first ${e} categories`),z(D({},t),{category:t.category.slice(0,e)}))}function o3(e){return t=>(t.value.length>e&&console.warn(`Maximum 'value' length is limited to ${e}. Taken first ${e} values`),z(D({},t),{value:t.value.slice(0,e)}))}function s3(e){return{y:e.value.map(t=>E.normalizeMeasureColumn(t)),breakBy:e.category.map(t=>E.normalizeColumn(t)),seriesToColorMap:e.seriesToColorMap}}function nd(e){return[...e.breakBy.map(l3)].filter(eY)}function id(e){return e.y.map(l3).filter(E.isMeasureColumn)}function ad(e){return"category"in e&&"value"in e&&Array.isArray(e.category)&&Array.isArray(e.value)}function od(e){return e&&"y"in e&&Array.isArray(e.y)&&e.y.every(E.isMeasureColumn)&&"breakBy"in e&&Array.isArray(e.breakBy)&&e.breakBy.every(E.isStyledColumn)}function l3(e){return e.column}function eY(e){return!E.isMeasureColumn(e)}function sd({maxCategories:e,maxValues:t}){return O.flow(a3(e),o3(t))}const tY={translateDataOptionsToInternal:e=>{const t=e.category.length>0?sd({maxCategories:1,maxValues:1})(e):e;return s3(t)},getAttributes:e=>nd(e),getMeasures:e=>id(e),isCorrectDataOptions:e=>ad(e),isCorrectDataOptionsInternal:e=>od(e)},ld=(e,t,r=!0)=>{const n=z(D({},e),{x:e.breakBy,breakBy:[]});let i=E.cartesianData(n,t,r);if(e.breakBy.some(({column:{type:o},numberFormatConfig:s})=>V.isNumber(o)&&(r||s))){const o=i.xValues.map(s=>{const u=[];return e.breakBy.forEach(({column:{type:c},numberFormatConfig:d},h)=>{const p=d!==void 0,m=s.xValues[h];if(V.isNumber(c)&&(r||p)){const g=E.getCompleteNumberFormatConfig(d);u.push(E.applyFormatPlainText(g,parseFloat(m)))}else u.push(m)}),z(D({},s),{xValues:u})});i=z(D({},i),{xValues:o})}return z(D({},i),{type:"categorical"})},u3=ur;function c3(e,t,r){return ld(e,t,r==null?void 0:r.defaultNumberFormattingEnabled)}const Ay=50,rY=e=>(...t)=>{var s;const[r,...n]=t,i=(s=r.queryDescription)==null?void 0:s.count,a=Math.min(i!=null?i:Ay,Ay),o=z(D({},r),{queryDescription:z(D({},r.queryDescription),{count:a})});return e(o,...n)},nY={loadData:rY(u3),getChartData:(e,t)=>c3(e,t)},iY=e=>{var r,n;const{dataLimits:t}=e;return{categoriesCapacity:(r=t==null?void 0:t.categoriesCapacity)!=null?r:5e4,seriesCapacity:(n=t==null?void 0:t.seriesCapacity)!=null?n:5e4}};function aY(e){var s,u,c,d,h;const{funnelType:t=E.DefaultFunnelType,funnelSize:r=E.DefaultFunnelSize,funnelDirection:n=E.DefaultFunnelDirection,legend:i,seriesLabels:a}=e,o=iY(e);return z(D({},Kt),{funnelSize:r,funnelType:t,funnelDirection:n,legend:i,dataLimits:o,seriesLabels:z(D({},a!=null?a:{}),{enabled:(s=a==null?void 0:a.enabled)!=null?s:E.DefaultFunnelSeriesLabels.enabled,showCategory:(u=a==null?void 0:a.showCategory)!=null?u:E.DefaultFunnelSeriesLabels.showCategory,showValue:(c=a==null?void 0:a.showValue)!=null?c:E.DefaultFunnelSeriesLabels.showValue,showPercentage:(d=a==null?void 0:a.showPercentage)!=null?d:E.DefaultFunnelSeriesLabels.showPercentage,showPercentDecimals:(h=a==null?void 0:a.showPercentDecimals)!=null?h:E.DefaultFunnelSeriesLabels.showPercentDecimals})})}function oY(e){return!e||typeof e=="object"}function sY(){return{legend:{enabled:!0,position:"bottom"},funnelType:E.DefaultFunnelType,funnelSize:E.DefaultFunnelSize,funnelDirection:E.DefaultFunnelDirection,seriesLabels:E.DefaultFunnelSeriesLabels}}function lY(e={}){var a,o,s,u,c;const i=e,{labels:t,seriesLabels:r}=i,n=Ye(i,["labels","seriesLabels"]);return E.omitUndefinedAndEmpty(z(D({},n),{seriesLabels:z(D({},r!=null?r:{}),{enabled:(a=r==null?void 0:r.enabled)!=null?a:t==null?void 0:t.enabled,showCategory:(o=r==null?void 0:r.showCategory)!=null?o:t==null?void 0:t.categories,showValue:(s=r==null?void 0:r.showValue)!=null?s:t==null?void 0:t.value,showPercentage:(u=r==null?void 0:r.showPercentage)!=null?u:t==null?void 0:t.percent,showPercentDecimals:(c=r==null?void 0:r.showPercentDecimals)!=null?c:t==null?void 0:t.decimals})}))}const uY={translateStyleOptionsToDesignOptions:aY,isCorrectStyleOptions:oY,getDefaultStyleOptions:sY,translateLegacyStyleOptionsToModern:lY},cY={getChart:function(e){return{type:E.determineHighchartsChartType("funnel",e.designOptions),spacing:[30,30,30,30],alignTicks:!1,polar:!1}},getSeries:function(e){const{series:t}=E.formatFunnelChartData(e.chartData,e.dataOptions,e.designOptions,e.extraConfig.themeSettings);return t},getAxes:function(){return{xAxis:[],yAxis:[]}},getLegend:function(e){return E.getLegendSettings(e.designOptions.legend)},getPlotOptions:function(e){return E.getFunnelPlotOptions(e.designOptions,e.dataOptions,e.extraConfig.defaultNumberFormattingEnabled)},getTooltip:function(e){var t;return E.getCategoryTooltipSettings((t=e.designOptions.seriesLabels)==null?void 0:t.showPercentDecimals,e.dataOptions,e.extraConfig.defaultNumberFormattingEnabled)},getExtras:function(){return{title:{text:null}}}},dY={dataOptions:tY,data:nY,designOptions:uY,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:cY,getAlerts:Kq}),isCorrectRendererProps:Yr}},hY=e=>{const{seriesCapacity:t}=e.designOptions.dataLimits;return E.getPieAlerts(e.chartData,t)},fY={translateDataOptionsToInternal:e=>{const t=e.category.length>0?sd({maxCategories:1,maxValues:1})(e):e;return s3(t)},getAttributes:e=>nd(e),getMeasures:e=>id(e),isCorrectDataOptions:e=>ad(e),isCorrectDataOptionsInternal:e=>od(e)},pY={loadData:u3,getChartData:(e,t)=>c3(e,t)},mY="classic",Vo={enabled:!0,showCategory:!0,showValue:!1,percentageLabels:{enabled:!0,showDecimals:!1}},gY=e=>{var r,n;const{dataLimits:t}=e;return{categoriesCapacity:(r=t==null?void 0:t.categoriesCapacity)!=null?r:5e4,seriesCapacity:(n=t==null?void 0:t.seriesCapacity)!=null?n:5e4}};function vY(e){var d,h,p,m,g,b,_,w,C,S,T,M;const{legend:t,labels:r,subtype:n,seriesLabels:i,semiCircle:a}=e,o=n?td[n]:void 0,s=(o==null?void 0:o.pieType)||mY,u=e!=null&&e.convolution?e.convolution:{enabled:!1},c=gY(e);return z(D({},Kt),{seriesLabels:z(D({},i),{enabled:(h=(d=i==null?void 0:i.enabled)!=null?d:r==null?void 0:r.enabled)!=null?h:Vo.enabled,showCategory:(m=(p=i==null?void 0:i.showCategory)!=null?p:r==null?void 0:r.categories)!=null?m:Vo.showCategory,showValue:(b=(g=i==null?void 0:i.showValue)!=null?g:r==null?void 0:r.value)!=null?b:Vo.showValue,percentageLabels:z(D({},i==null?void 0:i.percentageLabels),{enabled:(C=(w=(_=i==null?void 0:i.percentageLabels)==null?void 0:_.enabled)!=null?w:r==null?void 0:r.percent)!=null?C:Vo.percentageLabels.enabled,showDecimals:(M=(T=(S=i==null?void 0:i.percentageLabels)==null?void 0:S.showDecimals)!=null?T:r==null?void 0:r.decimals)!=null?M:Vo.percentageLabels.showDecimals})}),pieType:s,convolution:u,legend:t,dataLimits:c,semiCircle:a})}function yY(e){return!e||typeof e=="object"}function bY(){return{legend:{enabled:!0,position:"bottom"},labels:{enabled:!0,categories:!0,percent:!0,decimals:!1,value:!1}}}const _Y={translateStyleOptionsToDesignOptions:vY,isCorrectStyleOptions:yY,getDefaultStyleOptions:bY},wY={getChart:function(e){return{type:E.determineHighchartsChartType("pie",e.designOptions),spacing:[20,20,20,20],alignTicks:!1,polar:!1}},getSeries:function(e){return E.getPieSeries({chartData:e.chartData,dataOptions:e.dataOptions,seriesCapacity:e.designOptions.dataLimits.seriesCapacity,convolution:e.designOptions.convolution,themeSettings:e.extraConfig.themeSettings})},getAxes:function(){return{xAxis:[],yAxis:[]}},getLegend:function(e){return E.getLegendSettings(e.designOptions.legend)},getPlotOptions:function(e){return E.getPiePlotOptions({pieType:e.designOptions.pieType,seriesLabels:e.designOptions.seriesLabels,chartDataOptions:e.dataOptions,themeSettings:e.extraConfig.themeSettings,semiCircle:e.designOptions.semiCircle,defaultNumberFormattingEnabled:e.extraConfig.defaultNumberFormattingEnabled})},getTooltip:function(e){var t,r;return E.getCategoryTooltipSettings((r=(t=e.designOptions.seriesLabels)==null?void 0:t.percentageLabels)==null?void 0:r.showDecimals,e.dataOptions,e.extraConfig.defaultNumberFormattingEnabled)},getExtras:function(e){const t=E.getPieConvolutionSeries({chartData:e.chartData,dataOptions:e.dataOptions,seriesCapacity:e.designOptions.dataLimits.seriesCapacity,convolution:e.designOptions.convolution,themeSettings:e.extraConfig.themeSettings});return{title:{text:null},drilldown:{activeDataLabelStyle:{cursor:"pointer",fontWeight:"bold",textDecoration:"none"},series:t}}}},CY={dataOptions:fY,data:pY,designOptions:_Y,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:wY,getAlerts:hY}),isCorrectRendererProps:Yr}};function xY(){return[]}const TY=(e,t)=>{if(E.emptyTable(t))return{rows:[],columns:[]};const r=E.getColumnsByName(t,e);return E.selectColumns(t,r)},zp=({column:e,sortType:t})=>{switch("getSort"in e?e.getSort():t){case"sortAsc":case V.Sort.Ascending:return 1;case"sortDesc":case V.Sort.Descending:return-1;default:return 0}},SY=(e,t)=>{const r=e.columns.find(n=>zp(n)!==0);if(r){const n=E.getColumnByName(t,r.column.name);n&&(n.direction=zp(r))}return t},d3=e=>{if(!("sortType"in e))return e;const t=e.sortType,r=V.convertSortDirectionToSort(t);return z(D({},e),{sortType:t,column:MY(e.column,r)})};function MY(e,t){return EY(e)?PY(e,t):e}function PY(e,t){const r=e.sort(t);return E.isMeasureColumn(r)&&E.isMeasureColumn(e)&&(r.title=e.title),r}function EY(e){return"sort"in e&&typeof e.sort=="function"}const AY=(e,t)=>({columns:e.columns.map(r=>{const n=r.column.name===t.name,i=zp(r),a=n?i===1?"sortDesc":"sortAsc":"sortNone";return r.sortType=a,d3(r)})}),RY=(e,t)=>{const r=TY(e.columns.map(({column:{name:n}})=>n),t);return SY(e,r)},DY=(e,t)=>{switch(t){case"iqr":return G4(e);case"extremums":return q4(e);case"standardDeviation":return Y4(e)}},NY=(e,t)=>{switch(t){case"iqr":return X4(e);case"standardDeviation":return Z4(e)}},kY=(e,t,r)=>{const{column:n,style:i}=E.splitColumn(e);let a=DY(n,t),o;return i&&(a=a.map(s=>D({column:s},i))),r&&(o=NY(n,t),o&&i&&(o=D({column:o},i))),{values:a,outliers:o}},LY=e=>e.value.length>1,OY=()=>({valueTitle:""}),h3=e=>{var h;const{category:t}=e;if(e.value.length===0)return OY();let r,n,i;if(LY(e))r=e.value,i=e.valueTitle,n=(h=e.outliers)==null?void 0:h[0];else{const{outliersEnabled:p,boxType:m}=e,g=E.normalizeColumn(e.value[0]),{values:b,outliers:_}=kY(g,m,!!p);r=b,n=_,i=E.getDataOptionTitle(g)}const[a,o,s,u,c,d]=r;return{category:t[0]&&E.normalizeColumn(t[0]),boxMin:a&&E.normalizeMeasureColumn(a),boxMedian:o&&E.normalizeMeasureColumn(o),boxMax:s&&E.normalizeMeasureColumn(s),whiskerMin:u&&E.normalizeMeasureColumn(u),whiskerMax:c&&E.normalizeMeasureColumn(c),outliersCount:d&&E.normalizeMeasureColumn(d),outliers:n&&E.normalizeColumn(n),valueTitle:i}};function IY(e){var a;const t=e.value.map(o=>{if(o!=null&&o.chartType)return[E.normalizeMeasureColumn(o)];const h=o,{lowerBound:s,upperBound:u,title:c}=h,d=Ye(h,["lowerBound","upperBound","title"]);return[E.normalizeMeasureColumn(D({column:E.safeMerge(s,{title:c})},d)),E.normalizeMeasureColumn(D({column:E.safeMerge(u,{title:c})},d))]}),r=t.flat(),n=t.filter(o=>o.length===2),i=t.filter(o=>o.length===1).flat();return{x:e.category.map(o=>E.normalizeColumn(o)),breakBy:((a=e.breakBy)==null?void 0:a.map(o=>E.normalizeColumn(o)))||[],y:r,rangeValues:n,seriesValues:i,seriesToColorMap:e.seriesToColorMap}}const Ry={city:4,state:3,country:2,auto:1};function FY(e){return e.filter(r=>"geoLevel"in r&&r.geoLevel).map(r=>r.geoLevel).reduce((r,n)=>Ry[n]>Ry[r]?n:r,"auto")}function $Y(e){const{geo:t,size:r,colorBy:n,details:i}=e;return{locations:t.map(a=>E.normalizeColumn(a)),size:r&&E.normalizeMeasureColumn(r),colorBy:n&&E.normalizeMeasureColumn(n),details:i&&E.normalizeAnyColumn(i),locationLevel:FY(t)}}const f3=e=>`$measure${e}_`,p3=e=>{const t={};return e.forEach((r,n)=>{const i=r.name,a=`${f3(n)}${i}`;r.name=a,t[a]=i}),t},BY=e=>{const t={};return{measures:e.map((n,i)=>{const a=n.name,o=`${f3(i)}${a}`;return t[o]=a,Object.assign(Object.create(n),{name:o})}),mapping:t}},m3=(e,t)=>{if(t==="funnel"){const r=E.merge(e);if(r.breakBy.length>0&&r.breakBy[0].sortType===void 0&&r.y.length>0&&r.y[0].sortType===void 0)return r.y[0].sortType="sortDesc",r}return e},g3=(e,t,r,n,i,a)=>{if(!e)return!0;if(t.length+r.length===0)throw new V.TranslatableError("errors.dataOptions.noDimensionsAndMeasures");return t.forEach(o=>{if(e.columns.findIndex(u=>u.name===o.name)===-1)throw new V.TranslatableError("errors.dataOptions.attributeNotFound",{attributeName:o.name})}),r.forEach(o=>{if(e.columns.findIndex(u=>u.name===o.name||u.name===n[o.name])===-1)throw new V.TranslatableError("errors.dataOptions.measureNotFound",{measureName:n[o.name]})}),i&&i.forEach(o=>{if(e.columns.findIndex(u=>u.name===o.attribute.name)===-1)throw new V.TranslatableError("errors.dataOptions.filterAttributeNotFound",{attributeName:o.attribute.name})}),a&&a.forEach(o=>{if(e.columns.findIndex(u=>u.name===o.attribute.name)===-1)throw new V.TranslatableError("errors.dataOptions.highlightAttributeNotFound",{attributeName:o.attribute.name})}),!0};function v3(e,t){switch(e){case"pie":case"funnel":case"treemap":return Qq(e,t);default:return t}}function y3(e,t){if(H.isCartesian(e))return Ui(t);if(H.isCategorical(e))return j0(t);if(H.isIndicator(e))return zY(t);if(H.isScatter(e))return HY(t);if(H.isBoxplot(e))return h3(t);if(H.isScattermap(e))return $Y(t);if(H.isRange(e))return IY(t);throw new V.TranslatableError("errors.unexpectedChartType",{chartType:e})}const j0=e=>({y:e.value.map(t=>E.normalizeMeasureColumn(t)),breakBy:e.category.map(t=>E.normalizeColumn(t)),seriesToColorMap:e.seriesToColorMap}),zY=e=>{var t,r,n,i,a,o;return{value:(t=e.value)==null?void 0:t.map(s=>E.normalizeMeasureColumn(s)),secondary:(r=e.secondary)==null?void 0:r.map(s=>E.normalizeMeasureColumn(s)),min:(i=(n=e.min)==null?void 0:n.map(s=>E.normalizeMeasureColumn(s)))==null?void 0:i.map(Dy("min")),max:(o=(a=e.max)==null?void 0:a.map(s=>E.normalizeMeasureColumn(s)))==null?void 0:o.map(Dy("max"))}},Dy=e=>t=>{const{column:r}=t,n="aggregation"in r&&r.aggregation||e;return z(D({},t),{column:E.safeMerge(r,{aggregation:n})})},HY=e=>{const{x:t,y:r,breakByPoint:n,breakByColor:i,size:a,seriesToColorMap:o}=e;return{x:t&&E.normalizeAnyColumn(t),y:r&&E.normalizeAnyColumn(r),breakByPoint:n&&E.normalizeColumn(n),breakByColor:i&&E.normalizeAnyColumn(i),size:a&&E.normalizeMeasureColumn(a),seriesToColorMap:o}};function b3(e,t){const r=e[t];return r==null?[]:Array.isArray(r)?r:[r]}function _3(e,t){let r=[];return H.isScatter(t)?r=["x","y","breakByPoint","breakByColor"]:H.isCartesian(t)||H.isCategorical(t)||H.isRange(t)?r=["x","breakBy"]:H.isBoxplot(t)?r=["category","outliers"]:H.isScattermap(t)&&(r=["locations"]),r.flatMap(n=>b3(e,n)).filter(n=>!E.isMeasureColumn(n))}function w3(e,t){let r=[];return H.isIndicator(t)?r=["value","secondary","min","max"]:H.isScatter(t)?r=["x","y","breakByColor","size"]:H.isCartesian(t)||H.isCategorical(t)||H.isRange(t)?r=["y"]:H.isBoxplot(t)?r=["boxMin","boxMedian","boxMax","whiskerMin","whiskerMax","outliersCount"]:H.isScattermap(t)&&(r=["size","colorBy","details"]),r.flatMap(n=>b3(e,n)).filter(E.isMeasureColumn)}function WY(e,t){return _3(e,t).map(({column:r})=>r)}function jY(e,t){return w3(e,t).map(({column:r})=>r)}function ul(e){return{columns:e.columns.map(t=>E.normalizeAnyColumn(t)).map(d3)}}function VY(e){const t=e.columns.filter(E.isMeasureColumn),{measures:r,mapping:n}=BY(t.map(E.translateColumnToMeasure));let i=0;const a=e.columns.map(o=>E.isMeasureColumn(o)?z(D({},o),{column:r[i++]}):o);return{dataOptions:z(D({},e),{columns:a}),mapping:n}}function C3(e){var t,r,n;return{rows:(t=e.rows)==null?void 0:t.map(i=>E.normalizeColumn(i)),columns:(r=e.columns)==null?void 0:r.map(i=>E.normalizeColumn(i)),values:(n=e.values)==null?void 0:n.map(i=>E.normalizeMeasureColumn(i)),grandTotals:e.grandTotals}}const UY={translateDataOptionsToInternal:e=>j0(sd({maxCategories:6,maxValues:1})(e)),getAttributes:nd,getMeasures:id,isCorrectDataOptions:e=>ad(e),isCorrectDataOptionsInternal:e=>od(e)},GY={loadData:ur,getChartData:(e,t,r)=>ld(e,t,r==null?void 0:r.defaultNumberFormattingEnabled)},qY={translateStyleOptionsToDesignOptions:e=>Jx(e),getDefaultStyleOptions:()=>({seriesLabels:{enabled:!1},legend:{enabled:!0}}),translateLegacyStyleOptionsToModern:e=>{var r;const t=e!=null?e:{};return t!=null&&t.labels&&!(t!=null&&t.seriesLabels)?z(D({},t),{seriesLabels:(r=t.labels.category)==null?void 0:r.map(n=>{var i;return{enabled:(i=n==null?void 0:n.enabled)!=null?i:!0}})}):t},isCorrectStyleOptions:e=>!(!e||typeof e!="object")},YY={getChart:()=>({type:"sunburst",spacing:[20,20,20,20],alignTicks:!1,polar:!1,animation:{duration:300}}),getSeries:e=>E.prepareSunburstSeries(e.chartData,e.dataOptions,e.designOptions,e.extraConfig.themeSettings,e.extraConfig.defaultNumberFormattingEnabled),getAxes:()=>({xAxis:void 0,yAxis:void 0}),getLegend:e=>E.getLegendSettings(e.designOptions.legend),getPlotOptions:()=>({series:{},sunburst:{events:{legendItemClick:function(e){e.preventDefault()}}}}),getTooltip:e=>E.prepareSunburstTooltip(e.dataOptions,e.designOptions,e.extraConfig.translate),getExtras:()=>({title:{text:null}})},XY={dataOptions:UY,data:GY,designOptions:qY,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:YY,getAlerts:xY}),isCorrectRendererProps:Yr}};function ZY(){return[]}const KY={translateDataOptionsToInternal:e=>j0(sd({maxCategories:3,maxValues:1})(e)),getAttributes:nd,getMeasures:id,isCorrectDataOptions:e=>ad(e),isCorrectDataOptionsInternal:e=>od(e)},QY={loadData:ur,getChartData:(e,t,r)=>ld(e,t,r==null?void 0:r.defaultNumberFormattingEnabled)},JY={translateStyleOptionsToDesignOptions:e=>Qx(e),getDefaultStyleOptions:()=>({seriesLabels:{enabled:!0},tooltip:{mode:"value"}}),translateLegacyStyleOptionsToModern:e=>{var r;const t=e!=null?e:{};return t!=null&&t.labels&&!(t!=null&&t.seriesLabels)?z(D({},t),{seriesLabels:(r=t.labels.category)==null?void 0:r.map(n=>{var i;return{enabled:(i=n==null?void 0:n.enabled)!=null?i:!0}})}):t},isCorrectStyleOptions:e=>!(!e||typeof e!="object")},eX="rgb(0, 206, 230)",tX={getChart:()=>({type:"treemap",spacing:[20,20,20,20],alignTicks:!1,polar:!1,animation:{duration:300}}),getSeries:e=>[{type:"treemap",layoutAlgorithm:"strip",layoutStartingDirection:"horizontal",clip:!1,color:eX,name:e.dataOptions.y[0]?E.getDataOptionTitle(e.dataOptions.y[0]):"",data:E.prepareTreemapDataItems(e.chartData,e.dataOptions,e.extraConfig.themeSettings),levels:E.prepareTreemapLevels(e.dataOptions,e.designOptions,e.extraConfig.themeSettings),dataLabels:{style:{textOutline:"none"}}}],getAxes:()=>({xAxis:void 0,yAxis:void 0}),getLegend:()=>({enabled:!1}),getPlotOptions:()=>({series:{}}),getTooltip:e=>E.getTreemapTooltipSettings(e.dataOptions,e.designOptions,e.extraConfig.translate,void 0,e.extraConfig.defaultNumberFormattingEnabled),getExtras:()=>({title:{text:null}})},rX={dataOptions:KY,data:QY,designOptions:JY,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:tX,getAlerts:ZY}),isCorrectRendererProps:Yr}};function nX(e){const t=Object.values(e);return t.length>0&&t.every(r=>typeof r=="string")}function iX(e){const t=e.indexOf("__");if(t<=0)return;const r=Number.parseInt(e.slice(0,t),10);return Number.isNaN(r)?void 0:r}function aX(e){const t=new Set,r=E.getDataOptionTitle(e);return r&&(t.add(r),t.add(V.normalizeName(r))),t.add(e.column.name),t.add(V.normalizeName(e.column.name)),"title"in e.column&&typeof e.column.title=="string"&&(t.add(e.column.title),t.add(V.normalizeName(e.column.title))),[...t]}function x3(e,t,r,n){if(!n)return;if(nX(n)){const a=n[t];return typeof a=="string"?a:void 0}const i=iX(e);if(!(i===void 0||i>=r.length))for(const a of aX(r[i])){const o=n[a],s=o==null?void 0:o[t];if(typeof s=="string")return s}}const Hp=1e3;function oX(e,t){var g,b,_,w,C,S;const r=e.category.map(T=>T.column.name),n=e.value.column.name,i=new Map;for(const T of t.columns)i.set(T.name,T.index);const a=i.get(n),o=[],s=(T,M)=>`${T}__${M}`,u=new Map;for(let T=0;T<r.length-1;T++){const M=i.get(r[T]),P=i.get(r[T+1]);if(M===void 0||P===void 0||a===void 0)continue;const R=new Map;for(const k of t.rows){const I=k[M],$=k[P],G=String((g=I==null?void 0:I.displayValue)!=null?g:""),Y=String((b=$==null?void 0:$.displayValue)!=null?b:"");if(!G||!Y)continue;const B=s(T,G),X=s(T+1,Y),U=(_=k[a])==null?void 0:_.rawValue,Q=Math.max(0,typeof U=="number"?U:Number(U)||0),W=`${B}\0${X}`;R.set(W,((w=R.get(W))!=null?w:0)+Q),u.has(B)?(I==null?void 0:I.blur)===!1&&(u.get(B).blur=!1):u.set(B,{rawValue:I==null?void 0:I.rawValue,blur:I==null?void 0:I.blur,name:G}),u.has(X)?($==null?void 0:$.blur)===!1&&(u.get(X).blur=!1):u.set(X,{rawValue:$==null?void 0:$.rawValue,blur:$==null?void 0:$.blur,name:Y})}for(const[k,I]of R.entries()){const $=k.indexOf("\0");o.push({from:k.slice(0,$),to:k.slice($+1),weight:I})}}const c=o.length>Hp?o.length:void 0,d=c!==void 0?o.slice(0,Hp):o,h=new Set,p=[],m=Array.from(u.values()).some(T=>T.blur!==void 0);for(const T of d)for(const M of[T.from,T.to])if(!h.has(M)){h.add(M);const P=u.get(M),R=(C=P==null?void 0:P.name)!=null?C:M,k=x3(M,R,e.category,e.seriesToColorMap);p.push(z(D({id:M,name:R},k?{color:k}:{}),{rawValue:P==null?void 0:P.rawValue,blur:m?(S=P==null?void 0:P.blur)!=null?S:!1:void 0}))}return{type:"sankey",links:d,nodes:p,totalLinksBeforeTruncation:c}}const sX={loadData:ur,getChartData:oX},Ny=6;function lX(e){const{translate:t}=e.extraConfig,r=[],n=e.dataOptions.category.length;return n>Ny&&r.push(t("chart.sankey.alerts.tooManyStages",{stageCount:String(n),softLimit:String(Ny)})),e.chartData.totalLinksBeforeTruncation!==void 0&&console.warn(`Sankey chart: query returned ${e.chartData.totalLinksBeforeTruncation} links; only the first ${Hp} are displayed.`),r}function uX(e){return{category:e.category.map(t=>E.normalizeColumn(t)),value:E.normalizeMeasureColumn(e.value),seriesToColorMap:e.seriesToColorMap}}function cX(e){return e.category.map(t=>E.translateColumnToAttribute(t)).filter(Boolean)}function dX(e){return[E.translateColumnToMeasure(e.value)]}function hX(e){if(!("category"in e&&"value"in e)||"breakBy"in e)return!1;const{category:t,value:r}=e;if(!Array.isArray(t)||Array.isArray(r)||t.length<2)return!1;const n=i=>i!=null&&typeof i=="object"&&!Array.isArray(i);return t.every(n)&&n(r)}function fX(e){if(!("category"in e&&"value"in e))return!1;const{category:t,value:r}=e;return!Array.isArray(t)||Array.isArray(r)?!1:t.every(n=>E.isStyledColumn(n))&&E.isStyledColumn(r)}const pX={translateDataOptionsToInternal:uX,getAttributes:cX,getMeasures:dX,isCorrectDataOptions:hX,isCorrectDataOptionsInternal:fX};function mX(e){return e.orientation==="vertical"?"vertical":"horizontal"}function gX(e){var t;return z(D({},Kt),{orientation:mX(e),curveFactor:e.curveFactor,linkOpacity:e.linkOpacity,nodeWidth:e.nodeWidth,nodePadding:e.nodePadding,minLinkWidth:e.minLinkWidth,nodeAlignment:e.nodeAlignment,legend:(t=e.legend)!=null?t:{enabled:!1}})}function vX(e){return e!==null&&!Array.isArray(e)&&typeof e=="object"}function yX(){return{orientation:"horizontal",nodeAlignment:"top",curveFactor:.33,linkOpacity:.5,nodeWidth:20,nodePadding:10,minLinkWidth:1,legend:{enabled:!1}}}const bX={translateStyleOptionsToDesignOptions:gX,isCorrectStyleOptions:vX,getDefaultStyleOptions:yX},T3=e=>e.type==="sankey";function _X({isLoading:e,rendererPainted:t,hasNoDimensions:r,chartData:n}){const i=!e&&(r||!!n&&T3(n)&&n.links.length===0);return!e&&t||i}function wX(e,t,r,n){var o;const i=(o=e.name)!=null?o:e.id;if(t.has(i)||t.set(i,t.size),e.color)return e.color;const a=x3(e.id,i,r.category,r.seriesToColorMap);return a||E.getPaletteColor(n,t.get(i))}const CX={getChart(e){return{type:"sankey",polar:!1,spacing:[20,20,20,20],alignTicks:!1,inverted:e.designOptions.orientation==="vertical"}},getSeries(e){var d,h,p,m,g,b,_;const{links:t,nodes:r}=e.chartData,{designOptions:n,dataOptions:i,extraConfig:a}=e,o=.1,s=(d=n.linkOpacity)!=null?d:.5,u=new Map,c=(p=(h=a.themeSettings)==null?void 0:h.palette)==null?void 0:p.variantColors;return[D({type:"sankey",name:i.value.column.name,data:t.map(w=>{var P,R;const C=(P=r.find(k=>k.id===w.from))==null?void 0:P.blur,S=(R=r.find(k=>k.id===w.to))==null?void 0:R.blur,T=C===!0||S===!0,M=r.some(k=>k.blur!==void 0);return{from:w.from,to:w.to,weight:w.weight,linkOpacity:M&&T?o:s}}),nodes:r.map(w=>{var C;return{id:w.id,name:(C=w.name)!=null?C:w.id,color:wX(w,u,i,c),opacity:w.blur===!0?o:1,custom:{rawValue:w.rawValue}}}),linkOpacity:s,curveFactor:(m=n.curveFactor)!=null?m:.33,nodePadding:(g=n.nodePadding)!=null?g:10,nodeWidth:(b=n.nodeWidth)!=null?b:20,minLinkWidth:(_=n.minLinkWidth)!=null?_:1,turboThreshold:0},n.nodeAlignment?{nodeAlignment:n.nodeAlignment}:{})]},getAxes(){return{xAxis:void 0,yAxis:void 0}},getLegend(e){return E.getLegendSettings(e.designOptions.legend)},getPlotOptions(){return{series:{}}},getTooltip(e){var u;const{column:t,numberFormatConfig:r}=e.dataOptions.value,n=(u=t.title)==null?void 0:u.trim(),i=n!==void 0&&n.length>0?n:t.name,a=E.getCompleteNumberFormatConfig(r),o=c=>E.applyFormat(a,c),s=c=>{const d=c==null?void 0:c.trim();return d!==void 0&&d.length>0?d:"—"};return{useHTML:!0,formatter:function(){var p,m;const c=this;if(c.point.isNode)return E.purify.sanitize(`<span style="font-size:11px">${i}</span><br/><b>${c.point.name}</b>: ${o(c.point.sum)}`);const d=s((p=c.point.fromNode)==null?void 0:p.name),h=s((m=c.point.toNode)==null?void 0:m.name);return E.purify.sanitize(`<span style="font-size:11px">${i}</span><br/>${d} → ${h}: <b>${o(c.point.weight)}</b>`)}}},getExtras(){return{title:{text:null}}}},xX={dataOptions:pX,data:sX,designOptions:bX,renderer:{ChartRendererComponent:qr({highchartsOptionsBuilder:CX,getAlerts:lX}),isCorrectRendererProps:Yr},onReady:{isReadyForOnReady:_X}};function TX(e){switch(e.type){case"previous-period":return{type:"previous-period"};case"delta":return{type:"delta",value:E.normalizeMeasureColumn(e.value)};case"value":return{type:"value",value:E.normalizeMeasureColumn(e.value)};case"target":return{type:"target",target:typeof e.target=="number"?e.target:E.normalizeMeasureColumn(e.target)}}}function SX(e){var t;return{value:E.normalizeMeasureColumn(e.value),trend:e.trend?E.normalizeColumn(e.trend):void 0,valueMode:(t=e.valueMode)!=null?t:"last",comparison:e.comparison?TX(e.comparison):void 0}}function MX(e){return e.trend&&N0(e.trend.column)?[e.trend.column]:[]}function PX(e){const t=[e.value],r=e.comparison;return(r==null?void 0:r.type)==="delta"||(r==null?void 0:r.type)==="value"?t.push(r.value):(r==null?void 0:r.type)==="target"&&typeof r.target!="number"&&t.push(r.target),t.filter(n=>E.isMeasureColumn(n.column)).map(n=>n.column)}function EX(e){return"value"in e&&!!e.value&&!Array.isArray(e.value)&&!("category"in e)&&!("x"in e)&&!("y"in e)&&!("geo"in e)&&!("locations"in e)&&!("min"in e)&&!("max"in e)}function S3(e){return"value"in e&&typeof e.value=="object"&&e.value!==null&&!Array.isArray(e.value)&&"valueMode"in e}function M3(e,t){return E.applyFormatPlainText(E.getCompleteNumberFormatConfig(t),e)}function ky(e,t){return{deltaValue:e-t,deltaPercent:t===0?void 0:(e-t)/Math.abs(t)*100}}function AX(e,t){return{percentOfTarget:t===0?void 0:e/t*100,toGo:t-e}}const RX={years:"kpi.comparison.vsPriorYear",quarters:"kpi.comparison.vsPriorQuarter",months:"kpi.comparison.vsPriorMonth",weeks:"kpi.comparison.vsPriorWeek",days:"kpi.comparison.vsPriorDay"};function DX(e){var t,r;return(r=RX[(t=e==null?void 0:e.toLowerCase())!=null?t:""])!=null?r:"kpi.comparison.vsPriorPeriod"}const P3="$kpiRowType",NX="bucket",kX="total",LX=e=>ht(exports,null,function*(){const{app:t,chartDataOptionsInternal:r,queryDescription:n,executionConfig:i}=e;if(!(r.valueMode==="total"&&!!r.trend))return ur({app:t,queryDescription:n,executionConfig:i});const o=z(D({},n),{dimensions:[]}),[s,u]=yield Promise.all([ur({app:t,queryDescription:n,executionConfig:i}),ur({app:t,queryDescription:o,executionConfig:i})]);return OX(s,u)});function OX(e,t){const r=[...e.columns,{name:P3,type:"string"}],n=e.rows.map(s=>[...s,{data:NX}]);if(t.rows.length===0)return{columns:r,rows:n};const i=Math.max(e.columns.length-t.columns.length,0),o=[...Array.from({length:i},()=>({data:""})),...t.rows[0],{data:kX}];return{columns:r,rows:[...n,o]}}const IX="#4CAF50",FX="#E53935";function E3(e,t){const r=e.color;if(!r||t===void 0)return;const n=E.getColoringServiceByColorOptions(r);if(n.type==="Static")return n.getColor();if(n.type==="Absolute")return n.getColor(t)}function $X(e,t){if(t===void 0)return;if(!e)return t>0?IX:t<0?FX:void 0;const r=E.getColoringServiceByColorOptions(e);switch(r.type){case"Static":return r.getColor();case"Absolute":return r.getColor(t);case"Relative":return;default:return}}function _a(e,t){const r=E.getValue(e,t);return typeof r=="number"&&Number.isFinite(r)?r:void 0}function Ly(e){return typeof e=="number"}function Ou(e){return e.column.title||e.column.name}function Kh(e,t,r){if(!t)return;const n=E.getColumnByName(e,r.column.name);return n?_a(t,n):void 0}function BX(e,t,r,n,i,a){const o=e.comparison;if(o)switch(o.type){case"previous-period":{if(i===void 0||a===void 0)return;const{deltaValue:s,deltaPercent:u}=ky(i,a);return{type:"previous-period",baseline:a,deltaValue:s,deltaPercent:u,labelKey:DX(e.trend?E.getDataOptionGranularity(e.trend):void 0)}}case"delta":{const s=Kh(t,r,o.value);if(n===void 0||s===void 0)return;const{deltaValue:u,deltaPercent:c}=ky(n,s);return{type:"delta",baseline:s,deltaValue:u,deltaPercent:c,label:Ou(o.value)}}case"target":{const s=o.target,u=Ly(s)?s:Kh(t,r,s);if(n===void 0||u===void 0)return;const{percentOfTarget:c,toGo:d}=AX(n,u);return{type:"target",target:u,percentOfTarget:c,toGo:d,label:Ly(s)?M3(s):Ou(s)}}case"value":{const s=Kh(t,r,o.value);return s===void 0?void 0:{type:"value",value:s,label:Ou(o.value),color:E3(o.value,s),numberFormatConfig:o.value.numberFormatConfig}}default:return}}function zX(e,t){const n={type:"kpi",hasRows:!1,valueTitle:Ou(e.value),numberFormatConfig:e.value.numberFormatConfig},i=E.getColumnByName(t,e.value.column.name);if(!i||t.rows.length===0)return n;const a=E.getColumnByName(t,P3),o=a?t.rows.find(_=>E.getValue(_,a)==="total"):void 0,s=a?t.rows.filter(_=>E.getValue(_,a)!=="total"):t.rows,u=e.trend?E.getColumnByName(t,e.trend.column.name):void 0;let c,d,h,p,m,g;if(e.trend){h=s.map((C,S)=>{var P;const T=u?E.getValue(C,u):void 0;return{x:typeof T=="number"&&Number.isFinite(T)?T:S,y:(P=_a(C,i))!=null?P:null}});const _=s.length>0?s[s.length-1]:void 0,w=s.length>1?s[s.length-2]:void 0;if(p=_?_a(_,i):void 0,m=w?_a(w,i):void 0,e.valueMode==="total")g=o,c=o?_a(o,i):void 0;else if(g=_,c=p,_&&u){const C=E.getValue(_,u);d=typeof C=="number"&&Number.isFinite(C)?C:void 0}}else g=t.rows[0],c=_a(g,i);const b=BX(e,t,g,c,p,m);return z(D({},n),{hasRows:!0,value:c,valueColor:E3(e.value,c),valuePeriodMs:d,sparklinePoints:h,comparison:b})}function HX(e,t){var r,n,i,a,o,s,u,c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k,I,$,G;return z(D({},Kt),{width:e.width,height:e.height,layout:(r=e.layout)!=null?r:"standard",value:{textSize:(i=(n=e.value)==null?void 0:n.textSize)!=null?i:"auto",noDataText:(a=e.value)==null?void 0:a.noDataText,conditionalIcons:(o=e.value)==null?void 0:o.conditionalIcons},title:{enabled:(u=(s=e.title)==null?void 0:s.enabled)!=null?u:!0,text:(c=e.title)==null?void 0:c.text},card:{backgroundColor:(d=e.card)==null?void 0:d.backgroundColor,textAlign:(p=(h=e.card)==null?void 0:h.textAlign)!=null?p:"left",showBorder:(g=(m=e.card)==null?void 0:m.showBorder)!=null?g:!1,cornerRadius:(_=(b=e.card)==null?void 0:b.cornerRadius)!=null?_:8},sparkline:{enabled:((C=(w=e.sparkline)==null?void 0:w.enabled)!=null?C:!0)&&!!t.trend,chartType:(T=(S=e.sparkline)==null?void 0:S.chartType)!=null?T:"area"},comparison:{display:(P=(M=e.comparison)==null?void 0:M.display)!=null?P:"percent",label:(R=e.comparison)==null?void 0:R.label,color:(k=e.comparison)==null?void 0:k.color,showIcon:($=(I=e.comparison)==null?void 0:I.showIcon)!=null?$:!0,conditionalIcons:(G=e.comparison)==null?void 0:G.conditionalIcons}})}function WX(e){return typeof e=="object"&&e!==null&&!("subtype"in e)}function jX(){return{layout:"standard",title:{enabled:!0},value:{textSize:"auto"},comparison:{display:"percent",showIcon:!0},sparkline:{chartType:"area"},card:{textAlign:"left",showBorder:!1,cornerRadius:8}}}const A3=e=>e.type==="kpi",Wp=999.99,ks="previous-period";function ja(e,t){return E.applyFormat(E.getCompleteNumberFormatConfig(t),e)}function VX(e,t,r){return Math.max(0,e-t-r)}function UX(e){const t=Math.max(-Wp,Math.min(Wp,e));return`${t>=0?"+":""}${t.toFixed(2)}%`}function GX(e){return e!==void 0&&Number.isFinite(e)&&Math.abs(e)<=Wp}function qX(e,t){return`${e>=0?"+":""}${ja(e,t)}`}function Oy(e,t){if(!(!e||t===void 0))return e.find(r=>YX(t,r.operator,r.expression))}function YX(e,t,r){const n=Number(r);if(Number.isNaN(n))return!1;switch(t){case"<":return e<n;case">":return e>n;case"≤":case"<=":return e<=n;case"≥":case">=":return e>=n;case"=":return e===n;case"≠":case"!=":return e!==n;default:return!1}}function R3(e,t,r){const n=GX(e.deltaPercent)?UX(e.deltaPercent):null,i=qX(e.deltaValue,r);switch(t){case"percent":return n!=null?n:i;case"value":return i;case"both":return n?`${n} (${i})`:i;default:return i}}function Iy(e){switch(e.type){case ks:case"delta":return e.deltaPercent;case"target":return e.percentOfTarget;default:return}}function XX(e,t){switch(e.type){case ks:return{type:ks,baseline:e.baseline,deltaValue:e.deltaValue,deltaPercent:e.deltaPercent,label:t(e.labelKey)};case"delta":return{type:"delta",baseline:e.baseline,deltaValue:e.deltaValue,deltaPercent:e.deltaPercent,label:e.label};case"target":return{type:"target",target:e.target,percentOfTarget:e.percentOfTarget,toGo:e.toGo,label:e.label};case"value":return{type:"value",value:e.value,label:e.label}}}function ZX(e,t){return{value:e.value,valueTitle:e.valueTitle,valueColor:e.valueColor,valuePeriodMs:e.valuePeriodMs,comparison:e.comparison?XX(e.comparison,t):void 0,sparklinePoints:e.sparklinePoints}}function Fy(e){return{value:e.value,date:e.valuePeriodMs,comparison:e.comparison}}function KX(e,t){const r=e&&e.type===t.type?e:void 0,n=r&&"color"in r?r.color:void 0;switch(t.type){case ks:case"delta":return{type:t.type,baseline:t.baseline,deltaValue:t.deltaValue,deltaPercent:t.deltaPercent,label:t.label,color:n};case"target":return{type:"target",target:t.target,percentOfTarget:t.percentOfTarget,toGo:t.toGo,label:t.label,color:n};case"value":return{type:"value",value:t.value,label:t.label,color:n,numberFormatConfig:(r==null?void 0:r.type)==="value"?r.numberFormatConfig:void 0}}}function QX(e,t,r="percent"){switch(e.type){case ks:case"delta":{const n=R3(e,r,t);return e.label?`${n} ${e.label}`:n!=null?n:""}case"target":{const n=`${ja(Math.abs(e.toGo),t)} to go`,i=e.percentOfTarget!==void 0?`${Math.round(e.percentOfTarget)}% of ${e.label}`:void 0;return r==="value"||!i?n:r==="both"?`${i}, ${n}`:i}case"value":return`${e.label} ${ja(e.value,e.numberFormatConfig)}`}}const D3=4,N3=14,k3=8,L3=4,O3=1,I3=32,V0=.7,U0=6,F3=.85,jp=3,lu={columns:"1fr",rowsWithSparkline:`auto auto minmax(${I3}px, 1fr)`,rowsWithoutSparkline:"auto 1fr auto",areas:"'title' 'body' 'sparkline'"},JX=y.newStyled.figure`
98
+ margin: 0;
99
+ display: grid;
100
+ grid-template-columns: ${lu.columns};
101
+ grid-template-rows: ${({$hasSparkline:e})=>e?lu.rowsWithSparkline:lu.rowsWithoutSparkline};
102
+ grid-template-areas: ${lu.areas};
103
+ row-gap: ${L3}px;
104
+ width: 100%;
105
+ height: 100%;
106
+ box-sizing: border-box;
107
+ padding-block: ${N3}px ${k3}px;
108
+ padding-inline: 16px;
109
+ cursor: ${({$clickable:e})=>e?"pointer":"default"};
110
+ font-family: ${({theme:e})=>e.typography.fontFamily};
111
+ background-color: ${({$backgroundColor:e,theme:t})=>e!=null?e:t.chart.backgroundColor};
112
+ /* Logical values only ('start'/'end', never 'left'/'right') -- the card is a hard RTL-safety
113
+ invariant, so 'right' must mirror to the block-end edge (not the physical right) in RTL. */
114
+ text-align: ${({$textAlign:e})=>e==="left"?"start":e==="right"?"end":"center"};
115
+ border: ${({$showBorder:e})=>e?`${O3}px solid rgba(0, 0, 0, 0.12)`:"none"};
116
+ border-radius: ${({$cornerRadius:e})=>e}px;
117
+ overflow: hidden;
118
+
119
+ &:focus-visible {
120
+ outline: 2px solid currentColor;
121
+ outline-offset: -2px;
122
+ }
123
+ `,eZ=y.newStyled.div`
124
+ grid-area: title;
125
+ display: flex;
126
+ align-items: baseline;
127
+ justify-content: space-between;
128
+ gap: 8px;
129
+ min-width: 0;
130
+ `,tZ=y.newStyled.div`
131
+ grid-area: body;
132
+ display: flex;
133
+ flex-direction: column;
134
+ gap: ${D3}px;
135
+ min-width: 0;
136
+ min-height: 0;
137
+ overflow: hidden;
138
+ `,$y=y.newStyled.div`
139
+ flex: 0 0 auto;
140
+ min-width: 0;
141
+ order: ${({$order:e})=>e};
142
+ `,rZ=y.newStyled.div`
143
+ min-width: 0;
144
+ min-height: 0;
145
+ overflow: hidden;
146
+ `,Qh=y.newStyled.div`
147
+ min-width: 0;
148
+ `,nZ=y.newStyled.div`
149
+ grid-area: sparkline;
150
+ min-width: 0;
151
+ min-height: 0;
152
+ overflow: hidden;
153
+ /* No own height: the grid row is minmax(SPARKLINE_MIN_HEIGHT_PX, 1fr) when a sparkline is
154
+ rendered, so the area stretches to however much leftover height the content group leaves --
155
+ the Highcharts instance follows via useElementSize -> explicit chart.width/height. */
156
+ line-height: 0;
157
+ `,iZ=y.newStyled.span`
158
+ font-size: 0.72rem;
159
+ font-weight: 600;
160
+ text-transform: uppercase;
161
+ letter-spacing: 0.06em;
162
+ color: ${({$onColor:e,theme:t})=>e?"#ffffff":t.chart.textColor};
163
+ opacity: ${({$onColor:e})=>e?.85:.55};
164
+ white-space: nowrap;
165
+ overflow: hidden;
166
+ text-overflow: ellipsis;
167
+ `,aZ=y.newStyled.span`
168
+ font-size: 0.7rem;
169
+ color: ${({$onColor:e,theme:t})=>e?"#ffffff":t.chart.textColor};
170
+ opacity: ${({$onColor:e})=>e?.75:.45};
171
+ white-space: nowrap;
172
+ margin-inline-start: 8px;
173
+ flex-shrink: 0;
174
+ `,oZ=y.newStyled.div`
175
+ font-weight: 700;
176
+ line-height: 1.1;
177
+ color: ${({$color:e,$onColor:t,theme:r})=>e!=null?e:t?"#ffffff":r.chart.textColor};
178
+ white-space: nowrap;
179
+ overflow: hidden;
180
+ text-overflow: ellipsis;
181
+ `,$3=y.newStyled.span`
182
+ margin-inline-end: ${U0}px;
183
+ font-size: ${V0}em;
184
+ color: ${({$color:e})=>e!=null?e:"inherit"};
185
+ `,Jh=y.newStyled.div`
186
+ display: flex;
187
+ flex-direction: ${({$compact:e})=>e?"row":"column"};
188
+ align-items: ${({$compact:e})=>e?"baseline":"flex-start"};
189
+ gap: ${({$compact:e})=>e?"6px":"0"};
190
+ min-width: 0;
191
+ `,ef=y.newStyled.div`
192
+ /* 'headline' scale's font-size is auto-fit and set inline (see kpi-comparison.tsx), matching
193
+ how ValueText's headline scale is applied -- this rule only ever fires for 'compact'. */
194
+ font-size: ${({$scale:e})=>e==="compact"?"0.9rem":void 0};
195
+ font-weight: 600;
196
+ color: ${({$color:e,theme:t})=>e!=null?e:t.chart.textColor};
197
+ display: flex;
198
+ align-items: center;
199
+ gap: ${jp}px;
200
+ white-space: nowrap;
201
+ overflow: hidden;
202
+ text-overflow: ellipsis;
203
+ `,tf=y.newStyled.div`
204
+ font-size: 0.7rem;
205
+ color: ${({$onColor:e,theme:t})=>e?"#ffffff":t.chart.textColor};
206
+ opacity: ${({$onColor:e})=>e?.8:.5};
207
+ white-space: nowrap;
208
+ overflow: hidden;
209
+ text-overflow: ellipsis;
210
+ `,sZ=y.newStyled.span`
211
+ font-size: ${F3}em;
212
+ `;function lZ(e){return e==="big-comparison"?1:0}function uZ(e){return e==="big-comparison"?0:1}const cZ=N.forwardRef(function({layout:t,tier:r,ariaLabel:n,card:i,clickable:a,onClick:o,onContextMenu:s,title:u,value:c,comparison:d,sparkline:h,bodyRef:p},m){const{themeSettings:g}=y.useThemeContext(),b=_=>{_.key!=="Enter"&&_.key!==" "||(_.preventDefault(),_.currentTarget.click())};return O.jsxs(JX,{ref:m,role:"figure","aria-label":n,"data-kpi-tier":r,"data-kpi-layout":t,tabIndex:a?0:void 0,onClick:o,onContextMenu:s,onKeyDown:a?b:void 0,theme:g,$backgroundColor:i.backgroundColor,$textAlign:i.textAlign,$showBorder:i.showBorder,$cornerRadius:i.cornerRadius,$clickable:a,$hasSparkline:!!h,children:[u,O.jsxs(tZ,{ref:p,"data-kpi-area":"body",children:[O.jsx($y,{$order:lZ(t),children:c}),d&&O.jsx($y,{$order:uZ(t),children:d})]}),h]})}),dZ=1.2,Iu=100,hZ=2,fZ=500,pZ=20;function uc(e,t){return`${e.weight} ${t}px ${e.family}`}function By(e){return e.split(",")[0].trim().replace(/^['"]|['"]$/g,"").toLowerCase()}function zy(e,t){if(typeof e.forEach!="function")return;const r=By(t);let n=!1;try{e.forEach(i=>{By(i.family)===r&&(n=!0)})}catch(i){return}return n}function mZ(e,t,r){const n=document.fonts;if(!(n!=null&&n.check))return null;let i=!1;try{i=n.check(e)}catch(p){return null}if(i&&zy(n,t)!==!1)return null;const a=i;let o=!1,s=0;const u=[],c=()=>{o||(o=!0,u.forEach(p=>p()))},d=()=>{try{return a?zy(n,t)===!0&&n.check(e):n.check(e)}catch(p){return!1}},h=()=>{o||d()&&(c(),r())};if(n.addEventListener&&(n.addEventListener("loadingdone",h),u.push(()=>{var p;return(p=n.removeEventListener)==null?void 0:p.call(n,"loadingdone",h)})),!a){const p=setInterval(()=>{s+=1,h(),!o&&s>=pZ&&c()},fZ);u.push(()=>clearInterval(p))}return c}let Uo;function gZ(e,t){return Uo===void 0&&(Uo=document.createElement("canvas").getContext("2d")),Uo?(Uo.font=t,Uo.measureText(e).width):0}function Hy(e,t,r,n){return e.reduce((i,a)=>i+n(a.text,uc(t,a.emScale*r)),0)}function vZ(e){const{text:t,font:r,maxWidthPx:n,maxHeightPx:i,minPx:a,maxPx:o,measure:s=gZ,affixes:u=[]}=e,c=(s(t,uc(r,Iu))+Hy(u,r,Iu,s))/Iu,d=u.reduce((_,w)=>_+w.gapPx,0),h=Math.max(0,n-d),p=c>0?h/c:o,m=i/dZ,g=Math.min(Math.max(Math.min(p,m),a),o);let b=Math.max(a,Math.floor(g));for(let _=0;_<hZ&&b>a;_++){const w=s(t,uc(r,b))+Hy(u,r,b,s);if(w<=0||w<=h)break;const C=Math.max(a,Math.floor(b*(h/w)));if(C===b)break;b=C}return b}function yZ(e){return(e!=null?e:[]).map(t=>`${t.text} ${t.emScale} ${t.gapPx}`).join("|")}function bZ(e,t){return e.text===t.text&&e.fontFamily===t.fontFamily&&e.fontWeight===t.fontWeight&&e.maxWidthPx===t.maxWidthPx&&e.maxHeightPx===t.maxHeightPx&&e.minPx===t.minPx&&e.maxPx===t.maxPx&&e.measure===t.measure&&e.affixesKey===t.affixesKey}function B3(e){const{containerRef:t,text:r,font:n,minPx:i,maxPx:a,measure:o,maxHeightPxOverride:s,enabled:u,affixes:c}=e,[d,h]=N.useState(i),p=N.useRef({text:r,font:n,minPx:i,maxPx:a,measure:o,maxHeightPxOverride:s,enabled:u,affixes:c});p.current={text:r,font:n,minPx:i,maxPx:a,measure:o,maxHeightPxOverride:s,enabled:u,affixes:c};const m=N.useRef({element:null,ro:null,cancelled:!1,stopFontWatch:null,watchedProbeFont:null}),g=N.useRef(null);return N.useLayoutEffect(()=>{var C,S,T;const b=p.current.enabled===!1?null:t.current,_=m.current,w=()=>{var $;if(_.cancelled)return;const M=t.current;if(!M)return;const P=p.current,R={text:P.text,fontFamily:P.font.family,fontWeight:P.font.weight,maxWidthPx:M.clientWidth,maxHeightPx:($=P.maxHeightPxOverride)!=null?$:M.clientHeight,minPx:P.minPx,maxPx:P.maxPx,measure:P.measure,affixesKey:yZ(P.affixes)},k=g.current;if(k&&bZ(k,R))return;g.current=R;const I=vZ({text:R.text,font:P.font,maxWidthPx:R.maxWidthPx,maxHeightPx:R.maxHeightPx,minPx:R.minPx,maxPx:R.maxPx,measure:R.measure,affixes:P.affixes});h(G=>G===I?G:I)};if((b!==_.element||b!==null&&_.cancelled)&&(_.cancelled=!0,(C=_.ro)==null||C.disconnect(),_.ro=null,(S=_.stopFontWatch)==null||S.call(_),_.stopFontWatch=null,_.watchedProbeFont=null,_.element=b,b)){_.cancelled=!1;const M=new ResizeObserver(w);M.observe(b),_.ro=M}if(b){const M=uc(p.current.font,Iu);M!==_.watchedProbeFont&&(_.watchedProbeFont=M,(T=_.stopFontWatch)==null||T.call(_),_.stopFontWatch=mZ(M,p.current.font.family,()=>{g.current=null,w()})),w()}else{g.current=null;const M=p.current.minPx;h(P=>P===M?P:M)}}),N.useEffect(()=>()=>{var b,_,w;m.current.cancelled=!0,(b=m.current.ro)==null||b.disconnect(),(w=(_=m.current).stopFontWatch)==null||w.call(_)},[]),d}const z3=16,H3=64,_Z="0.9rem";function wZ({text:e,color:t,textSize:r,icon:n,onColor:i,scale:a,maxHeightPx:o,areaRef:s}){var g;const{themeSettings:u}=y.useThemeContext(),c=N.useRef(null),d=s!=null?s:c,h=n?[{text:n.icon,emScale:V0,gapPx:U0}]:void 0,p=B3({containerRef:d,text:e,font:{family:u.typography.fontFamily,weight:700},minPx:z3,maxPx:H3,maxHeightPxOverride:o,affixes:h,enabled:r==="auto"&&a==="headline"}),m=r!=="auto"?`${r}px`:a==="headline"?`${p}px`:_Z;return O.jsx(rZ,{ref:d,"data-kpi-area":"value",children:O.jsxs(oZ,{theme:u,$onColor:i,$color:t,style:{fontSize:m},children:[n&&O.jsx($3,{"aria-hidden":"true",$color:(g=n.color)!=null?g:t,children:n.icon}),e]})})}function CZ({comparison:e,color:t,numberFormatConfig:r,display:n,showIcon:i,conditionalIcon:a,labelOverride:o,scale:s,compact:u,onColor:c,maxHeightPx:d,areaRef:h}){var W,q;const{t:p}=O.useTranslation(),{themeSettings:m}=y.useThemeContext(),g=N.useRef(null),b=h!=null?h:g,_=o!=null?o:e.label,w=a&&O.jsx($3,{"aria-hidden":"true",$color:(W=a.color)!=null?W:t,children:a.icon}),C=e.type==="target"&&e.percentOfTarget!==void 0?Math.round(e.percentOfTarget):void 0,S=C!==void 0?p("kpi.target.ofGoal",{percent:`${C}%`,goal:_}):void 0,T=e.type==="previous-period"||e.type==="delta"?R3(e,n,r):void 0,M=e.type==="target"?p("kpi.target.toGo",{value:ja(Math.abs(e.toGo),r)}):void 0,P=e.type==="target"?n==="value"?M:S!=null?S:M:void 0,R=e.type==="target"&&n==="both"&&S?M:void 0,k=e.type==="value"?ja(e.value,r):e.type==="target"?P!=null?P:"":T!=null?T:"",I=e.type==="previous-period"||e.type==="delta",$=I&&i,Y=I&&((q=e.deltaPercent)!=null?q:e.deltaValue)>=0?"▲":"▼",B=[...a&&e.type!=="value"?[{text:a.icon,emScale:V0,gapPx:U0+jp}]:[],...$?[{text:Y,emScale:F3,gapPx:jp}]:[]],X=B3({containerRef:b,text:k,font:{family:m.typography.fontFamily,weight:600},minPx:z3,maxPx:H3,maxHeightPxOverride:d,affixes:B,enabled:s==="headline"}),U=s==="headline"?{fontSize:`${X}px`}:void 0,Q=u&&s!=="headline";return e.type==="target"?O.jsx(Qh,{ref:b,"data-kpi-area":"comparison",children:O.jsxs(Jh,{$compact:Q,children:[O.jsxs(ef,{theme:m,$color:t,$scale:s,style:U,children:[w,P]}),R&&O.jsx(tf,{theme:m,$onColor:c,children:R})]})}):e.type==="value"?O.jsx(Qh,{ref:b,"data-kpi-area":"comparison",children:O.jsxs(Jh,{$compact:Q,children:[O.jsx(ef,{theme:m,$color:t,$scale:s,style:U,children:k}),_&&O.jsx(tf,{theme:m,$onColor:c,children:_})]})}):O.jsx(Qh,{ref:b,"data-kpi-area":"comparison",children:O.jsxs(Jh,{$compact:Q,children:[O.jsxs(ef,{theme:m,$color:t,$scale:s,style:U,children:[w,$&&O.jsx(sZ,{"aria-hidden":"true",children:Y}),T]}),_&&O.jsx(tf,{theme:m,$onColor:c,children:_})]})})}const xZ=85/255,TZ=0,Go={enabled:!1,radius:0,states:{hover:{enabled:!1},select:{enabled:!1}}};function SZ(e,t,r,n={},i){const{numberFormatConfig:a,formatDate:o}=n,s=E.getCompleteNumberFormatConfig(a);return{chart:D({type:t,margin:[4,0,4,0],spacing:[0,0,0,0],backgroundColor:"transparent",animation:!1},i&&{width:i.width,height:i.height}),title:{text:void 0},subtitle:{text:void 0},credits:{enabled:!1},exporting:{enabled:!1},xAxis:{visible:!1,labels:{enabled:!1}},yAxis:{visible:!1,labels:{enabled:!1}},legend:{enabled:!1},tooltip:{enabled:!0,outside:!0,formatter(){const u=typeof this.x=="number"?this.x:void 0,c=u!==void 0&&o?o(u):void 0,d=typeof this.y=="number"?E.applyFormat(s,this.y):"";return c?`${c}: ${d}`:d}},plotOptions:{series:{animation:!1,dataLabels:{enabled:!1},enableMouseTracking:!0,states:{hover:{enabled:!0}},marker:Go},area:{fillOpacity:.25,lineWidth:1.5,marker:Go},line:{lineWidth:1.5,marker:Go},spline:{lineWidth:1.5,marker:Go},column:{borderWidth:0,pointPadding:.05,groupPadding:.05}},series:[D({type:t,name:"",showInLegend:!1,data:e,color:r,marker:Go},t==="area"?{fillColor:{linearGradient:{x1:0,y1:0,x2:0,y2:1},stops:[[0,E.applyOpacity(r,xZ)],[1,E.applyOpacity(r,TZ)]]}}:{})]}}const rf={width:0,height:0};function Wy(e,t){return e.width===t.width&&e.height===t.height}function wa(e){const[t,r]=N.useState(rf),n=N.useRef({element:null,ro:null,cancelled:!1});return N.useLayoutEffect(()=>{var u;const i=e.current,a=n.current;if(i===a.element&&(!i||!a.cancelled))return;if(a.cancelled=!0,(u=a.ro)==null||u.disconnect(),a.ro=null,a.element=i,!i){r(c=>Wy(c,rf)?c:rf);return}a.cancelled=!1;const o=()=>{if(a.cancelled)return;const{width:c,height:d}=i.getBoundingClientRect(),h={width:c,height:d};r(p=>Wy(p,h)?p:h)};o();const s=new ResizeObserver(o);s.observe(i),a.ro=s}),N.useEffect(()=>()=>{var i;n.current.cancelled=!0,(i=n.current.ro)==null||i.disconnect()},[]),t}function MZ({points:e,chartType:t,color:r,numberFormatConfig:n}){const i=Jc(),a=N.useRef(null),{width:o,height:s}=wa(a),u=N.useMemo(()=>SZ(e,t,r,{numberFormatConfig:n,formatDate:c=>i(new Date(c),"MMM d, yyyy")},o>0&&s>0?{width:o,height:s}:void 0),[e,t,r,n,i,o,s]);return O.jsx(nZ,{ref:a,"data-kpi-area":"sparkline","aria-hidden":"true",children:O.jsx(xx,{highcharts:E.Highcharts,options:u,containerProps:{style:{width:"100%",height:"100%"}}})})}function PZ({title:e,enabled:t,period:r,onColor:n,areaRef:i}){const{themeSettings:a}=y.useThemeContext();return!t&&!r?null:O.jsxs(eZ,{ref:i,"data-kpi-area":"title",children:[t&&O.jsx(iZ,{theme:a,$onColor:n,children:e}),r&&O.jsx(aZ,{theme:a,$onColor:n,children:r})]})}const EZ=.179;function AZ(e){if(!e)return;const t=/^#([0-9a-f]{3}|[0-9a-f]{4}|[0-9a-f]{6}|[0-9a-f]{8})$/i.exec(e.trim());if(!t)return;const r=t[1];if(r.length===3||r.length===4){const n=r.split("").map(i=>parseInt(i+i,16));return{r:n[0],g:n[1],b:n[2],a:r.length===4?n[3]/255:1}}return{r:parseInt(r.slice(0,2),16),g:parseInt(r.slice(2,4),16),b:parseInt(r.slice(4,6),16),a:r.length===8?parseInt(r.slice(6,8),16)/255:1}}function nf(e){const t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Vp(e){const t=AZ(e);if(!t||t.a<.5)return;const r=nf(t.r),n=nf(t.g),i=nf(t.b);return .2126*r+.7152*n+.0722*i}function RZ(e){const t=Vp(e);return t!==void 0&&t<EZ}const DZ=3;function af(e,t){const r=Vp(e),n=Vp(t);if(r===void 0||n===void 0)return;const[i,a]=r>=n?[r,n]:[n,r];return(i+.05)/(a+.05)}function NZ(e){var s,u;const{accent:t,textColor:r,backgroundColor:n}=e,i=af(t,n);if(i===void 0||i>=DZ)return t;const a=(s=af(r,n))!=null?s:0,o=(u=af("#ffffff",n))!=null?u:0;return a>=o?r:"#ffffff"}const of=["xs","sm","md","lg"],kZ=[200,320,520],LZ=[120,180,280];function jy(e,t){return e<t[0]?"xs":e<t[1]?"sm":e<t[2]?"md":"lg"}function OZ(e,t){const r=jy(e,kZ),n=jy(t,LZ);return of[Math.min(of.indexOf(r),of.indexOf(n))]}const IZ="#7b68ee",FZ=({chartData:e,designOptions:t,onDataPointClick:r,onDataPointContextMenu:n,onBeforeRender:i})=>{var jt,pt,St,Ft,Qt,bt;const{t:a}=O.useTranslation(),{themeSettings:o}=y.useThemeContext(),s=Jc(),u=N.useRef(null),c=wa(u),d=OZ(c.width,c.height),h=N.useRef(null),p=N.useRef(null),m=N.useRef(null),g=N.useRef(null),b=wa(h),_=wa(p),w=wa(m),C=wa(g),S=r,T=n,M=i,P=N.useMemo(()=>{const Jt=ZX(e,a);return M?M(Jt):Jt},[e,M,a]),R=N.useMemo(()=>P.comparison?KX(e.comparison,P.comparison):void 0,[e.comparison,P.comparison]),k=N.useCallback(Jt=>{S==null||S(Fy(P),Jt.nativeEvent)},[S,P]),I=N.useCallback(Jt=>{T==null||T(Fy(P),Jt.nativeEvent)},[T,P]),{value:$,valueTitle:G,valueColor:Y,valuePeriodMs:B,sparklinePoints:X}=P,U=t.value.noDataText;if((!e.hasRows||$===void 0)&&!U)return O.jsx(Ac,{iconType:"kpi"});const W=RZ(t.card.backgroundColor),q=$!==void 0?ja($,e.numberFormatConfig):U!=null?U:"",ee=Oy(t.value.conditionalIcons,$),Z=(jt=t.title.text)!=null?jt:G,J=B!==void 0&&!isNaN(B)?s(new Date(B),"MMM yyyy"):void 0,ne=NZ({accent:(Ft=(St=(pt=o.palette)==null?void 0:pt.variantColors)==null?void 0:St[0])!=null?Ft:IZ,textColor:(bt=(Qt=o.chart)==null?void 0:Qt.textColor)!=null?bt:"#5b6372",backgroundColor:t.card.backgroundColor}),oe=R?R.type==="value"?R.color:$X(t.comparison.color,Iy(R)):void 0,ae=R&&R.type!=="value"?Oy(t.comparison.conditionalIcons,Iy(R)):void 0,se=(R==null?void 0:R.type)==="value"?R.numberFormatConfig:e.numberFormatConfig,ue=R?QX(R,se,t.comparison.display):void 0,me=ue?`${Z}, ${q}, ${ue}`:`${Z}, ${q}`,pe=!!S||!!T,Ce=d!=="xs"&&t.sparkline.enabled&&!!(X!=null&&X.length),ke=d==="xs"||d==="sm",we=t.layout==="big-comparison"&&!!R,le=we?"compact":"headline",He=we?"headline":"compact",Te=we?w.height:C.height,Ae=R?D3:0,$e=t.card.showBorder?2*O3:0,Ge=Ce?c.height-$e-N3-k3-_.height-2*L3-I3:b.height,qe=VX(Ge,Te,Ae);return O.jsx(cZ,{ref:u,bodyRef:h,layout:t.layout,tier:d,ariaLabel:me,card:t.card,clickable:pe,onClick:pe?k:void 0,onContextMenu:T?I:void 0,title:O.jsx(PZ,{title:Z,enabled:t.title.enabled,period:J,onColor:W,areaRef:p}),value:O.jsx(wZ,{text:q,color:Y,textSize:t.value.textSize,icon:ee,onColor:W,scale:le,maxHeightPx:le==="headline"?qe:void 0,areaRef:m}),comparison:R&&O.jsx(CZ,{comparison:R,color:oe,numberFormatConfig:se,display:t.comparison.display,showIcon:t.comparison.showIcon,conditionalIcon:ae,labelOverride:t.comparison.label,scale:He,compact:ke,onColor:W,maxHeightPx:He==="headline"?qe:void 0,areaRef:g}),sparkline:Ce&&X?O.jsx(MZ,{points:X,chartType:t.sparkline.chartType,color:ne,numberFormatConfig:e.numberFormatConfig}):void 0})};function $Z(e){return"sparkline"in e&&typeof e.sparkline=="object"&&e.sparkline!==null&&"chartType"in e.sparkline}const BZ=e=>!!e.chartData&&A3(e.chartData)&&S3(e.dataOptions)&&$Z(e.designOptions),zZ={dataOptions:{translateDataOptionsToInternal:SX,getAttributes:MX,getMeasures:PX,isCorrectDataOptions:EX,isCorrectDataOptionsInternal:S3},data:{loadData:LX,getChartData:zX},designOptions:{translateStyleOptionsToDesignOptions:HX,isCorrectStyleOptions:WX,getDefaultStyleOptions:jX},renderer:{ChartRendererComponent:FZ,isCorrectRendererProps:BZ}},HZ={areamap:Oj,area:_q,column:Oq,bar:Aq,line:qG,polar:tq,streamgraph:Zq,pie:CY,funnel:dY,treemap:rX,sunburst:XY,"calendar-heatmap":hU,sankey:xX,kpi:zZ};function mo(e){const t=HZ[e];if(t)return t;throw new Error(`Unsupported chart type: ${e}`)}function WZ(e,t){return H.isCartesian(t)?e.value.some(n=>(n==null?void 0:n.forecast)!==void 0||(n==null?void 0:n.trend)!==void 0):!1}function go(e){return["areamap","area","column","bar","line","polar","pie","funnel","calendar-heatmap","kpi","treemap","sunburst","streamgraph","sankey"].includes(e)}function jZ(e){let t;switch(e.subtype){case"indicator/numeric":t=D({indicatorType:"numeric",numericSubtype:e.numericSubtype},e.numericSubtype==="numericSimple"?{skin:e.skin}:null);break;case"indicator/gauge":t=D({indicatorType:"gauge",skin:e.skin},e.tickerBarHeight?{tickerBarHeight:e.tickerBarHeight}:null);break}return z(D(D({},Kt),t),{indicatorComponents:e.indicatorComponents||Kt.indicatorComponents,forceTickerView:!!e.forceTickerView})}const VZ=(e,t,r)=>{const n="y"in r&&Array.isArray(r.y)?r.y.some(s=>s.showOnRightAxis):!1;let i;switch(e){case"area":i=gG(t,r,n);break;case"arearange":case"line":i=mG(t,r,n);break;case"pie":i=bG(t);break;case"funnel":i=_G(t);break;case"treemap":i=Qx(t);break;case"sunburst":i=Jx(t);break;case"polar":i=CG(t,r);break;case"indicator":i=jZ(t);break;case"scatter":i=TG(t);break;case"boxplot":i=SG(t);break;case"scattermap":i=PG(t);break;default:throw new V.TranslatableError("errors.chartTypeNotSupported",{chartType:e})}const a="subtype"in t&&t.subtype?t.subtype:"line/basic",o=td[a];return D(D({},i),o)};function UZ(e,t,r){var n,i,a,o,s,u,c;if(go(e)){const d=mo(e),h=mn((o=(a=(i=(n=d.designOptions).translateLegacyStyleOptionsToModern)==null?void 0:i.call(n,r))!=null?a:r)!=null?o:{},(c=(u=(s=d.designOptions).getDefaultStyleOptions)==null?void 0:u.call(s))!=null?c:E.getDefaultStyleOptions());if(!d.designOptions.isCorrectStyleOptions(h))throw new V.TranslatableError("errors.optionsTranslation.invalidStyleOptions",{chartType:e});if(!d.dataOptions.isCorrectDataOptionsInternal(t))throw new V.TranslatableError("errors.optionsTranslation.invalidInternalDataOptions",{chartType:e});return d.designOptions.translateStyleOptionsToDesignOptions(h,t)}else{const d=mn(r!=null?r:{},E.getDefaultStyleOptions());return VZ(e,d,t)}}function mn(e,t){return E.merge.withOptions({mergeArrays:!1},t,e)}function si(e,t,r){return GZ(e).map(i=>{const a=i.seriesId,o=i.seriesStyleOptions,s=pG(t,mn(o,r));return{seriesId:a,designOptions:kA(s,["line","marker"])}}).reduce((i,{seriesId:a,designOptions:o})=>z(D({},i),{[a]:o}),{})}function GZ(e){return e.y.filter(qZ).map(({column:{name:t},seriesStyleOptions:r})=>({seriesId:t,seriesStyleOptions:r}))}function qZ(e){return e.seriesStyleOptions!==void 0}const YZ=2e4;function qo(e,t){if(e&&t){const r=t.column.name,n=e.findIndex(i=>i.name===r);return n===-1?null:n}return null}const W3=(e,t,r)=>{if(!e)return{columns:[],rows:[]};let n=0,i=4,a=5,o=0,s=1;if(r&&(n=qo(e.columns,r.category),i=qo(e.columns,r.whiskerMin),a=qo(e.columns,r.whiskerMax),o=qo(t.columns,r.category),s=qo(t.columns,r.outliers)),Lu(s))return e;const u=s;return{columns:[...e.columns,t.columns[u]],rows:e.rows.map(d=>{const h=Lu(n)?null:d[n].data,p=d[a].data,m=d[i].data,g=t.rows.filter(b=>{const _=Lu(o)?null:b[o].data,w=b[u].data;return _===h&&(w<m||w>p)}).map(b=>b[u].data).join(",");return[...d,{data:g}]})}};function XZ(e,t,r){const n=r&&h3(r);return W3(e,t,n)}const ZZ=(c,d)=>ht(exports,[c,d],function*({app:e,chartDataOptions:t,dataSource:r,attributes:n,measures:i,filters:a,filterRelations:o,highlights:s},u){var b;const h={dataSource:r,dimensions:t.category?[n[0]]:[],measures:i,filters:a,filterRelations:o,highlights:s},p=yield u(h,e);let m=p;const g=t.outliersCount?KZ(p,t.outliersCount.column.name):0;if(t.outliers&&g<YZ){const _={dataSource:r,dimensions:n,measures:[],filters:a,filterRelations:o,highlights:s};try{const w=yield u(_,e);m=W3(p,w,t)}catch(w){if((b=w==null?void 0:w.message)!=null&&b.includes("UnsupportedFunctionalityException"))console.warn("Functionality not supported by platform: Boxplot outliers");else throw w}}return m}),KZ=(e,t)=>{if(!(e!=null&&e.columns))return 0;const r=e.columns.findIndex(({name:i})=>i===t);let n=0;return e.rows.forEach(i=>{n+=parseInt(i[r].data)}),n};function QZ(e,t){return go(e)&&!t?mo(e).data.loadData:e==="boxplot"?eK:JZ}const JZ=n=>ht(exports,[n],function*({app:e,queryDescription:t,executionConfig:r}){var o,s;return(((s=(o=e==null?void 0:e.settings.queryCacheConfig)==null?void 0:o.enabled)!=null?s:!1)?V.executeQueryWithCache:V.executeQuery)(t,e,r)}),eK=n=>ht(exports,[n],function*({app:e,chartDataOptionsInternal:t,queryDescription:r}){var o,s,u,c;const a=((s=(o=e==null?void 0:e.settings.queryCacheConfig)==null?void 0:o.enabled)!=null?s:!1)?V.executeQueryWithCache:V.executeQuery;return ZZ({app:e,chartDataOptions:t,dataSource:r.dataSource,attributes:(u=r.dimensions)!=null?u:[],measures:(c=r.measures)!=null?c:[],filters:r.filters,highlights:r.highlights,filterRelations:r.filterRelations},a)}),tK=e=>({type:"boxplot",xValues:[],series:[{name:e,title:e,data:[]}]}),rK=(e,t)=>{const{valueTitle:r}=e,n=e.boxMin&&E.getColumnByName(t,e.boxMin.column.name),i=e.boxMedian&&E.getColumnByName(t,e.boxMedian.column.name),a=e.boxMax&&E.getColumnByName(t,e.boxMax.column.name),o=e.whiskerMin&&E.getColumnByName(t,e.whiskerMin.column.name),s=e.whiskerMax&&E.getColumnByName(t,e.whiskerMax.column.name);if(!n||!i||!a||!o||!s)return tK(r);const u=e.category&&E.getColumnByName(t,e.category.column.name);u&&(u.direction=E.sortDirection(e.category.sortType));const c=E.getOrderedXValues(t,[],u?[u]:[],(u==null?void 0:u.direction)===0?E.rownumColumnName:void 0),d=E.getIndexedRows(t.rows,u?[u]:[]),h=e.outliers&&E.getColumnByName(t,e.outliers.column.name),p=[],m=[];c.forEach((b,_)=>{const w=d[b.key],C=w?w[0]:[],S=u&&!!E.isBlurred(C,u);p.push({q1:n?E.getValue(C,n):0,median:i?E.getValue(C,i):0,q3:a?E.getValue(C,a):0,low:o?E.getValue(C,o):0,high:s?E.getValue(C,s):0,blur:S});const T=h?C[h.index].rawValue.split(",").map(M=>parseFloat(M)):[];m.push(...T.map(M=>({x:_,y:M,blur:S})))});const g=[{name:e.valueTitle,title:e.valueTitle,data:p}];return m.length>0&&g.push({name:e.valueTitle,title:e.valueTitle,data:m}),{type:"boxplot",xValues:c,series:g}};function nK(e){return e.type==="boxplot"}const uu=(e,t)=>{if(!t||t.length!==1)return[void 0,void 0];const r=E.getColumnByName(e,t[0].column.name);return r?[E.getValue(e.rows[0],r),t[0].column.name]:[void 0,void 0]},iK=(e,t)=>{var s;const r={type:"indicator"};if(!((s=e.value)!=null&&s.length)||t.rows.length===0)return r;const[n]=uu(t,e.value);if(n===void 0)return r;const[i]=uu(t,e.secondary),[a]=uu(t,e.min),[o]=uu(t,e.max);return{type:"indicator",value:n,secondary:i,min:a,max:o}};function j3(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:V.baseSlice(e,t,r)}function aK(e,t){for(var r=e.length;r--&&$0(t,e[r],0)>-1;);return r}function oK(e,t){for(var r=-1,n=e.length;++r<n&&$0(t,e[r],0)>-1;);return r}function sK(e){return e.split("")}var lK="\\ud800-\\udfff",uK="\\u0300-\\u036f",cK="\\ufe20-\\ufe2f",dK="\\u20d0-\\u20ff",hK=uK+cK+dK,fK="\\ufe0e\\ufe0f",pK="\\u200d",mK=RegExp("["+pK+lK+hK+fK+"]");function V3(e){return mK.test(e)}var U3="\\ud800-\\udfff",gK="\\u0300-\\u036f",vK="\\ufe20-\\ufe2f",yK="\\u20d0-\\u20ff",bK=gK+vK+yK,_K="\\ufe0e\\ufe0f",wK="["+U3+"]",Up="["+bK+"]",Gp="\\ud83c[\\udffb-\\udfff]",CK="(?:"+Up+"|"+Gp+")",G3="[^"+U3+"]",q3="(?:\\ud83c[\\udde6-\\uddff]){2}",Y3="[\\ud800-\\udbff][\\udc00-\\udfff]",xK="\\u200d",X3=CK+"?",Z3="["+_K+"]?",TK="(?:"+xK+"(?:"+[G3,q3,Y3].join("|")+")"+Z3+X3+")*",SK=Z3+X3+TK,MK="(?:"+[G3+Up+"?",Up,q3,Y3,wK].join("|")+")",PK=RegExp(Gp+"(?="+Gp+")|"+MK+SK,"g");function EK(e){return e.match(PK)||[]}function qp(e){return V3(e)?EK(e):sK(e)}function AK(e,t,r){if(e=V.toString(e),e&&(r||t===void 0))return E.baseTrim(e);if(!e||!(t=V.baseToString(t)))return e;var n=qp(e),i=qp(t),a=oK(n,i),o=aK(n,i)+1;return j3(n,a,o).join("")}const K3=",";function RK(e){return e.join(`${K3} `)}function DK(e){return e.split(K3).map(AK)}function NK(e){switch(e){case"city":return"city";case"state":return"adm";case"country":return"country"}}function kK(e,t){const{name:r,rawName:n,coordinates:i,value:a,colorValue:o,details:s}=e,c={geo:t.locations.map((d,h)=>z(D({},Fe(d)),{value:n[h]}))};if(t.size&&(c.size=z(D({},Fe(t.size)),{value:a})),t.colorBy&&(c.colorBy=z(D({},Fe(t.colorBy)),{value:o})),t.details){const d=Fe(t.details);d.measure&&(c.details=z(D({},d),{value:s}))}return{categories:n,displayName:r,coordinates:{lat:i.lat,lng:i.lng},value:a,entries:c}}const LK=1,OK=(e,t)=>{const r=IK(e),n=e.locations&&E.getColumnsByName(t,e.locations.map(({column:{name:u}})=>u)),i=e.size&&E.getColumnByName(t,e.size.column.name),a=e.colorBy&&E.getColumnByName(t,e.colorBy.column.name),o=e.details&&E.getColumnByName(t,e.details.column.name);return{type:"scattermap",locations:t.rows.filter(u=>n.some(c=>E.getValue(u,c)!==O.NOT_AVAILABLE_DATA_VALUE)).map(u=>{const c=n.map(m=>E.getValue(u,m)),d=RK(c);let h;r&&(h={lat:E.getValue(u,n[0]),lng:E.getValue(u,n[1])});const p=n[0]&&!!E.isBlurred(u,n[0]);return D(z(D(D({name:d,rawName:c,value:i?E.getValue(u,i):LK},a&&{colorValue:E.getValue(u,a)}),o&&{details:E.getValue(u,o)}),{blur:p}),h?{coordinates:h}:null)})}};function IK(e){return e.locations.length===2&&e.locations.filter(({column:{type:t}})=>V.isNumber(t)).length===2}const FK=(e,t,r,n=!0)=>{if(H.isCartesian(e))return E.isForecastChart(t)?E.advancedAnalyticsData(t,r):E.cartesianData(t,r,n);if(H.isCategorical(e))return ld(t,r,n);if(H.isScatter(e))return E.scatterData(t,r,n);if(H.isScattermap(e))return OK(t,r);if(H.isIndicator(e))return iK(t,r);if(H.isBoxplot(e))return rK(t,r);if(H.isRange(e))return E.rangeData(t,r);throw new V.TranslatableError("errors.unexpectedChartType",{chartType:e})};var $K=1/0,BK=V.Set&&1/V.setToArray(new V.Set([,-0]))[1]==$K?function(e){return new V.Set(e)}:O.noop,zK=200;function G0(e,t,r){var n=-1,i=Gx,a=e.length,o=!0,s=[],u=s;if(a>=zK){var c=t?null:BK(e);if(c)return V.setToArray(c);o=!1,i=V.cacheHas,u=new V.SetCache}else u=t?[]:s;e:for(;++n<a;){var d=e[n],h=t?t(d):d;if(d=d!==0?d:0,o&&h===h){for(var p=u.length;p--;)if(u[p]===h)continue e;t&&u.push(h),s.push(d)}else i(u,h,r)||(u!==s&&u.push(h),s.push(d))}return s}var HK=V.baseRest(function(e){return G0(V.baseFlatten(e,1,V.isArrayLikeObject,!0))});const Q3=(e,t,r,n={})=>{if(E.emptyTable(e))return{rows:[],columns:[]};const i=HK(E.getColumnsByName(e,t.map(d=>d.name))),a=e,s=[...r.map(d=>{var h,p;return{column:(h=n[d.name])!=null?h:d.name,title:d.name,agg:(p=d.aggregation)!=null?p:"sum"}}),{column:E.rownumColumnName,title:E.rownumColumnName,agg:"min"}],u=E.groupBy(a,i,s),c=E.getColumnByName(u,E.rownumColumnName);if(!c)throw new V.TranslatableError("errors.noRowNumColumn",{columnName:E.rownumColumnName});return E.orderBy(u,[c])};function WK({dataSet:e,data:t,chartDataOptions:r,chartType:n,isForecastOrTrendChart:i,attributes:a,measures:o,dataColumnNamesMapping:s,onDataReady:u}){var h,p,m,g;const{app:c}=y.useSisenseContext(),d=(g=(m=(p=(h=c==null?void 0:c.settings)==null?void 0:h.chartConfig)==null?void 0:p.defaultNumberFormatting)==null?void 0:m.enabled)!=null?g:!0;return N.useMemo(()=>{if(!t||!r)return null;let b;if(u&&(b=u(t),!cT(b)))throw new V.TranslatableError("errors.incorrectOnDataReadyHandler");const _=b||t;let w=E.createDataTableFromData(_);return H.isDataSource(e)||(w=Q3(w,a,o,s)),jK(n,r,w,i,d)},[t,n,i,d])}function jK(e,t,r,n=!1,i=!0){if(go(e)&&!n){const a=mo(e);if(a.dataOptions.isCorrectDataOptionsInternal(t))return a.data.getChartData(t,r,{defaultNumberFormattingEnabled:i});throw new Error("Incorrect internal data options for restructured chart")}return FK(e,t,r,i)}function J3(e,t){const r=N.useRef(t);r.current=t;const n=N.useRef(!1);N.useEffect(()=>{var i;e&&!n.current&&((i=r.current)==null||i.call(r)),n.current=e},[e])}function VK({chartType:e,isLoading:t,hasNoDimensions:r,chartData:n,onReady:i}){const a=go(e)?mo(e).onReady:void 0,[o,s]=N.useState(!1);N.useEffect(()=>{a&&t&&s(!1)},[a,t]);const u=N.useCallback(()=>{s(!0)},[]),c=a?a.isReadyForOnReady({isLoading:t,rendererPainted:o,hasNoDimensions:r,chartData:n}):!1;return J3(c,a?i:void 0),{onRendererReady:a?u:void 0}}function UK(e){const{dataSet:t,chartType:r,chartData:n,internalDataOptions:i,designOptions:a,onBeforeRender:o,onDataPointClick:s,onDataPointContextMenu:u,onDataPointsSelected:c,onReady:d}=e;return N.useMemo(()=>!i||!a?null:{dataSource:H.isDataSource(t)?t:null,chartType:r,chartData:n,dataOptions:i,designOptions:a,onBeforeRender:o,onDataPointClick:s,onDataPointContextMenu:u,onDataPointsSelected:c,onReady:d},[t,r,n,i,a,o,s,u,c,d])}const q0=()=>{const[e,t]=N.useState();if(e)throw e;return t};function Yp(e,t,r=il(),n=al){const i=new Map;return[...t.breakBy?t.breakBy:[],...t.x?Array.isArray(t.x)?t.x:[t.x]:[],...t.columns?t.columns:[]].forEach(function(o){if(E.isMeasureColumn(o)||!o.dateFormat||!(e!=null&&e.columns))return;const s=e.columns.findIndex(function(c){return c.name===o.column.name&&V.isDatetime(o.column.type)&&V.isDatetime(c.type)});s!==-1&&i.set(s,o.dateFormat)}),i.size===0||(e.rows=e.rows.map(function(o){return o.map(function(u,c){const d=i.get(c);if(!d||u===O.NOT_AVAILABLE_DATA_VALUE)return u;let h,p;if(E.isCell(u)){if(u.data===O.NOT_AVAILABLE_DATA_VALUE)return u;h=D({},u)}else{const g=E.createCompareValue(`${u}`,"datetime");p=new Date(g.value),h={data:p.toISOString(),text:`${u}`}}if(!h.data)return u;let m=h.text;try{m=ol(h.data,d,r,n)}catch(g){console.error(g)}return h.text=m,h})})),e}const GK=e=>e==="funnel"?e:E.deriveChartFamily(e),qK=({dataSet:e,chartDataOptions:t,chartType:r,attributes:n,measures:i,dataColumnNamesMapping:a,filters:o,highlights:s,refreshCounter:u,enabled:c=!0,loadData:d})=>{const h=q0(),[p,m]=N.useState(!1),g=N.useMemo(()=>GK(r),[r]),b=N.useMemo(()=>[void 0,t],[t]),[_,w]=N.useState({}),{app:C}=y.useSisenseContext();N.useEffect(()=>{if(!c)return;let M=!1;const{filters:P,relations:R}=V.getFilterListAndRelationsJaql(o);if(H.isDataSource(e)){if(!C)return;m(!0),d({app:C,chartDataOptionsInternal:t,queryDescription:{dataSource:e,dimensions:n,measures:i,filters:P,filterRelations:R,highlights:s,count:C.settings.queryLimit}}).then(I=>{const $=Yp(I,t,C==null?void 0:C.settings.locale,C==null?void 0:C.settings.dateConfig);M||w({[g]:[$,t]})}).catch(I=>{h(I)}).finally(()=>{m(!1)})}else{g3(e,n,i,a,P,s);const k=Yp(e,t,C==null?void 0:C.settings.locale,C==null?void 0:C.settings.dateConfig);w({[g]:[k,t]})}return()=>{M=!0}},[r,t,e,o,s,C,u,c]);const[S,T]=_[g]||b;return{isLoading:p,data:S,dataOptions:T}};function eT(e,t){{const r=v3(t,e),n=y3(t,r),i=m3(n,t),a=WY(i,t),o=jY(i,t);return{dataOptions:i,attributes:a,measures:o}}}const YK=(e,t,r)=>N.useMemo(()=>Y0(e,t,{isForecastOrTrendChart:r,shouldHaveUniqueDataColumnNames:!0}),[e,t,r]);function Y0(e,t,r){if(go(t)&&!(r!=null&&r.isForecastOrTrendChart)){const n=mo(t);if(!n.dataOptions.isCorrectDataOptions(e))throw new Error("Incorrect data options");return XK(n,e,r)}else return ZK(e,t,r)}function XK(e,t,r){const n=e.dataOptions.translateDataOptionsToInternal(t),i=e.dataOptions.getAttributes(n),a=e.dataOptions.getMeasures(n),o=r!=null&&r.shouldHaveUniqueDataColumnNames?p3(a):{};return{dataOptions:n,attributes:i,measures:a,dataColumnNamesMapping:o}}function ZK(e,t,r){const{dataOptions:n,attributes:i,measures:a}=eT(e,t),o=r!=null&&r.shouldHaveUniqueDataColumnNames?p3(a):{};return{dataOptions:n,attributes:i,measures:a,dataColumnNamesMapping:o}}const Vy={fontFamily:"opensansregular, sans-serif",title:{color:"rgb(68, 81, 102)",fontSizes:{big:22,medium:18,small:15,micro:12}},value:{color:"rgb(0,206,230)",fontSizes:{big:66,medium:46,small:32,micro:23}},secondaryTitle:{color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},secondaryValue:{fontWeight:800,color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},textKeys:["title","value","secondaryTitle","secondaryValue"],backgroundColor:"rgb(255, 255, 255)",borderColor:"rgb(215, 215, 215)",borderWidth:1,relativeSizes:[{key:"titleSectionHeight",value:.5,decimals:0},{key:"titleSectionMarginTop",value:.13,decimals:0},{key:"titleSectionMinWidth",value:.29,decimals:0},{key:"numericMinWidth",value:4.69,decimals:0},{key:"valueSectionHeight",value:1,decimals:0},{key:"valueSectionMarginRight",value:.14,decimals:0},{key:"valueSectionMarginBottom",value:.07,decimals:0},{key:"secSectionHeight",value:.34,decimals:0},{key:"secSectionMarginTop",value:.14,decimals:0},{key:"secDividerWidth",value:.14,decimals:0},{key:"secTitleMinWidth",value:.29,decimals:0},{key:"indicatorHorizontalMargin",value:.31,decimals:0},{key:"indicatorVerticalMargin",value:.46,decimals:0}],measureKeys:["indicatorMargin","numericMinWidth","titleSectionHeight","secSectionHeight","valueSectionMarginBottom","secSectionMarginTop","indicatorHorizontalMargin","indicatorVerticalMargin"],sizes:[{size:"big",value:70},{size:"medium",value:49},{size:"small",value:34},{size:"micro",value:24}],fitMeasures:[{key:"fitTitleMeasure",prop:"string",dataKey:"title"},{key:"fitValueMeasure",prop:"string",dataKey:"value"},{key:"fitSecondaryMeasure",prop:"titleString",dataKey:"secondaryTitle"},{key:"fitSecondaryMeasure",prop:"valueString",dataKey:"secondary"}]},KK={fontFamily:"opensansregular, sans-serif",title:{color:"rgb(68, 81, 102)",fontSizes:{big:22,medium:18,small:15,micro:12}},value:{color:"rgb(255, 255, 255)",fontSizes:{big:45,medium:31,small:22,micro:15}},secondaryTitle:{color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},secondaryValue:{fontWeight:800,color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},textKeys:["title","value","secondaryTitle","secondaryValue"],backgroundColor:"rgb(255, 255, 255)",bracketColor:"rgb(198, 198, 198)",bracketThickness:1,relativeSizes:[{key:"titleSectionHeight",value:1,decimals:0},{key:"titleHorizontalMargin",value:.16,decimals:0},{key:"numericMinWidth",value:4.69,decimals:0},{key:"valueSectionHeight",value:1,decimals:0},{key:"secSectionHeight",value:1,decimals:0},{key:"secBottomMargin",value:.14,decimals:0},{key:"secDividerWidth",value:.14,decimals:0},{key:"secTitleMinWidth",value:.29,decimals:0},{key:"bracketWidth",value:.21,decimals:0},{key:"indicatorMargin",value:.64,decimals:0}],measureKeys:["indicatorMargin","numericMinWidth","bracketWidth","titleSectionHeight","secSectionHeight"],sizes:[{size:"big",value:70,maxWidth:1261,maxHeight:665},{size:"medium",value:49},{size:"small",value:34},{size:"micro",value:24}]},QK={fontFamily:"opensansregular, sans-serif",title:{color:"rgb(68, 81, 102)",fontSizes:{big:22,medium:18,small:15,micro:12}},value:{color:"rgb(255, 255, 255)",fontSizes:{big:45,medium:31,small:22,micro:15}},secondaryTitle:{color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},secondaryValue:{fontWeight:800,color:"rgb(163, 163, 163)",fontSizes:{big:20,medium:14,small:10,micro:10}},label:{color:"rgb(68, 81, 102)",fontSizes:{big:18,medium:13,small:9,micro:9}},textKeys:["title","value","secondaryTitle","secondaryValue","label"],backgroundColor:"rgb(255, 255, 255)",tickColor:"rgb(0, 0, 0)",needleColor:"rgb(43, 51, 66)",bracketColor:"rgb(198, 198, 198)",defaultDialColor:"rgb(179, 179, 179)",gaugeOpacity:.5,startAngle:20,endAngle:160,overDegrees:5,tickDegreesIncrement:10,bracketThickness:1,relativeSizes:[{key:"titleSectionHeight",value:.26,decimals:0},{key:"titleHorizontalMargin",value:.08,decimals:0},{key:"titleBottomMargin",value:.1,decimals:0},{key:"gaugeWidth",value:1.33,decimals:0},{key:"gaugeBottomMargin",value:.19,decimals:0},{key:"outerArcRadius",value:.63,decimals:0},{key:"innerArcRadius",dataKey:"skin",values:{1:.24,2:.51},decimals:0},{key:"lengthToTick",value:.7,decimals:0},{key:"tickRadius",value:.01,decimals:1},{key:"needleLength",dataKey:"skin",values:{1:.52,2:.58},decimals:0},{key:"needleBaseRadius",value:.04,decimals:0},{key:"labelMargin",value:.26,decimals:0},{key:"valueSectionHeight",value:.36,decimals:0},{key:"secSectionHeight",value:.36,decimals:0},{key:"secBottomMargin",value:.05,decimals:0},{key:"secDividerWidth",value:.05,decimals:0},{key:"secTitleMinWidth",value:.1,decimals:0},{key:"bracketWidth",value:.08,decimals:0},{key:"indicatorMargin",value:.14,decimals:0}],gaugeHeights:[{size:"big",value:192,maxWidth:1297,maxHeight:1075},{size:"medium",value:134},{size:"small",value:94},{size:"micro",value:66}],measureKeys:["indicatorMargin","gaugeWidth","bracketWidth","titleSectionHeight","valueSectionHeight","secSectionHeight"]},JK={fontFamily:"Open Sans",fontSize:15,title:{color:"rgb(68, 81, 102)"},value:{fontWeight:800},secondaryTitle:{color:"rgb(163, 163, 163)"},secondaryValue:{color:"rgb(163, 163, 163)"},textKeys:["title","value","secondaryTitle","secondaryValue"],backgroundColor:"transparent",dividerColor:"rgb(39, 42, 52)",barHandleColor:"rgb(43, 51, 66)",height:35,horizontalMargin:15,barWidth:100,barHeight:11,barOpacity:.5,tickerBarWidth:2,tickerBarHeight:13,horizontalPadding:9,textPadding:6,sectionMinWidth:20,dividerWidth:1,dividerHeight:13,forceTickerView:!1};function eQ(e,t){const r=V.cloneDeep(JK);if(r.forceTickerView=t.forceTickerView,r.fontFamily=t.fontFamily,r.backgroundColor=t.backgroundColor,r.value.color=t.value.color,r.title.color=t.title.color,r.secondaryTitle.color=t.secondaryTitle.color,r.secondaryValue.color=t.secondaryTitle.color,t.tickerBarHeight){const n=t.tickerBarHeight;r.barHeight=n,r.tickerBarHeight=n+2}return r.forceTickerView&&(r.height=e.offsetHeight),r}class cl{degToRad(t){return t*Math.PI/180}getFitStringMeasure(t,r,n,i){t.font=i;let a=this.getStringWidth(t,r);const o="…",s=this.getStringWidth(t,o);if(a<=n)return{string:r,width:a};if(s>=n)return{string:o,width:s};do r=r.slice(0,r.length-1),a=this.getStringWidth(t,r);while(a+s>n);return{string:r+o,width:a+s}}getStringWidth(t,r){return Math.ceil(t.measureText(r).width)}floor(t,r){r=typeof r=="number"?r:0;const n=Math.pow(10,r);return Math.round(t*n)/n}setCanvasSizes(t,r,n,i){const a=window.devicePixelRatio||1;t.width=n*a,t.height=i*a,t.style.width=n+"px",t.style.height=i+"px",r.scale(a,a)}}const ut=new cl,pa=function(e,t){return ut.floor(e*t.value,t.decimals)};function tQ(e,t){const r={};return e.forEach(n=>{t.some(function(i){return i.key===n?(r[n]=i,!0):!1})}),r}function rQ(e,t,r){const{maxWidth:n,maxHeight:i,showTitle:a,showSecondary:o}=r;for(let s=0;s<t.length;s++){const u=t[s],c=u.value,d=pa(c,e.valueSectionHeight),h=pa(c,e.indicatorMargin),p=Math.ceil(h*1.5);let m=c+d+p;if(a){const g=pa(c,e.titleSectionHeight);m+=g}if(o){const g=pa(c,e.secSectionHeight);m+=g}if(m<=i){const g=pa(c,e.gaugeWidth),b=pa(c,e.bracketWidth),_=h*2;if(g+b*2+_<=n)return z(D({},u),{maxWidth:n-_,maxHeight:i-p})}}return null}class nQ{getBaseMeasure(t,r,n){const i=r,a="gaugeHeights"in i?i.gaugeHeights:void 0;if(!a)return null;const o=i.relativeSizes,s=i.measureKeys.concat(),u=Math.floor(n.clientWidth),c=Math.floor(n.clientHeight),d=tQ(s,o);return rQ(d,a,{maxWidth:u,maxHeight:c,showTitle:t.showTitle,showSecondary:t.showSecondary})}render(t,r,n,i){const a=t.getContext("2d");let o=0,s;n.gaugeHeight=i.value,n.size=i.size,n.maxWidth=i.maxWidth,n.maxHeight=i.maxHeight,n.offsetY=0,s=n.gaugeHeight+n.valueSectionHeight,r.showTitle&&(n.fitTitleMeasure=this.getFitTitleMeasure(a,r,n),s+=n.titleSectionHeight),n.fitValueMeasure=this.getFitValueMeasure(a,r,n),r.showSecondary&&(n.fitSecondaryMeasure=this.getFitSecondaryMeasure(a,r,n),s+=n.secSectionHeight),o=this.getCanvasWidth(r,n),n.width=o,n.height=s,ut.setCanvasSizes(t,a,o,s),this.draw(a,r,n)}getFitTitleMeasure(t,r,n){const i=n.bracketWidth*2+n.titleHorizontalMargin*2,a=n.maxWidth-i,o=ut.getFitStringMeasure(t,r.title.text,a,n.titleFont);return o.width+=i,o.key="title",o}getFitValueMeasure(t,r,n){const i=n.bracketThickness*2,a=n.maxWidth-i,o=ut.getFitStringMeasure(t,r.value.text,a,n.valueFont);return o.width+=i,o.key="value",o}getFitSecondaryMeasure(t,r,n){const i=n.bracketWidth*2+n.secDividerWidth,a=n.maxWidth-i,o=a-n.secTitleMinWidth,s=ut.getFitStringMeasure(t,r.secondary.text,o,n.secondaryValueFont),u=a-s.width,c=ut.getFitStringMeasure(t,r.secondaryTitle.text,u,n.secondaryTitleFont);return{width:c.width+s.width+i,titleString:c.string,valueString:s.string,key:"secondary"}}getCanvasWidth(t,r){let n=r.gaugeWidth+r.bracketWidth*2;const i=r.fitTitleMeasure,a=r.fitValueMeasure;let s=i&&i.width>a.width?i:a;const u=r.fitSecondaryMeasure,c=u&&u.width>s.width;let d;return s=c?u:s,c?d=s.titleString!==t.secondaryTitle.text||s.valueString!==t.secondary.text:d=s.string!==t[s.key].text,d?n=r.maxWidth:s.width>n&&(n=s.width),n}draw(t,r,n){this.clearCanvas(t,n),r.showTitle&&this.drawTitle(t,n),this.drawGauge(t,r,n),this.drawValue(t,r,n),r.showSecondary&&this.drawSecondary(t,n),this.drawBrackets(t,r,n)}clearCanvas(t,r){t.fillStyle=r.backgroundColor,t.fillRect(0,0,r.width,r.height)}drawTitle(t,r){t.font=r.titleFont,t.fillStyle=r.titleColor,t.textAlign="center",t.textBaseline="middle",t.fillText(r.fitTitleMeasure.string,r.width/2,(r.titleSectionHeight-r.titleBottomMargin)/2),r.offsetY+=r.titleSectionHeight}drawGauge(t,r,n){n.gaugeCenterX=n.width/2,n.gaugeCenterY=n.offsetY+n.gaugeHeight-n.gaugeBottomMargin,n.needleAngle=this.getNeedleAngle(r,n),r.skin===2&&r.conditions&&r.conditions.length?this.drawConditionalDial(t,r,n):this.drawSimpleDial(t,r,n),r.showTicks&&n.size!=="micro"&&this.drawTicks(t,r,n),this.drawNeedle(t,n),r.showLabels&&n.size!=="micro"&&this.drawLabels(t,r,n),n.offsetY+=n.gaugeHeight}drawValue(t,r,n){t.fillStyle=n.valueColor,t.fillRect(1,n.offsetY,n.width-n.bracketThickness*2,n.valueSectionHeight),t.font=n.valueFont,t.fillStyle="white",t.textAlign="center",t.textBaseline="middle",t.fillText(n.fitValueMeasure.string,n.width/2,n.offsetY+n.valueSectionHeight/2)}drawSecondary(t,r){const n=r.height-r.secBottomMargin;t.font=r.secondaryTitleFont,t.fillStyle=r.secondaryTitleColor,t.textAlign="left",t.textBaseline="bottom",t.fillText(r.fitSecondaryMeasure.titleString,r.bracketWidth,n),t.font=r.secondaryValueFont,t.fillStyle=r.secondaryValueColor,t.textAlign="right",t.textBaseline="bottom",t.fillText(r.fitSecondaryMeasure.valueString,r.width-r.bracketWidth,n)}drawBrackets(t,r,n){const i=r.showTitle?(n.titleSectionHeight-n.titleBottomMargin)/2:0;t.strokeStyle=n.bracketColor,t.beginPath(),t.moveTo(n.bracketWidth+.5,i+.5),t.lineTo(.5,i+.5),t.lineTo(.5,n.height-.5),r.showSecondary&&t.lineTo(n.bracketWidth+.5,n.height-.5),t.stroke(),t.moveTo(n.width-(n.bracketWidth+.5),i+.5),t.lineTo(n.width-.5,i+.5),t.lineTo(n.width-.5,n.height-.5),r.showSecondary&&t.lineTo(n.width-(n.bracketWidth+.5),n.height-.5),t.stroke(),t.closePath()}getNeedleAngle(t,r){const n=+t.min.data,i=+t.max.data,a=+(t.value.data||0);return a<n?r.startAngle-r.overDegrees:a>i?r.endAngle+r.overDegrees:this.getAngle(r,a,n,i)}getAngle(t,r,n,i){const a=(t.endAngle-t.startAngle)/(i-n);return(r-n)*a+t.startAngle}drawConditionalDial(t,r,n){const i=r.conditions,a=+r.min.data,o=+r.max.data,s=ut.degToRad(n.startAngle+180),u=ut.degToRad(n.endAngle+180);let c;const d=h=>this.getAngle(n,h,a,o);for(this.drawArc(t,n,s,u,n.defaultDialColor),c=i.length-1;c>=0;c--){const h=i[c];let p=+h.data,m,g=NaN,b=NaN,_=NaN,w=NaN;const C=.25;switch(h.operator){case"<":if(p<=a)break;p=p>o?o:p,m=d(p),g=s,b=ut.degToRad(m+180);break;case">":if(p>=o)break;p=p<a?a:p,m=d(p),g=ut.degToRad(m+180),b=u;break;case"≤":if(p<a)break;p=p>o?o:p,m=d(p),g=s,b=ut.degToRad(m+(m+C<=n.endAngle?C:0)+180);break;case"≥":if(p>o)break;p=p<a?a:p,m=d(p),g=ut.degToRad(m-(m-C>=n.startAngle?C:0)+180),b=u;break;case"=":if(p<a||p>o)break;m=d(p),g=ut.degToRad(m-(m-C>=n.startAngle?C:0)+180),b=ut.degToRad(m+(m+C<=n.endAngle?C:0)+180);break;case"≠":if(p<a||p>o)g=s,b=u;else if(p===a||p===o){const S=p===a;g=ut.degToRad(n.startAngle+(S?C:0)+180),b=ut.degToRad(n.endAngle-(S?0:C)+180)}else m=d(p),g=s,b=ut.degToRad(m-(m-C>=n.startAngle?C:0)+180),_=ut.degToRad(m+(m+C<=n.endAngle?C:0)+180),w=u}!isNaN(g)&&!isNaN(b)&&this.drawArc(t,n,g,b,h.color),!isNaN(_)&&!isNaN(w)&&this.drawArc(t,n,_,w,h.color)}}drawSimpleDial(t,r,n){const i=ut.degToRad(n.startAngle+180),a=ut.degToRad(n.needleAngle+180),o=ut.degToRad(n.endAngle+180);n.needleAngle>n.startAngle&&n.needleAngle<n.endAngle?(this.drawArc(t,n,i,a,n.valueColor),t.globalAlpha=n.gaugeOpacity,this.drawArc(t,n,a,o,n.valueColor)):(n.needleAngle<=n.startAngle&&(t.globalAlpha=n.gaugeOpacity),this.drawArc(t,n,i,o,n.valueColor)),t.globalAlpha=1}drawArc(t,r,n,i,a){t.fillStyle=a,t.beginPath(),t.arc(r.gaugeCenterX,r.gaugeCenterY,r.outerArcRadius,n,i),t.arc(r.gaugeCenterX,r.gaugeCenterY,r.innerArcRadius,i,n,!0),t.fill()}drawTicks(t,r,n){const i=n.startAngle,a=n.endAngle,o=n.tickDegreesIncrement,s=n.needleAngle;let u;for(u=i;u<=a;u+=o){const c=ut.degToRad(u),d=n.gaugeCenterX-n.lengthToTick*Math.cos(c),h=n.gaugeCenterY-n.lengthToTick*Math.sin(c),p=s<i,m=s>=u-o/2&&s<u+o/2,g=u===a&&s>=u;t.fillStyle=!p&&m||g?r.color:n.tickColor,t.beginPath(),t.arc(d,h,n.tickRadius,0,2*Math.PI),t.fill()}}drawNeedle(t,r){const n=ut.degToRad(r.needleAngle);t.fillStyle=r.needleColor,t.save(),t.translate(r.gaugeCenterX,r.gaugeCenterY),t.rotate(n),t.translate(-r.gaugeCenterX,-r.gaugeCenterY),t.beginPath(),t.arc(r.gaugeCenterX,r.gaugeCenterY,r.needleBaseRadius,.5*Math.PI,1.5*Math.PI,!0),t.lineTo(r.gaugeCenterX-r.needleLength,r.gaugeCenterY),t.fill(),t.restore()}drawLabels(t,r,n){t.font=n.labelFont,t.fillStyle=n.labelColor,t.textAlign="right",t.textBaseline="middle",t.fillText(r.min.text,n.gaugeCenterX-n.labelMargin,n.gaugeCenterY),t.textAlign="left",t.fillText(r.max.text,n.gaugeCenterX+n.labelMargin,n.gaugeCenterY)}}const Ca=new cl,cu=function(e,t){return Ca.floor(e*t.value,t.decimals)};function iQ(e,t){const r={};return e.forEach(n=>{t.some(function(i){return i.key===n?(r[n]=i,!0):!1})}),r}function aQ(e,t,r){const{showTitle:n,showSecondary:i,maxHeight:a,maxWidth:o,bracketThickness:s}=r;for(let u=0;u<t.length;u++){const c=t[u],d=c.value,h=cu(d,e.indicatorMargin);let p=d+h;if(n){const m=cu(d,e.titleSectionHeight);p+=m}if(i){const m=cu(d,e.secSectionHeight);p+=m}if(p<=a){const m=cu(d,e.numericMinWidth),g=h*2;if(m+s*2+g<=o)return z(D({},c),{maxWidth:o-g,maxHeight:a-h})}}return null}class oQ{getBaseMeasure(t,r,n){const i=r,a="sizes"in i?i.sizes:[],o=i.relativeSizes,s=i.measureKeys.concat(),u=Math.floor(n.clientWidth),c=Math.floor(n.clientHeight),d=iQ(s,o);return aQ(d,a,{maxWidth:u,maxHeight:c,showTitle:t.showTitle,showSecondary:t.showSecondary,bracketThickness:i.bracketThickness})}render(t,r,n,i){const a=t.getContext("2d");let o;n.height=i.value,n.maxWidth=i.maxWidth,n.maxHeight=i.maxHeight,n.offsetY=0,o=n.height,r.showTitle&&(n.fitTitleMeasure=this.getFitTitleMeasure(a,r,n),o+=n.titleSectionHeight),n.fitValueMeasure=this.getFitValueMeasure(a,r,n),r.showSecondary&&(n.fitSecondaryMeasure=this.getFitSecondaryMeasure(a,r,n),o+=n.secSectionHeight);const s=this.getCanvasWidth(r,n);n.width=s,n.height=o,Ca.setCanvasSizes(t,a,s,o),this.draw(a,r,n)}getFitTitleMeasure(t,r,n){const i=n.bracketWidth*2+n.titleHorizontalMargin*2,a=n.maxWidth-i,o=Ca.getFitStringMeasure(t,r.title.text,a,n.titleFont);return o.width+=i,o.key="title",o}getFitValueMeasure(t,r,n){const i=n.bracketThickness*2,a=n.maxWidth-i,o=Ca.getFitStringMeasure(t,r.value.text,a,n.valueFont);return o.width+=i,o.key="value",o}getFitSecondaryMeasure(t,r,n){const i=n.bracketWidth*2+n.secDividerWidth,a=n.maxWidth-i,o=a-n.secTitleMinWidth,s=Ca.getFitStringMeasure(t,r.secondary.text,o,n.secondaryValueFont),u=a-s.width,c=Ca.getFitStringMeasure(t,r.secondaryTitle.text,u,n.secondaryTitleFont);return{width:c.width+s.width+i,titleString:c.string,valueString:s.string,key:"secondary"}}getCanvasWidth(t,r){let n=r.numericMinWidth+r.bracketThickness*2;const i=r.fitTitleMeasure,a=r.fitValueMeasure;let s=i&&i.width>a.width?i:a;const u=r.fitSecondaryMeasure,c=u&&u.width>s.width;let d;return s=c?u:s,c?d=s.titleString!==t.secondaryTitle.text||s.valueString!==t.secondary.text:d=s.string!==t[s.key].text,d?n=r.maxWidth:s.width>n&&(n=s.width),n}draw(t,r,n){this.clearCanvas(t,n),r.showTitle&&this.drawTitle(t,n),this.drawValue(t,r,n),r.showSecondary&&this.drawSecondary(t,n),(r.showTitle||r.showSecondary)&&this.drawBrackets(t,r,n)}clearCanvas(t,r){t.fillStyle=r.backgroundColor,t.fillRect(0,0,r.width,r.height)}drawTitle(t,r){t.font=r.titleFont,t.fillStyle=r.titleColor,t.textAlign="center",t.textBaseline="middle",t.fillText(r.fitTitleMeasure.string,r.width/2,r.titleSectionHeight/2),r.offsetY+=r.titleSectionHeight}drawValue(t,r,n){const i=n.offsetY;t.fillStyle=n.valueColor,t.fillRect(1,i,n.width-n.bracketThickness*2,n.valueSectionHeight),t.font=n.valueFont,t.fillStyle="white",t.textAlign="center",t.textBaseline="middle",t.fillText(n.fitValueMeasure.string,n.width/2,i+n.valueSectionHeight/2)}drawSecondary(t,r){const n=r.height-r.secBottomMargin;t.font=r.secondaryTitleFont,t.fillStyle=r.secondaryTitleColor,t.textAlign="left",t.textBaseline="bottom",t.fillText(r.fitSecondaryMeasure.titleString,r.bracketWidth,n),t.font=r.secondaryValueFont,t.fillStyle=r.secondaryValueColor,t.textAlign="right",t.textBaseline="bottom",t.fillText(r.fitSecondaryMeasure.valueString,r.width-r.bracketWidth,n)}drawBrackets(t,r,n){t.strokeStyle=n.bracketColor,t.beginPath(),r.showTitle?(t.moveTo(n.bracketWidth+.5,.5),t.lineTo(.5,.5)):t.moveTo(.5,.5),t.lineTo(.5,n.height-.5),r.showSecondary&&t.lineTo(n.bracketWidth+.5,n.height-.5),t.stroke(),r.showTitle?(t.moveTo(n.width-(n.bracketWidth+.5),.5),t.lineTo(n.width-.5,.5)):t.moveTo(n.width-.5,.5),t.lineTo(n.width-.5,n.height-.5),r.showSecondary&&t.lineTo(n.width-(n.bracketWidth+.5),n.height-.5),t.stroke(),t.closePath()}}const xa=new cl,vi=function(e,t){return xa.floor(e*t.value,t.decimals)};function sQ(e,t){const r={};return e.forEach(n=>{t.some(function(i){return i.key===n?(r[n]=i,!0):!1})}),r}function lQ(e,t,r){const{showTitle:n,showSecondary:i,skin:a,maxHeight:o,maxWidth:s,borderWidth:u}=r;for(let c=0;c<t.length;c++){const d=t[c],h=d.value,p=vi(h,e.valueSectionMarginBottom),g=vi(h,e.indicatorVerticalMargin)*2;let b=h+p+g;if(n&&a==="vertical"){const _=vi(h,e.titleSectionHeight);b+=_}if(i){const _=vi(h,e.secSectionHeight),w=vi(h,e.secSectionMarginTop);b+=_+w+(u||0)}if(b<=o){const _=vi(h,e.numericMinWidth),C=vi(h,e.indicatorHorizontalMargin)*2;if(_+C<=s)return z(D({},d),{maxWidth:s-C,maxHeight:o-g})}}return null}class uQ{getBaseMeasure(t,r,n){const i=r,a="sizes"in i?i.sizes:[],o=i.relativeSizes,s=i.measureKeys.concat(),u=Math.floor(n.clientWidth),c=Math.floor(n.clientHeight),d=sQ(s,o);return lQ(d,a,{maxWidth:u,maxHeight:c,showTitle:t.showTitle,showSecondary:t.showSecondary,skin:t.skin,borderWidth:"borderWidth"in i?i.borderWidth:0})}render(t,r,n,i){const a=t.getContext("2d");let o;n.height=i.value,n.maxWidth=i.maxWidth,n.maxHeight=i.maxHeight,o=n.height,n.fitValueMeasure=this.getFitValueMeasure(a,r,n),r.showTitle&&(n.fitTitleMeasure=this.getFitTitleMeasure(a,r,n),o+=r.skin==="vertical"?n.titleSectionHeight:0),r.showSecondary&&(n.fitSecondaryMeasure=this.getFitSecondaryMeasure(a,r,n),o+=n.valueSectionMarginBottom+n.secSectionHeight+n.secSectionMarginTop+n.borderWidth);const s=this.getCanvasWidth(r,n);n.width=s,n.height=o,xa.setCanvasSizes(t,a,s,o),this.draw(a,r,n)}getFitTitleMeasure(t,r,n){const i=r.skin==="horizontal",a=n.maxWidth-(i?n.fitValueMeasure.width+n.valueSectionMarginRight:0);if(i&&a+n.titleSectionMinWidth<=0)return;const o=xa.getFitStringMeasure(t,r.title.text,a,n.titleFont);return o.width+=i?n.valueSectionMarginRight:0,o.key="title",o}getFitValueMeasure(t,r,n){const i=xa.getFitStringMeasure(t,r.value.text,n.maxWidth,n.valueFont);return i.key="value",i}getFitSecondaryMeasure(t,r,n){const i=n.secDividerWidth,a=n.maxWidth-i,o=a-n.secTitleMinWidth,s=xa.getFitStringMeasure(t,r.secondary.text,o,n.secondaryValueFont),u=a-s.width,c=xa.getFitStringMeasure(t,r.secondaryTitle.text,u,n.secondaryTitleFont);return{width:c.width+s.width+i,titleString:c.string,valueString:s.string,key:"secondary"}}getCanvasWidth(t,r){let n;const i=r.fitTitleMeasure,a=r.fitValueMeasure,o=r.fitSecondaryMeasure;if(r.fitMeasures.some(u=>{const c=r[u.key],d=t[u.dataKey];return!!(c&&d&&c[u.prop]!==d.text)}))return r.maxWidth;if(t.skin==="vertical"){let c=i&&i.width>a.width?i:a;c=o&&o.width>c.width?o:c,n=c.width}else n=a.width,i&&(n+=i.width),o&&o.width>n&&(n=o.width);return n}draw(t,r,n){this.clearCanvas(t,n),this.drawValue(t,r,n),r.showTitle&&this.drawTitle(t,r,n),r.showSecondary&&this.drawSecondary(t,n)}clearCanvas(t,r){t.fillStyle=r.backgroundColor,t.fillRect(0,0,r.width,r.height)}drawTitle(t,r,n){!n.fitTitleMeasure||r.skin==="horizontal"&&n.fitValueMeasure.string!==r[n.fitValueMeasure.key].text||(t.font=n.titleFont,t.fillStyle=n.titleColor,r.skin==="vertical"?(t.textAlign="center",t.textBaseline="middle",t.fillText(n.fitTitleMeasure.string,n.width/2,n.titleSectionHeight/2)):(t.textAlign="left",t.textBaseline="top",t.fillText(n.fitTitleMeasure.string,n.fitValueMeasure.width+n.valueSectionMarginRight,n.titleSectionMarginTop)))}drawValue(t,r,n){const i=r.skin==="vertical";t.fillStyle=n.valueColor||r.color,t.font=n.valueFont,t.textAlign=i?"center":"left",t.textBaseline="middle",t.fillText(n.fitValueMeasure.string,i?n.width/2:0,(r.showTitle&&i?n.titleSectionHeight:0)+n.valueSectionHeight/2)}drawSecondary(t,r){let n=r.height-r.secSectionHeight/2;t.font=r.secondaryTitleFont,t.fillStyle=r.secondaryTitleColor,t.textAlign="left",t.textBaseline="middle",t.fillText(r.fitSecondaryMeasure.titleString,0,n),t.font=r.secondaryValueFont,t.fillStyle=r.secondaryValueColor,t.textAlign="right",t.fillText(r.fitSecondaryMeasure.valueString,r.width,n),t.strokeStyle=r.borderColor,t.beginPath(),n=r.height-r.secSectionHeight-r.secSectionMarginTop-r.borderWidth,t.moveTo(0,n),t.lineTo(r.width,n),t.stroke()}}const an=new cl;class cQ{render(t,r,n,i){const a=t.getContext("2d"),o=Math.floor(i.clientWidth)-n.horizontalMargin*2,s=n.sectionMinWidth;let u=0,c=0,d=0,h=0,p=0,m=0,g=0,b=0,_;if(a.font=n.valueFont,_=an.getStringWidth(a,r.value.text),n.offsetX=0,r.title.text+=":",r.secondaryTitle&&(r.secondaryTitle.text+=":"),r.showTitle&&(a.font=n.titleFont,m=an.getStringWidth(a,r.value.text),p=an.getStringWidth(a,r.title.text),c=p<s?p:s,_+=c+n.textPadding),r.showSecondary&&(a.font=n.secondaryValueFont,b=an.getStringWidth(a,r.secondary.text),h=b<s?b:s,_+=h,a.font=n.secondaryTitleFont||"",g=an.getStringWidth(a,r.secondaryTitle.text),d=g<s?g:s,_+=d+n.horizontalPadding*2+n.dividerWidth+n.textPadding),r.type==="gauge"){const C=n.horizontalPadding*2+n.dividerWidth;if(n.forceTickerView){const T=m+p+g+b+n.textPadding*4+C,M=o-C-T;n.barWidth=Math.max(M,n.barWidth)}const S=n.barWidth+C;_+=S,n.showTickerBar=_<=o||!0,u+=n.showTickerBar?S:0}u+=r.showTitle?n.textPadding:0,u+=r.showSecondary?n.horizontalPadding*2+n.dividerWidth+n.textPadding:0;const w=o-u-c-d-h;if(n.fitValueMeasure=an.getFitStringMeasure(a,r.value.text,w,n.valueFont),u+=n.fitValueMeasure.width,r.showSecondary){const C=o-u-c-d;let S;n.fitSecValueMeasure=an.getFitStringMeasure(a,r.secondary.text,C,n.secondaryValueFont),u+=n.fitSecValueMeasure.width;const T=o-u,M=T/2;r.showTitle?p+g>T?p>M&&g>M?S=M:g>M&&p<=M?S=T-p:S=g:S=g:S=T,n.fitSecTitleMeasure=an.getFitStringMeasure(a,r.secondaryTitle.text,S,n.secondaryTitleFont),u+=n.fitSecTitleMeasure.width}if(r.showTitle){const C=o-u;n.fitTitleMeasure=an.getFitStringMeasure(a,r.title.text,C,n.titleFont),u+=n.fitTitleMeasure.width}n.width=u,an.setCanvasSizes(t,a,u,n.height),this.draw(a,r,n)}draw(t,r,n){this.clearCanvas(t,n),r.type==="gauge"&&n.showTickerBar&&(this.drawTickerBar(t,r,n),this.drawDivider(t,n)),t.textBaseline="middle",r.showTitle&&this.drawTitle(t,n),this.drawValue(t,r,n),r.showSecondary&&(this.drawDivider(t,n),this.drawSecondary(t,n))}clearCanvas(t,r){t.fillStyle=r.backgroundColor,t.fillRect(0,0,r.width,r.height)}drawTickerBar(t,r,n){var c;const i=+r.min.data,a=+r.max.data,o=+(((c=r.value)==null?void 0:c.data)||0),s=Math.round((n.height-n.barHeight)/2);let u;if(t.fillStyle=n.valueColor,o<=i)t.globalAlpha=n.barOpacity,t.fillRect(n.offsetX,s,n.barWidth,n.barHeight),u=0;else if(o>=a)t.fillRect(n.offsetX,s,n.barWidth,n.barHeight),u=n.barWidth-n.tickerBarWidth;else{const d=(o-Math.abs(i))/(a-i),h=n.barWidth*d;t.fillRect(n.offsetX,s,h,n.barHeight),t.globalAlpha=n.barOpacity,t.fillRect(n.offsetX+h,s,n.barWidth-h,n.barHeight),h>n.barWidth-n.tickerBarWidth?u=n.barWidth-n.tickerBarWidth:h<n.tickerBarWidth?u=0:u=h-1}t.globalAlpha=1,t.fillStyle=n.barHandleColor,t.fillRect(n.offsetX+u,Math.round((n.height-n.tickerBarHeight)/2),n.tickerBarWidth,n.tickerBarHeight),n.offsetX+=n.barWidth}drawDivider(t,r){t.fillStyle=r.dividerColor,t.fillRect(r.offsetX+r.horizontalPadding,Math.round((r.height-r.dividerHeight)/2),r.dividerWidth,r.dividerHeight),r.offsetX+=r.horizontalPadding*2+r.dividerWidth}drawTitle(t,r){t.font=r.titleFont,t.fillStyle=r.titleColor,t.fillText(r.fitTitleMeasure.string,r.offsetX,Math.floor(r.height/2)),r.offsetX+=r.fitTitleMeasure.width+r.textPadding}drawValue(t,r,n){t.font=n.valueFont,t.fillStyle=n.valueColor||r.color,t.fillText(n.fitValueMeasure.string,n.offsetX,Math.floor(n.height/2)),n.offsetX+=n.fitValueMeasure.width}drawSecondary(t,r){t.font=r.secondaryTitleFont,t.fillStyle=r.secondaryTitleColor,t.fillText(r.fitSecTitleMeasure.string,r.offsetX,Math.floor(r.height/2)),r.offsetX+=r.fitSecTitleMeasure.width+r.textPadding,t.font=r.secondaryValueFont,t.fillStyle=r.secondaryValueColor,t.fillText(r.fitSecValueMeasure.string,r.offsetX,Math.floor(r.height/2))}}const dQ=new cl,hQ=new uQ,fQ=new oQ,pQ=new nQ,mQ=new cQ;class gQ{getService(t){switch(t){case"numericSimple":return hQ;case"numericBar":return fQ;case"gauge":return pQ;case"ticker":return mQ}}render(t,r,n,i){let a=this.getService(r.type);const o="getBaseMeasure"in a?a.getBaseMeasure(r,n,i):void 0;if(!o||n.forceTickerView){a=this.getService("ticker");const s=eQ(t,n);this.setTextOptions(s),a.render(t,r,s,i);return}this.calculateRelativeSizes(r,n,o.value),this.setTextOptions(n,o.size),a.render(t,r,n,o)}calculateRelativeSizes(t,r,n){const{relativeSizes:i}=r;i.forEach(function(a){let o;if("dataKey"in a&&"values"in a&&a.dataKey in t)o=a.values[String(t[a.dataKey])];else if("value"in a)o=a.value;else throw new V.TranslatableError("errors.indicatorInvalidRelativeSize");const s=o*n;r[a.key]=dQ.floor(s,a.decimals)})}setTextOptions(t,r){t.textKeys.forEach(function(n){const i=t[n],a=i.fontStyle?`${i.fontStyle} `:"",o=i.fontVariant?`${i.fontVariant} `:"",s=i.fontWeight?`${i.fontWeight} `:"",u=`${Number.parseFloat(i.fontSizes&&i.fontSizes[r]||i.fontSize||t.fontSize)}px `,c=i.fontFamily||t.fontFamily,{color:d}=i,h=t;h[`${n}Font`]=a+o+s+u+c,h[`${n}Color`]=d})}}function tT(e){var r;const t=(r=e.value)==null?void 0:r[0];if(t&&"color"in t)return t.color}function vQ(e,t,r){if(!yQ(e))return r;const i=E.getColoringServiceByColorOptions(e).getColor(t);return i?z(D({},r),{value:z(D({},r.value),{color:i})}):r}function yQ(e){return typeof e=="string"||e.type==="uniform"||e.type==="conditional"}const bQ=(e,t)=>{const r=tT(t);return r&&e.value?E.getColoringServiceByColorOptions(r).getColor(E.isNumber(e.value)?e.value:0):null},_Q=(e,t,r)=>{var h,p,m,g,b,_,w,C,S,T,M,P;const n=E.isNumber(e.min)?e.min:0,i=E.isNumber(e.max)?e.max:100,a=du(r,"value"),o=du(r,"secondary"),s=du(r,"min"),u=du(r,"max"),c=bQ(e,r),d=t.indicatorType==="gauge"?1:"vertical";return z(D(D({},CQ),c?{color:c}:null),{type:wQ(t.indicatorType,"numericSubtype"in t?t.numericSubtype:void 0)||"numericSimple",skin:t.skin||d,title:{text:(m=(p=(h=t.indicatorComponents)==null?void 0:h.title)==null?void 0:p.text)!=null?m:""},min:{data:n,text:E.applyFormatPlainText(s,n)},max:{data:i,text:E.applyFormatPlainText(u,i)},value:{data:e.value,text:Uy(e.value,a)},secondary:{data:e.secondary,text:Uy(e.secondary,o)},secondaryTitle:{text:(_=(b=(g=t.indicatorComponents)==null?void 0:g.secondaryTitle)==null?void 0:b.text)!=null?_:""},showSecondary:e.secondary!==void 0,showTitle:!!((C=(w=t.indicatorComponents)==null?void 0:w.title)!=null&&C.shouldBeShown),showLabels:!!((T=(S=t.indicatorComponents)==null?void 0:S.labels)!=null&&T.shouldBeShown),showTicks:!!((P=(M=t.indicatorComponents)==null?void 0:M.ticks)!=null&&P.shouldBeShown)})};function wQ(e,t){return e==="numeric"?t:e}function du(e,t){var n;const r=(n=e[t])==null?void 0:n[0];return E.getCompleteNumberFormatConfig(r&&"numberFormatConfig"in r?r.numberFormatConfig:{})}const CQ={color:"#00cee6",showSecondary:!1};function Uy(e,t){return e===void 0?"":isNaN(e)?`#${O.NOT_AVAILABLE_TEXT}`:E.applyFormatPlainText(t,e)}const xQ={fontFamily:"typography.fontFamily","title.color":"chart.textColor",backgroundColor:"chart.backgroundColor","label.color":"chart.textColor","secondaryTitle.color":"chart.secondaryTextColor","secondaryValue.color":"chart.secondaryTextColor","value.color":"palette.variantColors.0"};function Xp(e,t,r){const n=V.cloneDeep(r);for(const i in t){const a=t[i],o=TQ(e,a);o&&rT(n,i,o)}return n}function rT(e,t,r){const n=t.split(".");if(n.length===1)if(n[0]in e)e[n[0]]=r;else return;else{const[i,...a]=n;if(!(i in e))return;const o=e[i];if(!nT(o))return;rT(o,a.join("."),r)}}function TQ(e,t){const r=t.split(".");let n=e;for(const i of r){if(!nT(n)||!(i in n))return;n=n[i]}return n}function nT(e){return typeof e=="object"&&e!==null}function SQ(e,t,r){return Xp(e,t,r)}const MQ=(e,t)=>{const{chartData:r,dataOptions:n,themeSettings:i}=t,{type:a}=e;let o;switch(a){case"gauge":o=QK;break;case"numeric":e.numericSubtype==="numericBar"?o=KK:o=Vy;break;default:o=Vy}i&&(o=SQ(i,xQ,o));const s=tT(n);return s&&r.value&&E.isNumber(r.value)&&(o=vQ(s,r.value,o)),D(z(D({},o),{forceTickerView:e.forceTickerView}),e.type==="gauge"&&e.tickerBarHeight?{tickerBarHeight:e.tickerBarHeight}:null)};function PQ(e,t,r){return e==null?e:X_(e,t,r)}const iT={"value.data":"value.data","value.text":"value.text","secondary.data":"secondary.data","secondary.text":"secondary.text","title.text":"title.text","secondaryTitle.text":"secondaryTitle.text"},aT={"value.color":"value.color","secondaryValue.color":"secondary.color","secondaryValue.fontWeight":"secondary.fontWeight","title.color":"title.color","secondaryTitle.color":"secondaryTitle.color"};function EQ(e,t){const r={};return O.flow(Gy(e,iT),Gy(t,aT))(r)}function Gy(e,t){return r=>{const n=D({},r);for(const[i,a]of Object.entries(t))PQ(n,a,V.get(e,i));return n}}const AQ=(e,t,r)=>{const n=Xp(e,iT,t),i=Xp(e,aT,r);return{legacyDataOptions:n,legacyChartOptions:i}},RQ=e=>e,DQ=(e,t)=>{var i;const r={},n=(a,o)=>{if(a===void 0)return;const s=E.getCompleteNumberFormatConfig(o);return E.applyFormatPlainText(s,a)};return t.value&&t.value.length>0&&(r.value=z(D({},Fe(t.value[0])),{value:(i=e.value)!=null?i:0,displayValue:n(e.value,t.value[0])})),t.secondary&&t.secondary.length>0&&e.secondary!==void 0&&(r.secondary=z(D({},Fe(t.secondary[0])),{value:e.secondary,displayValue:n(e.secondary,t.secondary[0])})),t.min&&t.min.length>0&&e.min!==void 0&&(r.min=z(D({},Fe(t.min[0])),{value:e.min,displayValue:n(e.min,t.min[0])})),t.max&&t.max.length>0&&e.max!==void 0&&(r.max=z(D({},Fe(t.max[0])),{value:e.max,displayValue:n(e.max,t.max[0])})),{entries:r}},NQ=({chartData:e,dataOptions:t,designOptions:r,onBeforeRender:n=RQ,onDataPointClick:i})=>{var d;const a=N.useRef(null),o=N.useRef(null),{t:s}=O.useTranslation(),{themeSettings:u}=y.useThemeContext();N.useEffect(()=>{if(!o.current||!a.current)return;const h=new gQ,p=_Q(e,r,t),m=MQ({type:r.indicatorType,numericSubtype:"numericSubtype"in r?r.numericSubtype:void 0,forceTickerView:r.forceTickerView,tickerBarHeight:r.tickerBarHeight},{chartData:e,dataOptions:t,themeSettings:u}),g=EQ(p,m),b=n(g),{legacyDataOptions:_,legacyChartOptions:w}=AQ(b,p,m);h.render(o.current,_,w,a.current)},[e,t,r,u,n]);const c=h=>{if(i){const p=DQ(e,t);i(p,h.nativeEvent)}};return O.jsx("div",{ref:a,"data-testid":"indicator-root",role:"img","aria-label":s("chart.indicator.label"),style:{display:"flex",justifyContent:"center",width:"100%",height:"100%",alignItems:"center",backgroundColor:(d=u==null?void 0:u.chart)==null?void 0:d.backgroundColor,cursor:i?"pointer":"default"},onClick:c,children:O.jsx("canvas",{ref:o})})},kQ=e=>e.type==="indicator",LQ=e=>"min"in e,OQ=e=>"indicatorComponents"in e,IQ=e=>!!e.chartData&&kQ(e.chartData)&&LQ(e.dataOptions)&&OQ(e.designOptions),FQ=Object.freeze({usa:"united states",switzerland:"switzerland country",uk:"united kingdom"});function $Q(e,t){const r=FQ[e.toLowerCase()];return r&&(t[r]=e),r||e}function BQ(e,t){return t[e.toLowerCase()]||e}const zQ=(e,t)=>{const{app:r}=y.useSisenseContext(),[n,i]=N.useState([]),a=N.useRef(e),o=N.useCallback(()=>ht(exports,null,function*(){if(!r||!e)return;const s={},u=NK(t),c=yield r.httpClient.post("api/v1/geo/locations",D({locations:e.map(g=>({name:$Q(g.name,s)}))},u&&{geoLevel:u})),d=a.current!==e;if(!c||d)return;const h=c.reduce((g,b)=>{const _=z(D({},b),{name:BQ(b.name,s)});return g[_.name]=_,g},{}),p=[],m=e.map(g=>(h[g.name]||p.push(g.name),D(D({},g),h[g.name]?{coordinates:h[g.name].latLng}:null)));p.length&&console.warn(`Locations "${p.join(", ")}" coordinates not found`),i(m)}),[r,i,e,t]);return N.useEffect(()=>{e&&(a.current=e,e.some(u=>!!u.coordinates)?i(e):o())},[e,r,o,i]),n},HQ=()=>{const{app:e}=y.useSisenseContext(),[t,r]=N.useState(null),n=N.useCallback(()=>ht(exports,null,function*(){if(!e)return;const i=yield e.httpClient.get("api/v1/settings/system");i&&r(i.geo)}),[r,e]);return N.useEffect(()=>{n()},[e,n]),t};var WQ="Expected a function";function jQ(e,t,r){if(typeof e!="function")throw new TypeError(WQ);return setTimeout(function(){e.apply(void 0,r)},t)}var VQ=V.baseRest(function(e,t,r){return jQ(e,E.toNumber(t)||0,r)}),Fu=(e=>(e[e.YES=0]="YES",e[e.NO=1]="NO",e[e.LOADING=2]="LOADING",e))(Fu||{});const sf=10,UQ=`
213
+ <svg
214
+ xmlns="http://www.w3.org/2000/svg"
215
+ width="24"
216
+ height="24"
217
+ viewBox="0 0 24 24"
218
+ fill="green"
219
+ class="csdk-animate-spin"
220
+ >
221
+ <path
222
+ fillRule="evenodd"
223
+ clipRule="evenodd"
224
+ d="M12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20ZM12 21C16.9706 21 21 16.9706 21 12C21 7.02944 16.9706 3 12 3C7.02944 3 3 7.02944 3 12C3 16.9706 7.02944 21 12 21Z"
225
+ fill="transparent"
226
+ fillOpacity="0.3"
227
+ />
228
+ <path
229
+ fillRule="evenodd"
230
+ clipRule="evenodd"
231
+ d="M20 12C20 16.4183 16.4183 20 12 20C11.2844 20 10.5908 19.906 9.93078 19.7298C9.96227 19.5889 9.97888 19.4423 9.97888 19.2918C9.97888 18.1873 9.08345 17.2918 7.97888 17.2918C6.87431 17.2918 5.97888 18.1873 5.97888 19.2918C5.97888 20.3964 6.87431 21.2918 7.97888 21.2918C8.56576 21.2918 9.0936 21.0391 9.45946 20.6364C10.2652 20.8731 11.1178 21 12 21C16.9706 21 21 16.9706 21 12C21 7.02944 16.9706 3 12 3V4C16.4183 4 20 7.58172 20 12Z"
232
+ fill="#22C3C3"
233
+ />
234
+ </svg>
235
+ `,An=e=>`<span class="csdk-scattermap-tooltip-label">${e}</span>`,GQ=e=>{const t=`
236
+ <div>
237
+ <div>${An("...")}</div>
238
+ <div>${An(`Showing first ${sf} results`)}</div>
239
+ </div>
240
+ `;return`
241
+ <div>
242
+ ${e.slice(0,sf).map(r=>`<div>${An(r)}</div>`).join("")}
243
+ ${e.length>sf?t:""}
244
+ </div>
245
+ `},lf=e=>`
246
+ <span class="csdk-scattermap-tooltip-category">
247
+ ${An(e)}
248
+ </span>
249
+ `,qQ=()=>An(UQ),hu=(e,t,r=1)=>{const n=E.formatTooltipValue(t.size,e.value,`${e.value}`),i=E.formatTooltipValue(t.colorBy,e.colorValue,`${e.colorValue}`),a=t.details&&E.formatTooltipValue(t.details,e.details,`${e.details}`),o=`
250
+ <div class="csdk-scattermap-tooltip-container">
251
+ <div class="csdk-scattermap-tooltip-content">
252
+ <div>${An(e.name)}</div>
253
+ <div class="csdk-scattermap-tooltip-row">
254
+ ${t.size?lf(E.getDataOptionTitle(t.size)):""}
255
+ ${t.size?An(n):""}
256
+ </div>
257
+ <div class="csdk-scattermap-tooltip-row">
258
+ ${t.colorBy?lf(E.getDataOptionTitle(t.colorBy)):""}
259
+ ${t.colorBy?An(i||O.NOT_AVAILABLE_TEXT):""}
260
+ </div>
261
+ <div class="csdk-scattermap-tooltip-row">
262
+ ${(r===2||r===0)&&t.details?lf(E.getDataOptionTitle(t.details)):""}
263
+ ${r===2?qQ():""}
264
+ ${r===0&&t.details&&E.isMeasureColumn(t.details)?An(a||O.NOT_AVAILABLE_TEXT):""}
265
+ </div>
266
+ <div>
267
+ ${r===0&&t.details&&!E.isMeasureColumn(t.details)?GQ(e.details):""}
268
+ </div>
269
+ </div>
270
+ </div>
271
+ `;return E.purify.sanitize(o)},YQ=600,XQ=11,ZQ=({dataOptions:e,dataSource:t,filters:r=[]})=>{const{app:n}=y.useSisenseContext(),i=N.useCallback(o=>ht(exports,null,function*(){if(!n||!e.details||E.isMeasureColumn(e.details))return[];const s=e.locations.map((d,h)=>{const p=E.translateColumnToAttribute(d),m=DK(o)[h];return V.members(p,[m])}),u={dataSource:t,dimensions:[E.translateColumnToAttribute(e.details)],filters:H.mergeFilters(r,s),count:XQ};return(yield V.executeQuery(u,n)).rows.map(([d])=>d.text)}),[n,e,t,r]);return N.useCallback(o=>{if(!e.details||e.details&&!E.isMeasureColumn(e.details)&&!t)return{content:hu(o,e)};if(E.isMeasureColumn(e.details))return{content:hu(o,e,Fu.YES)};const s=new Promise(c=>VQ(c,YQ)),u=Promise.all([i(o.name),s]).then(([c])=>hu(z(D({},o),{details:c}),e,Fu.YES));return{content:hu(o,e,Fu.LOADING),postponedContent:u}},[e,t,i])},KQ="#00cee6",QQ=E.createDataColoringFunction({getValueFromDataStructure:({colorValue:e})=>parseFloat(`${e}`),applyColorToDataStructure:(e,t)=>z(D({},e),{color:t})});function JQ(e,t){return t?QQ(e.map(({colorValue:r})=>({colorValue:r})),t).map(({color:r})=>r):e.map(()=>KQ)}function eJ(e,t){const r=`
272
+ © <a href='https://www.mapbox.com/about/maps/'>Mapbox</a>
273
+ © <a href='http://www.openstreetmap.org/copyright'>OpenStreetMap</a>
274
+ <strong>
275
+ <a href='https://www.mapbox.com/map-feedback/' target='_blank' aria-label='Improve this map (opens in a new tab)'>
276
+ Improve this map
277
+ </a>
278
+ </strong>`,n="© <a href='http://www.openstreetmap.org/copyright'>OpenStreetMap</a>",i=Rn.control.attribution();return t.indexOf("mapbox")>-1?i.addAttribution(r).addTo(e):t.indexOf("openstreetmap")>-1&&i.addAttribution(n).addTo(e),i}function oT(e){return{isLight:["hollow","filled-light"].includes(e),isFilled:["filled","filled-light"].includes(e)}}function sT(e){const{color:t,size:r,fill:n,blur:i}=e,{isFilled:a}=oT(n),u=i?{filled:.1,"filled-light":.1,hollow:.2,"hollow-bold":.25}[n]:{filled:.5,"filled-light":.2,hollow:.35,"hollow-bold":.9}[n];return{radius:r,fillOpacity:u,opacity:u,fillColor:a?t:"transparent",color:a?"transparent":t,stroke:!a,weight:a?0:2,customStyle:e}}function tJ({coordinates:e,style:t}){const r=new Rn.CircleMarker({lat:e.lat,lng:e.lng},sT(t));return r.on("mouseover",rJ),r.on("mouseout",nJ),r}function rJ(e){const t=e.target,r=t.options.customStyle,{isFilled:n,isLight:i}=oT(r.fill);return t.setStyle(n?{stroke:!0,weight:2,opacity:i?.5:.7,fillOpacity:i?.5:.7}:{weight:3,opacity:i?.6:1}),t}function nJ(e){const t=e.target,r=t.options.customStyle;t.setStyle(sT(r))}function iJ(e){e.forEach(t=>t.remove())}function aJ(e){let t=Number.MAX_VALUE,r=Number.MIN_VALUE;return e.forEach(n=>{isNaN(n)||(t=Math.min(t,n),r=Math.max(r,n))}),{min:t,max:r}}function oJ(e,t=4,r=24){let n=0;const{min:i,max:a}=aJ(e.map(({value:s})=>s)),o=r-t;return n=a-i,e.map(s=>n===0?t:(s.value-i)/n*o+t)}const sJ=({chartData:e,dataOptions:t,dataSource:r,filters:n=[],designOptions:i,onDataPointClick:a})=>{const{locations:o}=e,s=HQ(),{themeSettings:u}=y.useThemeContext(),c=zQ(o,t.locationLevel),{filters:d}=V.getFilterListAndRelationsJaql(n),h=ZQ({dataOptions:t,dataSource:r,filters:d}),p=N.useRef(null),m=N.useRef(null),g=N.useMemo(()=>oJ(c,t.size?i.markers.size.minSize:i.markers.size.defaultSize,t.size?i.markers.size.maxSize:i.markers.size.defaultSize),[c,t,i]),b=N.useMemo(()=>{var T;return JQ(c,(T=t.colorBy)==null?void 0:T.color)},[c,t]),_=N.useRef([]),w=N.useRef(Rn.layerGroup([])),C=N.useRef(null),S=N.useRef(null);return N.useEffect(()=>{p.current&&!m.current&&(m.current=Rn.map(p.current,{attributionControl:!1,scrollWheelZoom:!0,minZoom:1,worldCopyJump:!0}),w.current.addTo(m.current),m.current.fitWorld())},[]),N.useEffect(()=>{_.current&&(iJ(_.current),_.current=[]),c&&(c.forEach((T,M)=>{if(!T.coordinates)return;const P=tJ({coordinates:T.coordinates,style:{color:b[M],size:g[M],fill:i.markers.fill,blur:!!T.blur}});_.current.push(P),P.addTo(w.current),a&&P.on("click",R=>{a(kK(T,t),R.originalEvent)}),P.bindTooltip(()=>{const{content:R,postponedContent:k}=h(T);return k==null||k.then(I=>P.setTooltipContent(I)),R})}),c7(m.current,_.current,qC(u)))},[c,b,g,i,u,t,h,a]),N.useEffect(()=>{var T;s&&(C.current&&C.current.remove(),C.current=Rn.tileLayer(s.maps_api_provider,{zoomOffset:-1,tileSize:512}),m.current&&(C.current.addTo(m.current),(T=S.current)==null||T.remove(),S.current=eJ(m.current,s.maps_api_provider)))},[s]),O.jsx("div",{className:"csdk-map-container",ref:p,style:{width:"100%",height:"100%"}})},lT=e=>e.type==="scattermap"&&"locations"in e,lJ=e=>"locations"in e,uJ=e=>"markers"in e,cJ=e=>!!e.chartData&&lT(e.chartData)&&lJ(e.dataOptions)&&uJ(e.designOptions),dJ=e=>e,hJ=({chartType:e,chartData:t,dataOptions:r,designOptions:n,onDataPointClick:i,onDataPointContextMenu:a,onDataPointsSelected:o,onBeforeRender:s=dJ,onReady:u,size:c})=>{const{app:d}=y.useSisenseContext(),{t:h}=O.useTranslation(),p=[],m=N.useCallback((w,C)=>ol(w,C,d==null?void 0:d.settings.locale,d==null?void 0:d.settings.dateConfig),[d==null?void 0:d.settings.locale,d==null?void 0:d.settings.dateConfig]),{themeSettings:g}=y.useThemeContext(),b=N.useMemo(()=>{var R;const{options:w,alerts:C}=E.highchartsOptionsService(t,e,n,r,h,g,m);p.push(...C);const S=((R=d==null?void 0:d.settings.accessibilityConfig)==null?void 0:R.enabled)||!1,T=Nx(w,g,S),M=Dx(T,r,{onDataPointClick:i,onDataPointContextMenu:a,onDataPointsSelected:o}),P=kx(M,g);return s(P)},[e,t,r,n,g,i,a,s,h]),_=N.useMemo(()=>b?z(D({},b),{chart:D(D(D({},b.chart),(c==null?void 0:c.width)&&{width:c.width}),(c==null?void 0:c.height)&&{height:c.height})}):null,[b,c]);return _&&O.jsxs("div",{"data-testid":"chart-root",role:"img","aria-label":h("chart.visualization.label"),style:{display:"flex",justifyContent:"center",height:"100%",width:"100%"},children:[!!p.length&&O.jsx(Zx,{alerts:p}),O.jsx(k0,{options:_,onReady:u})]})},fJ=[...H.CARTESIAN_CHART_TYPES,...H.CATEGORICAL_CHART_TYPES,...H.SCATTER_CHART_TYPES,...H.BOXPLOT_CHART_TYPES,...H.RANGE_CHART_TYPES],uT=e=>fJ.includes(e),pJ=e=>!!e.chartType&&uT(e.chartType)&&!!e.chartData;function mJ(e,t){return e==="scatter"&&"scatterDataTable"in t?t.scatterDataTable.length===0:e==="areamap"&&vx(t)?t.geoData.length===0:e==="scattermap"&&lT(t)?t.locations.length===0:e==="boxplot"&&nK(t)?t.xValues.length===0:e==="calendar-heatmap"&&wx(t)?t.values.length===0:e==="sankey"&&T3(t)?t.links.length===0:e==="kpi"&&A3(t)?!1:"series"in t&&t.series.length===0}const gJ=e=>e==="indicator",$u=e=>{const{chartType:t,dataSet:r,dataOptions:n,filters:i,highlights:a,styleOptions:o,refreshCounter:s,onDataPointClick:u,onDataPointContextMenu:c,onDataPointsSelected:d,onBeforeRender:h,onDataReady:p,onReady:m}=e,{width:g,height:b}=o||{},_=Ec(t),w=N.useMemo(()=>({width:g,height:b}),[g,b]),C=WZ(n,t),{dataOptions:S,attributes:T,measures:M,dataColumnNamesMapping:P}=YK(n,t,C),R=T.length===0&&M.length===0,k=N.useMemo(()=>QZ(t,C),[t,C]),{data:I,dataOptions:$,isLoading:G}=qK({dataSet:r,chartDataOptions:S,chartType:t,attributes:T,measures:M,dataColumnNamesMapping:P,filters:i,highlights:a,refreshCounter:s,enabled:!R,loadData:k}),Y=N.useMemo(()=>!n||R?null:UZ(t,$,o),[n,t,$,o,R]),B=WK({dataSet:r,data:I,chartDataOptions:S,chartType:t,isForecastOrTrendChart:C,attributes:T,measures:M,dataColumnNamesMapping:P,onDataReady:p}),{onRendererReady:X}=VK({chartType:t,isLoading:G,hasNoDimensions:R,chartData:B,onReady:m}),U=UK({dataSet:r,chartType:t,chartData:B,internalDataOptions:$,designOptions:Y,onBeforeRender:h,onDataPointClick:u,onDataPointContextMenu:c,onDataPointsSelected:d,onReady:X,filters:i}),Q=N.useCallback(W=>{if(B&&mJ(t,B)||R)return O.jsx(Ac,{iconType:t});if(!U)return null;if(!B&&G)return O.jsx(y.LoadingOverlay,{});if(go(t)&&!C){const ee=mo(t);return ee.renderer.isCorrectRendererProps(U)?O.jsx(y.LoadingOverlay,{isVisible:G,children:O.jsx(ee.renderer.ChartRendererComponent,z(D({},U),{size:W}))}):null}return t==="scattermap"&&cJ(U)?O.jsx(y.LoadingOverlay,{isVisible:G,children:O.jsx(sJ,D({},U))}):t==="indicator"&&IQ(U)?O.jsx(y.LoadingOverlay,{isVisible:G,children:O.jsx(NQ,D({},U))}):uT(t)&&pJ(U)?O.jsx(y.LoadingOverlay,{isVisible:G,children:O.jsx(hJ,z(D({},U),{designOptions:D({},U.designOptions),size:W}))}):null},[B,G,t,R,C,U]);return!U&&!R?null:O.jsx(Pc,{defaultSize:_,size:w,rerenderOnResize:gJ(t),children:Q})};function cT(e){return e&&typeof e=="object"&&"columns"in e&&V.isArray(e.columns)&&"rows"in e&&V.isArray(e.rows)}const X0=e=>{const t=[],r=[];for(const n of e.columns)E.isMeasureColumn(n)?r.push(E.translateColumnToMeasure(n)):t.push(E.translateColumnToAttribute(n));return{attributes:t,measures:r}},vJ=({dataSet:e,dataOptions:t,dataColumnNamesMapping:r,filters:n,filterRelations:i,count:a,offset:o})=>{const s=q0(),[u,c]=N.useState(H.isDataSource(e)?null:e),[d,h]=N.useState(!1),p=N.useRef(!0),{isInitialized:m,app:g}=y.useSisenseContext(),[b,_]=N.useState(t),[w,C]=N.useState(r);return N.useEffect(()=>{var P;let S=!1;if(!t)return;const{attributes:T,measures:M}=X0(t);if(H.isDataSource(e)){if(!m){s(new V.TranslatableError("errors.chartNoSisenseContext"));return}if(!g||!p.current&&o>0)return;h(!0),((P=g.settings.queryCacheConfig)!=null&&P.enabled?V.executeQueryWithCache:V.executeQuery)({dataSource:e,dimensions:T,measures:M,filters:n,filterRelations:i,count:a+1,offset:o,ungroup:!0},g).then(k=>{if(S)return;p.current=k.rows.length>a;const I=p.current?k.rows.slice(0,a):k.rows;o>0?c($=>{const G=$==null?void 0:$.rows.length,Y=G?G>o?$.rows.slice(0,o):$.rows:null;return{columns:k.columns,rows:Y?[...Y,...I]:I}}):c({columns:k.columns,rows:I}),_(t),C(r)}).finally(()=>{h(!1)}).catch(k=>{S||s(k)})}else c(e),_(t),C(r);return()=>{S=!0}},[g,e,t,r,n,i,o,a,m,s]),[d?null:u,b,w]},yJ=({data:e,innerDataOptions:t,dataColumnNamesMapping:r,needToAggregate:n=!1})=>{const{app:i}=y.useSisenseContext();return N.useMemo(()=>{if(!e||!t)return null;let a=E.createDataTableFromData(Yp(e,t,i==null?void 0:i.settings.locale,i==null?void 0:i.settings.dateConfig));const o=t.columns.filter(u=>!E.isMeasureColumn(u)).map(E.translateColumnToAttribute),s=t.columns.filter(u=>E.isMeasureColumn(u)).map(E.translateColumnToMeasure);return g3(a,o,s,r),n&&(a=Q3(a,o,s,r)),RY(t,a)},[e,t,n,r,i])};var mr="top",Ir="bottom",Fr="right",gr="left",Z0="auto",dl=[mr,Ir,Fr,gr],Va="start",Ls="end",bJ="clippingParents",dT="viewport",Yo="popper",_J="reference",qy=dl.reduce(function(e,t){return e.concat([t+"-"+Va,t+"-"+Ls])},[]),hT=[].concat(dl,[Z0]).reduce(function(e,t){return e.concat([t,t+"-"+Va,t+"-"+Ls])},[]),wJ="beforeRead",CJ="read",xJ="afterRead",TJ="beforeMain",SJ="main",MJ="afterMain",PJ="beforeWrite",EJ="write",AJ="afterWrite",RJ=[wJ,CJ,xJ,TJ,SJ,MJ,PJ,EJ,AJ];function gn(e){return e?(e.nodeName||"").toLowerCase():null}function xr(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Oi(e){var t=xr(e).Element;return e instanceof t||e instanceof Element}function Lr(e){var t=xr(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function K0(e){if(typeof ShadowRoot=="undefined")return!1;var t=xr(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function DJ(e){var t=e.state;Object.keys(t.elements).forEach(function(r){var n=t.styles[r]||{},i=t.attributes[r]||{},a=t.elements[r];!Lr(a)||!gn(a)||(Object.assign(a.style,n),Object.keys(i).forEach(function(o){var s=i[o];s===!1?a.removeAttribute(o):a.setAttribute(o,s===!0?"":s)}))})}function NJ(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(n){var i=t.elements[n],a=t.attributes[n]||{},o=Object.keys(t.styles.hasOwnProperty(n)?t.styles[n]:r[n]),s=o.reduce(function(u,c){return u[c]="",u},{});!Lr(i)||!gn(i)||(Object.assign(i.style,s),Object.keys(a).forEach(function(u){i.removeAttribute(u)}))})}}const kJ={name:"applyStyles",enabled:!0,phase:"write",fn:DJ,effect:NJ,requires:["computeStyles"]};function hn(e){return e.split("-")[0]}var Mi=Math.max,cc=Math.min,Ua=Math.round;function Zp(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function fT(){return!/^((?!chrome|android).)*safari/i.test(Zp())}function Ga(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var n=e.getBoundingClientRect(),i=1,a=1;t&&Lr(e)&&(i=e.offsetWidth>0&&Ua(n.width)/e.offsetWidth||1,a=e.offsetHeight>0&&Ua(n.height)/e.offsetHeight||1);var o=Oi(e)?xr(e):window,s=o.visualViewport,u=!fT()&&r,c=(n.left+(u&&s?s.offsetLeft:0))/i,d=(n.top+(u&&s?s.offsetTop:0))/a,h=n.width/i,p=n.height/a;return{width:h,height:p,top:d,right:c+h,bottom:d+p,left:c,x:c,y:d}}function Q0(e){var t=Ga(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function pT(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&K0(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function kn(e){return xr(e).getComputedStyle(e)}function LJ(e){return["table","td","th"].indexOf(gn(e))>=0}function li(e){return((Oi(e)?e.ownerDocument:e.document)||window.document).documentElement}function ud(e){return gn(e)==="html"?e:e.assignedSlot||e.parentNode||(K0(e)?e.host:null)||li(e)}function Yy(e){return!Lr(e)||kn(e).position==="fixed"?null:e.offsetParent}function OJ(e){var t=/firefox/i.test(Zp()),r=/Trident/i.test(Zp());if(r&&Lr(e)){var n=kn(e);if(n.position==="fixed")return null}var i=ud(e);for(K0(i)&&(i=i.host);Lr(i)&&["html","body"].indexOf(gn(i))<0;){var a=kn(i);if(a.transform!=="none"||a.perspective!=="none"||a.contain==="paint"||["transform","perspective"].indexOf(a.willChange)!==-1||t&&a.willChange==="filter"||t&&a.filter&&a.filter!=="none")return i;i=i.parentNode}return null}function hl(e){for(var t=xr(e),r=Yy(e);r&&LJ(r)&&kn(r).position==="static";)r=Yy(r);return r&&(gn(r)==="html"||gn(r)==="body"&&kn(r).position==="static")?t:r||OJ(e)||t}function J0(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ms(e,t,r){return Mi(e,cc(t,r))}function IJ(e,t,r){var n=ms(e,t,r);return n>r?r:n}function mT(){return{top:0,right:0,bottom:0,left:0}}function gT(e){return Object.assign({},mT(),e)}function vT(e,t){return t.reduce(function(r,n){return r[n]=e,r},{})}var FJ=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,gT(typeof t!="number"?t:vT(t,dl))};function $J(e){var t,r=e.state,n=e.name,i=e.options,a=r.elements.arrow,o=r.modifiersData.popperOffsets,s=hn(r.placement),u=J0(s),c=[gr,Fr].indexOf(s)>=0,d=c?"height":"width";if(!(!a||!o)){var h=FJ(i.padding,r),p=Q0(a),m=u==="y"?mr:gr,g=u==="y"?Ir:Fr,b=r.rects.reference[d]+r.rects.reference[u]-o[u]-r.rects.popper[d],_=o[u]-r.rects.reference[u],w=hl(a),C=w?u==="y"?w.clientHeight||0:w.clientWidth||0:0,S=b/2-_/2,T=h[m],M=C-p[d]-h[g],P=C/2-p[d]/2+S,R=ms(T,P,M),k=u;r.modifiersData[n]=(t={},t[k]=R,t.centerOffset=R-P,t)}}function BJ(e){var t=e.state,r=e.options,n=r.element,i=n===void 0?"[data-popper-arrow]":n;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||pT(t.elements.popper,i)&&(t.elements.arrow=i))}const zJ={name:"arrow",enabled:!0,phase:"main",fn:$J,effect:BJ,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function qa(e){return e.split("-")[1]}var HJ={top:"auto",right:"auto",bottom:"auto",left:"auto"};function WJ(e,t){var r=e.x,n=e.y,i=t.devicePixelRatio||1;return{x:Ua(r*i)/i||0,y:Ua(n*i)/i||0}}function Xy(e){var t,r=e.popper,n=e.popperRect,i=e.placement,a=e.variation,o=e.offsets,s=e.position,u=e.gpuAcceleration,c=e.adaptive,d=e.roundOffsets,h=e.isFixed,p=o.x,m=p===void 0?0:p,g=o.y,b=g===void 0?0:g,_=typeof d=="function"?d({x:m,y:b}):{x:m,y:b};m=_.x,b=_.y;var w=o.hasOwnProperty("x"),C=o.hasOwnProperty("y"),S=gr,T=mr,M=window;if(c){var P=hl(r),R="clientHeight",k="clientWidth";if(P===xr(r)&&(P=li(r),kn(P).position!=="static"&&s==="absolute"&&(R="scrollHeight",k="scrollWidth")),P=P,i===mr||(i===gr||i===Fr)&&a===Ls){T=Ir;var I=h&&P===M&&M.visualViewport?M.visualViewport.height:P[R];b-=I-n.height,b*=u?1:-1}if(i===gr||(i===mr||i===Ir)&&a===Ls){S=Fr;var $=h&&P===M&&M.visualViewport?M.visualViewport.width:P[k];m-=$-n.width,m*=u?1:-1}}var G=Object.assign({position:s},c&&HJ),Y=d===!0?WJ({x:m,y:b},xr(r)):{x:m,y:b};if(m=Y.x,b=Y.y,u){var B;return Object.assign({},G,(B={},B[T]=C?"0":"",B[S]=w?"0":"",B.transform=(M.devicePixelRatio||1)<=1?"translate("+m+"px, "+b+"px)":"translate3d("+m+"px, "+b+"px, 0)",B))}return Object.assign({},G,(t={},t[T]=C?b+"px":"",t[S]=w?m+"px":"",t.transform="",t))}function jJ(e){var t=e.state,r=e.options,n=r.gpuAcceleration,i=n===void 0?!0:n,a=r.adaptive,o=a===void 0?!0:a,s=r.roundOffsets,u=s===void 0?!0:s,c={placement:hn(t.placement),variation:qa(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Xy(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:u})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Xy(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:u})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const VJ={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:jJ,data:{}};var fu={passive:!0};function UJ(e){var t=e.state,r=e.instance,n=e.options,i=n.scroll,a=i===void 0?!0:i,o=n.resize,s=o===void 0?!0:o,u=xr(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&c.forEach(function(d){d.addEventListener("scroll",r.update,fu)}),s&&u.addEventListener("resize",r.update,fu),function(){a&&c.forEach(function(d){d.removeEventListener("scroll",r.update,fu)}),s&&u.removeEventListener("resize",r.update,fu)}}const GJ={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:UJ,data:{}};var qJ={left:"right",right:"left",bottom:"top",top:"bottom"};function Bu(e){return e.replace(/left|right|bottom|top/g,function(t){return qJ[t]})}var YJ={start:"end",end:"start"};function Zy(e){return e.replace(/start|end/g,function(t){return YJ[t]})}function eg(e){var t=xr(e),r=t.pageXOffset,n=t.pageYOffset;return{scrollLeft:r,scrollTop:n}}function tg(e){return Ga(li(e)).left+eg(e).scrollLeft}function XJ(e,t){var r=xr(e),n=li(e),i=r.visualViewport,a=n.clientWidth,o=n.clientHeight,s=0,u=0;if(i){a=i.width,o=i.height;var c=fT();(c||!c&&t==="fixed")&&(s=i.offsetLeft,u=i.offsetTop)}return{width:a,height:o,x:s+tg(e),y:u}}function ZJ(e){var t,r=li(e),n=eg(e),i=(t=e.ownerDocument)==null?void 0:t.body,a=Mi(r.scrollWidth,r.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=Mi(r.scrollHeight,r.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-n.scrollLeft+tg(e),u=-n.scrollTop;return kn(i||r).direction==="rtl"&&(s+=Mi(r.clientWidth,i?i.clientWidth:0)-a),{width:a,height:o,x:s,y:u}}function rg(e){var t=kn(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+i+n)}function yT(e){return["html","body","#document"].indexOf(gn(e))>=0?e.ownerDocument.body:Lr(e)&&rg(e)?e:yT(ud(e))}function gs(e,t){var r;t===void 0&&(t=[]);var n=yT(e),i=n===((r=e.ownerDocument)==null?void 0:r.body),a=xr(n),o=i?[a].concat(a.visualViewport||[],rg(n)?n:[]):n,s=t.concat(o);return i?s:s.concat(gs(ud(o)))}function Kp(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function KJ(e,t){var r=Ga(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function Ky(e,t,r){return t===dT?Kp(XJ(e,r)):Oi(t)?KJ(t,r):Kp(ZJ(li(e)))}function QJ(e){var t=gs(ud(e)),r=["absolute","fixed"].indexOf(kn(e).position)>=0,n=r&&Lr(e)?hl(e):e;return Oi(n)?t.filter(function(i){return Oi(i)&&pT(i,n)&&gn(i)!=="body"}):[]}function JJ(e,t,r,n){var i=t==="clippingParents"?QJ(e):[].concat(t),a=[].concat(i,[r]),o=a[0],s=a.reduce(function(u,c){var d=Ky(e,c,n);return u.top=Mi(d.top,u.top),u.right=cc(d.right,u.right),u.bottom=cc(d.bottom,u.bottom),u.left=Mi(d.left,u.left),u},Ky(e,o,n));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function bT(e){var t=e.reference,r=e.element,n=e.placement,i=n?hn(n):null,a=n?qa(n):null,o=t.x+t.width/2-r.width/2,s=t.y+t.height/2-r.height/2,u;switch(i){case mr:u={x:o,y:t.y-r.height};break;case Ir:u={x:o,y:t.y+t.height};break;case Fr:u={x:t.x+t.width,y:s};break;case gr:u={x:t.x-r.width,y:s};break;default:u={x:t.x,y:t.y}}var c=i?J0(i):null;if(c!=null){var d=c==="y"?"height":"width";switch(a){case Va:u[c]=u[c]-(t[d]/2-r[d]/2);break;case Ls:u[c]=u[c]+(t[d]/2-r[d]/2);break}}return u}function Os(e,t){t===void 0&&(t={});var r=t,n=r.placement,i=n===void 0?e.placement:n,a=r.strategy,o=a===void 0?e.strategy:a,s=r.boundary,u=s===void 0?bJ:s,c=r.rootBoundary,d=c===void 0?dT:c,h=r.elementContext,p=h===void 0?Yo:h,m=r.altBoundary,g=m===void 0?!1:m,b=r.padding,_=b===void 0?0:b,w=gT(typeof _!="number"?_:vT(_,dl)),C=p===Yo?_J:Yo,S=e.rects.popper,T=e.elements[g?C:p],M=JJ(Oi(T)?T:T.contextElement||li(e.elements.popper),u,d,o),P=Ga(e.elements.reference),R=bT({reference:P,element:S,strategy:"absolute",placement:i}),k=Kp(Object.assign({},S,R)),I=p===Yo?k:P,$={top:M.top-I.top+w.top,bottom:I.bottom-M.bottom+w.bottom,left:M.left-I.left+w.left,right:I.right-M.right+w.right},G=e.modifiersData.offset;if(p===Yo&&G){var Y=G[i];Object.keys($).forEach(function(B){var X=[Fr,Ir].indexOf(B)>=0?1:-1,U=[mr,Ir].indexOf(B)>=0?"y":"x";$[B]+=Y[U]*X})}return $}function eee(e,t){t===void 0&&(t={});var r=t,n=r.placement,i=r.boundary,a=r.rootBoundary,o=r.padding,s=r.flipVariations,u=r.allowedAutoPlacements,c=u===void 0?hT:u,d=qa(n),h=d?s?qy:qy.filter(function(g){return qa(g)===d}):dl,p=h.filter(function(g){return c.indexOf(g)>=0});p.length===0&&(p=h);var m=p.reduce(function(g,b){return g[b]=Os(e,{placement:b,boundary:i,rootBoundary:a,padding:o})[hn(b)],g},{});return Object.keys(m).sort(function(g,b){return m[g]-m[b]})}function tee(e){if(hn(e)===Z0)return[];var t=Bu(e);return[Zy(e),t,Zy(t)]}function ree(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var i=r.mainAxis,a=i===void 0?!0:i,o=r.altAxis,s=o===void 0?!0:o,u=r.fallbackPlacements,c=r.padding,d=r.boundary,h=r.rootBoundary,p=r.altBoundary,m=r.flipVariations,g=m===void 0?!0:m,b=r.allowedAutoPlacements,_=t.options.placement,w=hn(_),C=w===_,S=u||(C||!g?[Bu(_)]:tee(_)),T=[_].concat(S).reduce(function(ae,se){return ae.concat(hn(se)===Z0?eee(t,{placement:se,boundary:d,rootBoundary:h,padding:c,flipVariations:g,allowedAutoPlacements:b}):se)},[]),M=t.rects.reference,P=t.rects.popper,R=new Map,k=!0,I=T[0],$=0;$<T.length;$++){var G=T[$],Y=hn(G),B=qa(G)===Va,X=[mr,Ir].indexOf(Y)>=0,U=X?"width":"height",Q=Os(t,{placement:G,boundary:d,rootBoundary:h,altBoundary:p,padding:c}),W=X?B?Fr:gr:B?Ir:mr;M[U]>P[U]&&(W=Bu(W));var q=Bu(W),ee=[];if(a&&ee.push(Q[Y]<=0),s&&ee.push(Q[W]<=0,Q[q]<=0),ee.every(function(ae){return ae})){I=G,k=!1;break}R.set(G,ee)}if(k)for(var Z=g?3:1,J=function(se){var ue=T.find(function(me){var pe=R.get(me);if(pe)return pe.slice(0,se).every(function(Ce){return Ce})});if(ue)return I=ue,"break"},ne=Z;ne>0;ne--){var oe=J(ne);if(oe==="break")break}t.placement!==I&&(t.modifiersData[n]._skip=!0,t.placement=I,t.reset=!0)}}const nee={name:"flip",enabled:!0,phase:"main",fn:ree,requiresIfExists:["offset"],data:{_skip:!1}};function Qy(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Jy(e){return[mr,Fr,Ir,gr].some(function(t){return e[t]>=0})}function iee(e){var t=e.state,r=e.name,n=t.rects.reference,i=t.rects.popper,a=t.modifiersData.preventOverflow,o=Os(t,{elementContext:"reference"}),s=Os(t,{altBoundary:!0}),u=Qy(o,n),c=Qy(s,i,a),d=Jy(u),h=Jy(c);t.modifiersData[r]={referenceClippingOffsets:u,popperEscapeOffsets:c,isReferenceHidden:d,hasPopperEscaped:h},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":h})}const aee={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:iee};function oee(e,t,r){var n=hn(e),i=[gr,mr].indexOf(n)>=0?-1:1,a=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,o=a[0],s=a[1];return o=o||0,s=(s||0)*i,[gr,Fr].indexOf(n)>=0?{x:s,y:o}:{x:o,y:s}}function see(e){var t=e.state,r=e.options,n=e.name,i=r.offset,a=i===void 0?[0,0]:i,o=hT.reduce(function(d,h){return d[h]=oee(h,t.rects,a),d},{}),s=o[t.placement],u=s.x,c=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=u,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=o}const lee={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:see};function uee(e){var t=e.state,r=e.name;t.modifiersData[r]=bT({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const cee={name:"popperOffsets",enabled:!0,phase:"read",fn:uee,data:{}};function dee(e){return e==="x"?"y":"x"}function hee(e){var t=e.state,r=e.options,n=e.name,i=r.mainAxis,a=i===void 0?!0:i,o=r.altAxis,s=o===void 0?!1:o,u=r.boundary,c=r.rootBoundary,d=r.altBoundary,h=r.padding,p=r.tether,m=p===void 0?!0:p,g=r.tetherOffset,b=g===void 0?0:g,_=Os(t,{boundary:u,rootBoundary:c,padding:h,altBoundary:d}),w=hn(t.placement),C=qa(t.placement),S=!C,T=J0(w),M=dee(T),P=t.modifiersData.popperOffsets,R=t.rects.reference,k=t.rects.popper,I=typeof b=="function"?b(Object.assign({},t.rects,{placement:t.placement})):b,$=typeof I=="number"?{mainAxis:I,altAxis:I}:Object.assign({mainAxis:0,altAxis:0},I),G=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,Y={x:0,y:0};if(P){if(a){var B,X=T==="y"?mr:gr,U=T==="y"?Ir:Fr,Q=T==="y"?"height":"width",W=P[T],q=W+_[X],ee=W-_[U],Z=m?-k[Q]/2:0,J=C===Va?R[Q]:k[Q],ne=C===Va?-k[Q]:-R[Q],oe=t.elements.arrow,ae=m&&oe?Q0(oe):{width:0,height:0},se=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:mT(),ue=se[X],me=se[U],pe=ms(0,R[Q],ae[Q]),Ce=S?R[Q]/2-Z-pe-ue-$.mainAxis:J-pe-ue-$.mainAxis,ke=S?-R[Q]/2+Z+pe+me+$.mainAxis:ne+pe+me+$.mainAxis,we=t.elements.arrow&&hl(t.elements.arrow),le=we?T==="y"?we.clientTop||0:we.clientLeft||0:0,He=(B=G==null?void 0:G[T])!=null?B:0,Te=W+Ce-He-le,Ae=W+ke-He,$e=ms(m?cc(q,Te):q,W,m?Mi(ee,Ae):ee);P[T]=$e,Y[T]=$e-W}if(s){var Ge,qe=T==="x"?mr:gr,jt=T==="x"?Ir:Fr,pt=P[M],St=M==="y"?"height":"width",Ft=pt+_[qe],Qt=pt-_[jt],bt=[mr,gr].indexOf(w)!==-1,Jt=(Ge=G==null?void 0:G[M])!=null?Ge:0,Mr=bt?Ft:pt-R[St]-k[St]-Jt+$.altAxis,Pr=bt?pt+R[St]+k[St]-Jt-$.altAxis:Qt,Zr=m&&bt?IJ(Mr,pt,Pr):ms(m?Mr:Ft,pt,m?Pr:Qt);P[M]=Zr,Y[M]=Zr-pt}t.modifiersData[n]=Y}}const fee={name:"preventOverflow",enabled:!0,phase:"main",fn:hee,requiresIfExists:["offset"]};function pee(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function mee(e){return e===xr(e)||!Lr(e)?eg(e):pee(e)}function gee(e){var t=e.getBoundingClientRect(),r=Ua(t.width)/e.offsetWidth||1,n=Ua(t.height)/e.offsetHeight||1;return r!==1||n!==1}function vee(e,t,r){r===void 0&&(r=!1);var n=Lr(t),i=Lr(t)&&gee(t),a=li(t),o=Ga(e,i,r),s={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(n||!n&&!r)&&((gn(t)!=="body"||rg(a))&&(s=mee(t)),Lr(t)?(u=Ga(t,!0),u.x+=t.clientLeft,u.y+=t.clientTop):a&&(u.x=tg(a))),{x:o.left+s.scrollLeft-u.x,y:o.top+s.scrollTop-u.y,width:o.width,height:o.height}}function yee(e){var t=new Map,r=new Set,n=[];e.forEach(function(a){t.set(a.name,a)});function i(a){r.add(a.name);var o=[].concat(a.requires||[],a.requiresIfExists||[]);o.forEach(function(s){if(!r.has(s)){var u=t.get(s);u&&i(u)}}),n.push(a)}return e.forEach(function(a){r.has(a.name)||i(a)}),n}function bee(e){var t=yee(e);return RJ.reduce(function(r,n){return r.concat(t.filter(function(i){return i.phase===n}))},[])}function _ee(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function wee(e){var t=e.reduce(function(r,n){var i=r[n.name];return r[n.name]=i?Object.assign({},i,n,{options:Object.assign({},i.options,n.options),data:Object.assign({},i.data,n.data)}):n,r},{});return Object.keys(t).map(function(r){return t[r]})}var eb={placement:"bottom",modifiers:[],strategy:"absolute"};function tb(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(n){return!(n&&typeof n.getBoundingClientRect=="function")})}function Cee(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,n=r===void 0?[]:r,i=t.defaultOptions,a=i===void 0?eb:i;return function(s,u,c){c===void 0&&(c=a);var d={placement:"bottom",orderedModifiers:[],options:Object.assign({},eb,a),modifiersData:{},elements:{reference:s,popper:u},attributes:{},styles:{}},h=[],p=!1,m={state:d,setOptions:function(w){var C=typeof w=="function"?w(d.options):w;b(),d.options=Object.assign({},a,d.options,C),d.scrollParents={reference:Oi(s)?gs(s):s.contextElement?gs(s.contextElement):[],popper:gs(u)};var S=bee(wee([].concat(n,d.options.modifiers)));return d.orderedModifiers=S.filter(function(T){return T.enabled}),g(),m.update()},forceUpdate:function(){if(!p){var w=d.elements,C=w.reference,S=w.popper;if(tb(C,S)){d.rects={reference:vee(C,hl(S),d.options.strategy==="fixed"),popper:Q0(S)},d.reset=!1,d.placement=d.options.placement,d.orderedModifiers.forEach(function($){return d.modifiersData[$.name]=Object.assign({},$.data)});for(var T=0;T<d.orderedModifiers.length;T++){if(d.reset===!0){d.reset=!1,T=-1;continue}var M=d.orderedModifiers[T],P=M.fn,R=M.options,k=R===void 0?{}:R,I=M.name;typeof P=="function"&&(d=P({state:d,options:k,name:I,instance:m})||d)}}}},update:_ee(function(){return new Promise(function(_){m.forceUpdate(),_(d)})}),destroy:function(){b(),p=!0}};if(!tb(s,u))return m;m.setOptions(c).then(function(_){!p&&c.onFirstUpdate&&c.onFirstUpdate(_)});function g(){d.orderedModifiers.forEach(function(_){var w=_.name,C=_.options,S=C===void 0?{}:C,T=_.effect;if(typeof T=="function"){var M=T({state:d,name:w,instance:m,options:S}),P=function(){};h.push(M||P)}})}function b(){h.forEach(function(_){return _()}),h=[]}return m}}var xee=[GJ,cee,VJ,kJ,lee,nee,fee,zJ,aee],Tee=Cee({defaultModifiers:xee});function See(e){return y.generateUtilityClass("MuiPopper",e)}y.generateUtilityClasses("MuiPopper",["root"]);function Mee(e,t){if(t==="ltr")return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}function dc(e){return typeof e=="function"?e():e}function cd(e){return e.nodeType!==void 0}function Pee(e){return!cd(e)}const Eee=e=>{const{classes:t}=e,r={root:["root"]};return y.composeClasses(r,See,t)},Aee={},Ree=de.forwardRef(function(t,r){var Q;const U=t,{anchorEl:n,children:i,direction:a,disablePortal:o,modifiers:s,open:u,placement:c,popperOptions:d,popperRef:h,slotProps:p={},slots:m={},TransitionProps:g,ownerState:b}=U,_=Ye(U,["anchorEl","children","direction","disablePortal","modifiers","open","placement","popperOptions","popperRef","slotProps","slots","TransitionProps","ownerState"]),w=de.useRef(null),C=y.useForkRef(w,r),S=de.useRef(null),T=y.useForkRef(S,h),M=de.useRef(T);y.useEnhancedEffect(()=>{M.current=T},[T]),de.useImperativeHandle(h,()=>S.current,[]);const P=Mee(c,a),[R,k]=de.useState(P),[I,$]=de.useState(dc(n));de.useEffect(()=>{S.current&&S.current.forceUpdate()}),de.useEffect(()=>{n&&$(dc(n))},[n]),y.useEnhancedEffect(()=>{if(!I||!u)return;const W=Z=>{k(Z.placement)};if(process.env.NODE_ENV!=="production"&&I&&cd(I)&&I.nodeType===1){const Z=I.getBoundingClientRect();process.env.NODE_ENV!=="test"&&Z.top===0&&Z.left===0&&Z.right===0&&Z.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
279
+ `))}let q=[{name:"preventOverflow",options:{altBoundary:o}},{name:"flip",options:{altBoundary:o}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:Z})=>{W(Z)}}];s!=null&&(q=q.concat(s)),d&&d.modifiers!=null&&(q=q.concat(d.modifiers));const ee=Tee(I,w.current,z(D({placement:P},d),{modifiers:q}));return M.current(ee),()=>{ee.destroy(),M.current(null)}},[I,o,s,u,d,P]);const G={placement:R};g!==null&&(G.TransitionProps=g);const Y=Eee(t),B=(Q=m.root)!=null?Q:"div",X=y.useSlotProps({elementType:B,externalSlotProps:p.root,externalForwardedProps:_,additionalProps:{role:"tooltip",ref:C},ownerState:t,className:Y.root});return _e.jsx(B,z(D({},X),{children:typeof i=="function"?i(G):i}))}),_T=de.forwardRef(function(t,r){const $=t,{anchorEl:n,children:i,container:a,direction:o="ltr",disablePortal:s=!1,keepMounted:u=!1,modifiers:c,open:d,placement:h="bottom",popperOptions:p=Aee,popperRef:m,style:g,transition:b=!1,slotProps:_={},slots:w={}}=$,C=Ye($,["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"]),[S,T]=de.useState(!0),M=()=>{T(!1)},P=()=>{T(!0)};if(!u&&!d&&(!b||S))return null;let R;if(a)R=a;else if(n){const G=dc(n);R=G&&cd(G)?y.ownerDocument(G).body:y.ownerDocument(null).body}const k=!d&&u&&(!b||S)?"none":void 0,I=b?{in:d,onEnter:M,onExited:P}:void 0;return _e.jsx(y.Portal,{disablePortal:s,container:R,children:_e.jsx(Ree,z(D({anchorEl:n,direction:o,disablePortal:s,modifiers:c,ref:r,open:b?!S:d,placement:h,popperOptions:p,popperRef:m,slotProps:_,slots:w},C),{style:D({position:"fixed",top:0,left:0,display:k},g),TransitionProps:I,children:i}))})});process.env.NODE_ENV!=="production"&&(_T.propTypes={anchorEl:y.chainPropTypes(y.PropTypes.oneOfType([y.HTMLElementType,y.PropTypes.object,y.PropTypes.func]),e=>{if(e.open){const t=dc(e.anchorEl);if(t&&cd(t)&&t.nodeType===1){const r=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&r.top===0&&r.left===0&&r.right===0&&r.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
280
+ `))}else if(!t||typeof t.getBoundingClientRect!="function"||Pee(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(`
281
+ `))}return null}),children:y.PropTypes.oneOfType([y.PropTypes.node,y.PropTypes.func]),container:y.PropTypes.oneOfType([y.HTMLElementType,y.PropTypes.func]),direction:y.PropTypes.oneOf(["ltr","rtl"]),disablePortal:y.PropTypes.bool,keepMounted:y.PropTypes.bool,modifiers:y.PropTypes.arrayOf(y.PropTypes.shape({data:y.PropTypes.object,effect:y.PropTypes.func,enabled:y.PropTypes.bool,fn:y.PropTypes.func,name:y.PropTypes.any,options:y.PropTypes.object,phase:y.PropTypes.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:y.PropTypes.arrayOf(y.PropTypes.string),requiresIfExists:y.PropTypes.arrayOf(y.PropTypes.string)})),open:y.PropTypes.bool.isRequired,placement:y.PropTypes.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:y.PropTypes.shape({modifiers:y.PropTypes.array,onFirstUpdate:y.PropTypes.func,placement:y.PropTypes.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:y.PropTypes.oneOf(["absolute","fixed"])}),popperRef:y.refType,slotProps:y.PropTypes.shape({root:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({root:y.PropTypes.elementType}),transition:y.PropTypes.bool});const Dee=y.styled(_T,{name:"MuiPopper",slot:"Root",overridesResolver:(e,t)=>t.root})({}),fl=de.forwardRef(function(t,r){var k;const n=y.useRtl(),R=y.useDefaultProps({props:t,name:"MuiPopper"}),{anchorEl:a,component:o,components:s,componentsProps:u,container:c,disablePortal:d,keepMounted:h,modifiers:p,open:m,placement:g,popperOptions:b,popperRef:_,transition:w,slots:C,slotProps:S}=R,T=Ye(R,["anchorEl","component","components","componentsProps","container","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","transition","slots","slotProps"]),M=(k=C==null?void 0:C.root)!=null?k:s==null?void 0:s.Root,P=D({anchorEl:a,container:c,disablePortal:d,keepMounted:h,modifiers:p,open:m,placement:g,popperOptions:b,popperRef:_,transition:w},T);return _e.jsx(Dee,z(D({as:o,direction:n?"rtl":"ltr",slots:{root:M},slotProps:S!=null?S:u},P),{ref:r}))});process.env.NODE_ENV!=="production"&&(fl.propTypes={anchorEl:y.PropTypes.oneOfType([y.HTMLElementType,y.PropTypes.object,y.PropTypes.func]),children:y.PropTypes.oneOfType([y.PropTypes.node,y.PropTypes.func]),component:y.PropTypes.elementType,components:y.PropTypes.shape({Root:y.PropTypes.elementType}),componentsProps:y.PropTypes.shape({root:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),container:y.PropTypes.oneOfType([y.HTMLElementType,y.PropTypes.func]),disablePortal:y.PropTypes.bool,keepMounted:y.PropTypes.bool,modifiers:y.PropTypes.arrayOf(y.PropTypes.shape({data:y.PropTypes.object,effect:y.PropTypes.func,enabled:y.PropTypes.bool,fn:y.PropTypes.func,name:y.PropTypes.any,options:y.PropTypes.object,phase:y.PropTypes.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:y.PropTypes.arrayOf(y.PropTypes.string),requiresIfExists:y.PropTypes.arrayOf(y.PropTypes.string)})),open:y.PropTypes.bool.isRequired,placement:y.PropTypes.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:y.PropTypes.shape({modifiers:y.PropTypes.array,onFirstUpdate:y.PropTypes.func,placement:y.PropTypes.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:y.PropTypes.oneOf(["absolute","fixed"])}),popperRef:y.refType,slotProps:y.PropTypes.shape({root:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({root:y.PropTypes.elementType}),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),transition:y.PropTypes.bool});function Nee(e){return y.generateUtilityClass("MuiTooltip",e)}const ft=y.generateUtilityClasses("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);function kee(e){return Math.round(e*1e5)/1e5}const Lee=e=>{const{classes:t,disableInteractive:r,arrow:n,touch:i,placement:a}=e,o={popper:["popper",!r&&"popperInteractive",n&&"popperArrow"],tooltip:["tooltip",n&&"tooltipArrow",i&&"touch",`tooltipPlacement${y.capitalize(a.split("-")[0])}`],arrow:["arrow"]};return y.composeClasses(o,Nee,t)},Oee=y.styled(fl,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.popper,!r.disableInteractive&&t.popperInteractive,r.arrow&&t.popperArrow,!r.open&&t.popperClose]}})(y.memoTheme(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:t})=>!t.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:t})=>!t,style:{pointerEvents:"none"}},{props:({ownerState:t})=>t.arrow,style:{[`&[data-popper-placement*="bottom"] .${ft.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${ft.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${ft.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${ft.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="right"] .${ft.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="right"] .${ft.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="left"] .${ft.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="left"] .${ft.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),Iee=y.styled("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.tooltip,r.touch&&t.touch,r.arrow&&t.tooltipArrow,t[`tooltipPlacement${y.capitalize(r.placement.split("-")[0])}`]]}})(y.memoTheme(({theme:e})=>({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:y.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${ft.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${ft.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${ft.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${ft.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:t})=>t.arrow,style:{position:"relative",margin:0}},{props:({ownerState:t})=>t.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${kee(16/14)}em`,fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:t})=>!t.isRtl,style:{[`.${ft.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${ft.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:t})=>!t.isRtl&&t.touch,style:{[`.${ft.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${ft.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:t})=>!!t.isRtl,style:{[`.${ft.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${ft.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:t})=>!!t.isRtl&&t.touch,style:{[`.${ft.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${ft.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${ft.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${ft.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]}))),Fee=y.styled("span",{name:"MuiTooltip",slot:"Arrow",overridesResolver:(e,t)=>t.arrow})(y.memoTheme(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:y.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let pu=!1;const rb=new y.Timeout;let Xo={x:0,y:0};function mu(e,t){return(r,...n)=>{t&&t(r,...n),e(r,...n)}}const Ii=de.forwardRef(function(t,r){var Sl,Ki,Ml;const n=y.useDefaultProps({props:t,name:"MuiTooltip"}),Tl=n,{arrow:i=!1,children:a,classes:o,components:s={},componentsProps:u={},describeChild:c=!1,disableFocusListener:d=!1,disableHoverListener:h=!1,disableInteractive:p=!1,disableTouchListener:m=!1,enterDelay:g=100,enterNextDelay:b=0,enterTouchDelay:_=700,followCursor:w=!1,id:C,leaveDelay:S=0,leaveTouchDelay:T=1500,onClose:M,onOpen:P,open:R,placement:k="bottom",PopperComponent:I,PopperProps:$={},slotProps:G={},slots:Y={},title:B,TransitionComponent:X,TransitionProps:U}=Tl,Q=Ye(Tl,["arrow","children","classes","components","componentsProps","describeChild","disableFocusListener","disableHoverListener","disableInteractive","disableTouchListener","enterDelay","enterNextDelay","enterTouchDelay","followCursor","id","leaveDelay","leaveTouchDelay","onClose","onOpen","open","placement","PopperComponent","PopperProps","slotProps","slots","title","TransitionComponent","TransitionProps"]),W=de.isValidElement(a)?a:_e.jsx("span",{children:a}),q=y.useTheme(),ee=y.useRtl(),[Z,J]=de.useState(),[ne,oe]=de.useState(null),ae=de.useRef(!1),se=p||w,ue=y.useTimeout(),me=y.useTimeout(),pe=y.useTimeout(),Ce=y.useTimeout(),[ke,we]=Xm({controlled:R,default:!1,name:"Tooltip",state:"open"});let le=ke;if(process.env.NODE_ENV!=="production"){const{current:Re}=de.useRef(R!==void 0);de.useEffect(()=>{Z&&Z.disabled&&!Re&&B!==""&&Z.tagName.toLowerCase()==="button"&&console.warn(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(`
282
+ `))},[B,Z,Re])}const He=Mc(C),Te=de.useRef(),Ae=y.useEventCallback(()=>{Te.current!==void 0&&(document.body.style.WebkitUserSelect=Te.current,Te.current=void 0),Ce.clear()});de.useEffect(()=>Ae,[Ae]);const $e=Re=>{rb.clear(),pu=!0,we(!0),P&&!le&&P(Re)},Ge=y.useEventCallback(Re=>{rb.start(800+S,()=>{pu=!1}),we(!1),M&&le&&M(Re),ue.start(q.transitions.duration.shortest,()=>{ae.current=!1})}),qe=Re=>{ae.current&&Re.type!=="touchstart"||(Z&&Z.removeAttribute("title"),me.clear(),pe.clear(),g||pu&&b?me.start(pu?b:g,()=>{$e(Re)}):$e(Re))},jt=Re=>{me.clear(),pe.start(S,()=>{Ge(Re)})},[,pt]=de.useState(!1),St=Re=>{y.isFocusVisible(Re.target)||(pt(!1),jt(Re))},Ft=Re=>{Z||J(Re.currentTarget),y.isFocusVisible(Re.target)&&(pt(!0),qe(Re))},Qt=Re=>{ae.current=!0;const yr=W.props;yr.onTouchStart&&yr.onTouchStart(Re)},bt=Re=>{Qt(Re),pe.clear(),ue.clear(),Ae(),Te.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",Ce.start(_,()=>{document.body.style.WebkitUserSelect=Te.current,qe(Re)})},Jt=Re=>{W.props.onTouchEnd&&W.props.onTouchEnd(Re),Ae(),pe.start(T,()=>{Ge(Re)})};de.useEffect(()=>{if(!le)return;function Re(yr){yr.key==="Escape"&&Ge(yr)}return document.addEventListener("keydown",Re),()=>{document.removeEventListener("keydown",Re)}},[Ge,le]);const Mr=y.useForkRef(y.getReactElementRef(W),J,r);!B&&B!==0&&(le=!1);const Pr=de.useRef(),Zr=Re=>{const yr=W.props;yr.onMouseMove&&yr.onMouseMove(Re),Xo={x:Re.clientX,y:Re.clientY},Pr.current&&Pr.current.update()},Br={},Cn=typeof B=="string";c?(Br.title=!le&&Cn&&!h?B:null,Br["aria-describedby"]=le?He:null):(Br["aria-label"]=Cn?B:null,Br["aria-labelledby"]=le&&!Cn?He:null);const Nt=D(z(D(D(D({},Br),Q),W.props),{className:y.clsx(Q.className,W.props.className),onTouchStart:Qt,ref:Mr}),w?{onMouseMove:Zr}:{});process.env.NODE_ENV!=="production"&&(Nt["data-mui-internal-clone-element"]=!0,de.useEffect(()=>{Z&&!Z.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(`
283
+ `))},[Z]));const Kr={};m||(Nt.onTouchStart=bt,Nt.onTouchEnd=Jt),h||(Nt.onMouseOver=mu(qe,Nt.onMouseOver),Nt.onMouseLeave=mu(jt,Nt.onMouseLeave),se||(Kr.onMouseOver=qe,Kr.onMouseLeave=jt)),d||(Nt.onFocus=mu(Ft,Nt.onFocus),Nt.onBlur=mu(St,Nt.onBlur),se||(Kr.onFocus=Ft,Kr.onBlur=St)),process.env.NODE_ENV!=="production"&&W.props.title&&console.error(["MUI: You have provided a `title` prop to the child of <Tooltip />.",`Remove this title prop \`${W.props.title}\` or the Tooltip component.`].join(`
284
+ `));const We=z(D({},n),{isRtl:ee,arrow:i,disableInteractive:se,placement:k,PopperComponentProp:I,touch:ae.current}),_t=typeof G.popper=="function"?G.popper(We):G.popper,ci=de.useMemo(()=>{var yr,Pl;let Re=[{name:"arrow",enabled:!!ne,options:{element:ne,padding:4}}];return(yr=$.popperOptions)!=null&&yr.modifiers&&(Re=Re.concat($.popperOptions.modifiers)),(Pl=_t==null?void 0:_t.popperOptions)!=null&&Pl.modifiers&&(Re=Re.concat(_t.popperOptions.modifiers)),z(D(D({},$.popperOptions),_t==null?void 0:_t.popperOptions),{modifiers:Re})},[ne,$.popperOptions,_t==null?void 0:_t.popperOptions]),So=Lee(We),xn=typeof G.transition=="function"?G.transition(We):G.transition,Zi={slots:D({popper:s.Popper,transition:(Sl=s.Transition)!=null?Sl:X,tooltip:s.Tooltip,arrow:s.Arrow},Y),slotProps:{arrow:(Ki=G.arrow)!=null?Ki:u.arrow,popper:D(D({},$),_t!=null?_t:u.popper),tooltip:(Ml=G.tooltip)!=null?Ml:u.tooltip,transition:D(D({},U),xn!=null?xn:u.transition)}},[Hd,wl]=y.useSlot("popper",{elementType:Oee,externalForwardedProps:Zi,ownerState:We,className:y.clsx(So.popper,$==null?void 0:$.className)}),[Cl,xl]=y.useSlot("transition",{elementType:y.Grow,externalForwardedProps:Zi,ownerState:We}),[Wd,jd]=y.useSlot("tooltip",{elementType:Iee,className:So.tooltip,externalForwardedProps:Zi,ownerState:We}),[Vd,Ud]=y.useSlot("arrow",{elementType:Fee,className:So.arrow,externalForwardedProps:Zi,ownerState:We,ref:oe});return _e.jsxs(de.Fragment,{children:[de.cloneElement(W,Nt),_e.jsx(Hd,z(D(D({as:I!=null?I:fl,placement:k,anchorEl:w?{getBoundingClientRect:()=>({top:Xo.y,left:Xo.x,right:Xo.x,bottom:Xo.y,width:0,height:0})}:Z,popperRef:Pr,open:Z?le:!1,id:He,transition:!0},Kr),wl),{popperOptions:ci,children:({TransitionProps:Re})=>_e.jsx(Cl,z(D(D({timeout:q.transitions.duration.shorter},Re),xl),{children:_e.jsxs(Wd,z(D({},jd),{children:[B,i?_e.jsx(Vd,D({},Ud)):null]}))}))}))]})});process.env.NODE_ENV!=="production"&&(Ii.propTypes={arrow:y.PropTypes.bool,children:y.elementAcceptingRef.isRequired,classes:y.PropTypes.object,className:y.PropTypes.string,components:y.PropTypes.shape({Arrow:y.PropTypes.elementType,Popper:y.PropTypes.elementType,Tooltip:y.PropTypes.elementType,Transition:y.PropTypes.elementType}),componentsProps:y.PropTypes.shape({arrow:y.PropTypes.object,popper:y.PropTypes.object,tooltip:y.PropTypes.object,transition:y.PropTypes.object}),describeChild:y.PropTypes.bool,disableFocusListener:y.PropTypes.bool,disableHoverListener:y.PropTypes.bool,disableInteractive:y.PropTypes.bool,disableTouchListener:y.PropTypes.bool,enterDelay:y.PropTypes.number,enterNextDelay:y.PropTypes.number,enterTouchDelay:y.PropTypes.number,followCursor:y.PropTypes.bool,id:y.PropTypes.string,leaveDelay:y.PropTypes.number,leaveTouchDelay:y.PropTypes.number,onClose:y.PropTypes.func,onOpen:y.PropTypes.func,open:y.PropTypes.bool,placement:y.PropTypes.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:y.PropTypes.elementType,PopperProps:y.PropTypes.object,slotProps:y.PropTypes.shape({arrow:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),popper:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),tooltip:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object]),transition:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({arrow:y.PropTypes.elementType,popper:y.PropTypes.elementType,tooltip:y.PropTypes.elementType,transition:y.PropTypes.elementType}),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),title:y.PropTypes.node,TransitionComponent:y.PropTypes.elementType,TransitionProps:y.PropTypes.object});var wT={exports:{}};/*!
285
+ Copyright (c) 2018 Jed Watson.
286
+ Licensed under the MIT License (MIT), see
287
+ http://jedwatson.github.io/classnames
288
+ */(function(e){(function(){var t={}.hasOwnProperty;function r(){for(var a="",o=0;o<arguments.length;o++){var s=arguments[o];s&&(a=i(a,n(s)))}return a}function n(a){if(typeof a=="string"||typeof a=="number")return a;if(typeof a!="object")return"";if(Array.isArray(a))return r.apply(null,a);if(a.toString!==Object.prototype.toString&&!a.toString.toString().includes("[native code]"))return a.toString();var o="";for(var s in a)t.call(a,s)&&a[s]&&(o=i(o,s));return o}function i(a,o){return o?a?a+" "+o:a+o:a}e.exports?(r.default=r,e.exports=r):window.classNames=r})()})(wT);var $ee=wT.exports;const Is=O.getDefaultExportFromCjs($ee);function ot(){return ot=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ot.apply(null,arguments)}function rt(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ln(e){"@babel/helpers - typeof";return Ln=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},Ln(e)}function Bee(e,t){if(Ln(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ln(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function CT(e){var t=Bee(e,"string");return Ln(t)=="symbol"?t:t+""}function nb(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,CT(n.key),n)}}function nt(e,t,r){return t&&nb(e.prototype,t),r&&nb(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Qp(e,t){return Qp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},Qp(e,t)}function Tt(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&&Qp(e,t)}function he(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Wt(e,t){if(t&&(Ln(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return he(e)}function Be(e){return Be=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},Be(e)}function ie(e,t,r){return(t=CT(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var sn=function(t,r,n,i,a,o,s,u){if(process.env.NODE_ENV!=="production"&&r===void 0)throw new Error("invariant requires an error message argument");if(!t){var c;if(r===void 0)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var d=[n,i,a,o,s,u],h=0;c=new Error("Invariant Violation: "+r.replace(/%s/g,function(){return d[h++]}))}throw c.framesToPop=1,c}},gu=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},zee=Array.isArray,$r=zee,Hee=typeof gu=="object"&&gu&&gu.Object===Object&&gu,xT=Hee,Wee=xT,jee=typeof self=="object"&&self&&self.Object===Object&&self,Vee=Wee||jee||Function("return this")(),_n=Vee,Uee=_n,Gee=Uee.Symbol,pl=Gee,ib=pl,TT=Object.prototype,qee=TT.hasOwnProperty,Yee=TT.toString,Zo=ib?ib.toStringTag:void 0;function Xee(e){var t=qee.call(e,Zo),r=e[Zo];try{e[Zo]=void 0;var n=!0}catch(a){}var i=Yee.call(e);return n&&(t?e[Zo]=r:delete e[Zo]),i}var Zee=Xee,Kee=Object.prototype,Qee=Kee.toString;function Jee(e){return Qee.call(e)}var ete=Jee,ab=pl,tte=Zee,rte=ete,nte="[object Null]",ite="[object Undefined]",ob=ab?ab.toStringTag:void 0;function ate(e){return e==null?e===void 0?ite:nte:ob&&ob in Object(e)?tte(e):rte(e)}var Gi=ate;function ote(e){return e!=null&&typeof e=="object"}var ui=ote,ste=Gi,lte=ui,ute="[object Symbol]";function cte(e){return typeof e=="symbol"||lte(e)&&ste(e)==ute}var dd=cte,dte=$r,hte=dd,fte=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,pte=/^\w*$/;function mte(e,t){if(dte(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||hte(e)?!0:pte.test(e)||!fte.test(e)||t!=null&&e in Object(t)}var gte=mte;function vte(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var qi=vte,yte=Gi,bte=qi,_te="[object AsyncFunction]",wte="[object Function]",Cte="[object GeneratorFunction]",xte="[object Proxy]";function Tte(e){if(!bte(e))return!1;var t=yte(e);return t==wte||t==Cte||t==_te||t==xte}var ST=Tte,Ste=_n,Mte=Ste["__core-js_shared__"],Pte=Mte,uf=Pte,sb=function(){var e=/[^.]+$/.exec(uf&&uf.keys&&uf.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Ete(e){return!!sb&&sb in e}var Ate=Ete,Rte=Function.prototype,Dte=Rte.toString;function Nte(e){if(e!=null){try{return Dte.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var MT=Nte,kte=ST,Lte=Ate,Ote=qi,Ite=MT,Fte=/[\\^$.*+?()[\]{}|]/g,$te=/^\[object .+?Constructor\]$/,Bte=Function.prototype,zte=Object.prototype,Hte=Bte.toString,Wte=zte.hasOwnProperty,jte=RegExp("^"+Hte.call(Wte).replace(Fte,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Vte(e){if(!Ote(e)||Lte(e))return!1;var t=kte(e)?jte:$te;return t.test(Ite(e))}var Ute=Vte;function Gte(e,t){return e==null?void 0:e[t]}var qte=Gte,Yte=Ute,Xte=qte;function Zte(e,t){var r=Xte(e,t);return Yte(r)?r:void 0}var Yi=Zte,Kte=Yi,Qte=Kte(Object,"create"),hd=Qte,lb=hd;function Jte(){this.__data__=lb?lb(null):{},this.size=0}var ere=Jte;function tre(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var rre=tre,nre=hd,ire="__lodash_hash_undefined__",are=Object.prototype,ore=are.hasOwnProperty;function sre(e){var t=this.__data__;if(nre){var r=t[e];return r===ire?void 0:r}return ore.call(t,e)?t[e]:void 0}var lre=sre,ure=hd,cre=Object.prototype,dre=cre.hasOwnProperty;function hre(e){var t=this.__data__;return ure?t[e]!==void 0:dre.call(t,e)}var fre=hre,pre=hd,mre="__lodash_hash_undefined__";function gre(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=pre&&t===void 0?mre:t,this}var vre=gre,yre=ere,bre=rre,_re=lre,wre=fre,Cre=vre;function vo(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])}}vo.prototype.clear=yre;vo.prototype.delete=bre;vo.prototype.get=_re;vo.prototype.has=wre;vo.prototype.set=Cre;var xre=vo;function Tre(){this.__data__=[],this.size=0}var Sre=Tre;function Mre(e,t){return e===t||e!==e&&t!==t}var PT=Mre,Pre=PT;function Ere(e,t){for(var r=e.length;r--;)if(Pre(e[r][0],t))return r;return-1}var fd=Ere,Are=fd,Rre=Array.prototype,Dre=Rre.splice;function Nre(e){var t=this.__data__,r=Are(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():Dre.call(t,r,1),--this.size,!0}var kre=Nre,Lre=fd;function Ore(e){var t=this.__data__,r=Lre(t,e);return r<0?void 0:t[r][1]}var Ire=Ore,Fre=fd;function $re(e){return Fre(this.__data__,e)>-1}var Bre=$re,zre=fd;function Hre(e,t){var r=this.__data__,n=zre(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var Wre=Hre,jre=Sre,Vre=kre,Ure=Ire,Gre=Bre,qre=Wre;function yo(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])}}yo.prototype.clear=jre;yo.prototype.delete=Vre;yo.prototype.get=Ure;yo.prototype.has=Gre;yo.prototype.set=qre;var pd=yo,Yre=Yi,Xre=_n,Zre=Yre(Xre,"Map"),ng=Zre,ub=xre,Kre=pd,Qre=ng;function Jre(){this.size=0,this.__data__={hash:new ub,map:new(Qre||Kre),string:new ub}}var ene=Jre;function tne(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var rne=tne,nne=rne;function ine(e,t){var r=e.__data__;return nne(t)?r[typeof t=="string"?"string":"hash"]:r.map}var md=ine,ane=md;function one(e){var t=ane(this,e).delete(e);return this.size-=t?1:0,t}var sne=one,lne=md;function une(e){return lne(this,e).get(e)}var cne=une,dne=md;function hne(e){return dne(this,e).has(e)}var fne=hne,pne=md;function mne(e,t){var r=pne(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var gne=mne,vne=ene,yne=sne,bne=cne,_ne=fne,wne=gne;function bo(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])}}bo.prototype.clear=vne;bo.prototype.delete=yne;bo.prototype.get=bne;bo.prototype.has=_ne;bo.prototype.set=wne;var ET=bo,AT=ET,Cne="Expected a function";function ig(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Cne);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var o=e.apply(this,n);return r.cache=a.set(i,o)||a,o};return r.cache=new(ig.Cache||AT),r}ig.Cache=AT;var xne=ig,Tne=xne,Sne=500;function Mne(e){var t=Tne(e,function(n){return r.size===Sne&&r.clear(),n}),r=t.cache;return t}var Pne=Mne,Ene=Pne,Ane=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Rne=/\\(\\)?/g,Dne=Ene(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(Ane,function(r,n,i,a){t.push(i?a.replace(Rne,"$1"):n||r)}),t}),Nne=Dne;function kne(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 Lne=kne,cb=pl,One=Lne,Ine=$r,Fne=dd,$ne=1/0,db=cb?cb.prototype:void 0,hb=db?db.toString:void 0;function RT(e){if(typeof e=="string")return e;if(Ine(e))return One(e,RT)+"";if(Fne(e))return hb?hb.call(e):"";var t=e+"";return t=="0"&&1/e==-$ne?"-0":t}var Bne=RT,zne=Bne;function Hne(e){return e==null?"":zne(e)}var DT=Hne,Wne=$r,jne=gte,Vne=Nne,Une=DT;function Gne(e,t){return Wne(e)?e:jne(e,t)?[e]:Vne(Une(e))}var gd=Gne,qne=dd,Yne=1/0;function Xne(e){if(typeof e=="string"||qne(e))return e;var t=e+"";return t=="0"&&1/e==-Yne?"-0":t}var ag=Xne,Zne=gd,Kne=ag;function Qne(e,t){t=Zne(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[Kne(t[r++])];return r&&r==n?e:void 0}var NT=Qne,Jne=Yi,eie=function(){try{var e=Jne(Object,"defineProperty");return e({},"",{}),e}catch(t){}}(),kT=eie,fb=kT;function tie(e,t,r){t=="__proto__"&&fb?fb(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var LT=tie,rie=LT,nie=PT,iie=Object.prototype,aie=iie.hasOwnProperty;function oie(e,t,r){var n=e[t];(!(aie.call(e,t)&&nie(n,r))||r===void 0&&!(t in e))&&rie(e,t,r)}var og=oie,sie=9007199254740991,lie=/^(?:0|[1-9]\d*)$/;function uie(e,t){var r=typeof e;return t=t==null?sie:t,!!t&&(r=="number"||r!="symbol"&&lie.test(e))&&e>-1&&e%1==0&&e<t}var sg=uie,cie=og,die=gd,hie=sg,pb=qi,fie=ag;function pie(e,t,r,n){if(!pb(e))return e;t=die(t,e);for(var i=-1,a=t.length,o=a-1,s=e;s!=null&&++i<a;){var u=fie(t[i]),c=r;if(u==="__proto__"||u==="constructor"||u==="prototype")return e;if(i!=o){var d=s[u];c=n?n(d,u,s):void 0,c===void 0&&(c=pb(d)?d:hie(t[i+1])?[]:{})}cie(s,u,c),s=s[u]}return e}var mie=pie,gie=NT,vie=mie,yie=gd;function bie(e,t,r){for(var n=-1,i=t.length,a={};++n<i;){var o=t[n],s=gie(e,o);r(s,o)&&vie(a,yie(o,e),s)}return a}var _ie=bie;function wie(e,t){return e!=null&&t in Object(e)}var Cie=wie,xie=Gi,Tie=ui,Sie="[object Arguments]";function Mie(e){return Tie(e)&&xie(e)==Sie}var Pie=Mie,mb=Pie,Eie=ui,OT=Object.prototype,Aie=OT.hasOwnProperty,Rie=OT.propertyIsEnumerable,Die=mb(function(){return arguments}())?mb:function(e){return Eie(e)&&Aie.call(e,"callee")&&!Rie.call(e,"callee")},vd=Die,Nie=9007199254740991;function kie(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Nie}var lg=kie,Lie=gd,Oie=vd,Iie=$r,Fie=sg,$ie=lg,Bie=ag;function zie(e,t,r){t=Lie(t,e);for(var n=-1,i=t.length,a=!1;++n<i;){var o=Bie(t[n]);if(!(a=e!=null&&r(e,o)))break;e=e[o]}return a||++n!=i?a:(i=e==null?0:e.length,!!i&&$ie(i)&&Fie(o,i)&&(Iie(e)||Oie(e)))}var Hie=zie,Wie=Cie,jie=Hie;function Vie(e,t){return e!=null&&jie(e,t,Wie)}var Uie=Vie,Gie=_ie,qie=Uie;function Yie(e,t){return Gie(e,t,function(r,n){return qie(e,n)})}var Xie=Yie;function Zie(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var yd=Zie,gb=pl,Kie=vd,Qie=$r,vb=gb?gb.isConcatSpreadable:void 0;function Jie(e){return Qie(e)||Kie(e)||!!(vb&&e&&e[vb])}var eae=Jie,tae=yd,rae=eae;function IT(e,t,r,n,i){var a=-1,o=e.length;for(r||(r=rae),i||(i=[]);++a<o;){var s=e[a];t>0&&r(s)?t>1?IT(s,t-1,r,n,i):tae(i,s):n||(i[i.length]=s)}return i}var FT=IT,nae=FT;function iae(e){var t=e==null?0:e.length;return t?nae(e,1):[]}var aae=iae;function oae(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 sae=oae,lae=sae,yb=Math.max;function uae(e,t,r){return t=yb(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,a=yb(n.length-t,0),o=Array(a);++i<a;)o[i]=n[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=n[i];return s[t]=r(o),lae(e,this,s)}}var cae=uae;function dae(e){return function(){return e}}var hae=dae;function fae(e){return e}var $T=fae,pae=hae,bb=kT,mae=$T,gae=bb?function(e,t){return bb(e,"toString",{configurable:!0,enumerable:!1,value:pae(t),writable:!0})}:mae,vae=gae,yae=800,bae=16,_ae=Date.now;function wae(e){var t=0,r=0;return function(){var n=_ae(),i=bae-(n-r);if(r=n,i>0){if(++t>=yae)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Cae=wae,xae=vae,Tae=Cae,Sae=Tae(xae),Mae=Sae,Pae=aae,Eae=cae,Aae=Mae;function Rae(e){return Aae(Eae(e,void 0,Pae),e+"")}var Dae=Rae,Nae=Xie,kae=Dae,Lae=kae(function(e,t){return e==null?{}:Nae(e,t)}),is=Lae;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 wb(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){ie(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 zt(e){return"Minified Redux error #"+e+"; visit https://redux.js.org/Errors?code="+e+" for the full message or use the non-minified dev environment for full errors. "}var Cb=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}(),cf=function(){return Math.random().toString(36).substring(7).split("").join(".")},Pi={INIT:"@@redux/INIT"+cf(),REPLACE:"@@redux/REPLACE"+cf(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+cf()}};function BT(e){if(typeof e!="object"||e===null)return!1;for(var t=e;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function Oae(e){if(e===void 0)return"undefined";if(e===null)return"null";var t=typeof e;switch(t){case"boolean":case"string":case"number":case"symbol":case"function":return t}if(Array.isArray(e))return"array";if($ae(e))return"date";if(Fae(e))return"error";var r=Iae(e);switch(r){case"Symbol":case"Promise":case"WeakMap":case"WeakSet":case"Map":case"Set":return r}return t.slice(8,-1).toLowerCase().replace(/\s/g,"")}function Iae(e){return typeof e.constructor=="function"?e.constructor.name:null}function Fae(e){return e instanceof Error||typeof e.message=="string"&&e.constructor&&typeof e.constructor.stackTraceLimit=="number"}function $ae(e){return e instanceof Date?!0:typeof e.toDateString=="function"&&typeof e.getDate=="function"&&typeof e.setDate=="function"}function jn(e){var t=typeof e;return process.env.NODE_ENV!=="production"&&(t=Oae(e)),t}function zT(e,t,r){var n;if(typeof t=="function"&&typeof r=="function"||typeof r=="function"&&typeof arguments[3]=="function")throw new Error(process.env.NODE_ENV==="production"?zt(0):"It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function. See https://redux.js.org/tutorials/fundamentals/part-4-store#creating-a-store-with-enhancers for an example.");if(typeof t=="function"&&typeof r=="undefined"&&(r=t,t=void 0),typeof r!="undefined"){if(typeof r!="function")throw new Error(process.env.NODE_ENV==="production"?zt(1):"Expected the enhancer to be a function. Instead, received: '"+jn(r)+"'");return r(zT)(e,t)}if(typeof e!="function")throw new Error(process.env.NODE_ENV==="production"?zt(2):"Expected the root reducer to be a function. Instead, received: '"+jn(e)+"'");var i=e,a=t,o=[],s=o,u=!1;function c(){s===o&&(s=o.slice())}function d(){if(u)throw new Error(process.env.NODE_ENV==="production"?zt(3):"You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return a}function h(b){if(typeof b!="function")throw new Error(process.env.NODE_ENV==="production"?zt(4):"Expected the listener to be a function. Instead, received: '"+jn(b)+"'");if(u)throw new Error(process.env.NODE_ENV==="production"?zt(5):"You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api/store#subscribelistener for more details.");var _=!0;return c(),s.push(b),function(){if(_){if(u)throw new Error(process.env.NODE_ENV==="production"?zt(6):"You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api/store#subscribelistener for more details.");_=!1,c();var C=s.indexOf(b);s.splice(C,1),o=null}}}function p(b){if(!BT(b))throw new Error(process.env.NODE_ENV==="production"?zt(7):"Actions must be plain objects. Instead, the actual type was: '"+jn(b)+"'. You may need to add middleware to your store setup to handle dispatching other values, such as 'redux-thunk' to handle dispatching functions. See https://redux.js.org/tutorials/fundamentals/part-4-store#middleware and https://redux.js.org/tutorials/fundamentals/part-6-async-logic#using-the-redux-thunk-middleware for examples.");if(typeof b.type=="undefined")throw new Error(process.env.NODE_ENV==="production"?zt(8):'Actions may not have an undefined "type" property. You may have misspelled an action type string constant.');if(u)throw new Error(process.env.NODE_ENV==="production"?zt(9):"Reducers may not dispatch actions.");try{u=!0,a=i(a,b)}finally{u=!1}for(var _=o=s,w=0;w<_.length;w++){var C=_[w];C()}return b}function m(b){if(typeof b!="function")throw new Error(process.env.NODE_ENV==="production"?zt(10):"Expected the nextReducer to be a function. Instead, received: '"+jn(b));i=b,p({type:Pi.REPLACE})}function g(){var b,_=h;return b={subscribe:function(C){if(typeof C!="object"||C===null)throw new Error(process.env.NODE_ENV==="production"?zt(11):"Expected the observer to be an object. Instead, received: '"+jn(C)+"'");function S(){C.next&&C.next(d())}S();var T=_(S);return{unsubscribe:T}}},b[Cb]=function(){return this},b}return p({type:Pi.INIT}),n={dispatch:p,subscribe:h,getState:d,replaceReducer:m},n[Cb]=g,n}function Jp(e){typeof console!="undefined"&&typeof console.error=="function"&&console.error(e);try{throw new Error(e)}catch(t){}}function Bae(e,t,r,n){var i=Object.keys(t),a=r&&r.type===Pi.INIT?"preloadedState argument passed to createStore":"previous state received by the reducer";if(i.length===0)return"Store does not have a valid reducer. Make sure the argument passed to combineReducers is an object whose values are reducers.";if(!BT(e))return"The "+a+' has unexpected type of "'+jn(e)+'". Expected argument to be an object with the following '+('keys: "'+i.join('", "')+'"');var o=Object.keys(e).filter(function(s){return!t.hasOwnProperty(s)&&!n[s]});if(o.forEach(function(s){n[s]=!0}),!(r&&r.type===Pi.REPLACE)&&o.length>0)return"Unexpected "+(o.length>1?"keys":"key")+" "+('"'+o.join('", "')+'" found in '+a+". ")+"Expected to find one of the known reducer keys instead: "+('"'+i.join('", "')+'". Unexpected keys will be ignored.')}function zae(e){Object.keys(e).forEach(function(t){var r=e[t],n=r(void 0,{type:Pi.INIT});if(typeof n=="undefined")throw new Error(process.env.NODE_ENV==="production"?zt(12):'The slice reducer for key "'+t+`" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined. If you don't want to set a value for this reducer, you can use null instead of undefined.`);if(typeof r(void 0,{type:Pi.PROBE_UNKNOWN_ACTION()})=="undefined")throw new Error(process.env.NODE_ENV==="production"?zt(13):'The slice reducer for key "'+t+'" returned undefined when probed with a random type. '+("Don't try to handle '"+Pi.INIT+`' or other actions in "redux/*" `)+"namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined, but can be null.")})}function Hae(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++){var i=t[n];process.env.NODE_ENV!=="production"&&typeof e[i]=="undefined"&&Jp('No reducer provided for key "'+i+'"'),typeof e[i]=="function"&&(r[i]=e[i])}var a=Object.keys(r),o;process.env.NODE_ENV!=="production"&&(o={});var s;try{zae(r)}catch(u){s=u}return function(c,d){if(c===void 0&&(c={}),s)throw s;if(process.env.NODE_ENV!=="production"){var h=Bae(c,r,d,o);h&&Jp(h)}for(var p=!1,m={},g=0;g<a.length;g++){var b=a[g],_=r[b],w=c[b],C=_(w,d);if(typeof C=="undefined"){var S=d&&d.type;throw new Error(process.env.NODE_ENV==="production"?zt(14):"When called with an action of type "+(S?'"'+String(S)+'"':"(unknown type)")+', the slice reducer for key "'+b+'" returned undefined. To ignore an action, you must explicitly return the previous state. If you want this reducer to hold no value, you can return null instead of undefined.')}m[b]=C,p=p||C!==w}return p=p||a.length!==Object.keys(c).length,p?m:c}}function xb(e,t){return function(){return t(e.apply(this,arguments))}}function HT(e,t){if(typeof e=="function")return xb(e,t);if(typeof e!="object"||e===null)throw new Error(process.env.NODE_ENV==="production"?zt(16):"bindActionCreators expected an object or a function, but instead received: '"+jn(e)+`'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?`);var r={};for(var n in e){var i=e[n];typeof i=="function"&&(r[n]=xb(i,t))}return r}function hc(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return t.length===0?function(n){return n}:t.length===1?t[0]:t.reduce(function(n,i){return function(){return n(i.apply(void 0,arguments))}})}function Wae(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(n){return function(){var i=n.apply(void 0,arguments),a=function(){throw new Error(process.env.NODE_ENV==="production"?zt(15):"Dispatching while constructing your middleware is not allowed. Other middleware would not be applied to this dispatch.")},o={getState:i.getState,dispatch:function(){return a.apply(void 0,arguments)}},s=t.map(function(u){return u(o)});return a=hc.apply(void 0,s)(i.dispatch),wb(wb({},i),{},{dispatch:a})}}}function Tb(){}process.env.NODE_ENV!=="production"&&typeof Tb.name=="string"&&Tb.name!=="isCrushed"&&Jp('You are currently using minified code outside of NODE_ENV === "production". This means that you are running a slower development build of Redux. You can use loose-envify (https://github.com/zertosh/loose-envify) for browserify or setting mode to production in webpack (https://webpack.js.org/concepts/mode/) to ensure you have the correct code for your production build.');var jae=pd;function Vae(){this.__data__=new jae,this.size=0}var Uae=Vae;function Gae(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var qae=Gae;function Yae(e){return this.__data__.get(e)}var Xae=Yae;function Zae(e){return this.__data__.has(e)}var Kae=Zae,Qae=pd,Jae=ng,eoe=ET,toe=200;function roe(e,t){var r=this.__data__;if(r instanceof Qae){var n=r.__data__;if(!Jae||n.length<toe-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new eoe(n)}return r.set(e,t),this.size=r.size,this}var noe=roe,ioe=pd,aoe=Uae,ooe=qae,soe=Xae,loe=Kae,uoe=noe;function _o(e){var t=this.__data__=new ioe(e);this.size=t.size}_o.prototype.clear=aoe;_o.prototype.delete=ooe;_o.prototype.get=soe;_o.prototype.has=loe;_o.prototype.set=uoe;var coe=_o;function doe(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}var WT=doe,hoe=og,foe=LT;function poe(e,t,r,n){var i=!r;r||(r={});for(var a=-1,o=t.length;++a<o;){var s=t[a],u=n?n(r[s],e[s],s,r,e):void 0;u===void 0&&(u=e[s]),i?foe(r,s,u):hoe(r,s,u)}return r}var bd=poe;function moe(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var goe=moe,Fs={exports:{}};function voe(){return!1}var yoe=voe;(function(e,t){var r=_n,n=yoe,i=t&&!t.nodeType&&t,a=i&&!0&&e&&!e.nodeType&&e,o=a&&a.exports===i,s=o?r.Buffer:void 0,u=s?s.isBuffer:void 0,c=u||n;e.exports=c})(Fs,Fs.exports);var boe=Gi,_oe=lg,woe=ui,Coe="[object Arguments]",xoe="[object Array]",Toe="[object Boolean]",Soe="[object Date]",Moe="[object Error]",Poe="[object Function]",Eoe="[object Map]",Aoe="[object Number]",Roe="[object Object]",Doe="[object RegExp]",Noe="[object Set]",koe="[object String]",Loe="[object WeakMap]",Ooe="[object ArrayBuffer]",Ioe="[object DataView]",Foe="[object Float32Array]",$oe="[object Float64Array]",Boe="[object Int8Array]",zoe="[object Int16Array]",Hoe="[object Int32Array]",Woe="[object Uint8Array]",joe="[object Uint8ClampedArray]",Voe="[object Uint16Array]",Uoe="[object Uint32Array]",it={};it[Foe]=it[$oe]=it[Boe]=it[zoe]=it[Hoe]=it[Woe]=it[joe]=it[Voe]=it[Uoe]=!0;it[Coe]=it[xoe]=it[Ooe]=it[Toe]=it[Ioe]=it[Soe]=it[Moe]=it[Poe]=it[Eoe]=it[Aoe]=it[Roe]=it[Doe]=it[Noe]=it[koe]=it[Loe]=!1;function Goe(e){return woe(e)&&_oe(e.length)&&!!it[boe(e)]}var qoe=Goe;function Yoe(e){return function(t){return e(t)}}var ug=Yoe,$s={exports:{}};(function(e,t){var r=xT,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===n,o=a&&r.process,s=function(){try{var u=i&&i.require&&i.require("util").types;return u||o&&o.binding&&o.binding("util")}catch(c){}}();e.exports=s})($s,$s.exports);var Xoe=qoe,Zoe=ug,Sb=$s.exports,Mb=Sb&&Sb.isTypedArray,Koe=Mb?Zoe(Mb):Xoe,jT=Koe,Qoe=goe,Joe=vd,ese=$r,tse=Fs.exports,rse=sg,nse=jT,ise=Object.prototype,ase=ise.hasOwnProperty;function ose(e,t){var r=ese(e),n=!r&&Joe(e),i=!r&&!n&&tse(e),a=!r&&!n&&!i&&nse(e),o=r||n||i||a,s=o?Qoe(e.length,String):[],u=s.length;for(var c in e)(t||ase.call(e,c))&&!(o&&(c=="length"||i&&(c=="offset"||c=="parent")||a&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||rse(c,u)))&&s.push(c);return s}var VT=ose,sse=Object.prototype;function lse(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||sse;return e===r}var _d=lse;function use(e,t){return function(r){return e(t(r))}}var UT=use,cse=UT,dse=cse(Object.keys,Object),hse=dse,fse=_d,pse=hse,mse=Object.prototype,gse=mse.hasOwnProperty;function vse(e){if(!fse(e))return pse(e);var t=[];for(var r in Object(e))gse.call(e,r)&&r!="constructor"&&t.push(r);return t}var cg=vse,yse=ST,bse=lg;function _se(e){return e!=null&&bse(e.length)&&!yse(e)}var ml=_se,wse=VT,Cse=cg,xse=ml;function Tse(e){return xse(e)?wse(e):Cse(e)}var wd=Tse,Sse=bd,Mse=wd;function Pse(e,t){return e&&Sse(t,Mse(t),e)}var Ese=Pse;function Ase(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var Rse=Ase,Dse=qi,Nse=_d,kse=Rse,Lse=Object.prototype,Ose=Lse.hasOwnProperty;function Ise(e){if(!Dse(e))return kse(e);var t=Nse(e),r=[];for(var n in e)n=="constructor"&&(t||!Ose.call(e,n))||r.push(n);return r}var Fse=Ise,$se=VT,Bse=Fse,zse=ml;function Hse(e){return zse(e)?$se(e,!0):Bse(e)}var dg=Hse,Wse=bd,jse=dg;function Vse(e,t){return e&&Wse(t,jse(t),e)}var Use=Vse,em={exports:{}};(function(e,t){var r=_n,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===n,o=a?r.Buffer:void 0,s=o?o.allocUnsafe:void 0;function u(c,d){if(d)return c.slice();var h=c.length,p=s?s(h):new c.constructor(h);return c.copy(p),p}e.exports=u})(em,em.exports);function Gse(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}var GT=Gse;function qse(e,t){for(var r=-1,n=e==null?0:e.length,i=0,a=[];++r<n;){var o=e[r];t(o,r,e)&&(a[i++]=o)}return a}var Yse=qse;function Xse(){return[]}var qT=Xse,Zse=Yse,Kse=qT,Qse=Object.prototype,Jse=Qse.propertyIsEnumerable,Pb=Object.getOwnPropertySymbols,ele=Pb?function(e){return e==null?[]:(e=Object(e),Zse(Pb(e),function(t){return Jse.call(e,t)}))}:Kse,hg=ele,tle=bd,rle=hg;function nle(e,t){return tle(e,rle(e),t)}var ile=nle,ale=UT,ole=ale(Object.getPrototypeOf,Object),YT=ole,sle=yd,lle=YT,ule=hg,cle=qT,dle=Object.getOwnPropertySymbols,hle=dle?function(e){for(var t=[];e;)sle(t,ule(e)),e=lle(e);return t}:cle,XT=hle,fle=bd,ple=XT;function mle(e,t){return fle(e,ple(e),t)}var gle=mle,vle=yd,yle=$r;function ble(e,t,r){var n=t(e);return yle(e)?n:vle(n,r(e))}var ZT=ble,_le=ZT,wle=hg,Cle=wd;function xle(e){return _le(e,Cle,wle)}var Tle=xle,Sle=ZT,Mle=XT,Ple=dg;function Ele(e){return Sle(e,Ple,Mle)}var Ale=Ele,Rle=Yi,Dle=_n,Nle=Rle(Dle,"DataView"),kle=Nle,Lle=Yi,Ole=_n,Ile=Lle(Ole,"Promise"),Fle=Ile,$le=Yi,Ble=_n,zle=$le(Ble,"Set"),Hle=zle,Wle=Yi,jle=_n,Vle=Wle(jle,"WeakMap"),Ule=Vle,tm=kle,rm=ng,nm=Fle,im=Hle,am=Ule,KT=Gi,wo=MT,Eb="[object Map]",Gle="[object Object]",Ab="[object Promise]",Rb="[object Set]",Db="[object WeakMap]",Nb="[object DataView]",qle=wo(tm),Yle=wo(rm),Xle=wo(nm),Zle=wo(im),Kle=wo(am),_i=KT;(tm&&_i(new tm(new ArrayBuffer(1)))!=Nb||rm&&_i(new rm)!=Eb||nm&&_i(nm.resolve())!=Ab||im&&_i(new im)!=Rb||am&&_i(new am)!=Db)&&(_i=function(e){var t=KT(e),r=t==Gle?e.constructor:void 0,n=r?wo(r):"";if(n)switch(n){case qle:return Nb;case Yle:return Eb;case Xle:return Ab;case Zle:return Rb;case Kle:return Db}return t});var gl=_i,Qle=Object.prototype,Jle=Qle.hasOwnProperty;function eue(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&Jle.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var tue=eue,rue=_n,nue=rue.Uint8Array,iue=nue,kb=iue;function aue(e){var t=new e.constructor(e.byteLength);return new kb(t).set(new kb(e)),t}var fg=aue,oue=fg;function sue(e,t){var r=t?oue(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var lue=sue,uue=/\w*$/;function cue(e){var t=new e.constructor(e.source,uue.exec(e));return t.lastIndex=e.lastIndex,t}var due=cue,Lb=pl,Ob=Lb?Lb.prototype:void 0,Ib=Ob?Ob.valueOf:void 0;function hue(e){return Ib?Object(Ib.call(e)):{}}var fue=hue,pue=fg;function mue(e,t){var r=t?pue(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var gue=mue,vue=fg,yue=lue,bue=due,_ue=fue,wue=gue,Cue="[object Boolean]",xue="[object Date]",Tue="[object Map]",Sue="[object Number]",Mue="[object RegExp]",Pue="[object Set]",Eue="[object String]",Aue="[object Symbol]",Rue="[object ArrayBuffer]",Due="[object DataView]",Nue="[object Float32Array]",kue="[object Float64Array]",Lue="[object Int8Array]",Oue="[object Int16Array]",Iue="[object Int32Array]",Fue="[object Uint8Array]",$ue="[object Uint8ClampedArray]",Bue="[object Uint16Array]",zue="[object Uint32Array]";function Hue(e,t,r){var n=e.constructor;switch(t){case Rue:return vue(e);case Cue:case xue:return new n(+e);case Due:return yue(e,r);case Nue:case kue:case Lue:case Oue:case Iue:case Fue:case $ue:case Bue:case zue:return wue(e,r);case Tue:return new n;case Sue:case Eue:return new n(e);case Mue:return bue(e);case Pue:return new n;case Aue:return _ue(e)}}var Wue=Hue,jue=qi,Fb=Object.create,Vue=function(){function e(){}return function(t){if(!jue(t))return{};if(Fb)return Fb(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}(),Uue=Vue,Gue=Uue,que=YT,Yue=_d;function Xue(e){return typeof e.constructor=="function"&&!Yue(e)?Gue(que(e)):{}}var Zue=Xue,Kue=gl,Que=ui,Jue="[object Map]";function ece(e){return Que(e)&&Kue(e)==Jue}var tce=ece,rce=tce,nce=ug,$b=$s.exports,Bb=$b&&$b.isMap,ice=Bb?nce(Bb):rce,ace=ice,oce=gl,sce=ui,lce="[object Set]";function uce(e){return sce(e)&&oce(e)==lce}var cce=uce,dce=cce,hce=ug,zb=$s.exports,Hb=zb&&zb.isSet,fce=Hb?hce(Hb):dce,pce=fce,mce=coe,gce=WT,vce=og,yce=Ese,bce=Use,_ce=em.exports,wce=GT,Cce=ile,xce=gle,Tce=Tle,Sce=Ale,Mce=gl,Pce=tue,Ece=Wue,Ace=Zue,Rce=$r,Dce=Fs.exports,Nce=ace,kce=qi,Lce=pce,Oce=wd,Ice=dg,Fce=1,$ce=2,Bce=4,QT="[object Arguments]",zce="[object Array]",Hce="[object Boolean]",Wce="[object Date]",jce="[object Error]",JT="[object Function]",Vce="[object GeneratorFunction]",Uce="[object Map]",Gce="[object Number]",eS="[object Object]",qce="[object RegExp]",Yce="[object Set]",Xce="[object String]",Zce="[object Symbol]",Kce="[object WeakMap]",Qce="[object ArrayBuffer]",Jce="[object DataView]",ede="[object Float32Array]",tde="[object Float64Array]",rde="[object Int8Array]",nde="[object Int16Array]",ide="[object Int32Array]",ade="[object Uint8Array]",ode="[object Uint8ClampedArray]",sde="[object Uint16Array]",lde="[object Uint32Array]",tt={};tt[QT]=tt[zce]=tt[Qce]=tt[Jce]=tt[Hce]=tt[Wce]=tt[ede]=tt[tde]=tt[rde]=tt[nde]=tt[ide]=tt[Uce]=tt[Gce]=tt[eS]=tt[qce]=tt[Yce]=tt[Xce]=tt[Zce]=tt[ade]=tt[ode]=tt[sde]=tt[lde]=!0;tt[jce]=tt[JT]=tt[Kce]=!1;function zu(e,t,r,n,i,a){var o,s=t&Fce,u=t&$ce,c=t&Bce;if(r&&(o=i?r(e,n,i,a):r(e)),o!==void 0)return o;if(!kce(e))return e;var d=Rce(e);if(d){if(o=Pce(e),!s)return wce(e,o)}else{var h=Mce(e),p=h==JT||h==Vce;if(Dce(e))return _ce(e,s);if(h==eS||h==QT||p&&!i){if(o=u||p?{}:Ace(e),!s)return u?xce(e,bce(o,e)):Cce(e,yce(o,e))}else{if(!tt[h])return i?e:{};o=Ece(e,h,s)}}a||(a=new mce);var m=a.get(e);if(m)return m;a.set(e,o),Lce(e)?e.forEach(function(_){o.add(zu(_,t,r,_,e,a))}):Nce(e)&&e.forEach(function(_,w){o.set(w,zu(_,t,r,w,e,a))});var g=c?u?Sce:Tce:u?Ice:Oce,b=d?void 0:g(e);return gce(b||e,function(_,w){b&&(w=_,_=e[w]),vce(o,w,zu(_,t,r,w,e,a))}),o}var ude=zu,cde=ude,dde=4;function hde(e){return cde(e,dde)}var fde=hde;function pde(e,t){return e<t}var vu=function(){function e(t,r){rt(this,e),this._items=t||[],this._size=this._items.length,this._comparator=r||pde,this._heapify()}return nt(e,[{key:"empty",value:function(){return this._size===0}},{key:"pop",value:function(){if(this._size!==0){var r=this._items[0],n=this._items.pop();return this._size--,this._size>0&&(this._items[0]=n,this._sinkDown(0)),r}}},{key:"push",value:function(r){this._items[this._size++]=r,this._bubbleUp(this._size-1)}},{key:"size",value:function(){return this._size}},{key:"peek",value:function(){if(this._size!==0)return this._items[0]}},{key:"_heapify",value:function(){for(var r=Math.floor((this._size+1)/2);r>=0;r--)this._sinkDown(r)}},{key:"_bubbleUp",value:function(r){for(var n=this._items[r];r>0;){var i=Math.floor((r+1)/2)-1,a=this._items[i];if(this._comparator(a,n))return;this._items[i]=n,this._items[r]=a,r=i}}},{key:"_sinkDown",value:function(r){for(var n=this._items[r];;){var i=2*(r+1)-1,a=2*(r+1),o=-1;if(i<this._size){var s=this._items[i];this._comparator(s,n)&&(o=i)}if(a<this._size){var u=this._items[a];this._comparator(u,n)&&(o===-1||this._comparator(u,this._items[o]))&&(o=a)}if(o===-1)return;this._items[r]=this._items[o],this._items[o]=n,r=o}}}]),e}(),tS=function(){function e(){rt(this,e),this._valueToPositionMap={},this._size=0,this._smallValues=new vu([],this._smallerComparator),this._largeValues=new vu([],this._greaterComparator),this.getNewPositionForValue=this.getNewPositionForValue.bind(this),this.getValuePosition=this.getValuePosition.bind(this),this.getSize=this.getSize.bind(this),this.replaceFurthestValuePosition=this.replaceFurthestValuePosition.bind(this)}return nt(e,[{key:"getSize",value:function(){return this._size}},{key:"getValuePosition",value:function(r){return this._valueToPositionMap[r]===void 0?null:this._valueToPositionMap[r]}},{key:"getNewPositionForValue",value:function(r){sn(this._valueToPositionMap[r]===void 0,"Shouldn't try to find new position for value already stored in BufferSet");var n=this._size;return this._size++,this._pushToHeaps(n,r),this._valueToPositionMap[r]=n,n}},{key:"replaceFurthestValuePosition",value:function(r,n,i){if(sn(this._valueToPositionMap[i]===void 0,"Shouldn't try to replace values with value already stored value in BufferSet"),this._cleanHeaps(),this._smallValues.empty()||this._largeValues.empty())return null;var a=this._smallValues.peek().value,o=this._largeValues.peek().value;if(a>=r&&o<=n)return null;var s;r-a>o-n?(s=a,this._smallValues.pop()):(s=o,this._largeValues.pop());var u=this._valueToPositionMap[s];return delete this._valueToPositionMap[s],this._valueToPositionMap[i]=u,this._pushToHeaps(u,i),u}},{key:"_pushToHeaps",value:function(r,n){var i={position:r,value:n};this._smallValues.push(i),this._largeValues.push(i)}},{key:"_cleanHeaps",value:function(){this._cleanHeap(this._smallValues),this._cleanHeap(this._largeValues);var r=Math.min(this._smallValues.size(),this._largeValues.size()),n=Math.max(this._smallValues.size(),this._largeValues.size());n>10*r&&this._recreateHeaps()}},{key:"_recreateHeaps",value:function(){for(var r=this._smallValues.size()<this._largeValues.size()?this._smallValues:this._largeValues,n=new vu([],this._smallerComparator),i=new vu([],this._greaterComparator);!r.empty();){var a=r.pop();this._valueToPositionMap[a.value]!==void 0&&(n.push(a),i.push(a))}this._smallValues=n,this._largeValues=i}},{key:"_cleanHeap",value:function(r){for(;!r.empty()&&this._valueToPositionMap[r.peek().value]===void 0;)r.pop()}},{key:"_smallerComparator",value:function(r,n){return r.value<n.value}},{key:"_greaterComparator",value:function(r,n){return r.value>n.value}}]),e}(),ar=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{},df=function(t){return Math.floor(t/2)},mde=ar.Int32Array||function(e){for(var t=[],r=e-1;r>=0;--r)t[r]=0;return t};function gde(e){for(var t=1;t<e;)t*=2;return t}var vde=function(){function e(t){rt(this,e),this._size=t.length,this._half=gde(this._size),this._heap=new mde(2*this._half);var r;for(r=0;r<this._size;++r)this._heap[this._half+r]=t[r];for(r=this._half-1;r>0;--r)this._heap[r]=this._heap[2*r]+this._heap[2*r+1]}return nt(e,[{key:"set",value:function(r,n){sn(0<=r&&r<this._size,"Index out of range %s",r);var i=this._half+r;for(this._heap[i]=n,i=df(i);i!==0;i=df(i))this._heap[i]=this._heap[2*i]+this._heap[2*i+1]}},{key:"get",value:function(r){sn(0<=r&&r<this._size,"Index out of range %s",r);var n=this._half+r;return this._heap[n]}},{key:"getSize",value:function(){return this._size}},{key:"sumUntil",value:function(r){if(sn(0<=r&&r<this._size+1,"Index out of range %s",r),r===0)return 0;for(var n=this._half+r-1,i=this._heap[n];n!==1;n=df(n))n%2===1&&(i+=this._heap[n-1]);return i}},{key:"sumTo",value:function(r){return sn(0<=r&&r<this._size,"Index out of range %s",r),this.sumUntil(r+1)}},{key:"sum",value:function(r,n){return sn(r<=n,"Begin must precede end"),this.sumUntil(n)-this.sumUntil(r)}},{key:"greatestLowerBound",value:function(r){if(r<0)return-1;var n=1;if(this._heap[n]<=r)return this._size;for(;n<this._half;){var i=this._heap[2*n];r<i?n=2*n:(n=2*n+1,r-=i)}return n-this._half}},{key:"greatestStrictLowerBound",value:function(r){if(r<=0)return-1;var n=1;if(this._heap[n]<r)return this._size;for(;n<this._half;){var i=this._heap[2*n];r<=i?n=2*n:(n=2*n+1,r-=i)}return n-this._half}},{key:"leastUpperBound",value:function(r){return this.greatestStrictLowerBound(r)+1}},{key:"leastStrictUpperBound",value:function(r){return this.greatestLowerBound(r)+1}}],[{key:"uniform",value:function(r,n){for(var i=[],a=r-1;a>=0;--a)i[a]=n;return new e(i)}},{key:"empty",value:function(r){return e.uniform(r,0)}}]),e}();function Bs(e,t){if(e===t)return!0;if(Ln(e)!=="object"||e===null||Ln(t)!=="object"||t===null)return!1;var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(var i=Object.prototype.hasOwnProperty.bind(t),a=0;a<r.length;a++)if(!i(r[a])||e[r[a]]!==t[r[a]])return!1;return!0}var Pe={FIXED:"fixed",FIXED_RIGHT:"fixedRight",SCROLLABLE:"scrollable"};function om(e,t){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=yde(e))||t){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(c){throw c},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
289
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){r=r.call(e)},n:function(){var c=r.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(o)throw s}}}}function yde(e,t){if(e){if(typeof e=="string")return Wb(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 Wb(e,t)}}function Wb(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 hf(e){var t=e.props,r=t.align,n=t.allowCellsRecycling,i=t.cellClassName,a=t.columnKey,o=t.flexGrow,s=t.fixed,u=t.fixedRight,c=t.maxWidth,d=t.minWidth,h=t.isReorderable,p=t.isResizable,m=t.pureRendering,g=t.width;return{align:r,allowCellsRecycling:n,cellClassName:i,columnKey:a,flexGrow:o,fixed:s,fixedRight:u,maxWidth:c,minWidth:d,isReorderable:h,isResizable:p,pureRendering:m,width:g}}function jb(e,t){e.cell.push(t.props.cell),e.footer.push(t.props.footer),e.header.push(t.props.header)}function sm(e){var t,r;return e!=null&&(t=e.props)!==null&&t!==void 0&&t.fixed?Pe.FIXED:e!=null&&(r=e.props)!==null&&r!==void 0&&r.fixedRight?Pe.FIXED_RIGHT:Pe.SCROLLABLE}function zs(){var e;return e={},ie(e,Pe.FIXED,[]),ie(e,Pe.SCROLLABLE,[]),ie(e,Pe.FIXED_RIGHT,[]),e}function bde(){return{groupHeader:[],header:[],cell:[],footer:[]}}function Vb(e){var t=zs(),r=om(e),n;try{for(r.s();!(n=r.n()).done;){var i=n.value,a=sm(i);t[a].push(i)}}catch(s){r.e(s)}finally{r.f()}var o=[];return o.push.apply(o,t[Pe.FIXED]),o.push.apply(o,t[Pe.SCROLLABLE]),o.push.apply(o,t[Pe.FIXED_RIGHT]),o}function Ub(e,t){return t===Pe.FIXED?e[Pe.FIXED].length:t===Pe.SCROLLABLE?e[Pe.FIXED].length+e[Pe.SCROLLABLE].length:e[Pe.FIXED].length+e[Pe.SCROLLABLE].length+e[Pe.FIXED_RIGHT].length}function _de(e){var t,r,n=[];N.Children.forEach(e,function(m,g){m!=null&&(sn(m.type.__TableColumnGroup__||m.type.__TableColumn__,"child type should be <FixedDataTableColumn /> or <FixedDataTableColumnGroup />"),n.push(m))});var i=zs(),a=zs(),o=bde(),s=(t=(r=n[0])===null||r===void 0?void 0:r.type.__TableColumnGroup__)!==null&&t!==void 0?t:!1;if(s)(function(){var m=0,g=om(Vb(n)),b;try{var _=function(){var C=b.value,S=sm(C),T=hf(C);T.index=Ub(a,S),a[S].push(T),o.groupHeader.push(C.props.header),N.Children.forEach(C.props.children,function(M){var P=hf(M);P.index=m++,P.groupIdx=T.index,i[S].push(P),jb(o,M)})};for(g.s();!(b=g.n()).done;)_()}catch(w){g.e(w)}finally{g.f()}})();else{var u=om(Vb(n)),c;try{for(u.s();!(c=u.n()).done;){var d=c.value,h=sm(d),p=hf(d);p.index=Ub(i,h),i[h].push(p),jb(o,d)}}catch(m){u.e(m)}finally{u.f()}}return{columnGroupElements:a,columnElements:i,elementTemplates:o,useGroupHeader:s}}function Cd(e,t,r){return e<t?t:e>r?r:e}var fc="NOT_FOUND";function wde(e){var t;return{get:function(n){return t&&e(t.key,n)?t.value:fc},put:function(n,i){t={key:n,value:i}},getEntries:function(){return t?[t]:[]},clear:function(){t=void 0}}}function Cde(e,t){var r=[];function n(s){var u=r.findIndex(function(d){return t(s,d.key)});if(u>-1){var c=r[u];return u>0&&(r.splice(u,1),r.unshift(c)),c.value}return fc}function i(s,u){n(s)===fc&&(r.unshift({key:s,value:u}),r.length>e&&r.pop())}function a(){return r}function o(){r=[]}return{get:n,put:i,getEntries:a,clear:o}}var xde=function(t,r){return t===r};function Tde(e){return function(r,n){if(r===null||n===null||r.length!==n.length)return!1;for(var i=r.length,a=0;a<i;a++)if(!e(r[a],n[a]))return!1;return!0}}function Sde(e,t){var r=typeof t=="object"?t:{equalityCheck:t},n=r.equalityCheck,i=n===void 0?xde:n,a=r.maxSize,o=a===void 0?1:a,s=r.resultEqualityCheck,u=Tde(i),c=o===1?wde(u):Cde(o,u);function d(){var h=c.get(arguments);if(h===fc){if(h=e.apply(null,arguments),s){var p=c.getEntries(),m=p.find(function(g){return s(g.value,h)});m&&(h=m.value)}c.put(arguments,h)}return h}return d.clearCache=function(){return c.clear()},d}function Mde(e){var t=Array.isArray(e[0])?e[0]:e;if(!t.every(function(n){return typeof n=="function"})){var r=t.map(function(n){return typeof n=="function"?"function "+(n.name||"unnamed")+"()":typeof n}).join(", ");throw new Error("createSelector expects all input-selectors to be functions, but received the following types: ["+r+"]")}return t}function Pde(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];var i=function(){for(var o=arguments.length,s=new Array(o),u=0;u<o;u++)s[u]=arguments[u];var c=0,d,h={memoizeOptions:void 0},p=s.pop();if(typeof p=="object"&&(h=p,p=s.pop()),typeof p!="function")throw new Error("createSelector expects an output function after the inputs, but received: ["+typeof p+"]");var m=h,g=m.memoizeOptions,b=g===void 0?r:g,_=Array.isArray(b)?b:[b],w=Mde(s),C=e.apply(void 0,[function(){return c++,p.apply(null,arguments)}].concat(_)),S=e(function(){for(var M=[],P=w.length,R=0;R<P;R++)M.push(w[R].apply(null,arguments));return d=C.apply(null,M),d});return Object.assign(S,{resultFunc:p,memoizedResultFunc:C,dependencies:w,lastResult:function(){return d},recomputations:function(){return c},resetRecomputations:function(){return c=0}}),S};return i}var xd=Pde(Sde),Fn=xd;function Ede(e,t){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=Ade(e))||t){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(c){throw c},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
290
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){r=r.call(e)},n:function(){var c=r.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(o)throw s}}}}function Ade(e,t){if(e){if(typeof e=="string")return Gb(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 Gb(e,t)}}function Gb(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 rS=[],Rde={},pg={memoizeOptions:{maxSize:12}},Hu=xd(function(e){return e||rS},function(e){return e.reduce(function(t,r){return t+r.props.width},0)},pg),$a=xd(function(e){return e||rS},function(e){return e.reduce(function(t,r){return t+r.width},0)},pg);function nS(e){return $a(e.fixed)+$a(e.fixedRight)+$a(e.scrollable)}var Dde=xd(function(e){return e||Rde},function(e){var t=Array.prototype.concat.call(e.fixed,e.scrollable,e.fixedRight),r=0,n=Ede(t),i;try{for(n.s();!(i=n.n()).done;){var a=i.value;r+=a.flexGrow||0}}catch(o){n.e(o)}finally{n.f()}return r},pg),Nde=1,kde=3,Lde=6,Qn={HIDDEN:"hidden",JOINT_SCROLLBARS:"JOINT_SCROLLBARS",VISIBLE:"visible"};function Ode(e,t,r,n,i,a,o){var s=t.cellGroupWrapperHeight,u=t.footerHeight,c=t.headerHeight,d=t.groupHeaderHeight,h=s?0:2*Nde,p=u+c+d+h,m=i.height,g=i.maxHeight,b=i.useMaxHeight,_=i.width,w=Math.round(b?g:m),C=w-p,S=Ide(e,n,_,o),T=C,M=C;switch(S){case Qn.VISIBLE:{T-=a,M-=a;break}case Qn.JOINT_SCROLLBARS:{T-=a;break}}return{bufferRowCount:Fde(M,r),minAvailableHeight:Math.max(T,0),maxAvailableHeight:Math.max(M,0),reservedHeight:p,scrollStateX:S}}function Ide(e,t,r,n){var i=t.overflowX,a=t.showScrollbarX,o=nS(e);return i==="hidden"||a===!1?Qn.HIDDEN:o>r?Qn.VISIBLE:o>r-n?Qn.JOINT_SCROLLBARS:Qn.HIDDEN}function Fde(e,t){var r=t.bufferRowCount,n=t.rowHeight,i=t.subRowHeight;if(r!==void 0)return r;var a=n+i,o=Math.ceil(e/a)+1;return Cd(Math.floor(o/2),kde,Lde)}var mg=Fn([function(e){return e.columnElements},function(e){return e.elementHeights},function(e){return e.rowSettings},function(e){return e.scrollFlags},function(e){return e.tableSize},function(e){return e.scrollbarXHeight},function(e){return e.scrollbarYWidth}],Ode);function $de(e,t,r){var n=r.overflowY,i=r.showScrollbarY,a=n!=="hidden"&&i!==!1,o=e.minAvailableHeight,s=e.maxAvailableHeight,u=e.scrollStateX,c=!1,d=!1;u===Qn.VISIBLE&&(d=!0),a&&t>s&&(c=!0),c&&u===Qn.JOINT_SCROLLBARS&&(d=!0);var h=s;return d&&(h=o),{availableHeight:h,scrollEnabledX:d,scrollEnabledY:c}}var Fi=Fn([mg,function(e){return e.scrollContentHeight},function(e){return e.scrollFlags}],$de);function xi(e,t){var r=e.rowSettings,n=e.getInternal(),i=n.storedHeights,a=n.rowOffsetIntervalTree,o=r.rowHeightGetter,s=r.subRowHeightGetter,u=o(t)+s(t),c=i[t];return u!==c&&(a.set(t,u),i[t]=u,e.scrollContentHeight+=u-c),i[t]}function qb(e,t,r){return t.scrollToRow!==void 0&&t.scrollToRow!==null&&(!r||t.scrollToRow!==r.scrollToRow)?Bde(e,t.scrollToRow):t.scrollTop!==void 0&&t.scrollTop!==null&&(!r||t.scrollTop!==r.scrollTop)?lm(e,t.scrollTop):{firstIndex:e.firstRowIndex,firstOffset:e.firstRowOffset,lastIndex:void 0,changed:!1}}function lm(e,t){var r=Fi(e),n=r.availableHeight,i=e.rowSettings,a=e.scrollContentHeight,o=e.getInternal(),s=o.rowOffsetIntervalTree,u=i.rowsCount;if(e.rowSettings.rowHeightGetter!=null&&e.isVerticalScrollExact){for(var c=e.getInternal(),d=c.rowUntilOffsetsAreExact;d<u;)xi(e,d++);e.getInternal().rowUntilOffsetsAreExact=u}if(u===0)return{firstIndex:0,firstOffset:0,lastIndex:void 0,changed:e.firstRowIndex!==0||e.firstRowOffset!==0};var h=0,p=0,m=void 0;if(!(t<=0))if(t>=a-n)h=void 0,m=u-1;else{var g=s.greatestLowerBound(t);h=Cd(g,0,Math.max(u-1,0));var b=s.sumUntil(h);p=b-t}return{firstIndex:h,firstOffset:p,lastIndex:m,changed:!0}}function Bde(e,t){var r=Fi(e),n=r.availableHeight,i=e.rowSettings,a=e.scrollY,o=e.getInternal(),s=o.rowOffsetIntervalTree,u=o.storedHeights,c=i.rowsCount;if(c===0)return{firstIndex:0,firstOffset:0,lastIndex:void 0,changed:e.firstRowIndex!==0||e.firstRowOffset!==0};t=Cd(t,0,Math.max(c-1,0)),xi(e,t);var d=s.sumUntil(t),h=d+u[t],p=t,m=void 0;if(!(d<a))if(a+n<h)p=void 0,m=t;else return{firstIndex:e.firstRowIndex,firstOffset:e.firstRowOffset,lastIndex:void 0,changed:!1};return{firstIndex:p,firstOffset:0,lastIndex:m,changed:!0}}function zde(e){return e==null}var vs=zde;function Hde(e,t,r){return e===e&&(r!==void 0&&(e=e<=r?e:r),t!==void 0&&(e=e>=t?e:t)),e}var Wde=Hde,jde=/\s/;function Vde(e){for(var t=e.length;t--&&jde.test(e.charAt(t)););return t}var Ude=Vde,Gde=Ude,qde=/^\s+/;function Yde(e){return e&&e.slice(0,Gde(e)+1).replace(qde,"")}var Xde=Yde,Zde=Xde,Yb=qi,Kde=dd,Xb=NaN,Qde=/^[-+]0x[0-9a-f]+$/i,Jde=/^0b[01]+$/i,ehe=/^0o[0-7]+$/i,the=parseInt;function rhe(e){if(typeof e=="number")return e;if(Kde(e))return Xb;if(Yb(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Yb(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Zde(e);var r=Jde.test(e);return r||ehe.test(e)?the(e.slice(2),r?2:8):Qde.test(e)?Xb:+e}var gg=rhe,nhe=Wde,ff=gg;function ihe(e,t,r){return r===void 0&&(r=t,t=void 0),r!==void 0&&(r=ff(r),r=r===r?r:0),t!==void 0&&(t=ff(t),t=t===t?t:0),nhe(ff(e),t,r)}var Td=ihe,ahe=yd,ohe=FT,she=GT,lhe=$r;function uhe(){var e=arguments.length;if(!e)return[];for(var t=Array(e-1),r=arguments[0],n=e;n--;)t[n-1]=arguments[n];return ahe(lhe(r)?she(r):[r],ohe(t,1))}var Zb=uhe;function Kb(e,t){var r=typeof Symbol!="undefined"&&e[Symbol.iterator]||e["@@iterator"];if(!r){if(Array.isArray(e)||(r=che(e))||t){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(c){throw c},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
291
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a=!0,o=!1,s;return{s:function(){r=r.call(e)},n:function(){var c=r.next();return a=c.done,c},e:function(c){o=!0,s=c},f:function(){try{!a&&r.return!=null&&r.return()}finally{if(o)throw s}}}}function che(e,t){if(e){if(typeof e=="string")return Qb(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 Qb(e,t)}}function Qb(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 dhe(e,t,r,n,i){var a=r?i:0,o=n-a,s=hhe(e,t,o),u=s.columnGroupElements,c=s.columnElements,d=Jb(c),h=d.fixed,p=d.fixedRight,m=d.scrollable,g=Jb(u),b=g.fixed,_=g.fixedRight,w=g.scrollable,C=$a(h),S=$a(p),T=$a(m),M=o-C-S,P=Math.max(0,C+S+T-o);return{columnGroupProps:Zb(b,w,_),columnProps:Zb(h,m,p),availableScrollWidth:M,fixedColumns:h,fixedRightColumns:p,scrollableColumns:m,fixedColumnGroups:b,fixedRightColumnGroups:_,scrollableColumnGroups:w,maxScrollX:P}}function hhe(e,t,r){var n=zs(),i=zs(),a=nS(t),o=Dde(t),s=Math.max(r-a,0),u=[];for(var c in t){var d=t[c],h=0,p=0,m=Kb(d),g;try{for(m.s();!(g=m.n()).done;){var b=g.value,_=b.flexGrow||0,w=0;_&&(w=Math.floor(_*s/o));var C=b.width+w;o-=_,s-=w;var S=ot({},b,{width:C,offset:h});h+=C,u[b.groupIdx]=C+(u[b.groupIdx]||0),i[c][p]=S,p++}}catch(B){m.e(B)}finally{m.f()}}for(var T in e){var M=e[T],P=0,R=0,k=Kb(M),I;try{for(k.s();!(I=k.n()).done;){var $=I.value,G=u[$.index],Y=ot({},$,{width:G,offset:P});P+=G,n[T][R]=Y,R++}}catch(B){k.e(B)}finally{k.f()}}return{columnGroupElements:n,columnElements:i}}function Jb(e){return{fixed:e.fixed,fixedRight:e.fixedRight,scrollable:e.scrollable}}var vl=Fn([function(e){return e.columnGroupElements},function(e){return e.columnElements},function(e){return Fi(e).scrollEnabledY},function(e){return e.tableSize.width},function(e){return e.scrollbarYWidth}],dhe);function fhe(e,t,r){var n=t.scrollLeft,i=e.scrollX;n!==void 0&&(!r||n!==r.scrollLeft)&&(i=n),i=phe(e,t,r.scrollToColumn,i);var a=vl(e),o=a.maxScrollX;i=Td(i,0,o),ot(e,{maxScrollX:o,scrollX:i})}function phe(e,t,r,n){var i=t.scrollToColumn;if(vs(i))return n;var a=vl(e),o=a.availableScrollWidth,s=a.fixedColumns,u=a.scrollableColumns,c=s.length,d=u.length,h=d===0,p=i===r,m=i<c,g=i>=c+d;if(p||m||g||h)return n;for(var b=Math.min(i-c,u.length-1),_=0,w=0;w<b;++w)_+=u[w].width;var C=u[b].width,S=_+C-o;return n<S?S:n>_?_:n}var e2={initialize:fhe};function mhe(e,t,r,n,i,a,o){var s=i.availableHeight,u=i.scrollEnabledX,c=r;u&&(c+=o);var d=Math.min(s,n),h=a?d:s,p=h+c,m=h;t<p&&(m=t-c);var g=a?n:Math.max(n,s),b=g+c;t&&(b=Math.max(t,b));var _=e.footerHeight,w=e.groupHeaderHeight,C=e.headerHeight,S=w+C,T=S+m,M=T+_,P=Math.max(0,T-S);return{bodyHeight:d,bodyOffsetTop:S,componentHeight:p,contentHeight:b,footOffsetTop:T,scrollbarXOffsetTop:M,scrollbarYHeight:P,visibleRowsHeight:m}}var Ra=Fn([function(e){return e.elementHeights},function(e){return e.tableSize.ownerHeight},function(e){return mg(e).reservedHeight},function(e){return e.scrollContentHeight},Fi,function(e){return e.tableSize.useMaxHeight},function(e){return e.scrollbarXHeight}],mhe);function Ko(e,t){var r=t2(e,t),n=e.rowSettings,i=e.scrollContentHeight,a=n.rowsCount,o=Ra(e),s=o.bodyHeight,u=i-s,c;u===0?(r.firstViewportIdx>0&&(r=t2(e,{firstOffset:0,lastIndex:a-1})),c=0):c=r.firstOffset;var d=r.firstViewportIdx,h=r.endViewportIdx;ghe(e,r,e.scrolling);var p=0;a>0&&(p=e.rowOffsets[r.firstViewportIdx]-c),p=Td(p,0,u),ot(e,{firstRowIndex:d,firstRowOffset:c,endRowIndex:h,maxScrollY:u,scrollY:p})}function t2(e,t){var r=mg(e),n=r.bufferRowCount,i=r.maxAvailableHeight,a=e.rowSettings.rowsCount;if(a===0)return{endBufferIdx:0,endViewportIdx:0,firstBufferIdx:0,firstOffset:0,firstViewportIdx:0};var o=t.firstIndex,s=t.firstOffset,u=t.lastIndex;(o>=a||u>=a)&&(u=a-1);var c=1,d=o,h=s;u!==void 0&&(c=-1,d=u,h=0);for(var p=d,m=p;p<a&&p>=0&&h<i;)h+=xi(e,p),m=p,p+=c;var g=!1;if(h<i&&p===a&&u===void 0)for(g=!0,p=o-1;p>=0&&h<i;)h+=xi(e,p),d=p,--p;var b=Math.min(d,m),_=Math.max(b-n,0);for(p=_;p<b;p++)xi(e,p);var w=Math.max(d,m)+1,C=Math.min(w+n,a);for(p=w;p<C;p++)xi(e,p);var S=Fi(e),T=S.availableHeight;if(u!==void 0||g){s=s+Math.min(T-h,0);var M=e.getInternal(),P=M.storedHeights;-1*s>=P[b]&&(b+=1,s+=P[b])}return{endBufferIdx:C,endViewportIdx:w,firstBufferIdx:_,firstOffset:s,firstViewportIdx:b}}function ghe(e,t,r){var n=e.getInternal(),i=n.rowBufferSet,a=n.rowOffsetIntervalTree,o=n.storedHeights,s=t.endBufferIdx,u=t.endViewportIdx,c=t.firstBufferIdx,d=t.firstViewportIdx,h=s-c;if(h===0){e.rowOffsets={},e.rows=[];return}for(var p=r?d:c,m=r?u:s,g=[],b={},_=a.sumUntil(p),w=p;w<m;w++){b[w]=_,_+=o[w];var C=vhe(w,i,p,m,h);g[C]=w}e.rows=g,e.rowOffsets=b}function vhe(e,t,r,n,i){var a=t.getValuePosition(e);return a===null&&t.getSize()>=i&&(a=t.replaceFurthestValuePosition(r,n-1,e)),a===null&&(a=t.getNewPositionForValue(e)),a}var um={exports:{}},pc={exports:{}},Qe={};/** @license React v16.13.1
292
+ * react-is.production.min.js
293
+ *
294
+ * Copyright (c) Facebook, Inc. and its affiliates.
295
+ *
296
+ * This source code is licensed under the MIT license found in the
297
+ * LICENSE file in the root directory of this source tree.
298
+ */var It=typeof Symbol=="function"&&Symbol.for,vg=It?Symbol.for("react.element"):60103,yg=It?Symbol.for("react.portal"):60106,Sd=It?Symbol.for("react.fragment"):60107,Md=It?Symbol.for("react.strict_mode"):60108,Pd=It?Symbol.for("react.profiler"):60114,Ed=It?Symbol.for("react.provider"):60109,Ad=It?Symbol.for("react.context"):60110,bg=It?Symbol.for("react.async_mode"):60111,Rd=It?Symbol.for("react.concurrent_mode"):60111,Dd=It?Symbol.for("react.forward_ref"):60112,Nd=It?Symbol.for("react.suspense"):60113,yhe=It?Symbol.for("react.suspense_list"):60120,kd=It?Symbol.for("react.memo"):60115,Ld=It?Symbol.for("react.lazy"):60116,bhe=It?Symbol.for("react.block"):60121,_he=It?Symbol.for("react.fundamental"):60117,whe=It?Symbol.for("react.responder"):60118,Che=It?Symbol.for("react.scope"):60119;function Sr(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case vg:switch(e=e.type,e){case bg:case Rd:case Sd:case Pd:case Md:case Nd:return e;default:switch(e=e&&e.$$typeof,e){case Ad:case Dd:case Ld:case kd:case Ed:return e;default:return t}}case yg:return t}}}function iS(e){return Sr(e)===Rd}Qe.AsyncMode=bg;Qe.ConcurrentMode=Rd;Qe.ContextConsumer=Ad;Qe.ContextProvider=Ed;Qe.Element=vg;Qe.ForwardRef=Dd;Qe.Fragment=Sd;Qe.Lazy=Ld;Qe.Memo=kd;Qe.Portal=yg;Qe.Profiler=Pd;Qe.StrictMode=Md;Qe.Suspense=Nd;Qe.isAsyncMode=function(e){return iS(e)||Sr(e)===bg};Qe.isConcurrentMode=iS;Qe.isContextConsumer=function(e){return Sr(e)===Ad};Qe.isContextProvider=function(e){return Sr(e)===Ed};Qe.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===vg};Qe.isForwardRef=function(e){return Sr(e)===Dd};Qe.isFragment=function(e){return Sr(e)===Sd};Qe.isLazy=function(e){return Sr(e)===Ld};Qe.isMemo=function(e){return Sr(e)===kd};Qe.isPortal=function(e){return Sr(e)===yg};Qe.isProfiler=function(e){return Sr(e)===Pd};Qe.isStrictMode=function(e){return Sr(e)===Md};Qe.isSuspense=function(e){return Sr(e)===Nd};Qe.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===Sd||e===Rd||e===Pd||e===Md||e===Nd||e===yhe||typeof e=="object"&&e!==null&&(e.$$typeof===Ld||e.$$typeof===kd||e.$$typeof===Ed||e.$$typeof===Ad||e.$$typeof===Dd||e.$$typeof===_he||e.$$typeof===whe||e.$$typeof===Che||e.$$typeof===bhe)};Qe.typeOf=Sr;var Ke={};/** @license React v16.13.1
299
+ * react-is.development.js
300
+ *
301
+ * Copyright (c) Facebook, Inc. and its affiliates.
302
+ *
303
+ * This source code is licensed under the MIT license found in the
304
+ * LICENSE file in the root directory of this source tree.
305
+ */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,a=e?Symbol.for("react.profiler"):60114,o=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,h=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,g=e?Symbol.for("react.lazy"):60116,b=e?Symbol.for("react.block"):60121,_=e?Symbol.for("react.fundamental"):60117,w=e?Symbol.for("react.responder"):60118,C=e?Symbol.for("react.scope"):60119;function S(le){return typeof le=="string"||typeof le=="function"||le===n||le===c||le===a||le===i||le===h||le===p||typeof le=="object"&&le!==null&&(le.$$typeof===g||le.$$typeof===m||le.$$typeof===o||le.$$typeof===s||le.$$typeof===d||le.$$typeof===_||le.$$typeof===w||le.$$typeof===C||le.$$typeof===b)}function T(le){if(typeof le=="object"&&le!==null){var He=le.$$typeof;switch(He){case t:var Te=le.type;switch(Te){case u:case c:case n:case a:case i:case h:return Te;default:var Ae=Te&&Te.$$typeof;switch(Ae){case s:case d:case g:case m:case o:return Ae;default:return He}}case r:return He}}}var M=u,P=c,R=s,k=o,I=t,$=d,G=n,Y=g,B=m,X=r,U=a,Q=i,W=h,q=!1;function ee(le){return q||(q=!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.")),Z(le)||T(le)===u}function Z(le){return T(le)===c}function J(le){return T(le)===s}function ne(le){return T(le)===o}function oe(le){return typeof le=="object"&&le!==null&&le.$$typeof===t}function ae(le){return T(le)===d}function se(le){return T(le)===n}function ue(le){return T(le)===g}function me(le){return T(le)===m}function pe(le){return T(le)===r}function Ce(le){return T(le)===a}function ke(le){return T(le)===i}function we(le){return T(le)===h}Ke.AsyncMode=M,Ke.ConcurrentMode=P,Ke.ContextConsumer=R,Ke.ContextProvider=k,Ke.Element=I,Ke.ForwardRef=$,Ke.Fragment=G,Ke.Lazy=Y,Ke.Memo=B,Ke.Portal=X,Ke.Profiler=U,Ke.StrictMode=Q,Ke.Suspense=W,Ke.isAsyncMode=ee,Ke.isConcurrentMode=Z,Ke.isContextConsumer=J,Ke.isContextProvider=ne,Ke.isElement=oe,Ke.isForwardRef=ae,Ke.isFragment=se,Ke.isLazy=ue,Ke.isMemo=me,Ke.isPortal=pe,Ke.isProfiler=Ce,Ke.isStrictMode=ke,Ke.isSuspense=we,Ke.isValidElementType=S,Ke.typeOf=T}();process.env.NODE_ENV==="production"?pc.exports=Qe:pc.exports=Ke;/*
306
+ object-assign
307
+ (c) Sindre Sorhus
308
+ @license MIT
309
+ */var r2=Object.getOwnPropertySymbols,xhe=Object.prototype.hasOwnProperty,The=Object.prototype.propertyIsEnumerable;function She(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function Mhe(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;var n=Object.getOwnPropertyNames(t).map(function(a){return t[a]});if(n.join("")!=="0123456789")return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(a){i[a]=a}),Object.keys(Object.assign({},i)).join("")==="abcdefghijklmnopqrst"}catch(a){return!1}}var Phe=Mhe()?Object.assign:function(e,t){for(var r,n=She(e),i,a=1;a<arguments.length;a++){r=Object(arguments[a]);for(var o in r)xhe.call(r,o)&&(n[o]=r[o]);if(r2){i=r2(r);for(var s=0;s<i.length;s++)The.call(r,i[s])&&(n[i[s]]=r[i[s]])}}return n},Ehe="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",_g=Ehe,aS=Function.call.bind(Object.prototype.hasOwnProperty),cm=function(){};if(process.env.NODE_ENV!=="production"){var Ahe=_g,dm={},Rhe=aS;cm=function(e){var t="Warning: "+e;typeof console!="undefined"&&console.error(t);try{throw new Error(t)}catch(r){}}}function oS(e,t,r,n,i){if(process.env.NODE_ENV!=="production"){for(var a in e)if(Rhe(e,a)){var o;try{if(typeof e[a]!="function"){var s=Error((n||"React class")+": "+r+" type `"+a+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[a]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw s.name="Invariant Violation",s}o=e[a](t,a,n,r,null,Ahe)}catch(c){o=c}if(o&&!(o instanceof Error)&&cm((n||"React class")+": type specification of "+r+" `"+a+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof o+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),o instanceof Error&&!(o.message in dm)){dm[o.message]=!0;var u=i?i():"";cm("Failed "+r+" type: "+o.message+(u!=null?u:""))}}}}oS.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(dm={})};var Dhe=oS,Nhe=pc.exports,khe=Phe,ma=_g,pf=aS,n2=Dhe,Ta=function(){};process.env.NODE_ENV!=="production"&&(Ta=function(e){var t="Warning: "+e;typeof console!="undefined"&&console.error(t);try{throw new Error(t)}catch(r){}});function yu(){return null}var Lhe=function(e,t){var r=typeof Symbol=="function"&&Symbol.iterator,n="@@iterator";function i(B){var X=B&&(r&&B[r]||B[n]);if(typeof X=="function")return X}var a="<<anonymous>>",o={array:d("array"),bigint:d("bigint"),bool:d("boolean"),func:d("function"),number:d("number"),object:d("object"),string:d("string"),symbol:d("symbol"),any:h(),arrayOf:p,element:m(),elementType:g(),instanceOf:b,node:S(),objectOf:w,oneOf:_,oneOfType:C,shape:M,exact:P};function s(B,X){return B===X?B!==0||1/B===1/X:B!==B&&X!==X}function u(B,X){this.message=B,this.data=X&&typeof X=="object"?X:{},this.stack=""}u.prototype=Error.prototype;function c(B){if(process.env.NODE_ENV!=="production")var X={},U=0;function Q(q,ee,Z,J,ne,oe,ae){if(J=J||a,oe=oe||Z,ae!==ma){if(t){var se=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 se.name="Invariant Violation",se}else if(process.env.NODE_ENV!=="production"&&typeof console!="undefined"){var ue=J+":"+Z;!X[ue]&&U<3&&(Ta("You are manually calling a React.PropTypes validation function for the `"+oe+"` prop on `"+J+"`. 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."),X[ue]=!0,U++)}}return ee[Z]==null?q?ee[Z]===null?new u("The "+ne+" `"+oe+"` is marked as required "+("in `"+J+"`, but its value is `null`.")):new u("The "+ne+" `"+oe+"` is marked as required in "+("`"+J+"`, but its value is `undefined`.")):null:B(ee,Z,J,ne,oe)}var W=Q.bind(null,!1);return W.isRequired=Q.bind(null,!0),W}function d(B){function X(U,Q,W,q,ee,Z){var J=U[Q],ne=I(J);if(ne!==B){var oe=$(J);return new u("Invalid "+q+" `"+ee+"` of type "+("`"+oe+"` supplied to `"+W+"`, expected ")+("`"+B+"`."),{expectedType:B})}return null}return c(X)}function h(){return c(yu)}function p(B){function X(U,Q,W,q,ee){if(typeof B!="function")return new u("Property `"+ee+"` of component `"+W+"` has invalid PropType notation inside arrayOf.");var Z=U[Q];if(!Array.isArray(Z)){var J=I(Z);return new u("Invalid "+q+" `"+ee+"` of type "+("`"+J+"` supplied to `"+W+"`, expected an array."))}for(var ne=0;ne<Z.length;ne++){var oe=B(Z,ne,W,q,ee+"["+ne+"]",ma);if(oe instanceof Error)return oe}return null}return c(X)}function m(){function B(X,U,Q,W,q){var ee=X[U];if(!e(ee)){var Z=I(ee);return new u("Invalid "+W+" `"+q+"` of type "+("`"+Z+"` supplied to `"+Q+"`, expected a single ReactElement."))}return null}return c(B)}function g(){function B(X,U,Q,W,q){var ee=X[U];if(!Nhe.isValidElementType(ee)){var Z=I(ee);return new u("Invalid "+W+" `"+q+"` of type "+("`"+Z+"` supplied to `"+Q+"`, expected a single ReactElement type."))}return null}return c(B)}function b(B){function X(U,Q,W,q,ee){if(!(U[Q]instanceof B)){var Z=B.name||a,J=Y(U[Q]);return new u("Invalid "+q+" `"+ee+"` of type "+("`"+J+"` supplied to `"+W+"`, expected ")+("instance of `"+Z+"`."))}return null}return c(X)}function _(B){if(!Array.isArray(B))return process.env.NODE_ENV!=="production"&&(arguments.length>1?Ta("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])."):Ta("Invalid argument supplied to oneOf, expected an array.")),yu;function X(U,Q,W,q,ee){for(var Z=U[Q],J=0;J<B.length;J++)if(s(Z,B[J]))return null;var ne=JSON.stringify(B,function(ae,se){var ue=$(se);return ue==="symbol"?String(se):se});return new u("Invalid "+q+" `"+ee+"` of value `"+String(Z)+"` "+("supplied to `"+W+"`, expected one of "+ne+"."))}return c(X)}function w(B){function X(U,Q,W,q,ee){if(typeof B!="function")return new u("Property `"+ee+"` of component `"+W+"` has invalid PropType notation inside objectOf.");var Z=U[Q],J=I(Z);if(J!=="object")return new u("Invalid "+q+" `"+ee+"` of type "+("`"+J+"` supplied to `"+W+"`, expected an object."));for(var ne in Z)if(pf(Z,ne)){var oe=B(Z,ne,W,q,ee+"."+ne,ma);if(oe instanceof Error)return oe}return null}return c(X)}function C(B){if(!Array.isArray(B))return process.env.NODE_ENV!=="production"&&Ta("Invalid argument supplied to oneOfType, expected an instance of array."),yu;for(var X=0;X<B.length;X++){var U=B[X];if(typeof U!="function")return Ta("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+G(U)+" at index "+X+"."),yu}function Q(W,q,ee,Z,J){for(var ne=[],oe=0;oe<B.length;oe++){var ae=B[oe],se=ae(W,q,ee,Z,J,ma);if(se==null)return null;se.data&&pf(se.data,"expectedType")&&ne.push(se.data.expectedType)}var ue=ne.length>0?", expected one of type ["+ne.join(", ")+"]":"";return new u("Invalid "+Z+" `"+J+"` supplied to "+("`"+ee+"`"+ue+"."))}return c(Q)}function S(){function B(X,U,Q,W,q){return R(X[U])?null:new u("Invalid "+W+" `"+q+"` supplied to "+("`"+Q+"`, expected a ReactNode."))}return c(B)}function T(B,X,U,Q,W){return new u((B||"React class")+": "+X+" type `"+U+"."+Q+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+W+"`.")}function M(B){function X(U,Q,W,q,ee){var Z=U[Q],J=I(Z);if(J!=="object")return new u("Invalid "+q+" `"+ee+"` of type `"+J+"` "+("supplied to `"+W+"`, expected `object`."));for(var ne in B){var oe=B[ne];if(typeof oe!="function")return T(W,q,ee,ne,$(oe));var ae=oe(Z,ne,W,q,ee+"."+ne,ma);if(ae)return ae}return null}return c(X)}function P(B){function X(U,Q,W,q,ee){var Z=U[Q],J=I(Z);if(J!=="object")return new u("Invalid "+q+" `"+ee+"` of type `"+J+"` "+("supplied to `"+W+"`, expected `object`."));var ne=khe({},U[Q],B);for(var oe in ne){var ae=B[oe];if(pf(B,oe)&&typeof ae!="function")return T(W,q,ee,oe,$(ae));if(!ae)return new u("Invalid "+q+" `"+ee+"` key `"+oe+"` supplied to `"+W+"`.\nBad object: "+JSON.stringify(U[Q],null," ")+`
310
+ Valid keys: `+JSON.stringify(Object.keys(B),null," "));var se=ae(Z,oe,W,q,ee+"."+oe,ma);if(se)return se}return null}return c(X)}function R(B){switch(typeof B){case"number":case"string":case"undefined":return!0;case"boolean":return!B;case"object":if(Array.isArray(B))return B.every(R);if(B===null||e(B))return!0;var X=i(B);if(X){var U=X.call(B),Q;if(X!==B.entries){for(;!(Q=U.next()).done;)if(!R(Q.value))return!1}else for(;!(Q=U.next()).done;){var W=Q.value;if(W&&!R(W[1]))return!1}}else return!1;return!0;default:return!1}}function k(B,X){return B==="symbol"?!0:X?X["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&X instanceof Symbol:!1}function I(B){var X=typeof B;return Array.isArray(B)?"array":B instanceof RegExp?"object":k(X,B)?"symbol":X}function $(B){if(typeof B=="undefined"||B===null)return""+B;var X=I(B);if(X==="object"){if(B instanceof Date)return"date";if(B instanceof RegExp)return"regexp"}return X}function G(B){var X=$(B);switch(X){case"array":case"object":return"an "+X;case"boolean":case"date":case"regexp":return"a "+X;default:return X}}function Y(B){return!B.constructor||!B.constructor.name?a:B.constructor.name}return o.checkPropTypes=n2,o.resetWarningCache=n2.resetWarningCache,o.PropTypes=o,o},Ohe=_g;function sS(){}function lS(){}lS.resetWarningCache=sS;var Ihe=function(){function e(n,i,a,o,s,u){if(u!==Ohe){var c=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 c.name="Invariant Violation",c}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:lS,resetWarningCache:sS};return r.PropTypes=r,r};if(process.env.NODE_ENV!=="production"){var Fhe=pc.exports,$he=!0;um.exports=Lhe(Fhe.isElement,$he)}else um.exports=Ihe();var j=um.exports,Bhe=/\//g,bu={};function zhe(e){return bu[e]||(bu[e]=e.replace(Bhe,"_")),bu[e]}function Me(e){var t;return Ln(e)=="object"?t=Object.keys(e).filter(function(r){return e[r]}):t=Array.prototype.slice.call(arguments),t.map(zhe).join(" ")}function Od(e){return function(){return e}}function Ot(){}Ot.thatReturns=Od;Ot.thatReturnsFalse=Od(!1);Ot.thatReturnsTrue=Od(!0);Ot.thatReturnsNull=Od(null);Ot.thatReturnsThis=function(){return this};Ot.thatReturnsArgument=function(e){return e};var on={BACKSPACE:8,TAB:9,RETURN:13,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,COMMA:188,PERIOD:190,A:65,Z:90,ZERO:48,NUMPAD_0:96,NUMPAD_9:105},i2=!1,wi,hm,fm,Wu,ju,uS,Vu,pm,mm,gm,cS,vm,ym,dS,hS;function hr(){if(!i2){i2=!0;var e=navigator.userAgent,t=/(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec(e),r=/(Mac OS X)|(Windows)|(Linux)/.exec(e);if(vm=/\b(iPhone|iP[ao]d)/.exec(e),ym=/\b(iP[ao]d)/.exec(e),gm=/Android/i.exec(e),dS=/FBAN\/\w+;/i.exec(e),hS=/Mobile/i.exec(e),cS=!!/Win64/.exec(e),t){wi=t[1]?parseFloat(t[1]):t[5]?parseFloat(t[5]):NaN,wi&&document&&document.documentMode&&(wi=document.documentMode);var n=/(?:Trident\/(\d+.\d+))/.exec(e);uS=n?parseFloat(n[1])+4:wi,hm=t[2]?parseFloat(t[2]):NaN,fm=t[3]?parseFloat(t[3]):NaN,Wu=t[4]?parseFloat(t[4]):NaN,Wu?(t=/(?:Chrome\/(\d+\.\d+))/.exec(e),ju=t&&t[1]?parseFloat(t[1]):NaN):ju=NaN}else wi=hm=fm=ju=Wu=NaN;if(r){if(r[1]){var i=/(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e);Vu=i?parseFloat(i[1].replace("_",".")):!0}else Vu=!1;pm=!!r[2],mm=!!r[3]}else Vu=pm=mm=!1}}var bm={ie:function(){return hr()||wi},ieCompatibilityMode:function(){return hr()||uS>wi},ie64:function(){return bm.ie()&&cS},firefox:function(){return hr()||hm},opera:function(){return hr()||fm},webkit:function(){return hr()||Wu},safari:function(){return bm.webkit()},chrome:function(){return hr()||ju},windows:function(){return hr()||pm},osx:function(){return hr()||Vu},linux:function(){return hr()||mm},iphone:function(){return hr()||vm},mobile:function(){return hr()||vm||ym||gm||hS},nativeApp:function(){return hr()||dS},android:function(){return hr()||gm},ipad:function(){return hr()||ym}},_u=!!(typeof window!="undefined"&&window.document&&window.document.createElement),wg={canUseDOM:_u,canUseWorkers:typeof Worker!="undefined",canUseEventListeners:_u&&!!(window.addEventListener||window.attachEvent),canUseViewport:_u&&!!window.screen,isInWorker:!_u},fS;wg.canUseDOM&&(fS=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0);/**
311
+ * Checks if an event is supported in the current execution environment.
312
+ *
313
+ * NOTE: This will not work correctly for non-generic events such as `change`,
314
+ * `reset`, `load`, `error`, and `select`.
315
+ *
316
+ * Borrows from Modernizr.
317
+ *
318
+ * @param {string} eventNameSuffix Event name, e.g. "click".
319
+ * @param {?boolean} capture Check if the capture phase is supported.
320
+ * @return {boolean} True if the event is supported.
321
+ * @internal
322
+ * @license Modernizr 3.0.0pre (Custom Build) | MIT
323
+ */function Hhe(e,t){if(!wg.canUseDOM||t)return!1;var r="on"+e,n=r in document;if(!n){var i=document.createElement("div");i.setAttribute(r,"return;"),n=typeof i[r]=="function"}return!n&&fS&&e==="wheel"&&(n=document.implementation.hasFeature("Events.wheel","3.0")),n}var a2=10,o2=40,s2=800;function pS(e){var t=0,r=0,n=0,i=0;return"detail"in e&&(r=e.detail),"wheelDelta"in e&&(r=-e.wheelDelta/120),"wheelDeltaY"in e&&(r=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=r,r=0),n=t*a2,i=r*a2,"deltaY"in e&&(i=e.deltaY),"deltaX"in e&&(n=e.deltaX),(n||i)&&e.deltaMode&&(e.deltaMode==1?(n*=o2,i*=o2):(n*=s2,i*=s2)),n&&!t&&(t=n<1?-1:1),i&&!r&&(r=i<1?-1:1),{spinX:t,spinY:r,pixelX:n,pixelY:i}}pS.getEventType=function(){return bm.firefox()?"DOMMouseScroll":Hhe("wheel")?"wheel":"mousewheel"};var Whe=ar.requestAnimationFrame||ar.webkitRequestAnimationFrame||ar.mozRequestAnimationFrame||ar.oRequestAnimationFrame||ar.msRequestAnimationFrame,l2=0,ti=Whe||function(e){var t=Date.now(),r=Math.max(0,16-(t-l2));return l2=t+r,ar.setTimeout(function(){e(Date.now())},r)};ti(Ot);var mS=function(){function e(t,r,n,i,a,o){rt(this,e),this._animationFrameID=null,this._deltaX=0,this._deltaY=0,this._didWheel=this._didWheel.bind(this),this._rootRef=null,typeof r!="function"&&(r=r?Ot.thatReturnsTrue:Ot.thatReturnsFalse),typeof n!="function"&&(n=n?Ot.thatReturnsTrue:Ot.thatReturnsFalse),this._handleScrollX=r,this._handleScrollY=n,this._preventDefault=a,this._stopPropagation=o,this._onWheelCallback=t,this.onWheel=this.onWheel.bind(this),this._isRTL=i}return nt(e,[{key:"onWheel",value:function(r){this._preventDefault&&r.preventDefault();var n=pS(r);r.shiftKey&&e._allowInternalAxesSwap()?n=e._swapNormalizedWheelAxis(n):r.shiftKey||(n.pixelX*=this._isRTL?-1:1);var i=this._deltaX+n.pixelX,a=this._deltaY+n.pixelY,o=this._handleScrollX(i,a),s=this._handleScrollY(a,i);if(!(!o&&!s)&&!(this._rootRef&&!this._contains(r.target))){this._deltaX+=o?n.pixelX:0,this._deltaY+=s?n.pixelY:0,r.defaultPrevented||r.preventDefault();var u;(this._deltaX!==0||this._deltaY!==0)&&(this._stopPropagation&&r.stopPropagation(),u=!0),u===!0&&this._animationFrameID===null&&(this._animationFrameID=ti(this._didWheel))}}},{key:"setRoot",value:function(r){this._rootRef=r}},{key:"_didWheel",value:function(){this._animationFrameID=null,this._onWheelCallback(this._deltaX,this._deltaY),this._deltaX=0,this._deltaY=0}},{key:"_contains",value:function(r){for(var n=r;n!=document.body;){if(n===this._rootRef)return!0;n=n.parentNode}return!1}}],[{key:"_swapNormalizedWheelAxis",value:function(r){return{spinX:r.spinY,spinY:r.spinX,pixelX:r.pixelY,pixelY:r.pixelX}}},{key:"_allowInternalAxesSwap",value:function(){return navigator.platform!=="MacIntel"}}]),e}(),ga={listen:function(t,r,n){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};if(t.addEventListener)return t.addEventListener(r,n,i||!1),{remove:function(){t.removeEventListener(r,n,i||!1)}};if(t.attachEvent)return t.attachEvent("on"+r,n),{remove:function(){t.detachEvent("on"+r,n)}}},capture:function(t,r,n){return t.addEventListener?(t.addEventListener(r,n,!0),{remove:function(){t.removeEventListener(r,n,!0)}}):(process.env.NODE_ENV!=="production"&&console.error("Attempted to listen to events during the capture phase on a browser that does not support the capture phase. Your application will not receive some events."),{remove:Ot})},registerDefault:function(){}},gS=ar.cancelAnimationFrame||ar.webkitCancelAnimationFrame||ar.mozCancelAnimationFrame||ar.oCancelAnimationFrame||ar.msCancelAnimationFrame||ar.clearTimeout;function jhe(e){var t=0,r=0;if(!e.clientX||!e.clientY){if(e.touches&&e.touches.length>0){var n=e.touches[0];t=n.clientX,r=n.clientY}}else t=e.clientX,r=e.clientY;return{x:t,y:r}}var _m={getCoordinatesFromEvent:jhe},Cg=function(){function e(t,r,n,i){rt(this,e),this._isDragging=!1,this._isTouchEnabled=i,this._animationFrameID=null,this._domNode=n,this._onMove=t,this._onMoveEnd=r,this._onMouseEnd=this._onMouseEnd.bind(this),this._onMouseMove=this._onMouseMove.bind(this),this._onMouseUp=this._onMouseUp.bind(this),this._didMouseMove=this._didMouseMove.bind(this)}return nt(e,[{key:"captureMouseMoves",value:function(r){if(!this._eventMoveToken&&!this._eventUpToken&&!this._eventLeaveToken&&(this._eventMoveToken=ga.listen(this._domNode,"mousemove",this._onMouseMove),this._eventUpToken=ga.listen(this._domNode,"mouseup",this._onMouseUp),this._eventLeaveToken=ga.listen(this._domNode,"mouseleave",this._onMouseEnd)),this._isTouchEnabled&&!this._eventTouchStartToken&&!this._eventTouchMoveToken&&!this._eventTouchEndToken&&(this._eventTouchStartToken=ga.listen(this._domNode,"touchstart",this._onMouseMove,{passive:!1}),this._eventTouchMoveToken=ga.listen(r.target,"touchmove",this._onMouseMove,{passive:!1}),this._eventTouchEndToken=ga.listen(r.target,"touchend",this._onMouseUp,{passive:!1})),!this._isDragging){this._deltaX=0,this._deltaY=0,this._isDragging=!0;var n=_m.getCoordinatesFromEvent(r),i=n.x,a=n.y;this._x=i,this._y=a}r.preventDefault()}},{key:"releaseMouseMoves",value:function(){this._eventMoveToken&&this._eventUpToken&&this._eventLeaveToken&&(this._eventMoveToken.remove(),this._eventMoveToken=null,this._eventUpToken.remove(),this._eventUpToken=null,this._eventLeaveToken.remove(),this._eventLeaveToken=null),this._isTouchEnabled&&this._eventTouchStartToken&&this._eventTouchMoveToken&&this._eventTouchEndToken&&(this._eventTouchStartToken.remove(),this._eventTouchStartToken=null,this._eventTouchMoveToken.remove(),this._eventTouchMoveToken=null,this._eventTouchEndToken.remove(),this._eventTouchEndToken=null),this._animationFrameID!==null&&(gS(this._animationFrameID),this._animationFrameID=null),this._isDragging&&(this._isDragging=!1,this._x=null,this._y=null)}},{key:"isDragging",value:function(){return this._isDragging}},{key:"_onMouseMove",value:function(r){var n=_m.getCoordinatesFromEvent(r),i=n.x,a=n.y;this._deltaX+=i-this._x,this._deltaY+=a-this._y,this._animationFrameID===null&&(this._animationFrameID=ti(this._didMouseMove)),this._x=i,this._y=a,r.preventDefault()}},{key:"_didMouseMove",value:function(){this._animationFrameID=null,this._onMove(this._deltaX,this._deltaY),this._deltaX=0,this._deltaY=0}},{key:"_onMouseUp",value:function(){this._animationFrameID&&this._didMouseMove(),this._onMoveEnd(!1)}},{key:"_onMouseEnd",value:function(){this._onMoveEnd(!0)}}]),e}(),wm={"--scrollbar-face-active-color":"#7d7d7d","--scrollbar-face-color":"#c2c2c2","--scrollbar-face-margin":"4px","--scrollbar-face-radius":"6px","--scrollbar-size":"15px","--scrollbar-track-color":"#fff","--border-color":"#d3d3d3","--fbui-white":"#fff","--fbui-desktop-background-light":"#f6f7f8"};function Id(e){if(wm.hasOwnProperty(e))return wm[e];throw new Error('cssVar("'+e+'"): Unexpected class transformation.')}Id.CSS_VARS=wm;var Vhe=/-(.)/g;function Uhe(e){return e.replace(Vhe,function(t,r){return r.toUpperCase()})}var mf={},Cm=["Webkit","ms","Moz","O"],Ghe=new RegExp("^("+Cm.join("|")+")"),vS=wg.canUseDOM?document.createElement("div").style:{};function qhe(e){for(var t=0;t<Cm.length;t++){var r=Cm[t]+e;if(r in vS)return r}return null}function Da(e){var t=Uhe(e);if(mf[t]===void 0){var r=t.charAt(0).toUpperCase()+t.slice(1);Ghe.test(r)&&sn(!1,"getVendorPrefixedName must only be called with unprefixedCSS property names. It was called with %s",e),mf[t]=t in vS?t:qhe(r)}return mf[t]}var xm={hasCSSAnimations:function(){return!!Da("animationName")},hasCSSTransforms:function(){return!!Da("transform")},hasCSS3DTransforms:function(){return!!Da("perspective")},hasCSSTransitions:function(){return!!Da("transition")}},u2=Da("transform");Da("backfaceVisibility");var Yhe=function(){if(xm.hasCSSTransforms()){var e=ar.window?ar.window.navigator.userAgent:"UNKNOWN",t=/Safari\//.test(e)&&!/Chrome\//.test(e);return!t&&xm.hasCSS3DTransforms()?function(r,n,i){r[u2]="translate3d("+n+"px,"+i+"px,0)"}:function(r,n,i){r[u2]="translate("+n+"px,"+i+"px)"}}else return function(r,n,i){r.left=n+"px",r.top=i+"px"}}();function Ya(e,t,r){var n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;e.display!=="none"&&(n?(e.left=t+"px",e.top=r+"px"):(xm.hasCSSTransforms()&&(t*=i?-1:1),e.left=0,Yhe(e,t,r)),i&&(e.right=e.left,e.left="auto"))}function Xhe(e){var t=Zhe();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Zhe(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Khe={position:0,scrollable:!1},yS=parseInt(Id("--scrollbar-face-margin"),10),c2=yS*2,gf=30,bS=40,wr=function(e){Tt(r,e);var t=Xhe(r);function r(n){var i;return rt(this,r),i=t.call(this,n),ie(he(i),"_onRefFace",function(a){return i._faceRef=a}),ie(he(i),"_onRefRoot",function(a){return i._rootRef=a}),ie(he(i),"scrollBy",function(a){i._onWheel(a)}),ie(he(i),"_shouldHandleX",function(a){return i.props.orientation==="horizontal"?i._shouldHandleChange(a):!1}),ie(he(i),"_shouldHandleY",function(a){return i.props.orientation!=="horizontal"?i._shouldHandleChange(a):!1}),ie(he(i),"_shouldHandleChange",function(a){var o=i._calculateState(i.state.position+a,i.props.size,i.props.contentSize,i.props.orientation);return o.position!==i.state.position}),ie(he(i),"_calculateState",function(a,o,s,u){var c=Math.max(1,o);if(s<=c)return Khe;var d="".concat(a,"_").concat(c,"_").concat(s,"_").concat(u);if(i._stateKey===d)return i._stateForKey;var h=u==="horizontal",p=c/s,m=c*p;m<gf&&(p=(c-gf)/(s-c),m=gf);var g=!0,b=s-c;a<0?a=0:a>b&&(a=b);var _={faceSize:m,isHorizontal:h,position:a,scale:p,scrollable:g};return i._stateKey=d,i._stateForKey=_,_}),ie(he(i),"_onWheelY",function(a,o){i._onWheel(o)}),ie(he(i),"_onWheelX",function(a,o){i._onWheel(a)}),ie(he(i),"_onWheel",function(a){var o=i.props;i._setNextState(i._calculateState(i.state.position+a,o.size,o.contentSize,o.orientation))}),ie(he(i),"_onMouseDown",function(a){i.setState({isDragging:!0});var o;if(a.target!==i._faceRef){var s,u,c,d,h=a.nativeEvent,p=i.state.isHorizontal?(s=(u=h.offsetX)!==null&&u!==void 0?u:h.layerX)!==null&&s!==void 0?s:i.getTouchX(h):(c=(d=h.offsetY)!==null&&d!==void 0?d:h.layerY)!==null&&c!==void 0?c:i.getTouchY(h),m=i.props;p/=i.state.scale,o=i._calculateState(p-i.state.faceSize*.5/i.state.scale,m.size,m.contentSize,m.orientation)}else o={};i._setNextState(o),i._mouseMoveTracker.captureMouseMoves(a),i._rootRef.focus()}),ie(he(i),"_onTouchCancel",function(a){a.stopPropagation()}),ie(he(i),"_onTouchEnd",function(a){a.stopPropagation()}),ie(he(i),"_onTouchMove",function(a){a.stopPropagation()}),ie(he(i),"_onTouchStart",function(a){a.stopPropagation(),i._onMouseDown(a)}),ie(he(i),"_onMouseMove",function(a,o){var s=i.props,u=i.state.isHorizontal?a*(i.props.isRTL?-1:1):o;u/=i.state.scale;var c=Jn.flushSync||function(d){return d()};c(function(){return i._setNextState(i._calculateState(i.state.position+u,s.size,s.contentSize,s.orientation))})}),ie(he(i),"_onMouseMoveEnd",function(){i._nextState=null,i._mouseMoveTracker.releaseMouseMoves(),i.setState({isDragging:!1})}),ie(he(i),"_onKeyDown",function(a){var o=a.keyCode;if(o!==on.TAB){var s=bS,u=0;if(i.state.isHorizontal)switch(o){case on.HOME:u=-1,s=i.props.contentSize;break;case on.LEFT:u=-1;break;case on.RIGHT:u=1;break;default:return}if(!i.state.isHorizontal)switch(o){case on.SPACE:a.shiftKey?u=-1:u=1;break;case on.HOME:u=-1,s=i.props.contentSize;break;case on.UP:u=-1;break;case on.DOWN:u=1;break;case on.PAGE_UP:u=-1,s=i.props.size;break;case on.PAGE_DOWN:u=1,s=i.props.size;break;default:return}a.preventDefault();var c=i.props;i._setNextState(i._calculateState(i.state.position+s*u,c.size,c.contentSize,c.orientation))}}),ie(he(i),"getTouchX",function(a){return Math.round(a.targetTouches[0].clientX-a.target.getBoundingClientRect().x)}),ie(he(i),"getTouchY",function(a){return Math.round(a.targetTouches[0].clientY-a.target.getBoundingClientRect().y)}),ie(he(i),"_setNextState",function(a,o){o=o||i.props;var s=o.position,u=i.state.position!==a.position;if(s===void 0){var c=u?i._didScroll:void 0;i.setState(a,c)}else if(s===a.position)i.setState(a);else{a.position!==void 0&&a.position!==i.state.position&&i.props.onScroll(a.position);return}}),ie(he(i),"_didScroll",function(){i.props.onScroll(i.state.position)}),i.state=i._calculateState(n.position||n.defaultPosition||0,n.size,n.contentSize,n.orientation),i._initialRender=!0,i}return nt(r,[{key:"componentDidUpdate",value:function(){var i=this.props.position;i===void 0?this._setNextState(this._calculateState(this.state.position,this.props.size,this.props.contentSize,this.props.orientation)):this._setNextState(this._calculateState(i,this.props.size,this.props.contentSize,this.props.orientation),this.props)}},{key:"render",value:function(){if(!this.state.scrollable)return null;var i=this.props.size,a,o,s=this.state.isHorizontal,u=!s,c=this.state.isDragging,d=this.state.faceSize,h=this.props.isOpaque,p=this.props.verticalTop||0,m=Me({"ScrollbarLayout/main":!0,"ScrollbarLayout/mainVertical":u,"ScrollbarLayout/mainHorizontal":s,"public/Scrollbar/main":!0,"public/Scrollbar/mainOpaque":h,"public/Scrollbar/mainActive":c}),g=Me({"ScrollbarLayout/face":!0,"ScrollbarLayout/faceHorizontal":s,"ScrollbarLayout/faceVertical":u,"public/Scrollbar/faceActive":c,"public/Scrollbar/face":!0}),b=this.state.position*this.state.scale+yS;return s?(a={width:i},o={width:d-c2,top:0,bottom:0},Ya(o,b,0,this._initialRender,this.props.isRTL)):(a={top:p,height:i},this.props.isRTL&&(a.left=a.right||0,a.right="auto"),o={height:d-c2},Ya(o,0,b,this._initialRender,this.props.isRTL),o.left=0,o.right=0),a.touchAction="none",a.zIndex=this.props.zIndex,this.props.trackColor==="gray"&&(a.backgroundColor=Id("--fbui-desktop-background-light")),N.createElement("div",{onKeyDown:this._onKeyDown,onMouseDown:this._onMouseDown,onTouchCancel:this._onTouchCancel,onTouchEnd:this._onTouchEnd,onTouchMove:this._onTouchMove,onTouchStart:this._onTouchStart,className:m,style:a,ref:this._onRefRoot},N.createElement("div",{ref:this._onRefFace,className:g,style:o}))}},{key:"componentDidMount",value:function(){var i=this.props.orientation==="horizontal",a=i?this._onWheelX:this._onWheelY;this._wheelHandler=new mS(a,this._shouldHandleX,this._shouldHandleY,this.props.isRTL),this._rootRef&&this._rootRef.addEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._mouseMoveTracker=new Cg(this._onMouseMove,this._onMouseMoveEnd,document.documentElement,this.props.touchEnabled),this.props.position!==void 0&&this.state.position!==this.props.position&&this._didScroll(),this._initialRender=!1}},{key:"componentWillUnmount",value:function(){this._rootRef&&this._rootRef.removeEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._nextState=null,this._mouseMoveTracker&&(this._mouseMoveTracker.releaseMouseMoves(),this._mouseMoveTracker=null)}}]),r}(N.PureComponent);ie(wr,"propTypes",{contentSize:j.number.isRequired,defaultPosition:j.number,isOpaque:j.bool,orientation:j.oneOf(["vertical","horizontal"]),onScroll:j.func,position:j.number,size:j.number.isRequired,trackColor:j.oneOf(["gray"]),touchEnabled:j.bool,zIndex:j.number,verticalTop:j.number,isRTL:j.bool});ie(wr,"defaultProps",{defaultPosition:0,isOpaque:!1,onScroll:Ot,orientation:"vertical",zIndex:99});wr.KEYBOARD_SCROLL_AMOUNT=bS;wr.SIZE=parseInt(Id("--scrollbar-size"),10);wr.OFFSET=1;function Pt(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(process.env.NODE_ENV!=="production"){var i=sfe[e],a=i?typeof i=="function"?i.apply(null,r):i:"unknown error nr: "+e;throw Error("[Immer] "+a)}throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(o){return"'"+o+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function On(e){return!!e&&!!e[at]}function oi(e){return!!e&&(function(t){if(!t||typeof t!="object")return!1;var r=Object.getPrototypeOf(t);if(r===null)return!0;var n=Object.hasOwnProperty.call(r,"constructor")&&r.constructor;return n===Object||typeof n=="function"&&Function.toString.call(n)===lfe}(e)||Array.isArray(e)||!!e[v2]||!!e.constructor[v2]||xg(e)||Tg(e))}function Qhe(e){return On(e)||Pt(23,e),e[at].t}function $i(e,t,r){r===void 0&&(r=!1),Co(e)===0?(r?Object.keys:za)(e).forEach(function(n){r&&typeof n=="symbol"||t(n,e[n],e)}):e.forEach(function(n,i){return t(i,n,e)})}function Co(e){var t=e[at];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:xg(e)?2:Tg(e)?3:0}function Ba(e,t){return Co(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Jhe(e,t){return Co(e)===2?e.get(t):e[t]}function _S(e,t,r){var n=Co(e);n===2?e.set(t,r):n===3?(e.delete(t),e.add(r)):e[t]=r}function wS(e,t){return e===t?e!==0||1/e==1/t:e!=e&&t!=t}function xg(e){return afe&&e instanceof Map}function Tg(e){return ofe&&e instanceof Set}function Vn(e){return e.o||e.t}function Sg(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=xS(e);delete t[at];for(var r=za(t),n=0;n<r.length;n++){var i=r[n],a=t[i];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(t[i]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[i]})}return Object.create(Object.getPrototypeOf(e),t)}function Mg(e,t){return t===void 0&&(t=!1),Pg(e)||On(e)||!oi(e)||(Co(e)>1&&(e.set=e.add=e.clear=e.delete=efe),Object.freeze(e),t&&$i(e,function(r,n){return Mg(n,!0)},!0)),e}function efe(){Pt(2)}function Pg(e){return e==null||typeof e!="object"||Object.isFrozen(e)}function fn(e){var t=Pm[e];return t||Pt(18,e),t}function tfe(e,t){Pm[e]||(Pm[e]=t)}function Tm(){return process.env.NODE_ENV==="production"||Xa||Pt(0),Xa}function vf(e,t){t&&(fn("Patches"),e.u=[],e.s=[],e.v=t)}function mc(e){Sm(e),e.p.forEach(rfe),e.p=null}function Sm(e){e===Xa&&(Xa=e.l)}function d2(e){return Xa={p:[],l:Xa,h:e,m:!0,_:0}}function rfe(e){var t=e[at];t.i===0||t.i===1?t.j():t.O=!0}function yf(e,t){t._=t.p.length;var r=t.p[0],n=e!==void 0&&e!==r;return t.h.g||fn("ES5").S(t,e,n),n?(r[at].P&&(mc(t),Pt(4)),oi(e)&&(e=gc(t,e),t.l||vc(t,e)),t.u&&fn("Patches").M(r[at].t,e,t.u,t.s)):e=gc(t,r,[]),mc(t),t.u&&t.v(t.u,t.s),e!==CS?e:void 0}function gc(e,t,r){if(Pg(t))return t;var n=t[at];if(!n)return $i(t,function(a,o){return h2(e,n,t,a,o,r)},!0),t;if(n.A!==e)return t;if(!n.P)return vc(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=n.i===4||n.i===5?n.o=Sg(n.k):n.o;$i(n.i===3?new Set(i):i,function(a,o){return h2(e,n,i,a,o,r)}),vc(e,i,!1),r&&e.u&&fn("Patches").R(n,r,e.u,e.s)}return n.o}function h2(e,t,r,n,i,a){if(process.env.NODE_ENV!=="production"&&i===r&&Pt(5),On(i)){var o=gc(e,i,a&&t&&t.i!==3&&!Ba(t.D,n)?a.concat(n):void 0);if(_S(r,n,o),!On(o))return;e.m=!1}if(oi(i)&&!Pg(i)){if(!e.h.F&&e._<1)return;gc(e,i),t&&t.A.l||vc(e,i)}}function vc(e,t,r){r===void 0&&(r=!1),e.h.F&&e.m&&Mg(t,r)}function bf(e,t){var r=e[at];return(r?Vn(r):e)[t]}function f2(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function qn(e){e.P||(e.P=!0,e.l&&qn(e.l))}function _f(e){e.o||(e.o=Sg(e.t))}function Mm(e,t,r){var n=xg(t)?fn("MapSet").N(t,r):Tg(t)?fn("MapSet").T(t,r):e.g?function(i,a){var o=Array.isArray(i),s={i:o?1:0,A:a?a.A:Tm(),P:!1,I:!1,D:{},l:a,t:i,k:null,o:null,j:null,C:!1},u=s,c=Hs;o&&(u=[s],c=as);var d=Proxy.revocable(u,c),h=d.revoke,p=d.proxy;return s.k=p,s.j=h,p}(t,r):fn("ES5").J(t,r);return(r?r.A:Tm()).p.push(n),n}function nfe(e){return On(e)||Pt(22,e),function t(r){if(!oi(r))return r;var n,i=r[at],a=Co(r);if(i){if(!i.P&&(i.i<4||!fn("ES5").K(i)))return i.t;i.I=!0,n=p2(r,a),i.I=!1}else n=p2(r,a);return $i(n,function(o,s){i&&Jhe(i.t,o)===s||_S(n,o,t(s))}),a===3?new Set(n):n}(e)}function p2(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return Sg(e)}function ife(){function e(o,s){var u=a[o];return u?u.enumerable=s:a[o]=u={configurable:!0,enumerable:s,get:function(){var c=this[at];return process.env.NODE_ENV!=="production"&&i(c),Hs.get(c,o)},set:function(c){var d=this[at];process.env.NODE_ENV!=="production"&&i(d),Hs.set(d,o,c)}},u}function t(o){for(var s=o.length-1;s>=0;s--){var u=o[s][at];if(!u.P)switch(u.i){case 5:n(u)&&qn(u);break;case 4:r(u)&&qn(u)}}}function r(o){for(var s=o.t,u=o.k,c=za(u),d=c.length-1;d>=0;d--){var h=c[d];if(h!==at){var p=s[h];if(p===void 0&&!Ba(s,h))return!0;var m=u[h],g=m&&m[at];if(g?g.t!==p:!wS(m,p))return!0}}var b=!!s[at];return c.length!==za(s).length+(b?0:1)}function n(o){var s=o.k;if(s.length!==o.t.length)return!0;var u=Object.getOwnPropertyDescriptor(s,s.length-1);if(u&&!u.get)return!0;for(var c=0;c<s.length;c++)if(!s.hasOwnProperty(c))return!0;return!1}function i(o){o.O&&Pt(3,JSON.stringify(Vn(o)))}var a={};tfe("ES5",{J:function(o,s){var u=Array.isArray(o),c=function(h,p){if(h){for(var m=Array(p.length),g=0;g<p.length;g++)Object.defineProperty(m,""+g,e(g,!0));return m}var b=xS(p);delete b[at];for(var _=za(b),w=0;w<_.length;w++){var C=_[w];b[C]=e(C,h||!!b[C].enumerable)}return Object.create(Object.getPrototypeOf(p),b)}(u,o),d={i:u?5:4,A:s?s.A:Tm(),P:!1,I:!1,D:{},l:s,t:o,k:c,o:null,O:!1,C:!1};return Object.defineProperty(c,at,{value:d,writable:!0}),c},S:function(o,s,u){u?On(s)&&s[at].A===o&&t(o.p):(o.u&&function c(d){if(d&&typeof d=="object"){var h=d[at];if(h){var p=h.t,m=h.k,g=h.D,b=h.i;if(b===4)$i(m,function(T){T!==at&&(p[T]!==void 0||Ba(p,T)?g[T]||c(m[T]):(g[T]=!0,qn(h)))}),$i(p,function(T){m[T]!==void 0||Ba(m,T)||(g[T]=!1,qn(h))});else if(b===5){if(n(h)&&(qn(h),g.length=!0),m.length<p.length)for(var _=m.length;_<p.length;_++)g[_]=!1;else for(var w=p.length;w<m.length;w++)g[w]=!0;for(var C=Math.min(m.length,p.length),S=0;S<C;S++)m.hasOwnProperty(S)||(g[S]=!0),g[S]===void 0&&c(m[S])}}}}(o.p[0]),t(o.p))},K:function(o){return o.i===4?r(o):n(o)}})}var m2,Xa,Eg=typeof Symbol!="undefined"&&typeof Symbol("x")=="symbol",afe=typeof Map!="undefined",ofe=typeof Set!="undefined",g2=typeof Proxy!="undefined"&&Proxy.revocable!==void 0&&typeof Reflect!="undefined",CS=Eg?Symbol.for("immer-nothing"):((m2={})["immer-nothing"]=!0,m2),v2=Eg?Symbol.for("immer-draftable"):"__$immer_draftable",at=Eg?Symbol.for("immer-state"):"__$immer_state",sfe={0:"Illegal state",1:"Immer drafts cannot have computed properties",2:"This object has been frozen and should not be mutated",3:function(e){return"Cannot use a proxy that has been revoked. Did you pass an object from inside an immer function to an async process? "+e},4:"An immer producer returned a new value *and* modified its draft. Either return a new value *or* modify the draft.",5:"Immer forbids circular references",6:"The first or second argument to `produce` must be a function",7:"The third argument to `produce` must be a function or undefined",8:"First argument to `createDraft` must be a plain object, an array, or an immerable object",9:"First argument to `finishDraft` must be a draft returned by `createDraft`",10:"The given draft is already finalized",11:"Object.defineProperty() cannot be used on an Immer draft",12:"Object.setPrototypeOf() cannot be used on an Immer draft",13:"Immer only supports deleting array indices",14:"Immer only supports setting array indices and the 'length' property",15:function(e){return"Cannot apply patch, path doesn't resolve: "+e},16:'Sets cannot have "replace" patches.',17:function(e){return"Unsupported patch operation: "+e},18:function(e){return"The plugin for '"+e+"' has not been loaded into Immer. To enable the plugin, import and call `enable"+e+"()` when initializing your application."},20:"Cannot use proxies if Proxy, Proxy.revocable or Reflect are not available",21:function(e){return"produce can only be called on things that are draftable: plain objects, arrays, Map, Set or classes that are marked with '[immerable]: true'. Got '"+e+"'"},22:function(e){return"'current' expects a draft, got: "+e},23:function(e){return"'original' expects a draft, got: "+e},24:"Patching reserved attributes like __proto__, prototype and constructor is not allowed"},lfe=""+Object.prototype.constructor,za=typeof Reflect!="undefined"&&Reflect.ownKeys?Reflect.ownKeys:Object.getOwnPropertySymbols!==void 0?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,xS=Object.getOwnPropertyDescriptors||function(e){var t={};return za(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},Pm={},Hs={get:function(e,t){if(t===at)return e;var r=Vn(e);if(!Ba(r,t))return function(i,a,o){var s,u=f2(a,o);return u?"value"in u?u.value:(s=u.get)===null||s===void 0?void 0:s.call(i.k):void 0}(e,r,t);var n=r[t];return e.I||!oi(n)?n:n===bf(e.t,t)?(_f(e),e.o[t]=Mm(e.A.h,n,e)):n},has:function(e,t){return t in Vn(e)},ownKeys:function(e){return Reflect.ownKeys(Vn(e))},set:function(e,t,r){var n=f2(Vn(e),t);if(n!=null&&n.set)return n.set.call(e.k,r),!0;if(!e.P){var i=bf(Vn(e),t),a=i==null?void 0:i[at];if(a&&a.t===r)return e.o[t]=r,e.D[t]=!1,!0;if(wS(r,i)&&(r!==void 0||Ba(e.t,t)))return!0;_f(e),qn(e)}return e.o[t]===r&&typeof r!="number"&&(r!==void 0||t in e.o)||(e.o[t]=r,e.D[t]=!0,!0)},deleteProperty:function(e,t){return bf(e.t,t)!==void 0||t in e.t?(e.D[t]=!1,_f(e),qn(e)):delete e.D[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=Vn(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n&&{writable:!0,configurable:e.i!==1||t!=="length",enumerable:n.enumerable,value:r[t]}},defineProperty:function(){Pt(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){Pt(12)}},as={};$i(Hs,function(e,t){as[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),as.deleteProperty=function(e,t){return process.env.NODE_ENV!=="production"&&isNaN(parseInt(t))&&Pt(13),as.set.call(this,e,t,void 0)},as.set=function(e,t,r){return process.env.NODE_ENV!=="production"&&t!=="length"&&isNaN(parseInt(t))&&Pt(14),Hs.set.call(this,e[0],t,r,e[0])};var ufe=function(){function e(r){var n=this;this.g=g2,this.F=!0,this.produce=function(i,a,o){if(typeof i=="function"&&typeof a!="function"){var s=a;a=i;var u=n;return function(b){var _=this;b===void 0&&(b=s);for(var w=arguments.length,C=Array(w>1?w-1:0),S=1;S<w;S++)C[S-1]=arguments[S];return u.produce(b,function(T){var M;return(M=a).call.apply(M,[_,T].concat(C))})}}var c;if(typeof a!="function"&&Pt(6),o!==void 0&&typeof o!="function"&&Pt(7),oi(i)){var d=d2(n),h=Mm(n,i,void 0),p=!0;try{c=a(h),p=!1}finally{p?mc(d):Sm(d)}return typeof Promise!="undefined"&&c instanceof Promise?c.then(function(b){return vf(d,o),yf(b,d)},function(b){throw mc(d),b}):(vf(d,o),yf(c,d))}if(!i||typeof i!="object"){if((c=a(i))===void 0&&(c=i),c===CS&&(c=void 0),n.F&&Mg(c,!0),o){var m=[],g=[];fn("Patches").M(i,c,m,g),o(m,g)}return c}Pt(21,i)},this.produceWithPatches=function(i,a){if(typeof i=="function")return function(c){for(var d=arguments.length,h=Array(d>1?d-1:0),p=1;p<d;p++)h[p-1]=arguments[p];return n.produceWithPatches(c,function(m){return i.apply(void 0,[m].concat(h))})};var o,s,u=n.produce(i,a,function(c,d){o=c,s=d});return typeof Promise!="undefined"&&u instanceof Promise?u.then(function(c){return[c,o,s]}):[u,o,s]},typeof(r==null?void 0:r.useProxies)=="boolean"&&this.setUseProxies(r.useProxies),typeof(r==null?void 0:r.autoFreeze)=="boolean"&&this.setAutoFreeze(r.autoFreeze)}var t=e.prototype;return t.createDraft=function(r){oi(r)||Pt(8),On(r)&&(r=nfe(r));var n=d2(this),i=Mm(this,r,void 0);return i[at].C=!0,Sm(n),i},t.finishDraft=function(r,n){var i=r&&r[at];process.env.NODE_ENV!=="production"&&(i&&i.C||Pt(9),i.I&&Pt(10));var a=i.A;return vf(a,n),yf(void 0,a)},t.setAutoFreeze=function(r){this.F=r},t.setUseProxies=function(r){r&&!g2&&Pt(20),this.g=r},t.applyPatches=function(r,n){var i;for(i=n.length-1;i>=0;i--){var a=n[i];if(a.path.length===0&&a.op==="replace"){r=a.value;break}}i>-1&&(n=n.slice(i+1));var o=fn("Patches").$;return On(r)?o(r,n):this.produce(r,function(s){return o(s,n)})},e}(),Tr=new ufe,cfe=Tr.produce;Tr.produceWithPatches.bind(Tr);Tr.setAutoFreeze.bind(Tr);Tr.setUseProxies.bind(Tr);Tr.applyPatches.bind(Tr);Tr.createDraft.bind(Tr);Tr.finishDraft.bind(Tr);var Uu=cfe;function TS(e){var t=function(n){var i=n.dispatch,a=n.getState;return function(o){return function(s){return typeof s=="function"?s(i,a,e):o(s)}}};return t}var SS=TS();SS.withExtraArgument=TS;var y2=SS,dfe=function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),yc=function(e,t){for(var r=0,n=t.length,i=e.length;r<n;r++,i++)e[i]=t[r];return e},hfe=Object.defineProperty,b2=Object.getOwnPropertySymbols,ffe=Object.prototype.hasOwnProperty,pfe=Object.prototype.propertyIsEnumerable,_2=function(e,t,r){return t in e?hfe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r},Ws=function(e,t){for(var r in t||(t={}))ffe.call(t,r)&&_2(e,r,t[r]);if(b2)for(var n=0,i=b2(t);n<i.length;n++){var r=i[n];pfe.call(t,r)&&_2(e,r,t[r])}return e},mfe=typeof window!="undefined"&&window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__?window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__:function(){if(arguments.length!==0)return typeof arguments[0]=="object"?hc:hc.apply(null,arguments)};function MS(e){if(typeof e!="object"||e===null)return!1;var t=Object.getPrototypeOf(e);if(t===null)return!0;for(var r=t;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return t===r}function PS(e,t){var r=0;return{measureTime:function(n){var i=Date.now();try{return n()}finally{var a=Date.now();r+=a-i}},warnIfExceeded:function(){r>e&&console.warn(t+" took "+r+"ms, which is more than the warning threshold of "+e+`ms.
324
+ If your state or actions are very large, you may want to disable the middleware as it might cause too much of a slowdown in development mode. See https://redux-toolkit.js.org/api/getDefaultMiddleware for instructions.
325
+ It is disabled in production builds, so you don't need to worry about that.`)}}}var gfe=function(e){dfe(t,e);function t(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];var i=e.apply(this,r)||this;return Object.setPrototypeOf(i,t.prototype),i}return Object.defineProperty(t,Symbol.species,{get:function(){return t},enumerable:!1,configurable:!0}),t.prototype.concat=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return e.prototype.concat.apply(this,r)},t.prototype.prepend=function(){for(var r=[],n=0;n<arguments.length;n++)r[n]=arguments[n];return r.length===1&&Array.isArray(r[0])?new(t.bind.apply(t,yc([void 0],r[0].concat(this)))):new(t.bind.apply(t,yc([void 0],r.concat(this))))},t}(Array),vfe=process.env.NODE_ENV==="production",w2="Invariant failed";function C2(e,t){if(!e)throw vfe?new Error(w2):new Error(w2+": "+(t||""))}function yfe(e,t,r,n){return JSON.stringify(e,bfe(t,n),r)}function bfe(e,t){var r=[],n=[];return t||(t=function(i,a){return r[0]===a?"[Circular ~]":"[Circular ~."+n.slice(0,r.indexOf(a)).join(".")+"]"}),function(i,a){if(r.length>0){var o=r.indexOf(this);~o?r.splice(o+1):r.push(this),~o?n.splice(o,1/0,i):n.push(i),~r.indexOf(a)&&(a=t.call(this,i,a))}else r.push(a);return e==null?a:e.call(this,i,a)}}function _fe(e){return typeof e!="object"||e===null||typeof e=="undefined"||Object.isFrozen(e)}function wfe(e,t,r){var n=ES(e,t,r);return{detectMutations:function(){return AS(e,t,n,r)}}}function ES(e,t,r,n){t===void 0&&(t=[]),n===void 0&&(n="");var i={value:r};if(!e(r)){i.children={};for(var a in r){var o=n?n+"."+a:a;t.length&&t.indexOf(o)!==-1||(i.children[a]=ES(e,t,r[a],o))}}return i}function AS(e,t,r,n,i,a){t===void 0&&(t=[]),i===void 0&&(i=!1),a===void 0&&(a="");var o=r?r.value:void 0,s=o===n;if(i&&!s&&!Number.isNaN(n))return{wasMutated:!0,path:a};if(e(o)||e(n))return{wasMutated:!1};var u={};for(var c in r.children)u[c]=!0;for(var c in n)u[c]=!0;for(var c in u){var d=a?a+"."+c:c;if(!(t.length&&t.indexOf(d)!==-1)){var h=AS(e,t,r.children[c],n[c],s,d);if(h.wasMutated)return h}}return{wasMutated:!1}}function Cfe(e){if(e===void 0&&(e={}),process.env.NODE_ENV==="production")return function(){return function(u){return function(c){return u(c)}}};var t=e.isImmutable,r=t===void 0?_fe:t,n=e.ignoredPaths,i=e.warnAfter,a=i===void 0?32:i,o=e.ignore;n=n||o;var s=wfe.bind(null,r,n);return function(u){var c=u.getState,d=c(),h=s(d),p;return function(m){return function(g){var b=PS(a,"ImmutableStateInvariantMiddleware");b.measureTime(function(){d=c(),p=h.detectMutations(),h=s(d),C2(!p.wasMutated,"A state mutation was detected between dispatches, in the path '"+(p.path||"")+"'. This may cause incorrect behavior. (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)")});var _=m(g);return b.measureTime(function(){d=c(),p=h.detectMutations(),h=s(d),p.wasMutated&&C2(!p.wasMutated,"A state mutation was detected inside a dispatch, in the path: "+(p.path||"")+". Take a look at the reducer(s) handling the action "+yfe(g)+". (https://redux.js.org/style-guide/style-guide#do-not-mutate-state)")}),b.warnIfExceeded(),_}}}}function RS(e){var t=typeof e;return t==="undefined"||e===null||t==="string"||t==="boolean"||t==="number"||Array.isArray(e)||MS(e)}function Em(e,t,r,n,i){t===void 0&&(t=""),r===void 0&&(r=RS),i===void 0&&(i=[]);var a;if(!r(e))return{keyPath:t||"<root>",value:e};if(typeof e!="object"||e===null)return!1;for(var o=n!=null?n(e):Object.entries(e),s=i.length>0,u=0,c=o;u<c.length;u++){var d=c[u],h=d[0],p=d[1],m=t?t+"."+h:h;if(!(s&&i.indexOf(m)>=0)){if(!r(p))return{keyPath:m,value:p};if(typeof p=="object"&&(a=Em(p,m,r,n,i),a))return a}}return!1}function xfe(e){if(e===void 0&&(e={}),process.env.NODE_ENV==="production")return function(){return function(_){return function(w){return _(w)}}};var t=e.isSerializable,r=t===void 0?RS:t,n=e.getEntries,i=e.ignoredActions,a=i===void 0?[]:i,o=e.ignoredActionPaths,s=o===void 0?["meta.arg","meta.baseQueryMeta"]:o,u=e.ignoredPaths,c=u===void 0?[]:u,d=e.warnAfter,h=d===void 0?32:d,p=e.ignoreState,m=p===void 0?!1:p,g=e.ignoreActions,b=g===void 0?!1:g;return function(_){return function(w){return function(C){var S=w(C),T=PS(h,"SerializableStateInvariantMiddleware");return!b&&!(a.length&&a.indexOf(C.type)!==-1)&&T.measureTime(function(){var M=Em(C,"",r,n,s);if(M){var P=M.keyPath,R=M.value;console.error("A non-serializable value was detected in an action, in the path: `"+P+"`. Value:",R,`
326
+ Take a look at the logic that dispatched this action: `,C,`
327
+ (See https://redux.js.org/faq/actions#why-should-type-be-a-string-or-at-least-serializable-why-should-my-action-types-be-constants)`,`
328
+ (To allow non-serializable values see: https://redux-toolkit.js.org/usage/usage-guide#working-with-non-serializable-data)`)}}),m||(T.measureTime(function(){var M=_.getState(),P=Em(M,"",r,n,c);if(P){var R=P.keyPath,k=P.value;console.error("A non-serializable value was detected in the state, in the path: `"+R+"`. Value:",k,`
329
+ Take a look at the reducer(s) handling this action type: `+C.type+`.
330
+ (See https://redux.js.org/faq/organizing-state#can-i-put-functions-promises-or-other-non-serializable-items-in-my-store-state)`)}}),T.warnIfExceeded()),S}}}}function wf(e){return typeof e=="boolean"}function Tfe(){return function(t){return Sfe(t)}}function Sfe(e){e===void 0&&(e={});var t=e.thunk,r=t===void 0?!0:t,n=e.immutableCheck,i=n===void 0?!0:n,a=e.serializableCheck,o=a===void 0?!0:a,s=new gfe;if(r&&(wf(r)?s.push(y2):s.push(y2.withExtraArgument(r.extraArgument))),process.env.NODE_ENV!=="production"){if(i){var u={};wf(i)||(u=i),s.unshift(Cfe(u))}if(o){var c={};wf(o)||(c=o),s.push(xfe(c))}}return s}var Cf=process.env.NODE_ENV==="production";function Mfe(e){var t=Tfe(),r=e||{},n=r.reducer,i=n===void 0?void 0:n,a=r.middleware,o=a===void 0?t():a,s=r.devTools,u=s===void 0?!0:s,c=r.preloadedState,d=c===void 0?void 0:c,h=r.enhancers,p=h===void 0?void 0:h,m;if(typeof i=="function")m=i;else if(MS(i))m=Hae(i);else throw new Error('"reducer" is a required argument, and must be a function or an object of functions that can be passed to combineReducers');var g=o;if(typeof g=="function"&&(g=g(t),!Cf&&!Array.isArray(g)))throw new Error("when using a middleware builder function, an array of middleware must be returned");if(!Cf&&g.some(function(S){return typeof S!="function"}))throw new Error("each middleware provided to configureStore must be a function");var b=Wae.apply(void 0,g),_=hc;u&&(_=mfe(Ws({trace:!Cf},typeof u=="object"&&u)));var w=[b];Array.isArray(p)?w=yc([b],p):typeof p=="function"&&(w=p(w));var C=_.apply(void 0,w);return zT(m,d,C)}function js(e,t){function r(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(t){var a=t.apply(void 0,n);if(!a)throw new Error("prepareAction did not return an object");return Ws(Ws({type:e,payload:a.payload},"meta"in a&&{meta:a.meta}),"error"in a&&{error:a.error})}return{type:e,payload:n[0]}}return r.toString=function(){return""+e},r.type=e,r.match=function(n){return n.type===e},r}function DS(e){var t={},r=[],n,i={addCase:function(a,o){if(process.env.NODE_ENV!=="production"){if(r.length>0)throw new Error("`builder.addCase` should only be called before calling `builder.addMatcher`");if(n)throw new Error("`builder.addCase` should only be called before calling `builder.addDefaultCase`")}var s=typeof a=="string"?a:a.type;if(s in t)throw new Error("addCase cannot be called with two reducers for the same action type");return t[s]=o,i},addMatcher:function(a,o){if(process.env.NODE_ENV!=="production"&&n)throw new Error("`builder.addMatcher` should only be called before calling `builder.addDefaultCase`");return r.push({matcher:a,reducer:o}),i},addDefaultCase:function(a){if(process.env.NODE_ENV!=="production"&&n)throw new Error("`builder.addDefaultCase` can only be called once");return n=a,i}};return e(i),[t,r,n]}function Pfe(e){return typeof e=="function"}function Efe(e,t,r,n){r===void 0&&(r=[]);var i=typeof t=="function"?DS(t):[t,r,n],a=i[0],o=i[1],s=i[2],u;if(Pfe(e))u=function(){return Uu(e(),function(){})};else{var c=Uu(e,function(){});u=function(){return c}}function d(h,p){h===void 0&&(h=u());var m=yc([a[p.type]],o.filter(function(g){var b=g.matcher;return b(p)}).map(function(g){var b=g.reducer;return b}));return m.filter(function(g){return!!g}).length===0&&(m=[s]),m.reduce(function(g,b){if(b)if(On(g)){var _=g,w=b(_,p);return typeof w=="undefined"?g:w}else{if(oi(g))return Uu(g,function(C){return b(C,p)});var w=b(g,p);if(typeof w=="undefined"){if(g===null)return g;throw Error("A case reducer on a non-draftable value must not return undefined")}return w}return g},h)}return d.getInitialState=u,d}function Afe(e,t){return e+"/"+t}function Rfe(e){var t=e.name;if(!t)throw new Error("`name` is a required option for createSlice");var r=typeof e.initialState=="function"?e.initialState:Uu(e.initialState,function(){}),n=e.reducers||{},i=Object.keys(n),a={},o={},s={};i.forEach(function(d){var h=n[d],p=Afe(t,d),m,g;"reducer"in h?(m=h.reducer,g=h.prepare):m=h,a[d]=m,o[p]=m,s[d]=g?js(p,g):js(p)});function u(){var d=typeof e.extraReducers=="function"?DS(e.extraReducers):[e.extraReducers],h=d[0],p=h===void 0?{}:h,m=d[1],g=m===void 0?[]:m,b=d[2],_=b===void 0?void 0:b,w=Ws(Ws({},p),o);return Efe(r,w,g,_)}var c;return{name:t,reducer:function(d,h){return c||(c=u()),c(d,h)},actions:s,caseReducers:a,getInitialState:function(){return c||(c=u()),c.getInitialState()}}}var Ag="listenerMiddleware";js(Ag+"/add");js(Ag+"/removeAll");js(Ag+"/remove");ife();function Dfe(){var e=Nfe();return{columnElements:[],columnGroupElements:[],elementTemplates:{cell:[],footer:[],groupHeader:[],header:[]},elementHeights:{footerHeight:0,groupHeaderHeight:0,headerHeight:0},propsRevision:null,rowSettings:{bufferRowCount:void 0,rowAttributesGetter:void 0,rowHeight:0,rowHeightGetter:function(){return 0},rowsCount:0,subRowHeight:0,subRowHeightGetter:function(){return 0}},scrollFlags:{overflowX:"auto",overflowY:"auto",showScrollbarX:!0,showScrollbarY:!0},tableSize:{height:void 0,maxHeight:0,ownerHeight:void 0,useMaxHeight:!1,width:0},firstRowIndex:0,firstRowOffset:0,maxScrollX:0,maxScrollY:0,rowOffsets:{},rows:[],scrollContentHeight:0,scrollX:0,scrollbarXHeight:wr.SIZE,scrollY:0,scrollbarYWidth:wr.SIZE,scrolling:!1,getInternal:function(){return e}}}function Nfe(){return{rowBufferSet:new tS,rowOffsetIntervalTree:null,storedHeights:[],rowUntilOffsetsAreExact:0}}var NS=Rfe({name:"FDT",initialState:{},reducers:{initialize:function(t,r){var n=r.payload;ot(t,Dfe()),T2(t,n),x2(t);var i=qb(t,n);Ko(t,i),e2.initialize(t,n,{})},propChange:function(t,r){var n=r.payload,i=n.newProps,a=n.oldProps,o=fde(Qhe(t));T2(t,i),(a.rowsCount!==i.rowsCount||a.rowHeight!==i.rowHeight||a.subRowHeight!==i.subRowHeight)&&x2(t),a.rowsCount!==i.rowsCount&&(t.getInternal().rowBufferSet=new tS);var s=qb(t,i,a);(!Bs(t,o)||s.changed)&&Ko(t,s),e2.initialize(t,i,a),(t.scrollX!==o.scrollX||t.scrollY!==o.scrollY)&&(t.scrolling=t.scrolling||!0)},scrollEnd:function(t){t.scrolling=!1;var r={firstIndex:t.firstRowIndex,firstOffset:t.firstRowOffset,lastIndex:t.lastIndex};Ko(t,r)},scrollToY:function(t,r){var n=r.payload;t.scrolling=!0;var i=lm(t,n);Ko(t,i)},scrollToX:function(t,r){var n=r.payload;t.scrolling=!0,t.scrollX=n},updateRowHeights:function(t,r){var n=r.payload||0;if(!(n>=t.rowSettings.rowsCount)){for(;n<t.rowSettings.rowsCount;)xi(t,n++);var i=t.getInternal().rowOffsetIntervalTree.sumUntil(t.firstRowIndex)-t.firstRowOffset,a=lm(t,i);Ko(t,a)}}}});function x2(e){for(var t=e.rowSettings,r=t.rowHeight,n=t.rowsCount,i=t.subRowHeight,a=t.rowHeightGetter,o=t.subRowHeightGetter,s=r+i,u=0,c=new Array(n),d=0;d<n;d++)e.isVerticalScrollExact?c[d]=a(d)+o(d):c[d]=s,u+=c[d];var h=new vde(c);e.scrollContentHeight=u,ot(e.getInternal(),{rowOffsetIntervalTree:h,storedHeights:c})}function T2(e,t){var r=_de(t.children),n=r.columnGroupElements,i=r.columnElements,a=r.elementTemplates,o=r.useGroupHeader;ot(e,{columnGroupElements:n,columnElements:i,elementTemplates:a,propsRevision:e.propsRevision+1,isVerticalScrollExact:t.isVerticalScrollExact}),Object.freeze(e.columnElements),Object.freeze(e.columnGroupElements),Object.freeze(e.elementTemplates),e.elementHeights=ot({},e.elementHeights,is(t,["cellGroupWrapperHeight","footerHeight","groupHeaderHeight","headerHeight"])),o||(e.elementHeights.groupHeaderHeight=0),e.rowSettings=ot({},e.rowSettings,is(t,["bufferRowCount","rowHeight","rowsCount","subRowHeight"]));var s=e.rowSettings,u=s.rowHeight,c=s.subRowHeight;e.rowSettings.rowHeightGetter=t.rowHeightGetter||function(){return u},e.rowSettings.subRowHeightGetter=t.subRowHeightGetter||function(){return c||0},e.rowSettings.rowAttributesGetter=t.rowAttributesGetter,e.scrollFlags=ot({},e.scrollFlags,is(t,["overflowX","overflowY","showScrollbarX","showScrollbarY"])),e.tableSize=ot({},e.tableSize,is(t,["height","maxHeight","ownerHeight","width"])),e.tableSize.useMaxHeight=e.tableSize.height===void 0,e.scrollbarXHeight=t.scrollbarXHeight,e.scrollbarYWidth=t.scrollbarYWidth}var kfe=NS.reducer,xo=NS.actions,Lfe=xo.initialize,Ofe=xo.propChange,Ife=xo.scrollEnd,Ffe=xo.scrollToX,$fe=xo.scrollToY,Bfe=xo.updateRowHeights,zfe=function(t,r){var n=HT({scrollToX:Ffe,scrollToY:$fe,scrollEnd:Ife},t.dispatch),i=function(s){var u=t.getState(),c=u.scrollX;if(s!==c){var d=Math.round(s),h=r(),p=h.onHorizontalScroll;(!p||p(d))&&n.scrollToX(d)}},a=function(s){var u=t.getState(),c=u.scrollY;if(s!==c){var d=r(),h=d.onVerticalScroll;(!h||h(s))&&n.scrollToY(s)}};return{scrollToX:i,scrollToY:a,stopScroll:n.scrollEnd}},Hfe=Gi,Wfe=ui,jfe="[object Number]";function Vfe(e){return typeof e=="number"||Wfe(e)&&Hfe(e)==jfe}var Ufe=Vfe,Gfe=Ufe;function qfe(e){return Gfe(e)&&e!=+e}var S2=qfe;function Yfe(e,t,r,n,i){n=n||setTimeout,i=i||clearTimeout;var a;function o(){for(var s=arguments.length,u=new Array(s),c=0;c<s;c++)u[c]=arguments[c];o.reset();var d=function(){e.apply(r,u)};d.__SMmeta=e.__SMmeta,a=n(d,t)}return o.reset=function(){i(a)},o}function Lt(e){e||(e="");var t,r=arguments.length;if(r>1)for(var n=1;n<r;n++)t=arguments[n],t&&(e=(e?e+" ":"")+t);return e}function Xfe(e,t,r){var n=1,i=1,a=e+2,o=e+1,s=2;return t&&(i++,o++,a++,s++),r&&o++,{ariaGroupHeaderIndex:n,ariaHeaderIndex:i,ariaFooterIndex:a,ariaRowCount:o,ariaRowIndexOffset:s}}var Zfe=Fn([function(e){return e.rowsCount},function(e){return e.groupHeaderHeight>0},function(e){return e.footerHeight>0}],Xfe);function Kfe(e){return function(t,r,n){for(var i=-1,a=Object(t),o=n(t),s=o.length;s--;){var u=o[e?s:++i];if(r(a[u],u,a)===!1)break}return t}}var Qfe=Kfe,Jfe=Qfe,epe=Jfe(),tpe=epe,rpe=tpe,npe=wd;function ipe(e,t){return e&&rpe(e,t,npe)}var ape=ipe,ope=ml;function spe(e,t){return function(r,n){if(r==null)return r;if(!ope(r))return e(r,n);for(var i=r.length,a=t?i:-1,o=Object(r);(t?a--:++a<i)&&n(o[a],a,o)!==!1;);return r}}var lpe=spe,upe=ape,cpe=lpe,dpe=cpe(upe),hpe=dpe,fpe=$T;function ppe(e){return typeof e=="function"?e:fpe}var mpe=ppe,gpe=WT,vpe=hpe,ype=mpe,bpe=$r;function _pe(e,t){var r=bpe(e)?gpe:vpe;return r(e,ype(t))}var M2=_pe;function wpe(e,t){var r=e.columnGroupProps,n=e.columnProps,i=[],a=[],o=[];M2(r,function(d,h){var p={props:d,template:t.groupHeader[h]};d.fixed?i.push(p):d.fixedRight?a.push(p):o.push(p)});var s={cell:[],header:[],footer:[]},u={cell:[],header:[],footer:[]},c={cell:[],header:[],footer:[]};return M2(n,function(d,h){var p=c;d.fixed?p=s:d.fixedRight&&(p=u),p.cell.push({props:d,template:t.cell[h]}),p.header.push({props:d,template:t.header[h]}),p.footer.push({props:d,template:t.footer[h]})}),{fixedColumnGroups:i,fixedColumns:s,fixedRightColumnGroups:a,fixedRightColumns:u,scrollableColumnGroups:o,scrollableColumns:c}}var Cpe=Fn([function(e){return vl(e)},function(e){return e.elementTemplates}],wpe);function xpe(e,t){return e==null||e!==e?t:e}var Tpe=xpe,Spe=Math.max,Mpe=Math.min;function Ppe(e,t,r){return e>=Mpe(t,r)&&e<Spe(t,r)}var Epe=Ppe,Ape=gg,P2=1/0,Rpe=17976931348623157e292;function Dpe(e){if(!e)return e===0?e:0;if(e=Ape(e),e===P2||e===-P2){var t=e<0?-1:1;return t*Rpe}return e===e?e:0}var Npe=Dpe,kpe=Epe,E2=Npe,Lpe=gg;function Ope(e,t,r){return t=E2(t),r===void 0?(r=t,t=0):r=E2(r),e=Lpe(e),kpe(e,t,r)}var Ei=Ope;function Ipe(e,t){if(e==null)return{};var r={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(t.indexOf(n)!==-1)continue;r[n]=e[n]}return r}function Dn(e,t){if(e==null)return{};var r,n,i=Ipe(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)r=a[n],t.indexOf(r)===-1&&{}.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}var Fpe=["height","width","isVisible","style","className","children","columnKey","columnIndex","rowIndex","left","cellGroupType","isHeader","isGroupHeader","maxWidth","minWidth","touchEnabled"];function A2(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 $pe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?A2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):A2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Bpe(e){var t=zpe();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function zpe(){if(typeof Reflect=="undefined"||!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(e){return!1}}var bc=function(e){Tt(r,e);var t=Bpe(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){var i=this.props,a=i.height,o=i.width,s=i.style,u=i.className,c=i.children,d=Dn(i,Fpe),h=$pe({height:a,width:o},s);return N.createElement("div",ot({},d,{className:Lt(Me("fixedDataTableCellLayout/wrap1"),Me("public/fixedDataTableCell/wrap1"),u),style:h}),N.createElement("div",{className:Lt(Me("fixedDataTableCellLayout/wrap2"),Me("public/fixedDataTableCell/wrap2"))},N.createElement("div",{className:Lt(Me("fixedDataTableCellLayout/wrap3"),Me("public/fixedDataTableCell/wrap3"))},N.createElement("div",{className:Me("public/fixedDataTableCell/cellContent")},c))))}}]),r}(N.Component);ie(bc,"propTypes",{height:j.number,width:j.number,columnKey:j.oneOfType([j.string,j.number]),rowIndex:j.number,isVisible:j.bool});function kS(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);e!=null&&this.setState(e)}function LS(e){function t(r){var n=this.constructor.getDerivedStateFromProps(e,r);return n!=null?n:null}this.setState(t.bind(this))}function OS(e,t){try{var r=this.props,n=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(r,n)}finally{this.props=r,this.state=n}}kS.__suppressDeprecationWarning=!0;LS.__suppressDeprecationWarning=!0;OS.__suppressDeprecationWarning=!0;function IS(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if(typeof e.getDerivedStateFromProps!="function"&&typeof t.getSnapshotBeforeUpdate!="function")return e;var r=null,n=null,i=null;if(typeof t.componentWillMount=="function"?r="componentWillMount":typeof t.UNSAFE_componentWillMount=="function"&&(r="UNSAFE_componentWillMount"),typeof t.componentWillReceiveProps=="function"?n="componentWillReceiveProps":typeof t.UNSAFE_componentWillReceiveProps=="function"&&(n="UNSAFE_componentWillReceiveProps"),typeof t.componentWillUpdate=="function"?i="componentWillUpdate":typeof t.UNSAFE_componentWillUpdate=="function"&&(i="UNSAFE_componentWillUpdate"),r!==null||n!==null||i!==null){var a=e.displayName||e.name,o=typeof e.getDerivedStateFromProps=="function"?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs.
331
+
332
+ `+a+" uses "+o+" but also contains the following legacy lifecycles:"+(r!==null?`
333
+ `+r:"")+(n!==null?`
334
+ `+n:"")+(i!==null?`
335
+ `+i:"")+`
336
+
337
+ The above lifecycles should be removed. Learn more about this warning here:
338
+ https://fb.me/react-async-component-lifecycle-hooks`)}if(typeof e.getDerivedStateFromProps=="function"&&(t.componentWillMount=kS,t.componentWillReceiveProps=LS),typeof t.getSnapshotBeforeUpdate=="function"){if(typeof t.componentDidUpdate!="function")throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=OS;var s=t.componentDidUpdate;t.componentDidUpdate=function(c,d,h){var p=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:h;s.call(this,c,d,p)}}return e}var Hpe=["height","width","isVisible","style","className","children","columnKey","columnIndex","rowIndex","left","cellGroupType","isHeader","isGroupHeader","maxWidth","minWidth","touchEnabled"];function R2(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 Wpe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?R2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):R2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Rg=N.forwardRef(function(t,r){var n=t.height,i=t.width,a=t.style,o=t.className,s=t.children,u=Dn(t,Hpe),c=Wpe({height:n,width:i},a);return N.createElement("div",ot({},u,{className:Lt(Me("fixedDataTableCellLayout/wrap"),Me("public/fixedDataTableCell/wrap"),Me("public/fixedDataTableCell/cellContent"),o),style:c,ref:r}),s)});Rg.propTypes={height:j.number,width:j.number,columnKey:j.oneOfType([j.string,j.number]),rowIndex:j.number,isVisible:j.bool};var Za=N.createContext({}),jpe=NT;function Vpe(e,t,r){var n=e==null?void 0:jpe(e,t);return n===void 0?r:n}var Am=Vpe;function Upe(e){var t=Gpe();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Gpe(){if(typeof Reflect=="undefined"||!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(e){return!1}}var D2=15,N2=100,Dg=function(e){Tt(r,e);var t=Upe(r);function r(){var n;rt(this,r);for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return n=t.call.apply(t,[this].concat(a)),ie(he(n),"state",{displacement:0}),ie(he(n),"containerRef",N.createRef()),ie(he(n),"onTouchEnd",function(s){n.props.touchEnabled&&s.stopPropagation()}),ie(he(n),"onTouchMove",function(s){n.props.touchEnabled&&s.stopPropagation()}),ie(he(n),"onMouseMove",function(s){n.cursorDeltaX+=s*(n.context.isRTL?-1:1)}),ie(he(n),"onMouseUp",function(){gS(n.frameId),n.setState({displacement:0,isReordering:!1}),n.updateColumnOrder(),n.frameId=null,n.cursorDeltaX=0,n.mouseMoveTracker.releaseMouseMoves()}),ie(he(n),"initializeDOMMouseMoveTracker",function(s){n.mouseMoveTracker=new Cg(n.onMouseMove,n.onMouseUp,document.body,n.props.touchEnabled),n.mouseMoveTracker.captureMouseMoves(s)}),ie(he(n),"updateDisplacementPeriodically",function(){n.frameId=ti(n.updateDisplacementPeriodically),n.updateDisplacementWithScroll()}),ie(he(n),"getBoundedDeltaX",function(s){var u=0,c=0,d=n.props.cellGroupType,h=n.context.groupHeaderHeight>0;if(h&&!n.props.isGroupHeader){var p=n.context.getColumnGroupByChild(n.props.columnIndex);u=p.width,c=p.offset}else u=n.context.getCellGroupWidth(d);var m=u-n.props.width;return Td(s,-n.originalLeft+c,-n.originalLeft+m+c)}),ie(he(n),"updateDisplacementWithScroll",function(){var s=n.scrollStart,u=n.props.cellGroupType,c=n.context,d=c.scrollX,h=c.maxScrollX,p=c.availableScrollWidth,m=n.cursorDeltaX;if(u===Pe.SCROLLABLE){var g=n.originalLeft-s+m;m+=d-s,g>p-N2?d=Math.min(d+D2,h):g<=N2&&(d=Math.max(d-D2,0)),n.context.scrollToX(d)}m=n.getBoundedDeltaX(m),n.setState({displacement:m})}),ie(he(n),"isColumnMovedToRight",function(s){return s>0}),ie(he(n),"isColumnMovedToLeft",function(s){return s<0}),ie(he(n),"updateColumnOrder",function(){var s=n.props.cellGroupType,u=n.getBoundedDeltaX(n.cursorDeltaX+n.context.scrollX-n.scrollStart),c=u>=0?n.props.width+u+n.props.left:u+n.props.left,d,h;if(n.props.isGroupHeader){var p=n.context.getColumnGroupAtOffset(c,s),m=p.columnGroup,g=p.distanceFromOffset;d=m,h=g}else{var b=n.context.getColumnAtOffset(c,s),_=b.column,w=b.distanceFromOffset;d=_,h=w}var C=null,S=null;d.index<n.props.columnIndex?h<=d.width/2?(C=d.index-1,S=d.index):(C=d.index,S=d.index+1):h>=d.width/2?(C=d.index,S=d.index+1):(C=d.index-1,S=d.index),C===n.props.columnIndex&&--C,S===n.props.columnIndex&&++S;var T=n.props.isGroupHeader?n.context.getColumnGroupCount():n.context.getColumnCount(),M,P;Ei(C,0,T)&&(M=n.props.isGroupHeader?n.context.getColumnGroup(C):n.context.getColumn(C)),Ei(S,0,T)&&(P=n.props.isGroupHeader?n.context.getColumnGroup(S):n.context.getColumn(S)),n.props.onColumnReorderEnd({columnBefore:Am(M,"columnKey"),columnAfter:Am(P,"columnKey"),reorderColumn:n.props.columnKey})}),n}return nt(r,[{key:"componentDidMount",value:function(){var i=this.props.contents.parentNode.cloneNode(!0);i.firstChild.classList.add(Me("public/fixedDataTableCell/reordering")),this.containerRef.current.appendChild(i),this.startDrag()}},{key:"render",value:function(){var i={position:"absolute"};return Ya(i,this.state.displacement,0,!0,this.context.isRTL),N.createElement("div",{style:i,ref:this.containerRef})}},{key:"startDrag",value:function(){this.cursorDeltaX=0,this.scrollStart=this.context.scrollX,this.originalLeft=this.props.left,this.initializeDOMMouseMoveTracker(this.props.reorderStartEvent),this.setState({displacement:0,isReordering:!0}),this.frameId=ti(this.updateDisplacementPeriodically)}}]),r}(N.PureComponent);Dg.contextType=Za;Dg.propTypes={columnIndex:j.number.isRequired,columnKey:j.string.isRequired,contents:j.object.isRequired,cellGroupType:j.string,isGroupHeader:j.bool,isRTL:j.bool,left:j.number.isRequired,onColumnReorderStart:j.func.isRequired,reorderStartEvent:j.object.isRequired,touchEnabled:j.bool,width:j.number.isRequired};function qpe(e){var t=Ype();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Ype(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Xpe=function(e){Tt(r,e);var t=qpe(r);function r(n){var i;rt(this,r),i=t.call(this,n);var a=n.value;return i.unsubscribe=a.subscribe(function(o){i.setState({FixedDataTableContextValue:o})}),i.state={FixedDataTableContextValue:a},i}return nt(r,[{key:"componentWillUnmount",value:function(){this.unsubscribe()}},{key:"render",value:function(){var i=this.state.FixedDataTableContextValue;return N.createElement(Za.Provider,{value:i},this.props.children)}}]),r}(N.PureComponent);function Zpe(){}var Kpe=Zpe,Qpe=["onColumnReorderStart","onColumnReorderEnd","reorderStartEvent","children"];function Jpe(e){var t=eme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function eme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var tme=1,Vs=function(e){Tt(r,e);var t=Jpe(r);function r(){var n;rt(this,r);for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return n=t.call.apply(t,[this].concat(a)),ie(he(n),"state",{isReordering:!1}),ie(he(n),"dragContainer",null),ie(he(n),"cellRef",N.createRef()),ie(he(n),"isMounted",!1),ie(he(n),"setReorderHandle",function(s){s&&(s.addEventListener("mousedown",n.onMouseDown,{passive:!1}),s.addEventListener("touchstart",n.onTouchStart,{passive:!1}))}),ie(he(n),"onTouchStart",function(s){n.props.touchEnabled&&n.onMouseDown(s)}),ie(he(n),"onMouseDown",function(s){n.onDragStart(s)}),ie(he(n),"onDragStart",function(s){n.createDragContainer(),n.renderDragProxy(s),n.props.onColumnReorderStart(n.props.columnKey)}),ie(he(n),"onColumnReorderEnd",function(s){n.isMounted&&n.setState({isReordering:!1}),n.removeDragContainer(),n.props.onColumnReorderEnd(s)}),ie(he(n),"createDragContainer",function(){n.dragContainer=document.createElement("div"),n.dragContainer.dataset.columnKey=n.props.columnKey;var s=n.cellRef.current.closest(".fixedDataTableCellGroupLayout_cellGroup");s.appendChild(n.dragContainer)}),ie(he(n),"getDragContainer",function(){if(n.dragContainer)return n.dragContainer;var s=n.cellRef.current.closest(".fixedDataTableCellGroupLayout_cellGroup");return n.dragContainer=s.querySelector('[data-column-key="'.concat(n.props.columnKey,'"]')),n.dragContainer}),ie(he(n),"removeDragContainer",function(){n.props.__react19RootCreator?n.dragContainer.root.unmount():Jn.unmountComponentAtNode(n.dragContainer),n.dragContainer.remove(),n.dragContainer=null}),n}return nt(r,[{key:"componentDidMount",value:function(){this.isMounted=!0;var i=Am(this.getDragContainer(),"dataset.columnKey"),a=DT(this.props.columnKey)===i;a&&(this.renderDragProxy({}),this.setState({isReordering:!0}))}},{key:"componentWillUnmount",value:function(){this.isMounted=!1}},{key:"render",value:function(){if(this.state.isReordering)return null;var i=this.props,a=i.children,o=Dn(i,Qpe),s=Lt(Me({"public/fixedDataTableCell/resizeReorderCellContainer":!0}),o.className),u=Lt(s,Me({"public/fixedDataTableCell/hasReorderHandle":!0})),c={height:o.height,width:o.width-tme},d;return N.isValidElement(a)?d=N.cloneElement(a,o):typeof a=="function"?d=a(o):d=N.createElement(Rg,o,a),N.createElement("div",{className:u,style:c,ref:this.cellRef},this.renderReorderHandle(),d)}},{key:"renderReorderHandle",value:function(){var i={height:this.props.height};return N.createElement("div",{ref:this.setReorderHandle,className:Me({"fixedDataTableCellLayout/columnReorderContainer":!0,"fixedDataTableCellLayout/columnReorderContainer/active":!1}),style:i})}},{key:"renderDragProxy",value:function(i){var a=this,o={isDragProxy:!0,reorderStartEvent:i,onColumnReorderEnd:this.onColumnReorderEnd,contents:this.cellRef.current},s=N.createElement(Xpe,{value:this.context},N.createElement(Dg,ot({},this.props,o)));if(this.props.__react19RootCreator){var u=Jn.flushSync||function(c){return c()};u(function(){var c=a.props.__react19RootCreator(a.getDragContainer());a.dragContainer.root=c,c.render(s)}),this.setState({isReordering:!0});return}Jn.render(s,this.getDragContainer(),function(){return a.setState({isReordering:!0})})}}]),r}(N.PureComponent);Vs.contextType=Za;Vs.defaultProps={onColumnReorderStart:Kpe};Vs.propTypes={height:j.number,width:j.number,columnKey:j.oneOfType([j.string,j.number]),rowIndex:j.number,left:j.number,touchEnabled:j.bool,minWidth:j.number,maxWidth:j.number,onColumnReorderStart:j.func,onColumnReorderEnd:j.func.isRequired,__react19RootCreator:j.func};var rme=!!(typeof window!="undefined"&&window.document&&window.document.createElement),nme=function(){function e(t,r){for(var n=0;n<r.length;n++){var i=r[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();function ime(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ame(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function ome(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var FS=function(e){ome(t,e);function t(){return ime(this,t),ame(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return nme(t,[{key:"componentWillUnmount",value:function(){this.defaultNode&&document.body.removeChild(this.defaultNode),this.defaultNode=null}},{key:"render",value:function(){return rme?(!this.props.node&&!this.defaultNode&&(this.defaultNode=document.createElement("div"),document.body.appendChild(this.defaultNode)),Jn.createPortal(this.props.children,this.props.node||this.defaultNode)):null}}]),t}(N.Component);FS.propTypes={children:j.node.isRequired,node:j.any};var sme=FS,lme=function(){function e(t,r){for(var n=0;n<r.length;n++){var i=r[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}();function ume(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function cme(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t&&(typeof t=="object"||typeof t=="function")?t:e}function dme(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var $S=function(e){dme(t,e);function t(){return ume(this,t),cme(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return lme(t,[{key:"componentDidMount",value:function(){this.renderPortal()}},{key:"componentDidUpdate",value:function(n){this.renderPortal()}},{key:"componentWillUnmount",value:function(){Jn.unmountComponentAtNode(this.defaultNode||this.props.node),this.defaultNode&&document.body.removeChild(this.defaultNode),this.defaultNode=null,this.portal=null}},{key:"renderPortal",value:function(n){!this.props.node&&!this.defaultNode&&(this.defaultNode=document.createElement("div"),document.body.appendChild(this.defaultNode));var i=this.props.children;typeof this.props.children.type=="function"&&(i=N.cloneElement(this.props.children)),this.portal=Jn.unstable_renderSubtreeIntoContainer(this,i,this.props.node||this.defaultNode)}},{key:"render",value:function(){return null}}]),t}(N.Component),hme=$S;$S.propTypes={children:j.node.isRequired,node:j.any};var Rm=void 0;Jn.createPortal?Rm=sme:Rm=hme;var fme=Rm;function pme(e){var t=mme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function mme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var BS=function(e){Tt(r,e);var t=pme(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){if(!this.props.visible)return null;var i=this.getTableRef();if(!i)return null;var a={height:this.props.height,top:0,left:this.props.left};return N.createElement(fme,{node:i},N.createElement("div",{className:Lt(Me("fixedDataTableColumnResizerLineLayout/main"),Me("public/fixedDataTableColumnResizerLine/main")),style:a},N.createElement("div",{className:Me("fixedDataTableColumnResizerLineLayout/mouseArea"),style:{height:this.props.height}})))}},{key:"getTableRef",value:function(){var i=this.props.parentRef;return i?i.closest(Me(".fixedDataTableLayout/main")):null}}]),r}(N.PureComponent);ie(BS,"propTypes",{visible:j.bool.isRequired,height:j.number.isRequired,left:j.number.isRequired,parentRef:j.object});function k2(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 gme(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?k2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):k2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function vme(e){var t=yme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function yme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var zS=function(e){Tt(r,e);var t=vme(r);function r(n){var i;return rt(this,r),i=t.call(this,n),ie(he(i),"initialState",{isColumnResizing:!1,currentMouseXCoordinate:0,totalDisplacement:0}),ie(he(i),"state",gme({},i.initialState)),ie(he(i),"resizerKnobRef",null),ie(he(i),"mouseMoveTracker",null),ie(he(i),"setResizerKnobRef",function(a){i.resizerKnobRef=a}),ie(he(i),"initializeDOMMouseMoveTracker",function(a){i.mouseMoveTracker=new Cg(i.onMouseMove,i.onMouseUp,document.body,i.props.touchEnabled),i.mouseMoveTracker.captureMouseMoves(a)}),ie(he(i),"onTouchStart",function(a){i.props.touchEnabled&&i.onMouseDown(a)}),ie(he(i),"onMouseDown",function(a){i.initializeDOMMouseMoveTracker(a);var o=_m.getCoordinatesFromEvent(a).x-a.currentTarget.closest(Me(".fixedDataTableLayout/main")).getBoundingClientRect().left;i.setState({initialMouseXCoordinate:o,isColumnResizing:!0,totalDisplacement:0,currentMouseXCoordinate:o})}),ie(he(i),"onMouseUp",function(){var a=i.getMinMaxWidth(),o=a.minWidth,s=a.maxWidth,u=Cd(i.props.width+i.state.totalDisplacement*(i.props.isRTL?-1:1),o,s);i.mouseMoveTracker.releaseMouseMoves(),i.setState({isColumnResizing:!1,totalDisplacement:0},function(){i.props.onColumnResizeEnd(u,i.props.columnKey)})}),ie(he(i),"onMouseMove",function(a){var o=i.props,s=o.isRTL,u=o.width,c=i.state,d=c.initialMouseXCoordinate,h=c.totalDisplacement,p=h+a,m=d+p,g=i.getMinMaxWidth(),b=g.minWidth,_=g.maxWidth,w=u+p*(s?-1:1);(w<b||w>_)&&(m=i.state.currentMouseXCoordinate),i.setState({totalDisplacement:p,currentMouseXCoordinate:m})}),ie(he(i),"getMinMaxWidth",function(){return{minWidth:i.props.minWidth||0,maxWidth:i.props.maxWidth||Number.MAX_SAFE_INTEGER}}),ie(he(i),"suppressEventIfInTouchMode",function(a){i.props.touchEnabled&&(a.preventDefault(),a.stopPropagation())}),i}return nt(r,[{key:"componentDidMount",value:function(){this.setupHandlers()}},{key:"componentWillUnmount",value:function(){this.cleanupHandlers()}},{key:"render",value:function(){var i={height:this.props.height},a=N.createElement(BS,{height:this.props.resizerLineHeight,visible:!!this.state.isColumnResizing,left:this.state.currentMouseXCoordinate,parentRef:this.resizerKnobRef});return N.createElement("div",{className:Me("fixedDataTableCellLayout/columnResizerContainer"),ref:this.setResizerKnobRef,style:i},a)}},{key:"setupHandlers",value:function(){this.resizerKnobRef.addEventListener("mousedown",this.onMouseDown,{passive:!1}),this.resizerKnobRef.addEventListener("touchstart",this.onTouchStart,{passive:!1}),this.resizerKnobRef.addEventListener("touchmove",this.suppressEventIfInTouchMode,{passive:!1}),this.resizerKnobRef.addEventListener("touchend",this.suppressEventIfInTouchMode,{passive:!1})}},{key:"cleanupHandlers",value:function(){this.resizerKnobRef.removeEventListener("mousedown",this.onMouseDown,{passive:!1}),this.resizerKnobRef.removeEventListener("touchstart",this.onTouchStart,{passive:!1}),this.resizerKnobRef.removeEventListener("touchmove",this.suppressEventIfInTouchMode,{passive:!1}),this.resizerKnobRef.removeEventListener("touchend",this.suppressEventIfInTouchMode,{passive:!1})}}]),r}(N.PureComponent);zS.propTypes={columnKey:j.oneOfType([j.string,j.number]).isRequired,minWidth:j.number,maxWidth:j.number,width:j.number.isRequired,resizerLineHeight:j.number.isRequired,touchEnabled:j.bool,isRTL:j.bool,onColumnResizeEnd:j.func.isRequired,height:j.number.isRequired};var bme=["children","minWidth","maxWidth","onColumnResizeEnd","onColumnReorderEnd","rowIndex","left","touchEnabled","cellGroupType","onColumnReorderStart"];function _me(e){var t=wme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function wme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var _c=function(e){Tt(r,e);var t=_me(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){var i=this.props,a=i.children,o=Dn(i,bme),s;return N.isValidElement(a)?s=N.cloneElement(a,o):typeof a=="function"?s=a(o):s=N.createElement(Rg,o,a),N.createElement(N.Fragment,null,N.createElement(zS,{height:this.props.height,resizerLineHeight:this.context.tableHeight,onColumnResizeEnd:this.props.onColumnResizeEnd,width:this.props.width,minWidth:this.props.minWidth,maxWidth:this.props.maxWidth,columnKey:this.props.columnKey,touchEnabled:this.props.touchEnabled,isRTL:this.context.isRTL}),s)}}]),r}(N.PureComponent);_c.contextType=Za;_c.propTypes={columnKey:j.oneOfType([j.string,j.number]),minWidth:j.number,maxWidth:j.number,width:j.number,touchEnabled:j.bool,isRTL:j.bool,onColumnResizeEnd:j.func.isRequired,height:j.number};var Cme=["cell"],xme=["cell"],Tme=["height","width","columnIndex","isVisible","columnKey","isHeaderOrFooter","touchEnabled"];function L2(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 wu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?L2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):L2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Sme(e){var t=Mme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Mme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Ng=function(e){Tt(r,e);var t=Sme(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"shouldComponentUpdate",value:function(i){if(i.isScrolling&&this.props.rowIndex===i.rowIndex&&this.props.isVisible===i.isVisible)return!1;if(!i.pureRendering)return!0;var a=this.props,o=a.cell,s=Dn(a,Cme),u=i.cell,c=Dn(i,xme);return!Bs(s,c)||!o||!u||o.type!==u.type||!Bs(o.props,u.props)}},{key:"render",value:function(){var i=this.props,a=i.height,o=i.width,s=i.isVisible,u=i.isHeaderOrFooter,c=i.touchEnabled,d=Dn(i,Tme),h={height:a,width:o};this.props.isRTL?h.right=d.left:h.left=d.left;var p=Lt(Me({"fixedDataTableCellLayout/main":!0,"fixedDataTableCellLayout/lastChild":d.lastChild,"fixedDataTableCellLayout/alignRight":d.align==="right","fixedDataTableCellLayout/alignCenter":d.align==="center","public/fixedDataTableCell/alignRight":d.align==="right","public/fixedDataTableCell/highlighted":d.highlighted,"public/fixedDataTableCell/main":!0}),d.className),m={touchEnabled:c,isVisible:s,isHeader:this.props.isHeader,isGroupHeader:this.props.isGroupHeader,cellGroupType:this.props.cellGroupType,columnIndex:this.props.columnIndex,columnKey:this.props.columnKey,height:this.props.height,width:this.props.width,left:this.props.left};d.rowIndex>=0&&(m.rowIndex=d.rowIndex);var g;this.props.isHeader&&(this.props.onColumnResizeEnd||this.props.onColumnReorderEnd)?this.props.onColumnResizeEnd&&this.props.onColumnReorderEnd?(m=wu(wu({},m),{},{minWidth:this.props.minWidth,maxWidth:this.props.maxWidth}),g=N.createElement(Vs,ot({},m,{onColumnReorderEnd:this.props.onColumnReorderEnd}),N.createElement(_c,{onColumnResizeEnd:this.props.onColumnResizeEnd},d.cell))):this.props.onColumnReorderEnd?g=N.createElement(Vs,ot({},m,{onColumnReorderEnd:this.props.onColumnReorderEnd}),d.cell):(m=wu(wu({},m),{},{minWidth:this.props.minWidth,maxWidth:this.props.maxWidth}),g=N.createElement(_c,ot({},m,{onColumnResizeEnd:this.props.onColumnResizeEnd}),d.cell)):N.isValidElement(d.cell)?g=N.cloneElement(d.cell,m):typeof d.cell=="function"?g=d.cell(m):g=N.createElement(bc,m,d.cell);var b=u?"columnheader":"gridcell";return N.createElement("div",{className:p,style:h,role:b},g)}}]),r}(N.Component);ie(Ng,"propTypes_DISABLED_FOR_PERFORMANCE",{isScrolling:j.bool,align:j.oneOf(["left","center","right"]),className:j.string,highlighted:j.bool,width:j.number.isRequired,minWidth:j.number,maxWidth:j.number,height:j.number.isRequired,cell:j.oneOfType([j.string,j.element,j.func]),columnKey:j.oneOfType([j.string,j.number]),rowIndex:j.number.isRequired,left:j.number,pureRendering:j.bool,touchEnabled:j.bool,isHeaderOrFooter:j.bool,isRTL:j.bool,isVisible:j.bool.isRequired,onColumnResizeEnd:j.func,onColumnReorderEnd:j.func,isHeader:j.bool,cellGroupType:j.oneOf([Pe.FIXED,Pe.FIXED_RIGHT,Pe.SCROLLABLE])});ie(Ng,"defaultProps",{align:"left",highlighted:!1});var Pme=IS(Ng),Eme=["offsetLeft"];function HS(e){var t=Ame();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Ame(){if(typeof Reflect=="undefined"||!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(e){return!1}}var WS=function(e){Tt(r,e);var t=HS(r);function r(n){var i;return rt(this,r),i=t.call(this,n),ie(he(i),"_renderCell",function(a,o,s,u,c,d,h){var p=s.cellClassName,m=s.pureRendering||!1,g=s.isReorderable?i.props.onColumnReorderEndCallback:null,b=s.isResizable?i.props.onColumnResizeEndCallback:null;return N.createElement(Pme,{columnIndex:s.index,isScrolling:i.props.isScrolling,isHeaderOrFooter:i.props.isHeaderOrFooter,isHeader:i.props.isHeader,isGroupHeader:i.props.isGroupHeader,align:s.align,className:p,height:o,key:d,maxWidth:s.maxWidth,minWidth:s.minWidth,touchEnabled:i.props.touchEnabled,onColumnResizeEnd:b,onColumnReorderEnd:g,rowIndex:a,columnKey:s.columnKey,width:s.width,left:c,cell:u,pureRendering:m,isRTL:i.props.isRTL,cellGroupType:i.props.cellGroupType,isVisible:i.props.isVisible&&h})}),i._initialRender=!0,i}return nt(r,[{key:"componentDidMount",value:function(){this._initialRender=!1}},{key:"render",value:function(){for(var i=this.props,a=i.columns,o=new Array(a.length),s=Hu(a),u=0,c=0,d=a.length;c<d;c++){var h=a[c].props,p=a[c].template,m=h.allowCellsRecycling,g=u-i.left<=i.width&&u-i.left+h.width>=0;if(!m||g){var b=h.columnKey||"cell_"+c;o[c]=this._renderCell(i.rowIndex,i.rowHeight,h,p,u,b,g)}u+=h.width}var _={height:i.height,position:"absolute",width:s,zIndex:i.zIndex};return Ya(_,-1*i.left,0,this._initialRender,this.props.isRTL),N.createElement("div",{className:Me("fixedDataTableCellGroupLayout/cellGroup"),style:_},o)}}]),r}(N.Component);ie(WS,"propTypes_DISABLED_FOR_PERFORMANCE",{columns:j.array.isRequired,isScrolling:j.bool,left:j.number,height:j.number.isRequired,cellGroupWrapperHeight:j.number,rowHeight:j.number.isRequired,rowIndex:j.number.isRequired,width:j.number.isRequired,zIndex:j.number.isRequired,touchEnabled:j.bool,isHeaderOrFooter:j.bool,isRTL:j.bool,onColumnResizeEndCallback:j.func,onColumnReorderEndCallback:j.func,isHeader:j.bool,isVisible:j.bool.isRequired});var ys=function(e){Tt(r,e);var t=HS(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"shouldComponentUpdate",value:function(i){return!(i.isScrolling&&this.props.rowIndex===i.rowIndex&&this.props.left===i.left&&this.props.offsetLeft===i.offsetLeft&&this.props.isVisible===i.isVisible)}},{key:"render",value:function(){var i=this.props,a=i.offsetLeft,o=Dn(i,Eme),s={height:o.cellGroupWrapperHeight||o.height,width:o.width};return this.props.isRTL?s.right=a:s.left=a,N.createElement("div",{style:s,className:Me("fixedDataTableCellGroupLayout/cellGroupWrapper")},N.createElement(WS,o))}}]),r}(N.Component);ie(ys,"propTypes_DISABLED_FOR_PERFORMANCE",{isScrolling:j.bool,height:j.number.isRequired,offsetLeft:j.number,left:j.number,zIndex:j.number.isRequired});ie(ys,"defaultProps",{left:0,offsetLeft:0});var Rme=["offsetTop","zIndex"];function jS(e){var t=Dme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Dme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Nme=1,VS=function(e){Tt(r,e);var t=jS(r);function r(){var n;rt(this,r);for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return n=t.call.apply(t,[this].concat(a)),ie(he(n),"mouseLeaveIndex",null),ie(he(n),"_getRowExpanded",function(s){if(n.props.rowExpanded){var u={rowIndex:n.props.index,height:s,width:n.props.width},c;return N.isValidElement(n.props.rowExpanded)?c=N.cloneElement(n.props.rowExpanded,u):typeof n.props.rowExpanded=="function"&&(c=n.props.rowExpanded(u)),c}}),ie(he(n),"_renderColumnsLeftShadow",function(s){var u=Me({"fixedDataTableRowLayout/fixedColumnsDivider":s>0,"fixedDataTableRowLayout/columnsShadow":n.props.scrollLeft>0,"public/fixedDataTableRow/fixedColumnsDivider":s>0,"public/fixedDataTableRow/columnsShadow":n.props.scrollLeft>0}),c=n.props.cellGroupWrapperHeight?n.props.cellGroupWrapperHeight-Nme:n.props.height,d={left:s,height:c};return n.props.isRTL&&(d.right=s,d.left="auto"),N.createElement("div",{className:u,style:d})}),ie(he(n),"_renderFixedRightColumnsShadow",function(s){var u=Me("fixedDataTableRowLayout/columnsShadow","fixedDataTableRowLayout/columnsRightShadow","fixedDataTableRowLayout/fixedColumnsDivider","public/fixedDataTableRow/columnsShadow","public/fixedDataTableRow/columnsRightShadow","public/fixedDataTableRow/fixedColumnsDivider"),c={height:n.props.height,left:s};return n.props.isRTL&&(c.right=s,c.left="auto"),N.createElement("div",{className:u,style:c})}),ie(he(n),"_renderColumnsRightShadow",function(s){if(Math.ceil(n.props.scrollLeft+n.props.width)<Math.floor(s)){var u=Me("fixedDataTableRowLayout/columnsShadow","fixedDataTableRowLayout/columnsRightShadow","public/fixedDataTableRow/columnsShadow","public/fixedDataTableRow/columnsRightShadow"),c={height:n.props.height};return N.createElement("div",{className:u,style:c})}}),ie(he(n),"_onClick",function(s){n.props.onClick(s,n.props.index)}),ie(he(n),"_onContextMenu",function(s){n.props.onContextMenu(s,n.props.index)}),ie(he(n),"_onDoubleClick",function(s){n.props.onDoubleClick(s,n.props.index)}),ie(he(n),"_onMouseUp",function(s){n.props.onMouseUp(s,n.props.index)}),ie(he(n),"_onMouseDown",function(s){n.props.onMouseDown(s,n.props.index)}),ie(he(n),"_onMouseEnter",function(s){n.mouseLeaveIndex=n.props.index,n.props.onMouseEnter&&n.props.onMouseEnter(s,n.props.index)}),ie(he(n),"_onMouseLeave",function(s){n.mouseLeaveIndex===null&&(n.mouseLeaveIndex=n.props.index),n.props.onMouseLeave(s,n.mouseLeaveIndex),n.mouseLeaveIndex=null}),ie(he(n),"_onTouchStart",function(s){n.props.onTouchStart(s,n.props.index)}),ie(he(n),"_onTouchEnd",function(s){n.props.onTouchEnd(s,n.props.index)}),ie(he(n),"_onTouchMove",function(s){n.props.onTouchMove(s,n.props.index)}),n}return nt(r,[{key:"shouldComponentUpdate",value:function(i){return i.isScrolling?i.visible?this.props.visible!==i.visible?!0:!(this.props.index===i.index&&this.props.scrollLeft===i.scrollLeft):!1:!0}},{key:"render",value:function(){var i=this.props.subRowHeight||0,a={width:this.props.width,height:this.props.height+i},o=Me({"fixedDataTableRowLayout/main":!0,"public/fixedDataTableRow/main":!0,"public/fixedDataTableRow/highlighted":this.props.index%2===1,"public/fixedDataTableRow/odd":this.props.index%2===1,"public/fixedDataTableRow/even":this.props.index%2===0}),s=Hu(this.props.fixedColumns),u=N.createElement(ys,{key:"fixed_cells",isScrolling:this.props.isScrolling,height:this.props.height,cellGroupWrapperHeight:this.props.cellGroupWrapperHeight,left:0,width:s,zIndex:2,columns:this.props.fixedColumns,touchEnabled:this.props.touchEnabled,onColumnResizeEndCallback:this.props.onColumnResizeEndCallback,onColumnReorderEndCallback:this.props.onColumnReorderEndCallback,rowHeight:this.props.height,rowIndex:this.props.index,isHeaderOrFooter:this.props.isHeaderOrFooter,isHeader:this.props.isHeader,isGroupHeader:this.props.isGroupHeader,isRTL:this.props.isRTL,cellGroupType:Pe.FIXED,isVisible:this.props.visible}),c=this._renderColumnsLeftShadow(s),d=Hu(this.props.fixedRightColumns),h=this.props.showScrollbarY?this.props.scrollbarYWidth:0,p=N.createElement(ys,{key:"fixed_right_cells",isScrolling:this.props.isScrolling,height:this.props.height,cellGroupWrapperHeight:this.props.cellGroupWrapperHeight,offsetLeft:this.props.width-d-h,width:d,zIndex:2,columns:this.props.fixedRightColumns,touchEnabled:this.props.touchEnabled,onColumnResizeEndCallback:this.props.onColumnResizeEndCallback,onColumnReorderEndCallback:this.props.onColumnReorderEndCallback,rowHeight:this.props.height,rowIndex:this.props.index,isHeaderOrFooter:this.props.isHeaderOrFooter,isHeader:this.props.isHeader,isGroupHeader:this.props.isGroupHeader,isRTL:this.props.isRTL,cellGroupType:Pe.FIXED_RIGHT,isVisible:this.props.visible}),m=d?this._renderFixedRightColumnsShadow(this.props.width-d-h-5):null,g=N.createElement(ys,{key:"scrollable_cells",isScrolling:this.props.isScrolling,height:this.props.height,cellGroupWrapperHeight:this.props.cellGroupWrapperHeight,align:"right",left:this.props.scrollLeft,offsetLeft:s,width:this.props.width-s-d-h,zIndex:0,columns:this.props.scrollableColumns,touchEnabled:this.props.touchEnabled,onColumnResizeEndCallback:this.props.onColumnResizeEndCallback,onColumnReorderEndCallback:this.props.onColumnReorderEndCallback,rowHeight:this.props.height,rowIndex:this.props.index,isHeaderOrFooter:this.props.isHeaderOrFooter,isHeader:this.props.isHeader,isGroupHeader:this.props.isGroupHeader,isRTL:this.props.isRTL,cellGroupType:Pe.SCROLLABLE,isVisible:this.props.visible}),b=Hu(this.props.scrollableColumns),_=this._renderColumnsRightShadow(s+b),w=this._getRowExpanded(i),C={height:i,top:this.props.height,width:this.props.width},S=null;if(this.props.showScrollbarY){var T={width:h,height:this.props.height,left:this.props.isRTL?2:this.props.width-h-2};S=N.createElement("div",{style:T,className:Me("public/fixedDataTable/scrollbarSpacer")})}return N.createElement("div",ot({className:Lt(o,this.props.className),role:"row","aria-rowindex":this.props.ariaRowIndex},this.props.attributes,{onClick:this.props.onClick?this._onClick:null,onContextMenu:this.props.onContextMenu?this._onContextMenu:null,onDoubleClick:this.props.onDoubleClick?this._onDoubleClick:null,onMouseDown:this.props.onMouseDown?this._onMouseDown:null,onMouseUp:this.props.onMouseUp?this._onMouseUp:null,onMouseEnter:this.props.onMouseEnter||this.props.onMouseLeave?this._onMouseEnter:null,onMouseLeave:this.props.onMouseLeave?this._onMouseLeave:null,onTouchStart:this.props.onTouchStart?this._onTouchStart:null,onTouchEnd:this.props.onTouchEnd?this._onTouchEnd:null,onTouchMove:this.props.onTouchMove?this._onTouchMove:null,style:a}),N.createElement("div",{className:Me("fixedDataTableRowLayout/body")},u,g,c,p,m,S),w&&N.createElement("div",{className:Me("fixedDataTableRowLayout/rowExpanded"),style:C},w),_)}}]),r}(N.Component);ie(VS,"propTypes",{isScrolling:j.bool,fixedColumns:j.array.isRequired,fixedRightColumns:j.array.isRequired,height:j.number.isRequired,cellGroupWrapperHeight:j.number,subRowHeight:j.number,rowExpanded:j.oneOfType([j.element,j.func]),index:j.number.isRequired,scrollableColumns:j.array.isRequired,scrollLeft:j.number.isRequired,width:j.number.isRequired,onClick:j.func,onContextMenu:j.func,onDoubleClick:j.func,onColumnReorderEndCallback:j.func,touchEnabled:j.bool,isHeaderOrFooter:j.bool,ariaRowIndex:j.number,isRTL:j.bool,attributes:j.object,onColumnResizeEndCallback:j.func,isHeader:j.bool,isGroupHeader:j.bool,scrollToX:j.func});var bs=function(e){Tt(r,e);var t=jS(r);function r(n){var i;return rt(this,r),i=t.call(this,n),i._initialRender=!0,i}return nt(r,[{key:"componentDidMount",value:function(){this._initialRender=!1}},{key:"shouldComponentUpdate",value:function(i){return!i.isScrolling||this.props.visible!==i.visible?!0:i.visible?!(i.isScrolling&&this.props.index===i.index&&this.props.offsetTop===i.offsetTop&&this.props.scrollLeft===i.scrollLeft):!1}},{key:"render",value:function(){var i=this.props,a=i.offsetTop,o=i.zIndex,s=Dn(i,Rme),u={width:this.props.width,height:this.props.height,zIndex:o||0,visibility:s.visible?"visible":"hidden"};return Ya(u,0,a,this._initialRender,this.props.isRTL),N.createElement("div",{style:u,className:Me("fixedDataTableRowLayout/rowWrapper")},N.createElement(VS,s))}}]),r}(N.Component);ie(bs,"propTypes",{isScrolling:j.bool,height:j.number.isRequired,zIndex:j.number,offsetTop:j.number.isRequired,visible:j.bool.isRequired,width:j.number.isRequired});function kme(e){var t=Lme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Lme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var US=function(e){Tt(r,e);var t=kme(r);function r(n){var i;return rt(this,r),i=t.call(this,n),i._staticRowArray=[],i._initialRender=!0,i}return nt(r,[{key:"componentDidMount",value:function(){this._initialRender=!1}},{key:"shouldComponentUpdate",value:function(){return!0}},{key:"componentWillUnmount",value:function(){this._staticRowArray.length=0}},{key:"render",value:function(){var i=this.props,a=i.offsetTop,o=i.rowOffsets,s=i.scrollTop,u=i.isScrolling,c=i.rowsToRender;c=c||[],u?this._staticRowArray.length=Math.max(this._staticRowArray.length,c.length):this._staticRowArray.length=c.length;for(var d=1e6,h=a-s%d,p=0;p<this._staticRowArray.length;p++){var m,g=Tpe(c[p],(m=this._staticRowArray[p])===null||m===void 0?void 0:m.props.index);if(vs(g)||!Ei(g,0,this.props.rowSettings.rowsCount)){this._staticRowArray[p]=null;continue}var b=o[g]-Math.floor(s/d)*d;this._staticRowArray[p]=this.renderRow({rowIndex:g,key:p,rowOffsetTop:b})}var _={position:"relative"};Ya(_,0,h,!1);var w=this._staticRowArray.slice().sort(this.rowSortComparator);return N.createElement("div",{style:_},w)}},{key:"renderRow",value:function(i){var a=i.rowIndex,o=i.key,s=i.rowOffsetTop,u=this.props,c=u.rowClassNameGetter||Ot,d={};d.height=this.props.rowSettings.rowHeightGetter(a),d.subRowHeight=this.props.rowSettings.subRowHeightGetter(a),d.offsetTop=s,d.key=u.rowKeyGetter?u.rowKeyGetter(a):o,d.attributes=u.rowSettings.rowAttributesGetter&&u.rowSettings.rowAttributesGetter(a);var h=a===u.rowSettings.rowsCount-1&&u.showLastRowBorder;d.className=Lt(c(a),Me("public/fixedDataTable/bodyRow"),Me({"fixedDataTableLayout/hasBottomBorder":h,"public/fixedDataTable/hasBottomBorder":h}));var p=Ei(a,this.props.firstViewportRowIndex,this.props.endViewportRowIndex);return N.createElement(bs,ot({key:o,index:a,ariaRowIndex:a+u.ariaRowIndexOffset,isScrolling:u.isScrolling,width:u.width,rowExpanded:u.rowExpanded,scrollLeft:Math.round(u.scrollLeft),fixedColumns:u.fixedColumns,fixedRightColumns:u.fixedRightColumns,scrollableColumns:u.scrollableColumns,onClick:u.onRowClick,onContextMenu:u.onRowContextMenu,onDoubleClick:u.onRowDoubleClick,onMouseDown:u.onRowMouseDown,onMouseUp:u.onRowMouseUp,onMouseEnter:u.onRowMouseEnter,onMouseLeave:u.onRowMouseLeave,onTouchStart:u.onRowTouchStart,onTouchEnd:u.onRowTouchEnd,onTouchMove:u.onRowTouchMove,showScrollbarY:u.showScrollbarY,scrollbarYWidth:u.scrollbarYWidth,isRTL:u.isRTL,visible:p},d))}},{key:"rowSortComparator",value:function(i,a){var o,s;return((o=i==null?void 0:i.props.ariaRowIndex)!==null&&o!==void 0?o:-1)-((s=a==null?void 0:a.props.ariaRowIndex)!==null&&s!==void 0?s:-1)}}]),r}(N.Component);ie(US,"propTypes",{ariaRowIndexOffset:j.number,isScrolling:j.bool,firstViewportRowIndex:j.number.isRequired,endViewportRowIndex:j.number.isRequired,fixedColumns:j.array.isRequired,fixedRightColumns:j.array.isRequired,height:j.number.isRequired,offsetTop:j.number.isRequired,onRowClick:j.func,onRowContextMenu:j.func,onRowDoubleClick:j.func,onRowMouseDown:j.func,onRowMouseUp:j.func,onRowMouseEnter:j.func,onRowMouseLeave:j.func,onRowTouchStart:j.func,onRowTouchEnd:j.func,onRowTouchMove:j.func,rowClassNameGetter:j.func,rowExpanded:j.oneOfType([j.element,j.func]),rowOffsets:j.object.isRequired,rowKeyGetter:j.func,rowSettings:j.shape({rowAttributesGetter:j.func,rowHeightGetter:j.func,rowsCount:j.number.isRequired,subRowHeightGetter:j.func}),rowsToRender:j.array.isRequired,scrollLeft:j.number.isRequired,scrollTop:j.number.isRequired,scrollableColumns:j.array.isRequired,showLastRowBorder:j.bool,showScrollbarY:j.bool,width:j.number.isRequired,isRTL:j.bool});var O2=1.6,Ome=1.6,Ime=325,Qo=100,Fme=function(){function e(t,r,n,i,a){rt(this,e),this._dragAnimationId=null,this._trackerId=null,this._deltaX=0,this._deltaY=0,this._lastTouchX=0,this._lastTouchY=0,this._velocityX=0,this._velocityY=0,this._accumulatedDeltaX=0,this._accumulatedDeltaY=0,this._lastFrameTimestamp=Date.now(),this._autoScrollTimestamp=Date.now(),typeof r!="function"&&(r=r?Ot.thatReturnsTrue:Ot.thatReturnsFalse),typeof n!="function"&&(n=n?Ot.thatReturnsTrue:Ot.thatReturnsFalse),this._handleScrollX=r,this._handleScrollY=n,this._preventDefault=i,this._stopPropagation=a,this._onTouchScrollCallback=t,this._didTouchMove=this._didTouchMove.bind(this),this._track=this._track.bind(this),this._autoScroll=this._autoScroll.bind(this),this._startAutoScroll=this._startAutoScroll.bind(this),this.onTouchStart=this.onTouchStart.bind(this),this.onTouchEnd=this.onTouchEnd.bind(this),this.onTouchMove=this.onTouchMove.bind(this),this.onTouchCancel=this.onTouchCancel.bind(this)}return nt(e,[{key:"onTouchStart",value:function(r){this._lastTouchX=r.touches[0].pageX,this._lastTouchY=r.touches[0].pageY,this._velocityX=0,this._velocityY=0,this._accumulatedDeltaX=0,this._accumulatedDeltaY=0,this._lastFrameTimestamp=Date.now(),clearInterval(this._trackerId),this._trackerId=setInterval(this._track,Qo),this._stopPropagation&&r.stopPropagation()}},{key:"onTouchEnd",value:function(r){clearInterval(this._trackerId),this._trackerId=null,ti(this._startAutoScroll),this._stopPropagation&&r.stopPropagation()}},{key:"onTouchCancel",value:function(r){clearInterval(this._trackerId),this._trackerId=null,this._stopPropagation&&r.stopPropagation()}},{key:"onTouchMove",value:function(r){this._preventDefault&&r.preventDefault();var n=r.touches[0].pageX,i=r.touches[0].pageY;this._deltaX=O2*(this._lastTouchX-n),this._deltaY=O2*(this._lastTouchY-i);var a=this._handleScrollX(this._deltaX,this._deltaY),o=this._handleScrollY(this._deltaY,this._deltaX);if(!(!a&&!o)){a?this._lastTouchX=n:this._deltaX=0,o?this._lastTouchY=i:this._deltaY=0,r.defaultPrevented||r.preventDefault();var s=!1;(Math.abs(this._deltaX)>2||Math.abs(this._deltaY)>2)&&(this._stopPropagation&&r.stopPropagation(),s=!0),s===!0&&this._dragAnimationId===null&&(this._dragAnimationId=ti(this._didTouchMove))}}},{key:"_didTouchMove",value:function(){this._dragAnimationId=null,this._onTouchScrollCallback(this._deltaX,this._deltaY),this._accumulatedDeltaX+=this._deltaX,this._accumulatedDeltaY+=this._deltaY,this._deltaX=0,this._deltaY=0}},{key:"_track",value:function(){var r=Date.now(),n=r-this._lastFrameTimestamp,i=this._velocityX,a=this._velocityY,o=.8;n<Qo&&(o*=n/Qo),i===0&&a===0&&(o=1),this._velocityX=o*(Qo*this._accumulatedDeltaX/(1+n)),o<1&&(this._velocityX+=(1-o)*i),this._velocityY=o*(Qo*this._accumulatedDeltaY/(1+n)),o<1&&(this._velocityY+=(1-o)*a),this._accumulatedDeltaX=0,this._accumulatedDeltaY=0,this._lastFrameTimestamp=r}},{key:"_startAutoScroll",value:function(){this._autoScrollTimestamp=Date.now(),(this._deltaX>0||this.deltaY>0)&&this._didTouchMove(),this._track(),this._autoScroll()}},{key:"_autoScroll",value:function(){var r=Date.now()-this._autoScrollTimestamp,n=Ome*Math.exp(-r/Ime),i=n*this._velocityX,a=n*this._velocityY;(Math.abs(i)<=5||!this._handleScrollX(i,a))&&(i=0),(Math.abs(a)<=5||!this._handleScrollY(a,i))&&(a=0),(i!==0||a!==0)&&(this._onTouchScrollCallback(i,a),ti(this._autoScroll))}}]),e}();function $me(e){var t=Bme();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function Bme(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Cu=25,kg=function(e){Tt(r,e);var t=$me(r);function r(n){var i;return rt(this,r),i=t.call(this,n),ie(he(i),"_shouldHandleTouchX",function(a){return i.props.touchScrollEnabled&&i._shouldHandleWheelX(a)}),ie(he(i),"_shouldHandleTouchY",function(a){return i.props.touchScrollEnabled&&i._shouldHandleWheelY(a)}),ie(he(i),"_shouldHandleWheelX",function(a){var o=i.props,s=o.maxScrollX,u=o.scrollFlags,c=o.scrollX,d=u.overflowX;return d==="hidden"||(a=Math.round(a),a===0)?!1:a<0&&c>0||a>=0&&c<s}),ie(he(i),"_shouldHandleWheelY",function(a){var o=i.props,s=o.maxScrollY,u=o.scrollFlags,c=o.scrollY,d=u.overflowY;return d==="hidden"||a===0||(a=Math.round(a),a===0)?!1:a<0&&c>0||a>=0&&c<s}),ie(he(i),"_reportContentHeight",function(){var a=Ra(i.props),o=a.contentHeight,s=i.props.onContentHeightChange;o!==i._contentHeight&&s&&s(o),i._contentHeight=o}),ie(he(i),"_renderRows",function(a,o,s,u,c,d){var h=Fi(i.props),p=h.scrollEnabledY,m=i.props;return N.createElement(US,{ariaRowIndexOffset:d,isScrolling:m.scrolling,fixedColumns:o,fixedRightColumns:s,firstViewportRowIndex:m.firstRowIndex,endViewportRowIndex:m.endRowIndex,height:c,offsetTop:a,onRowClick:m.onRowClick,onRowContextMenu:m.onRowContextMenu,onRowDoubleClick:m.onRowDoubleClick,onRowMouseUp:m.onRowMouseUp,onRowMouseDown:m.onRowMouseDown,onRowMouseEnter:m.onRowMouseEnter,onRowMouseLeave:m.onRowMouseLeave,onRowTouchStart:m.touchScrollEnabled?m.onRowTouchStart:null,onRowTouchEnd:m.touchScrollEnabled?m.onRowTouchEnd:null,onRowTouchMove:m.touchScrollEnabled?m.onRowTouchMove:null,rowClassNameGetter:m.rowClassNameGetter,rowExpanded:m.rowExpanded,rowKeyGetter:m.rowKeyGetter,rowSettings:m.rowSettings,scrollLeft:m.scrollX,scrollTop:m.scrollY,scrollableColumns:u,showLastRowBorder:!0,width:m.tableSize.width,rowsToRender:m.rows,rowOffsets:m.rowOffsets,showScrollbarY:p,scrollbarYWidth:m.scrollbarYWidth,isRTL:m.isRTL})}),ie(he(i),"_onRef",function(a){i._divRef=a,i._wheelHandler&&(i.props.stopReactWheelPropagation?i._wheelHandler.setRoot(a):i._wheelHandler.setRoot(null))}),ie(he(i),"_onScroll",function(a,o){var s=i.props,u=s.maxScrollX,c=s.maxScrollY,d=s.onHorizontalScroll,h=s.onVerticalScroll,p=s.scrollActions,m=s.scrollFlags,g=s.scrollX,b=s.scrollY,_=m.overflowX,w=m.overflowY,C=g,S=b;if(Math.abs(o)>Math.abs(a)&&w!=="hidden")S+=o,S=S<0?0:S,S=S>c?c:S,(!h||h(S))&&p.scrollToY(S);else if(a&&_!=="hidden"){C+=a,C=C<0?0:C,C=C>u?u:C;var T=Math.round(C);(!d||d(T))&&p.scrollToX(T)}}),ie(he(i),"_scrollTo",function(a,o){i.props.scrollActions.scrollToX(a),i.props.scrollActions.scrollToY(o)}),ie(he(i),"_didScroll",function(a){var o=i.props,s=o.onScrollStart,u=o.scrollX,c=o.scrollY,d=o.onHorizontalScroll,h=o.onVerticalScroll,p=o.tableSize.ownerHeight,m=o.scrolling,g=a.endRowIndex,b=a.firstRowIndex,_=a.scrollX,w=a.scrollY,C=a.tableSize.ownerHeight,S=a.scrolling,T=p!==C&&!(S2(p)&&S2(C)),M=u!==_,P=c!==w;!T&&!M&&!P||(!S&&m&&s&&s(_,w,b,g),M&&d&&d(u),P&&h&&h(c),i._didScrollStop())}),ie(he(i),"_didScrollStopSync",function(){var a=i.props,o=a.endRowIndex,s=a.firstRowIndex,u=a.onScrollEnd,c=a.scrollActions,d=a.scrollX,h=a.scrollY,p=a.scrolling;p&&(c.stopScroll(),u&&u(d,h,s,o))}),i._didScrollStop=Yfe(i._didScrollStopSync,200,he(i)),i._onKeyDown=i._onKeyDown.bind(he(i)),i._setupHandlers(),i}return nt(r,[{key:"componentWillUnmount",value:function(){this._cleanupHandlers(),this._didScrollStop.reset(),this._didScrollStopSync()}},{key:"_setupHandlers",value:function(){this._wheelHandler||(this._wheelHandler=new mS(this._onScroll,this._shouldHandleWheelX,this._shouldHandleWheelY,this.props.isRTL,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation)),this._touchHandler||(this._touchHandler=new Fme(this._onScroll,this._shouldHandleTouchX,this._shouldHandleTouchY,this.props.stopScrollDefaultHandling,this.props.stopScrollPropagation)),this._divRef&&this._divRef.addEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this.props.touchScrollEnabled&&this._divRef&&this._divRef.addEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1})}},{key:"_cleanupHandlers",value:function(){this._wheelHandler&&(this._divRef&&this._divRef.removeEventListener("wheel",this._wheelHandler.onWheel,{passive:!1}),this._wheelHandler=null),this._touchHandler&&(this._divRef&&this._divRef.removeEventListener("touchmove",this._touchHandler.onTouchMove,{passive:!1}),this._touchHandler=null)}},{key:"_onKeyDown",value:function(i){var a=Ra(this.props),o=a.scrollbarYHeight;if(this.props.keyboardPageEnabled)switch(i.key){case"PageDown":this._onScroll(0,o),i.preventDefault();break;case"PageUp":this._onScroll(0,o*-1),i.preventDefault();break}if(this.props.keyboardScrollEnabled)switch(i.key){case"ArrowDown":this._onScroll(0,Cu),i.preventDefault();break;case"ArrowUp":this._onScroll(0,Cu*-1),i.preventDefault();break;case"ArrowRight":this._onScroll(Cu,0),i.preventDefault();break;case"ArrowLeft":this._onScroll(Cu*-1,0),i.preventDefault();break}}},{key:"shouldComponentUpdate",value:function(i){return!Bs(this.props,i)}},{key:"componentDidMount",value:function(){this._setupHandlers(),this._reportContentHeight(),this._reportScrollBarsUpdates()}},{key:"componentDidUpdate",value:function(i){this._didScroll(i),this._reportContentHeight(),this._reportScrollBarsUpdates()}},{key:"_reportScrollBarsUpdates",value:function(){var i=Ra(this.props),a=i.bodyOffsetTop,o=i.scrollbarXOffsetTop,s=i.visibleRowsHeight,u=this.props,c=u.tableSize.width,d=u.scrollContentHeight,h=u.scrollY,p=u.scrollX,m={viewportHeight:s,contentHeight:d,scrollbarYOffsetTop:a,scrollY:h,viewportWidth:c,contentWidth:c+this.props.maxScrollX,scrollbarXOffsetTop:o,scrollX:p,scrollTo:this._scrollTo,scrollToX:this.props.scrollActions.scrollToX,scrollToY:this.props.scrollActions.scrollToY};Bs(this.previousScrollState,m)||(this.props.onScrollBarsUpdate(m),this.previousScrollState=m)}},{key:"render",value:function(){var i=Zfe(this.props),a=i.ariaGroupHeaderIndex,o=i.ariaHeaderIndex,s=i.ariaFooterIndex,u=i.ariaRowCount,c=i.ariaRowIndexOffset,d=Cpe(this.props),h=d.fixedColumnGroups,p=d.fixedColumns,m=d.fixedRightColumnGroups,g=d.fixedRightColumns,b=d.scrollableColumnGroups,_=d.scrollableColumns,w=Ra(this.props),C=w.bodyHeight,S=w.bodyOffsetTop,T=w.componentHeight,M=w.footOffsetTop,P=w.scrollbarXOffsetTop,R=w.visibleRowsHeight,k=this.props,I=k.className,$=k.elementHeights,G=k.gridAttributesGetter,Y=k.maxScrollY,B=k.onColumnReorderEndCallback,X=k.onColumnResizeEndCallback,U=k.scrollContentHeight,Q=k.scrollX,W=k.scrollY,q=k.scrolling,ee=k.tableSize,Z=k.touchScrollEnabled,J=k.scrollbarYWidth,ne=ee.ownerHeight,oe=ee.width,ae=$.cellGroupWrapperHeight,se=$.footerHeight,ue=$.groupHeaderHeight,me=$.headerHeight,pe=Fi(this.props),Ce=pe.scrollEnabledX,ke=pe.scrollEnabledY,we=G&&G(),le;ue>0&&(le=N.createElement(bs,{key:"group_header",ariaRowIndex:a,isHeaderOrFooter:!0,isScrolling:q,className:Lt(Me("fixedDataTableLayout/header"),Me("public/fixedDataTable/header")),width:oe,height:ue,cellGroupWrapperHeight:ae,index:0,zIndex:1,offsetTop:0,scrollLeft:Q,fixedColumns:h,fixedRightColumns:m,scrollableColumns:b,visible:!0,touchEnabled:Z,onColumnResizeEndCallback:X,onColumnReorderEndCallback:B,showScrollbarY:ke,scrollbarYWidth:J,isRTL:this.props.isRTL,isHeader:!0,isGroupHeader:!0}));var He;ke&&(He=this.props.scrollbarY);var Te;Ce&&(Te=this.props.scrollbarX);var Ae=null;se&&(Ae=N.createElement(bs,{key:"footer",ariaRowIndex:s,isHeaderOrFooter:!0,isScrolling:q,className:Lt(Me("fixedDataTableLayout/footer"),Me("public/fixedDataTable/footer")),width:oe,height:se,index:-1,zIndex:1,offsetTop:M,visible:!0,fixedColumns:p.footer,fixedRightColumns:g.footer,scrollableColumns:_.footer,scrollLeft:Q,showScrollbarY:ke,scrollbarYWidth:J,isRTL:this.props.isRTL}));var $e=this._renderRows(S,p.cell,g.cell,_.cell,C,c),Ge=N.createElement(bs,{key:"header",ariaRowIndex:o,isHeaderOrFooter:!0,isScrolling:q,className:Lt(Me("fixedDataTableLayout/header"),Me("public/fixedDataTable/header")),width:oe,height:me,cellGroupWrapperHeight:ae,index:-1,zIndex:1,offsetTop:ue,scrollLeft:Q,visible:!0,fixedColumns:p.header,fixedRightColumns:g.header,scrollableColumns:_.header,touchEnabled:Z,onColumnResizeEndCallback:X,onColumnReorderEndCallback:B,showScrollbarY:ke,scrollbarYWidth:J,isRTL:this.props.isRTL,isHeader:!0}),qe;W&&(qe=N.createElement("div",{className:Lt(Me("fixedDataTableLayout/topShadow"),Me("public/fixedDataTable/topShadow")),style:{top:S}}));var jt=ne&&ne<T&&U>R,pt;(jt||W<Y)&&(pt=N.createElement("div",{className:Lt(Me("fixedDataTableLayout/bottomShadow"),Me("public/fixedDataTable/bottomShadow")),style:{top:M}}));var St=null;(this.props.keyboardPageEnabled||this.props.keyboardScrollEnabled)&&(St=0);var Ft=I;return this.props.isRTL&&(Ft=Lt(Ft,"fixedDataTable_isRTL")),N.createElement("div",ot({className:Lt(Ft,Me("fixedDataTableLayout/main"),Me("public/fixedDataTable/main")),role:"grid","aria-rowcount":u},we,{tabIndex:St,onKeyDown:this._onKeyDown,onTouchStart:Z?this._touchHandler.onTouchStart:null,onTouchEnd:Z?this._touchHandler.onTouchEnd:null,onTouchCancel:Z?this._touchHandler.onTouchCancel:null,ref:this._onRef,style:{height:T,width:oe}}),N.createElement("div",{className:Me("fixedDataTableLayout/rowsContainer"),style:{height:P,width:oe}},le,Ge,$e,Ae,qe,pt),He,Te)}}]),r}(N.Component);ie(kg,"propTypes",{width:j.number.isRequired,height:j.number,className:j.string,maxHeight:j.number,ownerHeight:j.number,overflowX:j.oneOf(["hidden","auto"]),overflowY:j.oneOf(["hidden","auto"]),touchScrollEnabled:j.bool,keyboardScrollEnabled:j.bool,keyboardPageEnabled:j.bool,scrollbarX:j.node,scrollbarXHeight:j.number,scrollbarY:j.node,scrollbarYWidth:j.number,onScrollBarsUpdate:j.func,defaultScrollbars:j.bool,showScrollbarX:j.bool,showScrollbarY:j.bool,onHorizontalScroll:j.func,onVerticalScroll:j.func,rowsCount:j.number.isRequired,rowHeight:j.number.isRequired,rowHeightGetter:j.func,subRowHeight:j.number,subRowHeightGetter:j.func,rowExpanded:j.oneOfType([j.element,j.func]),rowClassNameGetter:j.func,rowKeyGetter:j.func,groupHeaderHeight:j.number,headerHeight:j.number.isRequired,cellGroupWrapperHeight:j.number,footerHeight:j.number,scrollLeft:j.number,scrollToColumn:j.number,scrollTop:j.number,isVerticalScrollExact:j.bool,scrollToRow:j.number,onScrollStart:j.func,onScrollEnd:j.func,stopReactWheelPropagation:j.bool,stopScrollDefaultHandling:j.bool,stopScrollPropagation:j.bool,onContentHeightChange:j.func,onRowClick:j.func,onRowContextMenu:j.func,onRowDoubleClick:j.func,onRowMouseDown:j.func,onRowMouseUp:j.func,onRowMouseEnter:j.func,onRowMouseLeave:j.func,onRowTouchStart:j.func,onRowTouchEnd:j.func,onRowTouchMove:j.func,onColumnResizeEndCallback:j.func,onColumnReorderEndCallback:j.func,isRTL:j.bool,bufferRowCount:j.number,elementHeights:j.shape({cellGroupWrapperHeight:j.number,footerHeight:j.number,groupHeaderHeight:j.number,headerHeight:j.number}),gridAttributesGetter:j.func,rowAttributesGetter:j.func});ie(kg,"defaultProps",{elementHeights:{cellGroupWrapperHeight:void 0,footerHeight:0,groupHeaderHeight:0,headerHeight:0},keyboardScrollEnabled:!1,keyboardPageEnabled:!1,touchScrollEnabled:!1,stopScrollPropagation:!1});var zme={get:function(){return Mfe({reducer:kfe,devTools:process.env.NODE_ENV!=="production",middleware:function(r){return r({immutableCheck:!1,serializableCheck:!1})}})}},Hme=cg,Wme=gl,jme=vd,Vme=$r,Ume=ml,Gme=Fs.exports,qme=_d,Yme=jT,Xme="[object Map]",Zme="[object Set]",Kme=Object.prototype,Qme=Kme.hasOwnProperty;function Jme(e){if(e==null)return!0;if(Ume(e)&&(Vme(e)||typeof e=="string"||typeof e.splice=="function"||Gme(e)||Yme(e)||jme(e)))return!e.length;var t=Wme(e);if(t==Xme||t==Zme)return!e.size;if(qme(e))return!Hme(e).length;for(var r in e)if(Qme.call(e,r))return!1;return!0}var I2=Jme;function GS(e){var t=e0e();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function e0e(){if(typeof Reflect=="undefined"||!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(e){return!1}}var t0e=function(e){Tt(r,e);var t=GS(r);function r(){var n;rt(this,r);for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return n=t.call.apply(t,[this].concat(a)),ie(he(n),"state",{}),ie(he(n),"_onScrollBarsUpdate",function(s){n.setState(s)}),ie(he(n),"_onVerticalScroll",function(s){n.state.scrollToY!==void 0&&n.state.scrollToY(s)}),ie(he(n),"_onHorizontalScroll",function(s){n.state.scrollToX!==void 0&&n.state.scrollToX(s)}),n}return nt(r,[{key:"render",value:function(){var i=!I2(this.state)&&N.createElement(wr,{size:this.state.viewportHeight,contentSize:this.state.contentHeight,onScroll:this._onVerticalScroll,verticalTop:this.state.scrollbarYOffsetTop,position:this.state.scrollY,touchEnabled:this.props.touchScrollEnabled,isRTL:this.props.isRTL}),a=!I2(this.state)&&N.createElement(qS,{contentSize:this.state.contentWidth,offset:this.state.scrollbarXOffsetTop,onScroll:this._onHorizontalScroll,position:this.state.scrollX,size:this.state.viewportWidth,touchEnabled:this.props.touchScrollEnabled,isRTL:this.props.isRTL});return N.cloneElement(this.props.children,{onScrollBarsUpdate:this._onScrollBarsUpdate,scrollbarX:a,scrollbarY:i})}}]),r}(N.Component),qS=function(e){Tt(r,e);var t=GS(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){var i=this.props,a=i.offset,o=i.size,s={height:wr.SIZE,width:o},u={height:wr.SIZE,overflow:"hidden",width:o,top:a};return N.createElement("div",{className:Lt(Me("public/fixedDataTable/horizontalScrollbar")),style:s},N.createElement("div",{style:u},N.createElement(wr,ot({},this.props,{isOpaque:!0,orientation:"horizontal",offset:void 0}))))}}]),r}(N.PureComponent);ie(qS,"propTypes",{contentSize:j.number.isRequired,offset:j.number.isRequired,onScroll:j.func.isRequired,position:j.number.isRequired,size:j.number.isRequired,isRTL:j.bool});var r0e=function(){return Fn([function(t){return Ra(t).componentHeight},function(t){return t.elementHeights.groupHeaderHeight},function(t){return t.scrollX},function(t){return t.maxScrollX},function(t){return vl(t).availableScrollWidth},function(t){return t.isRTL}],function(t,r,n,i,a,o){return{tableHeight:t,groupHeaderHeight:r,scrollX:n,maxScrollX:i,availableScrollWidth:a,isRTL:o}})},n0e=Gi,i0e=$r,a0e=ui,o0e="[object String]";function s0e(e){return typeof e=="string"||!i0e(e)&&a0e(e)&&n0e(e)==o0e}var l0e=s0e;function u0e(e){return function(t){return t==null?void 0:t[e]}}var c0e=u0e,d0e=c0e,h0e=d0e("length"),f0e=h0e,p0e="\\ud800-\\udfff",m0e="\\u0300-\\u036f",g0e="\\ufe20-\\ufe2f",v0e="\\u20d0-\\u20ff",y0e=m0e+g0e+v0e,b0e="\\ufe0e\\ufe0f",_0e="\\u200d",w0e=RegExp("["+_0e+p0e+y0e+b0e+"]");function C0e(e){return w0e.test(e)}var x0e=C0e,YS="\\ud800-\\udfff",T0e="\\u0300-\\u036f",S0e="\\ufe20-\\ufe2f",M0e="\\u20d0-\\u20ff",P0e=T0e+S0e+M0e,E0e="\\ufe0e\\ufe0f",A0e="["+YS+"]",Dm="["+P0e+"]",Nm="\\ud83c[\\udffb-\\udfff]",R0e="(?:"+Dm+"|"+Nm+")",XS="[^"+YS+"]",ZS="(?:\\ud83c[\\udde6-\\uddff]){2}",KS="[\\ud800-\\udbff][\\udc00-\\udfff]",D0e="\\u200d",QS=R0e+"?",JS="["+E0e+"]?",N0e="(?:"+D0e+"(?:"+[XS,ZS,KS].join("|")+")"+JS+QS+")*",k0e=JS+QS+N0e,L0e="(?:"+[XS+Dm+"?",Dm,ZS,KS,A0e].join("|")+")",F2=RegExp(Nm+"(?="+Nm+")|"+L0e+k0e,"g");function O0e(e){for(var t=F2.lastIndex=0;F2.test(e);)++t;return t}var I0e=O0e,F0e=f0e,$0e=x0e,B0e=I0e;function z0e(e){return $0e(e)?B0e(e):F0e(e)}var H0e=z0e,W0e=cg,j0e=gl,V0e=ml,U0e=l0e,G0e=H0e,q0e="[object Map]",Y0e="[object Set]";function X0e(e){if(e==null)return 0;if(V0e(e))return U0e(e)?G0e(e):e.length;var t=j0e(e);return t==q0e||t==Y0e?e.size:W0e(e).length}var xf=X0e,Z0e=function(t){return{offset:t.offset,width:t.width,index:t.index,columnKey:t.columnKey}},xu=function(t){return{offset:t.offset,width:t.width,index:t.index,columnKey:t.columnKey}},K0e=function(){return Fn([function(t){return vl(t)},function(t,r){return r}],function(t,r){var n=t.fixedColumns,i=t.fixedRightColumns,a=t.scrollableColumns,o=t.fixedColumnGroups,s=t.fixedRightColumnGroups,u=t.scrollableColumnGroups,c=function(W){var q=n.length+a.length+i.length;if(W<0||W>=q||!Number.isInteger(W))throw"columnIndex must be an integer between 0 and ".concat(q-1," inclusive")},d=function(W){var q=o.length+u.length+s.length;if(W<0||W>=q||!Number.isInteger(W))throw"columnGroupIndex must be an integer between 0 and ".concat(q-1," inclusive")},h=function(W){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(!(q&&vs(W))&&W!==Pe.FIXED&&W!==Pe.FIXED_RIGHT&&W!==Pe.SCROLLABLE)throw"Invalid CellGroupType"},p=function(W){return W<n.length?Pe.FIXED:W<n.length+a.length?Pe.SCROLLABLE:Pe.FIXED_RIGHT},m=function(W){return W<o.length?Pe.FIXED:W<o.length+u.length?Pe.SCROLLABLE:Pe.FIXED_RIGHT},g=function(W,q){if(q===Pe.FIXED)return W;if(q===Pe.SCROLLABLE)return W-n.length;if(q===Pe.FIXED_RIGHT)return W-n.length-a.length},b=function(W,q){if(q===Pe.FIXED)return W;if(q===Pe.SCROLLABLE)return W-o.length;if(q===Pe.FIXED_RIGHT)return W-o.length-u.length},_=function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Pe.SCROLLABLE;h(W);var q=k(W);return q.reduce(function(ee,Z){return ee+Z.width},0)},w=function(W,q){var ee=k(q),Z=g(W,q);return ee[Z]},C=function(W){c(W);var q=p(W),ee=w(W,q);return Z0e(ee)},S=function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;if(h(W,!0),vs(W))return n.length+a.length+i.length;var q=k(W);return q.length},T=function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;if(h(W,!0),vs(W))return o.length+u.length+s.length;var q=I(W);return q.length},M=function(W,q){var ee=I(q),Z=b(W,q);return xu(ee[Z])},P=function(W){d(W);var q=m(W);return M(W,q)},R=function(W){c(W);var q=p(W),ee=w(W,q).groupIdx,Z=$(ee);return xu(Z)},k=function(W){if(W===Pe.FIXED)return n;if(W===Pe.FIXED_RIGHT)return i;if(W===Pe.SCROLLABLE)return a;throw"Invalid cell group type"},I=function(W){if(W===Pe.FIXED)return o;if(W===Pe.FIXED_RIGHT)return s;if(W===Pe.SCROLLABLE)return u;throw"Invalid cell group type"},$=function(W){var q=xf(o),ee=xf(u),Z=xf(s);if(Ei(W,0,q))return o[W];if(Ei(W,q,q+ee))return u[W-q];if(Ei(W,q+ee,q+ee+Z))return s[W-q-ee];throw"Invalid absolute column group index"},G=function(W,q){if(W.length===0)return{element:null,distanceFromOffset:null};for(var ee=0,Z=0;Z!==W.length&&!(ee>q);)ee+=W[Z].width,Z++;return Z=Td(Z-1,0,W.length-1),{element:W[Z],distanceFromOffset:W[Z].width-(ee-q)}},Y=function(W){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Pe.SCROLLABLE;h(q);var ee=k(q),Z=G(ee,W),J=Z.element,ne=Z.distanceFromOffset;return J&&(J=xu(J)),{column:J,distanceFromOffset:ne}},B=function(W){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Pe.SCROLLABLE;h(q);var ee=I(q),Z=G(ee,W),J=Z.element,ne=Z.distanceFromOffset;return J&&(J=xu(J)),{columnGroup:J,distanceFromOffset:ne}},X=r.scrollToX,U=r.updateRowHeights;return{getColumn:C,getColumnGroup:P,getColumnGroupByChild:R,getColumnAtOffset:Y,getColumnGroupAtOffset:B,getCellGroupWidth:_,getColumnCount:S,getColumnGroupCount:T,scrollToX:X,updateRowHeights:U}})};function $2(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 Tf(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?$2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):$2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var Q0e=function(){var t=[],r=null,n=function(s){return t=t.concat(s),function(){var u=t.indexOf(s);t.splice(u,1)}},i=r0e(),a=K0e();return{getValue:Fn([function(o){return i(o)},function(o,s){return a(o,s)}],function(o,s){return r=Tf(Tf(Tf({},o),s),{},{subscribe:n}),r}),notify:function(){t.forEach(function(s){return s(r)})}}};function B2(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 Tu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?B2(Object(r),!0).forEach(function(n){ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):B2(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function J0e(e){var t=ege();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function ege(){if(typeof Reflect=="undefined"||!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(e){return!1}}var eM=function(e){Tt(r,e);var t=J0e(r);function r(n){var i;return rt(this,r),i=t.call(this,n),i._initialize(n),i.fixedDataTableApi=Q0e(),i.previousApiValue=null,i}return nt(r,[{key:"componentDidMount",value:function(){this._initialize(this.props)}},{key:"componentWillUnmount",value:function(){this._cleanup()}},{key:"componentDidUpdate",value:function(){this.notifyApiValueChanges()}},{key:"_initialize",value:function(i){var a=this;if(!this.reduxStore){this.reduxStore=zme.get(),this.reduxStore.dispatch(Lfe(i)),this.scrollActions=zfe(this.reduxStore,function(){return a.props}),this.unsubscribe=this.reduxStore.subscribe(this.onStoreUpdate.bind(this));var o={boundState:r.getBoundState(this.reduxStore),reduxStore:this.reduxStore,props:i};this.state?this.setState(o):this.state=o}}},{key:"_cleanup",value:function(){this.reduxStore&&(this.unsubscribe(),this.unsubscribe=null,this.reduxStore=null)}},{key:"getApi",value:function(){var i=this;return this.fixedDataTableApi.getValue(Tu(Tu({},this.props),this.reduxStore.getState()),Tu(Tu({},this.scrollActions),{},{updateRowHeights:function(o){return HT({updateRowHeights:Bfe},i.reduxStore.dispatch).updateRowHeights(o)}}))}},{key:"notifyApiValueChanges",value:function(){var i=this.getApi();this.previousApiValue!==i&&(this.fixedDataTableApi.notify(),this.previousApiValue=i)}},{key:"render",value:function(){var i=this.getApi(),a=N.createElement(kg,ot({},this.props,this.state.boundState,{scrollActions:this.scrollActions}));return this.props.defaultScrollbars?N.createElement(Za.Provider,{value:i},N.createElement(t0e,this.props,a)):N.createElement(Za.Provider,{value:i},a)}},{key:"onStoreUpdate",value:function(){var i=r.getBoundState(this.reduxStore);this.state.boundState.propsRevision===i.propsRevision&&this.setState({boundState:i})}}],[{key:"getDerivedStateFromProps",value:function(i,a){return sn(i.height!==void 0||i.maxHeight!==void 0,"You must set either a height or a maxHeight"),i===a.props?null:(a.reduxStore.dispatch(Ofe({newProps:i,oldProps:a.props})),{boundState:r.getBoundState(a.reduxStore),props:i})}},{key:"getBoundState",value:function(i){var a=i.getState(),o=is(a,["columnGroupElements","columnElements","elementHeights","elementTemplates","firstRowIndex","endRowIndex","maxScrollX","maxScrollY","propsRevision","rows","rowOffsets","rowSettings","scrollContentHeight","scrollFlags","scrollX","scrollY","scrolling","scrollJumpedX","scrollJumpedY","tableSize"]);return o}}]),r}(N.Component);ie(eM,"defaultProps",{defaultScrollbars:!0,scrollbarXHeight:wr.SIZE,scrollbarYWidth:wr.SIZE});var tge=IS(eM);function rge(e){var t=nge();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function nge(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Fd=function(e){Tt(r,e);var t=rge(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){if(process.env.NODE_ENV!=="production")throw new Error("Component <FixedDataTableColumn /> should never render");return null}}]),r}(N.Component);ie(Fd,"__TableColumn__",!0);ie(Fd,"propTypes",{align:j.oneOf(["left","center","right"]),fixed:j.bool,fixedRight:j.bool,header:j.oneOfType([j.node,j.func]),cell:j.oneOfType([j.node,j.func]),footer:j.oneOfType([j.node,j.func]),columnKey:j.oneOfType([j.string,j.number]),width:j.number.isRequired,minWidth:j.number,maxWidth:j.number,flexGrow:j.number,isResizable:j.bool,isReorderable:j.bool,allowCellsRecycling:j.bool,pureRendering:j.bool,cellClassName:j.string});ie(Fd,"defaultProps",{allowCellsRecycling:!1,fixed:!1,fixedRight:!1});function ige(e){var t=age();return function(){var n=Be(e),i;if(t){var a=Be(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return Wt(this,i)}}function age(){if(typeof Reflect=="undefined"||!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(e){return!1}}var Lg=function(e){Tt(r,e);var t=ige(r);function r(){return rt(this,r),t.apply(this,arguments)}return nt(r,[{key:"render",value:function(){if(process.env.NODE_ENV!=="production")throw new Error("Component <FixedDataTableColumnGroup /> should never render");return null}}]),r}(N.Component);ie(Lg,"__TableColumnGroup__",!0);ie(Lg,"propTypes",{align:j.oneOf(["left","center","right"]),fixed:j.bool,header:j.oneOfType([j.node,j.func])});ie(Lg,"defaultProps",{fixed:!1});const oge=()=>typeof window=="undefined"||typeof document=="undefined"||!document.body||typeof window.innerWidth!="number"||typeof document.body.clientWidth!="number"?0:Math.max(0,window.innerWidth-document.body.clientWidth),sge="#f4f4f8",lge="#edeef1",uge="#e3e5ea",cge="#f9f9fb",dge="#ffcb05",hge="#1faff3",fge="#e5e5e5",pge="#5b6372",mge="#3a4356",gge="#3c3c42",vge="#a3a3a3",yge="#d0d3db",bge="_headerCell_2qf2w_16",_ge="_noSort_2qf2w_29",wge="_standard_2qf2w_29",Cge="_caret_2qf2w_33",xge="_headerLabel_2qf2w_38",Tge="_icon_2qf2w_43",Sge="_numberIcon_2qf2w_50",Mge="_dateIcon_2qf2w_54",Pge="_textIcon_2qf2w_58",Ege="_booleanIcon_2qf2w_62",Age="_sortIcon_2qf2w_66",Rge="_sortAscending_2qf2w_74",Dge="_sortDescending_2qf2w_78",zn={athensGray:sge,athensGrayDark:lge,athensGrayDark2:uge,athensGrayLight:cge,defaultBrandColor:dge,dodgerBlue:hge,mercury:fge,shuttleGrayDark:pge,oxfordBlue:mge,darkModeDefaultBackground:gge,indicatorGrey:vge,secondaryButtonHover:yge,headerCell:bge,noSort:_ge,standard:wge,caret:Cge,headerLabel:xge,icon:Tge,numberIcon:Sge,dateIcon:Mge,textIcon:Pge,booleanIcon:Ege,sortIcon:Age,sortAscending:Rge,sortDescending:Dge},Nge="_icon_t30x8_1",kge="_numberIcon_t30x8_11",Lge="_dateIcon_t30x8_15",Oge="_textIcon_t30x8_19",Ige="_booleanIcon_t30x8_23",Jo={icon:Nge,numberIcon:kge,dateIcon:Lge,textIcon:Oge,booleanIcon:Ige},Fge=({columnType:e})=>O.jsx("div",{className:Is(Jo.icon,{[Jo.numberIcon]:V.isNumber(e),[Jo.dateIcon]:V.isDatetime(e),[Jo.textIcon]:V.isText(e),[Jo.booleanIcon]:V.isBoolean(e)})}),$ge=({column:e,onClick:t,isSelected:r,children:n,showFieldTypeIcon:i,sortIcon:a="standard"})=>O.jsxs("div",{className:zn.headerCell,onClick:()=>{t(e)},children:[i&&O.jsx(Fge,{columnType:e.type}),O.jsx("div",{className:zn.headerLabel,children:n}),O.jsx("div",{className:Is(zn.sortIcon,{[zn.caret]:a==="caret",[zn.standard]:a==="standard",[zn.noSort]:!r||e.direction===0,[zn.sortAscending]:r&&e.direction===1,[zn.sortDescending]:r&&e.direction===-1})})]}),Bge=26,zge=26,z2=8,tM=36,rM=29,nM=24,iM=350,aM=120,Hge=38,Wge=55,jge=(e,t,r,{fontFamily:n,minWidth:i=aM,maxWidth:a=iM}={})=>{const s=document.createElement("canvas").getContext("2d");if(!s)return[];const u=Math.min(i,a),c=Math.max(i,a);s.font=`13px ${n||"Open Sans"}`;const d=e.columns.map(b=>s.measureText(b.name).width+tM+(t?rM:0)),h=s.measureText("0").width,p=e.columns.map(b=>({type:V.simpleColumnType(b.type),index:b.index})),{rows:m}=e,g=p.map(b=>{const _=m.reduce((w,C)=>{var P;const S=C[b.index].displayValue,T=(P=r[b.index])!=null&&P.isHtml?Vge(S):S,M=b.type==="number"?C[b.index].displayValue.length*h:s.measureText(T).width;return Math.max(w,M)},0);return nM+_});return d.map((b,_)=>{var C;const w=(C=r[_])==null?void 0:C.width;return w||Math.ceil(Math.max(u,Math.min(c,Math.max(b,g[_]))))})};function Vge(e){const t=document.createElement("div");return t.innerHTML=e,oM(t)}function oM(e){let t,r,n,i;for(r="",t=0;t<e.childNodes.length;t++)i=e.childNodes[t],n=null,i.nodeType===1?n=oM(i):i.nodeType===3&&(n=i.nodeValue),n&&(r+=n);return r}const H2=e=>e%2===1,W2=({colIndex:e=0,rowIndex:t=0,themeSettings:r,customStyles:n,isHeaderCell:i})=>{var c,d,h,p,m,g,b,_,w,C,S,T,M,P,R,k,I,$;let a=r.chart.textColor;const o=r.typography.fontFamily;let s=r.chart.backgroundColor;const u=E.getSlightlyDifferentColor(s);return i?(d=(c=n==null?void 0:n.header)==null?void 0:c.color)!=null&&d.enabled&&(s=((p=(h=n==null?void 0:n.header)==null?void 0:h.color)==null?void 0:p.backgroundColor)||u,a=((g=(m=n==null?void 0:n.header)==null?void 0:m.color)==null?void 0:g.textColor)||a):((_=(b=n==null?void 0:n.columns)==null?void 0:b.alternatingColor)!=null&&_.enabled&&H2(e)&&(s=((C=(w=n==null?void 0:n.columns)==null?void 0:w.alternatingColor)==null?void 0:C.backgroundColor)||u,a=((T=(S=n==null?void 0:n.columns)==null?void 0:S.alternatingColor)==null?void 0:T.textColor)||a),(P=(M=n==null?void 0:n.rows)==null?void 0:M.alternatingColor)!=null&&P.enabled&&H2(t)&&(s=((k=(R=n==null?void 0:n.rows)==null?void 0:R.alternatingColor)==null?void 0:k.backgroundColor)||u,a=(($=(I=n==null?void 0:n.rows)==null?void 0:I.alternatingColor)==null?void 0:$.textColor)||a)),{color:a,backgroundColor:s,fontFamily:o}},Uge="#f4f4f8",Gge="#edeef1",qge="#e3e5ea",Yge="#f9f9fb",Xge="#ffcb05",Zge="#1faff3",Kge="#e5e5e5",Qge="#5b6372",Jge="#3a4356",eve="#3c3c42",tve="#a3a3a3",rve="#d0d3db",nve="_tableWrapper_1vpuy_16",ive="_table_1vpuy_16",ave="_tableHeader_1vpuy_87",ove="_tableCell_1vpuy_97",sve="_tableCellContent_1vpuy_108",lve="_headerColor_1vpuy_114",uve="_rowColor_1vpuy_118",os={athensGray:Uge,athensGrayDark:Gge,athensGrayDark2:qge,athensGrayLight:Yge,defaultBrandColor:Xge,dodgerBlue:Zge,mercury:Kge,shuttleGrayDark:Qge,oxfordBlue:Jge,darkModeDefaultBackground:eve,indicatorGrey:tve,secondaryButtonHover:rve,tableWrapper:nve,table:ive,tableHeader:ave,tableCell:ove,tableCellContent:sve,headerColor:lve,rowColor:uve},cve=e=>V.isNumber(e)?"right":"left",dve=new RegExp(`<\\/?[\\w\\s="/.':;#-\\/\\?]+>`),j2=({displayValue:e,width:t,padding:r,ellipsizedLength:n,isHtml:i})=>{var h,p,m,g,b,_,w,C;const{app:a}=y.useSisenseContext(),o=(g=(m=(p=(h=a==null?void 0:a.settings)==null?void 0:h.chartConfig)==null?void 0:p.tabular)==null?void 0:m.htmlContent)==null?void 0:g.enabled,s=(C=(w=(_=(b=a==null?void 0:a.settings)==null?void 0:b.chartConfig)==null?void 0:_.tabular)==null?void 0:w.htmlContent)==null?void 0:C.sanitizeContents,{isHtmlValue:u,value:c}=N.useMemo(()=>{let S=i;o&&typeof S=="undefined"&&(S=dve.test(e));const T=S&&s?E.purify.sanitize(e):e;return{isHtmlValue:S,value:T}},[o,i,e,s]),d=c.length>n;return O.jsx("div",{className:os.tableCellContent,style:{maxWidth:`${t-r}px`},children:u?O.jsx("div",{dangerouslySetInnerHTML:{__html:c}}):d?O.jsx(Ii,{title:c,children:O.jsx("div",{children:c})}):O.jsx("div",{children:c})})},hve=({dataTable:e,dataOptions:t,height:r,width:n,customStyles:i,themeSettings:a,onSortUpdate:o})=>{var B,X,U,Q,W,q,ee,Z,J;const s=i&&i.showFieldTypeIcon!==void 0?i.showFieldTypeIcon:!0,u=((B=i==null?void 0:i.columns)==null?void 0:B.resizable)!==!1,c=(X=i==null?void 0:i.columns)==null?void 0:X.widths,d=(Q=(U=i==null?void 0:i.columns)==null?void 0:U.minWidth)!=null?Q:aM,h=(q=(W=i==null?void 0:i.columns)==null?void 0:W.maxWidth)!=null?q:iM,p=Math.min(d,h),m=Math.max(d,h),g=tM+(s?rM:0),b=(i==null?void 0:i.paddingVertical)||z2,_=(i==null?void 0:i.paddingHorizontal)||z2,w=((ee=i==null?void 0:i.columns)==null?void 0:ee.width)==="auto"?(n-_*2-oge())/t.columns.length:void 0,C=N.useMemo(()=>t.columns.map(ne=>({isHtml:"isHtml"in ne&&!!ne.isHtml,width:"width"in ne?ne.width:w})),[t.columns,w]),[S,T]=N.useState(((Z=document.fonts)==null?void 0:Z.status)==="loaded"),[M,P]=N.useState({}),R=(J=a.typography)==null?void 0:J.fontFamily,k=N.useMemo(()=>jge(e,s,C,{fontFamily:R,minWidth:p,maxWidth:m}),[m,p,e,s,C,R,S]),I=N.useMemo(()=>e.columns.map(ne=>`${ne.index}:${ne.name}:${ne.type}`).join("|"),[e.columns]);N.useEffect(()=>{P({})},[I]);const $=N.useMemo(()=>e.columns.map((ne,oe)=>{const ae=c==null?void 0:c[oe];if(ae!==void 0)return ae;const se=M[oe];return se!==void 0?se:k[oe]}),[c,e.columns,k,M]),G=N.useCallback((ne,oe)=>{var ue,me;const ae=Number(oe),se=e.columns.map((pe,Ce)=>{var ke;return Ce===ae?ne:(ke=$[Ce])!=null?ke:k[Ce]});c===void 0&&P(pe=>z(D({},pe),{[ae]:ne})),(me=(ue=i==null?void 0:i.columns)==null?void 0:ue.onColumnsResize)==null||me.call(ue,se)},[k,c,i==null?void 0:i.columns,e.columns,$]);N.useEffect(()=>{var ne;(ne=document.fonts)==null||ne.ready.then(()=>{T(!0)}).catch(oe=>{console.warn("Failed to observe font loading",oe)})},[]);const Y=N.useMemo(()=>e.columns.map((ne,oe)=>{const ae=$[oe],se=t.columns[oe],ue=W2({isHeaderCell:!0,themeSettings:a,customStyles:i});return ae?O.jsx(Fd,{columnKey:`${oe}`,isResizable:u,minWidth:p,maxWidth:m,allowCellsRecycling:!0,width:ae,header:O.jsx(bc,{className:Is(os.tableHeader),style:ue,children:O.jsx($ge,{column:ne,onClick:o,isSelected:!!Math.abs(ne.direction),showFieldTypeIcon:s,sortIcon:(i==null?void 0:i.sortIcon)||"standard",children:O.jsx(j2,{displayValue:E.getDataOptionTitle(se),width:ae,padding:g,ellipsizedLength:Hge})})}),cell:Ce=>{var ke=Ce,{rowIndex:me}=ke,pe=Ye(ke,["rowIndex"]);return O.jsx(bc,z(D({className:Is(os.tableCell),style:W2({colIndex:oe,rowIndex:me,themeSettings:a,customStyles:i})},pe),{children:O.jsx(j2,{displayValue:e.rows[me][oe].displayValue,width:ae,padding:nM,ellipsizedLength:Wge,isHtml:"isHtml"in se?se.isHtml:void 0})}))},align:cve(ne.type)},`col${oe}`):null}),[e,$,a,i,o,s,t,g,u,p,m]);return N.useMemo(()=>O.jsx("div",{"data-testid":"data-table-wrapper",className:os.tableWrapper,style:{padding:`${b}px ${_}px`,"--csdk-table-column-resizer-color":a.general.brandColor},children:O.jsx(tge,{className:os.table,rowHeight:(i==null?void 0:i.rowHeight)||zge,rowsCount:e.rows.length,width:n-_*2,height:r-b*2,headerHeight:(i==null?void 0:i.headerHeight)||Bge,isColumnResizing:!1,onColumnResizeEndCallback:u?G:void 0,children:Y})}),[Y,i,e,r,_,u,G,a.general.brandColor,b,n])},fve=(e,t,r=!0)=>{if(!e.columns.some(s=>V.isNumber(s.type)))return e;const n=e.columns,a=e.rows.map(s=>s.map((u,c)=>{const d=n[c].type;if(V.isNumber(d)){const h=t.columns[c].numberFormatConfig!==void 0;if(!r&&!h)return u;const p=E.getCompleteNumberFormatConfig(t.columns[c].numberFormatConfig),m=E.createCompareValue(u.displayValue,d);return{displayValue:E.applyFormatPlainText(p,m.value),compareValue:m}}else return u}));return{columns:n,rows:a}},pve="_component_1rw9b_1",mve={component:pve},gve=({dataTable:e,dataOptions:t,designOptions:r={},onSortUpdate:n,themeSettings:i,width:a=400,height:o=500})=>{var m,g,b,_;const{app:s}=y.useSisenseContext(),u=(_=(b=(g=(m=s==null?void 0:s.settings)==null?void 0:m.chartConfig)==null?void 0:g.defaultNumberFormatting)==null?void 0:b.enabled)!=null?_:!0,c=N.useRef(null),d=N.useRef(e),h=N.useMemo(()=>fve(e,t,u),[e,t,u]);N.useLayoutEffect(()=>{d.current=e},[e]);const p=N.useMemo(()=>D({sortIcon:"caret",showFieldTypeIcon:!1},r),[r]);return O.jsx("div",{className:mve.component,ref:c,children:O.jsx(hve,{dataTable:h,dataOptions:t,onSortUpdate:n,height:o,width:a,customStyles:p,themeSettings:i})})},vve=e=>({"& .MuiPaginationItem-circular.Mui-selected":{color:e.chart.textColor},"& .MuiPaginationItem-circular":{color:e.chart.secondaryTextColor,fontFamily:e.typography.fontFamily}}),yve=e=>({paddingVertical:e.paddingVertical,paddingHorizontal:e.paddingHorizontal,header:e.header,rows:e.rows,columns:e.columns}),sM=25,lM=10,uM=({dataSet:e,dataOptions:t,styleOptions:r={},filters:n,onDataReady:i})=>{const{rowsPerPage:a=sM,width:o,height:s}=r,{t:u}=O.useTranslation(),{themeSettings:c}=y.useThemeContext(),[d,h]=N.useState(0),{filters:p,relations:m}=N.useMemo(()=>V.getFilterListAndRelationsJaql(n),[n]),[g,b]=N.useState(1),_=N.useRef(null),{dataOptions:w,mapping:C}=N.useMemo(()=>VY(ul(t)),[t]),S=N.useMemo(()=>yve(r),[r]),[T,M]=N.useState(w),[P,R]=N.useState(C),[k,I]=N.useState(e),[$,G,Y]=vJ({dataSet:k,dataOptions:T,dataColumnNamesMapping:P,filters:p,filterRelations:m,count:a*lM,offset:d}),B=N.useMemo(()=>{if($&&i){const ee=i($);if(!cT(ee))throw new V.TranslatableError("errors.incorrectOnDataReadyHandler");return ee}return $},[$]),X=yJ({data:B,innerDataOptions:G,dataColumnNamesMapping:Y,needToAggregate:!H.isDataSource(k)});N.useEffect(()=>{M(w),R(C),I(e),b(1),h(0)},[e,w,C]);const U=N.useCallback(ee=>{if(!$)return;Math.floor($.rows.length/a)===ee&&h($.rows.length),b(ee)},[$,a]),Q=N.useCallback(ee=>{b(1),h(0),T&&M(AY(T,ee))},[T]),W=N.useMemo(()=>{if(!X||H.isDataSource(k))return X;const ee=X.columns.find(Z=>Z.direction!==0);return ee?E.orderBy(X,[ee]):X},[X,k]),q=N.useMemo(()=>W?{columns:W.columns,rows:W.rows.slice((g-1)*a,g*a)}:void 0,[W,g,a]);return G?O.jsx(Pc,{defaultSize:Ec("table"),size:{width:o,height:s},children:ee=>{if(!X||!q)return O.jsx(y.LoadingOverlay,{});if(E.isDataTableEmpty(X))return O.jsx(Ac,{iconType:"table"});const Z=Math.ceil(X.rows.length/a);return O.jsxs("div",{className:"csdk-table-root",style:{display:"flex",flexDirection:"column",alignItems:"center",backgroundColor:c.chart.backgroundColor},"data-testid":"table-root",role:"region","aria-label":u("chart.table.label"),children:[O.jsx(gve,{dataTable:q,dataOptions:G,designOptions:S,themeSettings:c,width:ee.width,height:ee.height-32,onSortUpdate:Q}),O.jsx($_,{ref:_,page:g,count:Z,onChange:(ne,oe)=>U(oe),sx:vve(c)})]})}}):null},bve=N.createContext(null),Sf={didCatch:!1,error:null};class km extends N.Component{constructor(t){super(t),this.resetErrorBoundary=this.resetErrorBoundary.bind(this),this.state=Sf}static getDerivedStateFromError(t){return{didCatch:!0,error:t}}resetErrorBoundary(){const{error:t}=this.state;if(t!==null){for(var r,n,i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];(r=(n=this.props).onReset)===null||r===void 0||r.call(n,{args:a,reason:"imperative-api"}),this.setState(Sf)}}componentDidCatch(t,r){var n,i;(n=(i=this.props).onError)===null||n===void 0||n.call(i,t,r)}componentDidUpdate(t,r){const{didCatch:n}=this.state,{resetKeys:i}=this.props;if(n&&r.error!==null&&_ve(t.resetKeys,i)){var a,o;(a=(o=this.props).onReset)===null||a===void 0||a.call(o,{next:i,prev:t.resetKeys,reason:"keys"}),this.setState(Sf)}}render(){const{children:t,fallbackRender:r,FallbackComponent:n,fallback:i}=this.props,{didCatch:a,error:o}=this.state;let s=t;if(a){const u={error:o,resetErrorBoundary:this.resetErrorBoundary};if(typeof r=="function")s=r(u);else if(n)s=N.createElement(n,u);else if(i===null||N.isValidElement(i))s=i;else throw o}return N.createElement(bve.Provider,{value:{didCatch:a,error:o,resetErrorBoundary:this.resetErrorBoundary}},s)}}function _ve(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e.length!==t.length||e.some((r,n)=>!Object.is(r,t[n]))}const cM=N.createContext(void 0),wve=({children:e})=>{const[t,r]=N.useState([]),[n,i]=N.useState([]),a=()=>r([]),o=()=>i([]);return O.jsx(cM.Provider,{value:{errors:t,warnings:n,clearError:a,clearWarning:o,setErrors:r,setWarnings:i},children:e})},dM=()=>{const e=N.useContext(cM);return e||{errors:[],warnings:[],setErrors:()=>{console.warn("setErrors called, but context is not available.")},setWarnings:()=>{console.warn("setWarnings called, but context is not available.")},clearError:()=>{console.warn("clearError called, but context is not available.")},clearWarning:()=>{console.warn("clearWarning called, but context is not available.")}}},Cve="BE#081586",xve="BE#733473",Tve=e=>{const[t,r]=N.useState(0),{setErrors:n,errors:i}=dM(),a=y.useHasChanged(e,["dataOptions","filters"]);if(N.useEffect(()=>{a&&i.length>0&&(r(t+1),n([]))},[e.dataOptions,e.filters]),!H.isDataSource(e.dataSet))throw new V.TranslatableError("errors.missingDataSource");const o=V.cloneDeep(e.dataOptions),s=E.extractTrendMeasures(o);o.value.push(...s);const u=E.extractForecastMeasures(o);o.value.push(...u);const c=N.useCallback(({error:p})=>{console.debug("Unexpected error occurred when rendering advanced chart:",p);const m=V.cloneDeep(o),g=h(p.toString());return m.value=m.value.filter(b=>{const _="column"in b?b.column.name:b.name;return!("column"in b&&"type"in b.column&&b.column.type==="calculatedmeasure"&&[E.TREND_PREFIX,E.FORECAST_PREFIX].some(S=>_.includes(S))&&g.some(S=>S.includes(_)))}),O.jsx(km,{fallbackRender:d,onError:b=>{const _=h(b.toString());n(w=>[...new Set([...w,..._])])},children:O.jsx($u,z(D({},e),{dataOptions:m}))},`errorboundary_${t}`)},[e,i]),d=N.useCallback(({error:p})=>(console.debug("Error occurred when rendering fallback chart:",p),p.toString().includes(Cve)?O.jsx($u,D({},e)):O.jsx(y.ErrorBoundaryBox,{error:i[0]})),[e,i]),h=p=>{if(p.includes(xve)){const m=/Error: BE#733473 More than 1 Function failed, aggregated failures:\s*/;if(m.test(p))return p.replace(m,"").split(";").map(b=>b.trim()).filter(Boolean)}return[p.trim()]};return O.jsx(km,{fallbackRender:c,onError:p=>{const m=h(p.toString());n(g=>[...new Set([...g,...m])])},children:O.jsx($u,z(D({},e),{dataOptions:o}))},`errorboundary_${t}`)},hM=e=>{const{dataSet:t}=e;return!!t&&typeof t!="string"&&"rows"in t&&"columns"in t},fM=y.asSisenseComponent({componentName:"Chart",shouldSkipSisenseContextWaiting:hM,customContextErrorMessageKey:"errors.chartNoSisenseContext"})(e=>{var t;if(Sve(e))return O.jsx(uM,D({},e));if(Mve(e))return O.jsx(Tve,D({},e));if(pM(e))return O.jsx($u,D({},e));throw new V.TranslatableError("errors.chartInvalidProps",{chartType:(t=e.chartType)!=null?t:"unknown"})});function Sve(e){return e.chartType==="table"&&"columns"in e.dataOptions}function pM(e){return e.chartType!=="table"}function Mve(e){return!pM(e)||!H.isCartesian(e.chartType)?!1:e.dataOptions.value.some(r=>(r==null?void 0:r.forecast)!==void 0||(r==null?void 0:r.trend)!==void 0)}function Og(e,{onLocalStateChange:t,syncCompareFn:r=V.isEqual}={}){const[n,i]=N.useState(e),a=N.useRef(e);N.useEffect(()=>{r(a.current,e)||i(e),a.current=e},[e,r]);const o=N.useCallback(s=>{i(u=>{const c=V.isFunction(s)?s(u):s;return t==null||t(c),c})},[t]);return[n,o]}var Mf=function(){return V.root.Date.now()},Pve="Expected a function",Eve=Math.max,Ave=Math.min;function Ig(e,t,r){var n,i,a,o,s,u,c=0,d=!1,h=!1,p=!0;if(typeof e!="function")throw new TypeError(Pve);t=E.toNumber(t)||0,V.isObject(r)&&(d=!!r.leading,h="maxWait"in r,a=h?Eve(E.toNumber(r.maxWait)||0,t):a,p="trailing"in r?!!r.trailing:p);function m(P){var R=n,k=i;return n=i=void 0,c=P,o=e.apply(k,R),o}function g(P){return c=P,s=setTimeout(w,t),d?m(P):o}function b(P){var R=P-u,k=P-c,I=t-R;return h?Ave(I,a-k):I}function _(P){var R=P-u,k=P-c;return u===void 0||R>=t||R<0||h&&k>=a}function w(){var P=Mf();if(_(P))return C(P);s=setTimeout(w,b(P))}function C(P){return s=void 0,p&&n?m(P):(n=i=void 0,o)}function S(){s!==void 0&&clearTimeout(s),c=0,n=u=i=s=void 0}function T(){return s===void 0?o:C(Mf())}function M(){var P=Mf(),R=_(P);if(n=arguments,i=this,u=P,R){if(s===void 0)return g(u);if(h)return clearTimeout(s),s=setTimeout(w,t),m(u)}return s===void 0&&(s=setTimeout(w,t)),o}return M.cancel=S,M.flush=T,M}function mM(e,t){const[r,n]=N.useState(e),i=N.useMemo(()=>Ig(a=>{n(a)},t),[t]);return N.useEffect(()=>{i(e)},[e,i]),N.useEffect(()=>()=>{i.cancel()},[i]),r}function gM(e){return ed(e)?{direction:e}:e}function Rve(e){return typeof e=="object"&&e!==null&&"direction"in e}function V2(e,t){return{valuesIndex:e.field-(t.rows||[]).length-(t.columns||[]).length,columnsMembersPath:Object.values(e.measurePath||{})}}function Dve({type:e,settings:t,sortDetails:r},n){return e==="simple"?r.field>=(n.rows||[]).length?[{rowIndex:0,sort:{direction:V.getSortType(t[0].direction),by:V2(r,n)}}]:[{rowIndex:r.field,sort:{direction:V.getSortType(t[0].direction)}}]:t.reduce((i,a,o)=>{var h;const s=(h=n.rows)==null?void 0:h[o],u=(s==null?void 0:s.sortType)&&gM(s==null?void 0:s.sortType),c={direction:V.getSortType(a.direction),by:V2(r,n)};return!a.selected&&V.isEqual(u==null?void 0:u.by,c.by)&&i.push({rowIndex:o,sort:null}),a.selected&&i.push({rowIndex:o,sort:c}),i},[])}const Nve=200,U2=e=>D(D({attribute:E.translateColumnToAttribute(e),includeSubTotals:e.includeSubTotals||!1},e.sortType&&{sort:gM(e.sortType)}),e.name&&{name:e.name}),kve=e=>{var t;return{measure:E.translateColumnToMeasure(e),totalsCalculation:e.totalsCalculation,dataBars:e.dataBars||!1,shouldRequestMinMax:((t=e.color)==null?void 0:t.type)==="range"}},Fg=e=>{const{rows:t=[],columns:r=[],values:n=[],grandTotals:i}=e,a=t.flatMap(U2),o=r.flatMap(U2),s=n.flatMap(kve);return{rows:a,columns:o,values:s,grandTotals:i}},Lve=({dataSet:e,dataOptionsInternal:t,filters:r,highlights:n})=>{const[i,a]=N.useState(),{rows:o,columns:s,values:u,grandTotals:c}=N.useMemo(()=>Fg(t),[t]),d=N.useCallback(m=>{a(g=>V.isEqual(g,m)?g:m)},[a]),h=mM(N.useMemo(()=>({dataSource:e,rows:o,columns:s,values:u,grandTotals:c,filters:r,highlights:n,onBeforeQuery:d}),[e,o,s,u,c,r,n,d]),Nve),{error:p}=y.useExecutePivotQueryInternal(h);return{jaql:i,error:p}},vM=e=>O.jsx("svg",z(D({width:"24",height:"24",viewBox:"0 0 24 24"},e),{children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11.5 21a8.5 8.5 0 1 1 0-17 8.5 8.5 0 0 1 0 17zM13 8.878c0-1.27-.499-1.896-1.496-1.878C10.501 7.03 10 7.68 10 8.95c0 .737.17 1.647.51 2.731l.318.98c.081.245.14.413.175.503.197.533.376.811.537.835.15.018.314-.248.493-.8.083-.257.161-.512.233-.763.071-.252.146-.503.224-.755.34-1.12.51-2.054.51-2.803zM11.5 18a1 1 0 1 0 0-2 1 1 0 0 0 0 2z"})}));var yl=(e=>(e.HIGHLIGHT="highlight",e.FILTER="filter",e))(yl||{});function yM(e){return function(t){t=V.toString(t);var r=V3(t)?qp(t):void 0,n=r?r[0]:t.charAt(0),i=r?j3(r,1).join(""):t.slice(1);return n[e]()+i}}var bM=yM("toUpperCase");function Ove(e){return bM(V.toString(e).toLowerCase())}function Ive(e,t,r,n){for(var i=-1,a=e==null?0:e.length;++i<a;)r=t(r,e[i],i,e);return r}function Fve(e){return function(t){return e==null?void 0:e[t]}}var $ve={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},Bve=Fve($ve),zve=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Hve="\\u0300-\\u036f",Wve="\\ufe20-\\ufe2f",jve="\\u20d0-\\u20ff",Vve=Hve+Wve+jve,Uve="["+Vve+"]",Gve=RegExp(Uve,"g");function qve(e){return e=V.toString(e),e&&e.replace(zve,Bve).replace(Gve,"")}var Yve=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Xve(e){return e.match(Yve)||[]}var Zve=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function Kve(e){return Zve.test(e)}var _M="\\ud800-\\udfff",Qve="\\u0300-\\u036f",Jve="\\ufe20-\\ufe2f",e1e="\\u20d0-\\u20ff",t1e=Qve+Jve+e1e,wM="\\u2700-\\u27bf",CM="a-z\\xdf-\\xf6\\xf8-\\xff",r1e="\\xac\\xb1\\xd7\\xf7",n1e="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",i1e="\\u2000-\\u206f",a1e=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",xM="A-Z\\xc0-\\xd6\\xd8-\\xde",o1e="\\ufe0e\\ufe0f",TM=r1e+n1e+i1e+a1e,SM="['’]",G2="["+TM+"]",s1e="["+t1e+"]",MM="\\d+",l1e="["+wM+"]",PM="["+CM+"]",EM="[^"+_M+TM+MM+wM+CM+xM+"]",u1e="\\ud83c[\\udffb-\\udfff]",c1e="(?:"+s1e+"|"+u1e+")",d1e="[^"+_M+"]",AM="(?:\\ud83c[\\udde6-\\uddff]){2}",RM="[\\ud800-\\udbff][\\udc00-\\udfff]",Sa="["+xM+"]",h1e="\\u200d",q2="(?:"+PM+"|"+EM+")",f1e="(?:"+Sa+"|"+EM+")",Y2="(?:"+SM+"(?:d|ll|m|re|s|t|ve))?",X2="(?:"+SM+"(?:D|LL|M|RE|S|T|VE))?",DM=c1e+"?",NM="["+o1e+"]?",p1e="(?:"+h1e+"(?:"+[d1e,AM,RM].join("|")+")"+NM+DM+")*",m1e="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",g1e="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",v1e=NM+DM+p1e,y1e="(?:"+[l1e,AM,RM].join("|")+")"+v1e,b1e=RegExp([Sa+"?"+PM+"+"+Y2+"(?="+[G2,Sa,"$"].join("|")+")",f1e+"+"+X2+"(?="+[G2,Sa+q2,"$"].join("|")+")",Sa+"?"+q2+"+"+Y2,Sa+"+"+X2,g1e,m1e,MM,y1e].join("|"),"g");function _1e(e){return e.match(b1e)||[]}function w1e(e,t,r){return e=V.toString(e),t=t,t===void 0?Kve(e)?_1e(e):Xve(e):e.match(t)||[]}var C1e="['’]",x1e=RegExp(C1e,"g");function T1e(e){return function(t){return Ive(w1e(qve(t).replace(x1e,"")),e,"")}}var kM=T1e(function(e,t,r){return t=t.toLowerCase(),e+(r?Ove(t):t)});function S1e(e,t,r,n){for(var i=-1,a=e==null?0:e.length;++i<a;){var o=e[i];t(n,o,r(o),e)}return n}function M1e(e,t){return function(r,n){if(r==null)return r;if(!V.isArrayLike(r))return e(r,n);for(var i=r.length,a=-1,o=Object(r);++a<i&&n(o[a],a,o)!==!1;);return r}}var P1e=M1e(V.baseForOwn);function E1e(e,t,r,n){return P1e(e,function(i,a,o){t(n,i,r(i),o)}),n}function LM(e,t){return function(r,n){var i=V.isArray(r)?S1e:E1e,a=t?t():{};return i(r,e,V.baseIteratee(n),a)}}var bl=LM(function(e,t,r){e[r?0:1].push(t)},function(){return[[],[]]});function $g(e){return t=>{var r,n,i,a,o;return z(D({},t),{toolbar:z(D({},t.toolbar),{menu:z(D({},(n=(r=t.toolbar)==null?void 0:r.menu)!=null?n:{}),{items:[...(o=(a=(i=t.toolbar)==null?void 0:i.menu)==null?void 0:a.items)!=null?o:[],e]})})})}}function OM(e){return t=>{var r,n;return z(D({},t),{config:z(D({},t.config),{header:$g(e)((n=(r=t.config)==null?void 0:r.header)!=null?n:{})})})}}const A1e=Object.freeze(Object.defineProperty({__proto__:null,withHeaderMenuItem:OM,withMenuItemInHeaderConfig:$g},Symbol.toStringTag,{value:"Module"})),Z2=(e,t)=>{var r;return H.isCartesian(e)&&((r=t.category)==null?void 0:r.length)===1||H.isScatter(e)};function R1e({chartType:e,dataOptions:t,enabled:r}){const[n,i]=N.useState([]),a=N.useRef(r&&Z2(e,t));N.useEffect(()=>{a.current=r&&Z2(e,t)},[e,t,r]);const o=N.useMemo(()=>{if(n.length===0)return h=>z(D({},h),{series:h.series.map(p=>z(D({},p),{data:p.data.map(m=>z(D({},m),{selected:!1}))}))});if(H.isScatter(e))return h=>z(D({},h),{series:h.series.map(p=>z(D({},p),{data:p.data.map(m=>z(D({},m),{selected:!n.some(g=>{var b,_;return g.x===m.x&&g.y===m.y&&g.size===m.z&&g.breakByPoint===((b=m.custom)==null?void 0:b.maskedBreakByPoint)&&g.breakByColor===((_=m.custom)==null?void 0:_.maskedBreakByColor)})}))}))});{const h=n.reduce((p,{categoryValue:m})=>(m&&(p[`${m}`]=!0),p),{});return p=>z(D({},p),{series:p.series.map(m=>z(D({},m),{data:m.data.map(g=>{var b,_;return h[(_=(b=g.custom)==null?void 0:b.xValue)==null?void 0:_[0]]?g:z(D({},g),{selected:!0})})}))})}},[n,e]),s=N.useMemo(()=>h=>{var p;return z(D({},h),{chart:z(D({},h.chart),{events:z(D({},(p=h.chart)==null?void 0:p.events),{click:()=>{i([])}})})})},[]),u=N.useCallback(h=>(a.current&&(h=o(h),h=s(h)),h),[o,s]),c=N.useCallback(h=>{a.current&&i(h)},[]),d=N.useCallback(h=>{a.current&&i([h])},[]);return{onBeforeRender:u,onDataPointsSelected:c,onDataPointClick:d}}const D1e="sdkWidgetInit",IM=e=>{const{widgetType:t,widgetName:r,widgetTitle:n,entityId:i,enabled:a=!0}=e,{tracking:o,app:s}=y.useSisenseContext(),{trackEvent:u}=y.useTracking(),c=N.useRef(!1);N.useEffect(()=>{if(!a||!o||!s||c.current)return;c.current=!0;const d={widgetType:t,widgetName:r,widgetTitle:n,entityId:i,entityType:"widget",eventType:"action",featureName:"composesdk",packageName:o.packageName,packageVersion:"2.32.0"};u(D1e,d,!o.enabled)},[a,t,r,n,i,o,s,u])};function N1e(e){const{enabled:t,onChange:r}=e,{t:n}=O.useTranslation(),[i,a]=N.useState(!1),o=N.useCallback(()=>{a(!0)},[]),s=N.useCallback(()=>{a(!1)},[]),u=N.useCallback(h=>{a(!1),r==null||r({type:"title/changed",payload:{title:h}})},[r]),c=N.useMemo(()=>{if(t)return{id:"rename-widget",caption:n("widgetHeader.menu.renameWidget"),onClick:o}},[t,n,o]),d=N.useMemo(()=>{if(t)return{isEditing:i,onCommit:u,onCancel:s,onEditingChange:h=>{h?o():s()}}},[t,i,u,s,o]);return{renameMenuItem:c,titleEditorConfig:d}}function FM(e){var u,c,d;const{onChange:t,headerConfig:r}=e,n=(d=(c=(u=r==null?void 0:r.title)==null?void 0:u.editing)==null?void 0:c.enabled)!=null?d:!1,{renameMenuItem:i,titleEditorConfig:a}=N1e({enabled:n,onChange:t}),o=N.useMemo(()=>!n||!i?r!=null?r:{}:$g(i)(r!=null?r:{}),[n,r,i]);return{headerConfig:n?o:r!=null?r:{},titleEditor:a}}const k1e=e=>E.isStyledColumn(e)?e.column.name:e.name,L1e=e=>"column"in e||"name"in e,O1e=e=>{const t=[];for(const r of Object.values(e)){const n=Array.isArray(r)?r:[r];for(const i of n)typeof i=="object"&&i!==null&&L1e(i)&&t.push(k1e(i))}return t},$M=(e,t,r)=>{var o;if(e.id)return e.id;const n=(o=e.title)!=null?o:null,i=e.dataOptions?O1e(e.dataOptions):[],a=e.dataSource?V.getDataSourceName(e.dataSource):null;return`hash:${V.hashIt({widgetType:t,widgetName:r,widgetTitle:n,columnNames:i,dataSourceName:a})}`},K2=e=>e.chartType,I1e=()=>"pivot",F1e=()=>"text",$1e=e=>e.customWidgetType,B1e=()=>"filter",BM=e=>{var t;return(t=e.title)!=null?t:null};function Su(e){return parseInt(e,10)||0}const z1e={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function H1e(e){for(const t in e)return!1;return!0}function Q2(e){return H1e(e)||e.outerHeightStyle===0&&!e.overflowing}const zM=de.forwardRef(function(t,r){const S=t,{onChange:n,maxRows:i,minRows:a=1,style:o,value:s}=S,u=Ye(S,["onChange","maxRows","minRows","style","value"]),{current:c}=de.useRef(s!=null),d=de.useRef(null),h=y.useForkRef(r,d),p=de.useRef(null),m=de.useRef(null),g=de.useCallback(()=>{const T=d.current,M=m.current;if(!T||!M)return;const R=y.ownerWindow(T).getComputedStyle(T);if(R.width==="0px")return{outerHeightStyle:0,overflowing:!1};M.style.width=R.width,M.value=T.value||t.placeholder||"x",M.value.slice(-1)===`
339
+ `&&(M.value+=" ");const k=R.boxSizing,I=Su(R.paddingBottom)+Su(R.paddingTop),$=Su(R.borderBottomWidth)+Su(R.borderTopWidth),G=M.scrollHeight;M.value="x";const Y=M.scrollHeight;let B=G;a&&(B=Math.max(Number(a)*Y,B)),i&&(B=Math.min(Number(i)*Y,B)),B=Math.max(B,Y);const X=B+(k==="border-box"?I+$:0),U=Math.abs(B-G)<=1;return{outerHeightStyle:X,overflowing:U}},[i,a,t.placeholder]),b=y.useEventCallback(()=>{const T=d.current,M=g();if(!T||!M||Q2(M))return!1;const P=M.outerHeightStyle;return p.current!=null&&p.current!==P}),_=de.useCallback(()=>{const T=d.current,M=g();if(!T||!M||Q2(M))return;const P=M.outerHeightStyle;p.current!==P&&(p.current=P,T.style.height=`${P}px`),T.style.overflow=M.overflowing?"hidden":""},[g]),w=de.useRef(-1);y.useEnhancedEffect(()=>{const T=y.debounce(_),M=d==null?void 0:d.current;if(!M)return;const P=y.ownerWindow(M);P.addEventListener("resize",T);let R;return typeof ResizeObserver!="undefined"&&(R=new ResizeObserver(()=>{b()&&(R.unobserve(M),cancelAnimationFrame(w.current),_(),w.current=requestAnimationFrame(()=>{R.observe(M)}))}),R.observe(M)),()=>{T.clear(),cancelAnimationFrame(w.current),P.removeEventListener("resize",T),R&&R.disconnect()}},[g,_,b]),y.useEnhancedEffect(()=>{_()});const C=T=>{c||_(),n&&n(T)};return _e.jsxs(de.Fragment,{children:[_e.jsx("textarea",D({value:s,onChange:C,ref:h,rows:a,style:o},u)),_e.jsx("textarea",{"aria-hidden":!0,className:t.className,readOnly:!0,ref:m,tabIndex:-1,style:z(D(D({},z1e.shadow),o),{paddingTop:0,paddingBottom:0})})]})});process.env.NODE_ENV!=="production"&&(zM.propTypes={className:y.PropTypes.string,maxRows:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),minRows:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),onChange:y.PropTypes.func,placeholder:y.PropTypes.string,style:y.PropTypes.object,value:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.string),y.PropTypes.number,y.PropTypes.string])});function W1e({props:e,states:t,muiFormControl:r}){return t.reduce((n,i)=>(n[i]=e[i],r&&typeof e[i]=="undefined"&&(n[i]=r[i]),n),{})}const Bg=de.createContext(void 0);process.env.NODE_ENV!=="production"&&(Bg.displayName="FormControlContext");function HM(){return de.useContext(Bg)}function J2(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function j1e(e,t=!1){return e&&(J2(e.value)&&e.value!==""||t&&J2(e.defaultValue)&&e.defaultValue!=="")}function V1e(e){return y.generateUtilityClass("MuiInputBase",e)}const Lm=y.generateUtilityClasses("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]);var e_;const U1e=(e,t)=>{const{ownerState:r}=e;return[t.root,r.formControl&&t.formControl,r.startAdornment&&t.adornedStart,r.endAdornment&&t.adornedEnd,r.error&&t.error,r.size==="small"&&t.sizeSmall,r.multiline&&t.multiline,r.color&&t[`color${y.capitalize(r.color)}`],r.fullWidth&&t.fullWidth,r.hiddenLabel&&t.hiddenLabel]},G1e=(e,t)=>{const{ownerState:r}=e;return[t.input,r.size==="small"&&t.inputSizeSmall,r.multiline&&t.inputMultiline,r.type==="search"&&t.inputTypeSearch,r.startAdornment&&t.inputAdornedStart,r.endAdornment&&t.inputAdornedEnd,r.hiddenLabel&&t.inputHiddenLabel]},q1e=e=>{const{classes:t,color:r,disabled:n,error:i,endAdornment:a,focused:o,formControl:s,fullWidth:u,hiddenLabel:c,multiline:d,readOnly:h,size:p,startAdornment:m,type:g}=e,b={root:["root",`color${y.capitalize(r)}`,n&&"disabled",i&&"error",u&&"fullWidth",o&&"focused",s&&"formControl",p&&p!=="medium"&&`size${y.capitalize(p)}`,d&&"multiline",m&&"adornedStart",a&&"adornedEnd",c&&"hiddenLabel",h&&"readOnly"],input:["input",n&&"disabled",g==="search"&&"inputTypeSearch",d&&"inputMultiline",p==="small"&&"inputSizeSmall",c&&"inputHiddenLabel",m&&"inputAdornedStart",a&&"inputAdornedEnd",h&&"readOnly"]};return y.composeClasses(b,V1e,t)},Y1e=y.styled("div",{name:"MuiInputBase",slot:"Root",overridesResolver:U1e})(y.memoTheme(({theme:e})=>z(D({},e.typography.body1),{color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${Lm.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"},variants:[{props:({ownerState:t})=>t.multiline,style:{padding:"4px 0 5px"}},{props:({ownerState:t,size:r})=>t.multiline&&r==="small",style:{paddingTop:1}},{props:({ownerState:t})=>t.fullWidth,style:{width:"100%"}}]}))),X1e=y.styled("input",{name:"MuiInputBase",slot:"Input",overridesResolver:G1e})(y.memoTheme(({theme:e})=>{const t=e.palette.mode==="light",r=z(D({color:"currentColor"},e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5}),{transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})}),n={opacity:"0 !important"},i=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return{font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%","&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&::-ms-input-placeholder":r,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${Lm.formControl} &`]:{"&::-webkit-input-placeholder":n,"&::-moz-placeholder":n,"&::-ms-input-placeholder":n,"&:focus::-webkit-input-placeholder":i,"&:focus::-moz-placeholder":i,"&:focus::-ms-input-placeholder":i},[`&.${Lm.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},variants:[{props:({ownerState:a})=>!a.disableInjectingGlobalStyles,style:{animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}}},{props:{size:"small"},style:{paddingTop:1}},{props:({ownerState:a})=>a.multiline,style:{height:"auto",resize:"none",padding:0,paddingTop:0}},{props:{type:"search"},style:{MozAppearance:"textfield"}}]}})),t_=P4({"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}),WM=de.forwardRef(function(t,r){var Kr;const n=y.useDefaultProps({props:t,name:"MuiInputBase"}),Nt=n,{"aria-describedby":i,autoComplete:a,autoFocus:o,className:s,color:u,components:c={},componentsProps:d={},defaultValue:h,disabled:p,disableInjectingGlobalStyles:m,endAdornment:g,error:b,fullWidth:_=!1,id:w,inputComponent:C="input",inputProps:S={},inputRef:T,margin:M,maxRows:P,minRows:R,multiline:k=!1,name:I,onBlur:$,onChange:G,onClick:Y,onFocus:B,onKeyDown:X,onKeyUp:U,placeholder:Q,readOnly:W,renderSuffix:q,rows:ee,size:Z,slotProps:J={},slots:ne={},startAdornment:oe,type:ae="text",value:se}=Nt,ue=Ye(Nt,["aria-describedby","autoComplete","autoFocus","className","color","components","componentsProps","defaultValue","disabled","disableInjectingGlobalStyles","endAdornment","error","fullWidth","id","inputComponent","inputProps","inputRef","margin","maxRows","minRows","multiline","name","onBlur","onChange","onClick","onFocus","onKeyDown","onKeyUp","placeholder","readOnly","renderSuffix","rows","size","slotProps","slots","startAdornment","type","value"]),me=S.value!=null?S.value:se,{current:pe}=de.useRef(me!=null),Ce=de.useRef(),ke=de.useCallback(We=>{process.env.NODE_ENV!=="production"&&We&&We.nodeName!=="INPUT"&&!We.focus&&console.error(["MUI: You have provided a `inputComponent` to the input component","that does not correctly handle the `ref` prop.","Make sure the `ref` prop is called with a HTMLInputElement."].join(`
340
+ `))},[]),we=y.useForkRef(Ce,T,S.ref,ke),[le,He]=de.useState(!1),Te=HM();process.env.NODE_ENV!=="production"&&de.useEffect(()=>{if(Te)return Te.registerEffect()},[Te]);const Ae=W1e({props:n,muiFormControl:Te,states:["color","disabled","error","hiddenLabel","size","required","filled"]});Ae.focused=Te?Te.focused:le,de.useEffect(()=>{!Te&&p&&le&&(He(!1),$&&$())},[Te,p,le,$]);const $e=Te&&Te.onFilled,Ge=Te&&Te.onEmpty,qe=de.useCallback(We=>{j1e(We)?$e&&$e():Ge&&Ge()},[$e,Ge]);y.useEnhancedEffect(()=>{pe&&qe({value:me})},[me,qe,pe]);const jt=We=>{B&&B(We),S.onFocus&&S.onFocus(We),Te&&Te.onFocus?Te.onFocus(We):He(!0)},pt=We=>{$&&$(We),S.onBlur&&S.onBlur(We),Te&&Te.onBlur?Te.onBlur(We):He(!1)},St=(We,..._t)=>{if(!pe){const ci=We.target||Ce.current;if(ci==null)throw new Error(process.env.NODE_ENV!=="production"?"MUI: Expected valid input target. Did you use a custom `inputComponent` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":y.formatMuiErrorMessage(1));qe({value:ci.value})}S.onChange&&S.onChange(We,..._t),G&&G(We,..._t)};de.useEffect(()=>{qe(Ce.current)},[]);const Ft=We=>{Ce.current&&We.currentTarget===We.target&&Ce.current.focus(),Y&&Y(We)};let Qt=C,bt=S;k&&Qt==="input"&&(ee?(process.env.NODE_ENV!=="production"&&(R||P)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),bt=D({type:void 0,minRows:ee,maxRows:ee},bt)):bt=D({type:void 0,maxRows:P,minRows:R},bt),Qt=zM);const Jt=We=>{qe(We.animationName==="mui-auto-fill-cancel"?Ce.current:{value:"x"})};de.useEffect(()=>{Te&&Te.setAdornedStart(!!oe)},[Te,oe]);const Mr=z(D({},n),{color:Ae.color||"primary",disabled:Ae.disabled,endAdornment:g,error:Ae.error,focused:Ae.focused,formControl:Te,fullWidth:_,hiddenLabel:Ae.hiddenLabel,multiline:k,size:Ae.size,startAdornment:oe,type:ae}),Pr=q1e(Mr),Zr=ne.root||c.Root||Y1e,Br=J.root||d.root||{},Cn=ne.input||c.Input||X1e;return bt=D(D({},bt),(Kr=J.input)!=null?Kr:d.input),_e.jsxs(de.Fragment,{children:[!m&&typeof t_=="function"&&(e_||(e_=_e.jsx(t_,{}))),_e.jsxs(Zr,z(D(D(z(D({},Br),{ref:r,onClick:Ft}),ue),!y.isHostComponent(Zr)&&{ownerState:D(D({},Mr),Br.ownerState)}),{className:y.clsx(Pr.root,Br.className,s,W&&"MuiInputBase-readOnly"),children:[oe,_e.jsx(Bg.Provider,{value:null,children:_e.jsx(Cn,z(D(D({"aria-invalid":Ae.error,"aria-describedby":i,autoComplete:a,autoFocus:o,defaultValue:h,disabled:Ae.disabled,id:w,onAnimationStart:Jt,name:I,placeholder:Q,readOnly:W,required:Ae.required,rows:ee,value:me,onKeyDown:X,onKeyUp:U,type:ae},bt),!y.isHostComponent(Cn)&&{as:Qt,ownerState:D(D({},Mr),bt.ownerState)}),{ref:we,className:y.clsx(Pr.input,bt.className,W&&"MuiInputBase-readOnly"),onBlur:pt,onChange:St,onFocus:jt}))}),g,q?q(z(D({},Ae),{startAdornment:oe})):null]}))]})});process.env.NODE_ENV!=="production"&&(WM.propTypes={"aria-describedby":y.PropTypes.string,autoComplete:y.PropTypes.string,autoFocus:y.PropTypes.bool,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["primary","secondary","error","info","success","warning"]),y.PropTypes.string]),components:y.PropTypes.shape({Input:y.PropTypes.elementType,Root:y.PropTypes.elementType}),componentsProps:y.PropTypes.shape({input:y.PropTypes.object,root:y.PropTypes.object}),defaultValue:y.PropTypes.any,disabled:y.PropTypes.bool,disableInjectingGlobalStyles:y.PropTypes.bool,endAdornment:y.PropTypes.node,error:y.PropTypes.bool,fullWidth:y.PropTypes.bool,id:y.PropTypes.string,inputComponent:y.elementTypeAcceptingRef,inputProps:y.PropTypes.object,inputRef:y.refType,margin:y.PropTypes.oneOf(["dense","none"]),maxRows:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),minRows:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),multiline:y.PropTypes.bool,name:y.PropTypes.string,onBlur:y.PropTypes.func,onChange:y.PropTypes.func,onClick:y.PropTypes.func,onFocus:y.PropTypes.func,onInvalid:y.PropTypes.func,onKeyDown:y.PropTypes.func,onKeyUp:y.PropTypes.func,placeholder:y.PropTypes.string,readOnly:y.PropTypes.bool,renderSuffix:y.PropTypes.func,required:y.PropTypes.bool,rows:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),size:y.PropTypes.oneOfType([y.PropTypes.oneOf(["medium","small"]),y.PropTypes.string]),slotProps:y.PropTypes.shape({input:y.PropTypes.object,root:y.PropTypes.object}),slots:y.PropTypes.shape({input:y.PropTypes.elementType,root:y.PropTypes.elementType}),startAdornment:y.PropTypes.node,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),type:y.PropTypes.string,value:y.PropTypes.any});function Z1e(e,t){N.useEffect(()=>{if(!t)return;const r=n=>{e.current&&!e.current.contains(n.target)&&e.current.blur()};return document.addEventListener("pointerdown",r),()=>{document.removeEventListener("pointerdown",r)}},[e,t])}const K1e=y.newStyled.div`
341
+ display: inline-grid;
342
+ grid-template-columns: 1fr;
343
+ align-items: baseline;
344
+ width: auto;
345
+ min-width: 50px;
346
+ max-width: 100%;
347
+ `,Q1e=y.newStyled.span`
348
+ // Auto-growing input using a CSS Grid technique with sharing the same grid area as the hidden text
349
+ grid-area: 1 / 1 / 2 / 2;
350
+ visibility: hidden;
351
+ white-space: pre;
352
+ font: inherit;
353
+ padding: 0;
354
+ `,J1e=y.newStyled(WM)`
355
+ // Auto-growing input using a CSS Grid technique with sharing the same grid area as the hidden text
356
+ grid-area: 1 / 1 / 2 / 2;
357
+ width: 100%;
358
+ font: inherit;
359
+ color: inherit;
360
+
361
+ & .MuiInputBase-input {
362
+ padding: 0;
363
+ font: inherit;
364
+ color: inherit;
365
+ width: 100%;
366
+
367
+ &::placeholder {
368
+ opacity: 0.5;
369
+ }
370
+
371
+ &:focus {
372
+ outline: none;
373
+ box-shadow: none;
374
+ }
375
+ }
376
+ `,eye=y.newStyled.span`
377
+ color: ${({isPlaceholder:e})=>e?"rgba(0, 0, 0, 0.38)":"inherit"};
378
+ `;function tye({value:e,isEditing:t,onCommit:r,onEditingChange:n,onCancel:i,placeholder:a}){const o=N.useRef(null),[s,u]=N.useState(e);N.useEffect(()=>{t&&u(e)},[t,e]);const c=N.useCallback(()=>{const _=s.trim(),w=E.purify.sanitize(_,{ALLOWED_TAGS:[]});w!==e&&r(w),n(!1)},[s,r,n,e]),d=N.useCallback(()=>{i==null||i(),n(!1)},[i,n]),h=N.useCallback(_=>{_.key==="Enter"?(_.preventDefault(),c()):_.key==="Escape"&&(_.preventDefault(),d())},[c,d]),p=N.useCallback(()=>{c()},[c]),m=N.useCallback(()=>{n(!0)},[n]),g=N.useCallback(_=>{(_.key==="Enter"||_.key===" ")&&(_.preventDefault(),m())},[m]);if(N.useEffect(()=>{t&&o.current&&(o.current.focus(),o.current.select())},[t]),Z1e(o,t),t)return O.jsxs(K1e,{children:[O.jsx(Q1e,{children:s||a||""}),O.jsx(J1e,{inputRef:o,inputProps:{"data-component":"inline-text-editor-input"},value:s,placeholder:a,onChange:_=>u(_.target.value),onBlur:p,onKeyDown:h})]});const b=!e&&!!a;return O.jsx(eye,{role:"button",tabIndex:0,"aria-label":"Editable text. Double-click or press Enter or Space to edit.","data-component":"inline-text-editor-text",onDoubleClick:m,onKeyDown:g,isPlaceholder:b,children:e||a||""})}function rye(e){return y.generateUtilityClass("MuiCard",e)}y.generateUtilityClasses("MuiCard",["root"]);const nye=e=>{const{classes:t}=e,r={root:["root"]};return y.composeClasses(r,rye,t)},iye=y.styled(y.Paper,{name:"MuiCard",slot:"Root",overridesResolver:(e,t)=>t.root})({overflow:"hidden"}),jM=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiCard"}),c=n,{className:i,raised:a=!1}=c,o=Ye(c,["className","raised"]),s=z(D({},n),{raised:a}),u=nye(s);return _e.jsx(iye,D({className:y.clsx(u.root,i),elevation:a?8:void 0,ref:r,ownerState:s},o))});process.env.NODE_ENV!=="production"&&(jM.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,raised:y.chainPropTypes(y.PropTypes.bool,e=>e.raised&&e.variant==="outlined"?new Error('MUI: Combining `raised={true}` with `variant="outlined"` has no effect.'):null),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object])});function aye(e){return y.generateUtilityClass("MuiCardContent",e)}y.generateUtilityClasses("MuiCardContent",["root"]);const oye=e=>{const{classes:t}=e,r={root:["root"]};return y.composeClasses(r,aye,t)},sye=y.styled("div",{name:"MuiCardContent",slot:"Root",overridesResolver:(e,t)=>t.root})({padding:16,"&:last-child":{paddingBottom:24}}),VM=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiCardContent"}),c=n,{className:i,component:a="div"}=c,o=Ye(c,["className","component"]),s=z(D({},n),{component:a}),u=oye(s);return _e.jsx(sye,D({as:a,className:y.clsx(u.root,i),ownerState:s,ref:r},o))});process.env.NODE_ENV!=="production"&&(VM.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,component:y.PropTypes.elementType,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object])});function lye(e){return y.generateUtilityClass("MuiCircularProgress",e)}y.generateUtilityClasses("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const Hn=44,Om=y.keyframes`
379
+ 0% {
380
+ transform: rotate(0deg);
381
+ }
382
+
383
+ 100% {
384
+ transform: rotate(360deg);
385
+ }
386
+ `,Im=y.keyframes`
387
+ 0% {
388
+ stroke-dasharray: 1px, 200px;
389
+ stroke-dashoffset: 0;
390
+ }
391
+
392
+ 50% {
393
+ stroke-dasharray: 100px, 200px;
394
+ stroke-dashoffset: -15px;
395
+ }
396
+
397
+ 100% {
398
+ stroke-dasharray: 1px, 200px;
399
+ stroke-dashoffset: -126px;
400
+ }
401
+ `,uye=typeof Om!="string"?y.css`
402
+ animation: ${Om} 1.4s linear infinite;
403
+ `:null,cye=typeof Im!="string"?y.css`
404
+ animation: ${Im} 1.4s ease-in-out infinite;
405
+ `:null,dye=e=>{const{classes:t,variant:r,color:n,disableShrink:i}=e,a={root:["root",r,`color${y.capitalize(n)}`],svg:["svg"],circle:["circle",`circle${y.capitalize(r)}`,i&&"circleDisableShrink"]};return y.composeClasses(a,lye,t)},hye=y.styled("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`color${y.capitalize(r.color)}`]]}})(y.memoTheme(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:uye||{animation:`${Om} 1.4s linear infinite`}},...Object.entries(e.palette).filter(ri()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),fye=y.styled("svg",{name:"MuiCircularProgress",slot:"Svg",overridesResolver:(e,t)=>t.svg})({display:"block"}),pye=y.styled("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.circle,t[`circle${y.capitalize(r.variant)}`],r.disableShrink&&t.circleDisableShrink]}})(y.memoTheme(({theme:e})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:t})=>t.variant==="indeterminate"&&!t.disableShrink,style:cye||{animation:`${Im} 1.4s ease-in-out infinite`}}]}))),zg=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiCircularProgress"}),C=n,{className:i,color:a="primary",disableShrink:o=!1,size:s=40,style:u,thickness:c=3.6,value:d=0,variant:h="indeterminate"}=C,p=Ye(C,["className","color","disableShrink","size","style","thickness","value","variant"]),m=z(D({},n),{color:a,disableShrink:o,size:s,thickness:c,value:d,variant:h}),g=dye(m),b={},_={},w={};if(h==="determinate"){const S=2*Math.PI*((Hn-c)/2);b.strokeDasharray=S.toFixed(3),w["aria-valuenow"]=Math.round(d),b.strokeDashoffset=`${((100-d)/100*S).toFixed(3)}px`,_.transform="rotate(-90deg)"}return _e.jsx(hye,z(D(D({className:y.clsx(g.root,i),style:D(D({width:s,height:s},_),u),ownerState:m,ref:r,role:"progressbar"},w),p),{children:_e.jsx(fye,{className:g.svg,ownerState:m,viewBox:`${Hn/2} ${Hn/2} ${Hn} ${Hn}`,children:_e.jsx(pye,{className:g.circle,style:b,ownerState:m,cx:Hn,cy:Hn,r:(Hn-c)/2,fill:"none",strokeWidth:c})})}))});process.env.NODE_ENV!=="production"&&(zg.propTypes={classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["inherit","primary","secondary","error","info","success","warning"]),y.PropTypes.string]),disableShrink:y.chainPropTypes(y.PropTypes.bool,e=>e.disableShrink&&e.variant&&e.variant!=="indeterminate"?new Error("MUI: You have provided the `disableShrink` prop with a variant other than `indeterminate`. This will have no effect."):null),size:y.PropTypes.oneOfType([y.PropTypes.number,y.PropTypes.string]),style:y.PropTypes.object,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),thickness:y.PropTypes.number,value:y.PropTypes.number,variant:y.PropTypes.oneOf(["determinate","indeterminate"])});function mye(e){return y.generateUtilityClass("MuiIconButton",e)}const r_=y.generateUtilityClasses("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),gye=e=>{const{classes:t,disabled:r,color:n,edge:i,size:a,loading:o}=e,s={root:["root",o&&"loading",r&&"disabled",n!=="default"&&`color${y.capitalize(n)}`,i&&`edge${y.capitalize(i)}`,`size${y.capitalize(a)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return y.composeClasses(s,mye,t)},vye=y.styled(y.ButtonBase,{name:"MuiIconButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,r.loading&&t.loading,r.color!=="default"&&t[`color${y.capitalize(r.color)}`],r.edge&&t[`edge${y.capitalize(r.edge)}`],t[`size${y.capitalize(r.size)}`]]}})(y.memoTheme(({theme:e})=>({textAlign:"center",flex:"0 0 auto",fontSize:e.typography.pxToRem(24),padding:8,borderRadius:"50%",color:(e.vars||e).palette.action.active,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),variants:[{props:t=>!t.disableRipple,style:{"--IconButton-hoverBg":e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha(e.palette.action.active,e.palette.action.hoverOpacity),"&:hover":{backgroundColor:"var(--IconButton-hoverBg)","@media (hover: none)":{backgroundColor:"transparent"}}}},{props:{edge:"start"},style:{marginLeft:-12}},{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:{edge:"end"},style:{marginRight:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}}]})),y.memoTheme(({theme:e})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(e.palette).filter(ri()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette).filter(ri()).map(([t])=>({props:{color:t},style:{"--IconButton-hoverBg":e.vars?`rgba(${(e.vars||e).palette[t].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha((e.vars||e).palette[t].main,e.palette.action.hoverOpacity)}})),{props:{size:"small"},style:{padding:5,fontSize:e.typography.pxToRem(18)}},{props:{size:"large"},style:{padding:12,fontSize:e.typography.pxToRem(28)}}],[`&.${r_.disabled}`]:{backgroundColor:"transparent",color:(e.vars||e).palette.action.disabled},[`&.${r_.loading}`]:{color:"transparent"}}))),yye=y.styled("span",{name:"MuiIconButton",slot:"LoadingIndicator",overridesResolver:(e,t)=>t.loadingIndicator})(({theme:e})=>({display:"none",position:"absolute",visibility:"visible",top:"50%",left:"50%",transform:"translate(-50%, -50%)",color:(e.vars||e).palette.action.disabled,variants:[{props:{loading:!0},style:{display:"flex"}}]})),vn=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiIconButton"}),S=n,{edge:i=!1,children:a,className:o,color:s="default",disabled:u=!1,disableFocusRipple:c=!1,size:d="medium",id:h,loading:p=null,loadingIndicator:m}=S,g=Ye(S,["edge","children","className","color","disabled","disableFocusRipple","size","id","loading","loadingIndicator"]),b=Mc(h),_=m!=null?m:_e.jsx(zg,{"aria-labelledby":b,color:"inherit",size:16}),w=z(D({},n),{edge:i,color:s,disabled:u,disableFocusRipple:c,loading:p,loadingIndicator:_,size:d}),C=gye(w);return _e.jsxs(vye,z(D({id:p?b:h,className:y.clsx(C.root,o),centerRipple:!0,focusRipple:!c,disabled:u||p,ref:r},g),{ownerState:w,children:[typeof p=="boolean"&&_e.jsx("span",{className:C.loadingWrapper,style:{display:"contents"},children:_e.jsx(yye,{className:C.loadingIndicator,ownerState:w,children:p&&_})}),a]}))});process.env.NODE_ENV!=="production"&&(vn.propTypes={children:y.chainPropTypes(y.PropTypes.node,e=>de.Children.toArray(e.children).some(r=>de.isValidElement(r)&&r.props.onClick)?new Error(["MUI: You are providing an onClick event listener to a child of a button element.","Prefer applying it to the IconButton directly.","This guarantees that the whole <button> will be responsive to click events."].join(`
406
+ `)):null),classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),y.PropTypes.string]),disabled:y.PropTypes.bool,disableFocusRipple:y.PropTypes.bool,disableRipple:y.PropTypes.bool,edge:y.PropTypes.oneOf(["end","start",!1]),id:y.PropTypes.string,loading:y.PropTypes.bool,loadingIndicator:y.PropTypes.node,size:y.PropTypes.oneOfType([y.PropTypes.oneOf(["small","medium","large"]),y.PropTypes.string]),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object])});function bye({fill:e="rgba(38, 46, 61, 0.67)"}){return O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:O.jsx("path",{fill:e,d:"M11.5 21a8.5 8.5 0 1 1 0-17 8.5 8.5 0 0 1 0 17zM13 8.878c0-1.27-.499-1.896-1.496-1.878C10.501 7.03 10 7.68 10 8.95c0 .737.17 1.647.51 2.731l.318.98c.081.245.14.413.175.503.197.533.376.811.537.835.15.018.314-.248.493-.8.083-.257.161-.512.233-.763.071-.252.146-.503.224-.755.34-1.12.51-2.054.51-2.803zM11.5 18a1 1 0 1 0 0-2 1 1 0 0 0 0 2z"})})}function _ye({title:e,description:t,errorMessages:r=[],styleOptions:n,onRefresh:i}){var w,C,S;const[a,o]=N.useState(null),{themeSettings:s}=y.useThemeContext(),{typography:{primaryTextColor:u,secondaryTextColor:c,fontFamily:d}}=s,{t:h}=O.useTranslation(),p=T=>{o(T.currentTarget)},m=()=>{o(null)},g=N.useMemo(()=>e?O.jsx(_r,{variant:"body2",style:{color:u,fontFamily:d,fontSize:13},children:e}):null,[e,u,d]),b=N.useMemo(()=>r.length===0?null:r.map(T=>O.jsxs(O.Fragment,{children:[O.jsx(Si,{sx:{my:1,borderColor:c,opacity:.3,marginY:"8px"}}),O.jsxs("div",{className:"csdk-flex",children:[O.jsx("div",{className:"csdk-shrink-0 csdk-grow-0",children:O.jsx(bye,{fill:"#fa5656"})}),O.jsx(_r,{variant:"body2",className:"csdk-grow-1",style:{color:c,fontFamily:d,fontSize:13,marginLeft:5,lineHeight:"24px",letterSpacing:"normal",overflowWrap:"anywhere"},children:T})]})]})),[r,c,d]),_=N.useMemo(()=>t?O.jsxs(O.Fragment,{children:[O.jsx(Si,{sx:{my:"8px",borderColor:c,opacity:.3}}),O.jsx(_r,{variant:"body2",style:{color:c,fontFamily:d,fontSize:13},children:t})]}):null,[t,c,d]);return O.jsxs(O.Fragment,{children:[O.jsx(Ii,{title:h("widgetHeader.info.tooltip"),style:{color:(w=s.chart)==null?void 0:w.textColor,fontFamily:(C=s.typography)==null?void 0:C.fontFamily},children:O.jsx(vn,{onClick:p,sx:D({p:0},O.MIN_TOUCH_TARGET_SIZE),"data-testid":"widget-header-info-icon-button",children:O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",children:O.jsx("path",{fill:(n==null?void 0:n.titleTextColor)||s.widget.header.titleTextColor,d:"M11.5 20a7.5 7.5 0 1 1 0-15 7.5 7.5 0 0 1 0 15zm0-1a6.5 6.5 0 1 0 0-13 6.5 6.5 0 0 0 0 13zm-.5-8h1v5h-1v-5zm0-1v-.998h1V10h-1z"})})})}),O.jsx(y.Popover,{open:!!a,position:a?{anchorEl:a,anchorOrigin:{vertical:"bottom",horizontal:"center"},contentOrigin:{vertical:"top",horizontal:"center"}}:void 0,onClose:m,children:O.jsxs(jM,{raised:!0,className:"csdk-max-w-xs csdk-w-[300px]",children:[O.jsxs("div",{className:"csdk-flex csdk-flex-row csdk-justify-between csdk-items-center csdk-py-[5px] csdk-px-[12px]",style:{backgroundColor:E.getSlightlyDifferentColor(s.general.backgroundColor)},children:[O.jsx(_r,{variant:"subtitle2",sx:{fontWeight:"bold"},style:{color:s.typography.primaryTextColor,fontFamily:s.typography.fontFamily},children:h("widgetHeader.info.details")}),O.jsx(vn,{onClick:i,sx:D({p:0},O.MIN_TOUCH_TARGET_SIZE),"data-testid":"widget-header-refresh-icon-button",children:O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",children:O.jsx("path",{fill:(S=s.chart)==null?void 0:S.textColor,d:"M20 12a8 8 0 0 1-15.259 3.368l1.004-.222a7 7 0 0 0 13.252-2.925L20 12zm0 0a8 8 0 0 1-15.259 3.368l1.004-.222a7 7 0 0 0 13.252-2.925L20 12zm-8-7a7 7 0 0 1 6.267 3.877l1.003-.22A8.001 8.001 0 0 0 4 12l1.003-.22A7 7 0 0 1 12 5zm6.998 3.12A8 8 0 0 0 4 12l1.003-.22a7 7 0 0 1 13.264-2.903l.73-.16v.28l-2.98.016-.017.971h3.985V6h-.987v2.12zm-14.01 9.864H4V14h3.985l-.016.971-2.981.017v2.996z"})})})]}),O.jsx(Si,{sx:{borderColor:s.typography.secondaryTextColor,opacity:.3}}),O.jsxs(VM,{style:{backgroundColor:s.general.backgroundColor,padding:12},children:[g,b,_]})]})})]})}const Hg=()=>{const e=y.useMenuContext();if(!e)throw new V.TranslatableError("errors.missingMenuRoot");return e};function UM({fill:e="rgba(38, 46, 61, 0.67)"}){return O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11 7C11 6.44772 11.4477 6 12 6C12.5523 6 13 6.44772 13 7C13 7.55228 12.5523 8 12 8C11.4477 8 11 7.55228 11 7ZM11 12C11 11.4477 11.4477 11 12 11C12.5523 11 13 11.4477 13 12C13 12.5523 12.5523 13 12 13C11.4477 13 11 12.5523 11 12ZM12 16C11.4477 16 11 16.4477 11 17C11 17.5523 11.4477 18 12 18C12.5523 18 13 17.5523 13 17C13 16.4477 12.5523 16 12 16Z",fill:e})})}const n_=28,wye=y.newStyled(vn,{shouldForwardProp:e=>e!=="iconSize"})`
407
+ min-width: ${({iconSize:e})=>e!=null?e:n_}px;
408
+ min-height: ${({iconSize:e})=>e!=null?e:n_}px;
409
+ `,GM=a=>{var o=a,{color:e,onClick:t,ariaLabel:r,size:n}=o,i=Ye(o,["color","onClick","ariaLabel","size"]);const s=N.useCallback(()=>E.getSlightlyDifferentColor(e!=null?e:"",void 0,.1),[e]);return O.jsx(wye,z(D({iconSize:n,sx:{padding:0,"&:hover":{backgroundColor:s()}},onClick:t,"aria-label":r},i),{children:O.jsx(UM,{fill:e})}))};function qM(e){var t;return{key:e.id,caption:e.caption,onClick:e.onClick,subItems:(t=e.items)!=null&&t.length?[{items:e.items.map(qM)}]:void 0}}const YM=({menuItems:e})=>{const{themeSettings:t}=y.useThemeContext(),{openMenu:r}=Hg(),n=N.useCallback(i=>{i.stopPropagation();const a=i.currentTarget.getBoundingClientRect();e.length&&r({position:{left:a.right,top:a.bottom},alignment:{horizontal:"right"},itemSections:[{items:e.map(qM)}]})},[e,r]);return O.jsx(GM,{onClick:n,ariaLabel:"widget header toolbar menu",color:t.widget.header.titleTextColor})};function Cye({infoButtonConfig:e,styleOptions:t,onRefresh:r,config:n}){var o,s,u,c;const i=N.useMemo(()=>{var d,h;return E.isUndefined((d=n==null?void 0:n.menu)==null?void 0:d.enabled)?!0:(h=n==null?void 0:n.menu)==null?void 0:h.enabled},[(o=n==null?void 0:n.menu)==null?void 0:o.enabled]),a=O.jsx(O.Fragment,{children:O.jsx(_ye,{title:e.dataSetName,description:e.description,styleOptions:t,errorMessages:e.errorMessages,warningMessages:e.warningMessages,onRefresh:r})});return O.jsxs(O.Fragment,{children:[t!=null&&t.renderToolbar?t.renderToolbar(r,a):a,i&&((s=n==null?void 0:n.menu)==null?void 0:s.items)&&((u=n==null?void 0:n.menu)==null?void 0:u.items.length)>0&&O.jsx(YM,{menuItems:(c=n==null?void 0:n.menu)==null?void 0:c.items})]})}function xye(e){return e.toLowerCase()}const Tye=({title:e,infoButtonConfig:t,styleOptions:r,onRefresh:n,config:i,titleEditor:a})=>{var d,h;const{themeSettings:o}=y.useThemeContext(),{t:s}=O.useTranslation(),u=V.get(r,"dividerLine",o.widget.header.dividerLine),c=a?O.jsx(tye,{value:e!=null?e:"",isEditing:a.isEditing,onEditingChange:a.onEditingChange,onCommit:a.onCommit,onCancel:a.onCancel,placeholder:s("widgetHeader.addTitle")}):e;return O.jsxs("div",{"data-component":"widget-header",children:[O.jsxs(Sye,{styleOptions:r,theme:o,"data-component":"header-container",children:[O.jsx(Mye,{styleOptions:r,theme:o,"data-component":"title",children:(h=(d=r==null?void 0:r.renderTitle)==null?void 0:d.call(r,c))!=null?h:c}),O.jsx(Pye,{"data-component":"toolbar-container",children:O.jsx(Cye,{infoButtonConfig:t,styleOptions:r,onRefresh:n,config:i==null?void 0:i.toolbar})})]}),u&&O.jsx(Eye,{styleOptions:r,theme:o,"data-component":"widget-header-divider"})]})},Sye=y.newStyled.div`
410
+ display: flex;
411
+ flex-direction: row;
412
+ align-items: center;
413
+ padding-left: 8px;
414
+ padding-right: 8px;
415
+ min-height: 32px;
416
+ background-color: ${({styleOptions:e,theme:t})=>(e==null?void 0:e.backgroundColor)||t.widget.header.backgroundColor};
417
+ `,Mye=y.newStyled.div`
418
+ width: 100%;
419
+ white-space: nowrap;
420
+ overflow: hidden;
421
+ text-align: ${({styleOptions:e,theme:t})=>xye((e==null?void 0:e.titleAlignment)||t.widget.header.titleAlignment)};
422
+ color: ${({styleOptions:e,theme:t})=>(e==null?void 0:e.titleTextColor)||t.widget.header.titleTextColor};
423
+ font-family: ${({theme:e})=>{var t,r;return(r=(t=e.typography)==null?void 0:t.fontFamily)!=null?r:"inherit"}};
424
+ font-size: ${({theme:e})=>{const t=e.widget.header.titleFontSize;return typeof t=="number"?`${t}px`:t}};
425
+ `,Pye=y.newStyled.div`
426
+ margin-left: auto;
427
+ display: flex;
428
+ align-items: center;
429
+ `,Eye=y.newStyled(Si)`
430
+ background-color: ${({styleOptions:e,theme:t})=>(e==null?void 0:e.dividerLineColor)||t.widget.header.dividerLineColor||"#e6e6e6"};
431
+ `;var XM=(e=>(e.None="",e.Large="30px",e.Medium="20px",e.Small="10px",e))(XM||{}),Fm=(e=>(e.None="",e.Light="0.15",e.Medium="0.3",e.Dark="0.7",e))(Fm||{}),$m=(e=>(e.None="",e.Large="3px 12px",e.Medium="2px 8px",e.Small="1px 4px",e))($m||{}),$d=(e=>(e.None="",e.Large="15px",e.Medium="10px",e.Small="5px",e))($d||{});const Aye=(e,t)=>{const r=V.get(e,"shadow",t.widget.shadow),n=V.get(e,"spaceAround",t.widget.spaceAround);if(r==="None"||n==="None")return"none";if(r in Fm&&n in $m){const i=Fm[`${r}`];return`0px ${$m[`${n}`]} rgba(9, 9, 10, ${i})`}return"none"},Rye=(e,t)=>{const r=V.get(e,"spaceAround",t.widget.spaceAround);return parseInt($d[`${r}`]||"0",10)||0},Dye=({styleOptions:e,themeSettings:t,hasHeader:r})=>(r?B_:0)+2*Rye(e,t),ZM=e=>O.jsx(wve,{children:O.jsx(Nye,D({},e))}),Nye=({dataSetName:e,styleOptions:t,headerConfig:r,titleEditor:n,title:i,description:a,topSlot:o,bottomSlot:s,children:u,onRefresh:c=()=>{},contentAreaRef:d})=>{var b,_;const{errors:h,warnings:p}=dM(),{themeSettings:m}=y.useThemeContext(),g=N.useMemo(()=>{var w;return{chart:{backgroundColor:(t==null?void 0:t.backgroundColor)||((w=m.chart)==null?void 0:w.backgroundColor)}}},[t==null?void 0:t.backgroundColor,(b=m.chart)==null?void 0:b.backgroundColor]);return O.jsx(kye,{className:"csdk-accessible","data-component":"widget-container-root",children:O.jsx(Lye,{styleOptions:t,theme:m,"data-component":"widget-container-layout",children:O.jsxs(Oye,{styleOptions:t,theme:m,"data-component":"widget-container-card",children:[!((_=t==null?void 0:t.header)!=null&&_.hidden)&&O.jsx(Tye,{title:i,infoButtonConfig:{dataSetName:e,description:a,errorMessages:h,warningMessages:p},styleOptions:t==null?void 0:t.header,config:r,titleEditor:n,onRefresh:c}),O.jsxs(Iye,{ref:d,styleOptions:t,theme:m,"data-component":"widget-content-area",children:[o,O.jsx(Y_,{theme:g,children:O.jsx(Fye,{styleOptions:t,theme:m,"data-component":"widget-container-content",children:u})}),s]})]})})})},kye=y.newStyled.div`
432
+ width: 100%;
433
+ height: 100%;
434
+ overflow: hidden;
435
+ `,Lye=y.newStyled.div`
436
+ box-sizing: border-box;
437
+ height: 100%;
438
+ padding: ${({styleOptions:e,theme:t})=>$d[V.get(e,"spaceAround",t.widget.spaceAround)]||"0px"};
439
+ `,Oye=y.newStyled.div`
440
+ box-sizing: border-box;
441
+ height: 100%;
442
+ overflow: hidden;
443
+ display: flex;
444
+ flex-direction: column;
445
+ background-color: ${({styleOptions:e})=>(e==null?void 0:e.backgroundColor)||"unset"};
446
+ border-width: ${({styleOptions:e,theme:t})=>V.get(e,"border",t.widget.border)?"1px":"0"};
447
+ border-style: solid;
448
+ border-color: ${({styleOptions:e,theme:t})=>(e==null?void 0:e.borderColor)||t.widget.borderColor};
449
+ border-radius: ${({styleOptions:e,theme:t})=>XM[(e==null?void 0:e.cornerRadius)||t.widget.cornerRadius]||"0"};
450
+ box-shadow: ${({styleOptions:e,theme:t})=>Aye(e,t)};
451
+ `,Iye=y.newStyled.div`
452
+ flex: 1;
453
+ min-height: 0;
454
+ display: flex;
455
+ flex-direction: column;
456
+ overflow: hidden;
457
+ background-color: ${({styleOptions:e,theme:t})=>{var r;return(e==null?void 0:e.backgroundColor)||((r=t.chart)==null?void 0:r.backgroundColor)}};
458
+ `,Fye=y.newStyled.div`
459
+ flex-grow: 1;
460
+ min-width: 0;
461
+ min-height: 0;
462
+ background-color: ${({styleOptions:e,theme:t})=>{var r;return(e==null?void 0:e.backgroundColor)||((r=t.chart)==null?void 0:r.backgroundColor)}};
463
+ `,$ye="file";function Wg(e,t){const r=URL.createObjectURL(e),n=document.createElement("a");n.href=r,n.download=t;try{document.body.appendChild(n),n.click()}finally{URL.revokeObjectURL(r),n.remove()}}function jg(e){const t=e.lastIndexOf("."),r=t===-1?e:e.substring(0,t),n=t===-1?"":e.substring(t);return`${r.replace(/[^a-zA-Z0-9]/g,"")||$ye}${n}`}const Bye=Object.freeze(Object.defineProperty({__proto__:null,downloadBlobAsFile:Wg,normalizeFileName:jg},Symbol.toStringTag,{value:"Module"})),zye="data.csv";function KM(){const[e,t]=N.useState(null),r=y.useExecuteCsvQueryInternal(z(D({},e!=null?e:{dimensions:[],measures:[]}),{enabled:!!e,config:{asDataStream:!0}}));return N.useEffect(()=>{var i;e&&(r.isSuccess&&r.data?(Wg(r.data,jg((i=e.filename)!=null?i:zye)),t(null)):r.isError&&t(null))},[e,r.isSuccess,r.isError,r.data]),{execute:N.useCallback(i=>{t(i)},[])}}const i_="widget-download",Hye="widget-download-csv-file";function QM({baseHeaderConfig:e,enabled:t,onClick:r}){const{t:n}=O.useTranslation();return N.useMemo(()=>{var u,c,d,h,p;if(!t)return e;const i={id:Hye,caption:n("widgetHeader.menu.csvFile"),onClick:r},a=(d=(c=(u=e.toolbar)==null?void 0:u.menu)==null?void 0:c.items)!=null?d:[],o=a.findIndex(m=>m.id===i_),s=o>=0?a.map((m,g)=>{var b;return g===o?z(D({},m),{items:[...(b=m.items)!=null?b:[],i]}):m}):[...a,{id:i_,caption:n("widgetHeader.menu.download"),items:[i]}];return z(D({},e),{toolbar:z(D({},e.toolbar),{menu:z(D({},(p=(h=e.toolbar)==null?void 0:h.menu)!=null?p:{}),{items:s})})})},[e,t,r,n])}const Wye="YYYY-MM-DD HH:mm:ss.S";function jye(e){var g,b;const{chartType:t,dataOptions:r,dataSource:n,filters:i,highlights:a,title:o,config:s,baseHeaderConfig:u}=e,c=KM(),d=N.useMemo(()=>{const _=H.isTable(t),{attributes:w,measures:C}=_?X0(ul(r)):Y0(r,t),S=w.map(T=>V.isDimensionalLevelAttribute(T)?T.format(Wye):T);return{dataSource:n,dimensions:S,measures:C,filters:i,highlights:a,ungroup:_,filename:o?`${o}.csv`:void 0}},[t,r,n,i,a,o]),h=d.dimensions.length>0||d.measures.length>0,p=!!((b=(g=s==null?void 0:s.actions)==null?void 0:g.downloadCsv)!=null&&b.enabled)&&h;return{headerConfig:QM({baseHeaderConfig:u,enabled:p,onClick:()=>h&&c.execute(d)})}}const Vye="0,0";function Bm(e){return e.map(t=>{if(!V.isDimensionalLevelAttribute(t)||typeof t.format!="function"||t.getFormat())return t;const r=V.DimensionalLevelAttribute.getDefaultFormatForGranularity(t.granularity);return r?t.format(r):t})}function JM(e){return e.map(t=>typeof t.format!="function"||(typeof t.getFormat=="function"?t.getFormat():void 0)?t:t.format(Vye))}function eP(e){const[t]=JM([E.translateColumnToMeasure(e)]),r="numberFormatConfig"in e?e.numberFormatConfig:void 0;return r?E.safeCombine(t,{excelNumberFormatConfig:r}):t}function tP(e){return e.map(eP)}const Uye="pre",Gye="post";function qye(e){var n,i,a,o,s,u;const t=E.getCompleteNumberFormatConfig(e),r=t.name==="Percent";return D(D(D({type:r?"percent":"number",abbreviations:{k:(n=t.kilo)!=null?n:!1,m:(i=t.million)!=null?i:!1,b:(a=t.billion)!=null?a:!1,t:(o=t.trillion)!=null?o:!1},abbreviateAll:!1,decimals:(s=t.decimalScale)!=null?s:"auto",isdefault:!0},t.thousandSeparator!==void 0&&{number:{separated:t.thousandSeparator},separated:t.thousandSeparator}),t.name==="Currency"&&{currency:{symbol:(u=t.symbol)!=null?u:"",position:t.prefix?Uye:Gye}}),r&&{percent:!0})}const Yye="export",a_={type:"number",abbreviations:{t:!1,b:!1,m:!1,k:!1},abbreviateAll:!1,separated:!0,decimals:"auto",isdefault:!0};function Xye(e){const t=e.match(/\.(0+)/);return t?t[1].length:"auto"}function Zye(e,t){const{format:r,jaql:n}=e;if(n.datatype==="datetime")return r!=null?r:{};if(n.datatype!=="numeric"&&!n.agg)return{};if(t)return{mask:qye(t)};if(!r)return{};if(r.mask&&typeof r.mask=="object")return{mask:Pf(r.mask)};if(typeof r.number=="string"){const i=Xye(r.number),a=r.number.includes(",");return r.number.includes("%")?{mask:Pf({type:"percent",percent:!0,separated:a,decimals:i})}:{mask:Pf({separated:a,decimals:i})}}return{}}function Pf(e){const t=e.abbreviations;return D(D(D({},a_),e),t&&typeof t=="object"?{abbreviations:D(D({},a_.abbreviations),t)}:{})}function Kye(){return V.v4()}function Qye(e,t){return t&&e.panel==="columns"?"columns":"rows"}function o_({jaqlItem:e,formatItem:t,panel:r,merged:n,extraJaql:i={},id:a,index:o,numberFormatConfig:s}){return{jaql:z(D({},i),{column:e.title,title:e.title,dim:e.dim,merged:n}),field:{id:a,index:o},format:Zye(t!=null?t:{jaql:e,format:void 0},s),panel:r}}function Jye(e,t,r){var o,s;const n=(o=e==null?void 0:e.map((u,c)=>{const d=u.jaql(),h=d.jaql,{level:p,dateTimeLevel:m,bucket:g}=h,b=D(D(D({},p!==void 0&&{level:p}),m!==void 0&&{dateTimeLevel:m}),g!==void 0&&{bucket:g});return o_({jaqlItem:h,formatItem:d,panel:Qye(u,r),merged:!!u.merged,extraJaql:b,id:u.id,index:c})}))!=null?o:[],i=n.length,a=(s=t==null?void 0:t.map((u,c)=>{const d=u.jaql(),h=d.jaql,p=u.excelNumberFormatConfig;return o_({jaqlItem:h,formatItem:d,panel:"measures",merged:!!h.agg,extraJaql:{agg:h.agg},id:u.id,index:i+c,numberFormatConfig:p})}))!=null?s:[];return[...n,...a]}function ebe(e,t){const r=e.jaql(),n=i=>z(D({},i),{panel:"scope"});return t?Array.isArray(r)?r.map(i=>n(z(D({},i),{instanceid:e.config.guid}))):n(z(D({},r),{instanceid:e.config.guid})):Array.isArray(r)?r.map(n):n(r)}function tbe(e){var t;return Object.keys((t=e.jaql.filter)!=null?t:{}).length>0}function rbe(e){const{filters:t,relations:r}=V.getFilterListAndRelationsJaql(e);return[...t!=null?t:[]].flatMap(n=>ebe(n,r)).filter(tbe)}function nbe(e,t){const{dimensions:r,measures:n,filters:i}=e,a=Jye(r,n,t.mergeRows),o=rbe(i);return{datasource:V.convertJaqlDataSource(t.dataSource),widget:`${t.widgetOid};${t.widgetTitle}`,queryGuid:Kye(),metadata:[...a,...o],mergeRows:t.mergeRows,count:-1,by:Yye,ungroup:!1}}function ibe(e,t,r){return{widgetId:e.widgetId,widgetType:e.widgetType,jaql:t,mergeRows:r,language:e.language,widgetStyles:{coloringRules:{alternatingRows:!0}}}}function s_(e,t){return y.dataLoadStateReducer(e,t)}function abe(e){const t=y.useHasChanged(e,["mergeRows","exportRunId","widgetId","widgetTitle","widgetType"]),r=y.useQueryParamsChanged(e);return t||r}function obe(e,t,r,n,i){var c;const{dimensions:a,measures:o,filters:s}=e,u=nbe({dimensions:a,measures:o,filters:s},{widgetOid:n,widgetTitle:(c=e.widgetTitle)!=null?c:"",dataSource:i,mergeRows:e.mergeRows});return ibe({widgetId:n,widgetType:r,language:t},u,e.mergeRows)}function sbe(e,t,r){var c,d;const n=r.widgetType;if(!n){e({type:"error",error:new Error("Excel export requires widgetType (e.g. ChartWidget `chartType`).")});return}const i=r.widgetId;if(!i){e({type:"error",error:new Error("Excel export requires widgetId (e.g. ChartWidget `id` when rendered via `Widget` / dashboard).")});return}e({type:"loading"});const a=t==null?void 0:t.httpClient;if(!a){e({type:"error",error:new V.TranslatableError("errors.executeQueryNoSisenseContext")});return}const o=(c=r.dataSource)!=null?c:t==null?void 0:t.defaultDataSource;if(!o){e({type:"error",error:new V.TranslatableError("errors.executeQueryNoDataSource")});return}const s=(d=t==null?void 0:t.settings.translationConfig.language)!=null?d:"en-US",u=obe(r,s,n,i,o);new Kc(a).exportJaqlToXlsx(u).then(h=>{if(!h||h.size===0){e({type:"error",error:new Error("Excel export returned an empty file.")});return}e({type:"success",data:h})}).catch(h=>{e({type:"error",error:h})})}function lbe(e){const t=abe(e),[r,n]=N.useReducer(s_,{isLoading:!0,isError:!1,isSuccess:!1,status:"loading",error:void 0,data:void 0}),{isInitialized:i,app:a}=y.useSisenseContext();return N.useEffect(()=>{let o=!1;const s=u=>{o||n(u)};return e.enabled?i?(sbe(s,a,e),()=>{o=!0}):(s({type:"error",error:new V.TranslatableError("errors.executeQueryNoSisenseContext")}),()=>{o=!0}):()=>{o=!0}},[a,i,e]),r.data&&t?s_(r,{type:"loading"}):r}const ube="data.xlsx",cbe={dimensions:[],measures:[],mergeRows:!1,enabled:!1};function rP(){const[e,t]=N.useState(null),r=N.useRef(0),n=N.useMemo(()=>{var o;return z(D(D({},cbe),e!=null?e:{}),{enabled:!!e,mergeRows:(o=e==null?void 0:e.mergeRows)!=null?o:!1})},[e]),i=lbe(n);return N.useEffect(()=>{var o;e&&(i.isSuccess&&i.data?(Wg(i.data,jg((o=e.filename)!=null?o:ube)),t(null)):i.isError&&t(null))},[e,i.isSuccess,i.isError,i.data]),{execute:N.useCallback(o=>{r.current+=1,t(z(D({},o),{exportRunId:r.current}))},[])}}const l_="widget-download",u_="excelFileMenuItem",dbe="downloadExcelRepeatRows",hbe="downloadExcelMergeRows";function nP({baseHeaderConfig:e,enabled:t,onDownloadExcel:r}){const{t:n}=O.useTranslation();return N.useMemo(()=>{var d,h,p,m,g;if(!t)return e;const i={id:dbe,caption:n("widgetHeader.menu.repeatRowsRecommended"),onClick:()=>r(!1)},a={id:hbe,caption:n("widgetHeader.menu.mergeRows"),onClick:()=>r(!0)},o={id:u_,caption:n("widgetHeader.menu.excelFile"),items:[i,a]},s=(p=(h=(d=e.toolbar)==null?void 0:d.menu)==null?void 0:h.items)!=null?p:[],u=s.findIndex(b=>b.id===l_),c=u>=0?s.map((b,_)=>{var w;return _===u?z(D({},b),{items:[...((w=b.items)!=null?w:[]).filter(C=>C.id!==u_),o]}):b}):[...s,{id:l_,caption:n("widgetHeader.menu.download"),items:[o]}];return z(D({},e),{toolbar:z(D({},e.toolbar),{menu:z(D({},(g=(m=e.toolbar)==null?void 0:m.menu)!=null?g:{}),{items:c})})})},[e,t,r,n])}function fbe(e){var _,w,C,S;const{chartType:t,dataOptions:r,dataSource:n,title:i,config:a,baseHeaderConfig:o,id:s,filters:u}=e,c=rP(),d=!!((w=(_=a==null?void 0:a.actions)==null?void 0:_.downloadExcel)!=null&&w.enabled),h=N.useMemo(()=>{if(!d)return{dataSource:n,dimensions:[],measures:[],ungroup:!1,filename:i?`${i}.xlsx`:void 0,widgetType:t,widgetId:s,widgetTitle:i!=null?i:""};const T=H.isTable(t),{attributes:M,measures:P}=T?(()=>{const R=ul(r),k=[],I=[];for(const $ of R.columns)E.isMeasureColumn($)?I.push($):k.push(E.translateColumnToAttribute($));return{attributes:Bm(k),measures:tP(I)}})():Y0(r,t);return{dataSource:n,dimensions:Bm(M),measures:T?P:JM(P),ungroup:!1,filename:i?`${i}.xlsx`:void 0,widgetType:t,widgetId:s,widgetTitle:i!=null?i:""}},[t,r,n,d,s,i]),p=h.dimensions.length>0||h.measures.length>0,m=!!((S=(C=a==null?void 0:a.actions)==null?void 0:C.downloadExcel)!=null&&S.enabled)&&p,g=N.useCallback(T=>{!m||!p||c.execute(z(D({},h),{mergeRows:T,filters:u}))},[c,h,u,p,m]);return{headerConfig:nP({baseHeaderConfig:o,enabled:m,onDownloadExcel:g})}}function iP({onClick:e,isVisible:t}){var o,s;const{themeSettings:r}=y.useThemeContext(),{t:n}=O.useTranslation(),i=r.widget.header.titleTextColor,a=n(t?"ai.buttons.hideNarrative":"ai.buttons.generateNarrative");return O.jsx(Ii,{title:a,style:{color:(o=r.chart)==null?void 0:o.textColor,fontFamily:(s=r.typography)==null?void 0:s.fontFamily},children:O.jsx(vn,{onClick:e,sx:D({p:0},O.MIN_TOUCH_TARGET_SIZE),"data-testid":"widget-narrative-trigger-button",children:t?O.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:[O.jsx("path",{d:"M15.7324 17.2959C16.0276 17.2959 16.2674 17.535 16.2676 17.8301C16.2676 18.1254 16.0277 18.3652 15.7324 18.3652H3.96973C3.67445 18.3652 3.43555 18.1254 3.43555 17.8301C3.43575 17.535 3.67458 17.2959 3.96973 17.2959H15.7324Z",fill:i}),O.jsx("path",{d:"M11.5049 14.0879C11.8 14.088 12.0389 14.327 12.0391 14.6221C12.0391 14.9173 11.8001 15.1571 11.5049 15.1572H3.96973C3.67445 15.1572 3.43555 14.9174 3.43555 14.6221C3.43572 14.3269 3.67456 14.0879 3.96973 14.0879H11.5049Z",fill:i}),O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.6396 3.75977C15.6769 3.76034 15.7165 3.76229 15.7568 3.76562L15.8818 3.78125L15.9658 3.7998C16.0496 3.82327 16.1309 3.86143 16.2061 3.91699C16.2536 3.95218 16.2931 3.9906 16.3262 4.02832L16.4082 4.13574L16.4717 4.24316C16.5317 4.35233 16.5822 4.46842 16.625 4.57812L16.7598 4.9541L16.9766 5.57324C17.0531 5.79645 17.1335 6.02839 17.2188 6.25391C17.3957 6.72219 17.5715 7.10258 17.7373 7.31055C17.8204 7.41478 18.0107 7.54958 18.333 7.70117C18.6414 7.84617 19.0096 7.97901 19.3906 8.11035C19.7599 8.23765 20.1532 8.36695 20.4668 8.49414C20.6249 8.55827 20.78 8.6291 20.9131 8.70703C21.0352 8.77855 21.1913 8.88626 21.2969 9.04492C21.3413 9.11166 21.4879 9.33064 21.4043 9.62402C21.367 9.75388 21.294 9.85006 21.2373 9.91113C21.1782 9.97469 21.1118 10.0279 21.0508 10.0703C20.9294 10.1546 20.7813 10.2315 20.6318 10.3008C20.3305 10.4405 19.9434 10.5842 19.5664 10.7217C19.1803 10.8625 18.7995 10.9984 18.4775 11.1299C18.1338 11.2703 17.9384 11.3748 17.8711 11.4336C17.7496 11.5399 17.6097 11.7511 17.46 12.0762C17.3151 12.3908 17.1843 12.7601 17.0547 13.1396C16.929 13.5078 16.8004 13.8975 16.6709 14.2109C16.6056 14.3689 16.5338 14.5249 16.4521 14.6592C16.3755 14.7852 16.2634 14.938 16.1025 15.042L15.9795 15.1211L15.834 15.1221L15.6484 15.1113C15.5939 15.1049 15.4886 15.091 15.3789 15.04C15.2863 14.9969 15.2128 14.9386 15.1533 14.874L15.0986 14.8076C14.9821 14.6521 14.9046 14.4792 14.8496 14.3369C14.8066 14.2257 14.7369 14.018 14.7129 13.9531C14.6476 13.7766 14.5747 13.561 14.499 13.3408C14.4223 13.1174 14.3408 12.8828 14.2549 12.6543C14.0755 12.1774 13.8997 11.7923 13.7432 11.5938C13.6511 11.4771 13.4564 11.3375 13.1406 11.1865C12.836 11.0409 12.4741 10.9098 12.0986 10.7812C11.7353 10.6569 11.3452 10.5303 11.0332 10.4053C10.8755 10.3421 10.7201 10.2729 10.5859 10.1953C10.4602 10.1226 10.308 10.0169 10.2002 9.86523C10.1447 9.7871 10.0907 9.68855 10.0664 9.56348C10.0438 9.44657 10.0546 9.34408 10.0635 9.28125L10.0801 9.16504L10.1455 9.06934C10.2472 8.92004 10.395 8.81577 10.5117 8.74512C10.6383 8.66847 10.7856 8.59777 10.9365 8.5332C11.2376 8.40446 11.6102 8.27492 11.9688 8.14844C12.3365 8.01873 12.6973 7.8895 13.0078 7.75488C13.3299 7.6152 13.5426 7.49139 13.6494 7.3916C13.7519 7.29577 13.882 7.09108 14.0283 6.76465C14.1687 6.45142 14.301 6.08302 14.4316 5.70605C14.5588 5.33924 14.6874 4.95438 14.8145 4.64746C14.8783 4.4933 14.9486 4.34186 15.0254 4.21289C15.095 4.09606 15.2033 3.94017 15.3643 3.83789L15.4902 3.75781L15.6396 3.75977ZM15.7305 5.04785C15.6202 5.31696 15.5067 5.65605 15.376 6.0332C15.2459 6.40844 15.101 6.81555 14.9404 7.17383C14.7858 7.51876 14.5898 7.88226 14.332 8.12305C14.0913 8.34782 13.7412 8.52718 13.4053 8.67285C13.0578 8.8235 12.6644 8.96288 12.3018 9.09082C11.9336 9.22069 11.6006 9.33643 11.3379 9.44824C11.3596 9.45734 11.3817 9.46807 11.4053 9.47754C11.6856 9.58986 12.0316 9.70135 12.4219 9.83496C12.7998 9.96435 13.2106 10.1113 13.5723 10.2842C13.9229 10.4518 14.2897 10.6722 14.5283 10.9746C14.7932 11.3105 15.0156 11.8343 15.1914 12.3018C15.2829 12.5452 15.3683 12.7923 15.4453 13.0166C15.5235 13.2441 15.5913 13.444 15.6514 13.6064C15.6926 13.7179 15.7132 13.7801 15.7373 13.8496C15.7402 13.8428 15.7442 13.8361 15.7471 13.8291C15.861 13.5534 15.975 13.2069 16.1084 12.8164C16.2379 12.4373 16.3831 12.0236 16.5518 11.6572C16.7157 11.3013 16.9274 10.9315 17.2129 10.6816C17.4251 10.496 17.7768 10.3359 18.0996 10.2041C18.4444 10.0633 18.8511 9.91845 19.2246 9.78223C19.5633 9.65871 19.8722 9.5392 20.1172 9.43164C20.1085 9.42808 20.0997 9.42452 20.0908 9.4209C19.8098 9.30693 19.4581 9.19136 19.0645 9.05566C18.6828 8.92409 18.2691 8.77567 17.9072 8.60547C17.6027 8.46225 17.2821 8.28011 17.0498 8.04004L16.9561 7.93359C16.6815 7.58929 16.459 7.07278 16.2832 6.60742C16.1921 6.36626 16.1071 6.12142 16.0303 5.89746C15.9525 5.67056 15.8844 5.46912 15.8223 5.30078L15.7305 5.04785Z",fill:i}),O.jsx("path",{d:"M8.49121 10.8799C8.78623 10.8801 9.02525 11.119 9.02539 11.4141C9.02539 11.7092 8.78631 11.949 8.49121 11.9492H3.96973C3.67445 11.9492 3.43555 11.7093 3.43555 11.4141C3.43568 11.1189 3.67454 10.8799 3.96973 10.8799H8.49121Z",fill:i}),O.jsx("path",{d:"M7.48723 19.7499C7.32796 19.9502 7.03648 19.9834 6.83619 19.8241C6.6359 19.6649 6.60264 19.3734 6.76191 19.1731L18.3716 4.57324C18.5309 4.37295 18.8224 4.3397 19.0227 4.49897C19.223 4.65824 19.2562 4.94972 19.097 5.15001L7.48723 19.7499Z",fill:i}),O.jsx("path",{d:"M8.29204 20.2294C8.13277 20.4296 7.84129 20.4629 7.641 20.3036C7.44071 20.1444 7.40745 19.8529 7.56672 19.6526L19.1765 5.05274C19.3357 4.85244 19.6272 4.81919 19.8275 4.97846C20.0278 5.13773 20.061 5.42921 19.9018 5.6295L8.29204 20.2294Z",fill:"white"})]}):O.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:[O.jsx("path",{d:"M15.7327 17.2958C16.028 17.2958 16.2674 17.5352 16.2674 17.8305C16.2674 18.1257 16.028 18.3651 15.7327 18.3651H3.96977C3.67447 18.3651 3.43509 18.1257 3.43509 17.8305C3.43509 17.5352 3.67447 17.2958 3.96977 17.2958H15.7327Z",fill:i}),O.jsx("path",{d:"M11.5047 14.0877C11.8 14.0877 12.0393 14.3271 12.0393 14.6224C12.0393 14.9177 11.8 15.1571 11.5047 15.1571H3.96977C3.67447 15.1571 3.43509 14.9177 3.43509 14.6224C3.43509 14.3271 3.67447 14.0877 3.96977 14.0877H11.5047Z",fill:i}),O.jsx("path",{d:"M8.49079 10.8796C8.78608 10.8796 9.02547 11.119 9.02547 11.4143C9.02547 11.7096 8.78608 11.949 8.49079 11.949H3.96977C3.67447 11.949 3.43509 11.7096 3.43509 11.4143C3.43509 11.119 3.67447 10.8796 3.96977 10.8796H8.49079Z",fill:i}),O.jsx("path",{d:"M15.6395 3.76001C15.6768 3.76059 15.7164 3.76253 15.7567 3.76587L15.8817 3.78149L15.9657 3.80005C16.0495 3.82352 16.1307 3.86165 16.2059 3.91724C16.2536 3.95245 16.2929 3.99082 16.3261 4.02856L16.4081 4.13599V4.13696L16.4716 4.24341C16.5316 4.35263 16.5821 4.46861 16.6249 4.57837L16.7597 4.95435L16.9764 5.57349C17.053 5.79675 17.1334 6.02858 17.2186 6.25415C17.3956 6.72251 17.5713 7.10285 17.7372 7.31079C17.8203 7.41503 18.0106 7.54982 18.3329 7.70142C18.6413 7.84642 19.0095 7.97925 19.3905 8.1106C19.7598 8.2379 20.153 8.36719 20.4667 8.49438C20.6248 8.55852 20.7799 8.62934 20.913 8.70728C21.0351 8.77881 21.1912 8.88644 21.2968 9.04517H21.2977C21.3422 9.11193 21.4879 9.33075 21.4042 9.62427V9.62524C21.3669 9.75523 21.294 9.85031 21.2372 9.91138C21.178 9.975 21.1117 10.0282 21.0507 10.0706C20.9292 10.1549 20.7813 10.2317 20.6317 10.301C20.3303 10.4407 19.9433 10.5844 19.5663 10.7219C19.1801 10.8628 18.7994 10.9986 18.4774 11.1301C18.1334 11.2706 17.9381 11.3751 17.871 11.4338C17.7495 11.5402 17.6096 11.7512 17.4598 12.0764C17.315 12.3911 17.1842 12.7602 17.0546 13.1399C16.9288 13.5081 16.8004 13.8977 16.6708 14.2112C16.6054 14.3693 16.5337 14.5251 16.452 14.6594C16.3754 14.7855 16.2634 14.9382 16.1024 15.0422L15.9794 15.1213L15.8339 15.1223L15.6483 15.1116C15.5938 15.1051 15.4885 15.0913 15.3788 15.0403C15.2862 14.9972 15.2127 14.9388 15.1532 14.8743L15.0985 14.8079C14.982 14.6523 14.9045 14.4794 14.8495 14.3372C14.8065 14.226 14.7368 14.0183 14.7128 13.9534C14.6475 13.7768 14.5746 13.5613 14.4989 13.3411C14.4222 13.1176 14.3407 12.8832 14.2548 12.6545C14.0754 12.1776 13.8996 11.7925 13.7431 11.594C13.651 11.4773 13.4564 11.3378 13.1405 11.1868C12.8359 11.0412 12.474 10.9101 12.0985 10.7815C11.7352 10.6571 11.3451 10.5306 11.0331 10.4055C10.8754 10.3423 10.72 10.2732 10.5858 10.1956C10.4601 10.1228 10.3078 10.0172 10.2001 9.86548C10.1446 9.78733 10.0906 9.68886 10.0663 9.56372C10.0436 9.44672 10.0545 9.34437 10.0634 9.28149L10.08 9.16528L10.1454 9.06958C10.2471 8.92017 10.3949 8.81605 10.5116 8.74536C10.6383 8.66867 10.7854 8.59805 10.9364 8.53345C11.2375 8.40468 11.61 8.27519 11.9686 8.14868C12.3364 8.01895 12.6972 7.88977 13.0077 7.75513C13.3299 7.61541 13.5424 7.49165 13.6493 7.39185C13.7518 7.29608 13.8818 7.09151 14.0282 6.76489C14.1686 6.45161 14.3008 6.08336 14.4315 5.7063C14.5587 5.33941 14.6872 4.9547 14.8143 4.64771C14.8782 4.49346 14.9484 4.34217 15.0253 4.21313C15.0949 4.09628 15.2031 3.94048 15.3641 3.83813L15.4901 3.75806L15.6395 3.76001ZM15.7304 5.0481C15.62 5.31726 15.5066 5.6562 15.3759 6.03345C15.2458 6.40877 15.1009 6.81573 14.9403 7.17407C14.7857 7.51908 14.5898 7.88251 14.3319 8.12329C14.0911 8.3481 13.7412 8.52741 13.4052 8.6731C13.0576 8.82376 12.6644 8.96311 12.3016 9.09106C11.9334 9.22096 11.6005 9.33665 11.3378 9.44849C11.3595 9.45759 11.3815 9.46832 11.4052 9.47778C11.6854 9.59011 12.0314 9.70159 12.4218 9.83521C12.7997 9.96459 13.2104 10.1115 13.5722 10.2844C13.9228 10.452 14.2896 10.6724 14.5282 10.9749C14.7931 11.3108 15.0155 11.8345 15.1913 12.302C15.2829 12.5455 15.3681 12.7925 15.4452 13.0168C15.5234 13.2444 15.5912 13.4442 15.6513 13.6067C15.6925 13.7182 15.7131 13.7803 15.7372 13.8499C15.7401 13.843 15.744 13.8364 15.747 13.8293C15.8609 13.5536 15.9749 13.2073 16.1083 12.8167C16.2378 12.4375 16.3829 12.024 16.5516 11.6575C16.7156 11.3014 16.9272 10.9318 17.2128 10.6819C17.4249 10.4962 17.7766 10.3362 18.0995 10.2043C18.4443 10.0635 18.8509 9.91872 19.2245 9.78247C19.5632 9.65893 19.8721 9.53946 20.1171 9.43188C20.1084 9.42832 20.0996 9.42476 20.0907 9.42114C19.8097 9.30717 19.458 9.1916 19.0643 9.05591C18.6827 8.92433 18.2691 8.77591 17.9071 8.60547C17.6026 8.46225 17.2821 8.28011 17.0497 8.04004L16.9559 7.93359C16.6813 7.58929 16.459 7.07278 16.2831 6.60742C16.1919 6.36626 16.107 6.12142 16.0302 5.89746C15.9523 5.67056 15.8843 5.46912 15.8222 5.30078L15.7304 5.0481Z",fill:i})]})})})}function Xi(e){var t;return(t=e.config)==null?void 0:t.narrative}function pbe(e){if(!(typeof e!="number"||!Number.isFinite(e))){if(e<0||e>1){console.error(`[WidgetNarrative] heightFraction must be in the range [0, 1], got ${e}. The value will be ignored.`);return}return e}}function Bi(e){var t,r,n,i,a,o,s;return{enabled:(t=e==null?void 0:e.enabled)!=null?t:!1,verbosity:(r=e==null?void 0:e.verbosity)!=null?r:"low",displayLocation:(n=e==null?void 0:e.displayLocation)!=null?n:"above",autoShow:(i=e==null?void 0:e.autoShow)!=null?i:!0,includeTrendAndForecast:(a=e==null?void 0:e.includeTrendAndForecast)!=null?a:!0,feedback:{enabled:(s=(o=e==null?void 0:e.feedback)==null?void 0:o.enabled)!=null?s:!1},heightFraction:pbe(e==null?void 0:e.heightFraction)}}class To{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){const r={listener:t};return this.listeners.add(r),this.onSubscribe(),()=>{this.listeners.delete(r),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}}const Us=typeof window=="undefined"||"Deno"in window;function Nr(){}function mbe(e,t){return typeof e=="function"?e(t):e}function zm(e){return typeof e=="number"&&e>=0&&e!==1/0}function aP(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ss(e,t,r){return _l(e)?typeof t=="function"?z(D({},r),{queryKey:e,queryFn:t}):z(D({},t),{queryKey:e}):e}function gbe(e,t,r){return _l(e)?z(D({},t),{mutationKey:e}):typeof e=="function"?z(D({},t),{mutationFn:e}):D({},e)}function Un(e,t,r){return _l(e)?[z(D({},t),{queryKey:e}),r]:[e||{},t]}function c_(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(_l(o)){if(n){if(t.queryHash!==Vg(o,t.options))return!1}else if(!Na(t.queryKey,o))return!1}if(r!=="all"){const u=t.isActive();if(r==="active"&&!u||r==="inactive"&&u)return!1}return!(typeof s=="boolean"&&t.isStale()!==s||typeof i!="undefined"&&i!==t.state.fetchStatus||a&&!a(t))}function d_(e,t){const{exact:r,fetching:n,predicate:i,mutationKey:a}=e;if(_l(a)){if(!t.options.mutationKey)return!1;if(r){if(Ti(t.options.mutationKey)!==Ti(a))return!1}else if(!Na(t.options.mutationKey,a))return!1}return!(typeof n=="boolean"&&t.state.status==="loading"!==n||i&&!i(t))}function Vg(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ti)(e)}function Ti(e){return JSON.stringify(e,(t,r)=>Hm(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function Na(e,t){return oP(e,t)}function oP(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(r=>!oP(e[r],t[r])):!1}function sP(e,t,r=0){if(e===t)return e;if(r>500)return t;const n=h_(e)&&h_(t);if(n||Hm(e)&&Hm(t)){const i=n?e.length:Object.keys(e).length,a=n?t:Object.keys(t),o=a.length,s=n?[]:{};let u=0;for(let c=0;c<o;c++){const d=n?c:a[c];s[d]=sP(e[d],t[d],r+1),s[d]===e[d]&&u++}return i===o&&u===i?e:s}return t}function wc(e,t){if(e&&!t||t&&!e)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function h_(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Hm(e){if(!f_(e))return!1;const t=e.constructor;if(typeof t=="undefined")return!0;const r=t.prototype;return!(!f_(r)||!r.hasOwnProperty("isPrototypeOf"))}function f_(e){return Object.prototype.toString.call(e)==="[object Object]"}function _l(e){return Array.isArray(e)}function lP(e){return new Promise(t=>{setTimeout(t,e)})}function p_(e){lP(0).then(e)}function vbe(){if(typeof AbortController=="function")return new AbortController}function Wm(e,t,r){return r.isDataEqual!=null&&r.isDataEqual(e,t)?e:typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?sP(e,t):t}class ybe extends To{constructor(){super(),this.setup=t=>{if(!Us&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),window.addEventListener("focus",r,!1),()=>{window.removeEventListener("visibilitychange",r),window.removeEventListener("focus",r)}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var t;(t=this.cleanup)==null||t.call(this),this.cleanup=void 0}}setEventListener(t){var r;this.setup=t,(r=this.cleanup)==null||r.call(this),this.cleanup=t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()})}setFocused(t){this.focused!==t&&(this.focused=t,this.onFocus())}onFocus(){this.listeners.forEach(({listener:t})=>{t()})}isFocused(){return typeof this.focused=="boolean"?this.focused:typeof document=="undefined"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)}}const Cc=new ybe,m_=["online","offline"];class bbe extends To{constructor(){super(),this.setup=t=>{if(!Us&&window.addEventListener){const r=()=>t();return m_.forEach(n=>{window.addEventListener(n,r,!1)}),()=>{m_.forEach(n=>{window.removeEventListener(n,r)})}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var t;(t=this.cleanup)==null||t.call(this),this.cleanup=void 0}}setEventListener(t){var r;this.setup=t,(r=this.cleanup)==null||r.call(this),this.cleanup=t(n=>{typeof n=="boolean"?this.setOnline(n):this.onOnline()})}setOnline(t){this.online!==t&&(this.online=t,this.onOnline())}onOnline(){this.listeners.forEach(({listener:t})=>{t()})}isOnline(){return typeof this.online=="boolean"?this.online:typeof navigator=="undefined"||typeof navigator.onLine=="undefined"?!0:navigator.onLine}}const xc=new bbe;function _be(e){return Math.min(1e3*Gv(2,e),3e4)}function Bd(e){return(e!=null?e:"online")==="online"?xc.isOnline():!0}class uP{constructor(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}}function Gu(e){return e instanceof uP}function cP(e){let t=!1,r=0,n=!1,i,a,o;const s=new Promise((_,w)=>{a=_,o=w}),u=_=>{n||(m(new uP(_)),e.abort==null||e.abort())},c=()=>{t=!0},d=()=>{t=!1},h=()=>!Cc.isFocused()||e.networkMode!=="always"&&!xc.isOnline(),p=_=>{n||(n=!0,e.onSuccess==null||e.onSuccess(_),i==null||i(),a(_))},m=_=>{n||(n=!0,e.onError==null||e.onError(_),i==null||i(),o(_))},g=()=>new Promise(_=>{i=w=>{const C=n||!h();return C&&_(w),C},e.onPause==null||e.onPause()}).then(()=>{i=void 0,n||e.onContinue==null||e.onContinue()}),b=()=>{if(n)return;let _;try{_=e.fn()}catch(w){_=Promise.reject(w)}Promise.resolve(_).then(p).catch(w=>{var C,S;if(n)return;const T=(C=e.retry)!=null?C:3,M=(S=e.retryDelay)!=null?S:_be,P=typeof M=="function"?M(r,w):M,R=T===!0||typeof T=="number"&&r<T||typeof T=="function"&&T(r,w);if(t||!R){m(w);return}r++,e.onFail==null||e.onFail(r,w),lP(P).then(()=>{if(h())return g()}).then(()=>{t?m(w):b()})})};return Bd(e.networkMode)?b():g().then(b),{promise:s,cancel:u,continue:()=>(i==null?void 0:i())?s:Promise.resolve(),cancelRetry:c,continueRetry:d}}const Ug=console;function wbe(){let e=[],t=0,r=d=>{d()},n=d=>{d()};const i=d=>{let h;t++;try{h=d()}finally{t--,t||s()}return h},a=d=>{t?e.push(d):p_(()=>{r(d)})},o=d=>(...h)=>{a(()=>{d(...h)})},s=()=>{const d=e;e=[],d.length&&p_(()=>{n(()=>{d.forEach(h=>{r(h)})})})};return{batch:i,batchCalls:o,schedule:a,setNotifyFunction:d=>{r=d},setBatchNotifyFunction:d=>{n=d}}}const yt=wbe();class dP{destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),zm(this.cacheTime)&&(this.gcTimeout=setTimeout(()=>{this.optionalRemove()},this.cacheTime))}updateCacheTime(t){this.cacheTime=Math.max(this.cacheTime||0,t!=null?t:Us?1/0:5*60*1e3)}clearGcTimeout(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)}}class Cbe extends dP{constructor(t){super(),this.abortSignalConsumed=!1,this.defaultOptions=t.defaultOptions,this.setOptions(t.options),this.observers=[],this.cache=t.cache,this.logger=t.logger||Ug,this.queryKey=t.queryKey,this.queryHash=t.queryHash,this.initialState=t.state||xbe(this.options),this.state=this.initialState,this.scheduleGc()}get meta(){return this.options.meta}setOptions(t){this.options=D(D({},this.defaultOptions),t),this.updateCacheTime(this.options.cacheTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.cache.remove(this)}setData(t,r){const n=Wm(this.state.data,t,this.options);return this.dispatch({data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){this.dispatch({type:"setState",state:t,setStateOptions:r})}cancel(t){var r;const n=this.promise;return(r=this.retryer)==null||r.cancel(t),n?n.then(Nr).catch(Nr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.initialState)}isActive(){return this.observers.some(t=>t.options.enabled!==!1)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(t=>t.getCurrentResult().isStale)}isStaleByTime(t=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!aP(this.state.dataUpdatedAt,t)}onFocus(){var t;const r=this.observers.find(n=>n.shouldFetchOnWindowFocus());r&&r.refetch({cancelRefetch:!1}),(t=this.retryer)==null||t.continue()}onOnline(){var t;const r=this.observers.find(n=>n.shouldFetchOnReconnect());r&&r.refetch({cancelRefetch:!1}),(t=this.retryer)==null||t.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(this.retryer&&(this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.scheduleGc()),this.cache.notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.dispatch({type:"invalidate"})}fetch(t,r){var n,i;if(this.state.fetchStatus!=="idle"){if(this.state.dataUpdatedAt&&r!=null&&r.cancelRefetch)this.cancel({silent:!0});else if(this.promise){var a;return(a=this.retryer)==null||a.continueRetry(),this.promise}}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(g=>g.options.queryFn);m&&this.setOptions(m.options)}process.env.NODE_ENV!=="production"&&(Array.isArray(this.options.queryKey)||this.logger.error("As of v4, queryKey needs to be an Array. If you are using a string like 'repoData', please change it to an Array, e.g. ['repoData']"));const o=vbe(),s={queryKey:this.queryKey,pageParam:void 0,meta:this.meta},u=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>{if(o)return this.abortSignalConsumed=!0,o.signal}})};u(s);const c=()=>this.options.queryFn?(this.abortSignalConsumed=!1,this.options.queryFn(s)):Promise.reject("Missing queryFn for queryKey '"+this.options.queryHash+"'"),d={fetchOptions:r,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:c};if(u(d),(n=this.options.behavior)==null||n.onFetch(d),this.revertState=this.state,this.state.fetchStatus==="idle"||this.state.fetchMeta!==((i=d.fetchOptions)==null?void 0:i.meta)){var h;this.dispatch({type:"fetch",meta:(h=d.fetchOptions)==null?void 0:h.meta})}const p=m=>{if(Gu(m)&&m.silent||this.dispatch({type:"error",error:m}),!Gu(m)){var g,b,_,w;(g=(b=this.cache.config).onError)==null||g.call(b,m,this),(_=(w=this.cache.config).onSettled)==null||_.call(w,this.state.data,m,this),process.env.NODE_ENV!=="production"&&this.logger.error(m)}this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.retryer=cP({fn:d.fetchFn,abort:o==null?void 0:o.abort.bind(o),onSuccess:m=>{var g,b,_,w;if(typeof m=="undefined"){process.env.NODE_ENV!=="production"&&this.logger.error("Query data cannot be undefined. Please make sure to return a value other than undefined from your query function. Affected query key: "+this.queryHash),p(new Error(this.queryHash+" data is undefined"));return}this.setData(m),(g=(b=this.cache.config).onSuccess)==null||g.call(b,m,this),(_=(w=this.cache.config).onSettled)==null||_.call(w,m,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError:p,onFail:(m,g)=>{this.dispatch({type:"failed",failureCount:m,error:g})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:d.options.retry,retryDelay:d.options.retryDelay,networkMode:d.options.networkMode}),this.promise=this.retryer.promise,this.promise}dispatch(t){const r=n=>{var i,a;switch(t.type){case"failed":return z(D({},n),{fetchFailureCount:t.failureCount,fetchFailureReason:t.error});case"pause":return z(D({},n),{fetchStatus:"paused"});case"continue":return z(D({},n),{fetchStatus:"fetching"});case"fetch":return D(z(D({},n),{fetchFailureCount:0,fetchFailureReason:null,fetchMeta:(i=t.meta)!=null?i:null,fetchStatus:Bd(this.options.networkMode)?"fetching":"paused"}),!n.dataUpdatedAt&&{error:null,status:"loading"});case"success":return D(z(D({},n),{data:t.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:(a=t.dataUpdatedAt)!=null?a:Date.now(),error:null,isInvalidated:!1,status:"success"}),!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null});case"error":const o=t.error;return Gu(o)&&o.revert&&this.revertState?z(D({},this.revertState),{fetchStatus:"idle"}):z(D({},n),{error:o,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"});case"invalidate":return z(D({},n),{isInvalidated:!0});case"setState":return D(D({},n),t.state)}};this.state=r(this.state),yt.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate(t)}),this.cache.notify({query:this,type:"updated",action:t})})}}function xbe(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=typeof t!="undefined",n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n!=null?n:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"loading",fetchStatus:"idle"}}class Tbe extends To{constructor(t){super(),this.config=t||{},this.queries=[],this.queriesMap={}}build(t,r,n){var i;const a=r.queryKey,o=(i=r.queryHash)!=null?i:Vg(a,r);let s=this.get(o);return s||(s=new Cbe({cache:this,logger:t.getLogger(),queryKey:a,queryHash:o,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(a)}),this.add(s)),s}add(t){this.queriesMap[t.queryHash]||(this.queriesMap[t.queryHash]=t,this.queries.push(t),this.notify({type:"added",query:t}))}remove(t){const r=this.queriesMap[t.queryHash];r&&(t.destroy(),this.queries=this.queries.filter(n=>n!==t),r===t&&delete this.queriesMap[t.queryHash],this.notify({type:"removed",query:t}))}clear(){yt.batch(()=>{this.queries.forEach(t=>{this.remove(t)})})}get(t){return this.queriesMap[t]}getAll(){return this.queries}find(t,r){const[n]=Un(t,r);return typeof n.exact=="undefined"&&(n.exact=!0),this.queries.find(i=>c_(n,i))}findAll(t,r){const[n]=Un(t,r);return Object.keys(n).length>0?this.queries.filter(i=>c_(n,i)):this.queries}notify(t){yt.batch(()=>{this.listeners.forEach(({listener:r})=>{r(t)})})}onFocus(){yt.batch(()=>{this.queries.forEach(t=>{t.onFocus()})})}onOnline(){yt.batch(()=>{this.queries.forEach(t=>{t.onOnline()})})}}class Sbe extends dP{constructor(t){super(),this.defaultOptions=t.defaultOptions,this.mutationId=t.mutationId,this.mutationCache=t.mutationCache,this.logger=t.logger||Ug,this.observers=[],this.state=t.state||hP(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=D(D({},this.defaultOptions),t),this.updateCacheTime(this.options.cacheTime)}get meta(){return this.options.meta}setState(t){this.dispatch({type:"setState",state:t})}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),this.mutationCache.notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){this.observers=this.observers.filter(r=>r!==t),this.scheduleGc(),this.mutationCache.notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){this.observers.length||(this.state.status==="loading"?this.scheduleGc():this.mutationCache.remove(this))}continue(){var t,r;return(t=(r=this.retryer)==null?void 0:r.continue())!=null?t:this.execute()}execute(){return ht(this,null,function*(){const t=()=>{var R;return this.retryer=cP({fn:()=>this.options.mutationFn?this.options.mutationFn(this.state.variables):Promise.reject("No mutationFn found"),onFail:(k,I)=>{this.dispatch({type:"failed",failureCount:k,error:I})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:(R=this.options.retry)!=null?R:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.retryer.promise},r=this.state.status==="loading";try{var n,i,a,o,s,u,c,d;if(!r){var h,p,m,g;this.dispatch({type:"loading",variables:this.options.variables}),yield(h=(p=this.mutationCache.config).onMutate)==null?void 0:h.call(p,this.state.variables,this);const k=yield(m=(g=this.options).onMutate)==null?void 0:m.call(g,this.state.variables);k!==this.state.context&&this.dispatch({type:"loading",context:k,variables:this.state.variables})}const R=yield t();return yield(n=(i=this.mutationCache.config).onSuccess)==null?void 0:n.call(i,R,this.state.variables,this.state.context,this),yield(a=(o=this.options).onSuccess)==null?void 0:a.call(o,R,this.state.variables,this.state.context),yield(s=(u=this.mutationCache.config).onSettled)==null?void 0:s.call(u,R,null,this.state.variables,this.state.context,this),yield(c=(d=this.options).onSettled)==null?void 0:c.call(d,R,null,this.state.variables,this.state.context),this.dispatch({type:"success",data:R}),R}catch(R){try{var b,_,w,C,S,T,M,P;throw yield(b=(_=this.mutationCache.config).onError)==null?void 0:b.call(_,R,this.state.variables,this.state.context,this),process.env.NODE_ENV!=="production"&&this.logger.error(R),yield(w=(C=this.options).onError)==null?void 0:w.call(C,R,this.state.variables,this.state.context),yield(S=(T=this.mutationCache.config).onSettled)==null?void 0:S.call(T,void 0,R,this.state.variables,this.state.context,this),yield(M=(P=this.options).onSettled)==null?void 0:M.call(P,void 0,R,this.state.variables,this.state.context),R}finally{this.dispatch({type:"error",error:R})}}})}dispatch(t){const r=n=>{switch(t.type){case"failed":return z(D({},n),{failureCount:t.failureCount,failureReason:t.error});case"pause":return z(D({},n),{isPaused:!0});case"continue":return z(D({},n),{isPaused:!1});case"loading":return z(D({},n),{context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!Bd(this.options.networkMode),status:"loading",variables:t.variables});case"success":return z(D({},n),{data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1});case"error":return z(D({},n),{data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"});case"setState":return D(D({},n),t.state)}};this.state=r(this.state),yt.batch(()=>{this.observers.forEach(n=>{n.onMutationUpdate(t)}),this.mutationCache.notify({mutation:this,type:"updated",action:t})})}}function hP(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0}}class Mbe extends To{constructor(t){super(),this.config=t||{},this.mutations=[],this.mutationId=0}build(t,r,n){const i=new Sbe({mutationCache:this,logger:t.getLogger(),mutationId:++this.mutationId,options:t.defaultMutationOptions(r),state:n,defaultOptions:r.mutationKey?t.getMutationDefaults(r.mutationKey):void 0});return this.add(i),i}add(t){this.mutations.push(t),this.notify({type:"added",mutation:t})}remove(t){this.mutations=this.mutations.filter(r=>r!==t),this.notify({type:"removed",mutation:t})}clear(){yt.batch(()=>{this.mutations.forEach(t=>{this.remove(t)})})}getAll(){return this.mutations}find(t){return typeof t.exact=="undefined"&&(t.exact=!0),this.mutations.find(r=>d_(t,r))}findAll(t){return this.mutations.filter(r=>d_(t,r))}notify(t){yt.batch(()=>{this.listeners.forEach(({listener:r})=>{r(t)})})}resumePausedMutations(){var t;return this.resuming=((t=this.resuming)!=null?t:Promise.resolve()).then(()=>{const r=this.mutations.filter(n=>n.state.isPaused);return yt.batch(()=>r.reduce((n,i)=>n.then(()=>i.continue().catch(Nr)),Promise.resolve()))}).then(()=>{this.resuming=void 0}),this.resuming}}function Pbe(){return{onFetch:e=>{e.fetchFn=()=>{var t,r,n,i,a,o;const s=(t=e.fetchOptions)==null||(r=t.meta)==null?void 0:r.refetchPage,u=(n=e.fetchOptions)==null||(i=n.meta)==null?void 0:i.fetchMore,c=u==null?void 0:u.pageParam,d=(u==null?void 0:u.direction)==="forward",h=(u==null?void 0:u.direction)==="backward",p=((a=e.state.data)==null?void 0:a.pages)||[],m=((o=e.state.data)==null?void 0:o.pageParams)||[];let g=m,b=!1;const _=P=>{Object.defineProperty(P,"signal",{enumerable:!0,get:()=>{var R;if((R=e.signal)!=null&&R.aborted)b=!0;else{var k;(k=e.signal)==null||k.addEventListener("abort",()=>{b=!0})}return e.signal}})},w=e.options.queryFn||(()=>Promise.reject("Missing queryFn for queryKey '"+e.options.queryHash+"'")),C=(P,R,k,I)=>(g=I?[R,...g]:[...g,R],I?[k,...P]:[...P,k]),S=(P,R,k,I)=>{if(b)return Promise.reject("Cancelled");if(typeof k=="undefined"&&!R&&P.length)return Promise.resolve(P);const $={queryKey:e.queryKey,pageParam:k,meta:e.options.meta};_($);const G=w($);return Promise.resolve(G).then(B=>C(P,k,B,I))};let T;if(!p.length)T=S([]);else if(d){const P=typeof c!="undefined",R=P?c:g_(e.options,p);T=S(p,P,R)}else if(h){const P=typeof c!="undefined",R=P?c:Ebe(e.options,p);T=S(p,P,R,!0)}else{g=[];const P=typeof e.options.getNextPageParam=="undefined";T=(s&&p[0]?s(p[0],0,p):!0)?S([],P,m[0]):Promise.resolve(C([],m[0],p[0]));for(let k=1;k<p.length;k++)T=T.then(I=>{if(s&&p[k]?s(p[k],k,p):!0){const G=P?m[k]:g_(e.options,I);return S(I,P,G)}return Promise.resolve(C(I,m[k],p[k]))})}return T.then(P=>({pages:P,pageParams:g}))}}}}function g_(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function Ebe(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}class Abe{constructor(t={}){this.queryCache=t.queryCache||new Tbe,this.mutationCache=t.mutationCache||new Mbe,this.logger=t.logger||Ug,this.defaultOptions=t.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[],this.mountCount=0,process.env.NODE_ENV!=="production"&&t.logger&&this.logger.error("Passing a custom logger has been deprecated and will be removed in the next major version.")}mount(){this.mountCount++,this.mountCount===1&&(this.unsubscribeFocus=Cc.subscribe(()=>{Cc.isFocused()&&(this.resumePausedMutations(),this.queryCache.onFocus())}),this.unsubscribeOnline=xc.subscribe(()=>{xc.isOnline()&&(this.resumePausedMutations(),this.queryCache.onOnline())}))}unmount(){var t,r;this.mountCount--,this.mountCount===0&&((t=this.unsubscribeFocus)==null||t.call(this),this.unsubscribeFocus=void 0,(r=this.unsubscribeOnline)==null||r.call(this),this.unsubscribeOnline=void 0)}isFetching(t,r){const[n]=Un(t,r);return n.fetchStatus="fetching",this.queryCache.findAll(n).length}isMutating(t){return this.mutationCache.findAll(z(D({},t),{fetching:!0})).length}getQueryData(t,r){var n;return(n=this.queryCache.find(t,r))==null?void 0:n.state.data}ensureQueryData(t,r,n){const i=ss(t,r,n),a=this.getQueryData(i.queryKey);return a?Promise.resolve(a):this.fetchQuery(i)}getQueriesData(t){return this.getQueryCache().findAll(t).map(({queryKey:r,state:n})=>{const i=n.data;return[r,i]})}setQueryData(t,r,n){const i=this.queryCache.find(t),a=i==null?void 0:i.state.data,o=mbe(r,a);if(typeof o=="undefined")return;const s=ss(t),u=this.defaultQueryOptions(s);return this.queryCache.build(this,u).setData(o,z(D({},n),{manual:!0}))}setQueriesData(t,r,n){return yt.batch(()=>this.getQueryCache().findAll(t).map(({queryKey:i})=>[i,this.setQueryData(i,r,n)]))}getQueryState(t,r){var n;return(n=this.queryCache.find(t,r))==null?void 0:n.state}removeQueries(t,r){const[n]=Un(t,r),i=this.queryCache;yt.batch(()=>{i.findAll(n).forEach(a=>{i.remove(a)})})}resetQueries(t,r,n){const[i,a]=Un(t,r,n),o=this.queryCache,s=D({type:"active"},i);return yt.batch(()=>(o.findAll(i).forEach(u=>{u.reset()}),this.refetchQueries(s,a)))}cancelQueries(t,r,n){const[i,a={}]=Un(t,r,n);typeof a.revert=="undefined"&&(a.revert=!0);const o=yt.batch(()=>this.queryCache.findAll(i).map(s=>s.cancel(a)));return Promise.all(o).then(Nr).catch(Nr)}invalidateQueries(t,r,n){const[i,a]=Un(t,r,n);return yt.batch(()=>{var o,s;if(this.queryCache.findAll(i).forEach(c=>{c.invalidate()}),i.refetchType==="none")return Promise.resolve();const u=z(D({},i),{type:(o=(s=i.refetchType)!=null?s:i.type)!=null?o:"active"});return this.refetchQueries(u,a)})}refetchQueries(t,r,n){const[i,a]=Un(t,r,n),o=yt.batch(()=>this.queryCache.findAll(i).filter(u=>!u.isDisabled()).map(u=>{var c;return u.fetch(void 0,z(D({},a),{cancelRefetch:(c=a==null?void 0:a.cancelRefetch)!=null?c:!0,meta:{refetchPage:i.refetchPage}}))}));let s=Promise.all(o).then(Nr);return a!=null&&a.throwOnError||(s=s.catch(Nr)),s}fetchQuery(t,r,n){const i=ss(t,r,n),a=this.defaultQueryOptions(i);typeof a.retry=="undefined"&&(a.retry=!1);const o=this.queryCache.build(this,a);return o.isStaleByTime(a.staleTime)?o.fetch(a):Promise.resolve(o.state.data)}prefetchQuery(t,r,n){return this.fetchQuery(t,r,n).then(Nr).catch(Nr)}fetchInfiniteQuery(t,r,n){const i=ss(t,r,n);return i.behavior=Pbe(),this.fetchQuery(i)}prefetchInfiniteQuery(t,r,n){return this.fetchInfiniteQuery(t,r,n).then(Nr).catch(Nr)}resumePausedMutations(){return this.mutationCache.resumePausedMutations()}getQueryCache(){return this.queryCache}getMutationCache(){return this.mutationCache}getLogger(){return this.logger}getDefaultOptions(){return this.defaultOptions}setDefaultOptions(t){this.defaultOptions=t}setQueryDefaults(t,r){const n=this.queryDefaults.find(i=>Ti(t)===Ti(i.queryKey));n?n.defaultOptions=r:this.queryDefaults.push({queryKey:t,defaultOptions:r})}getQueryDefaults(t){if(!t)return;const r=this.queryDefaults.find(n=>Na(t,n.queryKey));return process.env.NODE_ENV!=="production"&&this.queryDefaults.filter(i=>Na(t,i.queryKey)).length>1&&this.logger.error("[QueryClient] Several query defaults match with key '"+JSON.stringify(t)+"'. The first matching query defaults are used. Please check how query defaults are registered. Order does matter here. cf. https://react-query.tanstack.com/reference/QueryClient#queryclientsetquerydefaults."),r==null?void 0:r.defaultOptions}setMutationDefaults(t,r){const n=this.mutationDefaults.find(i=>Ti(t)===Ti(i.mutationKey));n?n.defaultOptions=r:this.mutationDefaults.push({mutationKey:t,defaultOptions:r})}getMutationDefaults(t){if(!t)return;const r=this.mutationDefaults.find(n=>Na(t,n.mutationKey));return process.env.NODE_ENV!=="production"&&this.mutationDefaults.filter(i=>Na(t,i.mutationKey)).length>1&&this.logger.error("[QueryClient] Several mutation defaults match with key '"+JSON.stringify(t)+"'. The first matching mutation defaults are used. Please check how mutation defaults are registered. Order does matter here. cf. https://react-query.tanstack.com/reference/QueryClient#queryclientsetmutationdefaults."),r==null?void 0:r.defaultOptions}defaultQueryOptions(t){if(t!=null&&t._defaulted)return t;const r=z(D(D(D({},this.defaultOptions.queries),this.getQueryDefaults(t==null?void 0:t.queryKey)),t),{_defaulted:!0});return!r.queryHash&&r.queryKey&&(r.queryHash=Vg(r.queryKey,r)),typeof r.refetchOnReconnect=="undefined"&&(r.refetchOnReconnect=r.networkMode!=="always"),typeof r.useErrorBoundary=="undefined"&&(r.useErrorBoundary=!!r.suspense),r}defaultMutationOptions(t){return t!=null&&t._defaulted?t:z(D(D(D({},this.defaultOptions.mutations),this.getMutationDefaults(t==null?void 0:t.mutationKey)),t),{_defaulted:!0})}clear(){this.queryCache.clear(),this.mutationCache.clear()}}class Rbe extends To{constructor(t,r){super(),this.client=t,this.options=r,this.trackedProps=new Set,this.selectError=null,this.bindMethods(),this.setOptions(r)}bindMethods(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.currentQuery.addObserver(this),v_(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return jm(this.currentQuery,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return jm(this.currentQuery,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.clearStaleTimeout(),this.clearRefetchInterval(),this.currentQuery.removeObserver(this)}setOptions(t,r){const n=this.options,i=this.currentQuery;if(this.options=this.client.defaultQueryOptions(t),process.env.NODE_ENV!=="production"&&typeof(t==null?void 0:t.isDataEqual)!="undefined"&&this.client.getLogger().error("The isDataEqual option has been deprecated and will be removed in the next major version. You can achieve the same functionality by passing a function as the structuralSharing option"),wc(n,this.options)||this.client.getQueryCache().notify({type:"observerOptionsUpdated",query:this.currentQuery,observer:this}),typeof this.options.enabled!="undefined"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=n.queryKey),this.updateQuery();const a=this.hasListeners();a&&y_(this.currentQuery,i,this.options,n)&&this.executeFetch(),this.updateResult(r),a&&(this.currentQuery!==i||this.options.enabled!==n.enabled||this.options.staleTime!==n.staleTime)&&this.updateStaleTimeout();const o=this.computeRefetchInterval();a&&(this.currentQuery!==i||this.options.enabled!==n.enabled||o!==this.currentRefetchInterval)&&this.updateRefetchInterval(o)}getOptimisticResult(t){const r=this.client.getQueryCache().build(this.client,t),n=this.createResult(r,t);return Nbe(this,n,t)&&(this.currentResult=n,this.currentResultOptions=this.options,this.currentResultState=this.currentQuery.state),n}getCurrentResult(){return this.currentResult}trackResult(t){const r={};return Object.keys(t).forEach(n=>{Object.defineProperty(r,n,{configurable:!1,enumerable:!0,get:()=>(this.trackedProps.add(n),t[n])})}),r}getCurrentQuery(){return this.currentQuery}remove(){this.client.getQueryCache().remove(this.currentQuery)}refetch(n={}){var i=n,{refetchPage:t}=i,r=Ye(i,["refetchPage"]);return this.fetch(z(D({},r),{meta:{refetchPage:t}}))}fetchOptimistic(t){const r=this.client.defaultQueryOptions(t),n=this.client.getQueryCache().build(this.client,r);return n.isFetchingOptimistic=!0,n.fetch().then(()=>this.createResult(n,r))}fetch(t){var r;return this.executeFetch(z(D({},t),{cancelRefetch:(r=t.cancelRefetch)!=null?r:!0})).then(()=>(this.updateResult(),this.currentResult))}executeFetch(t){this.updateQuery();let r=this.currentQuery.fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(Nr)),r}updateStaleTimeout(){if(this.clearStaleTimeout(),Us||this.currentResult.isStale||!zm(this.options.staleTime))return;const r=aP(this.currentResult.dataUpdatedAt,this.options.staleTime)+1;this.staleTimeoutId=setTimeout(()=>{this.currentResult.isStale||this.updateResult()},r)}computeRefetchInterval(){var t;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(t=this.options.refetchInterval)!=null?t:!1}updateRefetchInterval(t){this.clearRefetchInterval(),this.currentRefetchInterval=t,!(Us||this.options.enabled===!1||!zm(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(()=>{(this.options.refetchIntervalInBackground||Cc.isFocused())&&this.executeFetch()},this.currentRefetchInterval))}updateTimers(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())}clearStaleTimeout(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)}clearRefetchInterval(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)}createResult(t,r){const n=this.currentQuery,i=this.options,a=this.currentResult,o=this.currentResultState,s=this.currentResultOptions,u=t!==n,c=u?t.state:this.currentQueryInitialState,d=u?this.currentResult:this.previousQueryResult,{state:h}=t;let{dataUpdatedAt:p,error:m,errorUpdatedAt:g,fetchStatus:b,status:_}=h,w=!1,C=!1,S;if(r._optimisticResults){const k=this.hasListeners(),I=!k&&v_(t,r),$=k&&y_(t,n,r,i);(I||$)&&(b=Bd(t.options.networkMode)?"fetching":"paused",p||(_="loading")),r._optimisticResults==="isRestoring"&&(b="idle")}if(r.keepPreviousData&&!h.dataUpdatedAt&&d!=null&&d.isSuccess&&_!=="error")S=d.data,p=d.dataUpdatedAt,_=d.status,w=!0;else if(r.select&&typeof h.data!="undefined")if(a&&h.data===(o==null?void 0:o.data)&&r.select===this.selectFn)S=this.selectResult;else try{this.selectFn=r.select,S=r.select(h.data),S=Wm(a==null?void 0:a.data,S,r),this.selectResult=S,this.selectError=null}catch(k){process.env.NODE_ENV!=="production"&&this.client.getLogger().error(k),this.selectError=k}else S=h.data;if(typeof r.placeholderData!="undefined"&&typeof S=="undefined"&&_==="loading"){let k;if(a!=null&&a.isPlaceholderData&&r.placeholderData===(s==null?void 0:s.placeholderData))k=a.data;else if(k=typeof r.placeholderData=="function"?r.placeholderData():r.placeholderData,r.select&&typeof k!="undefined")try{k=r.select(k),this.selectError=null}catch(I){process.env.NODE_ENV!=="production"&&this.client.getLogger().error(I),this.selectError=I}typeof k!="undefined"&&(_="success",S=Wm(a==null?void 0:a.data,k,r),C=!0)}this.selectError&&(m=this.selectError,S=this.selectResult,g=Date.now(),_="error");const T=b==="fetching",M=_==="loading",P=_==="error";return{status:_,fetchStatus:b,isLoading:M,isSuccess:_==="success",isError:P,isInitialLoading:M&&T,data:S,dataUpdatedAt:p,error:m,errorUpdatedAt:g,failureCount:h.fetchFailureCount,failureReason:h.fetchFailureReason,errorUpdateCount:h.errorUpdateCount,isFetched:h.dataUpdateCount>0||h.errorUpdateCount>0,isFetchedAfterMount:h.dataUpdateCount>c.dataUpdateCount||h.errorUpdateCount>c.errorUpdateCount,isFetching:T,isRefetching:T&&!M,isLoadingError:P&&h.dataUpdatedAt===0,isPaused:b==="paused",isPlaceholderData:C,isPreviousData:w,isRefetchError:P&&h.dataUpdatedAt!==0,isStale:Gg(t,r),refetch:this.refetch,remove:this.remove}}updateResult(t){const r=this.currentResult,n=this.createResult(this.currentQuery,this.options);if(this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,wc(n,r))return;this.currentResult=n;const i={cache:!0},a=()=>{if(!r)return!0;const{notifyOnChangeProps:o}=this.options,s=typeof o=="function"?o():o;if(s==="all"||!s&&!this.trackedProps.size)return!0;const u=new Set(s!=null?s:this.trackedProps);return this.options.useErrorBoundary&&u.add("error"),Object.keys(this.currentResult).some(c=>{const d=c;return this.currentResult[d]!==r[d]&&u.has(d)})};(t==null?void 0:t.listeners)!==!1&&a()&&(i.listeners=!0),this.notify(D(D({},i),t))}updateQuery(){const t=this.client.getQueryCache().build(this.client,this.options);if(t===this.currentQuery)return;const r=this.currentQuery;this.currentQuery=t,this.currentQueryInitialState=t.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))}onQueryUpdate(t){const r={};t.type==="success"?r.onSuccess=!t.manual:t.type==="error"&&!Gu(t.error)&&(r.onError=!0),this.updateResult(r),this.hasListeners()&&this.updateTimers()}notify(t){yt.batch(()=>{if(t.onSuccess){var r,n,i,a;(r=(n=this.options).onSuccess)==null||r.call(n,this.currentResult.data),(i=(a=this.options).onSettled)==null||i.call(a,this.currentResult.data,null)}else if(t.onError){var o,s,u,c;(o=(s=this.options).onError)==null||o.call(s,this.currentResult.error),(u=(c=this.options).onSettled)==null||u.call(c,void 0,this.currentResult.error)}t.listeners&&this.listeners.forEach(({listener:d})=>{d(this.currentResult)}),t.cache&&this.client.getQueryCache().notify({query:this.currentQuery,type:"observerResultsUpdated"})})}}function Dbe(e,t){return t.enabled!==!1&&!e.state.dataUpdatedAt&&!(e.state.status==="error"&&t.retryOnMount===!1)}function v_(e,t){return Dbe(e,t)||e.state.dataUpdatedAt>0&&jm(e,t,t.refetchOnMount)}function jm(e,t,r){if(t.enabled!==!1){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&Gg(e,t)}return!1}function y_(e,t,r,n){return r.enabled!==!1&&(e!==t||n.enabled===!1)&&(!r.suspense||e.state.status!=="error")&&Gg(e,r)}function Gg(e,t){return e.isStaleByTime(t.staleTime)}function Nbe(e,t,r){return r.keepPreviousData?!1:r.placeholderData!==void 0?t.isPlaceholderData:!wc(e.getCurrentResult(),t)}var Vm={exports:{}},Ef={};/**
464
+ * @license React
465
+ * use-sync-external-store-shim.production.js
466
+ *
467
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
468
+ *
469
+ * This source code is licensed under the MIT license found in the
470
+ * LICENSE file in the root directory of this source tree.
471
+ */var b_;function kbe(){if(b_)return Ef;b_=1;var e=N;function t(h,p){return h===p&&(h!==0||1/h===1/p)||h!==h&&p!==p}var r=typeof Object.is=="function"?Object.is:t,n=e.useState,i=e.useEffect,a=e.useLayoutEffect,o=e.useDebugValue;function s(h,p){var m=p(),g=n({inst:{value:m,getSnapshot:p}}),b=g[0].inst,_=g[1];return a(function(){b.value=m,b.getSnapshot=p,u(b)&&_({inst:b})},[h,m,p]),i(function(){return u(b)&&_({inst:b}),h(function(){u(b)&&_({inst:b})})},[h]),o(m),m}function u(h){var p=h.getSnapshot;h=h.value;try{var m=p();return!r(h,m)}catch(g){return!0}}function c(h,p){return p()}var d=typeof window=="undefined"||typeof window.document=="undefined"||typeof window.document.createElement=="undefined"?c:s;return Ef.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,Ef}var Af={};/**
472
+ * @license React
473
+ * use-sync-external-store-shim.development.js
474
+ *
475
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
476
+ *
477
+ * This source code is licensed under the MIT license found in the
478
+ * LICENSE file in the root directory of this source tree.
479
+ */var __;function Lbe(){return __||(__=1,process.env.NODE_ENV!=="production"&&function(){function e(m,g){return m===g&&(m!==0||1/m===1/g)||m!==m&&g!==g}function t(m,g){d||i.startTransition===void 0||(d=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var b=g();if(!h){var _=g();a(b,_)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),h=!0)}_=o({inst:{value:b,getSnapshot:g}});var w=_[0].inst,C=_[1];return u(function(){w.value=b,w.getSnapshot=g,r(w)&&C({inst:w})},[m,b,g]),s(function(){return r(w)&&C({inst:w}),m(function(){r(w)&&C({inst:w})})},[m]),c(b),b}function r(m){var g=m.getSnapshot;m=m.value;try{var b=g();return!a(m,b)}catch(_){return!0}}function n(m,g){return g()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var i=N,a=typeof Object.is=="function"?Object.is:e,o=i.useState,s=i.useEffect,u=i.useLayoutEffect,c=i.useDebugValue,d=!1,h=!1,p=typeof window=="undefined"||typeof window.document=="undefined"||typeof window.document.createElement=="undefined"?n:t;Af.useSyncExternalStore=i.useSyncExternalStore!==void 0?i.useSyncExternalStore:p,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__!="undefined"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),Af}process.env.NODE_ENV==="production"?Vm.exports=kbe():Vm.exports=Lbe();var Obe=Vm.exports;const fP=Obe.useSyncExternalStore,w_=de.createContext(void 0),pP=de.createContext(!1);function mP(e,t){return e||(t&&typeof window!="undefined"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=w_),window.ReactQueryClientContext):w_)}const gP=({context:e}={})=>{const t=de.useContext(mP(e,de.useContext(pP)));if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},Ibe=({client:e,children:t,context:r,contextSharing:n=!1})=>{de.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),process.env.NODE_ENV!=="production"&&n&&e.getLogger().error("The contextSharing option has been deprecated and will be removed in the next major version");const i=mP(r,n);return de.createElement(pP.Provider,{value:!r&&n},de.createElement(i.Provider,{value:e},t))},Fbe=de.createContext(!1),$be=()=>de.useContext(Fbe);function Bbe(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}const zbe=de.createContext(Bbe()),Hbe=()=>de.useContext(zbe);function vP(e,t){return typeof e=="function"?e(...t):!!e}const Wbe=(e,t)=>{(e.suspense||e.useErrorBoundary)&&(t.isReset()||(e.retryOnMount=!1))},jbe=e=>{de.useEffect(()=>{e.clearReset()},[e])},Vbe=({result:e,errorResetBoundary:t,useErrorBoundary:r,query:n})=>e.isError&&!t.isReset()&&!e.isFetching&&vP(r,[e.error,n]),Ube=e=>{e.suspense&&(typeof e.staleTime!="number"&&(e.staleTime=1e3),typeof e.cacheTime=="number"&&(e.cacheTime=Math.max(e.cacheTime,1e3)))},Gbe=(e,t)=>e.isLoading&&e.isFetching&&!t,qbe=(e,t,r)=>(e==null?void 0:e.suspense)&&Gbe(t,r),Ybe=(e,t,r)=>t.fetchOptimistic(e).then(({data:n})=>{e.onSuccess==null||e.onSuccess(n),e.onSettled==null||e.onSettled(n,null)}).catch(n=>{r.clearReset(),e.onError==null||e.onError(n),e.onSettled==null||e.onSettled(void 0,n)});function Xbe(e,t){const r=gP({context:e.context}),n=$be(),i=Hbe(),a=r.defaultQueryOptions(e);a._optimisticResults=n?"isRestoring":"optimistic",a.onError&&(a.onError=yt.batchCalls(a.onError)),a.onSuccess&&(a.onSuccess=yt.batchCalls(a.onSuccess)),a.onSettled&&(a.onSettled=yt.batchCalls(a.onSettled)),Ube(a),Wbe(a,i),jbe(i);const[o]=de.useState(()=>new t(r,a)),s=o.getOptimisticResult(a);if(fP(de.useCallback(u=>{const c=n?()=>{}:o.subscribe(yt.batchCalls(u));return o.updateResult(),c},[o,n]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),de.useEffect(()=>{o.setOptions(a,{listeners:!1})},[a,o]),qbe(a,s,n))throw Ybe(a,o,i);if(Vbe({result:s,errorResetBoundary:i,useErrorBoundary:a.useErrorBoundary,query:o.getCurrentQuery()}))throw s.error;return a.notifyOnChangeProps?s:o.trackResult(s)}function qg(e,t,r){const n=ss(e,t,r);return Xbe(n,Rbe)}const Um="ComposeSDK";function yP(e){return z(D({},e),{jaql:z(D({},e.jaql),{by:Um})})}const Zbe="api/v2/ai/narrative",bP="api/v2/ai/nlg/queryResult";function _P(e){return"status"in e}function Kbe(e){return typeof e!="object"||e===null?!1:_P(e)&&e.status==="404"}function Qbe(e){return typeof e!="object"||e===null?!1:_P(e)&&e.status==="400"}function Jbe(e,t){return ht(this,null,function*(){const r=yP(t);try{return yield e.post(Zbe,r)}catch(n){if(!Kbe(n))throw n;return yield e.post(bP,r)}})}function wP(e,t,r){return ht(this,null,function*(){const{canGenerateNarrativeViaAI:n,fallbackRequestOn400:i}=r!=null?r:{},a=o=>n?Jbe(e,o):e.post(bP,yP(o));if(!i)return a(t);try{return yield a(t)}catch(o){if(!Qbe(o))throw o;return a(i)}})}function zd(e){var s,u;if("jaql"in e)return z(D({},e),{jaql:z(D({},e.jaql),{by:Um})});const t=V.convertJaqlDataSource(e.dataSource),{filters:r=[],relations:n}=V.getFilterListAndRelationsJaql(e.filters),{metadata:i,filterRelations:a}=V.getJaqlQueryPayload({dataSource:e.dataSource,attributes:(s=e.dimensions)!=null?s:[],measures:(u=e.measures)!=null?u:[],filters:r,filterRelations:n,highlights:[]},!0),o={jaql:{datasource:t,metadata:i,filterRelations:a,by:Um}};return e.verbosity&&(o.verbosity=e.verbosity),o}const e2e=zd;function CP(e,t,r){const n=e.map(H.toDimensionQueryAdaptItem),i=t.map(H.toMeasureQueryAdaptItem);return{dimensions:H.adaptDimensionsForQuery(n),measures:H.adaptMeasuresForQuery(i,r)}}function t2e(e){const t=[],r=[];for(const n of e)E.isMeasureColumn(n)?r.push(n):t.push(n);return{dimensionColumns:t,measureColumns:r}}function r2e(e,t,r){const n=v3(t,e),i=y3(t,n),a=m3(i,t);return CP(_3(a,t),w3(a,t),r)}function n2e(e,t){const r=ul(e),{dimensionColumns:n,measureColumns:i}=t2e(r.columns);return CP(n,i,t)}function xP(e){if(e!==void 0)return e==="high"?"High":"Low"}function i2e(e,t){const{dataSource:r,dataOptions:n,chartType:i,filters:a}=e,o=r!=null?r:t;if(!o)throw new Error("dataSource is required. Provide it in ChartWidgetProps or as defaultDataSource parameter.");const{verbosity:s,includeTrendAndForecast:u}=Bi(Xi(e)),c={includeTrendAndForecast:u},{dimensions:d,measures:h}=H.isTable(i)?n2e(n,c):r2e(n,i,c);return{dataSource:o,dimensions:d,measures:h,filters:a,verbosity:xP(s)}}function a2e(e,t){var w,C,S;const r=(w=e.dataSource)!=null?w:t;if(!r)throw new Error("dataSource is required. Provide it in pivot widget props or as defaultDataSource parameter.");const{verbosity:n,includeTrendAndForecast:i}=Bi(Xi(e)),a=!i&&e.dataOptions.values?z(D({},e.dataOptions),{values:e.dataOptions.values.map(T=>E.isMeasureColumn(T)&&("trend"in T||"forecast"in T)?V.omit(T,["trend","forecast"]):T)}):e.dataOptions,o=C3(a),{rows:s,columns:u,values:c,grandTotals:d}=Fg(o),{filters:h=[],relations:p}=V.getFilterListAndRelationsJaql((C=e.filters)!=null?C:[]),m=h.map(T=>E.safeCombine(T,{isScope:!0})),g=((S=e.highlights)!=null?S:[]).map(T=>E.safeCombine(T,{isScope:!0})),b={dataSource:r,rowsAttributes:s!=null?s:[],columnsAttributes:u!=null?u:[],measures:c!=null?c:[],grandTotals:D(D({},V.DEFAULT_PIVOT_GRAND_TOTALS),d!=null?d:{}),filters:m,filterRelations:p,highlights:g};yC(b);const _=V.getPivotJaqlQueryPayload(b,!1);return zd({jaql:_,verbosity:xP(n)})}function Mu(e,t){if(E.isPivotTableWidgetProps(e))return a2e(e,t);if(E.isChartWidgetProps(e))return zd(i2e(e,t));throw new Error("Expected chart or pivot widget props")}function o2e(e){return E.isChartWidgetProps(e)||E.isPivotTableWidgetProps(e)?Bi(Xi(e)):Bi(void 0)}const s2e="dataSource is required. Provide it on the widget props, defaultDataSource parameter or via SisenseContextProvider.";function qu(){return{supported:!1,narrativeRequest:void 0,narrativeFallbackRequest:void 0}}function C_(){return z(D({},qu()),{missingDataSource:!0})}function x_(e){var r;if(!E.isChartWidgetProps(e)&&!E.isPivotTableWidgetProps(e))return e;const t=Xi(e);return z(D({},e),{config:z(D({},(r=e.config)!=null?r:{}),{narrative:z(D({},t!=null?t:{}),{includeTrendAndForecast:!1})})})}function TP(e,t){var n,i;const{includeTrendAndForecast:r}=o2e(e);if(E.isPivotTableWidgetProps(e)){if(!((n=e.dataSource)!=null?n:t))return C_();let a;try{a=Mu(e,t)}catch(s){return qu()}let o;if(r)try{o=Mu(x_(e),t)}catch(s){}return{supported:!0,narrativeRequest:a,narrativeFallbackRequest:o}}if(E.isChartWidgetProps(e)){if(!((i=e.dataSource)!=null?i:t))return C_();let a;try{a=Mu(e,t)}catch(s){return qu()}let o;if(r)try{o=Mu(x_(e),t)}catch(s){}return{supported:!0,narrativeRequest:a,narrativeFallbackRequest:o}}return qu()}const l2e={dataSource:"__WidgetNarrativeInactive__",dimensions:[],measures:[],filters:[]};function SP({widgetProps:e,enabled:t=!0}){var S,T;const{app:r}=y.useSisenseContext(),n=r==null?void 0:r.httpClient,i=N.useMemo(()=>{var M,P;return{canGenerateNarrativeViaAI:(P=(M=r==null?void 0:r.settings)==null?void 0:M.narrative)==null?void 0:P.canGenerateNarrativeViaAI}},[(T=(S=r==null?void 0:r.settings)==null?void 0:S.narrative)==null?void 0:T.canGenerateNarrativeViaAI]),{supported:a,narrativeRequest:o,narrativeFallbackRequest:s}=N.useMemo(()=>TP(e,r==null?void 0:r.defaultDataSource),[e,r==null?void 0:r.defaultDataSource]),u=N.useMemo(()=>a&&o?o:zd(l2e),[a,o]),c=a&&t&&!!n,d=n?n.url:null,h=N.useMemo(()=>JSON.stringify(u),[u]),{data:p,error:m,isError:g,isLoading:b,isSuccess:_,refetch:w}=qg({queryKey:["narrative",h,d,i.canGenerateNarrativeViaAI],queryFn:()=>n?wP(n,u,z(D({},i),{fallbackRequestOn400:s})):Promise.reject(new Error("HttpClient is required for narrative requests")),select:M=>{var P;return(P=M==null?void 0:M.data)==null?void 0:P.answer},enabled:c}),C=N.useCallback(()=>{w()},[w]);return t?{isLoading:b,isError:g,isSuccess:_,data:p,error:m,refetch:C,supported:a,enabled:!0,narrativeRequest:a?o:void 0}:{isLoading:!1,isError:!1,isSuccess:!1,data:void 0,error:void 0,refetch:C,supported:a,enabled:!1,narrativeRequest:void 0}}function u2e(e){const t=document.createElement("span");t.setAttribute("aria-hidden","true"),t.textContent=`A
480
+ A`,Object.assign(t.style,{position:"absolute",visibility:"hidden",pointerEvents:"none",whiteSpace:"pre",margin:"0",padding:"0",border:"0"}),e.appendChild(t);const{height:r}=t.getBoundingClientRect();return e.removeChild(t),r>0?r/2:null}function c2e(e){const[t,r]=N.useState(null),n=N.useRef({element:null,ro:null,cancelled:!1});return N.useLayoutEffect(()=>{var c;const i=e.current,a=n.current;if(i===a.element)return;if(a.cancelled=!0,(c=a.ro)==null||c.disconnect(),a.ro=null,a.element=i,!i){r(null);return}a.cancelled=!1;const o=()=>{if(a.cancelled)return;const d=u2e(i);d!=null&&r(h=>h===d?h:d)};o();const s=document.fonts;s&&s.status!=="loaded"&&s.ready.then(o);const u=new ResizeObserver(o);u.observe(i),a.ro=u}),N.useEffect(()=>()=>{var i;n.current.cancelled=!0,(i=n.current.ro)==null||i.disconnect()},[]),t}const d2e=18,h2e=5;function MP({text:e,maxCollapsedHeightPx:t,maxExpandedHeightPx:r,reserveCollapsedHeight:n=!1,noCollapse:i=!1,isLoading:a=!1,isError:o=!1,onCollapsedChange:s,textClassName:u,showDisclaimer:c=!1}){const[d,h]=N.useState(!0),[p,m]=N.useState(!1),g=N.useRef(null),b=N.useRef(null),[_,w]=N.useState(0),{t:C}=O.useTranslation(),{themeSettings:S}=y.useThemeContext(),T=c2e(g),M=T!=null?T:d2e,P=N.useMemo(()=>t!==void 0&&t>0?Math.max(Math.floor(t/M)*M,M):h2e*M,[t,M]),R=Math.max(Math.floor((P-_)/M)*M,M);N.useLayoutEffect(()=>{var W,q;const U=(q=(W=b.current)==null?void 0:W.offsetHeight)!=null?q:0;if(w(ee=>ee===U?ee:U),i||!g.current)return;const Q=Math.max(Math.floor((P-U)/M)*M,M);m(g.current.scrollHeight>Q)},[i,P,M,a,c]),N.useEffect(()=>{if(i||!g.current)return;const U=g.current,Q=new ResizeObserver(()=>{m(U.scrollHeight>R)});return Q.observe(U),()=>Q.disconnect()},[i,R]),N.useEffect(()=>{const U=b.current;if(!U)return;const Q=new ResizeObserver(()=>{const W=U.offsetHeight;w(q=>q===W?q:W)});return Q.observe(U),()=>Q.disconnect()},[c,a]);const k=()=>{h(!1),s==null||s(!1)},I=()=>{h(!0),s==null||s(!0)},$=U=>Q=>{(Q.key==="Enter"||Q.key===" ")&&(Q.preventDefault(),U())},G=!i&&p&&d,Y=!i&&p&&!d,B=r?r-_:void 0;let X;return!i&&d?X=n?{height:R,overflow:"hidden"}:{maxHeight:R,overflow:"hidden"}:X={overflow:"auto",maxHeight:B},o?O.jsx("div",{style:{width:"100%"},children:O.jsx(y.ErrorBoundaryBox,{error:C("ai.errors.unexpected")})}):O.jsxs("div",{className:"csdk-min-w-0 csdk-flex-1",children:[O.jsx("div",{style:X,children:a?O.jsx(y.LoadingOverlay,{isVisible:!0}):O.jsx("div",{ref:g,className:["csdk-whitespace-pre-wrap",u].filter(Boolean).join(" "),style:{color:S.typography.primaryTextColor},children:e})}),O.jsxs("div",{className:"csdk-flex csdk-flex-row csdk-justify-between",children:[c&&!a&&O.jsx("div",{ref:b,className:"csdk-text-ai-xs csdk-pt-2",style:{color:S.typography.secondaryTextColor},children:C("ai.disclaimer.poweredByAi")}),(G||Y)&&O.jsx("div",{className:"csdk-mt-3 csdk-flex csdk-justify-end",children:O.jsx("div",{className:"csdk-text-ai-xs csdk-text-text-link csdk-cursor-pointer",onClick:G?k:I,onKeyDown:$(G?k:I),role:"button",tabIndex:0,children:C(G?"ai.buttons.readMore":"ai.buttons.collapse")})})]})]})}function PP(n){var i=n,{constrainedHeightPx:e,maxConstrainedHeightPx:t}=i,r=Ye(i,["constrainedHeightPx","maxConstrainedHeightPx"]);return O.jsx(MP,z(D({},r),{showDisclaimer:!0,maxCollapsedHeightPx:e,maxExpandedHeightPx:t,reserveCollapsedHeight:!0,textClassName:"csdk-text-[13px]"}))}const EP=18,AP=12,Gm=8,f2e=0,p2e=0,m2e=EP+f2e+p2e,qm=y.newStyled.div`
481
+ box-sizing: border-box;
482
+ margin: 0;
483
+ padding: ${({$horizontalInset:e})=>e?`${Gm}px ${AP}px 0 ${m2e}px`:"8px 0 0"};
484
+ width: 100%;
485
+ color: ${({theme:e})=>e.chart.textColor};
486
+ background-color: ${({theme:e})=>e.chart.backgroundColor};
487
+ `,g2e="api/v2/ai/feedback";function v2e(e,t){return e.post(g2e,t)}const RP=()=>{const[e,t]=N.useState(!1),r=N.useRef(null),n=N.useCallback(()=>{t(!0)},[]),i=N.useCallback(()=>{t(!1)},[]);return[N.useCallback(o=>{var s;((s=r.current)==null?void 0:s.nodeType)===Node.ELEMENT_NODE&&(r.current.removeEventListener("mouseenter",n),r.current.removeEventListener("mouseleave",i)),(o==null?void 0:o.nodeType)===Node.ELEMENT_NODE&&(o.addEventListener("mouseenter",n),o.addEventListener("mouseleave",i)),r.current=o},[n,i]),e]},DP=y.newStyled.div`
488
+ display: flex;
489
+ flex-direction: row;
490
+ align-items: center;
491
+ gap: 10px;
492
+ width: 100%;
493
+ box-sizing: border-box;
494
+ padding-left: ${EP}px;
495
+ padding-right: ${AP}px;
496
+ `,NP=y.newStyled.div`
497
+ align-self: flex-start;
498
+ `,y2e=y.newStyled.div`
499
+ display: flex;
500
+ flex-direction: column;
501
+ row-gap: ${({theme:e})=>e.aiChat.body.gapBetweenMessages};
502
+ `;function kP({theme:e}){const t=e.general.brandColor;return O.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"-2 -3 24 24",fill:"none","aria-hidden":!0,"data-testid":"narrative-ai-icon",children:[O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12.0533 3.62671e-06C12.0557 -9.45649e-05 12.0577 0.00181346 12.0578 0.00422597C12.1926 3.98958 15.4422 7.18501 19.4491 7.23273C19.4494 7.23273 19.4496 7.23296 19.4496 7.23325C19.4496 7.23356 19.4494 7.23381 19.4491 7.23382C15.3869 7.2822 12.1029 10.5659 12.054 14.628C12.054 14.6283 12.0538 14.6285 12.0535 14.6285C12.0532 14.6285 12.0529 14.6283 12.0529 14.628C12.0047 10.6218 8.80995 7.37281 4.8253 7.23765C4.82287 7.23757 4.82095 7.23552 4.82105 7.2331C4.82114 7.23081 4.82301 7.22897 4.8253 7.2289C8.75488 7.0956 11.9163 3.93392 12.0491 0.004224C12.0492 0.00194873 12.051 9.62326e-05 12.0533 3.62671e-06Z",fill:t}),O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9.0973 12.7759C7.1172 12.7236 5.51984 11.1352 5.45331 9.1587C5.45326 9.1573 5.45209 9.1562 5.4507 9.15625C5.44938 9.1563 5.44832 9.15738 5.44828 9.15869C5.38204 11.1266 3.79825 12.7098 1.83009 12.7751C1.82969 12.7752 1.82936 12.7755 1.82935 12.7759C1.82933 12.7763 1.82967 12.7767 1.83009 12.7767C3.8264 12.8429 5.42727 14.4708 5.45019 16.4778C5.45019 16.4781 5.45045 16.4784 5.45077 16.4784C5.45111 16.4784 5.4514 16.4781 5.4514 16.4778C5.47442 14.4622 7.089 12.8289 9.0973 12.7759Z",fill:t}),O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2.8778 2.15728C2.87779 2.15701 2.8779 2.15674 2.8781 2.15655C2.87874 2.15591 2.87983 2.15638 2.87981 2.15728C2.87934 2.17566 2.87911 2.1941 2.87911 2.21259C2.87911 3.36434 3.78842 4.30371 4.92829 4.35195C3.78842 4.40019 2.87911 5.33955 2.87911 6.4913C2.87911 6.56284 2.88262 6.63356 2.88947 6.7033C2.89045 6.7133 2.8783 6.71912 2.87119 6.71202C2.86894 6.70976 2.86781 6.70662 2.86813 6.70344C2.87499 6.63366 2.8785 6.56289 2.8785 6.4913C2.8785 5.33956 1.96921 4.40021 0.829346 4.35195C1.96921 4.30369 2.8785 3.36433 2.8785 2.21259C2.8785 2.1941 2.87827 2.17566 2.8778 2.15728ZM5.16566 4.35485C5.16834 4.35503 5.16981 4.35179 5.16791 4.34989C5.16732 4.3493 5.1665 4.34899 5.16567 4.34905C5.14802 4.35023 5.13031 4.3512 5.11255 4.35195C5.13031 4.3527 5.14801 4.35367 5.16566 4.35485Z",fill:t})]})}function b2e({color:e,bold:t=!1}){const r=t?{stroke:e,strokeWidth:1,paintOrder:"stroke fill"}:{};return O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:O.jsx("path",D({fillRule:"evenodd",clipRule:"evenodd",d:"M18.5798 14.7911C18.8749 14.4146 19.0165 14.011 18.9985 13.5954C18.9804 13.1377 18.7757 12.7793 18.607 12.5595C18.8027 12.0715 18.878 11.3036 18.2245 10.7073C17.7456 10.2705 16.9325 10.0748 15.806 10.1289C15.014 10.1651 14.3513 10.3127 14.3243 10.3187H14.3213C14.1708 10.3458 14.011 10.3789 13.8484 10.4151C13.8363 10.2223 13.8696 9.74345 14.2248 8.66522C14.6465 7.38231 14.6225 6.40041 14.1466 5.74397C13.6466 5.05425 12.8485 5 12.6136 5C12.3877 5 12.1799 5.09336 12.0324 5.26499C11.6981 5.6535 11.7373 6.37026 11.7793 6.70158C11.3818 7.76777 10.2676 10.382 9.32479 11.1077C9.30668 11.1198 9.2917 11.1349 9.27671 11.1499C8.99949 11.4421 8.81287 11.7583 8.68642 12.0353C8.50861 11.939 8.30687 11.8848 8.08995 11.8848H6.25291C5.56014 11.8848 5 12.448 5 13.1377V18.0318C5 18.7244 5.56323 19.2847 6.25291 19.2847H8.08995C8.35803 19.2847 8.60804 19.2003 8.81287 19.0557L9.52051 19.1401C9.62905 19.1551 11.5565 19.3991 13.5352 19.36C13.8935 19.387 14.2309 19.402 14.5441 19.402C15.0832 19.402 15.5531 19.36 15.9445 19.2756C16.8661 19.0798 17.4957 18.6884 17.8148 18.1131C18.0588 17.6734 18.0588 17.2366 18.0197 16.9596C18.6191 16.4175 18.7244 15.8181 18.7033 15.3965C18.6913 15.1525 18.637 14.9447 18.5798 14.7911ZM6.25291 18.4715C6.00896 18.4715 5.81324 18.2727 5.81324 18.0318V13.1346C5.81324 12.8908 6.0119 12.6949 6.25291 12.6949H8.08995C8.33393 12.6949 8.52981 12.8937 8.52981 13.1346V18.0287C8.52981 18.2727 8.33096 18.4685 8.08995 18.4685H6.25291V18.4715ZM17.8088 14.4387C17.6823 14.5712 17.6582 14.7731 17.7547 14.9298C17.7547 14.9327 17.878 15.1436 17.8932 15.4327C17.9142 15.8272 17.7245 16.1765 17.327 16.4747C17.1854 16.5831 17.1282 16.7699 17.1885 16.9385C17.1885 16.9415 17.3179 17.3391 17.1072 17.7156C16.9052 18.0769 16.4566 18.3359 15.7759 18.4804C15.2309 18.5979 14.4898 18.6191 13.5805 18.5468H13.5383C11.6017 18.589 9.64403 18.3359 9.62302 18.3329H9.61994L9.31583 18.2967C9.3339 18.2125 9.34286 18.1221 9.34286 18.0318V13.1346C9.34286 13.0052 9.32185 12.8787 9.28567 12.7612C9.33992 12.5595 9.49051 12.1106 9.84582 11.7281C11.1981 10.6559 12.5203 7.03893 12.5775 6.88232C12.6016 6.81908 12.6075 6.74981 12.5956 6.68058C12.5443 6.34323 12.5624 5.93058 12.6347 5.80718C12.7943 5.81015 13.225 5.85529 13.484 6.21365C13.7912 6.63837 13.7791 7.39733 13.4478 8.40316C12.9419 9.93624 12.8997 10.7433 13.3003 11.0987C13.4991 11.2764 13.7641 11.2855 13.9569 11.2162C14.1406 11.174 14.3153 11.1378 14.4809 11.1108C14.4929 11.1077 14.508 11.1048 14.52 11.1017C15.4447 10.8999 17.1011 10.7765 17.6763 11.3005C18.1642 11.7462 17.8179 12.3365 17.7788 12.3998C17.6673 12.5684 17.7004 12.7883 17.851 12.9238C17.854 12.9268 18.1702 13.225 18.1852 13.6256C18.1973 13.8935 18.0708 14.1677 17.8088 14.4387Z",fill:e},r))})}function _2e({color:e,bold:t=!1}){const r=t?{stroke:e,strokeWidth:1,paintOrder:"stroke fill"}:{};return O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:O.jsx("path",D({fillRule:"evenodd",clipRule:"evenodd",d:"M18.5798 9.61098C18.8749 9.98744 19.0165 10.391 18.9985 10.8066C18.9804 11.2643 18.7757 11.6227 18.607 11.8426C18.8027 12.3305 18.878 13.0984 18.2245 13.6947C17.7456 14.1315 16.9325 14.3273 15.806 14.2732C15.014 14.237 14.3513 14.0893 14.3243 14.0833H14.3213C14.1708 14.0562 14.011 14.0231 13.8484 13.9869C13.8363 14.1797 13.8696 14.6585 14.2249 15.7367C14.6465 17.0196 14.6225 18.0016 14.1466 18.6581C13.6466 19.3478 12.8485 19.4019 12.6136 19.4019C12.3877 19.4019 12.1799 19.3086 12.0324 19.137C11.6981 18.7484 11.7373 18.0317 11.7793 17.7004C11.3818 16.6342 10.2676 14.02 9.32479 13.2943C9.30668 13.2822 9.2917 13.2671 9.27671 13.2521C8.99949 12.9599 8.81287 12.6437 8.68642 12.3667C8.50861 12.463 8.30687 12.5173 8.08995 12.5173H6.25291C5.56014 12.5173 5 11.954 5 11.2643L5 6.37029C5 5.67764 5.56323 5.11738 6.25291 5.11738H8.08995C8.35803 5.11738 8.60804 5.20179 8.81287 5.34635L9.52051 5.26191C9.62905 5.24692 11.5565 5.00297 13.5352 5.04209C13.8935 5.01502 14.2309 5 14.5441 5C15.0832 5 15.5531 5.04209 15.9445 5.12649C16.8661 5.32222 17.4957 5.71366 17.8148 6.28898C18.0588 6.72865 18.0588 7.16543 18.0197 7.44247C18.6191 7.98454 18.7244 8.58394 18.7033 9.00555C18.6913 9.2495 18.637 9.4573 18.5798 9.61098ZM6.25291 5.93058C6.00896 5.93058 5.81324 6.12939 5.81324 6.37029V11.2674C5.81324 11.5112 6.0119 11.7071 6.25291 11.7071H8.08995C8.33393 11.7071 8.52981 11.5083 8.52981 11.2674V6.37338C8.52981 6.12939 8.33096 5.93352 8.08995 5.93352H6.25291V5.93058ZM17.8088 9.96331C17.6823 9.83083 17.6582 9.6289 17.7547 9.47229C17.7547 9.46935 17.878 9.25849 17.8932 8.96937C17.9142 8.5748 17.7245 8.22555 17.327 7.92731C17.1854 7.81893 17.1282 7.63217 17.1885 7.46351C17.1885 7.46057 17.3179 7.06291 17.1072 6.68645C16.9052 6.32516 16.4566 6.06619 15.7759 5.92162C15.2309 5.80413 14.4899 5.78293 13.5805 5.85529H13.5383C11.6017 5.81309 9.64403 6.06619 9.62302 6.06912H9.61994L9.31583 6.1053C9.3339 6.18955 9.34286 6.27998 9.34286 6.37029V11.2674C9.34286 11.3968 9.32185 11.5233 9.28567 11.6408C9.33992 11.8425 9.49051 12.2914 9.84582 12.6739C11.1982 13.7461 12.5203 17.3631 12.5775 17.5197C12.6017 17.583 12.6075 17.6521 12.5956 17.7214C12.5443 18.0587 12.5624 18.4715 12.6347 18.5949C12.7943 18.5919 13.225 18.5467 13.484 18.1883C13.7912 17.7636 13.7791 17.0046 13.4478 15.9988C12.9419 14.4657 12.8997 13.6587 13.3003 13.3033C13.4991 13.1256 13.7641 13.1165 13.9569 13.1858C14.1406 13.228 14.3153 13.2641 14.4809 13.2912C14.4929 13.2943 14.508 13.2973 14.52 13.3003C15.4447 13.5021 17.1011 13.6255 17.6763 13.1015C18.1642 12.6558 17.8179 12.0655 17.7788 12.0022C17.6673 11.8336 17.7004 11.6137 17.851 11.4782C17.854 11.4752 18.1702 11.177 18.1852 10.7764C18.1973 10.5085 18.0708 10.2343 17.8088 9.96331Z",fill:e},r))})}function w2e({narrativeTargetKey:e,visible:t,onSend:r,onCancelSend:n,themeSettings:i}){const[a,o]=N.useState(null),{t:s}=O.useTranslation();N.useEffect(()=>{o(null)},[e]);const u=N.useCallback(p=>{const m=a===p?null:p;o(m),m!==null?r(m==="up"?1:-1):n()},[r,n,a]),c=i.aiChat.icons.color,d=i.aiChat.icons.feedbackIcons.hoverColor;if(!t)return null;const h=p=>({padding:"2px",backgroundColor:a===p?d:"transparent","&:hover":{backgroundColor:d}});return O.jsxs("div",{className:"csdk-flex csdk-items-center",children:[O.jsx(Ii,{title:s("ai.buttons.correctResponse"),children:O.jsx(vn,{"aria-label":"thumbs-up",onClick:()=>u("up"),size:"small",sx:h("up"),children:O.jsx(b2e,{color:c,bold:a==="up"})})}),O.jsx(Ii,{title:s("ai.buttons.incorrectResponse"),children:O.jsx(vn,{"aria-label":"thumbs-down",onClick:()=>u("down"),size:"small",sx:h("down"),children:O.jsx(_2e,{color:c,bold:a==="down"})})})]})}function C2e({narrativeTargetKey:e,sourceId:t,data:r,type:n,buttonVisibility:i,renderContent:a}){const{app:o}=y.useSisenseContext(),s=o==null?void 0:o.httpClient,{themeSettings:u}=y.useThemeContext(),c=N.useCallback(g=>{s&&v2e(s,{sourceId:t,type:n,data:r,rating:g})},[s,t,r,n]),d=N.useMemo(()=>Ig(c,200),[c]);N.useEffect(()=>()=>{d.cancel()},[d]);const[h,p]=RP(),m=N.useMemo(()=>i==="always"||i==="onHover"&&p,[p,i]);return O.jsx(y2e,{ref:h,theme:u,children:a(O.jsx(w2e,{narrativeTargetKey:e,visible:m,onSend:d,onCancelSend:()=>d.cancel(),themeSettings:u}))})}function x2e({text:e,isError:t,isLoading:r,narrativeRequest:n,onCollapsedChange:i,constrainedHeightPx:a,maxConstrainedHeightPx:o,noCollapse:s}){const{themeSettings:u}=y.useThemeContext();return O.jsx(C2e,{narrativeTargetKey:e,sourceId:n.jaql.datasource.title,data:n,type:"chart/insights",buttonVisibility:"always",renderContent:c=>O.jsx(qm,{theme:u,"data-testid":"widget-narrative",children:O.jsxs(DP,{children:[O.jsx(NP,{theme:u,children:O.jsx(kP,{theme:u})}),O.jsx(PP,{isError:t,isLoading:r,text:e,noCollapse:s,onCollapsedChange:i,constrainedHeightPx:a,maxConstrainedHeightPx:o}),c]})})})}const LP=y.asSisenseComponent({componentName:"WidgetNarrative"})(function({widgetProps:t,enabled:r=!0,onCollapsedChange:n,constrainedHeightPx:i,maxConstrainedHeightPx:a}){const{t:o}=O.useTranslation(),{themeSettings:s}=y.useThemeContext(),{feedbackEnabled:u,isDisplayedAlone:c}=N.useMemo(()=>{if(!E.isChartWidgetProps(t)&&!E.isPivotTableWidgetProps(t))return{feedbackEnabled:!1,isDisplayedAlone:!1};const C=Bi(Xi(t));return{feedbackEnabled:C.feedback.enabled,isDisplayedAlone:C.displayLocation==="alone"}},[t]),{data:d,isLoading:h,isError:p,supported:m,narrativeRequest:g,enabled:b}=SP({widgetProps:t,enabled:r});if(!m||!b)return null;const _=d!=null?d:o("ai.errors.insightsNotAvailable"),w=O.jsxs(DP,{children:[O.jsx(NP,{theme:s,children:O.jsx(kP,{theme:s})}),O.jsx(PP,{isError:p,text:_,isLoading:h,noCollapse:c,onCollapsedChange:n,constrainedHeightPx:i,maxConstrainedHeightPx:a?a-Gm:void 0})]});return u?g?h?O.jsx(qm,{"data-testid":"widget-narrative",theme:s,children:w}):O.jsx(x2e,{isError:p,isLoading:h,narrativeRequest:g,text:_,noCollapse:c,onCollapsedChange:n,constrainedHeightPx:i,maxConstrainedHeightPx:a?a-Gm:void 0}):null:O.jsx(qm,{"data-testid":"widget-narrative",theme:s,children:w})});function T2e({propsWithDrilldown:e,styleOptions:t}){var C,S,T,M,P,R,k;const{app:r}=y.useSisenseContext(),n=N.useMemo(()=>Bi(Xi(e)),[e]),i=(T=(S=(C=r==null?void 0:r.settings)==null?void 0:C.narrative)==null?void 0:S.canGenerateNarrativeViaAI)!=null?T:!1,[a,o]=N.useState(!1),s=!!((P=(M=r==null?void 0:r.settings)==null?void 0:M.narrativeConfig)!=null&&P.enabled)&&i&&n.enabled&&!n.autoShow,u=N.useMemo(()=>s?z(D({},t),{header:z(D({},t==null?void 0:t.header),{renderToolbar:(I,$)=>{var Y;const G=(Y=t==null?void 0:t.header)!=null&&Y.renderToolbar?t.header.renderToolbar(I,$):$;return O.jsxs(O.Fragment,{children:[G,O.jsx(iP,{isVisible:a,onClick:()=>o(B=>!B)})]})}})}):t,[s,t,a,o]),c=!!((k=(R=r==null?void 0:r.settings)==null?void 0:R.narrativeConfig)!=null&&k.enabled)&&i&&n.enabled&&(n.autoShow||a),d=N.useMemo(()=>{const I=e,$=typeof I.id=="string"?I.id:"__chartWidgetNarrative__";return z(D({},I),{id:$,widgetType:"chart"})},[e]),h=N.useRef(null),[p,m]=N.useState(void 0);N.useEffect(()=>{const I=h.current;if(!I)return;m(I.clientHeight);const $=new ResizeObserver(()=>m(I.clientHeight));return $.observe(I),()=>$.disconnect()},[]);const g=N.useMemo(()=>{const{heightFraction:I,displayLocation:$}=n;if(!(I===void 0||$==="alone"||p===void 0))return I*p},[n,p]),b=N.useMemo(()=>{const{displayLocation:I}=n;if(p!==void 0)return I==="alone"?p:Math.max(p*.5,g!=null?g:0)},[n,p,g]),{displayLocation:_}=n,w=c?O.jsx(LP,{widgetProps:d,constrainedHeightPx:g,maxConstrainedHeightPx:b}):null;return{contentAreaRef:h,styleOptionsWithNarrative:u,narrativeTopSlot:_==="above"?w:null,narrativeBottomSlot:_==="below"?w:null,narrativeAloneContent:_==="alone"?w:null}}var S2e=Object.prototype,M2e=S2e.hasOwnProperty,OP=LM(function(e,t,r){M2e.call(e,r)?e[r].push(t):V.baseAssignValue(e,r,[t])});function Ym(e){return e&&e.length?G0(e):[]}var Gs=(e=>(e.WIDGET_POINTS_DRILLDOWN="widget-points-drilldown",e.WIDGET_POINTS_CROSSFILTERING="widget-points-crossfiltering",e))(Gs||{}),Ka=(e=>(e.DRILLDOWN_CHART_POINTS_SELECTION="drilldown-chart-points-selection",e.DRILLDOWN_DRILL_DIRECTIONS="drilldown-drill-directions",e.CROSSFILTERING_CHART_POINTS_SELECTION="crossfiltering-chart-points-selection",e))(Ka||{});const P2e=["rows","columns","values","category","value","breakBy","x","y","breakByPoint","breakByColor","size","date","geo","color","colorBy","details","outliers","secondary","min","max"];function E2e(e){return P2e.includes(e)}function A2e(e,t){const r=[];for(const[n,i]of Object.entries(e))!E2e(n)||i===null||i===void 0||(Array.isArray(i)?i.forEach((a,o)=>{T_(a)&&r.push({location:{dataOptionName:n,dataOptionIndex:o},column:a})}):typeof i=="object"&&!Array.isArray(i)&&T_(i)&&r.push({location:{dataOptionName:n,dataOptionIndex:0},column:i}));for(const{location:n,column:i}of r)if(IP(i,t))return n}function T_(e){if(!e||typeof e!="object")return!1;const t="column"in e?e.column:e;return typeof t=="object"&&t!==null&&"type"in t&&"expression"in t}function IP(e,t){return y.isSameAttribute(E.translateColumnToAttribute(e),E.translateColumnToAttribute(t))}function FP(e,t){const{dataOptionName:r,dataOptionIndex:n=0}=t,i=e[r];if(i!=null){if(V.isArray(i))return n>=0&&n<i.length?i[n]:void 0;if(V.isPlainObject(i))return n!==0&&t.dataOptionIndex!==void 0?void 0:i}}function R2e(e,t,r){const{dataOptionName:n,dataOptionIndex:i=0}=t,a=r[n];if(a==null)return r;if(V.isArray(a)){if(i>=0&&i<a.length){const o=[...a];return o[i]=e,z(D({},r),{[n]:o})}return r}return V.isPlainObject(a)?i!==0&&t.dataOptionIndex!==void 0?r:z(D({},r),{[n]:e}):r}function $P(e,t,r){return r.length===0||!t?void 0:"dataOptionName"in t?t:A2e(e,t)}function BP(e,t,r){const n=FP(e,t);return!n||IP(n,r)?e:R2e(r,t,e)}function D2e(e,t){return t.all?[]:e.filter(r=>{var n;return!((n=t.ids)!=null&&n.includes(r.config.guid))})}function zP(e,t){return e.find(r=>y.isSameAttribute(r.attribute,t))}function HP(e,t,r){var i;const n=zP(r,e);return V.members((i=n==null?void 0:n.attribute)!=null?i:e,t.map(a=>`${a}`),{guid:n==null?void 0:n.config.guid,backgroundFilter:n==null?void 0:n.config.backgroundFilter})}function WP(e,t){return y.haveSameAttribute(e,t)&&"members"in e&&"members"in t&&V.isEqual(e.members,t.members)}function N2e({widgetType:e,chartType:t,dataOptions:r,drilldownOptions:n}){if(e==="pivot"){const i=n,a=r,o=i==null?void 0:i.drilldownSelections,s=i==null?void 0:i.drilldownTarget;if(o&&o.length&&s){const u=$P(a,s,o),c=V.last(o);if(u&&(c!=null&&c.nextDimension))return BP(a,u,c.nextDimension)}}if(t){const i=n,a=r,o=i==null?void 0:i.drilldownSelections;if(o&&o.length){const s=V.last(o);if(s!=null&&s.nextDimension)return VP(t,a,s.nextDimension)}}return r}const jP=2;function k2e(e,t){const r=e[t];return r?Array.isArray(r)?r:[r]:[]}function wn(e,t,r=!1){if(!e.length||!t.length)return[];const n=e.flatMap(({entries:a={}})=>t.flatMap(o=>k2e(a,o)).filter(o=>"attribute"in o&&!!o.attribute)),i=OP(n,({attribute:a})=>V.isLevelAttribute(a)&&V.isDatetime(a.type)?`${a.expression}.${a.granularity}`:a.expression);return Object.values(i).filter(a=>a.length>0&&!!a[0].attribute&&(!V.MetadataTypes.isCalculatedAttribute(a[0].attribute)||r)).map(a=>{const o=a[0].attribute,s=Ym(a.map(({value:c})=>c).filter(c=>c!=null)),u=Ym(a.map(({displayValue:c})=>c).filter(c=>c!==void 0));return{attribute:o,values:s,displayValues:u}})}function L2e(e){return wn(e,["category"])}function O2e(e){return wn(e,["category"])}function I2e(e,t){const n=wn(e,["category"],!0),i=n.length-1,a=E.translateColumnToAttribute(t.category[i]);return V.MetadataTypes.isCalculatedAttribute(a)?[]:t.category.map((o,s)=>{const u=i===s,c=E.translateColumnToAttribute(o);if(!V.MetadataTypes.isCalculatedAttribute(c))return u?n[s]:{attribute:c,values:[],displayValues:[]}}).filter(o=>o!==void 0)}function F2e(e){return wn(e,["x","y","breakByPoint","breakByColor"])}function $2e(e){return wn(e,["geo"])}function B2e(e){return wn(e,["geo"])}function z2e(e){return wn(e,["date"])}function H2e(e){return wn(e,["category"])}function W2e(e){const t=e.filter(r=>r.isDataCell&&!r.isTotalCell);return wn(t.map(r=>{var n,i,a,o,s,u;return(i=(n=r.entries)==null?void 0:n.values)!=null&&i.length?r:z(D({},r),{entries:{rows:(o=(a=r.entries.rows)==null?void 0:a.slice(-1))!=null?o:[],columns:(u=(s=r.entries.columns)==null?void 0:s.slice(-1))!=null?u:[],values:[]}})}),["rows","columns","values"])}function j2e(e,t){const r=Object.entries(t).filter(([,n])=>Array.isArray(n)&&n.some(i=>!E.isMeasureColumn(i))).map(([n])=>n);return wn(e,r)}function Yu(e,t,r){return e==="custom"?j2e(r,t):e==="text"?[]:e==="pivot"?W2e(r):e==="treemap"||e==="sunburst"?I2e(r,t):H.isCartesian(e)||e==="pie"||e==="funnel"?L2e(r):H.isBoxplot(e)?O2e(r):H.isScatter(e)?F2e(r):H.isScattermap(e)?$2e(r):H.isAreamap(e)?B2e(r):H.isCalendarHeatmap(e)?z2e(r):H.isSankey(e)?H2e(r):[]}function Yg(e,t){let r=[];return e==="custom"?r=V2e(t):e==="text"?r=[]:e==="pivot"?r=[...t.rows||[],...t.columns||[]]:H.isCartesian(e)||H.isCategorical(e)||H.isBoxplot(e)||H.isRange(e)?r=[...t.category]:H.isScatter(e)?r=[t.x,t.y,t.breakByPoint,t.breakByColor].filter(n=>!!(n&&!E.isMeasureColumn(n))):H.isScattermap(e)||H.isAreamap(e)?r=[...t.geo]:H.isCalendarHeatmap(e)?r=[t.date]:H.isSankey(e)&&(r=[...t.category]),r.map(E.translateColumnToAttribute).filter(n=>!V.MetadataTypes.isCalculatedAttribute(n))}function V2e(e){return Object.values(e).flatMap(t=>Array.isArray(t)?t.filter(r=>!E.isMeasureColumn(r)):[])}function U2e(e,t,r){const n=zP(t,e.attribute);if(!n||y.isIncludeAllFilter(n))return null;if(WP(e,n))return y.clearMembersFilter(e);if(V.isMembersFilter(n)&&r){const[i,a]=bl(n.members,s=>e.members.includes(s));if(i.length===e.members.length&&a.length)return HP(e.attribute,a,[n])}return null}function G2e(e,t,r){const n=t.filter(o=>!o.config.disabled),i=e.map(o=>U2e(o,n,r)).filter(o=>!!o),a=e.length!==i.length;return{filters:a?e:i,isSelection:a}}function Rf(e,t,r=!1){const n=e.map(({attribute:a,values:o})=>HP(a,o,t)),i=q2e(t,n);return G2e(i,t,r)}function q2e(e,t){const r=e.filter(n=>n.config.locked);return r.length?t.filter(n=>!r.some(i=>y.haveSameAttribute(i,n))):t}function Y2e(e,t,r){const n=Yu(e,t,r).filter(({displayValues:s})=>s.length);if(n.length===0)return"";const[i]=n,a=r.length===1,o=i.displayValues.length>jP;return n.length>1?a?n.map(s=>s.displayValues[0]).join(", "):o?"":i.displayValues.join(", "):o?i.attribute.title:i.displayValues.join(", ")}function S_(e,t,r){const n=Y2e(e,t,r);return n?{id:Ka.CROSSFILTERING_CHART_POINTS_SELECTION,sectionTitle:n}:null}function M_(e,t){return{items:[{caption:e,onClick:t}]}}function X2e(e,t){return Yg(e,t)[0]}function Z2e(e){return[...H.CARTESIAN_CHART_TYPES,...H.CATEGORICAL_CHART_TYPES,...H.SCATTER_CHART_TYPES,...H.BOXPLOT_CHART_TYPES,...H.RANGE_CHART_TYPES,...H.SANKEY_CHART_TYPES].includes(e)}function K2e(e,t){return Yg(e,t).length>=1}function Q2e(e,t){return K2e(e,t)&&Z2e(e)}function VP(e,t,r){const n=i=>!!i&&!y.isSameAttribute(r,E.translateColumnToAttribute(i));if(H.isSankey(e)){const i=t,a=i.category.findIndex(o=>!V.MetadataTypes.isCalculatedAttribute(E.translateColumnToAttribute(o)));if(a>=0&&n(i.category[a])){const o=[...i.category];return o[a]=r,z(D({},i),{category:o})}return t}if(H.isCartesian(e)||H.isCategorical(e)||H.isBoxplot(e)||H.isRange(e)){const i=t.category.find(a=>!V.MetadataTypes.isCalculatedAttribute(E.translateColumnToAttribute(a)));if(n(i))return z(D({},t),{category:[r]})}else if(H.isScatter(e)){const i=t,o=["x","y","breakByPoint","breakByColor"].find(s=>UP(i[s]));if(o){const s=i[o];if(n(s))return z(D({},i),{[o]:r})}}return t}function UP(e){return!!e&&!E.isMeasureColumn(e)&&!V.MetadataTypes.isCalculatedAttribute(E.translateColumnToAttribute(e))}function P_(e,t,r){return e.map(n=>{const i=["x","y","breakByPoint","breakByColor"],a=[...i,"size"].some(s=>s in n),o=i.find(s=>UP(r[s]));if(a){const s=t,u=s.type==="mouseup";u&&console.warn("No drilldown support for multi-selection in scatter chart");const c=u?n[o]:s.point.options.custom[kM(`{masked ${o}`)];return{categoryValue:c,categoryDisplayValue:c}}return n})}function Tc(e,t){return e.filter(r=>{if(V.MetadataTypes.isAttribute(r)){const a=r;return t.every(o=>!y.isSameAttribute(o,a))}const i=r;return t.every((a,o)=>i.levels[o]&&y.isSameAttribute(a,i.levels[o]))})}function Sc(e,t){return[E.translateColumnToAttribute(e),...t.map(({nextDimension:r})=>r)]}const J2e=Qa(_e.jsx("path",{d:"M6 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm-6 0c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"}),"MoreHoriz"),e_e=y.styled(y.ButtonBase)(y.memoTheme(({theme:e})=>z(D({display:"flex",marginLeft:`calc(${e.spacing(1)} * 0.5)`,marginRight:`calc(${e.spacing(1)} * 0.5)`},e.palette.mode==="light"?{backgroundColor:e.palette.grey[100],color:e.palette.grey[700]}:{backgroundColor:e.palette.grey[700],color:e.palette.grey[100]}),{borderRadius:2,"&:hover, &:focus":D({},e.palette.mode==="light"?{backgroundColor:e.palette.grey[200]}:{backgroundColor:e.palette.grey[600]}),"&:active":D({boxShadow:e.shadows[0]},e.palette.mode==="light"?{backgroundColor:y.emphasize(e.palette.grey[200],.12)}:{backgroundColor:y.emphasize(e.palette.grey[600],.12)})}))),t_e=y.styled(J2e)({width:24,height:16});function GP(e){const a=e,{slots:t={},slotProps:r={}}=a,n=Ye(a,["slots","slotProps"]),i=e;return _e.jsx("li",{children:_e.jsx(e_e,z(D({focusRipple:!0},n),{ownerState:i,children:_e.jsx(t_e,D({as:t.CollapsedIcon,ownerState:i},r.collapsedIcon))}))})}process.env.NODE_ENV!=="production"&&(GP.propTypes={slotProps:y.PropTypes.shape({collapsedIcon:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({CollapsedIcon:y.PropTypes.elementType}),sx:y.PropTypes.object});function r_e(e){return y.generateUtilityClass("MuiBreadcrumbs",e)}const n_e=y.generateUtilityClasses("MuiBreadcrumbs",["root","ol","li","separator"]),i_e=e=>{const{classes:t}=e,r={root:["root"],li:["li"],ol:["ol"],separator:["separator"]};return y.composeClasses(r,r_e,t)},a_e=y.styled(_r,{name:"MuiBreadcrumbs",slot:"Root",overridesResolver:(e,t)=>[{[`& .${n_e.li}`]:t.li},t.root]})({}),o_e=y.styled("ol",{name:"MuiBreadcrumbs",slot:"Ol",overridesResolver:(e,t)=>t.ol})({display:"flex",flexWrap:"wrap",alignItems:"center",padding:0,margin:0,listStyle:"none"}),s_e=y.styled("li",{name:"MuiBreadcrumbs",slot:"Separator",overridesResolver:(e,t)=>t.separator})({display:"flex",userSelect:"none",marginLeft:8,marginRight:8});function l_e(e,t,r,n){return e.reduce((i,a,o)=>(o<e.length-1?i=i.concat(a,_e.jsx(s_e,{"aria-hidden":!0,className:t,ownerState:n,children:r},`separator-${o}`)):i.push(a),i),[])}const qP=de.forwardRef(function(t,r){const n=y.useDefaultProps({props:t,name:"MuiBreadcrumbs"}),R=n,{children:i,className:a,component:o="nav",slots:s={},slotProps:u={},expandText:c="Show path",itemsAfterCollapse:d=1,itemsBeforeCollapse:h=1,maxItems:p=8,separator:m="/"}=R,g=Ye(R,["children","className","component","slots","slotProps","expandText","itemsAfterCollapse","itemsBeforeCollapse","maxItems","separator"]),[b,_]=de.useState(!1),w=z(D({},n),{component:o,expanded:b,expandText:c,itemsAfterCollapse:d,itemsBeforeCollapse:h,maxItems:p,separator:m}),C=i_e(w),S=y.useSlotProps({elementType:s.CollapsedIcon,externalSlotProps:u.collapsedIcon,ownerState:w}),T=de.useRef(null),M=k=>{const I=()=>{_(!0);const $=T.current.querySelector("a[href],button,[tabindex]");$&&$.focus()};return h+d>=k.length?(process.env.NODE_ENV!=="production"&&console.error(["MUI: You have provided an invalid combination of props to the Breadcrumbs.",`itemsAfterCollapse={${d}} + itemsBeforeCollapse={${h}} >= maxItems={${p}}`].join(`
503
+ `)),k):[...k.slice(0,h),_e.jsx(GP,{"aria-label":c,slots:{CollapsedIcon:s.CollapsedIcon},slotProps:{collapsedIcon:S},onClick:I},"ellipsis"),...k.slice(k.length-d,k.length)]},P=de.Children.toArray(i).filter(k=>(process.env.NODE_ENV!=="production"&&y.reactIsExports.isFragment(k)&&console.error(["MUI: The Breadcrumbs component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
504
+ `)),de.isValidElement(k))).map((k,I)=>_e.jsx("li",{className:C.li,children:k},`child-${I}`));return _e.jsx(a_e,z(D({ref:r,component:o,color:"textSecondary",className:y.clsx(C.root,a),ownerState:w},g),{children:_e.jsx(o_e,{className:C.ol,ref:T,ownerState:w,children:l_e(b||p&&P.length<=p?P:M(P),C.separator,m,w)})}))});process.env.NODE_ENV!=="production"&&(qP.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,component:y.PropTypes.elementType,expandText:y.PropTypes.string,itemsAfterCollapse:y.integerPropType,itemsBeforeCollapse:y.integerPropType,maxItems:y.integerPropType,separator:y.PropTypes.node,slotProps:y.PropTypes.shape({collapsedIcon:y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object])}),slots:y.PropTypes.shape({CollapsedIcon:y.PropTypes.elementType}),sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object])});function u_e(e){return y.generateUtilityClass("MuiButton",e)}const yi=y.generateUtilityClasses("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge","loading","loadingWrapper","loadingIconPlaceholder","loadingIndicator","loadingPositionCenter","loadingPositionStart","loadingPositionEnd"]),YP=de.createContext({});process.env.NODE_ENV!=="production"&&(YP.displayName="ButtonGroupContext");const XP=de.createContext(void 0);process.env.NODE_ENV!=="production"&&(XP.displayName="ButtonGroupButtonContext");const c_e=e=>{const{color:t,disableElevation:r,fullWidth:n,size:i,variant:a,loading:o,loadingPosition:s,classes:u}=e,c={root:["root",o&&"loading",a,`${a}${y.capitalize(t)}`,`size${y.capitalize(i)}`,`${a}Size${y.capitalize(i)}`,`color${y.capitalize(t)}`,r&&"disableElevation",n&&"fullWidth",o&&`loadingPosition${y.capitalize(s)}`],startIcon:["icon","startIcon",`iconSize${y.capitalize(i)}`],endIcon:["icon","endIcon",`iconSize${y.capitalize(i)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},d=y.composeClasses(c,u_e,u);return D(D({},u),d)},ZP=[{props:{size:"small"},style:{"& > *:nth-of-type(1)":{fontSize:18}}},{props:{size:"medium"},style:{"& > *:nth-of-type(1)":{fontSize:20}}},{props:{size:"large"},style:{"& > *:nth-of-type(1)":{fontSize:22}}}],d_e=y.styled(y.ButtonBase,{shouldForwardProp:e=>y.rootShouldForwardProp(e)||e==="classes",name:"MuiButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,t[r.variant],t[`${r.variant}${y.capitalize(r.color)}`],t[`size${y.capitalize(r.size)}`],t[`${r.variant}Size${y.capitalize(r.size)}`],r.color==="inherit"&&t.colorInherit,r.disableElevation&&t.disableElevation,r.fullWidth&&t.fullWidth,r.loading&&t.loading]}})(y.memoTheme(({theme:e})=>{const t=e.palette.mode==="light"?e.palette.grey[300]:e.palette.grey[800],r=e.palette.mode==="light"?e.palette.grey.A100:e.palette.grey[700];return z(D({},e.typography.button),{minWidth:64,padding:"6px 16px",border:0,borderRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create(["background-color","box-shadow","border-color","color"],{duration:e.transitions.duration.short}),"&:hover":{textDecoration:"none"},[`&.${yi.disabled}`]:{color:(e.vars||e).palette.action.disabled},variants:[{props:{variant:"contained"},style:{color:"var(--variant-containedColor)",backgroundColor:"var(--variant-containedBg)",boxShadow:(e.vars||e).shadows[2],"&:hover":{boxShadow:(e.vars||e).shadows[4],"@media (hover: none)":{boxShadow:(e.vars||e).shadows[2]}},"&:active":{boxShadow:(e.vars||e).shadows[8]},[`&.${yi.focusVisible}`]:{boxShadow:(e.vars||e).shadows[6]},[`&.${yi.disabled}`]:{color:(e.vars||e).palette.action.disabled,boxShadow:(e.vars||e).shadows[0],backgroundColor:(e.vars||e).palette.action.disabledBackground}}},{props:{variant:"outlined"},style:{padding:"5px 15px",border:"1px solid currentColor",borderColor:"var(--variant-outlinedBorder, currentColor)",backgroundColor:"var(--variant-outlinedBg)",color:"var(--variant-outlinedColor)",[`&.${yi.disabled}`]:{border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`}}},{props:{variant:"text"},style:{padding:"6px 8px",color:"var(--variant-textColor)",backgroundColor:"var(--variant-textBg)"}},...Object.entries(e.palette).filter(ri()).map(([n])=>({props:{color:n},style:{"--variant-textColor":(e.vars||e).palette[n].main,"--variant-outlinedColor":(e.vars||e).palette[n].main,"--variant-outlinedBorder":e.vars?`rgba(${e.vars.palette[n].mainChannel} / 0.5)`:y.alpha(e.palette[n].main,.5),"--variant-containedColor":(e.vars||e).palette[n].contrastText,"--variant-containedBg":(e.vars||e).palette[n].main,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":(e.vars||e).palette[n].dark,"--variant-textBg":e.vars?`rgba(${e.vars.palette[n].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha(e.palette[n].main,e.palette.action.hoverOpacity),"--variant-outlinedBorder":(e.vars||e).palette[n].main,"--variant-outlinedBg":e.vars?`rgba(${e.vars.palette[n].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha(e.palette[n].main,e.palette.action.hoverOpacity)}}}})),{props:{color:"inherit"},style:{color:"inherit",borderColor:"currentColor","--variant-containedBg":e.vars?e.vars.palette.Button.inheritContainedBg:t,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":e.vars?e.vars.palette.Button.inheritContainedHoverBg:r,"--variant-textBg":e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha(e.palette.text.primary,e.palette.action.hoverOpacity),"--variant-outlinedBg":e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:y.alpha(e.palette.text.primary,e.palette.action.hoverOpacity)}}}},{props:{size:"small",variant:"text"},style:{padding:"4px 5px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"text"},style:{padding:"8px 11px",fontSize:e.typography.pxToRem(15)}},{props:{size:"small",variant:"outlined"},style:{padding:"3px 9px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"outlined"},style:{padding:"7px 21px",fontSize:e.typography.pxToRem(15)}},{props:{size:"small",variant:"contained"},style:{padding:"4px 10px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"contained"},style:{padding:"8px 22px",fontSize:e.typography.pxToRem(15)}},{props:{disableElevation:!0},style:{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${yi.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${yi.disabled}`]:{boxShadow:"none"}}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{loadingPosition:"center"},style:{transition:e.transitions.create(["background-color","box-shadow","border-color"],{duration:e.transitions.duration.short}),[`&.${yi.loading}`]:{color:"transparent"}}}]})})),h_e=y.styled("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.startIcon,r.loading&&t.startIconLoadingStart,t[`iconSize${y.capitalize(r.size)}`]]}})(({theme:e})=>({display:"inherit",marginRight:8,marginLeft:-4,variants:[{props:{size:"small"},style:{marginLeft:-2}},{props:{loadingPosition:"start",loading:!0},style:{transition:e.transitions.create(["opacity"],{duration:e.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"start",loading:!0,fullWidth:!0},style:{marginRight:-8}},...ZP]})),f_e=y.styled("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.endIcon,r.loading&&t.endIconLoadingEnd,t[`iconSize${y.capitalize(r.size)}`]]}})(({theme:e})=>({display:"inherit",marginRight:-4,marginLeft:8,variants:[{props:{size:"small"},style:{marginRight:-2}},{props:{loadingPosition:"end",loading:!0},style:{transition:e.transitions.create(["opacity"],{duration:e.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"end",loading:!0,fullWidth:!0},style:{marginLeft:-8}},...ZP]})),p_e=y.styled("span",{name:"MuiButton",slot:"LoadingIndicator",overridesResolver:(e,t)=>t.loadingIndicator})(({theme:e})=>({display:"none",position:"absolute",visibility:"visible",variants:[{props:{loading:!0},style:{display:"flex"}},{props:{loadingPosition:"start"},style:{left:14}},{props:{loadingPosition:"start",size:"small"},style:{left:10}},{props:{variant:"text",loadingPosition:"start"},style:{left:6}},{props:{loadingPosition:"center"},style:{left:"50%",transform:"translate(-50%)",color:(e.vars||e).palette.action.disabled}},{props:{loadingPosition:"end"},style:{right:14}},{props:{loadingPosition:"end",size:"small"},style:{right:10}},{props:{variant:"text",loadingPosition:"end"},style:{right:6}},{props:{loadingPosition:"start",fullWidth:!0},style:{position:"relative",left:-10}},{props:{loadingPosition:"end",fullWidth:!0},style:{position:"relative",right:-10}}]})),E_=y.styled("span",{name:"MuiButton",slot:"LoadingIconPlaceholder",overridesResolver:(e,t)=>t.loadingIconPlaceholder})({display:"inline-block",width:"1em",height:"1em"}),qs=de.forwardRef(function(t,r){const n=de.useContext(YP),i=de.useContext(XP),a=y.resolveProps(n,t),o=y.useDefaultProps({props:a,name:"MuiButton"}),q=o,{children:s,color:u="primary",component:c="button",className:d,disabled:h=!1,disableElevation:p=!1,disableFocusRipple:m=!1,endIcon:g,focusVisibleClassName:b,fullWidth:_=!1,id:w,loading:C=null,loadingIndicator:S,loadingPosition:T="center",size:M="medium",startIcon:P,type:R,variant:k="text"}=q,I=Ye(q,["children","color","component","className","disabled","disableElevation","disableFocusRipple","endIcon","focusVisibleClassName","fullWidth","id","loading","loadingIndicator","loadingPosition","size","startIcon","type","variant"]),$=Mc(w),G=S!=null?S:_e.jsx(zg,{"aria-labelledby":$,color:"inherit",size:16}),Y=z(D({},o),{color:u,component:c,disabled:h,disableElevation:p,disableFocusRipple:m,fullWidth:_,loading:C,loadingIndicator:G,loadingPosition:T,size:M,type:R,variant:k}),B=c_e(Y),X=(P||C&&T==="start")&&_e.jsx(h_e,{className:B.startIcon,ownerState:Y,children:P||_e.jsx(E_,{className:B.loadingIconPlaceholder,ownerState:Y})}),U=(g||C&&T==="end")&&_e.jsx(f_e,{className:B.endIcon,ownerState:Y,children:g||_e.jsx(E_,{className:B.loadingIconPlaceholder,ownerState:Y})}),Q=i||"",W=typeof C=="boolean"?_e.jsx("span",{className:B.loadingWrapper,style:{display:"contents"},children:C&&_e.jsx(p_e,{className:B.loadingIndicator,ownerState:Y,children:G})}):null;return _e.jsxs(d_e,z(D({ownerState:Y,className:y.clsx(n.className,B.root,d,Q),component:c,disabled:h||C,focusRipple:!m,focusVisibleClassName:y.clsx(B.focusVisible,b),ref:r,type:R,id:C?$:w},I),{classes:B,children:[X,T!=="end"&&W,s,T==="end"&&W,U]}))});process.env.NODE_ENV!=="production"&&(qs.propTypes={children:y.PropTypes.node,classes:y.PropTypes.object,className:y.PropTypes.string,color:y.PropTypes.oneOfType([y.PropTypes.oneOf(["inherit","primary","secondary","success","error","info","warning"]),y.PropTypes.string]),component:y.PropTypes.elementType,disabled:y.PropTypes.bool,disableElevation:y.PropTypes.bool,disableFocusRipple:y.PropTypes.bool,disableRipple:y.PropTypes.bool,endIcon:y.PropTypes.node,focusVisibleClassName:y.PropTypes.string,fullWidth:y.PropTypes.bool,href:y.PropTypes.string,id:y.PropTypes.string,loading:y.PropTypes.bool,loadingIndicator:y.PropTypes.node,loadingPosition:y.PropTypes.oneOf(["center","end","start"]),size:y.PropTypes.oneOfType([y.PropTypes.oneOf(["small","medium","large"]),y.PropTypes.string]),startIcon:y.PropTypes.node,sx:y.PropTypes.oneOfType([y.PropTypes.arrayOf(y.PropTypes.oneOfType([y.PropTypes.func,y.PropTypes.object,y.PropTypes.bool])),y.PropTypes.func,y.PropTypes.object]),type:y.PropTypes.oneOfType([y.PropTypes.oneOf(["button","reset","submit"]),y.PropTypes.string]),variant:y.PropTypes.oneOfType([y.PropTypes.oneOf(["contained","outlined","text"]),y.PropTypes.string])});const m_e=y.newStyled(vn)`
505
+ && {
506
+ position: absolute;
507
+ left: 0;
508
+ right: auto;
509
+ margin: auto;
510
+ bottom: 0;
511
+ top: 0;
512
+ z-index: 10;
513
+ background: linear-gradient(to right, white 30%, rgba(255, 255, 255, 0) 100%);
514
+ display: inline-flex;
515
+
516
+ span[aria-label='prev-item'] {
517
+ width: 0;
518
+ height: 0;
519
+ border-top: 6px solid transparent;
520
+ border-bottom: 6px solid transparent;
521
+ border-right: 5px solid #000;
522
+ color: transparent;
523
+ opacity: 0.3;
524
+
525
+ &:hover {
526
+ opacity: 0.8;
527
+ }
528
+ }
529
+ }
530
+ `,g_e=y.newStyled(vn)`
531
+ && {
532
+ position: absolute;
533
+ left: auto;
534
+ right: 0;
535
+ margin: auto;
536
+ bottom: 0;
537
+ top: 0;
538
+ z-index: 10;
539
+ background: linear-gradient(to right, rgba(255, 255, 255, 0) 0, white 70%);
540
+ display: inline-flex;
541
+
542
+ span[aria-label='next-item'] {
543
+ width: 0;
544
+ height: 0;
545
+ border-top: 6px solid transparent;
546
+ border-bottom: 6px solid transparent;
547
+ border-left: 5px solid #000;
548
+ color: transparent;
549
+ opacity: 0.3;
550
+
551
+ &:hover {
552
+ opacity: 0.8;
553
+ }
554
+ }
555
+ }
556
+ `,v_e=({currentDimension:e,children:t})=>{const{t:r}=O.useTranslation(),n=N.useRef(null),[i,a]=N.useState(0),[o,s]=N.useState(0),[u,c]=N.useState(0),d=()=>{var g;return(g=n.current)==null?void 0:g.querySelector("ol")};N.useEffect(()=>{const g=d();if(g){const b=g.clientWidth,_=g.scrollWidth,w=g.scrollLeft;a(b),s(_),c(w)}},[e]),N.useEffect(()=>{const g=d();function b(){if(g){const C=g.clientWidth;a(C)}}function _(){if(g){const C=g.scrollLeft;c(C)}}const w=new ResizeObserver(b);return g?(w.observe(g),g.addEventListener("scroll",_),()=>{w.disconnect(),g.removeEventListener("scroll",_)}):()=>{}},[]);const h=g=>{const _="smooth",w=d();w&&w.scrollBy({left:g==="right"?200:-200,behavior:_})},p=u!=0,m=Math.floor(o-u)>i;return O.jsxs("div",{style:{position:"relative"},children:[p&&O.jsx(m_e,{onClick:()=>h("left"),children:O.jsx("span",{"aria-label":"prev-item",children:r("drilldown.breadcrumbsPrev")})}),m&&O.jsx(g_e,{onClick:()=>h("right"),children:O.jsx("span",{"aria-label":"next-item",children:r("drilldown.breadcrumbsNext")})}),O.jsx("div",{ref:n,children:t})]})},y_e=({clearDrilldownSelections:e,currentDimension:t,setIsHovered:r,themeProps:n})=>{const{t:i}=O.useTranslation(),a=t.name,o=y.newStyled(qs)`
557
+ && {
558
+ background-color: ${n.activeDrillBackgroundColor};
559
+ color: ${n.primaryButtonTextColor};
560
+ border-radius: 100%;
561
+ border: 2px solid white;
562
+ min-width: 39px;
563
+ width: 39px;
564
+ height: 39px;
565
+ z-index: 10;
566
+ padding: 7px;
567
+ cursor: pointer;
568
+ text-transform: none;
569
+ margin-right: -5px;
570
+
571
+ &:hover {
572
+ background-color: ${n.activeDrillHoverBackgroundColor};
573
+ color: ${n.primaryTextColor};
574
+ }
575
+ }
576
+ `,s=y.newStyled.svg`
577
+ width: 22px;
578
+ height: 22px;
579
+ fill: #9ea2ab;
580
+ `,u=()=>O.jsx(o,{theme:n,onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1),onClick:e,children:O.jsx(s,{width:22,height:22,viewBox:"0 0 24 24",children:O.jsx("path",{fill:"#9EA2AB",d:"M12 12.293L6.854 7.146a.5.5 0 1 0-.708.708L11.293 13l-5.147 5.146a.5.5 0 0 0 .708.708L12 13.707l5.146 5.147a.5.5 0 0 0 .708-.708L12.707 13l5.147-5.146a.5.5 0 0 0-.708-.708L12 12.293z"})})}),c=y.newStyled(qs)`
581
+ && {
582
+ position: relative;
583
+ font-family: ${h=>h.theme.fontFamily};
584
+ border-radius: 0;
585
+ border: 1px solid ${un};
586
+ background-color: ${h=>h.theme.chartBackgroundColor};
587
+ border-right: none;
588
+ border-left: none;
589
+ color: ${h=>h.theme.secondaryTextColor};
590
+ padding-right: 1.25rem;
591
+ padding-left: 1.875rem;
592
+ height: 1.64rem;
593
+ font-size: 13px;
594
+ transition: background-color 0.2s, border-color 0.2s, color 0.2s;
595
+ text-transform: none;
596
+ cursor: auto;
597
+ pointer-events: none;
598
+ white-space: nowrap;
599
+
600
+ &:hover {
601
+ background-color: ${h=>h.theme.chartBackgroundColor};
602
+ border: 1px solid ${un};
603
+ border-right: none;
604
+ border-left: none;
605
+ }
606
+ }
607
+ `;return{CancelButton:u,CurrentDrillButton:()=>O.jsxs(c,{theme:n,children:[a," (",i("drilldown.breadcrumbsAllSuffix"),")",O.jsx("span",{className:"flex items-center justify-between",children:O.jsx("span",{className:"csdk-absolute csdk-right-[0px] csdk-top-[3px] csdk-h-[18px] csdk-w-[18px] csdk-transform csdk-translate-x-1/2 csdk-rotate-45",style:{backgroundColor:"transparent",borderTop:`1px solid ${un}`,borderRight:`1px solid ${un}`}})})]})}},b_e={modifiers:[{name:"offset",options:{offset:[0,12]}}]},__e=({themeProps:e,filterDisplayValues:t,currentTable:r,currentColumn:n})=>{const{t:i}=O.useTranslation();return O.jsxs("div",{className:"csdk-w-50 csdk-px-[12px] csdk-shadow-md csdk-shadow-gray-500 csdk-rounded-md csdk-bg-white",style:{backgroundColor:e.chartBackgroundColor,color:e.primaryTextColor},children:[O.jsxs("div",{className:"csdk-border-b csdk-border-[#e4e4e4] csdk-p-3 csdk-pl-1",children:[O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:11,children:i("drilldown.popover.members")}),O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:13,children:t.join(", ")})]}),O.jsxs("div",{className:"csdk-border-b csdk-border-[#e4e4e4] csdk-p-3 csdk-pl-1",children:[O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:11,children:i("drilldown.popover.table")}),O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:13,children:r})]}),O.jsxs("div",{className:"csdk-p-3 csdk-pl-1",children:[O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:11,children:i("drilldown.popover.column")}),O.jsx(_r,{variant:"body2",fontFamily:e.fontFamily,fontSize:13,children:n})]})]})},w_e=({popperParams:e,currentDimension:t,themeProps:r})=>{const n=t.expression.match(/\[(.*?)]/),[i,a]=n?n[1].split("."):["",""],o=!!e;return O.jsx(fl,{open:o,anchorEl:e==null?void 0:e.anchorEl,placement:"bottom",popperOptions:b_e,children:e&&O.jsx(__e,{themeProps:r,filterDisplayValues:e.filterDisplayValues,currentTable:i,currentColumn:a})})},C_e=()=>{const{themeSettings:{typography:{primaryTextColor:e,secondaryTextColor:t,fontFamily:r},general:{backgroundColor:n,brandColor:i,primaryButtonTextColor:a},chart:{backgroundColor:o}}}=y.useThemeContext(),s=E.scaleBrightness(o,-.02),u=E.scaleBrightness(s,-.05);return{primaryTextColor:e,secondaryTextColor:t,fontFamily:r,backgroundColor:n,brandColor:i,primaryButtonTextColor:a,chartBackgroundColor:o,activeDrillBackgroundColor:s,activeDrillHoverBackgroundColor:u}},un="#F2F2F2",x_e=y.newStyled(qs)`
608
+ && {
609
+ font-family: ${({theme:e})=>e.fontFamily};
610
+ position: relative;
611
+ border-radius: 0;
612
+ border: 1px solid ${un};
613
+ border-right: none;
614
+ color: ${({active:e,theme:t})=>e==="true"?t.primaryTextColor:t.secondaryTextColor};
615
+ background-color: ${({active:e,theme:t})=>e==="true"?t.activeDrillBackgroundColor:t.chartBackgroundColor};
616
+ padding-right: 1.25rem;
617
+ padding-left: 1.875rem;
618
+ height: 1.64rem;
619
+ font-size: 13px;
620
+ text-transform: none;
621
+ transition: background-color 0.2s, border-color 0.2s, color 0.2s;
622
+ white-space: nowrap;
623
+ cursor: ${({active:e})=>e==="true"?"pointer":"auto"};
624
+ margin-right: ${({active:e})=>e==="true"?"5px":"0px"};
625
+
626
+ &:hover {
627
+ background-color: ${({active:e,theme:t})=>e==="true"?t.activeDrillHoverBackgroundColor:t.chartBackgroundColor};
628
+ border: 1px solid ${un};
629
+ border-right: none;
630
+ }
631
+
632
+ .MuiTouchRipple-root {
633
+ display: none;
634
+ }
635
+ }
636
+ `,T_e=y.newStyled(qP)`
637
+ .MuiBreadcrumbs-ol {
638
+ flex-wrap: nowrap;
639
+ overflow: hidden;
640
+ }
641
+ .MuiBreadcrumbs-separator {
642
+ display: none;
643
+ }
644
+ `,S_e=({isActive:e,filterDisplayValue:t,handleMouseEnter:r,handleMouseLeave:n,handleClick:i,themeProps:a,popperParams:o,index:s})=>O.jsx(x_e,{theme:a,active:e.toString(),index:s,onMouseEnter:r,onMouseLeave:n,onClick:i,children:O.jsxs("span",{className:"flex items-center justify-between",children:[O.jsxs("span",{className:"mr-2",children:[t.slice(0,2).join(", "),t.length>2&&", ..."]}),e?O.jsx("span",{className:"csdk-absolute csdk-right-0 csdk-h-[18px] csdk-w-[18px] csdk-top-[3px] csdk-translate-x-1/2 csdk-rotate-45",style:{backgroundColor:t===(o==null?void 0:o.filterDisplayValues)?a.activeDrillHoverBackgroundColor:a.activeDrillBackgroundColor,borderTop:`1px solid ${un}`,borderRight:`1px solid ${un}`,transition:"background-color 0.2s, border-color 0.2s, color 0.2s",zIndex:8}}):void 0,O.jsx("span",{className:`csdk-absolute ${e?"csdk-h-[18px] csdk-w-[18px] csdk-top-[3px] csdk-right-[-15px]":"csdk-h-[10px] csdk-w-[10px] csdk-top-[7px] csdk-right-[-5px]"} csdk-transform translate-x-1/2 csdk-rotate-45`,style:{backgroundColor:a.chartBackgroundColor,borderTop:`1px solid ${un}`,borderRight:`1px solid ${un}`,zIndex:7,transition:"background-color 0.2s, border-color 0.2s, color 0.2s"}})]})}),KP=y.asSisenseComponent({componentName:"DrilldownBreadcrumbs",shouldSkipSisenseContextWaiting:!0})(({filtersDisplayValues:e,currentDimension:t,clearDrilldownSelections:r,sliceDrilldownSelections:n})=>{const[i,a]=N.useState(null),[o,s]=N.useState(!1),u=C_e(),{CancelButton:c,CurrentDrillButton:d}=y_e({clearDrilldownSelections:r,currentDimension:t,isHovered:o,setIsHovered:s,themeProps:u}),h=b=>_=>{s(!0),a({filterDisplayValues:b,anchorEl:_.currentTarget})},p=()=>{s(!1),a(null)},m=b=>b<e.length-1,g=b=>b===e.length-2;return e.length?O.jsx("div",{"data-testid":"drilldown-breadcrumbs",children:O.jsx(v_e,{currentDimension:t,children:O.jsxs(T_e,{separator:null,sx:{backgroundColor:u.chartBackgroundColor,padding:"4px"},children:[O.jsx(c,{}),e.map((b,_)=>{const w=m(_),C=g(_);return O.jsx("div",{children:O.jsx(S_e,{isActive:w,isLastActive:C,filterDisplayValue:b,handleMouseEnter:h(b),handleMouseLeave:p,handleClick:()=>n(_+1),themeProps:u,popperParams:i,index:_})},_)}),O.jsx(d,{}),O.jsx(w_e,{popperParams:i,currentDimension:t,themeProps:u})]})})}):null}),QP=e=>{const{initialDimension:t,onDrilldownSelectionsChange:r}=e,n=N.useMemo(()=>e.drilldownPaths||[],[e.drilldownPaths]),i=N.useMemo(()=>e.initialDrilldownSelections||[],[e.initialDrilldownSelections]),{t:a}=O.useTranslation();if(!t)throw new V.TranslatableError("errors.drilldownNoInitialDimension");const[o,s]=Og(i,{onLocalStateChange:r}),u=N.useMemo(()=>Sc(t,o),[t,o]),c=N.useMemo(()=>Tc(n,u),[n,u]),d=N.useCallback((_,w,C)=>{s(S=>JP(S,_,w,C))},[s]),h=N.useCallback(_=>{s(w=>w.slice(0,_))},[s]),p=N.useCallback(()=>{s([])},[s]),{drilldownFilters:m,drilldownFiltersDisplayValues:g,drilldownDimension:b}=N.useMemo(()=>eE(o,t,a),[o,t,a]);return{drilldownSelections:o,availableDrilldownPaths:c,drilldownFilters:m,drilldownFiltersDisplayValues:g,drilldownDimension:b,selectDrilldown:d,sliceDrilldownSelections:h,clearDrilldownSelections:p}},JP=(e,t,r,n)=>{var p,m;if(!(n!=null&&n.levels))return[...e,{points:t,nextDimension:r}];if(y.isSameAttribute(n.levels[0],r))return[];const a=(p=e==null?void 0:e.findIndex(g=>y.isSameAttribute(g.nextDimension,r)))!=null?p:-1;if(a!==-1)return e.slice(0,a+1);const s=(m=V.last(e))==null?void 0:m.nextDimension,u=e.length?n.levels.findIndex(g=>s&&y.isSameAttribute(g,s)):0,c=n.levels.indexOf(r),h=n.levels.slice(u+1,c+1).map((g,b)=>({points:b===0?t:[],nextDimension:g}));return[...e,...h]},eE=(e,t,r)=>{let n=t&&E.translateColumnToAttribute(t);const i=[],a=[];return e.forEach(({points:o,nextDimension:s})=>{i.push(V.members(n,o.map(M_e)));const u=o.length?o.map(tE):[`${n.name} (${r("drilldown.breadcrumbsAllSuffix")})`];a.push(u),n=s}),{drilldownFilters:i,drilldownFiltersDisplayValues:a,drilldownDimension:n}};function tE(e){return"categoryDisplayValue"in e?`${e.categoryDisplayValue}`:"categoryValue"in e?`${e.categoryValue}`:""}function M_e(e){return"categoryValue"in e?`${e.categoryValue}`:""}const rE=({initialDimension:e,initialDrilldownSelections:t,openMenu:r,onDrilldownSelectionsChange:n})=>{const{t:i}=O.useTranslation(),{drilldownFilters:a,drilldownFiltersDisplayValues:o,drilldownDimension:s,drilldownSelections:u,selectDrilldown:c,sliceDrilldownSelections:d,clearDrilldownSelections:h}=QP({initialDimension:e,initialDrilldownSelections:t,onDrilldownSelectionsChange:n}),p=N.useCallback((g,b,_=[],w)=>{const C=iE(_,s,(T,M)=>{w==null||w(T,M),c(b,T,M)},i),S=[nE(b,s),...C?[C]:[]];r({id:Gs.WIDGET_POINTS_DRILLDOWN,position:g,itemSections:S})},[s,i,c,r]),m=N.useMemo(()=>s&&O.jsx(KP,{filtersDisplayValues:o,currentDimension:s,clearDrilldownSelections:h,sliceDrilldownSelections:d}),[h,s,o,d]);return{drilldownDimension:s,drilldownSelections:u,drilldownFilters:a,breadcrumbs:m,openDrilldownMenu:p}};function nE(e,t){const r=Ym(e.map(tE).filter(n=>!!n));return r.length>jP?{id:Ka.DRILLDOWN_CHART_POINTS_SELECTION,sectionTitle:t.name}:{id:Ka.DRILLDOWN_CHART_POINTS_SELECTION,sectionTitle:r.join(", ")}}function P_e(e){return 30+12*e}function iE(e,t,r,n){const[i,a]=bl(e,V.MetadataTypes.isAttribute.bind(V.MetadataTypes)),o=i.map(c=>({caption:c.name,onClick:()=>r(c)})),u=[...a.map(c=>({caption:c.title,subItems:[{items:c.levels.map((d,h)=>({caption:d.name,class:h===0?"":"csdk-drilldown-hierarchy-nested-menu-item",style:{paddingLeft:`${P_e(h)}px`},disabled:y.isSameAttribute(d,t),onClick:()=>r(d,c)}))}]})),...o];return u.length===0?null:{id:Ka.DRILLDOWN_DRILL_DIRECTIONS,sectionTitle:n("drilldown.drillMenuItem"),items:u}}function E_e(e){const{_id:t,title:r,levels:n}=e;return{id:t,title:r,levels:n.map(i=>V.createDimensionalElementFromJaql(i))}}function aE(e,t,r){return ht(this,null,function*(){const i=yield new Kc(e,r).getHierarchies(t);return i==null?void 0:i.map(a=>E_e(a))})}function oE(){const{isInitialized:e,app:t}=y.useSisenseContext();return{getHierarchies:N.useCallback(n=>ht(this,null,function*(){const{attribute:i,dataSource:a,ids:o}=n;if(!e||!t)throw new V.TranslatableError("errors.noSisenseContext");return aE(t.httpClient,{dimension:i,dataSource:a,ids:o,alwaysIncluded:!0},t.defaultDataSource)}),[e,t])}}function A_e(e){const t=y.useHasChanged(e,["attribute","dataSource","drilldownPaths","enabled"]),{attribute:r,dataSource:n,drilldownPaths:i,enabled:a}=e,[o,s]=N.useMemo(()=>bl(i,ed),[i]),{getHierarchies:u}=oE(),[c,d]=N.useState([]);return N.useEffect(()=>{(a||a===void 0)&&t&&u({attribute:r,dataSource:n,ids:o}).then(p=>{d(m=>p.length>0||m.length!==p.length?p:m)}).catch(p=>{console.error("Failed to load hierarchies",p)})},[t,a,r,n,o,u]),N.useMemo(()=>c.length?[...c,...s]:s,[c,s])}const R_e=({propsToExtend:e,onDrilldownSelectionsChange:t})=>{const{chartType:r,dataOptions:n,dataSource:i,drilldownOptions:a}=e,{drilldownSelections:o}=a||{},{openMenu:s}=Hg(),u=N.useMemo(()=>Q2e(r,n),[r,n]),c=N.useMemo(()=>(a==null?void 0:a.drilldownPaths)||[],[a==null?void 0:a.drilldownPaths]),d=N.useMemo(()=>{const I=V.createAttribute({name:"dummy drilldown initial attribute"});return X2e(r,n)||I},[r,n]),h=A_e({attribute:d,dataSource:i,drilldownPaths:c,enabled:u}),p=N.useRef(h);N.useEffect(()=>{p.current=h},[h]);const m=N.useMemo(()=>{var $;return(!!(($=a==null?void 0:a.drilldownSelections)!=null&&$.length)||!!(h!=null&&h.length))&&u},[a,u,h]),{drilldownDimension:g,drilldownFilters:b,breadcrumbs:_,openDrilldownMenu:w}=rE({initialDimension:d,initialDrilldownSelections:o,openMenu:s,onDrilldownSelectionsChange:t}),C=N.useCallback((I,$)=>{const G=P_(I,$,n),Y=Sc(d,o||[]),B=Tc(p.current,Y);w({left:$.clientX,top:$.clientY},G,B)},[n,d,o,w]),S=N.useCallback((I,$)=>{const G=P_([I],$,n),Y=Sc(d,o||[]),B=Tc(p.current,Y);w({left:$.clientX,top:$.clientY},G,B)},[n,d,o,w]),T=N.useMemo(()=>u?VP(r,n,g):n,[r,n,g,u]),M=N.useMemo(()=>b.length?H.mergeFiltersOrFilterRelations(e.filters||[],b):e.filters,[e.filters,b]),P=N.useMemo(()=>E.combineHandlers([C,e.onDataPointsSelected]),[C,e.onDataPointsSelected]),R=N.useMemo(()=>E.combineHandlers([S,e.onDataPointContextMenu]),[S,e.onDataPointContextMenu]);return{propsWithDrilldown:z(D({},e),{dataOptions:T,filters:M,onDataPointsSelected:P,onDataPointContextMenu:R}),isDrilldownEnabled:m,breadcrumbs:_}},D_e=y.asSisenseComponent({componentName:"ChartWidget"})(e=>{var q,ee,Z;IM({widgetType:"chart",widgetName:K2(e),widgetTitle:BM(e),entityId:$M(e,"chart",K2(e)),enabled:!!(e.chartType&&e.dataOptions)});const{app:t}=y.useSisenseContext(),{chartType:r,dataSource:n=t==null?void 0:t.defaultDataSource,dataOptions:i,styleOptions:a,highlightSelectionDisabled:o=!1,highlights:s,description:u,onChange:c}=e,{width:d,height:h}=a||{},p=N.useMemo(()=>{var J;return H_(r,{hasHeader:!((J=a==null?void 0:a.header)!=null&&J.hidden)})},[r,(q=a==null?void 0:a.header)==null?void 0:q.hidden]),m=N.useMemo(()=>({width:d,height:h}),[d,h]),[g,b]=N.useState(0),_=N.useMemo(()=>V.omit(a,["width","height"]),[a]),w=N.useCallback(J=>{c==null||c({type:"drilldownSelections/changed",payload:J})},[c]),{headerConfig:C,titleEditor:S}=FM({title:e.title,onChange:e.onChange,headerConfig:(ee=e.config)==null?void 0:ee.header}),{headerConfig:T}=jye({baseHeaderConfig:C,title:e.title,chartType:r,dataOptions:i,dataSource:n,filters:e.filters,highlights:e.highlights,config:e.config}),{headerConfig:M}=fbe({baseHeaderConfig:T,title:e.title,chartType:r,dataOptions:i,dataSource:n,filters:e.filters,config:e.config,id:e.id}),{propsWithDrilldown:P,isDrilldownEnabled:R,breadcrumbs:k}=R_e({propsToExtend:e,onDrilldownSelectionsChange:w}),{contentAreaRef:I,styleOptionsWithNarrative:$,narrativeTopSlot:G,narrativeBottomSlot:Y,narrativeAloneContent:B}=T2e({propsWithDrilldown:P,styleOptions:a}),X=R1e({chartType:r,dataOptions:i,enabled:!o&&!R&&!(s!=null&&s.length)}),U=(Z=t==null?void 0:t.settings.accessibilityConfig)==null?void 0:Z.enabled,Q=N.useCallback(J=>{var ne;return U?z(D({},J),{accessibility:z(D({},J.accessibility),{description:u!=null?u:(ne=J.accessibility)==null?void 0:ne.description})}):J},[u,U]);if(!r||!i)return null;const W=z(D({},P),{dataSet:n,styleOptions:_,refreshCounter:g,onDataPointClick:N.useMemo(()=>E.combineHandlers([X.onDataPointClick,e.onDataPointClick]),[X.onDataPointClick,e.onDataPointClick]),onDataPointContextMenu:P.onDataPointContextMenu,onDataPointsSelected:N.useMemo(()=>E.combineHandlers([X.onDataPointsSelected,P.onDataPointsSelected]),[X.onDataPointsSelected,P.onDataPointsSelected]),onBeforeRender:N.useMemo(()=>E.combineHandlers([Q,X.onBeforeRender,e.onBeforeRender],!0),[Q,X.onBeforeRender,e.onBeforeRender])});return O.jsx(Pc,{defaultSize:p,size:m,children:O.jsx(ZM,z(D({},e),{styleOptions:$,headerConfig:M,titleEditor:S,contentAreaRef:I,topSlot:O.jsxs(O.Fragment,{children:[e.topSlot,G,k]}),dataSetName:n&&V.getDataSourceName(n),onRefresh:()=>b(g+1),bottomSlot:O.jsxs(O.Fragment,{children:[Y,e.bottomSlot]}),children:B!=null?B:O.jsx(fM,D({},W))}))})}),sE=()=>O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",children:O.jsx("path",{d:"M13.0908 2.20223C13.286 2.00704 13.6026 2.00699 13.7978 2.20223C13.993 2.39747 13.993 2.71402 13.7978 2.90926L8.70698 8.00008L13.7978 13.0909C13.9929 13.2862 13.993 13.6027 13.7978 13.7979C13.6026 13.9931 13.286 13.993 13.0908 13.7979L7.99995 8.70711L2.90913 13.7979C2.71389 13.9931 2.39735 13.9931 2.2021 13.7979C2.00687 13.6027 2.00692 13.2862 2.2021 13.0909L7.29292 8.00008L2.2021 2.90926C2.00685 2.714 2.00685 2.39749 2.2021 2.20223C2.39736 2.00697 2.71387 2.00697 2.90913 2.20223L7.99995 7.29305L13.0908 2.20223Z",fill:"#2C2E32"})});function lE(e,t,r){var u,c;const n=r!=null&&r.filterId&&(u=e.find(d=>d.config.guid===r.filterId))!=null?u:null,i=n!==null&&!y.isSameAttribute(n.attribute,t),a=i?null:n,o=i||r==null?void 0:r.filterId,s=o?null:(c=e.find(d=>y.isSameAttribute(d.attribute,t)))!=null?c:null;return{filter:a!=null?a:s,validLinkGuid:o}}function A_(e,t){e.config.guid=t}function N_e(e){return t=>{const{attribute:r}=t,{filters:n,setFilters:i,link:a,setLink:o}=e,{filter:s,validLinkGuid:u}=lE(n,r,a),c=u?null:s;return{filter:s,onChange:h=>{if(h===null){u&&i(n.filter(m=>m.config.guid!==u));return}const p=u;if(p){A_(h,p);const m=n.map(b=>b.config.guid===p?h:b),g=n.some(b=>b.config.guid===p)?m:[...m,h];i(g)}else c?(A_(h,c.config.guid),o({filterId:c.config.guid}),i(n.map(m=>m.config.guid===c.config.guid?h:m))):(o({filterId:h.config.guid}),i([...n,h]))}}}}function k_e(e){const t={};return{flatFilters:e.reduce((n,i)=>(V.isCascadingFilter(i)?(t[i.config.guid]||(t[i.config.guid]=[]),i.filters.forEach(a=>{t[i.config.guid].push(a),n.push(a)})):n.push(i),n),[]),cascadingToPureFiltersMap:t}}function uE(e,t,r){const n=t.filter(V.isCascadingFilter);return O_e(e,n).map(a=>{if(L_e(a)){const o=n.find(u=>u.config.guid===a.groupId);if(!o)throw new V.TranslatableError("errors.cascadingFilterOriginalNotFound");const s=r==null?void 0:r.shouldResetFiltersDeeperThanModified;return I_e(a,o,{shouldResetFiltersDeeperThanModified:s})}return a})}function L_e(e){return"groupId"in e}function O_e(e,t){const r=[];return e.forEach(n=>{const i=t.find(a=>a.filters.some(o=>H.getFilterCompareId(o)===H.getFilterCompareId(n)));if(i){const a=i.config.guid,o=r.find(s=>"groupId"in s&&s.groupId===a);o?o.filters.push(n):r.push({groupId:a,filters:[n],previousFilters:i.filters})}else r.push(n)}),r}function I_e(e,t,r){const n=r!=null&&r.shouldResetFiltersDeeperThanModified?B_e(e.filters,e.previousFilters):e.filters,i=F_e(n,t.config.disabled);return V.cascading(n,{guid:t.config.guid,disabled:i})}function F_e(e,t){return e.some(n=>n.config.disabled!==t)?!t:t}function $_e(e,t,r){const{flatFilters:n,cascadingToPureFiltersMap:i}=k_e(e);return{pureFilters:n,updateFilters:o=>{const s=uE(o,e,{shouldResetFiltersDeeperThanModified:!0});t(s)},pureFiltersIgnoringRules:z_e(r,i)}}function B_e(e,t){const r=e.reduce((n,i,a)=>{const o=t.find(s=>y.haveSameAttribute(s,i));return o&&!WP(i,o)?a:n},-1);return r===-1?e:e.map((n,i)=>i>r?y.clearMembersFilter(n):n)}function z_e(e,t){var r;return{all:e.all,ids:((r=e.ids)==null?void 0:r.reduce((n,i)=>{const a=t[i];return a?n.concat(a.map(o=>o.config.guid)):n.concat(i)},[]))||[]}}const H_e=y.newStyled.button`
645
+ color: ${({theme:e})=>{var t;return(t=e.chart)==null?void 0:t.textColor}};
646
+ background: none;
647
+ font-size: 13px;
648
+ border: none;
649
+ height: 26px;
650
+ padding: 0 6px 0 2px;
651
+ margin: 0 4px 0 4px;
652
+ border-radius: 4px;
653
+ cursor: pointer;
654
+ display: flex;
655
+ align-items: center;
656
+ justify-content: center;
657
+ &:hover {
658
+ background-color: rgba(247, 247, 247, 1);
659
+ }
660
+ `,W_e=y.newStyled.span`
661
+ color: ${({theme:e})=>{var t;return(t=e.chart)==null?void 0:t.textColor}};
662
+ display: inline-block;
663
+ padding-top: 3px;
664
+ white-space: nowrap;
665
+ `,j_e=({onClick:e})=>{var n;const{themeSettings:t}=y.useThemeContext(),{t:r}=O.useTranslation();return O.jsxs(H_e,{onClick:e,theme:t,"data-testid":"csdk-clear-selection-button",children:[O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",children:O.jsx("path",{fill:(n=t.chart)==null?void 0:n.textColor,d:"M7.187 7l9.774 10.279A1 1 0 0 0 17 17V8a1 1 0 0 0-1-1H7.187zm9.018 10.979L6.206 7.463l.487-.415A1 1 0 0 0 6 8v9a1 1 0 0 0 1 1h9c.07 0 .139-.007.205-.021zM7 6h9a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2z"})}),O.jsx(W_e,{theme:t,children:r("commonFilter.clearSelectionButton")})]})},R_={applyMode:yl.HIGHLIGHT,shouldAffectFilters:!0,ignoreFilters:{all:!1,ids:[]},forceApplyBackgroundFilters:!0};function V_e(e,t){return e==="table"?{applyMode:yl.FILTER,shouldAffectFilters:!1,ignoreFilters:E.merge(R_.ignoreFilters,t.ignoreFilters||{})}:E.merge(R_,t)}function U_e(e,t,r,n,i,a,o){const s={},u=V_e(r,i),{pureFilters:c,updateFilters:d,pureFiltersIgnoringRules:h}=$_e(e,t,u.ignoreFilters||{}),p=c.filter(S=>!S.config.disabled),m=D2e(p,h),g=Yg(r,n),b=u.shouldAffectFilters&&g.length,[_,w]=q_e(m,g,u.applyMode),C=u.forceApplyBackgroundFilters?H.mergeFilters(G_e(c),_):_;if(s.filters=C,s.highlights=w,s.onDataPointsSelected=(S,T)=>{const M=[];if(b){const P=S_(r,n,S);P&&M.push(P);const R=Yu(r,n,S),{filters:k,isSelection:I}=Rf(R,c,!0),$=a(I?"commonFilter.selectMenuItem":"commonFilter.unselectMenuItem"),G=M_($,()=>{d(H.mergeFilters(c,k))});M.push(G)}M.length&&(o==null||o({id:Gs.WIDGET_POINTS_CROSSFILTERING,position:{left:T.clientX,top:T.clientY},itemSections:M}))},s.onDataPointContextMenu=(S,T)=>{const M=[];if(b){const P=S_(r,n,[S]);P&&M.push(P);const R=Yu(r,n,[S]);if(!R.length)return;const{filters:k,isSelection:I}=Rf(R,c,!0),$=a(I?"commonFilter.selectMenuItem":"commonFilter.unselectMenuItem"),G=M_($,()=>{d(H.mergeFilters(c,k))});M.push(G)}M.length&&(o==null||o({id:Gs.WIDGET_POINTS_CROSSFILTERING,position:{left:T.clientX,top:T.clientY},itemSections:M}))},b){s.onDataPointClick=P=>{const R=Yu(r,n,[P]),{filters:k}=Rf(R,c);d(H.mergeFilters(c,k))};const S=p.filter(P=>g==null?void 0:g.some(R=>V.isMembersFilter(P)&&y.isSameAttribute(P.attribute,R)&&!y.isIncludeAllFilter(P)&&!P.config.locked)),T=!!S.length,M=()=>{const P=S.map(y.clearMembersFilter);d(H.mergeFilters(c,P))};T&&(s.renderToolbar=(P,R)=>{const k=g.map(({expression:I})=>I).join(";");return O.jsxs("div",{style:{display:"flex"},children:[O.jsx(j_e,{onClick:M}),R]},k)})}return s}function G_e(e){return e.map(t=>{var r;return(r=t.config)==null?void 0:r.backgroundFilter}).filter(t=>!!t)}function q_e(e,t,r){if(r===yl.HIGHLIGHT){const[n,i]=bl(e,o=>t.every(s=>!y.isSameAttribute(s,o.attribute))),a=i.filter(o=>!y.isIncludeAllFilter(o));return[n,a]}return[e,[]]}function Y_e(e,t){const r=N.useRef(void 0),[n,i]=Og(N.useMemo(()=>H.splitFiltersAndRelations(e),[e]),{onLocalStateChange:N.useCallback(m=>{const{filters:g,relations:b}=m;if(t){const _=H.combineFiltersAndRelations(g,b);V.isEqual(r.current,_)||(r.current=_,t(_))}},[t])}),{filters:a,relations:o}=n,s=N.useMemo(()=>H.combineFiltersAndRelations(a,o),[a,o]),u=N.useCallback(m=>{if(H.isFilterRelations(m)){const{filters:g,relations:b}=H.splitFiltersAndRelations(m);i({filters:g||[],relations:b||null})}else i({filters:m,relations:null})},[i]),c=N.useCallback(m=>{const g=H.mergeFilters(a,[m]);i({filters:g,relations:H.calculateNewRelations(a,o,g)})},[a,o,i]),d=N.useCallback(m=>{i({filters:m,relations:H.calculateNewRelations(a,o,m)})},[a,o,i]),h=N.useMemo(()=>a.some(m=>V.isCascadingFilter(m)),[a]),p=N.useCallback(m=>{if(!o)return m;const g=h?uE(m,a):m,b=H.calculateNewRelations(a,o,g,{shouldReplaceSameAttributeFilters:!0});return H.combineFiltersAndRelations(g,b)},[h,a,o]);return{regularFilters:a,addFilter:c,filtersOrFilterRelations:s,setFiltersOrFilterRelations:u,setFilters:d,applyRelationsToOtherFilters:p}}const X_e=({initialFilters:e=[],openMenu:t,onBeforeMenuOpen:r,onFiltersChange:n}={})=>{const{t:i}=O.useTranslation(),{filtersOrFilterRelations:a,regularFilters:o,addFilter:s,setFiltersOrFilterRelations:u,setFilters:c,applyRelationsToOtherFilters:d}=Y_e(e,n),h=N.useCallback((p,m={})=>{var S,T,M;if(E.isTextWidgetProps(p))return p;if(E.isFilterWidgetProps(p)){const{filter:P,onChange:R}=N_e({filters:o,setFilters:c,link:m.filterWidgetOptions,setLink:(S=m.setFilterWidgetOptions)!=null?S:()=>{}})(p),k=p.onChange,I=((T=m.ignoreFilters)==null?void 0:T.all)===!1?o.filter($=>{var G,Y;return!((Y=(G=m.ignoreFilters)==null?void 0:G.ids)!=null&&Y.includes($.config.guid))&&!y.isSameAttribute($.attribute,p.attribute)}):[];return z(D(z(D({},p),{filter:P}),I.length?{parentFilters:[...(M=p.parentFilters)!=null?M:[],...I]}:{}),{onChange:$=>{$.type==="filter/changed"&&R($.payload.filter),k==null||k($)},onBeforeMenuOpen:r})}const g=E.getInternalWidgetType(p),b=p,_=V.cloneDeep(p),w=N2e(p),C=U_e(o,c,g,w,m,i,t);return _.highlights=H.mergeFilters(C.highlights,b.highlights),_.onBeforeMenuOpen=r,_.filters=d(H.mergeFilters(C.filters,H.getFiltersArray(b.filters))),C.onDataPointClick&&E.registerDataPointClickHandler(_,C.onDataPointClick),C.onDataPointsSelected&&E.registerDataPointsSelectedHandler(_,C.onDataPointsSelected),C.onDataPointContextMenu&&E.registerDataPointContextMenuHandler(_,C.onDataPointContextMenu),C.renderToolbar&&E.registerRenderToolbarHandler(_,C.renderToolbar),_},[o,c,i,t,r,d]);return{filters:a,setFilters:u,addFilter:s,connectToWidgetProps:h}},Z_e=()=>O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 0C13.9706 0 18 4.02944 18 9C18 13.9706 13.9706 18 9 18C4.02944 18 0 13.9706 0 9C0 4.02944 4.02944 0 9 0ZM9 13C8.44772 13 8 13.4477 8 14C8 14.5523 8.44772 15 9 15C9.55228 15 10 14.5523 10 14C10 13.4477 9.55228 13 9 13ZM9.00586 3C7.66861 3.03426 7.00001 3.77738 7 5.22852C7 6.07042 7.227 7.11074 7.68066 8.34961C7.85572 8.8149 7.99704 9.18813 8.10449 9.46875C8.21185 9.74913 8.28914 9.94119 8.33691 10.0439C8.59959 10.6532 8.83879 10.9716 9.05371 10.999C9.25272 11.0196 9.47115 10.7147 9.70996 10.085C9.82133 9.79081 9.92504 9.5002 10.0205 9.21289C10.116 8.92539 10.2159 8.63711 10.3193 8.34961C10.773 7.06972 11 6.00206 11 5.14648C11 3.6953 10.3352 2.97946 9.00586 3Z",fill:"#F2B900"})}),K_e=()=>O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",viewBox:"0 0 18 18",fill:"none",children:O.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M9 0C13.9706 0 18 4.02944 18 9C18 13.9706 13.9706 18 9 18C4.02944 18 0 13.9706 0 9C2.57711e-07 4.02944 4.02944 2.57702e-07 9 0ZM12.7881 5.21582C12.4952 4.92297 12.0204 4.92307 11.7275 5.21582L9.00195 7.94141L6.27637 5.21582C5.98347 4.92293 5.50871 4.92293 5.21582 5.21582C4.92295 5.50872 4.92293 5.98348 5.21582 6.27637L7.94141 9.00195L5.21582 11.7275C4.923 12.0204 4.92295 12.4952 5.21582 12.7881C5.5087 13.0808 5.98352 13.0809 6.27637 12.7881L9.00195 10.0625L11.7275 12.7881C12.0204 13.0807 12.4953 13.0809 12.7881 12.7881C13.0809 12.4953 13.0807 12.0205 12.7881 11.7275L10.0625 9.00195L12.7881 6.27637C13.0808 5.98351 13.0808 5.50868 12.7881 5.21582Z",fill:"#D12D04"})}),Q_e=6e4,J_e=85,ewe=100,twe=(e,t)=>e===!0&&t==="sisense_managed";function rwe(e,t,r){const{initialBalance:n,balance:i}=e;if(n===0)return{initialBalance:n,currentBalance:i,usagePercentage:0,isWarning:!1,isExceeded:!0};const a=(n-i)/n*100,o=Math.min(Math.max(a,0),100);return{initialBalance:n,currentBalance:i,usagePercentage:o,isWarning:o>=t&&o<r,isExceeded:o>=r}}const cE=(e={})=>{var m,g;const{enabled:t,warningThreshold:r=J_e,exceededThreshold:n=ewe}=e,{app:i}=y.useSisenseContext(),a=i==null?void 0:i.httpClient,o=(g=(m=i==null?void 0:i.settings)==null?void 0:m.serverFeatures)==null?void 0:g.aiAssistant,u=twe(o==null?void 0:o.quotaNotification,o==null?void 0:o.featureModelType)&&(t!=null?t:!0),{data:c,isLoading:d,error:h}=qg({queryKey:["creditBalance"],queryFn:()=>ht(exports,null,function*(){if(!a)throw new V.TranslatableError("errors.httpClientNotFound");const b=yield a.call(a.url+"api/v1/credits/get-balance",{method:"GET"});if(!b)throw new V.TranslatableError("ai.errors.failedToFetchCreditBalance");return b}),enabled:!!a&&u,refetchInterval:Q_e}),p=N.useMemo(()=>c?rwe(c,r,n):null,[c,r,n]);return{enabled:u,quotaState:p,isLoading:d,error:h}},nwe="_alert_gx4j3_1",iwe="_error_gx4j3_12",awe="_warning_gx4j3_16",owe="_info_gx4j3_20",swe="_icon_gx4j3_25",lwe="_content_gx4j3_38",uwe="_title_gx4j3_47",cwe="_description_gx4j3_54",dwe="_dismissButton_gx4j3_61",bi={alert:nwe,error:iwe,warning:awe,info:owe,icon:swe,content:lwe,title:uwe,description:cwe,dismissButton:dwe},D_=({variant:e="info",title:t,description:r,icon:n,dismissible:i=!1,onDismiss:a,className:o=""})=>{const s=n||O.jsx(vM,{}),u=()=>{a==null||a()},c=d=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),u())};return O.jsxs("div",{role:"alert",className:`${bi.alert} ${bi[e]} ${o}`,children:[O.jsx("div",{className:bi.icon,children:s}),O.jsxs("div",{className:bi.content,children:[t&&O.jsx("div",{className:bi.title,children:t}),r&&O.jsx("div",{className:bi.description,children:r})]}),i&&a&&O.jsx("button",{type:"button",className:bi.dismissButton,onClick:u,onKeyDown:c,"aria-label":"Dismiss alert",children:O.jsx(sE,{})})]})},hwe="_container_gw9t3_1",fwe="_bannerWrapper_gw9t3_8",Pu={container:hwe,bannerWrapper:fwe};function pwe({className:e="",enabled:t=!0,warningThreshold:r,exceededThreshold:n}={}){const{t:i}=O.useTranslation(),{enabled:a,quotaState:o,isLoading:s}=cE({enabled:t,warningThreshold:r,exceededThreshold:n}),[u,c]=N.useState(!1);return!a||s||!o?null:o.isExceeded?O.jsx("div",{className:`${Pu.container} ${e}`,children:O.jsx("div",{className:Pu.bannerWrapper,children:O.jsx(D_,{variant:"error",icon:O.jsx(K_e,{}),title:i("ai.quota.exceededErrorTitle"),description:i("ai.quota.exceededErrorDescription"),dismissible:!1})})}):o.isWarning&&!u?O.jsx("div",{className:`${Pu.container} ${e}`,children:O.jsx("div",{className:Pu.bannerWrapper,children:O.jsx(D_,{variant:"warning",icon:O.jsx(Z_e,{}),description:i("ai.quota.warningDescription",{usagePercentage:Math.round(o.usagePercentage)}),dismissible:!0,onDismiss:()=>c(!0)})})}):null}exports.AlertIcon=vM;exports.ArrowIcon=Ip;exports.BaseAuthenticator=Zs;exports.BearerAuthenticator=G6;exports.Button=qs;exports.Chart=fM;exports.ChartWidget=D_e;exports.CloseIcon=sE;exports.Collapsible=MP;exports.CommonFiltersApplyMode=yl;exports.DEFAULT_PIVOT_TABLE_SIZE=z_;exports.DEFAULT_TABLE_ROWS_PER_PAGE=sM;exports.DatePeriod=lx;exports.DimensionalQueryClient=uN;exports.DoubleArrowIcon=Fp;exports.DrilldownBreadcrumbs=KP;exports.DynamicSizeContainer=Pc;exports.EVENT_DATA_CELL_FORMAT=Nw;exports.EVENT_HEADER_CELL_FORMAT=Of;exports.ElementStates=q_;exports.EmotionCacheProvider=W_;exports.ErrorBoundary=km;exports.IconButton=vn;exports.LEGACY_DESIGN_TYPES=es;exports.MISSING_DATASOURCE_NLG_ERROR=s2e;exports.MenuButton=GM;exports.MenuIds=Gs;exports.MenuSectionIds=Ka;exports.NarrativeTriggerButton=iP;exports.NoResultsOverlay=Ac;exports.PAGES_BATCH_SIZE=lM;exports.PanelType=Ne;exports.PasswordAuthenticator=oD;exports.PivotQueryClient=cC;exports.Popper=fl;exports.QueryClient=Abe;exports.QueryClientProvider=Ibe;exports.QuotaNotification=pwe;exports.RestApi=Kc;exports.RestApiNotReadyError=xj;exports.SsoAuthenticator=K6;exports.Subscribable=To;exports.TableComponent=uM;exports.ThemeProvider=Y_;exports.ThreeDotsIcon=UM;exports.Tooltip=Ii;exports.Typography=_r;exports.UserType=Et;exports.WatAuthenticator=J6;exports.WidgetContainer=ZM;exports.WidgetMenuButton=YM;exports.WidgetNarrative=LP;exports.WidgetSpaceAround=$d;exports.addQueryParamsToUrl=oC;exports.appendHeaders=Bc;exports.applyDrilldownDimensionToPivot=BP;exports.basePickBy=Z_;exports.baseUniq=G0;exports.boxWhiskerProcessResult=XZ;exports.buildWidgetNarrativeRequests=TP;exports.camelCase=kM;exports.classNames=Is;exports.convertToThemeSettings=j_;exports.createCaseFirst=yM;exports.createFormatter=Rt;exports.createHandPickedValueToColorMap=fN;exports.createHeaderCellValueFormatter=cj;exports.createLevelAttribute=bx;exports.createPanelColorFormat=pN;exports.createSimplePaletteValueFilter=ri;exports.createSvgIcon=Qa;exports.createValueColorOptions=bC;exports.createValueToColorMap=wC;exports.createValueToColorMultiColumnsMap=mN;exports.debounce=Ig;exports.defaultDateConfig=al;exports.downloadBlobAsFile=Bye;exports.errorInterceptor=zc;exports.extendSxProp=N_;exports.formatDateValue=ol;exports.formatDatetimeString=D0;exports.formatNumber=M3;exports.generateAttributeName=yx;exports.getAvailableDrilldownPaths=Tc;exports.getBaseDateFnsLocale=il;exports.getChartDefaultSize=Ec;exports.getCompleteWidgetNarrativeConfig=Bi;exports.getCustomWidgetName=$1e;exports.getDataOptionByLocation=FP;exports.getDataPointMetadata=Fe;exports.getDefaultDateMask=sj;exports.getDefaultState=hP;exports.getDrilldownMenuItems=iE;exports.getFilterWidgetName=B1e;exports.getHierarchyModels=aE;exports.getInitialDimensionLocation=$P;exports.getLegacyPalette=G_;exports.getNarrative=wP;exports.getPaletteName=V_;exports.getPivotDataOptionByJaqlIndex=mx;exports.getPivotDataOptionIdByJaqlIndex=lj;exports.getPivotQueryOptions=Fg;exports.getPivotWidgetName=I1e;exports.getResponseInterceptor=iD;exports.getSelectedDrilldownAttributes=Sc;exports.getSelectionTitleMenuItem=nE;exports.getTableAttributesAndMeasures=X0;exports.getTextWidgetName=F1e;exports.getThemeSettingsByOid=U_;exports.getTranslatedDataOptions=eT;exports.getWidgetDefaultSize=H_;exports.getWidgetEntityId=$M;exports.getWidgetNarrativeConfigFromWidgetProps=Xi;exports.getWidgetOverheadHeight=Dye;exports.getWidgetTitle=BM;exports.groupBy=OP;exports.headerMenuUtils=A1e;exports.isAuthTokenPending=V6;exports.isPivotRowsSort=Rve;exports.isSsoAuthenticator=m0;exports.isString=ed;exports.mapAttributesForExcelExport=Bm;exports.mapMeasureColumnForExcelExport=eP;exports.mapMeasureColumnsForExcelExport=tP;exports.normalizeUrl=zi;exports.notifyManager=yt;exports.parseDataTableDateValue=BW;exports.parseMutationArgs=gbe;exports.partition=bl;exports.prepareGetNlgInsightsPayload=e2e;exports.preparePivotRowsSortCriteriaList=Dve;exports.processDrilldownSelections=eE;exports.resolveFilterWidgetFilter=lE;exports.shallowEqualObjects=wc;exports.shouldSkipSisenseContextWaiting=hM;exports.shouldThrowError=vP;exports.startOfPeriod=$W;exports.translatePivotTableDataOptions=C3;exports.translateTableDataOptions=ul;exports.typographyClasses=aA;exports.updateDrilldownSelections=JP;exports.upperFirst=bM;exports.useCommonFilters=X_e;exports.useControlled=Xm;exports.useCsvQueryFileLoader=KM;exports.useDebouncedValue=mM;exports.useDrilldown=rE;exports.useDrilldownCore=QP;exports.useExcelQueryFileLoader=rP;exports.useFireOnReady=J3;exports.useFormControl=HM;exports.useHierarchiesLoader=oE;exports.useHover=RP;exports.useId=Mc;exports.useMenu=Hg;exports.usePivotTableQuery=Lve;exports.useQuery=qg;exports.useQueryClient=gP;exports.useQuotaNotification=cE;exports.useRestApi=gx;exports.useSetError=q0;exports.useSyncExternalStore=fP;exports.useSyncedState=Og;exports.useTrackWidgetInit=IM;exports.useWidgetHeaderManagement=FM;exports.useWidgetNarrativeState=SP;exports.useWithCsvDownloadMenuItem=QM;exports.useWithExcelDownloadMenuItem=nP;exports.validateUrl=U6;exports.withHeaderMenuItem=OM;