@arcgis/charts-components 5.2.0-next.26 → 5.2.0-next.27

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 (100) hide show
  1. package/dist/cdn/{VWW6TY7N.js → 2CCG5VRK.js} +1 -1
  2. package/dist/cdn/{IP3FZZNM.js → 2VERKODU.js} +1 -1
  3. package/dist/cdn/{N5AW3HBF.js → 3FDSEXHU.js} +1 -1
  4. package/dist/cdn/{4YRCWE6Z.js → 3HT2XHTE.js} +1 -1
  5. package/dist/cdn/{UB4O3XGF.js → 3M2I2DRI.js} +1 -1
  6. package/dist/cdn/{5UX2FYTM.js → 3QFCHMXP.js} +1 -1
  7. package/dist/cdn/4UG5VYOC.js +2 -0
  8. package/dist/cdn/{ZB5KGMQ6.js → 4X7O5PV4.js} +1 -1
  9. package/dist/cdn/{6Y6EK76O.js → 525WSDKI.js} +1 -1
  10. package/dist/cdn/{TSQOEJB4.js → 54F7CW76.js} +1 -1
  11. package/dist/cdn/{2B3QBXNI.js → 54UV746F.js} +1 -1
  12. package/dist/cdn/{OO5SFCWJ.js → 5LVCC5LO.js} +1 -1
  13. package/dist/cdn/{ICJALFR4.js → 6E2WAXRT.js} +1 -1
  14. package/dist/cdn/{D46R6YHX.js → 6EX4GDM3.js} +1 -1
  15. package/dist/cdn/{3BS7VF2U.js → 6N4SYUQV.js} +1 -1
  16. package/dist/cdn/{WY3UGKLF.js → 6OC4X4GP.js} +1 -1
  17. package/dist/cdn/6WZLNZJI.js +2 -0
  18. package/dist/cdn/{NJAGOS7G.js → 7UMBIDWG.js} +1 -1
  19. package/dist/cdn/{GW6GNNLA.js → 7ZQHAWKS.js} +1 -1
  20. package/dist/cdn/{XKJN3WVL.js → A3DHDZLR.js} +1 -1
  21. package/dist/cdn/{GZLTMREM.js → ATQN27OC.js} +1 -1
  22. package/dist/cdn/BFVFX476.js +3 -0
  23. package/dist/cdn/{DE2LP6LN.js → BRG2PBG4.js} +1 -1
  24. package/dist/cdn/{IUMYBJDG.js → CEBE6KZ5.js} +1 -1
  25. package/dist/cdn/{WXWLMWG5.js → CTTLJGLV.js} +1 -1
  26. package/dist/cdn/{HK3P3FUS.js → D2LXXBP5.js} +1 -1
  27. package/dist/cdn/{GSYV5MTU.js → DEN7277X.js} +1 -1
  28. package/dist/cdn/{5W76WCRM.js → DINELIBX.js} +1 -1
  29. package/dist/cdn/{FFE3EGXQ.js → DL77MIWY.js} +1 -1
  30. package/dist/cdn/{5JREGZML.js → E4OZ432W.js} +1 -1
  31. package/dist/cdn/{ZPFHE4XY.js → EA7AXGJI.js} +1 -1
  32. package/dist/cdn/{XWDLT2E4.js → EJEUMMWZ.js} +1 -1
  33. package/dist/cdn/{LSF6ITTC.js → F5NJPXUK.js} +1 -1
  34. package/dist/cdn/{TS6MWMCQ.js → FAOLLBXF.js} +1 -1
  35. package/dist/cdn/{UFI4PRSB.js → FSJ6RT4T.js} +1 -1
  36. package/dist/cdn/{7LI5APDL.js → FVGXWZBY.js} +1 -1
  37. package/dist/cdn/{XKHA7K4P.js → H4VTKKBN.js} +1 -1
  38. package/dist/cdn/{TG4EXCPF.js → HFCAMEBX.js} +1 -1
  39. package/dist/cdn/{N3FUI2RC.js → HOZ4AHQR.js} +1 -1
  40. package/dist/cdn/{IPECBZP3.js → HWUT7IFD.js} +1 -1
  41. package/dist/cdn/{AYNWMLFD.js → HYDDSP4M.js} +1 -1
  42. package/dist/cdn/{X4LAYI76.js → I4CGHGFK.js} +1 -1
  43. package/dist/cdn/{D6GG2ADV.js → I4NVKM3H.js} +1 -1
  44. package/dist/cdn/{ASEWMED3.js → ICFXSFV6.js} +1 -1
  45. package/dist/cdn/{RSYMKZMX.js → JAJUMMUL.js} +1 -1
  46. package/dist/cdn/{2ASYBTGM.js → JIHUDUXV.js} +1 -1
  47. package/dist/cdn/{VD3DRJBH.js → JPNGKMXS.js} +1 -1
  48. package/dist/cdn/{4XIBUPM6.js → K2H47DLO.js} +1 -1
  49. package/dist/cdn/{4RJT43K4.js → K473JQIX.js} +1 -1
  50. package/dist/cdn/{N6IOWWIK.js → LLICYFCD.js} +1 -1
  51. package/dist/cdn/{Y5GMGU4M.js → MMPHPV2C.js} +1 -1
  52. package/dist/cdn/{K7VEKFCK.js → MP4N4SFB.js} +1 -1
  53. package/dist/cdn/{BMC75GCV.js → ODTCEPEL.js} +1 -1
  54. package/dist/cdn/{L6SM2ORZ.js → OOVQ6IVC.js} +1 -1
  55. package/dist/cdn/{Y7HYSSRW.js → OPMJTZOV.js} +1 -1
  56. package/dist/cdn/{DKMTGCWH.js → OZEARYZA.js} +1 -1
  57. package/dist/cdn/{SUTVT5OC.js → PA5GXXDY.js} +1 -1
  58. package/dist/cdn/{2A24ACPF.js → PHAOZ7SV.js} +1 -1
  59. package/dist/cdn/{WJLUWK7Z.js → POPYMWVR.js} +1 -1
  60. package/dist/cdn/{AZZIMLGE.js → Q5VREFP6.js} +1 -1
  61. package/dist/cdn/{4AF64XYR.js → QGJNZGQX.js} +1 -1
  62. package/dist/cdn/{TNKGWBUO.js → R4F7L2HV.js} +1 -1
  63. package/dist/cdn/{ECG7HC37.js → RFU52ORA.js} +1 -1
  64. package/dist/cdn/{6ODWWOUP.js → RKZ2IOOP.js} +1 -1
  65. package/dist/cdn/{MUG3AZLX.js → RMF3UYFS.js} +1 -1
  66. package/dist/cdn/{HPEG72LB.js → S44GNLAE.js} +1 -1
  67. package/dist/cdn/{75XWLYW5.js → S6MDSIET.js} +1 -1
  68. package/dist/cdn/SBP4RBXK.js +4 -0
  69. package/dist/cdn/{662GFATG.js → SZ3VH4UZ.js} +1 -1
  70. package/dist/cdn/{IHJWEEOX.js → TR4ULKH5.js} +1 -1
  71. package/dist/cdn/{KBUBJ24X.js → TYJZR25X.js} +1 -1
  72. package/dist/cdn/{VHY7DPE3.js → U35HGES6.js} +1 -1
  73. package/dist/cdn/{N4IFMTPA.js → UU2LYQUI.js} +1 -1
  74. package/dist/cdn/{LSKFMUX4.js → VQFCYPDR.js} +1 -1
  75. package/dist/cdn/{MLD566HE.js → VRF5VORO.js} +19 -19
  76. package/dist/cdn/{4N3NVAA2.js → WF76CIN2.js} +1 -1
  77. package/dist/cdn/{BUUTWPEP.js → WINZ53K3.js} +1 -1
  78. package/dist/cdn/{ADJHTT4M.js → YFYTXRLW.js} +1 -1
  79. package/dist/cdn/{N4EH5HUB.js → ZO27SWFU.js} +1 -1
  80. package/dist/cdn/index.js +1 -1
  81. package/dist/cdn/model/shared/setup-utils.js +1 -1
  82. package/dist/chunks/heat-chart-model.js +46 -26
  83. package/dist/chunks/index2.js +3 -2
  84. package/dist/chunks/model-with-y-guides.js +6 -6
  85. package/dist/chunks/serial-chart-data.js +63 -62
  86. package/dist/chunks/serial-chart-model.js +107 -92
  87. package/dist/chunks/web-component-utils.js +414 -384
  88. package/dist/components/arcgis-chart/customElement.js +1927 -1923
  89. package/dist/docs/api.json +1 -1
  90. package/dist/docs/docs.json +1 -1
  91. package/dist/docs/web-types.json +1 -1
  92. package/dist/model/heat-chart-model/heat-chart-model.d.ts +22 -0
  93. package/dist/model/mixins/model-with-multi-axes.d.ts +22 -22
  94. package/dist/model/serial-chart-model/serial-chart-model.d.ts +15 -0
  95. package/dist/utils/data/index.d.ts +1 -1
  96. package/package.json +3 -3
  97. package/dist/cdn/2KCA3K57.js +0 -4
  98. package/dist/cdn/5NVUOG5B.js +0 -2
  99. package/dist/cdn/HFSVUO2D.js +0 -3
  100. package/dist/cdn/IK5VZ54O.js +0 -2
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import g from"./XKHA7K4P.js";import e from"./N3FUI2RC.js";import d from"./6ODWWOUP.js";import{c as M}from"./Y7HBWU3M.js";import b from"./D46R6YHX.js";import a from"./HFSVUO2D.js";import{n as B}from"./3TBK72EK.js";import{L as R,fa as _,wa as K}from"./PAIRUVLU.js";import{f as G}from"./KX7KGXKQ.js";import{d as $,g as j,k,o as z}from"./SP2IPHWF.js";import{d as y,e as c}from"./QP5UAIC6.js";import{a as E,b as f,h as F,v as p}from"./547RDEMV.js";export default $arcgis.t(([{substitute:A},{q:I,r:N,rb:O},{a:L,b:h},{a:U},{b:x},{g:Y}])=>{function V(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=e!==void 0?q({config:t,layerInfo:e,commonStrings:i,mode:o}):"",l=U(t),g=x(t);return a===l||g}function w(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=e!==void 0?h({config:t,layerInfo:e,commonStrings:i,numericFields:S(t),aggregationType:C(t,o)}):"",l=M(1,t),g=x(t);return a===l||g}var P=r=>r.series?.[0]?.x??"";function X(r,t){let e=r.series?.[0];return[`${t===c.Category?e.y:N} ${F.Descending}`]}var H=(r,t)=>{let e=y.valueDesc,o=r.orderOptions?.data?.orderType??X(r,t),i=r.orderOptions?.data&&"orderBy"in r.orderOptions.data?r.orderOptions.data.orderBy:F.Descending;return o===p.Category&&Array.isArray(i)?e=y.customSort:o===p.Category?i===F.Ascending?e=y.labelAsc:e=y.labelDesc:i===F.Ascending?e=y.valueAsc:e=y.valueDesc,e},S=$(r=>{let t=[];return t=r.series?.[0]?.query?.outStatistics?.map(e=>e.onStatisticField)??[r.series?.[0]?.y??""],t.filter(e=>e!=="")},r=>r.series),C=(r,t)=>{let e=S(r),o;return t===c.Fields&&e.length===0?o=f.Sum:o=r.series?.[0]?.query?.outStatistics?.[0]?.statisticType??f.NoAggregation,o};function J(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=O(e?.layer).idField,l=_(i,a),g=P(t),d=t.series[0]?.dataLabels,s={...l,x:o===c.Category?g:I,slices:t.series?.[0]?.slices,dataLabels:{...l.dataLabels,type:l.dataLabels?.type??E.Text,content:{...l.dataLabels?.content,...d?.content,type:G.TS},visible:d?.visible??!1},innerRadiusSize:t.series?.[0]?.innerRadius,sliceGrouping:t.series?.[0]?.sliceGrouping,dataLabelsCharacterLimit:t.series?.[0]?.dataLabelsCharacterLimit,numericValueFormat:t.series?.[0]?.numericValueFormat,percentValueFormat:t.series?.[0]?.percentValueFormat,displayCategoryOnDataLabel:t.series?.[0]?.displayCategoryOnDataLabel,displayNumericValueOnDataLabel:t.series?.[0]?.displayNumericValueOnDataLabel,displayPercentageOnDataLabel:t.series?.[0]?.displayPercentageOnDataLabel},n=C(t,o);if(n!==f.NoAggregation&&a!==void 0){let m=`${n}_${a}_0`.toUpperCase();s.y=o===c.Category?m:N,s.query={outStatistics:o===c.Category?[{statisticType:n,onStatisticField:a,outStatisticFieldName:m}]:[]}}return o===c.Category&&s.query!==void 0?s.query.groupByFieldsForStatistics=[g]:delete s.query?.groupByFieldsForStatistics,j(s)}function q(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,{layerFieldsInfo:a}=e,{idField:l,isTraditionalTypeOID:g}=O(e.layer),d=P(t),s=S(t),n=C(t,o),m=g&&(s.length===0||s.includes(l)),u=K(n,i),D=m?"":s.map(W=>B(a??[],W)).join(", "),b=B(a??[],d),T="",v;return o===c.Fields?v=s.length===0:v=d==="",v?T=i.utilsStrings.chartType.pieChart:n===f.NoAggregation?T=A(i.titleLabels.aggrFieldsByCategory,{aggregationFields:m?l:D,category:b}):n===f.Count?T=A(i.titleLabels.aggrTypeCategory,{aggregationType:u,category:b}):s.length>0&&(b===I||k(b)||z(b)?T=A(i.titleLabels.aggrTypeOfAggrFields,{aggregationType:u,aggregationFields:D}):T=A(i.titleLabels.aggrTypeOfAggrFieldsByCategory,{aggregationType:u,aggregationFields:D,category:b})),T}var me=r=>{let{newSortOrderKind:t,config:e,orderByList:o}=r;e.orderOptions??={},t===y.customSort&&o!==void 0?e.orderOptions.data={orderType:p.Category,orderBy:[...o]}:e.orderOptions.data={orderType:t===y.labelAsc||t===y.labelDesc?p.Category:p.YValue,orderBy:t===y.labelAsc||t===y.valueAsc?F.Ascending:F.Descending}},ue=r=>{let{newCategory:t,config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=e.series?.length??0,g=V({config:e,layerInfo:o,commonStrings:a,mode:i}),d=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(e.series.forEach(s=>{s.x=i===c.Category?t:I,s.query!==void 0&&t!==I?s.query.groupByFieldsForStatistics=[t]:delete s.query?.groupByFieldsForStatistics}),l===0){let s=[J({config:e,layerInfo:o,mode:i,commonStrings:a})];e.series=s}if(o!==void 0){if(d){let n=h({config:e,layerInfo:o,numericFields:S(e),aggregationType:C(e,i),commonStrings:a});L(e,1,n)}e.title&&g&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}));let s=i===c.Fields?S(e).filter(n=>n!==O(o.layer).idField):S(e);Z({newNumericFields:s,config:e,layerInfo:o,mode:i,commonStrings:a})}};function Q(r){let{numericFields:t,aggregationType:e,config:o,layerInfo:i,mode:a,commonStrings:l}=r,{layerFieldsInfo:g}=i,d=[],s=J({config:o,layerInfo:i,mode:a,commonStrings:l}),n={...s,query:{...s.query}};t.length<=1?n.query.where=s.query?.where:delete n.query.where;let m=Y({config:o,xAxisField:P(o),numericFields:t,aggregationType:e,mode:a,layer:i.layer,fieldList:g}).name;if(e!==f.NoAggregation)if(a===c.Category){if(t.length>0){let u=t[0];n.query.outStatistics=[{...s.query?.outStatistics?.[0]??{},onStatisticField:u,outStatisticFieldName:m,statisticType:e}]}}else for(let u of t)n.query.outStatistics?.push({onStatisticField:u,outStatisticFieldName:u,statisticType:e});else n.query={};n.y=m,d.push(n),o.series=d}var fe=r=>{let{newAggregationType:t,config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=S(e),g=V({config:e,layerInfo:o,commonStrings:a,mode:i}),d=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(Q({config:e,layerInfo:o,numericFields:l,aggregationType:t,commonStrings:a,mode:i}),d){let u=h({config:e,layerInfo:o,commonStrings:a,numericFields:S(e),aggregationType:C(e,i)});L(e,1,u)}e.title&&g&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}));let s=e.series?.[0]?.displayCategoryOnDataLabel,n=e.series?.[0]?.displayNumericValueOnDataLabel,m=e.series?.[0]?.displayPercentageOnDataLabel;e.legend={...e.legend??R(),displayNumericValue:n,displayPercentage:m,displayCategory:s}},Z=r=>{let{newNumericFields:t}=r,{config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=O(o?.layer).idField,g=C(e,i),d=V({config:e,layerInfo:o,commonStrings:a,mode:i}),s=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(t=t===""?[]:t,t=typeof t=="string"?[t]:t,l!==void 0&&(t.length===0&&i===c.Category?(t.push(l),g=f.Count):g===f.Count&&t.length>=1&&!t.includes(l)&&(g=f.Sum)),o!==void 0){if(Q({config:e,layerInfo:o,commonStrings:a,numericFields:t,aggregationType:g,mode:i}),s){let n=h({config:e,layerInfo:o,commonStrings:a,numericFields:S(e),aggregationType:C(e,i)});L(e,1,n)}e.title&&d&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}))}else e.series.forEach(n=>{delete n.query,n.y=t[0]})},pe=(r,t)=>{let e=[],o=r.orderOptions?.data?.orderType,i=H(r,t),a=r.orderOptions?.data&&"orderBy"in r.orderOptions.data?r.orderOptions.data.orderBy:void 0;return i===y.customSort&&o===p.Category&&Array.isArray(a)&&(e=a),e},Se=r=>{let{values:t,config:e,mode:o}=r;e.orderOptions??={};let i=e.orderOptions?.data?.orderType;H(e,o)===y.customSort&&i===p.Category&&(e.orderOptions.data={orderType:p.Category,orderBy:[...t]})};function Fe(r){let{category:t="",numericFields:e=[],fallbackMode:o=c.Category}=r,i=t.trim()!==""&&t!==I,a=o;return e.length>1?a=c.Fields:i&&e.length<=1&&(a=c.Category),a}return{a:P,b:H,c:S,d:C,e:q,f:me,g:ue,h:fe,i:Z,j:pe,k:Se,l:Fe}},"intl",a,b,d,e,g)
2
+ import g from"./H4VTKKBN.js";import e from"./HOZ4AHQR.js";import d from"./RKZ2IOOP.js";import{c as M}from"./Y7HBWU3M.js";import b from"./6EX4GDM3.js";import a from"./BFVFX476.js";import{n as B}from"./3TBK72EK.js";import{L as R,fa as _,wa as K}from"./PAIRUVLU.js";import{f as G}from"./KX7KGXKQ.js";import{d as $,g as j,k,o as z}from"./SP2IPHWF.js";import{d as y,e as c}from"./QP5UAIC6.js";import{a as E,b as f,h as F,v as p}from"./547RDEMV.js";export default $arcgis.t(([{substitute:A},{q:I,r:N,rb:O},{a:L,b:h},{a:U},{b:x},{g:Y}])=>{function V(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=e!==void 0?q({config:t,layerInfo:e,commonStrings:i,mode:o}):"",l=U(t),g=x(t);return a===l||g}function w(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=e!==void 0?h({config:t,layerInfo:e,commonStrings:i,numericFields:S(t),aggregationType:C(t,o)}):"",l=M(1,t),g=x(t);return a===l||g}var P=r=>r.series?.[0]?.x??"";function X(r,t){let e=r.series?.[0];return[`${t===c.Category?e.y:N} ${F.Descending}`]}var H=(r,t)=>{let e=y.valueDesc,o=r.orderOptions?.data?.orderType??X(r,t),i=r.orderOptions?.data&&"orderBy"in r.orderOptions.data?r.orderOptions.data.orderBy:F.Descending;return o===p.Category&&Array.isArray(i)?e=y.customSort:o===p.Category?i===F.Ascending?e=y.labelAsc:e=y.labelDesc:i===F.Ascending?e=y.valueAsc:e=y.valueDesc,e},S=$(r=>{let t=[];return t=r.series?.[0]?.query?.outStatistics?.map(e=>e.onStatisticField)??[r.series?.[0]?.y??""],t.filter(e=>e!=="")},r=>r.series),C=(r,t)=>{let e=S(r),o;return t===c.Fields&&e.length===0?o=f.Sum:o=r.series?.[0]?.query?.outStatistics?.[0]?.statisticType??f.NoAggregation,o};function J(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,a=O(e?.layer).idField,l=_(i,a),g=P(t),d=t.series[0]?.dataLabels,s={...l,x:o===c.Category?g:I,slices:t.series?.[0]?.slices,dataLabels:{...l.dataLabels,type:l.dataLabels?.type??E.Text,content:{...l.dataLabels?.content,...d?.content,type:G.TS},visible:d?.visible??!1},innerRadiusSize:t.series?.[0]?.innerRadius,sliceGrouping:t.series?.[0]?.sliceGrouping,dataLabelsCharacterLimit:t.series?.[0]?.dataLabelsCharacterLimit,numericValueFormat:t.series?.[0]?.numericValueFormat,percentValueFormat:t.series?.[0]?.percentValueFormat,displayCategoryOnDataLabel:t.series?.[0]?.displayCategoryOnDataLabel,displayNumericValueOnDataLabel:t.series?.[0]?.displayNumericValueOnDataLabel,displayPercentageOnDataLabel:t.series?.[0]?.displayPercentageOnDataLabel},n=C(t,o);if(n!==f.NoAggregation&&a!==void 0){let m=`${n}_${a}_0`.toUpperCase();s.y=o===c.Category?m:N,s.query={outStatistics:o===c.Category?[{statisticType:n,onStatisticField:a,outStatisticFieldName:m}]:[]}}return o===c.Category&&s.query!==void 0?s.query.groupByFieldsForStatistics=[g]:delete s.query?.groupByFieldsForStatistics,j(s)}function q(r){let{config:t,layerInfo:e,mode:o,commonStrings:i}=r,{layerFieldsInfo:a}=e,{idField:l,isTraditionalTypeOID:g}=O(e.layer),d=P(t),s=S(t),n=C(t,o),m=g&&(s.length===0||s.includes(l)),u=K(n,i),D=m?"":s.map(W=>B(a??[],W)).join(", "),b=B(a??[],d),T="",v;return o===c.Fields?v=s.length===0:v=d==="",v?T=i.utilsStrings.chartType.pieChart:n===f.NoAggregation?T=A(i.titleLabels.aggrFieldsByCategory,{aggregationFields:m?l:D,category:b}):n===f.Count?T=A(i.titleLabels.aggrTypeCategory,{aggregationType:u,category:b}):s.length>0&&(b===I||k(b)||z(b)?T=A(i.titleLabels.aggrTypeOfAggrFields,{aggregationType:u,aggregationFields:D}):T=A(i.titleLabels.aggrTypeOfAggrFieldsByCategory,{aggregationType:u,aggregationFields:D,category:b})),T}var me=r=>{let{newSortOrderKind:t,config:e,orderByList:o}=r;e.orderOptions??={},t===y.customSort&&o!==void 0?e.orderOptions.data={orderType:p.Category,orderBy:[...o]}:e.orderOptions.data={orderType:t===y.labelAsc||t===y.labelDesc?p.Category:p.YValue,orderBy:t===y.labelAsc||t===y.valueAsc?F.Ascending:F.Descending}},ue=r=>{let{newCategory:t,config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=e.series?.length??0,g=V({config:e,layerInfo:o,commonStrings:a,mode:i}),d=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(e.series.forEach(s=>{s.x=i===c.Category?t:I,s.query!==void 0&&t!==I?s.query.groupByFieldsForStatistics=[t]:delete s.query?.groupByFieldsForStatistics}),l===0){let s=[J({config:e,layerInfo:o,mode:i,commonStrings:a})];e.series=s}if(o!==void 0){if(d){let n=h({config:e,layerInfo:o,numericFields:S(e),aggregationType:C(e,i),commonStrings:a});L(e,1,n)}e.title&&g&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}));let s=i===c.Fields?S(e).filter(n=>n!==O(o.layer).idField):S(e);Z({newNumericFields:s,config:e,layerInfo:o,mode:i,commonStrings:a})}};function Q(r){let{numericFields:t,aggregationType:e,config:o,layerInfo:i,mode:a,commonStrings:l}=r,{layerFieldsInfo:g}=i,d=[],s=J({config:o,layerInfo:i,mode:a,commonStrings:l}),n={...s,query:{...s.query}};t.length<=1?n.query.where=s.query?.where:delete n.query.where;let m=Y({config:o,xAxisField:P(o),numericFields:t,aggregationType:e,mode:a,layer:i.layer,fieldList:g}).name;if(e!==f.NoAggregation)if(a===c.Category){if(t.length>0){let u=t[0];n.query.outStatistics=[{...s.query?.outStatistics?.[0]??{},onStatisticField:u,outStatisticFieldName:m,statisticType:e}]}}else for(let u of t)n.query.outStatistics?.push({onStatisticField:u,outStatisticFieldName:u,statisticType:e});else n.query={};n.y=m,d.push(n),o.series=d}var fe=r=>{let{newAggregationType:t,config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=S(e),g=V({config:e,layerInfo:o,commonStrings:a,mode:i}),d=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(Q({config:e,layerInfo:o,numericFields:l,aggregationType:t,commonStrings:a,mode:i}),d){let u=h({config:e,layerInfo:o,commonStrings:a,numericFields:S(e),aggregationType:C(e,i)});L(e,1,u)}e.title&&g&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}));let s=e.series?.[0]?.displayCategoryOnDataLabel,n=e.series?.[0]?.displayNumericValueOnDataLabel,m=e.series?.[0]?.displayPercentageOnDataLabel;e.legend={...e.legend??R(),displayNumericValue:n,displayPercentage:m,displayCategory:s}},Z=r=>{let{newNumericFields:t}=r,{config:e,layerInfo:o,mode:i,commonStrings:a}=r,l=O(o?.layer).idField,g=C(e,i),d=V({config:e,layerInfo:o,commonStrings:a,mode:i}),s=w({config:e,layerInfo:o,commonStrings:a,mode:i});if(t=t===""?[]:t,t=typeof t=="string"?[t]:t,l!==void 0&&(t.length===0&&i===c.Category?(t.push(l),g=f.Count):g===f.Count&&t.length>=1&&!t.includes(l)&&(g=f.Sum)),o!==void 0){if(Q({config:e,layerInfo:o,commonStrings:a,numericFields:t,aggregationType:g,mode:i}),s){let n=h({config:e,layerInfo:o,commonStrings:a,numericFields:S(e),aggregationType:C(e,i)});L(e,1,n)}e.title&&d&&(e.title.content.text=q({config:e,layerInfo:o,commonStrings:a,mode:i}))}else e.series.forEach(n=>{delete n.query,n.y=t[0]})},pe=(r,t)=>{let e=[],o=r.orderOptions?.data?.orderType,i=H(r,t),a=r.orderOptions?.data&&"orderBy"in r.orderOptions.data?r.orderOptions.data.orderBy:void 0;return i===y.customSort&&o===p.Category&&Array.isArray(a)&&(e=a),e},Se=r=>{let{values:t,config:e,mode:o}=r;e.orderOptions??={};let i=e.orderOptions?.data?.orderType;H(e,o)===y.customSort&&i===p.Category&&(e.orderOptions.data={orderType:p.Category,orderBy:[...t]})};function Fe(r){let{category:t="",numericFields:e=[],fallbackMode:o=c.Category}=r,i=t.trim()!==""&&t!==I,a=o;return e.length>1?a=c.Fields:i&&e.length<=1&&(a=c.Category),a}return{a:P,b:H,c:S,d:C,e:q,f:me,g:ue,h:fe,i:Z,j:pe,k:Se,l:Fe}},"intl",a,b,d,e,g)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import a from"./7LI5APDL.js";import{C as b,E as d,c as r}from"./PAIRUVLU.js";import{g as l}from"./SP2IPHWF.js";export default $arcgis.t(([{b:f,c:c}])=>{var m=Object.defineProperty,p=Object.getOwnPropertyDescriptor,L=(t,a,e,g)=>{for(var o=p(a,e),s=t.length-1,n;s>=0;s--)(n=t[s])&&(o=n(a,e,o)||o);return o&&m(a,e,o),o};function S(t){return t!==void 0&&"dataLabelsSymbol"in t}var v=t=>{for(let a of t.series)if(a.dataLabels!==void 0)return a.dataLabels.content},y=(t,a)=>{for(let e of a.series)(e.dataLabels===void 0||t===void 0)&&(e.dataLabels=d({text:"",visible:!0,font:b(r.DataLabels),type:r.DataLabels})),t!==void 0&&(e.dataLabels.content=l(t))},i=class extends f{get dataLabelsSymbol(){return v(this._config)}set dataLabelsSymbol(a){y(a,this._config)}};L([c],i.prototype,"dataLabelsSymbol");return{a:S,b:i}},a)
2
+ import a from"./FVGXWZBY.js";import{C as b,E as d,c as r}from"./PAIRUVLU.js";import{g as l}from"./SP2IPHWF.js";export default $arcgis.t(([{b:f,c:c}])=>{var m=Object.defineProperty,p=Object.getOwnPropertyDescriptor,L=(t,a,e,g)=>{for(var o=p(a,e),s=t.length-1,n;s>=0;s--)(n=t[s])&&(o=n(a,e,o)||o);return o&&m(a,e,o),o};function S(t){return t!==void 0&&"dataLabelsSymbol"in t}var v=t=>{for(let a of t.series)if(a.dataLabels!==void 0)return a.dataLabels.content},y=(t,a)=>{for(let e of a.series)(e.dataLabels===void 0||t===void 0)&&(e.dataLabels=d({text:"",visible:!0,font:b(r.DataLabels),type:r.DataLabels})),t!==void 0&&(e.dataLabels.content=l(t))},i=class extends f{get dataLabelsSymbol(){return v(this._config)}set dataLabelsSymbol(a){y(a,this._config)}};L([c],i.prototype,"dataLabelsSymbol");return{a:S,b:i}},a)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import{a as b}from"./L7CMLBHB.js";import{a as I,b as E}from"./OBPAQN4H.js";import e from"./LSKFMUX4.js";import{a as c}from"./JHANH4UG.js";import"./AK7X7SGI.js";import d from"./D46R6YHX.js";import"./WNKDEOFZ.js";import a from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{h as m}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as r,B as f,C as o,F as v,H as C,g as N,i as n,z as h}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as l}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{a:M,f:g,g:x,h:B,i:a}])=>{var u={linkContainer:"link-container",label:"label",mb2:"mb-2"},L=N`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}calcite-block{width:var(--arcgis-charts-config-calcite-block-width, var(--arcgis-charts-config-calcite-block-default-width));height:var(--arcgis-charts-config-calcite-block-height, var(--arcgis-charts-config-calcite-block-default-height));border:0px;-webkit-box-shadow:0 0 0 0;box-shadow:0 0}.label{display:flex;justify-content:space-between}.mb-2{margin-bottom:var(--arcgis-charts-config-margin-minor)}.link-container{display:flex;justify-content:flex-end;margin-top:-.75rem}`,p=class extends f{constructor(){super(...arguments),this._messages=c(),this.commonStrings=c({name:"common",blocking:!0}),this.axisModel=new b,this.minBoundInputElement=h(),this.maxBoundInputElement=h(),this.showLogScaleSwitch=h(),this.defaultMinBound=Number.NaN,this.defaultMaxBound=Number.NaN,this.onMaxBoundsChange=()=>{let e=this.maxBoundInputElement.value?.value,t=this.maxBoundInputElement.value?.status;if(e!==void 0&&e!==""){let s=this.maxBoundInputElement.value?.min===void 0?this.axisModel.getMinBound():Math.max(this.maxBoundInputElement.value.min,this.axisModel.getMinBound()),i=Number.parseFloat(e);if(i!==this.axisModel.getMinBound()&&g(i,s,this.maxBoundInputElement.value?.max)){if(i!==this.axisModel.getMaxBound()){this.axisModel.setMaxBound(i);let d=this.getAxisBoundsFromStateStore();d&&(d.currMaxBound=i)}t=a.IDLE}else t=a.INVALID}else t=a.IDLE;this.maxBoundInputElement.value&&B({inputElement:this.maxBoundInputElement.value,status:t}),t!==a.INVALID&&this.minBoundInputElement.value?.status===a.INVALID&&this.onMinBoundsChange(),this.requestUpdate()},this.onMaxBoundsChangeDebounced=m(this.onMaxBoundsChange,M.DebounceTimer),this.onMinBoundsChange=()=>{let e=this.minBoundInputElement.value?.value,t=this.minBoundInputElement.value?.status;if(e!==void 0&&e!==""){let s=this.minBoundInputElement.value?.max===void 0?this.axisModel.getMaxBound():Math.min(this.minBoundInputElement.value.max,this.axisModel.getMaxBound()),i=Number.parseFloat(e);if(i!==this.axisModel.getMaxBound()&&g(i,this.minBoundInputElement.value?.min,s)){if(i!==this.axisModel.getMinBound()){this.axisModel.setMinBound(i);let d=this.getAxisBoundsFromStateStore();d&&(d.currMinBound=i)}t=a.IDLE}else t=a.INVALID}else t=a.IDLE;this.minBoundInputElement.value&&B({inputElement:this.minBoundInputElement.value,status:t}),t!==a.INVALID&&this.maxBoundInputElement.value?.status===a.INVALID&&this.onMaxBoundsChange(),this.updateEnableLogarithmic(this.axisModel.getLogarithmic()&&(this.dataMinValue??Number.NaN)>0),this.requestUpdate()},this.onMinBoundsChangeDebounced=m(this.onMinBoundsChange,M.DebounceTimer),this.onModelConfigChange=()=>{this.requestUpdate()},this.disableMaxBoundResetBtn=!0,this.disableMinBoundResetBtn=!0,this.isXAxis=!1,this.axisTitle="",this.showMaxBoundOption=!1,this.showMinBoundOption=!1,this.showEnableLogOption=!1}static{this.properties={disableMaxBoundResetBtn:16,disableMinBoundResetBtn:16,messageOverrides:0,model:0,isXAxis:5,axisTitle:1,maxBoundMaxLimit:9,maxBoundMinLimit:9,minBoundMinLimit:9,minBoundMaxLimit:9,showMaxBoundOption:5,showMinBoundOption:5,showEnableLogOption:5,dataMaxValue:9,dataMinValue:9,initialMaxBound:9,initialMinBound:9}}static{this.styles=L}load(){this.modelChange(this.model),this.dataMinValue!==void 0&&this.dataMinValueChange(this.dataMinValue,Number.NaN),this.dataMaxValue!==void 0&&this.dataMaxValueChange(this.dataMaxValue,Number.NaN)}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("dataMinValue")&&this.dataMinValueChange(this.dataMinValue??Number.NaN,e.get("dataMinValue")),e.has("dataMaxValue")&&this.dataMaxValueChange(this.dataMaxValue??Number.NaN,e.get("dataMaxValue")),e.has("initialMaxBound")&&this.initialMaxBoundChange(),e.has("initialMinBound")&&this.initialMinBoundChange()}updated(){this.disableResetButtons()}disconnectedCallback(){super.disconnectedCallback(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){this.axisModel=new b(this.model,this.isXAxis),t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}dataMinValueChange(e,t){Number.isNaN(t)&&!Number.isNaN(e)&&(this.defaultMinBound=e)}dataMaxValueChange(e,t){Number.isNaN(t)&&!Number.isNaN(e)&&(this.defaultMaxBound=e)}initialMaxBoundChange(){Number.isNaN(this.axisModel.getMaxBound())||this.axisModel.setMaxBound(this.axisModel.getMaxBound())}initialMinBoundChange(){Number.isNaN(this.axisModel.getMinBound())||this.axisModel.setMinBound(this.axisModel.getMinBound())}getAxisBoundsFromStateStore(){let e,t=I.chartAxesBoundDataMap,s=this.model.chartId;if(s){let i=E({chartId:s,isXAxis:this.isXAxis,isLogarithmic:this.axisModel.getLogarithmic()});e=t[s]?.[i]}return e}disableResetButtons(){let e=this.getAxisBoundsFromStateStore();e&&(this.disableMaxBoundResetBtn=e.defaultMaxBound===e.currMaxBound,this.disableMinBoundResetBtn=e.defaultMinBound===e.currMinBound)}onShowLogScaleMouseEnter(){this.showLogScaleTooltip?.remove(),this.showLogScaleSwitch.value?.disabled&&(this.showLogScaleTooltip=v(n`<calcite-tooltip .referenceElement=${this.showLogScaleSwitch.value??document.body} open>${this.commonStrings.utilsStrings.tooltips?.logDisabled??""}</calcite-tooltip>`),document.body.appendChild(this.showLogScaleTooltip))}onShowLogScaleMouseLeave(){this.showLogScaleTooltip?.remove()}onCategoryFormatChange(e){this.axisModel.setValueFormat(e.target.categoryFormat)}updateEnableLogarithmic(e){e!==this.axisModel.getLogarithmic()&&(this.axisModel.setLogarithmic(e),this.requestUpdate())}onNumberFormatChange(e){this.axisModel.setValueFormat({type:l.NumberAxisFormat,intlOptions:e.detail}),this.requestUpdate()}onRevertMaxBoundsToDefault(){if(this.maxBoundInputElement.value?.status===a.INVALID||this.axisModel.getMaxBound()!==this.defaultMaxBound){let e=this.getAxisBoundsFromStateStore();this.axisModel.getMinBound()>this.defaultMaxBound&&this.axisModel.setMinBound(e?.defaultMinBound??Number.NaN),this.axisModel.setMaxBound(e?.defaultMaxBound??Number.NaN),this.requestUpdate()}}onRevertMinBoundsToDefault(){(this.minBoundInputElement.value?.status===a.INVALID||this.axisModel.getMinBound()!==this.defaultMinBound)&&(this.axisModel.getMaxBound()<this.defaultMinBound&&this.axisModel.setMaxBound(Number.NaN),this.axisModel.setMinBound(Number.NaN),this.requestUpdate())}enableLogScale(e){let{checked:t}=e.target;this.axisModel.setLogarithmic(t&&(this.dataMinValue??Number.NaN)>0),this.requestUpdate()}render(){return n`<calcite-block .hidden=${this.axisModel.getValueFormat()?.type===l.DateAxisFormat} expanded .heading=${this.axisTitle}>${this.renderAxis()}</calcite-block>`}renderAxis(){let e=null,t={...this.axisModel.getValueFormat()};switch(this.axisModel.getValueFormat()?.type){case l.CategoryAxisFormat:e=n`<arcgis-charts-config-category-format .categoryFormat=${t} @arcgisChartsConfigCategoryFormatChange=${this.onCategoryFormatChange}></arcgis-charts-config-category-format>`;break;case l.NumberAxisFormat:e=n`<div>${this.renderShowLogScale()}${this.renderMinBound()}${this.renderMaxBound()}<arcgis-charts-config-number-format .numberFormat=${{...t.intlOptions}} @arcgisChartsConfigNumberFormatChange=${this.onNumberFormatChange}></arcgis-charts-config-number-format></div>`;break;case l.DateAxisFormat:e=null;break}return e}renderMaxBound(){let e;if(!this.showMaxBoundOption)e=null;else{let t=x(this.axisModel.getMaxBound(),this.initialMaxBound);e=n`<div><calcite-label class=${o(u.label)}>${this._messages.maxBounds}<calcite-input type=number number-button-type=none .min=${this.maxBoundMinLimit??Number.MIN_SAFE_INTEGER} .max=${this.maxBoundMaxLimit??Number.MAX_SAFE_INTEGER} step=any .value=${t} @calciteInputInput=${this.onMaxBoundsChangeDebounced} ${r(this.maxBoundInputElement)}></calcite-input></calcite-label><div class=${o(u.linkContainer)}><calcite-button .disabled=${this.disableMaxBoundResetBtn} @click=${this.onRevertMaxBoundsToDefault} appearance=transparent icon-end=reset>${this._messages.revertToDefault}</calcite-button></div></div>`}return e}renderMinBound(){let e;if(!this.showMinBoundOption)e=null;else{let t=x(this.axisModel.getMinBound(),this.initialMinBound??void 0);e=n`<div><calcite-label class=${o(u.label)}>${this._messages.minBounds}<calcite-input type=number number-button-type=none .min=${this.minBoundMinLimit??Number.MIN_SAFE_INTEGER} .max=${this.minBoundMaxLimit??Number.MAX_SAFE_INTEGER} step=any .value=${t} @calciteInputInput=${this.onMinBoundsChangeDebounced} ${r(this.minBoundInputElement)}></calcite-input></calcite-label><div class=${o(u.linkContainer)}><calcite-button .disabled=${this.disableMinBoundResetBtn} appearance=transparent icon-end=reset @click=${this.onRevertMinBoundsToDefault}>${this._messages.revertToDefault}</calcite-button></div></div>`}return e}renderShowLogScale(){let e;return this.showEnableLogOption&&(e=n`<calcite-label layout=inline-space-between class=${o({[u.label]:!0,[u.mb2]:!0})}>${this._messages.logScale}<div @mouseenter=${this.onShowLogScaleMouseEnter} @mouseleave=${this.onShowLogScaleMouseLeave}><calcite-switch .checked=${this.axisModel.getLogarithmic()&&(this.dataMinValue??Number.NaN)>0} .disabled=${(this.dataMinValue??Number.NaN)<=0} @calciteSwitchChange=${this.enableLogScale} ${r(this.showLogScaleSwitch)}></calcite-switch></div></calcite-label>`),e}};C("arcgis-charts-config-axis",p);return p},a,d,e)
2
+ import{a as b}from"./L7CMLBHB.js";import{a as I,b as E}from"./OBPAQN4H.js";import e from"./VQFCYPDR.js";import{a as c}from"./JHANH4UG.js";import"./AK7X7SGI.js";import d from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import a from"./BFVFX476.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{h as m}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as r,B as f,C as o,F as v,H as C,g as N,i as n,z as h}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as l}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{a:M,f:g,g:x,h:B,i:a}])=>{var u={linkContainer:"link-container",label:"label",mb2:"mb-2"},L=N`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}calcite-block{width:var(--arcgis-charts-config-calcite-block-width, var(--arcgis-charts-config-calcite-block-default-width));height:var(--arcgis-charts-config-calcite-block-height, var(--arcgis-charts-config-calcite-block-default-height));border:0px;-webkit-box-shadow:0 0 0 0;box-shadow:0 0}.label{display:flex;justify-content:space-between}.mb-2{margin-bottom:var(--arcgis-charts-config-margin-minor)}.link-container{display:flex;justify-content:flex-end;margin-top:-.75rem}`,p=class extends f{constructor(){super(...arguments),this._messages=c(),this.commonStrings=c({name:"common",blocking:!0}),this.axisModel=new b,this.minBoundInputElement=h(),this.maxBoundInputElement=h(),this.showLogScaleSwitch=h(),this.defaultMinBound=Number.NaN,this.defaultMaxBound=Number.NaN,this.onMaxBoundsChange=()=>{let e=this.maxBoundInputElement.value?.value,t=this.maxBoundInputElement.value?.status;if(e!==void 0&&e!==""){let s=this.maxBoundInputElement.value?.min===void 0?this.axisModel.getMinBound():Math.max(this.maxBoundInputElement.value.min,this.axisModel.getMinBound()),i=Number.parseFloat(e);if(i!==this.axisModel.getMinBound()&&g(i,s,this.maxBoundInputElement.value?.max)){if(i!==this.axisModel.getMaxBound()){this.axisModel.setMaxBound(i);let d=this.getAxisBoundsFromStateStore();d&&(d.currMaxBound=i)}t=a.IDLE}else t=a.INVALID}else t=a.IDLE;this.maxBoundInputElement.value&&B({inputElement:this.maxBoundInputElement.value,status:t}),t!==a.INVALID&&this.minBoundInputElement.value?.status===a.INVALID&&this.onMinBoundsChange(),this.requestUpdate()},this.onMaxBoundsChangeDebounced=m(this.onMaxBoundsChange,M.DebounceTimer),this.onMinBoundsChange=()=>{let e=this.minBoundInputElement.value?.value,t=this.minBoundInputElement.value?.status;if(e!==void 0&&e!==""){let s=this.minBoundInputElement.value?.max===void 0?this.axisModel.getMaxBound():Math.min(this.minBoundInputElement.value.max,this.axisModel.getMaxBound()),i=Number.parseFloat(e);if(i!==this.axisModel.getMaxBound()&&g(i,this.minBoundInputElement.value?.min,s)){if(i!==this.axisModel.getMinBound()){this.axisModel.setMinBound(i);let d=this.getAxisBoundsFromStateStore();d&&(d.currMinBound=i)}t=a.IDLE}else t=a.INVALID}else t=a.IDLE;this.minBoundInputElement.value&&B({inputElement:this.minBoundInputElement.value,status:t}),t!==a.INVALID&&this.maxBoundInputElement.value?.status===a.INVALID&&this.onMaxBoundsChange(),this.updateEnableLogarithmic(this.axisModel.getLogarithmic()&&(this.dataMinValue??Number.NaN)>0),this.requestUpdate()},this.onMinBoundsChangeDebounced=m(this.onMinBoundsChange,M.DebounceTimer),this.onModelConfigChange=()=>{this.requestUpdate()},this.disableMaxBoundResetBtn=!0,this.disableMinBoundResetBtn=!0,this.isXAxis=!1,this.axisTitle="",this.showMaxBoundOption=!1,this.showMinBoundOption=!1,this.showEnableLogOption=!1}static{this.properties={disableMaxBoundResetBtn:16,disableMinBoundResetBtn:16,messageOverrides:0,model:0,isXAxis:5,axisTitle:1,maxBoundMaxLimit:9,maxBoundMinLimit:9,minBoundMinLimit:9,minBoundMaxLimit:9,showMaxBoundOption:5,showMinBoundOption:5,showEnableLogOption:5,dataMaxValue:9,dataMinValue:9,initialMaxBound:9,initialMinBound:9}}static{this.styles=L}load(){this.modelChange(this.model),this.dataMinValue!==void 0&&this.dataMinValueChange(this.dataMinValue,Number.NaN),this.dataMaxValue!==void 0&&this.dataMaxValueChange(this.dataMaxValue,Number.NaN)}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("dataMinValue")&&this.dataMinValueChange(this.dataMinValue??Number.NaN,e.get("dataMinValue")),e.has("dataMaxValue")&&this.dataMaxValueChange(this.dataMaxValue??Number.NaN,e.get("dataMaxValue")),e.has("initialMaxBound")&&this.initialMaxBoundChange(),e.has("initialMinBound")&&this.initialMinBoundChange()}updated(){this.disableResetButtons()}disconnectedCallback(){super.disconnectedCallback(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){this.axisModel=new b(this.model,this.isXAxis),t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}dataMinValueChange(e,t){Number.isNaN(t)&&!Number.isNaN(e)&&(this.defaultMinBound=e)}dataMaxValueChange(e,t){Number.isNaN(t)&&!Number.isNaN(e)&&(this.defaultMaxBound=e)}initialMaxBoundChange(){Number.isNaN(this.axisModel.getMaxBound())||this.axisModel.setMaxBound(this.axisModel.getMaxBound())}initialMinBoundChange(){Number.isNaN(this.axisModel.getMinBound())||this.axisModel.setMinBound(this.axisModel.getMinBound())}getAxisBoundsFromStateStore(){let e,t=I.chartAxesBoundDataMap,s=this.model.chartId;if(s){let i=E({chartId:s,isXAxis:this.isXAxis,isLogarithmic:this.axisModel.getLogarithmic()});e=t[s]?.[i]}return e}disableResetButtons(){let e=this.getAxisBoundsFromStateStore();e&&(this.disableMaxBoundResetBtn=e.defaultMaxBound===e.currMaxBound,this.disableMinBoundResetBtn=e.defaultMinBound===e.currMinBound)}onShowLogScaleMouseEnter(){this.showLogScaleTooltip?.remove(),this.showLogScaleSwitch.value?.disabled&&(this.showLogScaleTooltip=v(n`<calcite-tooltip .referenceElement=${this.showLogScaleSwitch.value??document.body} open>${this.commonStrings.utilsStrings.tooltips?.logDisabled??""}</calcite-tooltip>`),document.body.appendChild(this.showLogScaleTooltip))}onShowLogScaleMouseLeave(){this.showLogScaleTooltip?.remove()}onCategoryFormatChange(e){this.axisModel.setValueFormat(e.target.categoryFormat)}updateEnableLogarithmic(e){e!==this.axisModel.getLogarithmic()&&(this.axisModel.setLogarithmic(e),this.requestUpdate())}onNumberFormatChange(e){this.axisModel.setValueFormat({type:l.NumberAxisFormat,intlOptions:e.detail}),this.requestUpdate()}onRevertMaxBoundsToDefault(){if(this.maxBoundInputElement.value?.status===a.INVALID||this.axisModel.getMaxBound()!==this.defaultMaxBound){let e=this.getAxisBoundsFromStateStore();this.axisModel.getMinBound()>this.defaultMaxBound&&this.axisModel.setMinBound(e?.defaultMinBound??Number.NaN),this.axisModel.setMaxBound(e?.defaultMaxBound??Number.NaN),this.requestUpdate()}}onRevertMinBoundsToDefault(){(this.minBoundInputElement.value?.status===a.INVALID||this.axisModel.getMinBound()!==this.defaultMinBound)&&(this.axisModel.getMaxBound()<this.defaultMinBound&&this.axisModel.setMaxBound(Number.NaN),this.axisModel.setMinBound(Number.NaN),this.requestUpdate())}enableLogScale(e){let{checked:t}=e.target;this.axisModel.setLogarithmic(t&&(this.dataMinValue??Number.NaN)>0),this.requestUpdate()}render(){return n`<calcite-block .hidden=${this.axisModel.getValueFormat()?.type===l.DateAxisFormat} expanded .heading=${this.axisTitle}>${this.renderAxis()}</calcite-block>`}renderAxis(){let e=null,t={...this.axisModel.getValueFormat()};switch(this.axisModel.getValueFormat()?.type){case l.CategoryAxisFormat:e=n`<arcgis-charts-config-category-format .categoryFormat=${t} @arcgisChartsConfigCategoryFormatChange=${this.onCategoryFormatChange}></arcgis-charts-config-category-format>`;break;case l.NumberAxisFormat:e=n`<div>${this.renderShowLogScale()}${this.renderMinBound()}${this.renderMaxBound()}<arcgis-charts-config-number-format .numberFormat=${{...t.intlOptions}} @arcgisChartsConfigNumberFormatChange=${this.onNumberFormatChange}></arcgis-charts-config-number-format></div>`;break;case l.DateAxisFormat:e=null;break}return e}renderMaxBound(){let e;if(!this.showMaxBoundOption)e=null;else{let t=x(this.axisModel.getMaxBound(),this.initialMaxBound);e=n`<div><calcite-label class=${o(u.label)}>${this._messages.maxBounds}<calcite-input type=number number-button-type=none .min=${this.maxBoundMinLimit??Number.MIN_SAFE_INTEGER} .max=${this.maxBoundMaxLimit??Number.MAX_SAFE_INTEGER} step=any .value=${t} @calciteInputInput=${this.onMaxBoundsChangeDebounced} ${r(this.maxBoundInputElement)}></calcite-input></calcite-label><div class=${o(u.linkContainer)}><calcite-button .disabled=${this.disableMaxBoundResetBtn} @click=${this.onRevertMaxBoundsToDefault} appearance=transparent icon-end=reset>${this._messages.revertToDefault}</calcite-button></div></div>`}return e}renderMinBound(){let e;if(!this.showMinBoundOption)e=null;else{let t=x(this.axisModel.getMinBound(),this.initialMinBound??void 0);e=n`<div><calcite-label class=${o(u.label)}>${this._messages.minBounds}<calcite-input type=number number-button-type=none .min=${this.minBoundMinLimit??Number.MIN_SAFE_INTEGER} .max=${this.minBoundMaxLimit??Number.MAX_SAFE_INTEGER} step=any .value=${t} @calciteInputInput=${this.onMinBoundsChangeDebounced} ${r(this.minBoundInputElement)}></calcite-input></calcite-label><div class=${o(u.linkContainer)}><calcite-button .disabled=${this.disableMinBoundResetBtn} appearance=transparent icon-end=reset @click=${this.onRevertMinBoundsToDefault}>${this._messages.revertToDefault}</calcite-button></div></div>`}return e}renderShowLogScale(){let e;return this.showEnableLogOption&&(e=n`<calcite-label layout=inline-space-between class=${o({[u.label]:!0,[u.mb2]:!0})}>${this._messages.logScale}<div @mouseenter=${this.onShowLogScaleMouseEnter} @mouseleave=${this.onShowLogScaleMouseLeave}><calcite-switch .checked=${this.axisModel.getLogarithmic()&&(this.dataMinValue??Number.NaN)>0} .disabled=${(this.dataMinValue??Number.NaN)<=0} @calciteSwitchChange=${this.enableLogScale} ${r(this.showLogScaleSwitch)}></calcite-switch></div></calcite-label>`),e}};C("arcgis-charts-config-axis",p);return p},a,d,e)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import{a as u,c as P,d as T,f as _}from"./OBPAQN4H.js";import{a as w}from"./S7Z4HRW7.js";import{a as N}from"./IHO3OLL3.js";import{a as C}from"./JHANH4UG.js";import{f as l}from"./AK7X7SGI.js";import e from"./XKHA7K4P.js";import a from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import{n as p,u as S}from"./3TBK72EK.js";import{wa as B,xa as k}from"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as I}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as m,B as F,C as s,F as x,H as A,g as y,i as r,n as g,z as h}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{b as c,k as b,n as d}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{rb:f,tb:E},{h:L}])=>{var z=y`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin);margin-top:var(--arcgis-charts-top-section-margin)}.label,.disabled-label{display:flex;margin-left:.5rem;margin-right:.5rem;margin-bottom:.5rem;justify-content:space-between}.time-binning-header{display:flex;font-weight:700;margin-left:.5rem;margin-right:.5rem;justify-content:space-between}.field-list{max-height:50vh;overflow-y:auto}.disabled-label{pointer-events:none}.fab{display:flex;margin-left:.5rem;margin-right:.5rem;margin-bottom:1.5rem;justify-content:center}.link-container{display:flex;justify-content:flex-end}`,n={label:"label",fieldList:"field-list",fab:"fab",timeBinningHeader:"time-binning-header",linkContainer:"link-container",dimText:"dim-text"},$=class extends F{constructor(){super(...arguments),this._messages=C(),this.commonStrings=C({name:"common",blocking:!0}),this.lineChartPopover=null,this.aggregationElement=h(),this.xAxisFieldElement=h(),this.numericFieldsElement=h(),this.splitByFieldElement=h(),this.intervalAlignmentElement=h(),this.intervalElement=h(),this.onLineChartDataChange=e=>{try{if(e.detail!==null&&e.detail?.value!==void 0){let{contentKind:t}=e.detail,i=[...e.detail.value];switch(P(u),t){case l.aggregation:this.model.aggregationType=i[0]!==c.NoAggregation?i[0]:c.NoAggregation;break;case l.xAxisField:{let a=i[0]?.trim()||"";this.model.xAxisField=a,this.arcgisChartsConfigResetTimeInterval.emit();break}case l.numericFields:this.model.numericFields=i,this.model.numericFields.length>0&&this.model.aggregationType===c.Count&&this.model.numericFields[0]!==f(this.model.layer).idField&&(this.model.aggregationType=c.Sum);break;case l.splitByField:{let a=i[0]?.trim()||"";this.model.splitByField=a,this.model.colorMatch=!0;break}case l.interval:this.model.temporalBinningSize=i[0]?.intervalSize,this.model.temporalBinningUnit=i[0]?.intervalUnits,this.arcgisChartsConfigCustomizedTimeInterval.emit();break;case l.intervalAlignment:this.model.timeAggregationType=i[0]??"";break;default:break}t!==l.interval&&t!==l.intervalAlignment&&_(u)}}catch(t){throw t instanceof Error&&this.arcgisChartsConfigDataChangeError.emit({error:t,model:this.model}),t}this.removeLineChartDataPopover(),this.requestUpdate()},this.onModelConfigChange=()=>{this.requestUpdate()},this.popoverClose=e=>{this.lineChartPopover===e?.target&&this.removeLineChartDataPopover()},this.layerFieldsInfo=[],this.arcgisChartsConfigCustomizedTimeInterval=g(),this.arcgisChartsConfigDataChangeError=g(),this.arcgisChartsConfigLineChartDataNumericFieldValidate=g(),this.arcgisChartsConfigResetTimeInterval=g()}static{this.properties={aggregationLabel:16,timeAggregationLabel:16,disableSplitBy:16,messageOverrides:0,model:0,resetTimeInterval:0,layerFieldsInfo:0}}static{this.styles=z}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),this.aggregationLabel=B(this.model.aggregationType,this.commonStrings);let t=this.model.timeAggregationType;t!==void 0&&(this.timeAggregationLabel=k(t,this.commonStrings)),this.disableSplitBy=this.model.numericFields.length>1}disconnectedCallback(){super.disconnectedCallback(),this.removeLineChartDataPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}buildNumericFieldItem(e){return w(e,r`<calcite-list-item .label=${p(this.layerFieldsInfo,e)} .value=${e} closable @calciteListItemClose=${this.onRemoveNumericField}></calcite-list-item>`)}resetTimeIntervalOriginal(e){this.popoverClose(e),this.model.resetTimeInterval!==void 0&&(this.model.resetTimeInterval(),this.arcgisChartsConfigResetTimeInterval.emit())}onAggregationSelect(e){this.contentKind=l.aggregation,this.setupPopover(e)}onXAxisFieldSelect(e){this.contentKind=l.xAxisField,this.setupPopover(e)}onSplitBySelect(e){this.splitByFieldElement.value&&!this.splitByFieldElement.value.disabled&&(this.contentKind=l.splitByField,this.setupPopover(e))}onAddNumericFields(e){this.contentKind=l.numericFields,this.setupPopover(e)}onRemoveNumericField(e){let t=e.target.value;this.model.numericFields=this.model.numericFields.filter(i=>i!==t)}onIntervalAlignmentSelect(e){this.intervalAlignmentElement.value&&!this.intervalAlignmentElement.value.disabled&&(this.contentKind=l.intervalAlignment,this.setupPopover(e))}onIntervalSelect(e){this.intervalElement.value&&!this.intervalElement.value.disabled&&(this.contentKind=l.interval,this.setupPopover(e))}getCorrectedSplitByValue(){return this.model.splitByField===""||this.model.numericFields.length>1?"":p(this.layerFieldsInfo,this.model.splitByField)}getCorrectedXAxisValue(){return L({fieldName:this.model.xAxisField,fieldList:this.layerFieldsInfo})?"":p(this.layerFieldsInfo,this.model.xAxisField)}onShowDataLabelsChange(e){this.model.dataLabelsVisibility=e.target.checked}onTrimIncompleteIntervalChange(e){this.model.trimIncompleteTimeInterval=e.target.checked}onNullPolicyChange(e){this.model.nullPolicy=e.target.selectedItem?.value}shouldShowTimeBinning(){let e=this.layerFieldsInfo.find(i=>i.name===this.model.xAxisField),t=this.model.aggregationType!==c.NoAggregation;return e!==void 0&&E(e)&&t}setupPopover(e){e.stopImmediatePropagation(),this.removeLineChartDataPopover();let t={size:this.model.temporalBinningSize??1,unit:this.model.temporalBinningUnit??b.Second},i,a,o;switch(this.contentKind){case l.aggregation:i=this.aggregationElement.value,a=this._messages.aggregationHeader,o=this.model.aggregationType;break;case l.xAxisField:i=this.xAxisFieldElement.value,a=this._messages.xAxisFieldHeader,o=this.model.xAxisField;break;case l.numericFields:i=this.numericFieldsElement.value,a=this._messages.numericFieldsHeader,o=this.model.numericFields;break;case l.splitByField:i=this.splitByFieldElement.value,a=this._messages.splitByFieldHeader,o=this.model.splitByField;break;case l.interval:i=this.intervalElement.value,a=this._messages.editInterval,o=t;break;case l.intervalAlignment:i=this.intervalAlignmentElement.value,a=this._messages.intervalAlignment,o=this.model.timeAggregationType??"";break}this.lineChartPopover=x(r`<arcgis-charts-config-line-chart-popover .headingTitle=${a} .referenceElement=${i} open .contentKind=${this.contentKind} .layerFieldsInfo=${this.layerFieldsInfo} .selectedContent=${o} @arcgisChartsConfigLineChartDataPopoverChange=${this.onLineChartDataChange} @arcgisChartsConfigLineChartPopoverClose=${this.popoverClose}></arcgis-charts-config-line-chart-popover>`),!document.body.contains(this.lineChartPopover)&&this.lineChartPopover!==null&&document.body.appendChild(this.lineChartPopover)}removeLineChartDataPopover(){this.lineChartPopover!==null&&(this.lineChartPopover.open=!1,this.lineChartPopover=N(this.lineChartPopover))}renderAggregation(){return r`<arcgis-charts-config-field-select .label=${this.model.aggregationType===c.NoAggregation?this._messages.noAggregation:this.aggregationLabel} @click=${this.onAggregationSelect} ${m(this.aggregationElement)}></arcgis-charts-config-field-select>`}renderXAxisField(){let e=this.getCorrectedXAxisValue();return r`<arcgis-charts-config-field-select .label=${e} @click=${this.onXAxisFieldSelect} ${m(this.xAxisFieldElement)}></arcgis-charts-config-field-select>`}renderSplitBy(){let e=this.getCorrectedSplitByValue();return r`<arcgis-charts-config-field-select .label=${e} .disabled=${this.disableSplitBy} @click=${this.onSplitBySelect} ${m(this.splitByFieldElement)}></arcgis-charts-config-field-select>`}renderNumericFields(e){let t=f(this.model.layer).idField,i=[];for(let a of e)a!==t&&i.push(this.buildNumericFieldItem(a));return r`<calcite-list label class=${s(n.fieldList)} ${m(this.numericFieldsElement)}>${i}</calcite-list>`}renderInterval(){let e=(this.model.temporalBinningSize??0)<=0,t=this.model.temporalBinningSize??"",i=S(this.model.temporalBinningUnit??b.Second,this._messages)??"",a=T(u),o={size:this.model.temporalBinningSize,unit:this.model.temporalBinningUnit},v=I(o,a);return[r`<calcite-list label selection-appearance=border><calcite-list-item .value=${e?"":`${t} ${i}`} .label=${e?"":`${t} ${i}`} @click=${e?()=>{}:this.onIntervalSelect} ${m(this.intervalElement)}><calcite-icon slot=content-end icon=pencil></calcite-icon></calcite-list-item></calcite-list>`,r`<div class=${s(n.linkContainer)}><calcite-button .disabled=${v} appearance=transparent scale=s icon-end=reset @click=${this.resetTimeIntervalOriginal}>${this._messages.reset}</calcite-button></div>`]}renderIntervalAlignment(){return r`<arcgis-charts-config-field-select .label=${this.timeAggregationLabel} @click=${this.onIntervalAlignmentSelect} ${m(this.intervalAlignmentElement)}></arcgis-charts-config-field-select>`}renderEmptyBins(){return r`<calcite-radio-button-group name=empty-bins layout=vertical @calciteRadioButtonGroupChange=${this.onNullPolicyChange}><calcite-label layout=inline><calcite-radio-button .value=${d.Zero} .checked=${this.model.nullPolicy===d.Zero}></calcite-radio-button>${this._messages.treatAsZero}</calcite-label><calcite-label layout=inline><calcite-radio-button .value=${d.Interpolate} .checked=${this.model.nullPolicy===d.Interpolate}></calcite-radio-button>${this._messages.connectLine}</calcite-label><calcite-label layout=inline><calcite-radio-button .value=${d.Null} .checked=${this.model.nullPolicy===d.Null}></calcite-radio-button>${this._messages.breakLine}</calcite-label></calcite-radio-button-group>`}render(){let e=this.renderAggregation(),t=this.renderXAxisField(),i=this.renderSplitBy(),a=this.renderNumericFields([...this.model.numericFields]),o=this.renderInterval(),v=this.renderIntervalAlignment(),D=this.renderEmptyBins();return r`<calcite-label class=${s(n.label)}>${this._messages.xAxisField}${t}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.aggregation}${e}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.numericFields}${a}</calcite-label><div class=${s(n.fab)}><calcite-fab appearance=outline-fill kind=neutral scale=m .label=${this._messages.selectNumericFields} text-enabled .text=${this._messages.selectNumericFields} icon=plus @click=${this.onAddNumericFields}></calcite-fab></div><calcite-label class=${s(n.label)}><span class=${s(this.disableSplitBy?n.dimText:"")}>${this._messages.splitBy}</span>${i}</calcite-label><div .hidden=${!this.shouldShowTimeBinning()}><h3 class=${s(n.timeBinningHeader)}>${this._messages.timeBinningOptions}</h3><calcite-label class=${s(n.label)}>${this._messages.interval}${o}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.intervalAlignment}${v}</calcite-label><calcite-label class=${s(n.label)} layout=inline-space-between>${this._messages.trimIncompleteInterval}<calcite-switch .checked=${this.model.trimIncompleteTimeInterval} @calciteSwitchChange=${this.onTrimIncompleteIntervalChange}></calcite-switch></calcite-label>${this.model.aggregationType!==c.Count?r`<calcite-label class=${s(n.label)}>${this._messages.emptyBins}${D}</calcite-label>`:null}</div><calcite-label class=${s(n.label)} layout=inline-space-between>${this._messages.showDataLabels}<calcite-switch .checked=${this.model.dataLabelsVisibility} @calciteSwitchChange=${this.onShowDataLabelsChange}></calcite-switch></calcite-label>`}};A("arcgis-charts-config-line-chart-data",$);return $},a,e)
2
+ import{a as u,c as P,d as T,f as _}from"./OBPAQN4H.js";import{a as w}from"./S7Z4HRW7.js";import{a as N}from"./IHO3OLL3.js";import{a as C}from"./JHANH4UG.js";import{f as l}from"./AK7X7SGI.js";import e from"./H4VTKKBN.js";import a from"./BFVFX476.js";import"./EZV7JSQJ.js";import{n as p,u as S}from"./3TBK72EK.js";import{wa as B,xa as k}from"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as I}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as m,B as F,C as s,F as x,H as A,g as y,i as r,n as g,z as h}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{b as c,k as b,n as d}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{rb:f,tb:E},{h:L}])=>{var z=y`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin);margin-top:var(--arcgis-charts-top-section-margin)}.label,.disabled-label{display:flex;margin-left:.5rem;margin-right:.5rem;margin-bottom:.5rem;justify-content:space-between}.time-binning-header{display:flex;font-weight:700;margin-left:.5rem;margin-right:.5rem;justify-content:space-between}.field-list{max-height:50vh;overflow-y:auto}.disabled-label{pointer-events:none}.fab{display:flex;margin-left:.5rem;margin-right:.5rem;margin-bottom:1.5rem;justify-content:center}.link-container{display:flex;justify-content:flex-end}`,n={label:"label",fieldList:"field-list",fab:"fab",timeBinningHeader:"time-binning-header",linkContainer:"link-container",dimText:"dim-text"},$=class extends F{constructor(){super(...arguments),this._messages=C(),this.commonStrings=C({name:"common",blocking:!0}),this.lineChartPopover=null,this.aggregationElement=h(),this.xAxisFieldElement=h(),this.numericFieldsElement=h(),this.splitByFieldElement=h(),this.intervalAlignmentElement=h(),this.intervalElement=h(),this.onLineChartDataChange=e=>{try{if(e.detail!==null&&e.detail?.value!==void 0){let{contentKind:t}=e.detail,i=[...e.detail.value];switch(P(u),t){case l.aggregation:this.model.aggregationType=i[0]!==c.NoAggregation?i[0]:c.NoAggregation;break;case l.xAxisField:{let a=i[0]?.trim()||"";this.model.xAxisField=a,this.arcgisChartsConfigResetTimeInterval.emit();break}case l.numericFields:this.model.numericFields=i,this.model.numericFields.length>0&&this.model.aggregationType===c.Count&&this.model.numericFields[0]!==f(this.model.layer).idField&&(this.model.aggregationType=c.Sum);break;case l.splitByField:{let a=i[0]?.trim()||"";this.model.splitByField=a,this.model.colorMatch=!0;break}case l.interval:this.model.temporalBinningSize=i[0]?.intervalSize,this.model.temporalBinningUnit=i[0]?.intervalUnits,this.arcgisChartsConfigCustomizedTimeInterval.emit();break;case l.intervalAlignment:this.model.timeAggregationType=i[0]??"";break;default:break}t!==l.interval&&t!==l.intervalAlignment&&_(u)}}catch(t){throw t instanceof Error&&this.arcgisChartsConfigDataChangeError.emit({error:t,model:this.model}),t}this.removeLineChartDataPopover(),this.requestUpdate()},this.onModelConfigChange=()=>{this.requestUpdate()},this.popoverClose=e=>{this.lineChartPopover===e?.target&&this.removeLineChartDataPopover()},this.layerFieldsInfo=[],this.arcgisChartsConfigCustomizedTimeInterval=g(),this.arcgisChartsConfigDataChangeError=g(),this.arcgisChartsConfigLineChartDataNumericFieldValidate=g(),this.arcgisChartsConfigResetTimeInterval=g()}static{this.properties={aggregationLabel:16,timeAggregationLabel:16,disableSplitBy:16,messageOverrides:0,model:0,resetTimeInterval:0,layerFieldsInfo:0}}static{this.styles=z}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),this.aggregationLabel=B(this.model.aggregationType,this.commonStrings);let t=this.model.timeAggregationType;t!==void 0&&(this.timeAggregationLabel=k(t,this.commonStrings)),this.disableSplitBy=this.model.numericFields.length>1}disconnectedCallback(){super.disconnectedCallback(),this.removeLineChartDataPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}buildNumericFieldItem(e){return w(e,r`<calcite-list-item .label=${p(this.layerFieldsInfo,e)} .value=${e} closable @calciteListItemClose=${this.onRemoveNumericField}></calcite-list-item>`)}resetTimeIntervalOriginal(e){this.popoverClose(e),this.model.resetTimeInterval!==void 0&&(this.model.resetTimeInterval(),this.arcgisChartsConfigResetTimeInterval.emit())}onAggregationSelect(e){this.contentKind=l.aggregation,this.setupPopover(e)}onXAxisFieldSelect(e){this.contentKind=l.xAxisField,this.setupPopover(e)}onSplitBySelect(e){this.splitByFieldElement.value&&!this.splitByFieldElement.value.disabled&&(this.contentKind=l.splitByField,this.setupPopover(e))}onAddNumericFields(e){this.contentKind=l.numericFields,this.setupPopover(e)}onRemoveNumericField(e){let t=e.target.value;this.model.numericFields=this.model.numericFields.filter(i=>i!==t)}onIntervalAlignmentSelect(e){this.intervalAlignmentElement.value&&!this.intervalAlignmentElement.value.disabled&&(this.contentKind=l.intervalAlignment,this.setupPopover(e))}onIntervalSelect(e){this.intervalElement.value&&!this.intervalElement.value.disabled&&(this.contentKind=l.interval,this.setupPopover(e))}getCorrectedSplitByValue(){return this.model.splitByField===""||this.model.numericFields.length>1?"":p(this.layerFieldsInfo,this.model.splitByField)}getCorrectedXAxisValue(){return L({fieldName:this.model.xAxisField,fieldList:this.layerFieldsInfo})?"":p(this.layerFieldsInfo,this.model.xAxisField)}onShowDataLabelsChange(e){this.model.dataLabelsVisibility=e.target.checked}onTrimIncompleteIntervalChange(e){this.model.trimIncompleteTimeInterval=e.target.checked}onNullPolicyChange(e){this.model.nullPolicy=e.target.selectedItem?.value}shouldShowTimeBinning(){let e=this.layerFieldsInfo.find(i=>i.name===this.model.xAxisField),t=this.model.aggregationType!==c.NoAggregation;return e!==void 0&&E(e)&&t}setupPopover(e){e.stopImmediatePropagation(),this.removeLineChartDataPopover();let t={size:this.model.temporalBinningSize??1,unit:this.model.temporalBinningUnit??b.Second},i,a,o;switch(this.contentKind){case l.aggregation:i=this.aggregationElement.value,a=this._messages.aggregationHeader,o=this.model.aggregationType;break;case l.xAxisField:i=this.xAxisFieldElement.value,a=this._messages.xAxisFieldHeader,o=this.model.xAxisField;break;case l.numericFields:i=this.numericFieldsElement.value,a=this._messages.numericFieldsHeader,o=this.model.numericFields;break;case l.splitByField:i=this.splitByFieldElement.value,a=this._messages.splitByFieldHeader,o=this.model.splitByField;break;case l.interval:i=this.intervalElement.value,a=this._messages.editInterval,o=t;break;case l.intervalAlignment:i=this.intervalAlignmentElement.value,a=this._messages.intervalAlignment,o=this.model.timeAggregationType??"";break}this.lineChartPopover=x(r`<arcgis-charts-config-line-chart-popover .headingTitle=${a} .referenceElement=${i} open .contentKind=${this.contentKind} .layerFieldsInfo=${this.layerFieldsInfo} .selectedContent=${o} @arcgisChartsConfigLineChartDataPopoverChange=${this.onLineChartDataChange} @arcgisChartsConfigLineChartPopoverClose=${this.popoverClose}></arcgis-charts-config-line-chart-popover>`),!document.body.contains(this.lineChartPopover)&&this.lineChartPopover!==null&&document.body.appendChild(this.lineChartPopover)}removeLineChartDataPopover(){this.lineChartPopover!==null&&(this.lineChartPopover.open=!1,this.lineChartPopover=N(this.lineChartPopover))}renderAggregation(){return r`<arcgis-charts-config-field-select .label=${this.model.aggregationType===c.NoAggregation?this._messages.noAggregation:this.aggregationLabel} @click=${this.onAggregationSelect} ${m(this.aggregationElement)}></arcgis-charts-config-field-select>`}renderXAxisField(){let e=this.getCorrectedXAxisValue();return r`<arcgis-charts-config-field-select .label=${e} @click=${this.onXAxisFieldSelect} ${m(this.xAxisFieldElement)}></arcgis-charts-config-field-select>`}renderSplitBy(){let e=this.getCorrectedSplitByValue();return r`<arcgis-charts-config-field-select .label=${e} .disabled=${this.disableSplitBy} @click=${this.onSplitBySelect} ${m(this.splitByFieldElement)}></arcgis-charts-config-field-select>`}renderNumericFields(e){let t=f(this.model.layer).idField,i=[];for(let a of e)a!==t&&i.push(this.buildNumericFieldItem(a));return r`<calcite-list label class=${s(n.fieldList)} ${m(this.numericFieldsElement)}>${i}</calcite-list>`}renderInterval(){let e=(this.model.temporalBinningSize??0)<=0,t=this.model.temporalBinningSize??"",i=S(this.model.temporalBinningUnit??b.Second,this._messages)??"",a=T(u),o={size:this.model.temporalBinningSize,unit:this.model.temporalBinningUnit},v=I(o,a);return[r`<calcite-list label selection-appearance=border><calcite-list-item .value=${e?"":`${t} ${i}`} .label=${e?"":`${t} ${i}`} @click=${e?()=>{}:this.onIntervalSelect} ${m(this.intervalElement)}><calcite-icon slot=content-end icon=pencil></calcite-icon></calcite-list-item></calcite-list>`,r`<div class=${s(n.linkContainer)}><calcite-button .disabled=${v} appearance=transparent scale=s icon-end=reset @click=${this.resetTimeIntervalOriginal}>${this._messages.reset}</calcite-button></div>`]}renderIntervalAlignment(){return r`<arcgis-charts-config-field-select .label=${this.timeAggregationLabel} @click=${this.onIntervalAlignmentSelect} ${m(this.intervalAlignmentElement)}></arcgis-charts-config-field-select>`}renderEmptyBins(){return r`<calcite-radio-button-group name=empty-bins layout=vertical @calciteRadioButtonGroupChange=${this.onNullPolicyChange}><calcite-label layout=inline><calcite-radio-button .value=${d.Zero} .checked=${this.model.nullPolicy===d.Zero}></calcite-radio-button>${this._messages.treatAsZero}</calcite-label><calcite-label layout=inline><calcite-radio-button .value=${d.Interpolate} .checked=${this.model.nullPolicy===d.Interpolate}></calcite-radio-button>${this._messages.connectLine}</calcite-label><calcite-label layout=inline><calcite-radio-button .value=${d.Null} .checked=${this.model.nullPolicy===d.Null}></calcite-radio-button>${this._messages.breakLine}</calcite-label></calcite-radio-button-group>`}render(){let e=this.renderAggregation(),t=this.renderXAxisField(),i=this.renderSplitBy(),a=this.renderNumericFields([...this.model.numericFields]),o=this.renderInterval(),v=this.renderIntervalAlignment(),D=this.renderEmptyBins();return r`<calcite-label class=${s(n.label)}>${this._messages.xAxisField}${t}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.aggregation}${e}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.numericFields}${a}</calcite-label><div class=${s(n.fab)}><calcite-fab appearance=outline-fill kind=neutral scale=m .label=${this._messages.selectNumericFields} text-enabled .text=${this._messages.selectNumericFields} icon=plus @click=${this.onAddNumericFields}></calcite-fab></div><calcite-label class=${s(n.label)}><span class=${s(this.disableSplitBy?n.dimText:"")}>${this._messages.splitBy}</span>${i}</calcite-label><div .hidden=${!this.shouldShowTimeBinning()}><h3 class=${s(n.timeBinningHeader)}>${this._messages.timeBinningOptions}</h3><calcite-label class=${s(n.label)}>${this._messages.interval}${o}</calcite-label><calcite-label class=${s(n.label)}>${this._messages.intervalAlignment}${v}</calcite-label><calcite-label class=${s(n.label)} layout=inline-space-between>${this._messages.trimIncompleteInterval}<calcite-switch .checked=${this.model.trimIncompleteTimeInterval} @calciteSwitchChange=${this.onTrimIncompleteIntervalChange}></calcite-switch></calcite-label>${this.model.aggregationType!==c.Count?r`<calcite-label class=${s(n.label)}>${this._messages.emptyBins}${D}</calcite-label>`:null}</div><calcite-label class=${s(n.label)} layout=inline-space-between>${this._messages.showDataLabels}<calcite-switch .checked=${this.model.dataLabelsVisibility} @calciteSwitchChange=${this.onShowDataLabelsChange}></calcite-switch></calcite-label>`}};A("arcgis-charts-config-line-chart-data",$);return $},a,e)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import o from"./IUMYBJDG.js";import n from"./IP3FZZNM.js";import m from"./ADJHTT4M.js";import k from"./XWDLT2E4.js";import"./THTYR6IL.js";import j from"./Y7HYSSRW.js";import i from"./6ODWWOUP.js";import"./Y7HBWU3M.js";import g from"./7LI5APDL.js";import e from"./L6SM2ORZ.js";import d from"./D46R6YHX.js";import"./WNKDEOFZ.js";import a from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import{E as p,O as v,X as l,ga as h,na as _}from"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import"./RIM4HLHN.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as c,b as f,s as b}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{rb:S},{b:I,q:C},,{c:i},,L,{b:B,d:E,f:W},{b:w,d:V,f:D},{d:T,e:A},F])=>{var M=t=>t.axes[0].needle?.visible??!0,P=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.visible=t},$=t=>t.axes[0].needle?.symbol,G=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.symbol=t},j=t=>t.axes[0].needle?.startWidth,q=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.startWidth=t},O=t=>t.axes[0].needle?.endWidth,N=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.endWidth=t},J=t=>t.axes[0].needle?.innerRadius,K=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.innerRadius=t},z=t=>t.axes[0].needle?.displayPin??!1,H=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.displayPin=t},Q=t=>t.axes[0].innerLabel?.visible??!0,U=(t,e)=>{e.axes[0].innerLabel===void 0&&(e.axes[0].innerLabel=p()),e.axes[0].innerLabel.visible=t},X=t=>t.axes[0].innerLabel?.content,Y=(t,e)=>{e.axes[0].innerLabel===void 0&&(e.axes[0].innerLabel=p()),t!==void 0&&(e.axes[0].innerLabel.content=t)},Z=t=>t.axes[0].progressBands?.visible??!0,ee=(t,e)=>{e.axes[0].progressBands===void 0&&(e.axes[0].progressBands={type:c.FixedProgressBands}),e.axes[0].progressBands.visible=t},te=t=>t.axes[0].progressBands,ne=(t,e)=>{t===void 0?delete e.axes[0].progressBands:e.axes[0].progressBands=t},se=t=>t.axes[0].ticks?.visible??!0,ie=(t,e)=>{e.axes[0].ticks===void 0&&(e.axes[0].ticks={type:c.GaugeAxisTick}),e.axes[0].ticks.visible=t},oe=t=>t.axes[0].labelsIncrement,re=(t,e)=>{e.axes[0].labelsIncrement=t},ae=t=>t.axes[0].onlyShowFirstAndLastLabels??!1,ge=(t,e)=>{e.axes[0].onlyShowFirstAndLastLabels=t},le=t=>t.series[0]?.valueConversion,de=(t,e)=>{e.series[0]!==void 0&&(e.series[0].valueConversion=t)},k=t=>t.series[0]?.featureIndex,R=t=>{let{featureIndex:e,config:n,layerInfo:a,commonStrings:r}=t,g=x(n),d=u(n);e===null?delete n.series[0].featureIndex:n.series[0]!==void 0&&(n.series[0].featureIndex=e),y({config:n,layerInfo:a,field:g,aggregationType:d,commonStrings:r})},ce=t=>t.subType??b.StatisticGauge,fe=t=>{let{config:e,field:n,aggregationType:a}=t;if(a!==f.NoAggregation){let r=k(e),g=m(r)?{}:{outStatistics:[{statisticType:a,onStatisticField:n,outStatisticFieldName:`${a}_${n}`}]};e.series[0].query=g}},pe=t=>{let{config:e,layerInfo:n,commonStrings:a,field:r,aggregationType:g}=t;e.title&&(e.title.content.text=I({config:e,layerInfo:n,commonStrings:a,numericFields:[r],aggregationType:g}))},y=t=>{let{config:e,field:n,aggregationType:a}=t;e.series[0]===void 0&&(e.series=[h({})]);let r=m(e.series[0]?.featureIndex),g=r?n:`${a}_${n}`;r&&n.startsWith(`${a}_`)&&(g=n.replace(`${a}_`,"")),e.series[0].x=g,fe({config:e,field:n,aggregationType:a}),pe(t)},u=t=>t.series[0]?.query?.outStatistics?.[0]?.statisticType??f.Count,he=t=>{let{config:e,layerInfo:n,commonStrings:a,aggregationType:r}=t,g=x(e);y({config:e,layerInfo:n,commonStrings:a,field:g,aggregationType:r})},m=t=>typeof t=="number"&&t>=0,x=t=>m(t.series[0]?.featureIndex)?t.series[0]?.x:t.series[0]?.query?.outStatistics?.[0]?.onStatisticField??"",ye=t=>{let{field:e,config:n,layerInfo:a,commonStrings:r}=t,g=u(n);y({config:n,layerInfo:a,commonStrings:r,field:e,aggregationType:g})},ue=t=>t.innerRadius??50,me=(t,e)=>{e.innerRadius=t},xe=t=>t.startAngle??-90,be=(t,e)=>{e.startAngle=t},ve=t=>t.endAngle??270,_e=(t,e)=>{e.endAngle=t};function Se(t){return v(t)}var Ie=Object.defineProperty,Ce=Object.getOwnPropertyDescriptor,o=(t,e,n,a)=>{for(var r=Ce(e,n),g=t.length-1,d;g>=0;g--)(d=t[g])&&(r=d(e,n,r)||r);return r&&Ie(e,n,r),r},s=class extends L{constructor(){super(...arguments),this._chartType=c.GaugeSeries}generateChartTitle(){return Se(this.commonStrings)}async setup(e){await this.loadConfigFromLayer(e),typeof this.resolveSetup=="function"&&this.resolveSetup()}get field(){return x(this._config)}set field(e){ye({field:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings}),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get aggregationType(){return u(this._config)}set aggregationType(e){he({aggregationType:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings}),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get innerRadius(){return ue(this._config)}set innerRadius(e){me(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get startAngle(){return xe(this._config)}set startAngle(e){be(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get endAngle(){return ve(this._config)}set endAngle(e){_e(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get valueConversion(){return le(this._config)}set valueConversion(e){de(e,this._config)}get featureIndex(){return k(this._config)}set featureIndex(e){R({featureIndex:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings})}removeFeatureIndex(){R({featureIndex:null,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings})}get gaugeSubType(){return ce(this._config)}get needleVisibility(){return M(this._config)}set needleVisibility(e){P(e,this._config)}get needleSymbol(){return $(this._config)}set needleSymbol(e){G(e,this._config)}get needleStartWidth(){return j(this._config)}set needleStartWidth(e){q(e,this._config)}get needleEndWidth(){return O(this._config)}set needleEndWidth(e){N(e,this._config)}get needleInnerRadius(){return J(this._config)}set needleInnerRadius(e){K(e,this._config)}get needleDisplayPin(){return z(this._config)}set needleDisplayPin(e){H(e,this._config)}get innerLabelVisible(){return Q(this._config)}set innerLabelVisible(e){U(e,this._config)}get innerLabelContent(){return X(this._config)}set innerLabelContent(e){Y(e,this._config)}get progressBandsVisibility(){return Z(this._config)}set progressBandsVisibility(e){ee(e,this._config)}get progressBands(){return te(this._config)}set progressBands(e){ne(e,this._config)}get axisTickVisibility(){return se(this._config)}set axisTickVisibility(e){ie(e,this._config)}get labelsIncrement(){return oe(this._config)}set labelsIncrement(e){re(e,this._config)}get onlyShowFirstAndLastLabels(){return ae(this._config)}set onlyShowFirstAndLastLabels(e){ge(e,this._config)}generateDefaultConfig(){let e=_(this.commonStrings);return e.series=[h({objectIDField:S(this.layerInfo.layer).idField})],e}};o([i],s.prototype,"field");o([i],s.prototype,"aggregationType");o([i],s.prototype,"innerRadius");o([i],s.prototype,"startAngle");o([i],s.prototype,"endAngle");o([i],s.prototype,"valueConversion");o([i],s.prototype,"featureIndex");o([i],s.prototype,"removeFeatureIndex");o([i],s.prototype,"needleVisibility");o([i],s.prototype,"needleSymbol");o([i],s.prototype,"needleStartWidth");o([i],s.prototype,"needleEndWidth");o([i],s.prototype,"needleInnerRadius");o([i],s.prototype,"needleDisplayPin");o([i],s.prototype,"innerLabelVisible");o([i],s.prototype,"innerLabelContent");o([i],s.prototype,"progressBandsVisibility");o([i],s.prototype,"progressBands");o([i],s.prototype,"axisTickVisibility");o([i],s.prototype,"labelsIncrement");o([i],s.prototype,"onlyShowFirstAndLastLabels");var Le=[w,T,V,A,B,E,W,D,F];C(s,Le);return s},a,d,e,g,i,j,k,m,n,o)
2
+ import o from"./CEBE6KZ5.js";import n from"./2VERKODU.js";import m from"./YFYTXRLW.js";import k from"./EJEUMMWZ.js";import"./THTYR6IL.js";import j from"./OPMJTZOV.js";import i from"./RKZ2IOOP.js";import"./Y7HBWU3M.js";import g from"./FVGXWZBY.js";import e from"./OOVQ6IVC.js";import d from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import a from"./BFVFX476.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import{E as p,O as v,X as l,ga as h,na as _}from"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import"./RIM4HLHN.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as c,b as f,s as b}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{rb:S},{b:I,q:C},,{c:i},,L,{b:B,d:E,f:W},{b:w,d:V,f:D},{d:T,e:A},F])=>{var M=t=>t.axes[0].needle?.visible??!0,P=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.visible=t},$=t=>t.axes[0].needle?.symbol,G=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.symbol=t},j=t=>t.axes[0].needle?.startWidth,q=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.startWidth=t},O=t=>t.axes[0].needle?.endWidth,N=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.endWidth=t},J=t=>t.axes[0].needle?.innerRadius,K=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.innerRadius=t},z=t=>t.axes[0].needle?.displayPin??!1,H=(t,e)=>{e.axes[0].needle===void 0&&(e.axes[0].needle=l()),e.axes[0].needle.displayPin=t},Q=t=>t.axes[0].innerLabel?.visible??!0,U=(t,e)=>{e.axes[0].innerLabel===void 0&&(e.axes[0].innerLabel=p()),e.axes[0].innerLabel.visible=t},X=t=>t.axes[0].innerLabel?.content,Y=(t,e)=>{e.axes[0].innerLabel===void 0&&(e.axes[0].innerLabel=p()),t!==void 0&&(e.axes[0].innerLabel.content=t)},Z=t=>t.axes[0].progressBands?.visible??!0,ee=(t,e)=>{e.axes[0].progressBands===void 0&&(e.axes[0].progressBands={type:c.FixedProgressBands}),e.axes[0].progressBands.visible=t},te=t=>t.axes[0].progressBands,ne=(t,e)=>{t===void 0?delete e.axes[0].progressBands:e.axes[0].progressBands=t},se=t=>t.axes[0].ticks?.visible??!0,ie=(t,e)=>{e.axes[0].ticks===void 0&&(e.axes[0].ticks={type:c.GaugeAxisTick}),e.axes[0].ticks.visible=t},oe=t=>t.axes[0].labelsIncrement,re=(t,e)=>{e.axes[0].labelsIncrement=t},ae=t=>t.axes[0].onlyShowFirstAndLastLabels??!1,ge=(t,e)=>{e.axes[0].onlyShowFirstAndLastLabels=t},le=t=>t.series[0]?.valueConversion,de=(t,e)=>{e.series[0]!==void 0&&(e.series[0].valueConversion=t)},k=t=>t.series[0]?.featureIndex,R=t=>{let{featureIndex:e,config:n,layerInfo:a,commonStrings:r}=t,g=x(n),d=u(n);e===null?delete n.series[0].featureIndex:n.series[0]!==void 0&&(n.series[0].featureIndex=e),y({config:n,layerInfo:a,field:g,aggregationType:d,commonStrings:r})},ce=t=>t.subType??b.StatisticGauge,fe=t=>{let{config:e,field:n,aggregationType:a}=t;if(a!==f.NoAggregation){let r=k(e),g=m(r)?{}:{outStatistics:[{statisticType:a,onStatisticField:n,outStatisticFieldName:`${a}_${n}`}]};e.series[0].query=g}},pe=t=>{let{config:e,layerInfo:n,commonStrings:a,field:r,aggregationType:g}=t;e.title&&(e.title.content.text=I({config:e,layerInfo:n,commonStrings:a,numericFields:[r],aggregationType:g}))},y=t=>{let{config:e,field:n,aggregationType:a}=t;e.series[0]===void 0&&(e.series=[h({})]);let r=m(e.series[0]?.featureIndex),g=r?n:`${a}_${n}`;r&&n.startsWith(`${a}_`)&&(g=n.replace(`${a}_`,"")),e.series[0].x=g,fe({config:e,field:n,aggregationType:a}),pe(t)},u=t=>t.series[0]?.query?.outStatistics?.[0]?.statisticType??f.Count,he=t=>{let{config:e,layerInfo:n,commonStrings:a,aggregationType:r}=t,g=x(e);y({config:e,layerInfo:n,commonStrings:a,field:g,aggregationType:r})},m=t=>typeof t=="number"&&t>=0,x=t=>m(t.series[0]?.featureIndex)?t.series[0]?.x:t.series[0]?.query?.outStatistics?.[0]?.onStatisticField??"",ye=t=>{let{field:e,config:n,layerInfo:a,commonStrings:r}=t,g=u(n);y({config:n,layerInfo:a,commonStrings:r,field:e,aggregationType:g})},ue=t=>t.innerRadius??50,me=(t,e)=>{e.innerRadius=t},xe=t=>t.startAngle??-90,be=(t,e)=>{e.startAngle=t},ve=t=>t.endAngle??270,_e=(t,e)=>{e.endAngle=t};function Se(t){return v(t)}var Ie=Object.defineProperty,Ce=Object.getOwnPropertyDescriptor,o=(t,e,n,a)=>{for(var r=Ce(e,n),g=t.length-1,d;g>=0;g--)(d=t[g])&&(r=d(e,n,r)||r);return r&&Ie(e,n,r),r},s=class extends L{constructor(){super(...arguments),this._chartType=c.GaugeSeries}generateChartTitle(){return Se(this.commonStrings)}async setup(e){await this.loadConfigFromLayer(e),typeof this.resolveSetup=="function"&&this.resolveSetup()}get field(){return x(this._config)}set field(e){ye({field:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings}),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get aggregationType(){return u(this._config)}set aggregationType(e){he({aggregationType:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings}),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get innerRadius(){return ue(this._config)}set innerRadius(e){me(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get startAngle(){return xe(this._config)}set startAngle(e){be(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get endAngle(){return ve(this._config)}set endAngle(e){_e(e,this._config),this.dispatchEvent(new CustomEvent("arcgisChartsModelDataChange"))}get valueConversion(){return le(this._config)}set valueConversion(e){de(e,this._config)}get featureIndex(){return k(this._config)}set featureIndex(e){R({featureIndex:e,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings})}removeFeatureIndex(){R({featureIndex:null,config:this._config,layerInfo:this.layerInfo,commonStrings:this.commonStrings})}get gaugeSubType(){return ce(this._config)}get needleVisibility(){return M(this._config)}set needleVisibility(e){P(e,this._config)}get needleSymbol(){return $(this._config)}set needleSymbol(e){G(e,this._config)}get needleStartWidth(){return j(this._config)}set needleStartWidth(e){q(e,this._config)}get needleEndWidth(){return O(this._config)}set needleEndWidth(e){N(e,this._config)}get needleInnerRadius(){return J(this._config)}set needleInnerRadius(e){K(e,this._config)}get needleDisplayPin(){return z(this._config)}set needleDisplayPin(e){H(e,this._config)}get innerLabelVisible(){return Q(this._config)}set innerLabelVisible(e){U(e,this._config)}get innerLabelContent(){return X(this._config)}set innerLabelContent(e){Y(e,this._config)}get progressBandsVisibility(){return Z(this._config)}set progressBandsVisibility(e){ee(e,this._config)}get progressBands(){return te(this._config)}set progressBands(e){ne(e,this._config)}get axisTickVisibility(){return se(this._config)}set axisTickVisibility(e){ie(e,this._config)}get labelsIncrement(){return oe(this._config)}set labelsIncrement(e){re(e,this._config)}get onlyShowFirstAndLastLabels(){return ae(this._config)}set onlyShowFirstAndLastLabels(e){ge(e,this._config)}generateDefaultConfig(){let e=_(this.commonStrings);return e.series=[h({objectIDField:S(this.layerInfo.layer).idField})],e}};o([i],s.prototype,"field");o([i],s.prototype,"aggregationType");o([i],s.prototype,"innerRadius");o([i],s.prototype,"startAngle");o([i],s.prototype,"endAngle");o([i],s.prototype,"valueConversion");o([i],s.prototype,"featureIndex");o([i],s.prototype,"removeFeatureIndex");o([i],s.prototype,"needleVisibility");o([i],s.prototype,"needleSymbol");o([i],s.prototype,"needleStartWidth");o([i],s.prototype,"needleEndWidth");o([i],s.prototype,"needleInnerRadius");o([i],s.prototype,"needleDisplayPin");o([i],s.prototype,"innerLabelVisible");o([i],s.prototype,"innerLabelContent");o([i],s.prototype,"progressBandsVisibility");o([i],s.prototype,"progressBands");o([i],s.prototype,"axisTickVisibility");o([i],s.prototype,"labelsIncrement");o([i],s.prototype,"onlyShowFirstAndLastLabels");var Le=[w,T,V,A,B,E,W,D,F];C(s,Le);return s},a,d,e,g,i,j,k,m,n,o)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import{a as u}from"./AQIB3VEP.js";import{a as f}from"./S7Z4HRW7.js";import{a as o}from"./IHO3OLL3.js";import d from"./LSKFMUX4.js";import{a as S}from"./JHANH4UG.js";import"./AK7X7SGI.js";import b from"./D46R6YHX.js";import"./WNKDEOFZ.js";import a from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import{d as p}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as c,D as m,F as g,H as C,g as h,i as r}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{p:v}])=>{var O=h`:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin)}`,l=class extends c{constructor(){super(...arguments),this._messages=S(),this.seriesPopover=null,this.open=!1,this.seriesNameChange=e=>{if(e.detail!==null||e.detail!==void 0){let s=e.detail?.name;this.model.setSeriesName(s,this.selectedSeriesIndex??-1)}},this.seriesColorChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{color:s}=e.detail;this.model.colorMatch=!1,s!==void 0&&(this.model.setSeriesColor(s,this.selectedSeriesIndex??-1),this.model.setSeriesMarkerColor(s,this.selectedSeriesIndex??-1))}},this.seriesLineStyleChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{lineStyle:s}=e.detail;s!==void 0&&this.model.setSeriesLineStyle(s,this.selectedSeriesIndex??-1)}},this.seriesLineWidthChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{lineWidth:s}=e.detail;s!==void 0&&(this.model.setSeriesLineWidth(s,this.selectedSeriesIndex??-1),this.model.setSeriesMarkerSize(s*2,this.selectedSeriesIndex??-1))}},this.seriesPopoverClose=e=>{let{selectedSeriesIndex:s}=e.detail;this.selectedSeriesIndex===s&&(this.seriesPopover=o(this.seriesPopover),this.selectedSeriesIndex=void 0)},this.onModelConfigChange=()=>{this.requestUpdate()},this.seriesOrderResetCounter=0,this.activeColorMatch=!1,this.popoverPlacement="leading"}static{this.properties={selectedSeriesIndex:16,seriesOrderResetCounter:16,messageOverrides:0,model:0,activeColorMatch:5,popoverPlacement:1}}static{this.styles=O}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("selectedSeriesIndex")&&this.selectedSeriesIndexChange()}disconnectedCallback(){super.disconnectedCallback(),this.removeSeriesPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,s){s?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}selectedSeriesIndexChange(){this.selectedSeriesIndex!==void 0&&(this.seriesPopover=g(r`<arcgis-charts-config-line-chart-series-popover .referenceElement=${this.el} .selectedName=${this.model.getSeriesName(this.selectedSeriesIndex)} .selectedColor=${this.model.getSeriesColor(this.selectedSeriesIndex)} .selectedLineStyle=${this.model.getSeriesLineStyle(this.selectedSeriesIndex)} .selectedLineWidth=${this.model.getSeriesLineWidth(this.selectedSeriesIndex)} .placement=${this.popoverPlacement} .open=${this.open} .selectedSeriesIndex=${this.selectedSeriesIndex} @arcgisChartsConfigSeriesPopoverNameChange=${this.seriesNameChange} @arcgisChartsConfigSeriesPopoverColorChange=${this.seriesColorChange} @arcgisChartsConfigSeriesPopoverLineStyleChange=${this.seriesLineStyleChange} @arcgisChartsConfigSeriesPopoverLineWidthChange=${this.seriesLineWidthChange} @arcgisChartsConfigPopoverClose=${this.seriesPopoverClose}></arcgis-charts-config-line-chart-series-popover>`),this.seriesPopover&&!document.body.contains(this.seriesPopover)&&document.body.appendChild(this.seriesPopover))}removeSeriesPopover(){this.seriesPopover!==void 0&&this.seriesPopover!==null&&(this.seriesPopover.open=!1,this.seriesPopover=o(this.seriesPopover))}buildSeriesListItems(){let e=this.model.seriesLength,s=Array.from({length:e},(i,t)=>t);return u(s,i=>this.model.getSeriesId(i),i=>{let t=this.model.getSeriesId(i),n=this.model.getSeriesColor(i),I=this.model.getSeriesName(i),x=this.model.chartSubType===p.BarAndLineFromFields?this._messages.series:t,$=this.model.getSeriesLineStyle(i),P=v($),a="#CCCCCC",d="minus-circle";if((e>1||!this.activeColorMatch)&&n!==void 0){d=`line-${P}`;let[L,b,y,M]=[...n];a=`rgba(${L},${b},${y},${M/255})`}return r`<calcite-list-item .label=${I??t??""} .description=${x} .value=${t} .selected=${this.selectedSeriesIndex===i} @click=${this.openSeriesPopOver}><calcite-icon slot=content-end .icon=${d} style=${m({color:a})}></calcite-icon></calcite-list-item>`})}buildSeriesList(){return f(this.seriesOrderResetCounter,r`<calcite-list label drag-enabled selection-mode=single selection-appearance=border @calciteListOrderChange=${this.onCalciteListOrderChange}>${this.buildSeriesListItems()}</calcite-list>`)}resetSeriesOriginal(){this.selectedSeriesIndex=void 0,this.model.resetSeriesStyling(),this.seriesOrderResetCounter+=1}onCalciteListOrderChange(e){if(e.detail!==null&&e.detail!==void 0){let{newIndex:s,oldIndex:i}=e.detail;this.model.moveSeries(i??0,s??i??0),this.seriesOrderResetCounter+=1}}openSeriesPopOver(e){e.stopImmediatePropagation(),this.removeSeriesPopover();let s=e.target,i=s.localName==="calcite-list-item"?s:s.parentNode,t=this.model.getSeriesIndex(i.value);this.open=this.selectedSeriesIndex!==t,this.selectedSeriesIndex=this.selectedSeriesIndex!==t?t:void 0}render(){return r`<calcite-panel .heading=${this._messages.series}><calcite-button slot=header-actions-end @click=${this.resetSeriesOriginal} .disabled=${!this.model.resetAvailable()} appearance=transparent scale=s icon-end=reset>${this._messages.reset}</calcite-button>${this.buildSeriesList()}</calcite-panel>`}};C("arcgis-charts-config-line-chart-series",l);return l},a,b,d)
2
+ import{a as u}from"./AQIB3VEP.js";import{a as f}from"./S7Z4HRW7.js";import{a as o}from"./IHO3OLL3.js";import d from"./VQFCYPDR.js";import{a as S}from"./JHANH4UG.js";import"./AK7X7SGI.js";import b from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import a from"./BFVFX476.js";import"./EZV7JSQJ.js";import{d as p}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as c,D as m,F as g,H as C,g as h,i as r}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{p:v}])=>{var O=h`:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin)}`,l=class extends c{constructor(){super(...arguments),this._messages=S(),this.seriesPopover=null,this.open=!1,this.seriesNameChange=e=>{if(e.detail!==null||e.detail!==void 0){let s=e.detail?.name;this.model.setSeriesName(s,this.selectedSeriesIndex??-1)}},this.seriesColorChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{color:s}=e.detail;this.model.colorMatch=!1,s!==void 0&&(this.model.setSeriesColor(s,this.selectedSeriesIndex??-1),this.model.setSeriesMarkerColor(s,this.selectedSeriesIndex??-1))}},this.seriesLineStyleChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{lineStyle:s}=e.detail;s!==void 0&&this.model.setSeriesLineStyle(s,this.selectedSeriesIndex??-1)}},this.seriesLineWidthChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{lineWidth:s}=e.detail;s!==void 0&&(this.model.setSeriesLineWidth(s,this.selectedSeriesIndex??-1),this.model.setSeriesMarkerSize(s*2,this.selectedSeriesIndex??-1))}},this.seriesPopoverClose=e=>{let{selectedSeriesIndex:s}=e.detail;this.selectedSeriesIndex===s&&(this.seriesPopover=o(this.seriesPopover),this.selectedSeriesIndex=void 0)},this.onModelConfigChange=()=>{this.requestUpdate()},this.seriesOrderResetCounter=0,this.activeColorMatch=!1,this.popoverPlacement="leading"}static{this.properties={selectedSeriesIndex:16,seriesOrderResetCounter:16,messageOverrides:0,model:0,activeColorMatch:5,popoverPlacement:1}}static{this.styles=O}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("selectedSeriesIndex")&&this.selectedSeriesIndexChange()}disconnectedCallback(){super.disconnectedCallback(),this.removeSeriesPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,s){s?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}selectedSeriesIndexChange(){this.selectedSeriesIndex!==void 0&&(this.seriesPopover=g(r`<arcgis-charts-config-line-chart-series-popover .referenceElement=${this.el} .selectedName=${this.model.getSeriesName(this.selectedSeriesIndex)} .selectedColor=${this.model.getSeriesColor(this.selectedSeriesIndex)} .selectedLineStyle=${this.model.getSeriesLineStyle(this.selectedSeriesIndex)} .selectedLineWidth=${this.model.getSeriesLineWidth(this.selectedSeriesIndex)} .placement=${this.popoverPlacement} .open=${this.open} .selectedSeriesIndex=${this.selectedSeriesIndex} @arcgisChartsConfigSeriesPopoverNameChange=${this.seriesNameChange} @arcgisChartsConfigSeriesPopoverColorChange=${this.seriesColorChange} @arcgisChartsConfigSeriesPopoverLineStyleChange=${this.seriesLineStyleChange} @arcgisChartsConfigSeriesPopoverLineWidthChange=${this.seriesLineWidthChange} @arcgisChartsConfigPopoverClose=${this.seriesPopoverClose}></arcgis-charts-config-line-chart-series-popover>`),this.seriesPopover&&!document.body.contains(this.seriesPopover)&&document.body.appendChild(this.seriesPopover))}removeSeriesPopover(){this.seriesPopover!==void 0&&this.seriesPopover!==null&&(this.seriesPopover.open=!1,this.seriesPopover=o(this.seriesPopover))}buildSeriesListItems(){let e=this.model.seriesLength,s=Array.from({length:e},(i,t)=>t);return u(s,i=>this.model.getSeriesId(i),i=>{let t=this.model.getSeriesId(i),n=this.model.getSeriesColor(i),I=this.model.getSeriesName(i),x=this.model.chartSubType===p.BarAndLineFromFields?this._messages.series:t,$=this.model.getSeriesLineStyle(i),P=v($),a="#CCCCCC",d="minus-circle";if((e>1||!this.activeColorMatch)&&n!==void 0){d=`line-${P}`;let[L,b,y,M]=[...n];a=`rgba(${L},${b},${y},${M/255})`}return r`<calcite-list-item .label=${I??t??""} .description=${x} .value=${t} .selected=${this.selectedSeriesIndex===i} @click=${this.openSeriesPopOver}><calcite-icon slot=content-end .icon=${d} style=${m({color:a})}></calcite-icon></calcite-list-item>`})}buildSeriesList(){return f(this.seriesOrderResetCounter,r`<calcite-list label drag-enabled selection-mode=single selection-appearance=border @calciteListOrderChange=${this.onCalciteListOrderChange}>${this.buildSeriesListItems()}</calcite-list>`)}resetSeriesOriginal(){this.selectedSeriesIndex=void 0,this.model.resetSeriesStyling(),this.seriesOrderResetCounter+=1}onCalciteListOrderChange(e){if(e.detail!==null&&e.detail!==void 0){let{newIndex:s,oldIndex:i}=e.detail;this.model.moveSeries(i??0,s??i??0),this.seriesOrderResetCounter+=1}}openSeriesPopOver(e){e.stopImmediatePropagation(),this.removeSeriesPopover();let s=e.target,i=s.localName==="calcite-list-item"?s:s.parentNode,t=this.model.getSeriesIndex(i.value);this.open=this.selectedSeriesIndex!==t,this.selectedSeriesIndex=this.selectedSeriesIndex!==t?t:void 0}render(){return r`<calcite-panel .heading=${this._messages.series}><calcite-button slot=header-actions-end @click=${this.resetSeriesOriginal} .disabled=${!this.model.resetAvailable()} appearance=transparent scale=s icon-end=reset>${this._messages.reset}</calcite-button>${this.buildSeriesList()}</calcite-panel>`}};C("arcgis-charts-config-line-chart-series",l);return l},a,b,d)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import{a as L}from"./AQIB3VEP.js";import{a as P}from"./S7Z4HRW7.js";import{a as C}from"./IHO3OLL3.js";import h from"./LSKFMUX4.js";import{a as k}from"./JHANH4UG.js";import"./AK7X7SGI.js";import e from"./D46R6YHX.js";import"./WNKDEOFZ.js";import c from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import{c as u,d as x}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as $,C as a,D as d,F as g,H as y,g as f,i as o,n as b}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{b as p,f as r}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{r:I}])=>{var _={stackedType:"stacked-type"},l={topSection:"top-section",sectionLabel:"section-label",list:"list",disabledInfo:"disabled-info",disabledStackingOption:"disabled-stacking-option"},E=f`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin)}.top-section{margin-top:var(--arcgis-charts-config-margin-minor)}.section-label{display:flex;margin-bottom:var(--arcgis-charts-config-margin-major);margin-left:var(--arcgis-charts-config-margin-minor);margin-right:var(--arcgis-charts-config-margin-minor);justify-content:space-between;align-items:center;font-weight:var(--calcite-font-weight-medium);font-size:var(--calcite-font-size-0)}.list{margin-left:var(--arcgis-charts-config-margin-minor);margin-right:var(--arcgis-charts-config-margin-minor);margin-bottom:var(--arcgis-charts-config-margin-major)}.disabled-info{margin:auto 1rem;pointer-events:auto}.disabled-info:active{margin:auto 1rem;pointer-events:none}.disabled-stacking-option{pointer-events:none;opacity:var(--calcite-opacity-disabled)}`,v=class extends ${constructor(){super(...arguments),this._messages=k(),this.open=!1,this.seriesNameChange=e=>{if(e.detail!==null&&e.detail!==void 0){let t=e.detail.name;if(this.isNullCategorySelected){let i=this.model.nullCategory;if(i){let s={...i,text:t};this.model.nullCategory=s}}else this.model.setSeriesName(t,this.selectedSeriesIndex??-1)}},this.seriesColorChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{color:t}=e.detail;if(t!==void 0){if(this.isNullCategorySelected){let i=this.model.nullCategory,s=i?.symbol&&{...i,symbol:{...i.symbol,color:t,outline:i.symbol.outline&&{...i.symbol.outline,color:t}}};this.model.nullCategory=s}else this.model.setSeriesColor(t,this.selectedSeriesIndex??-1);this.model.colorMatch=!1}}},this.seriesPopoverClose=e=>{let{selectedSeriesIndex:t}=e.detail;this.selectedSeriesIndex===t&&(this.seriesPopover=C(this.seriesPopover),this.selectedSeriesIndex=void 0)},this.onModelConfigChange=()=>{this.requestUpdate()},this.seriesOrderResetCounter=0,this.activeColorMatch=!1,this.popoverPlacement="leading",this.arcgisChartsConfigDataChangeError=b()}static{this.properties={seriesOrderResetCounter:16,selectedSeriesIndex:16,messageOverrides:0,model:0,activeColorMatch:5,popoverPlacement:1}}static{this.styles=E}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("selectedSeriesIndex")&&this.selectedSeriesIndexChange()}disconnectedCallback(){super.disconnectedCallback(),this.removeSeriesPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}removeSeriesPopover(){this.seriesPopover!==null&&this.seriesPopover!==void 0&&(this.seriesPopover.open=!1,this.seriesPopover=C(this.seriesPopover))}selectedSeriesIndexChange(){this.selectedSeriesIndex!==void 0&&(this.seriesPopover=g(o`<arcgis-charts-config-bar-chart-series-popover .referenceElement=${this.el} .selectedName=${this.selectedSeriesIndex!=null?this.model.getSeriesName(this.selectedSeriesIndex):void 0} .selectedColor=${this.selectedSeriesIndex!=null?this.model.getSeriesColor(this.selectedSeriesIndex):void 0} .placement=${this.popoverPlacement} .selectedSeriesIndex=${this.selectedSeriesIndex!=null?this.selectedSeriesIndex:void 0} .nullCategory=${this.isNullCategorySelected?this.model.nullCategory:void 0} .open=${this.open} @arcgisChartsConfigSeriesPopoverNameChange=${this.seriesNameChange} @arcgisChartsConfigSeriesPopoverColorChange=${this.seriesColorChange} @arcgisChartsConfigPopoverClose=${this.seriesPopoverClose}></arcgis-charts-config-bar-chart-series-popover>`),this.seriesPopover&&!document.body.contains(this.seriesPopover)&&document.body.appendChild(this.seriesPopover))}buildSeriesListItems(){let e=this.model.seriesLength??0,t=Array.from({length:e},(i,s)=>s);return L(t,i=>this.model.getSeriesId(i),i=>{let s=this.model.getSeriesId(i),n=this.model.getSeriesColor(i),h=this.model.getSeriesName(i),m=this.model.chartSubType===x.BarAndLineFromFields?this._messages.series:s,c="#CCCCCC",S="minus-square";if((e>1||!this.activeColorMatch)&&n!==void 0){S="square-f";let[T,M,N,O]=[...n];c=`rgba(${T},${M},${N},${O/255})`}return o`<calcite-list-item .label=${h??s??""} .description=${m} .value=${s} .selected=${this.selectedSeriesIndex===i} @click=${this.openSeriesPopOver}><calcite-icon .icon=${S} style=${d({color:c})} slot=content-end></calcite-icon></calcite-list-item>`})}buildSeriesList(){return P(this.seriesOrderResetCounter,o`<calcite-list label class=${a(l.list)} drag-enabled selection-mode=single selection-appearance=border @calciteListOrderChange=${this.onCalciteListOrderChange}>${this.buildSeriesListItems()}</calcite-list>`)}buildNullCategoryUI(){let e=this.model.nullCategory,t=this._messages.nullCategory,i=e?.symbol?.color??u.nullCategory?.symbol?.color??u.grayColor,[s,n,h,m]=[...i],c=`rgba(${s},${n},${h},${m/255})`;return o`<calcite-list label class=${a(l.list)} selection-mode=none><calcite-list-item .label=${t} .value=${t} .selected=${this.selectedSeriesIndex===null} @click=${this.openSeriesPopOver}><calcite-icon icon=square-f style=${d({color:c})} slot=content-end></calcite-icon></calcite-list-item></calcite-list>`}buildMultipleBarTypeList(){let e=this.shouldDisableStacking();return e&&this.model.stackedType!==r.Side&&(this.model.stackedType=r.Side),o`<calcite-list label id=${_.stackedType} class=${a(l.list)} selection-mode=single-persist selection-appearance=border @click=${this.onMultipleBarSelect}><calcite-list-item .label=${this._messages.sideBySide} .value=${r.Side} .selected=${this.model.stackedType===void 0||this.model.stackedType===r.Side}><calcite-icon scale=l icon=graph-bar-side-by-side slot=content-start></calcite-icon></calcite-list-item><calcite-list-item class=${a(e?l.disabledStackingOption:"")} .label=${this._messages.stacked} .value=${r.Stacked} .selected=${this.model.stackedType===r.Stacked}><calcite-icon scale=l icon=graph-bar-stacked slot=content-start></calcite-icon>${e&&o`<calcite-icon class=${a(l.disabledInfo)} slot=content-end icon=information scale=s flip-rtl @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip}></calcite-icon>`||""}</calcite-list-item><calcite-list-item class=${a(e?l.disabledStackingOption:"")} .label=${this._messages.stacked100} .value=${r.Stacked100} .selected=${this.model.stackedType===r.Stacked100}><calcite-icon scale=l icon=graph-bar100-stacked slot=content-start></calcite-icon>${e&&o`<calcite-icon class=${a(l.disabledInfo)} slot=content-end icon=information scale=s flip-rtl @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip}></calcite-icon>`||""}</calcite-list-item></calcite-list>`}resetSeriesOriginal(){this.selectedSeriesIndex=void 0,this.model.resetSeriesStyling(),this.seriesOrderResetCounter+=1}onMultipleBarSelect(e){if(!this.shouldDisableStacking()){let t=e.target;this.model.stackedType=t.value??t.parentElement.value??""}}onCalciteListOrderChange(e){if(e.detail!==null&&e.detail!==void 0){let{newIndex:t,oldIndex:i}=e.detail;this.model.moveSeries(i??0,t??i??0),this.seriesOrderResetCounter+=1}}openSeriesPopOver(e){e.stopImmediatePropagation(),this.removeSeriesPopover();let t=e.target,i=t.localName==="calcite-list-item"?t:t.parentNode,s=this.model.getSeriesIndex(i.value);this.open=this.selectedSeriesIndex!==s,this.selectedSeriesIndex=this.selectedSeriesIndex!==s?s:void 0,this.isNullCategorySelected=i.value===this._messages.nullCategory}createTooltip(e){let t=e.target,i=(this.model.aggregationType===p.NoAggregation?this._messages.noAggStackingDisabled:this._messages.singleStackingDisabled)??"";this.tooltip=g(o`<calcite-tooltip style=${d({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${t} open placement=top>${i}</calcite-tooltip>`),document.body.appendChild(this.tooltip)}destroyTooltip(){I(this.tooltip)}shouldDisableStacking(){return(this.model.seriesLength??0)<=1||this.model.aggregationType===p.NoAggregation}render(){return o`<div class=${`${l.sectionLabel} ${l.topSection}`}>${this._messages.displayMultiSeries}</div>${this.buildMultipleBarTypeList()}<div class=${a(l.sectionLabel)}>${this._messages.series}<calcite-button @click=${this.resetSeriesOriginal} .disabled=${!this.model.resetAvailable()} appearance=transparent icon-end=reset>${this._messages.reset}</calcite-button></div>${this.buildSeriesList()}${this.model.nullCategory!==void 0&&this.model.fetchNULLValues?this.buildNullCategoryUI():null}`}};y("arcgis-charts-config-bar-chart-series",v);return v},c,e,h)
2
+ import{a as L}from"./AQIB3VEP.js";import{a as P}from"./S7Z4HRW7.js";import{a as C}from"./IHO3OLL3.js";import h from"./VQFCYPDR.js";import{a as k}from"./JHANH4UG.js";import"./AK7X7SGI.js";import e from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import c from"./BFVFX476.js";import"./EZV7JSQJ.js";import{c as u,d as x}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as $,C as a,D as d,F as g,H as y,g as f,i as o,n as b}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{b as p,f as r}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{r:I}])=>{var _={stackedType:"stacked-type"},l={topSection:"top-section",sectionLabel:"section-label",list:"list",disabledInfo:"disabled-info",disabledStackingOption:"disabled-stacking-option"},E=f`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;width:var(--arcgis-charts-config-calcite-block-default-width);margin:var(--arcgis-charts-config-calcite-block-default-margin)}.top-section{margin-top:var(--arcgis-charts-config-margin-minor)}.section-label{display:flex;margin-bottom:var(--arcgis-charts-config-margin-major);margin-left:var(--arcgis-charts-config-margin-minor);margin-right:var(--arcgis-charts-config-margin-minor);justify-content:space-between;align-items:center;font-weight:var(--calcite-font-weight-medium);font-size:var(--calcite-font-size-0)}.list{margin-left:var(--arcgis-charts-config-margin-minor);margin-right:var(--arcgis-charts-config-margin-minor);margin-bottom:var(--arcgis-charts-config-margin-major)}.disabled-info{margin:auto 1rem;pointer-events:auto}.disabled-info:active{margin:auto 1rem;pointer-events:none}.disabled-stacking-option{pointer-events:none;opacity:var(--calcite-opacity-disabled)}`,v=class extends ${constructor(){super(...arguments),this._messages=k(),this.open=!1,this.seriesNameChange=e=>{if(e.detail!==null&&e.detail!==void 0){let t=e.detail.name;if(this.isNullCategorySelected){let i=this.model.nullCategory;if(i){let s={...i,text:t};this.model.nullCategory=s}}else this.model.setSeriesName(t,this.selectedSeriesIndex??-1)}},this.seriesColorChange=e=>{if(e.detail!==null&&e.detail!==void 0){let{color:t}=e.detail;if(t!==void 0){if(this.isNullCategorySelected){let i=this.model.nullCategory,s=i?.symbol&&{...i,symbol:{...i.symbol,color:t,outline:i.symbol.outline&&{...i.symbol.outline,color:t}}};this.model.nullCategory=s}else this.model.setSeriesColor(t,this.selectedSeriesIndex??-1);this.model.colorMatch=!1}}},this.seriesPopoverClose=e=>{let{selectedSeriesIndex:t}=e.detail;this.selectedSeriesIndex===t&&(this.seriesPopover=C(this.seriesPopover),this.selectedSeriesIndex=void 0)},this.onModelConfigChange=()=>{this.requestUpdate()},this.seriesOrderResetCounter=0,this.activeColorMatch=!1,this.popoverPlacement="leading",this.arcgisChartsConfigDataChangeError=b()}static{this.properties={seriesOrderResetCounter:16,selectedSeriesIndex:16,messageOverrides:0,model:0,activeColorMatch:5,popoverPlacement:1}}static{this.styles=E}load(){this.modelChange(this.model),this.onModelConfigChange()}willUpdate(e){e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("selectedSeriesIndex")&&this.selectedSeriesIndexChange()}disconnectedCallback(){super.disconnectedCallback(),this.removeSeriesPopover(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,t){t?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}removeSeriesPopover(){this.seriesPopover!==null&&this.seriesPopover!==void 0&&(this.seriesPopover.open=!1,this.seriesPopover=C(this.seriesPopover))}selectedSeriesIndexChange(){this.selectedSeriesIndex!==void 0&&(this.seriesPopover=g(o`<arcgis-charts-config-bar-chart-series-popover .referenceElement=${this.el} .selectedName=${this.selectedSeriesIndex!=null?this.model.getSeriesName(this.selectedSeriesIndex):void 0} .selectedColor=${this.selectedSeriesIndex!=null?this.model.getSeriesColor(this.selectedSeriesIndex):void 0} .placement=${this.popoverPlacement} .selectedSeriesIndex=${this.selectedSeriesIndex!=null?this.selectedSeriesIndex:void 0} .nullCategory=${this.isNullCategorySelected?this.model.nullCategory:void 0} .open=${this.open} @arcgisChartsConfigSeriesPopoverNameChange=${this.seriesNameChange} @arcgisChartsConfigSeriesPopoverColorChange=${this.seriesColorChange} @arcgisChartsConfigPopoverClose=${this.seriesPopoverClose}></arcgis-charts-config-bar-chart-series-popover>`),this.seriesPopover&&!document.body.contains(this.seriesPopover)&&document.body.appendChild(this.seriesPopover))}buildSeriesListItems(){let e=this.model.seriesLength??0,t=Array.from({length:e},(i,s)=>s);return L(t,i=>this.model.getSeriesId(i),i=>{let s=this.model.getSeriesId(i),n=this.model.getSeriesColor(i),h=this.model.getSeriesName(i),m=this.model.chartSubType===x.BarAndLineFromFields?this._messages.series:s,c="#CCCCCC",S="minus-square";if((e>1||!this.activeColorMatch)&&n!==void 0){S="square-f";let[T,M,N,O]=[...n];c=`rgba(${T},${M},${N},${O/255})`}return o`<calcite-list-item .label=${h??s??""} .description=${m} .value=${s} .selected=${this.selectedSeriesIndex===i} @click=${this.openSeriesPopOver}><calcite-icon .icon=${S} style=${d({color:c})} slot=content-end></calcite-icon></calcite-list-item>`})}buildSeriesList(){return P(this.seriesOrderResetCounter,o`<calcite-list label class=${a(l.list)} drag-enabled selection-mode=single selection-appearance=border @calciteListOrderChange=${this.onCalciteListOrderChange}>${this.buildSeriesListItems()}</calcite-list>`)}buildNullCategoryUI(){let e=this.model.nullCategory,t=this._messages.nullCategory,i=e?.symbol?.color??u.nullCategory?.symbol?.color??u.grayColor,[s,n,h,m]=[...i],c=`rgba(${s},${n},${h},${m/255})`;return o`<calcite-list label class=${a(l.list)} selection-mode=none><calcite-list-item .label=${t} .value=${t} .selected=${this.selectedSeriesIndex===null} @click=${this.openSeriesPopOver}><calcite-icon icon=square-f style=${d({color:c})} slot=content-end></calcite-icon></calcite-list-item></calcite-list>`}buildMultipleBarTypeList(){let e=this.shouldDisableStacking();return e&&this.model.stackedType!==r.Side&&(this.model.stackedType=r.Side),o`<calcite-list label id=${_.stackedType} class=${a(l.list)} selection-mode=single-persist selection-appearance=border @click=${this.onMultipleBarSelect}><calcite-list-item .label=${this._messages.sideBySide} .value=${r.Side} .selected=${this.model.stackedType===void 0||this.model.stackedType===r.Side}><calcite-icon scale=l icon=graph-bar-side-by-side slot=content-start></calcite-icon></calcite-list-item><calcite-list-item class=${a(e?l.disabledStackingOption:"")} .label=${this._messages.stacked} .value=${r.Stacked} .selected=${this.model.stackedType===r.Stacked}><calcite-icon scale=l icon=graph-bar-stacked slot=content-start></calcite-icon>${e&&o`<calcite-icon class=${a(l.disabledInfo)} slot=content-end icon=information scale=s flip-rtl @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip}></calcite-icon>`||""}</calcite-list-item><calcite-list-item class=${a(e?l.disabledStackingOption:"")} .label=${this._messages.stacked100} .value=${r.Stacked100} .selected=${this.model.stackedType===r.Stacked100}><calcite-icon scale=l icon=graph-bar100-stacked slot=content-start></calcite-icon>${e&&o`<calcite-icon class=${a(l.disabledInfo)} slot=content-end icon=information scale=s flip-rtl @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip}></calcite-icon>`||""}</calcite-list-item></calcite-list>`}resetSeriesOriginal(){this.selectedSeriesIndex=void 0,this.model.resetSeriesStyling(),this.seriesOrderResetCounter+=1}onMultipleBarSelect(e){if(!this.shouldDisableStacking()){let t=e.target;this.model.stackedType=t.value??t.parentElement.value??""}}onCalciteListOrderChange(e){if(e.detail!==null&&e.detail!==void 0){let{newIndex:t,oldIndex:i}=e.detail;this.model.moveSeries(i??0,t??i??0),this.seriesOrderResetCounter+=1}}openSeriesPopOver(e){e.stopImmediatePropagation(),this.removeSeriesPopover();let t=e.target,i=t.localName==="calcite-list-item"?t:t.parentNode,s=this.model.getSeriesIndex(i.value);this.open=this.selectedSeriesIndex!==s,this.selectedSeriesIndex=this.selectedSeriesIndex!==s?s:void 0,this.isNullCategorySelected=i.value===this._messages.nullCategory}createTooltip(e){let t=e.target,i=(this.model.aggregationType===p.NoAggregation?this._messages.noAggStackingDisabled:this._messages.singleStackingDisabled)??"";this.tooltip=g(o`<calcite-tooltip style=${d({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${t} open placement=top>${i}</calcite-tooltip>`),document.body.appendChild(this.tooltip)}destroyTooltip(){I(this.tooltip)}shouldDisableStacking(){return(this.model.seriesLength??0)<=1||this.model.aggregationType===p.NoAggregation}render(){return o`<div class=${`${l.sectionLabel} ${l.topSection}`}>${this._messages.displayMultiSeries}</div>${this.buildMultipleBarTypeList()}<div class=${a(l.sectionLabel)}>${this._messages.series}<calcite-button @click=${this.resetSeriesOriginal} .disabled=${!this.model.resetAvailable()} appearance=transparent icon-end=reset>${this._messages.reset}</calcite-button></div>${this.buildSeriesList()}${this.model.nullCategory!==void 0&&this.model.fetchNULLValues?this.buildNullCategoryUI():null}`}};y("arcgis-charts-config-bar-chart-series",v);return v},c,e,h)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import{d as i}from"./AK7X7SGI.js";import{g as m}from"./WNKDEOFZ.js";import a from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as d}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as n,H as h,g as r,i as s}from"./RIM4HLHN.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{nb:c,pb:g}])=>{var p=r`:host{margin-bottom:var(--arcgis-charts-intra-section-margin);margin-top:var(--arcgis-charts-intra-section-margin);height:100%}`,o=class extends n{static{this.properties={layerFieldsInfo:16,model:0,page:1,layer:0,usePopupTemplateFieldsInfo:5,popupTemplateFieldInfosEnabled:5}}static{this.styles=p}async load(){await this.updateFetchLayerFieldsInfo(this.model?.config),this.modelChange(this.model)}willUpdate(e){let a=!1;e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("layer")&&this.layer!==void 0&&!d(e.get("layer"),this.layer)&&(a=!0),(e.has("usePopupTemplateFieldsInfo")&&this.usePopupTemplateFieldsInfo!==e.get("usePopupTemplateFieldsInfo")||e.has("popupTemplateFieldInfosEnabled")&&this.popupTemplateFieldInfosEnabled!==e.get("popupTemplateFieldInfosEnabled"))&&(a=!0),this.layerFieldsInfo===void 0&&(a=!0),a&&this.updateFetchLayerFieldsInfo()}disconnectedCallback(){super.disconnectedCallback(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,a){a?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}async updateFetchLayerFieldsInfo(e){let a=e??this.model.config,t=this.layer;if(!t){let l=m(a)?a.iLayer:void 0;l&&(t=await c(l))}t&&(await t.load(),this.layerFieldsInfo=g(t,this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled))}async onModelConfigChange(e){let a=e?.detail.config??this.model.config;this.layer===void 0&&await this.updateFetchLayerFieldsInfo(a)}render(){let e;switch(this.page){case i.Data:e=s`<arcgis-charts-config-heat-chart-data .model=${this.model} .layerFieldsInfo=${this.layerFieldsInfo}></arcgis-charts-config-heat-chart-data>`;break;case i.Format:e=s`<arcgis-charts-config-format .model=${this.model}></arcgis-charts-config-format>`;break;case i.General:e=s`<arcgis-charts-config-general .model=${this.model}></arcgis-charts-config-general>`;break;default:e="";break}return e}};h("arcgis-charts-config-heat-chart",o);return o},a)
2
+ import{d as i}from"./AK7X7SGI.js";import{g as m}from"./WNKDEOFZ.js";import a from"./BFVFX476.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as d}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as n,H as h,g as r,i as s}from"./RIM4HLHN.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{nb:c,pb:g}])=>{var p=r`:host{margin-bottom:var(--arcgis-charts-intra-section-margin);margin-top:var(--arcgis-charts-intra-section-margin);height:100%}`,o=class extends n{static{this.properties={layerFieldsInfo:16,model:0,page:1,layer:0,usePopupTemplateFieldsInfo:5,popupTemplateFieldInfosEnabled:5}}static{this.styles=p}async load(){await this.updateFetchLayerFieldsInfo(this.model?.config),this.modelChange(this.model)}willUpdate(e){let a=!1;e.has("model")&&this.modelChange(this.model,e.get("model")),e.has("layer")&&this.layer!==void 0&&!d(e.get("layer"),this.layer)&&(a=!0),(e.has("usePopupTemplateFieldsInfo")&&this.usePopupTemplateFieldsInfo!==e.get("usePopupTemplateFieldsInfo")||e.has("popupTemplateFieldInfosEnabled")&&this.popupTemplateFieldInfosEnabled!==e.get("popupTemplateFieldInfosEnabled"))&&(a=!0),this.layerFieldsInfo===void 0&&(a=!0),a&&this.updateFetchLayerFieldsInfo()}disconnectedCallback(){super.disconnectedCallback(),this.model.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}modelChange(e,a){a?.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange),e?.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}async updateFetchLayerFieldsInfo(e){let a=e??this.model.config,t=this.layer;if(!t){let l=m(a)?a.iLayer:void 0;l&&(t=await c(l))}t&&(await t.load(),this.layerFieldsInfo=g(t,this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled))}async onModelConfigChange(e){let a=e?.detail.config??this.model.config;this.layer===void 0&&await this.updateFetchLayerFieldsInfo(a)}render(){let e;switch(this.page){case i.Data:e=s`<arcgis-charts-config-heat-chart-data .model=${this.model} .layerFieldsInfo=${this.layerFieldsInfo}></arcgis-charts-config-heat-chart-data>`;break;case i.Format:e=s`<arcgis-charts-config-format .model=${this.model}></arcgis-charts-config-format>`;break;case i.General:e=s`<arcgis-charts-config-general .model=${this.model}></arcgis-charts-config-general>`;break;default:e="";break}return e}};h("arcgis-charts-config-heat-chart",o);return o},a)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import u from"./OO5SFCWJ.js";import t from"./2KCA3K57.js";import{a as f}from"./IVLVCLDE.js";import{a as ae}from"./L7CMLBHB.js";import{a as $,b as W,e as ee}from"./OBPAQN4H.js";import{a as ie}from"./AQIB3VEP.js";import{a as k}from"./S7Z4HRW7.js";import{a as se}from"./IHO3OLL3.js";import s from"./LSKFMUX4.js";import{a as P}from"./JHANH4UG.js";import{d as n}from"./AK7X7SGI.js";import r from"./5JREGZML.js";import q from"./IPECBZP3.js";import p from"./4AF64XYR.js";import m from"./TSQOEJB4.js";import l from"./75XWLYW5.js";import j from"./XKHA7K4P.js";import{b as B,c as L,i as Y,l as w,p as D}from"./THTYR6IL.js";import i from"./N3FUI2RC.js";import g from"./6ODWWOUP.js";import"./Y7HBWU3M.js";import e from"./7LI5APDL.js";import d from"./L6SM2ORZ.js";import b from"./D46R6YHX.js";import"./WNKDEOFZ.js";import a from"./HFSVUO2D.js";import{d as x,e as O}from"./EZV7JSQJ.js";import{C as v,c as R,q as T}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as S}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as V,B as _,C as h,D as z,F as M,H as U,g as N,i as c,n as C,z as A}from"./RIM4HLHN.js";import{a as J}from"./BMC75GCV.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as o,k as H}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{substitute:le},{Ga:X,Nb:K,gb:Z,kb:G,nc:j},,,,,{b:I},,{a:Q},,,,,{r:te},{e:y,f:q},{b:E}])=>{var d={chartUIComponent:"chart-ui-component",tabBar:"tab-bar",tab:"tab"};function re(m,e){let i=new Set,t=e;return m?.forEach((a,s)=>{let r=a.chartId;(i.has(r)||r===void 0||r==="")&&(a.chartId=`Chart_${Date.now()}_${s}`,e===r&&(t=a.chartId)),i.add(r)}),t}function ne(m,e,i){return m?.filter(t=>T(i,t.config)&&t.layer?.id===e)??[]}function ce(m){let{modelList:e,layerList:i,activeLayerId:t,disableEditing:a}=m,s=new Map;return e?.forEach(r=>{let l=r.layer;l&&s.set(l.id,l)}),a||i.forEach(r=>s.set(r.id,r)),Array.from(s.values()).filter(r=>!t||r.id===t)}function he(m,e){m.forEach(i=>{e.forEach(t=>{i?.id===t.layer?.id&&oe(i,t)})})}function oe(m,e){let i=m;if(i){let t=[...i?.charts??[]],a=t?.findIndex(r=>r.id===e.chartId),s=!1;a!==void 0&&a>-1?(s=!S(t[a],e.config),t[a]=e.config):i&&!I(e.config)&&(s=!0,t.push(e.config)),s&&(i.charts=t)}}function de(m,e){let i=m;if(i){let t=[...i.charts??[]],a=t.findIndex(s=>s.id===e);a>-1&&(t.splice(a,1),i.charts=t)}}function me(m,e){let i=m;if(i){let t=[...i.charts??[]];t=v({arrayA:t,arrayB:e.map(a=>a.config),getKey:a=>a.id??a.title?.content.text??""}),i.charts=t}}var pe=N`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;flex:1 1 auto;overflow:hidden;height:inherit;max-height:100%}.chart-ui-component{overflow-y:auto;overflow-x:hidden}.label{display:flex;margin-left:1rem;margin-bottom:.5rem;justify-content:space-between}.text{display:flex;margin-left:1rem;width:calc(100% - 1.5rem);height:2rem;margin-bottom:.5rem;justify-content:space-between}.field-list{max-height:50vh;overflow-y:scroll}.row{padding:.5rem}.bin-count-container{display:flex;width:calc(100% - 1rem);padding:.5rem}.bin-count-slider{margin-left:1rem;width:calc(90% - 1rem)}.bin-count-input{margin-left:1rem;height:2rem;width:2rem}.bin-row{padding:.5rem 0 .5rem .5rem}.tab-bar{display:flex}.tab{flex:1;height:2.5rem}`,F=class extends _{constructor(){super(),this.selectChartTypePopover=null,this.chartsListFlowItem=A(),this.supportedChartTypes=[o.BarSeries,o.BoxPlotSeries,o.LineSeries,o.PieSeries,o.HistogramSeries,o.ScatterSeries,o.HeatSeries],this._messages=P(),this.commonStrings=P({name:"common",blocking:!0}),this.chartDataProcessComplete=e=>{let i=e,{chartData:t,model:a}=i.detail,s=this.getModel(this.selectedChartId);if(a?.isSameChartAs(s))switch(s?.chartType){case o.HistogramSeries:if(this.chartData=t,a&&(a.dataStore.chartData=t,O(a.layer))){let r=a,l=t?.bins?.length;l!==void 0&&r.binCount!==l&&(r.binCount=l)}break;case o.PieSeries:{this.chartData=t,a&&(a.dataStore.chartData=t);break}case o.ScatterSeries:{let r=t,{dataItems:l,r2:g,aggregated:u}=r,p=g;Number.isFinite(g)||(p=void 0),this.r2=p,Y(a)&&(a.dataStore.r2=p,a.dataStore.aggregated=u,u&&(a.additionalTooltipField=void 0)),this.calculatedDataMinMaxBounds=this.getDataExtent(l),a&&(a.dataStore.calculatedDataMinMaxBounds=this.calculatedDataMinMaxBounds);break}case o.LineSeries:case o.BarSeries:{let{dataItems:r,timeIntervalInfo:l}=t;if((L(s)||B(s)&&s.binTemporalData)&&(l?.size!==void 0&&s.temporalBinningSize!==l?.size&&(s.temporalBinningSize=l?.size),l?.unit!==void 0&&s.temporalBinningUnit!==l?.unit&&l?.unit!==H.Quarter&&(s.temporalBinningUnit=l?.unit),l?.size!==void 0&&l?.unit!==void 0&&ee($,{size:l.size,unit:l.unit})),this.calculatedDataMinMaxBounds=this.getDataExtent(r),a&&(a.dataStore.calculatedDataMinMaxBounds=this.calculatedDataMinMaxBounds),B(s)){let g=s.xAxisField,u=r.some(b=>b[g]===null),p=s.nullCategory;u&&p===void 0&&(s.nullCategory=R.nullCategory)}break}}},this.chartAxesMinMaxChange=e=>{let i=e,{bounds:t,model:a}=i.detail,s=this.getModel(this.selectedChartId),r=a?.isSameChartAs(s),l=s?.chartType;if(r)switch(l){case o.BarSeries:case o.BoxPlotSeries:case o.LineSeries:case o.HistogramSeries:case o.ScatterSeries:this.calculatedMinMaxBounds=t,a&&(a.dataStore.calculatedMinMaxBounds=t),this.updateAxesBoundsInAppState(t);break}},this.chartSeriesColorChange=e=>{let i=e,{data:t,model:a}=i.detail,s=this.getModel(this.selectedChartId);if(a?.isSameChartAs(s))switch(s?.chartType){case o.BarSeries:case o.BoxPlotSeries:case o.LineSeries:case o.HistogramSeries:this.seriesColor=t,a&&(a.dataStore.seriesColor=t);break;case o.PieSeries:{let r=new Map([[0,t]]);this.seriesColor=r,a&&(a.dataStore.seriesColor=r);break}case o.ScatterSeries:}},this.chartNoRenderPropChange=e=>{let i=e,{propName:t,value:a,model:s}=i.detail,r=this.modelList.find(l=>s?.isSameChartAs(l));if(r)switch(t){case"rotation":typeof a=="boolean"&&Q(r)&&(r.rotated=a);break;case"legendPosition":typeof a=="string"&&D(r)&&(r.legendPosition=a);break;case"legendVisibility":typeof a=="boolean"&&D(r)&&(r.legendVisibility=a);break}},this.chartLegendItemVisibilityChange=e=>{let i=e,{legendItemVisibility:t,model:a}=i.detail,s=this.modelList.find(r=>a?.isSameChartAs(r));s?.setSeriesVisibility(t),w(s)&&((s.getMinBound(1)===null||Number.isNaN(s.getMinBound(1)))&&s.setMinBound(null,1),(s.getMaxBound(1)===null||Number.isNaN(s.getMaxBound(1)))&&s.setMaxBound(null,1),L(s)&&((s.getMinBound(0)===null||Number.isNaN(s.getMinBound(0)))&&s.setMinBound(null,0),(s.getMaxBound(0)===null||Number.isNaN(s.getMaxBound(0)))&&s.setMaxBound(null,0)))},this.onSelectChartTypeChange=e=>{this.currentChartTypeText="",this.calculatedDataMinMaxBounds=void 0,this.calculatedMinMaxBounds=void 0,this.removeSelectChartTypePopover();let{selectedModelType:i,layerId:t}=e.target;i!==void 0&&(this.allowChartSyncing=!0,this.arcgisChartsConfigNewChart.emit({key:"key",chartType:i,layerId:t}))},this.onAddChartClose=()=>{this.removeSelectChartTypePopover()},this.onModelConfigChange=e=>{if(this.syncChartsToLayers&&this.allowChartSyncing){let i=e.target;oe(i?.layer,i)}this.requestUpdate()},this.allowChartSyncing=!1,this.currentChartTypeText="",this.modelList=[],this.layerList=[],this.disableEditing=!1,this.syncChartsToLayers=!1,this.close=!1,this.usePopupTemplateFieldsInfo=!1,this.panelNumber=0,this.filterBySelection=!1,this.arcgisChartsConfigChartViewChartClose=C(),this.arcgisChartsConfigModelListChange=C(),this.arcgisChartsConfigNewChart=C(),this.arcgisChartsConfigPanelNumberChange=C(),this.arcgisChartsConfigSelectedChartChange=C(),this.addChartEventListeners(),this.listen("arcgisChartsConfigModelListReorder",this.modelListReorderChangeListener)}static{this.properties={selectedPanel:16,currentChartTypeText:16,messageOverrides:0,modelList:[0,{hasChanged:y}],layerList:[0,{hasChanged:y}],selectedChartId:1,activeLayerId:1,disableEditing:5,syncChartsToLayers:5,timeZone:1,headerTitle:1,close:5,chartData:[0,{hasChanged:y}],r2:9,calculatedDataMinMaxBounds:[0,{hasChanged:y}],calculatedMinMaxBounds:[0,{hasChanged:y}],seriesColor:[0,{hasChanged:q}],popoverPlacement:1,usePopupTemplateFieldsInfo:5,popupTemplateFieldInfosEnabled:5,panelNumber:9,filterBySelection:5}}static{this.styles=pe}async setFocus(){await this.chartsListFlowItem.value?.setFocus()}async load(){await this.layerListChange();let e=this.getModel(this.selectedChartId);this.setEventBasedPropsFromModelData(e)}willUpdate(e){e.has("layerList")&&this.layerListChange(),e.has("panelNumber")&&this.panelNumberChange(this.panelNumber),e.has("modelList")&&this.modelListChange(this.modelList,e.get("modelList")),e.has("selectedChartId")&&this.selectedChartIdChange(this.selectedChartId)}disconnectedCallback(){super.disconnectedCallback(),this.clearPartialModels(),this.removeSelectChartTypePopover()}modelListReorderChangeListener(e){let{modelList:i}=e.detail;if(this.modelList=v({arrayA:this.modelList,arrayB:i,getKey:t=>t.chartId??t.titleText??""}),this.syncChartsToLayers){let t=i.find(a=>a.layer?.id!==void 0)?.layer?.id;if(t){let a=this.layerList.find(s=>s.id.toString()===t);a&&me(a,i)}}}async layerListChange(){let e=[],i=this.layerList.map(a=>a.id.toString()),t=[...this.modelList.filter(a=>i.includes(a.layer?.id??""))];for(let a of this.layerList??[]){if(a.type==="sublayer"){let r=await a.createFeatureLayer();if(!r)continue;a=r}let s=a.charts;for(let r of s??[]){let l=await J({layer:a,config:r,commonStrings:this.commonStrings});l!==void 0&&e.push(l)}}re(e),e.forEach(a=>{t.find(s=>s.isSameChartAs(a))===void 0&&t.push(a)}),t=t.filter(a=>!K(a.config)),this.modelList=t}modelListChange(e,i){this.selectedChartId=re(e,this.selectedChartId),i?.forEach(a=>{a.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}),e.forEach(a=>{a.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)});let t=this.getModel(this.selectedChartId);this.currentChartTypeText=t?.chartType!==void 0?E({chartType:t.chartType,commonStrings:this.commonStrings,config:t.config}):"",this.syncChartsToLayers&&this.allowChartSyncing&&he(this.layerList,e),this.arcgisChartsConfigModelListChange.emit({modelList:e})}selectedChartIdChange(e){this.selectedChartId===void 0&&(this.panelNumber=0),this.selectedPanel=n.Data;let i=this.getModel(e);this.setEventBasedPropsFromModelData(i),this.currentChartTypeText=i?.chartType!==void 0?E({chartType:i.chartType,commonStrings:this.commonStrings,config:i.config}):"",e!==void 0&&e!==$.selectedChartId&&($.selectedChartId=e),this.allowChartSyncing=!0,this.arcgisChartsConfigSelectedChartChange.emit({key:"key",model:i})}panelNumberChange(e){e===0?this.clearPartialModels():e===1&&this.removeSelectChartTypePopover(),this.arcgisChartsConfigPanelNumberChange.emit({panelNumber:e,modelList:this.modelList})}addChartEventListeners(){this.listenOn(document,f.DataProcessComplete,this.chartDataProcessComplete),this.listenOn(document,f.AxesMinMaxChange,this.chartAxesMinMaxChange),this.listenOn(document,f.SeriesColorChange,this.chartSeriesColorChange),this.listenOn(document,f.NoRenderPropChange,this.chartNoRenderPropChange),this.listenOn(document,f.LegendItemVisibilityChange,this.chartLegendItemVisibilityChange)}getDataExtent(e){let i=this.getModel(this.selectedChartId)?.config,t=[];if(i!==void 0&&e!==void 0){let a=j({chartConfig:i,chartData:e}),{minY:s,maxY:r,minX:l,maxX:g}=a;t=[{isXAxis:!0,minimum:l,maximum:g},{isXAxis:!1,minimum:s,maximum:r}]}return t}updateAxesBoundsInAppState(e){e?.forEach(i=>{let{isXAxis:t,maximum:a,minimum:s}=i,r=this.getModel(this.selectedChartId);if(r!==void 0&&w(r)&&this.selectedChartId!==void 0){let l=new ae(r,t),g=W({chartId:this.selectedChartId,isXAxis:t,isLogarithmic:l.getLogarithmic()}),u=$.chartAxesBoundDataMap;u[this.selectedChartId]===void 0&&(u[this.selectedChartId]={});let p=u[this.selectedChartId]?.[g],b={defaultMinBound:p?.defaultMinBound===p?.currMinBound?s:p?.defaultMinBound,currMinBound:s,defaultMaxBound:p?.defaultMaxBound===p?.currMaxBound?a:p?.defaultMaxBound,currMaxBound:a};!S(p,b)&&this.selectedChartId!==void 0&&u?.[this.selectedChartId]!==void 0&&(u[this.selectedChartId][g]=b)}})}getPlacement(){let e;return this.popoverPlacement!==void 0?e=this.popoverPlacement:e=this.modelList?.filter(i=>T(X,i.config)).length<=2?"bottom":"top",e}onBackFlow(){this.panelNumber-=1}async onAddChartClick(e){let{referenceElement:i,layerId:t,layerType:a}=e.detail,s=!0;if(x(a)&&t){let r=this.layerList.find(l=>l.id===t);x(r?.type)&&(s=!!(await G(r))?.attributeTable)}this.setupSelectChartTypePopover(i,t,a,s)}setupSelectChartTypePopover(e,i,t,a=!0){let s=this.getPlacement();this.removeSelectChartTypePopover(),this.selectChartTypePopover=M(c`<arcgis-charts-config-select-chart-type-popover .referenceElement=${e} open .layerId=${i} .layerType=${t} .isRasterBarChartSupported=${a} .popoverPlacement=${s} @arcgisChartsConfigPopoverClose=${this.onAddChartClose} @arcgisChartsConfigSelectChartTypeChange=${this.onSelectChartTypeChange}></arcgis-charts-config-select-chart-type-popover>`),!document.body.contains(this.selectChartTypePopover)&&this.selectChartTypePopover!==null&&document.body.appendChild(this.selectChartTypePopover)}getModel(e){return this.modelList?.find(i=>i.chartId===e)}removeSelectChartTypePopover(){this.selectChartTypePopover!==void 0&&(this.selectChartTypePopover?.remove(),this.selectChartTypePopover=se(this.selectChartTypePopover))}clearPartialModels(){this.modelList=this.modelList.filter(e=>!I(e.config))}onViewChartDelete(e){let{chartId:i}=e.detail;if(i!==void 0){let t=this.modelList.find(s=>s.chartId===i),a=this.layerList.find(s=>s.id===t?.layer?.id);this.modelList=[...this.modelList.filter(s=>s.chartId!==i)],a&&this.syncChartsToLayers&&this.allowChartSyncing&&de(a,i)}}onViewChartsSelect(e){this.selectedChartId===e.detail.chartId&&(this.allowChartSyncing=!0,this.arcgisChartsConfigSelectedChartChange.emit({key:"key",model:this.getModel(this.selectedChartId)})),this.selectedChartId=e.detail.chartId}onViewChartsEdit(e){this.onViewChartsSelect(e),this.panelNumber=1}onViewChartClose(){this.close=!0,this.removeSelectChartTypePopover(),this.arcgisChartsConfigChartViewChartClose.emit()}setEventBasedPropsFromModelData(e){this.chartData=e?.dataStore.chartData,this.r2=e?.dataStore.r2,this.seriesColor=e?.dataStore.seriesColor,this.calculatedMinMaxBounds=e?.dataStore.calculatedMinMaxBounds,this.calculatedDataMinMaxBounds=e?.dataStore.calculatedDataMinMaxBounds}createTooltip(e){let i=e.target,t="";switch(i.icon){case"configure":t=this._messages.data??"";break;case"graph-bar-stacked":case"graph-line-series":case"box-chart-series":t=this._messages.series??"";break;case"graph-pie-slice":t=this._messages.slices??"";break;case"graph-axis":t=this._messages.axes??"";break;case"graph-guides":t=this._messages.guides??"";break;case"palette":t=this._messages.format??"";break;case"text":t=this._messages.general??"";break;default:t="";break}this.tooltip=M(c`<calcite-tooltip style=${z({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${i} open placement=top>${t}</calcite-tooltip>`),document.body.appendChild(this.tooltip)}destroyTooltip(){te(this.tooltip)}renderViewCharts(){let e=ce({modelList:this.modelList,layerList:this.layerList,activeLayerId:this.activeLayerId,disableEditing:this.disableEditing});return ie(e,i=>i.id,i=>c`<arcgis-charts-config-view-charts .noGroup=${this.activeLayerId!==void 0} .modelList=${ne(this.modelList,i.id.toString(),x(i.type)?Z:this.supportedChartTypes)} .selectedChartId=${this.selectedChartId??""} .layer=${i} .disableEditing=${this.disableEditing} @arcgisChartsConfigViewChartSelect=${this.onViewChartsSelect} @arcgisChartsConfigViewChartEdit=${this.onViewChartsEdit} @arcgisChartsConfigViewChartDelete=${this.onViewChartDelete} @arcgisChartsConfigViewChartAddChart=${this.onAddChartClick}></arcgis-charts-config-view-charts>`)}render(){return this.close?null:c`<calcite-flow>${k("charts-list",c`<calcite-flow-item .selected=${this.panelNumber===0||this.disableEditing} .heading=${this.headerTitle??this._messages.defaultHeaderTitle} closable @calciteFlowItemClose=${this.onViewChartClose} ${V(this.chartsListFlowItem)}>${this.renderViewCharts()}</calcite-flow-item>`)}${this.panelNumber>=1&&!this.disableEditing?this.renderTabs():null}</calcite-flow>`}renderTabs(){let e=this.getModel(this.selectedChartId);return k("chart-edit",c`<calcite-flow-item .selected=${this.panelNumber>=1&&!this.disableEditing} @calciteFlowItemBack=${this.onBackFlow} .heading=${this._messages[this.selectedPanel??n.Data]} .description=${this.currentChartTypeText!==""&&this._messages.pageFlowTitle!==void 0?le(this._messages.pageFlowTitle,{chartName:e?.titleText??this.currentChartTypeText,layerName:e?.layer?.title??""}):""}>${e?.chartType!==void 0?c`<calcite-action-bar class=${h(d.tabBar)} layout=horizontal expand-disabled><calcite-action class=${h(d.tab)} icon=configure scale=s alignment=center .active=${this.selectedPanel===n.Data||this.selectedPanel===void 0} @click=${()=>{this.selectedPanel=n.Data}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>${e?.chartType===o.BarSeries?c`<calcite-action class=${h(d.tab)} icon=graph-bar-stacked scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.LineSeries?c`<calcite-action class=${h(d.tab)} icon=graph-line-series scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.BoxPlotSeries?c`<calcite-action class=${h(d.tab)} icon=box-chart-series scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.PieSeries?c`<calcite-action class=${h(d.tab)} icon=graph-pie-slice scale=s alignment=center .active=${this.selectedPanel===n.Slices} @click=${()=>{this.selectedPanel=n.Slices}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType!==o.PieSeries&&e?.chartType!==o.HeatSeries?c`<calcite-action class=${h(d.tab)} icon=graph-axis scale=s alignment=center .active=${this.selectedPanel===n.Axes} @click=${()=>{this.selectedPanel=n.Axes}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType!==o.PieSeries&&e?.chartType!==o.HeatSeries?c`<calcite-action class=${h(d.tab)} icon=graph-guides scale=s alignment=center .active=${this.selectedPanel===n.Guides} @click=${()=>{this.selectedPanel=n.Guides}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}<calcite-action class=${h(d.tab)} icon=palette scale=s alignment=center .active=${this.selectedPanel===n.Format} @click=${()=>{this.selectedPanel=n.Format}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action><calcite-action class=${h(d.tab)} icon=text scale=s alignment=center .active=${this.selectedPanel===n.General} @click=${()=>{this.selectedPanel=n.General}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action></calcite-action-bar>`:null}${this.renderChartUIComponent()}</calcite-flow-item>`)}renderChartUIComponent(){let e=this.getModel(this.selectedChartId),i=e?.layer,t=null;if(e!==void 0&&!this.disableEditing)switch(e?.chartType){case o.BarSeries:t=c`<arcgis-charts-config-bar-chart class=${h(d.chartUIComponent)} .model=${e} .timeZone=${this.timeZone} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-bar-chart>`;break;case o.LineSeries:t=c`<arcgis-charts-config-line-chart class=${h(d.chartUIComponent)} .model=${e} .timeZone=${this.timeZone} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedDataMinMaxBounds=${this.calculatedDataMinMaxBounds} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-line-chart>`;break;case o.PieSeries:t=c`<arcgis-charts-config-pie-chart class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .chartData=${this.chartData} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor} .filterBySelection=${this.filterBySelection}></arcgis-charts-config-pie-chart>`;break;case o.HistogramSeries:t=c`<arcgis-charts-config-histogram class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .chartData=${this.chartData} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-histogram>`;break;case o.ScatterSeries:t=c`<arcgis-charts-config-scatter-plot class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .r2=${this.r2} .calculatedDataMinMaxBounds=${this.calculatedDataMinMaxBounds} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds}></arcgis-charts-config-scatter-plot>`;break;case o.BoxPlotSeries:t=c`<arcgis-charts-config-box-plot class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-box-plot>`;break;case o.HeatSeries:t=c`<arcgis-charts-config-heat-chart class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data}></arcgis-charts-config-heat-chart>`;break}return t}};U("arcgis-charts-config-create-flow",F);return F},"intl",a,b,d,e,g,i,j,l,m,p,q,r,s,t,u)
2
+ import u from"./5LVCC5LO.js";import t from"./SBP4RBXK.js";import{a as f}from"./IVLVCLDE.js";import{a as ae}from"./L7CMLBHB.js";import{a as $,b as W,e as ee}from"./OBPAQN4H.js";import{a as ie}from"./AQIB3VEP.js";import{a as k}from"./S7Z4HRW7.js";import{a as se}from"./IHO3OLL3.js";import s from"./VQFCYPDR.js";import{a as P}from"./JHANH4UG.js";import{d as n}from"./AK7X7SGI.js";import r from"./E4OZ432W.js";import q from"./HWUT7IFD.js";import p from"./QGJNZGQX.js";import m from"./54F7CW76.js";import l from"./S6MDSIET.js";import j from"./H4VTKKBN.js";import{b as B,c as L,i as Y,l as w,p as D}from"./THTYR6IL.js";import i from"./HOZ4AHQR.js";import g from"./RKZ2IOOP.js";import"./Y7HBWU3M.js";import e from"./FVGXWZBY.js";import d from"./OOVQ6IVC.js";import b from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import a from"./BFVFX476.js";import{d as x,e as O}from"./EZV7JSQJ.js";import{C as v,c as R,q as T}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import{l as S}from"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as V,B as _,C as h,D as z,F as M,H as U,g as N,i as c,n as C,z as A}from"./RIM4HLHN.js";import{a as J}from"./ODTCEPEL.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as o,k as H}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([{substitute:le},{Ga:X,Nb:K,gb:Z,kb:G,nc:j},,,,,{b:I},,{a:Q},,,,,{r:te},{e:y,f:q},{b:E}])=>{var d={chartUIComponent:"chart-ui-component",tabBar:"tab-bar",tab:"tab"};function re(m,e){let i=new Set,t=e;return m?.forEach((a,s)=>{let r=a.chartId;(i.has(r)||r===void 0||r==="")&&(a.chartId=`Chart_${Date.now()}_${s}`,e===r&&(t=a.chartId)),i.add(r)}),t}function ne(m,e,i){return m?.filter(t=>T(i,t.config)&&t.layer?.id===e)??[]}function ce(m){let{modelList:e,layerList:i,activeLayerId:t,disableEditing:a}=m,s=new Map;return e?.forEach(r=>{let l=r.layer;l&&s.set(l.id,l)}),a||i.forEach(r=>s.set(r.id,r)),Array.from(s.values()).filter(r=>!t||r.id===t)}function he(m,e){m.forEach(i=>{e.forEach(t=>{i?.id===t.layer?.id&&oe(i,t)})})}function oe(m,e){let i=m;if(i){let t=[...i?.charts??[]],a=t?.findIndex(r=>r.id===e.chartId),s=!1;a!==void 0&&a>-1?(s=!S(t[a],e.config),t[a]=e.config):i&&!I(e.config)&&(s=!0,t.push(e.config)),s&&(i.charts=t)}}function de(m,e){let i=m;if(i){let t=[...i.charts??[]],a=t.findIndex(s=>s.id===e);a>-1&&(t.splice(a,1),i.charts=t)}}function me(m,e){let i=m;if(i){let t=[...i.charts??[]];t=v({arrayA:t,arrayB:e.map(a=>a.config),getKey:a=>a.id??a.title?.content.text??""}),i.charts=t}}var pe=N`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}:host{display:flex;flex-direction:column;flex:1 1 auto;overflow:hidden;height:inherit;max-height:100%}.chart-ui-component{overflow-y:auto;overflow-x:hidden}.label{display:flex;margin-left:1rem;margin-bottom:.5rem;justify-content:space-between}.text{display:flex;margin-left:1rem;width:calc(100% - 1.5rem);height:2rem;margin-bottom:.5rem;justify-content:space-between}.field-list{max-height:50vh;overflow-y:scroll}.row{padding:.5rem}.bin-count-container{display:flex;width:calc(100% - 1rem);padding:.5rem}.bin-count-slider{margin-left:1rem;width:calc(90% - 1rem)}.bin-count-input{margin-left:1rem;height:2rem;width:2rem}.bin-row{padding:.5rem 0 .5rem .5rem}.tab-bar{display:flex}.tab{flex:1;height:2.5rem}`,F=class extends _{constructor(){super(),this.selectChartTypePopover=null,this.chartsListFlowItem=A(),this.supportedChartTypes=[o.BarSeries,o.BoxPlotSeries,o.LineSeries,o.PieSeries,o.HistogramSeries,o.ScatterSeries,o.HeatSeries],this._messages=P(),this.commonStrings=P({name:"common",blocking:!0}),this.chartDataProcessComplete=e=>{let i=e,{chartData:t,model:a}=i.detail,s=this.getModel(this.selectedChartId);if(a?.isSameChartAs(s))switch(s?.chartType){case o.HistogramSeries:if(this.chartData=t,a&&(a.dataStore.chartData=t,O(a.layer))){let r=a,l=t?.bins?.length;l!==void 0&&r.binCount!==l&&(r.binCount=l)}break;case o.PieSeries:{this.chartData=t,a&&(a.dataStore.chartData=t);break}case o.ScatterSeries:{let r=t,{dataItems:l,r2:g,aggregated:u}=r,p=g;Number.isFinite(g)||(p=void 0),this.r2=p,Y(a)&&(a.dataStore.r2=p,a.dataStore.aggregated=u,u&&(a.additionalTooltipField=void 0)),this.calculatedDataMinMaxBounds=this.getDataExtent(l),a&&(a.dataStore.calculatedDataMinMaxBounds=this.calculatedDataMinMaxBounds);break}case o.LineSeries:case o.BarSeries:{let{dataItems:r,timeIntervalInfo:l}=t;if((L(s)||B(s)&&s.binTemporalData)&&(l?.size!==void 0&&s.temporalBinningSize!==l?.size&&(s.temporalBinningSize=l?.size),l?.unit!==void 0&&s.temporalBinningUnit!==l?.unit&&l?.unit!==H.Quarter&&(s.temporalBinningUnit=l?.unit),l?.size!==void 0&&l?.unit!==void 0&&ee($,{size:l.size,unit:l.unit})),this.calculatedDataMinMaxBounds=this.getDataExtent(r),a&&(a.dataStore.calculatedDataMinMaxBounds=this.calculatedDataMinMaxBounds),B(s)){let g=s.xAxisField,u=r.some(b=>b[g]===null),p=s.nullCategory;u&&p===void 0&&(s.nullCategory=R.nullCategory)}break}}},this.chartAxesMinMaxChange=e=>{let i=e,{bounds:t,model:a}=i.detail,s=this.getModel(this.selectedChartId),r=a?.isSameChartAs(s),l=s?.chartType;if(r)switch(l){case o.BarSeries:case o.BoxPlotSeries:case o.LineSeries:case o.HistogramSeries:case o.ScatterSeries:this.calculatedMinMaxBounds=t,a&&(a.dataStore.calculatedMinMaxBounds=t),this.updateAxesBoundsInAppState(t);break}},this.chartSeriesColorChange=e=>{let i=e,{data:t,model:a}=i.detail,s=this.getModel(this.selectedChartId);if(a?.isSameChartAs(s))switch(s?.chartType){case o.BarSeries:case o.BoxPlotSeries:case o.LineSeries:case o.HistogramSeries:this.seriesColor=t,a&&(a.dataStore.seriesColor=t);break;case o.PieSeries:{let r=new Map([[0,t]]);this.seriesColor=r,a&&(a.dataStore.seriesColor=r);break}case o.ScatterSeries:}},this.chartNoRenderPropChange=e=>{let i=e,{propName:t,value:a,model:s}=i.detail,r=this.modelList.find(l=>s?.isSameChartAs(l));if(r)switch(t){case"rotation":typeof a=="boolean"&&Q(r)&&(r.rotated=a);break;case"legendPosition":typeof a=="string"&&D(r)&&(r.legendPosition=a);break;case"legendVisibility":typeof a=="boolean"&&D(r)&&(r.legendVisibility=a);break}},this.chartLegendItemVisibilityChange=e=>{let i=e,{legendItemVisibility:t,model:a}=i.detail,s=this.modelList.find(r=>a?.isSameChartAs(r));s?.setSeriesVisibility(t),w(s)&&((s.getMinBound(1)===null||Number.isNaN(s.getMinBound(1)))&&s.setMinBound(null,1),(s.getMaxBound(1)===null||Number.isNaN(s.getMaxBound(1)))&&s.setMaxBound(null,1),L(s)&&((s.getMinBound(0)===null||Number.isNaN(s.getMinBound(0)))&&s.setMinBound(null,0),(s.getMaxBound(0)===null||Number.isNaN(s.getMaxBound(0)))&&s.setMaxBound(null,0)))},this.onSelectChartTypeChange=e=>{this.currentChartTypeText="",this.calculatedDataMinMaxBounds=void 0,this.calculatedMinMaxBounds=void 0,this.removeSelectChartTypePopover();let{selectedModelType:i,layerId:t}=e.target;i!==void 0&&(this.allowChartSyncing=!0,this.arcgisChartsConfigNewChart.emit({key:"key",chartType:i,layerId:t}))},this.onAddChartClose=()=>{this.removeSelectChartTypePopover()},this.onModelConfigChange=e=>{if(this.syncChartsToLayers&&this.allowChartSyncing){let i=e.target;oe(i?.layer,i)}this.requestUpdate()},this.allowChartSyncing=!1,this.currentChartTypeText="",this.modelList=[],this.layerList=[],this.disableEditing=!1,this.syncChartsToLayers=!1,this.close=!1,this.usePopupTemplateFieldsInfo=!1,this.panelNumber=0,this.filterBySelection=!1,this.arcgisChartsConfigChartViewChartClose=C(),this.arcgisChartsConfigModelListChange=C(),this.arcgisChartsConfigNewChart=C(),this.arcgisChartsConfigPanelNumberChange=C(),this.arcgisChartsConfigSelectedChartChange=C(),this.addChartEventListeners(),this.listen("arcgisChartsConfigModelListReorder",this.modelListReorderChangeListener)}static{this.properties={selectedPanel:16,currentChartTypeText:16,messageOverrides:0,modelList:[0,{hasChanged:y}],layerList:[0,{hasChanged:y}],selectedChartId:1,activeLayerId:1,disableEditing:5,syncChartsToLayers:5,timeZone:1,headerTitle:1,close:5,chartData:[0,{hasChanged:y}],r2:9,calculatedDataMinMaxBounds:[0,{hasChanged:y}],calculatedMinMaxBounds:[0,{hasChanged:y}],seriesColor:[0,{hasChanged:q}],popoverPlacement:1,usePopupTemplateFieldsInfo:5,popupTemplateFieldInfosEnabled:5,panelNumber:9,filterBySelection:5}}static{this.styles=pe}async setFocus(){await this.chartsListFlowItem.value?.setFocus()}async load(){await this.layerListChange();let e=this.getModel(this.selectedChartId);this.setEventBasedPropsFromModelData(e)}willUpdate(e){e.has("layerList")&&this.layerListChange(),e.has("panelNumber")&&this.panelNumberChange(this.panelNumber),e.has("modelList")&&this.modelListChange(this.modelList,e.get("modelList")),e.has("selectedChartId")&&this.selectedChartIdChange(this.selectedChartId)}disconnectedCallback(){super.disconnectedCallback(),this.clearPartialModels(),this.removeSelectChartTypePopover()}modelListReorderChangeListener(e){let{modelList:i}=e.detail;if(this.modelList=v({arrayA:this.modelList,arrayB:i,getKey:t=>t.chartId??t.titleText??""}),this.syncChartsToLayers){let t=i.find(a=>a.layer?.id!==void 0)?.layer?.id;if(t){let a=this.layerList.find(s=>s.id.toString()===t);a&&me(a,i)}}}async layerListChange(){let e=[],i=this.layerList.map(a=>a.id.toString()),t=[...this.modelList.filter(a=>i.includes(a.layer?.id??""))];for(let a of this.layerList??[]){if(a.type==="sublayer"){let r=await a.createFeatureLayer();if(!r)continue;a=r}let s=a.charts;for(let r of s??[]){let l=await J({layer:a,config:r,commonStrings:this.commonStrings});l!==void 0&&e.push(l)}}re(e),e.forEach(a=>{t.find(s=>s.isSameChartAs(a))===void 0&&t.push(a)}),t=t.filter(a=>!K(a.config)),this.modelList=t}modelListChange(e,i){this.selectedChartId=re(e,this.selectedChartId),i?.forEach(a=>{a.removeEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)}),e.forEach(a=>{a.addEventListener("arcgisChartsModelConfigChange",this.onModelConfigChange)});let t=this.getModel(this.selectedChartId);this.currentChartTypeText=t?.chartType!==void 0?E({chartType:t.chartType,commonStrings:this.commonStrings,config:t.config}):"",this.syncChartsToLayers&&this.allowChartSyncing&&he(this.layerList,e),this.arcgisChartsConfigModelListChange.emit({modelList:e})}selectedChartIdChange(e){this.selectedChartId===void 0&&(this.panelNumber=0),this.selectedPanel=n.Data;let i=this.getModel(e);this.setEventBasedPropsFromModelData(i),this.currentChartTypeText=i?.chartType!==void 0?E({chartType:i.chartType,commonStrings:this.commonStrings,config:i.config}):"",e!==void 0&&e!==$.selectedChartId&&($.selectedChartId=e),this.allowChartSyncing=!0,this.arcgisChartsConfigSelectedChartChange.emit({key:"key",model:i})}panelNumberChange(e){e===0?this.clearPartialModels():e===1&&this.removeSelectChartTypePopover(),this.arcgisChartsConfigPanelNumberChange.emit({panelNumber:e,modelList:this.modelList})}addChartEventListeners(){this.listenOn(document,f.DataProcessComplete,this.chartDataProcessComplete),this.listenOn(document,f.AxesMinMaxChange,this.chartAxesMinMaxChange),this.listenOn(document,f.SeriesColorChange,this.chartSeriesColorChange),this.listenOn(document,f.NoRenderPropChange,this.chartNoRenderPropChange),this.listenOn(document,f.LegendItemVisibilityChange,this.chartLegendItemVisibilityChange)}getDataExtent(e){let i=this.getModel(this.selectedChartId)?.config,t=[];if(i!==void 0&&e!==void 0){let a=j({chartConfig:i,chartData:e}),{minY:s,maxY:r,minX:l,maxX:g}=a;t=[{isXAxis:!0,minimum:l,maximum:g},{isXAxis:!1,minimum:s,maximum:r}]}return t}updateAxesBoundsInAppState(e){e?.forEach(i=>{let{isXAxis:t,maximum:a,minimum:s}=i,r=this.getModel(this.selectedChartId);if(r!==void 0&&w(r)&&this.selectedChartId!==void 0){let l=new ae(r,t),g=W({chartId:this.selectedChartId,isXAxis:t,isLogarithmic:l.getLogarithmic()}),u=$.chartAxesBoundDataMap;u[this.selectedChartId]===void 0&&(u[this.selectedChartId]={});let p=u[this.selectedChartId]?.[g],b={defaultMinBound:p?.defaultMinBound===p?.currMinBound?s:p?.defaultMinBound,currMinBound:s,defaultMaxBound:p?.defaultMaxBound===p?.currMaxBound?a:p?.defaultMaxBound,currMaxBound:a};!S(p,b)&&this.selectedChartId!==void 0&&u?.[this.selectedChartId]!==void 0&&(u[this.selectedChartId][g]=b)}})}getPlacement(){let e;return this.popoverPlacement!==void 0?e=this.popoverPlacement:e=this.modelList?.filter(i=>T(X,i.config)).length<=2?"bottom":"top",e}onBackFlow(){this.panelNumber-=1}async onAddChartClick(e){let{referenceElement:i,layerId:t,layerType:a}=e.detail,s=!0;if(x(a)&&t){let r=this.layerList.find(l=>l.id===t);x(r?.type)&&(s=!!(await G(r))?.attributeTable)}this.setupSelectChartTypePopover(i,t,a,s)}setupSelectChartTypePopover(e,i,t,a=!0){let s=this.getPlacement();this.removeSelectChartTypePopover(),this.selectChartTypePopover=M(c`<arcgis-charts-config-select-chart-type-popover .referenceElement=${e} open .layerId=${i} .layerType=${t} .isRasterBarChartSupported=${a} .popoverPlacement=${s} @arcgisChartsConfigPopoverClose=${this.onAddChartClose} @arcgisChartsConfigSelectChartTypeChange=${this.onSelectChartTypeChange}></arcgis-charts-config-select-chart-type-popover>`),!document.body.contains(this.selectChartTypePopover)&&this.selectChartTypePopover!==null&&document.body.appendChild(this.selectChartTypePopover)}getModel(e){return this.modelList?.find(i=>i.chartId===e)}removeSelectChartTypePopover(){this.selectChartTypePopover!==void 0&&(this.selectChartTypePopover?.remove(),this.selectChartTypePopover=se(this.selectChartTypePopover))}clearPartialModels(){this.modelList=this.modelList.filter(e=>!I(e.config))}onViewChartDelete(e){let{chartId:i}=e.detail;if(i!==void 0){let t=this.modelList.find(s=>s.chartId===i),a=this.layerList.find(s=>s.id===t?.layer?.id);this.modelList=[...this.modelList.filter(s=>s.chartId!==i)],a&&this.syncChartsToLayers&&this.allowChartSyncing&&de(a,i)}}onViewChartsSelect(e){this.selectedChartId===e.detail.chartId&&(this.allowChartSyncing=!0,this.arcgisChartsConfigSelectedChartChange.emit({key:"key",model:this.getModel(this.selectedChartId)})),this.selectedChartId=e.detail.chartId}onViewChartsEdit(e){this.onViewChartsSelect(e),this.panelNumber=1}onViewChartClose(){this.close=!0,this.removeSelectChartTypePopover(),this.arcgisChartsConfigChartViewChartClose.emit()}setEventBasedPropsFromModelData(e){this.chartData=e?.dataStore.chartData,this.r2=e?.dataStore.r2,this.seriesColor=e?.dataStore.seriesColor,this.calculatedMinMaxBounds=e?.dataStore.calculatedMinMaxBounds,this.calculatedDataMinMaxBounds=e?.dataStore.calculatedDataMinMaxBounds}createTooltip(e){let i=e.target,t="";switch(i.icon){case"configure":t=this._messages.data??"";break;case"graph-bar-stacked":case"graph-line-series":case"box-chart-series":t=this._messages.series??"";break;case"graph-pie-slice":t=this._messages.slices??"";break;case"graph-axis":t=this._messages.axes??"";break;case"graph-guides":t=this._messages.guides??"";break;case"palette":t=this._messages.format??"";break;case"text":t=this._messages.general??"";break;default:t="";break}this.tooltip=M(c`<calcite-tooltip style=${z({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${i} open placement=top>${t}</calcite-tooltip>`),document.body.appendChild(this.tooltip)}destroyTooltip(){te(this.tooltip)}renderViewCharts(){let e=ce({modelList:this.modelList,layerList:this.layerList,activeLayerId:this.activeLayerId,disableEditing:this.disableEditing});return ie(e,i=>i.id,i=>c`<arcgis-charts-config-view-charts .noGroup=${this.activeLayerId!==void 0} .modelList=${ne(this.modelList,i.id.toString(),x(i.type)?Z:this.supportedChartTypes)} .selectedChartId=${this.selectedChartId??""} .layer=${i} .disableEditing=${this.disableEditing} @arcgisChartsConfigViewChartSelect=${this.onViewChartsSelect} @arcgisChartsConfigViewChartEdit=${this.onViewChartsEdit} @arcgisChartsConfigViewChartDelete=${this.onViewChartDelete} @arcgisChartsConfigViewChartAddChart=${this.onAddChartClick}></arcgis-charts-config-view-charts>`)}render(){return this.close?null:c`<calcite-flow>${k("charts-list",c`<calcite-flow-item .selected=${this.panelNumber===0||this.disableEditing} .heading=${this.headerTitle??this._messages.defaultHeaderTitle} closable @calciteFlowItemClose=${this.onViewChartClose} ${V(this.chartsListFlowItem)}>${this.renderViewCharts()}</calcite-flow-item>`)}${this.panelNumber>=1&&!this.disableEditing?this.renderTabs():null}</calcite-flow>`}renderTabs(){let e=this.getModel(this.selectedChartId);return k("chart-edit",c`<calcite-flow-item .selected=${this.panelNumber>=1&&!this.disableEditing} @calciteFlowItemBack=${this.onBackFlow} .heading=${this._messages[this.selectedPanel??n.Data]} .description=${this.currentChartTypeText!==""&&this._messages.pageFlowTitle!==void 0?le(this._messages.pageFlowTitle,{chartName:e?.titleText??this.currentChartTypeText,layerName:e?.layer?.title??""}):""}>${e?.chartType!==void 0?c`<calcite-action-bar class=${h(d.tabBar)} layout=horizontal expand-disabled><calcite-action class=${h(d.tab)} icon=configure scale=s alignment=center .active=${this.selectedPanel===n.Data||this.selectedPanel===void 0} @click=${()=>{this.selectedPanel=n.Data}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>${e?.chartType===o.BarSeries?c`<calcite-action class=${h(d.tab)} icon=graph-bar-stacked scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.LineSeries?c`<calcite-action class=${h(d.tab)} icon=graph-line-series scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.BoxPlotSeries?c`<calcite-action class=${h(d.tab)} icon=box-chart-series scale=s alignment=center .active=${this.selectedPanel===n.Series} @click=${()=>{this.selectedPanel=n.Series}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType===o.PieSeries?c`<calcite-action class=${h(d.tab)} icon=graph-pie-slice scale=s alignment=center .active=${this.selectedPanel===n.Slices} @click=${()=>{this.selectedPanel=n.Slices}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType!==o.PieSeries&&e?.chartType!==o.HeatSeries?c`<calcite-action class=${h(d.tab)} icon=graph-axis scale=s alignment=center .active=${this.selectedPanel===n.Axes} @click=${()=>{this.selectedPanel=n.Axes}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}${e?.chartType!==o.PieSeries&&e?.chartType!==o.HeatSeries?c`<calcite-action class=${h(d.tab)} icon=graph-guides scale=s alignment=center .active=${this.selectedPanel===n.Guides} @click=${()=>{this.selectedPanel=n.Guides}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action>`:null}<calcite-action class=${h(d.tab)} icon=palette scale=s alignment=center .active=${this.selectedPanel===n.Format} @click=${()=>{this.selectedPanel=n.Format}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action><calcite-action class=${h(d.tab)} icon=text scale=s alignment=center .active=${this.selectedPanel===n.General} @click=${()=>{this.selectedPanel=n.General}} @mouseover=${this.createTooltip} @mouseout=${this.destroyTooltip} text></calcite-action></calcite-action-bar>`:null}${this.renderChartUIComponent()}</calcite-flow-item>`)}renderChartUIComponent(){let e=this.getModel(this.selectedChartId),i=e?.layer,t=null;if(e!==void 0&&!this.disableEditing)switch(e?.chartType){case o.BarSeries:t=c`<arcgis-charts-config-bar-chart class=${h(d.chartUIComponent)} .model=${e} .timeZone=${this.timeZone} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-bar-chart>`;break;case o.LineSeries:t=c`<arcgis-charts-config-line-chart class=${h(d.chartUIComponent)} .model=${e} .timeZone=${this.timeZone} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedDataMinMaxBounds=${this.calculatedDataMinMaxBounds} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-line-chart>`;break;case o.PieSeries:t=c`<arcgis-charts-config-pie-chart class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .chartData=${this.chartData} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor} .filterBySelection=${this.filterBySelection}></arcgis-charts-config-pie-chart>`;break;case o.HistogramSeries:t=c`<arcgis-charts-config-histogram class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .chartData=${this.chartData} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-histogram>`;break;case o.ScatterSeries:t=c`<arcgis-charts-config-scatter-plot class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .r2=${this.r2} .calculatedDataMinMaxBounds=${this.calculatedDataMinMaxBounds} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds}></arcgis-charts-config-scatter-plot>`;break;case o.BoxPlotSeries:t=c`<arcgis-charts-config-box-plot class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data} .calculatedMinMaxBounds=${this.calculatedMinMaxBounds} .seriesColor=${this.seriesColor}></arcgis-charts-config-box-plot>`;break;case o.HeatSeries:t=c`<arcgis-charts-config-heat-chart class=${h(d.chartUIComponent)} .model=${e} .usePopupTemplateFieldsInfo=${this.usePopupTemplateFieldsInfo||this.popupTemplateFieldInfosEnabled} .layer=${i} .page=${this.selectedPanel??n.Data}></arcgis-charts-config-heat-chart>`;break}return t}};U("arcgis-charts-config-create-flow",F);return F},"intl",a,b,d,e,g,i,j,l,m,p,q,r,s,t,u)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import d from"./LSKFMUX4.js";import"./AK7X7SGI.js";import c from"./D46R6YHX.js";import"./WNKDEOFZ.js";import b from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as e,C as t,H as n,g as i,i as a}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{i:l}])=>{var o={invalidMessageColor:"invalid-message-color"},r=i`:host{display:block}.invalid-message-color{color:red}`,s=class extends e{constructor(){super(...arguments),this.isInvalid=!1}static{this.properties={invalidInputMessage:1,isInvalid:5}}static{this.styles=r}render(){return this.isInvalid?a`<calcite-input-message .status=${l.INVALID} icon=exclamationMarkTriangle .hidden=${!this.isInvalid} class=${t(o.invalidMessageColor)}>${this.invalidInputMessage}</calcite-input-message>`:null}};n("arcgis-charts-config-invalid-input-message",s);return s},b,c,d)
2
+ import d from"./VQFCYPDR.js";import"./AK7X7SGI.js";import c from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import b from"./BFVFX476.js";import"./EZV7JSQJ.js";import"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{B as e,C as t,H as n,g as i,i as a}from"./RIM4HLHN.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,{i:l}])=>{var o={invalidMessageColor:"invalid-message-color"},r=i`:host{display:block}.invalid-message-color{color:red}`,s=class extends e{constructor(){super(...arguments),this.isInvalid=!1}static{this.properties={invalidInputMessage:1,isInvalid:5}}static{this.styles=r}render(){return this.isInvalid?a`<calcite-input-message .status=${l.INVALID} icon=exclamationMarkTriangle .hidden=${!this.isInvalid} class=${t(o.invalidMessageColor)}>${this.invalidInputMessage}</calcite-input-message>`:null}};n("arcgis-charts-config-invalid-input-message",s);return s},b,c,d)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import n from"./BUUTWPEP.js";import{b as e,c as t,d as a}from"./IVLVCLDE.js";import l from"./LSKFMUX4.js";import{a as A}from"./JHANH4UG.js";import{a as u}from"./AK7X7SGI.js";import k from"./75XWLYW5.js";import{a as h,p as E}from"./THTYR6IL.js";import j from"./N3FUI2RC.js";import i from"./7LI5APDL.js";import f from"./L6SM2ORZ.js";import c from"./D46R6YHX.js";import"./WNKDEOFZ.js";import b from"./HFSVUO2D.js";import"./EZV7JSQJ.js";import{a as x}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as g,B as O,C as _,D as m,E as s,F as p,H as z,g as M,i as o,n as r,z as d}from"./RIM4HLHN.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as v}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,,,,{a:V},{r:n},{a:F,d:L}])=>{var R={actionBar:"action-bar"},Z=M`.action-bar{display:flex;flex-direction:column;height:100%;border-right:1px solid var(--calcite-color-border-2);width:fit-content}:host{z-index:1001}`,T=class extends O{constructor(){super(...arguments),this.calciteActionBar=d(),this.exportCalciteActionBar=d(),this.expandAction=null,this._messages=A(),this.commonStrings=A({name:"common",blocking:!0}),this.handleMouseOver=l=>{if(this.calciteActionBar.value&&!this.calciteActionBar.value?.expanded){let c=l.target;this.actionTooltip!==void 0&&(this.actionTooltip=n(this.actionTooltip));let i;c?.tagName==="CALCITE-ACTION"?i=c:(c?.tagName==="CALCITE-ACTION-MENU"||c?.tagName==="DIV")&&(i=c.firstChild),i!==void 0&&(this.actionTooltip=p(o`<calcite-tooltip style=${m({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${i} open placement=trailing-end>${i.text}</calcite-tooltip>`),document.body.appendChild(this.actionTooltip))}else this.actionTooltip=n(this.actionTooltip)},this._csvExportExclusionList=[v.ScatterSeries,v.BoxPlotSeries],this.actionTooltip=null,this.forceDisableActions=!1,this.editChartToggle=t.Inactive,this.editChartState=a.Disabled,this.legendToggle=t.Inactive,this.legendState=a.Enabled,this.rotateChartToggle=t.Inactive,this.rotateChartState=a.Enabled,this.filterBySelectionToggle=t.Inactive,this.filterBySelectionState=a.Enabled,this.filterByExtentToggle=t.Inactive,this.filterByExtentState=a.Enabled,this.actionBarSelectionMode=x.MultiSelectionWithCtrlKey,this.selectionToggle=t.Inactive,this.selectionState=a.Enabled,this.zoomToggle=t.Inactive,this.zoomState=a.Enabled,this.fullExtentToggle=t.Inactive,this.fullExtentState=a.Enabled,this.clearSelectionToggle=t.Inactive,this.clearSelectionState=a.Enabled,this.switchSelectionToggle=t.Inactive,this.switchSelectionState=a.Enabled,this.exportAsImageState=a.Enabled,this.exportAsCSVState=a.Enabled,this.disableCSVExportForChartTypes=this._csvExportExclusionList,this.csvExportExclusionList=this._csvExportExclusionList,this.exportActionState=a.Enabled,this.expanded=!1,this.hiddenActions=[e.EditChart],this.arcgisActionBarToggle=r(),this.arcgisDefaultActionSelect=r()}static{this.properties={actionTooltip:16,messageOverrides:0,chartType:1,chartElement:0,forceDisableActions:5,editChartToggle:1,editChartState:1,editChartTitle:1,legendToggle:1,legendState:1,legendTitle:1,rotateChartToggle:1,rotateChartState:1,rotateChartTitle:1,filterBySelectionToggle:1,filterBySelectionState:1,filterBySelectionTitle:1,filterByExtentToggle:1,filterByExtentState:1,filterByExtentTitle:1,actionBarSelectionMode:1,selectionToggle:1,selectionState:1,selectionTitle:1,zoomToggle:1,zoomState:1,zoomTitle:1,fullExtentToggle:1,fullExtentState:1,fullExtentTitle:1,clearSelectionToggle:1,clearSelectionState:1,clearSelectionTitle:1,switchSelectionToggle:1,switchSelectionState:1,switchSelectionTitle:1,exportAsImageState:1,exportAsImageTitle:1,exportAsCSVState:1,exportAsCSVTitle:1,disableCSVExportForChartTypes:0,csvExportExclusionList:0,exportActionState:1,expanded:5,hiddenActions:0}}static{this.styles=Z}load(){this.chartElement=L(this.el.parentElement)?this.el.parentElement:void 0}updated(){this.handleExpandTooltip()}disconnectedCallback(){super.disconnectedCallback(),this.actionTooltip?.remove()}async onDefaultActionClick(l){let c=l.currentTarget,i={actionId:c.id,actionActive:!1};switch(c.id){case e.EditChart:this.editChartToggle=this.editChartToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.editChartToggle===t.Active;break;case e.Legend:this.legendToggle=this.legendToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.legendToggle===t.Active,h(this.chartElement?.model)&&E(this.chartElement?.model)&&(this.chartElement.model.legendVisibility=i.actionActive),this.chartElement?.model&&(h(this.chartElement.model)?E(this.chartElement.model)&&(this.chartElement.model.legendVisibility=i.actionActive):this.chartElement.model.rotated=this.chartElement.model.rotated!==!0);break;case e.RotateChart:this.rotateChartToggle=this.rotateChartToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.rotateChartToggle===t.Active,this.chartElement?.model&&(h(this.chartElement.model)?V(this.chartElement.model)&&(this.chartElement.model.rotated=i.actionActive):this.chartElement.model.rotated=this.chartElement.model.rotated!==!0);break;case e.FilterBySelection:this.filterBySelectionToggle=this.filterBySelectionToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.filterBySelectionToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.filterBySelection=i.actionActive);break;case e.FilterByExtent:this.filterByExtentToggle=this.filterByExtentToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.filterByExtentToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.filterByViewExtent=i.actionActive);break;case e.Selection:this.selectionToggle=t.Active,this.zoomToggle=t.Inactive,i.actionActive=this.selectionToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.actionMode=this.actionBarSelectionMode);break;case e.Zoom:this.zoomToggle=t.Active,this.selectionToggle=t.Inactive,i.actionActive=this.zoomToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.actionMode=x.Zoom);break;case e.ClearSelection:i.actionActive=this.clearSelectionToggle===t.Active,this.chartElement?.clearSelection();break;case e.FullExtent:i.actionActive=this.fullExtentToggle===t.Active,this.chartElement?.resetZoom();break;case e.SwitchSelection:i.actionActive=this.switchSelectionToggle===t.Active,this.chartElement?.switchSelection();break;case e.ExportAsImage:i.actionActive=!0,await this.chartElement?.exportAsImage();break;case e.ExportAsCSV:i.actionActive=!0,await this.chartElement?.exportAsCSV();break}this.arcgisDefaultActionSelect.emit(i)}handleCalciteActionBarToggle(){this.expanded=this.calciteActionBar.value?.expanded??!1,this.setCustomActionsExpanded(),this.arcgisActionBarToggle.emit(this.expanded)}handleMouseOut(){this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))}handleSlotChange(l){let c=l.currentTarget.assignedElements();for(let i of c)i.onmouseover=this.handleMouseOver}setCustomActionsExpanded(){this.el.querySelectorAll("calcite-action").forEach(l=>{let c=l;c.textEnabled=this.expanded})}handleExpandTooltip(){this.expandAction===null&&(this.expandAction=this.calciteActionBar.value?.shadowRoot?.querySelector("calcite-action")??null,this.expandAction!==null&&(this.listenOn(this.expandAction,"mouseenter",()=>{!this.calciteActionBar.value?.expanded&&this.expandAction!==null&&!document.body.contains(this.actionTooltip)&&(this.actionTooltip=p(o`<calcite-tooltip style=${m({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${this.expandAction} open placement=trailing-end>${this._messages.expand??""}</calcite-tooltip>`),document.body.appendChild(this.actionTooltip))}),this.listenOn(this.expandAction,"mouseleave",()=>{!this.calciteActionBar.value?.expanded&&this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))}),this.listenOn(this.expandAction,"click",()=>{this.calciteActionBar.value?.expanded&&this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))})))}renderDefaultActions(){let l=F(this.chartType).filter(N=>!this.hiddenActions?.includes(N)),c=this.chartElement?.layer&&"isTable"in this.chartElement.layer?this.chartElement.layer.isTable:!1,i=l.includes(e.EditChart),S=l.includes(e.Legend),$=l.includes(e.RotateChart),b=l.includes(e.FilterBySelection),f=l.includes(e.FilterByExtent)&&!c,C=l.includes(e.Zoom),y=l.includes(e.Selection),B=l.includes(e.ClearSelection),D=l.includes(e.FullExtent),k=l.includes(e.SwitchSelection),I=l.includes(e.ExportAsImage),w=l.includes(e.ExportAsCSV);return[S||$?o`<calcite-action-group>${i?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.EditChart??s} icon=gear .text=${this.commonStrings?.utilsStrings.actions?.editChart??""} .textEnabled=${this.expanded} .active=${this.editChartToggle===t.Active} .disabled=${this.editChartState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${S?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Legend??s} .text=${this.legendTitle??this._messages?.legend??""} .textEnabled=${this.expanded} .active=${this.legendToggle===t.Active} .disabled=${this.legendState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}><calcite-icon icon=legend scale=s flip-rtl></calcite-icon></calcite-action></div>`:null}${$?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.RotateChart??s} icon=rotate .text=${this.rotateChartTitle??this._messages?.rotateChart??""} .textEnabled=${this.expanded} .active=${this.rotateChartToggle===t.Active} .disabled=${this.rotateChartState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,b||f?o`<calcite-action-group>${b?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FilterBySelection??s} icon=selection-filter .text=${this.filterBySelectionTitle??this._messages?.filterBySelection??""} .textEnabled=${this.expanded} .active=${this.filterBySelectionToggle===t.Active} .disabled=${this.filterBySelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${f?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FilterByExtent??s} icon=extent-filter .text=${this.filterByExtentTitle??this._messages?.filterByExtent??""} .textEnabled=${this.expanded} .active=${this.filterByExtentToggle===t.Active} .disabled=${this.filterByExtentState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,y||C||D||B||k?o`<calcite-action-group>${C?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Zoom??s} icon=magnifying-glass .text=${this.zoomTitle??this._messages?.zoom??""} .textEnabled=${this.expanded} .active=${this.zoomToggle===t.Active} .disabled=${this.zoomState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${y?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Selection??s} icon=cursor-selection .text=${this.selectionTitle??this._messages?.selection??""} .textEnabled=${this.expanded} .active=${this.selectionToggle===t.Active} .disabled=${this.selectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${B?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.ClearSelection??s} icon=erase .text=${this.clearSelectionTitle??this._messages?.clearSelection??""} .textEnabled=${this.expanded} .active=${this.clearSelectionToggle===t.Active} .disabled=${this.clearSelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${D?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FullExtent??s} icon=zoom-out-fixed .text=${this.fullExtentTitle??this._messages?.fullExtent??""} .textEnabled=${this.expanded} .active=${this.fullExtentToggle===t.Active} .disabled=${this.fullExtentState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${k?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.SwitchSelection??s} icon=arrow-right-left .text=${this.switchSelectionTitle??this._messages?.switchSelection??""} .textEnabled=${this.expanded} .active=${this.switchSelectionToggle===t.Active} .disabled=${this.switchSelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,I||w?o`<calcite-action-menu .label=${this._messages?.export??""} ${g(this.exportCalciteActionBar)}><calcite-action id=export icon=export .text=${this._messages?.export??""} .textEnabled=${this.expanded} .disabled=${this.exportActionState===a.Disabled||this.forceDisableActions} @mouseover=${this.handleMouseOver} slot=trigger></calcite-action>${I?o`<div><calcite-action id=${e.ExportAsImage??s} icon=graph-bar .text=${this.exportAsImageTitle??this._messages?.exportAsImage??""} .disabled=${this.exportAsImageState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick} text-enabled></calcite-action></div>`:null}${w?o`<div><calcite-action id=${e.ExportAsCSV??s} icon=table .text=${this.exportAsCSVTitle??this._messages?.exportAsTable??""} .disabled=${this.exportAsCSVState===a.Disabled||this.forceDisableActions||this.chartType&&(this.disableCSVExportForChartTypes.includes(this.chartType)||this.csvExportExclusionList.includes(this.chartType))} @click=${this.onDefaultActionClick} text-enabled></calcite-action></div>`:null}</calcite-action-menu>`:null]}render(){return o`<calcite-action-bar class=${_(R.actionBar)} @calciteActionBarToggle=${this.handleCalciteActionBarToggle} @mouseout=${this.handleMouseOut} .expanded=${this.expanded} .messageOverrides=${{expand:this._messages.expand,collapse:this._messages.collapse}} overflow-actions-disabled ${g(this.calciteActionBar)}><slot name=${u.customActionTop} @slotchange=${this.handleSlotChange}></slot>${this.renderDefaultActions()}<slot name=${u.customActionBelow} @slotchange=${this.handleSlotChange}></slot></calcite-action-bar>`}};z("arcgis-charts-action-bar",T);return T},b,c,f,i,j,k,l,n)
2
+ import n from"./WINZ53K3.js";import{b as e,c as t,d as a}from"./IVLVCLDE.js";import l from"./VQFCYPDR.js";import{a as A}from"./JHANH4UG.js";import{a as u}from"./AK7X7SGI.js";import k from"./S6MDSIET.js";import{a as h,p as E}from"./THTYR6IL.js";import j from"./HOZ4AHQR.js";import i from"./FVGXWZBY.js";import f from"./OOVQ6IVC.js";import c from"./6EX4GDM3.js";import"./WNKDEOFZ.js";import b from"./BFVFX476.js";import"./EZV7JSQJ.js";import{a as x}from"./3TBK72EK.js";import"./PAIRUVLU.js";import"./KX7KGXKQ.js";import"./SP2IPHWF.js";import"./IHHPUKGG.js";import{A as g,B as O,C as _,D as m,E as s,F as p,H as z,g as M,i as o,n as r,z as d}from"./RIM4HLHN.js";import"./KDJ5RVHA.js";import"./QP5UAIC6.js";import"./XJFVSX2E.js";import{a as v}from"./547RDEMV.js";import"./U67P6YAZ.js";export default $arcgis.t(([,,,,,{a:V},{r:n},{a:F,d:L}])=>{var R={actionBar:"action-bar"},Z=M`.action-bar{display:flex;flex-direction:column;height:100%;border-right:1px solid var(--calcite-color-border-2);width:fit-content}:host{z-index:1001}`,T=class extends O{constructor(){super(...arguments),this.calciteActionBar=d(),this.exportCalciteActionBar=d(),this.expandAction=null,this._messages=A(),this.commonStrings=A({name:"common",blocking:!0}),this.handleMouseOver=l=>{if(this.calciteActionBar.value&&!this.calciteActionBar.value?.expanded){let c=l.target;this.actionTooltip!==void 0&&(this.actionTooltip=n(this.actionTooltip));let i;c?.tagName==="CALCITE-ACTION"?i=c:(c?.tagName==="CALCITE-ACTION-MENU"||c?.tagName==="DIV")&&(i=c.firstChild),i!==void 0&&(this.actionTooltip=p(o`<calcite-tooltip style=${m({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${i} open placement=trailing-end>${i.text}</calcite-tooltip>`),document.body.appendChild(this.actionTooltip))}else this.actionTooltip=n(this.actionTooltip)},this._csvExportExclusionList=[v.ScatterSeries,v.BoxPlotSeries],this.actionTooltip=null,this.forceDisableActions=!1,this.editChartToggle=t.Inactive,this.editChartState=a.Disabled,this.legendToggle=t.Inactive,this.legendState=a.Enabled,this.rotateChartToggle=t.Inactive,this.rotateChartState=a.Enabled,this.filterBySelectionToggle=t.Inactive,this.filterBySelectionState=a.Enabled,this.filterByExtentToggle=t.Inactive,this.filterByExtentState=a.Enabled,this.actionBarSelectionMode=x.MultiSelectionWithCtrlKey,this.selectionToggle=t.Inactive,this.selectionState=a.Enabled,this.zoomToggle=t.Inactive,this.zoomState=a.Enabled,this.fullExtentToggle=t.Inactive,this.fullExtentState=a.Enabled,this.clearSelectionToggle=t.Inactive,this.clearSelectionState=a.Enabled,this.switchSelectionToggle=t.Inactive,this.switchSelectionState=a.Enabled,this.exportAsImageState=a.Enabled,this.exportAsCSVState=a.Enabled,this.disableCSVExportForChartTypes=this._csvExportExclusionList,this.csvExportExclusionList=this._csvExportExclusionList,this.exportActionState=a.Enabled,this.expanded=!1,this.hiddenActions=[e.EditChart],this.arcgisActionBarToggle=r(),this.arcgisDefaultActionSelect=r()}static{this.properties={actionTooltip:16,messageOverrides:0,chartType:1,chartElement:0,forceDisableActions:5,editChartToggle:1,editChartState:1,editChartTitle:1,legendToggle:1,legendState:1,legendTitle:1,rotateChartToggle:1,rotateChartState:1,rotateChartTitle:1,filterBySelectionToggle:1,filterBySelectionState:1,filterBySelectionTitle:1,filterByExtentToggle:1,filterByExtentState:1,filterByExtentTitle:1,actionBarSelectionMode:1,selectionToggle:1,selectionState:1,selectionTitle:1,zoomToggle:1,zoomState:1,zoomTitle:1,fullExtentToggle:1,fullExtentState:1,fullExtentTitle:1,clearSelectionToggle:1,clearSelectionState:1,clearSelectionTitle:1,switchSelectionToggle:1,switchSelectionState:1,switchSelectionTitle:1,exportAsImageState:1,exportAsImageTitle:1,exportAsCSVState:1,exportAsCSVTitle:1,disableCSVExportForChartTypes:0,csvExportExclusionList:0,exportActionState:1,expanded:5,hiddenActions:0}}static{this.styles=Z}load(){this.chartElement=L(this.el.parentElement)?this.el.parentElement:void 0}updated(){this.handleExpandTooltip()}disconnectedCallback(){super.disconnectedCallback(),this.actionTooltip?.remove()}async onDefaultActionClick(l){let c=l.currentTarget,i={actionId:c.id,actionActive:!1};switch(c.id){case e.EditChart:this.editChartToggle=this.editChartToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.editChartToggle===t.Active;break;case e.Legend:this.legendToggle=this.legendToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.legendToggle===t.Active,h(this.chartElement?.model)&&E(this.chartElement?.model)&&(this.chartElement.model.legendVisibility=i.actionActive),this.chartElement?.model&&(h(this.chartElement.model)?E(this.chartElement.model)&&(this.chartElement.model.legendVisibility=i.actionActive):this.chartElement.model.rotated=this.chartElement.model.rotated!==!0);break;case e.RotateChart:this.rotateChartToggle=this.rotateChartToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.rotateChartToggle===t.Active,this.chartElement?.model&&(h(this.chartElement.model)?V(this.chartElement.model)&&(this.chartElement.model.rotated=i.actionActive):this.chartElement.model.rotated=this.chartElement.model.rotated!==!0);break;case e.FilterBySelection:this.filterBySelectionToggle=this.filterBySelectionToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.filterBySelectionToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.filterBySelection=i.actionActive);break;case e.FilterByExtent:this.filterByExtentToggle=this.filterByExtentToggle===t.Active?t.Inactive:t.Active,i.actionActive=this.filterByExtentToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.filterByViewExtent=i.actionActive);break;case e.Selection:this.selectionToggle=t.Active,this.zoomToggle=t.Inactive,i.actionActive=this.selectionToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.actionMode=this.actionBarSelectionMode);break;case e.Zoom:this.zoomToggle=t.Active,this.selectionToggle=t.Inactive,i.actionActive=this.zoomToggle===t.Active,this.chartElement!==void 0&&(this.chartElement.actionMode=x.Zoom);break;case e.ClearSelection:i.actionActive=this.clearSelectionToggle===t.Active,this.chartElement?.clearSelection();break;case e.FullExtent:i.actionActive=this.fullExtentToggle===t.Active,this.chartElement?.resetZoom();break;case e.SwitchSelection:i.actionActive=this.switchSelectionToggle===t.Active,this.chartElement?.switchSelection();break;case e.ExportAsImage:i.actionActive=!0,await this.chartElement?.exportAsImage();break;case e.ExportAsCSV:i.actionActive=!0,await this.chartElement?.exportAsCSV();break}this.arcgisDefaultActionSelect.emit(i)}handleCalciteActionBarToggle(){this.expanded=this.calciteActionBar.value?.expanded??!1,this.setCustomActionsExpanded(),this.arcgisActionBarToggle.emit(this.expanded)}handleMouseOut(){this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))}handleSlotChange(l){let c=l.currentTarget.assignedElements();for(let i of c)i.onmouseover=this.handleMouseOver}setCustomActionsExpanded(){this.el.querySelectorAll("calcite-action").forEach(l=>{let c=l;c.textEnabled=this.expanded})}handleExpandTooltip(){this.expandAction===null&&(this.expandAction=this.calciteActionBar.value?.shadowRoot?.querySelector("calcite-action")??null,this.expandAction!==null&&(this.listenOn(this.expandAction,"mouseenter",()=>{!this.calciteActionBar.value?.expanded&&this.expandAction!==null&&!document.body.contains(this.actionTooltip)&&(this.actionTooltip=p(o`<calcite-tooltip style=${m({opacity:1,zIndex:"var(--calcite-floating-ui-z-index)"})} .referenceElement=${this.expandAction} open placement=trailing-end>${this._messages.expand??""}</calcite-tooltip>`),document.body.appendChild(this.actionTooltip))}),this.listenOn(this.expandAction,"mouseleave",()=>{!this.calciteActionBar.value?.expanded&&this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))}),this.listenOn(this.expandAction,"click",()=>{this.calciteActionBar.value?.expanded&&this.actionTooltip!==null&&(this.actionTooltip=n(this.actionTooltip))})))}renderDefaultActions(){let l=F(this.chartType).filter(N=>!this.hiddenActions?.includes(N)),c=this.chartElement?.layer&&"isTable"in this.chartElement.layer?this.chartElement.layer.isTable:!1,i=l.includes(e.EditChart),S=l.includes(e.Legend),$=l.includes(e.RotateChart),b=l.includes(e.FilterBySelection),f=l.includes(e.FilterByExtent)&&!c,C=l.includes(e.Zoom),y=l.includes(e.Selection),B=l.includes(e.ClearSelection),D=l.includes(e.FullExtent),k=l.includes(e.SwitchSelection),I=l.includes(e.ExportAsImage),w=l.includes(e.ExportAsCSV);return[S||$?o`<calcite-action-group>${i?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.EditChart??s} icon=gear .text=${this.commonStrings?.utilsStrings.actions?.editChart??""} .textEnabled=${this.expanded} .active=${this.editChartToggle===t.Active} .disabled=${this.editChartState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${S?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Legend??s} .text=${this.legendTitle??this._messages?.legend??""} .textEnabled=${this.expanded} .active=${this.legendToggle===t.Active} .disabled=${this.legendState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}><calcite-icon icon=legend scale=s flip-rtl></calcite-icon></calcite-action></div>`:null}${$?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.RotateChart??s} icon=rotate .text=${this.rotateChartTitle??this._messages?.rotateChart??""} .textEnabled=${this.expanded} .active=${this.rotateChartToggle===t.Active} .disabled=${this.rotateChartState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,b||f?o`<calcite-action-group>${b?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FilterBySelection??s} icon=selection-filter .text=${this.filterBySelectionTitle??this._messages?.filterBySelection??""} .textEnabled=${this.expanded} .active=${this.filterBySelectionToggle===t.Active} .disabled=${this.filterBySelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${f?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FilterByExtent??s} icon=extent-filter .text=${this.filterByExtentTitle??this._messages?.filterByExtent??""} .textEnabled=${this.expanded} .active=${this.filterByExtentToggle===t.Active} .disabled=${this.filterByExtentState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,y||C||D||B||k?o`<calcite-action-group>${C?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Zoom??s} icon=magnifying-glass .text=${this.zoomTitle??this._messages?.zoom??""} .textEnabled=${this.expanded} .active=${this.zoomToggle===t.Active} .disabled=${this.zoomState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${y?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.Selection??s} icon=cursor-selection .text=${this.selectionTitle??this._messages?.selection??""} .textEnabled=${this.expanded} .active=${this.selectionToggle===t.Active} .disabled=${this.selectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${B?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.ClearSelection??s} icon=erase .text=${this.clearSelectionTitle??this._messages?.clearSelection??""} .textEnabled=${this.expanded} .active=${this.clearSelectionToggle===t.Active} .disabled=${this.clearSelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${D?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.FullExtent??s} icon=zoom-out-fixed .text=${this.fullExtentTitle??this._messages?.fullExtent??""} .textEnabled=${this.expanded} .active=${this.fullExtentToggle===t.Active} .disabled=${this.fullExtentState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}${k?o`<div @mouseover=${this.handleMouseOver}><calcite-action id=${e.SwitchSelection??s} icon=arrow-right-left .text=${this.switchSelectionTitle??this._messages?.switchSelection??""} .textEnabled=${this.expanded} .active=${this.switchSelectionToggle===t.Active} .disabled=${this.switchSelectionState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick}></calcite-action></div>`:null}</calcite-action-group>`:null,I||w?o`<calcite-action-menu .label=${this._messages?.export??""} ${g(this.exportCalciteActionBar)}><calcite-action id=export icon=export .text=${this._messages?.export??""} .textEnabled=${this.expanded} .disabled=${this.exportActionState===a.Disabled||this.forceDisableActions} @mouseover=${this.handleMouseOver} slot=trigger></calcite-action>${I?o`<div><calcite-action id=${e.ExportAsImage??s} icon=graph-bar .text=${this.exportAsImageTitle??this._messages?.exportAsImage??""} .disabled=${this.exportAsImageState===a.Disabled||this.forceDisableActions} @click=${this.onDefaultActionClick} text-enabled></calcite-action></div>`:null}${w?o`<div><calcite-action id=${e.ExportAsCSV??s} icon=table .text=${this.exportAsCSVTitle??this._messages?.exportAsTable??""} .disabled=${this.exportAsCSVState===a.Disabled||this.forceDisableActions||this.chartType&&(this.disableCSVExportForChartTypes.includes(this.chartType)||this.csvExportExclusionList.includes(this.chartType))} @click=${this.onDefaultActionClick} text-enabled></calcite-action></div>`:null}</calcite-action-menu>`:null]}render(){return o`<calcite-action-bar class=${_(R.actionBar)} @calciteActionBarToggle=${this.handleCalciteActionBarToggle} @mouseout=${this.handleMouseOut} .expanded=${this.expanded} .messageOverrides=${{expand:this._messages.expand,collapse:this._messages.collapse}} overflow-actions-disabled ${g(this.calciteActionBar)}><slot name=${u.customActionTop} @slotchange=${this.handleSlotChange}></slot>${this.renderDefaultActions()}<slot name=${u.customActionBelow} @slotchange=${this.handleSlotChange}></slot></calcite-action-bar>`}};z("arcgis-charts-action-bar",T);return T},b,c,f,i,j,k,l,n)
@@ -1,2 +1,2 @@
1
1
  /* COPYRIGHT Esri - https://js.arcgis.com/5.2/LICENSE.txt */
2
- import c from"./Y7HYSSRW.js";import a from"./7LI5APDL.js";import{C as p,E as b,L as g,c as r}from"./PAIRUVLU.js";import{e as u}from"./547RDEMV.js";export default $arcgis.t(([{b:v,c:l},y])=>{var m=t=>{let e=!1;return t.legend!==void 0&&(e=t.legend.visible??!0),e},L=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.visible=t},V=t=>t.legend?.title?.content,M=(t,e)=>{e.legend===void 0&&(e.legend=g()),(e.legend.title===void 0||t===void 0)&&(e.legend.title=b({text:"",visible:!0,font:p(r.LegendTitle),type:r.LegendTitle})),t!==void 0&&(e.legend.title.content=t)},D=t=>t.legend?.body,O=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.body=t??b({text:"",visible:!0,font:p(r.LegendText),type:r.LegendText}).content},h=t=>t.legend?.title?.content.text??"",P=(t,e)=>{if(e.legend?.title!==void 0)e.legend.title.content.text=t;else if(e.legend===void 0&&t!==void 0){let i=g();i.title!==void 0&&(i.title.content.text=t,i.title.visible=!0,e.legend=i)}},R=t=>t.legend?.title?.visible??!1,j=(t,e)=>{if(e.legend?.title!==void 0)e.legend.title.visible=t;else if(e.legend!==void 0&&e.legend?.title===void 0&&t)e.legend.title=b({text:h(e),visible:t,font:p(r.LegendTitle),type:r.LegendTitle});else if(e.legend===void 0){let i=g();i.title=b({text:h(e),visible:t,font:p(r.LegendTitle),type:r.LegendTitle}),e.legend=i}},C=t=>t.legend?.position??u.Right,S=(t,e)=>{if(e.legend!==void 0)e.legend.position=t;else if(e.legend===void 0){let i=g();i.position=t,e.legend=i}},k=t=>t.legend?.roundMarkers??!1,H=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.roundMarkers=t},w=t=>t.legend?.maxHeight??void 0,E=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.maxHeight=t},I=Object.defineProperty,W=Object.getOwnPropertyDescriptor,a=(t,e,i,c)=>{for(var o=W(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&I(e,i,o),o},d=class extends y{get legendVisibility(){return m(this._config)}set legendVisibility(e){L(e,this._config)}get legendTitleText(){return h(this._config)}set legendTitleText(e){P(e,this._config)}get legendTitleVisibility(){return R(this._config)}set legendTitleVisibility(e){j(e,this._config)}get legendPosition(){return C(this._config)}set legendPosition(e){S(e,this._config)}get legendTitleSymbol(){return V(this._config)}set legendTitleSymbol(e){M(e,this._config)}get legendTextSymbol(){return D(this._config)}set legendTextSymbol(e){O(e,this._config)}get legendMaxHeight(){return w(this._config)}set legendMaxHeight(e){e!==void 0&&E(e,this._config)}get legendRoundMarker(){return k(this._config)}set legendRoundMarker(e){H(e,this._config)}};a([l],d.prototype,"legendVisibility");a([l],d.prototype,"legendTitleText");a([l],d.prototype,"legendTitleVisibility");a([l],d.prototype,"legendPosition");a([l],d.prototype,"legendTitleSymbol");a([l],d.prototype,"legendTextSymbol");a([l],d.prototype,"legendMaxHeight");a([l],d.prototype,"legendRoundMarker");var q=(t,e)=>t.series?.[e??0]?.dataTooltipVisible??!0,z=(t,e,i)=>{i&&t.series?.[i]?t.series[i].dataTooltipVisible=e:t.series&&t.series.forEach(c=>{c.dataTooltipVisible=e})},A=(t,e)=>t.series?.[e??0]?.dataTooltipReverseColor??!1,B=(t,e,i)=>{i&&t.series?.[i]?t.series[i].dataTooltipReverseColor=e:t.series&&t.series.forEach(c=>{c.dataTooltipReverseColor=e})},F=Object.defineProperty,G=Object.getOwnPropertyDescriptor,_=(t,e,i,c)=>{for(var o=G(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&F(e,i,o),o},f=class extends y{getDataTooltipVisibility(e){return q(this._config,e)}setDataTooltipVisibility(e,i){z(this._config,e,i)}getDataTooltipReverseColor(e){return A(this._config,e)}setDataTooltipReverseColor(e,i){B(this._config,e,i)}};_([l],f.prototype,"setDataTooltipVisibility");_([l],f.prototype,"setDataTooltipReverseColor");var J=Object.defineProperty,K=Object.getOwnPropertyDescriptor,N=(t,e,i,c)=>{for(var o=K(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&J(e,i,o),o},U=t=>t.colorMatch??!0,X=(t,e)=>{e.colorMatch=t},T=class extends v{get colorMatch(){return U(this._config)}set colorMatch(e){X(e,this._config)}};N([l],T.prototype,"colorMatch");var Y=Object.defineProperty,Z=Object.getOwnPropertyDescriptor,$=(t,e,i,c)=>{for(var o=Z(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&Y(e,i,o),o},Q=t=>t.series[0]?.dataLabels?.visible??!1,ee=(t,e)=>{e.series.forEach(i=>{i.dataLabels!==void 0?i.dataLabels.visible=t:i.dataLabels=b({text:"",visible:t,font:p(r.DataLabels),type:r.DataLabels})})},x=class extends v{get dataLabelsVisibility(){return Q(this._config)}set dataLabelsVisibility(e){ee(e,this._config)}};$([l],x.prototype,"dataLabelsVisibility");return{a:d,b:f,c:T,d:x}},a,c)
2
+ import c from"./OPMJTZOV.js";import a from"./FVGXWZBY.js";import{C as p,E as b,L as g,c as r}from"./PAIRUVLU.js";import{e as u}from"./547RDEMV.js";export default $arcgis.t(([{b:v,c:l},y])=>{var m=t=>{let e=!1;return t.legend!==void 0&&(e=t.legend.visible??!0),e},L=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.visible=t},V=t=>t.legend?.title?.content,M=(t,e)=>{e.legend===void 0&&(e.legend=g()),(e.legend.title===void 0||t===void 0)&&(e.legend.title=b({text:"",visible:!0,font:p(r.LegendTitle),type:r.LegendTitle})),t!==void 0&&(e.legend.title.content=t)},D=t=>t.legend?.body,O=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.body=t??b({text:"",visible:!0,font:p(r.LegendText),type:r.LegendText}).content},h=t=>t.legend?.title?.content.text??"",P=(t,e)=>{if(e.legend?.title!==void 0)e.legend.title.content.text=t;else if(e.legend===void 0&&t!==void 0){let i=g();i.title!==void 0&&(i.title.content.text=t,i.title.visible=!0,e.legend=i)}},R=t=>t.legend?.title?.visible??!1,j=(t,e)=>{if(e.legend?.title!==void 0)e.legend.title.visible=t;else if(e.legend!==void 0&&e.legend?.title===void 0&&t)e.legend.title=b({text:h(e),visible:t,font:p(r.LegendTitle),type:r.LegendTitle});else if(e.legend===void 0){let i=g();i.title=b({text:h(e),visible:t,font:p(r.LegendTitle),type:r.LegendTitle}),e.legend=i}},C=t=>t.legend?.position??u.Right,S=(t,e)=>{if(e.legend!==void 0)e.legend.position=t;else if(e.legend===void 0){let i=g();i.position=t,e.legend=i}},k=t=>t.legend?.roundMarkers??!1,H=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.roundMarkers=t},w=t=>t.legend?.maxHeight??void 0,E=(t,e)=>{e.legend===void 0&&(e.legend=g()),e.legend.maxHeight=t},I=Object.defineProperty,W=Object.getOwnPropertyDescriptor,a=(t,e,i,c)=>{for(var o=W(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&I(e,i,o),o},d=class extends y{get legendVisibility(){return m(this._config)}set legendVisibility(e){L(e,this._config)}get legendTitleText(){return h(this._config)}set legendTitleText(e){P(e,this._config)}get legendTitleVisibility(){return R(this._config)}set legendTitleVisibility(e){j(e,this._config)}get legendPosition(){return C(this._config)}set legendPosition(e){S(e,this._config)}get legendTitleSymbol(){return V(this._config)}set legendTitleSymbol(e){M(e,this._config)}get legendTextSymbol(){return D(this._config)}set legendTextSymbol(e){O(e,this._config)}get legendMaxHeight(){return w(this._config)}set legendMaxHeight(e){e!==void 0&&E(e,this._config)}get legendRoundMarker(){return k(this._config)}set legendRoundMarker(e){H(e,this._config)}};a([l],d.prototype,"legendVisibility");a([l],d.prototype,"legendTitleText");a([l],d.prototype,"legendTitleVisibility");a([l],d.prototype,"legendPosition");a([l],d.prototype,"legendTitleSymbol");a([l],d.prototype,"legendTextSymbol");a([l],d.prototype,"legendMaxHeight");a([l],d.prototype,"legendRoundMarker");var q=(t,e)=>t.series?.[e??0]?.dataTooltipVisible??!0,z=(t,e,i)=>{i&&t.series?.[i]?t.series[i].dataTooltipVisible=e:t.series&&t.series.forEach(c=>{c.dataTooltipVisible=e})},A=(t,e)=>t.series?.[e??0]?.dataTooltipReverseColor??!1,B=(t,e,i)=>{i&&t.series?.[i]?t.series[i].dataTooltipReverseColor=e:t.series&&t.series.forEach(c=>{c.dataTooltipReverseColor=e})},F=Object.defineProperty,G=Object.getOwnPropertyDescriptor,_=(t,e,i,c)=>{for(var o=G(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&F(e,i,o),o},f=class extends y{getDataTooltipVisibility(e){return q(this._config,e)}setDataTooltipVisibility(e,i){z(this._config,e,i)}getDataTooltipReverseColor(e){return A(this._config,e)}setDataTooltipReverseColor(e,i){B(this._config,e,i)}};_([l],f.prototype,"setDataTooltipVisibility");_([l],f.prototype,"setDataTooltipReverseColor");var J=Object.defineProperty,K=Object.getOwnPropertyDescriptor,N=(t,e,i,c)=>{for(var o=K(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&J(e,i,o),o},U=t=>t.colorMatch??!0,X=(t,e)=>{e.colorMatch=t},T=class extends v{get colorMatch(){return U(this._config)}set colorMatch(e){X(e,this._config)}};N([l],T.prototype,"colorMatch");var Y=Object.defineProperty,Z=Object.getOwnPropertyDescriptor,$=(t,e,i,c)=>{for(var o=Z(e,i),n=t.length-1,s;n>=0;n--)(s=t[n])&&(o=s(e,i,o)||o);return o&&Y(e,i,o),o},Q=t=>t.series[0]?.dataLabels?.visible??!1,ee=(t,e)=>{e.series.forEach(i=>{i.dataLabels!==void 0?i.dataLabels.visible=t:i.dataLabels=b({text:"",visible:t,font:p(r.DataLabels),type:r.DataLabels})})},x=class extends v{get dataLabelsVisibility(){return Q(this._config)}set dataLabelsVisibility(e){ee(e,this._config)}};$([l],x.prototype,"dataLabelsVisibility");return{a:d,b:f,c:T,d:x}},a,c)