@undp/data-viz 2.3.3 → 2.3.4

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 (123) hide show
  1. package/dist/AreaChart.cjs +1 -1
  2. package/dist/AreaChart.js +1 -1
  3. package/dist/BarGraph.cjs +1 -1
  4. package/dist/BarGraph.js +1 -1
  5. package/dist/BasicStatCard.cjs +1 -1
  6. package/dist/BasicStatCard.js +1 -1
  7. package/dist/BeeSwarmChart.cjs +1 -1
  8. package/dist/BeeSwarmChart.js +2 -2
  9. package/dist/BiVariateChoroplethMap.cjs +1 -1
  10. package/dist/BiVariateChoroplethMap.js +1 -1
  11. package/dist/BulletChart.cjs +1 -1
  12. package/dist/BulletChart.js +1 -1
  13. package/dist/ButterflyChart.cjs +1 -1
  14. package/dist/ButterflyChart.js +1 -1
  15. package/dist/ChoroplethMap.cjs +1 -1
  16. package/dist/ChoroplethMap.js +1 -1
  17. package/dist/CirclePackingGraph.cjs +1 -1
  18. package/dist/CirclePackingGraph.js +2 -2
  19. package/dist/ColorLegend.cjs +1 -1
  20. package/dist/ColorLegend.js +1 -1
  21. package/dist/ColorLegendWithMouseOver.cjs +1 -1
  22. package/dist/ColorLegendWithMouseOver.js +1 -1
  23. package/dist/DataCards.cjs +1 -1
  24. package/dist/DataCards.js +2 -2
  25. package/dist/DataTable.cjs +1 -1
  26. package/dist/DataTable.js +1 -1
  27. package/dist/DifferenceLineChart.cjs +1 -1
  28. package/dist/DifferenceLineChart.js +1 -1
  29. package/dist/DonutChart.cjs +1 -1
  30. package/dist/DonutChart.js +3 -3
  31. package/dist/DotDensityMap.cjs +1 -1
  32. package/dist/DotDensityMap.js +1 -1
  33. package/dist/DualAxisLineChart.cjs +1 -1
  34. package/dist/DualAxisLineChart.js +1 -1
  35. package/dist/DumbbellChart.cjs +1 -1
  36. package/dist/DumbbellChart.js +1 -1
  37. package/dist/{EmptyState-DX0t62iF.cjs → EmptyState-N1eHt3vq.cjs} +2 -2
  38. package/dist/{EmptyState-DX0t62iF.cjs.map → EmptyState-N1eHt3vq.cjs.map} +1 -1
  39. package/dist/{EmptyState-Pj-emXt5.js → EmptyState-dScPFkLy.js} +2 -2
  40. package/dist/{EmptyState-Pj-emXt5.js.map → EmptyState-dScPFkLy.js.map} +1 -1
  41. package/dist/FootNote.cjs +1 -1
  42. package/dist/FootNote.js +1 -1
  43. package/dist/GeoHubMapWithLayerSelection.cjs +1 -1
  44. package/dist/GeoHubMapWithLayerSelection.js +1 -1
  45. package/dist/GraphDescription.cjs +1 -1
  46. package/dist/GraphDescription.js +1 -1
  47. package/dist/{GraphEl-CWjTuiYd.cjs → GraphEl-B-XEJeRt.cjs} +2 -2
  48. package/dist/{GraphEl-CWjTuiYd.cjs.map → GraphEl-B-XEJeRt.cjs.map} +1 -1
  49. package/dist/{GraphEl-DDXkYObU.js → GraphEl-C2xExzzY.js} +3 -3
  50. package/dist/{GraphEl-DDXkYObU.js.map → GraphEl-C2xExzzY.js.map} +1 -1
  51. package/dist/GraphFooter.cjs +1 -1
  52. package/dist/GraphFooter.js +1 -1
  53. package/dist/GraphTitle.cjs +1 -1
  54. package/dist/GraphTitle.js +1 -1
  55. package/dist/GriddedGraphs.cjs +1 -1
  56. package/dist/GriddedGraphs.js +1 -1
  57. package/dist/HeatMap.cjs +1 -1
  58. package/dist/HeatMap.js +1 -1
  59. package/dist/Histogram.cjs +1 -1
  60. package/dist/Histogram.js +1 -1
  61. package/dist/HybridMap.cjs +1 -1
  62. package/dist/HybridMap.js +2 -2
  63. package/dist/LineChartWithConfidenceInterval.cjs +1 -1
  64. package/dist/LineChartWithConfidenceInterval.js +1 -1
  65. package/dist/LinearColorLegend.cjs +1 -1
  66. package/dist/LinearColorLegend.js +1 -1
  67. package/dist/MultiLineAltChart.cjs +1 -1
  68. package/dist/MultiLineAltChart.js +1 -1
  69. package/dist/MultiLineChart.cjs +1 -1
  70. package/dist/MultiLineChart.js +1 -1
  71. package/dist/ParetoChart.cjs +1 -1
  72. package/dist/ParetoChart.js +1 -1
  73. package/dist/RadarChart.cjs +1 -1
  74. package/dist/RadarChart.js +1 -1
  75. package/dist/SankeyChart.cjs +1 -1
  76. package/dist/SankeyChart.js +2 -2
  77. package/dist/ScatterPlot.cjs +1 -1
  78. package/dist/ScatterPlot.js +1 -1
  79. package/dist/SimpleLineChart.cjs +1 -1
  80. package/dist/SimpleLineChart.js +1 -1
  81. package/dist/SingleGraphDashboard.cjs +1 -1
  82. package/dist/SingleGraphDashboard.js +1 -1
  83. package/dist/SingleGraphDashboardGeoHubMaps.cjs +1 -1
  84. package/dist/SingleGraphDashboardGeoHubMaps.js +1 -1
  85. package/dist/SingleGraphDashboardThreeDGraphs.cjs +1 -1
  86. package/dist/SingleGraphDashboardThreeDGraphs.js +1 -1
  87. package/dist/SlopeChart.cjs +1 -1
  88. package/dist/SlopeChart.js +1 -1
  89. package/dist/{Source-B3i0Bx2R.cjs → Source-24M277ZQ.cjs} +2 -2
  90. package/dist/{Source-B3i0Bx2R.cjs.map → Source-24M277ZQ.cjs.map} +1 -1
  91. package/dist/{Source-_STIejqs.js → Source-Cu9OHOBj.js} +2 -2
  92. package/dist/{Source-_STIejqs.js.map → Source-Cu9OHOBj.js.map} +1 -1
  93. package/dist/Source.cjs +1 -1
  94. package/dist/Source.js +2 -2
  95. package/dist/StatCardFromData.cjs +1 -1
  96. package/dist/StatCardFromData.js +1 -1
  97. package/dist/StripChart.cjs +1 -1
  98. package/dist/StripChart.js +1 -1
  99. package/dist/ThreeDGlobe.cjs +1 -1
  100. package/dist/ThreeDGlobe.js +1 -1
  101. package/dist/ThresholdColorLegendWithMouseOver.cjs +1 -1
  102. package/dist/ThresholdColorLegendWithMouseOver.js +1 -1
  103. package/dist/TreeMapGraph.cjs +1 -1
  104. package/dist/TreeMapGraph.js +2 -2
  105. package/dist/Typography-Cc_iHQB-.cjs +2 -0
  106. package/dist/Typography-Cc_iHQB-.cjs.map +1 -0
  107. package/dist/{Typography-iR8PEgdt.js → Typography-CdMGooqp.js} +4 -4
  108. package/dist/Typography-CdMGooqp.js.map +1 -0
  109. package/dist/UnitChart.cjs +1 -1
  110. package/dist/UnitChart.js +1 -1
  111. package/dist/WaterfallChart.cjs +1 -1
  112. package/dist/WaterfallChart.js +1 -1
  113. package/dist/{index-BE-lvE4c.js → index-CH8RndC2.js} +3 -3
  114. package/dist/{index-BE-lvE4c.js.map → index-CH8RndC2.js.map} +1 -1
  115. package/dist/{index-DlrGwLQA.cjs → index-DNmkwfX8.cjs} +2 -2
  116. package/dist/{index-DlrGwLQA.cjs.map → index-DNmkwfX8.cjs.map} +1 -1
  117. package/dist/index.cjs +1 -1
  118. package/dist/index.js +2 -2
  119. package/dist/style.css +1 -1
  120. package/package.json +2 -3
  121. package/dist/Typography-DrJ7IOdw.cjs +0 -2
  122. package/dist/Typography-DrJ7IOdw.cjs.map +0 -1
  123. package/dist/Typography-iR8PEgdt.js.map +0 -1
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("./index-CHPV5EwG-6v2a2njQ.cjs"),m=require("./FootNote.cjs"),p=require("./Source-B3i0Bx2R.cjs");function d(x){const e=u.compilerRuntimeExports.c(14),{sources:t,footNote:c,width:f,styles:o,classNames:s}=x;if((t===void 0||(t||[]).length===0)&&c===void 0)return null;const a=f?`${f}px`:"none";let r;e[0]!==a?(r={maxWidth:a},e[0]=a,e[1]=r):r=e[1];let l;e[2]!==s?.source||e[3]!==t||e[4]!==o?.source?(l=t?u.jsxRuntimeExports.jsx(p.Source,{sources:t,style:o?.source,className:s?.source}):null,e[2]=s?.source,e[3]=t,e[4]=o?.source,e[5]=l):l=e[5];let n;e[6]!==s?.footnote||e[7]!==c||e[8]!==o?.footnote?(n=c?u.jsxRuntimeExports.jsx(m.FootNote,{text:c,style:o?.footnote,className:s?.footnote}):null,e[6]=s?.footnote,e[7]=c,e[8]=o?.footnote,e[9]=n):n=e[9];let i;return e[10]!==r||e[11]!==l||e[12]!==n?(i=u.jsxRuntimeExports.jsxs("div",{className:"flex flex-col pt-4",style:r,"aria-label":"Graph footer",children:[l,n]}),e[10]=r,e[11]=l,e[12]=n,e[13]=i):i=e[13],i}exports.GraphFooter=d;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("./index-CHPV5EwG-6v2a2njQ.cjs"),m=require("./FootNote.cjs"),p=require("./Source-24M277ZQ.cjs");function d(x){const e=u.compilerRuntimeExports.c(14),{sources:t,footNote:c,width:f,styles:o,classNames:s}=x;if((t===void 0||(t||[]).length===0)&&c===void 0)return null;const a=f?`${f}px`:"none";let r;e[0]!==a?(r={maxWidth:a},e[0]=a,e[1]=r):r=e[1];let l;e[2]!==s?.source||e[3]!==t||e[4]!==o?.source?(l=t?u.jsxRuntimeExports.jsx(p.Source,{sources:t,style:o?.source,className:s?.source}):null,e[2]=s?.source,e[3]=t,e[4]=o?.source,e[5]=l):l=e[5];let n;e[6]!==s?.footnote||e[7]!==c||e[8]!==o?.footnote?(n=c?u.jsxRuntimeExports.jsx(m.FootNote,{text:c,style:o?.footnote,className:s?.footnote}):null,e[6]=s?.footnote,e[7]=c,e[8]=o?.footnote,e[9]=n):n=e[9];let i;return e[10]!==r||e[11]!==l||e[12]!==n?(i=u.jsxRuntimeExports.jsxs("div",{className:"flex flex-col pt-4",style:r,"aria-label":"Graph footer",children:[l,n]}),e[10]=r,e[11]=l,e[12]=n,e[13]=i):i=e[13],i}exports.GraphFooter=d;
2
2
  //# sourceMappingURL=GraphFooter.cjs.map
@@ -1,6 +1,6 @@
1
1
  import { c as x, j as a } from "./index-CHPV5EwG-DecW7_qr.js";
2
2
  import { FootNote as p } from "./FootNote.js";
3
- import { S as d } from "./Source-_STIejqs.js";
3
+ import { S as d } from "./Source-Cu9OHOBj.js";
4
4
  function y(m) {
5
5
  const o = x.c(14), {
6
6
  sources: e,
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index-CHPV5EwG-6v2a2njQ.cjs"),m=require("./Typography-DrJ7IOdw.cjs"),u=require("react");function x(c){const e=s.compilerRuntimeExports.c(16),{text:t,isDashboard:p,style:i,className:l}=c;if(typeof t=="string"){if(t.trim()==="")return null;if(p){let a;e[0]!==l?(a=s.mo("font-bold pb-3 text-primary-black dark:text-primary-gray-100",l),e[0]=l,e[1]=a):a=e[1];let o;return e[2]!==i||e[3]!==a||e[4]!==t?(o=s.jsxRuntimeExports.jsx(m.P,{marginBottom:"base",className:a,"aria-label":"Dashboard title",style:i,children:t}),e[2]=i,e[3]=a,e[4]=t,e[5]=o):o=e[5],o}let r;e[6]!==l?(r=s.mo("text-primary-black dark:text-primary-gray-100",l),e[6]=l,e[7]=r):r=e[7];let n;return e[8]!==i||e[9]!==r||e[10]!==t?(n=s.jsxRuntimeExports.jsx(m._,{marginBottom:"none",className:r,"aria-label":"Graph title",style:i,children:t}),e[8]=i,e[9]=r,e[10]=t,e[11]=n):n=e[11],n}if(u.isValidElement(t)){let r;return e[12]!==l||e[13]!==i||e[14]!==t?(r=s.jsxRuntimeExports.jsx("div",{className:l,style:i,children:t}),e[12]=l,e[13]=i,e[14]=t,e[15]=r):r=e[15],r}return console.error("GraphTitle: Invalid text type. Expected string or React element."),null}exports.GraphTitle=x;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./index-CHPV5EwG-6v2a2njQ.cjs"),m=require("./Typography-Cc_iHQB-.cjs"),u=require("react");function x(c){const e=s.compilerRuntimeExports.c(16),{text:t,isDashboard:p,style:i,className:l}=c;if(typeof t=="string"){if(t.trim()==="")return null;if(p){let a;e[0]!==l?(a=s.mo("font-bold pb-3 text-primary-black dark:text-primary-gray-100",l),e[0]=l,e[1]=a):a=e[1];let o;return e[2]!==i||e[3]!==a||e[4]!==t?(o=s.jsxRuntimeExports.jsx(m.P,{marginBottom:"base",className:a,"aria-label":"Dashboard title",style:i,children:t}),e[2]=i,e[3]=a,e[4]=t,e[5]=o):o=e[5],o}let r;e[6]!==l?(r=s.mo("text-primary-black dark:text-primary-gray-100",l),e[6]=l,e[7]=r):r=e[7];let n;return e[8]!==i||e[9]!==r||e[10]!==t?(n=s.jsxRuntimeExports.jsx(m._,{marginBottom:"none",className:r,"aria-label":"Graph title",style:i,children:t}),e[8]=i,e[9]=r,e[10]=t,e[11]=n):n=e[11],n}if(u.isValidElement(t)){let r;return e[12]!==l||e[13]!==i||e[14]!==t?(r=s.jsxRuntimeExports.jsx("div",{className:l,style:i,children:t}),e[12]=l,e[13]=i,e[14]=t,e[15]=r):r=e[15],r}return console.error("GraphTitle: Invalid text type. Expected string or React element."),null}exports.GraphTitle=x;
2
2
  //# sourceMappingURL=GraphTitle.cjs.map
@@ -1,5 +1,5 @@
1
1
  import { c as f, m, j as n } from "./index-CHPV5EwG-DecW7_qr.js";
2
- import { P as x, _ as d } from "./Typography-iR8PEgdt.js";
2
+ import { P as x, _ as d } from "./Typography-CdMGooqp.js";
3
3
  import u from "react";
4
4
  function g(p) {
5
5
  const t = f.c(16), {
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-CHPV5EwG-6v2a2njQ.cjs"),i=require("react"),ae=require("./index-CyZ1lmi_.cjs"),G=require("./index-BS2TADPj.cjs"),u=require("./checkIfMultiple-DxnGtm3t.cjs"),te=require("./Spinner-jTMOLuw_.cjs"),m=require("./DropdownSelect-NNpOs7DX.cjs"),le=require("./GraphContainer-B1EDxJ0S.cjs"),oe=require("./GraphEl-CWjTuiYd.cjs"),S=require("./fetchAndParseData-QTF6tjij.cjs"),re=require("./Colors.cjs"),H=require("./transformDataForAggregation-BFdha9Dx.cjs"),W=require("./getUniqValue-NX8DgwND.cjs"),ne=require("./GraphHeader.cjs"),ie=require("./GraphFooter.cjs"),z=require("./filterData-T5DQBE9b.cjs"),se=require("./ColorLegend.cjs"),ue=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),B=require("./transformDataForSelect-YmStusCI.cjs");function ce(J){const{graphSettings:t,dataSettings:n,filters:T,graphType:$,dataTransform:D,graphDataConfiguration:s,noOfColumns:y,columnGridBy:E,dataFilters:q,showCommonColorScale:A,minGraphHeight:K,minGraphWidth:F,debugMode:w,dataSelectionOptions:O,advancedDataSelectionOptions:k,readableHeader:Q,noOfFiltersPerRow:f=4,uiMode:d="normal",theme:X="light"}=J,[v,Y]=i.useState(void 0),[g,Z]=i.useState(void 0),[b,_]=i.useState([]),M=i.useRef(null),[x,C]=i.useState(s),[j,L]=i.useState([]),[h,R]=i.useState({}),N=i.useMemo(()=>({ignoreCase:!0,ignoreAccents:!0,trim:!0}),[]),P=i.useMemo(()=>!g||j.length===0?g:g.filter(r=>j.every(a=>a.value&&G.flattenDeep([a.value]).length>0?ae.intersection(G.flattenDeep([r[a.filter]]),G.flattenDeep([a.value]).map(l=>l.value)).length>0:!0)),[j,g]);i.useEffect(()=>{Y(P)},[P]);const U=i.useEffectEvent(()=>{const e=(T||[]).map(r=>({filter:r.column,label:r.label||`Filter by ${r.column}`,singleSelect:r.singleSelect,clearable:r.clearable,ui:r.ui,defaultValue:B.transformDefaultValue(r.defaultValue),value:B.transformDefaultValue(r.defaultValue),availableValues:W.getUniqValue(g,r.column).filter(a=>!r.excludeValues?.includes(`${a}`)).map(a=>({value:a,label:a})),allowSelectAll:r.allowSelectAll,width:r.width}));L(e)});i.useEffect(()=>{(async()=>{try{const r=n.dataURL?typeof n.dataURL=="string"?n.fileType==="json"?await S.fetchAndParseJSON(n.dataURL,n.columnsToArray,n.dataTransformation,w):n.fileType==="api"?await S.fetchAndTransformDataFromAPI(n.dataURL,n.apiHeaders,n.columnsToArray,n.dataTransformation,w):await S.fetchAndParseCSV(n.dataURL,n.dataTransformation,n.columnsToArray,w,n.delimiter,!0):await S.fetchAndParseMultipleDataSources(n.dataURL,n.idColumnTitle):await S.transformColumnsToArray(n.data,n.columnsToArray);Z(r)}catch(r){console.error("Data fetching error:",r)}})(),U()},[n,w]),i.useEffect(()=>{U()},[T,g]);const ee=i.useEffectEvent(()=>{const e=W.getUniqValue(g,E);_(e)});i.useEffect(()=>{ee()},[E,g]),i.useEffect(()=>{C(s)},[s]);const I=i.useCallback((e,r)=>{L(a=>a.map(l=>l.filter===e?{...l,value:r}:l))},[]);return o.jsxRuntimeExports.jsxs(le.GraphContainer,{className:t?.classNames?.graphContainer,style:t?.styles?.graphContainer,id:t?.graphID,ref:M,"aria-label":t?.ariaLabel||"This is a gridded graph",backgroundColor:t?.backgroundColor??!1,theme:t?.theme||"light",language:t?.language||"en",width:t?.width,height:t?.height,padding:t?.padding,children:[h?.graphTitle||h?.graphDescription||t?.graphTitle||t?.graphDescription||t?.graphDownload||t?.dataDownload?o.jsxRuntimeExports.jsx(ne.GraphHeader,{styles:{title:h?.styles?.title||t?.styles?.title,description:h?.styles?.description||t?.styles?.description},classNames:{title:h?.classNames?.title||t?.classNames?.title,description:h?.classNames?.description||t?.classNames?.description},graphTitle:h?.graphTitle||t?.graphTitle,graphDescription:h?.graphDescription||t?.graphDescription,width:h?.width||t?.width,graphDownload:t?.graphDownload?M:void 0,dataDownload:t?.dataDownload&&v&&v.length>0?v:null}):null,v&&b.length>0?o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[j.length!==0||(O||[]).length!==0||(k||[]).length!==0?o.jsxRuntimeExports.jsxs("div",{className:"flex flex-wrap items-start gap-x-4 gap-y-0 w-full",children:[k?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,minWidth:"240px"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label||"Graph by"}),e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.options.map(a=>({...a,value:a.label})),isClearable:!1,isSearchable:!0,variant:d,controlShouldRenderValue:!0,defaultValue:e.defaultValue?{...e.defaultValue,value:e.defaultValue?.label}:{...e.options[0],value:e.options[0].label},onChange:a=>{R(a?.graphSettings||{}),C(a?.dataConfiguration)}}):o.jsxRuntimeExports.jsx(u.ye,{defaultValue:e.defaultValue?.label||e.options[0].label,variant:d,onValueChange:a=>{const l=e.options[e.options.findIndex(p=>p.label===a)];R(l.graphSettings||{}),C(l.dataConfiguration)},children:e.options.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:a.label,value:a.label},l))})]},r)),O?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,minWidth:"240px"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label||`Visualize ${e.chartConfigId} by`}),u.checkIfMultiple(e.chartConfigId,x||[])?e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.allowedColumnIds,isMulti:!0,variant:d,isSearchable:!0,controlShouldRenderValue:!0,defaultValue:s?s[s.findIndex(a=>a.chartConfigId===e.chartConfigId)].columnId.map(a=>e.allowedColumnIds[e.allowedColumnIds.findIndex(l=>l.value===a)]):void 0,filterOption:m.Du(N),onChange:a=>{const l={columnId:a.map(c=>c.value),chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);C(p)},isRtl:t?.language==="ar"||t?.language==="he"}):o.jsxRuntimeExports.jsx(u.$,{variant:d,defaultValue:s?s[s.findIndex(a=>a.chartConfigId===e.chartConfigId)].columnId.map(a=>e.allowedColumnIds[e.allowedColumnIds.findIndex(l=>l.value===a)]).map(a=>a.value):[],onValueChange:a=>{const l={columnId:a||[],chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);C(p)},children:e.allowedColumnIds.map((a,l)=>o.jsxRuntimeExports.jsx(u.P,{label:a.label,value:a.label},l))}):e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.allowedColumnIds,isClearable:!1,isSearchable:!0,variant:d,defaultValue:s?e.allowedColumnIds[e.allowedColumnIds.findIndex(a=>a.value===s[s.findIndex(l=>l.chartConfigId===e.chartConfigId)].columnId)]:void 0,controlShouldRenderValue:!0,onChange:a=>{const l={columnId:a?.value,chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);R(a?.graphSettings||{}),C(p)}}):o.jsxRuntimeExports.jsx(u.ye,{variant:d,defaultValue:s?e.allowedColumnIds[e.allowedColumnIds.findIndex(a=>a.value===s[s.findIndex(l=>l.chartConfigId===e.chartConfigId)].columnId)].label:"",onValueChange:a=>{const l=e.allowedColumnIds[e.allowedColumnIds.findIndex(V=>V.label===a)],p={columnId:l.value,chartConfigId:e.chartConfigId},c=x?.map(V=>V.chartConfigId===p.chartConfigId?p:V);R(l.graphSettings||{}),C(c)},children:e.allowedColumnIds.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:a.label,value:a.label},l))})]},r)),j?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,flexWrap:"wrap"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label}),e.singleSelect?e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.availableValues,variant:d,isClearable:e.clearable===void 0?!0:e.clearable,isSearchable:!0,controlShouldRenderValue:!0,filterOption:m.Du(N),onChange:a=>{I(e.filter,a)},value:e.value,defaultValue:e.defaultValue}):o.jsxRuntimeExports.jsx(u.ye,{variant:d,defaultValue:e.defaultValue.value,onValueChange:a=>{I(e.filter,e.availableValues.filter(l=>l.value===a))},children:e.availableValues.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:`${a.label}`,value:`${a.value}`},l))}):o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.availableValues,variant:d,size:"sm",isMulti:!0,isClearable:e.clearable===void 0?!0:e.clearable,isSearchable:!0,controlShouldRenderValue:!0,filterOption:m.Du(N),onChange:a=>{I(e.filter,a)},value:e.value,defaultValue:e.defaultValue}):o.jsxRuntimeExports.jsx(u.$,{variant:d,defaultValue:e.defaultValue?e.defaultValue.map(a=>`${a.value}`):[],value:e.value?e.value.map(a=>`${a.value}`):void 0,onValueChange:a=>{I(e.filter,e.availableValues.filter(l=>a.indexOf(`${l.value}`)!==-1))},children:e.availableValues.map((a,l)=>o.jsxRuntimeExports.jsx(u.P,{label:`${a.label}`,value:`${a.value}`},l))}),e.allowSelectAll?o.jsxRuntimeExports.jsx("button",{type:"button",className:"bg-transparent border-0 p-0 mt-2 cursor-pointer text-primary-blue-600 dark:text-primary-blue-400",onClick:()=>{I(e.filter,e.availableValues)},children:"Select all options"}):null]})]},r))]}):null,A!==!1&&t?.showColorScale!==!1?o.jsxRuntimeExports.jsx(se.ColorLegend,{width:t?.width,colorLegendTitle:t?.colorLegendTitle,colors:t?.colors||t?.lineColors||re.Colors[t?.theme||"light"].categoricalColors.colors,colorDomain:t?.colorDomain||t?.labels||[],showNAColor:t?.showNAColor===void 0||t?.showNAColor===null?!0:t?.showNAColor}):null,o.jsxRuntimeExports.jsx("div",{className:`flex flex-wrap gap-4 justify-center ${t?.language==="ar"||t?.language==="he"?"flex-row-reverse":"flex-row"}`,children:b.map((e,r)=>o.jsxRuntimeExports.jsx("div",{style:{width:`calc(${100/(y||Math.min(4,b.length||0))}% - ${((y||Math.min(4,b.length||0))-1)/(y||Math.min(4,b.length||0))}rem)`,minWidth:ue.checkIfNullOrUndefined(F)?"280px":`${F}px`},children:o.jsxRuntimeExports.jsx(oe.GraphEl,{graph:$,graphDataConfiguration:x,graphData:H.transformDataForGraph(D?H.transformDataForAggregation(z.filterData(v,q||[]).filter(a=>a[E]===e),D.keyColumn,D.aggregationColumnsSetting):z.filterData(v,q||[]).filter(a=>a[E]===e),$,x)||[],debugMode:w,settings:{...t||{},...h,theme:t?.theme||X,width:void 0,height:void 0,relativeHeight:t?.relativeHeight||.67,minHeight:K,graphTitle:`${e}`,graphDescription:void 0,graphDownload:!1,dataDownload:!1,backgroundColor:void 0,padding:"0",footNote:void 0,sources:void 0,showColorScale:t?.showColorScale===!1?!1:A===!1},readableHeader:Q||[]})},r))})]}):o.jsxRuntimeExports.jsx("div",{className:"w-full flex justify-center p-4",children:o.jsxRuntimeExports.jsx(te.w,{})}),t?.sources||t?.footNote?o.jsxRuntimeExports.jsx(ie.GraphFooter,{styles:{footnote:t?.styles?.footnote,source:t?.styles?.source},classNames:{footnote:t?.classNames?.footnote,source:t?.classNames?.source},sources:t?.sources,footNote:t?.footNote,width:t?.width}):null]})}exports.GriddedGraphs=ce;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./index-CHPV5EwG-6v2a2njQ.cjs"),i=require("react"),ae=require("./index-CyZ1lmi_.cjs"),G=require("./index-BS2TADPj.cjs"),u=require("./checkIfMultiple-DxnGtm3t.cjs"),te=require("./Spinner-jTMOLuw_.cjs"),m=require("./DropdownSelect-NNpOs7DX.cjs"),le=require("./GraphContainer-B1EDxJ0S.cjs"),oe=require("./GraphEl-B-XEJeRt.cjs"),S=require("./fetchAndParseData-QTF6tjij.cjs"),re=require("./Colors.cjs"),H=require("./transformDataForAggregation-BFdha9Dx.cjs"),W=require("./getUniqValue-NX8DgwND.cjs"),ne=require("./GraphHeader.cjs"),ie=require("./GraphFooter.cjs"),z=require("./filterData-T5DQBE9b.cjs"),se=require("./ColorLegend.cjs"),ue=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),B=require("./transformDataForSelect-YmStusCI.cjs");function ce(J){const{graphSettings:t,dataSettings:n,filters:T,graphType:$,dataTransform:D,graphDataConfiguration:s,noOfColumns:y,columnGridBy:E,dataFilters:q,showCommonColorScale:A,minGraphHeight:K,minGraphWidth:F,debugMode:w,dataSelectionOptions:O,advancedDataSelectionOptions:k,readableHeader:Q,noOfFiltersPerRow:f=4,uiMode:d="normal",theme:X="light"}=J,[v,Y]=i.useState(void 0),[g,Z]=i.useState(void 0),[b,_]=i.useState([]),M=i.useRef(null),[x,C]=i.useState(s),[j,L]=i.useState([]),[h,R]=i.useState({}),N=i.useMemo(()=>({ignoreCase:!0,ignoreAccents:!0,trim:!0}),[]),P=i.useMemo(()=>!g||j.length===0?g:g.filter(r=>j.every(a=>a.value&&G.flattenDeep([a.value]).length>0?ae.intersection(G.flattenDeep([r[a.filter]]),G.flattenDeep([a.value]).map(l=>l.value)).length>0:!0)),[j,g]);i.useEffect(()=>{Y(P)},[P]);const U=i.useEffectEvent(()=>{const e=(T||[]).map(r=>({filter:r.column,label:r.label||`Filter by ${r.column}`,singleSelect:r.singleSelect,clearable:r.clearable,ui:r.ui,defaultValue:B.transformDefaultValue(r.defaultValue),value:B.transformDefaultValue(r.defaultValue),availableValues:W.getUniqValue(g,r.column).filter(a=>!r.excludeValues?.includes(`${a}`)).map(a=>({value:a,label:a})),allowSelectAll:r.allowSelectAll,width:r.width}));L(e)});i.useEffect(()=>{(async()=>{try{const r=n.dataURL?typeof n.dataURL=="string"?n.fileType==="json"?await S.fetchAndParseJSON(n.dataURL,n.columnsToArray,n.dataTransformation,w):n.fileType==="api"?await S.fetchAndTransformDataFromAPI(n.dataURL,n.apiHeaders,n.columnsToArray,n.dataTransformation,w):await S.fetchAndParseCSV(n.dataURL,n.dataTransformation,n.columnsToArray,w,n.delimiter,!0):await S.fetchAndParseMultipleDataSources(n.dataURL,n.idColumnTitle):await S.transformColumnsToArray(n.data,n.columnsToArray);Z(r)}catch(r){console.error("Data fetching error:",r)}})(),U()},[n,w]),i.useEffect(()=>{U()},[T,g]);const ee=i.useEffectEvent(()=>{const e=W.getUniqValue(g,E);_(e)});i.useEffect(()=>{ee()},[E,g]),i.useEffect(()=>{C(s)},[s]);const I=i.useCallback((e,r)=>{L(a=>a.map(l=>l.filter===e?{...l,value:r}:l))},[]);return o.jsxRuntimeExports.jsxs(le.GraphContainer,{className:t?.classNames?.graphContainer,style:t?.styles?.graphContainer,id:t?.graphID,ref:M,"aria-label":t?.ariaLabel||"This is a gridded graph",backgroundColor:t?.backgroundColor??!1,theme:t?.theme||"light",language:t?.language||"en",width:t?.width,height:t?.height,padding:t?.padding,children:[h?.graphTitle||h?.graphDescription||t?.graphTitle||t?.graphDescription||t?.graphDownload||t?.dataDownload?o.jsxRuntimeExports.jsx(ne.GraphHeader,{styles:{title:h?.styles?.title||t?.styles?.title,description:h?.styles?.description||t?.styles?.description},classNames:{title:h?.classNames?.title||t?.classNames?.title,description:h?.classNames?.description||t?.classNames?.description},graphTitle:h?.graphTitle||t?.graphTitle,graphDescription:h?.graphDescription||t?.graphDescription,width:h?.width||t?.width,graphDownload:t?.graphDownload?M:void 0,dataDownload:t?.dataDownload&&v&&v.length>0?v:null}):null,v&&b.length>0?o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[j.length!==0||(O||[]).length!==0||(k||[]).length!==0?o.jsxRuntimeExports.jsxs("div",{className:"flex flex-wrap items-start gap-x-4 gap-y-0 w-full",children:[k?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,minWidth:"240px"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label||"Graph by"}),e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.options.map(a=>({...a,value:a.label})),isClearable:!1,isSearchable:!0,variant:d,controlShouldRenderValue:!0,defaultValue:e.defaultValue?{...e.defaultValue,value:e.defaultValue?.label}:{...e.options[0],value:e.options[0].label},onChange:a=>{R(a?.graphSettings||{}),C(a?.dataConfiguration)}}):o.jsxRuntimeExports.jsx(u.ye,{defaultValue:e.defaultValue?.label||e.options[0].label,variant:d,onValueChange:a=>{const l=e.options[e.options.findIndex(p=>p.label===a)];R(l.graphSettings||{}),C(l.dataConfiguration)},children:e.options.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:a.label,value:a.label},l))})]},r)),O?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,minWidth:"240px"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label||`Visualize ${e.chartConfigId} by`}),u.checkIfMultiple(e.chartConfigId,x||[])?e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.allowedColumnIds,isMulti:!0,variant:d,isSearchable:!0,controlShouldRenderValue:!0,defaultValue:s?s[s.findIndex(a=>a.chartConfigId===e.chartConfigId)].columnId.map(a=>e.allowedColumnIds[e.allowedColumnIds.findIndex(l=>l.value===a)]):void 0,filterOption:m.Du(N),onChange:a=>{const l={columnId:a.map(c=>c.value),chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);C(p)},isRtl:t?.language==="ar"||t?.language==="he"}):o.jsxRuntimeExports.jsx(u.$,{variant:d,defaultValue:s?s[s.findIndex(a=>a.chartConfigId===e.chartConfigId)].columnId.map(a=>e.allowedColumnIds[e.allowedColumnIds.findIndex(l=>l.value===a)]).map(a=>a.value):[],onValueChange:a=>{const l={columnId:a||[],chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);C(p)},children:e.allowedColumnIds.map((a,l)=>o.jsxRuntimeExports.jsx(u.P,{label:a.label,value:a.label},l))}):e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.allowedColumnIds,isClearable:!1,isSearchable:!0,variant:d,defaultValue:s?e.allowedColumnIds[e.allowedColumnIds.findIndex(a=>a.value===s[s.findIndex(l=>l.chartConfigId===e.chartConfigId)].columnId)]:void 0,controlShouldRenderValue:!0,onChange:a=>{const l={columnId:a?.value,chartConfigId:e.chartConfigId},p=x?.map(c=>c.chartConfigId===l.chartConfigId?l:c);R(a?.graphSettings||{}),C(p)}}):o.jsxRuntimeExports.jsx(u.ye,{variant:d,defaultValue:s?e.allowedColumnIds[e.allowedColumnIds.findIndex(a=>a.value===s[s.findIndex(l=>l.chartConfigId===e.chartConfigId)].columnId)].label:"",onValueChange:a=>{const l=e.allowedColumnIds[e.allowedColumnIds.findIndex(V=>V.label===a)],p={columnId:l.value,chartConfigId:e.chartConfigId},c=x?.map(V=>V.chartConfigId===p.chartConfigId?p:V);R(l.graphSettings||{}),C(c)},children:e.allowedColumnIds.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:a.label,value:a.label},l))})]},r)),j?.map((e,r)=>o.jsxRuntimeExports.jsxs("div",{style:{width:e.width||`calc(${100/f}% - ${(f-1)/f}rem)`,flexGrow:e.width?0:1,flexShrink:e.ui!=="radio"||e.width?0:1,flexWrap:"wrap"},className:"pb-4",children:[o.jsxRuntimeExports.jsx(u.b,{className:"mb-2",children:e.label}),e.singleSelect?e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.availableValues,variant:d,isClearable:e.clearable===void 0?!0:e.clearable,isSearchable:!0,controlShouldRenderValue:!0,filterOption:m.Du(N),onChange:a=>{I(e.filter,a)},value:e.value,defaultValue:e.defaultValue}):o.jsxRuntimeExports.jsx(u.ye,{variant:d,defaultValue:e.defaultValue.value,onValueChange:a=>{I(e.filter,e.availableValues.filter(l=>l.value===a))},children:e.availableValues.map((a,l)=>o.jsxRuntimeExports.jsx(u.he,{label:`${a.label}`,value:`${a.value}`},l))}):o.jsxRuntimeExports.jsxs(o.jsxRuntimeExports.Fragment,{children:[e.ui!=="radio"?o.jsxRuntimeExports.jsx(m.ja,{options:e.availableValues,variant:d,size:"sm",isMulti:!0,isClearable:e.clearable===void 0?!0:e.clearable,isSearchable:!0,controlShouldRenderValue:!0,filterOption:m.Du(N),onChange:a=>{I(e.filter,a)},value:e.value,defaultValue:e.defaultValue}):o.jsxRuntimeExports.jsx(u.$,{variant:d,defaultValue:e.defaultValue?e.defaultValue.map(a=>`${a.value}`):[],value:e.value?e.value.map(a=>`${a.value}`):void 0,onValueChange:a=>{I(e.filter,e.availableValues.filter(l=>a.indexOf(`${l.value}`)!==-1))},children:e.availableValues.map((a,l)=>o.jsxRuntimeExports.jsx(u.P,{label:`${a.label}`,value:`${a.value}`},l))}),e.allowSelectAll?o.jsxRuntimeExports.jsx("button",{type:"button",className:"bg-transparent border-0 p-0 mt-2 cursor-pointer text-primary-blue-600 dark:text-primary-blue-400",onClick:()=>{I(e.filter,e.availableValues)},children:"Select all options"}):null]})]},r))]}):null,A!==!1&&t?.showColorScale!==!1?o.jsxRuntimeExports.jsx(se.ColorLegend,{width:t?.width,colorLegendTitle:t?.colorLegendTitle,colors:t?.colors||t?.lineColors||re.Colors[t?.theme||"light"].categoricalColors.colors,colorDomain:t?.colorDomain||t?.labels||[],showNAColor:t?.showNAColor===void 0||t?.showNAColor===null?!0:t?.showNAColor}):null,o.jsxRuntimeExports.jsx("div",{className:`flex flex-wrap gap-4 justify-center ${t?.language==="ar"||t?.language==="he"?"flex-row-reverse":"flex-row"}`,children:b.map((e,r)=>o.jsxRuntimeExports.jsx("div",{style:{width:`calc(${100/(y||Math.min(4,b.length||0))}% - ${((y||Math.min(4,b.length||0))-1)/(y||Math.min(4,b.length||0))}rem)`,minWidth:ue.checkIfNullOrUndefined(F)?"280px":`${F}px`},children:o.jsxRuntimeExports.jsx(oe.GraphEl,{graph:$,graphDataConfiguration:x,graphData:H.transformDataForGraph(D?H.transformDataForAggregation(z.filterData(v,q||[]).filter(a=>a[E]===e),D.keyColumn,D.aggregationColumnsSetting):z.filterData(v,q||[]).filter(a=>a[E]===e),$,x)||[],debugMode:w,settings:{...t||{},...h,theme:t?.theme||X,width:void 0,height:void 0,relativeHeight:t?.relativeHeight||.67,minHeight:K,graphTitle:`${e}`,graphDescription:void 0,graphDownload:!1,dataDownload:!1,backgroundColor:void 0,padding:"0",footNote:void 0,sources:void 0,showColorScale:t?.showColorScale===!1?!1:A===!1},readableHeader:Q||[]})},r))})]}):o.jsxRuntimeExports.jsx("div",{className:"w-full flex justify-center p-4",children:o.jsxRuntimeExports.jsx(te.w,{})}),t?.sources||t?.footNote?o.jsxRuntimeExports.jsx(ie.GraphFooter,{styles:{footnote:t?.styles?.footnote,source:t?.styles?.source},classNames:{footnote:t?.classNames?.footnote,source:t?.classNames?.source},sources:t?.sources,footNote:t?.footNote,width:t?.width}):null]})}exports.GriddedGraphs=ce;
2
2
  //# sourceMappingURL=GriddedGraphs.cjs.map
