@bino-bi/bn-template-engine 1.0.0-next.25 → 1.0.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 (142) hide show
  1. package/dist/bn-template-engine/bn-template-engine.esm.js +1 -1
  2. package/dist/bn-template-engine/p-0a19e8af.entry.js +1 -0
  3. package/dist/bn-template-engine/p-0f6ece5a.entry.js +1 -0
  4. package/dist/bn-template-engine/p-13db2986.entry.js +1 -0
  5. package/dist/bn-template-engine/p-1b35c4ac.entry.js +1 -0
  6. package/dist/bn-template-engine/{p-0fb02c57.entry.js → p-4602d613.entry.js} +1 -1
  7. package/dist/bn-template-engine/{p-fcfbb329.entry.js → p-489438ed.entry.js} +1 -1
  8. package/dist/bn-template-engine/{p-5d7a3a77.entry.js → p-6f86159c.entry.js} +1 -1
  9. package/dist/bn-template-engine/{p-45508f1b.entry.js → p-7401e3f3.entry.js} +1 -1
  10. package/dist/bn-template-engine/{p-b27009eb.entry.js → p-83d50a14.entry.js} +1 -1
  11. package/dist/bn-template-engine/{p-qRZrT-U3.js → p-BCr2-Ka-.js} +1 -1
  12. package/dist/bn-template-engine/{p-BbmobTg0.js → p-BEkgk7Ij.js} +1 -1
  13. package/dist/bn-template-engine/{p-CsJ84YRk.js → p-BVYKc5cH.js} +1 -1
  14. package/dist/bn-template-engine/{p-CWWWM-XC.js → p-BeLWoM0Q.js} +1 -1
  15. package/dist/bn-template-engine/p-CHZZqoB7.js +1 -0
  16. package/dist/bn-template-engine/p-CURM2Nrr.js +1 -0
  17. package/dist/bn-template-engine/{p-DVrDYxlh.js → p-Ckhir6Ux.js} +1 -1
  18. package/dist/bn-template-engine/{p-EtT29btN.js → p-Ct0wEGrw.js} +1 -1
  19. package/dist/bn-template-engine/p-CtEA0ZQc.js +1 -0
  20. package/dist/bn-template-engine/{p-DjPXefnq.js → p-DJ5KJ6GF.js} +1 -1
  21. package/dist/bn-template-engine/{p-BcaI745G.js → p-DoIuKI09.js} +1 -1
  22. package/dist/bn-template-engine/{p-B5Jd_eCX.js → p-DwGg2_vO.js} +1 -1
  23. package/dist/bn-template-engine/{p-CG_Bcm6V.js → p-Z-mcXias.js} +1 -1
  24. package/dist/bn-template-engine/p-aeba74a4.entry.js +1 -0
  25. package/dist/bn-template-engine/{p-4419db8f.entry.js → p-b4dabaf9.entry.js} +1 -1
  26. package/dist/bn-template-engine/{p-a5867a4c.entry.js → p-d083f0e6.entry.js} +1 -1
  27. package/dist/bn-template-engine/p-ee09f216.entry.js +1 -0
  28. package/dist/bn-template-engine/p-f00b189f.entry.js +1 -0
  29. package/dist/cjs/{AxisConfig-DwiNUyYG.js → AxisConfig-CbNnsmGC.js} +1 -1
  30. package/dist/cjs/{LabelCollisionManager-Bv-xkeXw.js → LabelCollisionManager-tOT40-pH.js} +2 -2
  31. package/dist/cjs/{Order-2wRydarc.js → Order-C5XgrPzr.js} +1 -1
  32. package/dist/cjs/SVGStyle-C1LhLgbT.js +6513 -0
  33. package/dist/cjs/{SVGVariancesStyleGroup-CiI4GeWe.js → SVGVariancesStyleGroup-C2Ys_Iz6.js} +1 -1
  34. package/dist/cjs/{VarianceMeasure-CQlSRzlp.js → VarianceMeasure-uph4FBRa.js} +1 -1
  35. package/dist/cjs/{XYChartDataRow-C2FdL58s.js → XYChartDataRow-BNqTnXnX.js} +4 -4
  36. package/dist/cjs/bn-asset_21.cjs.entry.js +123 -43
  37. package/dist/cjs/bn-chart-bubble.cjs.entry.js +15 -14
  38. package/dist/cjs/bn-chart-bullet.cjs.entry.js +14 -13
  39. package/dist/cjs/bn-chart-scatter.cjs.entry.js +14 -13
  40. package/dist/cjs/bn-grid.cjs.entry.js +5 -5
  41. package/dist/cjs/bn-image.cjs.entry.js +4 -4
  42. package/dist/cjs/bn-internationalization.cjs.entry.js +1 -1
  43. package/dist/cjs/bn-ruleset.cjs.entry.js +1 -1
  44. package/dist/cjs/bn-text.cjs.entry.js +5 -5
  45. package/dist/cjs/bn-tree.cjs.entry.js +5 -5
  46. package/dist/cjs/{context-protocol-DcTEh1rq.js → context-protocol-G4pi217i.js} +10 -10
  47. package/dist/cjs/{diagnostics-CTgbq_Gc.js → diagnostics-CRfecdNZ.js} +1 -1
  48. package/dist/cjs/editor-companion.cjs.entry.js +1 -1
  49. package/dist/cjs/{svgChartElements-tDA43aYj.js → emptyState-B3kPjSFO.js} +27 -4
  50. package/dist/cjs/ibcs-chart-bubble.cjs.entry.js +9 -8
  51. package/dist/cjs/ibcs-chart-bullet.cjs.entry.js +9 -8
  52. package/dist/cjs/ibcs-chart-scatter.cjs.entry.js +9 -8
  53. package/dist/cjs/{scaling-Dsb5_NXy.js → scaling-BGTK5H0H.js} +1 -1
  54. package/dist/cjs/{withScalingGroup-CFIc5-6s.js → withScalingGroup-DrFV_zsQ.js} +1 -1
  55. package/dist/cjs/{withStyled-D0jLwCib.js → withStyled-CZCnmfPw.js} +3 -3
  56. package/dist/collection/components/bn-chart-bubble/bn-chart-bubble.css +40 -0
  57. package/dist/collection/components/bn-chart-bubble/bn-chart-bubble.js +3 -1
  58. package/dist/collection/components/bn-chart-bubble/ibcs-chart-bubble.css +37 -5
  59. package/dist/collection/components/bn-chart-bubble/ibcs-chart-bubble.js +3 -2
  60. package/dist/collection/components/bn-chart-bullet/bn-chart-bullet.css +40 -0
  61. package/dist/collection/components/bn-chart-bullet/bn-chart-bullet.js +3 -1
  62. package/dist/collection/components/bn-chart-bullet/ibcs-chart-bullet.css +37 -5
  63. package/dist/collection/components/bn-chart-bullet/ibcs-chart-bullet.js +3 -2
  64. package/dist/collection/components/bn-chart-scatter/bn-chart-scatter.css +40 -0
  65. package/dist/collection/components/bn-chart-scatter/bn-chart-scatter.js +3 -1
  66. package/dist/collection/components/bn-chart-scatter/ibcs-chart-scatter.css +37 -5
  67. package/dist/collection/components/bn-chart-scatter/ibcs-chart-scatter.js +3 -2
  68. package/dist/collection/components/bn-chart-structure/bn-chart-structure.css +40 -5
  69. package/dist/collection/components/bn-chart-structure/bn-chart-structure.js +16 -2
  70. package/dist/collection/components/bn-chart-structure/ibcs-chart-structure.js +4 -4
  71. package/dist/collection/components/bn-chart-time/bn-chart-time.css +40 -0
  72. package/dist/collection/components/bn-chart-time/bn-chart-time.js +24 -2
  73. package/dist/collection/components/bn-chart-time/ibcs-chart-time.css +37 -0
  74. package/dist/collection/components/bn-chart-time/ibcs-chart-time.js +4 -4
  75. package/dist/collection/components/bn-table/bn-table.css +41 -1
  76. package/dist/collection/components/bn-table/bn-table.js +49 -4
  77. package/dist/collection/components/bn-table/ibcs-table.css +37 -0
  78. package/dist/collection/components/bn-table/ibcs-table.js +5 -3
  79. package/dist/collection/stores/internationalization.js +10 -10
  80. package/dist/collection/utils/emptyState.js +21 -0
  81. package/dist/collection/utils/testing/hostFont.js +20 -0
  82. package/dist/components/bn-chart-bubble.js +1 -1
  83. package/dist/components/bn-chart-bullet.js +1 -1
  84. package/dist/components/bn-chart-scatter.js +1 -1
  85. package/dist/components/bn-chart-structure.js +1 -1
  86. package/dist/components/bn-chart-time.js +1 -1
  87. package/dist/components/bn-table.js +1 -1
  88. package/dist/components/context-protocol.js +1 -1
  89. package/dist/components/emptyState.js +1 -0
  90. package/dist/components/ibcs-chart-bubble2.js +1 -1
  91. package/dist/components/ibcs-chart-bullet2.js +1 -1
  92. package/dist/components/ibcs-chart-scatter2.js +1 -1
  93. package/dist/components/ibcs-chart-structure2.js +1 -1
  94. package/dist/components/ibcs-chart-time2.js +1 -1
  95. package/dist/components/ibcs-table2.js +1 -1
  96. package/dist/components/svg.esm.js +1 -0
  97. package/dist/esm/{AxisConfig-KqzWQbML.js → AxisConfig-CEFoGHUN.js} +1 -1
  98. package/dist/esm/{LabelCollisionManager-585bQMtP.js → LabelCollisionManager-Dou5LvUs.js} +2 -2
  99. package/dist/esm/{Order-DZVWjEL_.js → Order-Tn0j255j.js} +1 -1
  100. package/dist/esm/SVGStyle-BSuFK9YW.js +6503 -0
  101. package/dist/esm/{SVGVariancesStyleGroup-DO5QJfRQ.js → SVGVariancesStyleGroup-D52LMGw8.js} +1 -1
  102. package/dist/esm/{VarianceMeasure-DDjChp8C.js → VarianceMeasure-BXWH7oAW.js} +1 -1
  103. package/dist/esm/{XYChartDataRow-Dn83Tqh9.js → XYChartDataRow-D272UFel.js} +4 -4
  104. package/dist/esm/bn-asset_21.entry.js +114 -34
  105. package/dist/esm/bn-chart-bubble.entry.js +12 -11
  106. package/dist/esm/bn-chart-bullet.entry.js +11 -10
  107. package/dist/esm/bn-chart-scatter.entry.js +11 -10
  108. package/dist/esm/bn-grid.entry.js +5 -5
  109. package/dist/esm/bn-image.entry.js +4 -4
  110. package/dist/esm/bn-internationalization.entry.js +1 -1
  111. package/dist/esm/bn-ruleset.entry.js +1 -1
  112. package/dist/esm/bn-text.entry.js +5 -5
  113. package/dist/esm/bn-tree.entry.js +5 -5
  114. package/dist/esm/{context-protocol-B-vdGKeG.js → context-protocol-D_ysqCp8.js} +10 -10
  115. package/dist/esm/{diagnostics-CiquIw8B.js → diagnostics-BjZRZraG.js} +1 -1
  116. package/dist/esm/editor-companion.entry.js +1 -1
  117. package/dist/esm/{svgChartElements-B3YClivG.js → emptyState-DqkM4Yc5.js} +27 -5
  118. package/dist/esm/ibcs-chart-bubble.entry.js +9 -8
  119. package/dist/esm/ibcs-chart-bullet.entry.js +9 -8
  120. package/dist/esm/ibcs-chart-scatter.entry.js +9 -8
  121. package/dist/esm/{scaling-Dggyeqts.js → scaling-YbP727FC.js} +1 -1
  122. package/dist/esm/{withScalingGroup-DNBSqRC0.js → withScalingGroup-Byn-W6z8.js} +1 -1
  123. package/dist/esm/{withStyled-DoNsbwS3.js → withStyled-3yRswBcf.js} +3 -3
  124. package/dist/types/components/bn-table/bn-table.d.ts +19 -0
  125. package/dist/types/components.d.ts +2 -2
  126. package/dist/types/utils/emptyState.d.ts +10 -0
  127. package/dist/types/utils/testing/hostFont.d.ts +16 -0
  128. package/package.json +2 -2
  129. package/dist/bn-template-engine/p-03304284.entry.js +0 -1
  130. package/dist/bn-template-engine/p-0b2e1661.entry.js +0 -1
  131. package/dist/bn-template-engine/p-2fbc2d50.entry.js +0 -1
  132. package/dist/bn-template-engine/p-36f1c5f9.entry.js +0 -1
  133. package/dist/bn-template-engine/p-62cc95b7.entry.js +0 -1
  134. package/dist/bn-template-engine/p-BcLsoDrW.js +0 -1
  135. package/dist/bn-template-engine/p-D5e8I9Qe.js +0 -1
  136. package/dist/bn-template-engine/p-TuLpbB5O.js +0 -1
  137. package/dist/bn-template-engine/p-e30c7251.entry.js +0 -1
  138. package/dist/bn-template-engine/p-f06c3703.entry.js +0 -1
  139. package/dist/cjs/SVGStyle-DoxylrEQ.js +0 -8219
  140. package/dist/components/layoutObserver.js +0 -1
  141. package/dist/components/main.js +0 -1
  142. package/dist/esm/SVGStyle-OrPkzjcb.js +0 -8209