@@ -6,7 +6,7 @@ import { b as $, y as A, h as F, c as ca, $ as K, P as Q } from "./checkIfMultip
6
6
  import { w as da } from "./Spinner--r2RrJV8.js";
7
7
  import { j as V, D as O } from "./DropdownSelect-D8rFbygC.js";
8
8
  import { G as ha } from "./GraphContainer-CF6ws3pd.js";
9
- import { G as fa } from "./GraphEl-DDXkYObU.js";
9
+ import { G as fa } from "./GraphEl-C2xExzzY.js";
10
10
  import { f as pa, a as ga, b as ma, c as Ca, t as va } from "./fetchAndParseData-BAXhgTDM.js";
11
11
  import { Colors as wa } from "./Colors.js";
12
12
  import { a as ba, t as xa } from "./transformDataForAggregation-wdPf8bNt.js";
package/dist/HeatMap.cjs CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-6v2a2njQ.cjs"),q=require("react"),Ye=require("./index-DQA8q5sC.cjs"),Pe=require("./numberFormattingFunction-02t-wJta.cjs"),Ue=require("./Tooltip-BLa2EfMs.cjs"),ze=require("./getTextColorBasedOnBgColor-nqY-bsM_.cjs"),He=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Je=require("./XAxesLabels-C6o9jJal.cjs"),Ke=require("./YAxesLabels-BQ2aCazV.cjs"),Ge=require("./uniqBy-O05lp2S5.cjs"),Qe=require("./DetailsModal-DHttOA80.cjs"),Fe=require("./band-VYfcZeJ2.cjs"),Ze=require("./ordinal-CrsysVE-.cjs"),_e=require("./threshold-DNsSUf8Q.cjs"),et=require("./linear-CgUCbw9F.cjs"),Ve=require("./proxy-C4-uo6nS.cjs"),tt=require("./use-in-view-C3o_ntMv.cjs"),ot=require("./GraphHeader.cjs"),st=require("./GraphFooter.cjs"),it=require("./ColorLegendWithMouseOver.cjs"),rt=require("./LinearColorLegend.cjs"),nt=require("./ThresholdColorLegendWithMouseOver.cjs"),p=require("./Colors.cjs"),lt=require("./EmptyState-DX0t62iF.cjs"),Xe=require("./GraphContainer-B1EDxJ0S.cjs");function at(u){const e=t.compilerRuntimeExports.c(86),{data:l,showColumnLabels:z,leftMargin:f,rightMargin:J,truncateBy:y,width:K,height:Q,topMargin:ge,bottomMargin:pe,tooltip:Z,onSeriesMouseOver:n,suffix:$e,prefix:r,showValues:_,colorDomain:j,colors:B,noDataColor:ie,scaleType:re,showRowLabels:fe,selectedColor:ee,onSeriesMouseClick:W,resetSelectionOnDoubleClick:Ce,detailsOnClick:R,styles:m,classNames:c,animate:h,precision:ne}=u,Me=q.useRef(null);let le;e[0]!==h.amount||e[1]!==h.once?(le={once:h.once,amount:h.amount},e[0]=h.amount,e[1]=h.once,e[2]=le):le=e[2];const E=tt.useInView(Me,le);let ae;e[3]!==pe||e[4]!==f||e[5]!==J||e[6]!==ge?(ae={top:ge,bottom:pe,left:f,right:J},e[3]=pe,e[4]=f,e[5]=J,e[6]=ge,e[7]=ae):ae=e[7];const d=ae,[$,ve]=q.useState(void 0),[C,ye]=q.useState(void 0),[ce,ue]=q.useState(void 0),[de,he]=q.useState(void 0),a=K-d.left-d.right,i=Q-d.top-d.bottom;let G,F,M,O,k,S,D,L,N,A,V,H,g;if(e[8]!==h.duration||e[9]!==c?.graphObjectValues||e[10]!==c?.xAxis?.labels||e[11]!==c?.yAxis?.labels||e[12]!==j||e[13]!==B||e[14]!==l||e[15]!==R||e[16]!==i||e[17]!==a||e[18]!==Q||e[19]!==E||e[20]!==d.left||e[21]!==d.top||e[22]!==$||e[23]!==C||e[24]!==ie||e[25]!==W||e[26]!==n||e[27]!==ne||e[28]!==r||e[29]!==Ce||e[30]!==re||e[31]!==ee||e[32]!==z||e[33]!==fe||e[34]!==_||e[35]!==m?.graphObjectValues||e[36]!==m?.xAxis?.labels||e[37]!==m?.yAxis?.labels||e[38]!==$e||e[39]!==y||e[40]!==K){const oe=Ge.uniqBy(l,"column",!0),xe=Ge.uniqBy(l,"row",!0),s=Fe.band().domain(xe).range([0,i]),X=s.bandwidth(),I=Fe.band().domain(oe).range([0,a]),Y=I.bandwidth(),se=re==="categorical"?Ze.ordinal().domain(j).range(B):re==="threshold"?_e.threshold().domain(j).range(B):et.linear().domain(j).range(B);G=Ve.motion.svg,A=`${K}px`,V=`${Q}px`,H=`0 0 ${K} ${Q}`,e[54]===Symbol.for("react.memo_cache_sentinel")?(g={marginLeft:"auto",marginRight:"auto"},e[54]=g):g=e[54],F="ltr",M=Me,O=t.jsxRuntimeExports.jsx("g",{transform:`translate(${d.left},0)`,children:z?oe.map((o,v)=>t.jsxRuntimeExports.jsx(Je.XAxesLabels,{y:0,x:I(o),width:Y,height:d.top-5,value:`${o}`.length<y?`${o}`:`${`${o}`.substring(0,y)}...`,style:m?.xAxis?.labels,className:c?.xAxis?.labels,alignment:"bottom",animate:{duration:0,once:!0,amount:0},isInView:E},v)):null}),k=t.jsxRuntimeExports.jsx("g",{transform:`translate(0,${d.top})`,children:fe?xe.map((o,v)=>t.jsxRuntimeExports.jsx(Ke.YAxesLabels,{value:`${o}`.length<y?`${o}`:`${`${o}`.substring(0,y)}...`,y:s(o),x:0,width:d.left,height:X,alignment:"right",style:m?.yAxis?.labels,className:c?.yAxis?.labels,animate:{duration:0,once:!0,amount:0},isInView:E},v)):null}),S=`translate(${d.left},${d.top})`,D=xe.map((o,v)=>t.jsxRuntimeExports.jsx("g",{transform:`translate(0,${s(o)})`,children:oe.map(P=>t.jsxRuntimeExports.jsx("rect",{x:I(P),y:0,width:Y,height:X,style:{fill:ie},className:"stroke-1 stroke-primary-white dark:stroke-primary-gray-700"},`${o}-${P}`))},v)),L=l.filter(ct).map((o,v)=>{const P=He.checkIfNullOrUndefined(o.value)?ie:se(o.value);return t.jsxRuntimeExports.jsxs("g",{transform:`translate(${I(o.column)},${s(o.row)})`,onMouseEnter:U=>{ye(o),he(U.clientY),ue(U.clientX),n?.(o)},onClick:()=>{(W||R)&&(Ye.isEqual($,o)&&Ce?(ve(void 0),W?.(void 0)):(ve(o),W?.(o)))},onMouseMove:U=>{ye(o),he(U.clientY),ue(U.clientX)},onMouseLeave:()=>{ye(void 0),ue(void 0),he(void 0),n?.(void 0)},opacity:ee?ee===P?1:.3:1,children:[t.jsxRuntimeExports.jsx(Ve.motion.rect,{x:0,y:0,width:Y,height:X,className:"stroke-1 stroke-primary-white dark:stroke-primary-gray-700",exit:{opacity:0,transition:{duration:h.duration}},variants:{initial:{fill:P,opacity:0},whileInView:{fill:P,opacity:1,transition:{duration:h.duration}}},initial:"initial",animate:E?"whileInView":"initial"}),_&&!He.checkIfNullOrUndefined(o.value)?t.jsxRuntimeExports.jsx(Ve.motion.g,{variants:{initial:{opacity:0},whileInView:{opacity:1,transition:{duration:h.duration}}},initial:"initial",animate:E?"whileInView":"initial",exit:{opacity:0,transition:{duration:h.duration}},children:t.jsxRuntimeExports.jsx("foreignObject",{y:0,x:0,width:Y,height:X,children:t.jsxRuntimeExports.jsx("div",{className:"flex flex-col justify-center items-center h-inherit p-1",children:t.jsxRuntimeExports.jsx("p",{className:t.mo("text-xs text-center m-0 leading-[1.25] graph-value",c?.graphObjectValues),style:{color:ze.getTextColorBasedOnBgColor(P),...m?.graphObjectValues||{}},children:Pe.numberFormattingFunction(o.value,"NA",ne,r,$e)})})},v)}):null]},`${o.column}-${o.row}`)}),N=C?t.jsxRuntimeExports.jsx("rect",{x:I(C.column),y:s(C.row),width:Y,height:X,style:{fill:"none",fillOpacity:0,strokeWidth:1.5},className:"stroke-primary-gray-700 dark:stroke-primary-gray-300"}):null,e[8]=h.duration,e[9]=c?.graphObjectValues,e[10]=c?.xAxis?.labels,e[11]=c?.yAxis?.labels,e[12]=j,e[13]=B,e[14]=l,e[15]=R,e[16]=i,e[17]=a,e[18]=Q,e[19]=E,e[20]=d.left,e[21]=d.top,e[22]=$,e[23]=C,e[24]=ie,e[25]=W,e[26]=n,e[27]=ne,e[28]=r,e[29]=Ce,e[30]=re,e[31]=ee,e[32]=z,e[33]=fe,e[34]=_,e[35]=m?.graphObjectValues,e[36]=m?.xAxis?.labels,e[37]=m?.yAxis?.labels,e[38]=$e,e[39]=y,e[40]=K,e[41]=G,e[42]=F,e[43]=M,e[44]=O,e[45]=k,e[46]=S,e[47]=D,e[48]=L,e[49]=N,e[50]=A,e[51]=V,e[52]=H,e[53]=g}else G=e[41],F=e[42],M=e[43],O=e[44],k=e[45],S=e[46],D=e[47],L=e[48],N=e[49],A=e[50],V=e[51],H=e[52],g=e[53];let T;e[55]!==S||e[56]!==D||e[57]!==L||e[58]!==N?(T=t.jsxRuntimeExports.jsxs("g",{transform:S,children:[D,L,N]}),e[55]=S,e[56]=D,e[57]=L,e[58]=N,e[59]=T):T=e[59];let b;e[60]!==G||e[61]!==F||e[62]!==M||e[63]!==O||e[64]!==k||e[65]!==T||e[66]!==A||e[67]!==V||e[68]!==H||e[69]!==g?(b=t.jsxRuntimeExports.jsxs(G,{width:A,height:V,viewBox:H,style:g,direction:F,ref:M,children:[O,k,T]}),e[60]=G,e[61]=F,e[62]=M,e[63]=O,e[64]=k,e[65]=T,e[66]=A,e[67]=V,e[68]=H,e[69]=g,e[70]=b):b=e[70];let w;e[71]!==c?.tooltip||e[72]!==ce||e[73]!==de||e[74]!==C||e[75]!==m?.tooltip||e[76]!==Z?(w=C&&Z&&ce&&de?t.jsxRuntimeExports.jsx(Ue.Tooltip,{data:C,body:Z,xPos:ce,yPos:de,backgroundStyle:m?.tooltip,className:c?.tooltip}):null,e[71]=c?.tooltip,e[72]=ce,e[73]=de,e[74]=C,e[75]=m?.tooltip,e[76]=Z,e[77]=w):w=e[77];let x;e[78]!==c?.modal||e[79]!==R||e[80]!==$?(x=R&&$!==void 0?t.jsxRuntimeExports.jsx(Qe.DetailsModal,{body:R,data:$,setData:ve,className:c?.modal}):null,e[78]=c?.modal,e[79]=R,e[80]=$,e[81]=x):x=e[81];let te;return e[82]!==b||e[83]!==w||e[84]!==x?(te=t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[b,w,x]}),e[82]=b,e[83]=w,e[84]=x,e[85]=te):te=e[85],te}function ct(u){return!He.checkIfNullOrUndefined(u.value)}function ut(u){const e=t.compilerRuntimeExports.c(87),{data:l,graphTitle:z,colors:f,sources:J,graphDescription:y,showColumnLabels:K,leftMargin:Q,rightMargin:ge,truncateBy:pe,height:Z,width:n,scaleType:$e,colorDomain:r,footNote:_,colorLegendTitle:j,padding:B,backgroundColor:ie,topMargin:re,bottomMargin:fe,tooltip:ee,onSeriesMouseOver:W,suffix:Ce,prefix:R,showRowLabels:m,relativeHeight:c,showValues:h,graphID:ne,noDataColor:Me,showColorScale:le,onSeriesMouseClick:E,graphDownload:ae,dataDownload:d,fillContainer:$,language:ve,showNAColor:C,minHeight:ye,theme:ce,ariaLabel:ue,resetSelectionOnDoubleClick:de,detailsOnClick:he,styles:a,classNames:i,animate:G,precision:F}=u,M=K===void 0?!0:K,O=Q===void 0?100:Q,k=ge===void 0?10:ge,S=pe===void 0?999:pe,D=ie===void 0?!1:ie,L=re===void 0?30:re,N=fe===void 0?10:fe,A=Ce===void 0?"":Ce,V=R===void 0?"":R,H=m===void 0?!0:m,g=Me===void 0?p.Colors.gray:Me,T=le===void 0?!0:le,b=ae===void 0?!1:ae,w=d===void 0?!1:d,x=$===void 0?!0:$,te=ve===void 0?"en":ve,oe=C===void 0?!0:C,xe=ye===void 0?0:ye,s=ce===void 0?"light":ce,X=de===void 0?!0:de,I=G===void 0?!1:G,Y=F===void 0?2:F,[se,o]=q.useState(0),[v,P]=q.useState(0),[U,Te]=q.useState(void 0),De=q.useRef(null),Ie=q.useRef(null);let Oe,ke;e[0]===Symbol.for("react.memo_cache_sentinel")?(Oe=()=>{const Be=new ResizeObserver(We=>{o(We[0].target.clientWidth||620),P(We[0].target.clientHeight||480)});return De.current&&Be.observe(De.current),()=>Be.disconnect()},ke=[],e[0]=Oe,e[1]=ke):(Oe=e[0],ke=e[1]),q.useEffect(Oe,ke);const me=$e||(typeof r[0]=="string"?"categorical":r.length===2?"linear":"threshold"),Le=i?.graphContainer,Ne=a?.graphContainer,Ae=x?void 0:n;let je;e[2]!==i?.description||e[3]!==i?.title||e[4]!==l||e[5]!==w||e[6]!==y||e[7]!==b||e[8]!==z||e[9]!==a?.description||e[10]!==a?.title||e[11]!==n?(je=z||y||b||w?t.jsxRuntimeExports.jsx(ot.GraphHeader,{styles:{title:a?.title,description:a?.description},classNames:{title:i?.title,description:i?.description},graphTitle:z,graphDescription:y,width:n,graphDownload:b?Ie:void 0,dataDownload:w?l.map(pt).filter(gt).length>0?l.map(mt).filter(xt):l.filter(ht):null}):null,e[2]=i?.description,e[3]=i?.title,e[4]=l,e[5]=w,e[6]=y,e[7]=b,e[8]=z,e[9]=a?.description,e[10]=a?.title,e[11]=n,e[12]=je):je=e[12];let be;e[13]!==i?.colorLegend||e[14]!==r||e[15]!==j||e[16]!==f||e[17]!==l.length||e[18]!==x||e[19]!==g||e[20]!==me||e[21]!==T||e[22]!==oe||e[23]!==s||e[24]!==n?(be=T&&l.length>0?me==="categorical"?t.jsxRuntimeExports.jsx(it.ColorLegendWithMouseOver,{width:x?void 0:n,colorLegendTitle:j,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),colorDomain:r.map(dt),setSelectedColor:Te,showNAColor:oe,className:i?.colorLegend}):me==="threshold"?t.jsxRuntimeExports.jsx(nt.ThresholdColorLegendWithMouseOver,{width:x?void 0:n,colorLegendTitle:j,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),colorDomain:r,setSelectedColor:Te,naColor:g,showNAColor:oe}):t.jsxRuntimeExports.jsx(rt.LinearColorLegend,{width:x?void 0:n,colorLegendTitle:j,colors:f||[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]],colorDomain:r,className:i?.colorLegend}):null,e[13]=i?.colorLegend,e[14]=r,e[15]=j,e[16]=f,e[17]=l.length,e[18]=x,e[19]=g,e[20]=me,e[21]=T,e[22]=oe,e[23]=s,e[24]=n,e[25]=be):be=e[25];let we;e[26]!==l.length?(we=l.length===0&&t.jsxRuntimeExports.jsx(lt.EmptyState,{}),e[26]=l.length,e[27]=we):we=e[27];let qe;e[28]!==I||e[29]!==N||e[30]!==i||e[31]!==r||e[32]!==f||e[33]!==l||e[34]!==he||e[35]!==x||e[36]!==O||e[37]!==g||e[38]!==E||e[39]!==W||e[40]!==Y||e[41]!==V||e[42]!==X||e[43]!==k||e[44]!==me||e[45]!==U||e[46]!==M||e[47]!==H||e[48]!==h||e[49]!==a||e[50]!==A||e[51]!==v||e[52]!==se||e[53]!==s||e[54]!==ee||e[55]!==L||e[56]!==S||e[57]!==n?(qe=se&&v&&l.length>0?t.jsxRuntimeExports.jsx(at,{data:l,colorDomain:r,width:x||!n||se<n?se:n,height:v,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),noDataColor:g,scaleType:me,showColumnLabels:M,leftMargin:O,rightMargin:k,topMargin:L,bottomMargin:N,selectedColor:U,truncateBy:S,showRowLabels:H,tooltip:ee,onSeriesMouseOver:W,showValues:h,suffix:A,prefix:V,onSeriesMouseClick:E,resetSelectionOnDoubleClick:X,detailsOnClick:he,styles:a,classNames:i,animate:I===!0?{duration:.5,once:!0,amount:.5}:I||{duration:0,once:!0,amount:0},precision:Y}):null,e[28]=I,e[29]=N,e[30]=i,e[31]=r,e[32]=f,e[33]=l,e[34]=he,e[35]=x,e[36]=O,e[37]=g,e[38]=E,e[39]=W,e[40]=Y,e[41]=V,e[42]=X,e[43]=k,e[44]=me,e[45]=U,e[46]=M,e[47]=H,e[48]=h,e[49]=a,e[50]=A,e[51]=v,e[52]=se,e[53]=s,e[54]=ee,e[55]=L,e[56]=S,e[57]=n,e[58]=qe):qe=e[58];let Re;e[59]!==we||e[60]!==qe?(Re=t.jsxRuntimeExports.jsxs(Xe.GraphArea,{ref:De,children:[we,qe]}),e[59]=we,e[60]=qe,e[61]=Re):Re=e[61];let Ee;e[62]!==i?.footnote||e[63]!==i?.source||e[64]!==_||e[65]!==J||e[66]!==a?.footnote||e[67]!==a?.source||e[68]!==n?(Ee=J||_?t.jsxRuntimeExports.jsx(st.GraphFooter,{styles:{footnote:a?.footnote,source:a?.source},classNames:{footnote:i?.footnote,source:i?.source},sources:J,footNote:_,width:n}):null,e[62]=i?.footnote,e[63]=i?.source,e[64]=_,e[65]=J,e[66]=a?.footnote,e[67]=a?.source,e[68]=n,e[69]=Ee):Ee=e[69];let Se;return e[70]!==ue||e[71]!==D||e[72]!==ne||e[73]!==Z||e[74]!==te||e[75]!==xe||e[76]!==B||e[77]!==c||e[78]!==Le||e[79]!==Ne||e[80]!==Ae||e[81]!==je||e[82]!==be||e[83]!==Re||e[84]!==Ee||e[85]!==s?(Se=t.jsxRuntimeExports.jsxs(Xe.GraphContainer,{className:Le,style:Ne,id:ne,ref:Ie,"aria-label":ue,backgroundColor:D,theme:s,language:te,minHeight:xe,width:Ae,height:Z,relativeHeight:c,padding:B,children:[je,be,Re,Ee]}),e[70]=ue,e[71]=D,e[72]=ne,e[73]=Z,e[74]=te,e[75]=xe,e[76]=B,e[77]=c,e[78]=Le,e[79]=Ne,e[80]=Ae,e[81]=je,e[82]=be,e[83]=Re,e[84]=Ee,e[85]=s,e[86]=Se):Se=e[86],Se}function dt(u){return`${u}`}function ht(u){return u!==void 0}function xt(u){return u!==void 0}function mt(u){return u.data}function gt(u){return u!==void 0}function pt(u){return u.data}exports.HeatMap=ut;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-6v2a2njQ.cjs"),q=require("react"),Ye=require("./index-DQA8q5sC.cjs"),Pe=require("./numberFormattingFunction-02t-wJta.cjs"),Ue=require("./Tooltip-BLa2EfMs.cjs"),ze=require("./getTextColorBasedOnBgColor-nqY-bsM_.cjs"),He=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Je=require("./XAxesLabels-C6o9jJal.cjs"),Ke=require("./YAxesLabels-BQ2aCazV.cjs"),Ge=require("./uniqBy-O05lp2S5.cjs"),Qe=require("./DetailsModal-DHttOA80.cjs"),Fe=require("./band-VYfcZeJ2.cjs"),Ze=require("./ordinal-CrsysVE-.cjs"),_e=require("./threshold-DNsSUf8Q.cjs"),et=require("./linear-CgUCbw9F.cjs"),Ve=require("./proxy-C4-uo6nS.cjs"),tt=require("./use-in-view-C3o_ntMv.cjs"),ot=require("./GraphHeader.cjs"),st=require("./GraphFooter.cjs"),it=require("./ColorLegendWithMouseOver.cjs"),rt=require("./LinearColorLegend.cjs"),nt=require("./ThresholdColorLegendWithMouseOver.cjs"),p=require("./Colors.cjs"),lt=require("./EmptyState-N1eHt3vq.cjs"),Xe=require("./GraphContainer-B1EDxJ0S.cjs");function at(u){const e=t.compilerRuntimeExports.c(86),{data:l,showColumnLabels:z,leftMargin:f,rightMargin:J,truncateBy:y,width:K,height:Q,topMargin:ge,bottomMargin:pe,tooltip:Z,onSeriesMouseOver:n,suffix:$e,prefix:r,showValues:_,colorDomain:j,colors:B,noDataColor:ie,scaleType:re,showRowLabels:fe,selectedColor:ee,onSeriesMouseClick:W,resetSelectionOnDoubleClick:Ce,detailsOnClick:R,styles:m,classNames:c,animate:h,precision:ne}=u,Me=q.useRef(null);let le;e[0]!==h.amount||e[1]!==h.once?(le={once:h.once,amount:h.amount},e[0]=h.amount,e[1]=h.once,e[2]=le):le=e[2];const E=tt.useInView(Me,le);let ae;e[3]!==pe||e[4]!==f||e[5]!==J||e[6]!==ge?(ae={top:ge,bottom:pe,left:f,right:J},e[3]=pe,e[4]=f,e[5]=J,e[6]=ge,e[7]=ae):ae=e[7];const d=ae,[$,ve]=q.useState(void 0),[C,ye]=q.useState(void 0),[ce,ue]=q.useState(void 0),[de,he]=q.useState(void 0),a=K-d.left-d.right,i=Q-d.top-d.bottom;let G,F,M,O,k,S,D,L,N,A,V,H,g;if(e[8]!==h.duration||e[9]!==c?.graphObjectValues||e[10]!==c?.xAxis?.labels||e[11]!==c?.yAxis?.labels||e[12]!==j||e[13]!==B||e[14]!==l||e[15]!==R||e[16]!==i||e[17]!==a||e[18]!==Q||e[19]!==E||e[20]!==d.left||e[21]!==d.top||e[22]!==$||e[23]!==C||e[24]!==ie||e[25]!==W||e[26]!==n||e[27]!==ne||e[28]!==r||e[29]!==Ce||e[30]!==re||e[31]!==ee||e[32]!==z||e[33]!==fe||e[34]!==_||e[35]!==m?.graphObjectValues||e[36]!==m?.xAxis?.labels||e[37]!==m?.yAxis?.labels||e[38]!==$e||e[39]!==y||e[40]!==K){const oe=Ge.uniqBy(l,"column",!0),xe=Ge.uniqBy(l,"row",!0),s=Fe.band().domain(xe).range([0,i]),X=s.bandwidth(),I=Fe.band().domain(oe).range([0,a]),Y=I.bandwidth(),se=re==="categorical"?Ze.ordinal().domain(j).range(B):re==="threshold"?_e.threshold().domain(j).range(B):et.linear().domain(j).range(B);G=Ve.motion.svg,A=`${K}px`,V=`${Q}px`,H=`0 0 ${K} ${Q}`,e[54]===Symbol.for("react.memo_cache_sentinel")?(g={marginLeft:"auto",marginRight:"auto"},e[54]=g):g=e[54],F="ltr",M=Me,O=t.jsxRuntimeExports.jsx("g",{transform:`translate(${d.left},0)`,children:z?oe.map((o,v)=>t.jsxRuntimeExports.jsx(Je.XAxesLabels,{y:0,x:I(o),width:Y,height:d.top-5,value:`${o}`.length<y?`${o}`:`${`${o}`.substring(0,y)}...`,style:m?.xAxis?.labels,className:c?.xAxis?.labels,alignment:"bottom",animate:{duration:0,once:!0,amount:0},isInView:E},v)):null}),k=t.jsxRuntimeExports.jsx("g",{transform:`translate(0,${d.top})`,children:fe?xe.map((o,v)=>t.jsxRuntimeExports.jsx(Ke.YAxesLabels,{value:`${o}`.length<y?`${o}`:`${`${o}`.substring(0,y)}...`,y:s(o),x:0,width:d.left,height:X,alignment:"right",style:m?.yAxis?.labels,className:c?.yAxis?.labels,animate:{duration:0,once:!0,amount:0},isInView:E},v)):null}),S=`translate(${d.left},${d.top})`,D=xe.map((o,v)=>t.jsxRuntimeExports.jsx("g",{transform:`translate(0,${s(o)})`,children:oe.map(P=>t.jsxRuntimeExports.jsx("rect",{x:I(P),y:0,width:Y,height:X,style:{fill:ie},className:"stroke-1 stroke-primary-white dark:stroke-primary-gray-700"},`${o}-${P}`))},v)),L=l.filter(ct).map((o,v)=>{const P=He.checkIfNullOrUndefined(o.value)?ie:se(o.value);return t.jsxRuntimeExports.jsxs("g",{transform:`translate(${I(o.column)},${s(o.row)})`,onMouseEnter:U=>{ye(o),he(U.clientY),ue(U.clientX),n?.(o)},onClick:()=>{(W||R)&&(Ye.isEqual($,o)&&Ce?(ve(void 0),W?.(void 0)):(ve(o),W?.(o)))},onMouseMove:U=>{ye(o),he(U.clientY),ue(U.clientX)},onMouseLeave:()=>{ye(void 0),ue(void 0),he(void 0),n?.(void 0)},opacity:ee?ee===P?1:.3:1,children:[t.jsxRuntimeExports.jsx(Ve.motion.rect,{x:0,y:0,width:Y,height:X,className:"stroke-1 stroke-primary-white dark:stroke-primary-gray-700",exit:{opacity:0,transition:{duration:h.duration}},variants:{initial:{fill:P,opacity:0},whileInView:{fill:P,opacity:1,transition:{duration:h.duration}}},initial:"initial",animate:E?"whileInView":"initial"}),_&&!He.checkIfNullOrUndefined(o.value)?t.jsxRuntimeExports.jsx(Ve.motion.g,{variants:{initial:{opacity:0},whileInView:{opacity:1,transition:{duration:h.duration}}},initial:"initial",animate:E?"whileInView":"initial",exit:{opacity:0,transition:{duration:h.duration}},children:t.jsxRuntimeExports.jsx("foreignObject",{y:0,x:0,width:Y,height:X,children:t.jsxRuntimeExports.jsx("div",{className:"flex flex-col justify-center items-center h-inherit p-1",children:t.jsxRuntimeExports.jsx("p",{className:t.mo("text-xs text-center m-0 leading-[1.25] graph-value",c?.graphObjectValues),style:{color:ze.getTextColorBasedOnBgColor(P),...m?.graphObjectValues||{}},children:Pe.numberFormattingFunction(o.value,"NA",ne,r,$e)})})},v)}):null]},`${o.column}-${o.row}`)}),N=C?t.jsxRuntimeExports.jsx("rect",{x:I(C.column),y:s(C.row),width:Y,height:X,style:{fill:"none",fillOpacity:0,strokeWidth:1.5},className:"stroke-primary-gray-700 dark:stroke-primary-gray-300"}):null,e[8]=h.duration,e[9]=c?.graphObjectValues,e[10]=c?.xAxis?.labels,e[11]=c?.yAxis?.labels,e[12]=j,e[13]=B,e[14]=l,e[15]=R,e[16]=i,e[17]=a,e[18]=Q,e[19]=E,e[20]=d.left,e[21]=d.top,e[22]=$,e[23]=C,e[24]=ie,e[25]=W,e[26]=n,e[27]=ne,e[28]=r,e[29]=Ce,e[30]=re,e[31]=ee,e[32]=z,e[33]=fe,e[34]=_,e[35]=m?.graphObjectValues,e[36]=m?.xAxis?.labels,e[37]=m?.yAxis?.labels,e[38]=$e,e[39]=y,e[40]=K,e[41]=G,e[42]=F,e[43]=M,e[44]=O,e[45]=k,e[46]=S,e[47]=D,e[48]=L,e[49]=N,e[50]=A,e[51]=V,e[52]=H,e[53]=g}else G=e[41],F=e[42],M=e[43],O=e[44],k=e[45],S=e[46],D=e[47],L=e[48],N=e[49],A=e[50],V=e[51],H=e[52],g=e[53];let T;e[55]!==S||e[56]!==D||e[57]!==L||e[58]!==N?(T=t.jsxRuntimeExports.jsxs("g",{transform:S,children:[D,L,N]}),e[55]=S,e[56]=D,e[57]=L,e[58]=N,e[59]=T):T=e[59];let b;e[60]!==G||e[61]!==F||e[62]!==M||e[63]!==O||e[64]!==k||e[65]!==T||e[66]!==A||e[67]!==V||e[68]!==H||e[69]!==g?(b=t.jsxRuntimeExports.jsxs(G,{width:A,height:V,viewBox:H,style:g,direction:F,ref:M,children:[O,k,T]}),e[60]=G,e[61]=F,e[62]=M,e[63]=O,e[64]=k,e[65]=T,e[66]=A,e[67]=V,e[68]=H,e[69]=g,e[70]=b):b=e[70];let w;e[71]!==c?.tooltip||e[72]!==ce||e[73]!==de||e[74]!==C||e[75]!==m?.tooltip||e[76]!==Z?(w=C&&Z&&ce&&de?t.jsxRuntimeExports.jsx(Ue.Tooltip,{data:C,body:Z,xPos:ce,yPos:de,backgroundStyle:m?.tooltip,className:c?.tooltip}):null,e[71]=c?.tooltip,e[72]=ce,e[73]=de,e[74]=C,e[75]=m?.tooltip,e[76]=Z,e[77]=w):w=e[77];let x;e[78]!==c?.modal||e[79]!==R||e[80]!==$?(x=R&&$!==void 0?t.jsxRuntimeExports.jsx(Qe.DetailsModal,{body:R,data:$,setData:ve,className:c?.modal}):null,e[78]=c?.modal,e[79]=R,e[80]=$,e[81]=x):x=e[81];let te;return e[82]!==b||e[83]!==w||e[84]!==x?(te=t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[b,w,x]}),e[82]=b,e[83]=w,e[84]=x,e[85]=te):te=e[85],te}function ct(u){return!He.checkIfNullOrUndefined(u.value)}function ut(u){const e=t.compilerRuntimeExports.c(87),{data:l,graphTitle:z,colors:f,sources:J,graphDescription:y,showColumnLabels:K,leftMargin:Q,rightMargin:ge,truncateBy:pe,height:Z,width:n,scaleType:$e,colorDomain:r,footNote:_,colorLegendTitle:j,padding:B,backgroundColor:ie,topMargin:re,bottomMargin:fe,tooltip:ee,onSeriesMouseOver:W,suffix:Ce,prefix:R,showRowLabels:m,relativeHeight:c,showValues:h,graphID:ne,noDataColor:Me,showColorScale:le,onSeriesMouseClick:E,graphDownload:ae,dataDownload:d,fillContainer:$,language:ve,showNAColor:C,minHeight:ye,theme:ce,ariaLabel:ue,resetSelectionOnDoubleClick:de,detailsOnClick:he,styles:a,classNames:i,animate:G,precision:F}=u,M=K===void 0?!0:K,O=Q===void 0?100:Q,k=ge===void 0?10:ge,S=pe===void 0?999:pe,D=ie===void 0?!1:ie,L=re===void 0?30:re,N=fe===void 0?10:fe,A=Ce===void 0?"":Ce,V=R===void 0?"":R,H=m===void 0?!0:m,g=Me===void 0?p.Colors.gray:Me,T=le===void 0?!0:le,b=ae===void 0?!1:ae,w=d===void 0?!1:d,x=$===void 0?!0:$,te=ve===void 0?"en":ve,oe=C===void 0?!0:C,xe=ye===void 0?0:ye,s=ce===void 0?"light":ce,X=de===void 0?!0:de,I=G===void 0?!1:G,Y=F===void 0?2:F,[se,o]=q.useState(0),[v,P]=q.useState(0),[U,Te]=q.useState(void 0),De=q.useRef(null),Ie=q.useRef(null);let Oe,ke;e[0]===Symbol.for("react.memo_cache_sentinel")?(Oe=()=>{const Be=new ResizeObserver(We=>{o(We[0].target.clientWidth||620),P(We[0].target.clientHeight||480)});return De.current&&Be.observe(De.current),()=>Be.disconnect()},ke=[],e[0]=Oe,e[1]=ke):(Oe=e[0],ke=e[1]),q.useEffect(Oe,ke);const me=$e||(typeof r[0]=="string"?"categorical":r.length===2?"linear":"threshold"),Le=i?.graphContainer,Ne=a?.graphContainer,Ae=x?void 0:n;let je;e[2]!==i?.description||e[3]!==i?.title||e[4]!==l||e[5]!==w||e[6]!==y||e[7]!==b||e[8]!==z||e[9]!==a?.description||e[10]!==a?.title||e[11]!==n?(je=z||y||b||w?t.jsxRuntimeExports.jsx(ot.GraphHeader,{styles:{title:a?.title,description:a?.description},classNames:{title:i?.title,description:i?.description},graphTitle:z,graphDescription:y,width:n,graphDownload:b?Ie:void 0,dataDownload:w?l.map(pt).filter(gt).length>0?l.map(mt).filter(xt):l.filter(ht):null}):null,e[2]=i?.description,e[3]=i?.title,e[4]=l,e[5]=w,e[6]=y,e[7]=b,e[8]=z,e[9]=a?.description,e[10]=a?.title,e[11]=n,e[12]=je):je=e[12];let be;e[13]!==i?.colorLegend||e[14]!==r||e[15]!==j||e[16]!==f||e[17]!==l.length||e[18]!==x||e[19]!==g||e[20]!==me||e[21]!==T||e[22]!==oe||e[23]!==s||e[24]!==n?(be=T&&l.length>0?me==="categorical"?t.jsxRuntimeExports.jsx(it.ColorLegendWithMouseOver,{width:x?void 0:n,colorLegendTitle:j,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),colorDomain:r.map(dt),setSelectedColor:Te,showNAColor:oe,className:i?.colorLegend}):me==="threshold"?t.jsxRuntimeExports.jsx(nt.ThresholdColorLegendWithMouseOver,{width:x?void 0:n,colorLegendTitle:j,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),colorDomain:r,setSelectedColor:Te,naColor:g,showNAColor:oe}):t.jsxRuntimeExports.jsx(rt.LinearColorLegend,{width:x?void 0:n,colorLegendTitle:j,colors:f||[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]],colorDomain:r,className:i?.colorLegend}):null,e[13]=i?.colorLegend,e[14]=r,e[15]=j,e[16]=f,e[17]=l.length,e[18]=x,e[19]=g,e[20]=me,e[21]=T,e[22]=oe,e[23]=s,e[24]=n,e[25]=be):be=e[25];let we;e[26]!==l.length?(we=l.length===0&&t.jsxRuntimeExports.jsx(lt.EmptyState,{}),e[26]=l.length,e[27]=we):we=e[27];let qe;e[28]!==I||e[29]!==N||e[30]!==i||e[31]!==r||e[32]!==f||e[33]!==l||e[34]!==he||e[35]!==x||e[36]!==O||e[37]!==g||e[38]!==E||e[39]!==W||e[40]!==Y||e[41]!==V||e[42]!==X||e[43]!==k||e[44]!==me||e[45]!==U||e[46]!==M||e[47]!==H||e[48]!==h||e[49]!==a||e[50]!==A||e[51]!==v||e[52]!==se||e[53]!==s||e[54]!==ee||e[55]!==L||e[56]!==S||e[57]!==n?(qe=se&&v&&l.length>0?t.jsxRuntimeExports.jsx(at,{data:l,colorDomain:r,width:x||!n||se<n?se:n,height:v,colors:f||(typeof r[0]=="string"?p.Colors[s].categoricalColors.colors:r.length===2?[p.Colors[s].sequentialColors.neutralColorsx09[0],p.Colors[s].sequentialColors.neutralColorsx09[8]]:p.Colors[s].sequentialColors[`neutralColorsx0${r.length+1}`]),noDataColor:g,scaleType:me,showColumnLabels:M,leftMargin:O,rightMargin:k,topMargin:L,bottomMargin:N,selectedColor:U,truncateBy:S,showRowLabels:H,tooltip:ee,onSeriesMouseOver:W,showValues:h,suffix:A,prefix:V,onSeriesMouseClick:E,resetSelectionOnDoubleClick:X,detailsOnClick:he,styles:a,classNames:i,animate:I===!0?{duration:.5,once:!0,amount:.5}:I||{duration:0,once:!0,amount:0},precision:Y}):null,e[28]=I,e[29]=N,e[30]=i,e[31]=r,e[32]=f,e[33]=l,e[34]=he,e[35]=x,e[36]=O,e[37]=g,e[38]=E,e[39]=W,e[40]=Y,e[41]=V,e[42]=X,e[43]=k,e[44]=me,e[45]=U,e[46]=M,e[47]=H,e[48]=h,e[49]=a,e[50]=A,e[51]=v,e[52]=se,e[53]=s,e[54]=ee,e[55]=L,e[56]=S,e[57]=n,e[58]=qe):qe=e[58];let Re;e[59]!==we||e[60]!==qe?(Re=t.jsxRuntimeExports.jsxs(Xe.GraphArea,{ref:De,children:[we,qe]}),e[59]=we,e[60]=qe,e[61]=Re):Re=e[61];let Ee;e[62]!==i?.footnote||e[63]!==i?.source||e[64]!==_||e[65]!==J||e[66]!==a?.footnote||e[67]!==a?.source||e[68]!==n?(Ee=J||_?t.jsxRuntimeExports.jsx(st.GraphFooter,{styles:{footnote:a?.footnote,source:a?.source},classNames:{footnote:i?.footnote,source:i?.source},sources:J,footNote:_,width:n}):null,e[62]=i?.footnote,e[63]=i?.source,e[64]=_,e[65]=J,e[66]=a?.footnote,e[67]=a?.source,e[68]=n,e[69]=Ee):Ee=e[69];let Se;return e[70]!==ue||e[71]!==D||e[72]!==ne||e[73]!==Z||e[74]!==te||e[75]!==xe||e[76]!==B||e[77]!==c||e[78]!==Le||e[79]!==Ne||e[80]!==Ae||e[81]!==je||e[82]!==be||e[83]!==Re||e[84]!==Ee||e[85]!==s?(Se=t.jsxRuntimeExports.jsxs(Xe.GraphContainer,{className:Le,style:Ne,id:ne,ref:Ie,"aria-label":ue,backgroundColor:D,theme:s,language:te,minHeight:xe,width:Ae,height:Z,relativeHeight:c,padding:B,children:[je,be,Re,Ee]}),e[70]=ue,e[71]=D,e[72]=ne,e[73]=Z,e[74]=te,e[75]=xe,e[76]=B,e[77]=c,e[78]=Le,e[79]=Ne,e[80]=Ae,e[81]=je,e[82]=be,e[83]=Re,e[84]=Ee,e[85]=s,e[86]=Se):Se=e[86],Se}function dt(u){return`${u}`}function ht(u){return u!==void 0}function xt(u){return u!==void 0}function mt(u){return u.data}function gt(u){return u!==void 0}function pt(u){return u.data}exports.HeatMap=ut;
2
2
  //# sourceMappingURL=HeatMap.cjs.map