@@ -1 +1 @@
1
- import{D as t}from"./p-D5e8I9Qe.js";const n=t=>{if("object"==typeof t&&null!==t){if("function"==typeof Object.getPrototypeOf){const n=Object.getPrototypeOf(t);return n===Object.prototype||null===n}return"[object Object]"===Object.prototype.toString.call(t)}return!1},e=(t,n)=>n,r=(t,n)=>[...new Set([...t,...n])],a=(t,s)=>{const c=(t=>{return{arrayMergeType:"combine",arrayMerge:(n=t?t.arrayMergeType:"combine","overwrite"===n?e:r),...t};var n})(s);return t.reduce(((t,e)=>(Object.keys(e).forEach((r=>{Array.isArray(t[r])&&Array.isArray(e[r])?c&&c.arrayMerge&&(t[r]=c.arrayMerge(t[r],e[r])):t[r]=n(t[r])&&n(e[r])?a([t[r],e[r]],c):e[r]})),t)),{})};var s,c,o,u,i,l,f,p;!function(t){t.ALL="all",t.META="meta"}(s||(s={})),function(t){t.CURRENCY="currency",t.VOLUME="volume"}(c||(c={})),function(t){t.AC1="ac1",t.AC2="ac2",t.AC3="ac3",t.AC4="ac4",t.PP1="pp1",t.PP2="pp2",t.PP3="pp3",t.PP4="pp4",t.FC1="fc1",t.FC2="fc2",t.FC3="fc3",t.FC4="fc4",t.PL1="pl1",t.PL2="pl2",t.PL3="pl3",t.PL4="pl4"}(o||(o={})),function(t){t.POS="pos",t.NEG="neg",t.NEU="neu"}(u||(u={})),function(t){t.DECIMAL="decimal",t.PERCENT="percent"}(i||(i={})),function(t){t.LIST="list",t.SUM="sum",t.SUMNOTOTAL="sumnototal",t.OPT="opt",t.OPTNOTOTAL="optnototal"}(l||(l={})),function(t){t.INF="inf",t.W100="w100",t.W50="w50",t.W25="w25",t.W20="w20",t.W15="w15",t.W10="w10",t.W5="w5"}(f||(f={})),function(t){t.W5="w5",t.W10="w10",t.W15="w15",t.W20="w20",t.W25="w25",t.W30="w30",t.W40="w40",t.W60="w60",t.W80="w80",t.W100="w100"}(p||(p={}));const b={[p.W5]:5,[p.W10]:10,[p.W15]:15,[p.W20]:20,[p.W25]:25,[p.W30]:30,[p.W40]:40,[p.W60]:60,[p.W80]:80,[p.W100]:100};var w,m,y,d,g,j;!function(t){t.ROWGROUP="rowGroup",t.ROWGROUPINDEX="rowGroupIndex",t.CATEGORY="category",t.CATEGORYINDEX="categoryIndex",t.SUBCATEGORY="subCategory",t.SUBCATEGORYINDEX="subCategoryIndex"}(w||(w={})),function(t){t.SMART="smart",t.LONG="long",t.SHORT="short"}(m||(m={})),function(t){t.COLUMN="column",t.LINE="line",t.WATERFALL="waterfall"}(y||(y={})),function(t){t.BAR="bar",t.LINE="line",t.AUTO="auto"}(d||(d={})),function(t){t.SCENARIOS="scenarios",t.DIMENSIONS="dimensions"}(g||(g={})),function(t){t.ABSOLUTE="absolute",t.RELATIVE="relative",t.ABSOLUTE_RELATIVE="absolute-relative"}(j||(j={}));const v=100;var O;!function(t){t.ASC="asc",t.DESC="desc",t.DATASET="dataset"}(O||(O={}));class h{static isExisting(t){return null!=t}static isString(t){return"string"==typeof t}static isNumber(t){return"number"==typeof t&&!Number.isNaN(t)}static isBoolean(t){return"boolean"==typeof t}static isArray(t){return Array.isArray(t)}static isObject(t){return"object"==typeof t&&null!==t}static isOperator(t){return"+"===t||"-"===t}static isDate(n){return n instanceof t&&n.isValid}}const x=/^(dr|d)((?:ac|pp|fc|pl)[1-4])_((?:ac|pp|fc|pl)[1-4])(?:_(pos|neg|neu))?$/;class A{constructor(t,n,e){this.type=t,this.base=n,this.delta=e}static parse(t){const n=x.exec(t);return null===n?null:new A(n[1],n[2],n[3])}compute(t,n){return null==t||null==n?null:"dr"===this.type?0===n?null:(t-n)/n:t-n}}function I(t){const n=t.trim();if(Object.values(o).includes(n))return{kind:"scenario",slot:n};const e=A.parse(n);return null!==e?{kind:"variance",measure:e}:null}function D(t){return t.replace(/\d+$/,"")}function C(t){return t.replace(/^[a-z]+/,"")}export{w as A,b as B,h as C,i as D,s as I,c as M,v as R,o as S,p as T,C as a,u as b,m as c,l as d,f as e,g as f,O as g,j as h,d as i,a as m,I as r,D as s}
1
+ import{D as t}from"./p-CURM2Nrr.js";const n=t=>{if("object"==typeof t&&null!==t){if("function"==typeof Object.getPrototypeOf){const n=Object.getPrototypeOf(t);return n===Object.prototype||null===n}return"[object Object]"===Object.prototype.toString.call(t)}return!1},r=(t,n)=>n,e=(t,n)=>[...new Set([...t,...n])],a=(t,s)=>{const c=(t=>{return{arrayMergeType:"combine",arrayMerge:(n=t?t.arrayMergeType:"combine","overwrite"===n?r:e),...t};var n})(s);return t.reduce(((t,r)=>(Object.keys(r).forEach((e=>{Array.isArray(t[e])&&Array.isArray(r[e])?c&&c.arrayMerge&&(t[e]=c.arrayMerge(t[e],r[e])):t[e]=n(t[e])&&n(r[e])?a([t[e],r[e]],c):r[e]})),t)),{})};var s,c,o,u,i,l,f,p;!function(t){t.ALL="all",t.META="meta"}(s||(s={})),function(t){t.CURRENCY="currency",t.VOLUME="volume"}(c||(c={})),function(t){t.AC1="ac1",t.AC2="ac2",t.AC3="ac3",t.AC4="ac4",t.PP1="pp1",t.PP2="pp2",t.PP3="pp3",t.PP4="pp4",t.FC1="fc1",t.FC2="fc2",t.FC3="fc3",t.FC4="fc4",t.PL1="pl1",t.PL2="pl2",t.PL3="pl3",t.PL4="pl4"}(o||(o={})),function(t){t.POS="pos",t.NEG="neg",t.NEU="neu"}(u||(u={})),function(t){t.DECIMAL="decimal",t.PERCENT="percent"}(i||(i={})),function(t){t.LIST="list",t.SUM="sum",t.SUMNOTOTAL="sumnototal",t.OPT="opt",t.OPTNOTOTAL="optnototal"}(l||(l={})),function(t){t.INF="inf",t.W100="w100",t.W50="w50",t.W25="w25",t.W20="w20",t.W15="w15",t.W10="w10",t.W5="w5"}(f||(f={})),function(t){t.W5="w5",t.W10="w10",t.W15="w15",t.W20="w20",t.W25="w25",t.W30="w30",t.W40="w40",t.W60="w60",t.W80="w80",t.W100="w100"}(p||(p={}));const b={[p.W5]:5,[p.W10]:10,[p.W15]:15,[p.W20]:20,[p.W25]:25,[p.W30]:30,[p.W40]:40,[p.W60]:60,[p.W80]:80,[p.W100]:100};var w,m,y,d,g,j;!function(t){t.ROWGROUP="rowGroup",t.ROWGROUPINDEX="rowGroupIndex",t.CATEGORY="category",t.CATEGORYINDEX="categoryIndex",t.SUBCATEGORY="subCategory",t.SUBCATEGORYINDEX="subCategoryIndex"}(w||(w={})),function(t){t.SMART="smart",t.LONG="long",t.SHORT="short"}(m||(m={})),function(t){t.COLUMN="column",t.LINE="line",t.WATERFALL="waterfall"}(y||(y={})),function(t){t.BAR="bar",t.LINE="line",t.AUTO="auto"}(d||(d={})),function(t){t.SCENARIOS="scenarios",t.DIMENSIONS="dimensions"}(g||(g={})),function(t){t.ABSOLUTE="absolute",t.RELATIVE="relative",t.ABSOLUTE_RELATIVE="absolute-relative"}(j||(j={}));const v=100;var O;!function(t){t.ASC="asc",t.DESC="desc",t.DATASET="dataset"}(O||(O={}));class h{static isExisting(t){return null!=t}static isString(t){return"string"==typeof t}static isNumber(t){return"number"==typeof t&&!Number.isNaN(t)}static isBoolean(t){return"boolean"==typeof t}static isArray(t){return Array.isArray(t)}static isObject(t){return"object"==typeof t&&null!==t}static isOperator(t){return"+"===t||"-"===t}static isDate(n){return n instanceof t&&n.isValid}}const x=/^(dr|d)((?:ac|pp|fc|pl)[1-4])_((?:ac|pp|fc|pl)[1-4])(?:_(pos|neg|neu))?$/;class A{constructor(t,n,r){this.type=t,this.base=n,this.delta=r}static parse(t){const n=x.exec(t);return null===n?null:new A(n[1],n[2],n[3])}compute(t,n){return null==t||null==n?null:"dr"===this.type?0===n?null:(t-n)/n:t-n}}function C(t){const n=t.trim();if(Object.values(o).includes(n))return{kind:"scenario",slot:n};const r=A.parse(n);return null!==r?{kind:"variance",measure:r}:null}function I(t){return t.replace(/\d+$/,"")}function M(t){return t.replace(/^[a-z]+/,"")}export{w as A,b as B,h as C,i as D,s as I,c as M,v as R,o as S,p as T,M as a,u as b,m as c,l as d,f as e,g as f,O as g,j as h,d as i,a as m,C as r,I as s}
@@ -1 +1 @@
1
- import{g as t,f as e}from"./p-C5UYpZUU.js";import{g as s,c as r,D as n}from"./p-D5e8I9Qe.js";import{r as a}from"./p-DtLI_CzV.js";import{m as i,S as o,b as u,A as c,c as l,T as h,D as d,d as m,M as f,e as y,r as b}from"./p-BbmobTg0.js";import{b as N,O as g}from"./p-B5Jd_eCX.js";const p=n=>{let o,u,c,l;const h=()=>{const t=u.componentStyles.state;l=i([t._system||{},t._default||{},t[c]||{}],{arrayMergeType:"overwrite"})},d=new MutationObserver((s=>{s.forEach((s=>{"selected-style"===s.attributeName&&(c=t(n).getAttribute("selected-style"),h(),e(n))}))})),m=n.connectedCallback;n.connectedCallback=()=>{const r=t(n);u=s(r),l=u.componentStyles.state._system,d.observe(r,{attributes:!0,attributeFilter:["selected-style"]}),c=t(n).getAttribute("selected-style"),h(),o=u.componentStyles.on("set",(s=>{s===c&&(c=t(n).getAttribute("selected-style"),h(),e(t(n)))})),a(m,n)};const f=n.disconnectedCallback;return n.disconnectedCallback=()=>{d.disconnect(),a(o),r(t(n)),a(f,n)},t=>t(l)},v=/^\s*(set|first|last|min|max|avg|sum|lit)\(\s*(.*?)\s*\)\s*$/,S=/^[A-Za-z_][A-Za-z0-9_]*$/,D=["min","max","avg","sum"];class k{constructor(t,e,s,r){this.label=t,this.alias=e,this.fn=s,this.arg=r}get isNumeric(){return D.includes(this.fn)}}function w(t){if("string"!=typeof t)return!1;const e=v.exec(t);if(!e)return!1;const[,s,r]=e;return"lit"===s?r.length>0:S.test(r)}function T(t,e,s){if(!w(s))return null;const[,r,n]=v.exec(s);return new k(t,e,r,n)}var O,A;!function(t){t.YEAR="year",t.QUARTER="quarter",t.MONTH="month",t.WEEK="week",t.DAY="day",t.HOUR="hour",t.MINUTE="minute",t.SECOND="second",t.MILLISECOND="millisecond",t.NONE="fallback",t.AUTO="auto"}(O||(O={})),function(t){t.AVG="avg",t.INTERVAL="interval",t.START="start",t.END="end",t.YTD="ytd",t.YTG="ytg",t.CUM="cum",t.MAT="mat",t.NONE="none",t.AUTO="auto"}(A||(A={}));class M{constructor(){this._dateFormat={year:"yyyy",quarter:"q'Q' yyyy",month:"LLL yyyy",week:"'KW'WW yyyy",day:"dd.MM.yyyy",hour:"TT",minute:"TT",second:"TT",millisecond:"TT:SSS",fallback:"dd.MM.yyyy"},this._dateFormatShort={year:"yy",quarter:"q'Q'",month:"LLL",week:"'KW'WW",day:"dd",hour:"hh'h'",minute:"mm'm'",second:"ss's'",millisecond:"SSS'ms'",fallback:"dd.MM.yyyy"},this._dateLinkFormat={avg:"Ø[LINK]",interval:"[DATE]..[DATE2]",start:".[DATE]",end:"[DATE].",ytd:"_[DATE]",ytg:"[DATE]_",cum:"[DATE]_[DATE2]",mat:"~[DATE]",none:"[DATE]"},this.locale="de",this.dateFormatPinned=!1,this.dateFormatShortPinned=!1,this.dateFormat=this._dateFormat,this.dateLinkFormat=this._dateLinkFormat,this.dateFormatShort=this._dateFormatShort}setDateLinkFormat(t){this.dateLinkFormat=t}setDateFormat(t){this.dateFormat=t,this.dateFormatPinned=!0}setDateFormatShort(t){this.dateFormatShort=t,this.dateFormatShortPinned=!0}setLocale(t){this.locale=t,this.dateFormatPinned||(this.dateFormat=Object.assign(Object.assign({},this._dateFormat),M.LOCALE_DATE_FORMAT[t]||{})),this.dateFormatShortPinned||(this.dateFormatShort=Object.assign(Object.assign({},this._dateFormatShort),M.LOCALE_DATE_FORMAT_SHORT[t]||{}))}getDateString(t,e){return t.setLocale(this.locale).toFormat(this.dateFormat[e]||this.dateFormat.fallback)}getSmartDateString(t,e){switch(e){case O.DAY:return this.getFormatedDayDate(t);case O.MONTH:return this.getFormatedMonthDate(t);case O.QUARTER:return this.getFormatedQuarterDate(t);case O.WEEK:return this.getFormatedWeekDate(t);case O.HOUR:return this.getFormatedHourDate(t);case O.MINUTE:return this.getFormatedMinuteDate(t);case O.SECOND:return this.getFormatedSecondDate(t);case O.MILLISECOND:return this.getFormatedMilliSecondDate(t);default:return this.getDateString(t,e)}}calculateDistanceType(t,e,s=32){if(null==e)return O.DAY;const r="number"==typeof t?n.fromMillis(t):t,a="number"==typeof e?n.fromMillis(e):e;return 0===a.diff(r).as("milliseconds")?O.DAY:a.diff(r).as("milliseconds")<s?O.MILLISECOND:a.diff(r).as("seconds")<s?O.SECOND:a.diff(r).as("minutes")<s?O.MINUTE:a.diff(r).as("hours")<s?O.HOUR:a.diff(r).as("days")<s?O.DAY:a.diff(r).as("weeks")<s?O.WEEK:a.diff(r).as("months")<s?O.MONTH:a.diff(r).as("quarters")<s?O.QUARTER:O.YEAR}datesBetween(t,e,s,r){const n=this.convertDateDistanceToMomentunitOfTime(s),a=t.startOf(n),i=e.endOf(n);let o=i.diff(a).as(n);const u=[];o>=r&&(o=r);let c=a;do{u.push(c),c=c.plus(this.createDiratonLike(n,1))}while(c<=i&&u.length<o);return u}getDateLinkString(t,e,s,r,a){if(null==t&&null==e)return"";if(null==t&&s!==A.END&&s!==A.YTD)return"";if(null==e&&(A.INTERVAL===s||A.CUM===s||A.END===s||A.YTD===s))return"";const i=t||n.now(),o=e;r===O.AUTO&&(r=this.calculateDistanceType(i,o,a));let u=this.getDateString(i,r),c="",l=A.NONE;return null!=o&&(c=this.getDateString(o,r),l=A.INTERVAL,u===c&&s===A.INTERVAL&&(s=A.NONE),u===c&&s===A.AVG&&(l=A.NONE),A.END!==s&&A.YTD!==s||(u=c),(s===A.INTERVAL||s===A.CUM||A.AVG)&&(r===O.QUARTER?i.quarter===o.quarter&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,"")):r===O.MONTH?i.month===o.month&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,"")):r===O.WEEK&&(i.weekNumber===o.weekNumber&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,""))))),this.dateLinkFormat[s].replace("[LINK]",this.dateLinkFormat[l]).replace("[DATE]",u).replace("[DATE2]",c)}getShortDateString(t,e){return t.setLocale(this.locale).toFormat(this.dateFormatShort[e]||this.dateFormatShort.fallback)}getFormatedDayDate(t){let e=this.dateFormatShort.day;return this.isFirstInMonth(t)&&(e+=" "+this.dateFormatShort.month),this.isJanuary(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedMonthDate(t){let e=this.dateFormatShort.month;return this.isJanuary(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedQuarterDate(t){let e=this.dateFormatShort.quarter;return this.isFirstQuarter(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedWeekDate(t){let e=this.dateFormatShort.week;return this.isFirstWeek(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedHourDate(t){let e=this.dateFormatShort.hour;return this.isFirstHour(t)&&(e+=" "+this.dateFormatShort.day),t.setLocale(this.locale).toFormat(e)}getFormatedMinuteDate(t){let e=this.dateFormatShort.minute;return this.isFirstMinute(t)&&(e=this.dateFormatShort.hour+":"+e),t.setLocale(this.locale).toFormat(e)}getFormatedSecondDate(t){let e=this.dateFormatShort.second;return this.isFirstSecond(t)&&(e=this.dateFormatShort.minute+":"+e),t.setLocale(this.locale).toFormat(e)}getFormatedMilliSecondDate(t){let e=this.dateFormatShort.millisecond;return this.isFirstMilliSecond(t)&&(e=this.dateFormatShort.second+":"+e),t.setLocale(this.locale).toFormat(e)}isFirstInMonth(t){return 1===t.day}isJanuary(t){return 1===t.month}isFirstQuarter(t){return 1===t.quarter}isFirstWeek(t){return 1===t.weekNumber}isFirstHour(t){return 0===t.hour}isFirstMinute(t){return 0===t.minute}isFirstSecond(t){return 0===t.second}isFirstMilliSecond(t){return 0===t.millisecond}convertDateDistanceToMomentunitOfTime(t){let e;switch(t){case O.YEAR:e="year";break;case O.MONTH:e="month";break;case O.QUARTER:e="quarter";break;case O.WEEK:e="week";break;case O.DAY:e="day";break;case O.HOUR:e="hour";break;case O.MINUTE:e="minute";break;case O.SECOND:e="second";break;case O.MILLISECOND:e="millisecond";break;default:e="day"}return e}createDiratonLike(t,e){switch(t){case"year":return{years:e};case"month":return{months:e};case"quarter":return{quarters:e};case"week":return{weeks:e};case"day":default:return{days:e};case"hour":return{hours:e};case"minute":return{minutes:e};case"second":return{seconds:e};case"millisecond":return{milliseconds:e}}}}function J(t){return null==t||""===t||"null"===t}function F(t){return J(t)||"auto"===t.trim().toLowerCase()?[]:E((null==t?void 0:t.split(",").filter((t=>!(t.toUpperCase().trim()in o)))).toString())}function E(t){return J(t)?[]:t.replace(";",",").split(",").filter((t=>{var e,s,r;const n=t.split("_"),a=null===(e=n[0])||void 0===e?void 0:e.replace(/^dr|^d/,"").toUpperCase().trim(),i=null===(s=n[1])||void 0===s?void 0:s.toUpperCase().trim(),c=null===(r=n[2])||void 0===r?void 0:r.toUpperCase().trim();return 3!==n.length||!(a in o)||!(i in o)||!(c in u)}))}function L(t){return J(t)?[]:E(t.split(",").filter((t=>!(t.toUpperCase().trim()in o))).toString())}function j(t){return J(t)||"auto"===t.trim().toLowerCase()?[]:E(t.split(",").filter((t=>!(t.toUpperCase()in N))).toString())}function W(t){return!J(t)&&Number.isInteger(Number(t))}function $(t){return!J(t)&&!Number.isNaN(Number(t))}function q(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in g}function I(t){return"auto"===(null==t?void 0:t.toLowerCase())||(null==t?void 0:t.toUpperCase())in c}function _(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("name")&&t.hasOwnProperty("unit"))))}catch(t){console.error("validateMeasureList: failed to parse JSON",t)}return["Invalid JSON structure"]}function z(t){const e=Date.parse(t);return Number.isInteger(e)}function C(t){return(null==t?void 0:t.toUpperCase())in A}function x(t){return(null==t?void 0:t.toUpperCase())in O}function G(t){return(null==t?void 0:t.toUpperCase())in l}function Q(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in d}function B(t){return!J(t)&&["true","false",!0,!1].some((e=>e===t))}function K(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in m}function Z(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("rowGroup")&&t.hasOwnProperty("category")&&t.hasOwnProperty("subCategory"))))}catch(t){console.error("validateThereOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function H(t){if(J(t))return[];try{const e=JSON.parse(t);if(null!==e&&"object"==typeof e&&!(e instanceof Array))return Object.entries(e).filter((([,t])=>"string"!=typeof t||!w(t))).map((([t,e])=>`${t}: ${e}`))}catch(t){console.error("validateAttributesJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function U(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("rowGroup")&&t.hasOwnProperty("category"))))}catch(t){console.error("validatePartOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function P(t){return(null==t?void 0:t.trim().toUpperCase())in f}function Y(t){return["_","k","M","G","T","P","E","Z","Y","m","my","μ","n","p","f","a","z","y"].includes(null==t?void 0:t.trim())||["GREATEST","LEAST"].includes(null==t?void 0:t.trim().toUpperCase())}function R(t){return(null==t?void 0:t.toUpperCase().trim())in y}function V(t){return(null==t?void 0:t.toUpperCase().trim())in h}function X(t){if(J(t))return[];try{return JSON.parse(t).filter((t=>!(t.hasOwnProperty("scenario")&&t.hasOwnProperty("name")&&t.hasOwnProperty("subGroups"))))}catch(t){console.error("validateColumnThereOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function tt(t){if(J(t))return[];try{const e=JSON.parse(t);if("object"!=typeof e||null===e||Array.isArray(e))return["stack: must be a JSON object"];const s=[];if(e.hasOwnProperty("by")){const t=["scenarios","dimensions"];t.includes(e.by)||s.push(`stack: 'by' must be one of: ${t.join(", ")}`)}else s.push("stack: 'by' is required");if(e.hasOwnProperty("mode")){const t=["absolute","relative","absolute-relative"];t.includes(e.mode)||s.push(`stack: 'mode' must be one of: ${t.join(", ")}`)}if(e.hasOwnProperty("order")){const t=["asc","desc","dataset"];t.includes(e.order)||s.push(`stack: 'order' must be one of: ${t.join(", ")}`)}return s}catch(t){return["stack: invalid JSON"]}}function et(t){return!J(t)&&null!==b(t)}M.LOCALE_DATE_FORMAT={en:{week:"'W'WW yyyy",day:"MM/dd/yyyy",fallback:"MM/dd/yyyy"}},M.LOCALE_DATE_FORMAT_SHORT={en:{week:"'W'WW",fallback:"MM/dd/yyyy"}};class st{constructor(){this.cache=new Map,this.tag=st.makeStyleTag()}static makeStyleTag(){const t=document.createElement("style");return t.type="text/css",t.setAttribute("data-bn-computed-style",""),t.append(document.createTextNode("")),(document.head||document.querySelector("head")).append(t),t}apply(t){t.forEach((t=>this.cache.set(t.className,t.style))),this.tag.innerHTML=Array.from(this.cache.values()).map((t=>t)).join("\n")}}const rt=new st;function nt(t){for(var e,s=0,r=0,n=t.length;n>=4;++r,n-=4)e=1540483477*(65535&(e=255&t.charCodeAt(r)|(255&t.charCodeAt(++r))<<8|(255&t.charCodeAt(++r))<<16|(255&t.charCodeAt(++r))<<24))+(59797*(e>>>16)<<16),s=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&s)+(59797*(s>>>16)<<16);switch(n){case 3:s^=(255&t.charCodeAt(r+2))<<16;case 2:s^=(255&t.charCodeAt(r+1))<<8;case 1:s=1540483477*(65535&(s^=255&t.charCodeAt(r)))+(59797*(s>>>16)<<16)}return(((s=1540483477*(65535&(s^=s>>>13))+(59797*(s>>>16)<<16))^s>>>15)>>>0).toString(36)}const at=t=>$(t)?`${t}px`:t,it={width:{className:"w",cssName:"width",attrName:"width",transform:at},height:{className:"h",cssName:"height",attrName:"height",transform:at},position:{className:"pst",cssName:"position",attrName:"position"},top:{className:"top",cssName:"top",attrName:"top",transform:at},right:{className:"rgt",cssName:"right",attrName:"right",transform:at},bottom:{className:"btm",cssName:"bottom",attrName:"bottom",transform:at},left:{className:"lft",cssName:"left",attrName:"left",transform:at},"font-size":{className:"fts",cssName:"font-size",attrName:"font-size",transform:at},"grid-column":{className:"gdc",cssName:"grid-column",attrName:"grid-column"},"grid-row":{className:"gdr",cssName:"grid-row",attrName:"grid-row"}},ot=Object.keys(it);function ut(t,e){const s=function(t,e){const s=nt(e);return`bn-c-${t.className}_${s}`}(t,e),r=function(t,e,s){return`.${e} {${t.cssName}: ${s};}`}(t,s,e);return{className:s,style:r}}const ct=t=>{const e=new Map;return ot.forEach((s=>{const r=t.getAttribute(s);r&&(["top","left","right","bottom"].includes(s)&&e.set("position",ut(it.position,"absolute")),e.set(s,ut(it[s],(it[s].transform||function(t){return t})(r))))})),e},lt=new MutationObserver((t=>{for(const s of t){const t=s.target,r=ct(t);rt.apply(r);const n=Array.from(r.values()).map((t=>t.className));t.className=t.className.split(" ").filter((t=>!t.startsWith("bn-c-"))).concat(...n).join(" "),e(t)}})),ht=e=>{const s=e.connectedCallback,r=e.disconnectedCallback;e.connectedCallback=()=>{const r=t(e);if(!r)throw new Error("Can't find element field in component undefined");(t=>{const e=ct(t);rt.apply(e);const s=Array.from(e.values()).map((t=>t.className));t.className=t.className.split(" ").filter((t=>!t.startsWith("bn-c-"))).concat(...s).join(" "),lt.observe(t,{attributes:!0,attributeFilter:ot,childList:!1,subtree:!1})})(r),a(s,e)},e.disconnectedCallback=()=>{a(r,e)}};export{X as A,H as B,T as C,O as D,_ as E,z as F,C as G,A as H,W as a,p as b,et as c,q as d,B as e,$ as f,F as g,E as h,J as i,I as j,Y as k,tt as l,x as m,G as n,nt as o,M as p,L as q,V as r,Q as s,K as t,Z as u,j as v,ht as w,U as x,P as y,R as z}
1
+ import{g as t,f as e}from"./p-C5UYpZUU.js";import{g as r,c as s,D as n}from"./p-CURM2Nrr.js";import{r as a}from"./p-DtLI_CzV.js";import{m as i,S as o,b as u,A as c,c as l,T as h,D as d,d as m,M as f,e as y,r as b}from"./p-BEkgk7Ij.js";import{b as N,O as g}from"./p-DwGg2_vO.js";const v=n=>{let o,u,c,l;const h=()=>{const t=u.componentStyles.state;l=i([t._system||{},t._default||{},t[c]||{}],{arrayMergeType:"overwrite"})},d=new MutationObserver((r=>{r.forEach((r=>{"selected-style"===r.attributeName&&(c=t(n).getAttribute("selected-style"),h(),e(n))}))})),m=n.connectedCallback;n.connectedCallback=()=>{const s=t(n);u=r(s),l=u.componentStyles.state._system,d.observe(s,{attributes:!0,attributeFilter:["selected-style"]}),c=t(n).getAttribute("selected-style"),h(),o=u.componentStyles.on("set",(r=>{r===c&&(c=t(n).getAttribute("selected-style"),h(),e(t(n)))})),a(m,n)};const f=n.disconnectedCallback;return n.disconnectedCallback=()=>{d.disconnect(),a(o),s(t(n)),a(f,n)},t=>t(l)},p=/^\s*(set|first|last|min|max|avg|sum|lit)\(\s*(.*?)\s*\)\s*$/,S=/^[A-Za-z_][A-Za-z0-9_]*$/,k=["min","max","avg","sum"];class D{constructor(t,e,r,s){this.label=t,this.alias=e,this.fn=r,this.arg=s}get isNumeric(){return k.includes(this.fn)}}function w(t){if("string"!=typeof t)return!1;const e=p.exec(t);if(!e)return!1;const[,r,s]=e;return"lit"===r?s.length>0:S.test(s)}function O(t,e,r){if(!w(r))return null;const[,s,n]=p.exec(r);return new D(t,e,s,n)}var T,M;!function(t){t.YEAR="year",t.QUARTER="quarter",t.MONTH="month",t.WEEK="week",t.DAY="day",t.HOUR="hour",t.MINUTE="minute",t.SECOND="second",t.MILLISECOND="millisecond",t.NONE="fallback",t.AUTO="auto"}(T||(T={})),function(t){t.AVG="avg",t.INTERVAL="interval",t.START="start",t.END="end",t.YTD="ytd",t.YTG="ytg",t.CUM="cum",t.MAT="mat",t.NONE="none",t.AUTO="auto"}(M||(M={}));class A{constructor(){this._dateFormat={year:"yyyy",quarter:"q'Q' yyyy",month:"LLL yyyy",week:"'KW'WW yyyy",day:"dd.MM.yyyy",hour:"TT",minute:"TT",second:"TT",millisecond:"TT:SSS",fallback:"dd.MM.yyyy"},this._dateFormatShort={year:"yy",quarter:"q'Q'",month:"LLL",week:"'KW'WW",day:"dd",hour:"hh'h'",minute:"mm'm'",second:"ss's'",millisecond:"SSS'ms'",fallback:"dd.MM.yyyy"},this._dateLinkFormat={avg:"Ø[LINK]",interval:"[DATE]..[DATE2]",start:".[DATE]",end:"[DATE].",ytd:"_[DATE]",ytg:"[DATE]_",cum:"[DATE]_[DATE2]",mat:"~[DATE]",none:"[DATE]"},this.locale="de",this.dateFormatPinned=!1,this.dateFormatShortPinned=!1,this.dateFormat=this._dateFormat,this.dateLinkFormat=this._dateLinkFormat,this.dateFormatShort=this._dateFormatShort}setDateLinkFormat(t){this.dateLinkFormat=t}setDateFormat(t){this.dateFormat=t,this.dateFormatPinned=!0}setDateFormatShort(t){this.dateFormatShort=t,this.dateFormatShortPinned=!0}setLocale(t){this.locale=t,this.dateFormatPinned||(this.dateFormat=Object.assign(Object.assign({},this._dateFormat),A.LOCALE_DATE_FORMAT[t]||{})),this.dateFormatShortPinned||(this.dateFormatShort=Object.assign(Object.assign({},this._dateFormatShort),A.LOCALE_DATE_FORMAT_SHORT[t]||{}))}getDateString(t,e){return t.setLocale(this.locale).toFormat(this.dateFormat[e]||this.dateFormat.fallback)}getSmartDateString(t,e){switch(e){case T.DAY:return this.getFormatedDayDate(t);case T.MONTH:return this.getFormatedMonthDate(t);case T.QUARTER:return this.getFormatedQuarterDate(t);case T.WEEK:return this.getFormatedWeekDate(t);case T.HOUR:return this.getFormatedHourDate(t);case T.MINUTE:return this.getFormatedMinuteDate(t);case T.SECOND:return this.getFormatedSecondDate(t);case T.MILLISECOND:return this.getFormatedMilliSecondDate(t);default:return this.getDateString(t,e)}}calculateDistanceType(t,e,r=32){if(null==e)return T.DAY;const s="number"==typeof t?n.fromMillis(t):t,a="number"==typeof e?n.fromMillis(e):e;return 0===a.diff(s).as("milliseconds")?T.DAY:a.diff(s).as("milliseconds")<r?T.MILLISECOND:a.diff(s).as("seconds")<r?T.SECOND:a.diff(s).as("minutes")<r?T.MINUTE:a.diff(s).as("hours")<r?T.HOUR:a.diff(s).as("days")<r?T.DAY:a.diff(s).as("weeks")<r?T.WEEK:a.diff(s).as("months")<r?T.MONTH:a.diff(s).as("quarters")<r?T.QUARTER:T.YEAR}datesBetween(t,e,r,s){const n=this.convertDateDistanceToMomentunitOfTime(r),a=t.startOf(n),i=e.endOf(n);let o=i.diff(a).as(n);const u=[];o>=s&&(o=s);let c=a;do{u.push(c),c=c.plus(this.createDiratonLike(n,1))}while(c<=i&&u.length<o);return u}getDateLinkString(t,e,r,s,a){if(null==t&&null==e)return"";if(null==t&&r!==M.END&&r!==M.YTD)return"";if(null==e&&(M.INTERVAL===r||M.CUM===r||M.END===r||M.YTD===r))return"";const i=t||n.now(),o=e;s===T.AUTO&&(s=this.calculateDistanceType(i,o,a));let u=this.getDateString(i,s),c="",l=M.NONE;return null!=o&&(c=this.getDateString(o,s),l=M.INTERVAL,u===c&&r===M.INTERVAL&&(r=M.NONE),u===c&&r===M.AVG&&(l=M.NONE),M.END!==r&&M.YTD!==r||(u=c),(r===M.INTERVAL||r===M.CUM||M.AVG)&&(s===T.QUARTER?i.quarter===o.quarter&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,"")):s===T.MONTH?i.month===o.month&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,"")):s===T.WEEK&&(i.weekNumber===o.weekNumber&&i.year===o.year?c=c.replace(" "+o.year,""):i.year===o.year&&(u=u.replace(" "+i.year,""))))),this.dateLinkFormat[r].replace("[LINK]",this.dateLinkFormat[l]).replace("[DATE]",u).replace("[DATE2]",c)}getShortDateString(t,e){return t.setLocale(this.locale).toFormat(this.dateFormatShort[e]||this.dateFormatShort.fallback)}getFormatedDayDate(t){let e=this.dateFormatShort.day;return this.isFirstInMonth(t)&&(e+=" "+this.dateFormatShort.month),this.isJanuary(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedMonthDate(t){let e=this.dateFormatShort.month;return this.isJanuary(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedQuarterDate(t){let e=this.dateFormatShort.quarter;return this.isFirstQuarter(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedWeekDate(t){let e=this.dateFormatShort.week;return this.isFirstWeek(t)&&(e+=" "+this.dateFormatShort.year),t.setLocale(this.locale).toFormat(e)}getFormatedHourDate(t){let e=this.dateFormatShort.hour;return this.isFirstHour(t)&&(e+=" "+this.dateFormatShort.day),t.setLocale(this.locale).toFormat(e)}getFormatedMinuteDate(t){let e=this.dateFormatShort.minute;return this.isFirstMinute(t)&&(e=this.dateFormatShort.hour+":"+e),t.setLocale(this.locale).toFormat(e)}getFormatedSecondDate(t){let e=this.dateFormatShort.second;return this.isFirstSecond(t)&&(e=this.dateFormatShort.minute+":"+e),t.setLocale(this.locale).toFormat(e)}getFormatedMilliSecondDate(t){let e=this.dateFormatShort.millisecond;return this.isFirstMilliSecond(t)&&(e=this.dateFormatShort.second+":"+e),t.setLocale(this.locale).toFormat(e)}isFirstInMonth(t){return 1===t.day}isJanuary(t){return 1===t.month}isFirstQuarter(t){return 1===t.quarter}isFirstWeek(t){return 1===t.weekNumber}isFirstHour(t){return 0===t.hour}isFirstMinute(t){return 0===t.minute}isFirstSecond(t){return 0===t.second}isFirstMilliSecond(t){return 0===t.millisecond}convertDateDistanceToMomentunitOfTime(t){let e;switch(t){case T.YEAR:e="year";break;case T.MONTH:e="month";break;case T.QUARTER:e="quarter";break;case T.WEEK:e="week";break;case T.DAY:e="day";break;case T.HOUR:e="hour";break;case T.MINUTE:e="minute";break;case T.SECOND:e="second";break;case T.MILLISECOND:e="millisecond";break;default:e="day"}return e}createDiratonLike(t,e){switch(t){case"year":return{years:e};case"month":return{months:e};case"quarter":return{quarters:e};case"week":return{weeks:e};case"day":default:return{days:e};case"hour":return{hours:e};case"minute":return{minutes:e};case"second":return{seconds:e};case"millisecond":return{milliseconds:e}}}}function J(t){return null==t||""===t||"null"===t}function F(t){return J(t)||"auto"===t.trim().toLowerCase()?[]:E((null==t?void 0:t.split(",").filter((t=>!(t.toUpperCase().trim()in o)))).toString())}function E(t){return J(t)?[]:t.replace(";",",").split(",").filter((t=>{var e,r,s;const n=t.split("_"),a=null===(e=n[0])||void 0===e?void 0:e.replace(/^dr|^d/,"").toUpperCase().trim(),i=null===(r=n[1])||void 0===r?void 0:r.toUpperCase().trim(),c=null===(s=n[2])||void 0===s?void 0:s.toUpperCase().trim();return 3!==n.length||!(a in o)||!(i in o)||!(c in u)}))}function j(t){return J(t)?[]:E(t.split(",").filter((t=>!(t.toUpperCase().trim()in o))).toString())}function L(t){return J(t)||"auto"===t.trim().toLowerCase()?[]:E(t.split(",").filter((t=>!(t.toUpperCase()in N))).toString())}function W(t){return!J(t)&&Number.isInteger(Number(t))}function $(t){return!J(t)&&!Number.isNaN(Number(t))}function q(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in g}function I(t){return"auto"===(null==t?void 0:t.toLowerCase())||(null==t?void 0:t.toUpperCase())in c}function _(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("name")&&t.hasOwnProperty("unit"))))}catch(t){console.error("validateMeasureList: failed to parse JSON",t)}return["Invalid JSON structure"]}function z(t){const e=Date.parse(t);return Number.isInteger(e)}function C(t){return(null==t?void 0:t.toUpperCase())in M}function G(t){return(null==t?void 0:t.toUpperCase())in T}function x(t){return(null==t?void 0:t.toUpperCase())in l}function K(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in d}function Q(t){return!J(t)&&["true","false",!0,!1].some((e=>e===t))}function U(t){return!J(t)&&(null==t?void 0:t.toUpperCase())in m}function Z(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("rowGroup")&&t.hasOwnProperty("category")&&t.hasOwnProperty("subCategory"))))}catch(t){console.error("validateThereOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function B(t){if(J(t))return[];try{const e=JSON.parse(t);if(null!==e&&"object"==typeof e&&!(e instanceof Array))return Object.entries(e).filter((([,t])=>"string"!=typeof t||!w(t))).map((([t,e])=>`${t}: ${e}`))}catch(t){console.error("validateAttributesJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function H(t){if(J(t))return[];try{const e=JSON.parse(t);if(e instanceof Array)return e.filter((t=>!(t.hasOwnProperty("rowGroup")&&t.hasOwnProperty("category"))))}catch(t){console.error("validatePartOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function P(t){return(null==t?void 0:t.trim().toUpperCase())in f}function R(t){return["_","k","M","G","T","P","E","Z","Y","m","my","μ","n","p","f","a","z","y"].includes(null==t?void 0:t.trim())||["GREATEST","LEAST"].includes(null==t?void 0:t.trim().toUpperCase())}function Y(t){return(null==t?void 0:t.toUpperCase().trim())in y}function V(t){return(null==t?void 0:t.toUpperCase().trim())in h}function X(t){if(J(t))return[];try{return JSON.parse(t).filter((t=>!(t.hasOwnProperty("scenario")&&t.hasOwnProperty("name")&&t.hasOwnProperty("subGroups"))))}catch(t){console.error("validateColumnThereOfJsonStr: failed to parse JSON",t)}return["Invalid JSON structure"]}function tt(t){if(J(t))return[];try{const e=JSON.parse(t);if("object"!=typeof e||null===e||Array.isArray(e))return["stack: must be a JSON object"];const r=[];if(e.hasOwnProperty("by")){const t=["scenarios","dimensions"];t.includes(e.by)||r.push(`stack: 'by' must be one of: ${t.join(", ")}`)}else r.push("stack: 'by' is required");if(e.hasOwnProperty("mode")){const t=["absolute","relative","absolute-relative"];t.includes(e.mode)||r.push(`stack: 'mode' must be one of: ${t.join(", ")}`)}if(e.hasOwnProperty("order")){const t=["asc","desc","dataset"];t.includes(e.order)||r.push(`stack: 'order' must be one of: ${t.join(", ")}`)}return r}catch(t){return["stack: invalid JSON"]}}function et(t){return!J(t)&&null!==b(t)}A.LOCALE_DATE_FORMAT={en:{week:"'W'WW yyyy",day:"MM/dd/yyyy",fallback:"MM/dd/yyyy"}},A.LOCALE_DATE_FORMAT_SHORT={en:{week:"'W'WW",fallback:"MM/dd/yyyy"}};class rt{constructor(){this.cache=new Map,this.tag=rt.makeStyleTag()}static makeStyleTag(){const t=document.createElement("style");return t.type="text/css",t.setAttribute("data-bn-computed-style",""),t.append(document.createTextNode("")),(document.head||document.querySelector("head")).append(t),t}apply(t){t.forEach((t=>this.cache.set(t.className,t.style))),this.tag.innerHTML=Array.from(this.cache.values()).map((t=>t)).join("\n")}}const st=new rt;function nt(t){for(var e,r=0,s=0,n=t.length;n>=4;++s,n-=4)e=1540483477*(65535&(e=255&t.charCodeAt(s)|(255&t.charCodeAt(++s))<<8|(255&t.charCodeAt(++s))<<16|(255&t.charCodeAt(++s))<<24))+(59797*(e>>>16)<<16),r=1540483477*(65535&(e^=e>>>24))+(59797*(e>>>16)<<16)^1540483477*(65535&r)+(59797*(r>>>16)<<16);switch(n){case 3:r^=(255&t.charCodeAt(s+2))<<16;case 2:r^=(255&t.charCodeAt(s+1))<<8;case 1:r=1540483477*(65535&(r^=255&t.charCodeAt(s)))+(59797*(r>>>16)<<16)}return(((r=1540483477*(65535&(r^=r>>>13))+(59797*(r>>>16)<<16))^r>>>15)>>>0).toString(36)}const at=t=>$(t)?`${t}px`:t,it={width:{className:"w",cssName:"width",attrName:"width",transform:at},height:{className:"h",cssName:"height",attrName:"height",transform:at},position:{className:"pst",cssName:"position",attrName:"position"},top:{className:"top",cssName:"top",attrName:"top",transform:at},right:{className:"rgt",cssName:"right",attrName:"right",transform:at},bottom:{className:"btm",cssName:"bottom",attrName:"bottom",transform:at},left:{className:"lft",cssName:"left",attrName:"left",transform:at},"font-size":{className:"fts",cssName:"font-size",attrName:"font-size",transform:at},"grid-column":{className:"gdc",cssName:"grid-column",attrName:"grid-column"},"grid-row":{className:"gdr",cssName:"grid-row",attrName:"grid-row"}},ot=Object.keys(it);function ut(t,e){const r=function(t,e){const r=nt(e);return`bn-c-${t.className}_${r}`}(t,e),s=function(t,e,r){return`.${e} {${t.cssName}: ${r};}`}(t,r,e);return{className:r,style:s}}const ct=t=>{const e=new Map;return ot.forEach((r=>{const s=t.getAttribute(r);s&&(["top","left","right","bottom"].includes(r)&&e.set("position",ut(it.position,"absolute")),e.set(r,ut(it[r],(it[r].transform||function(t){return t})(s))))})),e},lt=new MutationObserver((t=>{for(const r of t){const t=r.target,s=ct(t);st.apply(s);const n=Array.from(s.values()).map((t=>t.className));t.className=t.className.split(" ").filter((t=>!t.startsWith("bn-c-"))).concat(...n).join(" "),e(t)}})),ht=e=>{const r=e.connectedCallback,s=e.disconnectedCallback;e.connectedCallback=()=>{const s=t(e);if(!s)throw new Error("Can't find element field in component undefined");(t=>{const e=ct(t);st.apply(e);const r=Array.from(e.values()).map((t=>t.className));t.className=t.className.split(" ").filter((t=>!t.startsWith("bn-c-"))).concat(...r).join(" "),lt.observe(t,{attributes:!0,attributeFilter:ot,childList:!1,subtree:!1})})(s),a(r,e)},e.disconnectedCallback=()=>{a(s,e)}};export{X as A,B,O as C,T as D,_ as E,z as F,C as G,M as H,W as a,v as b,et as c,q as d,Q as e,$ as f,F as g,E as h,J as i,I as j,R as k,tt as l,G as m,x as n,nt as o,A as p,j as q,V as r,K as s,U as t,Z as u,L as v,ht as w,H as x,P as y,Y as z}
@@ -1 +1 @@
1
- import{C as t}from"./p-BbmobTg0.js";class s{constructor(t,s,i){this.pos=t,this.neg=s,this.neu=i,this.needleHeadColour="#000000"}getSVGStyle(t){return"pos"===t?this.pos:"neg"===t?this.neg:this.neu}}class i{constructor(t){this.svgStyleAdapter=t}adapt(i){const h=new s(this.svgStyleAdapter.defaultPos(),this.svgStyleAdapter.defaultNeg(),this.svgStyleAdapter.defaultNeu());return t.isExisting(i.pos)&&(h.pos=this.svgStyleAdapter.adapt(i.pos)),t.isExisting(i.neg)&&(h.neg=this.svgStyleAdapter.adapt(i.neg)),t.isExisting(i.pp)&&(h.neu=this.svgStyleAdapter.adapt(i.neu)),t.isString(i.needleHeadColour)&&(h.needleHeadColour=i.needleHeadColour),h}default(){return new s(this.svgStyleAdapter.defaultPos(),this.svgStyleAdapter.defaultNeg(),this.svgStyleAdapter.defaultNeu())}}export{i as S}
1
+ import{C as t}from"./p-BEkgk7Ij.js";class s{constructor(t,s,i){this.pos=t,this.neg=s,this.neu=i,this.needleHeadColour="#000000"}getSVGStyle(t){return"pos"===t?this.pos:"neg"===t?this.neg:this.neu}}class i{constructor(t){this.svgStyleAdapter=t}adapt(i){const h=new s(this.svgStyleAdapter.defaultPos(),this.svgStyleAdapter.defaultNeg(),this.svgStyleAdapter.defaultNeu());return t.isExisting(i.pos)&&(h.pos=this.svgStyleAdapter.adapt(i.pos)),t.isExisting(i.neg)&&(h.neg=this.svgStyleAdapter.adapt(i.neg)),t.isExisting(i.pp)&&(h.neu=this.svgStyleAdapter.adapt(i.neu)),t.isString(i.needleHeadColour)&&(h.needleHeadColour=i.needleHeadColour),h}default(){return new s(this.svgStyleAdapter.defaultPos(),this.svgStyleAdapter.defaultNeg(),this.svgStyleAdapter.defaultNeu())}}export{i as S}
@@ -0,0 +1 @@
1
+ import{e as t,S as n}from"./p-CURM2Nrr.js";import{m as r,C as i}from"./p-BEkgk7Ij.js";class s{constructor(t){this.type="",this.base="",this.delta="",this.direction="",this.isValid=!1;const n=/(d|dr)(pl\d|ac\d|fc\d|pp\d)_(pl\d|ac\d|fc\d|pp\d)_(pos|neg|neu)/;if(n.test(t)){const r=n.exec(t);null!=r&&(this.type=String(r[1]),this.base=String(r[2]),this.delta=String(r[3]),this.direction=String(r[4]),this.isValid=!0)}}}var e;!function(t){t.OPERATION="operation",t.ROWGROUP="rowGroup",t.ROWGROUPINDEX="rowGroupIndex",t.CURRENTROW="currentRow",t.CATEGORY="category",t.CATEGORYINDEX="categoryIndex",t.SUBCATEGORY="subCategory",t.SUBCATEGORYINDEX="subCategoryIndex",t.COLUMNGROUP="columnGroup",t.COLUMNGROUPINDEX="columnIndex",t.COLUMNSUBGROUP="columnSubGroup",t.COLUMNSUBGROUPINDEX="columnSubGroupIndex",t.AC1="ac1",t.AC2="ac2",t.AC3="ac3",t.AC4="ac4",t.PP1="pp1",t.PP2="pp2",t.PP3="pp3",t.PP4="pp4",t.FC1="fc1",t.FC2="fc2",t.FC3="fc3",t.FC4="fc4",t.PL1="pl1",t.PL2="pl2",t.PL3="pl3",t.PL4="pl4",t.TOTALROWCOUNT="totalRowCnt",t.ROWNR="rowNr",t.TYPE="type"}(e||(e={}));var h,o={},u=function(){if(h)return o;h=1;var t={};return Object.defineProperty(o,"__esModule",{value:!0}),o.default=function(n,r){void 0===r&&(r={});var i=JSON.stringify({text:n,options:r});if(t[i])return t[i];r.font=r.font||"Times",r.fontSize=r.fontSize||"16px",r.fontWeight=r.fontWeight||"normal",r.width=r.width||"auto";var s=function(t,n){var r=document.createElement("div"),i=document.createTextNode(t);return r.appendChild(i),r.style.fontFamily=n.font,r.style.fontSize=n.fontSize,r.style.fontWeight=n.fontWeight,r.style.position="absolute",r.style.visibility="hidden",r.style.left="-999px",r.style.top="-999px",r.style.width=n.width,r.style.height="auto",document.body.appendChild(r),r}(n,r),e={width:s.offsetWidth,height:s.offsetHeight};return function(t){t.parentNode.removeChild(t)}(s),t[i]=e,e},o}(),c=t(u);class a{static number(t,n="decimal",r=1,i=0,s=1){return(t/s).toLocaleString("de-DE",{style:n,useGrouping:!0,maximumFractionDigits:r,minimumFractionDigits:i}).replace(/\s+(%)/g,"$1").replace(/\s/g,this.postfixSeperator).replace(/\./g,this.tsdDelimiter)}static translateScenarioLabel(t,n){if(null==t)return"";const r=new s(t);if(!r.isValid)return`${n.get(t)||t}`;let i,h;return e.AC1===r.base?(i=n.get("dr"===r.type?"ibcssymbol_delta_ac_relative":"ibcssymbol_delta_ac"),h=n.get(r.delta)||r.delta):(i=n.get("dr"===r.type?"ibcssymbol_delta_generic_relative":"ibcssymbol_delta_generic"),h=`${n.get(r.base)||r.base} - ${n.get(r.delta)||r.delta}`),void 0===i&&(i="{%}"),`${i.replace("{%}",h)}`}static getMaxWidthOfArrayItems(t,n,r){return c(t.map((t=>a.translateScenarioLabel(t,n))).reduce(((t,n)=>t.length<n.length?n:t),""),{font:r.fontStyles.font,fontSize:r.fontStyles.size+"px"}).width}}a.tsdDelimiter=".",a.postfixSeperator=",";var l=Object.create,f=Object.defineProperty,p=Object.getOwnPropertyDescriptor,d=Object.getOwnPropertyNames,w=Object.getPrototypeOf,y=Object.prototype.hasOwnProperty,m=(t,n)=>()=>(n||(t((n={exports:{}}).exports,n),t=null),n.exports),v=t=>{let n={};for(var r in t)f(n,r,{get:t[r],enumerable:!0});return f(n,Symbol.toStringTag,{value:"Module"}),n},b=(t,n,r)=>(r=null!=t?l(w(t)):{},((t,n,r,i)=>{if(n&&"object"==typeof n||"function"==typeof n)for(var s,e=d(n),h=0,o=e.length;h<o;h++)y.call(t,s=e[h])||undefined===s||f(t,s,{get:(t=>n[t]).bind(null,s),enumerable:!(i=p(n,s))||i.enumerable});return t})(f(r,"default",{value:t,enumerable:!0}),t));const g={},x=[];function M(t,n){if(Array.isArray(t))for(const r of t)M(r,n);else if("object"!=typeof t)j(Object.getOwnPropertyNames(n)),g[t]=Object.assign(g[t]||{},n);else for(const n in t)M(n,t[n])}function _(t){return g[t]||{}}function j(t){x.push(...t)}var S=m(((t,n)=>{n.exports=function(t){try{return!!t()}catch(t){return!0}}})),A=m(((t,n)=>{var r=S();n.exports=!r((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))})),O=m(((t,n)=>{var r=A(),i=Function.prototype,s=i.call,e=r&&i.bind.bind(s,s);n.exports=r?e:function(t){return function(){return s.apply(t,arguments)}}})),k=m(((t,n)=>{var r=O();n.exports=r({}.isPrototypeOf)})),E=m(((t,n)=>{var r=function(t){return t&&t.Math===Math&&t};n.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof global&&global)||r("object"==typeof t&&t)||function(){return this}()||Function("return this")()})),T=m(((t,n)=>{var r=A(),i=Function.prototype,s=i.apply,e=i.call;n.exports="object"==typeof Reflect&&Reflect.apply||(r?e.bind(s):function(){return e.apply(s,arguments)})})),C=m(((t,n)=>{var r=O(),i=r({}.toString),s=r("".slice);n.exports=function(t){return s(i(t),8,-1)}})),D=m(((t,n)=>{var r=C(),i=O();n.exports=function(t){if("Function"===r(t))return i(t)}})),z=m(((t,n)=>{var r="object"==typeof document&&document.all;n.exports=void 0===r&&void 0!==r?function(t){return"function"==typeof t||t===r}:function(t){return"function"==typeof t}})),F=m(((t,n)=>{var r=S();n.exports=!r((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))})),N=m(((t,n)=>{var r=A(),i=Function.prototype.call;n.exports=r?i.bind(i):function(){return i.apply(i,arguments)}})),Y=m((t=>{var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,i=r&&!n.call({1:2},1);t.f=i?function(t){var n=r(this,t);return!!n&&n.enumerable}:n})),P=m(((t,n)=>{n.exports=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}}})),I=m(((t,n)=>{var r=O(),i=S(),s=C(),e=Object,h=r("".split);n.exports=i((function(){return!e("z").propertyIsEnumerable(0)}))?function(t){return"String"===s(t)?h(t,""):e(t)}:e})),$=m(((t,n)=>{n.exports=function(t){return null==t}})),R=m(((t,n)=>{var r=$(),i=TypeError;n.exports=function(t){if(r(t))throw new i("Can't call method on "+t);return t}})),G=m(((t,n)=>{var r=I(),i=R();n.exports=function(t){return r(i(t))}})),L=m(((t,n)=>{var r=z();n.exports=function(t){return"object"==typeof t?null!==t:r(t)}})),X=m(((t,n)=>{n.exports={}})),H=m(((t,n)=>{var r=X(),i=E(),s=z(),e=function(t){return s(t)?t:void 0};n.exports=function(t,n){return arguments.length<2?e(r[t])||e(i[t]):r[t]&&r[t][n]||i[t]&&i[t][n]}})),Q=m(((t,n)=>{var r=E().navigator,i=r&&r.userAgent;n.exports=i?String(i):""})),V=m(((t,n)=>{var r,i,s=E(),e=Q(),h=s.process,o=s.Deno,u=h&&h.versions||o&&o.version,c=u&&u.v8;c&&(i=(r=c.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!i&&e&&(!(r=e.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=e.match(/Chrome\/(\d+)/))&&(i=+r[1]),n.exports=i})),B=m(((t,n)=>{var r=V(),i=S(),s=E().String;n.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol("symbol detection");return!s(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&r&&r<41}))})),W=m(((t,n)=>{var r=B();n.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator})),J=m(((t,n)=>{var r=H(),i=z(),s=k(),e=W(),h=Object;n.exports=e?function(t){return"symbol"==typeof t}:function(t){var n=r("Symbol");return i(n)&&s(n.prototype,h(t))}})),q=m(((t,n)=>{var r=String;n.exports=function(t){try{return r(t)}catch(t){return"Object"}}})),U=m(((t,n)=>{var r=z(),i=q(),s=TypeError;n.exports=function(t){if(r(t))return t;throw new s(i(t)+" is not a function")}})),Z=m(((t,n)=>{var r=U(),i=$();n.exports=function(t,n){var s=t[n];return i(s)?void 0:r(s)}})),K=m(((t,n)=>{var r=N(),i=z(),s=L(),e=TypeError;n.exports=function(t,n){var h,o;if("string"===n&&i(h=t.toString)&&!s(o=r(h,t)))return o;if(i(h=t.valueOf)&&!s(o=r(h,t)))return o;if("string"!==n&&i(h=t.toString)&&!s(o=r(h,t)))return o;throw new e("Can't convert object to primitive value")}})),tt=m(((t,n)=>{n.exports=!0})),nt=m(((t,n)=>{var r=E(),i=Object.defineProperty;n.exports=function(t,n){try{i(r,t,{value:n,configurable:!0,writable:!0})}catch(i){r[t]=n}return n}})),rt=m(((t,n)=>{var r=tt(),i=E(),s=nt(),e="__core-js_shared__",h=n.exports=i[e]||s(e,{});(h.versions||(h.versions=[])).push({version:"3.49.0",mode:r?"pure":"global",copyright:"© 2013–2025 Denis Pushkarev (zloirock.ru), 2025–2026 CoreJS Company (core-js.io). All rights reserved.",license:"https://github.com/zloirock/core-js/blob/v3.49.0/LICENSE",source:"https://github.com/zloirock/core-js"})})),it=m(((t,n)=>{var r=rt();n.exports=function(t,n){return r[t]||(r[t]=n||{})}})),st=m(((t,n)=>{var r=R(),i=Object;n.exports=function(t){return i(r(t))}})),et=m(((t,n)=>{var r=O(),i=st(),s=r({}.hasOwnProperty);n.exports=Object.hasOwn||function(t,n){return s(i(t),n)}})),ht=m(((t,n)=>{var r=O(),i=0,s=Math.random(),e=r(1.1.toString);n.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+e(++i+s,36)}})),ot=m(((t,n)=>{var r=E(),i=it(),s=et(),e=ht(),h=B(),o=W(),u=r.Symbol,c=i("wks"),a=o?u.for||u:u&&u.withoutSetter||e;n.exports=function(t){return s(c,t)||(c[t]=h&&s(u,t)?u[t]:a("Symbol."+t)),c[t]}})),ut=m(((t,n)=>{var r=N(),i=L(),s=J(),e=Z(),h=K(),o=ot(),u=TypeError,c=o("toPrimitive");n.exports=function(t,n){if(!i(t)||s(t))return t;var o,a=e(t,c);if(a){if(void 0===n&&(n="default"),o=r(a,t,n),!i(o)||s(o))return o;throw new u("Can't convert object to primitive value")}return void 0===n&&(n="number"),h(t,n)}})),ct=m(((t,n)=>{var r=ut(),i=J();n.exports=function(t){var n=r(t,"string");return i(n)?n:n+""}})),at=m(((t,n)=>{var r=E(),i=L(),s=r.document,e=i(s)&&i(s.createElement);n.exports=function(t){return e?s.createElement(t):{}}})),lt=m(((t,n)=>{var r=F(),i=S(),s=at();n.exports=!r&&!i((function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a}))})),ft=m((t=>{var n=F(),r=N(),i=Y(),s=P(),e=G(),h=ct(),o=et(),u=lt(),c=Object.getOwnPropertyDescriptor;t.f=n?c:function(t,n){if(t=e(t),n=h(n),u)try{return c(t,n)}catch(t){}if(o(t,n))return s(!r(i.f,t,n),t[n])}})),pt=m(((t,n)=>{var r=S(),i=z(),s=/#|\.prototype\./,e=function(t,n){var s=o[h(t)];return s===c||s!==u&&(i(n)?r(n):!!n)},h=e.normalize=function(t){return String(t).replace(s,".").toLowerCase()},o=e.data={},u=e.NATIVE="N",c=e.POLYFILL="P";n.exports=e})),dt=m(((t,n)=>{var r=D(),i=U(),s=A(),e=r(r.bind);n.exports=function(t,n){return i(t),void 0===n?t:s?e(t,n):function(){return t.apply(n,arguments)}}})),wt=m(((t,n)=>{var r=F(),i=S();n.exports=r&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))})),yt=m(((t,n)=>{var r=L(),i=String,s=TypeError;n.exports=function(t){if(r(t))return t;throw new s(i(t)+" is not an object")}})),mt=m((t=>{var n=F(),r=lt(),i=wt(),s=yt(),e=ct(),h=TypeError,o=Object.defineProperty,u=Object.getOwnPropertyDescriptor,c="enumerable",a="configurable",l="writable";t.f=n?i?function(t,n,r){if(s(t),n=e(n),s(r),"function"==typeof t&&"prototype"===n&&"value"in r&&l in r&&!r[l]){var i=u(t,n);i&&i[l]&&(t[n]=r.value,r={configurable:a in r?r[a]:i[a],enumerable:c in r?r[c]:i[c],writable:!1})}return o(t,n,r)}:o:function(t,n,i){if(s(t),n=e(n),s(i),r)try{return o(t,n,i)}catch(t){}if("get"in i||"set"in i)throw new h("Accessors not supported");return"value"in i&&(t[n]=i.value),t}})),vt=m(((t,n)=>{var r=F(),i=mt(),s=P();n.exports=r?function(t,n,r){return i.f(t,n,s(1,r))}:function(t,n,r){return t[n]=r,t}})),bt=m(((t,n)=>{var r=E(),i=T(),s=D(),e=z(),h=ft().f,o=pt(),u=X(),c=dt(),a=vt(),l=et();rt();var f=function(t){var n=function(r,s,e){if(this instanceof n){switch(arguments.length){case 0:return new t;case 1:return new t(r);case 2:return new t(r,s)}return new t(r,s,e)}return i(t,this,arguments)};return n.prototype=t.prototype,n};n.exports=function(t,n){var i,p,d,w,y,m,v,b,g,x=t.target,M=t.global,_=t.stat,j=t.proto,S=M?r:_?r[x]:r[x]&&r[x].prototype,A=M?u:u[x]||a(u,x,{})[x],O=A.prototype;for(w in n)p=!(i=o(M?w:x+(_?".":"#")+w,t.forced))&&S&&l(S,w),m=A[w],p&&(v=t.dontCallGetSet?(g=h(S,w))&&g.value:S[w]),y=p&&v?v:n[w],(i||j||typeof m!=typeof y)&&(b=t.bind&&p?c(y,r):t.wrap&&p?f(y):j&&e(y)?s(y):y,(t.sham||y&&y.sham||m&&m.sham)&&a(b,"sham",!0),a(A,w,b),j&&(l(u,d=x+"Prototype")||a(u,d,{}),a(u[d],w,y),t.real&&O&&(i||!O[w])&&a(O,w,y)))}})),gt=m(((t,n)=>{var r=Math.ceil,i=Math.floor;n.exports=Math.trunc||function(t){var n=+t;return(n>0?i:r)(n)}})),xt=m(((t,n)=>{var r=gt();n.exports=function(t){var n=+t;return n!=n||0===n?0:r(n)}})),Mt=m(((t,n)=>{var r=xt(),i=Math.max,s=Math.min;n.exports=function(t,n){var e=r(t);return e<0?i(e+n,0):s(e,n)}})),_t=m(((t,n)=>{var r=xt(),i=Math.min;n.exports=function(t){var n=r(t);return n>0?i(n,9007199254740991):0}})),jt=m(((t,n)=>{var r=_t();n.exports=function(t){return r(t.length)}})),St=m(((t,n)=>{var r=G(),i=Mt(),s=jt(),e=function(t){return function(n,e,h){var o=r(n),u=s(o);if(0===u)return!t&&-1;var c,a=i(h,u);if(t&&e!=e){for(;u>a;)if((c=o[a++])!=c)return!0}else for(;u>a;a++)if((t||a in o)&&o[a]===e)return t||a||0;return!t&&-1}};n.exports={includes:e(!0),indexOf:e(!1)}})),At=m(((t,n)=>{n.exports=function(){}})),Ot=m((()=>{var t=bt(),n=St().includes,r=S(),i=At(),s=r((function(){return!Array(1).includes()})),e=r((function(){return[,1].includes(void 0,1)}));t({target:"Array",proto:!0,forced:s||e},{includes:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}}),i("includes")})),kt=m(((t,n)=>{var r=E(),i=X();n.exports=function(t,n){var s=i[t+"Prototype"],e=s&&s[n];if(e)return e;var h=r[t],o=h&&h.prototype;return o&&o[n]}})),Et=m(((t,n)=>{Ot();var r=kt();n.exports=r("Array","includes")})),Tt=m(((t,n)=>{var r=L(),i=C(),s=ot()("match");n.exports=function(t){var n;return r(t)&&(void 0!==(n=t[s])?!!n:"RegExp"===i(t))}})),Ct=m(((t,n)=>{var r=Tt(),i=TypeError;n.exports=function(t){if(r(t))throw new i("The method doesn't accept regular expressions");return t}})),Dt=m(((t,n)=>{var r={};r[ot()("toStringTag")]="z",n.exports="[object z]"===String(r)})),zt=m(((t,n)=>{var r=Dt(),i=z(),s=C(),e=ot()("toStringTag"),h=Object,o="Arguments"===s(function(){return arguments}());n.exports=r?s:function(t){var n,r,u;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(r=function(t,n){try{return t[n]}catch(t){}}(n=h(t),e))?r:o?s(n):"Object"===(u=s(n))&&i(n.callee)?"Arguments":u}})),Ft=m(((t,n)=>{var r=zt(),i=String;n.exports=function(t){if("Symbol"===r(t))throw new TypeError("Cannot convert a Symbol value to a string");return i(t)}})),Nt=m(((t,n)=>{var r=ot()("match");n.exports=function(t){var n=/./;try{"/./"[t](n)}catch(i){try{return n[r]=!1,"/./"[t](n)}catch(t){}}return!1}})),Yt=m((()=>{var t=bt(),n=O(),r=Ct(),i=R(),s=Ft(),e=Nt(),h=n("".indexOf);t({target:"String",proto:!0,forced:!e("includes")},{includes:function(t){return!!~h(s(i(this)),s(r(t)),arguments.length>1?arguments[1]:void 0)}})})),Pt=m(((t,n)=>{Yt();var r=kt();n.exports=r("String","includes")})),It=m(((t,n)=>{var r=k(),i=Et(),s=Pt(),e=Array.prototype,h=String.prototype;n.exports=function(t){var n=t.includes;return t===e||r(e,t)&&n===e.includes?i:"string"==typeof t||t===h||r(h,t)&&n===h.includes?s:n}})),$t=b(m(((t,n)=>{var r=It();n.exports=r}))());function Rt(t,n){let r;const i=t.length,s=[];for(r=0;r<i;r++)s.push(n(t[r]));return s}function Gt(t){return t%360*Math.PI/180}function Lt(t){return t.replace(/([A-Z])/g,(function(t,n){return"-"+n.toLowerCase()}))}function Xt(t){return t.charAt(0).toUpperCase()+t.slice(1)}function Ht(t,n,r,i){return null!=n&&null!=r||(i=i||t.bbox(),null==n?n=i.width/i.height*r:null==r&&(r=i.height/i.width*n)),{width:n,height:r}}function Qt(t,n){const r=t.origin;let i=null!=t.ox?t.ox:null!=t.originX?t.originX:"center",s=null!=t.oy?t.oy:null!=t.originY?t.originY:"center";null!=r&&([i,s]=Array.isArray(r)?r:"object"==typeof r?[r.x,r.y]:[r,r]);const e="string"==typeof i,h="string"==typeof s;if(e||h){const{height:t,width:r,x:o,y:u}=n.bbox();e&&(i=(0,$t.default)(i).call(i,"left")?o:(0,$t.default)(i).call(i,"right")?o+r:o+r/2),h&&(s=(0,$t.default)(s).call(s,"top")?u:(0,$t.default)(s).call(s,"bottom")?u+t:u+t/2)}return[i,s]}const Vt=new Set(["desc","metadata","title"]),Bt=t=>Vt.has(t.nodeName),Wt="http://www.w3.org/2000/svg",Jt="http://www.w3.org/2000/xmlns/",qt="http://www.w3.org/1999/xlink",Ut={window:"undefined"==typeof window?null:window,document:"undefined"==typeof document?null:document};var Zt=class{};const Kt={},tn="___SYMBOL___ROOT___";function nn(t,n=Wt){return Ut.document.createElementNS(n,t)}function rn(t,n=!1){if(t instanceof Zt)return t;if("object"==typeof t)return hn(t);if(null==t)return new Kt[tn];if("string"==typeof t&&"<"!==t.trim().charAt(0))return hn(Ut.document.querySelector(t));const r=n?Ut.document.createElement("div"):nn("svg");return r.innerHTML=t.trim(),t=hn(r.firstElementChild),r.removeChild(r.firstElementChild),t}function sn(t,n){return n&&(n instanceof Ut.window.Node||n.ownerDocument&&n instanceof n.ownerDocument.defaultView.Node)?n:nn(t)}function en(t){if(!t)return null;if(t.instance instanceof Zt)return t.instance;if("#document-fragment"===t.nodeName)return new Kt.Fragment(t);let n=Xt(t.nodeName||"Dom");return"LinearGradient"===n||"RadialGradient"===n?n="Gradient":Kt[n]||(n="Dom"),new Kt[n](t)}let hn=en;function on(t,n=t.name,r=!1){return Kt[n]=t,r&&(Kt[tn]=t),j(Object.getOwnPropertyNames(t.prototype)),t}let un=1e3;function cn(t){return"Svgjs"+Xt(t)+un++}function an(t){for(let n=t.children.length-1;n>=0;n--)an(t.children[n]);return t.id?(t.id=cn(t.nodeName),t):t}function ln(t,n){let r,i;for(i=(t=Array.isArray(t)?t:[t]).length-1;i>=0;i--)for(r in n)t[i].prototype[r]=n[r]}function fn(t){return function(...n){const r=n[n.length-1];return!r||r.constructor!==Object||r instanceof Array?t.apply(this,n):t.apply(this,n.slice(0,-1)).attr(r)}}M("Dom",{siblings:function(){return this.parent().children()},position:function(){return this.parent().index(this)},next:function(){return this.siblings()[this.position()+1]},prev:function(){return this.siblings()[this.position()-1]},forward:function(){const t=this.position();return this.parent().add(this.remove(),t+1),this},backward:function(){const t=this.position();return this.parent().add(this.remove(),t?t-1:0),this},front:function(){return this.parent().add(this.remove()),this},back:function(){return this.parent().add(this.remove(),0),this},before:function(t){(t=rn(t)).remove();const n=this.position();return this.parent().add(t,n),this},after:function(t){(t=rn(t)).remove();const n=this.position();return this.parent().add(t,n+1),this},insertBefore:function(t){return(t=rn(t)).before(this),this},insertAfter:function(t){return(t=rn(t)).after(this),this}});const pn=/^([+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?)([a-z%]*)$/i,dn=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,wn=/rgb\((\d+),(\d+),(\d+)\)/,yn=/^(#[^\s]+)$/,mn=/\)\s*,?\s*/,vn=/\s/g,bn=/^#[a-f0-9]{3}$|^#[a-f0-9]{6}$/i,gn=/^rgb\(/,xn=/^(\s+)?$/,Mn=/^[+-]?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,_n=/\.(jpg|jpeg|png|gif|svg)(\?[^=]+.*)?/i,jn=/[\s,]+/,Sn=/[MLHVCSQTAZ]/i;M("Dom",{classes:function(){const t=this.attr("class");return null==t?[]:t.trim().split(jn)},hasClass:function(t){return-1!==this.classes().indexOf(t)},addClass:function(t){if(!this.hasClass(t)){const n=this.classes();n.push(t),this.attr("class",n.join(" "))}return this},removeClass:function(t){return this.hasClass(t)&&this.attr("class",this.classes().filter((function(n){return n!==t})).join(" ")),this},toggleClass:function(t){return this.hasClass(t)?this.removeClass(t):this.addClass(t)}});const An=t=>t.startsWith("--")?t:Lt(t);function On(t){const n=Math.max(0,Math.min(255,Math.round(t))).toString(16);return 1===n.length?"0"+n:n}function kn(t,n){for(let r=n.length;r--;)if(null==t[n[r]])return!1;return!0}function En(t,n,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?t+6*(n-t)*r:r<.5?n:r<2/3?t+(n-t)*(2/3-r)*6:t}M("Dom",{css:function(t,n){const r={};if(0===arguments.length){const t=this.node.style;for(let n=0;n<t.length;n++){const i=t.item(n),s=t.getPropertyValue(i),e=t.getPropertyPriority(i);r[i]=e?`${s} !${e}`:s}return r}if(arguments.length<2){if(Array.isArray(t)){for(const n of t){const t=An(n);r[n]=this.node.style.getPropertyValue(t)}return r}if("string"==typeof t)return this.node.style.getPropertyValue(An(t));if("object"==typeof t)for(const n in t)this.node.style.setProperty(An(n),null==t[n]||xn.test(t[n])?"":t[n])}return 2===arguments.length&&this.node.style.setProperty(An(t),null==n||xn.test(n)?"":n),this},show:function(){return this.css("display","")},hide:function(){return this.css("display","none")},visible:function(){return"none"!==this.css("display")}}),M("Dom",{data:function(t,n,r){if(null==t)return this.data(Rt(function(t){let n;const r=t.length,i=[];for(n=0;n<r;n++)0===t[n].nodeName.indexOf("data-")&&i.push(t[n]);return i}(this.node.attributes),(t=>t.nodeName.slice(5))));if(t instanceof Array){const n={};for(const r of t)n[r]=this.data(r);return n}if("object"==typeof t)for(n in t)this.data(n,t[n]);else if(arguments.length<2)try{return JSON.parse(this.attr("data-"+t))}catch(n){return this.attr("data-"+t)}else this.attr("data-"+t,null===n?null:!0===r||"string"==typeof n||"number"==typeof n?n:JSON.stringify(n));return this}}),M("Dom",{remember:function(t,n){if("object"==typeof arguments[0])for(const n in t)this.remember(n,t[n]);else{if(1===arguments.length)return this.memory()[t];this.memory()[t]=n}return this},forget:function(){if(0===arguments.length)this._memory={};else for(let t=arguments.length-1;t>=0;t--)delete this.memory()[arguments[t]];return this},memory:function(){return this._memory=this._memory||{}}});var Tn=class t{constructor(...t){this.init(...t)}static isColor(n){return n&&(n instanceof t||this.isRgb(n)||this.test(n))}static isRgb(t){return t&&"number"==typeof t.r&&"number"==typeof t.g&&"number"==typeof t.b}static random(n="vibrant",r){const{random:i,round:s,sin:e,PI:h}=Math;if("vibrant"===n){const n=24*i()+57,r=38*i()+45,s=360*i();return new t(n,r,s,"lch")}if("sine"===n){const n=s(80*e(2*h*(r=null==r?i():r)/.5+.01)+150),o=s(50*e(2*h*r/.5+4.6)+200),u=s(100*e(2*h*r/.5+2.3)+150);return new t(n,o,u)}if("pastel"===n){const n=8*i()+86,r=17*i()+9,s=360*i();return new t(n,r,s,"lch")}if("dark"===n){const n=10+10*i(),r=50*i()+86,s=360*i();return new t(n,r,s,"lch")}if("rgb"===n){const n=255*i(),r=255*i(),s=255*i();return new t(n,r,s)}if("lab"===n){const n=100*i(),r=256*i()-128,s=256*i()-128;return new t(n,r,s,"lab")}if("grey"===n){const n=255*i();return new t(n,n,n)}throw new Error("Unsupported random color mode")}static test(t){return"string"==typeof t&&(bn.test(t)||gn.test(t))}cmyk(){const{_a:n,_b:r,_c:i}=this.rgb(),[s,e,h]=[n,r,i].map((t=>t/255)),o=Math.min(1-s,1-e,1-h);return 1===o?new t(0,0,0,1,"cmyk"):new t((1-s-o)/(1-o),(1-e-o)/(1-o),(1-h-o)/(1-o),o,"cmyk")}hsl(){const{_a:n,_b:r,_c:i}=this.rgb(),[s,e,h]=[n,r,i].map((t=>t/255)),o=Math.max(s,e,h),u=Math.min(s,e,h),c=(o+u)/2,a=o===u,l=o-u;return new t(360*(a?0:o===s?((e-h)/l+(e<h?6:0))/6:o===e?((h-s)/l+2)/6:o===h?((s-e)/l+4)/6:0),100*(a?0:c>.5?l/(2-o-u):l/(o+u)),100*c,"hsl")}init(t=0,n=0,r=0,i=0,s="rgb"){if(t=t||0,this.space)for(const t in this.space)delete this[this.space[t]];if("number"==typeof t)s="string"==typeof i?i:s,i="string"==typeof i?0:i,Object.assign(this,{_a:t,_b:n,_c:r,_d:i,space:s});else if(t instanceof Array)this.space=n||("string"==typeof t[3]?t[3]:t[4])||"rgb",Object.assign(this,{_a:t[0],_b:t[1],_c:t[2],_d:t[3]||0});else if(t instanceof Object){const r=function(t,n){const r=kn(t,"rgb")?{_a:t.r,_b:t.g,_c:t.b,_d:0,space:"rgb"}:kn(t,"xyz")?{_a:t.x,_b:t.y,_c:t.z,_d:0,space:"xyz"}:kn(t,"hsl")?{_a:t.h,_b:t.s,_c:t.l,_d:0,space:"hsl"}:kn(t,"lab")?{_a:t.l,_b:t.a,_c:t.b,_d:0,space:"lab"}:kn(t,"lch")?{_a:t.l,_b:t.c,_c:t.h,_d:0,space:"lch"}:kn(t,"cmyk")?{_a:t.c,_b:t.m,_c:t.y,_d:t.k,space:"cmyk"}:{_a:0,_b:0,_c:0,space:"rgb"};return r.space=n||r.space,r}(t,n);Object.assign(this,r)}else if("string"==typeof t)if(gn.test(t)){const n=t.replace(vn,""),[r,i,s]=wn.exec(n).slice(1,4).map((t=>parseInt(t)));Object.assign(this,{_a:r,_b:i,_c:s,_d:0,space:"rgb"})}else{if(!bn.test(t))throw Error("Unsupported string format, can't construct Color");{const n=t=>parseInt(t,16),[,r,i,s]=dn.exec(function(t){return 4===t.length?["#",t.substring(1,2),t.substring(1,2),t.substring(2,3),t.substring(2,3),t.substring(3,4),t.substring(3,4)].join(""):t}(t)).map(n);Object.assign(this,{_a:r,_b:i,_c:s,_d:0,space:"rgb"})}}const{_a:e,_b:h,_c:o,_d:u}=this;Object.assign(this,"rgb"===this.space?{r:e,g:h,b:o}:"xyz"===this.space?{x:e,y:h,z:o}:"hsl"===this.space?{h:e,s:h,l:o}:"lab"===this.space?{l:e,a:h,b:o}:"lch"===this.space?{l:e,c:h,h:o}:"cmyk"===this.space?{c:e,m:h,y:o,k:u}:{})}lab(){const{x:n,y:r,z:i}=this.xyz();return new t(116*r-16,500*(n-r),200*(r-i),"lab")}lch(){const{l:n,a:r,b:i}=this.lab(),s=Math.sqrt(r**2+i**2);let e=180*Math.atan2(i,r)/Math.PI;return e<0&&(e*=-1,e=360-e),new t(n,s,e,"lch")}rgb(){if("rgb"===this.space)return this;if("lab"===(n=this.space)||"xyz"===n||"lch"===n){let{x:n,y:r,z:i}=this;if("lab"===this.space||"lch"===this.space){let{l:t,a:s,b:e}=this;if("lch"===this.space){const{c:t,h:n}=this,r=Math.PI/180;s=t*Math.cos(r*n),e=t*Math.sin(r*n)}const h=(t+16)/116,o=s/500+h,u=h-e/200,c=16/116,a=.008856,l=7.787;n=.95047*(o**3>a?o**3:(o-c)/l),r=1*(h**3>a?h**3:(h-c)/l),i=1.08883*(u**3>a?u**3:(u-c)/l)}const s=3.2406*n+-1.5372*r+-.4986*i,e=-.9689*n+1.8758*r+.0415*i,h=.0557*n+-.204*r+1.057*i,o=Math.pow,u=.0031308,c=s>u?1.055*o(s,1/2.4)-.055:12.92*s,a=e>u?1.055*o(e,1/2.4)-.055:12.92*e,l=h>u?1.055*o(h,1/2.4)-.055:12.92*h;return new t(255*c,255*a,255*l)}if("hsl"===this.space){let{h:n,s:r,l:i}=this;if(n/=360,r/=100,i/=100,0===r)return i*=255,new t(i,i,i);const s=i<.5?i*(1+r):i+r-i*r,e=2*i-s,h=255*En(e,s,n+1/3),o=255*En(e,s,n),u=255*En(e,s,n-1/3);return new t(h,o,u)}if("cmyk"===this.space){const{c:n,m:r,y:i,k:s}=this,e=255*(1-Math.min(1,n*(1-s)+s)),h=255*(1-Math.min(1,r*(1-s)+s)),o=255*(1-Math.min(1,i*(1-s)+s));return new t(e,h,o)}return this;var n}toArray(){const{_a:t,_b:n,_c:r,_d:i,space:s}=this;return[t,n,r,i,s]}toHex(){const[t,n,r]=this._clamped().map(On);return`#${t}${n}${r}`}toRgb(){const[t,n,r]=this._clamped();return`rgb(${t},${n},${r})`}toString(){return this.toHex()}xyz(){const{_a:n,_b:r,_c:i}=this.rgb(),[s,e,h]=[n,r,i].map((t=>t/255)),o=s>.04045?Math.pow((s+.055)/1.055,2.4):s/12.92,u=e>.04045?Math.pow((e+.055)/1.055,2.4):e/12.92,c=h>.04045?Math.pow((h+.055)/1.055,2.4):h/12.92,a=(.4124*o+.3576*u+.1805*c)/.95047,l=(.2126*o+.7152*u+.0722*c)/1,f=(.0193*o+.1192*u+.9505*c)/1.08883,p=a>.008856?Math.pow(a,1/3):7.787*a+16/116,d=l>.008856?Math.pow(l,1/3):7.787*l+16/116,w=f>.008856?Math.pow(f,1/3):7.787*f+16/116;return new t(p,d,w,"xyz")}_clamped(){const{_a:t,_b:n,_c:r}=this.rgb(),{max:i,min:s,round:e}=Math;return[t,n,r].map((t=>i(0,s(e(t),255))))}},Cn=class t{constructor(...t){this.init(...t)}clone(){return new t(this)}init(t,n){const r=Array.isArray(t)?{x:t[0],y:t[1]}:"object"==typeof t?{x:t.x,y:t.y}:{x:t,y:n};return this.x=null==r.x?0:r.x,this.y=null==r.y?0:r.y,this}toArray(){return[this.x,this.y]}transform(t){return this.clone().transformO(t)}transformO(t){zn.isMatrixLike(t)||(t=new zn(t));const{x:n,y:r}=this;return this.x=t.a*n+t.c*r+t.e,this.y=t.b*n+t.d*r+t.f,this}};function Dn(t,n){return Math.abs(n-t)<1e-6}var zn=class t{constructor(...t){this.init(...t)}static formatTransforms(t){const n="both"===t.flip||!0===t.flip,r=t.flip&&(n||"x"===t.flip)?-1:1,i=t.flip&&(n||"y"===t.flip)?-1:1,s=t.skew&&t.skew.length?t.skew[0]:isFinite(t.skew)?t.skew:isFinite(t.skewX)?t.skewX:0,e=t.skew&&t.skew.length?t.skew[1]:isFinite(t.skew)?t.skew:isFinite(t.skewY)?t.skewY:0,h=t.scale&&t.scale.length?t.scale[0]*r:isFinite(t.scale)?t.scale*r:isFinite(t.scaleX)?t.scaleX*r:r,o=t.scale&&t.scale.length?t.scale[1]*i:isFinite(t.scale)?t.scale*i:isFinite(t.scaleY)?t.scaleY*i:i,u=t.shear||0,c=t.rotate||t.theta||0,a=new Cn(t.origin||t.around||t.ox||t.originX,t.oy||t.originY),l=a.x,f=a.y,p=new Cn(t.position??t.px??t.positionX??NaN,t.py??t.positionY??NaN),d=p.x,w=p.y,y=new Cn(t.translate||t.tx||t.translateX,t.ty||t.translateY),m=y.x,v=y.y,b=new Cn(t.relative||t.rx||t.relativeX,t.ry||t.relativeY);return{scaleX:h,scaleY:o,skewX:s,skewY:e,shear:u,theta:c,rx:b.x,ry:b.y,tx:m,ty:v,ox:l,oy:f,px:d,py:w}}static fromArray(t){return{a:t[0],b:t[1],c:t[2],d:t[3],e:t[4],f:t[5]}}static isMatrixLike(t){return null!=t.a||null!=t.b||null!=t.c||null!=t.d||null!=t.e||null!=t.f}static matrixMultiply(t,n,r){const i=t.b*n.a+t.d*n.b,s=t.a*n.c+t.c*n.d,e=t.b*n.c+t.d*n.d,h=t.e+t.a*n.e+t.c*n.f,o=t.f+t.b*n.e+t.d*n.f;return r.a=t.a*n.a+t.c*n.b,r.b=i,r.c=s,r.d=e,r.e=h,r.f=o,r}around(t,n,r){return this.clone().aroundO(t,n,r)}aroundO(t,n,r){const i=t||0,s=n||0;return this.translateO(-i,-s).lmultiplyO(r).translateO(i,s)}clone(){return new t(this)}decompose(t=0,n=0){const r=this.a,i=this.b,s=this.c,e=this.d,h=this.e,o=this.f,u=r*e-i*s,c=u>0?1:-1,a=c*Math.sqrt(r*r+i*i),l=Math.atan2(c*i,c*r),f=(r*s+i*e)/u;return{scaleX:a,scaleY:s*a/(f*r-i)||e*a/(f*i+r),shear:f,rotate:180/Math.PI*l,translateX:h-t+t*r+n*s,translateY:o-n+t*i+n*e,originX:t,originY:n,a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f}}equals(n){if(n===this)return!0;const r=new t(n);return Dn(this.a,r.a)&&Dn(this.b,r.b)&&Dn(this.c,r.c)&&Dn(this.d,r.d)&&Dn(this.e,r.e)&&Dn(this.f,r.f)}flip(t,n){return this.clone().flipO(t,n)}flipO(t,n){return"x"===t?this.scaleO(-1,1,n,0):"y"===t?this.scaleO(1,-1,0,n):this.scaleO(-1,-1,t,n||t)}init(n){const r=t.fromArray([1,0,0,1,0,0]);return n=n instanceof er?n.matrixify():"string"==typeof n?t.fromArray(n.split(jn).map(parseFloat)):Array.isArray(n)?t.fromArray(n):"object"==typeof n&&t.isMatrixLike(n)?n:"object"==typeof n?(new t).transform(n):6===arguments.length?t.fromArray([].slice.call(arguments)):r,this.a=null!=n.a?n.a:r.a,this.b=null!=n.b?n.b:r.b,this.c=null!=n.c?n.c:r.c,this.d=null!=n.d?n.d:r.d,this.e=null!=n.e?n.e:r.e,this.f=null!=n.f?n.f:r.f,this}inverse(){return this.clone().inverseO()}inverseO(){const t=this.a,n=this.b,r=this.c,i=this.d,s=this.e,e=this.f,h=t*i-n*r;if(!h)throw new Error("Cannot invert "+this);const o=i/h,u=-n/h,c=-r/h,a=t/h,l=-(o*s+c*e),f=-(u*s+a*e);return this.a=o,this.b=u,this.c=c,this.d=a,this.e=l,this.f=f,this}lmultiply(t){return this.clone().lmultiplyO(t)}lmultiplyO(n){const r=n instanceof t?n:new t(n);return t.matrixMultiply(r,this,this)}multiply(t){return this.clone().multiplyO(t)}multiplyO(n){const r=n instanceof t?n:new t(n);return t.matrixMultiply(this,r,this)}rotate(t,n,r){return this.clone().rotateO(t,n,r)}rotateO(t,n=0,r=0){t=Gt(t);const i=Math.cos(t),s=Math.sin(t),{a:e,b:h,c:o,d:u,e:c,f:a}=this;return this.a=e*i-h*s,this.b=h*i+e*s,this.c=o*i-u*s,this.d=u*i+o*s,this.e=c*i-a*s+r*s-n*i+n,this.f=a*i+c*s-n*s-r*i+r,this}scale(){return this.clone().scaleO(...arguments)}scaleO(t,n=t,r=0,i=0){3===arguments.length&&(i=r,r=n,n=t);const{a:s,b:e,c:h,d:o,e:u,f:c}=this;return this.a=s*t,this.b=e*n,this.c=h*t,this.d=o*n,this.e=u*t-r*t+r,this.f=c*n-i*n+i,this}shear(t,n,r){return this.clone().shearO(t,n,r)}shearO(t,n=0,r=0){const{a:i,b:s,c:e,d:h,e:o,f:u}=this;return this.a=i+s*t,this.c=e+h*t,this.e=o+u*t-r*t,this}skew(){return this.clone().skewO(...arguments)}skewO(t,n=t,r=0,i=0){3===arguments.length&&(i=r,r=n,n=t),t=Gt(t),n=Gt(n);const s=Math.tan(t),e=Math.tan(n),{a:h,b:o,c:u,d:c,e:a,f:l}=this;return this.a=h+o*s,this.b=o+h*e,this.c=u+c*s,this.d=c+u*e,this.e=a+l*s-i*s,this.f=l+a*e-r*e,this}skewX(t,n,r){return this.skew(t,0,n,r)}skewY(t,n,r){return this.skew(0,t,n,r)}toArray(){return[this.a,this.b,this.c,this.d,this.e,this.f]}toString(){return"matrix("+this.a+","+this.b+","+this.c+","+this.d+","+this.e+","+this.f+")"}transform(n){if(t.isMatrixLike(n))return new t(n).multiplyO(this);const r=t.formatTransforms(n),{x:i,y:s}=new Cn(r.ox,r.oy).transform(this),e=(new t).translateO(r.rx,r.ry).lmultiplyO(this).translateO(-i,-s).scaleO(r.scaleX,r.scaleY).skewO(r.skewX,r.skewY).shearO(r.shear).rotateO(r.theta).translateO(i,s);if(isFinite(r.px)||isFinite(r.py)){const t=new Cn(i,s).transform(e),n=isFinite(r.px)?r.px-t.x:0,h=isFinite(r.py)?r.py-t.y:0;e.translateO(n,h)}return e.translateO(r.tx,r.ty),e}translate(t,n){return this.clone().translateO(t,n)}translateO(t,n){return this.e+=t||0,this.f+=n||0,this}valueOf(){return{a:this.a,b:this.b,c:this.c,d:this.d,e:this.e,f:this.f}}};function Fn(){if(!Fn.nodes||Fn.nodes.svg.node.ownerDocument!==Ut.document){const t=rn().size(2,0);t.node.style.cssText=["opacity: 0","position: absolute","left: -100%","top: -100%","overflow: hidden"].join(";"),t.attr("focusable","false"),t.attr("aria-hidden","true"),Fn.nodes={svg:t,path:t.path().node}}return Fn.nodes.svg.node.parentNode||Fn.nodes.svg.addTo(Ut.document.body||Ut.document.documentElement),Fn.nodes}function Nn(t){return!(t.width||t.height||t.x||t.y)}on(zn,"Matrix");var Yn=class t{constructor(...t){this.init(...t)}addOffset(){return this.x+=Ut.window.pageXOffset,this.y+=Ut.window.pageYOffset,new t(this)}init(t){return t="string"==typeof t?t.split(jn).map(parseFloat):Array.isArray(t)?t:"object"==typeof t?[null!=t.left?t.left:t.x,null!=t.top?t.top:t.y,t.width,t.height]:4===arguments.length?[].slice.call(arguments):[0,0,0,0],this.x=t[0]||0,this.y=t[1]||0,this.width=this.w=t[2]||0,this.height=this.h=t[3]||0,this.x2=this.x+this.w,this.y2=this.y+this.h,this.cx=this.x+this.w/2,this.cy=this.y+this.h/2,this}isNulled(){return Nn(this)}merge(n){const r=Math.min(this.x,n.x),i=Math.min(this.y,n.y),s=Math.max(this.x+this.width,n.x+n.width)-r,e=Math.max(this.y+this.height,n.y+n.height)-i;return new t(r,i,s,e)}toArray(){return[this.x,this.y,this.width,this.height]}toString(){return this.x+" "+this.y+" "+this.width+" "+this.height}transform(n){n instanceof zn||(n=new zn(n));let r=1/0,i=-1/0,s=1/0,e=-1/0;return[new Cn(this.x,this.y),new Cn(this.x2,this.y),new Cn(this.x,this.y2),new Cn(this.x2,this.y2)].forEach((function(t){t=t.transform(n),r=Math.min(r,t.x),i=Math.max(i,t.x),s=Math.min(s,t.y),e=Math.max(e,t.y)})),new t(r,s,i-r,e-s)}};function Pn(t,n,r){let i;try{if(i=n(t.node),Nn(i)&&(s=t.node)!==Ut.document&&!(Ut.document.documentElement.contains||function(t){for(;t.parentNode;)t=t.parentNode;return t===Ut.document}).call(Ut.document.documentElement,s))throw new Error("Element not in the dom")}catch(n){i=r(t)}var s;return i}M({viewbox:{viewbox(t,n,r,i){return null==t?new Yn(this.attr("viewBox")):this.attr("viewBox",new Yn(t,n,r,i))},zoom(t,n){let{width:r,height:i}=this.attr(["width","height"]);if((r||i)&&"string"!=typeof r&&"string"!=typeof i||(r=this.node.clientWidth,i=this.node.clientHeight),!r||!i)throw new Error("Impossible to get absolute width and height. Please provide an absolute width and height attribute on the zooming element");const s=this.viewbox(),e=r/s.width,h=i/s.height,o=Math.min(e,h);if(null==t)return o;let u=o/t;u===1/0&&(u=Number.MAX_SAFE_INTEGER/100),n=n||new Cn(r/2/e+s.x,i/2/h+s.y);const c=new Yn(s).transform(new zn({scale:u,origin:n}));return this.viewbox(c)}}}),on(Yn,"Box");var In=class extends Array{constructor(t=[],...n){if(super(t,...n),"number"==typeof t)return this;this.length=0,this.push(...t)}};ln([In],{each(t,...n){return this.map("function"==typeof t?(n,r,i)=>t.call(n,n,r,i):r=>r[t](...n))},toArray(){return Array.prototype.concat.apply([],this)}});const $n=["toArray","constructor","each"];function Rn(t){let n=(t+"").trim();const r=n.match(/^url\((.*)\)$/i);if(r){n=r[1].trim();const t=n[0];if('"'===t||"'"===t){if(n[n.length-1]!==t)return null;n=n.slice(1,-1)}}const i=n.match(yn);return i?i[1].slice(1):null}function Gn(t,n){const r=`#${Ut.window.CSS.escape(n)}`;return 1===t.nodeType&&t.matches(r)?t:t.querySelector(r)}function Ln(t,n,r=`[${n}]`){const i=t.getAttribute("id"),s=t.getRootNode();if(!i||Gn(s,i)!==t)return new In;const e=[];1===s.nodeType&&s.matches(r)&&Rn(s.getAttribute(n))===i&&e.push(en(s));for(const t of s.querySelectorAll(r))Rn(t.getAttribute(n))===i&&e.push(en(t));return new In(e)}In.extend=function(t){t=t.reduce(((t,n)=>((0,$t.default)($n).call($n,n)||"_"===n[0]||(n in Array.prototype&&(t["$"+n]=Array.prototype[n]),t[n]=function(...t){return this.each(n,...t)}),t)),{}),ln([In],t)};let Xn=0;const Hn=new WeakMap,Qn=new WeakMap,Vn=()=>Object.create(null);function Bn(t){const n=t.getEventHolder();let r=Hn.get(n);return r||(r=Vn(),Hn.set(n,r)),r}function Wn(t){return t.getEventTarget()}function Jn(t,n,r,i,s){const e=r.bind(i||t),h=s||!1,o=rn(t),u=Bn(o),c=Wn(o);n=Array.isArray(n)?n:n.split(jn);let a=Qn.get(r);a||(a=++Xn,Qn.set(r,a)),n.forEach((function(t){const n=t.split(".")[0],r=t.split(".")[1]||"*";u[n]=u[n]||Vn(),u[n][r]=u[n][r]||Vn(),u[n][r][a]=u[n][r][a]||[],u[n][r][a].push({listener:e,options:h}),c.addEventListener(n,e,h)}))}function qn(t,n,r,i){const s=rn(t),e=Bn(s),h=Wn(s);("function"!=typeof r||(r=Qn.get(r)))&&(n=Array.isArray(n)?n:(n||"").split(jn)).forEach((function(t){const n=t&&t.split(".")[0],o=t&&t.split(".")[1];let u,c;if(r){if(e[n]&&e[n][o||"*"]){const t=e[n][o||"*"][r];if(!t)return;t.forEach((function(t){h.removeEventListener(n,t.listener,t.options??i??!1)})),delete e[n][o||"*"][r]}}else if(n&&o){if(e[n]&&e[n][o]){for(c in e[n][o])qn(h,[n,o].join("."),c);delete e[n][o]}}else if(o)for(t in e)for(u in e[t])o===u&&qn(h,[t,o].join("."));else if(n){if(e[n]){for(u in e[n])qn(h,[n,u].join("."));delete e[n]}}else{for(t in e)qn(h,t);!function(t){Hn.delete(t.getEventHolder())}(s)}}))}var Un=class extends Zt{addEventListener(){}dispatch(t,n,r){return function(t,n,r,i){const s=Wn(t);return n instanceof Ut.window.Event||(n=new Ut.window.CustomEvent(n,{detail:r,cancelable:!0,...i})),s.dispatchEvent(n),n}(this,t,n,r)}dispatchEvent(t){const n=Bn(this)[t.type];if(!n)return!0;for(const r in n)for(const i in n[r])n[r][i].forEach((function(n){n.listener(t)}));return!t.defaultPrevented}fire(t,n,r){return this.dispatch(t,n,r),this}getEventHolder(){return this}getEventTarget(){return this}off(t,n,r){return qn(this,t,n,r),this}on(t,n,r,i){return Jn(this,t,n,r,i),this}removeEventListener(){}};function Zn(){}on(Un,"EventTarget");const Kn={"fill-opacity":1,"stroke-opacity":1,"stroke-width":0,"stroke-linejoin":"miter","stroke-linecap":"butt",fill:"#000000",stroke:"#000000",opacity:1,x:0,y:0,cx:0,cy:0,width:0,height:0,r:0,rx:0,ry:0,offset:0,"stop-opacity":1,"stop-color":"#000000","text-anchor":"start"};var tr=class extends Array{constructor(...t){super(...t),this.init(...t)}clone(){return new this.constructor(this)}init(t){return"number"==typeof t||(this.length=0,this.push(...this.parse(t))),this}parse(t=[]){return t instanceof Array?t:t.trim().split(jn).map(parseFloat)}toArray(){return Array.prototype.concat.apply([],this)}toSet(){return new Set(this)}toString(){return this.join(" ")}valueOf(){const t=[];return t.push(...this),t}},nr=class t{constructor(...t){this.init(...t)}convert(n){return new t(this.value,n)}divide(n){return n=new t(n),new t(this/n,this.unit||n.unit)}init(n,r){return r=Array.isArray(n)?n[1]:r,n=Array.isArray(n)?n[0]:n,this.value=0,this.unit=r||"","number"==typeof n?this.value=isNaN(n)?0:isFinite(n)?n:n<0?-34e37:34e37:"string"==typeof n?(r=n.match(pn))&&(this.value=parseFloat(r[1]),"%"===r[5]?this.value/=100:"s"===r[5]&&(this.value*=1e3),this.unit=r[5]):n instanceof t&&(this.value=n.valueOf(),this.unit=n.unit),this}minus(n){return n=new t(n),new t(this-n,this.unit||n.unit)}plus(n){return n=new t(n),new t(this+n,this.unit||n.unit)}times(n){return n=new t(n),new t(this*n,this.unit||n.unit)}toArray(){return[this.value,this.unit]}toJSON(){return this.toString()}toString(){return("%"===this.unit?~~(1e8*this.value)/1e6:"s"===this.unit?this.value/1e3:this.value)+this.unit}valueOf(){return this.value}};const rr=new Set(["fill","stroke","color","bgcolor","stop-color","flood-color","lighting-color"]),ir=[];var sr=class t extends Un{constructor(t,n){super(),this.node=t,this.type=t.nodeName,n&&t!==n&&this.attr(n)}add(t,n){return(t=rn(t)).removeNamespace&&this.node instanceof Ut.window.SVGElement&&t.removeNamespace(),null==n?this.node.appendChild(t.node):t.node!==this.node.childNodes[n]&&this.node.insertBefore(t.node,this.node.childNodes[n]),this}addTo(t,n){return rn(t).put(this,n)}children(){return new In(Rt(this.node.children,(function(t){return en(t)})))}clear(){for(;this.node.hasChildNodes();)this.node.removeChild(this.node.lastChild);return this}clone(t=!0,n=!0){this.writeDataToDom();let r=this.node.cloneNode(t);return n&&(r=an(r)),new this.constructor(r)}each(t,n){const r=this.children();let i,s;for(i=0,s=r.length;i<s;i++)t.apply(r[i],[i,r]),n&&r[i].each(t,n);return this}element(n,r){return this.put(new t(nn(n),r))}first(){return en(this.node.firstChild)}get(t){return en(this.node.childNodes[t])}getEventHolder(){return this.node}getEventTarget(){return this.node}has(t){return this.index(t)>=0}html(t,n){return this.xml(t,n,"http://www.w3.org/1999/xhtml")}id(t){return void 0!==t||this.node.id||(this.node.id=cn(this.type)),this.attr("id",t)}index(t){return[].slice.call(this.node.childNodes).indexOf(t.node)}last(){return en(this.node.lastChild)}matches(t){const n=this.node,r=n.matches||n.matchesSelector||n.msMatchesSelector||n.mozMatchesSelector||n.webkitMatchesSelector||n.oMatchesSelector||null;return r&&r.call(n,t)}parent(t){let n=this;if(!n.node.parentNode)return null;if(n=en(n.node.parentNode),!t)return n;do{if("string"==typeof t?n.matches(t):n instanceof t)return n}while(n=en(n.node.parentNode));return n}put(t,n){return t=rn(t),this.add(t,n),t}putIn(t,n){return rn(t).add(this,n)}remove(){return this.parent()&&this.parent().removeElement(this),this}removeElement(t){return this.node.removeChild(t.node),this}replace(t){return t=rn(t),this.node.parentNode&&this.node.parentNode.replaceChild(t.node,this.node),t}round(t=2,n=null){const r=10**t,i=this.attr(n);for(const t in i)"number"==typeof i[t]&&(i[t]=Math.round(i[t]*r)/r);return this.attr(i),this}svg(t,n){return this.xml(t,n,Wt)}toString(){return this.id()}words(t){return this.node.textContent=t,this}wrap(t){const n=this.parent();if(!n)return this.addTo(t);const r=n.index(this);return n.put(t,r).put(this)}writeDataToDom(){return this.each((function(){this.writeDataToDom()})),this}xml(t,n,r){if("boolean"==typeof t&&(r=n,n=t,t=null),null==t||"function"==typeof t){n=null==n||n,this.writeDataToDom();let r=this;if(null!=t){if(r=en(r.node.cloneNode(!0)),n){const n=t(r);if(r=n||r,!1===n)return""}r.each((function(){const n=t(this),r=n||this;!1===n?this.remove():n&&this!==r&&this.replace(r)}),!0)}return n?r.node.outerHTML:r.node.innerHTML}n=null!=n&&n;const i=nn("wrapper",r),s=Ut.document.createDocumentFragment();i.innerHTML=t;for(let t=i.children.length;t--;)s.appendChild(i.firstElementChild);const e=this.parent();return n?this.replace(s)&&e:this.add(s)}};ln(sr,{attr:function(t,n,r){if(null==t){t={},n=this.node.attributes;for(const r of n)t[r.nodeName]=Mn.test(r.nodeValue)?parseFloat(r.nodeValue):r.nodeValue;return t}if(t instanceof Array)return t.reduce(((t,n)=>(t[n]=this.attr(n),t)),{});if("object"==typeof t&&t.constructor===Object)for(n in t)this.attr(n,t[n]);else if(null===n)this.node.removeAttribute(t);else{if(null==n)return null==(n=this.node.getAttribute(t))?Kn[t]:Mn.test(n)?parseFloat(n):n;"number"==typeof(n=ir.reduce(((n,r)=>r(t,n,this)),n))?n=new nr(n):rr.has(t)&&Tn.isColor(n)?n=new Tn(n):n.constructor===Array&&(n=new tr(n)),"leading"===t?this.leading&&this.leading(n):"string"==typeof r?this.node.setAttributeNS(r,t,n.toString()):this.node.setAttribute(t,n.toString()),!this.rebuild||"font-size"!==t&&"x"!==t||this.rebuild()}return this},find:function(t){return function(t,n){return new In(Rt((n||Ut.document).querySelectorAll(t),(function(t){return en(t)})))}(t,this.node)},findOne:function(t){return en(this.node.querySelector(t))}}),on(sr,"Dom");var er=class extends sr{constructor(t,n){super(t,n),this.dom={},this.node.instance=this,(t.hasAttribute("data-svgjs")||t.hasAttribute("svgjs:data"))&&this.setData(JSON.parse(t.getAttribute("data-svgjs"))??JSON.parse(t.getAttribute("svgjs:data"))??{})}center(t,n){return this.cx(t).cy(n)}cx(t){return null==t?this.x()+this.width()/2:this.x(t-this.width()/2)}cy(t){return null==t?this.y()+this.height()/2:this.y(t-this.height()/2)}defs(){const t=this.root();return t&&t.defs()}dmove(t,n){return this.dx(t).dy(n)}dx(t=0){return this.x(new nr(t).plus(this.x()))}dy(t=0){return this.y(new nr(t).plus(this.y()))}getEventHolder(){return this}height(t){return this.attr("height",t)}move(t,n){return this.x(t).y(n)}parents(t=this.root()){const n="string"==typeof t,r=this.root(),i=r&&r.node;n||(t=t&&rn(t).node);const s=new In;let e=this;for(;(e=e.parent())&&e.node!==Ut.document&&"#document-fragment"!==e.node.nodeName&&(s.push(e),n||e.node!==t)&&(!n||!e.matches(t));)if(i&&e.node===i)return null;return s}reference(t){if(!(t=this.attr(t)))return null;const n=function(t,n){const r=Rn(n);return r?Gn(t.getRootNode(),r):null}(this.node,t);return n?rn(n):null}root(){const t=this.parent(Kt[tn]);return t&&t.root()}setData(t){return this.dom=t,this}size(t,n){const r=Ht(this,t,n);return this.width(new nr(r.width)).height(new nr(r.height))}width(t){return this.attr("width",t)}writeDataToDom(t){return((t,n,r={})=>{const i={...this.dom};for(const t in i)i[t].valueOf()===r[t]&&delete i[t];Object.keys(i).length?t.node.setAttribute("data-svgjs",JSON.stringify(i)):(t.node.removeAttribute("data-svgjs"),t.node.removeAttribute("svgjs:data"))})(this,0,t),super.writeDataToDom()}x(t){return this.attr("x",t)}y(t){return this.attr("y",t)}};ln(er,{bbox:function(){const t=Pn(this,(t=>t.getBBox()),(t=>{try{const n=t.clone().addTo(Fn().svg).show(),r=n.node.getBBox();return n.remove(),r}catch(n){throw new Error(`Getting bbox of element "${t.node.nodeName}" is not possible: ${n.toString()}`)}}));return new Yn(t)},rbox:function(t){const n=Pn(this,(t=>t.getBoundingClientRect()),(t=>{throw new Error(`Getting rbox of element "${t.node.nodeName}" is not possible`)})),r=new Yn(n);return t?r.transform(t.screenCTM().inverseO()):r.addOffset()},inside:function(t,n){const r=this.bbox();return t>r.x&&n>r.y&&t<r.x+r.width&&n<r.y+r.height},point:function(t,n){return new Cn(t,n).transformO(this.screenCTM().inverseO())},ctm:function(){return new zn(this.node.getCTM())},screenCTM:function(){try{if("function"==typeof this.isRoot&&!this.isRoot()){const t=this.rect(1,1),n=t.node.getScreenCTM();return t.remove(),new zn(n)}return new zn(this.node.getScreenCTM())}catch(t){return console.warn(`Cannot get CTM from SVG node ${this.node.nodeName}. Is the element rendered?`),new zn}}}),on(er,"Element");const hr={stroke:["color","width","opacity","linecap","linejoin","miterlimit","dasharray","dashoffset"],fill:["color","opacity","rule"],prefix:function(t,n){return"color"===n?t:t+"-"+n}};["fill","stroke"].forEach((function(t){const n={};let r;n[t]=function(n){if(void 0===n)return this.attr(t);if("string"==typeof n||n instanceof Tn||Tn.isRgb(n)||n instanceof er)this.attr(t,n);else for(r=hr[t].length-1;r>=0;r--)null!=n[hr[t][r]]&&this.attr(hr.prefix(t,hr[t][r]),n[hr[t][r]]);return this},M(["Element","Runner"],n)})),M(["Element","Runner"],{matrix:function(t,n,r,i,s,e){return null==t?new zn(this):this.attr("transform",new zn(t,n,r,i,s,e))},rotate:function(t,n,r){return this.transform({rotate:t,ox:n,oy:r},!0)},skew:function(t,n,r,i){return this.transform(1===arguments.length||3===arguments.length?{skew:t,ox:n,oy:r}:{skew:[t,n],ox:r,oy:i},!0)},shear:function(t,n,r){return this.transform({shear:t,ox:n,oy:r},!0)},scale:function(t,n,r,i){return this.transform(1===arguments.length||3===arguments.length?{scale:t,ox:n,oy:r}:{scale:[t,n],ox:r,oy:i},!0)},translate:function(t,n){return this.transform({translate:[t,n]},!0)},relative:function(t,n){return this.transform({relative:[t,n]},!0)},flip:function(t="both",n="center"){return-1==="xybothtrue".indexOf(t)&&(n=t,t="both"),this.transform({flip:t,origin:n},!0)},opacity:function(t){return this.attr("opacity",t)}}),M("radius",{radius:function(t,n=t){return"radialGradient"===(this._element||this).type?this.attr("r",new nr(t)):this.rx(t).ry(n)}}),M("Path",{length:function(){return this.node.getTotalLength()},pointAt:function(t){return new Cn(this.node.getPointAtLength(t))}}),M(["Element","Runner"],{font:function(t,n){if("object"==typeof t){for(n in t)this.font(n,t[n]);return this}return"leading"===t?this.leading(n):this.attr("anchor"===t?"text-anchor":"size"===t||"family"===t||"weight"===t||"stretch"===t||"variant"===t||"style"===t?"font-"+t:t,n)}}),M("Element",["click","dblclick","mousedown","mouseup","mouseover","mouseout","mousemove","mouseenter","mouseleave","touchstart","touchmove","touchleave","touchend","touchcancel","contextmenu","wheel","pointerdown","pointermove","pointerup","pointerleave","pointercancel"].reduce((function(t,n){return t[n]=function(t){return null===t?this.off(n):this.on(n,t),this},t}),{})),M("Element",{untransform:function(){return this.attr("transform",null)},matrixify:function(){return(this.attr("transform")||"").split(mn).slice(0,-1).map((function(t){const n=t.trim().split("(");return[n[0].trim(),n[1].split(jn).map((function(t){return parseFloat(t)}))]})).reverse().reduce((function(t,n){return"matrix"===n[0]?t.lmultiply(zn.fromArray(n[1])):t[n[0]].apply(t,n[1])}),new zn)},toParent:function(t,n){if(this===t)return this;if(Bt(this.node))return this.addTo(t,n);const r=this.screenCTM(),i=t.screenCTM().inverse();return this.addTo(t,n).untransform().transform(i.multiply(r)),this},toRoot:function(t){return this.toParent(this.root(),t)},transform:function(t,n){if(null==t||"string"==typeof t){const n=new zn(this).decompose();return null==t?n:n[t]}zn.isMatrixLike(t)||(t={...t,origin:Qt(t,this)});const r=new zn(!0===n?this:n||!1).transform(t);return this.attr("transform",r)}});var or=class t extends er{flatten(){return this.each((function(){if(this instanceof t)return this.flatten().ungroup()})),this}ungroup(t=this.parent(),n=t.index(this)){return n=-1===n?t.children().length:n,this.each((function(r,i){return i[i.length-r-1].toParent(t,n)})),this.remove()}};on(or,"Container");var ur=class extends or{constructor(t,n=t){super(sn("defs",t),n)}flatten(){return this}ungroup(){return this}};on(ur,"Defs");var cr=class extends er{};on(cr,"Shape");var ar=v({cx:()=>wr,cy:()=>yr,height:()=>vr,rx:()=>lr,ry:()=>fr,width:()=>mr,x:()=>pr,y:()=>dr});function lr(t){return this.attr("rx",t)}function fr(t){return this.attr("ry",t)}function pr(t){return null==t?this.cx()-this.rx():this.cx(t+this.rx())}function dr(t){return null==t?this.cy()-this.ry():this.cy(t+this.ry())}function wr(t){return this.attr("cx",t)}function yr(t){return this.attr("cy",t)}function mr(t){return null==t?2*this.rx():this.rx(new nr(t).divide(2))}function vr(t){return null==t?2*this.ry():this.ry(new nr(t).divide(2))}var br=class extends cr{constructor(t,n=t){super(sn("ellipse",t),n)}size(t,n){const r=Ht(this,t,n);return this.rx(new nr(r.width).divide(2)).ry(new nr(r.height).divide(2))}};ln(br,ar),M("Container",{ellipse:fn((function(t=0,n=t){return this.put(new br).size(t,n).move(0,0)}))}),on(br,"Ellipse");var gr=class extends sr{constructor(t=Ut.document.createDocumentFragment()){super(t)}xml(t,n,r){if("boolean"==typeof t&&(r=n,n=t,t=null),null==t||"function"==typeof t){const t=new sr(nn("wrapper",r));return t.add(this.node.cloneNode(!0)),t.xml(!1,r)}return super.xml(t,!1,r)}};on(gr,"Fragment");var xr=v({from:()=>Mr,to:()=>_r});function Mr(t,n){return this.attr("radialGradient"===(this._element||this).type?{fx:new nr(t),fy:new nr(n)}:{x1:new nr(t),y1:new nr(n)})}function _r(t,n){return this.attr("radialGradient"===(this._element||this).type?{cx:new nr(t),cy:new nr(n)}:{x2:new nr(t),y2:new nr(n)})}var jr=class extends or{constructor(t,n){super(sn(t+"Gradient","string"==typeof t?null:t),n)}attr(t,n,r){return"transform"===t&&(t="gradientTransform"),super.attr(t,n,r)}bbox(){return new Yn}targets(){return Ln(this.node,"fill")}toString(){return this.url()}update(t){return this.clear(),"function"==typeof t&&t.call(this,this),this}url(){return"url(#"+this.id()+")"}};ln(jr,xr),M({Container:{gradient(...t){return this.defs().gradient(...t)}},Defs:{gradient:fn((function(t,n){return this.put(new jr(t)).update(n)}))}}),on(jr,"Gradient");var Sr=class extends or{constructor(t,n=t){super(sn("pattern",t),n)}attr(t,n,r){return"transform"===t&&(t="patternTransform"),super.attr(t,n,r)}bbox(){return new Yn}targets(){return Ln(this.node,"fill")}toString(){return this.url()}update(t){return this.clear(),"function"==typeof t&&t.call(this,this),this}url(){return"url(#"+this.id()+")"}};M({Container:{pattern(...t){return this.defs().pattern(...t)}},Defs:{pattern:fn((function(t,n,r){return this.put(new Sr).update(r).attr({x:0,y:0,width:t,height:n,patternUnits:"userSpaceOnUse"})}))}}),on(Sr,"Pattern");var Ar=class extends cr{constructor(t,n=t){super(sn("image",t),n)}load(t,n){if(!t)return this;const r=new Ut.window.Image;return Jn(r,"load",(function(t){const i=this.parent(Sr);0===this.width()&&0===this.height()&&this.size(r.width,r.height),i instanceof Sr&&0===i.width()&&0===i.height()&&i.size(this.width(),this.height()),"function"==typeof n&&n.call(this,t)}),this),Jn(r,"load error",(function(){qn(r)})),this.attr("href",r.src=t,qt)}};ir.push((function(t,n,r){return"fill"!==t&&"stroke"!==t||_n.test(n)&&(n=r.root().defs().image(n)),n instanceof Ar&&(n=r.root().defs().pattern(0,0,(t=>{t.add(n)}))),n})),M({Container:{image:fn((function(t,n){return this.put(new Ar).size(0,0).load(t,n)}))}}),on(Ar,"Image");var Or=class extends tr{bbox(){let t=-1/0,n=-1/0,r=1/0,i=1/0;return this.forEach((function(s){t=Math.max(s[0],t),n=Math.max(s[1],n),r=Math.min(s[0],r),i=Math.min(s[1],i)})),new Yn(r,i,t-r,n-i)}move(t,n){const r=this.bbox();if(t-=r.x,n-=r.y,!isNaN(t)&&!isNaN(n))for(let r=this.length-1;r>=0;r--)this[r]=[this[r][0]+t,this[r][1]+n];return this}parse(t=[0,0]){const n=[];(t=t instanceof Array?Array.prototype.concat.apply([],t):t.trim().split(jn).map(parseFloat)).length%2!=0&&t.pop();for(let r=0,i=t.length;r<i;r+=2)n.push([t[r],t[r+1]]);return n}size(t,n){let r;const i=this.bbox();for(r=this.length-1;r>=0;r--)i.width&&(this[r][0]=(this[r][0]-i.x)*t/i.width+i.x),i.height&&(this[r][1]=(this[r][1]-i.y)*n/i.height+i.y);return this}toLine(){return{x1:this[0][0],y1:this[0][1],x2:this[1][0],y2:this[1][1]}}toString(){const t=[];for(let n=0,r=this.length;n<r;n++)t.push(this[n].join(","));return t.join(" ")}transform(t){return this.clone().transformO(t)}transformO(t){zn.isMatrixLike(t)||(t=new zn(t));for(let n=this.length;n--;){const[r,i]=this[n];this[n][0]=t.a*r+t.c*i+t.e,this[n][1]=t.b*r+t.d*i+t.f}return this}},kr=v({MorphArray:()=>Er,height:()=>zr,width:()=>Dr,x:()=>Tr,y:()=>Cr});const Er=Or;function Tr(t){return null==t?this.bbox().x:this.move(t,this.bbox().y)}function Cr(t){return null==t?this.bbox().y:this.move(this.bbox().x,t)}function Dr(t){const n=this.bbox();return null==t?n.width:this.size(t,n.height)}function zr(t){const n=this.bbox();return null==t?n.height:this.size(n.width,t)}var Fr=class extends cr{constructor(t,n=t){super(sn("line",t),n)}array(){return new Or([[this.attr("x1"),this.attr("y1")],[this.attr("x2"),this.attr("y2")]])}move(t,n){return this.attr(this.array().move(t,n).toLine())}plot(t,n,r,i){return null==t?this.array():(t=void 0!==n?{x1:t,y1:n,x2:r,y2:i}:new Or(t).toLine(),this.attr(t))}size(t,n){const r=Ht(this,t,n);return this.attr(this.array().size(r.width,r.height).toLine())}};ln(Fr,kr),M({Container:{line:fn((function(...t){return Fr.prototype.plot.apply(this.put(new Fr),null!=t[0]?t:[0,0,0,0])}))}}),on(Fr,"Line");var Nr=class extends or{constructor(t,n=t){super(sn("marker",t),n)}height(t){return this.attr("markerHeight",t)}orient(t){return this.attr("orient",t)}ref(t,n){return this.attr("refX",t).attr("refY",n)}toString(){return"url(#"+this.id()+")"}update(t){return this.clear(),"function"==typeof t&&t.call(this,this),this}width(t){return this.attr("markerWidth",t)}};function Yr(t,n){return function(r){return null==r?this[t]:(this[t]=r,n&&n.call(this),this)}}M({Container:{marker(...t){return this.defs().marker(...t)}},Defs:{marker:fn((function(t,n,r){return this.put(new Nr).size(t,n).ref(t/2,n/2).viewbox(0,0,t,n).attr("orient","auto").update(r)}))},marker:{marker(t,n,r,i){let s=["marker"];return"all"!==t&&s.push(t),s=s.join("-"),t=arguments[1]instanceof Nr?arguments[1]:this.defs().marker(n,r,i),this.attr(s,t)}}}),on(Nr,"Marker");const Pr={"-":function(t){return t},"<>":function(t){return-Math.cos(t*Math.PI)/2+.5},">":function(t){return Math.sin(t*Math.PI/2)},"<":function(t){return 1-Math.cos(t*Math.PI/2)},bezier:function(t,n,r,i){return function(s){return s<0?t>0?n/t*s:r>0?i/r*s:0:s>1?r<1?(1-i)/(1-r)*s+(i-r)/(1-r):t<1?(1-n)/(1-t)*s+(n-t)/(1-t):1:3*s*(1-s)**2*n+3*s**2*(1-s)*i+s**3}},steps:function(t,n="end"){n=n.split("-").reverse()[0];let r=t;return"none"===n?--r:"both"===n&&++r,(i,s=!1)=>{let e=Math.floor(i*t);const h=i*e%1==0;return"start"!==n&&"both"!==n||++e,s&&h&&--e,i>=0&&e<0&&(e=0),i<=1&&e>r&&(e=r),e/r}}};var Ir=class{done(){return!1}},$r=class extends Ir{constructor(t=">"){super(),this.ease=Pr[t]||t}step(t,n,r){return"number"!=typeof t?r<1?t:n:t+(n-t)*this.ease(r)}},Rr=class extends Ir{constructor(t){super(),this.stepper=t}done(t){return t.done}step(t,n,r,i){return this.stepper(t,n,r,i)}};function Gr(){const t=(this._duration||500)/1e3,n=Math.PI,r=Math.log((this._overshoot||0)/100+1e-10),i=-r/Math.sqrt(n*n+r*r),s=3.9/(i*t);this.d=2*i*s,this.k=s*s}ln(class extends Rr{constructor(t=500,n=0){super(),this.duration(t).overshoot(n)}step(t,n,r,i){if("string"==typeof t)return t;if(i.done=r===1/0,r===1/0)return n;if(0===r)return t;r>100&&(r=16);const s=i.velocity||0,e=-this.d*s-this.k*(t-n),h=t+s*(r/=1e3)+e*r*r/2;return i.velocity=s+e*r,i.done=Math.abs(n-h)+Math.abs(s)<.002,i.done?n:h}},{duration:Yr("_duration",Gr),overshoot:Yr("_overshoot",Gr)}),ln(class extends Rr{constructor(t=.1,n=.01,r=0,i=1e3){super(),this.p(t).i(n).d(r).windup(i)}step(t,n,r,i){if("string"==typeof t)return t;if(i.done=r===1/0,r===1/0)return n;if(0===r)return t;const s=n-t;let e=(i.integral||0)+s*r;const h=(s-(i.error||0))/r,o=this._windup;return!1!==o&&(e=Math.max(-o,Math.min(e,o))),i.error=s,i.integral=e,i.done=Math.abs(s)<.001,i.done?n:t+(this.P*s+this.I*e+this.D*h)}},{windup:Yr("_windup"),p:Yr("P"),i:Yr("I"),d:Yr("D")});const Lr={M:2,L:2,H:1,V:1,C:6,S:4,Q:4,T:2,A:7,Z:0},Xr={M:function(t,n,r){return n.x=r.x=t[0],n.y=r.y=t[1],["M",n.x,n.y]},L:function(t,n){return n.x=t[0],n.y=t[1],["L",t[0],t[1]]},H:function(t,n){return n.x=t[0],["H",t[0]]},V:function(t,n){return n.y=t[0],["V",t[0]]},C:function(t,n){return n.x=t[4],n.y=t[5],["C",t[0],t[1],t[2],t[3],t[4],t[5]]},S:function(t,n){return n.x=t[2],n.y=t[3],["S",t[0],t[1],t[2],t[3]]},Q:function(t,n){return n.x=t[2],n.y=t[3],["Q",t[0],t[1],t[2],t[3]]},T:function(t,n){return n.x=t[0],n.y=t[1],["T",t[0],t[1]]},Z:function(t,n,r){return n.x=r.x,n.y=r.y,["Z"]},A:function(t,n){return n.x=t[5],n.y=t[6],["A",t[0],t[1],t[2],t[3],t[4],t[5],t[6]]}},Hr="mlhvqtcsaz".split("");for(let t=0,n=Hr.length;t<n;++t)Xr[Hr[t]]=function(t){return function(n,r,i){if("H"===t)n[0]=n[0]+r.x;else if("V"===t)n[0]=n[0]+r.y;else if("A"===t)n[5]=n[5]+r.x,n[6]=n[6]+r.y;else for(let t=0,i=n.length;t<i;++t)n[t]=n[t]+(t%2?r.y:r.x);return Xr[t](n,r,i)}}(Hr[t].toUpperCase());function Qr(t){return t.segment.length&&t.segment.length-1===Lr[t.segment[0].toUpperCase()]}function Vr(t,n){t.inNumber&&Br(t,!1);const r=Sn.test(n);if(r)t.segment=[n];else{const n=t.lastCommand,r=n.toLowerCase();t.segment=["m"===r?n===r?"l":"L":n]}return t.inSegment=!0,t.lastCommand=t.segment[0],r}function Br(t,n){if(!t.inNumber)throw new Error("Parser Error");t.number&&t.segment.push(parseFloat(t.number)),t.inNumber=n,t.number="",t.pointSeen=!1,t.hasExponent=!1,Qr(t)&&Wr(t)}function Wr(t){t.inSegment=!1,t.absolute&&(t.segment=function(t){return Xr[t.segment[0]](t.segment.slice(1),t.p,t.p0)}(t)),t.segments.push(t.segment)}function Jr(t){if(!t.segment.length)return!1;const n="A"===t.segment[0].toUpperCase(),r=t.segment.length;return n&&(4===r||5===r)}function qr(t){return"E"===t.lastToken.toUpperCase()}const Ur=new Set([" ",",","\t","\n","\r","\f"]);var Zr=class extends tr{bbox(){return Fn().path.setAttribute("d",this.toString()),new Yn(Fn.nodes.path.getBBox())}move(t,n){const r=this.bbox();if(t-=r.x,n-=r.y,!isNaN(t)&&!isNaN(n))for(let r,i=this.length-1;i>=0;i--)r=this[i][0],"M"===r||"L"===r||"T"===r?(this[i][1]+=t,this[i][2]+=n):"H"===r?this[i][1]+=t:"V"===r?this[i][1]+=n:"C"===r||"S"===r||"Q"===r?(this[i][1]+=t,this[i][2]+=n,this[i][3]+=t,this[i][4]+=n,"C"===r&&(this[i][5]+=t,this[i][6]+=n)):"A"===r&&(this[i][6]+=t,this[i][7]+=n);return this}parse(t="M0 0"){return Array.isArray(t)&&(t=Array.prototype.concat.apply([],t).toString()),function(t,n=!0){let r=0,i="";const s={segment:[],inNumber:!1,number:"",lastToken:"",inSegment:!1,segments:[],pointSeen:!1,hasExponent:!1,absolute:n,p0:new Cn,p:new Cn};for(;s.lastToken=i,i=t.charAt(r++);)if(s.inSegment||!Vr(s,i))if("."!==i)if(isNaN(parseInt(i)))if(Ur.has(i))s.inNumber&&Br(s,!1);else if("-"!==i&&"+"!==i)if("E"!==i.toUpperCase()){if(Sn.test(i)){if(s.inNumber)Br(s,!1);else{if(!Qr(s))throw new Error("parser Error");Wr(s)}--r}}else s.number+=i,s.hasExponent=!0;else{if(s.inNumber&&!qr(s)){Br(s,!1),--r;continue}s.number+=i,s.inNumber=!0}else{if("0"===s.number||Jr(s)){s.inNumber=!0,s.number=i,Br(s,!0);continue}s.inNumber=!0,s.number+=i}else{if(s.pointSeen||s.hasExponent){Br(s,!1),--r;continue}s.inNumber=!0,s.pointSeen=!0,s.number+=i}return s.inNumber&&Br(s,!1),s.inSegment&&Qr(s)&&Wr(s),s.segments}(t)}size(t,n){const r=this.bbox();let i,s;for(r.width=0===r.width?1:r.width,r.height=0===r.height?1:r.height,i=this.length-1;i>=0;i--)s=this[i][0],"M"===s||"L"===s||"T"===s?(this[i][1]=(this[i][1]-r.x)*t/r.width+r.x,this[i][2]=(this[i][2]-r.y)*n/r.height+r.y):"H"===s?this[i][1]=(this[i][1]-r.x)*t/r.width+r.x:"V"===s?this[i][1]=(this[i][1]-r.y)*n/r.height+r.y:"C"===s||"S"===s||"Q"===s?(this[i][1]=(this[i][1]-r.x)*t/r.width+r.x,this[i][2]=(this[i][2]-r.y)*n/r.height+r.y,this[i][3]=(this[i][3]-r.x)*t/r.width+r.x,this[i][4]=(this[i][4]-r.y)*n/r.height+r.y,"C"===s&&(this[i][5]=(this[i][5]-r.x)*t/r.width+r.x,this[i][6]=(this[i][6]-r.y)*n/r.height+r.y)):"A"===s&&(this[i][1]=this[i][1]*t/r.width,this[i][2]=this[i][2]*n/r.height,this[i][6]=(this[i][6]-r.x)*t/r.width+r.x,this[i][7]=(this[i][7]-r.y)*n/r.height+r.y);return this}toString(){return function(t){let n="";for(let r=0,i=t.length;r<i;r++)n+=t[r][0],null!=t[r][1]&&(n+=t[r][1],null!=t[r][2]&&(n+=" ",n+=t[r][2],null!=t[r][3]&&(n+=" ",n+=t[r][3],n+=" ",n+=t[r][4],null!=t[r][5]&&(n+=" ",n+=t[r][5],n+=" ",n+=t[r][6],null!=t[r][7]&&(n+=" ",n+=t[r][7])))));return n+" "}(this)}};const Kr=t=>{const n=typeof t;return"number"===n?nr:"string"===n?Tn.isColor(t)?Tn:jn.test(t)?Sn.test(t)?Zr:tr:pn.test(t)?nr:ni:ei.indexOf(t.constructor)>-1?t.constructor:Array.isArray(t)?tr:"object"===n?si:ni};var ti=class{constructor(t){this._stepper=t||new $r("-"),this._from=null,this._to=null,this._type=null,this._context=null,this._morphObj=null}at(t){return this._morphObj.morph(this._from,this._to,t,this._stepper,this._context)}done(){return this._context.map(this._stepper.done).reduce((function(t,n){return t&&n}),!0)}from(t){return null==t?this._from:(this._from=this._set(t),this)}stepper(t){return null==t?this._stepper:(this._stepper=t,this)}to(t){return null==t?this._to:(this._to=this._set(t),this)}type(t){return null==t?this._type:(this._type=t,this)}_set(t){this._type||this.type(Kr(t));let n=new this._type(t);return this._type===Tn&&(n=this._to?n[this._to[4]]():this._from?n[this._from[4]]():n),this._type===si&&(n=this._to?n.align(this._to):this._from?n.align(this._from):n),n=n.toConsumable(),this._morphObj=this._morphObj||new this._type,this._context=this._context||Array.apply(null,Array(n.length)).map(Object).map((function(t){return t.done=!0,t})),n}},ni=class{constructor(...t){this.init(...t)}init(t){return t=Array.isArray(t)?t[0]:t,this.value=t,this}toArray(){return[this.value]}valueOf(){return this.value}},ri=class t{constructor(...t){this.init(...t)}init(n){return Array.isArray(n)&&(n={scaleX:n[0],scaleY:n[1],shear:n[2],rotate:n[3],translateX:n[4],translateY:n[5],originX:n[6],originY:n[7]}),Object.assign(this,t.defaults,n),this}toArray(){const t=this;return[t.scaleX,t.scaleY,t.shear,t.rotate,t.translateX,t.translateY,t.originX,t.originY]}};ri.defaults={scaleX:1,scaleY:1,shear:0,rotate:0,translateX:0,translateY:0,originX:0,originY:0};const ii=(t,n)=>t[0]<n[0]?-1:t[0]>n[0]?1:0;var si=class{constructor(...t){this.init(...t)}align(t){const n=this.values;for(let r=0,i=n.length;r<i;++r){if(n[r+1]===t[r+1]){if(n[r+1]===Tn&&t[r+7]!==n[r+7]){const n=t[r+7],i=new Tn(this.values.splice(r+3,5))[n]().toArray();this.values.splice(r+3,0,...i)}r+=n[r+2]+2;continue}if(!t[r+1])return this;const i=(new t[r+1]).toArray();n.splice(r,n[r+2]+3,t[r],t[r+1],t[r+2],...i),r+=n[r+2]+2}return this}init(t){if(this.values=[],Array.isArray(t))return void(this.values=t.slice());t=t||{};const n=[];for(const r in t){const i=Kr(t[r]),s=new i(t[r]).toArray();n.push([r,i,s.length,...s])}return n.sort(ii),this.values=n.reduce(((t,n)=>t.concat(n)),[]),this}toArray(){return this.values}valueOf(){const t={},n=this.values;for(;n.length;){const r=n.shift(),i=n.shift(),s=n.shift();t[r]=new i(n.splice(0,s))}return t}};const ei=[ni,ri,si];var hi=class extends cr{constructor(t,n=t){super(sn("path",t),n)}array(){return this._array||(this._array=new Zr(this.attr("d")))}clear(){return delete this._array,this}height(t){return null==t?this.bbox().height:this.size(this.bbox().width,t)}move(t,n){return this.attr("d",this.array().move(t,n))}plot(t){return null==t?this.array():this.clear().attr("d","string"==typeof t?t:this._array=new Zr(t))}size(t,n){const r=Ht(this,t,n);return this.attr("d",this.array().size(r.width,r.height))}width(t){return null==t?this.bbox().width:this.size(t,this.bbox().height)}x(t){return null==t?this.bbox().x:this.move(t,this.bbox().y)}y(t){return null==t?this.bbox().y:this.move(this.bbox().x,t)}};hi.prototype.MorphArray=Zr,M({Container:{path:fn((function(t){return this.put(new hi).plot(t||new Zr)}))}}),on(hi,"Path");var oi=v({array:()=>ui,clear:()=>ci,move:()=>ai,plot:()=>li,size:()=>fi});function ui(){return this._array||(this._array=new Or(this.attr("points")))}function ci(){return delete this._array,this}function ai(t,n){return this.attr("points",this.array().move(t,n))}function li(t){return null==t?this.array():this.clear().attr("points","string"==typeof t?t:this._array=new Or(t))}function fi(t,n){const r=Ht(this,t,n);return this.attr("points",this.array().size(r.width,r.height))}var pi=class extends cr{constructor(t,n=t){super(sn("polygon",t),n)}};M({Container:{polygon:fn((function(t){return this.put(new pi).plot(t||new Or)}))}}),ln(pi,kr),ln(pi,oi),on(pi,"Polygon");var di=class extends cr{constructor(t,n=t){super(sn("polyline",t),n)}};M({Container:{polyline:fn((function(t){return this.put(new di).plot(t||new Or)}))}}),ln(di,kr),ln(di,oi),on(di,"Polyline");var wi=class extends cr{constructor(t,n=t){super(sn("rect",t),n)}};ln(wi,{rx:lr,ry:fr}),M({Container:{rect:fn((function(t,n){return this.put(new wi).size(t,n)}))}}),on(wi,"Rect");var yi=class{constructor(){this._first=null,this._last=null}first(){return this._first&&this._first.value}last(){return this._last&&this._last.value}push(t){const n=void 0!==t.next?t:{value:t,next:null,prev:null};return this._last?(n.prev=this._last,this._last.next=n,this._last=n):(this._last=n,this._first=n),n}remove(t){t.prev&&(t.prev.next=t.next),t.next&&(t.next.prev=t.prev),t===this._last&&(this._last=t.prev),t===this._first&&(this._first=t.next),t.prev=null,t.next=null}shift(){const t=this._first;return t?(this._first=t.next,this._first&&(this._first.prev=null),this._last=this._first?this._last:null,t.value):null}};const mi={nextDraw:null,frames:new yi,timeouts:new yi,immediates:new yi,timer:()=>Ut.window.performance||Ut.window.Date,transforms:[],frame(t){const n=mi.frames.push({run:t});return null===mi.nextDraw&&(mi.nextDraw=Ut.window.requestAnimationFrame(mi._draw)),n},timeout(t,n){n=n||0;const r=mi.timer().now()+n,i=mi.timeouts.push({run:t,time:r});return null===mi.nextDraw&&(mi.nextDraw=Ut.window.requestAnimationFrame(mi._draw)),i},immediate(t){const n=mi.immediates.push(t);return null===mi.nextDraw&&(mi.nextDraw=Ut.window.requestAnimationFrame(mi._draw)),n},cancelFrame(t){null!=t&&mi.frames.remove(t)},clearTimeout(t){null!=t&&mi.timeouts.remove(t)},cancelImmediate(t){null!=t&&mi.immediates.remove(t)},_draw(t){try{let n=null;const r=mi.timeouts.last();for(;(n=mi.timeouts.shift())&&(t>=n.time?n.run():mi.timeouts.push(n),n!==r););let i=null;const s=mi.frames.last();for(;i!==s&&(i=mi.frames.shift());)i.run(t);let e=null;for(;e=mi.immediates.shift();)e()}finally{const t=mi.timeouts.first()||mi.frames.first()||mi.immediates.first();mi.nextDraw=t?Ut.window.requestAnimationFrame(mi._draw):null}}},vi=function(t){const n=t.start,r=t.runner.duration();return{start:n,duration:r,end:n+r,runner:t.runner}},bi=function(){const t=Ut.window;return(t.performance||t.Date).now()};var gi=class extends Un{constructor(t=bi){super(),this._timeSource=t,this.terminate()}active(){return!!this._nextFrame}finish(){return this.time(this.getEndTimeOfTimeline()+1),this.pause()}getEndTime(){const t=this.getLastRunnerInfo(),n=t?t.runner.duration():0;return(t?t.start:this._time)+n}getEndTimeOfTimeline(){const t=this._runners.map((t=>t.start+t.runner.duration()));return Math.max(0,...t)}getLastRunnerInfo(){return this.getRunnerInfoById(this._lastRunnerId)}getRunnerInfoById(t){return this._runners[this._runnerIds.indexOf(t)]||null}pause(){return this._paused=!0,this._continue()}persist(t){return null==t?this._persist:(this._persist=t,this)}play(){return this._paused=!1,this.updateTime()._continue()}reverse(t){const n=this.speed();if(null==t)return this.speed(-n);const r=Math.abs(n);return this.speed(t?-r:r)}schedule(t,n,r){if(null==t)return this._runners.map(vi);let i=0;const s=this.getEndTime();if(n=n||0,null==r||"last"===r||"after"===r)i=s;else if("absolute"===r||"start"===r)i=n,n=0;else if("now"===r)i=this._time;else if("relative"===r){const r=this.getRunnerInfoById(t.id);r&&(i=r.start+n,n=0)}else{if("with-last"!==r)throw new Error('Invalid value for the "when" parameter');{const t=this.getLastRunnerInfo();i=t?t.start:this._time}}t.unschedule(),t.timeline(this);const e=t.persist(),h={persist:null===e?this._persist:e,start:i+n,runner:t};return this._lastRunnerId=t.id,this._runners.push(h),this._runners.sort(((t,n)=>t.start-n.start)),this._runnerIds=this._runners.map((t=>t.runner.id)),this.updateTime()._continue(),this}seek(t){return this.time(this._time+t)}source(t){return null==t?this._timeSource:(this._timeSource=t,this)}speed(t){return null==t?this._speed:(this._speed=t,this)}stop(){return this.time(0),this.pause()}time(t){return null==t?this._time:(this._time=t,this._continue(!0))}unschedule(t){const n=this._runnerIds.indexOf(t.id);return n<0||(this._runners.splice(n,1),this._runnerIds.splice(n,1),t.timeline(null)),this}updateTime(){return this.active()||(this._lastSourceTime=this._timeSource()),this}_continue(t=!1){return mi.cancelFrame(this._nextFrame),this._nextFrame=null,t?this._stepImmediate():(this._paused||(this._nextFrame=mi.frame(this._step)),this)}_stepFn(t=!1){const n=this._timeSource();let r=n-this._lastSourceTime;t&&(r=0);const i=this._speed*r+(this._time-this._lastStepTime);this._lastSourceTime=n,t||(this._time+=i,this._time=this._time<0?0:this._time),this._lastStepTime=this._time,this.fire("time",this._time);for(let t=this._runners.length;t--;){const n=this._runners[t];this._time-n.start<=0&&n.runner.reset()}let s=!1;for(let t=0,n=this._runners.length;t<n;t++){const r=this._runners[t],e=r.runner;let h=i;const o=this._time-r.start;o<=0?s=!0:(o<h&&(h=o),e.active()&&(e.step(h).done?!0!==r.persist&&e.duration()-e.time()+this._time+r.persist<this._time&&(e.unschedule(),--t,--n):s=!0))}return s&&!(this._speed<0&&0===this._time)||this._runnerIds.length&&this._speed<0&&this._time>0?this._continue():(this.pause(),this.fire("finished")),this}terminate(){this._startTime=0,this._speed=1,this._persist=0,this._nextFrame=null,this._paused=!0,this._runners=[],this._runnerIds=[],this._lastRunnerId=-1,this._time=0,this._lastSourceTime=0,this._lastStepTime=0,this._step=this._stepFn.bind(this,!1),this._stepImmediate=this._stepFn.bind(this,!0)}};M({Element:{timeline:function(t){return null==t?(this._timeline=this._timeline||new gi,this._timeline):(this._timeline=t,this)}}});var xi=class t extends Un{constructor(n){super(),this.id=t.id++,n="function"==typeof(n=null==n?400:n)?new Rr(n):n,this._element=null,this._timeline=null,this.done=!1,this._queue=[],this._duration="number"==typeof n&&n,this._isDeclarative=n instanceof Rr,this._stepper=this._isDeclarative?n:new $r,this._history={},this.enabled=!0,this._time=0,this._lastTime=0,this._reseted=!0,this.transforms=new zn,this.transformId=1,this._haveReversed=!1,this._reverse=!1,this._loopsDone=0,this._swing=!1,this._wait=0,this._times=1,this._frameId=null,this._persist=!!this._isDeclarative||null}static sanitise(t,n,r){let i=1,s=!1,e=0;return n=n??0,r=r||"last","object"!=typeof(t=t??400)||t instanceof Ir||(n=t.delay??n,r=t.when??r,s=t.swing||s,i=t.times??i,e=t.wait??e,t=t.duration??400),{duration:t,delay:n,swing:s,times:i,wait:e,when:r}}active(t){return null==t?this.enabled:(this.enabled=t,this)}addTransform(t){return this.transforms.lmultiplyO(t),this}after(t){return this.on("finished",t)}animate(n,r,i){const s=t.sanitise(n,r,i),e=new t(s.duration);return this._timeline&&e.timeline(this._timeline),this._element&&e.element(this._element),e.loop(s).schedule(s.delay,s.when)}clearTransform(){return this.transforms=new zn,this}clearTransformsFromQueue(){var t;this.done&&this._timeline&&(0,$t.default)(t=this._timeline._runnerIds).call(t,this.id)||(this._queue=this._queue.filter((t=>!t.isTransform)))}delay(t){return this.animate(0,t)}duration(){return this._times*(this._wait+this._duration)-this._wait}during(t){return this.queue(null,t)}ease(t){return this._stepper=new $r(t),this}element(t){return null==t?this._element:(this._element=t,t._prepareRunner(),this)}finish(){return this.step(1/0)}loop(t,n,r){return"object"==typeof t&&(n=t.swing,r=t.wait,t=t.times),this._times=t||1/0,this._swing=n||!1,this._wait=r||0,!0===this._times&&(this._times=1/0),this}loops(t){const n=this._duration+this._wait;if(null==t){const t=Math.floor(this._time/n);return Math.min(t+(this._time-t*n)/this._duration,this._times)}const r=Math.floor(t);return this.time(n*r+this._duration*(t%1))}persist(t){return null==t?this._persist:(this._persist=t,this)}position(t){const n=this._time,r=this._duration,i=this._wait,s=this._swing,e=this._reverse;let h;if(null==t){const t=function(t){const n=s*Math.floor(t%(2*(i+r))/(i+r)),h=n&&!e||!n&&e,o=Math.pow(-1,h)*(t%(i+r))/r+h;return Math.max(Math.min(o,1),0)},o=this._times*(i+r)-i;return h=n<=0?Math.round(t(1e-5)):n<o?t(n):Math.round(t(o-1e-5)),h}const o=Math.floor(this.loops()),u=s&&o%2==0;return h=o+(u&&!e||e&&u?t:1-t),this.loops(h)}progress(t){return null==t?Math.min(1,this._time/this.duration()):this.time(t*this.duration())}queue(t,n,r,i){return this._queue.push({initialiser:t||Zn,runner:n||Zn,retarget:r,isTransform:i,initialised:!1,finished:!1}),this.timeline()&&this.timeline()._continue(),this}reset(){return this._reseted||(this.time(0),this._reseted=!0),this}reverse(t){return this._reverse=null==t?!this._reverse:t,this}schedule(t,n,r){if(t instanceof gi||(r=n,n=t,t=this.timeline()),!t)throw Error("Runner cannot be scheduled without timeline");return t.schedule(this,n,r),this}step(t){if(!this.enabled)return this;this._time+=t=null==t?16:t;const n=this.position(),r=this._lastPosition!==n&&this._time>=0;this._lastPosition=n;const i=this.duration(),s=this._lastTime<=0&&this._time>0,e=this._lastTime<i&&this._time>=i;this._lastTime=this._time,s&&this.fire("start",this);const h=this._isDeclarative;this.done=!h&&!e&&this._time>=i,this._reseted=!1;let o=!1;return(r||h)&&(this._initialise(r),this.transforms=new zn,o=this._run(h?t:n),this.fire("step",this)),this.done=this.done||o&&h,e&&this.fire("finished",this),this}time(t){return null==t?this._time:(this.step(t-this._time),this)}timeline(t){return void 0===t?this._timeline:(this._timeline=t,this)}unschedule(){const t=this.timeline();return t&&t.unschedule(this),this}_initialise(t){if(t||this._isDeclarative)for(let n=0,r=this._queue.length;n<r;++n){const r=this._queue[n],i=this._isDeclarative||!r.initialised&&t;t=!r.finished,i&&t&&(r.initialiser.call(this),r.initialised=!0)}}_rememberMorpher(t,n){if(this._history[t]={morpher:n,caller:this._queue[this._queue.length-1]},this._isDeclarative){const t=this.timeline();t&&t.play()}}_run(t){let n=!0;for(let r=0,i=this._queue.length;r<i;++r){const i=this._queue[r],s=i.runner.call(this,t);i.finished=i.finished||!0===s,n=n&&i.finished}return n}_tryRetarget(t,n,r){if(this._history[t]){if(!this._history[t].caller.initialised){const n=this._queue.indexOf(this._history[t].caller);return this._queue.splice(n,1),!1}this._history[t].caller.retarget?this._history[t].caller.retarget.call(this,n,r):this._history[t].morpher.to(n),this._history[t].caller.finished=!1;const i=this.timeline();return i&&i.play(),!0}return!1}};xi.id=0;var Mi=class{constructor(t=new zn,n=-1,r=!0){this.transforms=t,this.id=n,this.done=r}clearTransformsFromQueue(){}};ln([xi,Mi],{mergeWith(t){return new Mi(t.transforms.lmultiply(this.transforms),t.id)}});const _i=(t,n)=>t.lmultiplyO(n),ji=t=>t.transforms;function Si(){const t=this._transformationRunners.runners.map(ji).reduce(_i,new zn);this.transform(t),this._transformationRunners.merge(),1===this._transformationRunners.length()&&(this._frameId=null)}var Ai=class{constructor(){this.runners=[],this.ids=[]}add(t){var n;if((0,$t.default)(n=this.runners).call(n,t))return;const r=t.id+1;return this.runners.push(t),this.ids.push(r),this}clearBefore(t){const n=this.ids.indexOf(t+1)||1;return this.ids.splice(0,n,0),this.runners.splice(0,n,new Mi).forEach((t=>t.clearTransformsFromQueue())),this}edit(t,n){const r=this.ids.indexOf(t+1);return this.ids.splice(r,1,t+1),this.runners.splice(r,1,n),this}getByID(t){return this.runners[this.ids.indexOf(t+1)]}length(){return this.ids.length}merge(){let t=null;for(let i=0;i<this.runners.length;++i){var n,r;const s=this.runners[i];if(!(t&&s.done&&t.done)||s._timeline&&(0,$t.default)(n=s._timeline._runnerIds).call(n,s.id)||t._timeline&&(0,$t.default)(r=t._timeline._runnerIds).call(r,t.id))t=s;else{this.remove(s.id);const n=s.mergeWith(t);this.edit(t.id,n),t=n,--i}}return this}remove(t){const n=this.ids.indexOf(t+1);return this.ids.splice(n,1),this.runners.splice(n,1),this}};M({Element:{animate(t,n,r){const i=xi.sanitise(t,n,r),s=this.timeline();return new xi(i.duration).loop(i).element(this).timeline(s.play()).schedule(i.delay,i.when)},delay(t,n){return this.animate(0,t,n)},_clearTransformRunnersBefore(t){this._transformationRunners.clearBefore(t.id)},_currentTransform(t){return this._transformationRunners.runners.filter((n=>n.id<=t.id)).map(ji).reduce(_i,new zn)},_addRunner(t){this._transformationRunners.add(t),mi.cancelImmediate(this._frameId),this._frameId=mi.immediate(Si.bind(this))},_prepareRunner(){null==this._frameId&&(this._transformationRunners=(new Ai).add(new Mi(new zn(this))))}}}),ln(xi,{attr(t,n){return this.styleAttr("attr",t,n)},css(t,n){return this.styleAttr("css",t,n)},styleAttr(t,n,r){if("string"==typeof n)return this.styleAttr(t,{[n]:r});const i=n,s=this._history[t];if(s&&!s.caller.initialised&&s.caller.retarget)return s.caller.retarget.call(this,i),this;if(this._tryRetarget(t,i))return this;let e=new ti(this._stepper).to(i),h=Object.keys(i);return this.queue((function(){e=e.from(this.element()[t](h))}),(function(n){return this.element()[t](e.at(n).valueOf()),e.done()}),(function(n){const r=(i=Object.keys(n),s=h,i.filter((t=>!(0,$t.default)(s).call(s,t))));var i,s;if(r.length&&null!=e.from()){const n=this.element()[t](r),i=new si(e.from()).valueOf();Object.assign(i,n),e.from(i)}const o=new si(e.to()).valueOf();Object.assign(o,n),e.to(o),h=Object.keys(o)})),this._rememberMorpher(t,e),this},zoom(t,n){if(this._tryRetarget("zoom",t,n))return this;let r=new ti(this._stepper).to(new nr(t));return this.queue((function(){r=r.from(this.element().zoom())}),(function(t){return this.element().zoom(r.at(t),n),r.done()}),(function(t,i){n=i,r.to(t)})),this._rememberMorpher("zoom",r),this},transform(t,n,r){if(n=t.relative||n,this._isDeclarative&&!n&&this._tryRetarget("transform",t))return this;const i=zn.isMatrixLike(t);r=null!=t.affine?t.affine:null!=r?r:!i;const s=new ti(this._stepper).type(r?ri:zn);let e,h,o,u,c;return this.queue((function(){h=h||this.element(),e=e||Qt(t,h),c=new zn(n?void 0:h),h._addRunner(this),n||h._clearTransformRunnersBefore(this)}),(function(a){n||this.clearTransform();const{x:l,y:f}=new Cn(e).transform(h._currentTransform(this)),p={...t,origin:[l,f]};!0===p.relative&&delete p.relative;let d=new zn(p),w=this._isDeclarative&&o?o:c;if(r){d=d.decompose(l,f),w=w.decompose(l,f);const t=d.rotate,n=w.rotate,r=[t-360,t,t+360],i=r.map((t=>Math.abs(t-n))),s=Math.min(...i),e=i.indexOf(s);d.rotate=r[e]}n&&(i||(d.rotate=t.rotate||0),this._isDeclarative&&u&&(w.rotate=u)),s.from(w),s.to(d);const y=s.at(a);return u=y.rotate,o=new zn(y),this.addTransform(o),h._addRunner(this),s.done()}),(function(n){(n.origin||"center").toString()!==(t.origin||"center").toString()&&(e=Qt(n,h)),t={...n,origin:e}}),!0),this._isDeclarative&&this._rememberMorpher("transform",s),this},x(t){return this._queueNumber("x",t)},y(t){return this._queueNumber("y",t)},ax(t){return this._queueNumber("ax",t)},ay(t){return this._queueNumber("ay",t)},dx(t=0){return this._queueNumberDelta("x",t)},dy(t=0){return this._queueNumberDelta("y",t)},dmove(t,n){return this.dx(t).dy(n)},_queueNumberDelta(t,n){if(n=new nr(n),this._tryRetarget(t,n))return this;const r=new ti(this._stepper).to(n);let i=null;return this.queue((function(){i=this.element()[t](),r.from(i),r.to(i+n)}),(function(n){return this.element()[t](r.at(n)),r.done()}),(function(t){r.to(i+new nr(t))})),this._rememberMorpher(t,r),this},_queueObject(t,n){if(this._tryRetarget(t,n))return this;const r=new ti(this._stepper).to(n);return this.queue((function(){r.from(this.element()[t]())}),(function(n){return this.element()[t](r.at(n)),r.done()})),this._rememberMorpher(t,r),this},_queueNumber(t,n){return this._queueObject(t,new nr(n))},cx(t){return this._queueNumber("cx",t)},cy(t){return this._queueNumber("cy",t)},move(t,n){return this.x(t).y(n)},amove(t,n){return this.ax(t).ay(n)},center(t,n){return this.cx(t).cy(n)},size(t,n){const r=Ht(this._element,t,n);return this.width(r.width).height(r.height)},width(t){return this._queueNumber("width",t)},height(t){return this._queueNumber("height",t)},plot(t,n,r,i){if(4===arguments.length)return this.plot([t,n,r,i]);if(this._tryRetarget("plot",t))return this;const s=new ti(this._stepper).type(this._element.MorphArray).to(t);return this.queue((function(){s.from(this._element.array())}),(function(t){return this._element.plot(s.at(t)),s.done()})),this._rememberMorpher("plot",s),this},leading(t){return this._queueNumber("leading",t)},viewbox(t,n,r,i){return this._queueObject("viewbox",new Yn(t,n,r,i))},update(t){return"object"!=typeof t?this.update({offset:arguments[0],color:arguments[1],opacity:arguments[2]}):(null!=t.opacity&&this.attr("stop-opacity",t.opacity),null!=t.color&&this.attr("stop-color",t.color),null!=t.offset&&this.attr("offset",t.offset),this)}}),ln(xi,{rx:lr,ry:fr,from:Mr,to:_r}),on(xi,"Runner");var Oi=class extends or{constructor(t,n=t){super(sn("svg",t),n),this.namespace()}defs(){return this.isRoot()?en(this.node.querySelector("defs"))||this.put(new ur):this.root().defs()}isRoot(){return!this.node.parentNode||!(this.node.parentNode instanceof Ut.window.SVGElement)&&"#document-fragment"!==this.node.parentNode.nodeName}namespace(){return this.isRoot()?this.attr({xmlns:Wt,version:"1.1"}).attr("xmlns:xlink",qt,Jt):this.root().namespace()}removeNamespace(){return this.attr({xmlns:null,version:null}).attr("xmlns:xlink",null,Jt).attr("xmlns:svgjs",null,Jt)}root(){return this.isRoot()?this:super.root()}};M({Container:{nested:fn((function(){return this.put(new Oi)}))}}),on(Oi,"Svg",!0);var ki=class extends or{constructor(t,n=t){super(sn("symbol",t),n)}};M({Container:{symbol:fn((function(){return this.put(new ki)}))}}),on(ki,"Symbol");var Ei=v({amove:()=>Ri,ax:()=>Ii,ay:()=>$i,build:()=>Gi,center:()=>Pi,cx:()=>Ni,cy:()=>Yi,length:()=>Ci,move:()=>Fi,plain:()=>Ti,x:()=>Di,y:()=>zi});function Ti(t){return!1===this._build&&this.clear(),this.node.appendChild(Ut.document.createTextNode(t)),this}function Ci(){return this.node.getComputedTextLength()}function Di(t,n=this.bbox()){return null==t?n.x:this.attr("x",this.attr("x")+t-n.x)}function zi(t,n=this.bbox()){return null==t?n.y:this.attr("y",this.attr("y")+t-n.y)}function Fi(t,n,r=this.bbox()){return this.x(t,r).y(n,r)}function Ni(t,n=this.bbox()){return null==t?n.cx:this.attr("x",this.attr("x")+t-n.cx)}function Yi(t,n=this.bbox()){return null==t?n.cy:this.attr("y",this.attr("y")+t-n.cy)}function Pi(t,n,r=this.bbox()){return this.cx(t,r).cy(n,r)}function Ii(t){return this.attr("x",t)}function $i(t){return this.attr("y",t)}function Ri(t,n){return this.ax(t).ay(n)}function Gi(t){return this._build=!!t,this}var Li=class extends cr{constructor(t,n=t){super(sn("text",t),n),this.dom.leading=this.dom.leading??new nr(1.3),this._rebuild=!0,this._build=!1}leading(t){return null==t?this.dom.leading:(this.dom.leading=new nr(t),this.rebuild())}rebuild(t){if("boolean"==typeof t&&(this._rebuild=t),this._rebuild){const t=this;let n=0;const r=this.dom.leading;this.each((function(i){if(Bt(this.node))return;const s=Ut.window.getComputedStyle(this.node).getPropertyValue("font-size"),e=r*new nr(s);this.dom.newLined&&(this.attr("x",t.attr("x")),"\n"===this.text()?n+=e:(this.attr("dy",i?e+n:0),n=0))})),this.fire("rebuild")}return this}setData(t){return this.dom=t,this.dom.leading=new nr(t.leading||1.3),this}writeDataToDom(){return super.writeDataToDom({leading:1.3})}text(t){if(void 0===t){const n=this.node.childNodes;let r=0;t="";for(let i=0,s=n.length;i<s;++i)"textPath"===n[i].nodeName||Bt(n[i])?0===i&&(r=i+1):(i!==r&&3!==n[i].nodeType&&!0===en(n[i]).dom.newLined&&(t+="\n"),t+=n[i].textContent);return t}if(this.clear().build(!0),"function"==typeof t)t.call(this,this);else for(let n=0,r=(t=(t+"").split("\n")).length;n<r;n++)this.newLine(t[n]);return this.build(!1).rebuild()}};ln(Li,Ei),M({Container:{text:fn((function(t=""){return this.put(new Li).text(t)})),plain:fn((function(t=""){return this.put(new Li).plain(t)}))}}),on(Li,"Text");var Xi=class extends cr{constructor(t,n=t){super(sn("tspan",t),n),this._build=!1}dx(t){return this.attr("dx",t)}dy(t){return this.attr("dy",t)}newLine(){this.dom.newLined=!0;const t=this.parent();if(!(t instanceof Li))return this;const n=t.index(this),r=Ut.window.getComputedStyle(this.node).getPropertyValue("font-size"),i=t.dom.leading*new nr(r);return this.dy(n?i:0).attr("x",t.x())}text(t){return null==t?this.node.textContent+(this.dom.newLined?"\n":""):("function"==typeof t?(this.clear().build(!0),t.call(this,this),this.build(!1)):this.plain(t),this)}};ln(Xi,Ei),M({Tspan:{tspan:fn((function(t=""){const n=new Xi;return this._build||this.clear(),this.put(n).text(t)}))},Text:{newLine:function(t=""){return this.tspan(t).newLine()}}}),on(Xi,"Tspan");var Hi=class extends cr{constructor(t,n=t){super(sn("circle",t),n)}radius(t){return this.attr("r",t)}rx(t){return this.attr("r",t)}ry(t){return this.rx(t)}size(t){return this.radius(new nr(t).divide(2))}};ln(Hi,{x:pr,y:dr,cx:wr,cy:yr,width:mr,height:vr}),M({Container:{circle:fn((function(t=0){return this.put(new Hi).size(t).move(0,0)}))}}),on(Hi,"Circle");var Qi=class extends or{constructor(t,n=t){super(sn("clipPath",t),n)}remove(){return this.targets().forEach((function(t){t.unclip()})),super.remove()}targets(){return Ln(this.node,"clip-path")}};M({Container:{clip:fn((function(){return this.defs().put(new Qi)}))},Element:{clipper(){return this.reference("clip-path")},clipWith(t){const n=t instanceof Qi?t:this.parent().clip().add(t);return this.attr("clip-path","url(#"+n.id()+")")},unclip(){return this.attr("clip-path",null)}}}),on(Qi,"ClipPath");var Vi=class extends er{constructor(t,n=t){super(sn("foreignObject",t),n)}};M({Container:{foreignObject:fn((function(t,n){return this.put(new Vi).size(t,n)}))}}),on(Vi,"ForeignObject");var Bi=v({dmove:()=>Wi,dx:()=>Ji,dy:()=>qi,height:()=>Ui,move:()=>Zi,size:()=>Ki,width:()=>ts,x:()=>ns,y:()=>rs});function Wi(t,n){return this.children().forEach((r=>{let i;try{i=r.node instanceof Ut.window.SVGSVGElement?new Yn(r.attr(["x","y","width","height"])):r.bbox()}catch(t){return}const s=new zn(r),e=s.translate(t,n).transform(s.inverse()),h=new Cn(i.x,i.y).transform(e);r.dmove(h.x-i.x,h.y-i.y)})),this}function Ji(t){return this.dmove(t,0)}function qi(t){return this.dmove(0,t)}function Ui(t,n=this.bbox()){return null==t?n.height:this.size(n.width,t,n)}function Zi(t=0,n=0,r=this.bbox()){return this.dmove(t-r.x,n-r.y)}function Ki(t,n,r=this.bbox()){const i=Ht(this,t,n,r),s=i.width/r.width,e=i.height/r.height;return this.children().forEach((t=>{const n=new Cn(r).transform(new zn(t).inverse());t.scale(s,e,n.x,n.y)})),this}function ts(t,n=this.bbox()){return null==t?n.width:this.size(t,n.height,n)}function ns(t,n=this.bbox()){return null==t?n.x:this.move(t,n.y,n)}function rs(t,n=this.bbox()){return null==t?n.y:this.move(n.x,t,n)}var is=class extends or{constructor(t,n=t){super(sn("g",t),n)}};ln(is,Bi),M({Container:{group:fn((function(){return this.put(new is)}))}}),on(is,"G");var ss=class extends or{constructor(t,n=t){super(sn("a",t),n)}target(t){return this.attr("target",t)}to(t){return this.attr("href",t,qt)}};ln(ss,Bi),M({Container:{link:fn((function(t){return this.put(new ss).to(t)}))},Element:{unlink(){const t=this.linker();if(!t)return this;const n=t.parent();if(!n)return this.remove();const r=n.index(t);return n.add(this,r),t.remove(),this},linkTo(t){let n=this.linker();return n||(n=new ss,this.wrap(n)),"function"==typeof t?t.call(n,n):n.to(t),this},linker(){const t=this.parent();return t&&"a"===t.node.nodeName.toLowerCase()?t:null}}}),on(ss,"A");var es=class extends or{constructor(t,n=t){super(sn("mask",t),n)}remove(){return this.targets().forEach((function(t){t.unmask()})),super.remove()}targets(){return Ln(this.node,"mask")}};M({Container:{mask:fn((function(){return this.defs().put(new es)}))},Element:{masker(){return this.reference("mask")},maskWith(t){const n=t instanceof es?t:this.parent().mask().add(t);return this.attr("mask","url(#"+n.id()+")")},unmask(){return this.attr("mask",null)}}}),on(es,"Mask");var hs=class extends er{constructor(t,n=t){super(sn("stop",t),n)}update(t){return("number"==typeof t||t instanceof nr)&&(t={offset:arguments[0],color:arguments[1],opacity:arguments[2]}),null!=t.opacity&&this.attr("stop-opacity",t.opacity),null!=t.color&&this.attr("stop-color",t.color),null!=t.offset&&this.attr("offset",new nr(t.offset)),this}};M({Gradient:{stop:function(t,n,r){return this.put(new hs).update(t,n,r)}}}),on(hs,"Stop");var os=class extends er{constructor(t,n=t){super(sn("style",t),n)}addText(t=""){return this.node.textContent+=t,this}font(t,n,r={}){return this.rule("@font-face",{fontFamily:t,src:n,...r})}rule(t,n){return this.addText(function(t,n){if(!t)return"";if(!n)return t;let r=t+"{";for(const t in n)r+=Lt(t)+":"+n[t]+";";return r+="}",r}(t,n))}};M("Dom",{style(t,n){return this.put(new os).rule(t,n)},fontface(t,n,r){return this.put(new os).font(t,n,r)}}),on(os,"Style");var us=class extends Li{constructor(t,n=t){super(sn("textPath",t),n)}array(){const t=this.track();return t?t.array():null}plot(t){const n=this.track();let r=null;return n&&(r=n.plot(t)),null==t?r:this}track(){return this.reference("href")}};M({Container:{textPath:fn((function(t,n){return t instanceof Li||(t=this.text(t)),t.path(n)}))},Text:{path:fn((function(t,n=!0){const r=new us;let i;if(t instanceof hi||(t=this.defs().path(t)),r.attr("href","#"+t,qt),n)for(;i=this.node.firstChild;)r.node.appendChild(i);return this.put(r)})),textPath(){return this.findOne("textPath")}},Path:{text:fn((function(t){return t instanceof Li||(t=(new Li).addTo(this.parent()).text(t)),t.path(this)})),targets(){return Ln(this.node,"href","textPath")}}}),us.prototype.MorphArray=Zr,on(us,"TextPath");var cs=class extends cr{constructor(t,n=t){super(sn("use",t),n)}use(t,n){return this.attr("href",(n||"")+"#"+t,qt)}};M({Container:{use:fn((function(t,n){return this.put(new cs).use(t,n)}))}}),on(cs,"Use"),ln([Oi,ki,Ar,Sr,Nr],_("viewbox")),ln([Fr,di,pi,hi],_("marker")),ln(Li,_("Text")),ln(hi,_("Path")),ln(ur,_("Defs")),ln([Li,Xi],_("Tspan")),ln([wi,br,jr,xi],_("radius")),ln(Un,_("EventTarget")),ln(sr,_("Dom")),ln(er,_("Element")),ln(cr,_("Shape")),ln([or,gr],_("Container")),ln(jr,_("Gradient")),ln(xi,_("Runner")),In.extend([...new Set(x)]),function(t=[]){ei.push(...[].concat(t))}([nr,Tn,Yn,zn,tr,Or,Zr,Cn]),ln(ei,{to(t){return(new ti).type(this.constructor).from(this.toArray()).to(t)},fromArray(t){return this.init(t),this},toConsumable(){return this.toArray()},morph(t,n,r,i,s){return this.fromArray(t.map((function(t,e){return i.step(t,n[e],r,s[e],s)})))}});class as{constructor(t){this._dateFormat={year:"YYYY",quarter:"Q[Q] YYYY",month:"MMM YYYY",locale:"[KW]WW YYYY",day:"DD.MM.YYYY"},this._dateLinkFormat={avg:"Ø[DATE]",interval:"[DATE]..[DATE]",start:".[DATE]",end:"[DATE].",ytd:"_[DATE]",ytg:"[DATE]_",cum:"[DATE]_[DATE]",mat:"~[DATE]",none:"[DATE]"},this._scenarioMap=new Map;const i=r([n,null!=t?t:{}]);Object.entries(i.scenarios).forEach((([t,n])=>{var r,i,s;this.createScenarioMapEntry(t,null!==(r=n.name)&&void 0!==r?r:t,null!==(i=n.colorIndex)&&void 0!==i?i:10,null!==(s=n.sortIndex)&&void 0!==s?s:0)})),this._fallBackScenario=i.fallback}createScenarioMapEntry(t,n,r,i){const s=n,e=r;[1,2,3,4].forEach((r=>{this._scenarioMap.set(t+r,{name:n+r,group:s,colorIndex:e,sortIndex:i+10*r})}))}getScenario(t){return this._scenarioMap.has(t)?this._scenarioMap.get(t):this._fallBackScenario}getScenarioGroup(t){return this._scenarioMap.has(t)?this._scenarioMap.get(t).name:this._fallBackScenario.name}getScenarioColorIndex(t){return this._scenarioMap.has(t)?this._scenarioMap.get(t).colorIndex:this._fallBackScenario.colorIndex}getScenarioSorIndex(t){const n=this.normalizeVarianceScenario(t);return this._scenarioMap.has(n)?this._scenarioMap.get(n).sortIndex:this._fallBackScenario.sortIndex}normalizeVarianceScenario(t){if(null==t)return"";const n=new s(t);return n.isValid?n.type+n.delta:t}}class ls{constructor(){this.font="16px Arial",this.family="Arial",this.size=16,this.color="#000000",this.background="#ffffff",this.leading=1.8}}class fs{adapt(t){const n=new ls;return i.isString(t.font)&&(n.font=t.font),i.isString(t.family)&&(n.family=t.family),i.isNumber(t.size)&&(n.size=t.size),i.isString(t.color)&&(n.color=t.color),i.isString(t.background)&&(n.background=t.background),i.isNumber(t.leading)&&(n.leading=t.leading),n}default(){return new ls}}class ps{constructor(t,n,r,i){this.ac=t,this.fc=n,this.pp=r,this.pl=i}getSVGStyle(t){return"ac"===t?this.ac:"fc"===t?this.fc:"pp"===t?this.pp:"pl"===t?this.pl:this.ac}}class ds{constructor(t){this.svgStyleAdapter=t}adapt(t){const n=new ps(this.svgStyleAdapter.defaultAC(),this.svgStyleAdapter.defaultFC(),this.svgStyleAdapter.defaultPP(),this.svgStyleAdapter.defaultPL());return i.isExisting(t.ac)&&(n.ac=this.svgStyleAdapter.adapt(t.ac)),i.isExisting(t.fc)&&(n.fc=this.svgStyleAdapter.adapt(t.fc)),i.isExisting(t.pp)&&(n.pp=this.svgStyleAdapter.adapt(t.pp)),i.isExisting(t.pl)&&(n.pl=this.svgStyleAdapter.adapt(t.pl)),n}default(){return new ps(this.svgStyleAdapter.defaultAC(),this.svgStyleAdapter.defaultFC(),this.svgStyleAdapter.defaultPP(),this.svgStyleAdapter.defaultPL())}}class ws{constructor(){this.top=10,this.left=10,this.right=10,this.bottom=10}}class ys{adapt(t){const n=new ws;return i.isNumber(t.top)&&(n.top=t.top),i.isNumber(t.left)&&(n.left=t.left),i.isNumber(t.right)&&(n.right=t.right),i.isNumber(t.bottom)&&(n.bottom=t.bottom),n}default(){return new ws}}class ms{constructor(t="#000000",n="#000000",r=.1){this.stroke=t,this.fill=n,this.width=r}}class vs{adapt(t){const n=new ms(t.stroke,t.fill,t.width);return i.isString(t.fillpattern)&&(n.fillpattern=t.fillpattern),i.isString(t.dasharray)&&(n.dasharray=t.dasharray),n}default(){return new ms("#000000","#000000",.3)}defaultAC(){return new ms("#000000","#000000",.3)}defaultFC(){const t=new ms("#000000","#000000",.3);return t.dasharray="10 5 5 5",t.fillpattern="fc",t}defaultPP(){return new ms("#999999","#999999",.3)}defaultPL(){return new ms("#000000","#ffffff",.3)}defaultPos(){return new ms("#00ff00","#00ff00",.3)}defaultNeg(){return new ms("#ff0000","#ff0000",.3)}defaultNeu(){return new ms("#999999","#999999",.3)}}export{c as C,a as F,as as I,ys as P,e as Q,Oi as S,s as V,fs as a,ds as b,vs as c}