package/dist/HeatMap.js CHANGED
@@ -21,7 +21,7 @@ import { ColorLegendWithMouseOver as ae } from "./ColorLegendWithMouseOver.js";
21
21
  import { LinearColorLegend as ne } from "./LinearColorLegend.js";
22
22
  import { ThresholdColorLegendWithMouseOver as ce } from "./ThresholdColorLegendWithMouseOver.js";
23
23
  import { Colors as f } from "./Colors.js";
24
- import { E as ue } from "./EmptyState-Pj-emXt5.js";
24
+ import { E as ue } from "./EmptyState-dScPFkLy.js";
25
25
  import { a as me, G as he } from "./GraphContainer-CF6ws3pd.js";
26
26
  function de(u) {
27
27
  const t = Ft.c(86), {
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const I=require("./index-CHPV5EwG-6v2a2njQ.cjs"),le=require("./Spinner-jTMOLuw_.cjs"),J=require("./index-DlrGwLQA.cjs"),ae=require("./TreeMapGraph.cjs"),ce=require("./DonutChart.cjs"),ue=require("./BarGraph.cjs"),W=require("./Colors.cjs"),he=require("./init-DU0ybBc_.cjs"),K=require("./linear-CgUCbw9F.cjs");function fe(n,e){let C=0;for(let l of n)l!=null&&(l=+l)>=l&&++C;return C}function pe(n){return n}var ge=Array.prototype,me=ge.slice;function ne(n){return()=>n}function xe(n,e,C){let l;for(;;){const t=K.tickIncrement(n,e,C);if(t===l||t===0||!isFinite(t))return[n,e];t>0?(n=Math.floor(n/t)*t,e=Math.ceil(e/t)*t):t<0&&(n=Math.ceil(n*t)/t,e=Math.floor(e*t)/t),l=t}}function de(n){return Math.max(1,Math.ceil(Math.log(fe(n))/Math.LN2)+1)}function Me(){var n=pe,e=J.extent,C=de;function l(t){Array.isArray(t)||(t=Array.from(t));var r,B=t.length,a,L,p=new Array(B);for(r=0;r<B;++r)p[r]=n(t[r],r,t);var b=e(p),o=b[0],i=b[1],s=C(p,o,i);if(!Array.isArray(s)){const d=i,M=+s;if(e===J.extent&&([o,i]=xe(o,i,M)),s=K.ticks(o,i,M),s[0]<=o&&(L=K.tickIncrement(o,i,M)),s[s.length-1]>=i)if(d>=i&&e===J.extent){const c=K.tickIncrement(o,i,M);isFinite(c)&&(c>0?i=(Math.floor(i/c)+1)*c:c<0&&(i=(Math.ceil(i*-c)+1)/-c))}else s.pop()}for(var x=s.length,u=0,h=x;s[u]<=o;)++u;for(;s[h-1]>i;)--h;(u||h<x)&&(s=s.slice(u,h),x=h-u);var m=new Array(x+1),y;for(r=0;r<=x;++r)y=m[r]=[],y.x0=r>0?s[r-1]:o,y.x1=r<x?s[r]:i;if(isFinite(L)){if(L>0)for(r=0;r<B;++r)(a=p[r])!=null&&o<=a&&a<=i&&m[Math.min(x,Math.floor((a-o)/L))].push(t[r]);else if(L<0){for(r=0;r<B;++r)if((a=p[r])!=null&&o<=a&&a<=i){const d=Math.floor((o-a)*L);m[Math.min(x,d+(s[d]<=a))].push(t[r])}}}else for(r=0;r<B;++r)(a=p[r])!=null&&o<=a&&a<=i&&m[he.bisectRight(s,a,0,x)].push(t[r]);return m}return l.value=function(t){return arguments.length?(n=typeof t=="function"?t:ne(t),l):n},l.domain=function(t){return arguments.length?(e=typeof t=="function"?t:ne([t[0],t[1]]),l):e},l.thresholds=function(t){return arguments.length?(C=typeof t=="function"?t:ne(Array.isArray(t)?me.call(t):t),l):C},l}function ye(n){const e=I.compilerRuntimeExports.c(139),{data:C,graphTitle:l,sources:t,graphDescription:r,barPadding:B,showValues:a,showTicks:L,leftMargin:p,rightMargin:b,height:o,width:i,footNote:s,colors:x,padding:u,backgroundColor:h,topMargin:m,bottomMargin:y,showLabels:d,relativeHeight:M,tooltip:c,onSeriesMouseOver:w,refValues:Q,graphID:j,maxValue:U,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,numberOfBins:X,truncateBy:Y,graphType:Z,barGraphLayout:_,donutStrokeWidth:ee,sortData:N,language:q,minHeight:H,theme:oe,maxBarThickness:te,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T,hideAxisLine:se}=n,v=oe===void 0?"light":oe,re=se===void 0?!1:se;let O;e[0]!==C||e[1]!==X?(O=Me().thresholds(X||10).value(Ce)(C).map(ve),e[0]=C,e[1]=X,e[2]=O):O=e[2];const $=O;if($.length===0){const g=`${i}px`,f=`${o}px`;let P;e[3]!==g||e[4]!==f?(P={width:g,height:f,margin:"auto"},e[3]=g,e[4]=f,e[5]=P):P=e[5];let F;e[6]===Symbol.for("react.memo_cache_sentinel")?(F=I.jsxRuntimeExports.jsx("div",{className:"flex m-auto items-center justify-center p-0 leading-none text-base h-40",children:I.jsxRuntimeExports.jsx(le.w,{})}),e[6]=F):F=e[6];let z;return e[7]!==P?(z=I.jsxRuntimeExports.jsx("div",{style:P,children:F}),e[7]=P,e[8]=z):z=e[8],z}if(Z==="circlePacking"){const g=x||W.Colors.graphMainColor;let f;return e[9]!==E||e[10]!==h||e[11]!==y||e[12]!==D||e[13]!==A||e[14]!==$||e[15]!==R||e[16]!==s||e[17]!==r||e[18]!==S||e[19]!==j||e[20]!==l||e[21]!==o||e[22]!==q||e[23]!==p||e[24]!==H||e[25]!==k||e[26]!==w||e[27]!==u||e[28]!==T||e[29]!==M||e[30]!==b||e[31]!==d||e[32]!==a||e[33]!==t||e[34]!==G||e[35]!==g||e[36]!==v||e[37]!==c||e[38]!==m||e[39]!==i?(f=I.jsxRuntimeExports.jsx(J.CirclePackingGraph,{colors:g,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,language:q,minHeight:H,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[9]=E,e[10]=h,e[11]=y,e[12]=D,e[13]=A,e[14]=$,e[15]=R,e[16]=s,e[17]=r,e[18]=S,e[19]=j,e[20]=l,e[21]=o,e[22]=q,e[23]=p,e[24]=H,e[25]=k,e[26]=w,e[27]=u,e[28]=T,e[29]=M,e[30]=b,e[31]=d,e[32]=a,e[33]=t,e[34]=G,e[35]=g,e[36]=v,e[37]=c,e[38]=m,e[39]=i,e[40]=f):f=e[40],f}if(Z==="treeMap"){const g=x||W.Colors.graphMainColor;let f;return e[41]!==E||e[42]!==h||e[43]!==y||e[44]!==D||e[45]!==A||e[46]!==$||e[47]!==R||e[48]!==s||e[49]!==r||e[50]!==S||e[51]!==j||e[52]!==l||e[53]!==o||e[54]!==q||e[55]!==p||e[56]!==H||e[57]!==k||e[58]!==w||e[59]!==u||e[60]!==T||e[61]!==M||e[62]!==b||e[63]!==d||e[64]!==a||e[65]!==t||e[66]!==G||e[67]!==g||e[68]!==v||e[69]!==c||e[70]!==m||e[71]!==i?(f=I.jsxRuntimeExports.jsx(ae.TreeMapGraph,{colors:g,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,language:q,minHeight:H,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[41]=E,e[42]=h,e[43]=y,e[44]=D,e[45]=A,e[46]=$,e[47]=R,e[48]=s,e[49]=r,e[50]=S,e[51]=j,e[52]=l,e[53]=o,e[54]=q,e[55]=p,e[56]=H,e[57]=k,e[58]=w,e[59]=u,e[60]=T,e[61]=M,e[62]=b,e[63]=d,e[64]=a,e[65]=t,e[66]=G,e[67]=g,e[68]=v,e[69]=c,e[70]=m,e[71]=i,e[72]=f):f=e[72],f}if(Z==="donutChart"){const g=x||W.Colors[v].categoricalColors.colors,f=i&&o?i<o?i:o:i||o||void 0,P=$;let F;return e[73]!==E||e[74]!==h||e[75]!==D||e[76]!==A||e[77]!==R||e[78]!==ee||e[79]!==s||e[80]!==r||e[81]!==S||e[82]!==j||e[83]!==l||e[84]!==q||e[85]!==k||e[86]!==w||e[87]!==u||e[88]!==T||e[89]!==N||e[90]!==t||e[91]!==G||e[92]!==g||e[93]!==f||e[94]!==P||e[95]!==v||e[96]!==c?(F=I.jsxRuntimeExports.jsx(ce.DonutChart,{colors:g,graphTitle:l,graphDescription:r,footNote:s,radius:f,sources:t,backgroundColor:h,padding:u,tooltip:c,onSeriesMouseOver:w,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:P,strokeWidth:ee,showColorScale:!0,sortData:N,language:q,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[73]=E,e[74]=h,e[75]=D,e[76]=A,e[77]=R,e[78]=ee,e[79]=s,e[80]=r,e[81]=S,e[82]=j,e[83]=l,e[84]=q,e[85]=k,e[86]=w,e[87]=u,e[88]=T,e[89]=N,e[90]=t,e[91]=G,e[92]=g,e[93]=f,e[94]=P,e[95]=v,e[96]=c,e[97]=F):F=e[97],F}const ie=x||W.Colors.graphMainColor;let V;return e[98]!==E||e[99]!==h||e[100]!==_||e[101]!==B||e[102]!==y||e[103]!==D||e[104]!==A||e[105]!==$||e[106]!==R||e[107]!==s||e[108]!==r||e[109]!==S||e[110]!==j||e[111]!==l||e[112]!==o||e[113]!==re||e[114]!==q||e[115]!==p||e[116]!==te||e[117]!==U||e[118]!==H||e[119]!==k||e[120]!==w||e[121]!==u||e[122]!==T||e[123]!==Q||e[124]!==M||e[125]!==b||e[126]!==d||e[127]!==L||e[128]!==a||e[129]!==N||e[130]!==t||e[131]!==G||e[132]!==ie||e[133]!==v||e[134]!==c||e[135]!==m||e[136]!==Y||e[137]!==i?(V=I.jsxRuntimeExports.jsx(ue.SimpleBarGraph,{colors:ie,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,barPadding:B,refValues:Q,truncateBy:Y,maxValue:U,showTicks:L,sortData:N,language:q,minHeight:H,theme:v,maxBarThickness:te,ariaLabel:E,orientation:_,detailsOnClick:R,styles:G,classNames:D,precision:T,hideAxisLine:re}),e[98]=E,e[99]=h,e[100]=_,e[101]=B,e[102]=y,e[103]=D,e[104]=A,e[105]=$,e[106]=R,e[107]=s,e[108]=r,e[109]=S,e[110]=j,e[111]=l,e[112]=o,e[113]=re,e[114]=q,e[115]=p,e[116]=te,e[117]=U,e[118]=H,e[119]=k,e[120]=w,e[121]=u,e[122]=T,e[123]=Q,e[124]=M,e[125]=b,e[126]=d,e[127]=L,e[128]=a,e[129]=N,e[130]=t,e[131]=G,e[132]=ie,e[133]=v,e[134]=c,e[135]=m,e[136]=Y,e[137]=i,e[138]=V):V=e[138],V}function ve(n){return{label:`${n.x0}-${n.x1}`,size:n.length,data:{options:`${n.x0}-${n.x1}`,frequency:n.length}}}function Ce(n){return n.value}exports.Histogram=ye;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const I=require("./index-CHPV5EwG-6v2a2njQ.cjs"),le=require("./Spinner-jTMOLuw_.cjs"),J=require("./index-DNmkwfX8.cjs"),ae=require("./TreeMapGraph.cjs"),ce=require("./DonutChart.cjs"),ue=require("./BarGraph.cjs"),W=require("./Colors.cjs"),he=require("./init-DU0ybBc_.cjs"),K=require("./linear-CgUCbw9F.cjs");function fe(n,e){let C=0;for(let l of n)l!=null&&(l=+l)>=l&&++C;return C}function pe(n){return n}var ge=Array.prototype,me=ge.slice;function ne(n){return()=>n}function xe(n,e,C){let l;for(;;){const t=K.tickIncrement(n,e,C);if(t===l||t===0||!isFinite(t))return[n,e];t>0?(n=Math.floor(n/t)*t,e=Math.ceil(e/t)*t):t<0&&(n=Math.ceil(n*t)/t,e=Math.floor(e*t)/t),l=t}}function de(n){return Math.max(1,Math.ceil(Math.log(fe(n))/Math.LN2)+1)}function Me(){var n=pe,e=J.extent,C=de;function l(t){Array.isArray(t)||(t=Array.from(t));var r,B=t.length,a,L,p=new Array(B);for(r=0;r<B;++r)p[r]=n(t[r],r,t);var b=e(p),o=b[0],i=b[1],s=C(p,o,i);if(!Array.isArray(s)){const d=i,M=+s;if(e===J.extent&&([o,i]=xe(o,i,M)),s=K.ticks(o,i,M),s[0]<=o&&(L=K.tickIncrement(o,i,M)),s[s.length-1]>=i)if(d>=i&&e===J.extent){const c=K.tickIncrement(o,i,M);isFinite(c)&&(c>0?i=(Math.floor(i/c)+1)*c:c<0&&(i=(Math.ceil(i*-c)+1)/-c))}else s.pop()}for(var x=s.length,u=0,h=x;s[u]<=o;)++u;for(;s[h-1]>i;)--h;(u||h<x)&&(s=s.slice(u,h),x=h-u);var m=new Array(x+1),y;for(r=0;r<=x;++r)y=m[r]=[],y.x0=r>0?s[r-1]:o,y.x1=r<x?s[r]:i;if(isFinite(L)){if(L>0)for(r=0;r<B;++r)(a=p[r])!=null&&o<=a&&a<=i&&m[Math.min(x,Math.floor((a-o)/L))].push(t[r]);else if(L<0){for(r=0;r<B;++r)if((a=p[r])!=null&&o<=a&&a<=i){const d=Math.floor((o-a)*L);m[Math.min(x,d+(s[d]<=a))].push(t[r])}}}else for(r=0;r<B;++r)(a=p[r])!=null&&o<=a&&a<=i&&m[he.bisectRight(s,a,0,x)].push(t[r]);return m}return l.value=function(t){return arguments.length?(n=typeof t=="function"?t:ne(t),l):n},l.domain=function(t){return arguments.length?(e=typeof t=="function"?t:ne([t[0],t[1]]),l):e},l.thresholds=function(t){return arguments.length?(C=typeof t=="function"?t:ne(Array.isArray(t)?me.call(t):t),l):C},l}function ye(n){const e=I.compilerRuntimeExports.c(139),{data:C,graphTitle:l,sources:t,graphDescription:r,barPadding:B,showValues:a,showTicks:L,leftMargin:p,rightMargin:b,height:o,width:i,footNote:s,colors:x,padding:u,backgroundColor:h,topMargin:m,bottomMargin:y,showLabels:d,relativeHeight:M,tooltip:c,onSeriesMouseOver:w,refValues:Q,graphID:j,maxValue:U,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,numberOfBins:X,truncateBy:Y,graphType:Z,barGraphLayout:_,donutStrokeWidth:ee,sortData:N,language:q,minHeight:H,theme:oe,maxBarThickness:te,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T,hideAxisLine:se}=n,v=oe===void 0?"light":oe,re=se===void 0?!1:se;let O;e[0]!==C||e[1]!==X?(O=Me().thresholds(X||10).value(Ce)(C).map(ve),e[0]=C,e[1]=X,e[2]=O):O=e[2];const $=O;if($.length===0){const g=`${i}px`,f=`${o}px`;let P;e[3]!==g||e[4]!==f?(P={width:g,height:f,margin:"auto"},e[3]=g,e[4]=f,e[5]=P):P=e[5];let F;e[6]===Symbol.for("react.memo_cache_sentinel")?(F=I.jsxRuntimeExports.jsx("div",{className:"flex m-auto items-center justify-center p-0 leading-none text-base h-40",children:I.jsxRuntimeExports.jsx(le.w,{})}),e[6]=F):F=e[6];let z;return e[7]!==P?(z=I.jsxRuntimeExports.jsx("div",{style:P,children:F}),e[7]=P,e[8]=z):z=e[8],z}if(Z==="circlePacking"){const g=x||W.Colors.graphMainColor;let f;return e[9]!==E||e[10]!==h||e[11]!==y||e[12]!==D||e[13]!==A||e[14]!==$||e[15]!==R||e[16]!==s||e[17]!==r||e[18]!==S||e[19]!==j||e[20]!==l||e[21]!==o||e[22]!==q||e[23]!==p||e[24]!==H||e[25]!==k||e[26]!==w||e[27]!==u||e[28]!==T||e[29]!==M||e[30]!==b||e[31]!==d||e[32]!==a||e[33]!==t||e[34]!==G||e[35]!==g||e[36]!==v||e[37]!==c||e[38]!==m||e[39]!==i?(f=I.jsxRuntimeExports.jsx(J.CirclePackingGraph,{colors:g,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,language:q,minHeight:H,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[9]=E,e[10]=h,e[11]=y,e[12]=D,e[13]=A,e[14]=$,e[15]=R,e[16]=s,e[17]=r,e[18]=S,e[19]=j,e[20]=l,e[21]=o,e[22]=q,e[23]=p,e[24]=H,e[25]=k,e[26]=w,e[27]=u,e[28]=T,e[29]=M,e[30]=b,e[31]=d,e[32]=a,e[33]=t,e[34]=G,e[35]=g,e[36]=v,e[37]=c,e[38]=m,e[39]=i,e[40]=f):f=e[40],f}if(Z==="treeMap"){const g=x||W.Colors.graphMainColor;let f;return e[41]!==E||e[42]!==h||e[43]!==y||e[44]!==D||e[45]!==A||e[46]!==$||e[47]!==R||e[48]!==s||e[49]!==r||e[50]!==S||e[51]!==j||e[52]!==l||e[53]!==o||e[54]!==q||e[55]!==p||e[56]!==H||e[57]!==k||e[58]!==w||e[59]!==u||e[60]!==T||e[61]!==M||e[62]!==b||e[63]!==d||e[64]!==a||e[65]!==t||e[66]!==G||e[67]!==g||e[68]!==v||e[69]!==c||e[70]!==m||e[71]!==i?(f=I.jsxRuntimeExports.jsx(ae.TreeMapGraph,{colors:g,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,language:q,minHeight:H,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[41]=E,e[42]=h,e[43]=y,e[44]=D,e[45]=A,e[46]=$,e[47]=R,e[48]=s,e[49]=r,e[50]=S,e[51]=j,e[52]=l,e[53]=o,e[54]=q,e[55]=p,e[56]=H,e[57]=k,e[58]=w,e[59]=u,e[60]=T,e[61]=M,e[62]=b,e[63]=d,e[64]=a,e[65]=t,e[66]=G,e[67]=g,e[68]=v,e[69]=c,e[70]=m,e[71]=i,e[72]=f):f=e[72],f}if(Z==="donutChart"){const g=x||W.Colors[v].categoricalColors.colors,f=i&&o?i<o?i:o:i||o||void 0,P=$;let F;return e[73]!==E||e[74]!==h||e[75]!==D||e[76]!==A||e[77]!==R||e[78]!==ee||e[79]!==s||e[80]!==r||e[81]!==S||e[82]!==j||e[83]!==l||e[84]!==q||e[85]!==k||e[86]!==w||e[87]!==u||e[88]!==T||e[89]!==N||e[90]!==t||e[91]!==G||e[92]!==g||e[93]!==f||e[94]!==P||e[95]!==v||e[96]!==c?(F=I.jsxRuntimeExports.jsx(ce.DonutChart,{colors:g,graphTitle:l,graphDescription:r,footNote:s,radius:f,sources:t,backgroundColor:h,padding:u,tooltip:c,onSeriesMouseOver:w,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:P,strokeWidth:ee,showColorScale:!0,sortData:N,language:q,theme:v,ariaLabel:E,detailsOnClick:R,styles:G,classNames:D,precision:T}),e[73]=E,e[74]=h,e[75]=D,e[76]=A,e[77]=R,e[78]=ee,e[79]=s,e[80]=r,e[81]=S,e[82]=j,e[83]=l,e[84]=q,e[85]=k,e[86]=w,e[87]=u,e[88]=T,e[89]=N,e[90]=t,e[91]=G,e[92]=g,e[93]=f,e[94]=P,e[95]=v,e[96]=c,e[97]=F):F=e[97],F}const ie=x||W.Colors.graphMainColor;let V;return e[98]!==E||e[99]!==h||e[100]!==_||e[101]!==B||e[102]!==y||e[103]!==D||e[104]!==A||e[105]!==$||e[106]!==R||e[107]!==s||e[108]!==r||e[109]!==S||e[110]!==j||e[111]!==l||e[112]!==o||e[113]!==re||e[114]!==q||e[115]!==p||e[116]!==te||e[117]!==U||e[118]!==H||e[119]!==k||e[120]!==w||e[121]!==u||e[122]!==T||e[123]!==Q||e[124]!==M||e[125]!==b||e[126]!==d||e[127]!==L||e[128]!==a||e[129]!==N||e[130]!==t||e[131]!==G||e[132]!==ie||e[133]!==v||e[134]!==c||e[135]!==m||e[136]!==Y||e[137]!==i?(V=I.jsxRuntimeExports.jsx(ue.SimpleBarGraph,{colors:ie,graphTitle:l,graphDescription:r,footNote:s,width:i,height:o,sources:t,leftMargin:p,rightMargin:b,backgroundColor:h,padding:u,topMargin:m,bottomMargin:y,relativeHeight:M,showLabels:d,tooltip:c,onSeriesMouseOver:w,showColorScale:!1,showValues:a,graphID:j,onSeriesMouseClick:k,graphDownload:S,dataDownload:A,data:$,barPadding:B,refValues:Q,truncateBy:Y,maxValue:U,showTicks:L,sortData:N,language:q,minHeight:H,theme:v,maxBarThickness:te,ariaLabel:E,orientation:_,detailsOnClick:R,styles:G,classNames:D,precision:T,hideAxisLine:re}),e[98]=E,e[99]=h,e[100]=_,e[101]=B,e[102]=y,e[103]=D,e[104]=A,e[105]=$,e[106]=R,e[107]=s,e[108]=r,e[109]=S,e[110]=j,e[111]=l,e[112]=o,e[113]=re,e[114]=q,e[115]=p,e[116]=te,e[117]=U,e[118]=H,e[119]=k,e[120]=w,e[121]=u,e[122]=T,e[123]=Q,e[124]=M,e[125]=b,e[126]=d,e[127]=L,e[128]=a,e[129]=N,e[130]=t,e[131]=G,e[132]=ie,e[133]=v,e[134]=c,e[135]=m,e[136]=Y,e[137]=i,e[138]=V):V=e[138],V}function ve(n){return{label:`${n.x0}-${n.x1}`,size:n.length,data:{options:`${n.x0}-${n.x1}`,frequency:n.length}}}function Ce(n){return n.value}exports.Histogram=ye;
2
2
  //# sourceMappingURL=Histogram.cjs.map
package/dist/Histogram.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { c as le, j as R } from "./index-CHPV5EwG-DecW7_qr.js";
2
2
  import { w as se } from "./Spinner--r2RrJV8.js";
3
- import { e as re, C as ce } from "./index-BE-lvE4c.js";
3
+ import { e as re, C as ce } from "./index-CH8RndC2.js";
4
4
  import { TreeMapGraph as fe } from "./TreeMapGraph.js";
5
5
  import { DonutChart as he } from "./DonutChart.js";
6
6
  import { SimpleBarGraph as ue } from "./BarGraph.js";
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-CHPV5EwG-6v2a2njQ.cjs"),d=require("react"),qt=require("./parse-xYI9yrvL.cjs"),It=require("./getSliderMarks-CIuSoedo.cjs"),Ut=require("./Spinner-jTMOLuw_.cjs"),Pt=require("./index-DQA8q5sC.cjs"),U=require("./index-DLFt97gy.cjs"),St=require("./Typography-DrJ7IOdw.cjs"),Gt=require("./index-C5K--w8d.cjs"),zt=require("./Source-B3i0Bx2R.cjs"),Ht=require("./index-Dzc_aaI9-C3DbPpy3.cjs"),Xt=require("./Tooltip-BLa2EfMs.cjs"),Ot=require("./index-sbKVyHS2.cjs"),Yt=require("./DetailsModal-DHttOA80.cjs"),Jt=require("./pow-BnyPO-NX.cjs"),Kt=require("./ordinal-CrsysVE-.cjs"),Zt=require("./threshold-DNsSUf8Q.cjs"),Nt=require("./select-Bnfk0lJx.cjs"),le=require("./proxy-C4-uo6nS.cjs"),dt=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Qt=require("./numberFormattingFunction-02t-wJta.cjs"),eo=require("./use-in-view-C3o_ntMv.cjs"),to=require("./index-CoobIWNj.cjs"),oo=require("./GraphFooter.cjs"),ro=require("./GraphHeader.cjs"),we=require("./Colors.cjs"),ao=require("./fetchAndParseData-QTF6tjij.cjs"),_t=require("./GraphContainer-B1EDxJ0S.cjs"),io=require("./getUniqValue-NX8DgwND.cjs"),no=require("./getJenks-BzJvhy_H.cjs");function so(a){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const t in a)if(t!=="default"){const g=Object.getOwnPropertyDescriptor(a,t);Object.defineProperty(e,t,g.get?g:{enumerable:!0,get:()=>a[t]})}}return e.default=a,Object.freeze(e)}const lo=so(d);var co="Separator",Lt="horizontal",uo=["horizontal","vertical"],Vt=lo.forwardRef((a,e)=>{const{decorative:t,orientation:g=Lt,...f}=a,n=mo(g)?g:Lt,y=t?{role:"none"}:{"aria-orientation":n==="vertical"?n:void 0,role:"separator"};return r.ae.jsx(Ht.w.div,{"data-orientation":n,...y,...f,ref:e})});Vt.displayName=co;function mo(a){return uo.includes(a)}var $t=Vt;const Bt=d.forwardRef((a,e)=>{const t=r._.c(14);let g,f,n,y;t[0]!==a?({className:g,variant:n,orientation:y,...f}=a,t[0]=a,t[1]=g,t[2]=f,t[3]=n,t[4]=y):(g=t[1],f=t[2],n=t[3],y=t[4]);const v=n===void 0?"dark":n,s=y===void 0?"horizontal":y,x=s==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",k=v==="dark"?"bg-primary-gray-600 dark:bg-primary-gray-200":"bg-primary-gray-400 dark:bg-primary-gray-550";let E;t[5]!==g||t[6]!==x||t[7]!==k?(E=r.mo(x,k,g),t[5]=g,t[6]=x,t[7]=k,t[8]=E):E=t[8];let S;return t[9]!==s||t[10]!==f||t[11]!==e||t[12]!==E?(S=r.ae.jsx($t,{...f,ref:e,orientation:s,className:E}),t[9]=s,t[10]=f,t[11]=e,t[12]=E,t[13]=S):S=t[13],S});Bt.displayName=$t.displayName;function po(a){const{data:e,colors:t,mapData:g,mapColorLegendTitle:f,colorDomain:n,radius:y,height:v,width:s,scale:x,centerPoint:k,tooltip:E,showLabels:S,mapBorderWidth:ke,mapBorderColor:Re,mapNoDataColor:Ce,onSeriesMouseOver:G,showColorScale:De,zoomScaleExtend:We,zoomTranslateExtend:Ue,highlightedDataPoints:Se,onSeriesMouseClick:I,resetSelectionOnDoubleClick:Ne,detailsOnClick:H,styles:R,classNames:X,mapProjection:ee,zoomInteraction:Y,animate:j,dimmedOpacity:P,customLayers:ce,maxRadiusValue:de,categorical:te,dotColor:J,collapseColorScaleByDefault:Oe,highlightedIds:oe,mapProperty:ue,dotLegendTitle:me,dotBorderColor:Me,labelColor:qe,projectionRotate:K,rewindCoordinatesInMapData:pe}=a,u=d.useMemo(()=>pe?U.index_default(g,{reverse:!0}):g,[g,pe]),[l,z]=d.useState(void 0),[Ge,Ie]=d.useState(Oe===void 0?!(s<680):!Oe),xe=d.useRef(null),[_,N]=d.useState(void 0),[re,O]=d.useState(void 0),[Pe,C]=d.useState(void 0),[ze,M]=d.useState(void 0),L=d.useRef(null),Z=eo.useInView(L,{once:j.once,amount:j.amount}),ae=d.useRef(null),V=e.filter(o=>o.radius===void 0||o.radius===null).length!==e.length?Jt.sqrt().domain([0,de]).range([.25,y]).nice():void 0,q=te?Kt.ordinal().domain(n).range(t):Zt.threshold().domain(n).range(t);d.useEffect(()=>{const o=Nt.select(ae.current),i=Nt.select(L.current),b=m=>{if(Y==="noZoom")return!1;if(Y==="button")return!m.type.includes("wheel");const ge=m.type==="wheel",fe=m.type.startsWith("touch"),Be=m.type==="mousedown"||m.type==="mousemove";return fe?!0:ge?Y==="scroll"?!0:m.ctrlKey:Be&&!m.button&&!m.ctrlKey},D=U.zoom().scaleExtent(We).translateExtent(Ue||[[-20,-20],[s+20,v+20]]).filter(b).on("zoom",({transform:m})=>{o.attr("transform",m)});i.call(D),xe.current=D},[v,s,Y]);const $=U.index_default$1(u),w=Gt.index_default(u),_e=($[2]-$[0])*1.15,Le=($[3]-$[1])*1.15,Ve=s*190/960*360/_e,$e=v*190/678*180/Le,B=x*Math.min(Ve,$e),Q=ee==="mercator"?U.geoMercator().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="equalEarth"?U.geoEqualEarth().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="naturalEarth"?U.geoNaturalEarth1().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="orthographic"?U.geoOrthographic().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):U.geoAlbersUsa().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B),he=U.geoPath().projection(Q),ie=o=>{if(!L.current||!xe.current)return;Nt.select(L.current).call(xe.current.scaleBy,o==="in"?1.2:1/1.2)};return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:"relative",children:[r.jsxRuntimeExports.jsx(le.motion.svg,{width:`${s}px`,height:`${v}px`,viewBox:`0 0 ${s} ${v}`,ref:L,direction:"ltr",children:r.jsxRuntimeExports.jsxs("g",{ref:ae,children:[ce.filter(o=>o.position==="before").map(o=>o.layer),u.features.map((o,i)=>{if(!o.properties?.[ue])return null;const b=he(o);return b?r.jsxRuntimeExports.jsx(le.motion.g,{opacity:l?P:oe.length!==0?oe.indexOf(o.properties[ue])!==-1?1:P:1,children:r.jsxRuntimeExports.jsx("path",{d:b,style:{stroke:Re,strokeWidth:ke,fill:Ce}})},i):null}),r.jsxRuntimeExports.jsxs(to.AnimatePresence,{children:[e.filter(o=>o.id).map(o=>{const i=u.features.findIndex(m=>o.id===m.properties[ue]);if(i===-1)return null;const b=he(u.features[i]);if(!b)return null;const D=dt.checkIfNullOrUndefined(o.x)?Ce:q(o.x);return r.jsxRuntimeExports.jsx(le.motion.g,{className:"undp-map-shapes",variants:{initial:{opacity:0},whileInView:{opacity:l?l===D?1:P:oe.length!==0?oe.indexOf(o.id)!==-1?1:P:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},onMouseEnter:m=>{O(o),M(m.clientY),C(m.clientX),G?.(o)},onMouseMove:m=>{O(o),M(m.clientY),C(m.clientX)},onMouseLeave:()=>{O(void 0),C(void 0),M(void 0),G?.(void 0)},onClick:()=>{(I||H)&&(Pt.isEqual(_,o)&&Ne?(N(void 0),I?.(void 0)):(N(o),I?.(o)))},children:r.jsxRuntimeExports.jsx(le.motion.path,{d:b,variants:{initial:{fill:D,opacity:0},whileInView:{fill:D,opacity:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},style:{stroke:Re,strokeWidth:ke}},`${o.id}`)},o.id)}),e.filter(o=>!dt.checkIfNullOrUndefined(o.lat)&&!dt.checkIfNullOrUndefined(o.long)).map(o=>{const i=Q([o.long,o.lat])[0]>.8*s?-1:1;return r.jsxRuntimeExports.jsxs(le.motion.g,{className:"undp-map-dots",variants:{initial:{opacity:0},whileInView:{opacity:Se.length!==0?Se.indexOf(o.label||"")!==-1?1:P:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},onMouseEnter:b=>{O(o),M(b.clientY),C(b.clientX),G?.(o)},onMouseMove:b=>{O(o),M(b.clientY),C(b.clientX)},onMouseLeave:()=>{O(void 0),C(void 0),M(void 0),G?.(void 0)},onClick:()=>{(I||H)&&(Pt.isEqual(_,o)&&Ne?(N(void 0),I?.(void 0)):(N(o),I?.(o)))},transform:`translate(${Q([o.long,o.lat])[0]},${Q([o.long,o.lat])[1]})`,children:[r.jsxRuntimeExports.jsx(le.motion.circle,{cx:0,cy:0,variants:{initial:{r:0,fill:J,stroke:Me||J},whileInView:{r:V?V(o.radius||0):y,fill:J,stroke:Me||J,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{r:0,transition:{duration:j.duration}},style:{fillOpacity:.8}}),S&&o.label?r.jsxRuntimeExports.jsx(le.motion.text,{variants:{initial:{opacity:0,x:i*(V?V(o.radius||0):y)},whileInView:{opacity:1,x:i*(V?V(o.radius||0):y),transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},y:0,className:r.mo("text-sm",X?.graphObjectValues),style:{textAnchor:i===-1?"end":"start",fill:qe||"#000",...R?.graphObjectValues||{}},dx:i*4,dy:5,children:o.label}):null]},o.label||`${o.lat}-${o.long}`)})]}),ce.filter(o=>o.position==="after").map(o=>o.layer)]})}),De===!1?null:r.jsxRuntimeExports.jsx("div",{className:r.mo("absolute left-4 bottom-4 map-color-legend",X?.colorLegend),children:Ge?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx("div",{className:"color-legend-close-button bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)] border border-[var(--gray-400)] rounded-full w-6 h-6 p-[3px] cursor-pointer z-10 absolute right-[-0.75rem] top-[-0.75rem]",onClick:()=>{Ie(!1)},children:r.jsxRuntimeExports.jsx(Ot.X,{})}),r.jsxRuntimeExports.jsxs("div",{className:"color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]",style:{width:te?void 0:"340px"},children:[me&&me!==""?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2",children:[r.jsxRuntimeExports.jsx("div",{className:"w-3 h-3 rounded-full",style:{backgroundColor:J}}),r.jsxRuntimeExports.jsx(St._,{size:"xs",marginBottom:"none",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:me})]}),r.jsxRuntimeExports.jsx(zt.n,{size:"xl"}),r.jsxRuntimeExports.jsx(Bt,{}),r.jsxRuntimeExports.jsx(zt.n,{size:"xl"})]}):null,f&&f!==""?r.jsxRuntimeExports.jsx(St._,{size:"xs",marginBottom:"xs",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:f}):null,te?r.jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-3",children:n.map((o,i)=>r.jsxRuntimeExports.jsxs("div",{className:"flex gap-2 items-center",onMouseOver:()=>{z(t[i%t.length])},onMouseLeave:()=>{z(void 0)},children:[r.jsxRuntimeExports.jsx("div",{className:"w-2 h-2 rounded-full",style:{backgroundColor:t[i%t.length]}}),r.jsxRuntimeExports.jsx(St._,{size:"sm",marginBottom:"none",leading:"none",children:o})]},i))}):r.jsxRuntimeExports.jsx("svg",{width:"100%",viewBox:"0 0 320 30",direction:"ltr",children:r.jsxRuntimeExports.jsxs("g",{children:[n.map((o,i)=>r.jsxRuntimeExports.jsxs("g",{onMouseOver:()=>{z(t[i])},onMouseLeave:()=>{z(void 0)},className:"cursor-pointer",children:[r.jsxRuntimeExports.jsx("rect",{x:i*320/t.length+1,y:1,width:320/t.length-2,height:8,className:l===t[i]?"stroke-primary-gray-700 dark:stroke-primary-gray-300":"",style:{fill:t[i],...l===t[i]?{}:{stroke:t[i]}}}),r.jsxRuntimeExports.jsx("text",{x:(i+1)*320/t.length,y:25,className:"fill-primary-gray-700 dark:fill-primary-gray-300 text-xs",style:{textAnchor:"middle"},children:Qt.numberFormattingFunction(o,"NA")})]},i)),r.jsxRuntimeExports.jsx("g",{children:r.jsxRuntimeExports.jsx("rect",{onMouseOver:()=>{z(t[n.length])},onMouseLeave:()=>{z(void 0)},x:n.length*320/t.length+1,y:1,width:320/t.length-2,height:8,className:`cursor-pointer ${l===t[n.length]?"stroke-1 stroke-primary-gray-700 dark:stroke-primary-gray-300":""}`,style:{fill:t[n.length],...l===t[n.length]?{}:{stroke:t[n.length]}}})})]})})]})]}):r.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start map-legend-button",onClick:()=>{Ie(!0)},children:r.jsxRuntimeExports.jsx("div",{className:"show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500",children:"Show Legend"})})}),Y==="button"&&r.jsxRuntimeExports.jsxs("div",{className:"absolute left-4 top-4 flex flex-col zoom-buttons",children:[r.jsxRuntimeExports.jsx("button",{onClick:()=>ie("in"),className:"leading-0 px-2 py-3.5 text-primary-gray-700 border border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100",children:"+"}),r.jsxRuntimeExports.jsx("button",{onClick:()=>ie("out"),className:"leading-0 px-2 py-3.5 text-primary-gray-700 border border-t-0 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100",children:"–"})]})]}),H&&_!==void 0?r.jsxRuntimeExports.jsx(Yt.DetailsModal,{body:H,data:_,setData:N,className:X?.modal}):null,re&&E&&Pe&&ze?r.jsxRuntimeExports.jsx(Xt.Tooltip,{data:re,body:E,xPos:Pe,yPos:ze,backgroundStyle:R?.tooltip,className:X?.tooltip}):null]})}function xo(a){const e=r.compilerRuntimeExports.c(135),{data:t,mapData:g,graphTitle:f,colors:n,sources:y,graphDescription:v,height:s,width:x,footNote:k,mapColorLegendTitle:E,colorDomain:S,choroplethScaleType:ke,radius:Re,scale:Ce,centerPoint:G,padding:De,mapBorderWidth:We,mapNoDataColor:Ue,backgroundColor:Se,showLabels:I,mapBorderColor:Ne,tooltip:H,relativeHeight:R,onSeriesMouseOver:X,isWorldMap:ee,showColorScale:Y,zoomScaleExtend:j,zoomTranslateExtend:P,graphID:ce,highlightedDataPoints:de,onSeriesMouseClick:te,graphDownload:J,dataDownload:Oe,showAntarctica:oe,language:ue,minHeight:me,theme:Me,ariaLabel:qe,resetSelectionOnDoubleClick:K,detailsOnClick:pe,styles:u,classNames:l,mapProjection:z,zoomInteraction:Ge,animate:Ie,dimmedOpacity:xe,customLayers:_,maxRadiusValue:N,timeline:re,collapseColorScaleByDefault:O,dotColor:Pe,highlightedIds:C,mapProperty:ze,dotLegendTitle:M,dotBorderColor:L,labelColor:Z,projectionRotate:ae,rewindCoordinatesInMapData:V}=a,q=g===void 0?"https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-v2.json":g,$=k===void 0?"The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries.":k,w=ke===void 0?"threshold":ke,_e=Re===void 0?5:Re,Le=Ce===void 0?.95:Ce,Ve=We===void 0?.5:We,$e=Ue===void 0?we.Colors.light.graphNoData:Ue,B=Se===void 0?!1:Se,Q=I===void 0?!1:I,he=Ne===void 0?we.Colors.light.grays["gray-500"]:Ne,ie=ee===void 0?!0:ee,o=Y===void 0?!0:Y;let i;e[0]!==j?(i=j===void 0?[.8,6]:j,e[0]=j,e[1]=i):i=e[1];const b=i;let D;e[2]!==de?(D=de===void 0?[]:de,e[2]=de,e[3]=D):D=e[3];const m=D,ge=J===void 0?!1:J,fe=Oe===void 0?!1:Oe,Be=oe===void 0?!1:oe,ut=ue===void 0?"en":ue,F=me===void 0?0:me,ne=Me===void 0?"light":Me,mt=K===void 0?!0:K,pt=z===void 0?"naturalEarth":z,xt=Ge===void 0?"button":Ge,He=Ie===void 0?!1:Ie,ht=xe===void 0?.3:xe;let Xe;e[4]!==_?(Xe=_===void 0?[]:_,e[4]=_,e[5]=Xe):Xe=e[5];const gt=Xe;let Ye;e[6]!==re?(Ye=re===void 0?{enabled:!1,autoplay:!1,showOnlyActiveDate:!0}:re,e[6]=re,e[7]=Ye):Ye=e[7];const c=Ye,ft=Pe===void 0?we.Colors.primaryColors["blue-600"]:Pe;let Je;e[8]!==C?(Je=C===void 0?[]:C,e[8]=C,e[9]=Je):Je=e[9];const yt=Je,vt=ze===void 0?"ISO3":ze,jt=Z===void 0?we.Colors.primaryColors["blue-600"]:Z;let Ke;e[10]!==ae?(Ke=ae===void 0?[0,0]:ae,e[10]=ae,e[11]=Ke):Ke=e[11];const bt=Ke,Et=V===void 0?!0:V,[se,Ft]=d.useState(0),[Fe,Tt]=d.useState(0),[T,At]=d.useState(c.autoplay);let Te;if(e[12]!==t||e[13]!==c.dateFormat){let h;e[15]!==c.dateFormat?(h=W=>qt.parse(`${W.date}`,c.dateFormat||"yyyy",new Date).getTime(),e[15]=c.dateFormat,e[16]=h):h=e[16],Te=[...new Set(t.filter(Ro).map(h))],Te.sort(ko),e[12]=t,e[13]=c.dateFormat,e[14]=Te}else Te=e[14];const p=Te,[A,wt]=d.useState(c.autoplay?0:p.length-1),[ye,Wt]=d.useState(void 0),kt=d.useRef(null),Mt=d.useRef(null);let Ze;e[17]!==w||e[18]!==S||e[19]!==n?.length||e[20]!==t?(Ze=S||(w==="categorical"?io.getUniqValue(t,"x"):no.getJenks(t.map(wo),n?.length||4)),e[17]=w,e[18]=S,e[19]=n?.length,e[20]=t,e[21]=Ze):Ze=e[21];const Ae=Ze;let Qe,et;e[22]===Symbol.for("react.memo_cache_sentinel")?(Qe=()=>{const h=new ResizeObserver(W=>{Ft(W[0].target.clientWidth||620),Tt(W[0].target.clientHeight||480)});return kt.current&&h.observe(kt.current),()=>h.disconnect()},et=[],e[22]=Qe,e[23]=et):(Qe=e[22],et=e[23]),d.useEffect(Qe,et);let tt;e[24]===Symbol.for("react.memo_cache_sentinel")?(tt=h=>{Wt(h)},e[24]=tt):tt=e[24];const ot=d.useEffectEvent(tt);let rt;e[25]!==q||e[26]!==ot?(rt=()=>{typeof q=="string"?ao.fetchAndParseJSON(q).then(W=>{ot(W)}):ot(q)},e[25]=q,e[26]=ot,e[27]=rt):rt=e[27];let at;e[28]!==q?(at=[q],e[28]=q,e[29]=at):at=e[29],d.useEffect(rt,at);let it,nt;e[30]!==T||e[31]!==c.speed||e[32]!==p?(it=()=>{const h=setInterval(()=>{wt(W=>W<p.length-1?W+1:0)},(c.speed||2)*1e3);return T||clearInterval(h),()=>clearInterval(h)},nt=[p,T,c.speed],e[30]=T,e[31]=c.speed,e[32]=p,e[33]=it,e[34]=nt):(it=e[33],nt=e[34]),d.useEffect(it,nt);const Rt=c.dateFormat||"yyyy";let st;e[35]!==A||e[36]!==Rt||e[37]!==c.showOnlyActiveDate||e[38]!==p?(st=It.getSliderMarks(p,A,c.showOnlyActiveDate,Rt),e[35]=A,e[36]=Rt,e[37]=c.showOnlyActiveDate,e[38]=p,e[39]=st):st=e[39];const lt=st,Ct=l?.graphContainer,Dt=u?.graphContainer;let ve;e[40]!==l?.description||e[41]!==l?.title||e[42]!==t||e[43]!==fe||e[44]!==v||e[45]!==ge||e[46]!==f||e[47]!==u?.description||e[48]!==u?.title||e[49]!==x?(ve=f||v||ge||fe?r.jsxRuntimeExports.jsx(ro.GraphHeader,{styles:{title:u?.title,description:u?.description},classNames:{title:l?.title,description:l?.description},graphTitle:f,graphDescription:v,width:x,graphDownload:ge?Mt:void 0,dataDownload:fe?t.map(Eo).filter(bo).length>0?t.map(jo).filter(vo):t.filter(yo):null}):null,e[40]=l?.description,e[41]=l?.title,e[42]=t,e[43]=fe,e[44]=v,e[45]=ge,e[46]=f,e[47]=u?.description,e[48]=u?.title,e[49]=x,e[50]=ve):ve=e[50];let je;e[51]!==A||e[52]!==lt||e[53]!==T||e[54]!==c.enabled||e[55]!==p?(je=c.enabled&&p.length>0&&lt?r.jsxRuntimeExports.jsxs("div",{className:"flex gap-6 items-center",dir:"ltr",children:[r.jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>{At(!T)},className:"p-0 border-0 cursor-pointer bg-transparent","aria-label":T?"Click to pause animation":"Click to play animation",children:T?r.jsxRuntimeExports.jsx(Ot.Pause,{}):r.jsxRuntimeExports.jsx(Ot.Play,{})}),r.jsxRuntimeExports.jsx(It.Nr,{min:p[0],max:p[p.length-1],marks:lt,step:null,defaultValue:p[p.length-1],value:p[A],onChangeComplete:h=>{wt(p.indexOf(h))},onChange:h=>{wt(p.indexOf(h))},"aria-label":"Time slider. Use arrow keys to adjust selected time period."})]}):null,e[51]=A,e[52]=lt,e[53]=T,e[54]=c.enabled,e[55]=p,e[56]=je):je=e[56];let be;e[57]!==He||e[58]!==G||e[59]!==w||e[60]!==l||e[61]!==O||e[62]!==n||e[63]!==gt||e[64]!==t||e[65]!==pe||e[66]!==ht||e[67]!==Ae||e[68]!==L||e[69]!==ft||e[70]!==M||e[71]!==s||e[72]!==m||e[73]!==yt||e[74]!==A||e[75]!==ie||e[76]!==jt||e[77]!==he||e[78]!==Ve||e[79]!==E||e[80]!==$e||e[81]!==pt||e[82]!==vt||e[83]!==ye||e[84]!==N||e[85]!==F||e[86]!==te||e[87]!==X||e[88]!==bt||e[89]!==_e||e[90]!==R||e[91]!==mt||e[92]!==Et||e[93]!==Le||e[94]!==Be||e[95]!==o||e[96]!==Q||e[97]!==u||e[98]!==Fe||e[99]!==se||e[100]!==ne||e[101]!==c.dateFormat||e[102]!==c.enabled||e[103]!==H||e[104]!==p||e[105]!==x||e[106]!==xt||e[107]!==b||e[108]!==P?(be=r.jsxRuntimeExports.jsx(_t.GraphArea,{ref:kt,children:se&&Fe&&ye?r.jsxRuntimeExports.jsx(po,{dotColor:ft,data:t.filter(h=>c.enabled?h.date===qt.format(new Date(p[A]),c.dateFormat||"yyyy"):h),mapData:Be?ye:{...ye,features:ye.features.filter(fo)},colorDomain:Ae,width:se,height:Fe,scale:Le,centerPoint:G,colors:n||(w==="categorical"?we.Colors[ne].sequentialColors[`neutralColorsx0${Ae.length}`]:we.Colors[ne].sequentialColors[`neutralColorsx0${Ae.length+1}`]),mapColorLegendTitle:E,radius:_e,categorical:w==="categorical",mapBorderWidth:Ve,mapNoDataColor:$e,mapBorderColor:he,tooltip:H,onSeriesMouseOver:X,showLabels:Q,isWorldMap:ie,showColorScale:o,zoomScaleExtend:b,zoomTranslateExtend:P,onSeriesMouseClick:te,highlightedDataPoints:m,resetSelectionOnDoubleClick:mt,styles:u,classNames:l,zoomInteraction:xt,detailsOnClick:pe,mapProjection:pt||(ie?"naturalEarth":"mercator"),animate:He===!0?{duration:.5,once:!0,amount:.5}:He||{duration:0,once:!0,amount:0},dimmedOpacity:ht,customLayers:gt,maxRadiusValue:dt.checkIfNullOrUndefined(N)?Math.max(...t.map(go).filter(ho)):N,collapseColorScaleByDefault:O,highlightedIds:yt,mapProperty:vt,dotLegendTitle:M,dotBorderColor:L,labelColor:jt,projectionRotate:bt,rewindCoordinatesInMapData:Et}):r.jsxRuntimeExports.jsx("div",{style:{height:`${Math.max(F,s||(R?F?(x||se)*R>F?(x||se)*R:F:(x||se)*R:Fe))}px`},className:"flex items-center justify-center",children:r.jsxRuntimeExports.jsx(Ut.w,{"aria-label":"Loading graph"})})}),e[57]=He,e[58]=G,e[59]=w,e[60]=l,e[61]=O,e[62]=n,e[63]=gt,e[64]=t,e[65]=pe,e[66]=ht,e[67]=Ae,e[68]=L,e[69]=ft,e[70]=M,e[71]=s,e[72]=m,e[73]=yt,e[74]=A,e[75]=ie,e[76]=jt,e[77]=he,e[78]=Ve,e[79]=E,e[80]=$e,e[81]=pt,e[82]=vt,e[83]=ye,e[84]=N,e[85]=F,e[86]=te,e[87]=X,e[88]=bt,e[89]=_e,e[90]=R,e[91]=mt,e[92]=Et,e[93]=Le,e[94]=Be,e[95]=o,e[96]=Q,e[97]=u,e[98]=Fe,e[99]=se,e[100]=ne,e[101]=c.dateFormat,e[102]=c.enabled,e[103]=H,e[104]=p,e[105]=x,e[106]=xt,e[107]=b,e[108]=P,e[109]=be):be=e[109];let Ee;e[110]!==l?.footnote||e[111]!==l?.source||e[112]!==$||e[113]!==y||e[114]!==u?.footnote||e[115]!==u?.source||e[116]!==x?(Ee=y||$?r.jsxRuntimeExports.jsx(oo.GraphFooter,{styles:{footnote:u?.footnote,source:u?.source},classNames:{footnote:l?.footnote,source:l?.source},sources:y,footNote:$,width:x}):null,e[110]=l?.footnote,e[111]=l?.source,e[112]=$,e[113]=y,e[114]=u?.footnote,e[115]=u?.source,e[116]=x,e[117]=Ee):Ee=e[117];let ct;return e[118]!==qe||e[119]!==B||e[120]!==ce||e[121]!==s||e[122]!==ut||e[123]!==F||e[124]!==De||e[125]!==R||e[126]!==Ct||e[127]!==Dt||e[128]!==ve||e[129]!==je||e[130]!==be||e[131]!==Ee||e[132]!==ne||e[133]!==x?(ct=r.jsxRuntimeExports.jsxs(_t.GraphContainer,{className:Ct,style:Dt,id:ce,ref:Mt,"aria-label":qe,backgroundColor:B,theme:ne,language:ut,minHeight:F,width:x,height:s,relativeHeight:R,padding:De,children:[ve,je,be,Ee]}),e[118]=qe,e[119]=B,e[120]=ce,e[121]=s,e[122]=ut,e[123]=F,e[124]=De,e[125]=R,e[126]=Ct,e[127]=Dt,e[128]=ve,e[129]=je,e[130]=be,e[131]=Ee,e[132]=ne,e[133]=x,e[134]=ct):ct=e[134],ct}function ho(a){return a!=null}function go(a){return a.radius}function fo(a){return a.properties.NAME!=="Antarctica"}function yo(a){return a!==void 0}function vo(a){return a!==void 0}function jo(a){return a.data}function bo(a){return a!==void 0}function Eo(a){return a.data}function wo(a){return a.x}function ko(a,e){return a-e}function Ro(a){return a.date}exports.HybridMap=xo;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-CHPV5EwG-6v2a2njQ.cjs"),d=require("react"),qt=require("./parse-xYI9yrvL.cjs"),It=require("./getSliderMarks-CIuSoedo.cjs"),Ut=require("./Spinner-jTMOLuw_.cjs"),Pt=require("./index-DQA8q5sC.cjs"),U=require("./index-DLFt97gy.cjs"),St=require("./Typography-Cc_iHQB-.cjs"),Gt=require("./index-C5K--w8d.cjs"),zt=require("./Source-24M277ZQ.cjs"),Ht=require("./index-Dzc_aaI9-C3DbPpy3.cjs"),Xt=require("./Tooltip-BLa2EfMs.cjs"),Ot=require("./index-sbKVyHS2.cjs"),Yt=require("./DetailsModal-DHttOA80.cjs"),Jt=require("./pow-BnyPO-NX.cjs"),Kt=require("./ordinal-CrsysVE-.cjs"),Zt=require("./threshold-DNsSUf8Q.cjs"),Nt=require("./select-Bnfk0lJx.cjs"),le=require("./proxy-C4-uo6nS.cjs"),dt=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Qt=require("./numberFormattingFunction-02t-wJta.cjs"),eo=require("./use-in-view-C3o_ntMv.cjs"),to=require("./index-CoobIWNj.cjs"),oo=require("./GraphFooter.cjs"),ro=require("./GraphHeader.cjs"),we=require("./Colors.cjs"),ao=require("./fetchAndParseData-QTF6tjij.cjs"),_t=require("./GraphContainer-B1EDxJ0S.cjs"),io=require("./getUniqValue-NX8DgwND.cjs"),no=require("./getJenks-BzJvhy_H.cjs");function so(a){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const t in a)if(t!=="default"){const g=Object.getOwnPropertyDescriptor(a,t);Object.defineProperty(e,t,g.get?g:{enumerable:!0,get:()=>a[t]})}}return e.default=a,Object.freeze(e)}const lo=so(d);var co="Separator",Lt="horizontal",uo=["horizontal","vertical"],Vt=lo.forwardRef((a,e)=>{const{decorative:t,orientation:g=Lt,...f}=a,n=mo(g)?g:Lt,y=t?{role:"none"}:{"aria-orientation":n==="vertical"?n:void 0,role:"separator"};return r.ae.jsx(Ht.w.div,{"data-orientation":n,...y,...f,ref:e})});Vt.displayName=co;function mo(a){return uo.includes(a)}var $t=Vt;const Bt=d.forwardRef((a,e)=>{const t=r._.c(14);let g,f,n,y;t[0]!==a?({className:g,variant:n,orientation:y,...f}=a,t[0]=a,t[1]=g,t[2]=f,t[3]=n,t[4]=y):(g=t[1],f=t[2],n=t[3],y=t[4]);const v=n===void 0?"dark":n,s=y===void 0?"horizontal":y,x=s==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",k=v==="dark"?"bg-primary-gray-600 dark:bg-primary-gray-200":"bg-primary-gray-400 dark:bg-primary-gray-550";let E;t[5]!==g||t[6]!==x||t[7]!==k?(E=r.mo(x,k,g),t[5]=g,t[6]=x,t[7]=k,t[8]=E):E=t[8];let S;return t[9]!==s||t[10]!==f||t[11]!==e||t[12]!==E?(S=r.ae.jsx($t,{...f,ref:e,orientation:s,className:E}),t[9]=s,t[10]=f,t[11]=e,t[12]=E,t[13]=S):S=t[13],S});Bt.displayName=$t.displayName;function po(a){const{data:e,colors:t,mapData:g,mapColorLegendTitle:f,colorDomain:n,radius:y,height:v,width:s,scale:x,centerPoint:k,tooltip:E,showLabels:S,mapBorderWidth:ke,mapBorderColor:Re,mapNoDataColor:Ce,onSeriesMouseOver:G,showColorScale:De,zoomScaleExtend:We,zoomTranslateExtend:Ue,highlightedDataPoints:Se,onSeriesMouseClick:I,resetSelectionOnDoubleClick:Ne,detailsOnClick:H,styles:R,classNames:X,mapProjection:ee,zoomInteraction:Y,animate:j,dimmedOpacity:P,customLayers:ce,maxRadiusValue:de,categorical:te,dotColor:J,collapseColorScaleByDefault:Oe,highlightedIds:oe,mapProperty:ue,dotLegendTitle:me,dotBorderColor:Me,labelColor:qe,projectionRotate:K,rewindCoordinatesInMapData:pe}=a,u=d.useMemo(()=>pe?U.index_default(g,{reverse:!0}):g,[g,pe]),[l,z]=d.useState(void 0),[Ge,Ie]=d.useState(Oe===void 0?!(s<680):!Oe),xe=d.useRef(null),[_,N]=d.useState(void 0),[re,O]=d.useState(void 0),[Pe,C]=d.useState(void 0),[ze,M]=d.useState(void 0),L=d.useRef(null),Z=eo.useInView(L,{once:j.once,amount:j.amount}),ae=d.useRef(null),V=e.filter(o=>o.radius===void 0||o.radius===null).length!==e.length?Jt.sqrt().domain([0,de]).range([.25,y]).nice():void 0,q=te?Kt.ordinal().domain(n).range(t):Zt.threshold().domain(n).range(t);d.useEffect(()=>{const o=Nt.select(ae.current),i=Nt.select(L.current),b=m=>{if(Y==="noZoom")return!1;if(Y==="button")return!m.type.includes("wheel");const ge=m.type==="wheel",fe=m.type.startsWith("touch"),Be=m.type==="mousedown"||m.type==="mousemove";return fe?!0:ge?Y==="scroll"?!0:m.ctrlKey:Be&&!m.button&&!m.ctrlKey},D=U.zoom().scaleExtent(We).translateExtent(Ue||[[-20,-20],[s+20,v+20]]).filter(b).on("zoom",({transform:m})=>{o.attr("transform",m)});i.call(D),xe.current=D},[v,s,Y]);const $=U.index_default$1(u),w=Gt.index_default(u),_e=($[2]-$[0])*1.15,Le=($[3]-$[1])*1.15,Ve=s*190/960*360/_e,$e=v*190/678*180/Le,B=x*Math.min(Ve,$e),Q=ee==="mercator"?U.geoMercator().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="equalEarth"?U.geoEqualEarth().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="naturalEarth"?U.geoNaturalEarth1().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):ee==="orthographic"?U.geoOrthographic().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B):U.geoAlbersUsa().rotate(K).center(k||w.geometry.coordinates).translate([s/2,v/2]).scale(B),he=U.geoPath().projection(Q),ie=o=>{if(!L.current||!xe.current)return;Nt.select(L.current).call(xe.current.scaleBy,o==="in"?1.2:1/1.2)};return r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:"relative",children:[r.jsxRuntimeExports.jsx(le.motion.svg,{width:`${s}px`,height:`${v}px`,viewBox:`0 0 ${s} ${v}`,ref:L,direction:"ltr",children:r.jsxRuntimeExports.jsxs("g",{ref:ae,children:[ce.filter(o=>o.position==="before").map(o=>o.layer),u.features.map((o,i)=>{if(!o.properties?.[ue])return null;const b=he(o);return b?r.jsxRuntimeExports.jsx(le.motion.g,{opacity:l?P:oe.length!==0?oe.indexOf(o.properties[ue])!==-1?1:P:1,children:r.jsxRuntimeExports.jsx("path",{d:b,style:{stroke:Re,strokeWidth:ke,fill:Ce}})},i):null}),r.jsxRuntimeExports.jsxs(to.AnimatePresence,{children:[e.filter(o=>o.id).map(o=>{const i=u.features.findIndex(m=>o.id===m.properties[ue]);if(i===-1)return null;const b=he(u.features[i]);if(!b)return null;const D=dt.checkIfNullOrUndefined(o.x)?Ce:q(o.x);return r.jsxRuntimeExports.jsx(le.motion.g,{className:"undp-map-shapes",variants:{initial:{opacity:0},whileInView:{opacity:l?l===D?1:P:oe.length!==0?oe.indexOf(o.id)!==-1?1:P:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},onMouseEnter:m=>{O(o),M(m.clientY),C(m.clientX),G?.(o)},onMouseMove:m=>{O(o),M(m.clientY),C(m.clientX)},onMouseLeave:()=>{O(void 0),C(void 0),M(void 0),G?.(void 0)},onClick:()=>{(I||H)&&(Pt.isEqual(_,o)&&Ne?(N(void 0),I?.(void 0)):(N(o),I?.(o)))},children:r.jsxRuntimeExports.jsx(le.motion.path,{d:b,variants:{initial:{fill:D,opacity:0},whileInView:{fill:D,opacity:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},style:{stroke:Re,strokeWidth:ke}},`${o.id}`)},o.id)}),e.filter(o=>!dt.checkIfNullOrUndefined(o.lat)&&!dt.checkIfNullOrUndefined(o.long)).map(o=>{const i=Q([o.long,o.lat])[0]>.8*s?-1:1;return r.jsxRuntimeExports.jsxs(le.motion.g,{className:"undp-map-dots",variants:{initial:{opacity:0},whileInView:{opacity:Se.length!==0?Se.indexOf(o.label||"")!==-1?1:P:1,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},onMouseEnter:b=>{O(o),M(b.clientY),C(b.clientX),G?.(o)},onMouseMove:b=>{O(o),M(b.clientY),C(b.clientX)},onMouseLeave:()=>{O(void 0),C(void 0),M(void 0),G?.(void 0)},onClick:()=>{(I||H)&&(Pt.isEqual(_,o)&&Ne?(N(void 0),I?.(void 0)):(N(o),I?.(o)))},transform:`translate(${Q([o.long,o.lat])[0]},${Q([o.long,o.lat])[1]})`,children:[r.jsxRuntimeExports.jsx(le.motion.circle,{cx:0,cy:0,variants:{initial:{r:0,fill:J,stroke:Me||J},whileInView:{r:V?V(o.radius||0):y,fill:J,stroke:Me||J,transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{r:0,transition:{duration:j.duration}},style:{fillOpacity:.8}}),S&&o.label?r.jsxRuntimeExports.jsx(le.motion.text,{variants:{initial:{opacity:0,x:i*(V?V(o.radius||0):y)},whileInView:{opacity:1,x:i*(V?V(o.radius||0):y),transition:{duration:j.duration}}},initial:"initial",animate:Z?"whileInView":"initial",exit:{opacity:0,transition:{duration:j.duration}},y:0,className:r.mo("text-sm",X?.graphObjectValues),style:{textAnchor:i===-1?"end":"start",fill:qe||"#000",...R?.graphObjectValues||{}},dx:i*4,dy:5,children:o.label}):null]},o.label||`${o.lat}-${o.long}`)})]}),ce.filter(o=>o.position==="after").map(o=>o.layer)]})}),De===!1?null:r.jsxRuntimeExports.jsx("div",{className:r.mo("absolute left-4 bottom-4 map-color-legend",X?.colorLegend),children:Ge?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx("div",{className:"color-legend-close-button bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)] border border-[var(--gray-400)] rounded-full w-6 h-6 p-[3px] cursor-pointer z-10 absolute right-[-0.75rem] top-[-0.75rem]",onClick:()=>{Ie(!1)},children:r.jsxRuntimeExports.jsx(Ot.X,{})}),r.jsxRuntimeExports.jsxs("div",{className:"color-legend-box p-2 bg-[rgba(240,240,240,0.7)] dark:bg-[rgba(30,30,30,0.7)]",style:{width:te?void 0:"340px"},children:[me&&me!==""?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2",children:[r.jsxRuntimeExports.jsx("div",{className:"w-3 h-3 rounded-full",style:{backgroundColor:J}}),r.jsxRuntimeExports.jsx(St._,{size:"xs",marginBottom:"none",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:me})]}),r.jsxRuntimeExports.jsx(zt.n,{size:"xl"}),r.jsxRuntimeExports.jsx(Bt,{}),r.jsxRuntimeExports.jsx(zt.n,{size:"xl"})]}):null,f&&f!==""?r.jsxRuntimeExports.jsx(St._,{size:"xs",marginBottom:"xs",className:"p-0 leading-normal overflow-hidden text-primary-gray-700 dark:text-primary-gray-300",style:{display:"-webkit-box",WebkitLineClamp:"1",WebkitBoxOrient:"vertical"},children:f}):null,te?r.jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-3",children:n.map((o,i)=>r.jsxRuntimeExports.jsxs("div",{className:"flex gap-2 items-center",onMouseOver:()=>{z(t[i%t.length])},onMouseLeave:()=>{z(void 0)},children:[r.jsxRuntimeExports.jsx("div",{className:"w-2 h-2 rounded-full",style:{backgroundColor:t[i%t.length]}}),r.jsxRuntimeExports.jsx(St._,{size:"sm",marginBottom:"none",leading:"none",children:o})]},i))}):r.jsxRuntimeExports.jsx("svg",{width:"100%",viewBox:"0 0 320 30",direction:"ltr",children:r.jsxRuntimeExports.jsxs("g",{children:[n.map((o,i)=>r.jsxRuntimeExports.jsxs("g",{onMouseOver:()=>{z(t[i])},onMouseLeave:()=>{z(void 0)},className:"cursor-pointer",children:[r.jsxRuntimeExports.jsx("rect",{x:i*320/t.length+1,y:1,width:320/t.length-2,height:8,className:l===t[i]?"stroke-primary-gray-700 dark:stroke-primary-gray-300":"",style:{fill:t[i],...l===t[i]?{}:{stroke:t[i]}}}),r.jsxRuntimeExports.jsx("text",{x:(i+1)*320/t.length,y:25,className:"fill-primary-gray-700 dark:fill-primary-gray-300 text-xs",style:{textAnchor:"middle"},children:Qt.numberFormattingFunction(o,"NA")})]},i)),r.jsxRuntimeExports.jsx("g",{children:r.jsxRuntimeExports.jsx("rect",{onMouseOver:()=>{z(t[n.length])},onMouseLeave:()=>{z(void 0)},x:n.length*320/t.length+1,y:1,width:320/t.length-2,height:8,className:`cursor-pointer ${l===t[n.length]?"stroke-1 stroke-primary-gray-700 dark:stroke-primary-gray-300":""}`,style:{fill:t[n.length],...l===t[n.length]?{}:{stroke:t[n.length]}}})})]})})]})]}):r.jsxRuntimeExports.jsx("button",{type:"button",className:"mb-0 border-0 bg-transparent p-0 self-start map-legend-button",onClick:()=>{Ie(!0)},children:r.jsxRuntimeExports.jsx("div",{className:"show-color-legend-button items-start text-sm font-medium cursor-pointer p-2 mb-0 flex text-primary-black dark:text-primary-gray-300 bg-primary-gray-300 dark:bg-primary-gray-600 border-primary-gray-400 dark:border-primary-gray-500",children:"Show Legend"})})}),Y==="button"&&r.jsxRuntimeExports.jsxs("div",{className:"absolute left-4 top-4 flex flex-col zoom-buttons",children:[r.jsxRuntimeExports.jsx("button",{onClick:()=>ie("in"),className:"leading-0 px-2 py-3.5 text-primary-gray-700 border border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100",children:"+"}),r.jsxRuntimeExports.jsx("button",{onClick:()=>ie("out"),className:"leading-0 px-2 py-3.5 text-primary-gray-700 border border-t-0 border-primary-gray-400 bg-primary-gray-200 dark:border-primary-gray-550 dark:bg-primary-gray-600 dark:text-primary-gray-100",children:"–"})]})]}),H&&_!==void 0?r.jsxRuntimeExports.jsx(Yt.DetailsModal,{body:H,data:_,setData:N,className:X?.modal}):null,re&&E&&Pe&&ze?r.jsxRuntimeExports.jsx(Xt.Tooltip,{data:re,body:E,xPos:Pe,yPos:ze,backgroundStyle:R?.tooltip,className:X?.tooltip}):null]})}function xo(a){const e=r.compilerRuntimeExports.c(135),{data:t,mapData:g,graphTitle:f,colors:n,sources:y,graphDescription:v,height:s,width:x,footNote:k,mapColorLegendTitle:E,colorDomain:S,choroplethScaleType:ke,radius:Re,scale:Ce,centerPoint:G,padding:De,mapBorderWidth:We,mapNoDataColor:Ue,backgroundColor:Se,showLabels:I,mapBorderColor:Ne,tooltip:H,relativeHeight:R,onSeriesMouseOver:X,isWorldMap:ee,showColorScale:Y,zoomScaleExtend:j,zoomTranslateExtend:P,graphID:ce,highlightedDataPoints:de,onSeriesMouseClick:te,graphDownload:J,dataDownload:Oe,showAntarctica:oe,language:ue,minHeight:me,theme:Me,ariaLabel:qe,resetSelectionOnDoubleClick:K,detailsOnClick:pe,styles:u,classNames:l,mapProjection:z,zoomInteraction:Ge,animate:Ie,dimmedOpacity:xe,customLayers:_,maxRadiusValue:N,timeline:re,collapseColorScaleByDefault:O,dotColor:Pe,highlightedIds:C,mapProperty:ze,dotLegendTitle:M,dotBorderColor:L,labelColor:Z,projectionRotate:ae,rewindCoordinatesInMapData:V}=a,q=g===void 0?"https://raw.githubusercontent.com/UNDP-Data/dv-country-geojson/refs/heads/main/worldMap-v2.json":g,$=k===void 0?"The designations employed and the presentation of material on this map do not imply the expression of any opinion whatsoever on the part of the Secretariat of the United Nations or UNDP concerning the legal status of any country, territory, city or area or its authorities, or concerning the delimitation of its frontiers or boundaries.":k,w=ke===void 0?"threshold":ke,_e=Re===void 0?5:Re,Le=Ce===void 0?.95:Ce,Ve=We===void 0?.5:We,$e=Ue===void 0?we.Colors.light.graphNoData:Ue,B=Se===void 0?!1:Se,Q=I===void 0?!1:I,he=Ne===void 0?we.Colors.light.grays["gray-500"]:Ne,ie=ee===void 0?!0:ee,o=Y===void 0?!0:Y;let i;e[0]!==j?(i=j===void 0?[.8,6]:j,e[0]=j,e[1]=i):i=e[1];const b=i;let D;e[2]!==de?(D=de===void 0?[]:de,e[2]=de,e[3]=D):D=e[3];const m=D,ge=J===void 0?!1:J,fe=Oe===void 0?!1:Oe,Be=oe===void 0?!1:oe,ut=ue===void 0?"en":ue,F=me===void 0?0:me,ne=Me===void 0?"light":Me,mt=K===void 0?!0:K,pt=z===void 0?"naturalEarth":z,xt=Ge===void 0?"button":Ge,He=Ie===void 0?!1:Ie,ht=xe===void 0?.3:xe;let Xe;e[4]!==_?(Xe=_===void 0?[]:_,e[4]=_,e[5]=Xe):Xe=e[5];const gt=Xe;let Ye;e[6]!==re?(Ye=re===void 0?{enabled:!1,autoplay:!1,showOnlyActiveDate:!0}:re,e[6]=re,e[7]=Ye):Ye=e[7];const c=Ye,ft=Pe===void 0?we.Colors.primaryColors["blue-600"]:Pe;let Je;e[8]!==C?(Je=C===void 0?[]:C,e[8]=C,e[9]=Je):Je=e[9];const yt=Je,vt=ze===void 0?"ISO3":ze,jt=Z===void 0?we.Colors.primaryColors["blue-600"]:Z;let Ke;e[10]!==ae?(Ke=ae===void 0?[0,0]:ae,e[10]=ae,e[11]=Ke):Ke=e[11];const bt=Ke,Et=V===void 0?!0:V,[se,Ft]=d.useState(0),[Fe,Tt]=d.useState(0),[T,At]=d.useState(c.autoplay);let Te;if(e[12]!==t||e[13]!==c.dateFormat){let h;e[15]!==c.dateFormat?(h=W=>qt.parse(`${W.date}`,c.dateFormat||"yyyy",new Date).getTime(),e[15]=c.dateFormat,e[16]=h):h=e[16],Te=[...new Set(t.filter(Ro).map(h))],Te.sort(ko),e[12]=t,e[13]=c.dateFormat,e[14]=Te}else Te=e[14];const p=Te,[A,wt]=d.useState(c.autoplay?0:p.length-1),[ye,Wt]=d.useState(void 0),kt=d.useRef(null),Mt=d.useRef(null);let Ze;e[17]!==w||e[18]!==S||e[19]!==n?.length||e[20]!==t?(Ze=S||(w==="categorical"?io.getUniqValue(t,"x"):no.getJenks(t.map(wo),n?.length||4)),e[17]=w,e[18]=S,e[19]=n?.length,e[20]=t,e[21]=Ze):Ze=e[21];const Ae=Ze;let Qe,et;e[22]===Symbol.for("react.memo_cache_sentinel")?(Qe=()=>{const h=new ResizeObserver(W=>{Ft(W[0].target.clientWidth||620),Tt(W[0].target.clientHeight||480)});return kt.current&&h.observe(kt.current),()=>h.disconnect()},et=[],e[22]=Qe,e[23]=et):(Qe=e[22],et=e[23]),d.useEffect(Qe,et);let tt;e[24]===Symbol.for("react.memo_cache_sentinel")?(tt=h=>{Wt(h)},e[24]=tt):tt=e[24];const ot=d.useEffectEvent(tt);let rt;e[25]!==q||e[26]!==ot?(rt=()=>{typeof q=="string"?ao.fetchAndParseJSON(q).then(W=>{ot(W)}):ot(q)},e[25]=q,e[26]=ot,e[27]=rt):rt=e[27];let at;e[28]!==q?(at=[q],e[28]=q,e[29]=at):at=e[29],d.useEffect(rt,at);let it,nt;e[30]!==T||e[31]!==c.speed||e[32]!==p?(it=()=>{const h=setInterval(()=>{wt(W=>W<p.length-1?W+1:0)},(c.speed||2)*1e3);return T||clearInterval(h),()=>clearInterval(h)},nt=[p,T,c.speed],e[30]=T,e[31]=c.speed,e[32]=p,e[33]=it,e[34]=nt):(it=e[33],nt=e[34]),d.useEffect(it,nt);const Rt=c.dateFormat||"yyyy";let st;e[35]!==A||e[36]!==Rt||e[37]!==c.showOnlyActiveDate||e[38]!==p?(st=It.getSliderMarks(p,A,c.showOnlyActiveDate,Rt),e[35]=A,e[36]=Rt,e[37]=c.showOnlyActiveDate,e[38]=p,e[39]=st):st=e[39];const lt=st,Ct=l?.graphContainer,Dt=u?.graphContainer;let ve;e[40]!==l?.description||e[41]!==l?.title||e[42]!==t||e[43]!==fe||e[44]!==v||e[45]!==ge||e[46]!==f||e[47]!==u?.description||e[48]!==u?.title||e[49]!==x?(ve=f||v||ge||fe?r.jsxRuntimeExports.jsx(ro.GraphHeader,{styles:{title:u?.title,description:u?.description},classNames:{title:l?.title,description:l?.description},graphTitle:f,graphDescription:v,width:x,graphDownload:ge?Mt:void 0,dataDownload:fe?t.map(Eo).filter(bo).length>0?t.map(jo).filter(vo):t.filter(yo):null}):null,e[40]=l?.description,e[41]=l?.title,e[42]=t,e[43]=fe,e[44]=v,e[45]=ge,e[46]=f,e[47]=u?.description,e[48]=u?.title,e[49]=x,e[50]=ve):ve=e[50];let je;e[51]!==A||e[52]!==lt||e[53]!==T||e[54]!==c.enabled||e[55]!==p?(je=c.enabled&&p.length>0&&lt?r.jsxRuntimeExports.jsxs("div",{className:"flex gap-6 items-center",dir:"ltr",children:[r.jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>{At(!T)},className:"p-0 border-0 cursor-pointer bg-transparent","aria-label":T?"Click to pause animation":"Click to play animation",children:T?r.jsxRuntimeExports.jsx(Ot.Pause,{}):r.jsxRuntimeExports.jsx(Ot.Play,{})}),r.jsxRuntimeExports.jsx(It.Nr,{min:p[0],max:p[p.length-1],marks:lt,step:null,defaultValue:p[p.length-1],value:p[A],onChangeComplete:h=>{wt(p.indexOf(h))},onChange:h=>{wt(p.indexOf(h))},"aria-label":"Time slider. Use arrow keys to adjust selected time period."})]}):null,e[51]=A,e[52]=lt,e[53]=T,e[54]=c.enabled,e[55]=p,e[56]=je):je=e[56];let be;e[57]!==He||e[58]!==G||e[59]!==w||e[60]!==l||e[61]!==O||e[62]!==n||e[63]!==gt||e[64]!==t||e[65]!==pe||e[66]!==ht||e[67]!==Ae||e[68]!==L||e[69]!==ft||e[70]!==M||e[71]!==s||e[72]!==m||e[73]!==yt||e[74]!==A||e[75]!==ie||e[76]!==jt||e[77]!==he||e[78]!==Ve||e[79]!==E||e[80]!==$e||e[81]!==pt||e[82]!==vt||e[83]!==ye||e[84]!==N||e[85]!==F||e[86]!==te||e[87]!==X||e[88]!==bt||e[89]!==_e||e[90]!==R||e[91]!==mt||e[92]!==Et||e[93]!==Le||e[94]!==Be||e[95]!==o||e[96]!==Q||e[97]!==u||e[98]!==Fe||e[99]!==se||e[100]!==ne||e[101]!==c.dateFormat||e[102]!==c.enabled||e[103]!==H||e[104]!==p||e[105]!==x||e[106]!==xt||e[107]!==b||e[108]!==P?(be=r.jsxRuntimeExports.jsx(_t.GraphArea,{ref:kt,children:se&&Fe&&ye?r.jsxRuntimeExports.jsx(po,{dotColor:ft,data:t.filter(h=>c.enabled?h.date===qt.format(new Date(p[A]),c.dateFormat||"yyyy"):h),mapData:Be?ye:{...ye,features:ye.features.filter(fo)},colorDomain:Ae,width:se,height:Fe,scale:Le,centerPoint:G,colors:n||(w==="categorical"?we.Colors[ne].sequentialColors[`neutralColorsx0${Ae.length}`]:we.Colors[ne].sequentialColors[`neutralColorsx0${Ae.length+1}`]),mapColorLegendTitle:E,radius:_e,categorical:w==="categorical",mapBorderWidth:Ve,mapNoDataColor:$e,mapBorderColor:he,tooltip:H,onSeriesMouseOver:X,showLabels:Q,isWorldMap:ie,showColorScale:o,zoomScaleExtend:b,zoomTranslateExtend:P,onSeriesMouseClick:te,highlightedDataPoints:m,resetSelectionOnDoubleClick:mt,styles:u,classNames:l,zoomInteraction:xt,detailsOnClick:pe,mapProjection:pt||(ie?"naturalEarth":"mercator"),animate:He===!0?{duration:.5,once:!0,amount:.5}:He||{duration:0,once:!0,amount:0},dimmedOpacity:ht,customLayers:gt,maxRadiusValue:dt.checkIfNullOrUndefined(N)?Math.max(...t.map(go).filter(ho)):N,collapseColorScaleByDefault:O,highlightedIds:yt,mapProperty:vt,dotLegendTitle:M,dotBorderColor:L,labelColor:jt,projectionRotate:bt,rewindCoordinatesInMapData:Et}):r.jsxRuntimeExports.jsx("div",{style:{height:`${Math.max(F,s||(R?F?(x||se)*R>F?(x||se)*R:F:(x||se)*R:Fe))}px`},className:"flex items-center justify-center",children:r.jsxRuntimeExports.jsx(Ut.w,{"aria-label":"Loading graph"})})}),e[57]=He,e[58]=G,e[59]=w,e[60]=l,e[61]=O,e[62]=n,e[63]=gt,e[64]=t,e[65]=pe,e[66]=ht,e[67]=Ae,e[68]=L,e[69]=ft,e[70]=M,e[71]=s,e[72]=m,e[73]=yt,e[74]=A,e[75]=ie,e[76]=jt,e[77]=he,e[78]=Ve,e[79]=E,e[80]=$e,e[81]=pt,e[82]=vt,e[83]=ye,e[84]=N,e[85]=F,e[86]=te,e[87]=X,e[88]=bt,e[89]=_e,e[90]=R,e[91]=mt,e[92]=Et,e[93]=Le,e[94]=Be,e[95]=o,e[96]=Q,e[97]=u,e[98]=Fe,e[99]=se,e[100]=ne,e[101]=c.dateFormat,e[102]=c.enabled,e[103]=H,e[104]=p,e[105]=x,e[106]=xt,e[107]=b,e[108]=P,e[109]=be):be=e[109];let Ee;e[110]!==l?.footnote||e[111]!==l?.source||e[112]!==$||e[113]!==y||e[114]!==u?.footnote||e[115]!==u?.source||e[116]!==x?(Ee=y||$?r.jsxRuntimeExports.jsx(oo.GraphFooter,{styles:{footnote:u?.footnote,source:u?.source},classNames:{footnote:l?.footnote,source:l?.source},sources:y,footNote:$,width:x}):null,e[110]=l?.footnote,e[111]=l?.source,e[112]=$,e[113]=y,e[114]=u?.footnote,e[115]=u?.source,e[116]=x,e[117]=Ee):Ee=e[117];let ct;return e[118]!==qe||e[119]!==B||e[120]!==ce||e[121]!==s||e[122]!==ut||e[123]!==F||e[124]!==De||e[125]!==R||e[126]!==Ct||e[127]!==Dt||e[128]!==ve||e[129]!==je||e[130]!==be||e[131]!==Ee||e[132]!==ne||e[133]!==x?(ct=r.jsxRuntimeExports.jsxs(_t.GraphContainer,{className:Ct,style:Dt,id:ce,ref:Mt,"aria-label":qe,backgroundColor:B,theme:ne,language:ut,minHeight:F,width:x,height:s,relativeHeight:R,padding:De,children:[ve,je,be,Ee]}),e[118]=qe,e[119]=B,e[120]=ce,e[121]=s,e[122]=ut,e[123]=F,e[124]=De,e[125]=R,e[126]=Ct,e[127]=Dt,e[128]=ve,e[129]=je,e[130]=be,e[131]=Ee,e[132]=ne,e[133]=x,e[134]=ct):ct=e[134],ct}function ho(a){return a!=null}function go(a){return a.radius}function fo(a){return a.properties.NAME!=="Antarctica"}function yo(a){return a!==void 0}function vo(a){return a!==void 0}function jo(a){return a.data}function bo(a){return a!==void 0}function Eo(a){return a.data}function wo(a){return a.x}function ko(a,e){return a-e}function Ro(a){return a.date}exports.HybridMap=xo;
2
2
  //# sourceMappingURL=HybridMap.cjs.map
package/dist/HybridMap.js CHANGED
@@ -6,9 +6,9 @@ import { g as Ze, N as Qe } from "./getSliderMarks-Cvg8zHBU.js";
6
6
  import { w as to } from "./Spinner--r2RrJV8.js";
7
7
  import { i as Pe } from "./index-Bwrro8-q.js";
8
8
  import { i as eo, z as oo, a as ao, g as ro, b as io, c as no, d as lo, e as so, f as co } from "./index-Dp_SfsUA.js";
9
- import { _ as Oe } from "./Typography-iR8PEgdt.js";
9
+ import { _ as Oe } from "./Typography-CdMGooqp.js";
10
10
  import { i as mo } from "./index-DCsFBfJ_.js";
11
- import { n as Le } from "./Source-_STIejqs.js";
11
+ import { n as Le } from "./Source-Cu9OHOBj.js";
12
12
  import { w as po } from "./index-Dzc_aaI9-CG2Ar7l1.js";
13
13
  import { T as uo } from "./Tooltip-BRnAz2Gv.js";
14
14
  import { X as ho, P as go, e as fo } from "./index-B-4y_iGB.js";
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-CHPV5EwG-6v2a2njQ.cjs"),C=require("react"),R=require("./parse-xYI9yrvL.cjs"),Se=require("./simple-statistics-xm8c0LQQ.cjs"),Te=require("./index-Cno4Q0YE.cjs"),Oe=require("./numberFormattingFunction-02t-wJta.cjs"),$e=require("./Tooltip-BLa2EfMs.cjs"),G=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Ne=require("./customArea-B1LWQBmM.cjs"),Fe=require("./AxisTitle-DV4n0RxE.cjs"),We=require("./Axis-Jt_tmhxS.cjs"),He=require("./ReferenceLine-M9aP3dj-.cjs"),Ge=require("./RegressionLine-Ci-Dh0w0.cjs"),Pe=require("./YTicksAndGridLines-UzVC5eBM.cjs"),Ye=require("./index-D69M6klB.cjs"),Ue=require("./time-CkcKbhwe.cjs"),Xe=require("./linear-CgUCbw9F.cjs"),Ae=require("./line-DaEMhXmx.cjs"),be=require("./step-BZ3C8QFW.cjs"),Be=require("./area-C1gxfNGD.cjs"),ze=require("./select-Bnfk0lJx.cjs"),A=require("./proxy-C4-uo6nS.cjs"),Je=require("./init-DU0ybBc_.cjs"),Ke=require("./pointer-Dkq5NV1q.cjs"),Qe=require("./use-in-view-C3o_ntMv.cjs"),Ze=require("./GraphFooter.cjs"),_e=require("./GraphHeader.cjs"),Le=require("./Colors.cjs"),ti=require("./ColorLegend.cjs"),ei=require("./EmptyState-DX0t62iF.cjs"),De=require("./GraphContainer-B1EDxJ0S.cjs"),ii=require("./getNoOfTicks-C_1CFXv_.cjs");function ni(n){const t=i.compilerRuntimeExports.c(102),{data:h,width:_,height:Ft,lineColor:b,suffix:S,prefix:M,dateFormat:l,highlightAreaSettings:f,showValues:Wt,noOfXTicks:he,rightMargin:Ht,leftMargin:D,topMargin:Gt,bottomMargin:dt,tooltip:tt,onSeriesMouseOver:Pt,refValues:ie,minValue:ne,maxValue:ht,animate:o,rtl:ft,strokeWidth:et,showDots:oe,annotations:se,customHighlightAreaSettings:yt,regressionLine:gt,showIntervalDots:ae,showIntervalValues:fe,intervalLineStrokeWidth:Yt,intervalLineColors:E,intervalAreaColor:Ut,intervalAreaOpacity:Xt,yAxisTitle:vt,noOfYTicks:ye,minDate:re,maxDate:le,curveType:jt,styles:y,classNames:g,precision:q,customLayers:P}=n,wt=C.useRef(null);let Y;t[0]!==o.amount||t[1]!==o.once?(Y={once:o.once,amount:o.amount},t[0]=o.amount,t[1]=o.once,t[2]=Y):Y=t[2];const c=Qe.useInView(wt,Y),[p,ce]=C.useState(!1);let Rt,it;t[3]!==o.duration||t[4]!==p||t[5]!==c?(Rt=()=>{if(c&&!p){const e=setTimeout(()=>{ce(!0)},(o.duration+.5)*1e3);return()=>clearTimeout(e)}},it=[c,p,o.duration],t[3]=o.duration,t[4]=p,t[5]=c,t[6]=Rt,t[7]=it):(Rt=t[6],it=t[7]),C.useEffect(Rt,it);const nt=jt==="linear"?Ae.curveLinear:jt==="step"?be.curveStep:jt==="stepAfter"?be.stepAfter:jt==="stepBefore"?be.stepBefore:be.monotoneX,[L,Et]=C.useState(void 0),[U,ue]=C.useState(void 0),[m,x]=C.useState(void 0),Bt=vt?D+30:D;let X;t[8]!==dt||t[9]!==Ht||t[10]!==Bt||t[11]!==Gt?(X={top:Gt,bottom:dt,left:Bt,right:Ht},t[8]=dt,t[9]=Ht,t[10]=Bt,t[11]=Gt,t[12]=X):X=t[12];const j=X,ot=C.useRef(null);let st;t[13]!==l?(st=e=>({date:R.parse(`${e.date}`,l,new Date),y:e.y,yMin:G.checkIfNullOrUndefined(e.yMin)?e.y:e.yMin,yMax:G.checkIfNullOrUndefined(e.yMax)?e.y:e.yMax,data:e.data}),t[13]=l,t[14]=st):st=t[14];const a=Te.orderBy(h.filter(yi).map(st),["date"],["asc"]);let at;if(t[15]!==l||t[16]!==f){let e;t[18]!==l?(e=d=>({...d,coordinates:[d.coordinates[0]===null?null:R.parse(`${d.coordinates[0]}`,l,new Date),d.coordinates[1]===null?null:R.parse(`${d.coordinates[1]}`,l,new Date)]}),t[18]=l,t[19]=e):e=t[19],at=f.map(e),t[15]=l,t[16]=f,t[17]=at}else at=t[17];const Ct=at;let rt;if(t[20]!==yt||t[21]!==l){let e;t[23]!==l?(e=d=>({...d,coordinates:d.coordinates.map((Z,ee)=>ee%2===0?R.parse(`${Z}`,l,new Date):Z)}),t[23]=l,t[24]=e):e=t[24],rt=yt.map(e),t[20]=yt,t[21]=l,t[22]=rt}else rt=t[22];const xe=rt,u=_-j.left-j.right,v=Ft-j.top-j.bottom,zt=re?R.parse(`${re}`,l,new Date):a[0].date,me=le?R.parse(`${le}`,l,new Date):a[a.length-1].date,w=G.checkIfNullOrUndefined(ne)?Math.min(...a.map(fi))?Math.min(...a.map(hi))>0?0:Math.min(...a.map(di)):0:ne,B=Math.max(...a.map(pi))?Math.max(...a.map(mi)):0,s=Ue.time().domain([zt,me]).range([0,u]);let lt;t[25]!==B||t[26]!==ht?(lt=G.checkIfNullOrUndefined(ht)?B>0?B:0:ht,t[25]=B,t[26]=ht,t[27]=lt):lt=t[27];const r=Xe.linear().domain([w,lt]).range([v,0]).nice(),Jt=Ae.line().x(e=>s(e.date)).y(e=>r(e.y)).curve(nt),Mt=Ae.line().x(e=>s(e.date)).y(e=>r(e.yMin)).curve(nt),Kt=Ae.line().x(e=>s(e.date)).y(e=>r(e.yMax)).curve(nt),Qt=Be.area().x(e=>s(e.date)).y0(e=>r(e.yMin)).y1(e=>r(e.yMax)).curve(nt),Zt=r.ticks(ye),_t=s.ticks(he);C.useEffect(()=>{const e=Z=>{const ee=a[Je.bisectCenter(a.map(xi),s.invert(Ke.pointer(Z)[0]),0)];Et(ee||a[a.length-1]),Pt?.(ee||a[a.length-1]),x(Z.clientY),ue(Z.clientX)},d=()=>{Et(void 0),ue(void 0),x(void 0),Pt?.(void 0)};ze.select(ot.current).on("mousemove",e).on("mouseout",d)},[s,a,Pt]);const te=Se.linearRegression(a.filter(ui).map(e=>[s(e.date),r(e.y)])),Ot=Se.linearRegressionLine(te);let O;t[28]!==o||t[29]!==v||t[30]!==u||t[31]!==Ct||t[32]!==c||t[33]!==s?(O=i.jsxRuntimeExports.jsx(Ye.HighlightArea,{areaSettings:Ct,width:u,height:v,scale:s,animate:o,isInView:c}),t[28]=o,t[29]=v,t[30]=u,t[31]=Ct,t[32]=c,t[33]=s,t[34]=O):O=t[34];const At=y?.yAxis?.gridLines,bt=y?.yAxis?.labels;let ct;t[35]!==At||t[36]!==bt?(ct={gridLines:At,labels:bt},t[35]=At,t[36]=bt,t[37]=ct):ct=t[37];const ut=g?.yAxis?.gridLines,Lt=g?.yAxis?.labels;let z;t[38]!==ut||t[39]!==Lt?(z={gridLines:ut,labels:Lt},t[38]=ut,t[39]=Lt,t[40]=z):z=t[40];const kt=r(w<0?0:w),It=r(w<0?0:w),Vt=0-D,Nt=u+j.right,St=w<0?0:w;let k;t[41]!==q||t[42]!==M||t[43]!==S||t[44]!==St?(k=Oe.numberFormattingFunction(St,"NA",q,M,S),t[41]=q,t[42]=M,t[43]=S,t[44]=St,t[45]=k):k=t[45];const Dt=0-D,J=r(w<0?0:w),pe=B<0?"1em":-5;let I;t[46]!==Dt||t[47]!==J||t[48]!==pe?(I={x:Dt,y:J,dx:0,dy:pe},t[46]=Dt,t[47]=J,t[48]=pe,t[49]=I):I=t[49];const de=g?.xAxis?.axis,qt=g?.yAxis?.labels;let K;t[50]!==de||t[51]!==qt?(K={axis:de,label:qt},t[50]=de,t[51]=qt,t[52]=K):K=t[52];const xt=y?.xAxis?.axis,mt=y?.yAxis?.labels;let T;t[53]!==xt||t[54]!==mt?(T={axis:xt,label:mt},t[53]=xt,t[54]=mt,t[55]=T):T=t[55];let pt;t[56]!==kt||t[57]!==It||t[58]!==Vt||t[59]!==Nt||t[60]!==k||t[61]!==I||t[62]!==K||t[63]!==T?(pt=i.jsxRuntimeExports.jsx(We.Axis,{y1:kt,y2:It,x1:Vt,x2:Nt,label:k,labelPos:I,classNames:K,styles:T}),t[56]=kt,t[57]=It,t[58]=Vt,t[59]=Nt,t[60]=k,t[61]=I,t[62]=K,t[63]=T,t[64]=pt):pt=t[64];const $=0-D+15,F=v/2,W=y?.yAxis?.title,H=g?.yAxis?.title;let V;t[65]!==$||t[66]!==F||t[67]!==W||t[68]!==H||t[69]!==vt?(V=i.jsxRuntimeExports.jsx(Fe.AxisTitle,{x:$,y:F,style:W,className:H,text:vt,rotate90:!0}),t[65]=$,t[66]=F,t[67]=W,t[68]=H,t[69]=vt,t[70]=V):V=t[70];let N;t[71]!==P?(N=P.filter(ri).map(ai),t[71]=P,t[72]=N):N=t[72];let Q;t[73]!==Ut?(Q={fill:Ut},t[73]=Ut,t[74]=Q):Q=t[74];let Tt;t[75]!==o.duration?(Tt={opacity:0,transition:{duration:o.duration}},t[75]=o.duration,t[76]=Tt):Tt=t[76];let $t;t[77]!==b||t[78]!==et?($t={stroke:b,fill:"none",strokeWidth:et},t[77]=b,t[78]=et,t[79]=$t):$t=t[79];let ge;t[80]!==o.duration?(ge={opacity:0,transition:{duration:o.duration}},t[80]=o.duration,t[81]=ge):ge=t[81];const ke=a.map((e,d)=>i.jsxRuntimeExports.jsx(A.motion.g,{children:G.checkIfNullOrUndefined(e.y)?null:i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[oe?i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,style:{fill:b},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,cx:s(e.date),cy:r(e.y)},whileInView:{opacity:1,transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.y)}},initial:"initial",animate:c?"whileInView":"initial"}):null,ae?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[0],cx:s(e.date),cy:r(e.yMin)},whileInView:{opacity:1,transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.yMin),fill:E[0]}},initial:"initial",animate:c?"whileInView":"initial"}),i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[1],cx:s(e.date),cy:r(e.yMax)},whileInView:{opacity:1,fill:E[1],transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.yMax)}},initial:"initial",animate:c?"whileInView":"initial"})]}):null,Wt?i.jsxRuntimeExports.jsx(A.motion.text,{dy:-8,style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("graph-value text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:b,x:s(e.date),y:r(e.y)},whileInView:{opacity:1,x:s(e.date),fill:b,y:r(e.y),transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.y,"NA",q,M,S)}):null,fe?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.text,{dy:"1em",style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[0],x:s(e.date),y:r(e.yMin)},whileInView:{opacity:1,x:s(e.date),y:r(e.yMin),fill:E[0],transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.yMin,"NA",q,M,S)}),i.jsxRuntimeExports.jsx(A.motion.text,{dy:-8,style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[1],x:s(e.date),y:r(e.yMax)},whileInView:{opacity:1,fill:E[1],x:s(e.date),y:r(e.yMax),transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.yMax,"NA",q,M,S)})]}):null]})},d));let ve;t[82]!==ke?(ve=i.jsxRuntimeExports.jsx("g",{children:ke}),t[82]=ke,t[83]=ve):ve=t[83];const Ie=se.map((e,d)=>{const Z=Ne.getLineEndPoint({x:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),y:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0)-8:0+(e.yOffset||0)-8},{x:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date)):0,y:e.yCoordinate?r(e.yCoordinate):0},G.checkIfNullOrUndefined(e.connectorRadius)?3.5:e.connectorRadius),ee=e.showConnector?{y1:Z.y,x1:Z.x,y2:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0):0+(e.yOffset||0),x2:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),cy:e.yCoordinate?r(e.yCoordinate):0,cx:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date)):0,circleRadius:G.checkIfNullOrUndefined(e.connectorRadius)?3.5:e.connectorRadius,strokeWidth:e.showConnector===!0?2:Math.min(e.showConnector||0,1)}:void 0,qe={y:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0)-8:0+(e.yOffset||0)-8,x:ft?0:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),width:ft?e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0):u+j.right-(e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0)),maxWidth:e.maxWidth,fontWeight:e.fontWeight,align:e.align};return i.jsxRuntimeExports.jsx(Ne.Annotation,{color:e.color,connectorsSettings:ee,labelSettings:qe,text:e.text,classNames:e.classNames,styles:e.styles,animate:o,isInView:c},d)});let je;t[84]!==Ie?(je=i.jsxRuntimeExports.jsx("g",{children:Ie}),t[84]=Ie,t[85]=je):je=t[85];const Ve=gt?i.jsxRuntimeExports.jsx(Ge.RegressionLine,{x1:0,x2:u,y1:Ot(0),y2:Ot(u),graphHeight:v,graphWidth:u,className:g?.regLine,style:y?.regLine,color:typeof gt=="string"?gt:void 0,animate:o,isInView:c}):null;let we;t[86]!==Ve?(we=i.jsxRuntimeExports.jsx("g",{children:Ve}),t[86]=Ve,t[87]=we):we=t[87];let Re;t[88]!==P?(Re=P.filter(si).map(oi),t[88]=P,t[89]=Re):Re=t[89];let Ee;t[90]===Symbol.for("react.memo_cache_sentinel")?(Ee={fill:"none",pointerEvents:"all"},t[90]=Ee):Ee=t[90];let Ce;t[91]!==ot||t[92]!==v||t[93]!==u?(Ce=i.jsxRuntimeExports.jsx("rect",{ref:ot,style:Ee,width:u,height:v}),t[91]=ot,t[92]=v,t[93]=u,t[94]=Ce):Ce=t[94];let Me;return t[95]!==g?.tooltip||t[96]!==U||t[97]!==m||t[98]!==L||t[99]!==y?.tooltip||t[100]!==tt?(Me=L&&tt&&U&&m?i.jsxRuntimeExports.jsx($e.Tooltip,{data:L,body:tt,xPos:U,yPos:m,backgroundStyle:y?.tooltip,className:g?.tooltip}):null,t[95]=g?.tooltip,t[96]=U,t[97]=m,t[98]=L,t[99]=y?.tooltip,t[100]=tt,t[101]=Me):Me=t[101],i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.svg,{width:`${_}px`,height:`${Ft}px`,viewBox:`0 0 ${_} ${Ft}`,direction:"ltr",ref:wt,children:i.jsxRuntimeExports.jsxs("g",{transform:`translate(${j.left},${j.top})`,children:[O,i.jsxRuntimeExports.jsx(Ne.CustomArea,{areaSettings:xe,scaleX:s,scaleY:r,animate:o,isInView:c}),i.jsxRuntimeExports.jsxs("g",{children:[i.jsxRuntimeExports.jsx(Pe.YTicksAndGridLines,{values:Zt.filter(ci),y:Zt.filter(li).map(e=>r(e)),x1:0-D,x2:u+j.right,styles:ct,classNames:z,suffix:S,prefix:M,labelType:"secondary",showGridLines:!0,labelPos:"vertical",precision:q}),pt,V]}),i.jsxRuntimeExports.jsx("g",{children:_t.map((e,d)=>i.jsxRuntimeExports.jsx("g",{children:i.jsxRuntimeExports.jsx("text",{y:v,x:s(e),style:{textAnchor:"middle"},className:"fill-primary-gray-700 dark:fill-primary-gray-300 xs:max-[360px]:hidden text-[9px] md:text-[10px] lg:text-xs",dy:15,children:R.format(e,l)})},d))}),N,i.jsxRuntimeExports.jsx(A.motion.path,{style:Q,exit:Tt,variants:{initial:{opacity:0,d:Qt(a)||""},whileInView:{opacity:Xt,d:Qt(a)||"",transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),Yt?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.path,{style:{stroke:E[0],fill:"none",strokeWidth:Yt},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{pathLength:0,d:Mt(a)||"",opacity:1},whileInView:{pathLength:1,d:Mt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),i.jsxRuntimeExports.jsx(A.motion.path,{style:{stroke:E[1],fill:"none",strokeWidth:Yt},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{pathLength:0,d:Kt(a)||"",opacity:1},whileInView:{pathLength:1,d:Kt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"})]}):null,i.jsxRuntimeExports.jsx(A.motion.path,{style:$t,exit:ge,variants:{initial:{pathLength:0,d:Jt(a)||"",opacity:1},whileInView:{pathLength:1,d:Jt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),L?i.jsxRuntimeExports.jsx("line",{y1:0,y2:v,x1:s(L.date),x2:s(L.date),className:i.mo("undp-tick-line stroke-primary-gray-700 dark:stroke-primary-gray-100",g?.mouseOverLine),style:y?.mouseOverLine}):null,ve,ie?i.jsxRuntimeExports.jsx(i.jsxRuntimeExports.Fragment,{children:ie.map((e,d)=>i.jsxRuntimeExports.jsx(He.RefLineY,{text:e.text,color:e.color,y:r(e.value),x1:0-D,x2:u+j.right,classNames:e.classNames,styles:e.styles,animate:o,isInView:c},d))}):null,je,we,Re,Ce]})}),Me]})}function oi(n){return n.layer}function si(n){return n.position==="after"}function ai(n){return n.layer}function ri(n){return n.position==="before"}function li(n){return n!==0}function ci(n){return n!==0}function ui(n){return!G.checkIfNullOrUndefined(n.date)&&!G.checkIfNullOrUndefined(n.y)}function xi(n){return n.date}function mi(n){return Math.max(n.y,n.yMax,n.yMin)}function pi(n){return Math.max(n.y,n.yMax,n.yMin)}function di(n){return Math.min(n.y,n.yMax,n.yMin)}function hi(n){return Math.min(n.y,n.yMax,n.yMin)}function fi(n){return Math.min(n.y,n.yMax,n.yMin)}function yi(n){return!G.checkIfNullOrUndefined(n.y)}function gi(n){const t=i.compilerRuntimeExports.c(104),{data:h,graphTitle:_,suffix:Ft,sources:b,prefix:S,graphDescription:M,height:l,width:f,footNote:Wt,noOfXTicks:he,dateFormat:Ht,showValues:D,backgroundColor:Gt,padding:dt,lineColor:tt,leftMargin:Pt,rightMargin:ie,topMargin:ne,bottomMargin:ht,tooltip:o,refValues:ft,highlightAreaSettings:et,relativeHeight:oe,onSeriesMouseOver:se,graphID:yt,minValue:gt,maxValue:ae,regressionLine:fe,showIntervalDots:Yt,showIntervalValues:E,intervalLineStrokeWidth:Ut,intervalLineColors:Xt,intervalAreaColor:vt,intervalAreaOpacity:ye,graphDownload:re,dataDownload:le,animate:jt,language:y,minHeight:g,strokeWidth:q,showDots:P,annotations:wt,customHighlightAreaSettings:Y,theme:c,ariaLabel:p,yAxisTitle:ce,noOfYTicks:Rt,minDate:it,maxDate:nt,colorLegendTitle:L,colorLegendColors:Et,colorLegendDomain:U,curveType:ue,styles:m,classNames:x,precision:Bt,customLayers:X}=n,j=Ft===void 0?"":Ft,ot=S===void 0?"":S,st=he===void 0?10:he,a=Ht===void 0?"yyyy":Ht,at=D===void 0?!1:D,Ct=Gt===void 0?!1:Gt,rt=Pt===void 0?30:Pt,xe=ie===void 0?30:ie,u=ne===void 0?20:ne,v=ht===void 0?25:ht;let zt;t[0]!==ft?(zt=ft===void 0?[]:ft,t[0]=ft,t[1]=zt):zt=t[1];const me=zt;let w;t[2]!==et?(w=et===void 0?[]:et,t[2]=et,t[3]=w):w=t[3];const B=w,s=fe===void 0?!1:fe,lt=Yt===void 0?!1:Yt,r=E===void 0?!1:E,Jt=Ut===void 0?0:Ut;let Mt;t[4]!==Xt?(Mt=Xt===void 0?[Le.Colors.light.grays["gray-500"],Le.Colors.light.grays["gray-500"]]:Xt,t[4]=Xt,t[5]=Mt):Mt=t[5];const Kt=Mt,Qt=vt===void 0?Le.Colors.primaryColors["blue-100"]:vt,Zt=ye===void 0?.4:ye,_t=re===void 0?!1:re,te=le===void 0?!1:le,Ot=jt===void 0?!1:jt,O=y===void 0?"en":y,At=g===void 0?0:g,bt=q===void 0?2:q,ct=P===void 0?!0:P;let ut;t[6]!==wt?(ut=wt===void 0?[]:wt,t[6]=wt,t[7]=ut):ut=t[7];const Lt=ut;let z;t[8]!==Y?(z=Y===void 0?[]:Y,t[8]=Y,t[9]=z):z=t[9];const kt=z,It=c===void 0?"light":c,Vt=Rt===void 0?5:Rt,Nt=ue===void 0?"curve":ue,St=Bt===void 0?2:Bt;let k;t[10]!==X?(k=X===void 0?[]:X,t[10]=X,t[11]=k):k=t[11];const Dt=k,[J,pe]=C.useState(0),[I,de]=C.useState(0),qt=C.useRef(null),K=C.useRef(null);let xt,mt;t[12]===Symbol.for("react.memo_cache_sentinel")?(xt=()=>{const Tt=new ResizeObserver($t=>{pe($t[0].target.clientWidth||620),de($t[0].target.clientHeight||480)});return qt.current&&Tt.observe(qt.current),()=>Tt.disconnect()},mt=[],t[12]=xt,t[13]=mt):(xt=t[12],mt=t[13]),C.useEffect(xt,mt);const T=x?.graphContainer,pt=m?.graphContainer;let $;t[14]!==x?.description||t[15]!==x?.title||t[16]!==h||t[17]!==te||t[18]!==M||t[19]!==_t||t[20]!==_||t[21]!==m?.description||t[22]!==m?.title||t[23]!==f?($=_||M||_t||te?i.jsxRuntimeExports.jsx(_e.GraphHeader,{styles:{title:m?.title,description:m?.description},classNames:{title:x?.title,description:x?.description},graphTitle:_,graphDescription:M,width:f,graphDownload:_t?K:void 0,dataDownload:te?h.map(Ei).filter(Ri).length>0?h.map(wi).filter(ji):h.filter(vi):null}):null,t[14]=x?.description,t[15]=x?.title,t[16]=h,t[17]=te,t[18]=M,t[19]=_t,t[20]=_,t[21]=m?.description,t[22]=m?.title,t[23]=f,t[24]=$):$=t[24];let F;t[25]!==x?.colorLegend||t[26]!==Et||t[27]!==U||t[28]!==L||t[29]!==h.length||t[30]!==f?(F=Et&&U&&h.length>0?i.jsxRuntimeExports.jsx(ti.ColorLegend,{width:f,colorLegendTitle:L,colors:Et,colorDomain:U,showNAColor:!1,className:x?.colorLegend}):null,t[25]=x?.colorLegend,t[26]=Et,t[27]=U,t[28]=L,t[29]=h.length,t[30]=f,t[31]=F):F=t[31];let W;t[32]!==h.length?(W=h.length===0&&i.jsxRuntimeExports.jsx(ei.EmptyState,{}),t[32]=h.length,t[33]=W):W=t[33];let H;t[34]!==Ot||t[35]!==Lt||t[36]!==v||t[37]!==x||t[38]!==Nt||t[39]!==kt||t[40]!==Dt||t[41]!==h||t[42]!==a||t[43]!==B||t[44]!==Qt||t[45]!==Zt||t[46]!==Kt||t[47]!==Jt||t[48]!==O||t[49]!==rt||t[50]!==tt||t[51]!==nt||t[52]!==ae||t[53]!==it||t[54]!==gt||t[55]!==st||t[56]!==Vt||t[57]!==se||t[58]!==St||t[59]!==ot||t[60]!==me||t[61]!==s||t[62]!==xe||t[63]!==ct||t[64]!==lt||t[65]!==r||t[66]!==at||t[67]!==bt||t[68]!==m||t[69]!==j||t[70]!==I||t[71]!==J||t[72]!==o||t[73]!==u||t[74]!==ce?(H=J&&I&&h.length>0?i.jsxRuntimeExports.jsx(ni,{data:h,lineColor:tt||Le.Colors.primaryColors["blue-600"],width:J,height:I,suffix:j,prefix:ot,dateFormat:a,showValues:at,noOfXTicks:st??ii.getNoOfTicks(J),leftMargin:rt,rightMargin:xe,topMargin:u,bottomMargin:v,tooltip:o,highlightAreaSettings:B,onSeriesMouseOver:se,refValues:me,minValue:gt,maxValue:ae,animate:Ot===!0?{duration:.5,once:!0,amount:.5}:Ot||{duration:0,once:!0,amount:0},rtl:O==="he"||O==="ar",strokeWidth:bt,showDots:ct,annotations:Lt,customHighlightAreaSettings:kt,regressionLine:s,showIntervalDots:lt,showIntervalValues:r,intervalLineStrokeWidth:Jt,intervalLineColors:Kt,intervalAreaColor:Qt,intervalAreaOpacity:Zt,yAxisTitle:ce,noOfYTicks:Vt,minDate:it,maxDate:nt,curveType:Nt,styles:m,classNames:x,precision:St,customLayers:Dt}):null,t[34]=Ot,t[35]=Lt,t[36]=v,t[37]=x,t[38]=Nt,t[39]=kt,t[40]=Dt,t[41]=h,t[42]=a,t[43]=B,t[44]=Qt,t[45]=Zt,t[46]=Kt,t[47]=Jt,t[48]=O,t[49]=rt,t[50]=tt,t[51]=nt,t[52]=ae,t[53]=it,t[54]=gt,t[55]=st,t[56]=Vt,t[57]=se,t[58]=St,t[59]=ot,t[60]=me,t[61]=s,t[62]=xe,t[63]=ct,t[64]=lt,t[65]=r,t[66]=at,t[67]=bt,t[68]=m,t[69]=j,t[70]=I,t[71]=J,t[72]=o,t[73]=u,t[74]=ce,t[75]=H):H=t[75];let V;t[76]!==W||t[77]!==H?(V=i.jsxRuntimeExports.jsxs(De.GraphArea,{ref:qt,children:[W,H]}),t[76]=W,t[77]=H,t[78]=V):V=t[78];let N;t[79]!==x?.footnote||t[80]!==x?.source||t[81]!==Wt||t[82]!==b||t[83]!==m?.footnote||t[84]!==m?.source||t[85]!==f?(N=b||Wt?i.jsxRuntimeExports.jsx(Ze.GraphFooter,{styles:{footnote:m?.footnote,source:m?.source},classNames:{footnote:x?.footnote,source:x?.source},sources:b,footNote:Wt,width:f}):null,t[79]=x?.footnote,t[80]=x?.source,t[81]=Wt,t[82]=b,t[83]=m?.footnote,t[84]=m?.source,t[85]=f,t[86]=N):N=t[86];let Q;return t[87]!==p||t[88]!==Ct||t[89]!==yt||t[90]!==l||t[91]!==O||t[92]!==At||t[93]!==dt||t[94]!==oe||t[95]!==T||t[96]!==pt||t[97]!==$||t[98]!==F||t[99]!==V||t[100]!==N||t[101]!==It||t[102]!==f?(Q=i.jsxRuntimeExports.jsxs(De.GraphContainer,{className:T,style:pt,id:yt,ref:K,"aria-label":p,backgroundColor:Ct,theme:It,language:O,minHeight:At,width:f,height:l,relativeHeight:oe,padding:dt,children:[$,F,V,N]}),t[87]=p,t[88]=Ct,t[89]=yt,t[90]=l,t[91]=O,t[92]=At,t[93]=dt,t[94]=oe,t[95]=T,t[96]=pt,t[97]=$,t[98]=F,t[99]=V,t[100]=N,t[101]=It,t[102]=f,t[103]=Q):Q=t[103],Q}function vi(n){return n!==void 0}function ji(n){return n!==void 0}function wi(n){return n.data}function Ri(n){return n!==void 0}function Ei(n){return n.data}exports.LineChartWithConfidenceInterval=gi;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-CHPV5EwG-6v2a2njQ.cjs"),C=require("react"),R=require("./parse-xYI9yrvL.cjs"),Se=require("./simple-statistics-xm8c0LQQ.cjs"),Te=require("./index-Cno4Q0YE.cjs"),Oe=require("./numberFormattingFunction-02t-wJta.cjs"),$e=require("./Tooltip-BLa2EfMs.cjs"),G=require("./checkIfNullOrUndefined-BCW3Y1ML.cjs"),Ne=require("./customArea-B1LWQBmM.cjs"),Fe=require("./AxisTitle-DV4n0RxE.cjs"),We=require("./Axis-Jt_tmhxS.cjs"),He=require("./ReferenceLine-M9aP3dj-.cjs"),Ge=require("./RegressionLine-Ci-Dh0w0.cjs"),Pe=require("./YTicksAndGridLines-UzVC5eBM.cjs"),Ye=require("./index-D69M6klB.cjs"),Ue=require("./time-CkcKbhwe.cjs"),Xe=require("./linear-CgUCbw9F.cjs"),Ae=require("./line-DaEMhXmx.cjs"),be=require("./step-BZ3C8QFW.cjs"),Be=require("./area-C1gxfNGD.cjs"),ze=require("./select-Bnfk0lJx.cjs"),A=require("./proxy-C4-uo6nS.cjs"),Je=require("./init-DU0ybBc_.cjs"),Ke=require("./pointer-Dkq5NV1q.cjs"),Qe=require("./use-in-view-C3o_ntMv.cjs"),Ze=require("./GraphFooter.cjs"),_e=require("./GraphHeader.cjs"),Le=require("./Colors.cjs"),ti=require("./ColorLegend.cjs"),ei=require("./EmptyState-N1eHt3vq.cjs"),De=require("./GraphContainer-B1EDxJ0S.cjs"),ii=require("./getNoOfTicks-C_1CFXv_.cjs");function ni(n){const t=i.compilerRuntimeExports.c(102),{data:h,width:_,height:Ft,lineColor:b,suffix:S,prefix:M,dateFormat:l,highlightAreaSettings:f,showValues:Wt,noOfXTicks:he,rightMargin:Ht,leftMargin:D,topMargin:Gt,bottomMargin:dt,tooltip:tt,onSeriesMouseOver:Pt,refValues:ie,minValue:ne,maxValue:ht,animate:o,rtl:ft,strokeWidth:et,showDots:oe,annotations:se,customHighlightAreaSettings:yt,regressionLine:gt,showIntervalDots:ae,showIntervalValues:fe,intervalLineStrokeWidth:Yt,intervalLineColors:E,intervalAreaColor:Ut,intervalAreaOpacity:Xt,yAxisTitle:vt,noOfYTicks:ye,minDate:re,maxDate:le,curveType:jt,styles:y,classNames:g,precision:q,customLayers:P}=n,wt=C.useRef(null);let Y;t[0]!==o.amount||t[1]!==o.once?(Y={once:o.once,amount:o.amount},t[0]=o.amount,t[1]=o.once,t[2]=Y):Y=t[2];const c=Qe.useInView(wt,Y),[p,ce]=C.useState(!1);let Rt,it;t[3]!==o.duration||t[4]!==p||t[5]!==c?(Rt=()=>{if(c&&!p){const e=setTimeout(()=>{ce(!0)},(o.duration+.5)*1e3);return()=>clearTimeout(e)}},it=[c,p,o.duration],t[3]=o.duration,t[4]=p,t[5]=c,t[6]=Rt,t[7]=it):(Rt=t[6],it=t[7]),C.useEffect(Rt,it);const nt=jt==="linear"?Ae.curveLinear:jt==="step"?be.curveStep:jt==="stepAfter"?be.stepAfter:jt==="stepBefore"?be.stepBefore:be.monotoneX,[L,Et]=C.useState(void 0),[U,ue]=C.useState(void 0),[m,x]=C.useState(void 0),Bt=vt?D+30:D;let X;t[8]!==dt||t[9]!==Ht||t[10]!==Bt||t[11]!==Gt?(X={top:Gt,bottom:dt,left:Bt,right:Ht},t[8]=dt,t[9]=Ht,t[10]=Bt,t[11]=Gt,t[12]=X):X=t[12];const j=X,ot=C.useRef(null);let st;t[13]!==l?(st=e=>({date:R.parse(`${e.date}`,l,new Date),y:e.y,yMin:G.checkIfNullOrUndefined(e.yMin)?e.y:e.yMin,yMax:G.checkIfNullOrUndefined(e.yMax)?e.y:e.yMax,data:e.data}),t[13]=l,t[14]=st):st=t[14];const a=Te.orderBy(h.filter(yi).map(st),["date"],["asc"]);let at;if(t[15]!==l||t[16]!==f){let e;t[18]!==l?(e=d=>({...d,coordinates:[d.coordinates[0]===null?null:R.parse(`${d.coordinates[0]}`,l,new Date),d.coordinates[1]===null?null:R.parse(`${d.coordinates[1]}`,l,new Date)]}),t[18]=l,t[19]=e):e=t[19],at=f.map(e),t[15]=l,t[16]=f,t[17]=at}else at=t[17];const Ct=at;let rt;if(t[20]!==yt||t[21]!==l){let e;t[23]!==l?(e=d=>({...d,coordinates:d.coordinates.map((Z,ee)=>ee%2===0?R.parse(`${Z}`,l,new Date):Z)}),t[23]=l,t[24]=e):e=t[24],rt=yt.map(e),t[20]=yt,t[21]=l,t[22]=rt}else rt=t[22];const xe=rt,u=_-j.left-j.right,v=Ft-j.top-j.bottom,zt=re?R.parse(`${re}`,l,new Date):a[0].date,me=le?R.parse(`${le}`,l,new Date):a[a.length-1].date,w=G.checkIfNullOrUndefined(ne)?Math.min(...a.map(fi))?Math.min(...a.map(hi))>0?0:Math.min(...a.map(di)):0:ne,B=Math.max(...a.map(pi))?Math.max(...a.map(mi)):0,s=Ue.time().domain([zt,me]).range([0,u]);let lt;t[25]!==B||t[26]!==ht?(lt=G.checkIfNullOrUndefined(ht)?B>0?B:0:ht,t[25]=B,t[26]=ht,t[27]=lt):lt=t[27];const r=Xe.linear().domain([w,lt]).range([v,0]).nice(),Jt=Ae.line().x(e=>s(e.date)).y(e=>r(e.y)).curve(nt),Mt=Ae.line().x(e=>s(e.date)).y(e=>r(e.yMin)).curve(nt),Kt=Ae.line().x(e=>s(e.date)).y(e=>r(e.yMax)).curve(nt),Qt=Be.area().x(e=>s(e.date)).y0(e=>r(e.yMin)).y1(e=>r(e.yMax)).curve(nt),Zt=r.ticks(ye),_t=s.ticks(he);C.useEffect(()=>{const e=Z=>{const ee=a[Je.bisectCenter(a.map(xi),s.invert(Ke.pointer(Z)[0]),0)];Et(ee||a[a.length-1]),Pt?.(ee||a[a.length-1]),x(Z.clientY),ue(Z.clientX)},d=()=>{Et(void 0),ue(void 0),x(void 0),Pt?.(void 0)};ze.select(ot.current).on("mousemove",e).on("mouseout",d)},[s,a,Pt]);const te=Se.linearRegression(a.filter(ui).map(e=>[s(e.date),r(e.y)])),Ot=Se.linearRegressionLine(te);let O;t[28]!==o||t[29]!==v||t[30]!==u||t[31]!==Ct||t[32]!==c||t[33]!==s?(O=i.jsxRuntimeExports.jsx(Ye.HighlightArea,{areaSettings:Ct,width:u,height:v,scale:s,animate:o,isInView:c}),t[28]=o,t[29]=v,t[30]=u,t[31]=Ct,t[32]=c,t[33]=s,t[34]=O):O=t[34];const At=y?.yAxis?.gridLines,bt=y?.yAxis?.labels;let ct;t[35]!==At||t[36]!==bt?(ct={gridLines:At,labels:bt},t[35]=At,t[36]=bt,t[37]=ct):ct=t[37];const ut=g?.yAxis?.gridLines,Lt=g?.yAxis?.labels;let z;t[38]!==ut||t[39]!==Lt?(z={gridLines:ut,labels:Lt},t[38]=ut,t[39]=Lt,t[40]=z):z=t[40];const kt=r(w<0?0:w),It=r(w<0?0:w),Vt=0-D,Nt=u+j.right,St=w<0?0:w;let k;t[41]!==q||t[42]!==M||t[43]!==S||t[44]!==St?(k=Oe.numberFormattingFunction(St,"NA",q,M,S),t[41]=q,t[42]=M,t[43]=S,t[44]=St,t[45]=k):k=t[45];const Dt=0-D,J=r(w<0?0:w),pe=B<0?"1em":-5;let I;t[46]!==Dt||t[47]!==J||t[48]!==pe?(I={x:Dt,y:J,dx:0,dy:pe},t[46]=Dt,t[47]=J,t[48]=pe,t[49]=I):I=t[49];const de=g?.xAxis?.axis,qt=g?.yAxis?.labels;let K;t[50]!==de||t[51]!==qt?(K={axis:de,label:qt},t[50]=de,t[51]=qt,t[52]=K):K=t[52];const xt=y?.xAxis?.axis,mt=y?.yAxis?.labels;let T;t[53]!==xt||t[54]!==mt?(T={axis:xt,label:mt},t[53]=xt,t[54]=mt,t[55]=T):T=t[55];let pt;t[56]!==kt||t[57]!==It||t[58]!==Vt||t[59]!==Nt||t[60]!==k||t[61]!==I||t[62]!==K||t[63]!==T?(pt=i.jsxRuntimeExports.jsx(We.Axis,{y1:kt,y2:It,x1:Vt,x2:Nt,label:k,labelPos:I,classNames:K,styles:T}),t[56]=kt,t[57]=It,t[58]=Vt,t[59]=Nt,t[60]=k,t[61]=I,t[62]=K,t[63]=T,t[64]=pt):pt=t[64];const $=0-D+15,F=v/2,W=y?.yAxis?.title,H=g?.yAxis?.title;let V;t[65]!==$||t[66]!==F||t[67]!==W||t[68]!==H||t[69]!==vt?(V=i.jsxRuntimeExports.jsx(Fe.AxisTitle,{x:$,y:F,style:W,className:H,text:vt,rotate90:!0}),t[65]=$,t[66]=F,t[67]=W,t[68]=H,t[69]=vt,t[70]=V):V=t[70];let N;t[71]!==P?(N=P.filter(ri).map(ai),t[71]=P,t[72]=N):N=t[72];let Q;t[73]!==Ut?(Q={fill:Ut},t[73]=Ut,t[74]=Q):Q=t[74];let Tt;t[75]!==o.duration?(Tt={opacity:0,transition:{duration:o.duration}},t[75]=o.duration,t[76]=Tt):Tt=t[76];let $t;t[77]!==b||t[78]!==et?($t={stroke:b,fill:"none",strokeWidth:et},t[77]=b,t[78]=et,t[79]=$t):$t=t[79];let ge;t[80]!==o.duration?(ge={opacity:0,transition:{duration:o.duration}},t[80]=o.duration,t[81]=ge):ge=t[81];const ke=a.map((e,d)=>i.jsxRuntimeExports.jsx(A.motion.g,{children:G.checkIfNullOrUndefined(e.y)?null:i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[oe?i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,style:{fill:b},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,cx:s(e.date),cy:r(e.y)},whileInView:{opacity:1,transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.y)}},initial:"initial",animate:c?"whileInView":"initial"}):null,ae?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[0],cx:s(e.date),cy:r(e.yMin)},whileInView:{opacity:1,transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.yMin),fill:E[0]}},initial:"initial",animate:c?"whileInView":"initial"}),i.jsxRuntimeExports.jsx(A.motion.circle,{r:u/a.length<5?0:u/a.length<20?2:4,exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[1],cx:s(e.date),cy:r(e.yMax)},whileInView:{opacity:1,fill:E[1],transition:{duration:p?o.duration:.5,delay:p?0:o.duration},cx:s(e.date),cy:r(e.yMax)}},initial:"initial",animate:c?"whileInView":"initial"})]}):null,Wt?i.jsxRuntimeExports.jsx(A.motion.text,{dy:-8,style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("graph-value text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:b,x:s(e.date),y:r(e.y)},whileInView:{opacity:1,x:s(e.date),fill:b,y:r(e.y),transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.y,"NA",q,M,S)}):null,fe?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.text,{dy:"1em",style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[0],x:s(e.date),y:r(e.yMin)},whileInView:{opacity:1,x:s(e.date),y:r(e.yMin),fill:E[0],transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.yMin,"NA",q,M,S)}),i.jsxRuntimeExports.jsx(A.motion.text,{dy:-8,style:{textAnchor:"middle",...y?.graphObjectValues||{}},className:i.mo("text-xs font-bold",g?.graphObjectValues),exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{opacity:0,fill:E[1],x:s(e.date),y:r(e.yMax)},whileInView:{opacity:1,fill:E[1],x:s(e.date),y:r(e.yMax),transition:{duration:p?o.duration:.5,delay:p?0:o.duration}}},initial:"initial",animate:c?"whileInView":"initial",children:Oe.numberFormattingFunction(e.yMax,"NA",q,M,S)})]}):null]})},d));let ve;t[82]!==ke?(ve=i.jsxRuntimeExports.jsx("g",{children:ke}),t[82]=ke,t[83]=ve):ve=t[83];const Ie=se.map((e,d)=>{const Z=Ne.getLineEndPoint({x:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),y:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0)-8:0+(e.yOffset||0)-8},{x:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date)):0,y:e.yCoordinate?r(e.yCoordinate):0},G.checkIfNullOrUndefined(e.connectorRadius)?3.5:e.connectorRadius),ee=e.showConnector?{y1:Z.y,x1:Z.x,y2:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0):0+(e.yOffset||0),x2:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),cy:e.yCoordinate?r(e.yCoordinate):0,cx:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date)):0,circleRadius:G.checkIfNullOrUndefined(e.connectorRadius)?3.5:e.connectorRadius,strokeWidth:e.showConnector===!0?2:Math.min(e.showConnector||0,1)}:void 0,qe={y:e.yCoordinate?r(e.yCoordinate)+(e.yOffset||0)-8:0+(e.yOffset||0)-8,x:ft?0:e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0),width:ft?e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0):u+j.right-(e.xCoordinate?s(R.parse(`${e.xCoordinate}`,l,new Date))+(e.xOffset||0):0+(e.xOffset||0)),maxWidth:e.maxWidth,fontWeight:e.fontWeight,align:e.align};return i.jsxRuntimeExports.jsx(Ne.Annotation,{color:e.color,connectorsSettings:ee,labelSettings:qe,text:e.text,classNames:e.classNames,styles:e.styles,animate:o,isInView:c},d)});let je;t[84]!==Ie?(je=i.jsxRuntimeExports.jsx("g",{children:Ie}),t[84]=Ie,t[85]=je):je=t[85];const Ve=gt?i.jsxRuntimeExports.jsx(Ge.RegressionLine,{x1:0,x2:u,y1:Ot(0),y2:Ot(u),graphHeight:v,graphWidth:u,className:g?.regLine,style:y?.regLine,color:typeof gt=="string"?gt:void 0,animate:o,isInView:c}):null;let we;t[86]!==Ve?(we=i.jsxRuntimeExports.jsx("g",{children:Ve}),t[86]=Ve,t[87]=we):we=t[87];let Re;t[88]!==P?(Re=P.filter(si).map(oi),t[88]=P,t[89]=Re):Re=t[89];let Ee;t[90]===Symbol.for("react.memo_cache_sentinel")?(Ee={fill:"none",pointerEvents:"all"},t[90]=Ee):Ee=t[90];let Ce;t[91]!==ot||t[92]!==v||t[93]!==u?(Ce=i.jsxRuntimeExports.jsx("rect",{ref:ot,style:Ee,width:u,height:v}),t[91]=ot,t[92]=v,t[93]=u,t[94]=Ce):Ce=t[94];let Me;return t[95]!==g?.tooltip||t[96]!==U||t[97]!==m||t[98]!==L||t[99]!==y?.tooltip||t[100]!==tt?(Me=L&&tt&&U&&m?i.jsxRuntimeExports.jsx($e.Tooltip,{data:L,body:tt,xPos:U,yPos:m,backgroundStyle:y?.tooltip,className:g?.tooltip}):null,t[95]=g?.tooltip,t[96]=U,t[97]=m,t[98]=L,t[99]=y?.tooltip,t[100]=tt,t[101]=Me):Me=t[101],i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.svg,{width:`${_}px`,height:`${Ft}px`,viewBox:`0 0 ${_} ${Ft}`,direction:"ltr",ref:wt,children:i.jsxRuntimeExports.jsxs("g",{transform:`translate(${j.left},${j.top})`,children:[O,i.jsxRuntimeExports.jsx(Ne.CustomArea,{areaSettings:xe,scaleX:s,scaleY:r,animate:o,isInView:c}),i.jsxRuntimeExports.jsxs("g",{children:[i.jsxRuntimeExports.jsx(Pe.YTicksAndGridLines,{values:Zt.filter(ci),y:Zt.filter(li).map(e=>r(e)),x1:0-D,x2:u+j.right,styles:ct,classNames:z,suffix:S,prefix:M,labelType:"secondary",showGridLines:!0,labelPos:"vertical",precision:q}),pt,V]}),i.jsxRuntimeExports.jsx("g",{children:_t.map((e,d)=>i.jsxRuntimeExports.jsx("g",{children:i.jsxRuntimeExports.jsx("text",{y:v,x:s(e),style:{textAnchor:"middle"},className:"fill-primary-gray-700 dark:fill-primary-gray-300 xs:max-[360px]:hidden text-[9px] md:text-[10px] lg:text-xs",dy:15,children:R.format(e,l)})},d))}),N,i.jsxRuntimeExports.jsx(A.motion.path,{style:Q,exit:Tt,variants:{initial:{opacity:0,d:Qt(a)||""},whileInView:{opacity:Xt,d:Qt(a)||"",transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),Yt?i.jsxRuntimeExports.jsxs(i.jsxRuntimeExports.Fragment,{children:[i.jsxRuntimeExports.jsx(A.motion.path,{style:{stroke:E[0],fill:"none",strokeWidth:Yt},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{pathLength:0,d:Mt(a)||"",opacity:1},whileInView:{pathLength:1,d:Mt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),i.jsxRuntimeExports.jsx(A.motion.path,{style:{stroke:E[1],fill:"none",strokeWidth:Yt},exit:{opacity:0,transition:{duration:o.duration}},variants:{initial:{pathLength:0,d:Kt(a)||"",opacity:1},whileInView:{pathLength:1,d:Kt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"})]}):null,i.jsxRuntimeExports.jsx(A.motion.path,{style:$t,exit:ge,variants:{initial:{pathLength:0,d:Jt(a)||"",opacity:1},whileInView:{pathLength:1,d:Jt(a)||"",opacity:1,transition:{duration:o.duration}}},initial:"initial",animate:c?"whileInView":"initial"}),L?i.jsxRuntimeExports.jsx("line",{y1:0,y2:v,x1:s(L.date),x2:s(L.date),className:i.mo("undp-tick-line stroke-primary-gray-700 dark:stroke-primary-gray-100",g?.mouseOverLine),style:y?.mouseOverLine}):null,ve,ie?i.jsxRuntimeExports.jsx(i.jsxRuntimeExports.Fragment,{children:ie.map((e,d)=>i.jsxRuntimeExports.jsx(He.RefLineY,{text:e.text,color:e.color,y:r(e.value),x1:0-D,x2:u+j.right,classNames:e.classNames,styles:e.styles,animate:o,isInView:c},d))}):null,je,we,Re,Ce]})}),Me]})}function oi(n){return n.layer}function si(n){return n.position==="after"}function ai(n){return n.layer}function ri(n){return n.position==="before"}function li(n){return n!==0}function ci(n){return n!==0}function ui(n){return!G.checkIfNullOrUndefined(n.date)&&!G.checkIfNullOrUndefined(n.y)}function xi(n){return n.date}function mi(n){return Math.max(n.y,n.yMax,n.yMin)}function pi(n){return Math.max(n.y,n.yMax,n.yMin)}function di(n){return Math.min(n.y,n.yMax,n.yMin)}function hi(n){return Math.min(n.y,n.yMax,n.yMin)}function fi(n){return Math.min(n.y,n.yMax,n.yMin)}function yi(n){return!G.checkIfNullOrUndefined(n.y)}function gi(n){const t=i.compilerRuntimeExports.c(104),{data:h,graphTitle:_,suffix:Ft,sources:b,prefix:S,graphDescription:M,height:l,width:f,footNote:Wt,noOfXTicks:he,dateFormat:Ht,showValues:D,backgroundColor:Gt,padding:dt,lineColor:tt,leftMargin:Pt,rightMargin:ie,topMargin:ne,bottomMargin:ht,tooltip:o,refValues:ft,highlightAreaSettings:et,relativeHeight:oe,onSeriesMouseOver:se,graphID:yt,minValue:gt,maxValue:ae,regressionLine:fe,showIntervalDots:Yt,showIntervalValues:E,intervalLineStrokeWidth:Ut,intervalLineColors:Xt,intervalAreaColor:vt,intervalAreaOpacity:ye,graphDownload:re,dataDownload:le,animate:jt,language:y,minHeight:g,strokeWidth:q,showDots:P,annotations:wt,customHighlightAreaSettings:Y,theme:c,ariaLabel:p,yAxisTitle:ce,noOfYTicks:Rt,minDate:it,maxDate:nt,colorLegendTitle:L,colorLegendColors:Et,colorLegendDomain:U,curveType:ue,styles:m,classNames:x,precision:Bt,customLayers:X}=n,j=Ft===void 0?"":Ft,ot=S===void 0?"":S,st=he===void 0?10:he,a=Ht===void 0?"yyyy":Ht,at=D===void 0?!1:D,Ct=Gt===void 0?!1:Gt,rt=Pt===void 0?30:Pt,xe=ie===void 0?30:ie,u=ne===void 0?20:ne,v=ht===void 0?25:ht;let zt;t[0]!==ft?(zt=ft===void 0?[]:ft,t[0]=ft,t[1]=zt):zt=t[1];const me=zt;let w;t[2]!==et?(w=et===void 0?[]:et,t[2]=et,t[3]=w):w=t[3];const B=w,s=fe===void 0?!1:fe,lt=Yt===void 0?!1:Yt,r=E===void 0?!1:E,Jt=Ut===void 0?0:Ut;let Mt;t[4]!==Xt?(Mt=Xt===void 0?[Le.Colors.light.grays["gray-500"],Le.Colors.light.grays["gray-500"]]:Xt,t[4]=Xt,t[5]=Mt):Mt=t[5];const Kt=Mt,Qt=vt===void 0?Le.Colors.primaryColors["blue-100"]:vt,Zt=ye===void 0?.4:ye,_t=re===void 0?!1:re,te=le===void 0?!1:le,Ot=jt===void 0?!1:jt,O=y===void 0?"en":y,At=g===void 0?0:g,bt=q===void 0?2:q,ct=P===void 0?!0:P;let ut;t[6]!==wt?(ut=wt===void 0?[]:wt,t[6]=wt,t[7]=ut):ut=t[7];const Lt=ut;let z;t[8]!==Y?(z=Y===void 0?[]:Y,t[8]=Y,t[9]=z):z=t[9];const kt=z,It=c===void 0?"light":c,Vt=Rt===void 0?5:Rt,Nt=ue===void 0?"curve":ue,St=Bt===void 0?2:Bt;let k;t[10]!==X?(k=X===void 0?[]:X,t[10]=X,t[11]=k):k=t[11];const Dt=k,[J,pe]=C.useState(0),[I,de]=C.useState(0),qt=C.useRef(null),K=C.useRef(null);let xt,mt;t[12]===Symbol.for("react.memo_cache_sentinel")?(xt=()=>{const Tt=new ResizeObserver($t=>{pe($t[0].target.clientWidth||620),de($t[0].target.clientHeight||480)});return qt.current&&Tt.observe(qt.current),()=>Tt.disconnect()},mt=[],t[12]=xt,t[13]=mt):(xt=t[12],mt=t[13]),C.useEffect(xt,mt);const T=x?.graphContainer,pt=m?.graphContainer;let $;t[14]!==x?.description||t[15]!==x?.title||t[16]!==h||t[17]!==te||t[18]!==M||t[19]!==_t||t[20]!==_||t[21]!==m?.description||t[22]!==m?.title||t[23]!==f?($=_||M||_t||te?i.jsxRuntimeExports.jsx(_e.GraphHeader,{styles:{title:m?.title,description:m?.description},classNames:{title:x?.title,description:x?.description},graphTitle:_,graphDescription:M,width:f,graphDownload:_t?K:void 0,dataDownload:te?h.map(Ei).filter(Ri).length>0?h.map(wi).filter(ji):h.filter(vi):null}):null,t[14]=x?.description,t[15]=x?.title,t[16]=h,t[17]=te,t[18]=M,t[19]=_t,t[20]=_,t[21]=m?.description,t[22]=m?.title,t[23]=f,t[24]=$):$=t[24];let F;t[25]!==x?.colorLegend||t[26]!==Et||t[27]!==U||t[28]!==L||t[29]!==h.length||t[30]!==f?(F=Et&&U&&h.length>0?i.jsxRuntimeExports.jsx(ti.ColorLegend,{width:f,colorLegendTitle:L,colors:Et,colorDomain:U,showNAColor:!1,className:x?.colorLegend}):null,t[25]=x?.colorLegend,t[26]=Et,t[27]=U,t[28]=L,t[29]=h.length,t[30]=f,t[31]=F):F=t[31];let W;t[32]!==h.length?(W=h.length===0&&i.jsxRuntimeExports.jsx(ei.EmptyState,{}),t[32]=h.length,t[33]=W):W=t[33];let H;t[34]!==Ot||t[35]!==Lt||t[36]!==v||t[37]!==x||t[38]!==Nt||t[39]!==kt||t[40]!==Dt||t[41]!==h||t[42]!==a||t[43]!==B||t[44]!==Qt||t[45]!==Zt||t[46]!==Kt||t[47]!==Jt||t[48]!==O||t[49]!==rt||t[50]!==tt||t[51]!==nt||t[52]!==ae||t[53]!==it||t[54]!==gt||t[55]!==st||t[56]!==Vt||t[57]!==se||t[58]!==St||t[59]!==ot||t[60]!==me||t[61]!==s||t[62]!==xe||t[63]!==ct||t[64]!==lt||t[65]!==r||t[66]!==at||t[67]!==bt||t[68]!==m||t[69]!==j||t[70]!==I||t[71]!==J||t[72]!==o||t[73]!==u||t[74]!==ce?(H=J&&I&&h.length>0?i.jsxRuntimeExports.jsx(ni,{data:h,lineColor:tt||Le.Colors.primaryColors["blue-600"],width:J,height:I,suffix:j,prefix:ot,dateFormat:a,showValues:at,noOfXTicks:st??ii.getNoOfTicks(J),leftMargin:rt,rightMargin:xe,topMargin:u,bottomMargin:v,tooltip:o,highlightAreaSettings:B,onSeriesMouseOver:se,refValues:me,minValue:gt,maxValue:ae,animate:Ot===!0?{duration:.5,once:!0,amount:.5}:Ot||{duration:0,once:!0,amount:0},rtl:O==="he"||O==="ar",strokeWidth:bt,showDots:ct,annotations:Lt,customHighlightAreaSettings:kt,regressionLine:s,showIntervalDots:lt,showIntervalValues:r,intervalLineStrokeWidth:Jt,intervalLineColors:Kt,intervalAreaColor:Qt,intervalAreaOpacity:Zt,yAxisTitle:ce,noOfYTicks:Vt,minDate:it,maxDate:nt,curveType:Nt,styles:m,classNames:x,precision:St,customLayers:Dt}):null,t[34]=Ot,t[35]=Lt,t[36]=v,t[37]=x,t[38]=Nt,t[39]=kt,t[40]=Dt,t[41]=h,t[42]=a,t[43]=B,t[44]=Qt,t[45]=Zt,t[46]=Kt,t[47]=Jt,t[48]=O,t[49]=rt,t[50]=tt,t[51]=nt,t[52]=ae,t[53]=it,t[54]=gt,t[55]=st,t[56]=Vt,t[57]=se,t[58]=St,t[59]=ot,t[60]=me,t[61]=s,t[62]=xe,t[63]=ct,t[64]=lt,t[65]=r,t[66]=at,t[67]=bt,t[68]=m,t[69]=j,t[70]=I,t[71]=J,t[72]=o,t[73]=u,t[74]=ce,t[75]=H):H=t[75];let V;t[76]!==W||t[77]!==H?(V=i.jsxRuntimeExports.jsxs(De.GraphArea,{ref:qt,children:[W,H]}),t[76]=W,t[77]=H,t[78]=V):V=t[78];let N;t[79]!==x?.footnote||t[80]!==x?.source||t[81]!==Wt||t[82]!==b||t[83]!==m?.footnote||t[84]!==m?.source||t[85]!==f?(N=b||Wt?i.jsxRuntimeExports.jsx(Ze.GraphFooter,{styles:{footnote:m?.footnote,source:m?.source},classNames:{footnote:x?.footnote,source:x?.source},sources:b,footNote:Wt,width:f}):null,t[79]=x?.footnote,t[80]=x?.source,t[81]=Wt,t[82]=b,t[83]=m?.footnote,t[84]=m?.source,t[85]=f,t[86]=N):N=t[86];let Q;return t[87]!==p||t[88]!==Ct||t[89]!==yt||t[90]!==l||t[91]!==O||t[92]!==At||t[93]!==dt||t[94]!==oe||t[95]!==T||t[96]!==pt||t[97]!==$||t[98]!==F||t[99]!==V||t[100]!==N||t[101]!==It||t[102]!==f?(Q=i.jsxRuntimeExports.jsxs(De.GraphContainer,{className:T,style:pt,id:yt,ref:K,"aria-label":p,backgroundColor:Ct,theme:It,language:O,minHeight:At,width:f,height:l,relativeHeight:oe,padding:dt,children:[$,F,V,N]}),t[87]=p,t[88]=Ct,t[89]=yt,t[90]=l,t[91]=O,t[92]=At,t[93]=dt,t[94]=oe,t[95]=T,t[96]=pt,t[97]=$,t[98]=F,t[99]=V,t[100]=N,t[101]=It,t[102]=f,t[103]=Q):Q=t[103],Q}function vi(n){return n!==void 0}function ji(n){return n!==void 0}function wi(n){return n.data}function Ri(n){return n!==void 0}function Ei(n){return n.data}exports.LineChartWithConfidenceInterval=gi;
2
2
  //# sourceMappingURL=LineChartWithConfidenceInterval.cjs.map
@@ -27,7 +27,7 @@ import { GraphFooter as ci } from "./GraphFooter.js";
27
27
  import { GraphHeader as mi } from "./GraphHeader.js";
28
28
  import { Colors as Ve } from "./Colors.js";
29
29
  import { ColorLegend as fi } from "./ColorLegend.js";
30
- import { E as ui } from "./EmptyState-Pj-emXt5.js";
30
+ import { E as ui } from "./EmptyState-dScPFkLy.js";
31
31
  import { a as hi, G as yi } from "./GraphContainer-CF6ws3pd.js";
32
32
  import { g as pi } from "./getNoOfTicks-CpmRjcRF.js";
33
33
  function xi(i) {
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-6v2a2njQ.cjs"),w=require("./Typography-DrJ7IOdw.cjs"),y=require("./numberFormattingFunction-02t-wJta.cjs");function N(E){const e=t.compilerRuntimeExports.c(27),{colorLegendTitle:f,colorDomain:s,colors:b,width:h,className:p}=E;let l;e[0]!==p?(l=t.mo("flex gap-0 flex-wrap justify-center leading-0 pb-3",p),e[0]=p,e[1]=l):l=e[1];const g=h?`${h}px`:"none";let n;e[2]!==g?(n={maxWidth:g},e[2]=g,e[3]=n):n=e[3];let i;e[4]!==f?(i=f&&f!==""?t.jsxRuntimeExports.jsx(w._,{size:"sm",marginBottom:"2xs",className:"w-full text-center",children:f}):null,e[4]=f,e[5]=i):i=e[5];const j=`linear-gradient(90deg, ${b[0]} 0%, ${b[1]} 100%)`;let r;e[6]!==j?(r=t.jsxRuntimeExports.jsx("div",{className:"h-4 mb-1 w-full min-w-[360px]",style:{background:j}}),e[6]=j,e[7]=r):r=e[7];let o;e[8]!==s[0]?(o=y.numberFormattingFunction(s[0],"NA",2,"",""),e[8]=s[0],e[9]=o):o=e[9];let m;e[10]!==o?(m=t.jsxRuntimeExports.jsx(w._,{marginBottom:"none",size:"sm",children:o}),e[10]=o,e[11]=m):m=e[11];let a;e[12]!==s[1]?(a=y.numberFormattingFunction(s[1],"NA",2,"",""),e[12]=s[1],e[13]=a):a=e[13];let x;e[14]!==a?(x=t.jsxRuntimeExports.jsx(w._,{marginBottom:"none",size:"sm",children:a}),e[14]=a,e[15]=x):x=e[15];let c;e[16]!==m||e[17]!==x?(c=t.jsxRuntimeExports.jsxs("div",{className:"flex justify-between w-full min-w-[360px]",children:[m,x]}),e[16]=m,e[17]=x,e[18]=c):c=e[18];let u;e[19]!==c||e[20]!==r?(u=t.jsxRuntimeExports.jsxs("div",{className:"flex gap-0 flex-wrap justify-center w-full min-w-[360px] leading-0",children:[r,c]}),e[19]=c,e[20]=r,e[21]=u):u=e[21];let d;return e[22]!==l||e[23]!==u||e[24]!==n||e[25]!==i?(d=t.jsxRuntimeExports.jsxs("div",{className:l,style:n,"aria-label":"Color legend",children:[i,u]}),e[22]=l,e[23]=u,e[24]=n,e[25]=i,e[26]=d):d=e[26],d}exports.LinearColorLegend=N;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./index-CHPV5EwG-6v2a2njQ.cjs"),w=require("./Typography-Cc_iHQB-.cjs"),y=require("./numberFormattingFunction-02t-wJta.cjs");function N(E){const e=t.compilerRuntimeExports.c(27),{colorLegendTitle:f,colorDomain:s,colors:b,width:h,className:p}=E;let l;e[0]!==p?(l=t.mo("flex gap-0 flex-wrap justify-center leading-0 pb-3",p),e[0]=p,e[1]=l):l=e[1];const g=h?`${h}px`:"none";let n;e[2]!==g?(n={maxWidth:g},e[2]=g,e[3]=n):n=e[3];let i;e[4]!==f?(i=f&&f!==""?t.jsxRuntimeExports.jsx(w._,{size:"sm",marginBottom:"2xs",className:"w-full text-center",children:f}):null,e[4]=f,e[5]=i):i=e[5];const j=`linear-gradient(90deg, ${b[0]} 0%, ${b[1]} 100%)`;let r;e[6]!==j?(r=t.jsxRuntimeExports.jsx("div",{className:"h-4 mb-1 w-full min-w-[360px]",style:{background:j}}),e[6]=j,e[7]=r):r=e[7];let o;e[8]!==s[0]?(o=y.numberFormattingFunction(s[0],"NA",2,"",""),e[8]=s[0],e[9]=o):o=e[9];let m;e[10]!==o?(m=t.jsxRuntimeExports.jsx(w._,{marginBottom:"none",size:"sm",children:o}),e[10]=o,e[11]=m):m=e[11];let a;e[12]!==s[1]?(a=y.numberFormattingFunction(s[1],"NA",2,"",""),e[12]=s[1],e[13]=a):a=e[13];let x;e[14]!==a?(x=t.jsxRuntimeExports.jsx(w._,{marginBottom:"none",size:"sm",children:a}),e[14]=a,e[15]=x):x=e[15];let c;e[16]!==m||e[17]!==x?(c=t.jsxRuntimeExports.jsxs("div",{className:"flex justify-between w-full min-w-[360px]",children:[m,x]}),e[16]=m,e[17]=x,e[18]=c):c=e[18];let u;e[19]!==c||e[20]!==r?(u=t.jsxRuntimeExports.jsxs("div",{className:"flex gap-0 flex-wrap justify-center w-full min-w-[360px] leading-0",children:[r,c]}),e[19]=c,e[20]=r,e[21]=u):u=e[21];let d;return e[22]!==l||e[23]!==u||e[24]!==n||e[25]!==i?(d=t.jsxRuntimeExports.jsxs("div",{className:l,style:n,"aria-label":"Color legend",children:[i,u]}),e[22]=l,e[23]=u,e[24]=n,e[25]=i,e[26]=d):d=e[26],d}exports.LinearColorLegend=N;
2
2
  //# sourceMappingURL=LinearColorLegend.cjs.map
@@ -1,5 +1,5 @@
1
1
  import { c as v, m as $, j as l } from "./index-CHPV5EwG-DecW7_qr.js";
2
- import { _ as w } from "./Typography-iR8PEgdt.js";
2
+ import { _ as w } from "./Typography-CdMGooqp.js";
3
3
  import { n as b } from "./numberFormattingFunction-14YCbkN2.js";
4
4
  function A(y) {
5
5
  const e = v.c(27), {