@antv/infographic 0.2.10 → 0.2.11
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.
- package/README.md +2 -2
- package/README.zh-CN.md +2 -2
- package/dist/infographic.min.js +205 -176
- package/dist/infographic.min.js.map +1 -1
- package/esm/constants/index.js +4 -4
- package/esm/designs/components/Btn.js +2 -2
- package/esm/designs/components/BtnsGroup.js +2 -2
- package/esm/designs/components/Gap.js +1 -1
- package/esm/designs/components/Illus.js +2 -2
- package/esm/designs/components/ItemDesc.js +2 -2
- package/esm/designs/components/ItemIcon.js +2 -2
- package/esm/designs/components/ItemLabel.js +2 -2
- package/esm/designs/components/ItemValue.js +2 -2
- package/esm/designs/components/ItemsGroup.js +2 -2
- package/esm/designs/components/ShapesGroup.js +2 -2
- package/esm/designs/components/Title.js +3 -3
- package/esm/designs/components/index.js +11 -11
- package/esm/designs/decorations/index.js +3 -3
- package/esm/designs/decorations/simple-arrow.js +2 -2
- package/esm/designs/decorations/text-3d.js +2 -2
- package/esm/designs/decorations/triangle.js +2 -2
- package/esm/designs/defs/DropShadow.js +1 -1
- package/esm/designs/defs/LinearGradient.js +1 -1
- package/esm/designs/defs/index.js +2 -2
- package/esm/designs/index.js +5 -5
- package/esm/designs/items/BadgeCard.js +6 -6
- package/esm/designs/items/CandyCardLite.js +5 -5
- package/esm/designs/items/CapsuleItem.js +6 -6
- package/esm/designs/items/CircleNode.js +5 -5
- package/esm/designs/items/CircularProgress.js +5 -5
- package/esm/designs/items/CompactCard.js +6 -6
- package/esm/designs/items/DoneList.js +5 -5
- package/esm/designs/items/HorizontalIconArrow.js +6 -6
- package/esm/designs/items/HorizontalIconLine.js +6 -6
- package/esm/designs/items/IconBadge.js +5 -5
- package/esm/designs/items/IndexedCard.js +6 -6
- package/esm/designs/items/LCornerCard.js +5 -5
- package/esm/designs/items/LetterCard.js +5 -5
- package/esm/designs/items/LinedText.js +5 -5
- package/esm/designs/items/PillBadge.js +6 -6
- package/esm/designs/items/PlainText.js +4 -4
- package/esm/designs/items/ProgressCard.js +5 -5
- package/esm/designs/items/QuarterCircular.js +5 -5
- package/esm/designs/items/QuarterSimpleCard.js +5 -5
- package/esm/designs/items/RibbonCard.js +5 -5
- package/esm/designs/items/RoundedRectNode.js +5 -5
- package/esm/designs/items/SimpleCircleNode.js +4 -4
- package/esm/designs/items/SimpleHorizontalArrow.js +7 -7
- package/esm/designs/items/SimpleIllusItem.js +6 -6
- package/esm/designs/items/SimpleItem.js +6 -6
- package/esm/designs/items/SimpleVerticalArrow.js +7 -7
- package/esm/designs/items/UnderlineText.js +5 -5
- package/esm/designs/items/VerticalIconArrow.js +7 -7
- package/esm/designs/items/index.js +30 -30
- package/esm/designs/layouts/Align.js +2 -2
- package/esm/designs/layouts/Flex.js +2 -2
- package/esm/designs/layouts/index.js +2 -2
- package/esm/designs/structures/chart-bar.js +7 -7
- package/esm/designs/structures/chart-column.js +7 -7
- package/esm/designs/structures/chart-line.js +7 -7
- package/esm/designs/structures/chart-pie.js +6 -6
- package/esm/designs/structures/chart-wordcloud.js +6 -6
- package/esm/designs/structures/compare-binary-horizontal/dividers/index.js +4 -4
- package/esm/designs/structures/compare-binary-horizontal/dividers/pros-cons-arrow.js +4 -4
- package/esm/designs/structures/compare-binary-horizontal/dividers/pros-cons-fold.js +4 -4
- package/esm/designs/structures/compare-binary-horizontal/dividers/vs.js +4 -4
- package/esm/designs/structures/compare-binary-horizontal/index.js +8 -8
- package/esm/designs/structures/compare-hierarchy-left-right.js +7 -7
- package/esm/designs/structures/compare-hierarchy-row.js +6 -6
- package/esm/designs/structures/compare-quadrant.js +5 -5
- package/esm/designs/structures/hierarchy-mindmap.js +6 -6
- package/esm/designs/structures/hierarchy-structure.js +6 -6
- package/esm/designs/structures/hierarchy-tree.js +6 -6
- package/esm/designs/structures/index.js +42 -42
- package/esm/designs/structures/list-column.js +5 -5
- package/esm/designs/structures/list-grid.js +5 -5
- package/esm/designs/structures/list-pyramid.js +5 -5
- package/esm/designs/structures/list-row.js +5 -5
- package/esm/designs/structures/list-sector.js +5 -5
- package/esm/designs/structures/list-waterfall.js +5 -5
- package/esm/designs/structures/list-zigzag.js +6 -6
- package/esm/designs/structures/relation-circle.js +5 -5
- package/esm/designs/structures/relation-dagre-flow.js +6 -6
- package/esm/designs/structures/relation-network.js +6 -6
- package/esm/designs/structures/sequence-ascending-stairs-3d.js +7 -7
- package/esm/designs/structures/sequence-ascending-steps.js +5 -5
- package/esm/designs/structures/sequence-circle-arrows.js +6 -6
- package/esm/designs/structures/sequence-circular.js +6 -6
- package/esm/designs/structures/sequence-color-snake-steps.js +6 -6
- package/esm/designs/structures/sequence-cylinders-3d.js +6 -6
- package/esm/designs/structures/sequence-filter-mesh.js +6 -6
- package/esm/designs/structures/sequence-funnel.js +6 -6
- package/esm/designs/structures/sequence-horizontal-zigzag.js +6 -6
- package/esm/designs/structures/sequence-mountain.js +6 -6
- package/esm/designs/structures/sequence-pyramid.js +6 -6
- package/esm/designs/structures/sequence-roadmap-vertical.js +7 -7
- package/esm/designs/structures/sequence-snake-steps.js +7 -7
- package/esm/designs/structures/sequence-stairs-front.js +6 -6
- package/esm/designs/structures/sequence-steps.js +7 -7
- package/esm/designs/structures/sequence-timeline.js +6 -6
- package/esm/designs/structures/sequence-zigzag-pucks-3d.js +6 -6
- package/esm/designs/structures/sequence-zigzag-steps.js +6 -6
- package/esm/designs/utils/color.js +3 -3
- package/esm/designs/utils/index.js +3 -3
- package/esm/editor/commands/UpdateElement.js +1 -1
- package/esm/editor/commands/UpdateText.js +2 -2
- package/esm/editor/commands/index.js +4 -4
- package/esm/editor/editor.js +1 -1
- package/esm/editor/index.js +3 -3
- package/esm/editor/interactions/brush-select.js +3 -3
- package/esm/editor/interactions/click-select.js +3 -3
- package/esm/editor/interactions/dblclick-edit-text.js +4 -4
- package/esm/editor/interactions/drag-element.js +5 -5
- package/esm/editor/interactions/hotkey-history.js +2 -2
- package/esm/editor/interactions/index.js +8 -8
- package/esm/editor/interactions/select-highlight.js +4 -4
- package/esm/editor/interactions/zoom-wheel.js +3 -3
- package/esm/editor/managers/command.js +1 -1
- package/esm/editor/managers/index.js +4 -4
- package/esm/editor/managers/interaction.js +2 -2
- package/esm/editor/managers/plugin.js +1 -1
- package/esm/editor/managers/state.js +2 -2
- package/esm/editor/plugins/edit-bar/components/button.js +1 -1
- package/esm/editor/plugins/edit-bar/components/color-picker.js +1 -1
- package/esm/editor/plugins/edit-bar/components/index.js +5 -5
- package/esm/editor/plugins/edit-bar/components/popover.js +2 -2
- package/esm/editor/plugins/edit-bar/components/select.js +1 -1
- package/esm/editor/plugins/edit-bar/edit-bar.js +5 -5
- package/esm/editor/plugins/edit-bar/edit-items/align-elements.js +5 -5
- package/esm/editor/plugins/edit-bar/edit-items/font-align.js +3 -3
- package/esm/editor/plugins/edit-bar/edit-items/font-color.js +3 -3
- package/esm/editor/plugins/edit-bar/edit-items/font-family.js +4 -4
- package/esm/editor/plugins/edit-bar/edit-items/font-size.js +3 -3
- package/esm/editor/plugins/edit-bar/edit-items/icon-color.js +3 -3
- package/esm/editor/plugins/edit-bar/edit-items/index.js +6 -6
- package/esm/editor/plugins/edit-bar/index.js +2 -2
- package/esm/editor/plugins/index.js +3 -3
- package/esm/editor/plugins/resize-element.js +4 -4
- package/esm/editor/utils/data.js +1 -1
- package/esm/editor/utils/element.js +1 -1
- package/esm/editor/utils/event.js +1 -1
- package/esm/editor/utils/index.js +7 -7
- package/esm/exporter/font.d.ts +0 -13
- package/esm/exporter/font.js +20 -28
- package/esm/exporter/index.js +2 -2
- package/esm/exporter/png.js +2 -2
- package/esm/exporter/svg.js +2 -2
- package/esm/index.js +14 -14
- package/esm/jsx/components/Text.js +1 -1
- package/esm/jsx/components/index.js +7 -7
- package/esm/jsx/index.js +6 -6
- package/esm/jsx/layout.js +1 -1
- package/esm/jsx/renderer.js +4 -4
- package/esm/jsx/utils/bounds.js +4 -4
- package/esm/jsx/utils/children.js +1 -1
- package/esm/jsx/utils/element.js +2 -2
- package/esm/jsx/utils/index.js +10 -10
- package/esm/jsx/utils/is-fragment.js +1 -1
- package/esm/jsx-dev-runtime.js +1 -1
- package/esm/jsx-runtime.js +1 -1
- package/esm/options/index.js +1 -1
- package/esm/options/parser.js +4 -4
- package/esm/package.json +1 -0
- package/esm/renderer/composites/background.js +1 -1
- package/esm/renderer/composites/base.js +2 -2
- package/esm/renderer/composites/button.js +1 -1
- package/esm/renderer/composites/icon.js +3 -3
- package/esm/renderer/composites/illus.js +2 -2
- package/esm/renderer/composites/index.js +8 -8
- package/esm/renderer/composites/shape.js +3 -3
- package/esm/renderer/composites/svg.js +1 -1
- package/esm/renderer/composites/text.js +2 -2
- package/esm/renderer/constants/index.js +2 -2
- package/esm/renderer/fonts/index.js +4 -4
- package/esm/renderer/fonts/loader.js +3 -3
- package/esm/renderer/fonts/registry.js +1 -1
- package/esm/renderer/index.js +4 -4
- package/esm/renderer/palettes/built-in.js +1 -1
- package/esm/renderer/palettes/index.js +3 -3
- package/esm/renderer/palettes/utils.js +1 -1
- package/esm/renderer/renderer.js +3 -3
- package/esm/renderer/stylize/gradient.js +2 -2
- package/esm/renderer/stylize/index.js +3 -3
- package/esm/renderer/stylize/pattern.js +3 -3
- package/esm/renderer/stylize/patterns/diamond.js +1 -1
- package/esm/renderer/stylize/patterns/dot.js +1 -1
- package/esm/renderer/stylize/patterns/hex.js +1 -1
- package/esm/renderer/stylize/patterns/index.js +6 -6
- package/esm/renderer/stylize/patterns/line.js +1 -1
- package/esm/renderer/stylize/patterns/mosaic.js +1 -1
- package/esm/renderer/stylize/patterns/square.js +1 -1
- package/esm/renderer/stylize/rough.js +1 -1
- package/esm/renderer/utils/index.js +2 -2
- package/esm/resource/index.js +4 -4
- package/esm/resource/loader.js +6 -6
- package/esm/resource/loaders/image.js +1 -1
- package/esm/resource/loaders/index.js +4 -4
- package/esm/resource/loaders/remote.js +3 -3
- package/esm/resource/loaders/search.js +5 -5
- package/esm/resource/loaders/svg.js +1 -1
- package/esm/resource/utils/index.js +3 -3
- package/esm/resource/utils/parser.js +1 -1
- package/esm/resource/utils/ref.js +2 -2
- package/esm/runtime/Infographic.js +11 -11
- package/esm/runtime/index.js +1 -1
- package/esm/runtime/options.js +1 -1
- package/esm/runtime/utils.js +1 -1
- package/esm/ssr/index.js +1 -1
- package/esm/ssr/renderer.js +5 -5
- package/esm/syntax/index.js +4 -4
- package/esm/syntax/mapper.js +1 -1
- package/esm/syntax/relations.js +2 -2
- package/esm/templates/built-in.js +9 -9
- package/esm/templates/index.js +2 -2
- package/esm/themes/built-in.js +1 -1
- package/esm/themes/index.js +3 -3
- package/esm/utils/element.js +1 -1
- package/esm/utils/icon.js +2 -2
- package/esm/utils/index.js +21 -21
- package/esm/utils/measure-text.js +3 -3
- package/esm/utils/padding.js +3 -3
- package/esm/utils/recognizer.js +3 -3
- package/esm/utils/text.js +4 -4
- package/esm/version.d.ts +1 -1
- package/esm/version.js +1 -1
- package/lib/exporter/font.d.ts +0 -13
- package/lib/exporter/font.js +17 -26
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +4 -4
- package/src/exporter/font.ts +21 -32
- package/src/version.ts +1 -1
package/dist/infographic.min.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
(function(V,ht){typeof exports=="object"&&typeof module!="undefined"?ht(exports):typeof define=="function"&&define.amd?define(["exports"],ht):(V=typeof globalThis!="undefined"?globalThis:V||self,ht(V.AntVInfographic={}))})(this,(function(V){"use strict";var bae=Object.defineProperty,_ae=Object.defineProperties;var xae=Object.getOwnPropertyDescriptors;var $S=Object.getOwnPropertySymbols;var wae=Object.prototype.hasOwnProperty,Pae=Object.prototype.propertyIsEnumerable;var ia=Math.pow,CS=(V,ht,Zt)=>ht in V?bae(V,ht,{enumerable:!0,configurable:!0,writable:!0,value:Zt}):V[ht]=Zt,At=(V,ht)=>{for(var Zt in ht||(ht={}))wae.call(ht,Zt)&&CS(V,Zt,ht[Zt]);if($S)for(var Zt of $S(ht))Pae.call(ht,Zt)&&CS(V,Zt,ht[Zt]);return V},Kt=(V,ht)=>_ae(V,xae(ht));var ht=typeof document!="undefined"?document.currentScript:null;const Zt=new Map;function gm(e,t){Zt.set(e,t)}function mm(e){return Zt.get(e)}function SS(){return Array.from(Zt.keys())}const MS={"compare-quadrant-quarter-simple-card":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"quarter-simple-card"}]}},"compare-quadrant-quarter-circular":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"quarter-circular"}]}},"compare-quadrant-simple-illus":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"simple-illus"}]}}},ym=new Set,al={};Object.entries(MS).forEach(([e,t])=>{al[e]=t;const n=e.replace("compare-quadrant","quadrant");al[n]=new Proxy(t,{get(r,i,o){return ym.has(n)||(console.warn(`[Deprecated] "${n}" 已被废弃,将在下个版本移除,请使用 "${e}"`),ym.add(n)),Reflect.get(r,i,o)}})});const ES=al;var IS=Object.defineProperty,vm=Object.getOwnPropertySymbols,AS=Object.prototype.hasOwnProperty,TS=Object.prototype.propertyIsEnumerable,bm=(e,t,n)=>t in e?IS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_m=(e,t)=>{for(var n in t||(t={}))AS.call(t,n)&&bm(e,n,t[n]);if(vm)for(var n of vm(t))TS.call(t,n)&&bm(e,n,t[n]);return e};const Fi={edgeType:"curved",edgeColorMode:"gradient",edgeWidth:2,colorMode:"branch",levelGap:80,nodeGap:18},Bi={edgeType:"curved",edgeWidth:2,edgeColorMode:"gradient",colorMode:"level",levelGap:80,nodeGap:18},xm={type:"lined-text",usePaletteColor:!0,showUnderline:!0,underlineThickness:2},wm={type:"capsule-item"},Pm={type:"circular-progress"},$m={type:"rounded-rect-node",positionH:"center"},Cm={type:"compact-card"},kS=(e,t)=>_m(_m({type:"hierarchy-mindmap"},t!==void 0?{edgeAlign:t}:{}),e),wn=(e,t,n,r)=>[e,{design:{structure:kS(t,r),item:n}}],RS=Object.fromEntries([wn("hierarchy-mindmap-branch-gradient-lined-palette",Fi,xm,"bottom"),wn("hierarchy-mindmap-level-gradient-lined-palette",Bi,xm,"bottom"),wn("hierarchy-mindmap-branch-gradient-capsule-item",Fi,wm),wn("hierarchy-mindmap-level-gradient-capsule-item",Bi,wm),wn("hierarchy-mindmap-branch-gradient-circle-progress",Fi,Pm,.4),wn("hierarchy-mindmap-level-gradient-circle-progress",Bi,Pm,.4),wn("hierarchy-mindmap-branch-gradient-rounded-rect",Fi,$m),wn("hierarchy-mindmap-level-gradient-rounded-rect",Bi,$m),wn("hierarchy-mindmap-branch-gradient-compact-card",Fi,Cm),wn("hierarchy-mindmap-level-gradient-compact-card",Bi,Cm)]),LS={"hierarchy-structure":{design:{title:"default",structure:{type:"hierarchy-structure"},item:"simple"}},"hierarchy-structure-mirror":{design:{title:"default",structure:{type:"hierarchy-structure",layerLabelPosition:"right"},item:"simple"}}};var zS=Object.defineProperty,Om=Object.getOwnPropertySymbols,NS=Object.prototype.hasOwnProperty,DS=Object.prototype.propertyIsEnumerable,Sm=(e,t,n)=>t in e?zS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Mm=(e,t)=>{for(var n in t||(t={}))NS.call(t,n)&&Sm(e,n,t[n]);if(Om)for(var n of Om(t))DS.call(t,n)&&Sm(e,n,t[n]);return e};const HS={"tech-style":{edgeType:"straight",edgeStyle:"solid",edgeColorMode:"gradient",edgeMarker:"arrow",markerSize:12,edgeCornerRadius:5},"dashed-line":{edgeStyle:"dashed",edgeCornerRadius:10,edgeDashPattern:"10,5",edgeColorMode:"gradient",edgeMarker:"dot",markerSize:6,edgeOffset:6},"distributed-origin":{edgeOrigin:"distributed",edgeOriginPadding:30,edgeMarker:"arrow",edgeCornerRadius:10,markerSize:12,edgeColorMode:"gradient"},"curved-line":{edgeType:"curved",edgeColorMode:"gradient",edgeMarker:"none"},"dashed-arrow":{edgeType:"straight",edgeStyle:"dashed",edgeDashPattern:"8,4",edgeMarker:"arrow",markerSize:10,edgeCornerRadius:0}},qS=["capsule-item","rounded-rect-node","compact-card","badge-card","ribbon-card"],Em={},Im="hierarchy-tree",jS=[{key:""},{key:"bt",orientation:"bottom-top"},{key:"lr",orientation:"left-right"},{key:"rl",orientation:"right-left"}],FS=(e,t,n)=>e?`${Im}-${e}-${t}-${n}`:`${Im}-${t}-${n}`;for(const e of qS)for(const[t,n]of Object.entries(HS))for(const{key:r,orientation:i}of jS){const o=FS(r,t,e);Em[o]={design:{structure:Mm(Mm({type:"hierarchy-tree"},i?{orientation:i}:{}),n),item:{type:e}}}}const BS={"list-zigzag-up-compact-card":{design:{title:"default",structure:{type:"list-zigzag-up"},items:[{type:"compact-card"}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-up-simple":{design:{title:"default",structure:{type:"list-zigzag-up"},items:[{type:"simple",usePaletteColor:!0}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-down-compact-card":{design:{title:"default",structure:{type:"list-zigzag-down"},items:[{type:"compact-card"}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-down-simple":{design:{title:"default",structure:{type:"list-zigzag-down"},items:[{type:"simple",usePaletteColor:!0}]},themeConfig:{colorPrimary:"#17CA2C"}}};var WS=Object.defineProperty,GS=Object.defineProperties,VS=Object.getOwnPropertyDescriptors,Am=Object.getOwnPropertySymbols,YS=Object.prototype.hasOwnProperty,XS=Object.prototype.propertyIsEnumerable,Tm=(e,t,n)=>t in e?WS(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,oa=(e,t)=>{for(var n in t||(t={}))YS.call(t,n)&&Tm(e,n,t[n]);if(Am)for(var n of Am(t))XS.call(t,n)&&Tm(e,n,t[n]);return e},aa=(e,t)=>GS(e,VS(t));const US={"simple-circle-node":{type:"simple-circle-node"},"badge-card":{type:"badge-card"},capsule:{type:"capsule-item"},"compact-card":{type:"compact-card"}},sa={type:"relation-dagre-flow",edgeColorMode:"gradient",showArrow:!0,arrowType:"triangle",colorMode:"node"},KS={tb:aa(oa({},sa),{rankdir:"TB",edgeRouting:"orth"}),lr:aa(oa({},sa),{rankdir:"LR",edgeRouting:"orth"}),"tb-animated":aa(oa({},sa),{rankdir:"TB",edgeCornerRadius:12,edgeRouting:"orth",edgeAnimation:"ant-line",edgeDashPattern:"8,4",edgeAnimationSpeed:1}),"lr-animated":aa(oa({},sa),{rankdir:"LR",edgeCornerRadius:12,edgeRouting:"orth",edgeAnimation:"ant-line",edgeDashPattern:"8,4",edgeAnimationSpeed:1})},km={},ZS=["lr-capsule","tb-capsule"];Object.entries(KS).forEach(([e,t])=>{Object.entries(US).forEach(([n,r])=>{const i=`${e}-${n}`;if(ZS.includes(i))return;const o=`relation-dagre-flow-${i}`;km[o]={design:{title:"default",structure:t,item:r}}})});const QS={"sequence-stairs-front-pill-badge":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"pill-badge"}]}},"sequence-stairs-front-compact-card":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"compact-card"}]}},"sequence-stairs-front-simple":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"simple",usePaletteColor:!0}]}}},JS={"chart-wordcloud-rotate":{design:{structure:{type:"chart-wordcloud"},item:"simple"}},"chart-wordcloud":{design:{structure:{type:"chart-wordcloud",enableRotate:!1},item:"simple"}}};var eM=Object.defineProperty,Rm=Object.getOwnPropertySymbols,tM=Object.prototype.hasOwnProperty,nM=Object.prototype.propertyIsEnumerable,Lm=(e,t,n)=>t in e?eM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Jn=(e,t)=>{for(var n in t||(t={}))tM.call(t,n)&&Lm(e,n,t[n]);if(Rm)for(var n of Rm(t))nM.call(t,n)&&Lm(e,n,t[n]);return e};const rM=Jn(Jn(Jn(Jn(Jn(Jn(Jn(Jn({"compare-hierarchy-left-right-circle-node-pill-badge":{design:{structure:{type:"compare-hierarchy-left-right",decoration:"split-line",surround:!1,groupGap:-20},title:"default",items:[{type:"circle-node",width:240},"pill-badge"]},themeConfig:{}},"compare-hierarchy-left-right-circle-node-plain-text":{design:{title:"default",structure:{type:"compare-hierarchy-left-right",decoration:"dot-line",flipLeaf:!0,groupGap:-10},items:[{type:"circle-node",width:180},{type:"plain-text"}]}},"list-pyramid-rounded-rect-node":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"rounded-rect-node"}]}},"list-pyramid-badge-card":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"badge-card"}]}},"list-pyramid-compact-card":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"compact-card"}]}},"list-column-done-list":{design:{title:"default",structure:{type:"list-column"},items:[{type:"done-list"}]}},"list-column-vertical-icon-arrow":{design:{title:"default",structure:{type:"list-column",gap:-5,zigzag:!0},items:[{type:"vertical-icon-arrow"}]}},"list-grid-badge-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"badge-card"}]}},"list-grid-candy-card-lite":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"candy-card-lite"}]}},"chart-column-simple":{design:{title:"default",structure:{type:"chart-column"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"list-grid-circular-progress":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"circular-progress"}]}},"list-grid-compact-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"compact-card"}]}},"list-grid-done-list":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"done-list"}]}},"list-grid-horizontal-icon-arrow":{design:{title:"default",structure:{type:"list-grid",gap:0,zigzag:!0},items:[{type:"horizontal-icon-arrow"}]}},"list-grid-progress-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"progress-card"}]}},"list-grid-ribbon-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"ribbon-card"}]}},"list-grid-simple":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"simple"}]}},"list-row-circular-progress":{design:{title:"default",structure:{type:"list-row"},items:[{type:"circular-progress"}]}},"list-row-horizontal-icon-arrow":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"horizontal-icon-arrow"}]}},"relation-circle-circular-progress":{design:{title:"default",structure:{type:"relation-circle"},items:[{type:"circular-progress"}]}},"relation-circle-icon-badge":{design:{title:"default",structure:{type:"relation-circle"},items:[{type:"icon-badge"}]}},"sequence-steps-badge-card":{design:{title:"default",structure:{type:"sequence-steps"},items:[{type:"badge-card"}]}},"sequence-steps-simple":{design:{title:"default",structure:{type:"sequence-steps",gap:10},items:[{type:"simple"}]}},"sequence-timeline-done-list":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"done-list"}]}},"sequence-timeline-plain-text":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"plain-text"}]}},"sequence-timeline-rounded-rect-node":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"rounded-rect-node"}]}},"sequence-ascending-steps":{design:{title:"default",structure:{type:"sequence-ascending-steps",vGap:-46,hGap:-20},items:[{type:"l-corner-card"}]}},"sequence-timeline-simple":{design:{title:"default",structure:{type:"sequence-timeline",gap:20},items:[{type:"simple",positionV:"middle"}]}},"sequence-cylinders-3d-simple":{design:{title:"default",structure:{type:"sequence-cylinders-3d",gapY:20},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"list-column-simple-vertical-arrow":{design:{title:"default",structure:{type:"list-column",gap:0,zigzag:!0},items:[{type:"simple-vertical-arrow"}]}},"list-row-simple-horizontal-arrow":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"simple-horizontal-arrow"}]}},"compare-swot":{design:{title:"default",structure:{type:"compare-hierarchy-row",itemGap:32,itemPadding:40,showColumnBackground:!0,columnBackgroundAlpha:.08},items:[{type:"letter-card",showBottomShade:!1},{type:"plain-text",formatter:e=>`● ${e}`,usePaletteColor:!0}]}},"compare-hierarchy-row-letter-card-compact-card":{design:{title:"default",structure:{type:"compare-hierarchy-row"},items:[{type:"letter-card"},{type:"compact-card"}]}},"compare-hierarchy-row-letter-card-rounded-rect-node":{design:{title:"default",structure:{type:"compare-hierarchy-row"},items:[{type:"letter-card"},{type:"rounded-rect-node"}]}},"sequence-snake-steps-compact-card":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"compact-card"}]}},"sequence-snake-steps-pill-badge":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"pill-badge"}]}},"sequence-snake-steps-simple":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"simple"}]}},"sequence-color-snake-steps-horizontal-icon-line":{design:{title:"default",structure:{type:"sequence-color-snake-steps"},items:[{type:"horizontal-icon-line"}]}},"sequence-pyramid-simple":{design:{title:"default",structure:{type:"sequence-pyramid"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]},themeConfig:{colorPrimary:"#1677ff"}},"sequence-funnel-simple":{design:{title:"default",structure:{type:"sequence-funnel"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]},themeConfig:{palette:"#1677ff"}},"list-row-horizontal-icon-line":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"horizontal-icon-line"}]}},"list-sector-simple":{design:{title:"default",structure:{type:"list-sector"},items:[{type:"simple"}]}},"list-sector-plain-text":{design:{title:"default",structure:{type:"list-sector"},items:[{type:"plain-text"}]}},"list-sector-half-plain-text":{design:{title:"default",structure:{type:"list-sector",startAngle:-180,endAngle:0},items:[{type:"plain-text"}]}},"sequence-roadmap-vertical-plain-text":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"plain-text"}]}},"sequence-roadmap-vertical-simple":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"simple",showIcon:!1}]}},"sequence-roadmap-vertical-badge-card":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"badge-card"}]}},"sequence-roadmap-vertical-pill-badge":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"pill-badge"}]}},"sequence-roadmap-vertical-quarter-circular":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"quarter-circular"}]}},"sequence-roadmap-vertical-quarter-simple-card":{design:{title:"default",structure:{type:"sequence-roadmap-vertical",flipped:!0},items:[{type:"quarter-simple-card"}]}},"sequence-horizontal-zigzag-simple-illus":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple-illus"}]}},"sequence-horizontal-zigzag-horizontal-icon-line":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"horizontal-icon-line"}]}},"sequence-horizontal-zigzag-plain-text":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"plain-text"}]}},"sequence-horizontal-zigzag-simple-horizontal-arrow":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple-horizontal-arrow"}]}},"sequence-horizontal-zigzag-simple":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple"}]}},"list-row-simple-illus":{design:{title:"default",structure:{type:"list-row"},items:[{type:"simple-illus"}]}},"sequence-color-snake-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-color-snake-steps"},items:[{type:"simple-illus"}]}},"sequence-snake-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"simple-illus"}]}},"sequence-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-steps"},items:[{type:"simple-illus"}]}},"sequence-timeline-simple-illus":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"simple-illus",usePaletteColor:!0}]}},"sequence-zigzag-steps-underline-text":{design:{title:"default",structure:{type:"sequence-zigzag-steps"},items:[{type:"underline-text"}]}},"sequence-horizontal-zigzag-underline-text":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"underline-text"}]}},"sequence-roadmap-vertical-underline-text":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"underline-text"}]}},"sequence-snake-steps-underline-text":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"underline-text"}]}},"sequence-circle-arrows-indexed-card":{design:{title:"default",structure:{type:"sequence-circle-arrows"},items:[{type:"indexed-card"}]}},"sequence-zigzag-pucks-3d-simple":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-zigzag-pucks-3d-underline-text":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"underline-text"}]}},"sequence-zigzag-pucks-3d-indexed-card":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"indexed-card"}]}},"sequence-ascending-stairs-3d-simple":{design:{title:"default",structure:{type:"sequence-ascending-stairs-3d"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-ascending-stairs-3d-underline-text":{design:{title:"default",structure:{type:"sequence-ascending-stairs-3d"},items:[{type:"underline-text"}]}},"sequence-circular-underline-text":{design:{title:"default",structure:{type:"sequence-circular"},items:[{type:"underline-text"}]}},"sequence-circular-simple":{design:{title:"default",structure:{type:"sequence-circular"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-filter-mesh-underline-text":{design:{title:"default",structure:{type:"sequence-filter-mesh"},items:[{type:"underline-text"}]}},"sequence-filter-mesh-simple":{design:{title:"default",structure:{type:"sequence-filter-mesh"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-mountain-underline-text":{design:{title:"default",structure:{type:"sequence-mountain"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-simple-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"compact-card"}]}},"compare-binary-horizontal-simple-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"compact-card"}]}},"compare-binary-horizontal-simple-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"compact-card"}]}},"chart-bar-plain-text":{design:{title:"default",structure:{type:"chart-bar"},items:[{type:"plain-text",positionH:"flipped"}]}},"chart-line-plain-text":{design:{title:"default",structure:{type:"chart-line"},items:[{type:"plain-text",lineNumber:2}]}},"chart-pie-plain-text":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"plain-text"}]}},"chart-pie-compact-card":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"compact-card"}]}},"chart-pie-pill-badge":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"pill-badge"}]}},"chart-pie-donut-plain-text":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"plain-text"}]}},"chart-pie-donut-compact-card":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"compact-card"}]}},"chart-pie-donut-pill-badge":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"pill-badge"}]}}},ES),Em),RS),QS),JS),BS),km),LS);Object.entries(rM).forEach(([e,t])=>{gm(e,t)});const tt=Symbol.for("@antv/infographic/Fragment");function p(e,t={}){return{type:e,props:t}}const L=p,sl="infographic-component";var Ve=(e=>(e.Background="background",e.Title="title",e.Desc="desc",e.ItemsGroup="items-group",e.ItemIconGroup="item-icon-group",e.ItemIcon="item-icon",e.ItemLabel="item-label",e.ItemDesc="item-desc",e.ItemValue="item-value",e.ItemIllus="item-illus",e.BtnAdd="btn-add",e.BtnRemove="btn-remove",e.IllusGroup="illus-group",e.IllusVolume="illus-volume",e.Illus="illus",e.BtnsGroup="btns-group",e.Unknown="unknown",e))(Ve||{});const iM="https://www.weavefox.cn/api/open/v1/icon",cl=Symbol.for("@antv/infographic/Defs");function Ke(e){return{type:cl,props:e}}function Ze(e){var t,n,r,i;const{x:o=0,y:a=0,width:s=0,height:c=0}=e;return(t=e.cx)!=null||(e.cx=o+s/2),(n=e.cy)!=null||(e.cy=a+c/2),(r=e.rx)!=null||(e.rx=s/2),(i=e.ry)!=null||(e.ry=c/2),{type:"ellipse",props:e}}function Y(e){const{x:t=0,y:n=0}=e;return(t||n)&&(e.transform||(e.transform=`translate(${t}, ${n})`)),{type:"g",props:e}}var oM=Object.defineProperty,zm=Object.getOwnPropertySymbols,aM=Object.prototype.hasOwnProperty,sM=Object.prototype.propertyIsEnumerable,Nm=(e,t,n)=>t in e?oM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cM=(e,t)=>{for(var n in t||(t={}))aM.call(t,n)&&Nm(e,n,t[n]);if(zm)for(var n of zm(t))sM.call(t,n)&&Nm(e,n,t[n]);return e};function Pe(e){const{x:t,y:n}=e,r=cM({},e);return(t!==void 0||n!==void 0)&&(r.transform=`translate(${t!=null?t:0}, ${n!=null?n:0})`),{type:"path",props:r}}var lM=Object.defineProperty,uM=Object.defineProperties,hM=Object.getOwnPropertyDescriptors,ca=Object.getOwnPropertySymbols,Dm=Object.prototype.hasOwnProperty,Hm=Object.prototype.propertyIsEnumerable,qm=(e,t,n)=>t in e?lM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dM=(e,t)=>{for(var n in t||(t={}))Dm.call(t,n)&&qm(e,n,t[n]);if(ca)for(var n of ca(t))Hm.call(t,n)&&qm(e,n,t[n]);return e},fM=(e,t)=>uM(e,hM(t)),pM=(e,t)=>{var n={};for(var r in e)Dm.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ca)for(var r of ca(e))t.indexOf(r)<0&&Hm.call(e,r)&&(n[r]=e[r]);return n};function Wt(e){var t=e,{points:n=[]}=t,r=pM(t,["points"]);const{x:i,y:o}=r,a=n.map(({x:l,y:u})=>`${l},${u}`).join(" "),s=fM(dM({},r),{points:a});return(i!==void 0||o!==void 0)&&(s.transform=`translate(${i!=null?i:0}, ${o!=null?o:0})`+(s.transform||"")),{type:"polygon",props:s}}function Re(e){return{type:"rect",props:e}}function jm(e){return Object.keys(e[0]).reduce((t,n)=>{const r=n;return e.every(i=>i[r]===e[0][r])&&(t[r]=e[0][r]),t},{})}const Fm=(e,t)=>{if(typeof e=="number"){if(t===3)return{mode:"rgb",r:(e>>8&15|e>>4&240)/255,g:(e>>4&15|e&240)/255,b:(e&15|e<<4&240)/255};if(t===4)return{mode:"rgb",r:(e>>12&15|e>>8&240)/255,g:(e>>8&15|e>>4&240)/255,b:(e>>4&15|e&240)/255,alpha:(e&15|e<<4&240)/255};if(t===6)return{mode:"rgb",r:(e>>16&255)/255,g:(e>>8&255)/255,b:(e&255)/255};if(t===8)return{mode:"rgb",r:(e>>24&255)/255,g:(e>>16&255)/255,b:(e>>8&255)/255,alpha:(e&255)/255}}},gM={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},mM=e=>Fm(gM[e.toLowerCase()],6),yM=/^#?([0-9a-f]{8}|[0-9a-f]{6}|[0-9a-f]{4}|[0-9a-f]{3})$/i,vM=e=>{let t;return(t=e.match(yM))?Fm(parseInt(t[1],16),t[1].length):void 0},er="([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)",Wi=`${er}%`,ll=`(?:${er}%|${er})`,bM=`(?:${er}(deg|grad|rad|turn)|${er})`,ni="\\s*,\\s*",_M=new RegExp(`^rgba?\\(\\s*${er}${ni}${er}${ni}${er}\\s*(?:,\\s*${ll}\\s*)?\\)$`),xM=new RegExp(`^rgba?\\(\\s*${Wi}${ni}${Wi}${ni}${Wi}\\s*(?:,\\s*${ll}\\s*)?\\)$`),wM=e=>{let t={mode:"rgb"},n;if(n=e.match(_M))n[1]!==void 0&&(t.r=n[1]/255),n[2]!==void 0&&(t.g=n[2]/255),n[3]!==void 0&&(t.b=n[3]/255);else if(n=e.match(xM))n[1]!==void 0&&(t.r=n[1]/100),n[2]!==void 0&&(t.g=n[2]/100),n[3]!==void 0&&(t.b=n[3]/100);else return;return n[4]!==void 0?t.alpha=Math.max(0,Math.min(1,n[4]/100)):n[5]!==void 0&&(t.alpha=Math.max(0,Math.min(1,+n[5]))),t},PM=(e,t)=>e===void 0?void 0:typeof e!="object"?$n(e):e.mode!==void 0?e:t?Kt(At({},e),{mode:t}):void 0,ul=(e="rgb")=>t=>(t=PM(t,e))!==void 0?t.mode===e?t:Pn[t.mode][e]?Pn[t.mode][e](t):e==="rgb"?Pn[t.mode].rgb(t):Pn.rgb[e](Pn[t.mode].rgb(t)):void 0,Pn={},Bm={},la=[],Wm={},$M=e=>e,it=e=>(Pn[e.mode]=At(At({},Pn[e.mode]),e.toMode),Object.keys(e.fromMode||{}).forEach(t=>{Pn[t]||(Pn[t]={}),Pn[t][e.mode]=e.fromMode[t]}),e.ranges||(e.ranges={}),e.difference||(e.difference={}),e.channels.forEach(t=>{if(e.ranges[t]===void 0&&(e.ranges[t]=[0,1]),!e.interpolate[t])throw new Error(`Missing interpolator for: ${t}`);typeof e.interpolate[t]=="function"&&(e.interpolate[t]={use:e.interpolate[t]}),e.interpolate[t].fixup||(e.interpolate[t].fixup=$M)}),Bm[e.mode]=e,(e.parse||[]).forEach(t=>{OM(t,e.mode)}),ul(e.mode)),CM=e=>Bm[e],OM=(e,t)=>{if(typeof e=="string"){if(!t)throw new Error("'mode' required when 'parser' is a string");Wm[e]=t}else typeof e=="function"&&la.indexOf(e)<0&&la.push(e)},hl=/[^\x00-\x7F]|[a-zA-Z_]/,SM=/[^\x00-\x7F]|[-\w]/,fe={Function:"function",Ident:"ident",Number:"number",Percentage:"percentage",ParenClose:")",None:"none",Hue:"hue",Alpha:"alpha"};let Te=0;function ua(e){let t=e[Te],n=e[Te+1];return t==="-"||t==="+"?/\d/.test(n)||n==="."&&/\d/.test(e[Te+2]):t==="."?/\d/.test(n):/\d/.test(t)}function dl(e){if(Te>=e.length)return!1;let t=e[Te];if(hl.test(t))return!0;if(t==="-"){if(e.length-Te<2)return!1;let n=e[Te+1];return!!(n==="-"||hl.test(n))}return!1}const MM={deg:1,rad:180/Math.PI,grad:9/10,turn:360};function Gi(e){let t="";if((e[Te]==="-"||e[Te]==="+")&&(t+=e[Te++]),t+=ha(e),e[Te]==="."&&/\d/.test(e[Te+1])&&(t+=e[Te++]+ha(e)),(e[Te]==="e"||e[Te]==="E")&&((e[Te+1]==="-"||e[Te+1]==="+")&&/\d/.test(e[Te+2])?t+=e[Te++]+e[Te++]+ha(e):/\d/.test(e[Te+1])&&(t+=e[Te++]+ha(e))),dl(e)){let n=da(e);return n==="deg"||n==="rad"||n==="turn"||n==="grad"?{type:fe.Hue,value:t*MM[n]}:void 0}return e[Te]==="%"?(Te++,{type:fe.Percentage,value:+t}):{type:fe.Number,value:+t}}function ha(e){let t="";for(;/\d/.test(e[Te]);)t+=e[Te++];return t}function da(e){let t="";for(;Te<e.length&&SM.test(e[Te]);)t+=e[Te++];return t}function EM(e){let t=da(e);return e[Te]==="("?(Te++,{type:fe.Function,value:t}):t==="none"?{type:fe.None,value:void 0}:{type:fe.Ident,value:t}}function IM(e=""){let t=e.trim(),n=[],r;for(Te=0;Te<t.length;){if(r=t[Te++],r===`
|
|
1
|
+
(function(W,it){typeof exports=="object"&&typeof module!="undefined"?it(exports):typeof define=="function"&&define.amd?define(["exports"],it):(W=typeof globalThis!="undefined"?globalThis:W||self,it(W.AntVInfographic={}))})(this,(function(W){"use strict";var ele=Object.defineProperty,tle=Object.defineProperties;var nle=Object.getOwnPropertyDescriptors;var xc=Object.getOwnPropertySymbols;var tM=Object.prototype.hasOwnProperty,nM=Object.prototype.propertyIsEnumerable;var ds=Math.pow,eM=(W,it,Ct)=>it in W?ele(W,it,{enumerable:!0,configurable:!0,writable:!0,value:Ct}):W[it]=Ct,ht=(W,it)=>{for(var Ct in it||(it={}))tM.call(it,Ct)&&eM(W,Ct,it[Ct]);if(xc)for(var Ct of xc(it))nM.call(it,Ct)&&eM(W,Ct,it[Ct]);return W},zt=(W,it)=>tle(W,nle(it));var fy=(W,it)=>{var Ct={};for(var Jt in W)tM.call(W,Jt)&&it.indexOf(Jt)<0&&(Ct[Jt]=W[Jt]);if(W!=null&&xc)for(var Jt of xc(W))it.indexOf(Jt)<0&&nM.call(W,Jt)&&(Ct[Jt]=W[Jt]);return Ct};var rM=(W,it,Ct)=>new Promise((Jt,Xi)=>{var Cc=pn=>{try{ai(Ct.next(pn))}catch(Ui){Xi(Ui)}},Pc=pn=>{try{ai(Ct.throw(pn))}catch(Ui){Xi(Ui)}},ai=pn=>pn.done?Jt(pn.value):Promise.resolve(pn.value).then(Cc,Pc);ai((Ct=Ct.apply(W,it)).next())});var it=typeof document!="undefined"?document.currentScript:null;const Ct=new Map;function Jt(e,t){Ct.set(e,t)}function Xi(e){return Ct.get(e)}function Cc(){return Array.from(Ct.keys())}const Pc={"compare-quadrant-quarter-simple-card":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"quarter-simple-card"}]}},"compare-quadrant-quarter-circular":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"quarter-circular"}]}},"compare-quadrant-simple-illus":{design:{title:"default",structure:{type:"quadrant"},items:[{type:"simple-illus"}]}}},ai=new Set,pn={};Object.entries(Pc).forEach(([e,t])=>{pn[e]=t;const n=e.replace("compare-quadrant","quadrant");pn[n]=new Proxy(t,{get(r,i,o){return ai.has(n)||(console.warn(`[Deprecated] "${n}" 已被废弃,将在下个版本移除,请使用 "${e}"`),ai.add(n)),Reflect.get(r,i,o)}})});const Ui=pn;var oM=Object.defineProperty,dy=Object.getOwnPropertySymbols,sM=Object.prototype.hasOwnProperty,aM=Object.prototype.propertyIsEnumerable,py=(e,t,n)=>t in e?oM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gy=(e,t)=>{for(var n in t||(t={}))sM.call(t,n)&&py(e,n,t[n]);if(dy)for(var n of dy(t))aM.call(t,n)&&py(e,n,t[n]);return e};const Ki={edgeType:"curved",edgeColorMode:"gradient",edgeWidth:2,colorMode:"branch",levelGap:80,nodeGap:18},Zi={edgeType:"curved",edgeWidth:2,edgeColorMode:"gradient",colorMode:"level",levelGap:80,nodeGap:18},my={type:"lined-text",usePaletteColor:!0,showUnderline:!0,underlineThickness:2},yy={type:"capsule-item"},vy={type:"circular-progress"},by={type:"rounded-rect-node",positionH:"center"},_y={type:"compact-card"},lM=(e,t)=>gy(gy({type:"hierarchy-mindmap"},t!==void 0?{edgeAlign:t}:{}),e),Sn=(e,t,n,r)=>[e,{design:{structure:lM(t,r),item:n}}],cM=Object.fromEntries([Sn("hierarchy-mindmap-branch-gradient-lined-palette",Ki,my,"bottom"),Sn("hierarchy-mindmap-level-gradient-lined-palette",Zi,my,"bottom"),Sn("hierarchy-mindmap-branch-gradient-capsule-item",Ki,yy),Sn("hierarchy-mindmap-level-gradient-capsule-item",Zi,yy),Sn("hierarchy-mindmap-branch-gradient-circle-progress",Ki,vy,.4),Sn("hierarchy-mindmap-level-gradient-circle-progress",Zi,vy,.4),Sn("hierarchy-mindmap-branch-gradient-rounded-rect",Ki,by),Sn("hierarchy-mindmap-level-gradient-rounded-rect",Zi,by),Sn("hierarchy-mindmap-branch-gradient-compact-card",Ki,_y),Sn("hierarchy-mindmap-level-gradient-compact-card",Zi,_y)]),uM={"hierarchy-structure":{design:{title:"default",structure:{type:"hierarchy-structure"},item:"simple"}},"hierarchy-structure-mirror":{design:{title:"default",structure:{type:"hierarchy-structure",layerLabelPosition:"right"},item:"simple"}}};var hM=Object.defineProperty,wy=Object.getOwnPropertySymbols,fM=Object.prototype.hasOwnProperty,dM=Object.prototype.propertyIsEnumerable,xy=(e,t,n)=>t in e?hM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Cy=(e,t)=>{for(var n in t||(t={}))fM.call(t,n)&&xy(e,n,t[n]);if(wy)for(var n of wy(t))dM.call(t,n)&&xy(e,n,t[n]);return e};const pM={"tech-style":{edgeType:"straight",edgeStyle:"solid",edgeColorMode:"gradient",edgeMarker:"arrow",markerSize:12,edgeCornerRadius:5},"dashed-line":{edgeStyle:"dashed",edgeCornerRadius:10,edgeDashPattern:"10,5",edgeColorMode:"gradient",edgeMarker:"dot",markerSize:6,edgeOffset:6},"distributed-origin":{edgeOrigin:"distributed",edgeOriginPadding:30,edgeMarker:"arrow",edgeCornerRadius:10,markerSize:12,edgeColorMode:"gradient"},"curved-line":{edgeType:"curved",edgeColorMode:"gradient",edgeMarker:"none"},"dashed-arrow":{edgeType:"straight",edgeStyle:"dashed",edgeDashPattern:"8,4",edgeMarker:"arrow",markerSize:10,edgeCornerRadius:0}},gM=["capsule-item","rounded-rect-node","compact-card","badge-card","ribbon-card"],Py={},Oy="hierarchy-tree",mM=[{key:""},{key:"bt",orientation:"bottom-top"},{key:"lr",orientation:"left-right"},{key:"rl",orientation:"right-left"}],yM=(e,t,n)=>e?`${Oy}-${e}-${t}-${n}`:`${Oy}-${t}-${n}`;for(const e of gM)for(const[t,n]of Object.entries(pM))for(const{key:r,orientation:i}of mM){const o=yM(r,t,e);Py[o]={design:{structure:Cy(Cy({type:"hierarchy-tree"},i?{orientation:i}:{}),n),item:{type:e}}}}const vM={"list-zigzag-up-compact-card":{design:{title:"default",structure:{type:"list-zigzag-up"},items:[{type:"compact-card"}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-up-simple":{design:{title:"default",structure:{type:"list-zigzag-up"},items:[{type:"simple",usePaletteColor:!0}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-down-compact-card":{design:{title:"default",structure:{type:"list-zigzag-down"},items:[{type:"compact-card"}]},themeConfig:{colorPrimary:"#17CA2C"}},"list-zigzag-down-simple":{design:{title:"default",structure:{type:"list-zigzag-down"},items:[{type:"simple",usePaletteColor:!0}]},themeConfig:{colorPrimary:"#17CA2C"}}};var bM=Object.defineProperty,_M=Object.defineProperties,wM=Object.getOwnPropertyDescriptors,Sy=Object.getOwnPropertySymbols,xM=Object.prototype.hasOwnProperty,CM=Object.prototype.propertyIsEnumerable,$y=(e,t,n)=>t in e?bM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ps=(e,t)=>{for(var n in t||(t={}))xM.call(t,n)&&$y(e,n,t[n]);if(Sy)for(var n of Sy(t))CM.call(t,n)&&$y(e,n,t[n]);return e},gs=(e,t)=>_M(e,wM(t));const PM={"simple-circle-node":{type:"simple-circle-node"},"badge-card":{type:"badge-card"},capsule:{type:"capsule-item"},"compact-card":{type:"compact-card"}},ms={type:"relation-dagre-flow",edgeColorMode:"gradient",showArrow:!0,arrowType:"triangle",colorMode:"node"},OM={tb:gs(ps({},ms),{rankdir:"TB",edgeRouting:"orth"}),lr:gs(ps({},ms),{rankdir:"LR",edgeRouting:"orth"}),"tb-animated":gs(ps({},ms),{rankdir:"TB",edgeCornerRadius:12,edgeRouting:"orth",edgeAnimation:"ant-line",edgeDashPattern:"8,4",edgeAnimationSpeed:1}),"lr-animated":gs(ps({},ms),{rankdir:"LR",edgeCornerRadius:12,edgeRouting:"orth",edgeAnimation:"ant-line",edgeDashPattern:"8,4",edgeAnimationSpeed:1})},Ey={},SM=["lr-capsule","tb-capsule"];Object.entries(OM).forEach(([e,t])=>{Object.entries(PM).forEach(([n,r])=>{const i=`${e}-${n}`;if(SM.includes(i))return;const o=`relation-dagre-flow-${i}`;Ey[o]={design:{title:"default",structure:t,item:r}}})});const $M={"sequence-stairs-front-pill-badge":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"pill-badge"}]}},"sequence-stairs-front-compact-card":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"compact-card"}]}},"sequence-stairs-front-simple":{design:{title:"default",structure:{type:"sequence-stairs-front"},items:[{type:"simple",usePaletteColor:!0}]}}},EM={"chart-wordcloud-rotate":{design:{structure:{type:"chart-wordcloud"},item:"simple"}},"chart-wordcloud":{design:{structure:{type:"chart-wordcloud",enableRotate:!1},item:"simple"}}};var MM=Object.defineProperty,My=Object.getOwnPropertySymbols,IM=Object.prototype.hasOwnProperty,AM=Object.prototype.propertyIsEnumerable,Iy=(e,t,n)=>t in e?MM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,rr=(e,t)=>{for(var n in t||(t={}))IM.call(t,n)&&Iy(e,n,t[n]);if(My)for(var n of My(t))AM.call(t,n)&&Iy(e,n,t[n]);return e};const TM=rr(rr(rr(rr(rr(rr(rr(rr({"compare-hierarchy-left-right-circle-node-pill-badge":{design:{structure:{type:"compare-hierarchy-left-right",decoration:"split-line",surround:!1,groupGap:-20},title:"default",items:[{type:"circle-node",width:240},"pill-badge"]},themeConfig:{}},"compare-hierarchy-left-right-circle-node-plain-text":{design:{title:"default",structure:{type:"compare-hierarchy-left-right",decoration:"dot-line",flipLeaf:!0,groupGap:-10},items:[{type:"circle-node",width:180},{type:"plain-text"}]}},"list-pyramid-rounded-rect-node":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"rounded-rect-node"}]}},"list-pyramid-badge-card":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"badge-card"}]}},"list-pyramid-compact-card":{design:{title:"default",structure:{type:"list-pyramid"},items:[{type:"compact-card"}]}},"list-column-done-list":{design:{title:"default",structure:{type:"list-column"},items:[{type:"done-list"}]}},"list-column-vertical-icon-arrow":{design:{title:"default",structure:{type:"list-column",gap:-5,zigzag:!0},items:[{type:"vertical-icon-arrow"}]}},"list-grid-badge-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"badge-card"}]}},"list-grid-candy-card-lite":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"candy-card-lite"}]}},"chart-column-simple":{design:{title:"default",structure:{type:"chart-column"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"list-grid-circular-progress":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"circular-progress"}]}},"list-grid-compact-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"compact-card"}]}},"list-grid-done-list":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"done-list"}]}},"list-grid-horizontal-icon-arrow":{design:{title:"default",structure:{type:"list-grid",gap:0,zigzag:!0},items:[{type:"horizontal-icon-arrow"}]}},"list-grid-progress-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"progress-card"}]}},"list-grid-ribbon-card":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"ribbon-card"}]}},"list-grid-simple":{design:{title:"default",structure:{type:"list-grid"},items:[{type:"simple"}]}},"list-row-circular-progress":{design:{title:"default",structure:{type:"list-row"},items:[{type:"circular-progress"}]}},"list-row-horizontal-icon-arrow":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"horizontal-icon-arrow"}]}},"relation-circle-circular-progress":{design:{title:"default",structure:{type:"relation-circle"},items:[{type:"circular-progress"}]}},"relation-circle-icon-badge":{design:{title:"default",structure:{type:"relation-circle"},items:[{type:"icon-badge"}]}},"sequence-steps-badge-card":{design:{title:"default",structure:{type:"sequence-steps"},items:[{type:"badge-card"}]}},"sequence-steps-simple":{design:{title:"default",structure:{type:"sequence-steps",gap:10},items:[{type:"simple"}]}},"sequence-timeline-done-list":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"done-list"}]}},"sequence-timeline-plain-text":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"plain-text"}]}},"sequence-timeline-rounded-rect-node":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"rounded-rect-node"}]}},"sequence-ascending-steps":{design:{title:"default",structure:{type:"sequence-ascending-steps",vGap:-46,hGap:-20},items:[{type:"l-corner-card"}]}},"sequence-timeline-simple":{design:{title:"default",structure:{type:"sequence-timeline",gap:20},items:[{type:"simple",positionV:"middle"}]}},"sequence-cylinders-3d-simple":{design:{title:"default",structure:{type:"sequence-cylinders-3d",gapY:20},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"list-column-simple-vertical-arrow":{design:{title:"default",structure:{type:"list-column",gap:0,zigzag:!0},items:[{type:"simple-vertical-arrow"}]}},"list-row-simple-horizontal-arrow":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"simple-horizontal-arrow"}]}},"compare-swot":{design:{title:"default",structure:{type:"compare-hierarchy-row",itemGap:32,itemPadding:40,showColumnBackground:!0,columnBackgroundAlpha:.08},items:[{type:"letter-card",showBottomShade:!1},{type:"plain-text",formatter:e=>`● ${e}`,usePaletteColor:!0}]}},"compare-hierarchy-row-letter-card-compact-card":{design:{title:"default",structure:{type:"compare-hierarchy-row"},items:[{type:"letter-card"},{type:"compact-card"}]}},"compare-hierarchy-row-letter-card-rounded-rect-node":{design:{title:"default",structure:{type:"compare-hierarchy-row"},items:[{type:"letter-card"},{type:"rounded-rect-node"}]}},"sequence-snake-steps-compact-card":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"compact-card"}]}},"sequence-snake-steps-pill-badge":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"pill-badge"}]}},"sequence-snake-steps-simple":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"simple"}]}},"sequence-color-snake-steps-horizontal-icon-line":{design:{title:"default",structure:{type:"sequence-color-snake-steps"},items:[{type:"horizontal-icon-line"}]}},"sequence-pyramid-simple":{design:{title:"default",structure:{type:"sequence-pyramid"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]},themeConfig:{colorPrimary:"#1677ff"}},"sequence-funnel-simple":{design:{title:"default",structure:{type:"sequence-funnel"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]},themeConfig:{palette:"#1677ff"}},"list-row-horizontal-icon-line":{design:{title:"default",structure:{type:"list-row",gap:0,zigzag:!0},items:[{type:"horizontal-icon-line"}]}},"list-sector-simple":{design:{title:"default",structure:{type:"list-sector"},items:[{type:"simple"}]}},"list-sector-plain-text":{design:{title:"default",structure:{type:"list-sector"},items:[{type:"plain-text"}]}},"list-sector-half-plain-text":{design:{title:"default",structure:{type:"list-sector",startAngle:-180,endAngle:0},items:[{type:"plain-text"}]}},"sequence-roadmap-vertical-plain-text":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"plain-text"}]}},"sequence-roadmap-vertical-simple":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"simple",showIcon:!1}]}},"sequence-roadmap-vertical-badge-card":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"badge-card"}]}},"sequence-roadmap-vertical-pill-badge":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"pill-badge"}]}},"sequence-roadmap-vertical-quarter-circular":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"quarter-circular"}]}},"sequence-roadmap-vertical-quarter-simple-card":{design:{title:"default",structure:{type:"sequence-roadmap-vertical",flipped:!0},items:[{type:"quarter-simple-card"}]}},"sequence-horizontal-zigzag-simple-illus":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple-illus"}]}},"sequence-horizontal-zigzag-horizontal-icon-line":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"horizontal-icon-line"}]}},"sequence-horizontal-zigzag-plain-text":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"plain-text"}]}},"sequence-horizontal-zigzag-simple-horizontal-arrow":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple-horizontal-arrow"}]}},"sequence-horizontal-zigzag-simple":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"simple"}]}},"list-row-simple-illus":{design:{title:"default",structure:{type:"list-row"},items:[{type:"simple-illus"}]}},"sequence-color-snake-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-color-snake-steps"},items:[{type:"simple-illus"}]}},"sequence-snake-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"simple-illus"}]}},"sequence-steps-simple-illus":{design:{title:"default",structure:{type:"sequence-steps"},items:[{type:"simple-illus"}]}},"sequence-timeline-simple-illus":{design:{title:"default",structure:{type:"sequence-timeline"},items:[{type:"simple-illus",usePaletteColor:!0}]}},"sequence-zigzag-steps-underline-text":{design:{title:"default",structure:{type:"sequence-zigzag-steps"},items:[{type:"underline-text"}]}},"sequence-horizontal-zigzag-underline-text":{design:{title:"default",structure:{type:"sequence-horizontal-zigzag"},items:[{type:"underline-text"}]}},"sequence-roadmap-vertical-underline-text":{design:{title:"default",structure:{type:"sequence-roadmap-vertical"},items:[{type:"underline-text"}]}},"sequence-snake-steps-underline-text":{design:{title:"default",structure:{type:"sequence-snake-steps"},items:[{type:"underline-text"}]}},"sequence-circle-arrows-indexed-card":{design:{title:"default",structure:{type:"sequence-circle-arrows"},items:[{type:"indexed-card"}]}},"sequence-zigzag-pucks-3d-simple":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-zigzag-pucks-3d-underline-text":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"underline-text"}]}},"sequence-zigzag-pucks-3d-indexed-card":{design:{title:"default",structure:{type:"sequence-zigzag-pucks-3d"},items:[{type:"indexed-card"}]}},"sequence-ascending-stairs-3d-simple":{design:{title:"default",structure:{type:"sequence-ascending-stairs-3d"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-ascending-stairs-3d-underline-text":{design:{title:"default",structure:{type:"sequence-ascending-stairs-3d"},items:[{type:"underline-text"}]}},"sequence-circular-underline-text":{design:{title:"default",structure:{type:"sequence-circular"},items:[{type:"underline-text"}]}},"sequence-circular-simple":{design:{title:"default",structure:{type:"sequence-circular"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-filter-mesh-underline-text":{design:{title:"default",structure:{type:"sequence-filter-mesh"},items:[{type:"underline-text"}]}},"sequence-filter-mesh-simple":{design:{title:"default",structure:{type:"sequence-filter-mesh"},items:[{type:"simple",showIcon:!1,usePaletteColor:!0}]}},"sequence-mountain-underline-text":{design:{title:"default",structure:{type:"sequence-mountain"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-simple-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-fold":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-fold"},items:[{type:"compact-card"}]}},"compare-binary-horizontal-simple-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-arrow":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"pros-cons-arrow"},items:[{type:"compact-card"}]}},"compare-binary-horizontal-simple-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"simple",iconType:"circle",iconSize:40}]}},"compare-binary-horizontal-underline-text-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"underline-text"}]}},"compare-binary-horizontal-badge-card-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"badge-card"}]}},"compare-binary-horizontal-compact-card-vs":{design:{title:"default",structure:{type:"compare-binary-horizontal",dividerType:"vs"},items:[{type:"compact-card"}]}},"chart-bar-plain-text":{design:{title:"default",structure:{type:"chart-bar"},items:[{type:"plain-text",positionH:"flipped"}]}},"chart-line-plain-text":{design:{title:"default",structure:{type:"chart-line"},items:[{type:"plain-text",lineNumber:2}]}},"chart-pie-plain-text":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"plain-text"}]}},"chart-pie-compact-card":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"compact-card"}]}},"chart-pie-pill-badge":{design:{title:"default",structure:{type:"chart-pie"},items:[{type:"pill-badge"}]}},"chart-pie-donut-plain-text":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"plain-text"}]}},"chart-pie-donut-compact-card":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"compact-card"}]}},"chart-pie-donut-pill-badge":{design:{title:"default",structure:{type:"chart-pie",innerRadius:90},items:[{type:"pill-badge"}]}}},Ui),Py),cM),$M),EM),vM),Ey),uM);Object.entries(TM).forEach(([e,t])=>{Jt(e,t)});const tt=Symbol.for("@antv/infographic/Fragment");function y(e,t={}){return{type:e,props:t}}const k=y,Oc="infographic-component";var Ge=(e=>(e.Background="background",e.Title="title",e.Desc="desc",e.ItemsGroup="items-group",e.ItemIconGroup="item-icon-group",e.ItemIcon="item-icon",e.ItemLabel="item-label",e.ItemDesc="item-desc",e.ItemValue="item-value",e.ItemIllus="item-illus",e.BtnAdd="btn-add",e.BtnRemove="btn-remove",e.IllusGroup="illus-group",e.IllusVolume="illus-volume",e.Illus="illus",e.BtnsGroup="btns-group",e.Unknown="unknown",e))(Ge||{});const RM="https://www.weavefox.cn/api/open/v1/icon",Sc=Symbol.for("@antv/infographic/Defs");function Ke(e){return{type:Sc,props:e}}function Ze(e){var t,n,r,i;const{x:o=0,y:s=0,width:a=0,height:l=0}=e;return(t=e.cx)!=null||(e.cx=o+a/2),(n=e.cy)!=null||(e.cy=s+l/2),(r=e.rx)!=null||(e.rx=a/2),(i=e.ry)!=null||(e.ry=l/2),{type:"ellipse",props:e}}function Y(e){const{x:t=0,y:n=0}=e;return(t||n)&&(e.transform||(e.transform=`translate(${t}, ${n})`)),{type:"g",props:e}}var kM=Object.defineProperty,Ay=Object.getOwnPropertySymbols,LM=Object.prototype.hasOwnProperty,NM=Object.prototype.propertyIsEnumerable,Ty=(e,t,n)=>t in e?kM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zM=(e,t)=>{for(var n in t||(t={}))LM.call(t,n)&&Ty(e,n,t[n]);if(Ay)for(var n of Ay(t))NM.call(t,n)&&Ty(e,n,t[n]);return e};function Ce(e){const{x:t,y:n}=e,r=zM({},e);return(t!==void 0||n!==void 0)&&(r.transform=`translate(${t!=null?t:0}, ${n!=null?n:0})`),{type:"path",props:r}}var DM=Object.defineProperty,qM=Object.defineProperties,HM=Object.getOwnPropertyDescriptors,ys=Object.getOwnPropertySymbols,Ry=Object.prototype.hasOwnProperty,ky=Object.prototype.propertyIsEnumerable,Ly=(e,t,n)=>t in e?DM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,jM=(e,t)=>{for(var n in t||(t={}))Ry.call(t,n)&&Ly(e,n,t[n]);if(ys)for(var n of ys(t))ky.call(t,n)&&Ly(e,n,t[n]);return e},FM=(e,t)=>qM(e,HM(t)),BM=(e,t)=>{var n={};for(var r in e)Ry.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ys)for(var r of ys(e))t.indexOf(r)<0&&ky.call(e,r)&&(n[r]=e[r]);return n};function Yt(e){var t=e,{points:n=[]}=t,r=BM(t,["points"]);const{x:i,y:o}=r,s=n.map(({x:c,y:u})=>`${c},${u}`).join(" "),a=FM(jM({},r),{points:s});return(i!==void 0||o!==void 0)&&(a.transform=`translate(${i!=null?i:0}, ${o!=null?o:0})`+(a.transform||"")),{type:"polygon",props:a}}function ke(e){return{type:"rect",props:e}}function Ny(e){return Object.keys(e[0]).reduce((t,n)=>{const r=n;return e.every(i=>i[r]===e[0][r])&&(t[r]=e[0][r]),t},{})}const zy=(e,t)=>{if(typeof e=="number"){if(t===3)return{mode:"rgb",r:(e>>8&15|e>>4&240)/255,g:(e>>4&15|e&240)/255,b:(e&15|e<<4&240)/255};if(t===4)return{mode:"rgb",r:(e>>12&15|e>>8&240)/255,g:(e>>8&15|e>>4&240)/255,b:(e>>4&15|e&240)/255,alpha:(e&15|e<<4&240)/255};if(t===6)return{mode:"rgb",r:(e>>16&255)/255,g:(e>>8&255)/255,b:(e&255)/255};if(t===8)return{mode:"rgb",r:(e>>24&255)/255,g:(e>>16&255)/255,b:(e>>8&255)/255,alpha:(e&255)/255}}},WM={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},VM=e=>zy(WM[e.toLowerCase()],6),GM=/^#?([0-9a-f]{8}|[0-9a-f]{6}|[0-9a-f]{4}|[0-9a-f]{3})$/i,YM=e=>{let t;return(t=e.match(GM))?zy(parseInt(t[1],16),t[1].length):void 0},ir="([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)",Qi=`${ir}%`,$c=`(?:${ir}%|${ir})`,XM=`(?:${ir}(deg|grad|rad|turn)|${ir})`,li="\\s*,\\s*",UM=new RegExp(`^rgba?\\(\\s*${ir}${li}${ir}${li}${ir}\\s*(?:,\\s*${$c}\\s*)?\\)$`),KM=new RegExp(`^rgba?\\(\\s*${Qi}${li}${Qi}${li}${Qi}\\s*(?:,\\s*${$c}\\s*)?\\)$`),ZM=e=>{let t={mode:"rgb"},n;if(n=e.match(UM))n[1]!==void 0&&(t.r=n[1]/255),n[2]!==void 0&&(t.g=n[2]/255),n[3]!==void 0&&(t.b=n[3]/255);else if(n=e.match(KM))n[1]!==void 0&&(t.r=n[1]/100),n[2]!==void 0&&(t.g=n[2]/100),n[3]!==void 0&&(t.b=n[3]/100);else return;return n[4]!==void 0?t.alpha=Math.max(0,Math.min(1,n[4]/100)):n[5]!==void 0&&(t.alpha=Math.max(0,Math.min(1,+n[5]))),t},QM=(e,t)=>e===void 0?void 0:typeof e!="object"?En(e):e.mode!==void 0?e:t?zt(ht({},e),{mode:t}):void 0,Ec=(e="rgb")=>t=>(t=QM(t,e))!==void 0?t.mode===e?t:$n[t.mode][e]?$n[t.mode][e](t):e==="rgb"?$n[t.mode].rgb(t):$n.rgb[e]($n[t.mode].rgb(t)):void 0,$n={},Dy={},vs=[],qy={},JM=e=>e,ot=e=>($n[e.mode]=ht(ht({},$n[e.mode]),e.toMode),Object.keys(e.fromMode||{}).forEach(t=>{$n[t]||($n[t]={}),$n[t][e.mode]=e.fromMode[t]}),e.ranges||(e.ranges={}),e.difference||(e.difference={}),e.channels.forEach(t=>{if(e.ranges[t]===void 0&&(e.ranges[t]=[0,1]),!e.interpolate[t])throw new Error(`Missing interpolator for: ${t}`);typeof e.interpolate[t]=="function"&&(e.interpolate[t]={use:e.interpolate[t]}),e.interpolate[t].fixup||(e.interpolate[t].fixup=JM)}),Dy[e.mode]=e,(e.parse||[]).forEach(t=>{tI(t,e.mode)}),Ec(e.mode)),eI=e=>Dy[e],tI=(e,t)=>{if(typeof e=="string"){if(!t)throw new Error("'mode' required when 'parser' is a string");qy[e]=t}else typeof e=="function"&&vs.indexOf(e)<0&&vs.push(e)},Mc=/[^\x00-\x7F]|[a-zA-Z_]/,nI=/[^\x00-\x7F]|[-\w]/,de={Function:"function",Ident:"ident",Number:"number",Percentage:"percentage",ParenClose:")",None:"none",Hue:"hue",Alpha:"alpha"};let Te=0;function bs(e){let t=e[Te],n=e[Te+1];return t==="-"||t==="+"?/\d/.test(n)||n==="."&&/\d/.test(e[Te+2]):t==="."?/\d/.test(n):/\d/.test(t)}function Ic(e){if(Te>=e.length)return!1;let t=e[Te];if(Mc.test(t))return!0;if(t==="-"){if(e.length-Te<2)return!1;let n=e[Te+1];return!!(n==="-"||Mc.test(n))}return!1}const rI={deg:1,rad:180/Math.PI,grad:9/10,turn:360};function Ji(e){let t="";if((e[Te]==="-"||e[Te]==="+")&&(t+=e[Te++]),t+=_s(e),e[Te]==="."&&/\d/.test(e[Te+1])&&(t+=e[Te++]+_s(e)),(e[Te]==="e"||e[Te]==="E")&&((e[Te+1]==="-"||e[Te+1]==="+")&&/\d/.test(e[Te+2])?t+=e[Te++]+e[Te++]+_s(e):/\d/.test(e[Te+1])&&(t+=e[Te++]+_s(e))),Ic(e)){let n=ws(e);return n==="deg"||n==="rad"||n==="turn"||n==="grad"?{type:de.Hue,value:t*rI[n]}:void 0}return e[Te]==="%"?(Te++,{type:de.Percentage,value:+t}):{type:de.Number,value:+t}}function _s(e){let t="";for(;/\d/.test(e[Te]);)t+=e[Te++];return t}function ws(e){let t="";for(;Te<e.length&&nI.test(e[Te]);)t+=e[Te++];return t}function iI(e){let t=ws(e);return e[Te]==="("?(Te++,{type:de.Function,value:t}):t==="none"?{type:de.None,value:void 0}:{type:de.Ident,value:t}}function oI(e=""){let t=e.trim(),n=[],r;for(Te=0;Te<t.length;){if(r=t[Te++],r===`
|
|
2
2
|
`||r===" "||r===" "){for(;Te<t.length&&(t[Te]===`
|
|
3
|
-
`||t[Te]===" "||t[Te]===" ");)Te++;continue}if(r===",")return;if(r===")"){n.push({type:
|
|
4
|
-
`||t[Te]===" "||t[Te]===" ");)Te++;let i;if(ua(t)&&(i=Gi(t),i.type!==fe.Hue)){n.push({type:fe.Alpha,value:i});continue}if(dl(t)&&da(t)==="none"){n.push({type:fe.Alpha,value:{type:fe.None,value:void 0}});continue}return}if(/\d/.test(r)){Te--,n.push(Gi(t));continue}if(hl.test(r)){Te--,n.push(EM(t));continue}return}return n}function AM(e){e._i=0;let t=e[e._i++];if(!t||t.type!==fe.Function||t.value!=="color"||(t=e[e._i++],t.type!==fe.Ident))return;const n=Wm[t.value];if(!n)return;const r={mode:n},i=Gm(e,!1);if(!i)return;const o=CM(n).channels;for(let a=0,s,c;a<o.length;a++)s=i[a],c=o[a],s.type!==fe.None&&(r[c]=s.type===fe.Number?s.value:s.value/100,c==="alpha"&&(r[c]=Math.max(0,Math.min(1,r[c]))));return r}function Gm(e,t){const n=[];let r;for(;e._i<e.length;){if(r=e[e._i++],r.type===fe.None||r.type===fe.Number||r.type===fe.Alpha||r.type===fe.Percentage||t&&r.type===fe.Hue){n.push(r);continue}if(r.type===fe.ParenClose){if(e._i<e.length)return;continue}return}if(!(n.length<3||n.length>4)){if(n.length===4){if(n[3].type!==fe.Alpha)return;n[3]=n[3].value}return n.length===3&&n.push({type:fe.None,value:void 0}),n.every(i=>i.type!==fe.Alpha)?n:void 0}}function TM(e,t){e._i=0;let n=e[e._i++];if(!n||n.type!==fe.Function)return;let r=Gm(e,t);if(r)return r.unshift(n.value),r}const $n=e=>{if(typeof e!="string")return;const t=IM(e),n=t?TM(t,!0):void 0;let r,i=0,o=la.length;for(;i<o;)if((r=la[i++](e,n))!==void 0)return r;return t?AM(t):void 0};function kM(e,t){if(!t||t[0]!=="rgb"&&t[0]!=="rgba")return;const n={mode:"rgb"},[,r,i,o,a]=t;if(!(r.type===fe.Hue||i.type===fe.Hue||o.type===fe.Hue))return r.type!==fe.None&&(n.r=r.type===fe.Number?r.value/255:r.value/100),i.type!==fe.None&&(n.g=i.type===fe.Number?i.value/255:i.value/100),o.type!==fe.None&&(n.b=o.type===fe.Number?o.value/255:o.value/100),a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const RM=e=>e==="transparent"?{mode:"rgb",r:0,g:0,b:0,alpha:0}:void 0,LM=(e,t,n)=>e+n*(t-e),zM=e=>{let t=[];for(let n=0;n<e.length-1;n++){let r=e[n],i=e[n+1];r===void 0&&i===void 0?t.push(void 0):r!==void 0&&i!==void 0?t.push([r,i]):t.push(r!==void 0?[r,r]:[i,i])}return t},_e=(e=>t=>{let n=zM(t);return r=>{let i=r*n.length,o=r>=1?n.length-1:Math.max(Math.floor(i),0),a=n[o];return a===void 0?void 0:e(a[0],a[1],i-o)}})(LM),Tt=e=>{let t=!1,n=e.map(r=>r!==void 0?(t=!0,r):1);return t?n:e},ri={mode:"rgb",channels:["r","g","b","alpha"],parse:[kM,vM,wM,mM,RM,"srgb"],serialize:"srgb",interpolate:{r:_e,g:_e,b:_e,alpha:{use:_e,fixup:Tt}},gamut:!0,white:{r:1,g:1,b:1},black:{r:0,g:0,b:0}},fl=(e=0)=>Math.pow(Math.abs(e),563/256)*Math.sign(e),Vm=e=>{let t=fl(e.r),n=fl(e.g),r=fl(e.b),i={mode:"xyz65",x:.5766690429101305*t+.1855582379065463*n+.1882286462349947*r,y:.297344975250536*t+.6273635662554661*n+.0752914584939979*r,z:.0270313613864123*t+.0706888525358272*n+.9913375368376386*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},pl=e=>Math.pow(Math.abs(e),256/563)*Math.sign(e),Ym=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"a98",r:pl(e*2.0415879038107465-t*.5650069742788597-.3447313507783297*n),g:pl(e*-.9692436362808798+t*1.8759675015077206+.0415550574071756*n),b:pl(e*.0134442806320312-t*.1183623922310184+1.0151749943912058*n)};return r!==void 0&&(i.alpha=r),i},gl=(e=0)=>{const t=Math.abs(e);return t<=.04045?e/12.92:(Math.sign(e)||1)*Math.pow((t+.055)/1.055,2.4)},ii=({r:e,g:t,b:n,alpha:r})=>{let i={mode:"lrgb",r:gl(e),g:gl(t),b:gl(n)};return r!==void 0&&(i.alpha=r),i},yr=e=>{let{r:t,g:n,b:r,alpha:i}=ii(e),o={mode:"xyz65",x:.4123907992659593*t+.357584339383878*n+.1804807884018343*r,y:.2126390058715102*t+.715168678767756*n+.0721923153607337*r,z:.0193308187155918*t+.119194779794626*n+.9505321522496607*r};return i!==void 0&&(o.alpha=i),o},ml=(e=0)=>{const t=Math.abs(e);return t>.0031308?(Math.sign(e)||1)*(1.055*Math.pow(t,1/2.4)-.055):e*12.92},oi=({r:e,g:t,b:n,alpha:r},i="rgb")=>{let o={mode:i,r:ml(e),g:ml(t),b:ml(n)};return r!==void 0&&(o.alpha=r),o},vr=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=oi({r:e*3.2409699419045226-t*1.537383177570094-.4986107602930034*n,g:e*-.9692436362808796+t*1.8759675015077204+.0415550574071756*n,b:e*.0556300796969936-t*.2039769588889765+1.0569715142428784*n});return r!==void 0&&(i.alpha=r),i},NM=Kt(At({},ri),{mode:"a98",parse:["a98-rgb"],serialize:"a98-rgb",fromMode:{rgb:e=>Ym(yr(e)),xyz65:Ym},toMode:{rgb:e=>vr(Vm(e)),xyz65:Vm}}),Dt=e=>(e=e%360)<0?e+360:e,DM=(e,t)=>e.map((n,r,i)=>{if(n===void 0)return n;let o=Dt(n);return r===0||e[r-1]===void 0?o:t(o-Dt(i[r-1]))}).reduce((n,r)=>!n.length||r===void 0||n[n.length-1]===void 0?(n.push(r),n):(n.push(r+n[n.length-1]),n),[]),Nn=e=>DM(e,t=>Math.abs(t)<=180?t:t-360*Math.sign(t)),Lt=[-.14861,1.78277,-.29227,-.90649,1.97294,0],HM=Math.PI/180,qM=180/Math.PI;let Xm=Lt[3]*Lt[4],Um=Lt[1]*Lt[4],Km=Lt[1]*Lt[2]-Lt[0]*Lt[3];const jM=({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(Km*n+e*Xm-t*Um)/(Km+Xm-Um),o=n-i,a=(Lt[4]*(t-i)-Lt[2]*o)/Lt[3],s={mode:"cubehelix",l:i,s:i===0||i===1?void 0:Math.sqrt(o*o+a*a)/(Lt[4]*i*(1-i))};return s.s&&(s.h=Math.atan2(a,o)*qM-120),r!==void 0&&(s.alpha=r),s},FM=({h:e,s:t,l:n,alpha:r})=>{let i={mode:"rgb"};e=(e===void 0?0:e+120)*HM,n===void 0&&(n=0);let o=t===void 0?0:t*n*(1-n),a=Math.cos(e),s=Math.sin(e);return i.r=n+o*(Lt[0]*a+Lt[1]*s),i.g=n+o*(Lt[2]*a+Lt[3]*s),i.b=n+o*(Lt[4]*a+Lt[5]*s),r!==void 0&&(i.alpha=r),i},fa=(e,t)=>{if(e.h===void 0||t.h===void 0||!e.s||!t.s)return 0;let n=Dt(e.h),r=Dt(t.h),i=Math.sin((r-n+360)/2*Math.PI/180);return 2*Math.sqrt(e.s*t.s)*i},BM=(e,t)=>{if(e.h===void 0||t.h===void 0)return 0;let n=Dt(e.h),r=Dt(t.h);return Math.abs(r-n)>180?n-(r-360*Math.sign(r-n)):r-n},pa=(e,t)=>{if(e.h===void 0||t.h===void 0||!e.c||!t.c)return 0;let n=Dt(e.h),r=Dt(t.h),i=Math.sin((r-n+360)/2*Math.PI/180);return 2*Math.sqrt(e.c*t.c)*i},Dn=e=>{let t=e.reduce((r,i)=>{if(i!==void 0){let o=i*Math.PI/180;r.sin+=Math.sin(o),r.cos+=Math.cos(o)}return r},{sin:0,cos:0}),n=Math.atan2(t.sin,t.cos)*180/Math.PI;return n<0?360+n:n},WM={mode:"cubehelix",channels:["h","s","l","alpha"],parse:["--cubehelix"],serialize:"--cubehelix",ranges:{h:[0,360],s:[0,4.614],l:[0,1]},fromMode:{rgb:jM},toMode:{rgb:FM},interpolate:{h:{use:_e,fixup:Nn},s:_e,l:_e,alpha:{use:_e,fixup:Tt}},difference:{h:fa},average:{h:Dn}},tr=({l:e,a:t,b:n,alpha:r},i="lch")=>{t===void 0&&(t=0),n===void 0&&(n=0);let o=Math.sqrt(t*t+n*n),a={mode:i,l:e,c:o};return o&&(a.h=Dt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(a.alpha=r),a},nr=({l:e,c:t,h:n,alpha:r},i="lab")=>{n===void 0&&(n=0);let o={mode:i,l:e,a:t?t*Math.cos(n/180*Math.PI):0,b:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(o.alpha=r),o},Zm=Math.pow(29,3)/Math.pow(3,3),Qm=Math.pow(6,3)/Math.pow(29,3),Mt={X:.3457/.3585,Y:1,Z:(1-.3457-.3585)/.3585},ai={X:.3127/.329,Y:1,Z:(1-.3127-.329)/.329};let yl=e=>Math.pow(e,3)>Qm?Math.pow(e,3):(116*e-16)/Zm;const Jm=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+16)/116,o=t/500+i,a=i-n/200,s={mode:"xyz65",x:yl(o)*ai.X,y:yl(i)*ai.Y,z:yl(a)*ai.Z};return r!==void 0&&(s.alpha=r),s},ga=e=>vr(Jm(e)),vl=e=>e>Qm?Math.cbrt(e):(Zm*e+16)/116,ey=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=vl(e/ai.X),o=vl(t/ai.Y),a=vl(n/ai.Z),s={mode:"lab65",l:116*o-16,a:500*(i-o),b:200*(o-a)};return r!==void 0&&(s.alpha=r),s},ma=e=>{let t=ey(yr(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},ya=1,ty=1,Vi=26/180*Math.PI,va=Math.cos(Vi),ba=Math.sin(Vi),ny=100/Math.log(139/100),bl=({l:e,c:t,h:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"lab65",l:(Math.exp(e*ya/ny)-1)/.0039},o=(Math.exp(.0435*t*ty*ya)-1)/.075,a=o*Math.cos(n/180*Math.PI-Vi),s=o*Math.sin(n/180*Math.PI-Vi);return i.a=a*va-s/.83*ba,i.b=a*ba+s/.83*va,r!==void 0&&(i.alpha=r),i},_l=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=t*va+n*ba,o=.83*(n*va-t*ba),a=Math.sqrt(i*i+o*o),s={mode:"dlch",l:ny/ya*Math.log(1+.0039*e),c:Math.log(1+.075*a)/(.0435*ty*ya)};return s.c&&(s.h=Dt((Math.atan2(o,i)+Vi)/Math.PI*180)),r!==void 0&&(s.alpha=r),s},ry=e=>bl(tr(e,"dlch")),iy=e=>nr(_l(e),"dlab"),GM={mode:"dlab",parse:["--din99o-lab"],serialize:"--din99o-lab",toMode:{lab65:ry,rgb:e=>ga(ry(e))},fromMode:{lab65:iy,rgb:e=>iy(ma(e))},channels:["l","a","b","alpha"],ranges:{l:[0,100],a:[-40.09,45.501],b:[-40.469,44.344]},interpolate:{l:_e,a:_e,b:_e,alpha:{use:_e,fixup:Tt}}},VM={mode:"dlch",parse:["--din99o-lch"],serialize:"--din99o-lch",toMode:{lab65:bl,dlab:e=>nr(e,"dlab"),rgb:e=>ga(bl(e))},fromMode:{lab65:_l,dlab:e=>tr(e,"dlch"),rgb:e=>_l(ma(e))},channels:["l","c","h","alpha"],ranges:{l:[0,100],c:[0,51.484],h:[0,360]},interpolate:{l:_e,c:_e,h:{use:_e,fixup:Nn},alpha:{use:_e,fixup:Tt}},difference:{h:pa},average:{h:Dn}};function YM({h:e,s:t,i:n,alpha:r}){e=Dt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.abs(e/60%2-1),o;switch(Math.floor(e/60)){case 0:o={r:n*(1+t*(3/(2-i)-1)),g:n*(1+t*(3*(1-i)/(2-i)-1)),b:n*(1-t)};break;case 1:o={r:n*(1+t*(3*(1-i)/(2-i)-1)),g:n*(1+t*(3/(2-i)-1)),b:n*(1-t)};break;case 2:o={r:n*(1-t),g:n*(1+t*(3/(2-i)-1)),b:n*(1+t*(3*(1-i)/(2-i)-1))};break;case 3:o={r:n*(1-t),g:n*(1+t*(3*(1-i)/(2-i)-1)),b:n*(1+t*(3/(2-i)-1))};break;case 4:o={r:n*(1+t*(3*(1-i)/(2-i)-1)),g:n*(1-t),b:n*(1+t*(3/(2-i)-1))};break;case 5:o={r:n*(1+t*(3/(2-i)-1)),g:n*(1-t),b:n*(1+t*(3*(1-i)/(2-i)-1))};break;default:o={r:n*(1-t),g:n*(1-t),b:n*(1-t)}}return o.mode="rgb",r!==void 0&&(o.alpha=r),o}function XM({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),a={mode:"hsi",s:e+t+n===0?0:1-3*o/(e+t+n),i:(e+t+n)/3};return i-o!==0&&(a.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(a.alpha=r),a}const UM={mode:"hsi",toMode:{rgb:YM},parse:["--hsi"],serialize:"--hsi",fromMode:{rgb:XM},channels:["h","s","i","alpha"],ranges:{h:[0,360]},gamut:"rgb",interpolate:{h:{use:_e,fixup:Nn},s:_e,i:_e,alpha:{use:_e,fixup:Tt}},difference:{h:fa},average:{h:Dn}};function KM({h:e,s:t,l:n,alpha:r}){e=Dt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=n+t*(n<.5?n:1-n),o=i-(i-n)*2*Math.abs(e/60%2-1),a;switch(Math.floor(e/60)){case 0:a={r:i,g:o,b:2*n-i};break;case 1:a={r:o,g:i,b:2*n-i};break;case 2:a={r:2*n-i,g:i,b:o};break;case 3:a={r:2*n-i,g:o,b:i};break;case 4:a={r:o,g:2*n-i,b:i};break;case 5:a={r:i,g:2*n-i,b:o};break;default:a={r:2*n-i,g:2*n-i,b:2*n-i}}return a.mode="rgb",r!==void 0&&(a.alpha=r),a}function ZM({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),a={mode:"hsl",s:i===o?0:(i-o)/(1-Math.abs(i+o-1)),l:.5*(i+o)};return i-o!==0&&(a.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(a.alpha=r),a}const QM=(e,t)=>{switch(t){case"deg":return+e;case"rad":return e/Math.PI*180;case"grad":return e/10*9;case"turn":return e*360}},JM=new RegExp(`^hsla?\\(\\s*${bM}${ni}${Wi}${ni}${Wi}\\s*(?:,\\s*${ll}\\s*)?\\)$`),eE=e=>{let t=e.match(JM);if(!t)return;let n={mode:"hsl"};return t[3]!==void 0?n.h=+t[3]:t[1]!==void 0&&t[2]!==void 0&&(n.h=QM(t[1],t[2])),t[4]!==void 0&&(n.s=Math.min(Math.max(0,t[4]/100),1)),t[5]!==void 0&&(n.l=Math.min(Math.max(0,t[5]/100),1)),t[6]!==void 0?n.alpha=Math.max(0,Math.min(1,t[6]/100)):t[7]!==void 0&&(n.alpha=Math.max(0,Math.min(1,+t[7]))),n};function tE(e,t){if(!t||t[0]!=="hsl"&&t[0]!=="hsla")return;const n={mode:"hsl"},[,r,i,o,a]=t;if(r.type!==fe.None){if(r.type===fe.Percentage)return;n.h=r.value}if(i.type!==fe.None){if(i.type===fe.Hue)return;n.s=i.value/100}if(o.type!==fe.None){if(o.type===fe.Hue)return;n.l=o.value/100}return a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const oy={mode:"hsl",toMode:{rgb:KM},fromMode:{rgb:ZM},channels:["h","s","l","alpha"],ranges:{h:[0,360]},gamut:"rgb",parse:[tE,eE],serialize:e=>`hsl(${e.h!==void 0?e.h:"none"} ${e.s!==void 0?e.s*100+"%":"none"} ${e.l!==void 0?e.l*100+"%":"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:Nn},s:_e,l:_e,alpha:{use:_e,fixup:Tt}},difference:{h:fa},average:{h:Dn}};function ay({h:e,s:t,v:n,alpha:r}){e=Dt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.abs(e/60%2-1),o;switch(Math.floor(e/60)){case 0:o={r:n,g:n*(1-t*i),b:n*(1-t)};break;case 1:o={r:n*(1-t*i),g:n,b:n*(1-t)};break;case 2:o={r:n*(1-t),g:n,b:n*(1-t*i)};break;case 3:o={r:n*(1-t),g:n*(1-t*i),b:n};break;case 4:o={r:n*(1-t*i),g:n*(1-t),b:n};break;case 5:o={r:n,g:n*(1-t),b:n*(1-t*i)};break;default:o={r:n*(1-t),g:n*(1-t),b:n*(1-t)}}return o.mode="rgb",r!==void 0&&(o.alpha=r),o}function sy({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),a={mode:"hsv",s:i===0?0:1-o/i,v:i};return i-o!==0&&(a.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(a.alpha=r),a}const cy={mode:"hsv",toMode:{rgb:ay},parse:["--hsv"],serialize:"--hsv",fromMode:{rgb:sy},channels:["h","s","v","alpha"],ranges:{h:[0,360]},gamut:"rgb",interpolate:{h:{use:_e,fixup:Nn},s:_e,v:_e,alpha:{use:_e,fixup:Tt}},difference:{h:fa},average:{h:Dn}};function nE({h:e,w:t,b:n,alpha:r}){if(t===void 0&&(t=0),n===void 0&&(n=0),t+n>1){let i=t+n;t/=i,n/=i}return ay({h:e,s:n===1?1:1-t/(1-n),v:1-n,alpha:r})}function rE(e){let t=sy(e);if(t===void 0)return;let n=t.s!==void 0?t.s:0,r=t.v!==void 0?t.v:0,i={mode:"hwb",w:(1-n)*r,b:1-r};return t.h!==void 0&&(i.h=t.h),t.alpha!==void 0&&(i.alpha=t.alpha),i}function iE(e,t){if(!t||t[0]!=="hwb")return;const n={mode:"hwb"},[,r,i,o,a]=t;if(r.type!==fe.None){if(r.type===fe.Percentage)return;n.h=r.value}if(i.type!==fe.None){if(i.type===fe.Hue)return;n.w=i.value/100}if(o.type!==fe.None){if(o.type===fe.Hue)return;n.b=o.value/100}return a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const oE={mode:"hwb",toMode:{rgb:nE},fromMode:{rgb:rE},channels:["h","w","b","alpha"],ranges:{h:[0,360]},gamut:"rgb",parse:[iE],serialize:e=>`hwb(${e.h!==void 0?e.h:"none"} ${e.w!==void 0?e.w*100+"%":"none"} ${e.b!==void 0?e.b*100+"%":"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:Nn},w:_e,b:_e,alpha:{use:_e,fixup:Tt}},difference:{h:BM},average:{h:Dn}},ly=203,_a=.1593017578125,uy=78.84375,xa=.8359375,wa=18.8515625,Pa=18.6875;function xl(e){if(e<0)return 0;const t=Math.pow(e,1/uy);return 1e4*Math.pow(Math.max(0,t-xa)/(wa-Pa*t),1/_a)}function wl(e){if(e<0)return 0;const t=Math.pow(e/1e4,_a);return Math.pow((xa+wa*t)/(1+Pa*t),uy)}const Pl=e=>Math.max(e/ly,0),hy=({i:e,t,p:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i=xl(e+.008609037037932761*t+.11102962500302593*n),o=xl(e-.00860903703793275*t-.11102962500302599*n),a=xl(e+.5600313357106791*t-.32062717498731885*n),s={mode:"xyz65",x:Pl(2.070152218389422*i-1.3263473389671556*o+.2066510476294051*a),y:Pl(.3647385209748074*i+.680566024947227*o-.0453045459220346*a),z:Pl(-.049747207535812*i-.0492609666966138*o+1.1880659249923042*a)};return r!==void 0&&(s.alpha=r),s},$l=(e=0)=>Math.max(e*ly,0),dy=({x:e,y:t,z:n,alpha:r})=>{const i=$l(e),o=$l(t),a=$l(n),s=wl(.3592832590121217*i+.6976051147779502*o-.0358915932320289*a),c=wl(-.1920808463704995*i+1.1004767970374323*o+.0753748658519118*a),l=wl(.0070797844607477*i+.0748396662186366*o+.8433265453898765*a),u=.5*s+.5*c,h=1.61376953125*s-3.323486328125*c+1.709716796875*l,d=4.378173828125*s-4.24560546875*c-.132568359375*l,f={mode:"itp",i:u,t:h,p:d};return r!==void 0&&(f.alpha=r),f},aE={mode:"itp",channels:["i","t","p","alpha"],parse:["--ictcp"],serialize:"--ictcp",toMode:{xyz65:hy,rgb:e=>vr(hy(e))},fromMode:{xyz65:dy,rgb:e=>dy(yr(e))},ranges:{i:[0,.581],t:[-.369,.272],p:[-.164,.331]},interpolate:{i:_e,t:_e,p:_e,alpha:{use:_e,fixup:Tt}}},sE=134.03437499999998,cE=16295499532821565e-27,Cl=e=>{if(e<0)return 0;let t=Math.pow(e/1e4,_a);return Math.pow((xa+wa*t)/(1+Pa*t),sE)},Ol=(e=0)=>Math.max(e*203,0),fy=({x:e,y:t,z:n,alpha:r})=>{e=Ol(e),t=Ol(t),n=Ol(n);let i=1.15*e-.15*n,o=.66*t+.34*e,a=Cl(.41478972*i+.579999*o+.014648*n),s=Cl(-.20151*i+1.120649*o+.0531008*n),c=Cl(-.0166008*i+.2648*o+.6684799*n),l=(a+s)/2,u={mode:"jab",j:.44*l/(1-.56*l)-cE,a:3.524*a-4.066708*s+.542708*c,b:.199076*a+1.096799*s-1.295875*c};return r!==void 0&&(u.alpha=r),u},lE=134.03437499999998,py=16295499532821565e-27,Sl=e=>{if(e<0)return 0;let t=Math.pow(e,1/lE);return 1e4*Math.pow((xa-t)/(Pa*t-wa),1/_a)},Ml=e=>e/203,gy=({j:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+py)/(.44+.56*(e+py)),o=Sl(i+.13860504*t+.058047316*n),a=Sl(i-.13860504*t-.058047316*n),s=Sl(i-.096019242*t-.8118919*n),c={mode:"xyz65",x:Ml(1.661373024652174*o-.914523081304348*a+.23136208173913045*s),y:Ml(-.3250758611844533*o+1.571847026732543*a-.21825383453227928*s),z:Ml(-.090982811*o-.31272829*a+1.5227666*s)};return r!==void 0&&(c.alpha=r),c},my=e=>{let t=fy(yr(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},yy=e=>vr(gy(e)),uE={mode:"jab",channels:["j","a","b","alpha"],parse:["--jzazbz"],serialize:"--jzazbz",fromMode:{rgb:my,xyz65:fy},toMode:{rgb:yy,xyz65:gy},ranges:{j:[0,.222],a:[-.109,.129],b:[-.185,.134]},interpolate:{j:_e,a:_e,b:_e,alpha:{use:_e,fixup:Tt}}},vy=({j:e,a:t,b:n,alpha:r})=>{t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.sqrt(t*t+n*n),o={mode:"jch",j:e,c:i};return i&&(o.h=Dt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(o.alpha=r),o},by=({j:e,c:t,h:n,alpha:r})=>{n===void 0&&(n=0);let i={mode:"jab",j:e,a:t?t*Math.cos(n/180*Math.PI):0,b:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(i.alpha=r),i},hE={mode:"jch",parse:["--jzczhz"],serialize:"--jzczhz",toMode:{jab:by,rgb:e=>yy(by(e))},fromMode:{rgb:e=>vy(my(e)),jab:vy},channels:["j","c","h","alpha"],ranges:{j:[0,.221],c:[0,.19],h:[0,360]},interpolate:{h:{use:_e,fixup:Nn},c:_e,j:_e,alpha:{use:_e,fixup:Tt}},difference:{h:pa},average:{h:Dn}},$a=Math.pow(29,3)/Math.pow(3,3),El=Math.pow(6,3)/Math.pow(29,3);let Il=e=>Math.pow(e,3)>El?Math.pow(e,3):(116*e-16)/$a;const Al=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+16)/116,o=t/500+i,a=i-n/200,s={mode:"xyz50",x:Il(o)*Mt.X,y:Il(i)*Mt.Y,z:Il(a)*Mt.Z};return r!==void 0&&(s.alpha=r),s},Yi=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=oi({r:e*3.1341359569958707-t*1.6173863321612538-.4906619460083532*n,g:e*-.978795502912089+t*1.916254567259524+.03344273116131949*n,b:e*.07195537988411677-t*.2289768264158322+1.405386058324125*n});return r!==void 0&&(i.alpha=r),i},_y=e=>Yi(Al(e)),Xi=e=>{let{r:t,g:n,b:r,alpha:i}=ii(e),o={mode:"xyz50",x:.436065742824811*t+.3851514688337912*n+.14307845442264197*r,y:.22249319175623702*t+.7168870538238823*n+.06061979053616537*r,z:.013923904500943465*t+.09708128566574634*n+.7140993584005155*r};return i!==void 0&&(o.alpha=i),o},Tl=e=>e>El?Math.cbrt(e):($a*e+16)/116,kl=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Tl(e/Mt.X),o=Tl(t/Mt.Y),a=Tl(n/Mt.Z),s={mode:"lab",l:116*o-16,a:500*(i-o),b:200*(o-a)};return r!==void 0&&(s.alpha=r),s},xy=e=>{let t=kl(Xi(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t};function dE(e,t){if(!t||t[0]!=="lab")return;const n={mode:"lab"},[,r,i,o,a]=t;if(!(r.type===fe.Hue||i.type===fe.Hue||o.type===fe.Hue))return r.type!==fe.None&&(n.l=Math.min(Math.max(0,r.value),100)),i.type!==fe.None&&(n.a=i.type===fe.Number?i.value:i.value*125/100),o.type!==fe.None&&(n.b=o.type===fe.Number?o.value:o.value*125/100),a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const Rl={mode:"lab",toMode:{xyz50:Al,rgb:_y},fromMode:{xyz50:kl,rgb:xy},channels:["l","a","b","alpha"],ranges:{l:[0,100],a:[-125,125],b:[-125,125]},parse:[dE],serialize:e=>`lab(${e.l!==void 0?e.l:"none"} ${e.a!==void 0?e.a:"none"} ${e.b!==void 0?e.b:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{l:_e,a:_e,b:_e,alpha:{use:_e,fixup:Tt}}},fE=Kt(At({},Rl),{mode:"lab65",parse:["--lab-d65"],serialize:"--lab-d65",toMode:{xyz65:Jm,rgb:ga},fromMode:{xyz65:ey,rgb:ma},ranges:{l:[0,100],a:[-125,125],b:[-125,125]}});function pE(e,t){if(!t||t[0]!=="lch")return;const n={mode:"lch"},[,r,i,o,a]=t;if(r.type!==fe.None){if(r.type===fe.Hue)return;n.l=Math.min(Math.max(0,r.value),100)}if(i.type!==fe.None&&(n.c=Math.max(0,i.type===fe.Number?i.value:i.value*150/100)),o.type!==fe.None){if(o.type===fe.Percentage)return;n.h=o.value}return a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const Ll={mode:"lch",toMode:{lab:nr,rgb:e=>_y(nr(e))},fromMode:{rgb:e=>tr(xy(e)),lab:tr},channels:["l","c","h","alpha"],ranges:{l:[0,100],c:[0,150],h:[0,360]},parse:[pE],serialize:e=>`lch(${e.l!==void 0?e.l:"none"} ${e.c!==void 0?e.c:"none"} ${e.h!==void 0?e.h:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:Nn},c:_e,l:_e,alpha:{use:_e,fixup:Tt}},difference:{h:pa},average:{h:Dn}},gE=Kt(At({},Ll),{mode:"lch65",parse:["--lch-d65"],serialize:"--lch-d65",toMode:{lab65:e=>nr(e,"lab65"),rgb:e=>ga(nr(e,"lab65"))},fromMode:{rgb:e=>tr(ma(e),"lch65"),lab65:e=>tr(e,"lch65")},ranges:{l:[0,100],c:[0,150],h:[0,360]}}),wy=({l:e,u:t,v:n,alpha:r})=>{t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.sqrt(t*t+n*n),o={mode:"lchuv",l:e,c:i};return i&&(o.h=Dt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(o.alpha=r),o},Py=({l:e,c:t,h:n,alpha:r})=>{n===void 0&&(n=0);let i={mode:"luv",l:e,u:t?t*Math.cos(n/180*Math.PI):0,v:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(i.alpha=r),i},$y=(e,t,n)=>4*e/(e+15*t+3*n),Cy=(e,t,n)=>9*t/(e+15*t+3*n),mE=$y(Mt.X,Mt.Y,Mt.Z),yE=Cy(Mt.X,Mt.Y,Mt.Z),vE=e=>e<=El?$a*e:116*Math.cbrt(e)-16,zl=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=vE(t/Mt.Y),o=$y(e,t,n),a=Cy(e,t,n);!isFinite(o)||!isFinite(a)?i=o=a=0:(o=13*i*(o-mE),a=13*i*(a-yE));let s={mode:"luv",l:i,u:o,v:a};return r!==void 0&&(s.alpha=r),s},bE=(e,t,n)=>4*e/(e+15*t+3*n),_E=(e,t,n)=>9*t/(e+15*t+3*n),xE=bE(Mt.X,Mt.Y,Mt.Z),wE=_E(Mt.X,Mt.Y,Mt.Z),Nl=({l:e,u:t,v:n,alpha:r})=>{if(e===void 0&&(e=0),e===0)return{mode:"xyz50",x:0,y:0,z:0};t===void 0&&(t=0),n===void 0&&(n=0);let i=t/(13*e)+xE,o=n/(13*e)+wE,a=Mt.Y*(e<=8?e/$a:Math.pow((e+16)/116,3)),s=a*(9*i)/(4*o),c=a*(12-3*i-20*o)/(4*o),l={mode:"xyz50",x:s,y:a,z:c};return r!==void 0&&(l.alpha=r),l},PE={mode:"lchuv",toMode:{luv:Py,rgb:e=>Yi(Nl(Py(e)))},fromMode:{rgb:e=>wy(zl(Xi(e))),luv:wy},channels:["l","c","h","alpha"],parse:["--lchuv"],serialize:"--lchuv",ranges:{l:[0,100],c:[0,176.956],h:[0,360]},interpolate:{h:{use:_e,fixup:Nn},c:_e,l:_e,alpha:{use:_e,fixup:Tt}},difference:{h:pa},average:{h:Dn}},$E=Kt(At({},ri),{mode:"lrgb",toMode:{rgb:oi},fromMode:{rgb:ii},parse:["srgb-linear"],serialize:"srgb-linear"}),CE={mode:"luv",toMode:{xyz50:Nl,rgb:e=>Yi(Nl(e))},fromMode:{xyz50:zl,rgb:e=>zl(Xi(e))},channels:["l","u","v","alpha"],parse:["--luv"],serialize:"--luv",ranges:{l:[0,100],u:[-84.936,175.042],v:[-125.882,87.243]},interpolate:{l:_e,u:_e,v:_e,alpha:{use:_e,fixup:Tt}}},Oy=({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.cbrt(.412221469470763*e+.5363325372617348*t+.0514459932675022*n),o=Math.cbrt(.2119034958178252*e+.6806995506452344*t+.1073969535369406*n),a=Math.cbrt(.0883024591900564*e+.2817188391361215*t+.6299787016738222*n),s={mode:"oklab",l:.210454268309314*i+.7936177747023054*o-.0040720430116193*a,a:1.9779985324311684*i-2.42859224204858*o+.450593709617411*a,b:.0259040424655478*i+.7827717124575296*o-.8086757549230774*a};return r!==void 0&&(s.alpha=r),s},Ca=e=>{let t=Oy(ii(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},Ui=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.pow(e+.3963377773761749*t+.2158037573099136*n,3),o=Math.pow(e-.1055613458156586*t-.0638541728258133*n,3),a=Math.pow(e-.0894841775298119*t-1.2914855480194092*n,3),s={mode:"lrgb",r:4.076741636075957*i-3.3077115392580616*o+.2309699031821044*a,g:-1.2684379732850317*i+2.6097573492876887*o-.3413193760026573*a,b:-.0041960761386756*i-.7034186179359362*o+1.7076146940746117*a};return r!==void 0&&(s.alpha=r),s},Oa=e=>oi(Ui(e));function Dl(e){const r=1.170873786407767;return .5*(r*e-.206+Math.sqrt((r*e-.206)*(r*e-.206)+4*.03*r*e))}function Sa(e){return(e*e+.206*e)/(1.170873786407767*(e+.03))}function OE(e,t){let n,r,i,o,a,s,c,l;-1.88170328*e-.80936493*t>1?(n=1.19086277,r=1.76576728,i=.59662641,o=.75515197,a=.56771245,s=4.0767416621,c=-3.3077115913,l=.2309699292):1.81444104*e-1.19445276*t>1?(n=.73956515,r=-.45954404,i=.08285427,o=.1254107,a=.14503204,s=-1.2684380046,c=2.6097574011,l=-.3413193965):(n=1.35733652,r=-.00915799,i=-1.1513021,o=-.50559606,a=.00692167,s=-.0041960863,c=-.7034186147,l=1.707614701);let u=n+r*e+i*t+o*e*e+a*e*t,h=.3963377774*e+.2158037573*t,d=-.1055613458*e-.0638541728*t,f=-.0894841775*e-1.291485548*t;{let g=1+u*h,y=1+u*d,m=1+u*f,v=g*g*g,b=y*y*y,_=m*m*m,x=3*h*g*g,w=3*d*y*y,P=3*f*m*m,$=6*h*h*g,C=6*d*d*y,M=6*f*f*m,S=s*v+c*b+l*_,E=s*x+c*w+l*P,A=s*$+c*C+l*M;u=u-S*E/(E*E-.5*S*A)}return u}function Hl(e,t){let n=OE(e,t),r=Ui({l:1,a:n*e,b:n*t}),i=Math.cbrt(1/Math.max(r.r,r.g,r.b)),o=i*n;return[i,o]}function SE(e,t,n,r,i,o=null){o||(o=Hl(e,t));let a;if((n-i)*o[1]-(o[0]-i)*r<=0)a=o[1]*i/(r*o[0]+o[1]*(i-n));else{a=o[1]*(i-1)/(r*(o[0]-1)+o[1]*(i-n));{let s=n-i,c=r,l=.3963377774*e+.2158037573*t,u=-.1055613458*e-.0638541728*t,h=-.0894841775*e-1.291485548*t,d=s+c*l,f=s+c*u,g=s+c*h;{let y=i*(1-a)+a*n,m=a*r,v=y+m*l,b=y+m*u,_=y+m*h,x=v*v*v,w=b*b*b,P=_*_*_,$=3*d*v*v,C=3*f*b*b,M=3*g*_*_,S=6*d*d*v,E=6*f*f*b,A=6*g*g*_,O=4.0767416621*x-3.3077115913*w+.2309699292*P-1,T=4.0767416621*$-3.3077115913*C+.2309699292*M,F=4.0767416621*S-3.3077115913*E+.2309699292*A,z=T/(T*T-.5*O*F),j=-O*z,D=-1.2684380046*x+2.6097574011*w-.3413193965*P-1,W=-1.2684380046*$+2.6097574011*C-.3413193965*M,B=-1.2684380046*S+2.6097574011*E-.3413193965*A,X=W/(W*W-.5*D*B),H=-D*X,k=-.0041960863*x-.7034186147*w+1.707614701*P-1,I=-.0041960863*$-.7034186147*C+1.707614701*M,R=-.0041960863*S-.7034186147*E+1.707614701*A,N=I/(I*I-.5*k*R),q=-k*N;j=z>=0?j:1e6,H=X>=0?H:1e6,q=N>=0?q:1e6,a+=Math.min(j,Math.min(H,q))}}}return a}function ql(e,t,n=null){n||(n=Hl(e,t));let r=n[0],i=n[1];return[i/r,i/(1-r)]}function Sy(e,t,n){let r=Hl(t,n),i=SE(t,n,e,1,e,r),o=ql(t,n,r),a=.11516993+1/(7.4477897+4.1590124*n+t*(-2.19557347+1.75198401*n+t*(-2.13704948-10.02301043*n+t*(-4.24894561+5.38770819*n+4.69891013*t)))),s=.11239642+1/(1.6132032-.68124379*n+t*(.40370612+.90148123*n+t*(-.27087943+.6122399*n+t*(.00299215-.45399568*n-.14661872*t)))),c=i/Math.min(e*o[0],(1-e)*o[1]),l=e*a,u=(1-e)*s,h=.9*c*Math.sqrt(Math.sqrt(1/(1/(l*l*l*l)+1/(u*u*u*u))));return l=e*.4,u=(1-e)*.8,[Math.sqrt(1/(1/(l*l)+1/(u*u))),h,i]}function My(e){const t=e.l!==void 0?e.l:0,n=e.a!==void 0?e.a:0,r=e.b!==void 0?e.b:0,i={mode:"okhsl",l:Dl(t)};e.alpha!==void 0&&(i.alpha=e.alpha);let o=Math.sqrt(n*n+r*r);if(!o)return i.s=0,i;let[a,s,c]=Sy(t,n/o,r/o),l;if(o<s){let u=0,h=.8*a,d=1-h/s;l=(o-u)/(h+d*(o-u))*.8}else{let u=s,h=.2*s*s*1.25*1.25/a,d=1-h/(c-s);l=.8+.2*((o-u)/(h+d*(o-u)))}return l&&(i.s=l,i.h=Dt(Math.atan2(r,n)*180/Math.PI)),i}function Ey(e){let t=e.h!==void 0?e.h:0,n=e.s!==void 0?e.s:0,r=e.l!==void 0?e.l:0;const i={mode:"oklab",l:Sa(r)};if(e.alpha!==void 0&&(i.alpha=e.alpha),!n||r===1)return i.a=i.b=0,i;let o=Math.cos(t/180*Math.PI),a=Math.sin(t/180*Math.PI),[s,c,l]=Sy(i.l,o,a),u,h,d,f;n<.8?(u=1.25*n,h=0,d=.8*s,f=1-d/c):(u=5*(n-.8),h=c,d=.2*c*c*1.25*1.25/s,f=1-d/(l-c));let g=h+u*d/(1-f*u);return i.a=g*o,i.b=g*a,i}const ME=Kt(At({},oy),{mode:"okhsl",channels:["h","s","l","alpha"],parse:["--okhsl"],serialize:"--okhsl",fromMode:{oklab:My,rgb:e=>My(Ca(e))},toMode:{oklab:Ey,rgb:e=>Oa(Ey(e))}});function Iy(e){let t=e.l!==void 0?e.l:0,n=e.a!==void 0?e.a:0,r=e.b!==void 0?e.b:0,i=Math.sqrt(n*n+r*r),o=i?n/i:1,a=i?r/i:1,[s,c]=ql(o,a),l=.5,u=1-l/s,h=c/(i+t*c),d=h*t,f=h*i,g=Sa(d),y=f*g/d,m=Ui({l:g,a:o*y,b:a*y}),v=Math.cbrt(1/Math.max(m.r,m.g,m.b,0));t=t/v,i=i/v*Dl(t)/t,t=Dl(t);const b={mode:"okhsv",s:i?(l+c)*f/(c*l+c*u*f):0,v:t?t/d:0};return b.s&&(b.h=Dt(Math.atan2(r,n)*180/Math.PI)),e.alpha!==void 0&&(b.alpha=e.alpha),b}function Ay(e){const t={mode:"oklab"};e.alpha!==void 0&&(t.alpha=e.alpha);const n=e.h!==void 0?e.h:0,r=e.s!==void 0?e.s:0,i=e.v!==void 0?e.v:0,o=Math.cos(n/180*Math.PI),a=Math.sin(n/180*Math.PI),[s,c]=ql(o,a),l=.5,u=1-l/s,h=1-r*l/(l+c-c*u*r),d=r*c*l/(l+c-c*u*r),f=Sa(h),g=d*f/h,y=Ui({l:f,a:o*g,b:a*g}),m=Math.cbrt(1/Math.max(y.r,y.g,y.b,0)),v=Sa(i*h),b=d*v/h;return t.l=v*m,t.a=b*o*m,t.b=b*a*m,t}const EE=Kt(At({},cy),{mode:"okhsv",channels:["h","s","v","alpha"],parse:["--okhsv"],serialize:"--okhsv",fromMode:{oklab:Iy,rgb:e=>Iy(Ca(e))},toMode:{oklab:Ay,rgb:e=>Oa(Ay(e))}});function IE(e,t){if(!t||t[0]!=="oklab")return;const n={mode:"oklab"},[,r,i,o,a]=t;if(!(r.type===fe.Hue||i.type===fe.Hue||o.type===fe.Hue))return r.type!==fe.None&&(n.l=Math.min(Math.max(0,r.type===fe.Number?r.value:r.value/100),1)),i.type!==fe.None&&(n.a=i.type===fe.Number?i.value:i.value*.4/100),o.type!==fe.None&&(n.b=o.type===fe.Number?o.value:o.value*.4/100),a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const AE=Kt(At({},Rl),{mode:"oklab",toMode:{lrgb:Ui,rgb:Oa},fromMode:{lrgb:Oy,rgb:Ca},ranges:{l:[0,1],a:[-.4,.4],b:[-.4,.4]},parse:[IE],serialize:e=>`oklab(${e.l!==void 0?e.l:"none"} ${e.a!==void 0?e.a:"none"} ${e.b!==void 0?e.b:"none"}${e.alpha<1?` / ${e.alpha}`:""})`});function TE(e,t){if(!t||t[0]!=="oklch")return;const n={mode:"oklch"},[,r,i,o,a]=t;if(r.type!==fe.None){if(r.type===fe.Hue)return;n.l=Math.min(Math.max(0,r.type===fe.Number?r.value:r.value/100),1)}if(i.type!==fe.None&&(n.c=Math.max(0,i.type===fe.Number?i.value:i.value*.4/100)),o.type!==fe.None){if(o.type===fe.Percentage)return;n.h=o.value}return a.type!==fe.None&&(n.alpha=Math.min(1,Math.max(0,a.type===fe.Number?a.value:a.value/100))),n}const Ty=Kt(At({},Ll),{mode:"oklch",toMode:{oklab:e=>nr(e,"oklab"),rgb:e=>Oa(nr(e,"oklab"))},fromMode:{rgb:e=>tr(Ca(e),"oklch"),oklab:e=>tr(e,"oklch")},parse:[TE],serialize:e=>`oklch(${e.l!==void 0?e.l:"none"} ${e.c!==void 0?e.c:"none"} ${e.h!==void 0?e.h:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,ranges:{l:[0,1],c:[0,.4],h:[0,360]}}),ky=e=>{let{r:t,g:n,b:r,alpha:i}=ii(e),o={mode:"xyz65",x:.486570948648216*t+.265667693169093*n+.1982172852343625*r,y:.2289745640697487*t+.6917385218365062*n+.079286914093745*r,z:0*t+.0451133818589026*n+1.043944368900976*r};return i!==void 0&&(o.alpha=i),o},Ry=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=oi({r:e*2.4934969119414263-t*.9313836179191242-.402710784450717*n,g:e*-.8294889695615749+t*1.7626640603183465+.0236246858419436*n,b:e*.0358458302437845-t*.0761723892680418+.9568845240076871*n},"p3");return r!==void 0&&(i.alpha=r),i},kE=Kt(At({},ri),{mode:"p3",parse:["display-p3"],serialize:"display-p3",fromMode:{rgb:e=>Ry(yr(e)),xyz65:Ry},toMode:{rgb:e=>vr(ky(e)),xyz65:ky}}),jl=e=>{let t=Math.abs(e);return t>=1/512?Math.sign(e)*Math.pow(t,1/1.8):16*e},Ly=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"prophoto",r:jl(e*1.3457868816471585-t*.2555720873797946-.0511018649755453*n),g:jl(e*-.5446307051249019+t*1.5082477428451466+.0205274474364214*n),b:jl(e*0+t*0+1.2119675456389452*n)};return r!==void 0&&(i.alpha=r),i},Fl=(e=0)=>{let t=Math.abs(e);return t>=16/512?Math.sign(e)*Math.pow(t,1.8):e/16},zy=e=>{let t=Fl(e.r),n=Fl(e.g),r=Fl(e.b),i={mode:"xyz50",x:.7977666449006423*t+.1351812974005331*n+.0313477341283922*r,y:.2880748288194013*t+.7118352342418731*n+899369387256e-16*r,z:0*t+0*n+.8251046025104602*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},RE=Kt(At({},ri),{mode:"prophoto",parse:["prophoto-rgb"],serialize:"prophoto-rgb",fromMode:{xyz50:Ly,rgb:e=>Ly(Xi(e))},toMode:{xyz50:zy,rgb:e=>Yi(zy(e))}}),Ny=1.09929682680944,LE=.018053968510807,Bl=e=>{const t=Math.abs(e);return t>LE?(Math.sign(e)||1)*(Ny*Math.pow(t,.45)-(Ny-1)):4.5*e},Dy=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"rec2020",r:Bl(e*1.7166511879712683-t*.3556707837763925-.2533662813736599*n),g:Bl(e*-.6666843518324893+t*1.6164812366349395+.0157685458139111*n),b:Bl(e*.0176398574453108-t*.0427706132578085+.9421031212354739*n)};return r!==void 0&&(i.alpha=r),i},Hy=1.09929682680944,zE=.018053968510807,Wl=(e=0)=>{let t=Math.abs(e);return t<zE*4.5?e/4.5:(Math.sign(e)||1)*Math.pow((t+Hy-1)/Hy,1/.45)},qy=e=>{let t=Wl(e.r),n=Wl(e.g),r=Wl(e.b),i={mode:"xyz65",x:.6369580483012911*t+.1446169035862083*n+.1688809751641721*r,y:.262700212011267*t+.6779980715188708*n+.059301716469862*r,z:0*t+.0280726930490874*n+1.0609850577107909*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},NE=Kt(At({},ri),{mode:"rec2020",fromMode:{xyz65:Dy,rgb:e=>Dy(yr(e))},toMode:{xyz65:qy,rgb:e=>vr(qy(e))},parse:["rec2020"],serialize:"rec2020"}),br=.0037930732552754493,jy=Math.cbrt(br),Gl=e=>Math.cbrt(e)-jy,DE=e=>{const{r:t,g:n,b:r,alpha:i}=ii(e),o=Gl(.3*t+.622*n+.078*r+br),a=Gl(.23*t+.692*n+.078*r+br),s=Gl(.2434226892454782*t+.2047674442449682*n+.5518098665095535*r+br),c={mode:"xyb",x:(o-a)/2,y:(o+a)/2,b:s-(o+a)/2};return i!==void 0&&(c.alpha=i),c},Vl=e=>Math.pow(e+jy,3),HE={mode:"xyb",channels:["x","y","b","alpha"],parse:["--xyb"],serialize:"--xyb",toMode:{rgb:({x:e,y:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i=Vl(e+t)-br,o=Vl(t-e)-br,a=Vl(n+t)-br,s=oi({r:11.031566904639861*i-9.866943908131562*o-.16462299650829934*a,g:-3.2541473810744237*i+4.418770377582723*o-.16462299650829934*a,b:-3.6588512867136815*i+2.7129230459360922*o+1.9459282407775895*a});return r!==void 0&&(s.alpha=r),s}},fromMode:{rgb:DE},ranges:{x:[-.0154,.0281],y:[0,.8453],b:[-.2778,.388]},interpolate:{x:_e,y:_e,b:_e,alpha:{use:_e,fixup:Tt}}},qE={mode:"xyz50",parse:["xyz-d50"],serialize:"xyz-d50",toMode:{rgb:Yi,lab:kl},fromMode:{rgb:Xi,lab:Al},channels:["x","y","z","alpha"],ranges:{x:[0,.964],y:[0,.999],z:[0,.825]},interpolate:{x:_e,y:_e,z:_e,alpha:{use:_e,fixup:Tt}}},jE={mode:"xyz65",toMode:{rgb:vr,xyz50:e=>{let{x:t,y:n,z:r,alpha:i}=e;t===void 0&&(t=0),n===void 0&&(n=0),r===void 0&&(r=0);let o={mode:"xyz50",x:1.0479298208405488*t+.0229467933410191*n-.0501922295431356*r,y:.0296278156881593*t+.990434484573249*n-.0170738250293851*r,z:-.0092430581525912*t+.0150551448965779*n+.7518742899580008*r};return i!==void 0&&(o.alpha=i),o}},fromMode:{rgb:yr,xyz50:e=>{let{x:t,y:n,z:r,alpha:i}=e;t===void 0&&(t=0),n===void 0&&(n=0),r===void 0&&(r=0);let o={mode:"xyz65",x:.9554734527042182*t-.0230985368742614*n+.0632593086610217*r,y:-.0283697069632081*t+1.0099954580058226*n+.021041398966943*r,z:.0123140016883199*t-.0205076964334779*n+1.3303659366080753*r};return i!==void 0&&(o.alpha=i),o}},ranges:{x:[0,.95],y:[0,1],z:[0,1.088]},channels:["x","y","z","alpha"],parse:["xyz","xyz-d65"],serialize:"xyz-d65",interpolate:{x:_e,y:_e,z:_e,alpha:{use:_e,fixup:Tt}}},FE={mode:"yiq",toMode:{rgb:({y:e,i:t,q:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i={mode:"rgb",r:e+.95608445*t+.6208885*n,g:e-.27137664*t-.6486059*n,b:e-1.10561724*t+1.70250126*n};return r!==void 0&&(i.alpha=r),i}},fromMode:{rgb:({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i={mode:"yiq",y:.29889531*e+.58662247*t+.11448223*n,i:.59597799*e-.2741761*t-.32180189*n,q:.21147017*e-.52261711*t+.31114694*n};return r!==void 0&&(i.alpha=r),i}},channels:["y","i","q","alpha"],parse:["--yiq"],serialize:"--yiq",ranges:{i:[-.595,.595],q:[-.522,.522]},interpolate:{y:_e,i:_e,q:_e,alpha:{use:_e,fixup:Tt}}},BE=e=>Math.max(0,Math.min(1,e||0)),Ma=e=>Math.round(BE(e)*255),Fy=ul("rgb"),By=e=>{if(e===void 0)return;let t=Ma(e.r),n=Ma(e.g),r=Ma(e.b);return"#"+(1<<24|t<<16|n<<8|r).toString(16).slice(1)},WE=e=>{if(e===void 0)return;let t=Ma(e.alpha!==void 0?e.alpha:1);return By(e)+(256|t).toString(16).slice(1)},Ki=e=>By(Fy(e)),GE=e=>WE(Fy(e));function Yl(e){let t=ul("lrgb")(e);return .2126*t.r+.7152*t.g+.0722*t.b}function Xl(e,t){let n=Yl(e),r=Yl(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}it(NM),it(WM),it(GM),it(VM),it(UM),it(oy),it(cy),it(oE),it(aE),it(uE),it(hE),it(Rl),it(fE),it(Ll),it(gE),it(PE),it($E),it(CE),it(ME),it(EE),it(AE);const Wy=it(Ty);it(kE),it(RE),it(NE),it(ri),it(HE),it(qE),it(jE),it(FE);function _r(e){if(!e)return!1;const t=e.trim().toLowerCase();return!(t==="none"||t==="transparent"||t==="")}function Gy(e){const t=$n(e);return t?Yl(t)<.5:!1}var Vy=typeof global=="object"&&global&&global.Object===Object&&global,VE=typeof self=="object"&&self&&self.Object===Object&&self,Cn=Vy||VE||Function("return this")(),rr=Cn.Symbol,Yy=Object.prototype,YE=Yy.hasOwnProperty,XE=Yy.toString,Zi=rr?rr.toStringTag:void 0;function UE(e){var t=YE.call(e,Zi),n=e[Zi];try{e[Zi]=void 0;var r=!0}catch(o){}var i=XE.call(e);return r&&(t?e[Zi]=n:delete e[Zi]),i}var KE=Object.prototype,ZE=KE.toString;function QE(e){return ZE.call(e)}var JE="[object Null]",eI="[object Undefined]",Xy=rr?rr.toStringTag:void 0;function xr(e){return e==null?e===void 0?eI:JE:Xy&&Xy in Object(e)?UE(e):QE(e)}function ir(e){return e!=null&&typeof e=="object"}var tI="[object Symbol]";function Ea(e){return typeof e=="symbol"||ir(e)&&xr(e)==tI}function nI(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var or=Array.isArray,Uy=rr?rr.prototype:void 0,Ky=Uy?Uy.toString:void 0;function Zy(e){if(typeof e=="string")return e;if(or(e))return nI(e,Zy)+"";if(Ea(e))return Ky?Ky.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var rI=/\s/;function iI(e){for(var t=e.length;t--&&rI.test(e.charAt(t)););return t}var oI=/^\s+/;function aI(e){return e&&e.slice(0,iI(e)+1).replace(oI,"")}function On(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Qy=NaN,sI=/^[-+]0x[0-9a-f]+$/i,cI=/^0b[01]+$/i,lI=/^0o[0-7]+$/i,uI=parseInt;function Ul(e){if(typeof e=="number")return e;if(Ea(e))return Qy;if(On(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=On(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=aI(e);var n=cI.test(e);return n||lI.test(e)?uI(e.slice(2),n?2:8):sI.test(e)?Qy:+e}function Jy(e){return e}var hI="[object AsyncFunction]",dI="[object Function]",fI="[object GeneratorFunction]",pI="[object Proxy]";function Kl(e){if(!On(e))return!1;var t=xr(e);return t==dI||t==fI||t==hI||t==pI}var Zl=Cn["__core-js_shared__"],e2=(function(){var e=/[^.]+$/.exec(Zl&&Zl.keys&&Zl.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function gI(e){return!!e2&&e2 in e}var mI=Function.prototype,yI=mI.toString;function wr(e){if(e!=null){try{return yI.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var vI=/[\\^$.*+?()[\]{}|]/g,bI=/^\[object .+?Constructor\]$/,_I=Function.prototype,xI=Object.prototype,wI=_I.toString,PI=xI.hasOwnProperty,$I=RegExp("^"+wI.call(PI).replace(vI,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function CI(e){if(!On(e)||gI(e))return!1;var t=Kl(e)?$I:bI;return t.test(wr(e))}function OI(e,t){return e==null?void 0:e[t]}function Pr(e,t){var n=OI(e,t);return CI(n)?n:void 0}var Ql=Pr(Cn,"WeakMap"),t2=Object.create,SI=(function(){function e(){}return function(t){if(!On(t))return{};if(t2)return t2(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}})();function MI(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function EI(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var II=800,AI=16,TI=Date.now;function kI(e){var t=0,n=0;return function(){var r=TI(),i=AI-(r-n);if(n=r,i>0){if(++t>=II)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function RI(e){return function(){return e}}var Ia=(function(){try{var e=Pr(Object,"defineProperty");return e({},"",{}),e}catch(t){}})(),LI=Ia?function(e,t){return Ia(e,"toString",{configurable:!0,enumerable:!1,value:RI(t),writable:!0})}:Jy,zI=kI(LI);function NI(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}var DI=9007199254740991,HI=/^(?:0|[1-9]\d*)$/;function n2(e,t){var n=typeof e;return t=t==null?DI:t,!!t&&(n=="number"||n!="symbol"&&HI.test(e))&&e>-1&&e%1==0&&e<t}function Jl(e,t,n){t=="__proto__"&&Ia?Ia(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Aa(e,t){return e===t||e!==e&&t!==t}var qI=Object.prototype,jI=qI.hasOwnProperty;function r2(e,t,n){var r=e[t];(!(jI.call(e,t)&&Aa(r,n))||n===void 0&&!(t in e))&&Jl(e,t,n)}function FI(e,t,n,r){var i=!n;n||(n={});for(var o=-1,a=t.length;++o<a;){var s=t[o],c=void 0;c===void 0&&(c=e[s]),i?Jl(n,s,c):r2(n,s,c)}return n}var i2=Math.max;function BI(e,t,n){return t=i2(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=i2(r.length-t,0),a=Array(o);++i<o;)a[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(a),MI(e,this,s)}}function WI(e,t){return zI(BI(e,t,Jy),e+"")}var GI=9007199254740991;function o2(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=GI}function Ta(e){return e!=null&&o2(e.length)&&!Kl(e)}function VI(e,t,n){if(!On(n))return!1;var r=typeof t;return(r=="number"?Ta(n)&&n2(t,n.length):r=="string"&&t in n)?Aa(n[t],e):!1}function YI(e){return WI(function(t,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,a=i>2?n[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,a&&VI(n[0],n[1],a)&&(o=i<3?void 0:o,i=1),t=Object(t);++r<i;){var s=n[r];s&&e(t,s,r,o)}return t})}var XI=Object.prototype;function eu(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||XI;return e===n}function UI(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var KI="[object Arguments]";function a2(e){return ir(e)&&xr(e)==KI}var s2=Object.prototype,ZI=s2.hasOwnProperty,QI=s2.propertyIsEnumerable,tu=a2((function(){return arguments})())?a2:function(e){return ir(e)&&ZI.call(e,"callee")&&!QI.call(e,"callee")};function JI(){return!1}var c2=typeof V=="object"&&V&&!V.nodeType&&V,l2=c2&&typeof module=="object"&&module&&!module.nodeType&&module,eA=l2&&l2.exports===c2,u2=eA?Cn.Buffer:void 0,tA=u2?u2.isBuffer:void 0,nu=tA||JI,nA="[object Arguments]",rA="[object Array]",iA="[object Boolean]",oA="[object Date]",aA="[object Error]",sA="[object Function]",cA="[object Map]",lA="[object Number]",uA="[object Object]",hA="[object RegExp]",dA="[object Set]",fA="[object String]",pA="[object WeakMap]",gA="[object ArrayBuffer]",mA="[object DataView]",yA="[object Float32Array]",vA="[object Float64Array]",bA="[object Int8Array]",_A="[object Int16Array]",xA="[object Int32Array]",wA="[object Uint8Array]",PA="[object Uint8ClampedArray]",$A="[object Uint16Array]",CA="[object Uint32Array]",gt={};gt[yA]=gt[vA]=gt[bA]=gt[_A]=gt[xA]=gt[wA]=gt[PA]=gt[$A]=gt[CA]=!0,gt[nA]=gt[rA]=gt[gA]=gt[iA]=gt[mA]=gt[oA]=gt[aA]=gt[sA]=gt[cA]=gt[lA]=gt[uA]=gt[hA]=gt[dA]=gt[fA]=gt[pA]=!1;function OA(e){return ir(e)&&o2(e.length)&&!!gt[xr(e)]}function ru(e){return function(t){return e(t)}}var h2=typeof V=="object"&&V&&!V.nodeType&&V,Qi=h2&&typeof module=="object"&&module&&!module.nodeType&&module,SA=Qi&&Qi.exports===h2,iu=SA&&Vy.process,si=(function(){try{var e=Qi&&Qi.require&&Qi.require("util").types;return e||iu&&iu.binding&&iu.binding("util")}catch(t){}})(),d2=si&&si.isTypedArray,f2=d2?ru(d2):OA,MA=Object.prototype,EA=MA.hasOwnProperty;function p2(e,t){var n=or(e),r=!n&&tu(e),i=!n&&!r&&nu(e),o=!n&&!r&&!i&&f2(e),a=n||r||i||o,s=a?UI(e.length,String):[],c=s.length;for(var l in e)(t||EA.call(e,l))&&!(a&&(l=="length"||i&&(l=="offset"||l=="parent")||o&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||n2(l,c)))&&s.push(l);return s}function g2(e,t){return function(n){return e(t(n))}}var IA=g2(Object.keys,Object),AA=Object.prototype,TA=AA.hasOwnProperty;function kA(e){if(!eu(e))return IA(e);var t=[];for(var n in Object(e))TA.call(e,n)&&n!="constructor"&&t.push(n);return t}function RA(e){return Ta(e)?p2(e):kA(e)}function LA(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var zA=Object.prototype,NA=zA.hasOwnProperty;function DA(e){if(!On(e))return LA(e);var t=eu(e),n=[];for(var r in e)r=="constructor"&&(t||!NA.call(e,r))||n.push(r);return n}function m2(e){return Ta(e)?p2(e,!0):DA(e)}var HA=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qA=/^\w*$/;function jA(e,t){if(or(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Ea(e)?!0:qA.test(e)||!HA.test(e)||t!=null&&e in Object(t)}var Ji=Pr(Object,"create");function FA(){this.__data__=Ji?Ji(null):{},this.size=0}function BA(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var WA="__lodash_hash_undefined__",GA=Object.prototype,VA=GA.hasOwnProperty;function YA(e){var t=this.__data__;if(Ji){var n=t[e];return n===WA?void 0:n}return VA.call(t,e)?t[e]:void 0}var XA=Object.prototype,UA=XA.hasOwnProperty;function KA(e){var t=this.__data__;return Ji?t[e]!==void 0:UA.call(t,e)}var ZA="__lodash_hash_undefined__";function QA(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Ji&&t===void 0?ZA:t,this}function $r(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}$r.prototype.clear=FA,$r.prototype.delete=BA,$r.prototype.get=YA,$r.prototype.has=KA,$r.prototype.set=QA;function JA(){this.__data__=[],this.size=0}function ka(e,t){for(var n=e.length;n--;)if(Aa(e[n][0],t))return n;return-1}var eT=Array.prototype,tT=eT.splice;function nT(e){var t=this.__data__,n=ka(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():tT.call(t,n,1),--this.size,!0}function rT(e){var t=this.__data__,n=ka(t,e);return n<0?void 0:t[n][1]}function iT(e){return ka(this.__data__,e)>-1}function oT(e,t){var n=this.__data__,r=ka(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Hn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Hn.prototype.clear=JA,Hn.prototype.delete=nT,Hn.prototype.get=rT,Hn.prototype.has=iT,Hn.prototype.set=oT;var eo=Pr(Cn,"Map");function aT(){this.size=0,this.__data__={hash:new $r,map:new(eo||Hn),string:new $r}}function sT(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Ra(e,t){var n=e.__data__;return sT(t)?n[typeof t=="string"?"string":"hash"]:n.map}function cT(e){var t=Ra(this,e).delete(e);return this.size-=t?1:0,t}function lT(e){return Ra(this,e).get(e)}function uT(e){return Ra(this,e).has(e)}function hT(e,t){var n=Ra(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function ar(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ar.prototype.clear=aT,ar.prototype.delete=cT,ar.prototype.get=lT,ar.prototype.has=uT,ar.prototype.set=hT;var dT="Expected a function";function ou(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(dT);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(ou.Cache||ar),n}ou.Cache=ar;var fT=500;function pT(e){var t=ou(e,function(r){return n.size===fT&&n.clear(),r}),n=t.cache;return t}var gT=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,mT=/\\(\\)?/g,yT=pT(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(gT,function(n,r,i,o){t.push(i?o.replace(mT,"$1"):r||n)}),t});function to(e){return e==null?"":Zy(e)}function vT(e,t){return or(e)?e:jA(e,t)?[e]:yT(to(e))}function bT(e){if(typeof e=="string"||Ea(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function _T(e,t){t=vT(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[bT(t[n++])];return n&&n==r?e:void 0}function y2(e,t,n){var r=e==null?void 0:_T(e,t);return r===void 0?n:r}function xT(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var v2=g2(Object.getPrototypeOf,Object),wT="[object Object]",PT=Function.prototype,$T=Object.prototype,b2=PT.toString,CT=$T.hasOwnProperty,OT=b2.call(Object);function ST(e){if(!ir(e)||xr(e)!=wT)return!1;var t=v2(e);if(t===null)return!0;var n=CT.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&b2.call(n)==OT}function MT(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=Array(i);++r<i;)o[r]=e[r+t];return o}function ET(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:MT(e,t,n)}var IT="\\ud800-\\udfff",AT="\\u0300-\\u036f",TT="\\ufe20-\\ufe2f",kT="\\u20d0-\\u20ff",RT=AT+TT+kT,LT="\\ufe0e\\ufe0f",zT="\\u200d",NT=RegExp("["+zT+IT+RT+LT+"]");function _2(e){return NT.test(e)}function DT(e){return e.split("")}var x2="\\ud800-\\udfff",HT="\\u0300-\\u036f",qT="\\ufe20-\\ufe2f",jT="\\u20d0-\\u20ff",FT=HT+qT+jT,BT="\\ufe0e\\ufe0f",WT="["+x2+"]",au="["+FT+"]",su="\\ud83c[\\udffb-\\udfff]",GT="(?:"+au+"|"+su+")",w2="[^"+x2+"]",P2="(?:\\ud83c[\\udde6-\\uddff]){2}",$2="[\\ud800-\\udbff][\\udc00-\\udfff]",VT="\\u200d",C2=GT+"?",O2="["+BT+"]?",YT="(?:"+VT+"(?:"+[w2,P2,$2].join("|")+")"+O2+C2+")*",XT=O2+C2+YT,UT="(?:"+[w2+au+"?",au,P2,$2,WT].join("|")+")",KT=RegExp(su+"(?="+su+")|"+UT+XT,"g");function ZT(e){return e.match(KT)||[]}function QT(e){return _2(e)?ZT(e):DT(e)}function JT(e){return function(t){t=to(t);var n=_2(t)?QT(t):void 0,r=n?n[0]:t.charAt(0),i=n?ET(n,1).join(""):t.slice(1);return r[e]()+i}}var ek=JT("toUpperCase");function tk(e){return ek(to(e).toLowerCase())}function nk(e,t,n,r){for(var i=-1,o=e==null?0:e.length;++i<o;)n=t(n,e[i],i,e);return n}function rk(e){return function(t){return e==null?void 0:e[t]}}var ik={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},ok=rk(ik),ak=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,sk="\\u0300-\\u036f",ck="\\ufe20-\\ufe2f",lk="\\u20d0-\\u20ff",uk=sk+ck+lk,hk="["+uk+"]",dk=RegExp(hk,"g");function fk(e){return e=to(e),e&&e.replace(ak,ok).replace(dk,"")}var pk=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function gk(e){return e.match(pk)||[]}var mk=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function yk(e){return mk.test(e)}var S2="\\ud800-\\udfff",vk="\\u0300-\\u036f",bk="\\ufe20-\\ufe2f",_k="\\u20d0-\\u20ff",xk=vk+bk+_k,M2="\\u2700-\\u27bf",E2="a-z\\xdf-\\xf6\\xf8-\\xff",wk="\\xac\\xb1\\xd7\\xf7",Pk="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",$k="\\u2000-\\u206f",Ck=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",I2="A-Z\\xc0-\\xd6\\xd8-\\xde",Ok="\\ufe0e\\ufe0f",A2=wk+Pk+$k+Ck,T2="['’]",k2="["+A2+"]",Sk="["+xk+"]",R2="\\d+",Mk="["+M2+"]",L2="["+E2+"]",z2="[^"+S2+A2+R2+M2+E2+I2+"]",Ek="\\ud83c[\\udffb-\\udfff]",Ik="(?:"+Sk+"|"+Ek+")",Ak="[^"+S2+"]",N2="(?:\\ud83c[\\udde6-\\uddff]){2}",D2="[\\ud800-\\udbff][\\udc00-\\udfff]",ci="["+I2+"]",Tk="\\u200d",H2="(?:"+L2+"|"+z2+")",kk="(?:"+ci+"|"+z2+")",q2="(?:"+T2+"(?:d|ll|m|re|s|t|ve))?",j2="(?:"+T2+"(?:D|LL|M|RE|S|T|VE))?",F2=Ik+"?",B2="["+Ok+"]?",Rk="(?:"+Tk+"(?:"+[Ak,N2,D2].join("|")+")"+B2+F2+")*",Lk="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",zk="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Nk=B2+F2+Rk,Dk="(?:"+[Mk,N2,D2].join("|")+")"+Nk,Hk=RegExp([ci+"?"+L2+"+"+q2+"(?="+[k2,ci,"$"].join("|")+")",kk+"+"+j2+"(?="+[k2,ci+H2,"$"].join("|")+")",ci+"?"+H2+"+"+q2,ci+"+"+j2,zk,Lk,R2,Dk].join("|"),"g");function qk(e){return e.match(Hk)||[]}function jk(e,t,n){return e=to(e),t=t,t===void 0?yk(e)?qk(e):gk(e):e.match(t)||[]}var Fk="['’]",Bk=RegExp(Fk,"g");function W2(e){return function(t){return nk(jk(fk(t).replace(Bk,"")),e,"")}}var Wk=W2(function(e,t,n){return t=t.toLowerCase(),e+(n?tk(t):t)});function Gk(e,t,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),t!==void 0&&(e=e>=t?e:t)),e}function Vk(e,t,n){return n===void 0&&(n=t,t=void 0),n!==void 0&&(n=Ul(n),n=n===n?n:0),t!==void 0&&(t=Ul(t),t=t===t?t:0),Gk(Ul(e),t,n)}function Yk(){this.__data__=new Hn,this.size=0}function Xk(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function Uk(e){return this.__data__.get(e)}function Kk(e){return this.__data__.has(e)}var Zk=200;function Qk(e,t){var n=this.__data__;if(n instanceof Hn){var r=n.__data__;if(!eo||r.length<Zk-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new ar(r)}return n.set(e,t),this.size=n.size,this}function Cr(e){var t=this.__data__=new Hn(e);this.size=t.size}Cr.prototype.clear=Yk,Cr.prototype.delete=Xk,Cr.prototype.get=Uk,Cr.prototype.has=Kk,Cr.prototype.set=Qk;var G2=typeof V=="object"&&V&&!V.nodeType&&V,V2=G2&&typeof module=="object"&&module&&!module.nodeType&&module,Jk=V2&&V2.exports===G2,Y2=Jk?Cn.Buffer:void 0,X2=Y2?Y2.allocUnsafe:void 0;function U2(e,t){if(t)return e.slice();var n=e.length,r=X2?X2(n):new e.constructor(n);return e.copy(r),r}function eR(e,t){for(var n=-1,r=e==null?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function tR(){return[]}var nR=Object.prototype,rR=nR.propertyIsEnumerable,K2=Object.getOwnPropertySymbols,iR=K2?function(e){return e==null?[]:(e=Object(e),eR(K2(e),function(t){return rR.call(e,t)}))}:tR;function oR(e,t,n){var r=t(e);return or(e)?r:xT(r,n(e))}function aR(e){return oR(e,RA,iR)}var cu=Pr(Cn,"DataView"),lu=Pr(Cn,"Promise"),uu=Pr(Cn,"Set"),Z2="[object Map]",sR="[object Object]",Q2="[object Promise]",J2="[object Set]",ev="[object WeakMap]",tv="[object DataView]",cR=wr(cu),lR=wr(eo),uR=wr(lu),hR=wr(uu),dR=wr(Ql),qn=xr;(cu&&qn(new cu(new ArrayBuffer(1)))!=tv||eo&&qn(new eo)!=Z2||lu&&qn(lu.resolve())!=Q2||uu&&qn(new uu)!=J2||Ql&&qn(new Ql)!=ev)&&(qn=function(e){var t=xr(e),n=t==sR?e.constructor:void 0,r=n?wr(n):"";if(r)switch(r){case cR:return tv;case lR:return Z2;case uR:return Q2;case hR:return J2;case dR:return ev}return t});var fR=Object.prototype,pR=fR.hasOwnProperty;function gR(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&pR.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var nv=Cn.Uint8Array;function hu(e){var t=new e.constructor(e.byteLength);return new nv(t).set(new nv(e)),t}function mR(e,t){var n=hu(e.buffer);return new e.constructor(n,e.byteOffset,e.byteLength)}var yR=/\w*$/;function vR(e){var t=new e.constructor(e.source,yR.exec(e));return t.lastIndex=e.lastIndex,t}var rv=rr?rr.prototype:void 0,iv=rv?rv.valueOf:void 0;function bR(e){return iv?Object(iv.call(e)):{}}function ov(e,t){var n=t?hu(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var _R="[object Boolean]",xR="[object Date]",wR="[object Map]",PR="[object Number]",$R="[object RegExp]",CR="[object Set]",OR="[object String]",SR="[object Symbol]",MR="[object ArrayBuffer]",ER="[object DataView]",IR="[object Float32Array]",AR="[object Float64Array]",TR="[object Int8Array]",kR="[object Int16Array]",RR="[object Int32Array]",LR="[object Uint8Array]",zR="[object Uint8ClampedArray]",NR="[object Uint16Array]",DR="[object Uint32Array]";function HR(e,t,n){var r=e.constructor;switch(t){case MR:return hu(e);case _R:case xR:return new r(+e);case ER:return mR(e);case IR:case AR:case TR:case kR:case RR:case LR:case zR:case NR:case DR:return ov(e,n);case wR:return new r;case PR:case OR:return new r(e);case $R:return vR(e);case CR:return new r;case SR:return bR(e)}}function av(e){return typeof e.constructor=="function"&&!eu(e)?SI(v2(e)):{}}var qR="[object Map]";function jR(e){return ir(e)&&qn(e)==qR}var sv=si&&si.isMap,FR=sv?ru(sv):jR,BR="[object Set]";function WR(e){return ir(e)&&qn(e)==BR}var cv=si&&si.isSet,GR=cv?ru(cv):WR,VR=1,lv="[object Arguments]",YR="[object Array]",XR="[object Boolean]",UR="[object Date]",KR="[object Error]",uv="[object Function]",ZR="[object GeneratorFunction]",QR="[object Map]",JR="[object Number]",hv="[object Object]",eL="[object RegExp]",tL="[object Set]",nL="[object String]",rL="[object Symbol]",iL="[object WeakMap]",oL="[object ArrayBuffer]",aL="[object DataView]",sL="[object Float32Array]",cL="[object Float64Array]",lL="[object Int8Array]",uL="[object Int16Array]",hL="[object Int32Array]",dL="[object Uint8Array]",fL="[object Uint8ClampedArray]",pL="[object Uint16Array]",gL="[object Uint32Array]",dt={};dt[lv]=dt[YR]=dt[oL]=dt[aL]=dt[XR]=dt[UR]=dt[sL]=dt[cL]=dt[lL]=dt[uL]=dt[hL]=dt[QR]=dt[JR]=dt[hv]=dt[eL]=dt[tL]=dt[nL]=dt[rL]=dt[dL]=dt[fL]=dt[pL]=dt[gL]=!0,dt[KR]=dt[uv]=dt[iL]=!1;function La(e,t,n,r,i,o){var a,s=t&VR;if(a!==void 0)return a;if(!On(e))return e;var c=or(e);if(c)a=gR(e);else{var l=qn(e),u=l==uv||l==ZR;if(nu(e))return U2(e,s);if(l==hv||l==lv||u&&!i)a=u?{}:av(e);else{if(!dt[l])return i?e:{};a=HR(e,l,s)}}o||(o=new Cr);var h=o.get(e);if(h)return h;o.set(e,a),GR(e)?e.forEach(function(g){a.add(La(g,t,n,g,e,o))}):FR(e)&&e.forEach(function(g,y){a.set(y,La(g,t,n,y,e,o))});var d=aR,f=c?void 0:d(e);return NI(f||e,function(g,y){f&&(y=g,g=e[y]),r2(a,y,La(g,t,n,y,e,o))}),a}var mL=1,yL=4;function dv(e){return La(e,mL|yL)}function vL(e){return function(t,n,r){for(var i=-1,o=Object(t),a=r(t),s=a.length;s--;){var c=a[++i];if(n(o[c],c,o)===!1)break}return t}}var bL=vL();function du(e,t,n){(n!==void 0&&!Aa(e[t],n)||n===void 0&&!(t in e))&&Jl(e,t,n)}function _L(e){return ir(e)&&Ta(e)}function fu(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function xL(e){return FI(e,m2(e))}function wL(e,t,n,r,i,o,a){var s=fu(e,n),c=fu(t,n),l=a.get(c);if(l){du(e,n,l);return}var u=o?o(s,c,n+"",e,t,a):void 0,h=u===void 0;if(h){var d=or(c),f=!d&&nu(c),g=!d&&!f&&f2(c);u=c,d||f||g?or(s)?u=s:_L(s)?u=EI(s):f?(h=!1,u=U2(c,!0)):g?(h=!1,u=ov(c,!0)):u=[]:ST(c)||tu(c)?(u=s,tu(s)?u=xL(s):(!On(s)||Kl(s))&&(u=av(c))):h=!1}h&&(a.set(c,u),i(u,c,r,o,a),a.delete(c)),du(e,n,u)}function fv(e,t,n,r,i){e!==t&&bL(t,function(o,a){if(i||(i=new Cr),On(o))wL(e,t,a,n,fv,r,i);else{var s=r?r(fu(e,a),o,a+"",e,t,i):void 0;s===void 0&&(s=o),du(e,a,s)}},m2)}var PL=W2(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),pv=YI(function(e,t,n){fv(e,t,n)});function no(e,t){if(t.length===0)return{};const n=Array.isArray(e)?e[t[0]]:e.items[t[0]];if(t.length===1)return n;const r=t.slice(1).map(i=>`children[${i}]`).join(".");return y2(n,r)}function gv(e){const{structure:t,item:n,items:r}=e;return!(!t||!n||r.some(i=>!i))}const $L=new Set(["serif","sans-serif","monospace","cursive","fantasy","system-ui","-apple-system","ui-serif","ui-sans-serif","ui-monospace","ui-rounded","emoji","math","fangsong"]);function Or(e){const t=[];let n="",r=null;const i=()=>{const o=n.trim();o&&t.push(o),n=""};for(let o=0;o<e.length;o+=1){const a=e[o];if(r){n+=a,a===r&&(r=null);continue}if(a==='"'||a==="'"){r=a,n+=a;continue}if(a===","){i();continue}n+=a}return i(),t}function mv(e){const t=e.trim();return t.startsWith('"')&&t.endsWith('"')||t.startsWith("'")&&t.endsWith("'")?t.slice(1,-1):t}function CL(e){const t=e.trim();return t.startsWith('"')&&t.endsWith('"')||t.startsWith("'")&&t.endsWith("'")}function OL(e){return/^\d/.test(e)||/\s/.test(e)}function SL(e){const t=e.trim();if(!t||CL(t)||$L.has(t.toLowerCase())||!OL(t))return t;const n=t.includes('"')&&!t.includes("'")?"'":'"';return`${n}${t}${n}`}function li(e){const t=Or(e);return t.length?t.length===1?mv(t[0]):t.map(n=>mv(n)).join(", "):""}function Sr(e){const t=Or(e);return t.length?t.map(n=>SL(n)).join(", "):e.trim()}const ML={100:"thin",hairline:"thin",thin:"thin",200:"extralight",ultralight:"extralight",extralight:"extralight",300:"light",light:"light",400:"regular",normal:"regular",regular:"regular",500:"medium",medium:"medium",600:"semibold",demibold:"semibold",semibold:"semibold",700:"bold",bold:"bold",800:"extrabold",ultrabold:"extrabold",extrabold:"extrabold",900:"black",heavy:"black",black:"black",950:"extrablack",ultrablack:"extrablack",extrablack:"extrablack"};function yv(e){const t=String(e).toLowerCase();return ML[t]||"regular"}const ro=new Map,pu=new Map;let EL="sans-serif";function IL(e){return ro.has(e)?e:pu.get(e)||e}const AL={fontFamily:"sans-serif",fontWeight:400,fontStyle:"normal",unitsPerEm:2048,metrics:{ascender:2189,descender:-555,lineGap:0},glyphs:{'"':727,"%":1821,"'":391,"(":682,")":682,"*":797,"+":1196,"-":682,"<":1196,"=":1196,">":1196,"@":2079,C:1479,D:1479,F:1251,G:1593,H:1479,J:1024,M:1706,N:1479,O:1593,Q:1593,R:1479,T:1251,U:1479,W:1933,Z:1251,"^":961,_:1024,"`":682,c:1024,i:455,j:455,k:1024,l:455,m:1706,r:682,s:1024,v:1024,w:1479,x:1024,y:1024,z:1024,"{":684,"|":532,"}":684,"~":1196},glyphsByWidth:{569:" !,./:;I[\\]ft",1139:"#$0123456789?Labdeghnopqu",1366:"&ABEKPSVXY"},defaultWidth:1139};function vv(e){if(e===void 0||e==="normal")return"400";if(e==="bold")return"700";const t={thin:"100",hairline:"100","extra-light":"200","ultra-light":"200",light:"300",regular:"400",normal:"400",medium:"500","semi-bold":"600",semibold:"600","demi-bold":"600",demibold:"600","extra-bold":"800",extrabold:"800","ultra-bold":"800",ultrabold:"800",black:"900",heavy:"900","extra-black":"950",extrablack:"950","ultra-black":"950",ultrablack:"950",bolder:"900",lighter:"300"};if(typeof e=="string"){const n=e.toLowerCase();return t[n]||e}return String(e)}function bv(e){return e||"normal"}function TL(e){const t=e.fontFamily,n=vv(e.fontWeight),r=bv(e.fontStyle);if(e.aliases)for(const a of e.aliases)pu.has(a)||pu.set(a,t);if(e.glyphsByWidth){const a=At({},e.glyphs||{});for(const[s,c]of Object.entries(e.glyphsByWidth))if(typeof c=="string"){const l=Number(s);for(const u of c)a[u]=l}else a[s]=c;e=Kt(At({},e),{glyphs:a,glyphsByWidth:void 0})}ro.has(t)||ro.set(t,new Map);const i=ro.get(t);i.has(n)||i.set(n,new Map),i.get(n).set(r,e)}function kL(e,t,n){const r=IL(e||EL),i=vv(t),o=bv(n),a=ro.get(r);if(!a)return console.warn(`Font family "${r}" not registered, using fallback font data`),AL;let s=a.get(i);if(s){let l=s.get(o);if(l||o!=="normal"&&(l=s.get("normal"),l))return l;const u=s.values().next().value;if(u)return u}if(s=a.get("400"),s){let l=s.get(o);if(l||o!=="normal"&&(l=s.get("normal"),l))return l;const u=s.values().next().value;if(u)return u}const c=a.values().next().value;if(c){const l=c.values().next().value;if(l)return l}throw new Error(`No font data found for family "${r}" with weight "${i}" and style "${o}"`)}function RL(e,t){if(!t||t==="none")return e;switch(t){case"uppercase":return e.toUpperCase();case"lowercase":return e.toLowerCase();case"capitalize":return e.split(" ").map(n=>n.length===0?n:n[0].toUpperCase()+n.slice(1).toLowerCase()).join(" ");default:return e}}function _v(e){if(e===void 0)return 14;if(typeof e=="number")return e;const t=parseFloat(e);return isNaN(t)?16:t}function LL(e,t){const n=_v(e.fontSize),r=e.lineHeight;if(r===void 0){const{ascender:i,descender:o,lineGap:a=0}=t.metrics;return(i-o+a)/t.unitsPerEm*n}return typeof r=="number"?r*n:r.type==="pixel"?r.value:r.type==="percent"?r.value/100*n:n}function zL(e,t={}){var d;const n=RL(e,t.textTransform),r=kL(t.fontFamily,t.fontWeight,t.fontStyle),i=_v(t.fontSize),o=t.letterSpacing||0,a=t.wordSpacing||0;let s=0;const c=Array.from(n);for(let f=0;f<c.length;f++){const g=c[f],y=f<c.length-1?c[f+1]:void 0;let m=(d=r.glyphs)==null?void 0:d[g];m===void 0&&(m=r.defaultWidth||r.unitsPerEm/2);const v=m/r.unitsPerEm*i;if(s+=v,y&&r.kerning){const b=g+y,_=r.kerning[b];_!==void 0&&(s+=_/r.unitsPerEm*i)}f<c.length-1&&(s+=o),g===" "&&(s+=a)}const l=LL(t,r),{ascender:u}=r.metrics,h=u/r.unitsPerEm*i;return{width:s,height:l,baseline:h}}const NL={fontFamily:"Alibaba PuHuiTi",aliases:["AlibabaPuHuiTi","AlibabaPuHuiTi-Regular"],fontWeight:400,fontStyle:"normal",unitsPerEm:1e3,metrics:{ascender:1060,descender:-340,lineGap:0},glyphs:{" ":257,"!":361,'"':405,"#":600,"%":821,"&":640,"'":253,"(":359,")":359,"*":430,",":302,"-":440,".":302,"/":500,":":378,";":378,"?":431,"@":860,B:620,C:599,D:699,F:527,G:685,H:708,J:271,K:614,L:507,M:830,N:737,P:597,R:614,S:566,T:528,V:617,W:898,X:624,Y:594,Z:626,"[":294,"\\":510,"]":294,_:500,"`":346,b:635,c:497,d:635,f:349,g:636,k:518,l:286,m:921,p:635,q:636,r:379,s:479,t:337,v:526,w:828,x:516,y:527,z:506,"{":299,"|":183,"}":299," ":257,"¡":357,"¦":183,"§":479,"¨":346,"©":806,ª:483,"«":511,"":440,"®":404,"¯":346,"°":363,"´":346,"¶":593,"·":357,"¸":346,º:445,"»":511,"¼":902,"½":914,"¾":902,"¿":431,Æ:889,Ç:599,Ð:719,Ñ:737,Ý:594,Þ:597,ß:610,æ:926,ç:497,ý:527,þ:635,ÿ:527,Ć:599,ć:497,Ĉ:599,ĉ:497,Ċ:599,ċ:497,Č:599,č:497,Ď:699,ď:640,Đ:719,đ:635,Ĝ:685,ĝ:636,Ğ:685,ğ:636,Ġ:685,ġ:636,Ģ:685,ģ:636,Ĥ:708,Ħ:708,IJ:545,ij:536,Ĵ:271,Ķ:614,ķ:518,ĸ:518,Ĺ:507,ĺ:286,Ļ:507,ļ:286,Ľ:507,ľ:290,Ŀ:507,ŀ:291,Ł:507,ł:286,Ń:737,Ņ:737,Ň:737,ʼn:669,Ŋ:737,Œ:987,œ:917,Ŕ:614,ŕ:379,Ŗ:614,ŗ:379,Ř:614,ř:379,Ś:566,ś:479,Ŝ:566,ŝ:479,Ş:566,ş:479,Š:566,š:479,Ţ:528,ţ:337,Ť:528,ť:340,Ŧ:528,ŧ:337,Ŵ:898,ŵ:828,Ŷ:594,ŷ:527,Ÿ:594,Ź:626,ź:506,Ż:626,ż:506,Ž:626,ž:506,ſ:310,Ə:719,ǎ:608,ǐ:265,ǒ:614,ǔ:609,ǖ:609,ǘ:609,ǚ:609,ǜ:609,Ǽ:889,ǽ:926,Ș:566,ș:479,Ț:528,ț:337,"ʹ":255,"͵":255,";":378,"΄":346,"΅":346,Ά:670,"·":357,Έ:628,Ή:779,Ί:346,Ό:765,Ύ:726,Ώ:765,ΐ:312,Β:620,Γ:507,Ζ:626,Η:708,Κ:614,Λ:617,Μ:830,Ν:737,Π:708,Ρ:597,Σ:596,Τ:528,Υ:594,Φ:831,Χ:624,Ψ:804,Ϋ:594,έ:509,ή:643,ί:312,ΰ:593,β:610,γ:526,ε:509,ζ:465,η:643,θ:638,ι:312,κ:518,λ:514,ν:526,ξ:465,π:616,ρ:619,ς:497,σ:639,τ:437,υ:593,φ:774,χ:509,ψ:745,ω:782,ϊ:312,ϋ:593,ύ:593,ώ:782,"‐":440,"‑":440,"–":495,"—":684,"―":684,"‗":500,"‘":270,"’":270,"‚":270,"‛":270,"“":784,"”":784,"„":468,"†":500,"‡":500,"•":308,"…":1085,"‰":1174,"′":256,"″":472,"‴":689,"‵":256,"‶":472,"‷":689,"‹":312,"›":312,"‼":589,"‽":433,"‾":500,"⁄":120,"⁺":407,"⁻":407,"⁼":407,"⁽":225,"⁾":225,ⁿ:486,"₊":407,"₋":407,"₌":407,"₍":225,"₎":225,"ₙ":486,"₡":599,"₣":527,"₤":600,"₥":921,"₦":625,"₨":1093,"₩":769,"₪":754,"₫":635,"₭":614,"₮":528,"₯":1288,"₰":950,"₲":685,"₴":576,"₵":599,"₶":576,"₷":700,"₸":528,"₻":750,"₼":683,"₾":577,"₿":620,"℃":915,"℅":825,"℉":868,ℓ:385,"№":1176,"℗":806,"℡":1022,"™":903,"℮":903,"⅛":930,"⅜":931,"⅝":931,"⅞":871,"Ⅶ":1166,"∂":587,"∈":663,"∏":708,"∑":596,"√":604,"∞":679,"∧":617,"∫":531,"∮":654,"≈":600,"≒":662,"◊":600," ":0,"〞":472},glyphsByWidth:{268:"ijìíîïĩīĭįıĵȷ",274:"IÌÍÎÏĨĪĬĮİΙΪ",406:"²³¹⁰⁴⁵⁶⁷⁸⁹₀₁₂₃₄₅₆₇₈₉",552:"+<=>^~¬±×÷−∕∙≠≤≥≦≧≮≯",556:"EÈÉÊËĒĔĖĘĚΕΞ",575:"$0123456789¢£¤¥ƒ₢₧€₱₹₺₽",578:"eèéêëēĕėęě",612:"aàáâãäåāăąǻ",613:"uµùúûüũūŭůűųάαμ∨",618:"hnoðñòóôõöøĥħńņňŋōŏőǿδοό",667:"AÀÁÂÃÄÅĀĂĄǺΑΔ₳∆",701:"UÙÚÛÜŨŪŬŮŰŲ",743:"OQÒÓÔÕÖØŌŎŐǾΘΟΩΩ",1e3:"─━│┃┄┅┆┇┈┉┊┋┌┍┎┏┐┑┒┓└┕┖┗┘┙┚┛├┝┞┟┠┡┢┣┤┥┦┧┨┩┪┫┬┭┮┯┰┱┲┳┴┵┶┷┸┹┺┻┼┽┾┿╀╁╂╃╄╅╆╇╈╉╊╋═║╒╓╔╕╖╗╘╙╚╛╜╝╞╟╠╡╢╣╤╥╦╧╨╩╪╫╬╭╮╯╰╱╲╳▁▂▃▄▅▆▇█▉▊▋▌▍▎▏▓▔▕■□▲△▼▽◆◇○◎●◢◣◤◥★☆☉♀♂〾"},defaultWidth:984,kerning:{'""':-56,"\"'":-57,'",':-179,'".':-179,"'\"":-56,"''":-57,"',":-179,"'.":-179,"(j":60,',"':-160,",'":-160,",1":-140,",7":-41,",9":-39,'."':-160,".'":-160,".1":-140,".7":-41,".9":-39,"//":-120,"1,":-99,"1.":-99,"1:":-99,"1;":-99,"7,":-160,"7.":-160,"7:":-99,"7;":-99,":1":-79,":7":-59,";1":-79,";7":-59,'A"':-100,"A'":-100,AC:-20,AG:-20,AO:-20,AQ:-20,AT:-80,AU:-10,AV:-70,AW:-39,AY:-81,Af:-20,Al:-10,At:-20,Av:-20,Ay:-20,BC:-10,BG:-10,BO:-10,BQ:-10,BT:-40,BV:-20,BX:-20,BY:-21,"D,":-59,"D.":-59,DA:-20,DT:-36,DV:-30,DW:-19,DX:-20,DY:-40,DZ:-20,Da:-39,Ej:19,"F,":-159,"F.":-159,FA:-40,Fa:-59,Fh:1,Fk:1,GV:-11,GY:-21,JJ:7,KA:-19,KC:-20,KG:-20,KO:-20,KQ:-20,KT:-19,KU:-39,KV:-39,KW:-39,KY:-40,Kc:-39,Kd:-39,Ke:-39,Kg:-39,Kl:-39,Ko:-39,Kq:-39,Ks:-19,Kt:-10,Ku:-40,Kv:-60,Kw:-40,Ky:-60,'L"':-99,"L'":-99,LA:20,LC:-59,LG:-59,LO:-59,LQ:-59,LT:-79,LU:-19,LV:-79,LW:-39,LY:-100,Lv:-41,Lw:-21,Ly:-41,"O,":-59,"O.":-59,OA:-20,OT:-36,OV:-30,OW:-19,OX:-20,OY:-40,OZ:-20,Oa:-39,"P,":-199,"P.":-199,PA:-60,PT:-29,PV:-10,PW:-10,PX:-50,PY:-20,PZ:-39,Pa:-60,"Q,":-59,"Q.":-59,QA:-20,QJ:7,QT:-36,QV:-30,QW:-19,QX:-20,QY:-40,QZ:-20,Qa:-39,RC:-15,RG:-15,RO:-15,RQ:-15,RT:-40,RU:-10,RV:-21,RW:-10,RX:-29,RY:-41,Rc:-20,Rd:-20,Re:-20,Rg:-20,Ro:-20,Rq:-20,Rt:-20,Ru:-10,Rv:-10,Rx:20,Ry:-10,"S,":-20,"S.":-20,SS:-1,ST:-1,SV:-21,SW:-10,SY:-21,St:-1,Sv:-20,Sw:-10,Sx:-1,Sy:-20,'T"':2,"T'":2,"T,":-154,"T.":-154,TA:-80,TC:-20,TG:-20,TO:-20,TQ:-20,TS:-1,Ta:-80,Tc:-59,Td:-59,Te:-59,Tg:-59,Ti:-20,Tj:-19,Tm:-59,Tn:-59,To:-59,Tp:-58,Tq:-59,Tr:-59,Ts:-60,Tt:20,Tu:-79,Tv:-39,Tw:-19,Tx:-39,Ty:-39,Tz:-59,UA:-10,UX:-19,Ux:-1,"V,":-140,"V.":-140,"V:":-41,"V;":-41,VA:-70,VC:-30,VG:-30,VO:-30,VQ:-30,VS:-10,Va:-41,Vc:-21,Vd:-21,Ve:-21,Vg:-21,Vh:1,Vk:1,Vo:-21,Vq:-21,Vs:-21,Vv:-1,Vy:-1,"W,":-79,"W.":-79,"W:":-39,"W;":-39,WA:-40,WC:-19,WG:-19,WO:-19,WQ:-19,Wa:-40,Wc:-20,Wd:-20,We:-20,Wg:-20,Wo:-20,Wq:-20,Ws:-20,XA:-19,XC:-20,XG:-20,XO:-20,XQ:-20,XT:-19,XU:-39,XV:-39,XW:-39,XY:-40,Xc:-39,Xd:-39,Xe:-39,Xg:-39,Xl:-39,Xo:-39,Xq:-39,Xs:-19,Xt:-10,Xu:-40,Xv:-60,Xw:-40,Xy:-60,'Y"':1,"Y'":1,"Y,":-141,"Y.":-141,"Y:":-60,"Y;":-60,YA:-81,YC:-40,YG:-40,YO:-40,YQ:-40,YS:-1,Ya:-101,Yc:-60,Yd:-60,Ye:-60,Yf:-1,Yg:-60,Yh:1,Yi:-19,Yk:1,Ym:-41,Yn:-41,Yo:-60,Yp:-40,Yq:-60,Yr:-41,Ys:-61,Yt:-1,Yu:-40,Yv:-40,Yx:-41,Yy:-40,Yz:-41,ZC:-20,ZG:-20,ZO:-20,ZQ:-20,"[j":80,aT:-60,aV:-21,aY:-61,av:-10,aw:-10,ay:-10,"b,":-40,"b.":-40,bT:-59,bV:-21,bW:-20,bX:-39,bY:-60,bv:-10,bx:-20,by:-10,"e,":-20,"e.":-20,eT:-59,eY:-40,ej:20,'f"':3,"f'":3,"f)":1,"f*":61,"f,":-1,"f.":-1,"f?":40,fT:40,fV:21,fW:21,fX:21,fY:1,"f]":21,fa:-29,fc:-19,fd:-19,fe:-19,ff:1,fg:-39,fh:-19,fi:-19,fj:-19,fk:-19,fl:-19,fo:-19,fq:-19,fs:-19,ft:1,"f}":3,hT:-58,hY:-39,hv:-10,hy:-10,'i"':2,"i'":2,"i)":2,"i?":3,iT:-20,"i]":41,"i}":22,jT:-20,kT:-39,kU:-1,kW:-20,ka:-20,kc:-20,kd:-20,ke:-20,kg:-20,kl:-20,ko:-20,kq:-20,ku:-10,lf:-20,lv:-19,lw:-10,ly:-19,mT:-58,mY:-39,mv:-10,my:-10,nT:-58,nY:-39,nv:-10,ny:-10,"o,":-40,"o.":-40,oT:-59,oV:-21,oW:-20,oX:-39,oY:-60,ov:-10,ox:-20,oy:-10,"p,":-40,"p.":-40,pT:-59,pV:-21,pW:-20,pX:-39,pY:-60,pv:-10,px:-20,py:-10,qT:-19,qY:-19,qj:20,'r"':2,"r'":2,"r,":-90,"r.":-90,ra:-49,rc:-19,rd:-19,re:-19,rf:1,ro:-19,rq:-19,rt:20,sT:-59,sV:-21,sW:-20,sX:-19,sY:-60,sv:-19,sx:-10,sy:-19,tf:1,uT:-40,uY:-19,"v,":-90,"v.":-90,vT:-39,vX:-39,va:-35,vc:-10,vd:-10,ve:-10,vo:-10,vq:-10,"w,":-50,"w.":-50,wT:-19,wX:-39,wa:-30,xT:-39,xU:-1,xW:-20,xa:-20,xc:-20,xd:-20,xe:-20,xg:-20,xl:-20,xo:-20,xq:-20,xu:-10,"y,":-90,"y.":-90,yT:-39,yX:-39,ya:-35,yc:-10,yd:-10,ye:-10,yo:-10,yq:-10,zT:-59,"{h":2,"{j":79,"{k":2}};var DL=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});const ui=new WeakMap;function HL(e){const t=ui.get(e);return t?Array.from(t.values()):[]}function xv(e,t){var n;return(n=ui.get(e))==null?void 0:n.get(t)}function wv(e,t,n){let r=ui.get(e);return r||(r=new Map,ui.set(e,r)),r.set(t,n),n.finally(()=>{const i=ui.get(e);i&&(i.get(t)===n&&i.delete(t),i.size===0&&ui.delete(e))}),n}function qL(e){return DL(this,null,function*(){for(yield Promise.resolve();;){const t=HL(e);if(!t.length)break;yield Promise.allSettled(t),yield Promise.resolve()}})}var jL=Object.defineProperty,Pv=Object.getOwnPropertySymbols,FL=Object.prototype.hasOwnProperty,BL=Object.prototype.propertyIsEnumerable,$v=(e,t,n)=>t in e?jL(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WL=(e,t)=>{for(var n in t||(t={}))FL.call(t,n)&&$v(e,n,t[n]);if(Pv)for(var n of Pv(t))BL.call(t,n)&&$v(e,n,t[n]);return e};const gu=new Map;let mu="Alibaba PuHuiTi";function yu(e){const t=Or(e);for(const n of t){const r=gu.get(li(n));if(r)return r}return null}function vu(){return Array.from(gu.values())}function GL(e){mu=Sr(e)}function Cv(e){const t=WL({},e);return gu.set(t.fontFamily,t),t.fontFamily=Sr(t.fontFamily),t}function Ov(e){const t=Or(e).flatMap(n=>{const r=yu(n);if(!r)return[];const{baseUrl:i,fontWeight:o}=r;return Object.values(o).filter(a=>!!a).map(a=>Yu(i,a))});return Array.from(new Set(t))}function VL(e,t){const n=Or(e);let r=null;for(const a of n)if(r=yu(a),r)break;if(!r)return null;const i=yv(t),o=r.fontWeight[i];return o?Yu(r.baseUrl,o.replace(/\/result.css$/,"")):null}const bu=new WeakMap,io=new WeakMap;function Sv(e,t,n){let r=io.get(e);return r||(r=new Map,io.set(e,r)),r.set(t,n),n.finally(()=>{const i=io.get(e);i&&(i.get(t)===n&&i.delete(t),i.size===0&&io.delete(e))}),n}function YL(e){if(e.getAttribute("data-infographic-font-loaded")==="true")return!0;try{return!!e.sheet}catch(t){return!1}}function XL(e,t,n){var r;const i=(r=io.get(e))==null?void 0:r.get(t);if(i)return i;if(!n||YL(n))return Sv(e,t,Promise.resolve());const o=new Promise(a=>{const s=()=>{n.setAttribute("data-infographic-font-loaded","true"),a()};n.addEventListener("load",s,{once:!0}),n.addEventListener("error",s,{once:!0})});return Sv(e,t,o)}function UL(e,t){const n=e.ownerDocument,r=(n==null?void 0:n.head)||document.head;if(!r)return;bu.has(r)||bu.set(r,new Map);const i=bu.get(r),o=Ov(t);if(!o.length)return;const a=[];o.forEach(s=>{const c=`${t}-${s}`,l=`font:${c}`;if(xv(e,l))return;let u=i.get(c);u||(u=n.createElement("link"),u.id=c,u.rel="stylesheet",u.href=s,a.push(u),i.set(c,u));const h=XL(r,c,u);wv(e,l,h)}),a.length&&r.tagName==="HEAD"&&a.forEach(s=>r.appendChild(s))}function KL(e){if(Vu)return;vu().forEach(n=>UL(e,n.fontFamily))}const oo="https://assets.antv.antgroup.com",hi=e=>`${e}/result.css`;[{fontFamily:"Alibaba PuHuiTi",name:"阿里巴巴普惠体",baseUrl:oo,fontWeight:{regular:hi("AlibabaPuHuiTi-Regular"),bold:hi("AlibabaPuHuiTi-Bold")}},{fontFamily:"Source Han Sans",name:"黑体",baseUrl:oo,fontWeight:{regular:hi("SourceHanSansCN-Regular")}},{fontFamily:"Source Han Serif",name:"宋体",baseUrl:oo,fontWeight:{regular:hi("SourceHanSerifCN-Regular")}},{fontFamily:"LXGW WenKai",name:"楷体",baseUrl:oo,fontWeight:{regular:hi("LXGWWenKai-Regular")}},{fontFamily:"851tegakizatsu",name:"手写体",baseUrl:oo,fontWeight:{regular:hi("851tegakizatsu-Regular")}}].forEach(Cv);const _u=new Map;function xu(e,t){_u.set(e,t)}function Mv(e){return _u.get(e)}function ZL(){return Object.fromEntries(_u)}xu("antv",["#1783FF","#00C9C9","#F0884D","#D580FF","#7863FF","#60C42D","#BD8F24","#FF80CA","#2491B3","#17C76F","#70CAF8"]),xu("spectral",(e,t,n)=>{const r=[["#fc8d59","#ffffbf","#99d594"],["#d7191c","#fdae61","#abdda4","#2b83ba"],["#d7191c","#fdae61","#ffffbf","#abdda4","#2b83ba"],["#d53e4f","#fc8d59","#fee08b","#e6f598","#99d594","#3288bd"],["#d53e4f","#fc8d59","#fee08b","#ffffbf","#e6f598","#99d594","#3288bd"],["#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd"],["#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd"],["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"]],i=Math.min(Math.max(n,3),11);return r[i-3][t%i]});const za=(e=[],t,n)=>{var r;const i=typeof e=="string"?Mv(e)||[]:e,o=(r=t[0])!=null?r:0;if(typeof i=="function"){const a=n?o/n:0;return i(a,o,n!=null?n:0)}if(Array.isArray(i))return i.length===0?void 0:i[o%i.length]};function QL(e,t){var n,r;if(((n=t.svg)==null?void 0:n.background)===!1)return;const{themeConfig:{colorBg:i}}=t;if(!i)return;const o=e.parentElement;o&&(o.style.backgroundColor=i||"none");const a=mi(e,Ve.Background);if(e.style.backgroundColor=i,a)a.setAttribute("fill",i);else if((r=e.viewBox)!=null&&r.baseVal){const{x:s,y:c,width:l,height:u}=e.viewBox.baseVal,h=Ee("rect",{x:s,y:c,width:l,height:u,fill:i,"data-element-type":Ve.Background});e.prepend(h)}}function ao(e,t){return Object.entries(t).reduce((r,[i,o])=>{if(typeof o=="function"){const a=o(e.getAttribute(i),e);a!=null&&(r[i]=a)}else Object.assign(r,{[i]:o});return r},{})}function Ev(e){return e.replace(/#|%|\.| |\/|\(|\)/g,"").replace(/,/g,"-")}function JL(e,t){t&&Object.keys(t).length>0&&gi(e,n=>{const r=ao(n,t);lt(n,r)})}const Iv="btn-add-icon",Av="btn-remove-icon";function ez(e,t){lt(t,{display:"none"});const n=t.querySelectorAll('[id^="btn-add-"]'),r=t.querySelectorAll('[id^="btn-remove-"]');nz(e),n.forEach(rz),r.forEach(iz)}const tz="btn-icon-defs";function nz(e){const t=Ee("defs");po(t,tz);const n=pi(`<symbol class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="200" height="200">
|
|
3
|
+
`||t[Te]===" "||t[Te]===" ");)Te++;continue}if(r===",")return;if(r===")"){n.push({type:de.ParenClose});continue}if(r==="+"){if(Te--,bs(t)){n.push(Ji(t));continue}return}if(r==="-"){if(Te--,bs(t)){n.push(Ji(t));continue}if(Ic(t)){n.push({type:de.Ident,value:ws(t)});continue}return}if(r==="."){if(Te--,bs(t)){n.push(Ji(t));continue}return}if(r==="/"){for(;Te<t.length&&(t[Te]===`
|
|
4
|
+
`||t[Te]===" "||t[Te]===" ");)Te++;let i;if(bs(t)&&(i=Ji(t),i.type!==de.Hue)){n.push({type:de.Alpha,value:i});continue}if(Ic(t)&&ws(t)==="none"){n.push({type:de.Alpha,value:{type:de.None,value:void 0}});continue}return}if(/\d/.test(r)){Te--,n.push(Ji(t));continue}if(Mc.test(r)){Te--,n.push(iI(t));continue}return}return n}function sI(e){e._i=0;let t=e[e._i++];if(!t||t.type!==de.Function||t.value!=="color"||(t=e[e._i++],t.type!==de.Ident))return;const n=qy[t.value];if(!n)return;const r={mode:n},i=Hy(e,!1);if(!i)return;const o=eI(n).channels;for(let s=0,a,l;s<o.length;s++)a=i[s],l=o[s],a.type!==de.None&&(r[l]=a.type===de.Number?a.value:a.value/100,l==="alpha"&&(r[l]=Math.max(0,Math.min(1,r[l]))));return r}function Hy(e,t){const n=[];let r;for(;e._i<e.length;){if(r=e[e._i++],r.type===de.None||r.type===de.Number||r.type===de.Alpha||r.type===de.Percentage||t&&r.type===de.Hue){n.push(r);continue}if(r.type===de.ParenClose){if(e._i<e.length)return;continue}return}if(!(n.length<3||n.length>4)){if(n.length===4){if(n[3].type!==de.Alpha)return;n[3]=n[3].value}return n.length===3&&n.push({type:de.None,value:void 0}),n.every(i=>i.type!==de.Alpha)?n:void 0}}function aI(e,t){e._i=0;let n=e[e._i++];if(!n||n.type!==de.Function)return;let r=Hy(e,t);if(r)return r.unshift(n.value),r}const En=e=>{if(typeof e!="string")return;const t=oI(e),n=t?aI(t,!0):void 0;let r,i=0,o=vs.length;for(;i<o;)if((r=vs[i++](e,n))!==void 0)return r;return t?sI(t):void 0};function lI(e,t){if(!t||t[0]!=="rgb"&&t[0]!=="rgba")return;const n={mode:"rgb"},[,r,i,o,s]=t;if(!(r.type===de.Hue||i.type===de.Hue||o.type===de.Hue))return r.type!==de.None&&(n.r=r.type===de.Number?r.value/255:r.value/100),i.type!==de.None&&(n.g=i.type===de.Number?i.value/255:i.value/100),o.type!==de.None&&(n.b=o.type===de.Number?o.value/255:o.value/100),s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const cI=e=>e==="transparent"?{mode:"rgb",r:0,g:0,b:0,alpha:0}:void 0,uI=(e,t,n)=>e+n*(t-e),hI=e=>{let t=[];for(let n=0;n<e.length-1;n++){let r=e[n],i=e[n+1];r===void 0&&i===void 0?t.push(void 0):r!==void 0&&i!==void 0?t.push([r,i]):t.push(r!==void 0?[r,r]:[i,i])}return t},_e=(e=>t=>{let n=hI(t);return r=>{let i=r*n.length,o=r>=1?n.length-1:Math.max(Math.floor(i),0),s=n[o];return s===void 0?void 0:e(s[0],s[1],i-o)}})(uI),kt=e=>{let t=!1,n=e.map(r=>r!==void 0?(t=!0,r):1);return t?n:e},ci={mode:"rgb",channels:["r","g","b","alpha"],parse:[lI,YM,ZM,VM,cI,"srgb"],serialize:"srgb",interpolate:{r:_e,g:_e,b:_e,alpha:{use:_e,fixup:kt}},gamut:!0,white:{r:1,g:1,b:1},black:{r:0,g:0,b:0}},Ac=(e=0)=>Math.pow(Math.abs(e),563/256)*Math.sign(e),jy=e=>{let t=Ac(e.r),n=Ac(e.g),r=Ac(e.b),i={mode:"xyz65",x:.5766690429101305*t+.1855582379065463*n+.1882286462349947*r,y:.297344975250536*t+.6273635662554661*n+.0752914584939979*r,z:.0270313613864123*t+.0706888525358272*n+.9913375368376386*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},Tc=e=>Math.pow(Math.abs(e),256/563)*Math.sign(e),Fy=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"a98",r:Tc(e*2.0415879038107465-t*.5650069742788597-.3447313507783297*n),g:Tc(e*-.9692436362808798+t*1.8759675015077206+.0415550574071756*n),b:Tc(e*.0134442806320312-t*.1183623922310184+1.0151749943912058*n)};return r!==void 0&&(i.alpha=r),i},Rc=(e=0)=>{const t=Math.abs(e);return t<=.04045?e/12.92:(Math.sign(e)||1)*Math.pow((t+.055)/1.055,2.4)},ui=({r:e,g:t,b:n,alpha:r})=>{let i={mode:"lrgb",r:Rc(e),g:Rc(t),b:Rc(n)};return r!==void 0&&(i.alpha=r),i},wr=e=>{let{r:t,g:n,b:r,alpha:i}=ui(e),o={mode:"xyz65",x:.4123907992659593*t+.357584339383878*n+.1804807884018343*r,y:.2126390058715102*t+.715168678767756*n+.0721923153607337*r,z:.0193308187155918*t+.119194779794626*n+.9505321522496607*r};return i!==void 0&&(o.alpha=i),o},kc=(e=0)=>{const t=Math.abs(e);return t>.0031308?(Math.sign(e)||1)*(1.055*Math.pow(t,1/2.4)-.055):e*12.92},hi=({r:e,g:t,b:n,alpha:r},i="rgb")=>{let o={mode:i,r:kc(e),g:kc(t),b:kc(n)};return r!==void 0&&(o.alpha=r),o},xr=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=hi({r:e*3.2409699419045226-t*1.537383177570094-.4986107602930034*n,g:e*-.9692436362808796+t*1.8759675015077204+.0415550574071756*n,b:e*.0556300796969936-t*.2039769588889765+1.0569715142428784*n});return r!==void 0&&(i.alpha=r),i},fI=zt(ht({},ci),{mode:"a98",parse:["a98-rgb"],serialize:"a98-rgb",fromMode:{rgb:e=>Fy(wr(e)),xyz65:Fy},toMode:{rgb:e=>xr(jy(e)),xyz65:jy}}),jt=e=>(e=e%360)<0?e+360:e,dI=(e,t)=>e.map((n,r,i)=>{if(n===void 0)return n;let o=jt(n);return r===0||e[r-1]===void 0?o:t(o-jt(i[r-1]))}).reduce((n,r)=>!n.length||r===void 0||n[n.length-1]===void 0?(n.push(r),n):(n.push(r+n[n.length-1]),n),[]),jn=e=>dI(e,t=>Math.abs(t)<=180?t:t-360*Math.sign(t)),Dt=[-.14861,1.78277,-.29227,-.90649,1.97294,0],pI=Math.PI/180,gI=180/Math.PI;let By=Dt[3]*Dt[4],Wy=Dt[1]*Dt[4],Vy=Dt[1]*Dt[2]-Dt[0]*Dt[3];const mI=({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(Vy*n+e*By-t*Wy)/(Vy+By-Wy),o=n-i,s=(Dt[4]*(t-i)-Dt[2]*o)/Dt[3],a={mode:"cubehelix",l:i,s:i===0||i===1?void 0:Math.sqrt(o*o+s*s)/(Dt[4]*i*(1-i))};return a.s&&(a.h=Math.atan2(s,o)*gI-120),r!==void 0&&(a.alpha=r),a},yI=({h:e,s:t,l:n,alpha:r})=>{let i={mode:"rgb"};e=(e===void 0?0:e+120)*pI,n===void 0&&(n=0);let o=t===void 0?0:t*n*(1-n),s=Math.cos(e),a=Math.sin(e);return i.r=n+o*(Dt[0]*s+Dt[1]*a),i.g=n+o*(Dt[2]*s+Dt[3]*a),i.b=n+o*(Dt[4]*s+Dt[5]*a),r!==void 0&&(i.alpha=r),i},xs=(e,t)=>{if(e.h===void 0||t.h===void 0||!e.s||!t.s)return 0;let n=jt(e.h),r=jt(t.h),i=Math.sin((r-n+360)/2*Math.PI/180);return 2*Math.sqrt(e.s*t.s)*i},vI=(e,t)=>{if(e.h===void 0||t.h===void 0)return 0;let n=jt(e.h),r=jt(t.h);return Math.abs(r-n)>180?n-(r-360*Math.sign(r-n)):r-n},Cs=(e,t)=>{if(e.h===void 0||t.h===void 0||!e.c||!t.c)return 0;let n=jt(e.h),r=jt(t.h),i=Math.sin((r-n+360)/2*Math.PI/180);return 2*Math.sqrt(e.c*t.c)*i},Fn=e=>{let t=e.reduce((r,i)=>{if(i!==void 0){let o=i*Math.PI/180;r.sin+=Math.sin(o),r.cos+=Math.cos(o)}return r},{sin:0,cos:0}),n=Math.atan2(t.sin,t.cos)*180/Math.PI;return n<0?360+n:n},bI={mode:"cubehelix",channels:["h","s","l","alpha"],parse:["--cubehelix"],serialize:"--cubehelix",ranges:{h:[0,360],s:[0,4.614],l:[0,1]},fromMode:{rgb:mI},toMode:{rgb:yI},interpolate:{h:{use:_e,fixup:jn},s:_e,l:_e,alpha:{use:_e,fixup:kt}},difference:{h:xs},average:{h:Fn}},or=({l:e,a:t,b:n,alpha:r},i="lch")=>{t===void 0&&(t=0),n===void 0&&(n=0);let o=Math.sqrt(t*t+n*n),s={mode:i,l:e,c:o};return o&&(s.h=jt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(s.alpha=r),s},sr=({l:e,c:t,h:n,alpha:r},i="lab")=>{n===void 0&&(n=0);let o={mode:i,l:e,a:t?t*Math.cos(n/180*Math.PI):0,b:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(o.alpha=r),o},Gy=Math.pow(29,3)/Math.pow(3,3),Yy=Math.pow(6,3)/Math.pow(29,3),At={X:.3457/.3585,Y:1,Z:(1-.3457-.3585)/.3585},fi={X:.3127/.329,Y:1,Z:(1-.3127-.329)/.329};let Lc=e=>Math.pow(e,3)>Yy?Math.pow(e,3):(116*e-16)/Gy;const Xy=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+16)/116,o=t/500+i,s=i-n/200,a={mode:"xyz65",x:Lc(o)*fi.X,y:Lc(i)*fi.Y,z:Lc(s)*fi.Z};return r!==void 0&&(a.alpha=r),a},Ps=e=>xr(Xy(e)),Nc=e=>e>Yy?Math.cbrt(e):(Gy*e+16)/116,Uy=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Nc(e/fi.X),o=Nc(t/fi.Y),s=Nc(n/fi.Z),a={mode:"lab65",l:116*o-16,a:500*(i-o),b:200*(o-s)};return r!==void 0&&(a.alpha=r),a},Os=e=>{let t=Uy(wr(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},Ss=1,Ky=1,eo=26/180*Math.PI,$s=Math.cos(eo),Es=Math.sin(eo),Zy=100/Math.log(139/100),zc=({l:e,c:t,h:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"lab65",l:(Math.exp(e*Ss/Zy)-1)/.0039},o=(Math.exp(.0435*t*Ky*Ss)-1)/.075,s=o*Math.cos(n/180*Math.PI-eo),a=o*Math.sin(n/180*Math.PI-eo);return i.a=s*$s-a/.83*Es,i.b=s*Es+a/.83*$s,r!==void 0&&(i.alpha=r),i},Dc=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=t*$s+n*Es,o=.83*(n*$s-t*Es),s=Math.sqrt(i*i+o*o),a={mode:"dlch",l:Zy/Ss*Math.log(1+.0039*e),c:Math.log(1+.075*s)/(.0435*Ky*Ss)};return a.c&&(a.h=jt((Math.atan2(o,i)+eo)/Math.PI*180)),r!==void 0&&(a.alpha=r),a},Qy=e=>zc(or(e,"dlch")),Jy=e=>sr(Dc(e),"dlab"),_I={mode:"dlab",parse:["--din99o-lab"],serialize:"--din99o-lab",toMode:{lab65:Qy,rgb:e=>Ps(Qy(e))},fromMode:{lab65:Jy,rgb:e=>Jy(Os(e))},channels:["l","a","b","alpha"],ranges:{l:[0,100],a:[-40.09,45.501],b:[-40.469,44.344]},interpolate:{l:_e,a:_e,b:_e,alpha:{use:_e,fixup:kt}}},wI={mode:"dlch",parse:["--din99o-lch"],serialize:"--din99o-lch",toMode:{lab65:zc,dlab:e=>sr(e,"dlab"),rgb:e=>Ps(zc(e))},fromMode:{lab65:Dc,dlab:e=>or(e,"dlch"),rgb:e=>Dc(Os(e))},channels:["l","c","h","alpha"],ranges:{l:[0,100],c:[0,51.484],h:[0,360]},interpolate:{l:_e,c:_e,h:{use:_e,fixup:jn},alpha:{use:_e,fixup:kt}},difference:{h:Cs},average:{h:Fn}};function xI({h:e,s:t,i:n,alpha:r}){e=jt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.abs(e/60%2-1),o;switch(Math.floor(e/60)){case 0:o={r:n*(1+t*(3/(2-i)-1)),g:n*(1+t*(3*(1-i)/(2-i)-1)),b:n*(1-t)};break;case 1:o={r:n*(1+t*(3*(1-i)/(2-i)-1)),g:n*(1+t*(3/(2-i)-1)),b:n*(1-t)};break;case 2:o={r:n*(1-t),g:n*(1+t*(3/(2-i)-1)),b:n*(1+t*(3*(1-i)/(2-i)-1))};break;case 3:o={r:n*(1-t),g:n*(1+t*(3*(1-i)/(2-i)-1)),b:n*(1+t*(3/(2-i)-1))};break;case 4:o={r:n*(1+t*(3*(1-i)/(2-i)-1)),g:n*(1-t),b:n*(1+t*(3/(2-i)-1))};break;case 5:o={r:n*(1+t*(3/(2-i)-1)),g:n*(1-t),b:n*(1+t*(3*(1-i)/(2-i)-1))};break;default:o={r:n*(1-t),g:n*(1-t),b:n*(1-t)}}return o.mode="rgb",r!==void 0&&(o.alpha=r),o}function CI({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),s={mode:"hsi",s:e+t+n===0?0:1-3*o/(e+t+n),i:(e+t+n)/3};return i-o!==0&&(s.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(s.alpha=r),s}const PI={mode:"hsi",toMode:{rgb:xI},parse:["--hsi"],serialize:"--hsi",fromMode:{rgb:CI},channels:["h","s","i","alpha"],ranges:{h:[0,360]},gamut:"rgb",interpolate:{h:{use:_e,fixup:jn},s:_e,i:_e,alpha:{use:_e,fixup:kt}},difference:{h:xs},average:{h:Fn}};function OI({h:e,s:t,l:n,alpha:r}){e=jt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=n+t*(n<.5?n:1-n),o=i-(i-n)*2*Math.abs(e/60%2-1),s;switch(Math.floor(e/60)){case 0:s={r:i,g:o,b:2*n-i};break;case 1:s={r:o,g:i,b:2*n-i};break;case 2:s={r:2*n-i,g:i,b:o};break;case 3:s={r:2*n-i,g:o,b:i};break;case 4:s={r:o,g:2*n-i,b:i};break;case 5:s={r:i,g:2*n-i,b:o};break;default:s={r:2*n-i,g:2*n-i,b:2*n-i}}return s.mode="rgb",r!==void 0&&(s.alpha=r),s}function SI({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),s={mode:"hsl",s:i===o?0:(i-o)/(1-Math.abs(i+o-1)),l:.5*(i+o)};return i-o!==0&&(s.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(s.alpha=r),s}const $I=(e,t)=>{switch(t){case"deg":return+e;case"rad":return e/Math.PI*180;case"grad":return e/10*9;case"turn":return e*360}},EI=new RegExp(`^hsla?\\(\\s*${XM}${li}${Qi}${li}${Qi}\\s*(?:,\\s*${$c}\\s*)?\\)$`),MI=e=>{let t=e.match(EI);if(!t)return;let n={mode:"hsl"};return t[3]!==void 0?n.h=+t[3]:t[1]!==void 0&&t[2]!==void 0&&(n.h=$I(t[1],t[2])),t[4]!==void 0&&(n.s=Math.min(Math.max(0,t[4]/100),1)),t[5]!==void 0&&(n.l=Math.min(Math.max(0,t[5]/100),1)),t[6]!==void 0?n.alpha=Math.max(0,Math.min(1,t[6]/100)):t[7]!==void 0&&(n.alpha=Math.max(0,Math.min(1,+t[7]))),n};function II(e,t){if(!t||t[0]!=="hsl"&&t[0]!=="hsla")return;const n={mode:"hsl"},[,r,i,o,s]=t;if(r.type!==de.None){if(r.type===de.Percentage)return;n.h=r.value}if(i.type!==de.None){if(i.type===de.Hue)return;n.s=i.value/100}if(o.type!==de.None){if(o.type===de.Hue)return;n.l=o.value/100}return s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const e2={mode:"hsl",toMode:{rgb:OI},fromMode:{rgb:SI},channels:["h","s","l","alpha"],ranges:{h:[0,360]},gamut:"rgb",parse:[II,MI],serialize:e=>`hsl(${e.h!==void 0?e.h:"none"} ${e.s!==void 0?e.s*100+"%":"none"} ${e.l!==void 0?e.l*100+"%":"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:jn},s:_e,l:_e,alpha:{use:_e,fixup:kt}},difference:{h:xs},average:{h:Fn}};function t2({h:e,s:t,v:n,alpha:r}){e=jt(e!==void 0?e:0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.abs(e/60%2-1),o;switch(Math.floor(e/60)){case 0:o={r:n,g:n*(1-t*i),b:n*(1-t)};break;case 1:o={r:n*(1-t*i),g:n,b:n*(1-t)};break;case 2:o={r:n*(1-t),g:n,b:n*(1-t*i)};break;case 3:o={r:n*(1-t),g:n*(1-t*i),b:n};break;case 4:o={r:n*(1-t*i),g:n*(1-t),b:n};break;case 5:o={r:n,g:n*(1-t),b:n*(1-t*i)};break;default:o={r:n*(1-t),g:n*(1-t),b:n*(1-t)}}return o.mode="rgb",r!==void 0&&(o.alpha=r),o}function n2({r:e,g:t,b:n,alpha:r}){e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.max(e,t,n),o=Math.min(e,t,n),s={mode:"hsv",s:i===0?0:1-o/i,v:i};return i-o!==0&&(s.h=(i===e?(t-n)/(i-o)+(t<n)*6:i===t?(n-e)/(i-o)+2:(e-t)/(i-o)+4)*60),r!==void 0&&(s.alpha=r),s}const r2={mode:"hsv",toMode:{rgb:t2},parse:["--hsv"],serialize:"--hsv",fromMode:{rgb:n2},channels:["h","s","v","alpha"],ranges:{h:[0,360]},gamut:"rgb",interpolate:{h:{use:_e,fixup:jn},s:_e,v:_e,alpha:{use:_e,fixup:kt}},difference:{h:xs},average:{h:Fn}};function AI({h:e,w:t,b:n,alpha:r}){if(t===void 0&&(t=0),n===void 0&&(n=0),t+n>1){let i=t+n;t/=i,n/=i}return t2({h:e,s:n===1?1:1-t/(1-n),v:1-n,alpha:r})}function TI(e){let t=n2(e);if(t===void 0)return;let n=t.s!==void 0?t.s:0,r=t.v!==void 0?t.v:0,i={mode:"hwb",w:(1-n)*r,b:1-r};return t.h!==void 0&&(i.h=t.h),t.alpha!==void 0&&(i.alpha=t.alpha),i}function RI(e,t){if(!t||t[0]!=="hwb")return;const n={mode:"hwb"},[,r,i,o,s]=t;if(r.type!==de.None){if(r.type===de.Percentage)return;n.h=r.value}if(i.type!==de.None){if(i.type===de.Hue)return;n.w=i.value/100}if(o.type!==de.None){if(o.type===de.Hue)return;n.b=o.value/100}return s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const kI={mode:"hwb",toMode:{rgb:AI},fromMode:{rgb:TI},channels:["h","w","b","alpha"],ranges:{h:[0,360]},gamut:"rgb",parse:[RI],serialize:e=>`hwb(${e.h!==void 0?e.h:"none"} ${e.w!==void 0?e.w*100+"%":"none"} ${e.b!==void 0?e.b*100+"%":"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:jn},w:_e,b:_e,alpha:{use:_e,fixup:kt}},difference:{h:vI},average:{h:Fn}},i2=203,Ms=.1593017578125,o2=78.84375,Is=.8359375,As=18.8515625,Ts=18.6875;function qc(e){if(e<0)return 0;const t=Math.pow(e,1/o2);return 1e4*Math.pow(Math.max(0,t-Is)/(As-Ts*t),1/Ms)}function Hc(e){if(e<0)return 0;const t=Math.pow(e/1e4,Ms);return Math.pow((Is+As*t)/(1+Ts*t),o2)}const jc=e=>Math.max(e/i2,0),s2=({i:e,t,p:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i=qc(e+.008609037037932761*t+.11102962500302593*n),o=qc(e-.00860903703793275*t-.11102962500302599*n),s=qc(e+.5600313357106791*t-.32062717498731885*n),a={mode:"xyz65",x:jc(2.070152218389422*i-1.3263473389671556*o+.2066510476294051*s),y:jc(.3647385209748074*i+.680566024947227*o-.0453045459220346*s),z:jc(-.049747207535812*i-.0492609666966138*o+1.1880659249923042*s)};return r!==void 0&&(a.alpha=r),a},Fc=(e=0)=>Math.max(e*i2,0),a2=({x:e,y:t,z:n,alpha:r})=>{const i=Fc(e),o=Fc(t),s=Fc(n),a=Hc(.3592832590121217*i+.6976051147779502*o-.0358915932320289*s),l=Hc(-.1920808463704995*i+1.1004767970374323*o+.0753748658519118*s),c=Hc(.0070797844607477*i+.0748396662186366*o+.8433265453898765*s),u=.5*a+.5*l,h=1.61376953125*a-3.323486328125*l+1.709716796875*c,f=4.378173828125*a-4.24560546875*l-.132568359375*c,d={mode:"itp",i:u,t:h,p:f};return r!==void 0&&(d.alpha=r),d},LI={mode:"itp",channels:["i","t","p","alpha"],parse:["--ictcp"],serialize:"--ictcp",toMode:{xyz65:s2,rgb:e=>xr(s2(e))},fromMode:{xyz65:a2,rgb:e=>a2(wr(e))},ranges:{i:[0,.581],t:[-.369,.272],p:[-.164,.331]},interpolate:{i:_e,t:_e,p:_e,alpha:{use:_e,fixup:kt}}},NI=134.03437499999998,zI=16295499532821565e-27,Bc=e=>{if(e<0)return 0;let t=Math.pow(e/1e4,Ms);return Math.pow((Is+As*t)/(1+Ts*t),NI)},Wc=(e=0)=>Math.max(e*203,0),l2=({x:e,y:t,z:n,alpha:r})=>{e=Wc(e),t=Wc(t),n=Wc(n);let i=1.15*e-.15*n,o=.66*t+.34*e,s=Bc(.41478972*i+.579999*o+.014648*n),a=Bc(-.20151*i+1.120649*o+.0531008*n),l=Bc(-.0166008*i+.2648*o+.6684799*n),c=(s+a)/2,u={mode:"jab",j:.44*c/(1-.56*c)-zI,a:3.524*s-4.066708*a+.542708*l,b:.199076*s+1.096799*a-1.295875*l};return r!==void 0&&(u.alpha=r),u},DI=134.03437499999998,c2=16295499532821565e-27,Vc=e=>{if(e<0)return 0;let t=Math.pow(e,1/DI);return 1e4*Math.pow((Is-t)/(Ts*t-As),1/Ms)},Gc=e=>e/203,u2=({j:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+c2)/(.44+.56*(e+c2)),o=Vc(i+.13860504*t+.058047316*n),s=Vc(i-.13860504*t-.058047316*n),a=Vc(i-.096019242*t-.8118919*n),l={mode:"xyz65",x:Gc(1.661373024652174*o-.914523081304348*s+.23136208173913045*a),y:Gc(-.3250758611844533*o+1.571847026732543*s-.21825383453227928*a),z:Gc(-.090982811*o-.31272829*s+1.5227666*a)};return r!==void 0&&(l.alpha=r),l},h2=e=>{let t=l2(wr(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},f2=e=>xr(u2(e)),qI={mode:"jab",channels:["j","a","b","alpha"],parse:["--jzazbz"],serialize:"--jzazbz",fromMode:{rgb:h2,xyz65:l2},toMode:{rgb:f2,xyz65:u2},ranges:{j:[0,.222],a:[-.109,.129],b:[-.185,.134]},interpolate:{j:_e,a:_e,b:_e,alpha:{use:_e,fixup:kt}}},d2=({j:e,a:t,b:n,alpha:r})=>{t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.sqrt(t*t+n*n),o={mode:"jch",j:e,c:i};return i&&(o.h=jt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(o.alpha=r),o},p2=({j:e,c:t,h:n,alpha:r})=>{n===void 0&&(n=0);let i={mode:"jab",j:e,a:t?t*Math.cos(n/180*Math.PI):0,b:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(i.alpha=r),i},HI={mode:"jch",parse:["--jzczhz"],serialize:"--jzczhz",toMode:{jab:p2,rgb:e=>f2(p2(e))},fromMode:{rgb:e=>d2(h2(e)),jab:d2},channels:["j","c","h","alpha"],ranges:{j:[0,.221],c:[0,.19],h:[0,360]},interpolate:{h:{use:_e,fixup:jn},c:_e,j:_e,alpha:{use:_e,fixup:kt}},difference:{h:Cs},average:{h:Fn}},Rs=Math.pow(29,3)/Math.pow(3,3),Yc=Math.pow(6,3)/Math.pow(29,3);let Xc=e=>Math.pow(e,3)>Yc?Math.pow(e,3):(116*e-16)/Rs;const Uc=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=(e+16)/116,o=t/500+i,s=i-n/200,a={mode:"xyz50",x:Xc(o)*At.X,y:Xc(i)*At.Y,z:Xc(s)*At.Z};return r!==void 0&&(a.alpha=r),a},to=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=hi({r:e*3.1341359569958707-t*1.6173863321612538-.4906619460083532*n,g:e*-.978795502912089+t*1.916254567259524+.03344273116131949*n,b:e*.07195537988411677-t*.2289768264158322+1.405386058324125*n});return r!==void 0&&(i.alpha=r),i},g2=e=>to(Uc(e)),no=e=>{let{r:t,g:n,b:r,alpha:i}=ui(e),o={mode:"xyz50",x:.436065742824811*t+.3851514688337912*n+.14307845442264197*r,y:.22249319175623702*t+.7168870538238823*n+.06061979053616537*r,z:.013923904500943465*t+.09708128566574634*n+.7140993584005155*r};return i!==void 0&&(o.alpha=i),o},Kc=e=>e>Yc?Math.cbrt(e):(Rs*e+16)/116,Zc=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Kc(e/At.X),o=Kc(t/At.Y),s=Kc(n/At.Z),a={mode:"lab",l:116*o-16,a:500*(i-o),b:200*(o-s)};return r!==void 0&&(a.alpha=r),a},m2=e=>{let t=Zc(no(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t};function jI(e,t){if(!t||t[0]!=="lab")return;const n={mode:"lab"},[,r,i,o,s]=t;if(!(r.type===de.Hue||i.type===de.Hue||o.type===de.Hue))return r.type!==de.None&&(n.l=Math.min(Math.max(0,r.value),100)),i.type!==de.None&&(n.a=i.type===de.Number?i.value:i.value*125/100),o.type!==de.None&&(n.b=o.type===de.Number?o.value:o.value*125/100),s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const Qc={mode:"lab",toMode:{xyz50:Uc,rgb:g2},fromMode:{xyz50:Zc,rgb:m2},channels:["l","a","b","alpha"],ranges:{l:[0,100],a:[-125,125],b:[-125,125]},parse:[jI],serialize:e=>`lab(${e.l!==void 0?e.l:"none"} ${e.a!==void 0?e.a:"none"} ${e.b!==void 0?e.b:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{l:_e,a:_e,b:_e,alpha:{use:_e,fixup:kt}}},FI=zt(ht({},Qc),{mode:"lab65",parse:["--lab-d65"],serialize:"--lab-d65",toMode:{xyz65:Xy,rgb:Ps},fromMode:{xyz65:Uy,rgb:Os},ranges:{l:[0,100],a:[-125,125],b:[-125,125]}});function BI(e,t){if(!t||t[0]!=="lch")return;const n={mode:"lch"},[,r,i,o,s]=t;if(r.type!==de.None){if(r.type===de.Hue)return;n.l=Math.min(Math.max(0,r.value),100)}if(i.type!==de.None&&(n.c=Math.max(0,i.type===de.Number?i.value:i.value*150/100)),o.type!==de.None){if(o.type===de.Percentage)return;n.h=o.value}return s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const Jc={mode:"lch",toMode:{lab:sr,rgb:e=>g2(sr(e))},fromMode:{rgb:e=>or(m2(e)),lab:or},channels:["l","c","h","alpha"],ranges:{l:[0,100],c:[0,150],h:[0,360]},parse:[BI],serialize:e=>`lch(${e.l!==void 0?e.l:"none"} ${e.c!==void 0?e.c:"none"} ${e.h!==void 0?e.h:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,interpolate:{h:{use:_e,fixup:jn},c:_e,l:_e,alpha:{use:_e,fixup:kt}},difference:{h:Cs},average:{h:Fn}},WI=zt(ht({},Jc),{mode:"lch65",parse:["--lch-d65"],serialize:"--lch-d65",toMode:{lab65:e=>sr(e,"lab65"),rgb:e=>Ps(sr(e,"lab65"))},fromMode:{rgb:e=>or(Os(e),"lch65"),lab65:e=>or(e,"lch65")},ranges:{l:[0,100],c:[0,150],h:[0,360]}}),y2=({l:e,u:t,v:n,alpha:r})=>{t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.sqrt(t*t+n*n),o={mode:"lchuv",l:e,c:i};return i&&(o.h=jt(Math.atan2(n,t)*180/Math.PI)),r!==void 0&&(o.alpha=r),o},v2=({l:e,c:t,h:n,alpha:r})=>{n===void 0&&(n=0);let i={mode:"luv",l:e,u:t?t*Math.cos(n/180*Math.PI):0,v:t?t*Math.sin(n/180*Math.PI):0};return r!==void 0&&(i.alpha=r),i},b2=(e,t,n)=>4*e/(e+15*t+3*n),_2=(e,t,n)=>9*t/(e+15*t+3*n),VI=b2(At.X,At.Y,At.Z),GI=_2(At.X,At.Y,At.Z),YI=e=>e<=Yc?Rs*e:116*Math.cbrt(e)-16,eu=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=YI(t/At.Y),o=b2(e,t,n),s=_2(e,t,n);!isFinite(o)||!isFinite(s)?i=o=s=0:(o=13*i*(o-VI),s=13*i*(s-GI));let a={mode:"luv",l:i,u:o,v:s};return r!==void 0&&(a.alpha=r),a},XI=(e,t,n)=>4*e/(e+15*t+3*n),UI=(e,t,n)=>9*t/(e+15*t+3*n),KI=XI(At.X,At.Y,At.Z),ZI=UI(At.X,At.Y,At.Z),tu=({l:e,u:t,v:n,alpha:r})=>{if(e===void 0&&(e=0),e===0)return{mode:"xyz50",x:0,y:0,z:0};t===void 0&&(t=0),n===void 0&&(n=0);let i=t/(13*e)+KI,o=n/(13*e)+ZI,s=At.Y*(e<=8?e/Rs:Math.pow((e+16)/116,3)),a=s*(9*i)/(4*o),l=s*(12-3*i-20*o)/(4*o),c={mode:"xyz50",x:a,y:s,z:l};return r!==void 0&&(c.alpha=r),c},QI={mode:"lchuv",toMode:{luv:v2,rgb:e=>to(tu(v2(e)))},fromMode:{rgb:e=>y2(eu(no(e))),luv:y2},channels:["l","c","h","alpha"],parse:["--lchuv"],serialize:"--lchuv",ranges:{l:[0,100],c:[0,176.956],h:[0,360]},interpolate:{h:{use:_e,fixup:jn},c:_e,l:_e,alpha:{use:_e,fixup:kt}},difference:{h:Cs},average:{h:Fn}},JI=zt(ht({},ci),{mode:"lrgb",toMode:{rgb:hi},fromMode:{rgb:ui},parse:["srgb-linear"],serialize:"srgb-linear"}),eA={mode:"luv",toMode:{xyz50:tu,rgb:e=>to(tu(e))},fromMode:{xyz50:eu,rgb:e=>eu(no(e))},channels:["l","u","v","alpha"],parse:["--luv"],serialize:"--luv",ranges:{l:[0,100],u:[-84.936,175.042],v:[-125.882,87.243]},interpolate:{l:_e,u:_e,v:_e,alpha:{use:_e,fixup:kt}}},w2=({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.cbrt(.412221469470763*e+.5363325372617348*t+.0514459932675022*n),o=Math.cbrt(.2119034958178252*e+.6806995506452344*t+.1073969535369406*n),s=Math.cbrt(.0883024591900564*e+.2817188391361215*t+.6299787016738222*n),a={mode:"oklab",l:.210454268309314*i+.7936177747023054*o-.0040720430116193*s,a:1.9779985324311684*i-2.42859224204858*o+.450593709617411*s,b:.0259040424655478*i+.7827717124575296*o-.8086757549230774*s};return r!==void 0&&(a.alpha=r),a},ks=e=>{let t=w2(ui(e));return e.r===e.b&&e.b===e.g&&(t.a=t.b=0),t},ro=({l:e,a:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=Math.pow(e+.3963377773761749*t+.2158037573099136*n,3),o=Math.pow(e-.1055613458156586*t-.0638541728258133*n,3),s=Math.pow(e-.0894841775298119*t-1.2914855480194092*n,3),a={mode:"lrgb",r:4.076741636075957*i-3.3077115392580616*o+.2309699031821044*s,g:-1.2684379732850317*i+2.6097573492876887*o-.3413193760026573*s,b:-.0041960761386756*i-.7034186179359362*o+1.7076146940746117*s};return r!==void 0&&(a.alpha=r),a},Ls=e=>hi(ro(e));function nu(e){const r=1.170873786407767;return .5*(r*e-.206+Math.sqrt((r*e-.206)*(r*e-.206)+4*.03*r*e))}function Ns(e){return(e*e+.206*e)/(1.170873786407767*(e+.03))}function tA(e,t){let n,r,i,o,s,a,l,c;-1.88170328*e-.80936493*t>1?(n=1.19086277,r=1.76576728,i=.59662641,o=.75515197,s=.56771245,a=4.0767416621,l=-3.3077115913,c=.2309699292):1.81444104*e-1.19445276*t>1?(n=.73956515,r=-.45954404,i=.08285427,o=.1254107,s=.14503204,a=-1.2684380046,l=2.6097574011,c=-.3413193965):(n=1.35733652,r=-.00915799,i=-1.1513021,o=-.50559606,s=.00692167,a=-.0041960863,l=-.7034186147,c=1.707614701);let u=n+r*e+i*t+o*e*e+s*e*t,h=.3963377774*e+.2158037573*t,f=-.1055613458*e-.0638541728*t,d=-.0894841775*e-1.291485548*t;{let p=1+u*h,g=1+u*f,m=1+u*d,v=p*p*p,b=g*g*g,_=m*m*m,x=3*h*p*p,w=3*f*g*g,C=3*d*m*m,P=6*h*h*p,O=6*f*f*g,$=6*d*d*m,S=a*v+l*b+c*_,M=a*x+l*w+c*C,I=a*P+l*O+c*$;u=u-S*M/(M*M-.5*S*I)}return u}function ru(e,t){let n=tA(e,t),r=ro({l:1,a:n*e,b:n*t}),i=Math.cbrt(1/Math.max(r.r,r.g,r.b)),o=i*n;return[i,o]}function nA(e,t,n,r,i,o=null){o||(o=ru(e,t));let s;if((n-i)*o[1]-(o[0]-i)*r<=0)s=o[1]*i/(r*o[0]+o[1]*(i-n));else{s=o[1]*(i-1)/(r*(o[0]-1)+o[1]*(i-n));{let a=n-i,l=r,c=.3963377774*e+.2158037573*t,u=-.1055613458*e-.0638541728*t,h=-.0894841775*e-1.291485548*t,f=a+l*c,d=a+l*u,p=a+l*h;{let g=i*(1-s)+s*n,m=s*r,v=g+m*c,b=g+m*u,_=g+m*h,x=v*v*v,w=b*b*b,C=_*_*_,P=3*f*v*v,O=3*d*b*b,$=3*p*_*_,S=6*f*f*v,M=6*d*d*b,I=6*p*p*_,E=4.0767416621*x-3.3077115913*w+.2309699292*C-1,A=4.0767416621*P-3.3077115913*O+.2309699292*$,T=4.0767416621*S-3.3077115913*M+.2309699292*I,N=A/(A*A-.5*E*T),H=-E*N,D=-1.2684380046*x+2.6097574011*w-.3413193965*C-1,B=-1.2684380046*P+2.6097574011*O-.3413193965*$,F=-1.2684380046*S+2.6097574011*M-.3413193965*I,X=B/(B*B-.5*D*F),G=-D*X,L=-.0041960863*x-.7034186147*w+1.707614701*C-1,R=-.0041960863*P-.7034186147*O+1.707614701*$,z=-.0041960863*S-.7034186147*M+1.707614701*I,q=R/(R*R-.5*L*z),j=-L*q;H=N>=0?H:1e6,G=X>=0?G:1e6,j=q>=0?j:1e6,s+=Math.min(H,Math.min(G,j))}}}return s}function iu(e,t,n=null){n||(n=ru(e,t));let r=n[0],i=n[1];return[i/r,i/(1-r)]}function x2(e,t,n){let r=ru(t,n),i=nA(t,n,e,1,e,r),o=iu(t,n,r),s=.11516993+1/(7.4477897+4.1590124*n+t*(-2.19557347+1.75198401*n+t*(-2.13704948-10.02301043*n+t*(-4.24894561+5.38770819*n+4.69891013*t)))),a=.11239642+1/(1.6132032-.68124379*n+t*(.40370612+.90148123*n+t*(-.27087943+.6122399*n+t*(.00299215-.45399568*n-.14661872*t)))),l=i/Math.min(e*o[0],(1-e)*o[1]),c=e*s,u=(1-e)*a,h=.9*l*Math.sqrt(Math.sqrt(1/(1/(c*c*c*c)+1/(u*u*u*u))));return c=e*.4,u=(1-e)*.8,[Math.sqrt(1/(1/(c*c)+1/(u*u))),h,i]}function C2(e){const t=e.l!==void 0?e.l:0,n=e.a!==void 0?e.a:0,r=e.b!==void 0?e.b:0,i={mode:"okhsl",l:nu(t)};e.alpha!==void 0&&(i.alpha=e.alpha);let o=Math.sqrt(n*n+r*r);if(!o)return i.s=0,i;let[s,a,l]=x2(t,n/o,r/o),c;if(o<a){let u=0,h=.8*s,f=1-h/a;c=(o-u)/(h+f*(o-u))*.8}else{let u=a,h=.2*a*a*1.25*1.25/s,f=1-h/(l-a);c=.8+.2*((o-u)/(h+f*(o-u)))}return c&&(i.s=c,i.h=jt(Math.atan2(r,n)*180/Math.PI)),i}function P2(e){let t=e.h!==void 0?e.h:0,n=e.s!==void 0?e.s:0,r=e.l!==void 0?e.l:0;const i={mode:"oklab",l:Ns(r)};if(e.alpha!==void 0&&(i.alpha=e.alpha),!n||r===1)return i.a=i.b=0,i;let o=Math.cos(t/180*Math.PI),s=Math.sin(t/180*Math.PI),[a,l,c]=x2(i.l,o,s),u,h,f,d;n<.8?(u=1.25*n,h=0,f=.8*a,d=1-f/l):(u=5*(n-.8),h=l,f=.2*l*l*1.25*1.25/a,d=1-f/(c-l));let p=h+u*f/(1-d*u);return i.a=p*o,i.b=p*s,i}const rA=zt(ht({},e2),{mode:"okhsl",channels:["h","s","l","alpha"],parse:["--okhsl"],serialize:"--okhsl",fromMode:{oklab:C2,rgb:e=>C2(ks(e))},toMode:{oklab:P2,rgb:e=>Ls(P2(e))}});function O2(e){let t=e.l!==void 0?e.l:0,n=e.a!==void 0?e.a:0,r=e.b!==void 0?e.b:0,i=Math.sqrt(n*n+r*r),o=i?n/i:1,s=i?r/i:1,[a,l]=iu(o,s),c=.5,u=1-c/a,h=l/(i+t*l),f=h*t,d=h*i,p=Ns(f),g=d*p/f,m=ro({l:p,a:o*g,b:s*g}),v=Math.cbrt(1/Math.max(m.r,m.g,m.b,0));t=t/v,i=i/v*nu(t)/t,t=nu(t);const b={mode:"okhsv",s:i?(c+l)*d/(l*c+l*u*d):0,v:t?t/f:0};return b.s&&(b.h=jt(Math.atan2(r,n)*180/Math.PI)),e.alpha!==void 0&&(b.alpha=e.alpha),b}function S2(e){const t={mode:"oklab"};e.alpha!==void 0&&(t.alpha=e.alpha);const n=e.h!==void 0?e.h:0,r=e.s!==void 0?e.s:0,i=e.v!==void 0?e.v:0,o=Math.cos(n/180*Math.PI),s=Math.sin(n/180*Math.PI),[a,l]=iu(o,s),c=.5,u=1-c/a,h=1-r*c/(c+l-l*u*r),f=r*l*c/(c+l-l*u*r),d=Ns(h),p=f*d/h,g=ro({l:d,a:o*p,b:s*p}),m=Math.cbrt(1/Math.max(g.r,g.g,g.b,0)),v=Ns(i*h),b=f*v/h;return t.l=v*m,t.a=b*o*m,t.b=b*s*m,t}const iA=zt(ht({},r2),{mode:"okhsv",channels:["h","s","v","alpha"],parse:["--okhsv"],serialize:"--okhsv",fromMode:{oklab:O2,rgb:e=>O2(ks(e))},toMode:{oklab:S2,rgb:e=>Ls(S2(e))}});function oA(e,t){if(!t||t[0]!=="oklab")return;const n={mode:"oklab"},[,r,i,o,s]=t;if(!(r.type===de.Hue||i.type===de.Hue||o.type===de.Hue))return r.type!==de.None&&(n.l=Math.min(Math.max(0,r.type===de.Number?r.value:r.value/100),1)),i.type!==de.None&&(n.a=i.type===de.Number?i.value:i.value*.4/100),o.type!==de.None&&(n.b=o.type===de.Number?o.value:o.value*.4/100),s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const sA=zt(ht({},Qc),{mode:"oklab",toMode:{lrgb:ro,rgb:Ls},fromMode:{lrgb:w2,rgb:ks},ranges:{l:[0,1],a:[-.4,.4],b:[-.4,.4]},parse:[oA],serialize:e=>`oklab(${e.l!==void 0?e.l:"none"} ${e.a!==void 0?e.a:"none"} ${e.b!==void 0?e.b:"none"}${e.alpha<1?` / ${e.alpha}`:""})`});function aA(e,t){if(!t||t[0]!=="oklch")return;const n={mode:"oklch"},[,r,i,o,s]=t;if(r.type!==de.None){if(r.type===de.Hue)return;n.l=Math.min(Math.max(0,r.type===de.Number?r.value:r.value/100),1)}if(i.type!==de.None&&(n.c=Math.max(0,i.type===de.Number?i.value:i.value*.4/100)),o.type!==de.None){if(o.type===de.Percentage)return;n.h=o.value}return s.type!==de.None&&(n.alpha=Math.min(1,Math.max(0,s.type===de.Number?s.value:s.value/100))),n}const $2=zt(ht({},Jc),{mode:"oklch",toMode:{oklab:e=>sr(e,"oklab"),rgb:e=>Ls(sr(e,"oklab"))},fromMode:{rgb:e=>or(ks(e),"oklch"),oklab:e=>or(e,"oklch")},parse:[aA],serialize:e=>`oklch(${e.l!==void 0?e.l:"none"} ${e.c!==void 0?e.c:"none"} ${e.h!==void 0?e.h:"none"}${e.alpha<1?` / ${e.alpha}`:""})`,ranges:{l:[0,1],c:[0,.4],h:[0,360]}}),E2=e=>{let{r:t,g:n,b:r,alpha:i}=ui(e),o={mode:"xyz65",x:.486570948648216*t+.265667693169093*n+.1982172852343625*r,y:.2289745640697487*t+.6917385218365062*n+.079286914093745*r,z:0*t+.0451133818589026*n+1.043944368900976*r};return i!==void 0&&(o.alpha=i),o},M2=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i=hi({r:e*2.4934969119414263-t*.9313836179191242-.402710784450717*n,g:e*-.8294889695615749+t*1.7626640603183465+.0236246858419436*n,b:e*.0358458302437845-t*.0761723892680418+.9568845240076871*n},"p3");return r!==void 0&&(i.alpha=r),i},lA=zt(ht({},ci),{mode:"p3",parse:["display-p3"],serialize:"display-p3",fromMode:{rgb:e=>M2(wr(e)),xyz65:M2},toMode:{rgb:e=>xr(E2(e)),xyz65:E2}}),ou=e=>{let t=Math.abs(e);return t>=1/512?Math.sign(e)*Math.pow(t,1/1.8):16*e},I2=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"prophoto",r:ou(e*1.3457868816471585-t*.2555720873797946-.0511018649755453*n),g:ou(e*-.5446307051249019+t*1.5082477428451466+.0205274474364214*n),b:ou(e*0+t*0+1.2119675456389452*n)};return r!==void 0&&(i.alpha=r),i},su=(e=0)=>{let t=Math.abs(e);return t>=16/512?Math.sign(e)*Math.pow(t,1.8):e/16},A2=e=>{let t=su(e.r),n=su(e.g),r=su(e.b),i={mode:"xyz50",x:.7977666449006423*t+.1351812974005331*n+.0313477341283922*r,y:.2880748288194013*t+.7118352342418731*n+899369387256e-16*r,z:0*t+0*n+.8251046025104602*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},cA=zt(ht({},ci),{mode:"prophoto",parse:["prophoto-rgb"],serialize:"prophoto-rgb",fromMode:{xyz50:I2,rgb:e=>I2(no(e))},toMode:{xyz50:A2,rgb:e=>to(A2(e))}}),T2=1.09929682680944,uA=.018053968510807,au=e=>{const t=Math.abs(e);return t>uA?(Math.sign(e)||1)*(T2*Math.pow(t,.45)-(T2-1)):4.5*e},R2=({x:e,y:t,z:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);let i={mode:"rec2020",r:au(e*1.7166511879712683-t*.3556707837763925-.2533662813736599*n),g:au(e*-.6666843518324893+t*1.6164812366349395+.0157685458139111*n),b:au(e*.0176398574453108-t*.0427706132578085+.9421031212354739*n)};return r!==void 0&&(i.alpha=r),i},k2=1.09929682680944,hA=.018053968510807,lu=(e=0)=>{let t=Math.abs(e);return t<hA*4.5?e/4.5:(Math.sign(e)||1)*Math.pow((t+k2-1)/k2,1/.45)},L2=e=>{let t=lu(e.r),n=lu(e.g),r=lu(e.b),i={mode:"xyz65",x:.6369580483012911*t+.1446169035862083*n+.1688809751641721*r,y:.262700212011267*t+.6779980715188708*n+.059301716469862*r,z:0*t+.0280726930490874*n+1.0609850577107909*r};return e.alpha!==void 0&&(i.alpha=e.alpha),i},fA=zt(ht({},ci),{mode:"rec2020",fromMode:{xyz65:R2,rgb:e=>R2(wr(e))},toMode:{xyz65:L2,rgb:e=>xr(L2(e))},parse:["rec2020"],serialize:"rec2020"}),Cr=.0037930732552754493,N2=Math.cbrt(Cr),cu=e=>Math.cbrt(e)-N2,dA=e=>{const{r:t,g:n,b:r,alpha:i}=ui(e),o=cu(.3*t+.622*n+.078*r+Cr),s=cu(.23*t+.692*n+.078*r+Cr),a=cu(.2434226892454782*t+.2047674442449682*n+.5518098665095535*r+Cr),l={mode:"xyb",x:(o-s)/2,y:(o+s)/2,b:a-(o+s)/2};return i!==void 0&&(l.alpha=i),l},uu=e=>Math.pow(e+N2,3),pA={mode:"xyb",channels:["x","y","b","alpha"],parse:["--xyb"],serialize:"--xyb",toMode:{rgb:({x:e,y:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i=uu(e+t)-Cr,o=uu(t-e)-Cr,s=uu(n+t)-Cr,a=hi({r:11.031566904639861*i-9.866943908131562*o-.16462299650829934*s,g:-3.2541473810744237*i+4.418770377582723*o-.16462299650829934*s,b:-3.6588512867136815*i+2.7129230459360922*o+1.9459282407775895*s});return r!==void 0&&(a.alpha=r),a}},fromMode:{rgb:dA},ranges:{x:[-.0154,.0281],y:[0,.8453],b:[-.2778,.388]},interpolate:{x:_e,y:_e,b:_e,alpha:{use:_e,fixup:kt}}},gA={mode:"xyz50",parse:["xyz-d50"],serialize:"xyz-d50",toMode:{rgb:to,lab:Zc},fromMode:{rgb:no,lab:Uc},channels:["x","y","z","alpha"],ranges:{x:[0,.964],y:[0,.999],z:[0,.825]},interpolate:{x:_e,y:_e,z:_e,alpha:{use:_e,fixup:kt}}},mA={mode:"xyz65",toMode:{rgb:xr,xyz50:e=>{let{x:t,y:n,z:r,alpha:i}=e;t===void 0&&(t=0),n===void 0&&(n=0),r===void 0&&(r=0);let o={mode:"xyz50",x:1.0479298208405488*t+.0229467933410191*n-.0501922295431356*r,y:.0296278156881593*t+.990434484573249*n-.0170738250293851*r,z:-.0092430581525912*t+.0150551448965779*n+.7518742899580008*r};return i!==void 0&&(o.alpha=i),o}},fromMode:{rgb:wr,xyz50:e=>{let{x:t,y:n,z:r,alpha:i}=e;t===void 0&&(t=0),n===void 0&&(n=0),r===void 0&&(r=0);let o={mode:"xyz65",x:.9554734527042182*t-.0230985368742614*n+.0632593086610217*r,y:-.0283697069632081*t+1.0099954580058226*n+.021041398966943*r,z:.0123140016883199*t-.0205076964334779*n+1.3303659366080753*r};return i!==void 0&&(o.alpha=i),o}},ranges:{x:[0,.95],y:[0,1],z:[0,1.088]},channels:["x","y","z","alpha"],parse:["xyz","xyz-d65"],serialize:"xyz-d65",interpolate:{x:_e,y:_e,z:_e,alpha:{use:_e,fixup:kt}}},yA={mode:"yiq",toMode:{rgb:({y:e,i:t,q:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i={mode:"rgb",r:e+.95608445*t+.6208885*n,g:e-.27137664*t-.6486059*n,b:e-1.10561724*t+1.70250126*n};return r!==void 0&&(i.alpha=r),i}},fromMode:{rgb:({r:e,g:t,b:n,alpha:r})=>{e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=0);const i={mode:"yiq",y:.29889531*e+.58662247*t+.11448223*n,i:.59597799*e-.2741761*t-.32180189*n,q:.21147017*e-.52261711*t+.31114694*n};return r!==void 0&&(i.alpha=r),i}},channels:["y","i","q","alpha"],parse:["--yiq"],serialize:"--yiq",ranges:{i:[-.595,.595],q:[-.522,.522]},interpolate:{y:_e,i:_e,q:_e,alpha:{use:_e,fixup:kt}}},vA=e=>Math.max(0,Math.min(1,e||0)),zs=e=>Math.round(vA(e)*255),z2=Ec("rgb"),D2=e=>{if(e===void 0)return;let t=zs(e.r),n=zs(e.g),r=zs(e.b);return"#"+(1<<24|t<<16|n<<8|r).toString(16).slice(1)},bA=e=>{if(e===void 0)return;let t=zs(e.alpha!==void 0?e.alpha:1);return D2(e)+(256|t).toString(16).slice(1)},io=e=>D2(z2(e)),_A=e=>bA(z2(e));function hu(e){let t=Ec("lrgb")(e);return .2126*t.r+.7152*t.g+.0722*t.b}function fu(e,t){let n=hu(e),r=hu(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}ot(fI),ot(bI),ot(_I),ot(wI),ot(PI),ot(e2),ot(r2),ot(kI),ot(LI),ot(qI),ot(HI),ot(Qc),ot(FI),ot(Jc),ot(WI),ot(QI),ot(JI),ot(eA),ot(rA),ot(iA),ot(sA);const q2=ot($2);ot(lA),ot(cA),ot(fA),ot(ci),ot(pA),ot(gA),ot(mA),ot(yA);function Pr(e){if(!e)return!1;const t=e.trim().toLowerCase();return!(t==="none"||t==="transparent"||t==="")}function H2(e){const t=En(e);return t?hu(t)<.5:!1}var j2=typeof global=="object"&&global&&global.Object===Object&&global,wA=typeof self=="object"&&self&&self.Object===Object&&self,Mn=j2||wA||Function("return this")(),ar=Mn.Symbol,F2=Object.prototype,xA=F2.hasOwnProperty,CA=F2.toString,oo=ar?ar.toStringTag:void 0;function PA(e){var t=xA.call(e,oo),n=e[oo];try{e[oo]=void 0;var r=!0}catch(o){}var i=CA.call(e);return r&&(t?e[oo]=n:delete e[oo]),i}var OA=Object.prototype,SA=OA.toString;function $A(e){return SA.call(e)}var EA="[object Null]",MA="[object Undefined]",B2=ar?ar.toStringTag:void 0;function Or(e){return e==null?e===void 0?MA:EA:B2&&B2 in Object(e)?PA(e):$A(e)}function lr(e){return e!=null&&typeof e=="object"}var IA="[object Symbol]";function Ds(e){return typeof e=="symbol"||lr(e)&&Or(e)==IA}function AA(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var cr=Array.isArray,W2=ar?ar.prototype:void 0,V2=W2?W2.toString:void 0;function G2(e){if(typeof e=="string")return e;if(cr(e))return AA(e,G2)+"";if(Ds(e))return V2?V2.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var TA=/\s/;function RA(e){for(var t=e.length;t--&&TA.test(e.charAt(t)););return t}var kA=/^\s+/;function LA(e){return e&&e.slice(0,RA(e)+1).replace(kA,"")}function In(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Y2=NaN,NA=/^[-+]0x[0-9a-f]+$/i,zA=/^0b[01]+$/i,DA=/^0o[0-7]+$/i,qA=parseInt;function du(e){if(typeof e=="number")return e;if(Ds(e))return Y2;if(In(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=In(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=LA(e);var n=zA.test(e);return n||DA.test(e)?qA(e.slice(2),n?2:8):NA.test(e)?Y2:+e}function X2(e){return e}var HA="[object AsyncFunction]",jA="[object Function]",FA="[object GeneratorFunction]",BA="[object Proxy]";function pu(e){if(!In(e))return!1;var t=Or(e);return t==jA||t==FA||t==HA||t==BA}var gu=Mn["__core-js_shared__"],U2=(function(){var e=/[^.]+$/.exec(gu&&gu.keys&&gu.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function WA(e){return!!U2&&U2 in e}var VA=Function.prototype,GA=VA.toString;function Sr(e){if(e!=null){try{return GA.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var YA=/[\\^$.*+?()[\]{}|]/g,XA=/^\[object .+?Constructor\]$/,UA=Function.prototype,KA=Object.prototype,ZA=UA.toString,QA=KA.hasOwnProperty,JA=RegExp("^"+ZA.call(QA).replace(YA,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function eT(e){if(!In(e)||WA(e))return!1;var t=pu(e)?JA:XA;return t.test(Sr(e))}function tT(e,t){return e==null?void 0:e[t]}function $r(e,t){var n=tT(e,t);return eT(n)?n:void 0}var mu=$r(Mn,"WeakMap"),K2=Object.create,nT=(function(){function e(){}return function(t){if(!In(t))return{};if(K2)return K2(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}})();function rT(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function iT(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}var oT=800,sT=16,aT=Date.now;function lT(e){var t=0,n=0;return function(){var r=aT(),i=sT-(r-n);if(n=r,i>0){if(++t>=oT)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function cT(e){return function(){return e}}var qs=(function(){try{var e=$r(Object,"defineProperty");return e({},"",{}),e}catch(t){}})(),uT=qs?function(e,t){return qs(e,"toString",{configurable:!0,enumerable:!1,value:cT(t),writable:!0})}:X2,hT=lT(uT);function fT(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}var dT=9007199254740991,pT=/^(?:0|[1-9]\d*)$/;function Z2(e,t){var n=typeof e;return t=t==null?dT:t,!!t&&(n=="number"||n!="symbol"&&pT.test(e))&&e>-1&&e%1==0&&e<t}function yu(e,t,n){t=="__proto__"&&qs?qs(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Hs(e,t){return e===t||e!==e&&t!==t}var gT=Object.prototype,mT=gT.hasOwnProperty;function Q2(e,t,n){var r=e[t];(!(mT.call(e,t)&&Hs(r,n))||n===void 0&&!(t in e))&&yu(e,t,n)}function yT(e,t,n,r){var i=!n;n||(n={});for(var o=-1,s=t.length;++o<s;){var a=t[o],l=void 0;l===void 0&&(l=e[a]),i?yu(n,a,l):Q2(n,a,l)}return n}var J2=Math.max;function vT(e,t,n){return t=J2(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=J2(r.length-t,0),s=Array(o);++i<o;)s[i]=r[t+i];i=-1;for(var a=Array(t+1);++i<t;)a[i]=r[i];return a[t]=n(s),rT(e,this,a)}}function bT(e,t){return hT(vT(e,t,X2),e+"")}var _T=9007199254740991;function ev(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=_T}function js(e){return e!=null&&ev(e.length)&&!pu(e)}function wT(e,t,n){if(!In(n))return!1;var r=typeof t;return(r=="number"?js(n)&&Z2(t,n.length):r=="string"&&t in n)?Hs(n[t],e):!1}function xT(e){return bT(function(t,n){var r=-1,i=n.length,o=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(o=e.length>3&&typeof o=="function"?(i--,o):void 0,s&&wT(n[0],n[1],s)&&(o=i<3?void 0:o,i=1),t=Object(t);++r<i;){var a=n[r];a&&e(t,a,r,o)}return t})}var CT=Object.prototype;function vu(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||CT;return e===n}function PT(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var OT="[object Arguments]";function tv(e){return lr(e)&&Or(e)==OT}var nv=Object.prototype,ST=nv.hasOwnProperty,$T=nv.propertyIsEnumerable,bu=tv((function(){return arguments})())?tv:function(e){return lr(e)&&ST.call(e,"callee")&&!$T.call(e,"callee")};function ET(){return!1}var rv=typeof W=="object"&&W&&!W.nodeType&&W,iv=rv&&typeof module=="object"&&module&&!module.nodeType&&module,MT=iv&&iv.exports===rv,ov=MT?Mn.Buffer:void 0,IT=ov?ov.isBuffer:void 0,_u=IT||ET,AT="[object Arguments]",TT="[object Array]",RT="[object Boolean]",kT="[object Date]",LT="[object Error]",NT="[object Function]",zT="[object Map]",DT="[object Number]",qT="[object Object]",HT="[object RegExp]",jT="[object Set]",FT="[object String]",BT="[object WeakMap]",WT="[object ArrayBuffer]",VT="[object DataView]",GT="[object Float32Array]",YT="[object Float64Array]",XT="[object Int8Array]",UT="[object Int16Array]",KT="[object Int32Array]",ZT="[object Uint8Array]",QT="[object Uint8ClampedArray]",JT="[object Uint16Array]",eR="[object Uint32Array]",mt={};mt[GT]=mt[YT]=mt[XT]=mt[UT]=mt[KT]=mt[ZT]=mt[QT]=mt[JT]=mt[eR]=!0,mt[AT]=mt[TT]=mt[WT]=mt[RT]=mt[VT]=mt[kT]=mt[LT]=mt[NT]=mt[zT]=mt[DT]=mt[qT]=mt[HT]=mt[jT]=mt[FT]=mt[BT]=!1;function tR(e){return lr(e)&&ev(e.length)&&!!mt[Or(e)]}function wu(e){return function(t){return e(t)}}var sv=typeof W=="object"&&W&&!W.nodeType&&W,so=sv&&typeof module=="object"&&module&&!module.nodeType&&module,nR=so&&so.exports===sv,xu=nR&&j2.process,di=(function(){try{var e=so&&so.require&&so.require("util").types;return e||xu&&xu.binding&&xu.binding("util")}catch(t){}})(),av=di&&di.isTypedArray,lv=av?wu(av):tR,rR=Object.prototype,iR=rR.hasOwnProperty;function cv(e,t){var n=cr(e),r=!n&&bu(e),i=!n&&!r&&_u(e),o=!n&&!r&&!i&&lv(e),s=n||r||i||o,a=s?PT(e.length,String):[],l=a.length;for(var c in e)(t||iR.call(e,c))&&!(s&&(c=="length"||i&&(c=="offset"||c=="parent")||o&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Z2(c,l)))&&a.push(c);return a}function uv(e,t){return function(n){return e(t(n))}}var oR=uv(Object.keys,Object),sR=Object.prototype,aR=sR.hasOwnProperty;function lR(e){if(!vu(e))return oR(e);var t=[];for(var n in Object(e))aR.call(e,n)&&n!="constructor"&&t.push(n);return t}function cR(e){return js(e)?cv(e):lR(e)}function uR(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var hR=Object.prototype,fR=hR.hasOwnProperty;function dR(e){if(!In(e))return uR(e);var t=vu(e),n=[];for(var r in e)r=="constructor"&&(t||!fR.call(e,r))||n.push(r);return n}function hv(e){return js(e)?cv(e,!0):dR(e)}var pR=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,gR=/^\w*$/;function mR(e,t){if(cr(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||Ds(e)?!0:gR.test(e)||!pR.test(e)||t!=null&&e in Object(t)}var ao=$r(Object,"create");function yR(){this.__data__=ao?ao(null):{},this.size=0}function vR(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var bR="__lodash_hash_undefined__",_R=Object.prototype,wR=_R.hasOwnProperty;function xR(e){var t=this.__data__;if(ao){var n=t[e];return n===bR?void 0:n}return wR.call(t,e)?t[e]:void 0}var CR=Object.prototype,PR=CR.hasOwnProperty;function OR(e){var t=this.__data__;return ao?t[e]!==void 0:PR.call(t,e)}var SR="__lodash_hash_undefined__";function $R(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ao&&t===void 0?SR:t,this}function Er(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Er.prototype.clear=yR,Er.prototype.delete=vR,Er.prototype.get=xR,Er.prototype.has=OR,Er.prototype.set=$R;function ER(){this.__data__=[],this.size=0}function Fs(e,t){for(var n=e.length;n--;)if(Hs(e[n][0],t))return n;return-1}var MR=Array.prototype,IR=MR.splice;function AR(e){var t=this.__data__,n=Fs(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():IR.call(t,n,1),--this.size,!0}function TR(e){var t=this.__data__,n=Fs(t,e);return n<0?void 0:t[n][1]}function RR(e){return Fs(this.__data__,e)>-1}function kR(e,t){var n=this.__data__,r=Fs(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Bn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Bn.prototype.clear=ER,Bn.prototype.delete=AR,Bn.prototype.get=TR,Bn.prototype.has=RR,Bn.prototype.set=kR;var lo=$r(Mn,"Map");function LR(){this.size=0,this.__data__={hash:new Er,map:new(lo||Bn),string:new Er}}function NR(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function Bs(e,t){var n=e.__data__;return NR(t)?n[typeof t=="string"?"string":"hash"]:n.map}function zR(e){var t=Bs(this,e).delete(e);return this.size-=t?1:0,t}function DR(e){return Bs(this,e).get(e)}function qR(e){return Bs(this,e).has(e)}function HR(e,t){var n=Bs(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function ur(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}ur.prototype.clear=LR,ur.prototype.delete=zR,ur.prototype.get=DR,ur.prototype.has=qR,ur.prototype.set=HR;var jR="Expected a function";function Cu(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(jR);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return n.cache=o.set(i,s)||o,s};return n.cache=new(Cu.Cache||ur),n}Cu.Cache=ur;var FR=500;function BR(e){var t=Cu(e,function(r){return n.size===FR&&n.clear(),r}),n=t.cache;return t}var WR=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,VR=/\\(\\)?/g,GR=BR(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(WR,function(n,r,i,o){t.push(i?o.replace(VR,"$1"):r||n)}),t});function co(e){return e==null?"":G2(e)}function YR(e,t){return cr(e)?e:mR(e,t)?[e]:GR(co(e))}function XR(e){if(typeof e=="string"||Ds(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}function UR(e,t){t=YR(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[XR(t[n++])];return n&&n==r?e:void 0}function fv(e,t,n){var r=e==null?void 0:UR(e,t);return r===void 0?n:r}function KR(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var dv=uv(Object.getPrototypeOf,Object),ZR="[object Object]",QR=Function.prototype,JR=Object.prototype,pv=QR.toString,ek=JR.hasOwnProperty,tk=pv.call(Object);function nk(e){if(!lr(e)||Or(e)!=ZR)return!1;var t=dv(e);if(t===null)return!0;var n=ek.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&pv.call(n)==tk}function rk(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=Array(i);++r<i;)o[r]=e[r+t];return o}function ik(e,t,n){var r=e.length;return n=n===void 0?r:n,!t&&n>=r?e:rk(e,t,n)}var ok="\\ud800-\\udfff",sk="\\u0300-\\u036f",ak="\\ufe20-\\ufe2f",lk="\\u20d0-\\u20ff",ck=sk+ak+lk,uk="\\ufe0e\\ufe0f",hk="\\u200d",fk=RegExp("["+hk+ok+ck+uk+"]");function gv(e){return fk.test(e)}function dk(e){return e.split("")}var mv="\\ud800-\\udfff",pk="\\u0300-\\u036f",gk="\\ufe20-\\ufe2f",mk="\\u20d0-\\u20ff",yk=pk+gk+mk,vk="\\ufe0e\\ufe0f",bk="["+mv+"]",Pu="["+yk+"]",Ou="\\ud83c[\\udffb-\\udfff]",_k="(?:"+Pu+"|"+Ou+")",yv="[^"+mv+"]",vv="(?:\\ud83c[\\udde6-\\uddff]){2}",bv="[\\ud800-\\udbff][\\udc00-\\udfff]",wk="\\u200d",_v=_k+"?",wv="["+vk+"]?",xk="(?:"+wk+"(?:"+[yv,vv,bv].join("|")+")"+wv+_v+")*",Ck=wv+_v+xk,Pk="(?:"+[yv+Pu+"?",Pu,vv,bv,bk].join("|")+")",Ok=RegExp(Ou+"(?="+Ou+")|"+Pk+Ck,"g");function Sk(e){return e.match(Ok)||[]}function $k(e){return gv(e)?Sk(e):dk(e)}function Ek(e){return function(t){t=co(t);var n=gv(t)?$k(t):void 0,r=n?n[0]:t.charAt(0),i=n?ik(n,1).join(""):t.slice(1);return r[e]()+i}}var Mk=Ek("toUpperCase");function Ik(e){return Mk(co(e).toLowerCase())}function Ak(e,t,n,r){for(var i=-1,o=e==null?0:e.length;++i<o;)n=t(n,e[i],i,e);return n}function Tk(e){return function(t){return e==null?void 0:e[t]}}var Rk={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},kk=Tk(Rk),Lk=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Nk="\\u0300-\\u036f",zk="\\ufe20-\\ufe2f",Dk="\\u20d0-\\u20ff",qk=Nk+zk+Dk,Hk="["+qk+"]",jk=RegExp(Hk,"g");function Fk(e){return e=co(e),e&&e.replace(Lk,kk).replace(jk,"")}var Bk=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function Wk(e){return e.match(Bk)||[]}var Vk=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function Gk(e){return Vk.test(e)}var xv="\\ud800-\\udfff",Yk="\\u0300-\\u036f",Xk="\\ufe20-\\ufe2f",Uk="\\u20d0-\\u20ff",Kk=Yk+Xk+Uk,Cv="\\u2700-\\u27bf",Pv="a-z\\xdf-\\xf6\\xf8-\\xff",Zk="\\xac\\xb1\\xd7\\xf7",Qk="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",Jk="\\u2000-\\u206f",eL=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ov="A-Z\\xc0-\\xd6\\xd8-\\xde",tL="\\ufe0e\\ufe0f",Sv=Zk+Qk+Jk+eL,$v="['’]",Ev="["+Sv+"]",nL="["+Kk+"]",Mv="\\d+",rL="["+Cv+"]",Iv="["+Pv+"]",Av="[^"+xv+Sv+Mv+Cv+Pv+Ov+"]",iL="\\ud83c[\\udffb-\\udfff]",oL="(?:"+nL+"|"+iL+")",sL="[^"+xv+"]",Tv="(?:\\ud83c[\\udde6-\\uddff]){2}",Rv="[\\ud800-\\udbff][\\udc00-\\udfff]",pi="["+Ov+"]",aL="\\u200d",kv="(?:"+Iv+"|"+Av+")",lL="(?:"+pi+"|"+Av+")",Lv="(?:"+$v+"(?:d|ll|m|re|s|t|ve))?",Nv="(?:"+$v+"(?:D|LL|M|RE|S|T|VE))?",zv=oL+"?",Dv="["+tL+"]?",cL="(?:"+aL+"(?:"+[sL,Tv,Rv].join("|")+")"+Dv+zv+")*",uL="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",hL="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",fL=Dv+zv+cL,dL="(?:"+[rL,Tv,Rv].join("|")+")"+fL,pL=RegExp([pi+"?"+Iv+"+"+Lv+"(?="+[Ev,pi,"$"].join("|")+")",lL+"+"+Nv+"(?="+[Ev,pi+kv,"$"].join("|")+")",pi+"?"+kv+"+"+Lv,pi+"+"+Nv,hL,uL,Mv,dL].join("|"),"g");function gL(e){return e.match(pL)||[]}function mL(e,t,n){return e=co(e),t=t,t===void 0?Gk(e)?gL(e):Wk(e):e.match(t)||[]}var yL="['’]",vL=RegExp(yL,"g");function qv(e){return function(t){return Ak(mL(Fk(t).replace(vL,"")),e,"")}}var bL=qv(function(e,t,n){return t=t.toLowerCase(),e+(n?Ik(t):t)});function _L(e,t,n){return e===e&&(n!==void 0&&(e=e<=n?e:n),t!==void 0&&(e=e>=t?e:t)),e}function wL(e,t,n){return n===void 0&&(n=t,t=void 0),n!==void 0&&(n=du(n),n=n===n?n:0),t!==void 0&&(t=du(t),t=t===t?t:0),_L(du(e),t,n)}function xL(){this.__data__=new Bn,this.size=0}function CL(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function PL(e){return this.__data__.get(e)}function OL(e){return this.__data__.has(e)}var SL=200;function $L(e,t){var n=this.__data__;if(n instanceof Bn){var r=n.__data__;if(!lo||r.length<SL-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new ur(r)}return n.set(e,t),this.size=n.size,this}function Mr(e){var t=this.__data__=new Bn(e);this.size=t.size}Mr.prototype.clear=xL,Mr.prototype.delete=CL,Mr.prototype.get=PL,Mr.prototype.has=OL,Mr.prototype.set=$L;var Hv=typeof W=="object"&&W&&!W.nodeType&&W,jv=Hv&&typeof module=="object"&&module&&!module.nodeType&&module,EL=jv&&jv.exports===Hv,Fv=EL?Mn.Buffer:void 0,Bv=Fv?Fv.allocUnsafe:void 0;function Wv(e,t){if(t)return e.slice();var n=e.length,r=Bv?Bv(n):new e.constructor(n);return e.copy(r),r}function ML(e,t){for(var n=-1,r=e==null?0:e.length,i=0,o=[];++n<r;){var s=e[n];t(s,n,e)&&(o[i++]=s)}return o}function IL(){return[]}var AL=Object.prototype,TL=AL.propertyIsEnumerable,Vv=Object.getOwnPropertySymbols,RL=Vv?function(e){return e==null?[]:(e=Object(e),ML(Vv(e),function(t){return TL.call(e,t)}))}:IL;function kL(e,t,n){var r=t(e);return cr(e)?r:KR(r,n(e))}function LL(e){return kL(e,cR,RL)}var Su=$r(Mn,"DataView"),$u=$r(Mn,"Promise"),Eu=$r(Mn,"Set"),Gv="[object Map]",NL="[object Object]",Yv="[object Promise]",Xv="[object Set]",Uv="[object WeakMap]",Kv="[object DataView]",zL=Sr(Su),DL=Sr(lo),qL=Sr($u),HL=Sr(Eu),jL=Sr(mu),Wn=Or;(Su&&Wn(new Su(new ArrayBuffer(1)))!=Kv||lo&&Wn(new lo)!=Gv||$u&&Wn($u.resolve())!=Yv||Eu&&Wn(new Eu)!=Xv||mu&&Wn(new mu)!=Uv)&&(Wn=function(e){var t=Or(e),n=t==NL?e.constructor:void 0,r=n?Sr(n):"";if(r)switch(r){case zL:return Kv;case DL:return Gv;case qL:return Yv;case HL:return Xv;case jL:return Uv}return t});var FL=Object.prototype,BL=FL.hasOwnProperty;function WL(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&BL.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Zv=Mn.Uint8Array;function Mu(e){var t=new e.constructor(e.byteLength);return new Zv(t).set(new Zv(e)),t}function VL(e,t){var n=Mu(e.buffer);return new e.constructor(n,e.byteOffset,e.byteLength)}var GL=/\w*$/;function YL(e){var t=new e.constructor(e.source,GL.exec(e));return t.lastIndex=e.lastIndex,t}var Qv=ar?ar.prototype:void 0,Jv=Qv?Qv.valueOf:void 0;function XL(e){return Jv?Object(Jv.call(e)):{}}function eb(e,t){var n=t?Mu(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var UL="[object Boolean]",KL="[object Date]",ZL="[object Map]",QL="[object Number]",JL="[object RegExp]",eN="[object Set]",tN="[object String]",nN="[object Symbol]",rN="[object ArrayBuffer]",iN="[object DataView]",oN="[object Float32Array]",sN="[object Float64Array]",aN="[object Int8Array]",lN="[object Int16Array]",cN="[object Int32Array]",uN="[object Uint8Array]",hN="[object Uint8ClampedArray]",fN="[object Uint16Array]",dN="[object Uint32Array]";function pN(e,t,n){var r=e.constructor;switch(t){case rN:return Mu(e);case UL:case KL:return new r(+e);case iN:return VL(e);case oN:case sN:case aN:case lN:case cN:case uN:case hN:case fN:case dN:return eb(e,n);case ZL:return new r;case QL:case tN:return new r(e);case JL:return YL(e);case eN:return new r;case nN:return XL(e)}}function tb(e){return typeof e.constructor=="function"&&!vu(e)?nT(dv(e)):{}}var gN="[object Map]";function mN(e){return lr(e)&&Wn(e)==gN}var nb=di&&di.isMap,yN=nb?wu(nb):mN,vN="[object Set]";function bN(e){return lr(e)&&Wn(e)==vN}var rb=di&&di.isSet,_N=rb?wu(rb):bN,wN=1,ib="[object Arguments]",xN="[object Array]",CN="[object Boolean]",PN="[object Date]",ON="[object Error]",ob="[object Function]",SN="[object GeneratorFunction]",$N="[object Map]",EN="[object Number]",sb="[object Object]",MN="[object RegExp]",IN="[object Set]",AN="[object String]",TN="[object Symbol]",RN="[object WeakMap]",kN="[object ArrayBuffer]",LN="[object DataView]",NN="[object Float32Array]",zN="[object Float64Array]",DN="[object Int8Array]",qN="[object Int16Array]",HN="[object Int32Array]",jN="[object Uint8Array]",FN="[object Uint8ClampedArray]",BN="[object Uint16Array]",WN="[object Uint32Array]",dt={};dt[ib]=dt[xN]=dt[kN]=dt[LN]=dt[CN]=dt[PN]=dt[NN]=dt[zN]=dt[DN]=dt[qN]=dt[HN]=dt[$N]=dt[EN]=dt[sb]=dt[MN]=dt[IN]=dt[AN]=dt[TN]=dt[jN]=dt[FN]=dt[BN]=dt[WN]=!0,dt[ON]=dt[ob]=dt[RN]=!1;function Ws(e,t,n,r,i,o){var s,a=t&wN;if(s!==void 0)return s;if(!In(e))return e;var l=cr(e);if(l)s=WL(e);else{var c=Wn(e),u=c==ob||c==SN;if(_u(e))return Wv(e,a);if(c==sb||c==ib||u&&!i)s=u?{}:tb(e);else{if(!dt[c])return i?e:{};s=pN(e,c,a)}}o||(o=new Mr);var h=o.get(e);if(h)return h;o.set(e,s),_N(e)?e.forEach(function(p){s.add(Ws(p,t,n,p,e,o))}):yN(e)&&e.forEach(function(p,g){s.set(g,Ws(p,t,n,g,e,o))});var f=LL,d=l?void 0:f(e);return fT(d||e,function(p,g){d&&(g=p,p=e[g]),Q2(s,g,Ws(p,t,n,g,e,o))}),s}var VN=1,GN=4;function ab(e){return Ws(e,VN|GN)}function YN(e){return function(t,n,r){for(var i=-1,o=Object(t),s=r(t),a=s.length;a--;){var l=s[++i];if(n(o[l],l,o)===!1)break}return t}}var XN=YN();function Iu(e,t,n){(n!==void 0&&!Hs(e[t],n)||n===void 0&&!(t in e))&&yu(e,t,n)}function UN(e){return lr(e)&&js(e)}function Au(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}function KN(e){return yT(e,hv(e))}function ZN(e,t,n,r,i,o,s){var a=Au(e,n),l=Au(t,n),c=s.get(l);if(c){Iu(e,n,c);return}var u=o?o(a,l,n+"",e,t,s):void 0,h=u===void 0;if(h){var f=cr(l),d=!f&&_u(l),p=!f&&!d&&lv(l);u=l,f||d||p?cr(a)?u=a:UN(a)?u=iT(a):d?(h=!1,u=Wv(l,!0)):p?(h=!1,u=eb(l,!0)):u=[]:nk(l)||bu(l)?(u=a,bu(a)?u=KN(a):(!In(a)||pu(a))&&(u=tb(l))):h=!1}h&&(s.set(l,u),i(u,l,r,o,s),s.delete(l)),Iu(e,n,u)}function lb(e,t,n,r,i){e!==t&&XN(t,function(o,s){if(i||(i=new Mr),In(o))ZN(e,t,s,n,lb,r,i);else{var a=r?r(Au(e,s),o,s+"",e,t,i):void 0;a===void 0&&(a=o),Iu(e,s,a)}},hv)}var QN=qv(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()}),cb=xT(function(e,t,n){lb(e,t,n)});function uo(e,t){if(t.length===0)return{};const n=Array.isArray(e)?e[t[0]]:e.items[t[0]];if(t.length===1)return n;const r=t.slice(1).map(i=>`children[${i}]`).join(".");return fv(n,r)}function ub(e){const{structure:t,item:n,items:r}=e;return!(!t||!n||r.some(i=>!i))}const JN=new Set(["serif","sans-serif","monospace","cursive","fantasy","system-ui","-apple-system","ui-serif","ui-sans-serif","ui-monospace","ui-rounded","emoji","math","fangsong"]);function Ir(e){const t=[];let n="",r=null;const i=()=>{const o=n.trim();o&&t.push(o),n=""};for(let o=0;o<e.length;o+=1){const s=e[o];if(r){n+=s,s===r&&(r=null);continue}if(s==='"'||s==="'"){r=s,n+=s;continue}if(s===","){i();continue}n+=s}return i(),t}function hb(e){const t=e.trim();return t.startsWith('"')&&t.endsWith('"')||t.startsWith("'")&&t.endsWith("'")?t.slice(1,-1):t}function ez(e){const t=e.trim();return t.startsWith('"')&&t.endsWith('"')||t.startsWith("'")&&t.endsWith("'")}function tz(e){return/^\d/.test(e)||/\s/.test(e)}function nz(e){const t=e.trim();if(!t||ez(t)||JN.has(t.toLowerCase())||!tz(t))return t;const n=t.includes('"')&&!t.includes("'")?"'":'"';return`${n}${t}${n}`}function gi(e){const t=Ir(e);return t.length?t.length===1?hb(t[0]):t.map(n=>hb(n)).join(", "):""}function Ar(e){const t=Ir(e);return t.length?t.map(n=>nz(n)).join(", "):e.trim()}const rz={100:"thin",hairline:"thin",thin:"thin",200:"extralight",ultralight:"extralight",extralight:"extralight",300:"light",light:"light",400:"regular",normal:"regular",regular:"regular",500:"medium",medium:"medium",600:"semibold",demibold:"semibold",semibold:"semibold",700:"bold",bold:"bold",800:"extrabold",ultrabold:"extrabold",extrabold:"extrabold",900:"black",heavy:"black",black:"black",950:"extrablack",ultrablack:"extrablack",extrablack:"extrablack"};function fb(e){const t=String(e).toLowerCase();return rz[t]||"regular"}const ho=new Map,Tu=new Map;let iz="sans-serif";function oz(e){return ho.has(e)?e:Tu.get(e)||e}const sz={fontFamily:"sans-serif",fontWeight:400,fontStyle:"normal",unitsPerEm:2048,metrics:{ascender:2189,descender:-555,lineGap:0},glyphs:{'"':727,"%":1821,"'":391,"(":682,")":682,"*":797,"+":1196,"-":682,"<":1196,"=":1196,">":1196,"@":2079,C:1479,D:1479,F:1251,G:1593,H:1479,J:1024,M:1706,N:1479,O:1593,Q:1593,R:1479,T:1251,U:1479,W:1933,Z:1251,"^":961,_:1024,"`":682,c:1024,i:455,j:455,k:1024,l:455,m:1706,r:682,s:1024,v:1024,w:1479,x:1024,y:1024,z:1024,"{":684,"|":532,"}":684,"~":1196},glyphsByWidth:{569:" !,./:;I[\\]ft",1139:"#$0123456789?Labdeghnopqu",1366:"&ABEKPSVXY"},defaultWidth:1139};function db(e){if(e===void 0||e==="normal")return"400";if(e==="bold")return"700";const t={thin:"100",hairline:"100","extra-light":"200","ultra-light":"200",light:"300",regular:"400",normal:"400",medium:"500","semi-bold":"600",semibold:"600","demi-bold":"600",demibold:"600","extra-bold":"800",extrabold:"800","ultra-bold":"800",ultrabold:"800",black:"900",heavy:"900","extra-black":"950",extrablack:"950","ultra-black":"950",ultrablack:"950",bolder:"900",lighter:"300"};if(typeof e=="string"){const n=e.toLowerCase();return t[n]||e}return String(e)}function pb(e){return e||"normal"}function az(e){const t=e.fontFamily,n=db(e.fontWeight),r=pb(e.fontStyle);if(e.aliases)for(const s of e.aliases)Tu.has(s)||Tu.set(s,t);if(e.glyphsByWidth){const s=ht({},e.glyphs||{});for(const[a,l]of Object.entries(e.glyphsByWidth))if(typeof l=="string"){const c=Number(a);for(const u of l)s[u]=c}else s[a]=l;e=zt(ht({},e),{glyphs:s,glyphsByWidth:void 0})}ho.has(t)||ho.set(t,new Map);const i=ho.get(t);i.has(n)||i.set(n,new Map),i.get(n).set(r,e)}function lz(e,t,n){const r=oz(e||iz),i=db(t),o=pb(n),s=ho.get(r);if(!s)return console.warn(`Font family "${r}" not registered, using fallback font data`),sz;let a=s.get(i);if(a){let c=a.get(o);if(c||o!=="normal"&&(c=a.get("normal"),c))return c;const u=a.values().next().value;if(u)return u}if(a=s.get("400"),a){let c=a.get(o);if(c||o!=="normal"&&(c=a.get("normal"),c))return c;const u=a.values().next().value;if(u)return u}const l=s.values().next().value;if(l){const c=l.values().next().value;if(c)return c}throw new Error(`No font data found for family "${r}" with weight "${i}" and style "${o}"`)}function cz(e,t){if(!t||t==="none")return e;switch(t){case"uppercase":return e.toUpperCase();case"lowercase":return e.toLowerCase();case"capitalize":return e.split(" ").map(n=>n.length===0?n:n[0].toUpperCase()+n.slice(1).toLowerCase()).join(" ");default:return e}}function gb(e){if(e===void 0)return 14;if(typeof e=="number")return e;const t=parseFloat(e);return isNaN(t)?16:t}function uz(e,t){const n=gb(e.fontSize),r=e.lineHeight;if(r===void 0){const{ascender:i,descender:o,lineGap:s=0}=t.metrics;return(i-o+s)/t.unitsPerEm*n}return typeof r=="number"?r*n:r.type==="pixel"?r.value:r.type==="percent"?r.value/100*n:n}function hz(e,t={}){var f;const n=cz(e,t.textTransform),r=lz(t.fontFamily,t.fontWeight,t.fontStyle),i=gb(t.fontSize),o=t.letterSpacing||0,s=t.wordSpacing||0;let a=0;const l=Array.from(n);for(let d=0;d<l.length;d++){const p=l[d],g=d<l.length-1?l[d+1]:void 0;let m=(f=r.glyphs)==null?void 0:f[p];m===void 0&&(m=r.defaultWidth||r.unitsPerEm/2);const v=m/r.unitsPerEm*i;if(a+=v,g&&r.kerning){const b=p+g,_=r.kerning[b];_!==void 0&&(a+=_/r.unitsPerEm*i)}d<l.length-1&&(a+=o),p===" "&&(a+=s)}const c=uz(t,r),{ascender:u}=r.metrics,h=u/r.unitsPerEm*i;return{width:a,height:c,baseline:h}}const fz={fontFamily:"Alibaba PuHuiTi",aliases:["AlibabaPuHuiTi","AlibabaPuHuiTi-Regular"],fontWeight:400,fontStyle:"normal",unitsPerEm:1e3,metrics:{ascender:1060,descender:-340,lineGap:0},glyphs:{" ":257,"!":361,'"':405,"#":600,"%":821,"&":640,"'":253,"(":359,")":359,"*":430,",":302,"-":440,".":302,"/":500,":":378,";":378,"?":431,"@":860,B:620,C:599,D:699,F:527,G:685,H:708,J:271,K:614,L:507,M:830,N:737,P:597,R:614,S:566,T:528,V:617,W:898,X:624,Y:594,Z:626,"[":294,"\\":510,"]":294,_:500,"`":346,b:635,c:497,d:635,f:349,g:636,k:518,l:286,m:921,p:635,q:636,r:379,s:479,t:337,v:526,w:828,x:516,y:527,z:506,"{":299,"|":183,"}":299," ":257,"¡":357,"¦":183,"§":479,"¨":346,"©":806,ª:483,"«":511,"":440,"®":404,"¯":346,"°":363,"´":346,"¶":593,"·":357,"¸":346,º:445,"»":511,"¼":902,"½":914,"¾":902,"¿":431,Æ:889,Ç:599,Ð:719,Ñ:737,Ý:594,Þ:597,ß:610,æ:926,ç:497,ý:527,þ:635,ÿ:527,Ć:599,ć:497,Ĉ:599,ĉ:497,Ċ:599,ċ:497,Č:599,č:497,Ď:699,ď:640,Đ:719,đ:635,Ĝ:685,ĝ:636,Ğ:685,ğ:636,Ġ:685,ġ:636,Ģ:685,ģ:636,Ĥ:708,Ħ:708,IJ:545,ij:536,Ĵ:271,Ķ:614,ķ:518,ĸ:518,Ĺ:507,ĺ:286,Ļ:507,ļ:286,Ľ:507,ľ:290,Ŀ:507,ŀ:291,Ł:507,ł:286,Ń:737,Ņ:737,Ň:737,ʼn:669,Ŋ:737,Œ:987,œ:917,Ŕ:614,ŕ:379,Ŗ:614,ŗ:379,Ř:614,ř:379,Ś:566,ś:479,Ŝ:566,ŝ:479,Ş:566,ş:479,Š:566,š:479,Ţ:528,ţ:337,Ť:528,ť:340,Ŧ:528,ŧ:337,Ŵ:898,ŵ:828,Ŷ:594,ŷ:527,Ÿ:594,Ź:626,ź:506,Ż:626,ż:506,Ž:626,ž:506,ſ:310,Ə:719,ǎ:608,ǐ:265,ǒ:614,ǔ:609,ǖ:609,ǘ:609,ǚ:609,ǜ:609,Ǽ:889,ǽ:926,Ș:566,ș:479,Ț:528,ț:337,"ʹ":255,"͵":255,";":378,"΄":346,"΅":346,Ά:670,"·":357,Έ:628,Ή:779,Ί:346,Ό:765,Ύ:726,Ώ:765,ΐ:312,Β:620,Γ:507,Ζ:626,Η:708,Κ:614,Λ:617,Μ:830,Ν:737,Π:708,Ρ:597,Σ:596,Τ:528,Υ:594,Φ:831,Χ:624,Ψ:804,Ϋ:594,έ:509,ή:643,ί:312,ΰ:593,β:610,γ:526,ε:509,ζ:465,η:643,θ:638,ι:312,κ:518,λ:514,ν:526,ξ:465,π:616,ρ:619,ς:497,σ:639,τ:437,υ:593,φ:774,χ:509,ψ:745,ω:782,ϊ:312,ϋ:593,ύ:593,ώ:782,"‐":440,"‑":440,"–":495,"—":684,"―":684,"‗":500,"‘":270,"’":270,"‚":270,"‛":270,"“":784,"”":784,"„":468,"†":500,"‡":500,"•":308,"…":1085,"‰":1174,"′":256,"″":472,"‴":689,"‵":256,"‶":472,"‷":689,"‹":312,"›":312,"‼":589,"‽":433,"‾":500,"⁄":120,"⁺":407,"⁻":407,"⁼":407,"⁽":225,"⁾":225,ⁿ:486,"₊":407,"₋":407,"₌":407,"₍":225,"₎":225,"ₙ":486,"₡":599,"₣":527,"₤":600,"₥":921,"₦":625,"₨":1093,"₩":769,"₪":754,"₫":635,"₭":614,"₮":528,"₯":1288,"₰":950,"₲":685,"₴":576,"₵":599,"₶":576,"₷":700,"₸":528,"₻":750,"₼":683,"₾":577,"₿":620,"℃":915,"℅":825,"℉":868,ℓ:385,"№":1176,"℗":806,"℡":1022,"™":903,"℮":903,"⅛":930,"⅜":931,"⅝":931,"⅞":871,"Ⅶ":1166,"∂":587,"∈":663,"∏":708,"∑":596,"√":604,"∞":679,"∧":617,"∫":531,"∮":654,"≈":600,"≒":662,"◊":600," ":0,"〞":472},glyphsByWidth:{268:"ijìíîïĩīĭįıĵȷ",274:"IÌÍÎÏĨĪĬĮİΙΪ",406:"²³¹⁰⁴⁵⁶⁷⁸⁹₀₁₂₃₄₅₆₇₈₉",552:"+<=>^~¬±×÷−∕∙≠≤≥≦≧≮≯",556:"EÈÉÊËĒĔĖĘĚΕΞ",575:"$0123456789¢£¤¥ƒ₢₧€₱₹₺₽",578:"eèéêëēĕėęě",612:"aàáâãäåāăąǻ",613:"uµùúûüũūŭůűųάαμ∨",618:"hnoðñòóôõöøĥħńņňŋōŏőǿδοό",667:"AÀÁÂÃÄÅĀĂĄǺΑΔ₳∆",701:"UÙÚÛÜŨŪŬŮŰŲ",743:"OQÒÓÔÕÖØŌŎŐǾΘΟΩΩ",1e3:"─━│┃┄┅┆┇┈┉┊┋┌┍┎┏┐┑┒┓└┕┖┗┘┙┚┛├┝┞┟┠┡┢┣┤┥┦┧┨┩┪┫┬┭┮┯┰┱┲┳┴┵┶┷┸┹┺┻┼┽┾┿╀╁╂╃╄╅╆╇╈╉╊╋═║╒╓╔╕╖╗╘╙╚╛╜╝╞╟╠╡╢╣╤╥╦╧╨╩╪╫╬╭╮╯╰╱╲╳▁▂▃▄▅▆▇█▉▊▋▌▍▎▏▓▔▕■□▲△▼▽◆◇○◎●◢◣◤◥★☆☉♀♂〾"},defaultWidth:984,kerning:{'""':-56,"\"'":-57,'",':-179,'".':-179,"'\"":-56,"''":-57,"',":-179,"'.":-179,"(j":60,',"':-160,",'":-160,",1":-140,",7":-41,",9":-39,'."':-160,".'":-160,".1":-140,".7":-41,".9":-39,"//":-120,"1,":-99,"1.":-99,"1:":-99,"1;":-99,"7,":-160,"7.":-160,"7:":-99,"7;":-99,":1":-79,":7":-59,";1":-79,";7":-59,'A"':-100,"A'":-100,AC:-20,AG:-20,AO:-20,AQ:-20,AT:-80,AU:-10,AV:-70,AW:-39,AY:-81,Af:-20,Al:-10,At:-20,Av:-20,Ay:-20,BC:-10,BG:-10,BO:-10,BQ:-10,BT:-40,BV:-20,BX:-20,BY:-21,"D,":-59,"D.":-59,DA:-20,DT:-36,DV:-30,DW:-19,DX:-20,DY:-40,DZ:-20,Da:-39,Ej:19,"F,":-159,"F.":-159,FA:-40,Fa:-59,Fh:1,Fk:1,GV:-11,GY:-21,JJ:7,KA:-19,KC:-20,KG:-20,KO:-20,KQ:-20,KT:-19,KU:-39,KV:-39,KW:-39,KY:-40,Kc:-39,Kd:-39,Ke:-39,Kg:-39,Kl:-39,Ko:-39,Kq:-39,Ks:-19,Kt:-10,Ku:-40,Kv:-60,Kw:-40,Ky:-60,'L"':-99,"L'":-99,LA:20,LC:-59,LG:-59,LO:-59,LQ:-59,LT:-79,LU:-19,LV:-79,LW:-39,LY:-100,Lv:-41,Lw:-21,Ly:-41,"O,":-59,"O.":-59,OA:-20,OT:-36,OV:-30,OW:-19,OX:-20,OY:-40,OZ:-20,Oa:-39,"P,":-199,"P.":-199,PA:-60,PT:-29,PV:-10,PW:-10,PX:-50,PY:-20,PZ:-39,Pa:-60,"Q,":-59,"Q.":-59,QA:-20,QJ:7,QT:-36,QV:-30,QW:-19,QX:-20,QY:-40,QZ:-20,Qa:-39,RC:-15,RG:-15,RO:-15,RQ:-15,RT:-40,RU:-10,RV:-21,RW:-10,RX:-29,RY:-41,Rc:-20,Rd:-20,Re:-20,Rg:-20,Ro:-20,Rq:-20,Rt:-20,Ru:-10,Rv:-10,Rx:20,Ry:-10,"S,":-20,"S.":-20,SS:-1,ST:-1,SV:-21,SW:-10,SY:-21,St:-1,Sv:-20,Sw:-10,Sx:-1,Sy:-20,'T"':2,"T'":2,"T,":-154,"T.":-154,TA:-80,TC:-20,TG:-20,TO:-20,TQ:-20,TS:-1,Ta:-80,Tc:-59,Td:-59,Te:-59,Tg:-59,Ti:-20,Tj:-19,Tm:-59,Tn:-59,To:-59,Tp:-58,Tq:-59,Tr:-59,Ts:-60,Tt:20,Tu:-79,Tv:-39,Tw:-19,Tx:-39,Ty:-39,Tz:-59,UA:-10,UX:-19,Ux:-1,"V,":-140,"V.":-140,"V:":-41,"V;":-41,VA:-70,VC:-30,VG:-30,VO:-30,VQ:-30,VS:-10,Va:-41,Vc:-21,Vd:-21,Ve:-21,Vg:-21,Vh:1,Vk:1,Vo:-21,Vq:-21,Vs:-21,Vv:-1,Vy:-1,"W,":-79,"W.":-79,"W:":-39,"W;":-39,WA:-40,WC:-19,WG:-19,WO:-19,WQ:-19,Wa:-40,Wc:-20,Wd:-20,We:-20,Wg:-20,Wo:-20,Wq:-20,Ws:-20,XA:-19,XC:-20,XG:-20,XO:-20,XQ:-20,XT:-19,XU:-39,XV:-39,XW:-39,XY:-40,Xc:-39,Xd:-39,Xe:-39,Xg:-39,Xl:-39,Xo:-39,Xq:-39,Xs:-19,Xt:-10,Xu:-40,Xv:-60,Xw:-40,Xy:-60,'Y"':1,"Y'":1,"Y,":-141,"Y.":-141,"Y:":-60,"Y;":-60,YA:-81,YC:-40,YG:-40,YO:-40,YQ:-40,YS:-1,Ya:-101,Yc:-60,Yd:-60,Ye:-60,Yf:-1,Yg:-60,Yh:1,Yi:-19,Yk:1,Ym:-41,Yn:-41,Yo:-60,Yp:-40,Yq:-60,Yr:-41,Ys:-61,Yt:-1,Yu:-40,Yv:-40,Yx:-41,Yy:-40,Yz:-41,ZC:-20,ZG:-20,ZO:-20,ZQ:-20,"[j":80,aT:-60,aV:-21,aY:-61,av:-10,aw:-10,ay:-10,"b,":-40,"b.":-40,bT:-59,bV:-21,bW:-20,bX:-39,bY:-60,bv:-10,bx:-20,by:-10,"e,":-20,"e.":-20,eT:-59,eY:-40,ej:20,'f"':3,"f'":3,"f)":1,"f*":61,"f,":-1,"f.":-1,"f?":40,fT:40,fV:21,fW:21,fX:21,fY:1,"f]":21,fa:-29,fc:-19,fd:-19,fe:-19,ff:1,fg:-39,fh:-19,fi:-19,fj:-19,fk:-19,fl:-19,fo:-19,fq:-19,fs:-19,ft:1,"f}":3,hT:-58,hY:-39,hv:-10,hy:-10,'i"':2,"i'":2,"i)":2,"i?":3,iT:-20,"i]":41,"i}":22,jT:-20,kT:-39,kU:-1,kW:-20,ka:-20,kc:-20,kd:-20,ke:-20,kg:-20,kl:-20,ko:-20,kq:-20,ku:-10,lf:-20,lv:-19,lw:-10,ly:-19,mT:-58,mY:-39,mv:-10,my:-10,nT:-58,nY:-39,nv:-10,ny:-10,"o,":-40,"o.":-40,oT:-59,oV:-21,oW:-20,oX:-39,oY:-60,ov:-10,ox:-20,oy:-10,"p,":-40,"p.":-40,pT:-59,pV:-21,pW:-20,pX:-39,pY:-60,pv:-10,px:-20,py:-10,qT:-19,qY:-19,qj:20,'r"':2,"r'":2,"r,":-90,"r.":-90,ra:-49,rc:-19,rd:-19,re:-19,rf:1,ro:-19,rq:-19,rt:20,sT:-59,sV:-21,sW:-20,sX:-19,sY:-60,sv:-19,sx:-10,sy:-19,tf:1,uT:-40,uY:-19,"v,":-90,"v.":-90,vT:-39,vX:-39,va:-35,vc:-10,vd:-10,ve:-10,vo:-10,vq:-10,"w,":-50,"w.":-50,wT:-19,wX:-39,wa:-30,xT:-39,xU:-1,xW:-20,xa:-20,xc:-20,xd:-20,xe:-20,xg:-20,xl:-20,xo:-20,xq:-20,xu:-10,"y,":-90,"y.":-90,yT:-39,yX:-39,ya:-35,yc:-10,yd:-10,ye:-10,yo:-10,yq:-10,zT:-59,"{h":2,"{j":79,"{k":2}};var dz=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});const mi=new WeakMap;function pz(e){const t=mi.get(e);return t?Array.from(t.values()):[]}function mb(e,t){var n;return(n=mi.get(e))==null?void 0:n.get(t)}function yb(e,t,n){let r=mi.get(e);return r||(r=new Map,mi.set(e,r)),r.set(t,n),n.finally(()=>{const i=mi.get(e);i&&(i.get(t)===n&&i.delete(t),i.size===0&&mi.delete(e))}),n}function gz(e){return dz(this,null,function*(){for(yield Promise.resolve();;){const t=pz(e);if(!t.length)break;yield Promise.allSettled(t),yield Promise.resolve()}})}var mz=Object.defineProperty,vb=Object.getOwnPropertySymbols,yz=Object.prototype.hasOwnProperty,vz=Object.prototype.propertyIsEnumerable,bb=(e,t,n)=>t in e?mz(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bz=(e,t)=>{for(var n in t||(t={}))yz.call(t,n)&&bb(e,n,t[n]);if(vb)for(var n of vb(t))vz.call(t,n)&&bb(e,n,t[n]);return e};const Ru=new Map;let ku="Alibaba PuHuiTi";function Lu(e){const t=Ir(e);for(const n of t){const r=Ru.get(gi(n));if(r)return r}return null}function Nu(){return Array.from(Ru.values())}function _z(e){ku=Ar(e)}function _b(e){const t=bz({},e);return Ru.set(t.fontFamily,t),t.fontFamily=Ar(t.fontFamily),t}function wb(e){const t=Ir(e).flatMap(n=>{const r=Lu(n);if(!r)return[];const{baseUrl:i,fontWeight:o}=r;return Object.values(o).filter(s=>!!s).map(s=>hh(i,s))});return Array.from(new Set(t))}function wz(e,t){const n=Ir(e);let r=null;for(const s of n)if(r=Lu(s),r)break;if(!r)return null;const i=fb(t),o=r.fontWeight[i];return o?hh(r.baseUrl,o.replace(/\/result.css$/,"")):null}const zu=new WeakMap,fo=new WeakMap;function xb(e,t,n){let r=fo.get(e);return r||(r=new Map,fo.set(e,r)),r.set(t,n),n.finally(()=>{const i=fo.get(e);i&&(i.get(t)===n&&i.delete(t),i.size===0&&fo.delete(e))}),n}function xz(e){if(e.getAttribute("data-infographic-font-loaded")==="true")return!0;try{return!!e.sheet}catch(t){return!1}}function Cz(e,t,n){var r;const i=(r=fo.get(e))==null?void 0:r.get(t);if(i)return i;if(!n||xz(n))return xb(e,t,Promise.resolve());const o=new Promise(s=>{const a=()=>{n.setAttribute("data-infographic-font-loaded","true"),s()};n.addEventListener("load",a,{once:!0}),n.addEventListener("error",a,{once:!0})});return xb(e,t,o)}function Pz(e,t){const n=e.ownerDocument,r=(n==null?void 0:n.head)||document.head;if(!r)return;zu.has(r)||zu.set(r,new Map);const i=zu.get(r),o=wb(t);if(!o.length)return;const s=[];o.forEach(a=>{const l=`${t}-${a}`,c=`font:${l}`;if(mb(e,c))return;let u=i.get(l);u||(u=n.createElement("link"),u.id=l,u.rel="stylesheet",u.href=a,s.push(u),i.set(l,u));const h=Cz(r,l,u);yb(e,c,h)}),s.length&&r.tagName==="HEAD"&&s.forEach(a=>r.appendChild(a))}function Oz(e){if(uh)return;Nu().forEach(n=>Pz(e,n.fontFamily))}const po="https://assets.antv.antgroup.com",yi=e=>`${e}/result.css`;[{fontFamily:"Alibaba PuHuiTi",name:"阿里巴巴普惠体",baseUrl:po,fontWeight:{regular:yi("AlibabaPuHuiTi-Regular"),bold:yi("AlibabaPuHuiTi-Bold")}},{fontFamily:"Source Han Sans",name:"黑体",baseUrl:po,fontWeight:{regular:yi("SourceHanSansCN-Regular")}},{fontFamily:"Source Han Serif",name:"宋体",baseUrl:po,fontWeight:{regular:yi("SourceHanSerifCN-Regular")}},{fontFamily:"LXGW WenKai",name:"楷体",baseUrl:po,fontWeight:{regular:yi("LXGWWenKai-Regular")}},{fontFamily:"851tegakizatsu",name:"手写体",baseUrl:po,fontWeight:{regular:yi("851tegakizatsu-Regular")}}].forEach(_b);const Du=new Map;function qu(e,t){Du.set(e,t)}function Cb(e){return Du.get(e)}function Sz(){return Object.fromEntries(Du)}qu("antv",["#1783FF","#00C9C9","#F0884D","#D580FF","#7863FF","#60C42D","#BD8F24","#FF80CA","#2491B3","#17C76F","#70CAF8"]),qu("spectral",(e,t,n)=>{const r=[["#fc8d59","#ffffbf","#99d594"],["#d7191c","#fdae61","#abdda4","#2b83ba"],["#d7191c","#fdae61","#ffffbf","#abdda4","#2b83ba"],["#d53e4f","#fc8d59","#fee08b","#e6f598","#99d594","#3288bd"],["#d53e4f","#fc8d59","#fee08b","#ffffbf","#e6f598","#99d594","#3288bd"],["#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd"],["#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd"],["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"],["#9e0142","#d53e4f","#f46d43","#fdae61","#fee08b","#ffffbf","#e6f598","#abdda4","#66c2a5","#3288bd","#5e4fa2"]],i=Math.min(Math.max(n,3),11);return r[i-3][t%i]});const Vs=(e=[],t,n)=>{var r;const i=typeof e=="string"?Cb(e)||[]:e,o=(r=t[0])!=null?r:0;if(typeof i=="function"){const s=n?o/n:0;return i(s,o,n!=null?n:0)}if(Array.isArray(i))return i.length===0?void 0:i[o%i.length]};function $z(e,t){var n,r;if(((n=t.svg)==null?void 0:n.background)===!1)return;const{themeConfig:{colorBg:i}}=t;if(!i)return;const o=e.parentElement;o&&(o.style.backgroundColor=i||"none");const s=xi(e,Ge.Background);if(e.style.backgroundColor=i,s)s.setAttribute("fill",i);else if((r=e.viewBox)!=null&&r.baseVal){const{x:a,y:l,width:c,height:u}=e.viewBox.baseVal,h=Me("rect",{x:a,y:l,width:c,height:u,fill:i,"data-element-type":Ge.Background});e.prepend(h)}}function go(e,t){return Object.entries(t).reduce((r,[i,o])=>{if(typeof o=="function"){const s=o(e.getAttribute(i),e);s!=null&&(r[i]=s)}else Object.assign(r,{[i]:o});return r},{})}function Pb(e){return e.replace(/#|%|\.| |\/|\(|\)/g,"").replace(/,/g,"-")}function Ez(e,t){t&&Object.keys(t).length>0&&wi(e,n=>{const r=go(n,t);ut(n,r)})}const Ob="btn-add-icon",Sb="btn-remove-icon";function Mz(e,t){ut(t,{display:"none"});const n=t.querySelectorAll('[id^="btn-add-"]'),r=t.querySelectorAll('[id^="btn-remove-"]');Az(e),n.forEach(Tz),r.forEach(Rz)}const Iz="btn-icon-defs";function Az(e){const t=Me("defs");xo(t,Iz);const n=_i(`<symbol class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="200" height="200">
|
|
5
5
|
<path
|
|
6
6
|
d="M512 1024C229.216 1024 0 794.784 0 512S229.216 0 512 0s512 229.216 512 512-229.216 512-512 512z m0-960C264.576 64 64 264.576 64 512s200.576 448 448 448 448-200.576 448-448S759.424 64 512 64z m192 480h-160v160a32 32 0 0 1-64 0v-160h-160a32 32 0 0 1 0-64h160v-160a32 32 0 0 1 64 0v160h160a32 32 0 0 1 0 64z"
|
|
7
7
|
fill="#339900"></path>
|
|
8
|
-
</symbol>`);n&&(n.setAttribute("id",
|
|
8
|
+
</symbol>`);n&&(n.setAttribute("id",Ob),t.appendChild(n));const r=_i(`<symbol viewBox="0 0 1025 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="200" height="200">
|
|
9
9
|
<path d="M874.971429 149.942857C776.228571 54.857143 648.228571 0 512.914286 0S245.942857 54.857143 150.857143 149.942857c-201.142857 201.142857-201.142857 522.971429 0 724.114286C245.942857 969.142857 377.6 1024 512.914286 1024s266.971429-54.857143 362.057143-149.942857c201.142857-201.142857 201.142857-522.971429 0-724.114286m-51.2 672.914286C739.657143 906.971429 629.942857 950.857143 512.914286 950.857143s-226.742857-43.885714-310.857143-128c-171.885714-171.885714-171.885714-449.828571 0-621.714286C286.171429 117.028571 395.885714 73.142857 512.914286 73.142857s226.742857 43.885714 310.857143 128c171.885714 171.885714 171.885714 449.828571 0 621.714286" fill="#E63C33"></path>
|
|
10
10
|
<path d="M772.571429 475.428571H253.257143c-21.942857 0-36.571429 14.628571-36.571429 36.571429 0 10.971429 3.657143 18.285714 10.971429 25.6s14.628571 10.971429 25.6 10.971429H768.914286c21.942857 0 36.571429-14.628571 36.571428-36.571429s-14.628571-36.571429-32.914285-36.571429" fill="#E63C33"></path>
|
|
11
|
-
</symbol>`);r&&(r.setAttribute("id",
|
|
12
|
-
<symbol xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${i} ${o}" preserveAspectRatio="${
|
|
11
|
+
</symbol>`);r&&(r.setAttribute("id",Sb),t.appendChild(r)),e.prepend(t)}function $b(e,t){const{id:n,x:r=0,y:i=0,width:o=0,height:s=0}=cn(e,["id","x","y","width","height"]),a=Me("g",{id:n,class:"btn-group",transform:`translate(${r}, ${i})`}),l=e.getAttribute("data-items");l&&a.setAttribute("data-items",l);const c=Math.max(+o,+s)/2,u=Me("circle",{cx:c,cy:c,r:c,fill:"#fff",stroke:"transparent"});a.appendChild(u);const h=Me("use",{href:`#${t}`,width:o,height:s});a.appendChild(h),a.style.cursor="pointer",e.replaceWith(a)}function Tz(e){$b(e,Ob)}function Rz(e){$b(e,Sb)}var kz=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function Lz(e){return e.startsWith("data:")}function mo(e){return kz(this,null,function*(){var t;if(!e||!Lz(e))return null;const n=(t=e.match(/^data:([^;]+)/))==null?void 0:t[1];if(!n)return null;const r=()=>new Promise((c,u)=>{const h=new Image;h.onload=()=>{const f=h.naturalWidth,d=h.naturalHeight,p=document.createElement("canvas"),g=p.getContext("2d");if(!g)return c({width:f,height:d,hasAlpha:!1});if(["image/jpeg","image/jpg","image/webp","image/gif"].includes(n))return c({width:f,height:d,hasAlpha:!1});p.width=f,p.height=d,g.drawImage(h,0,0);let m=!1;const v=10;for(let b=0;b<f&&!m;b+=v)for(let _=0;_<d;_+=v)if(g.getImageData(b,_,1,1).data[3]<255){m=!0;break}c({width:f,height:d,hasAlpha:m})},h.onerror=()=>u(new Error("Failed to analysis image")),h.src=e}),{width:i,height:o,hasAlpha:s}=yield r(),l=(()=>{if(s||n!=null&&n.includes("image/gif")||n!=null&&n.includes("image/svg")||Math.min(i,o)<=200)return"xMidYMid meet";const u=i/o;return u>=.6&&u<=1.67||u<.3||u>3.33?"xMidYMid meet":"xMidYMid slice"})();return _i(`
|
|
12
|
+
<symbol xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${i} ${o}" preserveAspectRatio="${l}">
|
|
13
13
|
<image href="${e}" width="${i}" height="${o}" />
|
|
14
|
-
</symbol>`)})}function sz(e){const t=e.trim();return/^(?:<\?xml[^>]*>\s*)?<svg[\s>]/i.test(t)||t.startsWith("<symbol")}function di(e){if(!e||!sz(e))return null;const t=e.replace(/<svg(?=[\s/>])/i,"<symbol").replace(/<\/svg>/i,"</symbol>");return pi(t)}var cz=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});function lz(e){try{return!!new URL(e)}catch(t){return!1}}function uz(e,t){return!!(e.toLowerCase().includes("image/svg")||!e&&t==="svg")}function kv(e,t){return cz(this,null,function*(){if(!e||!lz(e))return null;const n=yield as(e);if(!n.ok)throw new Error("Failed to load resource");const r=n.headers.get("Content-Type")||"";if(uz(r,t)){const a=yield n.text();return di(a)}const i=yield n.blob(),o=yield hz(i);return so(o)})}function hz(e){return new Promise((t,n)=>{const r=new FileReader;r.onloadend=()=>{t(r.result)},r.onerror=n,r.readAsDataURL(e)})}var Rv=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});const dz=e=>Rv(null,null,function*(){var t;try{const n=new URLSearchParams({text:e,topK:"1"}),r=`${iM}?${n.toString()}`,i=yield as(r);if(!i.ok)return null;const o=yield i.json();return!(o!=null&&o.status)||!Array.isArray((t=o.data)==null?void 0:t.data)?null:o.data.data[0]||null}catch(n){return console.error(`Failed to query icon for "${e}":`,n),null}});function fz(e){return e.startsWith("data:")}function pz(e){const t=e.trim();return t.startsWith("<svg")||t.startsWith("<symbol")}function Lv(e,t){return Rv(this,null,function*(){var n;if(!e)return null;const r=yield dz(e);if(!r)return null;if(pz(r))return di(r);if(fz(r)){const i=((n=r.match(/^data:([^;]+)/))==null?void 0:n[1])||"",o=r.includes(";base64,");if(i==="image/svg+xml"&&!o){const a=r.indexOf(","),s=a>=0?r.slice(a+1):r;return di(s)}return so(r)}return kv(r,t)})}let zv=null;function gz(e){zv=e}function mz(){return zv}function yz(e){if(!e.startsWith("data:"))return null;const t=e.indexOf(",");if(t===-1)return null;const n=e.slice(5,t),r=e.slice(t+1),i=n.split(";"),o=i[0],a=i.includes("base64");return o==="image/svg+xml"&&!a?{source:"inline",format:"svg",encoding:"raw",data:r.startsWith("%3C")?decodeURIComponent(r):r}:o.startsWith("image/")?{source:"inline",format:o==="image/svg+xml"?"svg":"image",encoding:a?"base64":"data-uri",data:e}:null}const vz=new Set(["svg","png","jpg","jpeg","webp","gif"]);function bz(e){const t=e.trim();return t.startsWith("<svg")||t.startsWith("<symbol")}function _z(e){const t=e.toLowerCase();if(t.endsWith(".svg")||t.includes(".svg?"))return"svg";if(t.endsWith(".png")||t.endsWith(".jpg")||t.endsWith(".jpeg")||t.endsWith(".webp")||t.endsWith(".gif"))return"image"}function xz(e){var t;if(!e.startsWith("ref:"))return null;const n=e.slice(4),[r,...i]=n.split(":");if(!r||i.length===0)return null;let o;i.length>1&&vz.has(i[0].toLowerCase())&&(o=(t=i.shift())==null?void 0:t.toLowerCase());const a=i.join(":");if(!a)return null;const s=r==="url"?"remote":r;return s==="remote"?{source:"remote",format:o||_z(a)||void 0,data:a}:s==="search"?{source:"search",format:o||"svg",data:a}:s==="svg"?{source:"inline",format:"svg",data:a,encoding:"raw"}:{source:"custom",data:e,format:o}}function Na(e){if(!e)return null;if(typeof e!="string"){if(e.source)return e;const r=e;return r.type==="image"?{source:"inline",format:"image",data:r.data}:r.type==="svg"?{source:"inline",format:"svg",encoding:"raw",data:r.data}:r.type==="remote"?{source:"remote",format:r.format,data:r.data}:r.type==="search"?{source:"search",format:r.format||"svg",data:r.data}:r.type==="custom"?{source:"custom",data:r.data}:null}const t=yz(e);if(t)return t;const n=xz(e);return n||(bz(e)?{source:"inline",format:"svg",encoding:"raw",data:e}:{source:"custom",data:e})}function wu(e){const t=typeof e=="string"?Na(e):e;return t?"rsc-"+Nb(JSON.stringify(t)):null}function Nv(e){const t=wu(e);return t?`#${t}`:null}var Pu=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});function wz(e,t,n){return Pu(this,null,function*(){const r=Na(t);if(!r)return null;r.scene||(r.scene=e);const{source:i,data:o,format:a,encoding:s}=r;let c=null;try{if(i==="inline"){const l=o.startsWith("data:");a==="svg"&&s==="raw"?c=di(o):a==="svg"&&l?c=yield so(o):l||a==="image"?c=yield so(o):c=di(o)}else if(i==="remote")c=yield kv(o,a);else if(i==="search")c=yield Lv(o,a);else{const l=mz();l&&(c=yield l(r))}}catch(l){c=null}return c||(yield Lv(Pz(r,e,n),a))})}const Dv=new Map,Da=new WeakMap;function Hv(e,t,n,r){return Pu(this,null,function*(){if(!e)return null;const i=Na(n);if(!i)return null;const o=wu(i),a=`resource:${o}`,s=Da.get(e);if(s!=null&&s.has(o))return o;const c=xv(e,a);if(c)return yield c;const l=Pu(null,null,function*(){const u=Dv.has(o)?Dv.get(o)||null:yield wz(t,i,r);if(!u)return null;Da.has(e)||Da.set(e,new Map);const h=Da.get(e);if(h.has(o))return o;const d=rs(e);return u.id=o,d.appendChild(u),h.set(o,u),o});return wv(e,a,l),yield l})}function Pz(e,t,n){const r=t==="illus"?"illustration":"icon",i=Ha(e.data)||Ha(n==null?void 0:n.label)||Ha(n==null?void 0:n.desc);if(i)return i;const o=Ha(e.data);return!o||e.source==="inline"||o.startsWith("data:")||o.startsWith("<svg")||o.startsWith("<symbol")?r:o}function Ha(e){if(typeof e!="string")return null;const t=e.trim();return t||null}var $z=Object.defineProperty,qv=Object.getOwnPropertySymbols,Cz=Object.prototype.hasOwnProperty,Oz=Object.prototype.propertyIsEnumerable,jv=(e,t,n)=>t in e?$z(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qa=(e,t)=>{for(var n in t||(t={}))Cz.call(t,n)&&jv(e,n,t[n]);if(qv)for(var n of qv(t))Oz.call(t,n)&&jv(e,n,t[n]);return e};function Sz(e,t,n,r){var i,o;const a=n.icon;if(!a)return null;const{themeConfig:s}=r,c=(i=n.attributes)==null?void 0:i.icon,l=qa(qa({},(o=s.item)==null?void 0:o.icon),c),u=ao(t,l);return Mz(e,t,a,u,n)}function Mz(e,t,n,r,i){return Hv(e,"icon",n,i),XD(n,qa(qa({},sn(t,["id","x","y","width","height","fill","stroke","data-element-type","data-indexes"])),r))}var Ez=Object.defineProperty,Iz=Object.defineProperties,Az=Object.getOwnPropertyDescriptors,ja=Object.getOwnPropertySymbols,Fv=Object.prototype.hasOwnProperty,Bv=Object.prototype.propertyIsEnumerable,Wv=(e,t,n)=>t in e?Ez(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,co=(e,t)=>{for(var n in t||(t={}))Fv.call(t,n)&&Wv(e,n,t[n]);if(ja)for(var n of ja(t))Bv.call(t,n)&&Wv(e,n,t[n]);return e},Gv=(e,t)=>Iz(e,Az(t)),Tz=(e,t)=>{var n={};for(var r in e)Fv.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ja)for(var r of ja(e))t.indexOf(r)<0&&Bv.call(e,r)&&(n[r]=e[r]);return n};function Vv(e,t,n,r,i={}){if(!n)return null;const o=Na(n);if(!o)return null;const a=wu(o);i&&Object.keys(i).length>0&<(t,i);const s=Rz(e,t,a);Hv(e,"illus",o,r);const{data:c,color:l}=o;return Lz(a,Gv(co(co(co({},zz(t)),l?{color:l}:{}),i),{"clip-path":`url(#${s})`}),c)}function kz(e,t,n){var r;const i=n.illus,o=(r=n.attributes)==null?void 0:r.illus;return Vv(e,t,i,n,o)}function Rz(e,t,n){const r=`clip-${n}-${JD()}`;if(e.querySelector(`#${r}`))return r;const i=rs(e),o=Ee("clipPath",{id:r}),a=t.cloneNode();return lD(a,["id","data-illus-bounds","data-element-type"]),o.appendChild(a),i.appendChild(o),r}function Lz(e,t,n){const r=t,{"clip-path":i}=r,o=Tz(r,["clip-path"]),{x:a="0",y:s="0",width:c="0",height:l="0"}=o,u=Ee("rect",{id:`${e}-volume`,"data-element-type":Ve.IllusVolume,x:a,y:s,width:c,height:l,fill:"transparent"}),h=Ee("g",{"data-element-type":Ve.IllusGroup,"clip-path":i,id:`${e}-group`});h.appendChild(u);const d=Ee("use",Gv(co({id:e,fill:"lightgray"},o),{href:Nv(n),"data-element-type":Ve.Illus}));return h.appendChild(d),h}function zz(e){const t=e.getAttribute("data-illus-bounds");if(!t)return co({x:"0",y:"0",width:"0",height:"0"},sn(e,["x","y","width","height"]));const[n,r,i,o]=t.split(" ");return{x:n,y:r,width:i,height:o}}function Fa(e){"@babel/helpers - typeof";return Fa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Fa(e)}var Nz=/^\s+/,Dz=/\s+$/;function be(e,t){if(e=e||"",t=t||{},e instanceof be)return e;if(!(this instanceof be))return new be(e,t);var n=Hz(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=Math.round(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=n.ok}be.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},getLuminance:function(){var t=this.toRgb(),n,r,i,o,a,s;return n=t.r/255,r=t.g/255,i=t.b/255,n<=.03928?o=n/12.92:o=Math.pow((n+.055)/1.055,2.4),r<=.03928?a=r/12.92:a=Math.pow((r+.055)/1.055,2.4),i<=.03928?s=i/12.92:s=Math.pow((i+.055)/1.055,2.4),.2126*o+.7152*a+.0722*s},setAlpha:function(t){return this._a=Qv(t),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var t=Xv(this._r,this._g,this._b);return{h:t.h*360,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=Xv(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.v*100);return this._a==1?"hsv("+n+", "+r+"%, "+i+"%)":"hsva("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=Yv(this._r,this._g,this._b);return{h:t.h*360,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=Yv(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.l*100);return this._a==1?"hsl("+n+", "+r+"%, "+i+"%)":"hsla("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return Uv(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(t){return Bz(this._r,this._g,this._b,this._a,t)},toHex8String:function(t){return"#"+this.toHex8(t)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(vt(this._r,255)*100)+"%",g:Math.round(vt(this._g,255)*100)+"%",b:Math.round(vt(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(vt(this._r,255)*100)+"%, "+Math.round(vt(this._g,255)*100)+"%, "+Math.round(vt(this._b,255)*100)+"%)":"rgba("+Math.round(vt(this._r,255)*100)+"%, "+Math.round(vt(this._g,255)*100)+"%, "+Math.round(vt(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:tN[Uv(this._r,this._g,this._b,!0)]||!1},toFilter:function(t){var n="#"+Kv(this._r,this._g,this._b,this._a),r=n,i=this._gradientType?"GradientType = 1, ":"";if(t){var o=be(t);r="#"+Kv(o._r,o._g,o._b,o._a)}return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+n+",endColorstr="+r+")"},toString:function(t){var n=!!t;t=t||this._format;var r=!1,i=this._a<1&&this._a>=0,o=!n&&i&&(t==="hex"||t==="hex6"||t==="hex3"||t==="hex4"||t==="hex8"||t==="name");return o?t==="name"&&this._a===0?this.toName():this.toRgbString():(t==="rgb"&&(r=this.toRgbString()),t==="prgb"&&(r=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(r=this.toHexString()),t==="hex3"&&(r=this.toHexString(!0)),t==="hex4"&&(r=this.toHex8String(!0)),t==="hex8"&&(r=this.toHex8String()),t==="name"&&(r=this.toName()),t==="hsl"&&(r=this.toHslString()),t==="hsv"&&(r=this.toHsvString()),r||this.toHexString())},clone:function(){return be(this.toString())},_applyModification:function(t,n){var r=t.apply(null,[this].concat([].slice.call(n)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(Yz,arguments)},brighten:function(){return this._applyModification(Xz,arguments)},darken:function(){return this._applyModification(Uz,arguments)},desaturate:function(){return this._applyModification(Wz,arguments)},saturate:function(){return this._applyModification(Gz,arguments)},greyscale:function(){return this._applyModification(Vz,arguments)},spin:function(){return this._applyModification(Kz,arguments)},_applyCombination:function(t,n){return t.apply(null,[this].concat([].slice.call(n)))},analogous:function(){return this._applyCombination(Jz,arguments)},complement:function(){return this._applyCombination(Zz,arguments)},monochromatic:function(){return this._applyCombination(eN,arguments)},splitcomplement:function(){return this._applyCombination(Qz,arguments)},triad:function(){return this._applyCombination(Zv,[3])},tetrad:function(){return this._applyCombination(Zv,[4])}},be.fromRatio=function(e,t){if(Fa(e)=="object"){var n={};for(var r in e)e.hasOwnProperty(r)&&(r==="a"?n[r]=e[r]:n[r]=lo(e[r]));e=n}return be(e,t)};function Hz(e){var t={r:0,g:0,b:0},n=1,r=null,i=null,o=null,a=!1,s=!1;return typeof e=="string"&&(e=oN(e)),Fa(e)=="object"&&(jn(e.r)&&jn(e.g)&&jn(e.b)?(t=qz(e.r,e.g,e.b),a=!0,s=String(e.r).substr(-1)==="%"?"prgb":"rgb"):jn(e.h)&&jn(e.s)&&jn(e.v)?(r=lo(e.s),i=lo(e.v),t=Fz(e.h,r,i),a=!0,s="hsv"):jn(e.h)&&jn(e.s)&&jn(e.l)&&(r=lo(e.s),o=lo(e.l),t=jz(e.h,r,o),a=!0,s="hsl"),e.hasOwnProperty("a")&&(n=e.a)),n=Qv(n),{ok:a,format:e.format||s,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}function qz(e,t,n){return{r:vt(e,255)*255,g:vt(t,255)*255,b:vt(n,255)*255}}function Yv(e,t,n){e=vt(e,255),t=vt(t,255),n=vt(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,a,s=(r+i)/2;if(r==i)o=a=0;else{var c=r-i;switch(a=s>.5?c/(2-r-i):c/(r+i),r){case e:o=(t-n)/c+(t<n?6:0);break;case t:o=(n-e)/c+2;break;case n:o=(e-t)/c+4;break}o/=6}return{h:o,s:a,l:s}}function jz(e,t,n){var r,i,o;e=vt(e,360),t=vt(t,100),n=vt(n,100);function a(l,u,h){return h<0&&(h+=1),h>1&&(h-=1),h<1/6?l+(u-l)*6*h:h<1/2?u:h<2/3?l+(u-l)*(2/3-h)*6:l}if(t===0)r=i=o=n;else{var s=n<.5?n*(1+t):n+t-n*t,c=2*n-s;r=a(c,s,e+1/3),i=a(c,s,e),o=a(c,s,e-1/3)}return{r:r*255,g:i*255,b:o*255}}function Xv(e,t,n){e=vt(e,255),t=vt(t,255),n=vt(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,a,s=r,c=r-i;if(a=r===0?0:c/r,r==i)o=0;else{switch(r){case e:o=(t-n)/c+(t<n?6:0);break;case t:o=(n-e)/c+2;break;case n:o=(e-t)/c+4;break}o/=6}return{h:o,s:a,v:s}}function Fz(e,t,n){e=vt(e,360)*6,t=vt(t,100),n=vt(n,100);var r=Math.floor(e),i=e-r,o=n*(1-t),a=n*(1-i*t),s=n*(1-(1-i)*t),c=r%6,l=[n,a,o,o,s,n][c],u=[s,n,n,a,o,o][c],h=[o,o,s,n,n,a][c];return{r:l*255,g:u*255,b:h*255}}function Uv(e,t,n,r){var i=[dn(Math.round(e).toString(16)),dn(Math.round(t).toString(16)),dn(Math.round(n).toString(16))];return r&&i[0].charAt(0)==i[0].charAt(1)&&i[1].charAt(0)==i[1].charAt(1)&&i[2].charAt(0)==i[2].charAt(1)?i[0].charAt(0)+i[1].charAt(0)+i[2].charAt(0):i.join("")}function Bz(e,t,n,r,i){var o=[dn(Math.round(e).toString(16)),dn(Math.round(t).toString(16)),dn(Math.round(n).toString(16)),dn(Jv(r))];return i&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0):o.join("")}function Kv(e,t,n,r){var i=[dn(Jv(r)),dn(Math.round(e).toString(16)),dn(Math.round(t).toString(16)),dn(Math.round(n).toString(16))];return i.join("")}be.equals=function(e,t){return!e||!t?!1:be(e).toRgbString()==be(t).toRgbString()},be.random=function(){return be.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function Wz(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.s-=t/100,n.s=Ba(n.s),be(n)}function Gz(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.s+=t/100,n.s=Ba(n.s),be(n)}function Vz(e){return be(e).desaturate(100)}function Yz(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.l+=t/100,n.l=Ba(n.l),be(n)}function Xz(e,t){t=t===0?0:t||10;var n=be(e).toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(255*-(t/100)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(255*-(t/100)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(255*-(t/100)))),be(n)}function Uz(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.l-=t/100,n.l=Ba(n.l),be(n)}function Kz(e,t){var n=be(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,be(n)}function Zz(e){var t=be(e).toHsl();return t.h=(t.h+180)%360,be(t)}function Zv(e,t){if(isNaN(t)||t<=0)throw new Error("Argument to polyad must be a positive number");for(var n=be(e).toHsl(),r=[be(e)],i=360/t,o=1;o<t;o++)r.push(be({h:(n.h+o*i)%360,s:n.s,l:n.l}));return r}function Qz(e){var t=be(e).toHsl(),n=t.h;return[be(e),be({h:(n+72)%360,s:t.s,l:t.l}),be({h:(n+216)%360,s:t.s,l:t.l})]}function Jz(e,t,n){t=t||6,n=n||30;var r=be(e).toHsl(),i=360/n,o=[be(e)];for(r.h=(r.h-(i*t>>1)+720)%360;--t;)r.h=(r.h+i)%360,o.push(be(r));return o}function eN(e,t){t=t||6;for(var n=be(e).toHsv(),r=n.h,i=n.s,o=n.v,a=[],s=1/t;t--;)a.push(be({h:r,s:i,v:o})),o=(o+s)%1;return a}be.mix=function(e,t,n){n=n===0?0:n||50;var r=be(e).toRgb(),i=be(t).toRgb(),o=n/100,a={r:(i.r-r.r)*o+r.r,g:(i.g-r.g)*o+r.g,b:(i.b-r.b)*o+r.b,a:(i.a-r.a)*o+r.a};return be(a)},be.readability=function(e,t){var n=be(e),r=be(t);return(Math.max(n.getLuminance(),r.getLuminance())+.05)/(Math.min(n.getLuminance(),r.getLuminance())+.05)},be.isReadable=function(e,t,n){var r=be.readability(e,t),i,o;switch(o=!1,i=aN(n),i.level+i.size){case"AAsmall":case"AAAlarge":o=r>=4.5;break;case"AAlarge":o=r>=3;break;case"AAAsmall":o=r>=7;break}return o},be.mostReadable=function(e,t,n){var r=null,i=0,o,a,s,c;n=n||{},a=n.includeFallbackColors,s=n.level,c=n.size;for(var l=0;l<t.length;l++)o=be.readability(e,t[l]),o>i&&(i=o,r=be(t[l]));return be.isReadable(e,r,{level:s,size:c})||!a?r:(n.includeFallbackColors=!1,be.mostReadable(e,["#fff","#000"],n))};var $u=be.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},tN=be.hexNames=nN($u);function nN(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}function Qv(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function vt(e,t){rN(e)&&(e="100%");var n=iN(e);return e=Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),Math.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function Ba(e){return Math.min(1,Math.max(0,e))}function on(e){return parseInt(e,16)}function rN(e){return typeof e=="string"&&e.indexOf(".")!=-1&&parseFloat(e)===1}function iN(e){return typeof e=="string"&&e.indexOf("%")!=-1}function dn(e){return e.length==1?"0"+e:""+e}function lo(e){return e<=1&&(e=e*100+"%"),e}function Jv(e){return Math.round(parseFloat(e)*255).toString(16)}function eb(e){return on(e)/255}var fn=(function(){var e="[-\\+]?\\d+%?",t="[-\\+]?\\d*\\.\\d+%?",n="(?:"+t+")|(?:"+e+")",r="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?",i="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?";return{CSS_UNIT:new RegExp(n),rgb:new RegExp("rgb"+r),rgba:new RegExp("rgba"+i),hsl:new RegExp("hsl"+r),hsla:new RegExp("hsla"+i),hsv:new RegExp("hsv"+r),hsva:new RegExp("hsva"+i),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}})();function jn(e){return!!fn.CSS_UNIT.exec(e)}function oN(e){e=e.replace(Nz,"").replace(Dz,"").toLowerCase();var t=!1;if($u[e])e=$u[e],t=!0;else if(e=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n;return(n=fn.rgb.exec(e))?{r:n[1],g:n[2],b:n[3]}:(n=fn.rgba.exec(e))?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=fn.hsl.exec(e))?{h:n[1],s:n[2],l:n[3]}:(n=fn.hsla.exec(e))?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=fn.hsv.exec(e))?{h:n[1],s:n[2],v:n[3]}:(n=fn.hsva.exec(e))?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=fn.hex8.exec(e))?{r:on(n[1]),g:on(n[2]),b:on(n[3]),a:eb(n[4]),format:t?"name":"hex8"}:(n=fn.hex6.exec(e))?{r:on(n[1]),g:on(n[2]),b:on(n[3]),format:t?"name":"hex"}:(n=fn.hex4.exec(e))?{r:on(n[1]+""+n[1]),g:on(n[2]+""+n[2]),b:on(n[3]+""+n[3]),a:eb(n[4]+""+n[4]),format:t?"name":"hex8"}:(n=fn.hex3.exec(e))?{r:on(n[1]+""+n[1]),g:on(n[2]+""+n[2]),b:on(n[3]+""+n[3]),format:t?"name":"hex"}:!1}function aN(e){var t,n;return e=e||{level:"AA",size:"small"},t=(e.level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),t!=="AA"&&t!=="AAA"&&(t="AA"),n!=="small"&&n!=="large"&&(n="small"),{level:t,size:n}}var sN=Object.defineProperty,tb=Object.getOwnPropertySymbols,cN=Object.prototype.hasOwnProperty,lN=Object.prototype.propertyIsEnumerable,nb=(e,t,n)=>t in e?sN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,uN=(e,t)=>{for(var n in t||(t={}))cN.call(t,n)&&nb(e,n,t[n]);if(tb)for(var n of tb(t))lN.call(t,n)&&nb(e,n,t[n]);return e};function rb(e,t,n,r){const i=e.getAttribute(r),o=hN(i,n),{type:a,colors:s=[]}=o,c=s.length-1,l=s.map((f,g)=>typeof f=="string"?Ee("stop",{offset:`${g/c}`,"stop-color":f}):Ee("stop",{offset:`${f.offset}`,"stop-color":f.color})),u=dN(o);if(a==="linear-gradient"){const{angle:f=0}=o,[[g,y],[m,v]]=fN(f),b=Ee("linearGradient",{id:u,x1:g,y1:y,x2:m,y2:v});l.forEach(_=>b.appendChild(_)),ib(t,u,b)}else if(a==="radial-gradient"){const f=Ee("radialGradient",{id:u});l.forEach(g=>f.appendChild(g)),ib(t,u,f)}const h=e.getAttribute("fill"),d=e.getAttribute("stroke");_r(h)&&e.setAttribute("fill",`url(#${u})`),_r(d)&&e.setAttribute("stroke",`url(#${u})`)}function ib(e,t,n){const r=rs(e);n.setAttribute("id",t);const i=r.querySelector(`#${t}`);i?i.replaceWith(n):r.appendChild(n)}function hN(e,t){var n;if((n=t.colors)!=null&&n.length||!e)return t;const r=be(e),i=uN({},t);return i.colors=r.isDark()?[e,r.lighten(20).toHexString()]:[r.darken(20).toHexString(),e],!("angle"in t)&&i.type==="linear-gradient"&&(i.angle=225),i}function dN(e){const{type:t,colors:n=[]}=e,r=Ev(n.map(i=>typeof i=="string"?i:`${i.color}_${i.offset}`).join("-"));if(t==="linear-gradient"){const{angle:i=0}=e;return`${t}-${r}-${i}`}return`${t}-${r}`}function fN(e){const t=Math.PI/180*e,n=Math.cos(t),r=Math.sin(t);return[[.5-n/2,.5-r/2],[.5+n/2,.5+r/2]]}const pN=Object.freeze(Object.defineProperty({__proto__:null,diamond:({scale:e=.5,backgroundColor:t,foregroundColor:n})=>{const r=Ee("pattern",{id:"pattern-diamond",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Ee("rect",{width:"100%",height:"100%",fill:t}),o=Ee("path",{d:"M0,0 L20,20 M20,0 L0,20",stroke:n,"stroke-width":"1"});return r.appendChild(i),r.appendChild(o),r},dot:({scale:e=1,backgroundColor:t,foregroundColor:n})=>{const r=Ee("pattern",{id:"pattern-dot",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Ee("rect",{width:"100%",height:"100%",fill:t}),o=Ee("circle",{cx:"5",cy:"5",r:"3",fill:n}),a=Ee("circle",{cx:"15",cy:"15",r:"3",fill:n});return r.appendChild(i),r.appendChild(o),r.appendChild(a),r},hex:({scale:e=.3,backgroundColor:t,foregroundColor:n})=>{const r=Ee("pattern",{id:"pattern-hex",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Ee("rect",{width:"100%",height:"100%",fill:t}),o=Ee("path",{d:"M10,0 L20,5 L20,15 L10,20 L0,15 L0,5 Z",fill:n});return r.appendChild(i),r.appendChild(o),r},line:({scale:e=1,backgroundColor:t,foregroundColor:n})=>{const o=Ee("pattern",{id:"pattern-line",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),a=Ee("rect",{width:"100%",height:"100%",fill:t}),s=Ee("line",{x1:"7",y1:"-3",x2:"23",y2:"13",stroke:n,"stroke-width":6,"stroke-opacity":"0.5"}),c=Ee("line",{x1:"-3",y1:"7",x2:"13",y2:"23",stroke:n,"stroke-width":6,"stroke-opacity":"0.5"});return o.appendChild(a),o.appendChild(s),o.appendChild(c),o},mosaic:({scale:e=1,backgroundColor:t="#ffffff",foregroundColor:n="#000000"})=>{const s=Ee("pattern",{id:"pattern-mosaic",width:20,height:20,patternUnits:"userSpaceOnUse",patternTransform:`scale(${e})`}),c=Ee("rect",{width:"100%",height:"100%",fill:t});s.appendChild(c);for(let l=0;l<4;l++)for(let u=0;u<4;u++)if((u+l)%2===0){const h=Ee("rect",{x:u*5,y:l*5,width:5,height:5,fill:n});s.appendChild(h)}return s},square:({scale:e=.3,backgroundColor:t,foregroundColor:n})=>{const r=Ee("pattern",{id:"pattern-square",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Ee("rect",{width:"100%",height:"100%",fill:t}),o=Ee("path",{d:"M0,0 L20,0 L20,20 L0,20 Z",fill:n});return r.appendChild(i),r.appendChild(o),r}},Symbol.toStringTag,{value:"Module"}));var gN=Object.defineProperty,Wa=Object.getOwnPropertySymbols,ob=Object.prototype.hasOwnProperty,ab=Object.prototype.propertyIsEnumerable,sb=(e,t,n)=>t in e?gN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Cu=(e,t)=>{for(var n in t||(t={}))ob.call(t,n)&&sb(e,n,t[n]);if(Wa)for(var n of Wa(t))ab.call(t,n)&&sb(e,n,t[n]);return e},mN=(e,t)=>{var n={};for(var r in e)ob.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Wa)for(var r of Wa(e))t.indexOf(r)<0&&ab.call(e,r)&&(n[r]=e[r]);return n};const Ou=new Map;function cb(e,t){Ou.has(e)&&console.warn(`Pattern ${e} will be overwritten`),Ou.set(e,t)}for(const[e,t]of Object.entries(pN))cb(e,t);function yN(e,t,n){const r=n.themeConfig.stylize;if(!r||r.type!=="pattern")return;const i=r,{pattern:o}=i,a=mN(i,["pattern"]),s=Ou.get(o);if(!s)return console.warn(`Pattern ${o} not found`);const{fill:c}=sn(e,["fill","stroke"]),l=c,u=Cu({backgroundColor:l&&be(l).setAlpha(.5).toRgbString(),foregroundColor:l},a),h=bN(Cu(Cu({},r),u));vN(t,h,s(u)),_r(c)&&(e.setAttribute("fill",`url(#${h})`),!e.getAttribute("stroke")&&c&&e.setAttribute("stroke",c))}function vN(e,t,n){const r=rs(e);n.setAttribute("id",t);const i=r.querySelector(`pattern#${t}`);i?i.replaceWith(n):r.appendChild(n)}function bN(e){const{pattern:t,foregroundColor:n="unset",backgroundColor:r="unset",scale:i="unset"}=e;return Ev(`pattern-${t}-${n}-${r}-${i}`)}function Su(e,t,n){if(e&&e.length){const[r,i]=t,o=Math.PI/180*n,a=Math.cos(o),s=Math.sin(o);for(const c of e){const[l,u]=c;c[0]=(l-r)*a-(u-i)*s+r,c[1]=(l-r)*s+(u-i)*a+i}}}function _N(e,t){return e[0]===t[0]&&e[1]===t[1]}function xN(e,t,n,r=1){const i=n,o=Math.max(t,.1),a=e[0]&&e[0][0]&&typeof e[0][0]=="number"?[e]:e,s=[0,0];if(i)for(const l of a)Su(l,s,i);const c=(function(l,u,h){const d=[];for(const b of l){const _=[...b];_N(_[0],_[_.length-1])||_.push([_[0][0],_[0][1]]),_.length>2&&d.push(_)}const f=[];u=Math.max(u,.1);const g=[];for(const b of d)for(let _=0;_<b.length-1;_++){const x=b[_],w=b[_+1];if(x[1]!==w[1]){const P=Math.min(x[1],w[1]);g.push({ymin:P,ymax:Math.max(x[1],w[1]),x:P===x[1]?x[0]:w[0],islope:(w[0]-x[0])/(w[1]-x[1])})}}if(g.sort(((b,_)=>b.ymin<_.ymin?-1:b.ymin>_.ymin?1:b.x<_.x?-1:b.x>_.x?1:b.ymax===_.ymax?0:(b.ymax-_.ymax)/Math.abs(b.ymax-_.ymax))),!g.length)return f;let y=[],m=g[0].ymin,v=0;for(;y.length||g.length;){if(g.length){let b=-1;for(let _=0;_<g.length&&!(g[_].ymin>m);_++)b=_;g.splice(0,b+1).forEach((_=>{y.push({s:m,edge:_})}))}if(y=y.filter((b=>!(b.edge.ymax<=m))),y.sort(((b,_)=>b.edge.x===_.edge.x?0:(b.edge.x-_.edge.x)/Math.abs(b.edge.x-_.edge.x))),(h!==1||v%u==0)&&y.length>1)for(let b=0;b<y.length;b+=2){const _=b+1;if(_>=y.length)break;const x=y[b].edge,w=y[_].edge;f.push([[Math.round(x.x),m],[Math.round(w.x),m]])}m+=h,y.forEach((b=>{b.edge.x=b.edge.x+h*b.edge.islope})),v++}return f})(a,o,r);if(i){for(const l of a)Su(l,s,-i);(function(l,u,h){const d=[];l.forEach((f=>d.push(...f))),Su(d,u,h)})(c,s,-i)}return c}function uo(e,t){var n;const r=t.hachureAngle+90;let i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let o=1;return t.roughness>=1&&(((n=t.randomizer)===null||n===void 0?void 0:n.next())||Math.random())>.7&&(o=i),xN(e,i,r,o||1)}let Mu=class{constructor(t){this.helper=t}fillPolygons(t,n){return this._fillPolygons(t,n)}_fillPolygons(t,n){const r=uo(t,n);return{type:"fillSketch",ops:this.renderLines(r,n)}}renderLines(t,n){const r=[];for(const i of t)r.push(...this.helper.doubleLineOps(i[0][0],i[0][1],i[1][0],i[1][1],n));return r}};function Ga(e){const t=e[0],n=e[1];return Math.sqrt(Math.pow(t[0]-n[0],2)+Math.pow(t[1]-n[1],2))}let wN=class extends Mu{fillPolygons(t,n){let r=n.hachureGap;r<0&&(r=4*n.strokeWidth),r=Math.max(r,.1);const i=uo(t,Object.assign({},n,{hachureGap:r})),o=Math.PI/180*n.hachureAngle,a=[],s=.5*r*Math.cos(o),c=.5*r*Math.sin(o);for(const[l,u]of i)Ga([l,u])&&a.push([[l[0]-s,l[1]+c],[...u]],[[l[0]+s,l[1]-c],[...u]]);return{type:"fillSketch",ops:this.renderLines(a,n)}}},PN=class extends Mu{fillPolygons(t,n){const r=this._fillPolygons(t,n),i=Object.assign({},n,{hachureAngle:n.hachureAngle+90}),o=this._fillPolygons(t,i);return r.ops=r.ops.concat(o.ops),r}},$N=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=uo(t,n=Object.assign({},n,{hachureAngle:0}));return this.dotsOnLines(r,n)}dotsOnLines(t,n){const r=[];let i=n.hachureGap;i<0&&(i=4*n.strokeWidth),i=Math.max(i,.1);let o=n.fillWeight;o<0&&(o=n.strokeWidth/2);const a=i/4;for(const s of t){const c=Ga(s),l=c/i,u=Math.ceil(l)-1,h=c-u*i,d=(s[0][0]+s[1][0])/2-i/4,f=Math.min(s[0][1],s[1][1]);for(let g=0;g<u;g++){const y=f+h+g*i,m=d-a+2*Math.random()*a,v=y-a+2*Math.random()*a,b=this.helper.ellipse(m,v,o,o,n);r.push(...b.ops)}}return{type:"fillSketch",ops:r}}},CN=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=uo(t,n);return{type:"fillSketch",ops:this.dashedLine(r,n)}}dashedLine(t,n){const r=n.dashOffset<0?n.hachureGap<0?4*n.strokeWidth:n.hachureGap:n.dashOffset,i=n.dashGap<0?n.hachureGap<0?4*n.strokeWidth:n.hachureGap:n.dashGap,o=[];return t.forEach((a=>{const s=Ga(a),c=Math.floor(s/(r+i)),l=(s+i-c*(r+i))/2;let u=a[0],h=a[1];u[0]>h[0]&&(u=a[1],h=a[0]);const d=Math.atan((h[1]-u[1])/(h[0]-u[0]));for(let f=0;f<c;f++){const g=f*(r+i),y=g+r,m=[u[0]+g*Math.cos(d)+l*Math.cos(d),u[1]+g*Math.sin(d)+l*Math.sin(d)],v=[u[0]+y*Math.cos(d)+l*Math.cos(d),u[1]+y*Math.sin(d)+l*Math.sin(d)];o.push(...this.helper.doubleLineOps(m[0],m[1],v[0],v[1],n))}})),o}},ON=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=n.hachureGap<0?4*n.strokeWidth:n.hachureGap,i=n.zigzagOffset<0?r:n.zigzagOffset,o=uo(t,n=Object.assign({},n,{hachureGap:r+i}));return{type:"fillSketch",ops:this.zigzagLines(o,i,n)}}zigzagLines(t,n,r){const i=[];return t.forEach((o=>{const a=Ga(o),s=Math.round(a/(2*n));let c=o[0],l=o[1];c[0]>l[0]&&(c=o[1],l=o[0]);const u=Math.atan((l[1]-c[1])/(l[0]-c[0]));for(let h=0;h<s;h++){const d=2*h*n,f=2*(h+1)*n,g=Math.sqrt(2*Math.pow(n,2)),y=[c[0]+d*Math.cos(u),c[1]+d*Math.sin(u)],m=[c[0]+f*Math.cos(u),c[1]+f*Math.sin(u)],v=[y[0]+g*Math.cos(u+Math.PI/4),y[1]+g*Math.sin(u+Math.PI/4)];i.push(...this.helper.doubleLineOps(y[0],y[1],v[0],v[1],r),...this.helper.doubleLineOps(v[0],v[1],m[0],m[1],r))}})),i}};const Qt={};let SN=class{constructor(t){this.seed=t}next(){return this.seed?(ia(2,31)-1&(this.seed=Math.imul(48271,this.seed)))/ia(2,31):Math.random()}};const MN=0,Eu=1,lb=2,Va={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Iu(e,t){return e.type===t}function Au(e){const t=[],n=(function(a){const s=new Array;for(;a!=="";)if(a.match(/^([ \t\r\n,]+)/))a=a.substr(RegExp.$1.length);else if(a.match(/^([aAcChHlLmMqQsStTvVzZ])/))s[s.length]={type:MN,text:RegExp.$1},a=a.substr(RegExp.$1.length);else{if(!a.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];s[s.length]={type:Eu,text:`${parseFloat(RegExp.$1)}`},a=a.substr(RegExp.$1.length)}return s[s.length]={type:lb,text:""},s})(e);let r="BOD",i=0,o=n[i];for(;!Iu(o,lb);){let a=0;const s=[];if(r==="BOD"){if(o.text!=="M"&&o.text!=="m")return Au("M0,0"+e);i++,a=Va[o.text],r=o.text}else Iu(o,Eu)?a=Va[r]:(i++,a=Va[o.text],r=o.text);if(!(i+a<n.length))throw new Error("Path data ended short");for(let c=i;c<i+a;c++){const l=n[c];if(!Iu(l,Eu))throw new Error("Param not a number: "+r+","+l.text);s[s.length]=+l.text}if(typeof Va[r]!="number")throw new Error("Bad segment: "+r);{const c={key:r,data:s};t.push(c),i+=a,o=n[i],r==="M"&&(r="L"),r==="m"&&(r="l")}}return t}function ub(e){let t=0,n=0,r=0,i=0;const o=[];for(const{key:a,data:s}of e)switch(a){case"M":o.push({key:"M",data:[...s]}),[t,n]=s,[r,i]=s;break;case"m":t+=s[0],n+=s[1],o.push({key:"M",data:[t,n]}),r=t,i=n;break;case"L":o.push({key:"L",data:[...s]}),[t,n]=s;break;case"l":t+=s[0],n+=s[1],o.push({key:"L",data:[t,n]});break;case"C":o.push({key:"C",data:[...s]}),t=s[4],n=s[5];break;case"c":{const c=s.map(((l,u)=>u%2?l+n:l+t));o.push({key:"C",data:c}),t=c[4],n=c[5];break}case"Q":o.push({key:"Q",data:[...s]}),t=s[2],n=s[3];break;case"q":{const c=s.map(((l,u)=>u%2?l+n:l+t));o.push({key:"Q",data:c}),t=c[2],n=c[3];break}case"A":o.push({key:"A",data:[...s]}),t=s[5],n=s[6];break;case"a":t+=s[5],n+=s[6],o.push({key:"A",data:[s[0],s[1],s[2],s[3],s[4],t,n]});break;case"H":o.push({key:"H",data:[...s]}),t=s[0];break;case"h":t+=s[0],o.push({key:"H",data:[t]});break;case"V":o.push({key:"V",data:[...s]}),n=s[0];break;case"v":n+=s[0],o.push({key:"V",data:[n]});break;case"S":o.push({key:"S",data:[...s]}),t=s[2],n=s[3];break;case"s":{const c=s.map(((l,u)=>u%2?l+n:l+t));o.push({key:"S",data:c}),t=c[2],n=c[3];break}case"T":o.push({key:"T",data:[...s]}),t=s[0],n=s[1];break;case"t":t+=s[0],n+=s[1],o.push({key:"T",data:[t,n]});break;case"Z":case"z":o.push({key:"Z",data:[]}),t=r,n=i}return o}function hb(e){const t=[];let n="",r=0,i=0,o=0,a=0,s=0,c=0;for(const{key:l,data:u}of e){switch(l){case"M":t.push({key:"M",data:[...u]}),[r,i]=u,[o,a]=u;break;case"C":t.push({key:"C",data:[...u]}),r=u[4],i=u[5],s=u[2],c=u[3];break;case"L":t.push({key:"L",data:[...u]}),[r,i]=u;break;case"H":r=u[0],t.push({key:"L",data:[r,i]});break;case"V":i=u[0],t.push({key:"L",data:[r,i]});break;case"S":{let h=0,d=0;n==="C"||n==="S"?(h=r+(r-s),d=i+(i-c)):(h=r,d=i),t.push({key:"C",data:[h,d,...u]}),s=u[0],c=u[1],r=u[2],i=u[3];break}case"T":{const[h,d]=u;let f=0,g=0;n==="Q"||n==="T"?(f=r+(r-s),g=i+(i-c)):(f=r,g=i);const y=r+2*(f-r)/3,m=i+2*(g-i)/3,v=h+2*(f-h)/3,b=d+2*(g-d)/3;t.push({key:"C",data:[y,m,v,b,h,d]}),s=f,c=g,r=h,i=d;break}case"Q":{const[h,d,f,g]=u,y=r+2*(h-r)/3,m=i+2*(d-i)/3,v=f+2*(h-f)/3,b=g+2*(d-g)/3;t.push({key:"C",data:[y,m,v,b,f,g]}),s=h,c=d,r=f,i=g;break}case"A":{const h=Math.abs(u[0]),d=Math.abs(u[1]),f=u[2],g=u[3],y=u[4],m=u[5],v=u[6];h===0||d===0?(t.push({key:"C",data:[r,i,m,v,m,v]}),r=m,i=v):(r!==m||i!==v)&&(db(r,i,m,v,h,d,f,g,y).forEach((function(b){t.push({key:"C",data:b})})),r=m,i=v);break}case"Z":t.push({key:"Z",data:[]}),r=o,i=a}n=l}return t}function ho(e,t,n){return[e*Math.cos(n)-t*Math.sin(n),e*Math.sin(n)+t*Math.cos(n)]}function db(e,t,n,r,i,o,a,s,c,l){const u=(h=a,Math.PI*h/180);var h;let d=[],f=0,g=0,y=0,m=0;if(l)[f,g,y,m]=l;else{[e,t]=ho(e,t,-u),[n,r]=ho(n,r,-u);const O=(e-n)/2,T=(t-r)/2;let F=O*O/(i*i)+T*T/(o*o);F>1&&(F=Math.sqrt(F),i*=F,o*=F);const z=i*i,j=o*o,D=z*j-z*T*T-j*O*O,W=z*T*T+j*O*O,B=(s===c?-1:1)*Math.sqrt(Math.abs(D/W));y=B*i*T/o+(e+n)/2,m=B*-o*O/i+(t+r)/2,f=Math.asin(parseFloat(((t-m)/o).toFixed(9))),g=Math.asin(parseFloat(((r-m)/o).toFixed(9))),e<y&&(f=Math.PI-f),n<y&&(g=Math.PI-g),f<0&&(f=2*Math.PI+f),g<0&&(g=2*Math.PI+g),c&&f>g&&(f-=2*Math.PI),!c&&g>f&&(g-=2*Math.PI)}let v=g-f;if(Math.abs(v)>120*Math.PI/180){const O=g,T=n,F=r;g=c&&g>f?f+120*Math.PI/180*1:f+120*Math.PI/180*-1,d=db(n=y+i*Math.cos(g),r=m+o*Math.sin(g),T,F,i,o,a,0,c,[g,O,y,m])}v=g-f;const b=Math.cos(f),_=Math.sin(f),x=Math.cos(g),w=Math.sin(g),P=Math.tan(v/4),$=4/3*i*P,C=4/3*o*P,M=[e,t],S=[e+$*_,t-C*b],E=[n+$*w,r-C*x],A=[n,r];if(S[0]=2*M[0]-S[0],S[1]=2*M[1]-S[1],l)return[S,E,A].concat(d);{d=[S,E,A].concat(d);const O=[];for(let T=0;T<d.length;T+=3){const F=ho(d[T][0],d[T][1],u),z=ho(d[T+1][0],d[T+1][1],u),j=ho(d[T+2][0],d[T+2][1],u);O.push([F[0],F[1],z[0],z[1],j[0],j[1]])}return O}}const EN={randOffset:function(e,t){return ke(e,t)},randOffsetWithRange:function(e,t,n){return Xa(e,t,n)},ellipse:function(e,t,n,r,i){const o=gb(n,r,i);return Tu(e,t,i,o).opset},doubleLineOps:function(e,t,n,r,i){return sr(e,t,n,r,i,!0)}};function fb(e,t,n,r,i){return{type:"path",ops:sr(e,t,n,r,i)}}function Ya(e,t,n){const r=(e||[]).length;if(r>2){const i=[];for(let o=0;o<r-1;o++)i.push(...sr(e[o][0],e[o][1],e[o+1][0],e[o+1][1],n));return t&&i.push(...sr(e[r-1][0],e[r-1][1],e[0][0],e[0][1],n)),{type:"path",ops:i}}return r===2?fb(e[0][0],e[0][1],e[1][0],e[1][1],n):{type:"path",ops:[]}}function IN(e,t,n,r,i){return(function(o,a){return Ya(o,!0,a)})([[e,t],[e+n,t],[e+n,t+r],[e,t+r]],i)}function pb(e,t){if(e.length){const n=typeof e[0][0]=="number"?[e]:e,r=Ua(n[0],1*(1+.2*t.roughness),t),i=t.disableMultiStroke?[]:Ua(n[0],1.5*(1+.22*t.roughness),vb(t));for(let o=1;o<n.length;o++){const a=n[o];if(a.length){const s=Ua(a,1*(1+.2*t.roughness),t),c=t.disableMultiStroke?[]:Ua(a,1.5*(1+.22*t.roughness),vb(t));for(const l of s)l.op!=="move"&&r.push(l);for(const l of c)l.op!=="move"&&i.push(l)}}return{type:"path",ops:r.concat(i)}}return{type:"path",ops:[]}}function gb(e,t,n){const r=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),i=Math.ceil(Math.max(n.curveStepCount,n.curveStepCount/Math.sqrt(200)*r)),o=2*Math.PI/i;let a=Math.abs(e/2),s=Math.abs(t/2);const c=1-n.curveFitting;return a+=ke(a*c,n),s+=ke(s*c,n),{increment:o,rx:a,ry:s}}function Tu(e,t,n,r){const[i,o]=_b(r.increment,e,t,r.rx,r.ry,1,r.increment*Xa(.1,Xa(.4,1,n),n),n);let a=Ka(i,null,n);if(!n.disableMultiStroke&&n.roughness!==0){const[s]=_b(r.increment,e,t,r.rx,r.ry,1.5,0,n),c=Ka(s,null,n);a=a.concat(c)}return{estimatedPoints:o,opset:{type:"path",ops:a}}}function mb(e,t,n,r,i,o,a,s,c){const l=e,u=t;let h=Math.abs(n/2),d=Math.abs(r/2);h+=ke(.01*h,c),d+=ke(.01*d,c);let f=i,g=o;for(;f<0;)f+=2*Math.PI,g+=2*Math.PI;g-f>2*Math.PI&&(f=0,g=2*Math.PI);const y=2*Math.PI/c.curveStepCount,m=Math.min(y/2,(g-f)/2),v=xb(m,l,u,h,d,f,g,1,c);if(!c.disableMultiStroke){const b=xb(m,l,u,h,d,f,g,1.5,c);v.push(...b)}return a&&(s?v.push(...sr(l,u,l+h*Math.cos(f),u+d*Math.sin(f),c),...sr(l,u,l+h*Math.cos(g),u+d*Math.sin(g),c)):v.push({op:"lineTo",data:[l,u]},{op:"lineTo",data:[l+h*Math.cos(f),u+d*Math.sin(f)]})),{type:"path",ops:v}}function yb(e,t){const n=hb(ub(Au(e))),r=[];let i=[0,0],o=[0,0];for(const{key:a,data:s}of n)switch(a){case"M":o=[s[0],s[1]],i=[s[0],s[1]];break;case"L":r.push(...sr(o[0],o[1],s[0],s[1],t)),o=[s[0],s[1]];break;case"C":{const[c,l,u,h,d,f]=s;r.push(...AN(c,l,u,h,d,f,o,t)),o=[d,f];break}case"Z":r.push(...sr(o[0],o[1],i[0],i[1],t)),o=[i[0],i[1]]}return{type:"path",ops:r}}function ku(e,t){const n=[];for(const r of e)if(r.length){const i=t.maxRandomnessOffset||0,o=r.length;if(o>2){n.push({op:"move",data:[r[0][0]+ke(i,t),r[0][1]+ke(i,t)]});for(let a=1;a<o;a++)n.push({op:"lineTo",data:[r[a][0]+ke(i,t),r[a][1]+ke(i,t)]})}}return{type:"fillPath",ops:n}}function fi(e,t){return(function(n,r){let i=n.fillStyle||"hachure";if(!Qt[i])switch(i){case"zigzag":Qt[i]||(Qt[i]=new wN(r));break;case"cross-hatch":Qt[i]||(Qt[i]=new PN(r));break;case"dots":Qt[i]||(Qt[i]=new $N(r));break;case"dashed":Qt[i]||(Qt[i]=new CN(r));break;case"zigzag-line":Qt[i]||(Qt[i]=new ON(r));break;default:i="hachure",Qt[i]||(Qt[i]=new Mu(r))}return Qt[i]})(t,EN).fillPolygons(e,t)}function vb(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function bb(e){return e.randomizer||(e.randomizer=new SN(e.seed||0)),e.randomizer.next()}function Xa(e,t,n,r=1){return n.roughness*r*(bb(n)*(t-e)+e)}function ke(e,t,n=1){return Xa(-e,e,t,n)}function sr(e,t,n,r,i,o=!1){const a=o?i.disableMultiStrokeFill:i.disableMultiStroke,s=Ru(e,t,n,r,i,!0,!1);if(a)return s;const c=Ru(e,t,n,r,i,!0,!0);return s.concat(c)}function Ru(e,t,n,r,i,o,a){const s=Math.pow(e-n,2)+Math.pow(t-r,2),c=Math.sqrt(s);let l=1;l=c<200?1:c>500?.4:-.0016668*c+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>s&&(u=c/10);const h=u/2,d=.2+.2*bb(i);let f=i.bowing*i.maxRandomnessOffset*(r-t)/200,g=i.bowing*i.maxRandomnessOffset*(e-n)/200;f=ke(f,i,l),g=ke(g,i,l);const y=[],m=()=>ke(h,i,l),v=()=>ke(u,i,l),b=i.preserveVertices;return a?y.push({op:"move",data:[e+(b?0:m()),t+(b?0:m())]}):y.push({op:"move",data:[e+(b?0:ke(u,i,l)),t+(b?0:ke(u,i,l))]}),a?y.push({op:"bcurveTo",data:[f+e+(n-e)*d+m(),g+t+(r-t)*d+m(),f+e+2*(n-e)*d+m(),g+t+2*(r-t)*d+m(),n+(b?0:m()),r+(b?0:m())]}):y.push({op:"bcurveTo",data:[f+e+(n-e)*d+v(),g+t+(r-t)*d+v(),f+e+2*(n-e)*d+v(),g+t+2*(r-t)*d+v(),n+(b?0:v()),r+(b?0:v())]}),y}function Ua(e,t,n){if(!e.length)return[];const r=[];r.push([e[0][0]+ke(t,n),e[0][1]+ke(t,n)]),r.push([e[0][0]+ke(t,n),e[0][1]+ke(t,n)]);for(let i=1;i<e.length;i++)r.push([e[i][0]+ke(t,n),e[i][1]+ke(t,n)]),i===e.length-1&&r.push([e[i][0]+ke(t,n),e[i][1]+ke(t,n)]);return Ka(r,null,n)}function Ka(e,t,n){const r=e.length,i=[];if(r>3){const o=[],a=1-n.curveTightness;i.push({op:"move",data:[e[1][0],e[1][1]]});for(let s=1;s+2<r;s++){const c=e[s];o[0]=[c[0],c[1]],o[1]=[c[0]+(a*e[s+1][0]-a*e[s-1][0])/6,c[1]+(a*e[s+1][1]-a*e[s-1][1])/6],o[2]=[e[s+1][0]+(a*e[s][0]-a*e[s+2][0])/6,e[s+1][1]+(a*e[s][1]-a*e[s+2][1])/6],o[3]=[e[s+1][0],e[s+1][1]],i.push({op:"bcurveTo",data:[o[1][0],o[1][1],o[2][0],o[2][1],o[3][0],o[3][1]]})}}else r===3?(i.push({op:"move",data:[e[1][0],e[1][1]]}),i.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):r===2&&i.push(...Ru(e[0][0],e[0][1],e[1][0],e[1][1],n,!0,!0));return i}function _b(e,t,n,r,i,o,a,s){const c=[],l=[];if(s.roughness===0){e/=4,l.push([t+r*Math.cos(-e),n+i*Math.sin(-e)]);for(let u=0;u<=2*Math.PI;u+=e){const h=[t+r*Math.cos(u),n+i*Math.sin(u)];c.push(h),l.push(h)}l.push([t+r*Math.cos(0),n+i*Math.sin(0)]),l.push([t+r*Math.cos(e),n+i*Math.sin(e)])}else{const u=ke(.5,s)-Math.PI/2;l.push([ke(o,s)+t+.9*r*Math.cos(u-e),ke(o,s)+n+.9*i*Math.sin(u-e)]);const h=2*Math.PI+u-.01;for(let d=u;d<h;d+=e){const f=[ke(o,s)+t+r*Math.cos(d),ke(o,s)+n+i*Math.sin(d)];c.push(f),l.push(f)}l.push([ke(o,s)+t+r*Math.cos(u+2*Math.PI+.5*a),ke(o,s)+n+i*Math.sin(u+2*Math.PI+.5*a)]),l.push([ke(o,s)+t+.98*r*Math.cos(u+a),ke(o,s)+n+.98*i*Math.sin(u+a)]),l.push([ke(o,s)+t+.9*r*Math.cos(u+.5*a),ke(o,s)+n+.9*i*Math.sin(u+.5*a)])}return[l,c]}function xb(e,t,n,r,i,o,a,s,c){const l=o+ke(.1,c),u=[];u.push([ke(s,c)+t+.9*r*Math.cos(l-e),ke(s,c)+n+.9*i*Math.sin(l-e)]);for(let h=l;h<=a;h+=e)u.push([ke(s,c)+t+r*Math.cos(h),ke(s,c)+n+i*Math.sin(h)]);return u.push([t+r*Math.cos(a),n+i*Math.sin(a)]),u.push([t+r*Math.cos(a),n+i*Math.sin(a)]),Ka(u,null,c)}function AN(e,t,n,r,i,o,a,s){const c=[],l=[s.maxRandomnessOffset||1,(s.maxRandomnessOffset||1)+.3];let u=[0,0];const h=s.disableMultiStroke?1:2,d=s.preserveVertices;for(let f=0;f<h;f++)f===0?c.push({op:"move",data:[a[0],a[1]]}):c.push({op:"move",data:[a[0]+(d?0:ke(l[0],s)),a[1]+(d?0:ke(l[0],s))]}),u=d?[i,o]:[i+ke(l[f],s),o+ke(l[f],s)],c.push({op:"bcurveTo",data:[e+ke(l[f],s),t+ke(l[f],s),n+ke(l[f],s),r+ke(l[f],s),u[0],u[1]]});return c}function fo(e){return[...e]}function wb(e,t=0){const n=e.length;if(n<3)throw new Error("A curve must have at least three points.");const r=[];if(n===3)r.push(fo(e[0]),fo(e[1]),fo(e[2]),fo(e[2]));else{const i=[];i.push(e[0],e[0]);for(let s=1;s<e.length;s++)i.push(e[s]),s===e.length-1&&i.push(e[s]);const o=[],a=1-t;r.push(fo(i[0]));for(let s=1;s+2<i.length;s++){const c=i[s];o[0]=[c[0],c[1]],o[1]=[c[0]+(a*i[s+1][0]-a*i[s-1][0])/6,c[1]+(a*i[s+1][1]-a*i[s-1][1])/6],o[2]=[i[s+1][0]+(a*i[s][0]-a*i[s+2][0])/6,i[s+1][1]+(a*i[s][1]-a*i[s+2][1])/6],o[3]=[i[s+1][0],i[s+1][1]],r.push(o[1],o[2],o[3])}}return r}function Za(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function TN(e,t,n){const r=Za(t,n);if(r===0)return Za(e,t);let i=((e[0]-t[0])*(n[0]-t[0])+(e[1]-t[1])*(n[1]-t[1]))/r;return i=Math.max(0,Math.min(1,i)),Za(e,Mr(t,n,i))}function Mr(e,t,n){return[e[0]+(t[0]-e[0])*n,e[1]+(t[1]-e[1])*n]}function Lu(e,t,n,r){const i=r||[];if((function(s,c){const l=s[c+0],u=s[c+1],h=s[c+2],d=s[c+3];let f=3*u[0]-2*l[0]-d[0];f*=f;let g=3*u[1]-2*l[1]-d[1];g*=g;let y=3*h[0]-2*d[0]-l[0];y*=y;let m=3*h[1]-2*d[1]-l[1];return m*=m,f<y&&(f=y),g<m&&(g=m),f+g})(e,t)<n){const s=e[t+0];i.length?(o=i[i.length-1],a=s,Math.sqrt(Za(o,a))>1&&i.push(s)):i.push(s),i.push(e[t+3])}else{const c=e[t+0],l=e[t+1],u=e[t+2],h=e[t+3],d=Mr(c,l,.5),f=Mr(l,u,.5),g=Mr(u,h,.5),y=Mr(d,f,.5),m=Mr(f,g,.5),v=Mr(y,m,.5);Lu([c,d,y,v],0,n,i),Lu([v,m,g,h],0,n,i)}var o,a;return i}function kN(e,t){return Qa(e,0,e.length,t)}function Qa(e,t,n,r,i){const o=i||[],a=e[t],s=e[n-1];let c=0,l=1;for(let u=t+1;u<n-1;++u){const h=TN(e[u],a,s);h>c&&(c=h,l=u)}return Math.sqrt(c)>r?(Qa(e,t,l+1,r,o),Qa(e,l,n,r,o)):(o.length||o.push(a),o.push(s)),o}function zu(e,t=.15,n){const r=[],i=(e.length-1)/3;for(let o=0;o<i;o++)Lu(e,3*o,t,r);return n&&n>0?Qa(r,0,r.length,n):r}const an="none";class Ja{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*ia(2,31))}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,n,r){return{shape:t,sets:n||[],options:r||this.defaultOptions}}line(t,n,r,i,o){const a=this._o(o);return this._d("line",[fb(t,n,r,i,a)],a)}rectangle(t,n,r,i,o){const a=this._o(o),s=[],c=IN(t,n,r,i,a);if(a.fill){const l=[[t,n],[t+r,n],[t+r,n+i],[t,n+i]];a.fillStyle==="solid"?s.push(ku([l],a)):s.push(fi([l],a))}return a.stroke!==an&&s.push(c),this._d("rectangle",s,a)}ellipse(t,n,r,i,o){const a=this._o(o),s=[],c=gb(r,i,a),l=Tu(t,n,a,c);if(a.fill)if(a.fillStyle==="solid"){const u=Tu(t,n,a,c).opset;u.type="fillPath",s.push(u)}else s.push(fi([l.estimatedPoints],a));return a.stroke!==an&&s.push(l.opset),this._d("ellipse",s,a)}circle(t,n,r,i){const o=this.ellipse(t,n,r,r,i);return o.shape="circle",o}linearPath(t,n){const r=this._o(n);return this._d("linearPath",[Ya(t,!1,r)],r)}arc(t,n,r,i,o,a,s=!1,c){const l=this._o(c),u=[],h=mb(t,n,r,i,o,a,s,!0,l);if(s&&l.fill)if(l.fillStyle==="solid"){const d=Object.assign({},l);d.disableMultiStroke=!0;const f=mb(t,n,r,i,o,a,!0,!1,d);f.type="fillPath",u.push(f)}else u.push((function(d,f,g,y,m,v,b){const _=d,x=f;let w=Math.abs(g/2),P=Math.abs(y/2);w+=ke(.01*w,b),P+=ke(.01*P,b);let $=m,C=v;for(;$<0;)$+=2*Math.PI,C+=2*Math.PI;C-$>2*Math.PI&&($=0,C=2*Math.PI);const M=(C-$)/b.curveStepCount,S=[];for(let E=$;E<=C;E+=M)S.push([_+w*Math.cos(E),x+P*Math.sin(E)]);return S.push([_+w*Math.cos(C),x+P*Math.sin(C)]),S.push([_,x]),fi([S],b)})(t,n,r,i,o,a,l));return l.stroke!==an&&u.push(h),this._d("arc",u,l)}curve(t,n){const r=this._o(n),i=[],o=pb(t,r);if(r.fill&&r.fill!==an)if(r.fillStyle==="solid"){const a=pb(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(a.ops)})}else{const a=[],s=t;if(s.length){const c=typeof s[0][0]=="number"?[s]:s;for(const l of c)l.length<3?a.push(...l):l.length===3?a.push(...zu(wb([l[0],l[0],l[1],l[2]]),10,(1+r.roughness)/2)):a.push(...zu(wb(l),10,(1+r.roughness)/2))}a.length&&i.push(fi([a],r))}return r.stroke!==an&&i.push(o),this._d("curve",i,r)}polygon(t,n){const r=this._o(n),i=[],o=Ya(t,!0,r);return r.fill&&(r.fillStyle==="solid"?i.push(ku([t],r)):i.push(fi([t],r))),r.stroke!==an&&i.push(o),this._d("polygon",i,r)}path(t,n){const r=this._o(n),i=[];if(!t)return this._d("path",i,r);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const o=r.fill&&r.fill!=="transparent"&&r.fill!==an,a=r.stroke!==an,s=!!(r.simplification&&r.simplification<1),c=(function(u,h,d){const f=hb(ub(Au(u))),g=[];let y=[],m=[0,0],v=[];const b=()=>{v.length>=4&&y.push(...zu(v,h)),v=[]},_=()=>{b(),y.length&&(g.push(y),y=[])};for(const{key:w,data:P}of f)switch(w){case"M":_(),m=[P[0],P[1]],y.push(m);break;case"L":b(),y.push([P[0],P[1]]);break;case"C":if(!v.length){const $=y.length?y[y.length-1]:m;v.push([$[0],$[1]])}v.push([P[0],P[1]]),v.push([P[2],P[3]]),v.push([P[4],P[5]]);break;case"Z":b(),y.push([m[0],m[1]])}if(_(),!d)return g;const x=[];for(const w of g){const P=kN(w,d);P.length&&x.push(P)}return x})(t,1,s?4-4*(r.simplification||1):(1+r.roughness)/2),l=yb(t,r);if(o)if(r.fillStyle==="solid")if(c.length===1){const u=yb(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(u.ops)})}else i.push(ku(c,r));else i.push(fi(c,r));return a&&(s?c.forEach((u=>{i.push(Ya(u,!1,r))})):i.push(l)),this._d("path",i,r)}opsToPath(t,n){let r="";for(const i of t.ops){const o=typeof n=="number"&&n>=0?i.data.map((a=>+a.toFixed(n))):i.data;switch(i.op){case"move":r+=`M${o[0]} ${o[1]} `;break;case"bcurveTo":r+=`C${o[0]} ${o[1]}, ${o[2]} ${o[3]}, ${o[4]} ${o[5]} `;break;case"lineTo":r+=`L${o[0]} ${o[1]} `}}return r.trim()}toPaths(t){const n=t.sets||[],r=t.options||this.defaultOptions,i=[];for(const o of n){let a=null;switch(o.type){case"path":a={d:this.opsToPath(o),stroke:r.stroke,strokeWidth:r.strokeWidth,fill:an};break;case"fillPath":a={d:this.opsToPath(o),stroke:an,strokeWidth:0,fill:r.fill||an};break;case"fillSketch":a=this.fillSketch(o,r)}a&&i.push(a)}return i}fillSketch(t,n){let r=n.fillWeight;return r<0&&(r=n.strokeWidth/2),{d:this.opsToPath(t),stroke:n.fill||an,strokeWidth:r,fill:an}}_mergedShape(t){return t.filter(((n,r)=>r===0||n.op!=="move"))}}class RN{constructor(t,n){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new Ja(n)}draw(t){const n=t.sets||[],r=t.options||this.getDefaultOptions(),i=this.ctx,o=t.options.fixedDecimalPlaceDigits;for(const a of n)switch(a.type){case"path":i.save(),i.strokeStyle=r.stroke==="none"?"transparent":r.stroke,i.lineWidth=r.strokeWidth,r.strokeLineDash&&i.setLineDash(r.strokeLineDash),r.strokeLineDashOffset&&(i.lineDashOffset=r.strokeLineDashOffset),this._drawToContext(i,a,o),i.restore();break;case"fillPath":{i.save(),i.fillStyle=r.fill||"";const s=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(i,a,o,s),i.restore();break}case"fillSketch":this.fillSketch(i,a,r)}}fillSketch(t,n,r){let i=r.fillWeight;i<0&&(i=r.strokeWidth/2),t.save(),r.fillLineDash&&t.setLineDash(r.fillLineDash),r.fillLineDashOffset&&(t.lineDashOffset=r.fillLineDashOffset),t.strokeStyle=r.fill||"",t.lineWidth=i,this._drawToContext(t,n,r.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,n,r,i="nonzero"){t.beginPath();for(const o of n.ops){const a=typeof r=="number"&&r>=0?o.data.map((s=>+s.toFixed(r))):o.data;switch(o.op){case"move":t.moveTo(a[0],a[1]);break;case"bcurveTo":t.bezierCurveTo(a[0],a[1],a[2],a[3],a[4],a[5]);break;case"lineTo":t.lineTo(a[0],a[1])}}n.type==="fillPath"?t.fill(i):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,n,r,i,o){const a=this.gen.line(t,n,r,i,o);return this.draw(a),a}rectangle(t,n,r,i,o){const a=this.gen.rectangle(t,n,r,i,o);return this.draw(a),a}ellipse(t,n,r,i,o){const a=this.gen.ellipse(t,n,r,i,o);return this.draw(a),a}circle(t,n,r,i){const o=this.gen.circle(t,n,r,i);return this.draw(o),o}linearPath(t,n){const r=this.gen.linearPath(t,n);return this.draw(r),r}polygon(t,n){const r=this.gen.polygon(t,n);return this.draw(r),r}arc(t,n,r,i,o,a,s=!1,c){const l=this.gen.arc(t,n,r,i,o,a,s,c);return this.draw(l),l}curve(t,n){const r=this.gen.curve(t,n);return this.draw(r),r}path(t,n){const r=this.gen.path(t,n);return this.draw(r),r}}const es="http://www.w3.org/2000/svg";class LN{constructor(t,n){this.svg=t,this.gen=new Ja(n)}draw(t){const n=t.sets||[],r=t.options||this.getDefaultOptions(),i=this.svg.ownerDocument||window.document,o=i.createElementNS(es,"g"),a=t.options.fixedDecimalPlaceDigits;for(const s of n){let c=null;switch(s.type){case"path":c=i.createElementNS(es,"path"),c.setAttribute("d",this.opsToPath(s,a)),c.setAttribute("stroke",r.stroke),c.setAttribute("stroke-width",r.strokeWidth+""),c.setAttribute("fill","none"),r.strokeLineDash&&c.setAttribute("stroke-dasharray",r.strokeLineDash.join(" ").trim()),r.strokeLineDashOffset&&c.setAttribute("stroke-dashoffset",`${r.strokeLineDashOffset}`);break;case"fillPath":c=i.createElementNS(es,"path"),c.setAttribute("d",this.opsToPath(s,a)),c.setAttribute("stroke","none"),c.setAttribute("stroke-width","0"),c.setAttribute("fill",r.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||c.setAttribute("fill-rule","evenodd");break;case"fillSketch":c=this.fillSketch(i,s,r)}c&&o.appendChild(c)}return o}fillSketch(t,n,r){let i=r.fillWeight;i<0&&(i=r.strokeWidth/2);const o=t.createElementNS(es,"path");return o.setAttribute("d",this.opsToPath(n,r.fixedDecimalPlaceDigits)),o.setAttribute("stroke",r.fill||""),o.setAttribute("stroke-width",i+""),o.setAttribute("fill","none"),r.fillLineDash&&o.setAttribute("stroke-dasharray",r.fillLineDash.join(" ").trim()),r.fillLineDashOffset&&o.setAttribute("stroke-dashoffset",`${r.fillLineDashOffset}`),o}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,n){return this.gen.opsToPath(t,n)}line(t,n,r,i,o){const a=this.gen.line(t,n,r,i,o);return this.draw(a)}rectangle(t,n,r,i,o){const a=this.gen.rectangle(t,n,r,i,o);return this.draw(a)}ellipse(t,n,r,i,o){const a=this.gen.ellipse(t,n,r,i,o);return this.draw(a)}circle(t,n,r,i){const o=this.gen.circle(t,n,r,i);return this.draw(o)}linearPath(t,n){const r=this.gen.linearPath(t,n);return this.draw(r)}polygon(t,n){const r=this.gen.polygon(t,n);return this.draw(r)}arc(t,n,r,i,o,a,s=!1,c){const l=this.gen.arc(t,n,r,i,o,a,s,c);return this.draw(l)}curve(t,n){const r=this.gen.curve(t,n);return this.draw(r)}path(t,n){const r=this.gen.path(t,n);return this.draw(r)}}var zN={canvas:(e,t)=>new RN(e,t),svg:(e,t)=>new LN(e,t),generator:e=>new Ja(e),newSeed:()=>Ja.newSeed()},NN=Object.defineProperty,Pb=Object.getOwnPropertySymbols,DN=Object.prototype.hasOwnProperty,HN=Object.prototype.propertyIsEnumerable,$b=(e,t,n)=>t in e?NN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qN=(e,t)=>{for(var n in t||(t={}))DN.call(t,n)&&$b(e,n,t[n]);if(Pb)for(var n of Pb(t))HN.call(t,n)&&$b(e,n,t[n]);return e};function jN(e,t,n){if(!e||!t){console.warn("Invalid node or svg element");return}const r=zN.svg(t,{options:{seed:1e3}}),i=Ee("g");e.hasAttribute("transform")&&i.setAttribute("transform",e.getAttribute("transform")||"");const o=e.cloneNode();lt(o,{opacity:.5}),o.hasAttribute("transform")&&o.removeAttribute("transform"),o.dataset.elementType="rough-volume",i.appendChild(o);const a=BN(r,e,n);if(a){const{element:c,svgAttributes:l}=a;c.dataset.elementType="rough-element",c.style.pointerEvents="none",FN(c,l),i.appendChild(c)}e.id&&(i.id=e.id),Array.from(e.classList).forEach(c=>{i.classList.contains(c)||i.classList.add(c)}),Array.from(e.attributes).forEach(c=>{c.name.startsWith("data-")&&i.setAttribute(c.name,c.value)}),i.childElementCount>0?e.replaceWith(i):e.remove()}function FN(e,t){t.opacity!==void 0&&e.setAttribute("opacity",String(t.opacity)),t.fillOpacity!==void 0&&e.setAttribute("fill-opacity",String(t.fillOpacity)),t.strokeOpacity!==void 0&&e.setAttribute("stroke-opacity",String(t.strokeOpacity)),t.strokeLinecap&&e.setAttribute("stroke-linecap",t.strokeLinecap),t.strokeLinejoin&&e.setAttribute("stroke-linejoin",t.strokeLinejoin),t.strokeDasharray&&e.setAttribute("stroke-dasharray",t.strokeDasharray),t.filter&&e.setAttribute("filter",t.filter),t.clipPath&&e.setAttribute("clip-path",t.clipPath),t.mask&&e.setAttribute("mask",t.mask)}function BN(e,t,n){const r=t.nodeName.toLowerCase(),i=(o,a)=>{const s=sn(o,[...a,"fill","fill-opacity","stroke","stroke-opacity","stroke-width","stroke-dasharray","stroke-linecap","stroke-linejoin","opacity","filter","clip-path","mask"],!0),c={},l=qN({},n),u={};a.forEach($=>{s[$]!==void 0&&(c[$]=s[$])});const{fill:h,"fill-opacity":d,stroke:f,"stroke-opacity":g,"stroke-width":y,"stroke-dasharray":m,"stroke-linecap":v,"stroke-linejoin":b,opacity:_,filter:x,"clip-path":w,mask:P}=s;if(l.fill=h||"none",l.stroke=f||(h&&h!=="none"?h:"currentColor"),y&&(l.strokeWidth=parseFloat(y)),m&&m!=="none"){const $=m.split(/[\s,]+/).map(C=>parseFloat(C)).filter(C=>!isNaN(C));$.length>0&&(l.strokeLineDash=$)}return d&&(u.fillOpacity=parseFloat(d)),g&&(u.strokeOpacity=parseFloat(g)),_&&(u.opacity=parseFloat(_)),v&&(u.strokeLinecap=v),b&&(u.strokeLinejoin=b),m&&m!=="none"&&(u.strokeDasharray=m),x&&(u.filter=x),w&&(u.clipPath=w),P&&(u.mask=P),[c,l,u]};try{let o=null,a={};switch(r){case"circle":{const[s,c,l]=i(t,["cx","cy","r"]),u=parseFloat(s.cx)||0,h=parseFloat(s.cy)||0,d=parseFloat(s.r)||0;o=e.circle(u,h,d*2,c),a=l;break}case"ellipse":{const[s,c,l]=i(t,["cx","cy","rx","ry"]),u=parseFloat(s.cx)||0,h=parseFloat(s.cy)||0,d=parseFloat(s.rx)||0,f=parseFloat(s.ry)||0;o=e.ellipse(u,h,d*2,f*2,c),a=l;break}case"line":{const[s,c,l]=i(t,["x1","y1","x2","y2"]),u=parseFloat(s.x1)||0,h=parseFloat(s.y1)||0,d=parseFloat(s.x2)||0,f=parseFloat(s.y2)||0;o=e.line(u,h,d,f,c),a=l;break}case"rect":{const[s,c,l]=i(t,["x","y","width","height","rx","ry"]),u=parseFloat(s.x)||0,h=parseFloat(s.y)||0,d=parseFloat(s.width)||0,f=parseFloat(s.height)||0,g=parseFloat(s.rx)||0,y=parseFloat(s.ry)||0;if(g>0||y>0){const b=WN(u,h,d,f,g||y,y||g);o=e.path(b,c)}else o=e.rectangle(u,h,d,f,c);a=l;break}case"path":{const[s,c,l]=i(t,["d"]),u=s.d||"";if(!u)return console.warn("Path element has no d attribute"),null;o=e.path(u,c),a=l;break}case"polygon":{const[s,c,l]=i(t,["points"]),u=Cb(s.points||"");if(u.length<3)return console.warn("Polygon needs at least 3 points"),null;o=e.polygon(u,c),a=l;break}case"polyline":{const[s,c,l]=i(t,["points"]),u=Cb(s.points||"");if(u.length<2)return console.warn("Polyline needs at least 2 points"),null;o=e.linearPath(u,c),a=l;break}default:return console.warn(`Unsupported shape type: ${r}`),null}return o?{element:o,svgAttributes:a}:null}catch(o){return console.error(`Error creating rough shape for ${r}:`,o),null}}function WN(e,t,n,r,i,o){return i=Math.min(i,n/2),o=Math.min(o,r/2),`
|
|
14
|
+
</symbol>`)})}function Nz(e){const t=e.trim();return/^(?:<\?xml[^>]*>\s*)?<svg[\s>]/i.test(t)||t.startsWith("<symbol")}function vi(e){if(!e||!Nz(e))return null;const t=e.replace(/<svg(?=[\s/>])/i,"<symbol").replace(/<\/svg>/i,"</symbol>");return _i(t)}var zz=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function Dz(e){try{return!!new URL(e)}catch(t){return!1}}function qz(e,t){return!!(e.toLowerCase().includes("image/svg")||!e&&t==="svg")}function Eb(e,t){return zz(this,null,function*(){if(!e||!Dz(e))return null;const n=yield ga(e);if(!n.ok)throw new Error("Failed to load resource");const r=n.headers.get("Content-Type")||"";if(qz(r,t)){const s=yield n.text();return vi(s)}const i=yield n.blob(),o=yield Hz(i);return mo(o)})}function Hz(e){return new Promise((t,n)=>{const r=new FileReader;r.onloadend=()=>{t(r.result)},r.onerror=n,r.readAsDataURL(e)})}var Mb=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});const jz=e=>Mb(null,null,function*(){var t;try{const n=new URLSearchParams({text:e,topK:"1"}),r=`${RM}?${n.toString()}`,i=yield ga(r);if(!i.ok)return null;const o=yield i.json();return!(o!=null&&o.status)||!Array.isArray((t=o.data)==null?void 0:t.data)?null:o.data.data[0]||null}catch(n){return console.error(`Failed to query icon for "${e}":`,n),null}});function Fz(e){return e.startsWith("data:")}function Bz(e){const t=e.trim();return t.startsWith("<svg")||t.startsWith("<symbol")}function Ib(e,t){return Mb(this,null,function*(){var n;if(!e)return null;const r=yield jz(e);if(!r)return null;if(Bz(r))return vi(r);if(Fz(r)){const i=((n=r.match(/^data:([^;]+)/))==null?void 0:n[1])||"",o=r.includes(";base64,");if(i==="image/svg+xml"&&!o){const s=r.indexOf(","),a=s>=0?r.slice(s+1):r;return vi(a)}return mo(r)}return Eb(r,t)})}let Ab=null;function Wz(e){Ab=e}function Vz(){return Ab}function Gz(e){if(!e.startsWith("data:"))return null;const t=e.indexOf(",");if(t===-1)return null;const n=e.slice(5,t),r=e.slice(t+1),i=n.split(";"),o=i[0],s=i.includes("base64");return o==="image/svg+xml"&&!s?{source:"inline",format:"svg",encoding:"raw",data:r.startsWith("%3C")?decodeURIComponent(r):r}:o.startsWith("image/")?{source:"inline",format:o==="image/svg+xml"?"svg":"image",encoding:s?"base64":"data-uri",data:e}:null}const Yz=new Set(["svg","png","jpg","jpeg","webp","gif"]);function Xz(e){const t=e.trim();return t.startsWith("<svg")||t.startsWith("<symbol")}function Uz(e){const t=e.toLowerCase();if(t.endsWith(".svg")||t.includes(".svg?"))return"svg";if(t.endsWith(".png")||t.endsWith(".jpg")||t.endsWith(".jpeg")||t.endsWith(".webp")||t.endsWith(".gif"))return"image"}function Kz(e){var t;if(!e.startsWith("ref:"))return null;const n=e.slice(4),[r,...i]=n.split(":");if(!r||i.length===0)return null;let o;i.length>1&&Yz.has(i[0].toLowerCase())&&(o=(t=i.shift())==null?void 0:t.toLowerCase());const s=i.join(":");if(!s)return null;const a=r==="url"?"remote":r;return a==="remote"?{source:"remote",format:o||Uz(s)||void 0,data:s}:a==="search"?{source:"search",format:o||"svg",data:s}:a==="svg"?{source:"inline",format:"svg",data:s,encoding:"raw"}:{source:"custom",data:e,format:o}}function Gs(e){if(!e)return null;if(typeof e!="string"){if(e.source)return e;const r=e;return r.type==="image"?{source:"inline",format:"image",data:r.data}:r.type==="svg"?{source:"inline",format:"svg",encoding:"raw",data:r.data}:r.type==="remote"?{source:"remote",format:r.format,data:r.data}:r.type==="search"?{source:"search",format:r.format||"svg",data:r.data}:r.type==="custom"?{source:"custom",data:r.data}:null}const t=Gz(e);if(t)return t;const n=Kz(e);return n||(Xz(e)?{source:"inline",format:"svg",encoding:"raw",data:e}:{source:"custom",data:e})}function Hu(e){const t=typeof e=="string"?Gs(e):e;return t?"rsc-"+T_(JSON.stringify(t)):null}function Tb(e){const t=Hu(e);return t?`#${t}`:null}var ju=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function Zz(e,t,n){return ju(this,null,function*(){const r=Gs(t);if(!r)return null;r.scene||(r.scene=e);const{source:i,data:o,format:s,encoding:a}=r;let l=null;try{if(i==="inline"){const c=o.startsWith("data:");s==="svg"&&a==="raw"?l=vi(o):s==="svg"&&c?l=yield mo(o):c||s==="image"?l=yield mo(o):l=vi(o)}else if(i==="remote")l=yield Eb(o,s);else if(i==="search")l=yield Ib(o,s);else{const c=Vz();c&&(l=yield c(r))}}catch(c){l=null}return l||(yield Ib(Qz(r,e,n),s))})}const Rb=new Map,Ys=new WeakMap;function kb(e,t,n,r){return ju(this,null,function*(){if(!e)return null;const i=Gs(n);if(!i)return null;const o=Hu(i),s=`resource:${o}`,a=Ys.get(e);if(a!=null&&a.has(o))return o;const l=mb(e,s);if(l)return yield l;const c=ju(null,null,function*(){const u=Rb.has(o)?Rb.get(o)||null:yield Zz(t,i,r);if(!u)return null;Ys.has(e)||Ys.set(e,new Map);const h=Ys.get(e);if(h.has(o))return o;const f=fa(e);return u.id=o,f.appendChild(u),h.set(o,u),o});return yb(e,s,c),yield c})}function Qz(e,t,n){const r=t==="illus"?"illustration":"icon",i=Xs(e.data)||Xs(n==null?void 0:n.label)||Xs(n==null?void 0:n.desc);if(i)return i;const o=Xs(e.data);return!o||e.source==="inline"||o.startsWith("data:")||o.startsWith("<svg")||o.startsWith("<symbol")?r:o}function Xs(e){if(typeof e!="string")return null;const t=e.trim();return t||null}var Jz=Object.defineProperty,Lb=Object.getOwnPropertySymbols,eD=Object.prototype.hasOwnProperty,tD=Object.prototype.propertyIsEnumerable,Nb=(e,t,n)=>t in e?Jz(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Us=(e,t)=>{for(var n in t||(t={}))eD.call(t,n)&&Nb(e,n,t[n]);if(Lb)for(var n of Lb(t))tD.call(t,n)&&Nb(e,n,t[n]);return e};function nD(e,t,n,r){var i,o;const s=n.icon;if(!s)return null;const{themeConfig:a}=r,l=(i=n.attributes)==null?void 0:i.icon,c=Us(Us({},(o=a.item)==null?void 0:o.icon),l),u=go(t,c);return rD(e,t,s,u,n)}function rD(e,t,n,r,i){return kb(e,"icon",n,i),CH(n,Us(Us({},cn(t,["id","x","y","width","height","fill","stroke","data-element-type","data-indexes"])),r))}var iD=Object.defineProperty,oD=Object.defineProperties,sD=Object.getOwnPropertyDescriptors,Ks=Object.getOwnPropertySymbols,zb=Object.prototype.hasOwnProperty,Db=Object.prototype.propertyIsEnumerable,qb=(e,t,n)=>t in e?iD(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,yo=(e,t)=>{for(var n in t||(t={}))zb.call(t,n)&&qb(e,n,t[n]);if(Ks)for(var n of Ks(t))Db.call(t,n)&&qb(e,n,t[n]);return e},Hb=(e,t)=>oD(e,sD(t)),aD=(e,t)=>{var n={};for(var r in e)zb.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ks)for(var r of Ks(e))t.indexOf(r)<0&&Db.call(e,r)&&(n[r]=e[r]);return n};function jb(e,t,n,r,i={}){if(!n)return null;const o=Gs(n);if(!o)return null;const s=Hu(o);i&&Object.keys(i).length>0&&ut(t,i);const a=cD(e,t,s);kb(e,"illus",o,r);const{data:l,color:c}=o;return uD(s,Hb(yo(yo(yo({},hD(t)),c?{color:c}:{}),i),{"clip-path":`url(#${a})`}),l)}function lD(e,t,n){var r;const i=n.illus,o=(r=n.attributes)==null?void 0:r.illus;return jb(e,t,i,n,o)}function cD(e,t,n){const r=`clip-${n}-${EH()}`;if(e.querySelector(`#${r}`))return r;const i=fa(e),o=Me("clipPath",{id:r}),s=t.cloneNode();return Dq(s,["id","data-illus-bounds","data-element-type"]),o.appendChild(s),i.appendChild(o),r}function uD(e,t,n){const r=t,{"clip-path":i}=r,o=aD(r,["clip-path"]),{x:s="0",y:a="0",width:l="0",height:c="0"}=o,u=Me("rect",{id:`${e}-volume`,"data-element-type":Ge.IllusVolume,x:s,y:a,width:l,height:c,fill:"transparent"}),h=Me("g",{"data-element-type":Ge.IllusGroup,"clip-path":i,id:`${e}-group`});h.appendChild(u);const f=Me("use",Hb(yo({id:e,fill:"lightgray"},o),{href:Tb(n),"data-element-type":Ge.Illus}));return h.appendChild(f),h}function hD(e){const t=e.getAttribute("data-illus-bounds");if(!t)return yo({x:"0",y:"0",width:"0",height:"0"},cn(e,["x","y","width","height"]));const[n,r,i,o]=t.split(" ");return{x:n,y:r,width:i,height:o}}function Zs(e){"@babel/helpers - typeof";return Zs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zs(e)}var fD=/^\s+/,dD=/\s+$/;function be(e,t){if(e=e||"",t=t||{},e instanceof be)return e;if(!(this instanceof be))return new be(e,t);var n=pD(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=Math.round(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=n.ok}be.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(t.r*299+t.g*587+t.b*114)/1e3},getLuminance:function(){var t=this.toRgb(),n,r,i,o,s,a;return n=t.r/255,r=t.g/255,i=t.b/255,n<=.03928?o=n/12.92:o=Math.pow((n+.055)/1.055,2.4),r<=.03928?s=r/12.92:s=Math.pow((r+.055)/1.055,2.4),i<=.03928?a=i/12.92:a=Math.pow((i+.055)/1.055,2.4),.2126*o+.7152*s+.0722*a},setAlpha:function(t){return this._a=Yb(t),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var t=Bb(this._r,this._g,this._b);return{h:t.h*360,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=Bb(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.v*100);return this._a==1?"hsv("+n+", "+r+"%, "+i+"%)":"hsva("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=Fb(this._r,this._g,this._b);return{h:t.h*360,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=Fb(this._r,this._g,this._b),n=Math.round(t.h*360),r=Math.round(t.s*100),i=Math.round(t.l*100);return this._a==1?"hsl("+n+", "+r+"%, "+i+"%)":"hsla("+n+", "+r+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return Wb(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(t){return vD(this._r,this._g,this._b,this._a,t)},toHex8String:function(t){return"#"+this.toHex8(t)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(_t(this._r,255)*100)+"%",g:Math.round(_t(this._g,255)*100)+"%",b:Math.round(_t(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(_t(this._r,255)*100)+"%, "+Math.round(_t(this._g,255)*100)+"%, "+Math.round(_t(this._b,255)*100)+"%)":"rgba("+Math.round(_t(this._r,255)*100)+"%, "+Math.round(_t(this._g,255)*100)+"%, "+Math.round(_t(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:ID[Wb(this._r,this._g,this._b,!0)]||!1},toFilter:function(t){var n="#"+Vb(this._r,this._g,this._b,this._a),r=n,i=this._gradientType?"GradientType = 1, ":"";if(t){var o=be(t);r="#"+Vb(o._r,o._g,o._b,o._a)}return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+n+",endColorstr="+r+")"},toString:function(t){var n=!!t;t=t||this._format;var r=!1,i=this._a<1&&this._a>=0,o=!n&&i&&(t==="hex"||t==="hex6"||t==="hex3"||t==="hex4"||t==="hex8"||t==="name");return o?t==="name"&&this._a===0?this.toName():this.toRgbString():(t==="rgb"&&(r=this.toRgbString()),t==="prgb"&&(r=this.toPercentageRgbString()),(t==="hex"||t==="hex6")&&(r=this.toHexString()),t==="hex3"&&(r=this.toHexString(!0)),t==="hex4"&&(r=this.toHex8String(!0)),t==="hex8"&&(r=this.toHex8String()),t==="name"&&(r=this.toName()),t==="hsl"&&(r=this.toHslString()),t==="hsv"&&(r=this.toHsvString()),r||this.toHexString())},clone:function(){return be(this.toString())},_applyModification:function(t,n){var r=t.apply(null,[this].concat([].slice.call(n)));return this._r=r._r,this._g=r._g,this._b=r._b,this.setAlpha(r._a),this},lighten:function(){return this._applyModification(xD,arguments)},brighten:function(){return this._applyModification(CD,arguments)},darken:function(){return this._applyModification(PD,arguments)},desaturate:function(){return this._applyModification(bD,arguments)},saturate:function(){return this._applyModification(_D,arguments)},greyscale:function(){return this._applyModification(wD,arguments)},spin:function(){return this._applyModification(OD,arguments)},_applyCombination:function(t,n){return t.apply(null,[this].concat([].slice.call(n)))},analogous:function(){return this._applyCombination(ED,arguments)},complement:function(){return this._applyCombination(SD,arguments)},monochromatic:function(){return this._applyCombination(MD,arguments)},splitcomplement:function(){return this._applyCombination($D,arguments)},triad:function(){return this._applyCombination(Gb,[3])},tetrad:function(){return this._applyCombination(Gb,[4])}},be.fromRatio=function(e,t){if(Zs(e)=="object"){var n={};for(var r in e)e.hasOwnProperty(r)&&(r==="a"?n[r]=e[r]:n[r]=vo(e[r]));e=n}return be(e,t)};function pD(e){var t={r:0,g:0,b:0},n=1,r=null,i=null,o=null,s=!1,a=!1;return typeof e=="string"&&(e=kD(e)),Zs(e)=="object"&&(Vn(e.r)&&Vn(e.g)&&Vn(e.b)?(t=gD(e.r,e.g,e.b),s=!0,a=String(e.r).substr(-1)==="%"?"prgb":"rgb"):Vn(e.h)&&Vn(e.s)&&Vn(e.v)?(r=vo(e.s),i=vo(e.v),t=yD(e.h,r,i),s=!0,a="hsv"):Vn(e.h)&&Vn(e.s)&&Vn(e.l)&&(r=vo(e.s),o=vo(e.l),t=mD(e.h,r,o),s=!0,a="hsl"),e.hasOwnProperty("a")&&(n=e.a)),n=Yb(n),{ok:s,format:e.format||a,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}function gD(e,t,n){return{r:_t(e,255)*255,g:_t(t,255)*255,b:_t(n,255)*255}}function Fb(e,t,n){e=_t(e,255),t=_t(t,255),n=_t(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,s,a=(r+i)/2;if(r==i)o=s=0;else{var l=r-i;switch(s=a>.5?l/(2-r-i):l/(r+i),r){case e:o=(t-n)/l+(t<n?6:0);break;case t:o=(n-e)/l+2;break;case n:o=(e-t)/l+4;break}o/=6}return{h:o,s,l:a}}function mD(e,t,n){var r,i,o;e=_t(e,360),t=_t(t,100),n=_t(n,100);function s(c,u,h){return h<0&&(h+=1),h>1&&(h-=1),h<1/6?c+(u-c)*6*h:h<1/2?u:h<2/3?c+(u-c)*(2/3-h)*6:c}if(t===0)r=i=o=n;else{var a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=s(l,a,e+1/3),i=s(l,a,e),o=s(l,a,e-1/3)}return{r:r*255,g:i*255,b:o*255}}function Bb(e,t,n){e=_t(e,255),t=_t(t,255),n=_t(n,255);var r=Math.max(e,t,n),i=Math.min(e,t,n),o,s,a=r,l=r-i;if(s=r===0?0:l/r,r==i)o=0;else{switch(r){case e:o=(t-n)/l+(t<n?6:0);break;case t:o=(n-e)/l+2;break;case n:o=(e-t)/l+4;break}o/=6}return{h:o,s,v:a}}function yD(e,t,n){e=_t(e,360)*6,t=_t(t,100),n=_t(n,100);var r=Math.floor(e),i=e-r,o=n*(1-t),s=n*(1-i*t),a=n*(1-(1-i)*t),l=r%6,c=[n,s,o,o,a,n][l],u=[a,n,n,s,o,o][l],h=[o,o,a,n,n,s][l];return{r:c*255,g:u*255,b:h*255}}function Wb(e,t,n,r){var i=[gn(Math.round(e).toString(16)),gn(Math.round(t).toString(16)),gn(Math.round(n).toString(16))];return r&&i[0].charAt(0)==i[0].charAt(1)&&i[1].charAt(0)==i[1].charAt(1)&&i[2].charAt(0)==i[2].charAt(1)?i[0].charAt(0)+i[1].charAt(0)+i[2].charAt(0):i.join("")}function vD(e,t,n,r,i){var o=[gn(Math.round(e).toString(16)),gn(Math.round(t).toString(16)),gn(Math.round(n).toString(16)),gn(Xb(r))];return i&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0):o.join("")}function Vb(e,t,n,r){var i=[gn(Xb(r)),gn(Math.round(e).toString(16)),gn(Math.round(t).toString(16)),gn(Math.round(n).toString(16))];return i.join("")}be.equals=function(e,t){return!e||!t?!1:be(e).toRgbString()==be(t).toRgbString()},be.random=function(){return be.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function bD(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.s-=t/100,n.s=Qs(n.s),be(n)}function _D(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.s+=t/100,n.s=Qs(n.s),be(n)}function wD(e){return be(e).desaturate(100)}function xD(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.l+=t/100,n.l=Qs(n.l),be(n)}function CD(e,t){t=t===0?0:t||10;var n=be(e).toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(255*-(t/100)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(255*-(t/100)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(255*-(t/100)))),be(n)}function PD(e,t){t=t===0?0:t||10;var n=be(e).toHsl();return n.l-=t/100,n.l=Qs(n.l),be(n)}function OD(e,t){var n=be(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,be(n)}function SD(e){var t=be(e).toHsl();return t.h=(t.h+180)%360,be(t)}function Gb(e,t){if(isNaN(t)||t<=0)throw new Error("Argument to polyad must be a positive number");for(var n=be(e).toHsl(),r=[be(e)],i=360/t,o=1;o<t;o++)r.push(be({h:(n.h+o*i)%360,s:n.s,l:n.l}));return r}function $D(e){var t=be(e).toHsl(),n=t.h;return[be(e),be({h:(n+72)%360,s:t.s,l:t.l}),be({h:(n+216)%360,s:t.s,l:t.l})]}function ED(e,t,n){t=t||6,n=n||30;var r=be(e).toHsl(),i=360/n,o=[be(e)];for(r.h=(r.h-(i*t>>1)+720)%360;--t;)r.h=(r.h+i)%360,o.push(be(r));return o}function MD(e,t){t=t||6;for(var n=be(e).toHsv(),r=n.h,i=n.s,o=n.v,s=[],a=1/t;t--;)s.push(be({h:r,s:i,v:o})),o=(o+a)%1;return s}be.mix=function(e,t,n){n=n===0?0:n||50;var r=be(e).toRgb(),i=be(t).toRgb(),o=n/100,s={r:(i.r-r.r)*o+r.r,g:(i.g-r.g)*o+r.g,b:(i.b-r.b)*o+r.b,a:(i.a-r.a)*o+r.a};return be(s)},be.readability=function(e,t){var n=be(e),r=be(t);return(Math.max(n.getLuminance(),r.getLuminance())+.05)/(Math.min(n.getLuminance(),r.getLuminance())+.05)},be.isReadable=function(e,t,n){var r=be.readability(e,t),i,o;switch(o=!1,i=LD(n),i.level+i.size){case"AAsmall":case"AAAlarge":o=r>=4.5;break;case"AAlarge":o=r>=3;break;case"AAAsmall":o=r>=7;break}return o},be.mostReadable=function(e,t,n){var r=null,i=0,o,s,a,l;n=n||{},s=n.includeFallbackColors,a=n.level,l=n.size;for(var c=0;c<t.length;c++)o=be.readability(e,t[c]),o>i&&(i=o,r=be(t[c]));return be.isReadable(e,r,{level:a,size:l})||!s?r:(n.includeFallbackColors=!1,be.mostReadable(e,["#fff","#000"],n))};var Fu=be.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},ID=be.hexNames=AD(Fu);function AD(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}function Yb(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function _t(e,t){TD(e)&&(e="100%");var n=RD(e);return e=Math.min(t,Math.max(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),Math.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function Qs(e){return Math.min(1,Math.max(0,e))}function an(e){return parseInt(e,16)}function TD(e){return typeof e=="string"&&e.indexOf(".")!=-1&&parseFloat(e)===1}function RD(e){return typeof e=="string"&&e.indexOf("%")!=-1}function gn(e){return e.length==1?"0"+e:""+e}function vo(e){return e<=1&&(e=e*100+"%"),e}function Xb(e){return Math.round(parseFloat(e)*255).toString(16)}function Ub(e){return an(e)/255}var mn=(function(){var e="[-\\+]?\\d+%?",t="[-\\+]?\\d*\\.\\d+%?",n="(?:"+t+")|(?:"+e+")",r="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?",i="[\\s|\\(]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")[,|\\s]+("+n+")\\s*\\)?";return{CSS_UNIT:new RegExp(n),rgb:new RegExp("rgb"+r),rgba:new RegExp("rgba"+i),hsl:new RegExp("hsl"+r),hsla:new RegExp("hsla"+i),hsv:new RegExp("hsv"+r),hsva:new RegExp("hsva"+i),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}})();function Vn(e){return!!mn.CSS_UNIT.exec(e)}function kD(e){e=e.replace(fD,"").replace(dD,"").toLowerCase();var t=!1;if(Fu[e])e=Fu[e],t=!0;else if(e=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var n;return(n=mn.rgb.exec(e))?{r:n[1],g:n[2],b:n[3]}:(n=mn.rgba.exec(e))?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=mn.hsl.exec(e))?{h:n[1],s:n[2],l:n[3]}:(n=mn.hsla.exec(e))?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=mn.hsv.exec(e))?{h:n[1],s:n[2],v:n[3]}:(n=mn.hsva.exec(e))?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=mn.hex8.exec(e))?{r:an(n[1]),g:an(n[2]),b:an(n[3]),a:Ub(n[4]),format:t?"name":"hex8"}:(n=mn.hex6.exec(e))?{r:an(n[1]),g:an(n[2]),b:an(n[3]),format:t?"name":"hex"}:(n=mn.hex4.exec(e))?{r:an(n[1]+""+n[1]),g:an(n[2]+""+n[2]),b:an(n[3]+""+n[3]),a:Ub(n[4]+""+n[4]),format:t?"name":"hex8"}:(n=mn.hex3.exec(e))?{r:an(n[1]+""+n[1]),g:an(n[2]+""+n[2]),b:an(n[3]+""+n[3]),format:t?"name":"hex"}:!1}function LD(e){var t,n;return e=e||{level:"AA",size:"small"},t=(e.level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),t!=="AA"&&t!=="AAA"&&(t="AA"),n!=="small"&&n!=="large"&&(n="small"),{level:t,size:n}}var ND=Object.defineProperty,Kb=Object.getOwnPropertySymbols,zD=Object.prototype.hasOwnProperty,DD=Object.prototype.propertyIsEnumerable,Zb=(e,t,n)=>t in e?ND(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qD=(e,t)=>{for(var n in t||(t={}))zD.call(t,n)&&Zb(e,n,t[n]);if(Kb)for(var n of Kb(t))DD.call(t,n)&&Zb(e,n,t[n]);return e};function Qb(e,t,n,r){const i=e.getAttribute(r),o=HD(i,n),{type:s,colors:a=[]}=o,l=a.length-1,c=a.map((d,p)=>typeof d=="string"?Me("stop",{offset:`${p/l}`,"stop-color":d}):Me("stop",{offset:`${d.offset}`,"stop-color":d.color})),u=jD(o);if(s==="linear-gradient"){const{angle:d=0}=o,[[p,g],[m,v]]=FD(d),b=Me("linearGradient",{id:u,x1:p,y1:g,x2:m,y2:v});c.forEach(_=>b.appendChild(_)),Jb(t,u,b)}else if(s==="radial-gradient"){const d=Me("radialGradient",{id:u});c.forEach(p=>d.appendChild(p)),Jb(t,u,d)}const h=e.getAttribute("fill"),f=e.getAttribute("stroke");Pr(h)&&e.setAttribute("fill",`url(#${u})`),Pr(f)&&e.setAttribute("stroke",`url(#${u})`)}function Jb(e,t,n){const r=fa(e);n.setAttribute("id",t);const i=r.querySelector(`#${t}`);i?i.replaceWith(n):r.appendChild(n)}function HD(e,t){var n;if((n=t.colors)!=null&&n.length||!e)return t;const r=be(e),i=qD({},t);return i.colors=r.isDark()?[e,r.lighten(20).toHexString()]:[r.darken(20).toHexString(),e],!("angle"in t)&&i.type==="linear-gradient"&&(i.angle=225),i}function jD(e){const{type:t,colors:n=[]}=e,r=Pb(n.map(i=>typeof i=="string"?i:`${i.color}_${i.offset}`).join("-"));if(t==="linear-gradient"){const{angle:i=0}=e;return`${t}-${r}-${i}`}return`${t}-${r}`}function FD(e){const t=Math.PI/180*e,n=Math.cos(t),r=Math.sin(t);return[[.5-n/2,.5-r/2],[.5+n/2,.5+r/2]]}const BD=Object.freeze(Object.defineProperty({__proto__:null,diamond:({scale:e=.5,backgroundColor:t,foregroundColor:n})=>{const r=Me("pattern",{id:"pattern-diamond",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Me("rect",{width:"100%",height:"100%",fill:t}),o=Me("path",{d:"M0,0 L20,20 M20,0 L0,20",stroke:n,"stroke-width":"1"});return r.appendChild(i),r.appendChild(o),r},dot:({scale:e=1,backgroundColor:t,foregroundColor:n})=>{const r=Me("pattern",{id:"pattern-dot",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Me("rect",{width:"100%",height:"100%",fill:t}),o=Me("circle",{cx:"5",cy:"5",r:"3",fill:n}),s=Me("circle",{cx:"15",cy:"15",r:"3",fill:n});return r.appendChild(i),r.appendChild(o),r.appendChild(s),r},hex:({scale:e=.3,backgroundColor:t,foregroundColor:n})=>{const r=Me("pattern",{id:"pattern-hex",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Me("rect",{width:"100%",height:"100%",fill:t}),o=Me("path",{d:"M10,0 L20,5 L20,15 L10,20 L0,15 L0,5 Z",fill:n});return r.appendChild(i),r.appendChild(o),r},line:({scale:e=1,backgroundColor:t,foregroundColor:n})=>{const o=Me("pattern",{id:"pattern-line",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),s=Me("rect",{width:"100%",height:"100%",fill:t}),a=Me("line",{x1:"7",y1:"-3",x2:"23",y2:"13",stroke:n,"stroke-width":6,"stroke-opacity":"0.5"}),l=Me("line",{x1:"-3",y1:"7",x2:"13",y2:"23",stroke:n,"stroke-width":6,"stroke-opacity":"0.5"});return o.appendChild(s),o.appendChild(a),o.appendChild(l),o},mosaic:({scale:e=1,backgroundColor:t="#ffffff",foregroundColor:n="#000000"})=>{const a=Me("pattern",{id:"pattern-mosaic",width:20,height:20,patternUnits:"userSpaceOnUse",patternTransform:`scale(${e})`}),l=Me("rect",{width:"100%",height:"100%",fill:t});a.appendChild(l);for(let c=0;c<4;c++)for(let u=0;u<4;u++)if((u+c)%2===0){const h=Me("rect",{x:u*5,y:c*5,width:5,height:5,fill:n});a.appendChild(h)}return a},square:({scale:e=.3,backgroundColor:t,foregroundColor:n})=>{const r=Me("pattern",{id:"pattern-square",width:"20",height:"20",patternTransform:`scale(${e})`,patternUnits:"userSpaceOnUse"}),i=Me("rect",{width:"100%",height:"100%",fill:t}),o=Me("path",{d:"M0,0 L20,0 L20,20 L0,20 Z",fill:n});return r.appendChild(i),r.appendChild(o),r}},Symbol.toStringTag,{value:"Module"}));var WD=Object.defineProperty,Js=Object.getOwnPropertySymbols,e_=Object.prototype.hasOwnProperty,t_=Object.prototype.propertyIsEnumerable,n_=(e,t,n)=>t in e?WD(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bu=(e,t)=>{for(var n in t||(t={}))e_.call(t,n)&&n_(e,n,t[n]);if(Js)for(var n of Js(t))t_.call(t,n)&&n_(e,n,t[n]);return e},VD=(e,t)=>{var n={};for(var r in e)e_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Js)for(var r of Js(e))t.indexOf(r)<0&&t_.call(e,r)&&(n[r]=e[r]);return n};const Wu=new Map;function r_(e,t){Wu.has(e)&&console.warn(`Pattern ${e} will be overwritten`),Wu.set(e,t)}for(const[e,t]of Object.entries(BD))r_(e,t);function GD(e,t,n){const r=n.themeConfig.stylize;if(!r||r.type!=="pattern")return;const i=r,{pattern:o}=i,s=VD(i,["pattern"]),a=Wu.get(o);if(!a)return console.warn(`Pattern ${o} not found`);const{fill:l}=cn(e,["fill","stroke"]),c=l,u=Bu({backgroundColor:c&&be(c).setAlpha(.5).toRgbString(),foregroundColor:c},s),h=XD(Bu(Bu({},r),u));YD(t,h,a(u)),Pr(l)&&(e.setAttribute("fill",`url(#${h})`),!e.getAttribute("stroke")&&l&&e.setAttribute("stroke",l))}function YD(e,t,n){const r=fa(e);n.setAttribute("id",t);const i=r.querySelector(`pattern#${t}`);i?i.replaceWith(n):r.appendChild(n)}function XD(e){const{pattern:t,foregroundColor:n="unset",backgroundColor:r="unset",scale:i="unset"}=e;return Pb(`pattern-${t}-${n}-${r}-${i}`)}function Vu(e,t,n){if(e&&e.length){const[r,i]=t,o=Math.PI/180*n,s=Math.cos(o),a=Math.sin(o);for(const l of e){const[c,u]=l;l[0]=(c-r)*s-(u-i)*a+r,l[1]=(c-r)*a+(u-i)*s+i}}}function UD(e,t){return e[0]===t[0]&&e[1]===t[1]}function KD(e,t,n,r=1){const i=n,o=Math.max(t,.1),s=e[0]&&e[0][0]&&typeof e[0][0]=="number"?[e]:e,a=[0,0];if(i)for(const c of s)Vu(c,a,i);const l=(function(c,u,h){const f=[];for(const b of c){const _=[...b];UD(_[0],_[_.length-1])||_.push([_[0][0],_[0][1]]),_.length>2&&f.push(_)}const d=[];u=Math.max(u,.1);const p=[];for(const b of f)for(let _=0;_<b.length-1;_++){const x=b[_],w=b[_+1];if(x[1]!==w[1]){const C=Math.min(x[1],w[1]);p.push({ymin:C,ymax:Math.max(x[1],w[1]),x:C===x[1]?x[0]:w[0],islope:(w[0]-x[0])/(w[1]-x[1])})}}if(p.sort(((b,_)=>b.ymin<_.ymin?-1:b.ymin>_.ymin?1:b.x<_.x?-1:b.x>_.x?1:b.ymax===_.ymax?0:(b.ymax-_.ymax)/Math.abs(b.ymax-_.ymax))),!p.length)return d;let g=[],m=p[0].ymin,v=0;for(;g.length||p.length;){if(p.length){let b=-1;for(let _=0;_<p.length&&!(p[_].ymin>m);_++)b=_;p.splice(0,b+1).forEach((_=>{g.push({s:m,edge:_})}))}if(g=g.filter((b=>!(b.edge.ymax<=m))),g.sort(((b,_)=>b.edge.x===_.edge.x?0:(b.edge.x-_.edge.x)/Math.abs(b.edge.x-_.edge.x))),(h!==1||v%u==0)&&g.length>1)for(let b=0;b<g.length;b+=2){const _=b+1;if(_>=g.length)break;const x=g[b].edge,w=g[_].edge;d.push([[Math.round(x.x),m],[Math.round(w.x),m]])}m+=h,g.forEach((b=>{b.edge.x=b.edge.x+h*b.edge.islope})),v++}return d})(s,o,r);if(i){for(const c of s)Vu(c,a,-i);(function(c,u,h){const f=[];c.forEach((d=>f.push(...d))),Vu(f,u,h)})(l,a,-i)}return l}function bo(e,t){var n;const r=t.hachureAngle+90;let i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let o=1;return t.roughness>=1&&(((n=t.randomizer)===null||n===void 0?void 0:n.next())||Math.random())>.7&&(o=i),KD(e,i,r,o||1)}let Gu=class{constructor(t){this.helper=t}fillPolygons(t,n){return this._fillPolygons(t,n)}_fillPolygons(t,n){const r=bo(t,n);return{type:"fillSketch",ops:this.renderLines(r,n)}}renderLines(t,n){const r=[];for(const i of t)r.push(...this.helper.doubleLineOps(i[0][0],i[0][1],i[1][0],i[1][1],n));return r}};function ea(e){const t=e[0],n=e[1];return Math.sqrt(Math.pow(t[0]-n[0],2)+Math.pow(t[1]-n[1],2))}let ZD=class extends Gu{fillPolygons(t,n){let r=n.hachureGap;r<0&&(r=4*n.strokeWidth),r=Math.max(r,.1);const i=bo(t,Object.assign({},n,{hachureGap:r})),o=Math.PI/180*n.hachureAngle,s=[],a=.5*r*Math.cos(o),l=.5*r*Math.sin(o);for(const[c,u]of i)ea([c,u])&&s.push([[c[0]-a,c[1]+l],[...u]],[[c[0]+a,c[1]-l],[...u]]);return{type:"fillSketch",ops:this.renderLines(s,n)}}},QD=class extends Gu{fillPolygons(t,n){const r=this._fillPolygons(t,n),i=Object.assign({},n,{hachureAngle:n.hachureAngle+90}),o=this._fillPolygons(t,i);return r.ops=r.ops.concat(o.ops),r}},JD=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=bo(t,n=Object.assign({},n,{hachureAngle:0}));return this.dotsOnLines(r,n)}dotsOnLines(t,n){const r=[];let i=n.hachureGap;i<0&&(i=4*n.strokeWidth),i=Math.max(i,.1);let o=n.fillWeight;o<0&&(o=n.strokeWidth/2);const s=i/4;for(const a of t){const l=ea(a),c=l/i,u=Math.ceil(c)-1,h=l-u*i,f=(a[0][0]+a[1][0])/2-i/4,d=Math.min(a[0][1],a[1][1]);for(let p=0;p<u;p++){const g=d+h+p*i,m=f-s+2*Math.random()*s,v=g-s+2*Math.random()*s,b=this.helper.ellipse(m,v,o,o,n);r.push(...b.ops)}}return{type:"fillSketch",ops:r}}},eq=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=bo(t,n);return{type:"fillSketch",ops:this.dashedLine(r,n)}}dashedLine(t,n){const r=n.dashOffset<0?n.hachureGap<0?4*n.strokeWidth:n.hachureGap:n.dashOffset,i=n.dashGap<0?n.hachureGap<0?4*n.strokeWidth:n.hachureGap:n.dashGap,o=[];return t.forEach((s=>{const a=ea(s),l=Math.floor(a/(r+i)),c=(a+i-l*(r+i))/2;let u=s[0],h=s[1];u[0]>h[0]&&(u=s[1],h=s[0]);const f=Math.atan((h[1]-u[1])/(h[0]-u[0]));for(let d=0;d<l;d++){const p=d*(r+i),g=p+r,m=[u[0]+p*Math.cos(f)+c*Math.cos(f),u[1]+p*Math.sin(f)+c*Math.sin(f)],v=[u[0]+g*Math.cos(f)+c*Math.cos(f),u[1]+g*Math.sin(f)+c*Math.sin(f)];o.push(...this.helper.doubleLineOps(m[0],m[1],v[0],v[1],n))}})),o}},tq=class{constructor(t){this.helper=t}fillPolygons(t,n){const r=n.hachureGap<0?4*n.strokeWidth:n.hachureGap,i=n.zigzagOffset<0?r:n.zigzagOffset,o=bo(t,n=Object.assign({},n,{hachureGap:r+i}));return{type:"fillSketch",ops:this.zigzagLines(o,i,n)}}zigzagLines(t,n,r){const i=[];return t.forEach((o=>{const s=ea(o),a=Math.round(s/(2*n));let l=o[0],c=o[1];l[0]>c[0]&&(l=o[1],c=o[0]);const u=Math.atan((c[1]-l[1])/(c[0]-l[0]));for(let h=0;h<a;h++){const f=2*h*n,d=2*(h+1)*n,p=Math.sqrt(2*Math.pow(n,2)),g=[l[0]+f*Math.cos(u),l[1]+f*Math.sin(u)],m=[l[0]+d*Math.cos(u),l[1]+d*Math.sin(u)],v=[g[0]+p*Math.cos(u+Math.PI/4),g[1]+p*Math.sin(u+Math.PI/4)];i.push(...this.helper.doubleLineOps(g[0],g[1],v[0],v[1],r),...this.helper.doubleLineOps(v[0],v[1],m[0],m[1],r))}})),i}};const en={};let nq=class{constructor(t){this.seed=t}next(){return this.seed?(ds(2,31)-1&(this.seed=Math.imul(48271,this.seed)))/ds(2,31):Math.random()}};const rq=0,Yu=1,i_=2,ta={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Xu(e,t){return e.type===t}function Uu(e){const t=[],n=(function(s){const a=new Array;for(;s!=="";)if(s.match(/^([ \t\r\n,]+)/))s=s.substr(RegExp.$1.length);else if(s.match(/^([aAcChHlLmMqQsStTvVzZ])/))a[a.length]={type:rq,text:RegExp.$1},s=s.substr(RegExp.$1.length);else{if(!s.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];a[a.length]={type:Yu,text:`${parseFloat(RegExp.$1)}`},s=s.substr(RegExp.$1.length)}return a[a.length]={type:i_,text:""},a})(e);let r="BOD",i=0,o=n[i];for(;!Xu(o,i_);){let s=0;const a=[];if(r==="BOD"){if(o.text!=="M"&&o.text!=="m")return Uu("M0,0"+e);i++,s=ta[o.text],r=o.text}else Xu(o,Yu)?s=ta[r]:(i++,s=ta[o.text],r=o.text);if(!(i+s<n.length))throw new Error("Path data ended short");for(let l=i;l<i+s;l++){const c=n[l];if(!Xu(c,Yu))throw new Error("Param not a number: "+r+","+c.text);a[a.length]=+c.text}if(typeof ta[r]!="number")throw new Error("Bad segment: "+r);{const l={key:r,data:a};t.push(l),i+=s,o=n[i],r==="M"&&(r="L"),r==="m"&&(r="l")}}return t}function o_(e){let t=0,n=0,r=0,i=0;const o=[];for(const{key:s,data:a}of e)switch(s){case"M":o.push({key:"M",data:[...a]}),[t,n]=a,[r,i]=a;break;case"m":t+=a[0],n+=a[1],o.push({key:"M",data:[t,n]}),r=t,i=n;break;case"L":o.push({key:"L",data:[...a]}),[t,n]=a;break;case"l":t+=a[0],n+=a[1],o.push({key:"L",data:[t,n]});break;case"C":o.push({key:"C",data:[...a]}),t=a[4],n=a[5];break;case"c":{const l=a.map(((c,u)=>u%2?c+n:c+t));o.push({key:"C",data:l}),t=l[4],n=l[5];break}case"Q":o.push({key:"Q",data:[...a]}),t=a[2],n=a[3];break;case"q":{const l=a.map(((c,u)=>u%2?c+n:c+t));o.push({key:"Q",data:l}),t=l[2],n=l[3];break}case"A":o.push({key:"A",data:[...a]}),t=a[5],n=a[6];break;case"a":t+=a[5],n+=a[6],o.push({key:"A",data:[a[0],a[1],a[2],a[3],a[4],t,n]});break;case"H":o.push({key:"H",data:[...a]}),t=a[0];break;case"h":t+=a[0],o.push({key:"H",data:[t]});break;case"V":o.push({key:"V",data:[...a]}),n=a[0];break;case"v":n+=a[0],o.push({key:"V",data:[n]});break;case"S":o.push({key:"S",data:[...a]}),t=a[2],n=a[3];break;case"s":{const l=a.map(((c,u)=>u%2?c+n:c+t));o.push({key:"S",data:l}),t=l[2],n=l[3];break}case"T":o.push({key:"T",data:[...a]}),t=a[0],n=a[1];break;case"t":t+=a[0],n+=a[1],o.push({key:"T",data:[t,n]});break;case"Z":case"z":o.push({key:"Z",data:[]}),t=r,n=i}return o}function s_(e){const t=[];let n="",r=0,i=0,o=0,s=0,a=0,l=0;for(const{key:c,data:u}of e){switch(c){case"M":t.push({key:"M",data:[...u]}),[r,i]=u,[o,s]=u;break;case"C":t.push({key:"C",data:[...u]}),r=u[4],i=u[5],a=u[2],l=u[3];break;case"L":t.push({key:"L",data:[...u]}),[r,i]=u;break;case"H":r=u[0],t.push({key:"L",data:[r,i]});break;case"V":i=u[0],t.push({key:"L",data:[r,i]});break;case"S":{let h=0,f=0;n==="C"||n==="S"?(h=r+(r-a),f=i+(i-l)):(h=r,f=i),t.push({key:"C",data:[h,f,...u]}),a=u[0],l=u[1],r=u[2],i=u[3];break}case"T":{const[h,f]=u;let d=0,p=0;n==="Q"||n==="T"?(d=r+(r-a),p=i+(i-l)):(d=r,p=i);const g=r+2*(d-r)/3,m=i+2*(p-i)/3,v=h+2*(d-h)/3,b=f+2*(p-f)/3;t.push({key:"C",data:[g,m,v,b,h,f]}),a=d,l=p,r=h,i=f;break}case"Q":{const[h,f,d,p]=u,g=r+2*(h-r)/3,m=i+2*(f-i)/3,v=d+2*(h-d)/3,b=p+2*(f-p)/3;t.push({key:"C",data:[g,m,v,b,d,p]}),a=h,l=f,r=d,i=p;break}case"A":{const h=Math.abs(u[0]),f=Math.abs(u[1]),d=u[2],p=u[3],g=u[4],m=u[5],v=u[6];h===0||f===0?(t.push({key:"C",data:[r,i,m,v,m,v]}),r=m,i=v):(r!==m||i!==v)&&(a_(r,i,m,v,h,f,d,p,g).forEach((function(b){t.push({key:"C",data:b})})),r=m,i=v);break}case"Z":t.push({key:"Z",data:[]}),r=o,i=s}n=c}return t}function _o(e,t,n){return[e*Math.cos(n)-t*Math.sin(n),e*Math.sin(n)+t*Math.cos(n)]}function a_(e,t,n,r,i,o,s,a,l,c){const u=(h=s,Math.PI*h/180);var h;let f=[],d=0,p=0,g=0,m=0;if(c)[d,p,g,m]=c;else{[e,t]=_o(e,t,-u),[n,r]=_o(n,r,-u);const E=(e-n)/2,A=(t-r)/2;let T=E*E/(i*i)+A*A/(o*o);T>1&&(T=Math.sqrt(T),i*=T,o*=T);const N=i*i,H=o*o,D=N*H-N*A*A-H*E*E,B=N*A*A+H*E*E,F=(a===l?-1:1)*Math.sqrt(Math.abs(D/B));g=F*i*A/o+(e+n)/2,m=F*-o*E/i+(t+r)/2,d=Math.asin(parseFloat(((t-m)/o).toFixed(9))),p=Math.asin(parseFloat(((r-m)/o).toFixed(9))),e<g&&(d=Math.PI-d),n<g&&(p=Math.PI-p),d<0&&(d=2*Math.PI+d),p<0&&(p=2*Math.PI+p),l&&d>p&&(d-=2*Math.PI),!l&&p>d&&(p-=2*Math.PI)}let v=p-d;if(Math.abs(v)>120*Math.PI/180){const E=p,A=n,T=r;p=l&&p>d?d+120*Math.PI/180*1:d+120*Math.PI/180*-1,f=a_(n=g+i*Math.cos(p),r=m+o*Math.sin(p),A,T,i,o,s,0,l,[p,E,g,m])}v=p-d;const b=Math.cos(d),_=Math.sin(d),x=Math.cos(p),w=Math.sin(p),C=Math.tan(v/4),P=4/3*i*C,O=4/3*o*C,$=[e,t],S=[e+P*_,t-O*b],M=[n+P*w,r-O*x],I=[n,r];if(S[0]=2*$[0]-S[0],S[1]=2*$[1]-S[1],c)return[S,M,I].concat(f);{f=[S,M,I].concat(f);const E=[];for(let A=0;A<f.length;A+=3){const T=_o(f[A][0],f[A][1],u),N=_o(f[A+1][0],f[A+1][1],u),H=_o(f[A+2][0],f[A+2][1],u);E.push([T[0],T[1],N[0],N[1],H[0],H[1]])}return E}}const iq={randOffset:function(e,t){return Re(e,t)},randOffsetWithRange:function(e,t,n){return ra(e,t,n)},ellipse:function(e,t,n,r,i){const o=u_(n,r,i);return Ku(e,t,i,o).opset},doubleLineOps:function(e,t,n,r,i){return hr(e,t,n,r,i,!0)}};function l_(e,t,n,r,i){return{type:"path",ops:hr(e,t,n,r,i)}}function na(e,t,n){const r=(e||[]).length;if(r>2){const i=[];for(let o=0;o<r-1;o++)i.push(...hr(e[o][0],e[o][1],e[o+1][0],e[o+1][1],n));return t&&i.push(...hr(e[r-1][0],e[r-1][1],e[0][0],e[0][1],n)),{type:"path",ops:i}}return r===2?l_(e[0][0],e[0][1],e[1][0],e[1][1],n):{type:"path",ops:[]}}function oq(e,t,n,r,i){return(function(o,s){return na(o,!0,s)})([[e,t],[e+n,t],[e+n,t+r],[e,t+r]],i)}function c_(e,t){if(e.length){const n=typeof e[0][0]=="number"?[e]:e,r=ia(n[0],1*(1+.2*t.roughness),t),i=t.disableMultiStroke?[]:ia(n[0],1.5*(1+.22*t.roughness),d_(t));for(let o=1;o<n.length;o++){const s=n[o];if(s.length){const a=ia(s,1*(1+.2*t.roughness),t),l=t.disableMultiStroke?[]:ia(s,1.5*(1+.22*t.roughness),d_(t));for(const c of a)c.op!=="move"&&r.push(c);for(const c of l)c.op!=="move"&&i.push(c)}}return{type:"path",ops:r.concat(i)}}return{type:"path",ops:[]}}function u_(e,t,n){const r=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),i=Math.ceil(Math.max(n.curveStepCount,n.curveStepCount/Math.sqrt(200)*r)),o=2*Math.PI/i;let s=Math.abs(e/2),a=Math.abs(t/2);const l=1-n.curveFitting;return s+=Re(s*l,n),a+=Re(a*l,n),{increment:o,rx:s,ry:a}}function Ku(e,t,n,r){const[i,o]=g_(r.increment,e,t,r.rx,r.ry,1,r.increment*ra(.1,ra(.4,1,n),n),n);let s=oa(i,null,n);if(!n.disableMultiStroke&&n.roughness!==0){const[a]=g_(r.increment,e,t,r.rx,r.ry,1.5,0,n),l=oa(a,null,n);s=s.concat(l)}return{estimatedPoints:o,opset:{type:"path",ops:s}}}function h_(e,t,n,r,i,o,s,a,l){const c=e,u=t;let h=Math.abs(n/2),f=Math.abs(r/2);h+=Re(.01*h,l),f+=Re(.01*f,l);let d=i,p=o;for(;d<0;)d+=2*Math.PI,p+=2*Math.PI;p-d>2*Math.PI&&(d=0,p=2*Math.PI);const g=2*Math.PI/l.curveStepCount,m=Math.min(g/2,(p-d)/2),v=m_(m,c,u,h,f,d,p,1,l);if(!l.disableMultiStroke){const b=m_(m,c,u,h,f,d,p,1.5,l);v.push(...b)}return s&&(a?v.push(...hr(c,u,c+h*Math.cos(d),u+f*Math.sin(d),l),...hr(c,u,c+h*Math.cos(p),u+f*Math.sin(p),l)):v.push({op:"lineTo",data:[c,u]},{op:"lineTo",data:[c+h*Math.cos(d),u+f*Math.sin(d)]})),{type:"path",ops:v}}function f_(e,t){const n=s_(o_(Uu(e))),r=[];let i=[0,0],o=[0,0];for(const{key:s,data:a}of n)switch(s){case"M":o=[a[0],a[1]],i=[a[0],a[1]];break;case"L":r.push(...hr(o[0],o[1],a[0],a[1],t)),o=[a[0],a[1]];break;case"C":{const[l,c,u,h,f,d]=a;r.push(...sq(l,c,u,h,f,d,o,t)),o=[f,d];break}case"Z":r.push(...hr(o[0],o[1],i[0],i[1],t)),o=[i[0],i[1]]}return{type:"path",ops:r}}function Zu(e,t){const n=[];for(const r of e)if(r.length){const i=t.maxRandomnessOffset||0,o=r.length;if(o>2){n.push({op:"move",data:[r[0][0]+Re(i,t),r[0][1]+Re(i,t)]});for(let s=1;s<o;s++)n.push({op:"lineTo",data:[r[s][0]+Re(i,t),r[s][1]+Re(i,t)]})}}return{type:"fillPath",ops:n}}function bi(e,t){return(function(n,r){let i=n.fillStyle||"hachure";if(!en[i])switch(i){case"zigzag":en[i]||(en[i]=new ZD(r));break;case"cross-hatch":en[i]||(en[i]=new QD(r));break;case"dots":en[i]||(en[i]=new JD(r));break;case"dashed":en[i]||(en[i]=new eq(r));break;case"zigzag-line":en[i]||(en[i]=new tq(r));break;default:i="hachure",en[i]||(en[i]=new Gu(r))}return en[i]})(t,iq).fillPolygons(e,t)}function d_(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function p_(e){return e.randomizer||(e.randomizer=new nq(e.seed||0)),e.randomizer.next()}function ra(e,t,n,r=1){return n.roughness*r*(p_(n)*(t-e)+e)}function Re(e,t,n=1){return ra(-e,e,t,n)}function hr(e,t,n,r,i,o=!1){const s=o?i.disableMultiStrokeFill:i.disableMultiStroke,a=Qu(e,t,n,r,i,!0,!1);if(s)return a;const l=Qu(e,t,n,r,i,!0,!0);return a.concat(l)}function Qu(e,t,n,r,i,o,s){const a=Math.pow(e-n,2)+Math.pow(t-r,2),l=Math.sqrt(a);let c=1;c=l<200?1:l>500?.4:-.0016668*l+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>a&&(u=l/10);const h=u/2,f=.2+.2*p_(i);let d=i.bowing*i.maxRandomnessOffset*(r-t)/200,p=i.bowing*i.maxRandomnessOffset*(e-n)/200;d=Re(d,i,c),p=Re(p,i,c);const g=[],m=()=>Re(h,i,c),v=()=>Re(u,i,c),b=i.preserveVertices;return s?g.push({op:"move",data:[e+(b?0:m()),t+(b?0:m())]}):g.push({op:"move",data:[e+(b?0:Re(u,i,c)),t+(b?0:Re(u,i,c))]}),s?g.push({op:"bcurveTo",data:[d+e+(n-e)*f+m(),p+t+(r-t)*f+m(),d+e+2*(n-e)*f+m(),p+t+2*(r-t)*f+m(),n+(b?0:m()),r+(b?0:m())]}):g.push({op:"bcurveTo",data:[d+e+(n-e)*f+v(),p+t+(r-t)*f+v(),d+e+2*(n-e)*f+v(),p+t+2*(r-t)*f+v(),n+(b?0:v()),r+(b?0:v())]}),g}function ia(e,t,n){if(!e.length)return[];const r=[];r.push([e[0][0]+Re(t,n),e[0][1]+Re(t,n)]),r.push([e[0][0]+Re(t,n),e[0][1]+Re(t,n)]);for(let i=1;i<e.length;i++)r.push([e[i][0]+Re(t,n),e[i][1]+Re(t,n)]),i===e.length-1&&r.push([e[i][0]+Re(t,n),e[i][1]+Re(t,n)]);return oa(r,null,n)}function oa(e,t,n){const r=e.length,i=[];if(r>3){const o=[],s=1-n.curveTightness;i.push({op:"move",data:[e[1][0],e[1][1]]});for(let a=1;a+2<r;a++){const l=e[a];o[0]=[l[0],l[1]],o[1]=[l[0]+(s*e[a+1][0]-s*e[a-1][0])/6,l[1]+(s*e[a+1][1]-s*e[a-1][1])/6],o[2]=[e[a+1][0]+(s*e[a][0]-s*e[a+2][0])/6,e[a+1][1]+(s*e[a][1]-s*e[a+2][1])/6],o[3]=[e[a+1][0],e[a+1][1]],i.push({op:"bcurveTo",data:[o[1][0],o[1][1],o[2][0],o[2][1],o[3][0],o[3][1]]})}}else r===3?(i.push({op:"move",data:[e[1][0],e[1][1]]}),i.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):r===2&&i.push(...Qu(e[0][0],e[0][1],e[1][0],e[1][1],n,!0,!0));return i}function g_(e,t,n,r,i,o,s,a){const l=[],c=[];if(a.roughness===0){e/=4,c.push([t+r*Math.cos(-e),n+i*Math.sin(-e)]);for(let u=0;u<=2*Math.PI;u+=e){const h=[t+r*Math.cos(u),n+i*Math.sin(u)];l.push(h),c.push(h)}c.push([t+r*Math.cos(0),n+i*Math.sin(0)]),c.push([t+r*Math.cos(e),n+i*Math.sin(e)])}else{const u=Re(.5,a)-Math.PI/2;c.push([Re(o,a)+t+.9*r*Math.cos(u-e),Re(o,a)+n+.9*i*Math.sin(u-e)]);const h=2*Math.PI+u-.01;for(let f=u;f<h;f+=e){const d=[Re(o,a)+t+r*Math.cos(f),Re(o,a)+n+i*Math.sin(f)];l.push(d),c.push(d)}c.push([Re(o,a)+t+r*Math.cos(u+2*Math.PI+.5*s),Re(o,a)+n+i*Math.sin(u+2*Math.PI+.5*s)]),c.push([Re(o,a)+t+.98*r*Math.cos(u+s),Re(o,a)+n+.98*i*Math.sin(u+s)]),c.push([Re(o,a)+t+.9*r*Math.cos(u+.5*s),Re(o,a)+n+.9*i*Math.sin(u+.5*s)])}return[c,l]}function m_(e,t,n,r,i,o,s,a,l){const c=o+Re(.1,l),u=[];u.push([Re(a,l)+t+.9*r*Math.cos(c-e),Re(a,l)+n+.9*i*Math.sin(c-e)]);for(let h=c;h<=s;h+=e)u.push([Re(a,l)+t+r*Math.cos(h),Re(a,l)+n+i*Math.sin(h)]);return u.push([t+r*Math.cos(s),n+i*Math.sin(s)]),u.push([t+r*Math.cos(s),n+i*Math.sin(s)]),oa(u,null,l)}function sq(e,t,n,r,i,o,s,a){const l=[],c=[a.maxRandomnessOffset||1,(a.maxRandomnessOffset||1)+.3];let u=[0,0];const h=a.disableMultiStroke?1:2,f=a.preserveVertices;for(let d=0;d<h;d++)d===0?l.push({op:"move",data:[s[0],s[1]]}):l.push({op:"move",data:[s[0]+(f?0:Re(c[0],a)),s[1]+(f?0:Re(c[0],a))]}),u=f?[i,o]:[i+Re(c[d],a),o+Re(c[d],a)],l.push({op:"bcurveTo",data:[e+Re(c[d],a),t+Re(c[d],a),n+Re(c[d],a),r+Re(c[d],a),u[0],u[1]]});return l}function wo(e){return[...e]}function y_(e,t=0){const n=e.length;if(n<3)throw new Error("A curve must have at least three points.");const r=[];if(n===3)r.push(wo(e[0]),wo(e[1]),wo(e[2]),wo(e[2]));else{const i=[];i.push(e[0],e[0]);for(let a=1;a<e.length;a++)i.push(e[a]),a===e.length-1&&i.push(e[a]);const o=[],s=1-t;r.push(wo(i[0]));for(let a=1;a+2<i.length;a++){const l=i[a];o[0]=[l[0],l[1]],o[1]=[l[0]+(s*i[a+1][0]-s*i[a-1][0])/6,l[1]+(s*i[a+1][1]-s*i[a-1][1])/6],o[2]=[i[a+1][0]+(s*i[a][0]-s*i[a+2][0])/6,i[a+1][1]+(s*i[a][1]-s*i[a+2][1])/6],o[3]=[i[a+1][0],i[a+1][1]],r.push(o[1],o[2],o[3])}}return r}function sa(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function aq(e,t,n){const r=sa(t,n);if(r===0)return sa(e,t);let i=((e[0]-t[0])*(n[0]-t[0])+(e[1]-t[1])*(n[1]-t[1]))/r;return i=Math.max(0,Math.min(1,i)),sa(e,Tr(t,n,i))}function Tr(e,t,n){return[e[0]+(t[0]-e[0])*n,e[1]+(t[1]-e[1])*n]}function Ju(e,t,n,r){const i=r||[];if((function(a,l){const c=a[l+0],u=a[l+1],h=a[l+2],f=a[l+3];let d=3*u[0]-2*c[0]-f[0];d*=d;let p=3*u[1]-2*c[1]-f[1];p*=p;let g=3*h[0]-2*f[0]-c[0];g*=g;let m=3*h[1]-2*f[1]-c[1];return m*=m,d<g&&(d=g),p<m&&(p=m),d+p})(e,t)<n){const a=e[t+0];i.length?(o=i[i.length-1],s=a,Math.sqrt(sa(o,s))>1&&i.push(a)):i.push(a),i.push(e[t+3])}else{const l=e[t+0],c=e[t+1],u=e[t+2],h=e[t+3],f=Tr(l,c,.5),d=Tr(c,u,.5),p=Tr(u,h,.5),g=Tr(f,d,.5),m=Tr(d,p,.5),v=Tr(g,m,.5);Ju([l,f,g,v],0,n,i),Ju([v,m,p,h],0,n,i)}var o,s;return i}function lq(e,t){return aa(e,0,e.length,t)}function aa(e,t,n,r,i){const o=i||[],s=e[t],a=e[n-1];let l=0,c=1;for(let u=t+1;u<n-1;++u){const h=aq(e[u],s,a);h>l&&(l=h,c=u)}return Math.sqrt(l)>r?(aa(e,t,c+1,r,o),aa(e,c,n,r,o)):(o.length||o.push(s),o.push(a)),o}function eh(e,t=.15,n){const r=[],i=(e.length-1)/3;for(let o=0;o<i;o++)Ju(e,3*o,t,r);return n&&n>0?aa(r,0,r.length,n):r}const ln="none";class la{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*ds(2,31))}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,n,r){return{shape:t,sets:n||[],options:r||this.defaultOptions}}line(t,n,r,i,o){const s=this._o(o);return this._d("line",[l_(t,n,r,i,s)],s)}rectangle(t,n,r,i,o){const s=this._o(o),a=[],l=oq(t,n,r,i,s);if(s.fill){const c=[[t,n],[t+r,n],[t+r,n+i],[t,n+i]];s.fillStyle==="solid"?a.push(Zu([c],s)):a.push(bi([c],s))}return s.stroke!==ln&&a.push(l),this._d("rectangle",a,s)}ellipse(t,n,r,i,o){const s=this._o(o),a=[],l=u_(r,i,s),c=Ku(t,n,s,l);if(s.fill)if(s.fillStyle==="solid"){const u=Ku(t,n,s,l).opset;u.type="fillPath",a.push(u)}else a.push(bi([c.estimatedPoints],s));return s.stroke!==ln&&a.push(c.opset),this._d("ellipse",a,s)}circle(t,n,r,i){const o=this.ellipse(t,n,r,r,i);return o.shape="circle",o}linearPath(t,n){const r=this._o(n);return this._d("linearPath",[na(t,!1,r)],r)}arc(t,n,r,i,o,s,a=!1,l){const c=this._o(l),u=[],h=h_(t,n,r,i,o,s,a,!0,c);if(a&&c.fill)if(c.fillStyle==="solid"){const f=Object.assign({},c);f.disableMultiStroke=!0;const d=h_(t,n,r,i,o,s,!0,!1,f);d.type="fillPath",u.push(d)}else u.push((function(f,d,p,g,m,v,b){const _=f,x=d;let w=Math.abs(p/2),C=Math.abs(g/2);w+=Re(.01*w,b),C+=Re(.01*C,b);let P=m,O=v;for(;P<0;)P+=2*Math.PI,O+=2*Math.PI;O-P>2*Math.PI&&(P=0,O=2*Math.PI);const $=(O-P)/b.curveStepCount,S=[];for(let M=P;M<=O;M+=$)S.push([_+w*Math.cos(M),x+C*Math.sin(M)]);return S.push([_+w*Math.cos(O),x+C*Math.sin(O)]),S.push([_,x]),bi([S],b)})(t,n,r,i,o,s,c));return c.stroke!==ln&&u.push(h),this._d("arc",u,c)}curve(t,n){const r=this._o(n),i=[],o=c_(t,r);if(r.fill&&r.fill!==ln)if(r.fillStyle==="solid"){const s=c_(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(s.ops)})}else{const s=[],a=t;if(a.length){const l=typeof a[0][0]=="number"?[a]:a;for(const c of l)c.length<3?s.push(...c):c.length===3?s.push(...eh(y_([c[0],c[0],c[1],c[2]]),10,(1+r.roughness)/2)):s.push(...eh(y_(c),10,(1+r.roughness)/2))}s.length&&i.push(bi([s],r))}return r.stroke!==ln&&i.push(o),this._d("curve",i,r)}polygon(t,n){const r=this._o(n),i=[],o=na(t,!0,r);return r.fill&&(r.fillStyle==="solid"?i.push(Zu([t],r)):i.push(bi([t],r))),r.stroke!==ln&&i.push(o),this._d("polygon",i,r)}path(t,n){const r=this._o(n),i=[];if(!t)return this._d("path",i,r);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const o=r.fill&&r.fill!=="transparent"&&r.fill!==ln,s=r.stroke!==ln,a=!!(r.simplification&&r.simplification<1),l=(function(u,h,f){const d=s_(o_(Uu(u))),p=[];let g=[],m=[0,0],v=[];const b=()=>{v.length>=4&&g.push(...eh(v,h)),v=[]},_=()=>{b(),g.length&&(p.push(g),g=[])};for(const{key:w,data:C}of d)switch(w){case"M":_(),m=[C[0],C[1]],g.push(m);break;case"L":b(),g.push([C[0],C[1]]);break;case"C":if(!v.length){const P=g.length?g[g.length-1]:m;v.push([P[0],P[1]])}v.push([C[0],C[1]]),v.push([C[2],C[3]]),v.push([C[4],C[5]]);break;case"Z":b(),g.push([m[0],m[1]])}if(_(),!f)return p;const x=[];for(const w of p){const C=lq(w,f);C.length&&x.push(C)}return x})(t,1,a?4-4*(r.simplification||1):(1+r.roughness)/2),c=f_(t,r);if(o)if(r.fillStyle==="solid")if(l.length===1){const u=f_(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(u.ops)})}else i.push(Zu(l,r));else i.push(bi(l,r));return s&&(a?l.forEach((u=>{i.push(na(u,!1,r))})):i.push(c)),this._d("path",i,r)}opsToPath(t,n){let r="";for(const i of t.ops){const o=typeof n=="number"&&n>=0?i.data.map((s=>+s.toFixed(n))):i.data;switch(i.op){case"move":r+=`M${o[0]} ${o[1]} `;break;case"bcurveTo":r+=`C${o[0]} ${o[1]}, ${o[2]} ${o[3]}, ${o[4]} ${o[5]} `;break;case"lineTo":r+=`L${o[0]} ${o[1]} `}}return r.trim()}toPaths(t){const n=t.sets||[],r=t.options||this.defaultOptions,i=[];for(const o of n){let s=null;switch(o.type){case"path":s={d:this.opsToPath(o),stroke:r.stroke,strokeWidth:r.strokeWidth,fill:ln};break;case"fillPath":s={d:this.opsToPath(o),stroke:ln,strokeWidth:0,fill:r.fill||ln};break;case"fillSketch":s=this.fillSketch(o,r)}s&&i.push(s)}return i}fillSketch(t,n){let r=n.fillWeight;return r<0&&(r=n.strokeWidth/2),{d:this.opsToPath(t),stroke:n.fill||ln,strokeWidth:r,fill:ln}}_mergedShape(t){return t.filter(((n,r)=>r===0||n.op!=="move"))}}class cq{constructor(t,n){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new la(n)}draw(t){const n=t.sets||[],r=t.options||this.getDefaultOptions(),i=this.ctx,o=t.options.fixedDecimalPlaceDigits;for(const s of n)switch(s.type){case"path":i.save(),i.strokeStyle=r.stroke==="none"?"transparent":r.stroke,i.lineWidth=r.strokeWidth,r.strokeLineDash&&i.setLineDash(r.strokeLineDash),r.strokeLineDashOffset&&(i.lineDashOffset=r.strokeLineDashOffset),this._drawToContext(i,s,o),i.restore();break;case"fillPath":{i.save(),i.fillStyle=r.fill||"";const a=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(i,s,o,a),i.restore();break}case"fillSketch":this.fillSketch(i,s,r)}}fillSketch(t,n,r){let i=r.fillWeight;i<0&&(i=r.strokeWidth/2),t.save(),r.fillLineDash&&t.setLineDash(r.fillLineDash),r.fillLineDashOffset&&(t.lineDashOffset=r.fillLineDashOffset),t.strokeStyle=r.fill||"",t.lineWidth=i,this._drawToContext(t,n,r.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,n,r,i="nonzero"){t.beginPath();for(const o of n.ops){const s=typeof r=="number"&&r>=0?o.data.map((a=>+a.toFixed(r))):o.data;switch(o.op){case"move":t.moveTo(s[0],s[1]);break;case"bcurveTo":t.bezierCurveTo(s[0],s[1],s[2],s[3],s[4],s[5]);break;case"lineTo":t.lineTo(s[0],s[1])}}n.type==="fillPath"?t.fill(i):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,n,r,i,o){const s=this.gen.line(t,n,r,i,o);return this.draw(s),s}rectangle(t,n,r,i,o){const s=this.gen.rectangle(t,n,r,i,o);return this.draw(s),s}ellipse(t,n,r,i,o){const s=this.gen.ellipse(t,n,r,i,o);return this.draw(s),s}circle(t,n,r,i){const o=this.gen.circle(t,n,r,i);return this.draw(o),o}linearPath(t,n){const r=this.gen.linearPath(t,n);return this.draw(r),r}polygon(t,n){const r=this.gen.polygon(t,n);return this.draw(r),r}arc(t,n,r,i,o,s,a=!1,l){const c=this.gen.arc(t,n,r,i,o,s,a,l);return this.draw(c),c}curve(t,n){const r=this.gen.curve(t,n);return this.draw(r),r}path(t,n){const r=this.gen.path(t,n);return this.draw(r),r}}const ca="http://www.w3.org/2000/svg";class uq{constructor(t,n){this.svg=t,this.gen=new la(n)}draw(t){const n=t.sets||[],r=t.options||this.getDefaultOptions(),i=this.svg.ownerDocument||window.document,o=i.createElementNS(ca,"g"),s=t.options.fixedDecimalPlaceDigits;for(const a of n){let l=null;switch(a.type){case"path":l=i.createElementNS(ca,"path"),l.setAttribute("d",this.opsToPath(a,s)),l.setAttribute("stroke",r.stroke),l.setAttribute("stroke-width",r.strokeWidth+""),l.setAttribute("fill","none"),r.strokeLineDash&&l.setAttribute("stroke-dasharray",r.strokeLineDash.join(" ").trim()),r.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${r.strokeLineDashOffset}`);break;case"fillPath":l=i.createElementNS(ca,"path"),l.setAttribute("d",this.opsToPath(a,s)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",r.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(i,a,r)}l&&o.appendChild(l)}return o}fillSketch(t,n,r){let i=r.fillWeight;i<0&&(i=r.strokeWidth/2);const o=t.createElementNS(ca,"path");return o.setAttribute("d",this.opsToPath(n,r.fixedDecimalPlaceDigits)),o.setAttribute("stroke",r.fill||""),o.setAttribute("stroke-width",i+""),o.setAttribute("fill","none"),r.fillLineDash&&o.setAttribute("stroke-dasharray",r.fillLineDash.join(" ").trim()),r.fillLineDashOffset&&o.setAttribute("stroke-dashoffset",`${r.fillLineDashOffset}`),o}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,n){return this.gen.opsToPath(t,n)}line(t,n,r,i,o){const s=this.gen.line(t,n,r,i,o);return this.draw(s)}rectangle(t,n,r,i,o){const s=this.gen.rectangle(t,n,r,i,o);return this.draw(s)}ellipse(t,n,r,i,o){const s=this.gen.ellipse(t,n,r,i,o);return this.draw(s)}circle(t,n,r,i){const o=this.gen.circle(t,n,r,i);return this.draw(o)}linearPath(t,n){const r=this.gen.linearPath(t,n);return this.draw(r)}polygon(t,n){const r=this.gen.polygon(t,n);return this.draw(r)}arc(t,n,r,i,o,s,a=!1,l){const c=this.gen.arc(t,n,r,i,o,s,a,l);return this.draw(c)}curve(t,n){const r=this.gen.curve(t,n);return this.draw(r)}path(t,n){const r=this.gen.path(t,n);return this.draw(r)}}var hq={canvas:(e,t)=>new cq(e,t),svg:(e,t)=>new uq(e,t),generator:e=>new la(e),newSeed:()=>la.newSeed()},fq=Object.defineProperty,v_=Object.getOwnPropertySymbols,dq=Object.prototype.hasOwnProperty,pq=Object.prototype.propertyIsEnumerable,b_=(e,t,n)=>t in e?fq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gq=(e,t)=>{for(var n in t||(t={}))dq.call(t,n)&&b_(e,n,t[n]);if(v_)for(var n of v_(t))pq.call(t,n)&&b_(e,n,t[n]);return e};function mq(e,t,n){if(!e||!t){console.warn("Invalid node or svg element");return}const r=hq.svg(t,{options:{seed:1e3}}),i=Me("g");e.hasAttribute("transform")&&i.setAttribute("transform",e.getAttribute("transform")||"");const o=e.cloneNode();ut(o,{opacity:.5}),o.hasAttribute("transform")&&o.removeAttribute("transform"),o.dataset.elementType="rough-volume",i.appendChild(o);const s=vq(r,e,n);if(s){const{element:l,svgAttributes:c}=s;l.dataset.elementType="rough-element",l.style.pointerEvents="none",yq(l,c),i.appendChild(l)}e.id&&(i.id=e.id),Array.from(e.classList).forEach(l=>{i.classList.contains(l)||i.classList.add(l)}),Array.from(e.attributes).forEach(l=>{l.name.startsWith("data-")&&i.setAttribute(l.name,l.value)}),i.childElementCount>0?e.replaceWith(i):e.remove()}function yq(e,t){t.opacity!==void 0&&e.setAttribute("opacity",String(t.opacity)),t.fillOpacity!==void 0&&e.setAttribute("fill-opacity",String(t.fillOpacity)),t.strokeOpacity!==void 0&&e.setAttribute("stroke-opacity",String(t.strokeOpacity)),t.strokeLinecap&&e.setAttribute("stroke-linecap",t.strokeLinecap),t.strokeLinejoin&&e.setAttribute("stroke-linejoin",t.strokeLinejoin),t.strokeDasharray&&e.setAttribute("stroke-dasharray",t.strokeDasharray),t.filter&&e.setAttribute("filter",t.filter),t.clipPath&&e.setAttribute("clip-path",t.clipPath),t.mask&&e.setAttribute("mask",t.mask)}function vq(e,t,n){const r=t.nodeName.toLowerCase(),i=(o,s)=>{const a=cn(o,[...s,"fill","fill-opacity","stroke","stroke-opacity","stroke-width","stroke-dasharray","stroke-linecap","stroke-linejoin","opacity","filter","clip-path","mask"],!0),l={},c=gq({},n),u={};s.forEach(P=>{a[P]!==void 0&&(l[P]=a[P])});const{fill:h,"fill-opacity":f,stroke:d,"stroke-opacity":p,"stroke-width":g,"stroke-dasharray":m,"stroke-linecap":v,"stroke-linejoin":b,opacity:_,filter:x,"clip-path":w,mask:C}=a;if(c.fill=h||"none",c.stroke=d||(h&&h!=="none"?h:"currentColor"),g&&(c.strokeWidth=parseFloat(g)),m&&m!=="none"){const P=m.split(/[\s,]+/).map(O=>parseFloat(O)).filter(O=>!isNaN(O));P.length>0&&(c.strokeLineDash=P)}return f&&(u.fillOpacity=parseFloat(f)),p&&(u.strokeOpacity=parseFloat(p)),_&&(u.opacity=parseFloat(_)),v&&(u.strokeLinecap=v),b&&(u.strokeLinejoin=b),m&&m!=="none"&&(u.strokeDasharray=m),x&&(u.filter=x),w&&(u.clipPath=w),C&&(u.mask=C),[l,c,u]};try{let o=null,s={};switch(r){case"circle":{const[a,l,c]=i(t,["cx","cy","r"]),u=parseFloat(a.cx)||0,h=parseFloat(a.cy)||0,f=parseFloat(a.r)||0;o=e.circle(u,h,f*2,l),s=c;break}case"ellipse":{const[a,l,c]=i(t,["cx","cy","rx","ry"]),u=parseFloat(a.cx)||0,h=parseFloat(a.cy)||0,f=parseFloat(a.rx)||0,d=parseFloat(a.ry)||0;o=e.ellipse(u,h,f*2,d*2,l),s=c;break}case"line":{const[a,l,c]=i(t,["x1","y1","x2","y2"]),u=parseFloat(a.x1)||0,h=parseFloat(a.y1)||0,f=parseFloat(a.x2)||0,d=parseFloat(a.y2)||0;o=e.line(u,h,f,d,l),s=c;break}case"rect":{const[a,l,c]=i(t,["x","y","width","height","rx","ry"]),u=parseFloat(a.x)||0,h=parseFloat(a.y)||0,f=parseFloat(a.width)||0,d=parseFloat(a.height)||0,p=parseFloat(a.rx)||0,g=parseFloat(a.ry)||0;if(p>0||g>0){const b=bq(u,h,f,d,p||g,g||p);o=e.path(b,l)}else o=e.rectangle(u,h,f,d,l);s=c;break}case"path":{const[a,l,c]=i(t,["d"]),u=a.d||"";if(!u)return console.warn("Path element has no d attribute"),null;o=e.path(u,l),s=c;break}case"polygon":{const[a,l,c]=i(t,["points"]),u=__(a.points||"");if(u.length<3)return console.warn("Polygon needs at least 3 points"),null;o=e.polygon(u,l),s=c;break}case"polyline":{const[a,l,c]=i(t,["points"]),u=__(a.points||"");if(u.length<2)return console.warn("Polyline needs at least 2 points"),null;o=e.linearPath(u,l),s=c;break}default:return console.warn(`Unsupported shape type: ${r}`),null}return o?{element:o,svgAttributes:s}:null}catch(o){return console.error(`Error creating rough shape for ${r}:`,o),null}}function bq(e,t,n,r,i,o){return i=Math.min(i,n/2),o=Math.min(o,r/2),`
|
|
15
15
|
M ${e+i} ${t}
|
|
16
16
|
L ${e+n-i} ${t}
|
|
17
17
|
A ${i} ${o} 0 0 1 ${e+n} ${t+o}
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
L ${e} ${t+o}
|
|
23
23
|
A ${i} ${o} 0 0 1 ${e+i} ${t}
|
|
24
24
|
Z
|
|
25
|
-
`.replace(/\s+/g," ").trim()}function
|
|
25
|
+
`.replace(/\s+/g," ").trim()}function __(e){if(!e||typeof e!="string")return[];try{const n=e.trim().replace(/,/g," ").replace(/\s+/g," ").split(" ").filter(Boolean),r=[];for(let i=0;i<n.length-1;i+=2){const o=parseFloat(n[i]),s=parseFloat(n[i+1]);if(isNaN(o)||isNaN(s)){console.warn(`Invalid coordinate pair at index ${i}: "${n[i]}", "${n[i+1]}"`);continue}r.push([o,s])}return n.length%2!==0&&console.warn(`Odd number of coordinates in points attribute, last value ignored: "${n[n.length-1]}"`),r}catch(t){return console.error("Failed to parse polygon points:",e,t),[]}}function w_(e,t,n){var r;const{themeConfig:i}=n,o=Object.assign({},(r=i.base)==null?void 0:r.shape,i.shape),s=go(t,o);return ut(t,s),wq(t,e,n),t}function _q(e,t){var n;ut(e,((n=t.themeConfig.base)==null?void 0:n.shape)||{})}function wq(e,t,n){const r=n.themeConfig.stylize;if(!r)return e;const{type:i}=r;if(!i)return e;if(i==="rough")return mq(e,t,r);if(i==="pattern")return GD(e,t,n);if(i==="linear-gradient"||i==="radial-gradient"){const{fill:o,stroke:s}=cn(e,["fill","stroke"]);Pr(o)&&Qb(e,t,r,"fill"),Pr(s)&&Qb(e,t,r,"stroke");return}}function xq(e,t){var n;const{themeConfig:r}=t,{"font-family":i=ku}=((n=r.base)==null?void 0:n.text)||{};e.setAttribute("font-family",i)}function th(e,t,n={}){if(!t)return null;const r=e,i=go(r,n);ut(r,i);const o=Oq(t,r);for(const s in r.dataset)o.setAttribute(`data-${QN(s)}`,r.dataset[s]);return o}function Cq(e,t,n){var r,i,o;const s=t.nodeName==="text"?t:null;if(!s)return null;const{data:a,themeConfig:l}=n,c=N_(t.dataset.indexes||"0"),u=uo(a,c),h=String(fv(u,e,"")),f=(r=u==null?void 0:u.attributes)==null?void 0:r[e],d=Object.assign({},(i=l.base)==null?void 0:i.text,(o=l.item)==null?void 0:o[e],f),p=go(s,d);return th(t,t.textContent||h,p)}function Pq(e,t){var n;const r=((n=t.themeConfig.base)==null?void 0:n.text)||{};ut(e,r),r["font-family"]&&e.setAttribute("font-family",Ar(r["font-family"])),e.style.userSelect="none",e.style.pointerEvents="none"}const ua=(e,t)=>e?parseFloat(e):t;function Oq(e,t){const n=ua(t.dataset.x,0),r=ua(t.dataset.y,0),i=ua(t.getAttribute("width")),o=ua(t.getAttribute("height")),s=Sq(t);return Object.assign(s,{x:n,y:r,width:i,height:o,"data-horizontal-align":t.dataset.horizontalAlign||"LEFT","data-vertical-align":t.dataset.verticalAlign||"TOP"}),Fq(e,s)}function Sq(e){return cn(e,["font-family","font-size","font-weight","font-style","font-variant","letter-spacing","line-height","fill","stroke","stroke-width"])}const Rr=(e,t)=>{e!==t&&(t?e.replaceWith(t):e.remove())};class $q{constructor(t,n){this.options=t,this.template=n,this.rendered=!1}getOptions(){return this.options}getSVG(){return this.template}render(){const t=this.getSVG();if(this.rendered)return t;Eq(t,this.options),t.style.visibility="hidden";const n=()=>{Aq(this.template,this.options),Oz(this.template),t.style.removeProperty("visibility")};if(uh)n();else{const r=new MutationObserver(i=>{i.forEach(o=>{o.addedNodes.forEach(s=>{(s===t||s.contains(t))&&(n(),r.disconnect())})})});try{r.observe(document,{childList:!0,subtree:!0})}catch(i){n(),console.error(i)}}return this.rendered=!0,t}}function Eq(e,t){Mq(e,t),Iq(e,t),$z(e,t)}function Mq(e,t){var n;const{themeConfig:r,data:i}=t;Ez(e,(n=r.base)==null?void 0:n.global),e.querySelectorAll("[data-element-type]").forEach(s=>{var a,l,c,u,h,f,d;const p=s.id||"";if(Gq(s)){const g=th(s,i.title||"",Object.assign({},(a=r.base)==null?void 0:a.text,r.title,(l=i.attributes)==null?void 0:l.title));return Rr(s,g)}if(Yq(s)){const g=th(s,i.desc||"",Object.assign({},(c=r.base)==null?void 0:c.text,r.desc,(u=i.attributes)==null?void 0:u.desc));return Rr(s,g)}if(Kq(s)){const g=jb(e,s,(h=i.illus)==null?void 0:h[p],void 0,(f=i.attributes)==null?void 0:f.illus);return Rr(s,g)}if(Uq(s))return Array.from(s.children).forEach(g=>{w_(e,g,t)});if(Xq(s)){const g=w_(e,s,t);return Rr(s,g)}if(iH(s))return Mz(e,s);if((d=s.dataset.elementType)!=null&&d.startsWith("item-")){const g=N_(s.dataset.indexes||"0"),m=s.dataset.elementType.replace("item-",""),v=uo(i,g);if(Jq(s)||eH(s)||tH(s)){const b=Cq(m,s,t);return Rr(s,b)}if(!v)return;if(nH(s)){const b=lD(e,s,v);return Rr(s,b)}if(oh(s)){const b=nD(e,s,v,t);return Rr(s,b)}}if(Zq(s))return Pq(s,t);if(!Qq(s))return _q(s,t)}),xq(e,t)}function Iq(e,t){const{width:n,height:r}=t,{style:i={},attributes:o={},id:s,className:a}=t.svg||{};s&&(e.id=s),a&&e.classList.add(a),n!==void 0&&e.setAttribute("width",typeof n=="number"?`${n}px`:n),r!==void 0&&e.setAttribute("height",typeof r=="number"?`${r}px`:r),Object.assign(e.style,i),ut(e,o)}function Aq(e,t){const{padding:n=0,viewBox:r}=t;r?e.setAttribute("viewBox",r):n!==void 0&&z_(e,Lr(n))}let x_;function Tq(){if(x_)return!0;if(typeof window=="undefined"||typeof document=="undefined")return!1;const e=document.body;if(!e)return!1;let t=!1;try{const r=document.createElement("div");r.style.cssText=`
|
|
26
26
|
position: absolute;
|
|
27
27
|
left: 11px;
|
|
28
28
|
top: 13px;
|
|
@@ -32,120 +32,120 @@
|
|
|
32
32
|
margin: 0;
|
|
33
33
|
border: 0;
|
|
34
34
|
visibility: hidden;
|
|
35
|
-
`,e.appendChild(r),r.offsetHeight;const i=r.getBoundingClientRect();e.removeChild(r),t=i.width===37&&i.height===19&&i.left!==0&&i.top!==0}catch(r){t=!1}if(!t)return!1;let n=!1;try{const r=document.createElement("canvas");r.width=100,r.height=50;const i=r.getContext("2d");if(!i)return!1;i.font="20px sans-serif";const o=i.measureText("Hello");n=typeof o.width=="number"&&o.width>0&&o.width<1e3}catch(r){n=!1}return n&&(
|
|
36
|
-
${o(u)}${
|
|
35
|
+
`,e.appendChild(r),r.offsetHeight;const i=r.getBoundingClientRect();e.removeChild(r),t=i.width===37&&i.height===19&&i.left!==0&&i.top!==0}catch(r){t=!1}if(!t)return!1;let n=!1;try{const r=document.createElement("canvas");r.width=100,r.height=50;const i=r.getContext("2d");if(!i)return!1;i.font="20px sans-serif";const o=i.measureText("Hello");n=typeof o.width=="number"&&o.width>0&&o.width<1e3}catch(r){n=!1}return n&&(x_=n),n}let nh=1.01;const Rq=e=>{nh=e};az(fz);let ha=null,tn=null;function kq(){return ha||(ha=document.createElement("canvas").getContext("2d"),ha)}function Lq(){return document.body?tn||(tn=document.createElement("span"),tn.style.position="absolute",tn.style.top="-10000px",tn.style.left="-10000px",tn.style.visibility="hidden",tn.style.pointerEvents="none",tn.style.whiteSpace="pre",tn.style.display="inline-block",tn.style.padding="0",tn.style.margin="0",document.body.appendChild(tn),tn):null}function Nq(e,t){if(t==null)return e*1.4;if(typeof t=="string"){const n=t.trim();if(n.endsWith("px")){const r=Number.parseFloat(n);return Number.isFinite(r)?r:e*1.4}t=Number(n)}return typeof t!="number"||!Number.isFinite(t)?e*1.4:t>4?t:t*e}function zq(e,{fontFamily:t,fontSize:n,fontWeight:r,lineHeight:i}){const o=e.split(/\r?\n/),s=Ar(t),a=r||"normal",l=Nq(n,i),c=kq();if(c)return c.font=`${a} ${n}px ${s}`,{width:o.reduce((d,p)=>{const g=c.measureText(p);return Math.max(d,g.width)},0),height:l*Math.max(o.length,1)};const u=Lq();if(!u)return null;u.style.fontFamily=s,u.style.fontSize=`${n}px`,u.style.fontWeight=String(a),u.style.lineHeight=`${l}px`,u.textContent=e;const h=u.getBoundingClientRect();return{width:h.width,height:h.height}}function C_(e="",t){var n;if(t.width&&t.height)return{width:t.width,height:t.height};if(typeof e!="string"&&typeof e!="number")return{width:0,height:0};const{fontFamily:r=ku,fontSize:i=14,fontWeight:o="normal",lineHeight:s=1.4}=t,a=e.toString(),l={fontFamily:r,fontSize:parseFloat(i.toString()),fontWeight:o,lineHeight:s},c=()=>hz(a,l),u=Tq()&&(n=zq(a,l))!=null?n:c();return{width:Math.ceil(u.width*nh),height:Math.ceil(u.height*nh)}}function Me(e,t={}){const n=document.createElementNS("http://www.w3.org/2000/svg",e);return ut(n,t),n}function _i(e){const n=new DOMParser().parseFromString(e,"image/svg+xml");if(n.querySelector("parsererror"))throw new Error("Invalid SVG string");return n.documentElement}function ut(e,t){Object.entries(t).forEach(([n,r])=>{r==null?e.removeAttribute(n):e.setAttribute(n,r)})}function cn(e,t,n=!0){return t.reduce((r,i)=>{const o=e.getAttribute(i);return(!n||o!==null&&o!==""&&o!==void 0)&&(r[i]=o),r},{})}function Dq(e,t){t.forEach(n=>{e.removeAttribute(n)})}function wi(e,t){if(t(e)===!1)return;Array.from(e.children).forEach(r=>{wi(r,t)})}function fa(e,t="infographic-defs"){const n=t?`defs#${t}`:"defs",r=e.querySelector(n);if(r)return r;const i=Me("defs");return t&&(i.id=t),e.prepend(i),i}var P_=Object.getOwnPropertySymbols,qq=Object.prototype.hasOwnProperty,Hq=Object.prototype.propertyIsEnumerable,jq=(e,t)=>{var n={};for(var r in e)qq.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&P_)for(var r of P_(e))t.indexOf(r)<0&&Hq.call(e,r)&&(n[r]=e[r]);return n};function kr(e){return $_(e)?e.querySelector("span"):null}function Fq(e,t){const n=document.createElement("span");n.setAttribute("xmlns","http://www.w3.org/1999/xhtml");const r=Me("foreignObject",{overflow:"visible"});return r.appendChild(n),O_(r,{textContent:e,attributes:t}),r}function O_(e,t){const{textContent:n,attributes:r}=t;if(n!==void 0&&rh(e,n),!r)return;const i=kr(e);let{width:o,height:s}=r;const a={};if(i){if(Object.assign(i.style,Wq(r)),!o||!s){const d=n!=null?n:da(e),{fontFamily:p,fontSize:g,fontWeight:m,lineHeight:v}=i.style,b=g?parseFloat(String(g)):12,_=C_(d,{fontFamily:p,fontSize:b,fontWeight:m,lineHeight:v.endsWith("px")?parseFloat(v):(parseFloat(v)||1.4)*b});!o&&!e.hasAttribute("width")&&(o=String(_.width)),!s&&!e.hasAttribute("height")&&(s=String(_.height))}const{"data-horizontal-align":h,"data-vertical-align":f}=r;Object.assign(i.style,Bq(h,f))}const{id:l,x:c,y:u}=r;l&&(a.id=l),c!==void 0&&(a.x=String(c)),u!==void 0&&(a.y=String(u)),o!==void 0&&(a.width=String(o)),s!==void 0&&(a.height=String(s)),ut(e,a)}function Bq(e,t){const n={width:"100%",height:"100%",display:"flex",flexWrap:"wrap",wordBreak:"break-word",whiteSpace:"pre-wrap"};switch(e){case"LEFT":n.textAlign="left",n.justifyContent="flex-start";break;case"CENTER":n.textAlign="center",n.justifyContent="center";break;case"RIGHT":n.textAlign="right",n.justifyContent="flex-end";break}switch(t){case"TOP":n.alignContent="flex-start",n.alignItems="flex-start";break;case"MIDDLE":n.alignContent="center",n.alignItems="center";break;case"BOTTOM":n.alignContent="flex-end",n.alignItems="flex-end";break}return n}function Wq(e){const t=e,{x:n,y:r,width:i,height:o,["data-horizontal-align"]:s,["data-vertical-align"]:a,["font-size"]:l,["letter-spacing"]:c,["line-height"]:u,fill:h,["stroke-width"]:f,["text-anchor"]:d,["dominant-baseline"]:p,["font-family"]:g}=t,m=jq(t,["x","y","width","height","data-horizontal-align","data-vertical-align","font-size","letter-spacing","line-height","fill","stroke-width","text-anchor","dominant-baseline","font-family"]),v={overflow:"visible"};return h&&(v.color=h),Object.entries(m).forEach(([b,_])=>{v[bL(b)]=_}),l&&(v.fontSize=`${l}px`),u&&(v.lineHeight=typeof u=="string"&&u.endsWith("px")?u:+u),c&&(v.letterSpacing=`${c}px`),f&&(v.strokeWidth=`${f}px`),g&&(v.fontFamily=Ar(g)),v}function da(e){const t=kr(e);return t&&(t.innerText||t.textContent)||""}function rh(e,t){const n=kr(e);if(n)try{n.innerText=t}catch(r){n.textContent=t}}function ih(e){const t=kr(e);if(!t)return{};const{color:n,fontSize:r,fontFamily:i,justifyContent:o,alignContent:s,fontWeight:a}=t.style,[l,c]=Vq(o,s),u={"data-horizontal-align":l,"data-vertical-align":c};return i&&(u["font-family"]=gi(i)),a&&(u["font-weight"]=a),r&&(u["font-size"]=String(parseInt(r))),n&&(u.fill=n),{attributes:u,textContent:da(e)}}function Vq(e,t){let n="LEFT",r="TOP";switch(e){case"flex-start":n="LEFT";break;case"center":n="CENTER";break;case"flex-end":n="RIGHT";break}switch(t){case"flex-start":r="TOP";break;case"center":r="MIDDLE";break;case"flex-end":r="BOTTOM";break}return[n,r]}const Xt=(e,t)=>{var n;return((n=e==null?void 0:e.dataset)==null?void 0:n.elementType)===t},pa=(e,t)=>e.tagName.toLowerCase()===t.toLowerCase(),Gq=e=>Xt(e,"title"),Yq=e=>Xt(e,"desc"),Xq=e=>Xt(e,"shape"),Uq=e=>Xt(e,"shapes-group"),Kq=e=>Xt(e,"illus"),Zq=e=>e instanceof SVGElement&&pa(e,"text"),Qq=e=>e instanceof SVGElement&&pa(e,"g"),oh=e=>Xt(e,"item-icon"),S_=e=>Xt(e,"item-icon-group"),Jq=e=>Xt(e,"item-label"),eH=e=>Xt(e,"item-desc"),tH=e=>Xt(e,"item-value"),nH=e=>Xt(e,"item-illus"),rH=e=>Xt(e,"edit-area"),iH=e=>Xt(e,"btns-group"),oH=e=>Xt(e,"rough-element"),sH=e=>Xt(e,"rough-volume");function $_(e){return pa(e,"foreignObject")}function aH(e){return pa(e,"SPAN")}function Gn(e){const t=sh(e);return[Ge.Title,Ge.Desc,Ge.ItemLabel,Ge.ItemDesc].includes(t)}function E_(e){if(!e||!Gn(e))return!1;const t=kr(e);return t?t.hasAttribute("contenteditable"):!1}function lH(e){const t=e.tagName.toLowerCase();return["rect","circle","ellipse","line","polygon","polyline","path"].includes(t)}function fr(e){return oh(e)||S_(e)}function cH(e){let t=e;for(;t;){if(xi(t,Oc))return!0;t=t.parentElement}return!1}function xo(e,t){e.setAttribute("data-element-type",t)}function xi(e,t){return e.querySelector(`[data-element-type="${t}"]`)}function sh(e){return fr(e)?Ge.ItemIcon:e.getAttribute("data-element-type")||Ge.Unknown}function uH(e){var t,n,r,i=e;function o(a,l){++t>i&&(r=n,s(1),++t),n[a]=l}function s(a){t=0,n=Object.create(null),a||(r=Object.create(null))}return s(),{clear:s,has:function(a){return n[a]!==void 0||r[a]!==void 0},get:function(a){var l=n[a];if(l!==void 0)return l;if((l=r[a])!==void 0)return o(a,l),l},set:function(a,l){n[a]!==void 0?n[a]=l:o(a,l)}}}var M_=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});const I_=globalThis.fetch,ah=uH(1024),lh=new Map;function hH(e){const t=Array.from(e.headers.entries());return t.length===0?"":(t.sort(([n],[r])=>n.toLowerCase().localeCompare(r.toLowerCase())),t.map(([n,r])=>`${n.toLowerCase()}:${r}`).join("|"))}function fH(e){const t=hH(e);return t?`${e.method}:${e.url}:${t}`:`${e.method}:${e.url}`}function A_(e){return new Response(e.body.slice(0),e.init)}function dH(e,t){return M_(this,null,function*(){try{const n=yield I_(e),i={body:yield n.arrayBuffer(),init:{status:n.status,statusText:n.statusText,headers:Array.from(n.headers.entries())}};return n.ok&&ah.set(t,i),i}finally{lh.delete(t)}})}function ga(e,t){return M_(this,null,function*(){const n=new Request(e,t);if(n.method!=="GET")return I_(n);const r=fH(n);if(ah.has(r))return A_(ah.get(r));let i=lh.get(r);i||(i=dH(n,r),lh.set(r,i));const o=yield i;return A_(o)})}function pH(e,t={title:"信息图标题",desc:"信息图描述",items:"信息图的内容项",label:"项目标签文本",value:"项目数值内容",icon:"项目图标",illus:"项目插图",children:"子级项目(多层结构)"}){const{structure:n,items:r}=e,i=[],o=l=>" ".repeat(l);function s(l,c,u){const h=t[l];return h?`${o(u)}/** ${h} */
|
|
36
|
+
${o(u)}${l}: ${c};`:`${o(u)}${l}: ${c};`}function a(l,c){const u=r[l],h=[];for(const f of u){const d=f==="value"?"number":"string";h.push(s(f,d,c+1))}return r[l+1]&&h.push(s("children",`Array<${a(l+1,c+1)}>`,c+1)),`{
|
|
37
37
|
${h.join(`
|
|
38
38
|
`)}
|
|
39
|
-
${o(
|
|
40
|
-
`)}function Nb(e){let t=0;if(e.length===0)return t.toString();for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=(t<<5)-t+r,t=t&t}return Math.abs(t).toString()}var qD=Object.defineProperty,jD=Object.defineProperties,FD=Object.getOwnPropertyDescriptors,Db=Object.getOwnPropertySymbols,BD=Object.prototype.hasOwnProperty,WD=Object.prototype.propertyIsEnumerable,Hb=(e,t,n)=>t in e?qD(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,GD=(e,t)=>{for(var n in t||(t={}))BD.call(t,n)&&Hb(e,n,t[n]);if(Db)for(var n of Db(t))WD.call(t,n)&&Hb(e,n,t[n]);return e},VD=(e,t)=>jD(e,FD(t));const YD=new WeakMap;function XD(e,t={}){const n=Ee("use",VD(GD({},t),{href:Nv(e)}));return qb(n),YD.set(n,e),n}function qb(e){const{stroke:t,fill:n}=sn(e,["fill","stroke"]);e.style.color=n||t||"currentColor"}function ss(e){return e.tagName==="use"?e:e.querySelector("use")}function Gu(e){const t=ss(e);return t?sn(t,["width","height","x","y","width","height","fill","fill-opacity","stroke","opacity"]):{}}function UD(e,t,n){const r=ss(e);r&&(n&<(r,n),qb(r))}const Vu=!!(typeof process!="undefined"&&process.versions&&process.versions.node),KD=",",ZD=(e,t=KD)=>e.split(t).map(n=>parseInt(n,10)),jb=e=>ZD(e);function Yu(...e){return e.map(t=>t.replace(/^\/+|\/+$/g,"")).filter(t=>t.trim().length>0).join("/")}function Xu(e){const t=e.getAttribute("viewBox");if(t){const[a,s,c,l]=t.split(" ").map(Number);return{x:a,y:s,width:c,height:l}}const n=e.getAttribute("width"),r=e.getAttribute("height"),i=Number(n)||0,o=Number(r)||0;return{x:0,y:0,width:i,height:o}}function Ar(e){return e?typeof e=="number"?[e,e,e,e]:e.length===1?[e[0],e[0],e[0],e[0]]:e.length===2?[e[0],e[1],e[0],e[1]]:e.length===3?[e[0],e[1],e[2],e[1]]:e.length===4?[e[0],e[1],e[2],e[3]]:[0,0,0,0]:[0,0,0,0]}function Fb(e,t){if(Vu)Bb(e,t);else if(document.contains(e))Wb(e,t);else try{const n=new MutationObserver(r=>{r.forEach(i=>{i.addedNodes.forEach(o=>{(o===e||o.contains(e))&&(QD(e,()=>{Wb(e,t)}),n.disconnect())})})});n.observe(document,{childList:!0,subtree:!0})}catch(n){Bb(e,t)}}function Bb(e,t){const n=Xu(e),[r,i,o,a]=t;lt(e,{viewBox:`${n.x-a} ${n.y-r} ${n.width+a+i} ${n.height+r+o}`})}function Wb(e,t){const n=e.getBBox(),r=e.getBoundingClientRect(),i=r.width>0?n.width/r.width:1,o=r.height>0?n.height/r.height:1,[a,s,c,l]=t,u=a*o,h=s*i,d=c*o,f=l*i,g=n.x-f,y=n.y-u,m=n.width+f+h,v=n.height+u+d;lt(e,{viewBox:`${g} ${y} ${m} ${v}`})}function QD(e,t){requestAnimationFrame(()=>{const n=()=>{const r=e.getBoundingClientRect();r.width>0&&r.height>0?t():requestAnimationFrame(n)};n()})}function Sn(e,t){if(document.getElementById(e))return;const n=document.createElement("style");n.id=e,n.textContent=t,document.head.appendChild(n)}function JD(){return crypto&&crypto.randomUUID?crypto.randomUUID():"xxxx-xxxx-4xxx-yxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e==="x"?t:t&3|8).toString(16)})}var eH=Object.defineProperty,tH=Object.defineProperties,nH=Object.getOwnPropertyDescriptors,cs=Object.getOwnPropertySymbols,Gb=Object.prototype.hasOwnProperty,Vb=Object.prototype.propertyIsEnumerable,Yb=(e,t,n)=>t in e?eH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Vt=(e,t)=>{for(var n in t||(t={}))Gb.call(t,n)&&Yb(e,n,t[n]);if(cs)for(var n of cs(t))Vb.call(t,n)&&Yb(e,n,t[n]);return e},Uu=(e,t)=>tH(e,nH(t)),rH=(e,t)=>{var n={};for(var r in e)Gb.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&cs)for(var r of cs(e))t.indexOf(r)<0&&Vb.call(e,r)&&(n[r]=e[r]);return n};function ze(e){const t=e,{id:n,x:r=0,y:i=0,width:o,height:a,alignHorizontal:s="left",alignVertical:c="top",children:l,fontSize:u=14,fontFamily:h,fontStyle:d,fontWeight:f,textDecoration:g,letterSpacing:y,wordSpacing:m,opacity:v,fill:b="black",lineHeight:_,wordWrap:x,backgroundColor:w="none",backgroundOpacity:P=1,backgroundRadius:$=0}=t,C=rH(t,["id","x","y","width","height","alignHorizontal","alignVertical","children","fontSize","fontFamily","fontStyle","fontWeight","textDecoration","letterSpacing","wordSpacing","opacity","fill","lineHeight","wordWrap","backgroundColor","backgroundOpacity","backgroundRadius"]);let M=o,S=a,E=0,A=0;if(!M||!S){const B=Mb(l,e);M||(M=B.width),S||(S=B.height)}o&&(E=s==="center"?M/2:s==="right"?M:0),a&&(A=c==="middle"?S/2:c==="bottom"?S:0);const O=Object.entries(Vt(Vt({width:M,height:S},_!==void 0&&{"line-height":_}),x!==void 0&&{"data-word-wrap":x})).reduce((B,[X,H])=>Uu(Vt({},B),{[X]:H}),{}),z=Vt(Vt(Vt(Vt(Vt(Vt(Vt(Vt(Vt({"data-element-type":"text",width:M,height:S,x:E,y:A,"data-x":0,"data-y":0,fill:b,fontSize:u,textAnchor:s==="center"?"middle":s==="right"?"end":"start",dominantBaseline:c==="middle"?"central":c==="bottom"?"baseline":"hanging","data-horizontal-align":s.toUpperCase(),"data-vertical-align":c.toUpperCase(),children:l},O),C),h&&{fontFamily:h}),d&&{fontStyle:d}),f&&{fontWeight:f}),g&&g!=="none"&&{textDecoration:g}),y&&{letterSpacing:y}),m&&{wordSpacing:m}),v!==void 0&&v!==1&&{opacity:v}),j=Vt(Uu(Vt({},r!==0||i!==0?{x:r,y:i,transform:`translate(${r}, ${i})`}:{}),{width:M,height:S}),n&&{id:n}),W=w&&w!=="none"?{"data-element-type":"shape",x:0,y:0,width:M,height:S,fill:w,fillOpacity:P,rx:$,ry:$}:void 0;return{type:"g",props:Uu(Vt({},j),{children:[...W?[{type:"rect",props:W}]:[],{type:"text",props:z}]})}}const go=Symbol.for("@antv/infographic/Fragment");function ls(e,t={}){return{type:e,props:t}}function iH(e={}){return ls(go,e)}const oH=ls,aH=ls;function sH(e){return!e||typeof e!="object"||Array.isArray(e)?!1:e.type===go}function Xb(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&"type"in e}function mo(e){return yo(e).filter(Xb)}function yo(e,t=[]){var n;if(!e||typeof e=="boolean")return t;if(Array.isArray(e))e.forEach(r=>yo(r,t));else if(sH(e)){const r=(n=e.props)==null?void 0:n.children;(Array.isArray(r)?r:[r]).filter(Boolean).forEach(i=>{yo(i,t)})}else t.push(e);return t}function at(e){return typeof e=="number"&&!Number.isNaN(e)&&Number.isFinite(e)}const us=()=>({x:0,y:0,width:0,height:0});function yi(e){if(!e||e.length===0)return us();let t=1/0,n=1/0,r=-1/0,i=-1/0;for(const o of e){const{x:a,y:s,width:c,height:l}=o,u=a+c,h=s+l;a<t&&(t=a),s<n&&(n=s),u>r&&(r=u),h>i&&(i=h)}return t===1/0||n===1/0||r===-1/0||i===-1/0?{x:0,y:0,width:0,height:0}:{x:t,y:n,width:Math.max(0,r-t),height:Math.max(0,i-n)}}function se(e){var t,n,r,i;if(!e)return us();if(Array.isArray(e)){const f=mo(e);return Tr(f)}if(typeof e!="object")return us();const{type:o,props:a={}}=e;if(th(e)){const f=t_(e);return se(f)}if(typeof o=="function"){const f=(t=a.x)!=null?t:0,g=(n=a.y)!=null?n:0,y=a.width,m=a.height;if(at(y)&&at(m))return{x:f,y:g,width:y,height:m};const v=o(a);if(!v)return{x:f,y:g,width:y!=null?y:0,height:m!=null?m:0};if(Array.isArray(v)){const b=mo(v),_=Tr(b);if(at(y)&&at(m))return{x:f,y:g,width:y,height:m};const x=_.width!==0?_.width:y!=null?y:0,w=_.height!==0?_.height:m!=null?m:0;return{x:f+_.x,y:g+_.y,width:x,height:w}}if(Xb(v)){const b=v,_=se(b);if(cH(b,a))return _;const x=b.props&&at(b.props.width)&&at(b.props.height),$=Ub(b).flatMap(E=>mo(E)).length>0,C=b.props&&b.props.x===a.x&&b.props.y===a.y;if(x)return{x:C?_.x:f+_.x,y:C?_.y:g+_.y,width:_.width,height:_.height};if(at(y)&&at(m))return $?{x:C?_.x:f,y:C?_.y:g,width:y,height:m}:{x:C?_.x:f+_.x,y:C?_.y:g+_.y,width:y,height:m};const M=_.width!==0?_.width:y!=null?y:0,S=_.height!==0?_.height:m!=null?m:0;return{x:C?_.x:f+_.x,y:C?_.y:g+_.y,width:M,height:S}}return{x:f,y:g,width:y!=null?y:0,height:m!=null?m:0}}const s=(r=a.x)!=null?r:0,c=(i=a.y)!=null?i:0,l=at(a.width)?a.width:void 0,u=at(a.height)?a.height:void 0;if(at(l)&&at(u))return{x:s,y:c,width:l,height:u};const d=Ub(e).flatMap(f=>mo(f));if(d.length>0){const f=Tr(d);return{x:s+f.x,y:c+f.y,width:at(l)?l:f.width,height:at(u)?u:f.height}}return{x:s,y:c,width:l!=null?l:0,height:u!=null?u:0}}function Tr(e){if(!e||!Array.isArray(e)||e.length===0)return us();const t=[];for(const n of e){const r=mo(n);for(const i of r){const o=se(i);o&&t.push(o)}}return yi(t)}function cH(e,t){if(!(e!=null&&e.props)||!t)return!1;const n=e.props;if(at(n.x)&&at(n.y)&&at(t.x)&&at(t.y)&&n.x===t.x&&n.y===t.y){const r=at(n.width)&&at(n.height),i=at(t.width)&&at(t.height);if(!r&&!i)return!0}return at(n.x)&&at(n.y)&&at(n.width)&&at(n.height)&&at(t.x)&&at(t.y)&&at(t.width)&&at(t.height)?n.x===t.x&&n.y===t.y&&n.width===t.width&&n.height===t.height:!1}function Ub(e){var t;const n=(t=e.props)==null?void 0:t.children;return n?Array.isArray(n)?n:[n]:[]}function Ku(e){var t;return e==null||typeof e=="boolean"?[]:Array.isArray(e)?yo(e):typeof e=="object"?yo((t=e.props)==null?void 0:t.children):[e]}var lH=Object.defineProperty,hs=Object.getOwnPropertySymbols,Kb=Object.prototype.hasOwnProperty,Zb=Object.prototype.propertyIsEnumerable,Qb=(e,t,n)=>t in e?lH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Zu=(e,t)=>{for(var n in t||(t={}))Kb.call(t,n)&&Qb(e,n,t[n]);if(hs)for(var n of hs(t))Zb.call(t,n)&&Qb(e,n,t[n]);return e},uH=(e,t)=>{var n={};for(var r in e)Kb.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&hs)for(var r of hs(e))t.indexOf(r)<0&&Zb.call(e,r)&&(n[r]=e[r]);return n};const lr=(e,t)=>{const n=e,{type:r,props:i}=n,o=uH(n,["type","props"]);return Zu({type:r,props:Zu(Zu({},i),t)},o)},Jb=()=>({defs:new Map});function Qu(e){const t={"&":"&","<":"<",">":">",'"':""","'":"'"};return String(e).replace(/[&<>"']/g,n=>t[n])}const e_={className:"class",viewBox:"viewBox",preserveAspectRatio:"preserveAspectRatio",gradientUnits:"gradientUnits",gradientTransform:"gradientTransform",patternUnits:"patternUnits",patternContentUnits:"patternContentUnits",patternTransform:"patternTransform",maskUnits:"maskUnits",maskContentUnits:"maskContentUnits",clipPathUnits:"clipPathUnits",primitiveUnits:"primitiveUnits",filterUnits:"filterUnits",markerUnits:"markerUnits",markerWidth:"markerWidth",markerHeight:"markerHeight",refX:"refX",refY:"refY",xmlLang:"xml:lang",xmlSpace:"xml:space",xmlnsXlink:"xmlns:xlink",xlinkHref:"href",xlinkTitle:"xlink:title",xlinkShow:"xlink:show",xlinkActuate:"xlink:actuate",textLength:"textLength",lengthAdjust:"lengthAdjust",attributeName:"attributeName",attributeType:"attributeType",repeatCount:"repeatCount",repeatDur:"repeatDur",calcMode:"calcMode",keyTimes:"keyTimes",keySplines:"keySplines",keyPoints:"keyPoints",stdDeviation:"stdDeviation",baseFrequency:"baseFrequency",numOctaves:"numOctaves",pathLength:"pathLength",systemLanguage:"systemLanguage",requiredFeatures:"requiredFeatures",requiredExtensions:"requiredExtensions"};function hH(e){return e_[e]?e_[e]:e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}const Ju=new Map;function eh(e){const t=Symbol("layout");return Ju.set(t,e),r=>({type:t,props:r})}function th(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.type=="symbol"&&Ju.has(e.type)}function t_(e,t=Jb()){const n=Ju.get(e.type);if(!n)return console.warn("Layout function not found for symbol:",e.type),e;const r=Ku(e).filter(i=>typeof i=="object");return n(r,e.props,t)}var dH=Object.defineProperty,fH=Object.defineProperties,pH=Object.getOwnPropertyDescriptors,ds=Object.getOwnPropertySymbols,n_=Object.prototype.hasOwnProperty,r_=Object.prototype.propertyIsEnumerable,i_=(e,t,n)=>t in e?dH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gH=(e,t)=>{for(var n in t||(t={}))n_.call(t,n)&&i_(e,n,t[n]);if(ds)for(var n of ds(t))r_.call(t,n)&&i_(e,n,t[n]);return e},mH=(e,t)=>fH(e,pH(t)),o_=(e,t)=>{var n={};for(var r in e)n_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ds)for(var r of ds(e))t.indexOf(r)<0&&r_.call(e,r)&&(n[r]=e[r]);return n};function vo(e,t){if(e==null||typeof e=="boolean")return null;if(typeof e=="string"||typeof e=="number")return e;if(Array.isArray(e))return e.map(r=>vo(r,t)).filter(Boolean);if(th(e)){const r=t_(e,t);return vo(r,t)}if(typeof e.type=="function"){const r=e.type(e.props);return vo(r,t)}const n=Ku(e).map(r=>vo(r,t)).filter(Boolean);return e.type===go?n:e.type===cl?(n.forEach(r=>{typeof r=="object"&&r.props.id&&t.defs.set(r.props.id,r)}),null):n.length?lr(e,{children:n}):e}function bo(e,t){if(e==null)return"";if(typeof e=="string")return Qu(e);if(typeof e=="number")return String(e);const{type:n,props:r}=e;if(!n)return"";const i=Ku(e);if(n===go)return i.map(c=>bo(c)).filter(Boolean).join("");if(n===cl)return"";if(typeof n=="function"||th(e))return console.warn("Unexpected unprocessed component in render:",e),"";const o=s_(r),a=i.map(c=>bo(c)).filter(Boolean).join(""),s=String(n);return a?`<${s}${o}>${a}</${s}>`:`<${s}${o} />`}function a_(e,t={}){const n=Jb(),r=vo(e,n);if(!r)return"";const i=Array.isArray(r)?r.map(m=>bo(m)).join(""):bo(r),o=t,{x:a,y:s,width:c,height:l,style:u}=o,h=o_(o,["x","y","width","height","style"]),d=mH(gH({},h),{xmlns:"http://www.w3.org/2000/svg"});if(!d.viewBox)if(c&&l)d.viewBox=`${a!=null?a:0} ${s!=null?s:0} ${c!=null?c:0} ${l!=null?l:0}`;else{const m=se(r);if(m){const{x:v,y:b,width:_,height:x}=m;d.viewBox=`${v} ${b} ${_} ${x}`}}const f=s_(d),g=yH(u),y=n.defs.size?`<defs>${Array.from(n.defs.values()).map(m=>bo(m)).join("")}</defs>`:"";return`<svg${f}${g}>${y}${i}</svg>`}function s_(e){if(!e)return"";const t=e,{children:n}=t,r=o_(t,["children"]);return Object.entries(r).filter(([,i])=>i!=null).map(([i,o])=>{const a=hH(i),s=typeof o=="string"?Qu(String(o)):String(o);return` ${a}="${s}"`}).join("")}function yH(e){if(!e||Object.keys(e).length===0)return"";const t=Object.entries(e).map(([n,r])=>`${n.replace(/[A-Z]/g,o=>`-${o.toLowerCase()}`)}: ${r};`).join("");return` style="${Qu(t)}"`}var vH=Object.defineProperty,fs=Object.getOwnPropertySymbols,c_=Object.prototype.hasOwnProperty,l_=Object.prototype.propertyIsEnumerable,u_=(e,t,n)=>t in e?vH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ps=(e,t)=>{for(var n in t||(t={}))c_.call(t,n)&&u_(e,n,t[n]);if(fs)for(var n of fs(t))l_.call(t,n)&&u_(e,n,t[n]);return e},h_=(e,t)=>{var n={};for(var r in e)c_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&fs)for(var r of fs(e))t.indexOf(r)<0&&l_.call(e,r)&&(n[r]=e[r]);return n};const Q=e=>{const t=e,{indexes:n}=t,r=h_(t,["indexes"]),i={fill:"#B9EBCA",fillOpacity:.3,width:20,height:20,"data-indexes":n,"data-element-type":Ve.BtnAdd};return p(Re,ps(ps({},i),r))},nt=e=>{const t=e,{indexes:n}=t,r=h_(t,["indexes"]),i={fill:"#F9C0C0",fillOpacity:.3,width:20,height:20,"data-indexes":n,"data-element-type":Ve.BtnRemove};return p(Re,ps(ps({},i),r))};var bH=Object.defineProperty,_H=Object.defineProperties,xH=Object.getOwnPropertyDescriptors,d_=Object.getOwnPropertySymbols,wH=Object.prototype.hasOwnProperty,PH=Object.prototype.propertyIsEnumerable,f_=(e,t,n)=>t in e?bH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$H=(e,t)=>{for(var n in t||(t={}))wH.call(t,n)&&f_(e,n,t[n]);if(d_)for(var n of d_(t))PH.call(t,n)&&f_(e,n,t[n]);return e},CH=(e,t)=>_H(e,xH(t));const He=e=>p(Y,CH($H({"data-element-type":Ve.BtnsGroup,width:0,height:0},e),{display:"none"})),mt=()=>p(tt,{});var OH=Object.defineProperty,gs=Object.getOwnPropertySymbols,p_=Object.prototype.hasOwnProperty,g_=Object.prototype.propertyIsEnumerable,m_=(e,t,n)=>t in e?OH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nh=(e,t)=>{for(var n in t||(t={}))p_.call(t,n)&&m_(e,n,t[n]);if(gs)for(var n of gs(t))g_.call(t,n)&&m_(e,n,t[n]);return e},SH=(e,t)=>{var n={};for(var r in e)p_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&gs)for(var r of gs(e))t.indexOf(r)<0&&g_.call(e,r)&&(n[r]=e[r]);return n};const y_=e=>{var t=e,{indexes:n}=t,r=SH(t,["indexes"]);const o=nh(nh({},{fill:"lightgray"}),r);return n?(o["data-indexes"]=n,o["data-element-type"]=Ve.ItemIllus):o["data-element-type"]=Ve.Illus,p(Re,nh({},o))};var MH=Object.defineProperty,EH=Object.defineProperties,IH=Object.getOwnPropertyDescriptors,ms=Object.getOwnPropertySymbols,v_=Object.prototype.hasOwnProperty,b_=Object.prototype.propertyIsEnumerable,__=(e,t,n)=>t in e?MH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,x_=(e,t)=>{for(var n in t||(t={}))v_.call(t,n)&&__(e,n,t[n]);if(ms)for(var n of ms(t))b_.call(t,n)&&__(e,n,t[n]);return e},AH=(e,t)=>EH(e,IH(t)),TH=(e,t)=>{var n={};for(var r in e)v_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ms)for(var r of ms(e))t.indexOf(r)<0&&b_.call(e,r)&&(n[r]=e[r]);return n};const ut=e=>{var t=e,{indexes:n,lineNumber:r=2,children:i}=t,o=TH(t,["indexes","lineNumber","children"]),a;if(!i)return null;const s=x_({fontSize:14,fill:"#666",wordWrap:!0,lineHeight:1.4,children:i},o);return(a=s.height)!=null||(s.height=Math.ceil(r*+s.lineHeight*+s.fontSize)),p(ze,AH(x_({},s),{"data-indexes":n,"data-element-type":Ve.ItemDesc}))};var kH=Object.defineProperty,RH=Object.defineProperties,LH=Object.getOwnPropertyDescriptors,ys=Object.getOwnPropertySymbols,w_=Object.prototype.hasOwnProperty,P_=Object.prototype.propertyIsEnumerable,$_=(e,t,n)=>t in e?kH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_o=(e,t)=>{for(var n in t||(t={}))w_.call(t,n)&&$_(e,n,t[n]);if(ys)for(var n of ys(t))P_.call(t,n)&&$_(e,n,t[n]);return e},vs=(e,t)=>RH(e,LH(t)),C_=(e,t)=>{var n={};for(var r in e)w_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ys)for(var r of ys(e))t.indexOf(r)<0&&P_.call(e,r)&&(n[r]=e[r]);return n};const Ht=e=>{const t=e,{indexes:n,size:r=32}=t,i=C_(t,["indexes","size"]),o=_o({fill:"lightgray",width:r,height:r},i);return p(Re,vs(_o({},o),{"data-indexes":n,"data-element-type":"item-icon"}))},kr=e=>{const t=e,{indexes:n,size:r=50,fill:i,colorBg:o="white"}=t,a=C_(t,["indexes","size","fill","colorBg"]),s=r/Math.SQRT2*.9,c=(r-s)/2,l=vs(_o({fill:o},a),{x:c,y:c,width:s,height:s});return L(Y,vs(_o({},a),{width:r,height:r,"data-element-type":Ve.ItemIconGroup,children:[p(Ze,{width:r,height:r,fill:i,"data-element-type":"shape"}),p(Re,vs(_o({},l),{"data-indexes":n,"data-element-type":Ve.ItemIcon}))]}))};var zH=Object.defineProperty,NH=Object.defineProperties,DH=Object.getOwnPropertyDescriptors,bs=Object.getOwnPropertySymbols,O_=Object.prototype.hasOwnProperty,S_=Object.prototype.propertyIsEnumerable,M_=(e,t,n)=>t in e?zH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,E_=(e,t)=>{for(var n in t||(t={}))O_.call(t,n)&&M_(e,n,t[n]);if(bs)for(var n of bs(t))S_.call(t,n)&&M_(e,n,t[n]);return e},HH=(e,t)=>NH(e,DH(t)),qH=(e,t)=>{var n={};for(var r in e)O_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&bs)for(var r of bs(e))t.indexOf(r)<0&&S_.call(e,r)&&(n[r]=e[r]);return n};const Ge=e=>{var t=e,{indexes:n,children:r}=t,i=qH(t,["indexes","children"]),o;const a=E_({fontSize:18,fontWeight:"bold",fill:"#252525",lineHeight:1.4,children:r},i);return(o=a.height)!=null||(a.height=Math.ceil(+a.lineHeight*+a.fontSize)),p(ze,HH(E_({},a),{"data-indexes":n,"data-element-type":Ve.ItemLabel}))};var jH=Object.defineProperty,I_=Object.getOwnPropertySymbols,FH=Object.prototype.hasOwnProperty,BH=Object.prototype.propertyIsEnumerable,A_=(e,t,n)=>t in e?jH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WH=(e,t)=>{for(var n in t||(t={}))FH.call(t,n)&&A_(e,n,t[n]);if(I_)for(var n of I_(t))BH.call(t,n)&&A_(e,n,t[n]);return e};const Ne=e=>p(Y,WH({"data-element-type":Ve.ItemsGroup},e));var GH=Object.defineProperty,VH=Object.defineProperties,YH=Object.getOwnPropertyDescriptors,_s=Object.getOwnPropertySymbols,T_=Object.prototype.hasOwnProperty,k_=Object.prototype.propertyIsEnumerable,R_=(e,t,n)=>t in e?GH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,L_=(e,t)=>{for(var n in t||(t={}))T_.call(t,n)&&R_(e,n,t[n]);if(_s)for(var n of _s(t))k_.call(t,n)&&R_(e,n,t[n]);return e},XH=(e,t)=>VH(e,YH(t)),UH=(e,t)=>{var n={};for(var r in e)T_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_s)for(var r of _s(e))t.indexOf(r)<0&&k_.call(e,r)&&(n[r]=e[r]);return n};const xo=e=>{var t=e,{indexes:n,value:r,formatter:i=c=>String(c)}=t,o=UH(t,["indexes","value","formatter"]),a;const s=L_({fontSize:14,fill:"#666",wordWrap:!0,lineHeight:1.4,children:i(r),"data-value":r},o);return(a=s.height)!=null||(s.height=Math.ceil(+s.lineHeight*+s.fontSize)),p(ze,XH(L_({},s),{"data-indexes":n,"data-element-type":Ve.ItemValue}))};var KH=Object.defineProperty,z_=Object.getOwnPropertySymbols,ZH=Object.prototype.hasOwnProperty,QH=Object.prototype.propertyIsEnumerable,N_=(e,t,n)=>t in e?KH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,JH=(e,t)=>{for(var n in t||(t={}))ZH.call(t,n)&&N_(e,n,t[n]);if(z_)for(var n of z_(t))QH.call(t,n)&&N_(e,n,t[n]);return e};const xt=e=>p(Y,JH({"data-element-type":"shapes-group"},e));var eq=Object.defineProperty,tq=Object.defineProperties,nq=Object.getOwnPropertyDescriptors,xs=Object.getOwnPropertySymbols,D_=Object.prototype.hasOwnProperty,H_=Object.prototype.propertyIsEnumerable,q_=(e,t,n)=>t in e?eq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ws=(e,t)=>{for(var n in t||(t={}))D_.call(t,n)&&q_(e,n,t[n]);if(xs)for(var n of xs(t))H_.call(t,n)&&q_(e,n,t[n]);return e},j_=(e,t)=>tq(e,nq(t)),rq=(e,t)=>{var n={};for(var r in e)D_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&xs)for(var r of xs(e))t.indexOf(r)<0&&H_.call(e,r)&&(n[r]=e[r]);return n};const vi=eh((e,t)=>{var n=t,{horizontal:r,vertical:i}=n,o=rq(n,["horizontal","vertical"]),a,s,c,l;if(!e||e.length===0)return p(Y,ws({},o));const u=e.map(b=>se(b)),h=Tr(e),d=(a=o.x)!=null?a:h.x,f=(s=o.y)!=null?s:h.y,g=(c=o.width)!=null?c:h.width,y=(l=o.height)!=null?l:h.height,m=e.map((b,_)=>{const x=u[_],w=ws({},b.props);if(r!==void 0)switch(r){case"left":w.x=-x.x;break;case"center":w.x=(g-x.width)/2-x.x;break;case"right":w.x=g-x.width-x.x;break}else w.x===void 0&&(w.x=x.x-d);if(i!==void 0)switch(i){case"top":w.y=-x.y;break;case"middle":w.y=(y-x.height)/2-x.y;break;case"bottom":w.y=y-x.height-x.y;break}else w.y===void 0&&(w.y=x.y-f);return lr(b,w)}),v=j_(ws({},o),{x:d,y:f,width:g,height:y});return p(Y,j_(ws({},v),{children:m}))});var iq=Object.defineProperty,oq=Object.defineProperties,aq=Object.getOwnPropertyDescriptors,Ps=Object.getOwnPropertySymbols,F_=Object.prototype.hasOwnProperty,B_=Object.prototype.propertyIsEnumerable,W_=(e,t,n)=>t in e?iq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Rr=(e,t)=>{for(var n in t||(t={}))F_.call(t,n)&&W_(e,n,t[n]);if(Ps)for(var n of Ps(t))B_.call(t,n)&&W_(e,n,t[n]);return e},G_=(e,t)=>oq(e,aq(t)),sq=(e,t)=>{var n={};for(var r in e)F_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ps)for(var r of Ps(e))t.indexOf(r)<0&&B_.call(e,r)&&(n[r]=e[r]);return n};const ve=eh((e,t)=>{var n=t,{flexDirection:r="row",justifyContent:i="flex-start",alignItems:o="flex-start",alignContent:a="flex-start",flexWrap:s="nowrap",gap:c=0}=n,l=sq(n,["flexDirection","justifyContent","alignItems","alignContent","flexWrap","gap"]),u,h,d,f,g,y;if(!e||e.length===0)return p(Y,Rr({},l));const m=r==="row"||r==="row-reverse",v=r==="row-reverse"||r==="column-reverse",b=e.map(O=>se(O)),_=Tr(e),x=(u=l.width)!=null?u:_.width,w=(h=l.height)!=null?h:_.height,P=l.width!==void 0&&l.height!==void 0,$=[];if(s==="wrap"&&P){let O=[],T=[],F=0;for(let z=0;z<e.length;z++){const j=e[z],D=b[z],W=m?D.width:D.height,B=m?x:w;O.length===0||F+c+W<=B?(O.push(j),T.push(D),F+=(O.length>1?c:0)+W):($.push({children:O,bounds:T}),O=[j],T=[D],F=W)}O.length>0&&$.push({children:O,bounds:T})}else $.push({children:e,bounds:b});const C=[];let M=0;const S=[];if($.forEach(O=>{const{children:T,bounds:F}=O,z=F.reduce((H,k,I)=>{const R=m?k.width:k.height;return H+R+(I>0?c:0)},0),j=Math.max(...F.map(H=>m?H.height:H.width));S.push(j);let D=0;const W=(m?x:w)-z;if(P)switch(i){case"flex-end":D=W;break;case"center":D=W/2;break;case"space-between":D=0;break;default:D=0;break}let B=c;P&&i==="space-between"&&T.length>1&&(B=W/(T.length-1)+c);let X=D;T.forEach((H,k)=>{const I=F[k],R=m?I.width:I.height,N=m?I.height:I.width,q=m?I.x:I.y,G=m?I.y:I.x;let U=M;if(P)switch(o){case"flex-end":U=M+j-N;break;case"center":U=M+(j-N)/2;break;default:U=M;break}let K,oe;m?(K=v?x-X-R-q:X-q,oe=U-G):(K=U-G,oe=v?w-X-R-q:X-q);const te=lr(H,{x:K,y:oe});C.push(te),X+=R+B}),M+=j+c}),$.length>1&&P){const O=S.reduce((z,j)=>z+j,0)+($.length-1)*c,T=(m?w:x)-O;let F=0;switch(a){case"flex-end":F=T;break;case"center":F=T/2;break;case"space-between":if($.length>1){const z=T/($.length-1);let j=0;$.forEach((D,W)=>{const B=$.slice(0,W).reduce((H,k)=>H+k.children.length,0),X=B+D.children.length;for(let H=B;H<X;H++){const k=C[H],I=Rr({},k.props);m?I.y=(I.y||0)+j:I.x=(I.x||0)+j,C[H]=lr(k,I)}j+=S[W]+c+(W<$.length-1?z:0)});break}break;default:F=0;break}F!==0&&a!=="space-between"&&C.forEach((z,j)=>{const D=Rr({},z.props);m?D.y=(D.y||0)+F:D.x=(D.x||0)+F,C[j]=lr(z,D)})}if(!P&&o==="center")if(m){const O=Math.max(...b.map(T=>T.height));C.forEach((T,F)=>{const z=b[F],j=(O-z.height)/2,D=Rr({},T.props);D.y=(D.y||0)+j,C[F]=lr(T,D)})}else{const O=Math.max(...b.map(T=>T.width));C.forEach((T,F)=>{const z=b[F],j=(O-z.width)/2,D=Rr({},T.props);D.x=(D.x||0)+j,C[F]=lr(T,D)})}const E=Tr(C),A=G_(Rr({},l),{x:(d=l.x)!=null?d:_.x,y:(f=l.y)!=null?f:_.y,width:(g=l.width)!=null?g:E.width,height:(y=l.height)!=null?y:E.height});return p(Y,G_(Rr({},A),{children:C}))});var cq=Object.defineProperty,lq=Object.defineProperties,uq=Object.getOwnPropertyDescriptors,V_=Object.getOwnPropertySymbols,hq=Object.prototype.hasOwnProperty,dq=Object.prototype.propertyIsEnumerable,Y_=(e,t,n)=>t in e?cq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$s=(e,t)=>{for(var n in t||(t={}))hq.call(t,n)&&Y_(e,n,t[n]);if(V_)for(var n of V_(t))dq.call(t,n)&&Y_(e,n,t[n]);return e},X_=(e,t)=>lq(e,uq(t));const U_=e=>{const{x:t=0,y:n=0,alignHorizontal:r="center",title:i,desc:o,descLineNumber:a=2,themeColors:s}=e,c=u=>{const h={fontSize:24,fill:s.colorPrimaryText,lineHeight:1.4,alignHorizontal:r};return p(ze,X_($s($s({},h),u),{"data-element-type":"title",children:i}))},l=u=>{const h={fontSize:16,fill:s.colorTextSecondary,alignHorizontal:r,lineHeight:1.4,height:a*24};return p(ze,X_($s($s({},h),u),{"data-element-type":"desc",children:o}))};return!i&&!o?null:L(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",x:t,y:n,gap:8,children:[i&&p(c,{}),o&&p(l,{})]})},rh=new Map;function ih(e,t){rh.set(e,t)}function K_(e){return rh.get(e)}function fq(){return Array.from(rh.keys())}ih("dark",{colorBg:"#1F1F1F",base:{text:{fill:"#fff"}}}),ih("hand-drawn",{base:{text:{"font-family":"851tegakizatsu"}},stylize:{type:"rough"}});var pq=Object.defineProperty,gq=Object.defineProperties,mq=Object.getOwnPropertyDescriptors,Z_=Object.getOwnPropertySymbols,yq=Object.prototype.hasOwnProperty,vq=Object.prototype.propertyIsEnumerable,Q_=(e,t,n)=>t in e?pq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wo=(e,t)=>{for(var n in t||(t={}))yq.call(t,n)&&Q_(e,n,t[n]);if(Z_)for(var n of Z_(t))vq.call(t,n)&&Q_(e,n,t[n]);return e},Po=(e,t)=>gq(e,mq(t));it(Ty);const J_=({colorPrimary:e,colorBg:t="#ffffff",isDarkMode:n=!1})=>{const r=$n(e),i=$n(t),o=$q({primaryColor:r,bgColor:i});return Cq(o,{primaryColor:r,bgColor:i,isDarkMode:n})},bq=(e,t)=>GE(Po(wo({},e),{alpha:t?.2:.1}))||"#ffffff",_q=(e,t)=>{if(t)return"#ffffff";const n=$n("#262626");return Xl(n,e)>=7?Ki(n):"#000000"},xq=e=>{const t=Wy($n(e)),n=Po(wo({},t),{l:Math.min(1,t.l+.2)});return Ki(n)},wq=(e,t)=>{const n=$n(e),r=$n("#262626"),i=$n("#ffffff"),o=Xl(r,n);return Xl(i,n)>=3?Ki(i):o>=4.5?Ki(r):"#ffffff"},Pq=(e,t)=>{const n=Wy(e);if(t){const r=Po(wo({},n),{l:Math.min(1,n.l+.1)});return Cs(r,"#1f1f1f")}else{if(n.l>.95)return"#ffffff";{const r=Po(wo({},n),{l:Math.min(1,n.l+.05)});return Cs(r,"#ffffff")}}},$q=({primaryColor:e,bgColor:t})=>({colorPrimary:Cs(e,"#FF356A"),colorBg:Cs(t,"#ffffff"),colorWhite:"#ffffff"}),Cq=(e,{primaryColor:t,bgColor:n,isDarkMode:r})=>{const i=_q(n,r),o=bq(t,r);return Po(wo({},e),{isDarkMode:r,colorPrimaryBg:o,colorText:i,colorTextSecondary:xq(i),colorPrimaryText:wq(o,r),colorBgElevated:Pq(n,r)})};function Cs(e,t="#000000"){var n;return(n=Ki(e))!=null?n:t}const oh="#FF356A";function wt(e){var t;return((t=e==null?void 0:e.themeConfig)==null?void 0:t.colorPrimary)||oh}function e3(e){var t;const{themeConfig:n={},data:r}=e,{colorPrimary:i,palette:o}=n;return!o||o.length===0?Array(((t=r==null?void 0:r.items)==null?void 0:t.length)||1).fill(i||oh):r.items.map((a,s)=>za(o,[s],r.items.length)||oh)}function qe(e,t){var n,r,i;return za((n=e==null?void 0:e.themeConfig)==null?void 0:n.palette,t,(i=(r=e.data)==null?void 0:r.items)==null?void 0:i.length)}function Ct(e,t){var n;const{colorBg:r=((n=t==null?void 0:t.themeConfig)==null?void 0:n.colorBg)||"white",colorPrimary:i=t?wt(t):"black"}=e;return J_({colorPrimary:i,isDarkMode:Gy(r),colorBg:r})}function t3(e,t){const{depth:n,originalIndexes:r,flatIndex:i}=e;switch(t){case"level":return[n];case"branch":return n===0?[0]:n===1?[r[1]+1]:[r[1]+1];case"node":return r;case"node-flat":return i!==void 0?[i]:(console.warn("node-flat mode requires flatIndex in HierarchyNode, falling back to originalIndexes"),r);default:return[0]}}var Oq=Object.defineProperty,n3=Object.getOwnPropertySymbols,Sq=Object.prototype.hasOwnProperty,Mq=Object.prototype.propertyIsEnumerable,r3=(e,t,n)=>t in e?Oq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Eq=(e,t)=>{for(var n in t||(t={}))Sq.call(t,n)&&r3(e,n,t[n]);if(n3)for(var n of n3(t))Mq.call(t,n)&&r3(e,n,t[n]);return e};function st(e,t=[]){const n=Eq({},e),r={};return["indexes","data","datum","positionH","positionV","themeColors","valueFormatter",...t].forEach(o=>{o in n&&(r[o]=n[o],delete n[o])}),["x","y","width","height"].forEach(o=>{o in e&&(n[o]=e[o])}),[r,n]}function Os(e,t){var n;return e.length===0?()=>null:t===void 0?e[0]:(n=e[t])!=null?n:e[0]}const ah=new Map;function ct(e,t){ah.set(e,t)}function i3(e){return ah.get(e)}function Iq(){return Array.from(ah.keys())}var Aq=Object.defineProperty,Tq=Object.defineProperties,kq=Object.getOwnPropertyDescriptors,o3=Object.getOwnPropertySymbols,Rq=Object.prototype.hasOwnProperty,Lq=Object.prototype.propertyIsEnumerable,a3=(e,t,n)=>t in e?Aq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zq=(e,t)=>{for(var n in t||(t={}))Rq.call(t,n)&&a3(e,n,t[n]);if(o3)for(var n of o3(t))Lq.call(t,n)&&a3(e,n,t[n]);return e},Nq=(e,t)=>Tq(e,kq(t));const s3=e=>{const[{datum:t,indexes:n,width:r=200,height:i=80,iconSize:o=24,badgeSize:a=32,gap:s=8,positionH:c="normal",themeColors:l,valueFormatter:u},h]=st(e,["width","height","iconSize","badgeSize","gap"]),d=t.value,f=d!==void 0,g=!!t.desc,y=!!t.icon,m=`${l.colorPrimary}-badge`,v=c==="flipped"?r-s-a:s,b=y?c==="flipped"?s:a+2*s:s,_=r-s*2,x=y?r-a-3*s:_,w=s+14+18+8,P=w-s,$=g?s:(i-a)/2,C=!f&&!g?(i-14)/2:s,M=!y&&c==="center"?"center":c==="flipped"?"right":"left";return L(Y,Nq(zq({},h),{width:r,height:i,children:[p(Ke,{children:L("radialGradient",{id:m,cx:"50%",cy:"50%",r:"50%",children:[p("stop",{offset:"0%",stopColor:l.colorPrimary}),p("stop",{offset:"100%",stopColor:be(l.colorPrimary).darken(20).toHexString()})]})}),p(Re,{"data-element-type":"shape",x:0,y:0,width:r,height:i,fill:l.colorPrimaryBg,rx:8,ry:8}),y&&L(tt,{children:[p(Ze,{x:v,y:$,width:a,height:a,fill:`url(#${m})`}),p(Ht,{indexes:n,x:v+(a-o)/2,y:$+(a-o)/2,size:o,fill:l.colorWhite})]}),L(ve,{flexDirection:"column",x:b,y:C,width:x,height:!f&&!g?void 0:P,alignItems:"center",justifyContent:"center",children:[p(Ge,{indexes:n,width:x,alignHorizontal:M,alignVertical:"middle",fontSize:14,fill:l.colorText,children:t.label}),f&&p(xo,{indexes:n,width:x,alignHorizontal:c==="flipped"?"right":"left",alignVertical:"middle",fontSize:18,lineHeight:1,fontWeight:"bold",fill:l.colorPrimary,value:d,formatter:u})]}),g&&p(ut,{indexes:n,x:s,y:w,width:_,alignHorizontal:M,fontSize:11,fill:l.colorTextSecondary,lineNumber:2,lineHeight:1.2,wordWrap:!0,children:t.desc})]}))};ct("badge-card",{component:s3,composites:["icon","label","value","desc"]});var Dq=Object.defineProperty,Hq=Object.defineProperties,qq=Object.getOwnPropertyDescriptors,c3=Object.getOwnPropertySymbols,jq=Object.prototype.hasOwnProperty,Fq=Object.prototype.propertyIsEnumerable,l3=(e,t,n)=>t in e?Dq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bq=(e,t)=>{for(var n in t||(t={}))jq.call(t,n)&&l3(e,n,t[n]);if(c3)for(var n of c3(t))Fq.call(t,n)&&l3(e,n,t[n]);return e},Wq=(e,t)=>Hq(e,qq(t));const u3=e=>{const[{indexes:t,datum:n,width:r=280,height:i=140,themeColors:o},a]=st(e,["width","height"]);return L(Y,Wq(Bq({},a),{children:[p("rect",{x:0,y:0,width:r,height:i,rx:22,ry:22,fill:o.colorPrimaryBg,stroke:o.colorPrimary,"data-element-type":"shape"}),p(Pe,{x:r-85,y:.5,width:85,height:65,d:"M0 0H62.4495C74.9557 0 85.4549 10.8574 84.4557 23.1875V60.1875L77.8772 62.5839C64.3776 67.6876 48.51 64.6893 37.8662 53.7441L10.2361 25.3312C4.91402 19.8571 1.65356 13.1736 0.435652 6.21819L0 0Z",fill:o.colorBg,"data-element-type":"shape"}),p(Ge,{indexes:t,x:20,y:24,width:200,alignHorizontal:"left",alignVertical:"middle",fill:o.colorText,children:n.label}),p(ut,{indexes:t,x:20,y:58,width:220,height:70,fill:o.colorTextSecondary,alignHorizontal:"left",alignVertical:"top",children:n.desc}),p(Ht,{indexes:t,x:r-48,y:12,width:32,height:32,fill:o.colorPrimary})]}))};ct("candy-card-lite",{component:u3,composites:["icon","label","desc"]});var Gq=Object.defineProperty,Vq=Object.defineProperties,Yq=Object.getOwnPropertyDescriptors,Ss=Object.getOwnPropertySymbols,h3=Object.prototype.hasOwnProperty,d3=Object.prototype.propertyIsEnumerable,f3=(e,t,n)=>t in e?Gq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xq=(e,t)=>{for(var n in t||(t={}))h3.call(t,n)&&f3(e,n,t[n]);if(Ss)for(var n of Ss(t))d3.call(t,n)&&f3(e,n,t[n]);return e},Uq=(e,t)=>Vq(e,Yq(t)),Kq=(e,t)=>{var n={};for(var r in e)h3.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ss)for(var r of Ss(e))t.indexOf(r)<0&&d3.call(e,r)&&(n[r]=e[r]);return n};const sh=e=>{const t=e,{color:n="black",opacity:r=.8}=t,i=Kq(t,["color","opacity"]);return p("filter",Uq(Xq({id:"drop-shadow",x:"-25%",y:"-25%",width:"200%",height:"200%"},i),{children:p("feDropShadow",{dx:"4",dy:"4",stdDeviation:"4","flood-color":n,"flood-opacity":r})}))};var Zq=Object.defineProperty,Qq=Object.defineProperties,Jq=Object.getOwnPropertyDescriptors,p3=Object.getOwnPropertySymbols,ej=Object.prototype.hasOwnProperty,tj=Object.prototype.propertyIsEnumerable,g3=(e,t,n)=>t in e?Zq(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nj=(e,t)=>{for(var n in t||(t={}))ej.call(t,n)&&g3(e,n,t[n]);if(p3)for(var n of p3(t))tj.call(t,n)&&g3(e,n,t[n]);return e},rj=(e,t)=>Qq(e,Jq(t));const ch=e=>{const{id:t="linear-gradient",startColor:n="black",stopColor:r="white",direction:i="left-right"}=e;return L("linearGradient",rj(nj({id:t},{"left-right":{x1:"0%",y1:"0%",x2:"100%",y2:"0%"},"right-left":{x1:"100%",y1:"0%",x2:"0%",y2:"0%"},"top-bottom":{x1:"0%",y1:"0%",x2:"0%",y2:"100%"},"bottom-top":{x1:"0%",y1:"100%",x2:"0%",y2:"0%"}}[i]),{children:[p("stop",{offset:"0%",stopColor:n}),p("stop",{offset:"100%",stopColor:r})]}))};var ij=Object.defineProperty,oj=Object.defineProperties,aj=Object.getOwnPropertyDescriptors,m3=Object.getOwnPropertySymbols,sj=Object.prototype.hasOwnProperty,cj=Object.prototype.propertyIsEnumerable,y3=(e,t,n)=>t in e?ij(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$o=(e,t)=>{for(var n in t||(t={}))sj.call(t,n)&&y3(e,n,t[n]);if(m3)for(var n of m3(t))cj.call(t,n)&&y3(e,n,t[n]);return e},Co=(e,t)=>oj(e,aj(t));const v3=e=>{const[{datum:t,indexes:n,width:r=300,height:i=80,gap:o=12,positionH:a="normal",iconPadding:s=i/10,themeColors:c},l]=st(e,["width","height","gap","iconPadding"]),u=i/2,h=i-s*2,d=a==="flipped",f=!!t.icon,g=f?r-i-o:r-o*2,y=f?d?o:i:o,m=f?d?"right":"left":"center",v={indexes:n,width:g,alignHorizontal:m,alignVertical:"middle",fontSize:16,fontWeight:"600",fill:c.colorWhite},b=se(p(Ge,Co($o({},v),{children:t.label}))),_={indexes:n,width:g,alignHorizontal:m,alignVertical:"top",fontSize:12,lineNumber:1,fill:c.colorWhite},x=se(t.desc?p(ut,Co($o({},_),{children:t.desc})):null),w=4,P=b.height+w+x.height,C=(i-P)/2,M=C+b.height+w,S=d?r-i+s:s,E=s;return L(Y,Co($o({},l),{children:[p(Ke,{children:p(sh,{})}),p(Re,{x:0,y:0,width:r,height:i,fill:c.colorPrimary,rx:u,ry:u,"data-element-type":"shape"}),t.icon&&L(tt,{children:[p(Ze,{x:S,y:E,width:h,height:h,fillOpacity:.5,fill:c.colorBg,filter:"url(#drop-shadow)"}),p(kr,{indexes:n,x:S,y:E,size:h,fill:c.colorBg,colorBg:c.colorPrimary})]}),t.label&&p(Ge,Co($o({x:y,y:C},v),{children:t.label})),t.desc&&p(ut,Co($o({x:y,y:M},_),{children:t.desc}))]}))};ct("capsule-item",{component:v3,composites:["icon","label","desc"]});var lj=Object.defineProperty,uj=Object.defineProperties,hj=Object.getOwnPropertyDescriptors,b3=Object.getOwnPropertySymbols,dj=Object.prototype.hasOwnProperty,fj=Object.prototype.propertyIsEnumerable,_3=(e,t,n)=>t in e?lj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lh=(e,t)=>{for(var n in t||(t={}))dj.call(t,n)&&_3(e,n,t[n]);if(b3)for(var n of b3(t))fj.call(t,n)&&_3(e,n,t[n]);return e},uh=(e,t)=>uj(e,hj(t));const x3=e=>{const[{indexes:t,datum:n,themeColors:r,positionH:i="normal",width:o=240,height:a=o},s]=st(e,["width","height"]),c=Math.min(o,a),l=c*.7,u=(c-l)/2,h=l*Math.sqrt(2)/2,d=(c-h)/2,f=be(r.colorPrimary),g=Ms(f,80,.2),y=Ms(f,20,.8),m=Ms(f,75,.32),v=Ms(f,45,.4),b=f.clone().darken(5).toRgbString(),_=`${r.colorPrimary}-${i}-outer`,x=`${r.colorPrimary}-${i}-inner`,w=i==="flipped"?{x1:"0%",y1:"0%",x2:"100%",y2:"0%"}:{x1:"100%",y1:"0%",x2:"0%",y2:"0%"};return L(Y,uh(lh({},s),{children:[L(Ke,{children:[L("linearGradient",uh(lh({id:_},w),{children:[p("stop",{offset:"0%",stopColor:g}),p("stop",{offset:"100%",stopColor:y})]})),L("linearGradient",uh(lh({id:x},w),{children:[p("stop",{offset:"0%",stopColor:m}),p("stop",{offset:"100%",stopColor:v})]}))]}),p(Ze,{width:c,height:c,fill:`url(#${_})`,"data-element-type":"shape"}),p(Ze,{x:u,y:u,width:l,height:l,fill:`url(#${x})`,stroke:"#FFFFFF",strokeWidth:1,"data-element-type":"shape"}),p(Ge,{indexes:t,x:d,y:d,width:h,height:h,lineHeight:1.1,alignHorizontal:"center",alignVertical:"middle",fill:b,fontWeight:"500",children:n.label})]}))};ct("circle-node",{component:x3,composites:["label"]});function Ms(e,t,n){return be.mix(e,"#ffffff",t).setAlpha(n).toRgbString()}var pj=Object.defineProperty,gj=Object.defineProperties,mj=Object.getOwnPropertyDescriptors,w3=Object.getOwnPropertySymbols,yj=Object.prototype.hasOwnProperty,vj=Object.prototype.propertyIsEnumerable,P3=(e,t,n)=>t in e?pj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hh=(e,t)=>{for(var n in t||(t={}))yj.call(t,n)&&P3(e,n,t[n]);if(w3)for(var n of w3(t))vj.call(t,n)&&P3(e,n,t[n]);return e},dh=(e,t)=>gj(e,mj(t));const $3=e=>{var t;const[{datum:n,indexes:r,size:i=120,strokeWidth:o=12,gap:a=8,themeColors:s,valueFormatter:c=w=>`${Math.round(w)}%`},l]=st(e,["size","strokeWidth","gap"]),u=(t=n.value)!=null?t:0,d=Math.min(Math.max(u/100,0),1),f=(i-o)/2,g=i/2,y=o/2,m=i-o,v=d>=1,b=d*360,_=bj(g,g,f,0,b),x={x:y,y,width:m,height:m};return L(Y,dh(hh({},l),{width:i,height:i+a+20,children:[p(Re,{width:i,height:i,fill:"none"}),p(Ze,dh(hh({},x),{fill:"none",stroke:"#f0f0f0",strokeWidth:o,"data-element-type":"shape"})),v?p(Ze,dh(hh({},x),{fill:"none",stroke:s.colorPrimary,strokeWidth:o,"data-element-type":"shape"})):p(Pe,{d:_,fill:"none",stroke:s.colorPrimary,strokeWidth:o,strokeLinecap:"round","data-element-type":"shape"}),p(xo,{indexes:r,x:o,y:o,width:m-o,height:m-o,fontSize:24,fontWeight:"bold",fill:s.colorPrimary,alignHorizontal:"center",alignVertical:"middle",value:u,formatter:c}),p(Ge,{indexes:r,x:0,y:i+a,width:i,alignHorizontal:"center",fontSize:12,fill:s.colorTextSecondary,children:n.label})]}))};function bj(e,t,n,r,i){const o=C3(e,t,n,i),a=C3(e,t,n,r),s=i-r<=180?"0":"1";return`M ${o.x} ${o.y} A ${n} ${n} 0 ${s} 0 ${a.x} ${a.y}`}function C3(e,t,n,r){const i=(r-90)*Math.PI/180;return{x:e+n*Math.cos(i),y:t+n*Math.sin(i)}}ct("circular-progress",{component:$3,composites:["label","value"]});var _j=Object.defineProperty,xj=Object.defineProperties,wj=Object.getOwnPropertyDescriptors,O3=Object.getOwnPropertySymbols,Pj=Object.prototype.hasOwnProperty,$j=Object.prototype.propertyIsEnumerable,S3=(e,t,n)=>t in e?_j(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Cj=(e,t)=>{for(var n in t||(t={}))Pj.call(t,n)&&S3(e,n,t[n]);if(O3)for(var n of O3(t))$j.call(t,n)&&S3(e,n,t[n]);return e},Oj=(e,t)=>xj(e,wj(t));const M3=e=>{const[{datum:t,indexes:n,width:r=200,height:i=60,iconSize:o=20,gap:a=8,positionH:s="normal",themeColors:c,valueFormatter:l},u]=st(e,["width","height","iconSize","gap"]),h=t.value,d=h!=null,f="compact-shadow",g=s==="flipped"?r-a-o:a,y=s==="flipped"?a:o+2*a,m=r-o-3*a,v=d?m*.8:m,b=d?m*.2:0;return L(Y,Oj(Cj({},u),{children:[p(Ke,{children:p("filter",{id:f,children:p("feDropShadow",{dx:"0",dy:"2",stdDeviation:"2",floodOpacity:"0.15"})})}),p(Re,{x:0,y:0,width:r,height:i,fill:c.colorBgElevated,stroke:c.colorBgElevated,strokeWidth:1,rx:6,ry:6,filter:`url(#${f})`,"data-element-type":"shape"}),p(Re,{x:s==="flipped"?r-3:0,y:0,width:3,height:i,fill:c.colorPrimary,rx:1.5,ry:1.5,"data-element-type":"shape"}),p(Ht,{indexes:n,x:g,y:(i-o)/2,size:o,fill:c.colorPrimary}),L(ve,{x:y,y:a,width:m,height:i-a*2,flexDirection:"column",justifyContent:"center",alignItems:"flex-start",children:[L(ve,{width:m,flexDirection:"row",justifyContent:"space-between",alignItems:"center",children:[p(Ge,{indexes:n,width:v,alignHorizontal:"left",fontSize:12,fill:c.colorText,children:t.label}),d&&p(xo,{indexes:n,width:b,alignHorizontal:"right",fontSize:12,fontWeight:"bold",fill:c.colorPrimary,value:h,formatter:l})]}),p(ut,{indexes:n,width:m,alignHorizontal:"left",alignVertical:"middle",fontSize:10,fill:c.colorTextSecondary,lineNumber:2,wordWrap:!0,children:t.desc})]})]}))};ct("compact-card",{component:M3,composites:["icon","label","value","desc"]});var Sj=Object.defineProperty,Mj=Object.defineProperties,Ej=Object.getOwnPropertyDescriptors,E3=Object.getOwnPropertySymbols,Ij=Object.prototype.hasOwnProperty,Aj=Object.prototype.propertyIsEnumerable,I3=(e,t,n)=>t in e?Sj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tj=(e,t)=>{for(var n in t||(t={}))Ij.call(t,n)&&I3(e,n,t[n]);if(E3)for(var n of E3(t))Aj.call(t,n)&&I3(e,n,t[n]);return e},kj=(e,t)=>Mj(e,Ej(t));const A3=e=>{const[{datum:t,indexes:n,width:r=300,height:i=30,iconSize:o=30,gap:a=5,positionH:s="normal",positionV:c="middle",themeColors:l},u]=st(e,["width","height","iconSize","gap"]),h=r-o-a,d=c==="middle"?(i-o)/2:c==="flipped"?i-o:0;return L(Y,kj(Tj({},u),{children:[p(Pe,{"data-element-type":"shape",x:s==="flipped"?h+a:0,y:d,fill:l.colorPrimary,width:o,height:o,d:"M14.7273 30C6.54538 30 0 22.9077 0 14.7269C0 6.54617 6.54538 0 14.7273 0C22.9092 0 30 6.54617 30 14.7269C30 22.9077 22.9092 30 14.7273 30ZM24.5454 10.9077C22.9092 9.27307 22.9092 9.27307 22.9092 9.27307C22.3638 8.72692 22.3638 8.7269 21.8181 8.7269C21.2727 8.7269 21.2727 8.72692 20.7273 9.27307C13.0908 16.9077 13.0908 16.9077 13.0908 16.9077C8.72731 12.5461 8.72731 12.5462 8.72731 12.5462C8.18193 12.5462 8.18193 12 7.63654 12L7.09077 12.5462C4.90923 14.1808 4.90923 14.1808 4.90923 14.1808C4.90923 14.7269 4.90923 14.7269 4.90923 15.2731C4.90923 15.8192 4.90923 15.8192 4.90923 16.3654C12 23.4539 12 23.4538 12 23.4538C12.5454 23.4538 12.5454 23.4538 13.0908 23.4538C13.6365 23.4538 13.6365 23.4538 14.1819 23.4538C24.5454 12.5461 24.5454 12.5462 24.5454 12.5462L25.0908 12C25.0908 11.4538 24.5454 10.9077 24.5454 10.9077Z"}),p(Ge,{indexes:n,x:s==="flipped"?0:o+a,width:h,height:i,fontWeight:"normal",alignVertical:"middle",wordWrap:!1,fill:"#666",children:t.label||t.desc})]}))};ct("done-list",{component:A3,composites:["label"]});var Rj=Object.defineProperty,Lj=Object.defineProperties,zj=Object.getOwnPropertyDescriptors,T3=Object.getOwnPropertySymbols,Nj=Object.prototype.hasOwnProperty,Dj=Object.prototype.propertyIsEnumerable,k3=(e,t,n)=>t in e?Rj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Hj=(e,t)=>{for(var n in t||(t={}))Nj.call(t,n)&&k3(e,n,t[n]);if(T3)for(var n of T3(t))Dj.call(t,n)&&k3(e,n,t[n]);return e},qj=(e,t)=>Lj(e,zj(t));const R3=e=>{const[{indexes:t,datum:n,width:r=140,themeColors:i,positionV:o="normal"},a]=st(e,["width"]),s=o!=="flipped",c=o==="normal"?"bottom":"top",l=p(Ge,{indexes:t,width:r,fill:i.colorText,alignHorizontal:"center",alignVertical:c,fontSize:14,children:n.label}),u=p(ut,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:"center",alignVertical:c,children:n.desc}),h=p(kr,{indexes:t,fill:i.colorPrimary,colorBg:i.colorWhite}),d=p(Fj,{width:8,height:30,fill:i.colorPrimary,positionV:o}),f=5,g=25,y=30,m=se(l),v=se(u),b=se(h),_=se(d),x=m.height+v.height+f+_.height-b.height-g,w=b.height+g+y+_.height+f+m.height+v.height;return p(Y,qj(Hj({width:r,height:w},a),{children:L(ve,{flexDirection:"column",alignItems:"center",children:[s?L(tt,{children:[u,l,p(mt,{height:f}),d]}):L(tt,{children:[p(mt,{height:x}),h,p(mt,{height:g})]}),L(vi,{horizontal:"center",vertical:"middle",width:r,height:y,children:[p(jj,{width:r,height:y,fill:i.colorPrimary}),p(ze,{width:r,height:y,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:n.time?n.time:String(t[0]+1).padStart(2,"0").slice(-2)})]}),s?L(tt,{children:[p(mt,{height:g}),h]}):L(tt,{children:[d,p(mt,{height:f}),l,u]})]})}))},jj=e=>{const{x:t=0,y:n=0,width:r=100,height:i=40,fill:o="#FF356A",size:a=10}=e;return p(Wt,{width:r,height:i,points:[{x:t,y:n},{x:t+r-a,y:n},{x:t+r,y:n+i/2},{x:t+r-a,y:n+i},{x:t,y:n+i},{x:t+a,y:n+i/2}],fill:o,"data-element-type":"shape"})},Fj=e=>{const{x:t=0,y:n=0,width:r=10,height:i=50,fill:o,positionV:a="top"}=e,s=r/2,c=i-s,l=2,u=s;return L(xt,{x:t,y:n,width:r,height:i,children:[p(Ze,{width:r,height:r,fill:o,y:a==="top"?0:c-s}),p(Pe,{d:a==="top"?`M${u},${s} L${u},${s+c}`:`M${u},0 L${u},${c-s}`,strokeWidth:l,stroke:o})]})};ct("horizontal-icon-arrow",{component:R3,composites:["icon","label","desc","time"]});var Bj=Object.defineProperty,Wj=Object.defineProperties,Gj=Object.getOwnPropertyDescriptors,L3=Object.getOwnPropertySymbols,Vj=Object.prototype.hasOwnProperty,Yj=Object.prototype.propertyIsEnumerable,z3=(e,t,n)=>t in e?Bj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,N3=(e,t)=>{for(var n in t||(t={}))Vj.call(t,n)&&z3(e,n,t[n]);if(L3)for(var n of L3(t))Yj.call(t,n)&&z3(e,n,t[n]);return e},D3=(e,t)=>Wj(e,Gj(t));const H3=e=>{const[{indexes:t,datum:n,width:r=160,themeColors:i,positionH:o="center",positionV:a="normal"},s]=st(e,["width"]),c=o==="normal"?"left":o==="flipped"?"right":"center",l=p(Ge,{indexes:t,width:r,alignHorizontal:c,fill:i.colorPrimary,children:n.label}),u=se(l),h=n.desc?p(ut,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:c,alignVertical:a==="flipped"?"top":"bottom",children:n.desc}):null,d=se(h),g=n.icon?p(kr,{size:45,indexes:t,colorBg:i.colorBg,fill:i.colorPrimary}):null,y=se(g),m=n.time?p(ze,{width:r,height:30,alignHorizontal:"center",alignVertical:"middle",fill:i.colorPrimary,fontSize:18,fontWeight:"bold",children:n.time}):null,v=se(m),b=18,_=L(vi,{horizontal:"center",vertical:"middle",width:r,height:b,children:[p(Re,{width:r,height:b,fill:i.colorPrimary,"data-element-type":"shape"}),p(Ze,{width:b+6,height:b+6,fill:i.colorBg,fillOpacity:.5,"data-element-type":"shape"}),p(Ze,{width:12,height:12,fill:"white","data-element-type":"shape"})]}),x=u.height+d.height,w=y.height+v.height+5,P=Math.abs(w-x),$=w>x?P:0,C=x>w?P:0;return a==="flipped"?L(ve,D3(N3({},s),{flexDirection:"column",alignItems:"center",children:[p(mt,{height:C}),m,g,p(mt,{height:5}),_,l,h,p(mt,{height:$})]})):L(ve,D3(N3({},s),{flexDirection:"column",alignItems:"center",children:[p(mt,{height:$}),l,h,_,p(mt,{height:5}),g,m,p(mt,{height:C})]}))};ct("horizontal-icon-line",{component:H3,composites:["icon","label","desc"]});var Xj=Object.defineProperty,Uj=Object.defineProperties,Kj=Object.getOwnPropertyDescriptors,q3=Object.getOwnPropertySymbols,Zj=Object.prototype.hasOwnProperty,Qj=Object.prototype.propertyIsEnumerable,j3=(e,t,n)=>t in e?Xj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Jj=(e,t)=>{for(var n in t||(t={}))Zj.call(t,n)&&j3(e,n,t[n]);if(q3)for(var n of q3(t))Qj.call(t,n)&&j3(e,n,t[n]);return e},eF=(e,t)=>Uj(e,Kj(t));const F3=e=>{var t;const[{datum:n,indexes:r,size:i=80,iconSize:o=28,badgeSize:a=24,gap:s=8,themeColors:c,width:l=84,height:u=105},h]=st(e,["size","iconSize","badgeSize","gap"]),d=(t=n.value)!=null?t:0,f=`${c.colorPrimary}-icon`,g="#ff6b6b-badge";return L(Y,eF(Jj({},h),{width:l,height:u,children:[L(Ke,{children:[L("radialGradient",{id:f,cx:"50%",cy:"30%",r:"70%",children:[p("stop",{offset:"0%",stopColor:be(c.colorPrimary).lighten(30).toHexString()}),p("stop",{offset:"100%",stopColor:c.colorPrimary})]}),L("linearGradient",{id:g,x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:"#ff6b6b"}),p("stop",{offset:"100%",stopColor:"#ee5a52"})]})]}),p(Ze,{x:0,y:0,width:i,height:i,fill:`url(#${f})`,"data-element-type":"shape"}),p(Ht,{indexes:r,x:(i-o)/2,y:(i-o)/2,size:o,fill:c.colorPrimaryText}),p(Ze,{x:i-a+4,width:a,height:a,fill:`url(#${g})`}),p(ze,{x:i-a+4,width:a,height:a,fontSize:10,fontWeight:"bold",fill:c.colorWhite,alignHorizontal:"center",alignVertical:"middle",children:d>99?"99+":Math.round(d)}),p(Ge,{indexes:r,x:0,y:i+s,width:i,alignHorizontal:"center",fontSize:12,fill:c.colorText,children:n.label})]}))};ct("icon-badge",{component:F3,composites:["icon","label"]});var tF=Object.defineProperty,nF=Object.defineProperties,rF=Object.getOwnPropertyDescriptors,B3=Object.getOwnPropertySymbols,iF=Object.prototype.hasOwnProperty,oF=Object.prototype.propertyIsEnumerable,W3=(e,t,n)=>t in e?tF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,aF=(e,t)=>{for(var n in t||(t={}))iF.call(t,n)&&W3(e,n,t[n]);if(B3)for(var n of B3(t))oF.call(t,n)&&W3(e,n,t[n]);return e},sF=(e,t)=>nF(e,rF(t));const G3=e=>{const[{datum:t,indexes:n,width:r=200,borderRadius:i=12,padding:o=16,separatorHeight:a=2,indexFontSize:s=20,labelFontSize:c=16,gap:l=8,themeColors:u},h]=st(e,["width","height","borderRadius","padding","separatorHeight","indexFontSize","labelFontSize","gap"]),d=n[0]+1,f=String(d).padStart(2,"0"),g=t.label!==void 0,y=t.desc!==void 0,m=be.mix(u.colorPrimary,u.colorWhite,40).toHexString(),v=u.colorBgElevated||u.colorWhite,b=r-2*o,_=se(p(ze,{fontSize:s,fontWeight:"bold",children:f})),x=b-_.width-l,w=g?se(p(Ge,{indexes:n,width:x,fontSize:c,fontWeight:"bold",x:s,children:t.label})):{height:0},P=y?se(p(ut,{indexes:n,width:b,fontSize:14,lineHeight:1.5,wordWrap:!0,children:t.desc})):{height:0},$=Math.max(_.height,w.height),C=o*2+$+(g||y?l:0)+a+(y?l:0)+P.height;return L(Y,sF(aF({},h),{width:r,height:C,children:[p(Re,{x:0,y:0,width:r,height:C,rx:i,ry:i,fill:v,stroke:be(v).darken(5).toHexString(),strokeWidth:.5,"data-element-type":"shape"}),L(Y,{x:o,y:o,children:[L(Y,{x:0,y:0,children:[p(ze,{x:0,y:0,fontSize:s,fontWeight:"bold",fill:u.colorPrimary,alignVertical:"top",children:f}),g&&p(Ge,{indexes:n,x:s+l,y:0,width:x,fontSize:c,fontWeight:"bold",fill:u.colorTextSecondary,alignVertical:"top",children:t.label})]}),p(Re,{x:0,y:$+l,width:b,height:a,fill:m,"data-element-type":"shape"}),y&&p(ut,{indexes:n,x:0,y:$+l+a+l,width:b,fontSize:14,lineHeight:1.5,wordWrap:!0,fill:u.colorTextSecondary,children:t.desc})]})]}))};ct("indexed-card",{component:G3,composites:["label","desc"]});var cF=Object.defineProperty,lF=Object.defineProperties,uF=Object.getOwnPropertyDescriptors,V3=Object.getOwnPropertySymbols,hF=Object.prototype.hasOwnProperty,dF=Object.prototype.propertyIsEnumerable,Y3=(e,t,n)=>t in e?cF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fF=(e,t)=>{for(var n in t||(t={}))hF.call(t,n)&&Y3(e,n,t[n]);if(V3)for(var n of V3(t))dF.call(t,n)&&Y3(e,n,t[n]);return e},pF=(e,t)=>lF(e,uF(t));const X3=e=>{const[{indexes:t,datum:n,width:r=140,iconSize:i=24,themeColors:o},a]=st(e,["width","iconSize"]),{label:s,desc:c}=n,l=8,u=16,h=12,d=u+h,f=r-d,g=60,y=i+44,m=u,v=g+h,b=g+u+h,_=[{x:0,y:b},{x:m,y:v},{x:m,y:b}],x=r-m-h,w=m+h,P=w+x,$=v+l/2,C=$+y,M=`M ${w} ${C} L ${w} ${$} L ${P} ${$}`,S=l/2,E=w+S,A=$+S,O=8;return L(Y,pF(fF({},a),{children:[p(ut,{indexes:t,x:d,width:f,height:g,fontSize:12,alignHorizontal:"left",alignVertical:"bottom",fill:o.colorTextSecondary,children:c}),p(Wt,{points:_,fill:o.colorPrimary,opacity:.9,width:u,height:u,"data-element-type":"shape"}),p(Pe,{d:M,stroke:o.colorPrimary,strokeWidth:l,fill:"none","data-element-type":"shape"}),p(Ht,{indexes:t,x:E+x/2-i/2,y:A+O,size:i,fill:o.colorPrimary}),p(Ge,{indexes:t,x:E,y:A+i+O*2,width:x,fontSize:14,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:o.colorText,children:s})]}))};ct("l-corner-card",{component:X3,composites:["icon","label","desc"]});var gF=Object.defineProperty,mF=Object.defineProperties,yF=Object.getOwnPropertyDescriptors,U3=Object.getOwnPropertySymbols,vF=Object.prototype.hasOwnProperty,bF=Object.prototype.propertyIsEnumerable,K3=(e,t,n)=>t in e?gF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_F=(e,t)=>{for(var n in t||(t={}))vF.call(t,n)&&K3(e,n,t[n]);if(U3)for(var n of U3(t))bF.call(t,n)&&K3(e,n,t[n]);return e},xF=(e,t)=>mF(e,yF(t));const Z3=e=>{var t,n;const[{datum:r,indexes:i,width:o=280,height:a=160,showStripe:s=!0,showGradient:c=!0,showBottomShade:l=!0,themeColors:u},h]=st(e,["width","height","showStripe","showGradient","showBottomShade"]),d=(t=r.label)==null?void 0:t[0].toUpperCase(),f=(n=r.label)==null?void 0:n.toUpperCase(),g=u.colorPrimary,y=be(g),m=4,v=6,b=45,_=40,x=12,P=y.clone().darken(4).toHexString(),$=y.clone().lighten(x).toHexString(),C="rgba(255, 255, 255, 0)",M="rgba(0, 0, 0, 0.03)",S=`letter-card-${i.join("-")}`,E=`${S}-gradient`,A=`${S}-pattern`,O=`${S}-shade`,T=m+v,F=1,z=96,j=z*F,D=16,W=D*F,B=a/16,X=j+B+W,H=(a-X)/2,k=H+j+B;return L(Y,xF(_F({},h),{width:o,height:a,children:[L(Ke,{children:[c&&L("linearGradient",{id:E,x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:P}),p("stop",{offset:"100%",stopColor:$})]}),s&&L("pattern",{id:A,patternUnits:"userSpaceOnUse",width:T,height:T,patternTransform:`rotate(${b})`,children:[p("rect",{x:"0",y:"0",width:T,height:T,fill:C}),p("rect",{x:"0",y:"0",width:m,height:T,fill:M})]}),l&&L("linearGradient",{id:O,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:"rgba(0,0,0,0)"}),p("stop",{offset:"100%",stopColor:"rgba(0,0,0,0.16)"})]})]}),p(Re,{x:0,y:0,width:o,height:a,fill:c?`url(#${E})`:g,rx:0,ry:0,"data-element-type":"shape"}),s&&p(Re,{x:0,y:0,width:o,height:a,fill:`url(#${A})`,rx:0,ry:0}),l&&p(Re,{x:0,y:a-_,width:o,height:_,fill:`url(#${O})`,rx:0,ry:0}),d&&p(Ge,{indexes:i,x:0,y:H,width:o,fontSize:z,fontWeight:"bold",fill:"#FFFFFF",alignHorizontal:"center",alignVertical:"top",lineHeight:1,children:d}),p(Ge,{indexes:i,x:0,y:k,width:o,fontSize:D,fontWeight:"bold",fill:"#FFFFFF",alignHorizontal:"center",alignVertical:"middle",lineHeight:1,children:f})]}))};ct("letter-card",{component:Z3,composites:["label"]});var wF=Object.defineProperty,PF=Object.defineProperties,$F=Object.getOwnPropertyDescriptors,Q3=Object.getOwnPropertySymbols,CF=Object.prototype.hasOwnProperty,OF=Object.prototype.propertyIsEnumerable,J3=(e,t,n)=>t in e?wF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,SF=(e,t)=>{for(var n in t||(t={}))CF.call(t,n)&&J3(e,n,t[n]);if(Q3)for(var n of Q3(t))OF.call(t,n)&&J3(e,n,t[n]);return e},MF=(e,t)=>PF(e,$F(t));const ex=e=>{var t,n,r;const[{datum:i,indexes:o,width:a,themeColors:s,positionH:c="normal",positionV:l="center",formatter:u=F=>F||"",usePaletteColor:h=!1,showUnderline:d=!1,underlineGap:f=6,underlineExtend:g=8,underlineThickness:y=2},m]=st(e,["width","formatter","usePaletteColor","showUnderline","underlineGap","underlineExtend","underlineThickness"]),v=u((n=(t=i.label)!=null?t:i.desc)!=null?n:""),b=c==="flipped"?"right":c==="center"?"center":"left",_=se(p(Ge,{indexes:o,width:a,children:v})),x=a!=null?a:_.width,w=_.height,P=d?x+g*2:0,$=w+(d?f+y:0),C=d?Math.max(x,P):x,M=(r=m.height)!=null?r:$,S=l==="middle"?(M-$)/2:l==="flipped"?M-$:0,E=b==="right"?C-x:b==="center"?(C-x)/2:0,A=S,O=b==="right"?C-P:b==="center"?(C-P)/2:0,T=M;return L(Y,MF(SF({},m),{width:C,height:M,children:[p(Ge,{indexes:o,x:E,y:A,width:x,height:w,alignHorizontal:b,alignVertical:l==="flipped"?"bottom":l==="center"?"middle":"top",fill:h?s.colorPrimary:s.colorText,children:v}),d&&p(Pe,{d:`M 0 ${y/2} L ${P} ${y/2}`,x:O,y:T-y/2,width:P,height:y,stroke:s.colorPrimary,strokeWidth:y,fill:"none",strokeLinecap:"round","data-element-type":"shape"})]}))};ct("lined-text",{component:ex,composites:["label"]});var EF=Object.defineProperty,IF=Object.defineProperties,AF=Object.getOwnPropertyDescriptors,tx=Object.getOwnPropertySymbols,TF=Object.prototype.hasOwnProperty,kF=Object.prototype.propertyIsEnumerable,nx=(e,t,n)=>t in e?EF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,RF=(e,t)=>{for(var n in t||(t={}))TF.call(t,n)&&nx(e,n,t[n]);if(tx)for(var n of tx(t))kF.call(t,n)&&nx(e,n,t[n]);return e},LF=(e,t)=>IF(e,AF(t));const rx=e=>{const[{datum:t,indexes:n,width:r=300,pillWidth:i=120,pillHeight:o=36,gap:a=16,positionH:s="normal",themeColors:c},l]=st(e,["width","pillWidth","pillHeight","gap"]),u=!!t.desc,h=u?r:i,d=u?s==="center"?(h-i)/2:s==="flipped"?h-i:0:0,f=0,g=0,y=o+a,m=h,v=`drop-shadow-${c.colorPrimary}`,b="linear-gradient-white-top-bottom";return L(Y,LF(RF({},l),{children:[L(Ke,{children:[p(sh,{id:v,color:c.colorPrimary}),p(ch,{id:b,startColor:"#fff",stopColor:"#ffffff33",direction:"top-bottom"})]}),p(Re,{x:d,y:f,width:i,height:o,fill:c.colorPrimaryBg,stroke:c.colorPrimary,rx:o/2,ry:o/2,filter:`url(#${v})`,"data-element-type":"shape"}),p(Re,{x:d,y:f,width:i,height:o,fill:`url(#${b})`,opacity:c.isDarkMode?.4:.7,rx:o/2,ry:o/2}),p(Ge,{indexes:n,x:d,y:f,width:i,height:o,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"500",fill:c.colorText,children:t.label}),t.desc&&p(ut,{indexes:n,x:g,y,width:m,alignHorizontal:s==="center"?"center":s==="flipped"?"right":"left",fontSize:12,fill:c.colorTextSecondary,lineNumber:2,wordWrap:!0,children:t.desc})]}))};ct("pill-badge",{component:rx,composites:["label","desc"]});var zF=Object.defineProperty,NF=Object.defineProperties,DF=Object.getOwnPropertyDescriptors,ix=Object.getOwnPropertySymbols,HF=Object.prototype.hasOwnProperty,qF=Object.prototype.propertyIsEnumerable,ox=(e,t,n)=>t in e?zF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,jF=(e,t)=>{for(var n in t||(t={}))HF.call(t,n)&&ox(e,n,t[n]);if(ix)for(var n of ix(t))qF.call(t,n)&&ox(e,n,t[n]);return e},FF=(e,t)=>NF(e,DF(t));const ax=e=>{var t;const[{indexes:n,datum:r,width:i=120,themeColors:o,positionH:a="normal",positionV:s="center",formatter:c=y=>y||"",usePaletteColor:l=!1,lineNumber:u=1},h]=st(e,["width","formatter","usePaletteColor","lineNumber"]),d=14,f=1.4,g=(t=h.height)!=null?t:Math.ceil(u*f*d);return p(Ge,FF(jF({},h),{indexes:n,width:i,height:g,lineHeight:f,fill:l?o.colorPrimary:o.colorText,fontSize:d,fontWeight:"regular",alignHorizontal:a==="flipped"?"right":a==="center"?"center":"left",alignVertical:s==="flipped"?"bottom":s==="center"?"middle":"top",children:c(r.label||r.desc)}))};ct("plain-text",{component:ax,composites:["label"]});function Es(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function BF(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function sx(e){let t,n,r;e.length!==2?(t=Es,n=(s,c)=>Es(e(s),c),r=(s,c)=>e(s)-c):(t=e===Es||e===BF?e:WF,n=e,r=e);function i(s,c,l=0,u=s.length){if(l<u){if(t(c,c)!==0)return u;do{const h=l+u>>>1;n(s[h],c)<0?l=h+1:u=h}while(l<u)}return l}function o(s,c,l=0,u=s.length){if(l<u){if(t(c,c)!==0)return u;do{const h=l+u>>>1;n(s[h],c)<=0?l=h+1:u=h}while(l<u)}return l}function a(s,c,l=0,u=s.length){const h=i(s,c,l,u-1);return h>l&&r(s[h-1],c)>-r(s[h],c)?h-1:h}return{left:i,center:a,right:o}}function WF(){return 0}function GF(e){return e===null?NaN:+e}const VF=sx(Es).right;sx(GF).center;const YF=Math.sqrt(50),XF=Math.sqrt(10),UF=Math.sqrt(2);function Is(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=YF?10:o>=XF?5:o>=UF?2:1;let s,c,l;return i<0?(l=Math.pow(10,-i)/a,s=Math.round(e*l),c=Math.round(t*l),s/l<e&&++s,c/l>t&&--c,l=-l):(l=Math.pow(10,i)*a,s=Math.round(e/l),c=Math.round(t/l),s*l<e&&++s,c*l>t&&--c),c<s&&.5<=n&&n<2?Is(e,t,n*2):[s,c,l]}function KF(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,a]=r?Is(t,e,n):Is(e,t,n);if(!(o>=i))return[];const s=o-i+1,c=new Array(s);if(r)if(a<0)for(let l=0;l<s;++l)c[l]=(o-l)/-a;else for(let l=0;l<s;++l)c[l]=(o-l)*a;else if(a<0)for(let l=0;l<s;++l)c[l]=(i+l)/-a;else for(let l=0;l<s;++l)c[l]=(i+l)*a;return c}function fh(e,t,n){return t=+t,e=+e,n=+n,Is(e,t,n)[2]}function ZF(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?fh(t,e,n):fh(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}var QF={value:()=>{}};function ph(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new As(n)}function As(e){this._=e}function JF(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}As.prototype=ph.prototype={constructor:As,on:function(e,t){var n=this._,r=JF(e+"",n),i,o=-1,a=r.length;if(arguments.length<2){for(;++o<a;)if((i=(e=r[o]).type)&&(i=eB(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<a;)if(i=(e=r[o]).type)n[i]=cx(n[i],e.name,t);else if(t==null)for(i in n)n[i]=cx(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new As(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,o;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],r=0,i=o.length;r<i;++r)o[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,o=r.length;i<o;++i)r[i].value.apply(t,n)}};function eB(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function cx(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=QF,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var gh="http://www.w3.org/1999/xhtml";const lx={svg:"http://www.w3.org/2000/svg",xhtml:gh,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ts(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),lx.hasOwnProperty(t)?{space:lx[t],local:e}:e}function tB(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===gh&&t.documentElement.namespaceURI===gh?t.createElement(e):t.createElementNS(n,e)}}function nB(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function ux(e){var t=Ts(e);return(t.local?nB:tB)(t)}function rB(){}function mh(e){return e==null?rB:function(){return this.querySelector(e)}}function iB(e){typeof e!="function"&&(e=mh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],a=o.length,s=r[i]=new Array(a),c,l,u=0;u<a;++u)(c=o[u])&&(l=e.call(c,c.__data__,u,o))&&("__data__"in c&&(l.__data__=c.__data__),s[u]=l);return new pn(r,this._parents)}function oB(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function aB(){return[]}function hx(e){return e==null?aB:function(){return this.querySelectorAll(e)}}function sB(e){return function(){return oB(e.apply(this,arguments))}}function cB(e){typeof e=="function"?e=sB(e):e=hx(e);for(var t=this._groups,n=t.length,r=[],i=[],o=0;o<n;++o)for(var a=t[o],s=a.length,c,l=0;l<s;++l)(c=a[l])&&(r.push(e.call(c,c.__data__,l,a)),i.push(c));return new pn(r,i)}function dx(e){return function(){return this.matches(e)}}function fx(e){return function(t){return t.matches(e)}}var lB=Array.prototype.find;function uB(e){return function(){return lB.call(this.children,e)}}function hB(){return this.firstElementChild}function dB(e){return this.select(e==null?hB:uB(typeof e=="function"?e:fx(e)))}var fB=Array.prototype.filter;function pB(){return Array.from(this.children)}function gB(e){return function(){return fB.call(this.children,e)}}function mB(e){return this.selectAll(e==null?pB:gB(typeof e=="function"?e:fx(e)))}function yB(e){typeof e!="function"&&(e=dx(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],a=o.length,s=r[i]=[],c,l=0;l<a;++l)(c=o[l])&&e.call(c,c.__data__,l,o)&&s.push(c);return new pn(r,this._parents)}function px(e){return new Array(e.length)}function vB(){return new pn(this._enter||this._groups.map(px),this._parents)}function ks(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}ks.prototype={constructor:ks,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function bB(e){return function(){return e}}function _B(e,t,n,r,i,o){for(var a=0,s,c=t.length,l=o.length;a<l;++a)(s=t[a])?(s.__data__=o[a],r[a]=s):n[a]=new ks(e,o[a]);for(;a<c;++a)(s=t[a])&&(i[a]=s)}function xB(e,t,n,r,i,o,a){var s,c,l=new Map,u=t.length,h=o.length,d=new Array(u),f;for(s=0;s<u;++s)(c=t[s])&&(d[s]=f=a.call(c,c.__data__,s,t)+"",l.has(f)?i[s]=c:l.set(f,c));for(s=0;s<h;++s)f=a.call(e,o[s],s,o)+"",(c=l.get(f))?(r[s]=c,c.__data__=o[s],l.delete(f)):n[s]=new ks(e,o[s]);for(s=0;s<u;++s)(c=t[s])&&l.get(d[s])===c&&(i[s]=c)}function wB(e){return e.__data__}function PB(e,t){if(!arguments.length)return Array.from(this,wB);var n=t?xB:_B,r=this._parents,i=this._groups;typeof e!="function"&&(e=bB(e));for(var o=i.length,a=new Array(o),s=new Array(o),c=new Array(o),l=0;l<o;++l){var u=r[l],h=i[l],d=h.length,f=$B(e.call(u,u&&u.__data__,l,r)),g=f.length,y=s[l]=new Array(g),m=a[l]=new Array(g),v=c[l]=new Array(d);n(u,h,y,m,v,f,t);for(var b=0,_=0,x,w;b<g;++b)if(x=y[b]){for(b>=_&&(_=b+1);!(w=m[_])&&++_<g;);x._next=w||null}}return a=new pn(a,r),a._enter=s,a._exit=c,a}function $B(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function CB(){return new pn(this._exit||this._groups.map(px),this._parents)}function OB(e,t,n){var r=this.enter(),i=this,o=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?o.remove():n(o),r&&i?r.merge(i).order():i}function SB(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,o=r.length,a=Math.min(i,o),s=new Array(i),c=0;c<a;++c)for(var l=n[c],u=r[c],h=l.length,d=s[c]=new Array(h),f,g=0;g<h;++g)(f=l[g]||u[g])&&(d[g]=f);for(;c<i;++c)s[c]=n[c];return new pn(s,this._parents)}function MB(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,o=r[i],a;--i>=0;)(a=r[i])&&(o&&a.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(a,o),o=a);return this}function EB(e){e||(e=IB);function t(h,d){return h&&d?e(h.__data__,d.__data__):!h-!d}for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a=n[o],s=a.length,c=i[o]=new Array(s),l,u=0;u<s;++u)(l=a[u])&&(c[u]=l);c.sort(t)}return new pn(i,this._parents).order()}function IB(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function AB(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function TB(){return Array.from(this)}function kB(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null}function RB(){let e=0;for(const t of this)++e;return e}function LB(){return!this.node()}function zB(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],o=0,a=i.length,s;o<a;++o)(s=i[o])&&e.call(s,s.__data__,o,i);return this}function NB(e){return function(){this.removeAttribute(e)}}function DB(e){return function(){this.removeAttributeNS(e.space,e.local)}}function HB(e,t){return function(){this.setAttribute(e,t)}}function qB(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function jB(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function FB(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function BB(e,t){var n=Ts(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?DB:NB:typeof t=="function"?n.local?FB:jB:n.local?qB:HB)(n,t))}function gx(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function WB(e){return function(){this.style.removeProperty(e)}}function GB(e,t,n){return function(){this.style.setProperty(e,t,n)}}function VB(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function YB(e,t,n){return arguments.length>1?this.each((t==null?WB:typeof t=="function"?VB:GB)(e,t,n==null?"":n)):bi(this.node(),e)}function bi(e,t){return e.style.getPropertyValue(t)||gx(e).getComputedStyle(e,null).getPropertyValue(t)}function XB(e){return function(){delete this[e]}}function UB(e,t){return function(){this[e]=t}}function KB(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function ZB(e,t){return arguments.length>1?this.each((t==null?XB:typeof t=="function"?KB:UB)(e,t)):this.node()[e]}function mx(e){return e.trim().split(/^|\s+/)}function yh(e){return e.classList||new yx(e)}function yx(e){this._node=e,this._names=mx(e.getAttribute("class")||"")}yx.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function vx(e,t){for(var n=yh(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function bx(e,t){for(var n=yh(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function QB(e){return function(){vx(this,e)}}function JB(e){return function(){bx(this,e)}}function eW(e,t){return function(){(t.apply(this,arguments)?vx:bx)(this,e)}}function tW(e,t){var n=mx(e+"");if(arguments.length<2){for(var r=yh(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?eW:t?QB:JB)(n,t))}function nW(){this.textContent=""}function rW(e){return function(){this.textContent=e}}function iW(e){return function(){var t=e.apply(this,arguments);this.textContent=t==null?"":t}}function oW(e){return arguments.length?this.each(e==null?nW:(typeof e=="function"?iW:rW)(e)):this.node().textContent}function aW(){this.innerHTML=""}function sW(e){return function(){this.innerHTML=e}}function cW(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t==null?"":t}}function lW(e){return arguments.length?this.each(e==null?aW:(typeof e=="function"?cW:sW)(e)):this.node().innerHTML}function uW(){this.nextSibling&&this.parentNode.appendChild(this)}function hW(){return this.each(uW)}function dW(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function fW(){return this.each(dW)}function pW(e){var t=typeof e=="function"?e:ux(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function gW(){return null}function mW(e,t){var n=typeof e=="function"?e:ux(e),r=t==null?gW:typeof t=="function"?t:mh(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function yW(){var e=this.parentNode;e&&e.removeChild(this)}function vW(){return this.each(yW)}function bW(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function _W(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function xW(e){return this.select(e?_W:bW)}function wW(e){return arguments.length?this.property("__data__",e):this.node().__data__}function PW(e){return function(t){e.call(this,t,this.__data__)}}function $W(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function CW(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,o;n<i;++n)o=t[n],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++r]=o;++r?t.length=r:delete this.__on}}}function OW(e,t,n){return function(){var r=this.__on,i,o=PW(t);if(r){for(var a=0,s=r.length;a<s;++a)if((i=r[a]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=n),i.value=t;return}}this.addEventListener(e.type,o,n),i={type:e.type,name:e.name,value:t,listener:o,options:n},r?r.push(i):this.__on=[i]}}function SW(e,t,n){var r=$W(e+""),i,o=r.length,a;if(arguments.length<2){var s=this.node().__on;if(s){for(var c=0,l=s.length,u;c<l;++c)for(i=0,u=s[c];i<o;++i)if((a=r[i]).type===u.type&&a.name===u.name)return u.value}return}for(s=t?OW:CW,i=0;i<o;++i)this.each(s(r[i],t,n));return this}function _x(e,t,n){var r=gx(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function MW(e,t){return function(){return _x(this,e,t)}}function EW(e,t){return function(){return _x(this,e,t.apply(this,arguments))}}function IW(e,t){return this.each((typeof t=="function"?EW:MW)(e,t))}function*AW(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length,a;i<o;++i)(a=r[i])&&(yield a)}var TW=[null];function pn(e,t){this._groups=e,this._parents=t}function Oo(){return new pn([[document.documentElement]],TW)}function kW(){return this}pn.prototype=Oo.prototype={constructor:pn,select:iB,selectAll:cB,selectChild:dB,selectChildren:mB,filter:yB,data:PB,enter:vB,exit:CB,join:OB,merge:SB,selection:kW,order:MB,sort:EB,call:AB,nodes:TB,node:kB,size:RB,empty:LB,each:zB,attr:BB,style:YB,property:ZB,classed:tW,text:oW,html:lW,raise:hW,lower:fW,append:pW,insert:mW,remove:vW,clone:xW,datum:wW,on:SW,dispatch:IW,[Symbol.iterator]:AW};function vh(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function xx(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function So(){}var Mo=.7,Rs=1/Mo,_i="\\s*([+-]?\\d+)\\s*",Eo="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Mn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",RW=/^#([0-9a-f]{3,8})$/,LW=new RegExp(`^rgb\\(${_i},${_i},${_i}\\)$`),zW=new RegExp(`^rgb\\(${Mn},${Mn},${Mn}\\)$`),NW=new RegExp(`^rgba\\(${_i},${_i},${_i},${Eo}\\)$`),DW=new RegExp(`^rgba\\(${Mn},${Mn},${Mn},${Eo}\\)$`),HW=new RegExp(`^hsl\\(${Eo},${Mn},${Mn}\\)$`),qW=new RegExp(`^hsla\\(${Eo},${Mn},${Mn},${Eo}\\)$`),wx={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};vh(So,Lr,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Px,formatHex:Px,formatHex8:jW,formatHsl:FW,formatRgb:$x,toString:$x});function Px(){return this.rgb().formatHex()}function jW(){return this.rgb().formatHex8()}function FW(){return Ex(this).formatHsl()}function $x(){return this.rgb().formatRgb()}function Lr(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=RW.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Cx(t):n===3?new en(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Ls(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Ls(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=LW.exec(e))?new en(t[1],t[2],t[3],1):(t=zW.exec(e))?new en(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=NW.exec(e))?Ls(t[1],t[2],t[3],t[4]):(t=DW.exec(e))?Ls(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=HW.exec(e))?Mx(t[1],t[2]/100,t[3]/100,1):(t=qW.exec(e))?Mx(t[1],t[2]/100,t[3]/100,t[4]):wx.hasOwnProperty(e)?Cx(wx[e]):e==="transparent"?new en(NaN,NaN,NaN,0):null}function Cx(e){return new en(e>>16&255,e>>8&255,e&255,1)}function Ls(e,t,n,r){return r<=0&&(e=t=n=NaN),new en(e,t,n,r)}function BW(e){return e instanceof So||(e=Lr(e)),e?(e=e.rgb(),new en(e.r,e.g,e.b,e.opacity)):new en}function bh(e,t,n,r){return arguments.length===1?BW(e):new en(e,t,n,r==null?1:r)}function en(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}vh(en,bh,xx(So,{brighter(e){return e=e==null?Rs:Math.pow(Rs,e),new en(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Mo:Math.pow(Mo,e),new en(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new en(zr(this.r),zr(this.g),zr(this.b),zs(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Ox,formatHex:Ox,formatHex8:WW,formatRgb:Sx,toString:Sx}));function Ox(){return`#${Nr(this.r)}${Nr(this.g)}${Nr(this.b)}`}function WW(){return`#${Nr(this.r)}${Nr(this.g)}${Nr(this.b)}${Nr((isNaN(this.opacity)?1:this.opacity)*255)}`}function Sx(){const e=zs(this.opacity);return`${e===1?"rgb(":"rgba("}${zr(this.r)}, ${zr(this.g)}, ${zr(this.b)}${e===1?")":`, ${e})`}`}function zs(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function zr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Nr(e){return e=zr(e),(e<16?"0":"")+e.toString(16)}function Mx(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new gn(e,t,n,r)}function Ex(e){if(e instanceof gn)return new gn(e.h,e.s,e.l,e.opacity);if(e instanceof So||(e=Lr(e)),!e)return new gn;if(e instanceof gn)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,c=(o+i)/2;return s?(t===o?a=(n-r)/s+(n<r)*6:n===o?a=(r-t)/s+2:a=(t-n)/s+4,s/=c<.5?o+i:2-o-i,a*=60):s=c>0&&c<1?0:a,new gn(a,s,c,e.opacity)}function GW(e,t,n,r){return arguments.length===1?Ex(e):new gn(e,t,n,r==null?1:r)}function gn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}vh(gn,GW,xx(So,{brighter(e){return e=e==null?Rs:Math.pow(Rs,e),new gn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Mo:Math.pow(Mo,e),new gn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new en(_h(e>=240?e-240:e+120,i,r),_h(e,i,r),_h(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new gn(Ix(this.h),Ns(this.s),Ns(this.l),zs(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=zs(this.opacity);return`${e===1?"hsl(":"hsla("}${Ix(this.h)}, ${Ns(this.s)*100}%, ${Ns(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ix(e){return e=(e||0)%360,e<0?e+360:e}function Ns(e){return Math.max(0,Math.min(1,e||0))}function _h(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const xh=e=>()=>e;function VW(e,t){return function(n){return e+n*t}}function YW(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function XW(e){return(e=+e)==1?Ax:function(t,n){return n-t?YW(t,n,e):xh(isNaN(t)?n:t)}}function Ax(e,t){var n=t-e;return n?VW(e,n):xh(isNaN(e)?t:e)}const Ds=(function e(t){var n=XW(t);function r(i,o){var a=n((i=bh(i)).r,(o=bh(o)).r),s=n(i.g,o.g),c=n(i.b,o.b),l=Ax(i.opacity,o.opacity);return function(u){return i.r=a(u),i.g=s(u),i.b=c(u),i.opacity=l(u),i+""}}return r.gamma=e,r})(1);function UW(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function KW(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function ZW(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),a;for(a=0;a<r;++a)i[a]=$h(e[a],t[a]);for(;a<n;++a)o[a]=t[a];return function(s){for(a=0;a<r;++a)o[a]=i[a](s);return o}}function QW(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function mn(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function JW(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=$h(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var wh=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Ph=new RegExp(wh.source,"g");function eG(e){return function(){return e}}function tG(e){return function(t){return e(t)+""}}function Tx(e,t){var n=wh.lastIndex=Ph.lastIndex=0,r,i,o,a=-1,s=[],c=[];for(e=e+"",t=t+"";(r=wh.exec(e))&&(i=Ph.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,c.push({i:a,x:mn(r,i)})),n=Ph.lastIndex;return n<t.length&&(o=t.slice(n),s[a]?s[a]+=o:s[++a]=o),s.length<2?c[0]?tG(c[0].x):eG(t):(t=c.length,function(l){for(var u=0,h;u<t;++u)s[(h=c[u]).i]=h.x(l);return s.join("")})}function $h(e,t){var n=typeof t,r;return t==null||n==="boolean"?xh(t):(n==="number"?mn:n==="string"?(r=Lr(t))?(t=r,Ds):Tx:t instanceof Lr?Ds:t instanceof Date?QW:KW(t)?UW:Array.isArray(t)?ZW:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?JW:mn)(e,t)}function nG(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var kx=180/Math.PI,Ch={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Rx(e,t,n,r,i,o){var a,s,c;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(c=e*n+t*r)&&(n-=e*c,r-=t*c),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,c/=s),e*r<t*n&&(e=-e,t=-t,c=-c,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*kx,skewX:Math.atan(c)*kx,scaleX:a,scaleY:s}}var Hs;function rG(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Ch:Rx(t.a,t.b,t.c,t.d,t.e,t.f)}function iG(e){return e==null||(Hs||(Hs=document.createElementNS("http://www.w3.org/2000/svg","g")),Hs.setAttribute("transform",e),!(e=Hs.transform.baseVal.consolidate()))?Ch:(e=e.matrix,Rx(e.a,e.b,e.c,e.d,e.e,e.f))}function Lx(e,t,n,r){function i(l){return l.length?l.pop()+" ":""}function o(l,u,h,d,f,g){if(l!==h||u!==d){var y=f.push("translate(",null,t,null,n);g.push({i:y-4,x:mn(l,h)},{i:y-2,x:mn(u,d)})}else(h||d)&&f.push("translate("+h+t+d+n)}function a(l,u,h,d){l!==u?(l-u>180?u+=360:u-l>180&&(l+=360),d.push({i:h.push(i(h)+"rotate(",null,r)-2,x:mn(l,u)})):u&&h.push(i(h)+"rotate("+u+r)}function s(l,u,h,d){l!==u?d.push({i:h.push(i(h)+"skewX(",null,r)-2,x:mn(l,u)}):u&&h.push(i(h)+"skewX("+u+r)}function c(l,u,h,d,f,g){if(l!==h||u!==d){var y=f.push(i(f)+"scale(",null,",",null,")");g.push({i:y-4,x:mn(l,h)},{i:y-2,x:mn(u,d)})}else(h!==1||d!==1)&&f.push(i(f)+"scale("+h+","+d+")")}return function(l,u){var h=[],d=[];return l=e(l),u=e(u),o(l.translateX,l.translateY,u.translateX,u.translateY,h,d),a(l.rotate,u.rotate,h,d),s(l.skewX,u.skewX,h,d),c(l.scaleX,l.scaleY,u.scaleX,u.scaleY,h,d),l=u=null,function(f){for(var g=-1,y=d.length,m;++g<y;)h[(m=d[g]).i]=m.x(f);return h.join("")}}}var oG=Lx(rG,"px, ","px)","deg)"),aG=Lx(iG,", ",")",")"),xi=0,Io=0,Ao=0,zx=1e3,qs,To,js=0,Dr=0,Fs=0,ko=typeof performance=="object"&&performance.now?performance:Date,Nx=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Oh(){return Dr||(Nx(sG),Dr=ko.now()+Fs)}function sG(){Dr=0}function Bs(){this._call=this._time=this._next=null}Bs.prototype=Sh.prototype={constructor:Bs,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Oh():+n)+(t==null?0:+t),!this._next&&To!==this&&(To?To._next=this:qs=this,To=this),this._call=e,this._time=n,Mh()},stop:function(){this._call&&(this._call=null,this._time=1/0,Mh())}};function Sh(e,t,n){var r=new Bs;return r.restart(e,t,n),r}function cG(){Oh(),++xi;for(var e=qs,t;e;)(t=Dr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--xi}function Dx(){Dr=(js=ko.now())+Fs,xi=Io=0;try{cG()}finally{xi=0,uG(),Dr=0}}function lG(){var e=ko.now(),t=e-js;t>zx&&(Fs-=t,js=e)}function uG(){for(var e,t=qs,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:qs=n);To=e,Mh(r)}function Mh(e){if(!xi){Io&&(Io=clearTimeout(Io));var t=e-Dr;t>24?(e<1/0&&(Io=setTimeout(Dx,e-ko.now()-Fs)),Ao&&(Ao=clearInterval(Ao))):(Ao||(js=ko.now(),Ao=setInterval(lG,zx)),xi=1,Nx(Dx))}}function Hx(e,t,n){var r=new Bs;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var hG=ph("start","end","cancel","interrupt"),dG=[],qx=0,jx=1,Eh=2,Ws=3,Fx=4,Ih=5,Gs=6;function Vs(e,t,n,r,i,o){var a=e.__transition;if(!a)e.__transition={};else if(n in a)return;fG(e,n,{name:t,index:r,group:i,on:hG,tween:dG,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:qx})}function Ah(e,t){var n=yn(e,t);if(n.state>qx)throw new Error("too late; already scheduled");return n}function En(e,t){var n=yn(e,t);if(n.state>Ws)throw new Error("too late; already running");return n}function yn(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function fG(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=Sh(o,0,n.time);function o(l){n.state=jx,n.timer.restart(a,n.delay,n.time),n.delay<=l&&a(l-n.delay)}function a(l){var u,h,d,f;if(n.state!==jx)return c();for(u in r)if(f=r[u],f.name===n.name){if(f.state===Ws)return Hx(a);f.state===Fx?(f.state=Gs,f.timer.stop(),f.on.call("interrupt",e,e.__data__,f.index,f.group),delete r[u]):+u<t&&(f.state=Gs,f.timer.stop(),f.on.call("cancel",e,e.__data__,f.index,f.group),delete r[u])}if(Hx(function(){n.state===Ws&&(n.state=Fx,n.timer.restart(s,n.delay,n.time),s(l))}),n.state=Eh,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Eh){for(n.state=Ws,i=new Array(d=n.tween.length),u=0,h=-1;u<d;++u)(f=n.tween[u].value.call(e,e.__data__,n.index,n.group))&&(i[++h]=f);i.length=h+1}}function s(l){for(var u=l<n.duration?n.ease.call(null,l/n.duration):(n.timer.restart(c),n.state=Ih,1),h=-1,d=i.length;++h<d;)i[h].call(e,u);n.state===Ih&&(n.on.call("end",e,e.__data__,n.index,n.group),c())}function c(){n.state=Gs,n.timer.stop(),delete r[t];for(var l in r)return;delete e.__transition}}function pG(e,t){var n=e.__transition,r,i,o=!0,a;if(n){t=t==null?null:t+"";for(a in n){if((r=n[a]).name!==t){o=!1;continue}i=r.state>Eh&&r.state<Ih,r.state=Gs,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[a]}o&&delete e.__transition}}function gG(e){return this.each(function(){pG(this,e)})}function mG(e,t){var n,r;return function(){var i=En(this,e),o=i.tween;if(o!==n){r=n=o;for(var a=0,s=r.length;a<s;++a)if(r[a].name===t){r=r.slice(),r.splice(a,1);break}}i.tween=r}}function yG(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var o=En(this,e),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:t,value:n},c=0,l=i.length;c<l;++c)if(i[c].name===t){i[c]=s;break}c===l&&i.push(s)}o.tween=i}}function vG(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=yn(this.node(),n).tween,i=0,o=r.length,a;i<o;++i)if((a=r[i]).name===e)return a.value;return null}return this.each((t==null?mG:yG)(n,e,t))}function Th(e,t,n){var r=e._id;return e.each(function(){var i=En(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return yn(i,r).value[t]}}function Bx(e,t){var n;return(typeof t=="number"?mn:t instanceof Lr?Ds:(n=Lr(t))?(t=n,Ds):Tx)(e,t)}function bG(e){return function(){this.removeAttribute(e)}}function _G(e){return function(){this.removeAttributeNS(e.space,e.local)}}function xG(e,t,n){var r,i=n+"",o;return function(){var a=this.getAttribute(e);return a===i?null:a===r?o:o=t(r=a,n)}}function wG(e,t,n){var r,i=n+"",o;return function(){var a=this.getAttributeNS(e.space,e.local);return a===i?null:a===r?o:o=t(r=a,n)}}function PG(e,t,n){var r,i,o;return function(){var a,s=n(this),c;return s==null?void this.removeAttribute(e):(a=this.getAttribute(e),c=s+"",a===c?null:a===r&&c===i?o:(i=c,o=t(r=a,s)))}}function $G(e,t,n){var r,i,o;return function(){var a,s=n(this),c;return s==null?void this.removeAttributeNS(e.space,e.local):(a=this.getAttributeNS(e.space,e.local),c=s+"",a===c?null:a===r&&c===i?o:(i=c,o=t(r=a,s)))}}function CG(e,t){var n=Ts(e),r=n==="transform"?aG:Bx;return this.attrTween(e,typeof t=="function"?(n.local?$G:PG)(n,r,Th(this,"attr."+e,t)):t==null?(n.local?_G:bG)(n):(n.local?wG:xG)(n,r,t))}function OG(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function SG(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function MG(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&SG(e,o)),n}return i._value=t,i}function EG(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&OG(e,o)),n}return i._value=t,i}function IG(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=Ts(e);return this.tween(n,(r.local?MG:EG)(r,t))}function AG(e,t){return function(){Ah(this,e).delay=+t.apply(this,arguments)}}function TG(e,t){return t=+t,function(){Ah(this,e).delay=t}}function kG(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?AG:TG)(t,e)):yn(this.node(),t).delay}function RG(e,t){return function(){En(this,e).duration=+t.apply(this,arguments)}}function LG(e,t){return t=+t,function(){En(this,e).duration=t}}function zG(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?RG:LG)(t,e)):yn(this.node(),t).duration}function NG(e,t){if(typeof t!="function")throw new Error;return function(){En(this,e).ease=t}}function DG(e){var t=this._id;return arguments.length?this.each(NG(t,e)):yn(this.node(),t).ease}function HG(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;En(this,e).ease=n}}function qG(e){if(typeof e!="function")throw new Error;return this.each(HG(this._id,e))}function jG(e){typeof e!="function"&&(e=dx(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],a=o.length,s=r[i]=[],c,l=0;l<a;++l)(c=o[l])&&e.call(c,c.__data__,l,o)&&s.push(c);return new Bn(r,this._parents,this._name,this._id)}function FG(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var c=t[s],l=n[s],u=c.length,h=a[s]=new Array(u),d,f=0;f<u;++f)(d=c[f]||l[f])&&(h[f]=d);for(;s<r;++s)a[s]=t[s];return new Bn(a,this._parents,this._name,this._id)}function BG(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function WG(e,t,n){var r,i,o=BG(t)?Ah:En;return function(){var a=o(this,e),s=a.on;s!==r&&(i=(r=s).copy()).on(t,n),a.on=i}}function GG(e,t){var n=this._id;return arguments.length<2?yn(this.node(),n).on.on(e):this.each(WG(n,e,t))}function VG(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function YG(){return this.on("end.remove",VG(this._id))}function XG(e){var t=this._name,n=this._id;typeof e!="function"&&(e=mh(e));for(var r=this._groups,i=r.length,o=new Array(i),a=0;a<i;++a)for(var s=r[a],c=s.length,l=o[a]=new Array(c),u,h,d=0;d<c;++d)(u=s[d])&&(h=e.call(u,u.__data__,d,s))&&("__data__"in u&&(h.__data__=u.__data__),l[d]=h,Vs(l[d],t,n,d,l,yn(u,n)));return new Bn(o,this._parents,t,n)}function UG(e){var t=this._name,n=this._id;typeof e!="function"&&(e=hx(e));for(var r=this._groups,i=r.length,o=[],a=[],s=0;s<i;++s)for(var c=r[s],l=c.length,u,h=0;h<l;++h)if(u=c[h]){for(var d=e.call(u,u.__data__,h,c),f,g=yn(u,n),y=0,m=d.length;y<m;++y)(f=d[y])&&Vs(f,t,n,y,d,g);o.push(d),a.push(u)}return new Bn(o,a,t,n)}var KG=Oo.prototype.constructor;function ZG(){return new KG(this._groups,this._parents)}function QG(e,t){var n,r,i;return function(){var o=bi(this,e),a=(this.style.removeProperty(e),bi(this,e));return o===a?null:o===n&&a===r?i:i=t(n=o,r=a)}}function Wx(e){return function(){this.style.removeProperty(e)}}function JG(e,t,n){var r,i=n+"",o;return function(){var a=bi(this,e);return a===i?null:a===r?o:o=t(r=a,n)}}function eV(e,t,n){var r,i,o;return function(){var a=bi(this,e),s=n(this),c=s+"";return s==null&&(c=s=(this.style.removeProperty(e),bi(this,e))),a===c?null:a===r&&c===i?o:(i=c,o=t(r=a,s))}}function tV(e,t){var n,r,i,o="style."+t,a="end."+o,s;return function(){var c=En(this,e),l=c.on,u=c.value[o]==null?s||(s=Wx(t)):void 0;(l!==n||i!==u)&&(r=(n=l).copy()).on(a,i=u),c.on=r}}function nV(e,t,n){var r=(e+="")=="transform"?oG:Bx;return t==null?this.styleTween(e,QG(e,r)).on("end.style."+e,Wx(e)):typeof t=="function"?this.styleTween(e,eV(e,r,Th(this,"style."+e,t))).each(tV(this._id,e)):this.styleTween(e,JG(e,r,t),n).on("end.style."+e,null)}function rV(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function iV(e,t,n){var r,i;function o(){var a=t.apply(this,arguments);return a!==i&&(r=(i=a)&&rV(e,a,n)),r}return o._value=t,o}function oV(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,iV(e,t,n==null?"":n))}function aV(e){return function(){this.textContent=e}}function sV(e){return function(){var t=e(this);this.textContent=t==null?"":t}}function cV(e){return this.tween("text",typeof e=="function"?sV(Th(this,"text",e)):aV(e==null?"":e+""))}function lV(e){return function(t){this.textContent=e.call(this,t)}}function uV(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&lV(i)),t}return r._value=e,r}function hV(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,uV(e))}function dV(){for(var e=this._name,t=this._id,n=Gx(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a=r[o],s=a.length,c,l=0;l<s;++l)if(c=a[l]){var u=yn(c,t);Vs(c,e,n,l,a,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new Bn(r,this._parents,e,n)}function fV(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(o,a){var s={value:a},c={value:function(){--i===0&&o()}};n.each(function(){var l=En(this,r),u=l.on;u!==e&&(t=(e=u).copy(),t._.cancel.push(s),t._.interrupt.push(s),t._.end.push(c)),l.on=t}),i===0&&o()})}var pV=0;function Bn(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function Gx(){return++pV}var Wn=Oo.prototype;Bn.prototype={constructor:Bn,select:XG,selectAll:UG,selectChild:Wn.selectChild,selectChildren:Wn.selectChildren,filter:jG,merge:FG,selection:ZG,transition:dV,call:Wn.call,nodes:Wn.nodes,node:Wn.node,size:Wn.size,empty:Wn.empty,each:Wn.each,on:GG,attr:CG,attrTween:IG,style:nV,styleTween:oV,text:cV,textTween:hV,remove:YG,tween:vG,delay:kG,duration:zG,ease:DG,easeVarying:qG,end:fV,[Symbol.iterator]:Wn[Symbol.iterator]};function gV(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var mV={time:null,delay:0,duration:250,ease:gV};function yV(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function vV(e){var t,n;e instanceof Bn?(t=e._id,e=e._name):(t=Gx(),(n=mV).time=Oh(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a=r[o],s=a.length,c,l=0;l<s;++l)(c=a[l])&&Vs(c,e,t,l,a,n||yV(c,t));return new Bn(r,this._parents,e,t)}Oo.prototype.interrupt=gG,Oo.prototype.transition=vV;const kh=Math.PI,Rh=2*kh,Hr=1e-6,bV=Rh-Hr;function Vx(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function _V(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Vx;const n=ia(10,t);return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class xV{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Vx:_V(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,a){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+a}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let a=this._x1,s=this._y1,c=r-t,l=i-n,u=a-t,h=s-n,d=u*u+h*h;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(d>Hr)if(!(Math.abs(h*c-l*u)>Hr)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let f=r-a,g=i-s,y=c*c+l*l,m=f*f+g*g,v=Math.sqrt(y),b=Math.sqrt(d),_=o*Math.tan((kh-Math.acos((y+d-m)/(2*v*b)))/2),x=_/b,w=_/v;Math.abs(x-1)>Hr&&this._append`L${t+x*u},${n+x*h}`,this._append`A${o},${o},0,0,${+(h*f>u*g)},${this._x1=t+w*c},${this._y1=n+w*l}`}}arc(t,n,r,i,o,a){if(t=+t,n=+n,r=+r,a=!!a,r<0)throw new Error(`negative radius: ${r}`);let s=r*Math.cos(i),c=r*Math.sin(i),l=t+s,u=n+c,h=1^a,d=a?i-o:o-i;this._x1===null?this._append`M${l},${u}`:(Math.abs(this._x1-l)>Hr||Math.abs(this._y1-u)>Hr)&&this._append`L${l},${u}`,r&&(d<0&&(d=d%Rh+Rh),d>bV?this._append`A${r},${r},0,1,${h},${t-s},${n-c}A${r},${r},0,1,${h},${this._x1=l},${this._y1=u}`:d>Hr&&this._append`A${r},${r},0,${+(d>=kh)},${h},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function wV(e,t){var n,r=1;e==null&&(e=0),t==null&&(t=0);function i(){var o,a=n.length,s,c=0,l=0;for(o=0;o<a;++o)s=n[o],c+=s.x,l+=s.y;for(c=(c/a-e)*r,l=(l/a-t)*r,o=0;o<a;++o)s=n[o],s.x-=c,s.y-=l}return i.initialize=function(o){n=o},i.x=function(o){return arguments.length?(e=+o,i):e},i.y=function(o){return arguments.length?(t=+o,i):t},i.strength=function(o){return arguments.length?(r=+o,i):r},i}function PV(e){const t=+this._x.call(null,e),n=+this._y.call(null,e);return Yx(this.cover(t,n),t,n,e)}function Yx(e,t,n,r){if(isNaN(t)||isNaN(n))return e;var i,o=e._root,a={data:r},s=e._x0,c=e._y0,l=e._x1,u=e._y1,h,d,f,g,y,m,v,b;if(!o)return e._root=a,e;for(;o.length;)if((y=t>=(h=(s+l)/2))?s=h:l=h,(m=n>=(d=(c+u)/2))?c=d:u=d,i=o,!(o=o[v=m<<1|y]))return i[v]=a,e;if(f=+e._x.call(null,o.data),g=+e._y.call(null,o.data),t===f&&n===g)return a.next=o,i?i[v]=a:e._root=a,e;do i=i?i[v]=new Array(4):e._root=new Array(4),(y=t>=(h=(s+l)/2))?s=h:l=h,(m=n>=(d=(c+u)/2))?c=d:u=d;while((v=m<<1|y)===(b=(g>=d)<<1|f>=h));return i[b]=o,i[v]=a,e}function $V(e){var t,n,r=e.length,i,o,a=new Array(r),s=new Array(r),c=1/0,l=1/0,u=-1/0,h=-1/0;for(n=0;n<r;++n)isNaN(i=+this._x.call(null,t=e[n]))||isNaN(o=+this._y.call(null,t))||(a[n]=i,s[n]=o,i<c&&(c=i),i>u&&(u=i),o<l&&(l=o),o>h&&(h=o));if(c>u||l>h)return this;for(this.cover(c,l).cover(u,h),n=0;n<r;++n)Yx(this,a[n],s[n],e[n]);return this}function CV(e,t){if(isNaN(e=+e)||isNaN(t=+t))return this;var n=this._x0,r=this._y0,i=this._x1,o=this._y1;if(isNaN(n))i=(n=Math.floor(e))+1,o=(r=Math.floor(t))+1;else{for(var a=i-n||1,s=this._root,c,l;n>e||e>=i||r>t||t>=o;)switch(l=(t<r)<<1|e<n,c=new Array(4),c[l]=s,s=c,a*=2,l){case 0:i=n+a,o=r+a;break;case 1:n=i-a,o=r+a;break;case 2:i=n+a,r=o-a;break;case 3:n=i-a,r=o-a;break}this._root&&this._root.length&&(this._root=s)}return this._x0=n,this._y0=r,this._x1=i,this._y1=o,this}function OV(){var e=[];return this.visit(function(t){if(!t.length)do e.push(t.data);while(t=t.next)}),e}function SV(e){return arguments.length?this.cover(+e[0][0],+e[0][1]).cover(+e[1][0],+e[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]}function Yt(e,t,n,r,i){this.node=e,this.x0=t,this.y0=n,this.x1=r,this.y1=i}function MV(e,t,n){var r,i=this._x0,o=this._y0,a,s,c,l,u=this._x1,h=this._y1,d=[],f=this._root,g,y;for(f&&d.push(new Yt(f,i,o,u,h)),n==null?n=1/0:(i=e-n,o=t-n,u=e+n,h=t+n,n*=n);g=d.pop();)if(!(!(f=g.node)||(a=g.x0)>u||(s=g.y0)>h||(c=g.x1)<i||(l=g.y1)<o))if(f.length){var m=(a+c)/2,v=(s+l)/2;d.push(new Yt(f[3],m,v,c,l),new Yt(f[2],a,v,m,l),new Yt(f[1],m,s,c,v),new Yt(f[0],a,s,m,v)),(y=(t>=v)<<1|e>=m)&&(g=d[d.length-1],d[d.length-1]=d[d.length-1-y],d[d.length-1-y]=g)}else{var b=e-+this._x.call(null,f.data),_=t-+this._y.call(null,f.data),x=b*b+_*_;if(x<n){var w=Math.sqrt(n=x);i=e-w,o=t-w,u=e+w,h=t+w,r=f.data}}return r}function EV(e){if(isNaN(u=+this._x.call(null,e))||isNaN(h=+this._y.call(null,e)))return this;var t,n=this._root,r,i,o,a=this._x0,s=this._y0,c=this._x1,l=this._y1,u,h,d,f,g,y,m,v;if(!n)return this;if(n.length)for(;;){if((g=u>=(d=(a+c)/2))?a=d:c=d,(y=h>=(f=(s+l)/2))?s=f:l=f,t=n,!(n=n[m=y<<1|g]))return this;if(!n.length)break;(t[m+1&3]||t[m+2&3]||t[m+3&3])&&(r=t,v=m)}for(;n.data!==e;)if(i=n,!(n=n.next))return this;return(o=n.next)&&delete n.next,i?(o?i.next=o:delete i.next,this):t?(o?t[m]=o:delete t[m],(n=t[0]||t[1]||t[2]||t[3])&&n===(t[3]||t[2]||t[1]||t[0])&&!n.length&&(r?r[v]=n:this._root=n),this):(this._root=o,this)}function IV(e){for(var t=0,n=e.length;t<n;++t)this.remove(e[t]);return this}function AV(){return this._root}function TV(){var e=0;return this.visit(function(t){if(!t.length)do++e;while(t=t.next)}),e}function kV(e){var t=[],n,r=this._root,i,o,a,s,c;for(r&&t.push(new Yt(r,this._x0,this._y0,this._x1,this._y1));n=t.pop();)if(!e(r=n.node,o=n.x0,a=n.y0,s=n.x1,c=n.y1)&&r.length){var l=(o+s)/2,u=(a+c)/2;(i=r[3])&&t.push(new Yt(i,l,u,s,c)),(i=r[2])&&t.push(new Yt(i,o,u,l,c)),(i=r[1])&&t.push(new Yt(i,l,a,s,u)),(i=r[0])&&t.push(new Yt(i,o,a,l,u))}return this}function RV(e){var t=[],n=[],r;for(this._root&&t.push(new Yt(this._root,this._x0,this._y0,this._x1,this._y1));r=t.pop();){var i=r.node;if(i.length){var o,a=r.x0,s=r.y0,c=r.x1,l=r.y1,u=(a+c)/2,h=(s+l)/2;(o=i[0])&&t.push(new Yt(o,a,s,u,h)),(o=i[1])&&t.push(new Yt(o,u,s,c,h)),(o=i[2])&&t.push(new Yt(o,a,h,u,l)),(o=i[3])&&t.push(new Yt(o,u,h,c,l))}n.push(r)}for(;r=n.pop();)e(r.node,r.x0,r.y0,r.x1,r.y1);return this}function LV(e){return e[0]}function zV(e){return arguments.length?(this._x=e,this):this._x}function NV(e){return e[1]}function DV(e){return arguments.length?(this._y=e,this):this._y}function Lh(e,t,n){var r=new zh(t==null?LV:t,n==null?NV:n,NaN,NaN,NaN,NaN);return e==null?r:r.addAll(e)}function zh(e,t,n,r,i,o){this._x=e,this._y=t,this._x0=n,this._y0=r,this._x1=i,this._y1=o,this._root=void 0}function Xx(e){for(var t={data:e.data},n=t;e=e.next;)n=n.next={data:e.data};return t}var Xt=Lh.prototype=zh.prototype;Xt.copy=function(){var e=new zh(this._x,this._y,this._x0,this._y0,this._x1,this._y1),t=this._root,n,r;if(!t)return e;if(!t.length)return e._root=Xx(t),e;for(n=[{source:t,target:e._root=new Array(4)}];t=n.pop();)for(var i=0;i<4;++i)(r=t.source[i])&&(r.length?n.push({source:r,target:t.target[i]=new Array(4)}):t.target[i]=Xx(r));return e},Xt.add=PV,Xt.addAll=$V,Xt.cover=CV,Xt.data=OV,Xt.extent=SV,Xt.find=MV,Xt.remove=EV,Xt.removeAll=IV,Xt.root=AV,Xt.size=TV,Xt.visit=kV,Xt.visitAfter=RV,Xt.x=zV,Xt.y=DV;function qr(e){return function(){return e}}function ur(e){return(e()-.5)*1e-6}function HV(e){return e.x+e.vx}function qV(e){return e.y+e.vy}function jV(e){var t,n,r,i=1,o=1;typeof e!="function"&&(e=qr(e==null?1:+e));function a(){for(var l,u=t.length,h,d,f,g,y,m,v=0;v<o;++v)for(h=Lh(t,HV,qV).visitAfter(s),l=0;l<u;++l)d=t[l],y=n[d.index],m=y*y,f=d.x+d.vx,g=d.y+d.vy,h.visit(b);function b(_,x,w,P,$){var C=_.data,M=_.r,S=y+M;if(C){if(C.index>d.index){var E=f-C.x-C.vx,A=g-C.y-C.vy,O=E*E+A*A;O<S*S&&(E===0&&(E=ur(r),O+=E*E),A===0&&(A=ur(r),O+=A*A),O=(S-(O=Math.sqrt(O)))/O*i,d.vx+=(E*=O)*(S=(M*=M)/(m+M)),d.vy+=(A*=O)*S,C.vx-=E*(S=1-S),C.vy-=A*S)}return}return x>f+S||P<f-S||w>g+S||$<g-S}}function s(l){if(l.data)return l.r=n[l.data.index];for(var u=l.r=0;u<4;++u)l[u]&&l[u].r>l.r&&(l.r=l[u].r)}function c(){if(t){var l,u=t.length,h;for(n=new Array(u),l=0;l<u;++l)h=t[l],n[h.index]=+e(h,l,t)}}return a.initialize=function(l,u){t=l,r=u,c()},a.iterations=function(l){return arguments.length?(o=+l,a):o},a.strength=function(l){return arguments.length?(i=+l,a):i},a.radius=function(l){return arguments.length?(e=typeof l=="function"?l:qr(+l),c(),a):e},a}function FV(e){return e.index}function Ux(e,t){var n=e.get(t);if(!n)throw new Error("node not found: "+t);return n}function BV(e){var t=FV,n=h,r,i=qr(30),o,a,s,c,l,u=1;e==null&&(e=[]);function h(m){return 1/Math.min(s[m.source.index],s[m.target.index])}function d(m){for(var v=0,b=e.length;v<u;++v)for(var _=0,x,w,P,$,C,M,S;_<b;++_)x=e[_],w=x.source,P=x.target,$=P.x+P.vx-w.x-w.vx||ur(l),C=P.y+P.vy-w.y-w.vy||ur(l),M=Math.sqrt($*$+C*C),M=(M-o[_])/M*m*r[_],$*=M,C*=M,P.vx-=$*(S=c[_]),P.vy-=C*S,w.vx+=$*(S=1-S),w.vy+=C*S}function f(){if(a){var m,v=a.length,b=e.length,_=new Map(a.map((w,P)=>[t(w,P,a),w])),x;for(m=0,s=new Array(v);m<b;++m)x=e[m],x.index=m,typeof x.source!="object"&&(x.source=Ux(_,x.source)),typeof x.target!="object"&&(x.target=Ux(_,x.target)),s[x.source.index]=(s[x.source.index]||0)+1,s[x.target.index]=(s[x.target.index]||0)+1;for(m=0,c=new Array(b);m<b;++m)x=e[m],c[m]=s[x.source.index]/(s[x.source.index]+s[x.target.index]);r=new Array(b),g(),o=new Array(b),y()}}function g(){if(a)for(var m=0,v=e.length;m<v;++m)r[m]=+n(e[m],m,e)}function y(){if(a)for(var m=0,v=e.length;m<v;++m)o[m]=+i(e[m],m,e)}return d.initialize=function(m,v){a=m,l=v,f()},d.links=function(m){return arguments.length?(e=m,f(),d):e},d.id=function(m){return arguments.length?(t=m,d):t},d.iterations=function(m){return arguments.length?(u=+m,d):u},d.strength=function(m){return arguments.length?(n=typeof m=="function"?m:qr(+m),g(),d):n},d.distance=function(m){return arguments.length?(i=typeof m=="function"?m:qr(+m),y(),d):i},d}const WV=1664525,GV=1013904223,Kx=4294967296;function VV(){let e=1;return()=>(e=(WV*e+GV)%Kx)/Kx}function YV(e){return e.x}function XV(e){return e.y}var UV=10,KV=Math.PI*(3-Math.sqrt(5));function ZV(e){var t,n=1,r=.001,i=1-Math.pow(r,1/300),o=0,a=.6,s=new Map,c=Sh(h),l=ph("tick","end"),u=VV();e==null&&(e=[]);function h(){d(),l.call("tick",t),n<r&&(c.stop(),l.call("end",t))}function d(y){var m,v=e.length,b;y===void 0&&(y=1);for(var _=0;_<y;++_)for(n+=(o-n)*i,s.forEach(function(x){x(n)}),m=0;m<v;++m)b=e[m],b.fx==null?b.x+=b.vx*=a:(b.x=b.fx,b.vx=0),b.fy==null?b.y+=b.vy*=a:(b.y=b.fy,b.vy=0);return t}function f(){for(var y=0,m=e.length,v;y<m;++y){if(v=e[y],v.index=y,v.fx!=null&&(v.x=v.fx),v.fy!=null&&(v.y=v.fy),isNaN(v.x)||isNaN(v.y)){var b=UV*Math.sqrt(.5+y),_=y*KV;v.x=b*Math.cos(_),v.y=b*Math.sin(_)}(isNaN(v.vx)||isNaN(v.vy))&&(v.vx=v.vy=0)}}function g(y){return y.initialize&&y.initialize(e,u),y}return f(),t={tick:d,restart:function(){return c.restart(h),t},stop:function(){return c.stop(),t},nodes:function(y){return arguments.length?(e=y,f(),s.forEach(g),t):e},alpha:function(y){return arguments.length?(n=+y,t):n},alphaMin:function(y){return arguments.length?(r=+y,t):r},alphaDecay:function(y){return arguments.length?(i=+y,t):+i},alphaTarget:function(y){return arguments.length?(o=+y,t):o},velocityDecay:function(y){return arguments.length?(a=1-y,t):1-a},randomSource:function(y){return arguments.length?(u=y,s.forEach(g),t):u},force:function(y,m){return arguments.length>1?(m==null?s.delete(y):s.set(y,g(m)),t):s.get(y)},find:function(y,m,v){var b=0,_=e.length,x,w,P,$,C;for(v==null?v=1/0:v*=v,b=0;b<_;++b)$=e[b],x=y-$.x,w=m-$.y,P=x*x+w*w,P<v&&(C=$,v=P);return C},on:function(y,m){return arguments.length>1?(l.on(y,m),t):l.on(y)}}}function QV(){var e,t,n,r,i=qr(-30),o,a=1,s=1/0,c=.81;function l(f){var g,y=e.length,m=Lh(e,YV,XV).visitAfter(h);for(r=f,g=0;g<y;++g)t=e[g],m.visit(d)}function u(){if(e){var f,g=e.length,y;for(o=new Array(g),f=0;f<g;++f)y=e[f],o[y.index]=+i(y,f,e)}}function h(f){var g=0,y,m,v=0,b,_,x;if(f.length){for(b=_=x=0;x<4;++x)(y=f[x])&&(m=Math.abs(y.value))&&(g+=y.value,v+=m,b+=m*y.x,_+=m*y.y);f.x=b/v,f.y=_/v}else{y=f,y.x=y.data.x,y.y=y.data.y;do g+=o[y.data.index];while(y=y.next)}f.value=g}function d(f,g,y,m){if(!f.value)return!0;var v=f.x-t.x,b=f.y-t.y,_=m-g,x=v*v+b*b;if(_*_/c<x)return x<s&&(v===0&&(v=ur(n),x+=v*v),b===0&&(b=ur(n),x+=b*b),x<a&&(x=Math.sqrt(a*x)),t.vx+=v*f.value*r/x,t.vy+=b*f.value*r/x),!0;if(f.length||x>=s)return;(f.data!==t||f.next)&&(v===0&&(v=ur(n),x+=v*v),b===0&&(b=ur(n),x+=b*b),x<a&&(x=Math.sqrt(a*x)));do f.data!==t&&(_=o[f.data.index]*r/x,t.vx+=v*_,t.vy+=b*_);while(f=f.next)}return l.initialize=function(f,g){e=f,n=g,u()},l.strength=function(f){return arguments.length?(i=typeof f=="function"?f:qr(+f),u(),l):i},l.distanceMin=function(f){return arguments.length?(a=f*f,l):Math.sqrt(a)},l.distanceMax=function(f){return arguments.length?(s=f*f,l):Math.sqrt(s)},l.theta=function(f){return arguments.length?(c=f*f,l):Math.sqrt(c)},l}function JV(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Ys(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function wi(e){return e=Ys(Math.abs(e)),e?e[1]:NaN}function eY(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),o.push(n.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function tY(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var nY=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Xs(e){if(!(t=nY.exec(e)))throw new Error("invalid format: "+e);var t;return new Nh({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Xs.prototype=Nh.prototype;function Nh(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}Nh.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function rY(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var Us;function iY(e,t){var n=Ys(e,t);if(!n)return Us=void 0,e.toPrecision(t);var r=n[0],i=n[1],o=i-(Us=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Ys(e,Math.max(0,t+o-1))[0]}function Zx(e,t){var n=Ys(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const Qx={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:JV,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>Zx(e*100,t),r:Zx,s:iY,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Jx(e){return e}var ew=Array.prototype.map,tw=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function oY(e){var t=e.grouping===void 0||e.thousands===void 0?Jx:eY(ew.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?Jx:tY(ew.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",c=e.nan===void 0?"NaN":e.nan+"";function l(h,d){h=Xs(h);var f=h.fill,g=h.align,y=h.sign,m=h.symbol,v=h.zero,b=h.width,_=h.comma,x=h.precision,w=h.trim,P=h.type;P==="n"?(_=!0,P="g"):Qx[P]||(x===void 0&&(x=12),w=!0,P="g"),(v||f==="0"&&g==="=")&&(v=!0,f="0",g="=");var $=(d&&d.prefix!==void 0?d.prefix:"")+(m==="$"?n:m==="#"&&/[boxX]/.test(P)?"0"+P.toLowerCase():""),C=(m==="$"?r:/[%p]/.test(P)?a:"")+(d&&d.suffix!==void 0?d.suffix:""),M=Qx[P],S=/[defgprs%]/.test(P);x=x===void 0?6:/[gprs]/.test(P)?Math.max(1,Math.min(21,x)):Math.max(0,Math.min(20,x));function E(A){var O=$,T=C,F,z,j;if(P==="c")T=M(A)+T,A="";else{A=+A;var D=A<0||1/A<0;if(A=isNaN(A)?c:M(Math.abs(A),x),w&&(A=rY(A)),D&&+A==0&&y!=="+"&&(D=!1),O=(D?y==="("?y:s:y==="-"||y==="("?"":y)+O,T=(P==="s"&&!isNaN(A)&&Us!==void 0?tw[8+Us/3]:"")+T+(D&&y==="("?")":""),S){for(F=-1,z=A.length;++F<z;)if(j=A.charCodeAt(F),48>j||j>57){T=(j===46?i+A.slice(F+1):A.slice(F))+T,A=A.slice(0,F);break}}}_&&!v&&(A=t(A,1/0));var W=O.length+A.length+T.length,B=W<b?new Array(b-W+1).join(f):"";switch(_&&v&&(A=t(B+A,B.length?b-T.length:1/0),B=""),g){case"<":A=O+A+T+B;break;case"=":A=O+B+A+T;break;case"^":A=B.slice(0,W=B.length>>1)+O+A+T+B.slice(W);break;default:A=B+O+A+T;break}return o(A)}return E.toString=function(){return h+""},E}function u(h,d){var f=Math.max(-8,Math.min(8,Math.floor(wi(d)/3)))*3,g=Math.pow(10,-f),y=l((h=Xs(h),h.type="f",h),{suffix:tw[8+f/3]});return function(m){return y(g*m)}}return{format:l,formatPrefix:u}}var Ks,nw,rw;aY({thousands:",",grouping:[3],currency:["$",""]});function aY(e){return Ks=oY(e),nw=Ks.format,rw=Ks.formatPrefix,Ks}function sY(e){return Math.max(0,-wi(Math.abs(e)))}function cY(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(wi(t)/3)))*3-wi(Math.abs(e)))}function lY(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,wi(t)-wi(e))+1}function uY(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function hY(){return this.eachAfter(uY)}function dY(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this}function fY(e,t){for(var n=this,r=[n],i,o,a=-1;n=r.pop();)if(e.call(t,n,++a,this),i=n.children)for(o=i.length-1;o>=0;--o)r.push(i[o]);return this}function pY(e,t){for(var n=this,r=[n],i=[],o,a,s,c=-1;n=r.pop();)if(i.push(n),o=n.children)for(a=0,s=o.length;a<s;++a)r.push(o[a]);for(;n=i.pop();)e.call(t,n,++c,this);return this}function gY(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r}function mY(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})}function yY(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function vY(e){for(var t=this,n=bY(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function bY(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function _Y(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function xY(){return Array.from(this)}function wY(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function PY(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*$Y(){var e=this,t,n=[e],r,i,o;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,o=r.length;i<o;++i)n.push(r[i]);while(n.length)}function Dh(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=SY)):t===void 0&&(t=OY);for(var n=new Ro(e),r,i=[n],o,a,s,c;r=i.pop();)if((a=t(r.data))&&(c=(a=Array.from(a)).length))for(r.children=a,s=c-1;s>=0;--s)i.push(o=a[s]=new Ro(a[s])),o.parent=r,o.depth=r.depth+1;return n.eachBefore(EY)}function CY(){return Dh(this).eachBefore(MY)}function OY(e){return e.children}function SY(e){return Array.isArray(e)?e[1]:null}function MY(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function EY(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function Ro(e){this.data=e,this.depth=this.height=0,this.parent=null}Ro.prototype=Dh.prototype={constructor:Ro,count:hY,each:dY,eachAfter:pY,eachBefore:fY,find:gY,sum:mY,sort:yY,path:vY,ancestors:_Y,descendants:xY,leaves:wY,links:PY,copy:CY,[Symbol.iterator]:$Y};function IY(e,t){return e.parent===t.parent?1:2}function Hh(e){var t=e.children;return t?t[0]:e.t}function qh(e){var t=e.children;return t?t[t.length-1]:e.t}function AY(e,t,n){var r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n}function TY(e){for(var t=0,n=0,r=e.children,i=r.length,o;--i>=0;)o=r[i],o.z+=t,o.m+=t,t+=o.s+(n+=o.c)}function kY(e,t,n){return e.a.parent===t.parent?e.a:n}function Zs(e,t){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=t}Zs.prototype=Object.create(Ro.prototype);function RY(e){for(var t=new Zs(e,0),n,r=[t],i,o,a,s;n=r.pop();)if(o=n._.children)for(n.children=new Array(s=o.length),a=s-1;a>=0;--a)r.push(i=n.children[a]=new Zs(o[a],a)),i.parent=n;return(t.parent=new Zs(null,0)).children=[t],t}function LY(){var e=IY,t=1,n=1,r=null;function i(l){var u=RY(l);if(u.eachAfter(o),u.parent.m=-u.z,u.eachBefore(a),r)l.eachBefore(c);else{var h=l,d=l,f=l;l.eachBefore(function(b){b.x<h.x&&(h=b),b.x>d.x&&(d=b),b.depth>f.depth&&(f=b)});var g=h===d?1:e(h,d)/2,y=g-h.x,m=t/(d.x+g+y),v=n/(f.depth||1);l.eachBefore(function(b){b.x=(b.x+y)*m,b.y=b.depth*v})}return l}function o(l){var u=l.children,h=l.parent.children,d=l.i?h[l.i-1]:null;if(u){TY(l);var f=(u[0].z+u[u.length-1].z)/2;d?(l.z=d.z+e(l._,d._),l.m=l.z-f):l.z=f}else d&&(l.z=d.z+e(l._,d._));l.parent.A=s(l,d,l.parent.A||h[0])}function a(l){l._.x=l.z+l.parent.m,l.m+=l.parent.m}function s(l,u,h){if(u){for(var d=l,f=l,g=u,y=d.parent.children[0],m=d.m,v=f.m,b=g.m,_=y.m,x;g=qh(g),d=Hh(d),g&&d;)y=Hh(y),f=qh(f),f.a=l,x=g.z+b-d.z-m+e(g._,d._),x>0&&(AY(kY(g,l,h),l,x),m+=x,v+=x),b+=g.m,m+=d.m,_+=y.m,v+=f.m;g&&!qh(f)&&(f.t=g,f.m+=b-v),d&&!Hh(y)&&(y.t=d,y.m+=m-_,h=l)}return h}function c(l){l.x*=t,l.y=l.depth*n}return i.separation=function(l){return arguments.length?(e=l,i):e},i.size=function(l){return arguments.length?(r=!1,t=+l[0],n=+l[1],i):r?null:[t,n]},i.nodeSize=function(l){return arguments.length?(r=!0,t=+l[0],n=+l[1],i):r?[t,n]:null},i}function zY(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function NY(e){return function(){return e}}function DY(e){return+e}var iw=[0,1];function Pi(e){return e}function jh(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:NY(isNaN(t)?NaN:.5)}function HY(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function qY(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=jh(i,r),o=n(a,o)):(r=jh(r,i),o=n(o,a)),function(s){return o(r(s))}}function jY(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=jh(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(s){var c=VF(e,s,1,r)-1;return o[c](i[c](s))}}function FY(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function BY(){var e=iw,t=iw,n=$h,r,i,o,a=Pi,s,c,l;function u(){var d=Math.min(e.length,t.length);return a!==Pi&&(a=HY(e[0],e[d-1])),s=d>2?jY:qY,c=l=null,h}function h(d){return d==null||isNaN(d=+d)?o:(c||(c=s(e.map(r),t,n)))(r(a(d)))}return h.invert=function(d){return a(i((l||(l=s(t,e.map(r),mn)))(d)))},h.domain=function(d){return arguments.length?(e=Array.from(d,DY),u()):e.slice()},h.range=function(d){return arguments.length?(t=Array.from(d),u()):t.slice()},h.rangeRound=function(d){return t=Array.from(d),n=nG,u()},h.clamp=function(d){return arguments.length?(a=d?!0:Pi,u()):a!==Pi},h.interpolate=function(d){return arguments.length?(n=d,u()):n},h.unknown=function(d){return arguments.length?(o=d,h):o},function(d,f){return r=d,i=f,u()}}function WY(){return BY()(Pi,Pi)}function GY(e,t,n,r){var i=ZF(e,t,n),o;switch(r=Xs(r==null?",f":r),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=cY(i,a))&&(r.precision=o),rw(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=lY(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=sY(i))&&(r.precision=o-(r.type==="%")*2);break}}return nw(r)}function VY(e){var t=e.domain;return e.ticks=function(n){var r=t();return KF(r[0],r[r.length-1],n==null?10:n)},e.tickFormat=function(n,r){var i=t();return GY(i[0],i[i.length-1],n==null?10:n,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],c,l,u=10;for(s<a&&(l=a,a=s,s=l,l=i,i=o,o=l);u-- >0;){if(l=fh(a,s,n),l===c)return r[i]=a,r[o]=s,t(r);if(l>0)a=Math.floor(a/l)*l,s=Math.ceil(s/l)*l;else if(l<0)a=Math.ceil(a*l)/l,s=Math.floor(s*l)/l;else break;c=l}return e},e}function Lo(){var e=WY();return e.copy=function(){return FY(e,Lo())},zY.apply(e,arguments),VY(e)}function Ot(e){return function(){return e}}const ow=Math.abs,Ft=Math.atan2,jr=Math.cos,YY=Math.max,Fh=Math.min,In=Math.sin,$i=Math.sqrt,tn=1e-12,zo=Math.PI,Qs=zo/2,Js=2*zo;function XY(e){return e>1?0:e<-1?zo:Math.acos(e)}function aw(e){return e>=1?Qs:e<=-1?-Qs:Math.asin(e)}function sw(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new xV(t)}function UY(e){return e.innerRadius}function KY(e){return e.outerRadius}function ZY(e){return e.startAngle}function QY(e){return e.endAngle}function JY(e){return e&&e.padAngle}function eX(e,t,n,r,i,o,a,s){var c=n-e,l=r-t,u=a-i,h=s-o,d=h*c-u*l;if(!(d*d<tn))return d=(u*(t-o)-h*(e-i))/d,[e+d*c,t+d*l]}function ec(e,t,n,r,i,o,a){var s=e-n,c=t-r,l=(a?o:-o)/$i(s*s+c*c),u=l*c,h=-l*s,d=e+u,f=t+h,g=n+u,y=r+h,m=(d+g)/2,v=(f+y)/2,b=g-d,_=y-f,x=b*b+_*_,w=i-o,P=d*y-g*f,$=(_<0?-1:1)*$i(YY(0,w*w*x-P*P)),C=(P*_-b*$)/x,M=(-P*b-_*$)/x,S=(P*_+b*$)/x,E=(-P*b+_*$)/x,A=C-m,O=M-v,T=S-m,F=E-v;return A*A+O*O>T*T+F*F&&(C=S,M=E),{cx:C,cy:M,x01:-u,y01:-h,x11:C*(i/w-1),y11:M*(i/w-1)}}function No(){var e=UY,t=KY,n=Ot(0),r=null,i=ZY,o=QY,a=JY,s=null,c=sw(l);function l(){var u,h,d=+e.apply(this,arguments),f=+t.apply(this,arguments),g=i.apply(this,arguments)-Qs,y=o.apply(this,arguments)-Qs,m=ow(y-g),v=y>g;if(s||(s=u=c()),f<d&&(h=f,f=d,d=h),!(f>tn))s.moveTo(0,0);else if(m>Js-tn)s.moveTo(f*jr(g),f*In(g)),s.arc(0,0,f,g,y,!v),d>tn&&(s.moveTo(d*jr(y),d*In(y)),s.arc(0,0,d,y,g,v));else{var b=g,_=y,x=g,w=y,P=m,$=m,C=a.apply(this,arguments)/2,M=C>tn&&(r?+r.apply(this,arguments):$i(d*d+f*f)),S=Fh(ow(f-d)/2,+n.apply(this,arguments)),E=S,A=S,O,T;if(M>tn){var F=aw(M/d*In(C)),z=aw(M/f*In(C));(P-=F*2)>tn?(F*=v?1:-1,x+=F,w-=F):(P=0,x=w=(g+y)/2),($-=z*2)>tn?(z*=v?1:-1,b+=z,_-=z):($=0,b=_=(g+y)/2)}var j=f*jr(b),D=f*In(b),W=d*jr(w),B=d*In(w);if(S>tn){var X=f*jr(_),H=f*In(_),k=d*jr(x),I=d*In(x),R;if(m<zo)if(R=eX(j,D,k,I,X,H,W,B)){var N=j-R[0],q=D-R[1],G=X-R[0],U=H-R[1],K=1/In(XY((N*G+q*U)/($i(N*N+q*q)*$i(G*G+U*U)))/2),oe=$i(R[0]*R[0]+R[1]*R[1]);E=Fh(S,(d-oe)/(K-1)),A=Fh(S,(f-oe)/(K+1))}else E=A=0}$>tn?A>tn?(O=ec(k,I,j,D,f,A,v),T=ec(X,H,W,B,f,A,v),s.moveTo(O.cx+O.x01,O.cy+O.y01),A<S?s.arc(O.cx,O.cy,A,Ft(O.y01,O.x01),Ft(T.y01,T.x01),!v):(s.arc(O.cx,O.cy,A,Ft(O.y01,O.x01),Ft(O.y11,O.x11),!v),s.arc(0,0,f,Ft(O.cy+O.y11,O.cx+O.x11),Ft(T.cy+T.y11,T.cx+T.x11),!v),s.arc(T.cx,T.cy,A,Ft(T.y11,T.x11),Ft(T.y01,T.x01),!v))):(s.moveTo(j,D),s.arc(0,0,f,b,_,!v)):s.moveTo(j,D),!(d>tn)||!(P>tn)?s.lineTo(W,B):E>tn?(O=ec(W,B,X,H,d,-E,v),T=ec(j,D,k,I,d,-E,v),s.lineTo(O.cx+O.x01,O.cy+O.y01),E<S?s.arc(O.cx,O.cy,E,Ft(O.y01,O.x01),Ft(T.y01,T.x01),!v):(s.arc(O.cx,O.cy,E,Ft(O.y01,O.x01),Ft(O.y11,O.x11),!v),s.arc(0,0,d,Ft(O.cy+O.y11,O.cx+O.x11),Ft(T.cy+T.y11,T.cx+T.x11),v),s.arc(T.cx,T.cy,E,Ft(T.y11,T.x11),Ft(T.y01,T.x01),!v))):s.arc(0,0,d,w,x,v)}if(s.closePath(),u)return s=null,u+""||null}return l.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,h=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-zo/2;return[jr(h)*u,In(h)*u]},l.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:Ot(+u),l):e},l.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:Ot(+u),l):t},l.cornerRadius=function(u){return arguments.length?(n=typeof u=="function"?u:Ot(+u),l):n},l.padRadius=function(u){return arguments.length?(r=u==null?null:typeof u=="function"?u:Ot(+u),l):r},l.startAngle=function(u){return arguments.length?(i=typeof u=="function"?u:Ot(+u),l):i},l.endAngle=function(u){return arguments.length?(o=typeof u=="function"?u:Ot(+u),l):o},l.padAngle=function(u){return arguments.length?(a=typeof u=="function"?u:Ot(+u),l):a},l.context=function(u){return arguments.length?(s=u==null?null:u,l):s},l}function cw(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function lw(e){this._context=e}lw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function uw(e){return new lw(e)}function tX(e){return e[0]}function nX(e){return e[1]}function rX(e,t){var n=Ot(!0),r=null,i=uw,o=null,a=sw(s);e=typeof e=="function"?e:e===void 0?tX:Ot(e),t=typeof t=="function"?t:t===void 0?nX:Ot(t);function s(c){var l,u=(c=cw(c)).length,h,d=!1,f;for(r==null&&(o=i(f=a())),l=0;l<=u;++l)!(l<u&&n(h=c[l],l,c))===d&&((d=!d)?o.lineStart():o.lineEnd()),d&&o.point(+e(h,l,c),+t(h,l,c));if(f)return o=null,f+""||null}return s.x=function(c){return arguments.length?(e=typeof c=="function"?c:Ot(+c),s):e},s.y=function(c){return arguments.length?(t=typeof c=="function"?c:Ot(+c),s):t},s.defined=function(c){return arguments.length?(n=typeof c=="function"?c:Ot(!!c),s):n},s.curve=function(c){return arguments.length?(i=c,r!=null&&(o=i(r)),s):i},s.context=function(c){return arguments.length?(c==null?r=o=null:o=i(r=c),s):r},s}function iX(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function oX(e){return e}function aX(){var e=oX,t=iX,n=null,r=Ot(0),i=Ot(Js),o=Ot(0);function a(s){var c,l=(s=cw(s)).length,u,h,d=0,f=new Array(l),g=new Array(l),y=+r.apply(this,arguments),m=Math.min(Js,Math.max(-Js,i.apply(this,arguments)-y)),v,b=Math.min(Math.abs(m)/l,o.apply(this,arguments)),_=b*(m<0?-1:1),x;for(c=0;c<l;++c)(x=g[f[c]=c]=+e(s[c],c,s))>0&&(d+=x);for(t!=null?f.sort(function(w,P){return t(g[w],g[P])}):n!=null&&f.sort(function(w,P){return n(s[w],s[P])}),c=0,h=d?(m-l*_)/d:0;c<l;++c,y=v)u=f[c],x=g[u],v=y+(x>0?x*h:0)+_,g[u]={data:s[u],index:c,value:x,startAngle:y,endAngle:v,padAngle:b};return g}return a.value=function(s){return arguments.length?(e=typeof s=="function"?s:Ot(+s),a):e},a.sortValues=function(s){return arguments.length?(t=s,n=null,a):t},a.sort=function(s){return arguments.length?(n=s,t=null,a):n},a.startAngle=function(s){return arguments.length?(r=typeof s=="function"?s:Ot(+s),a):r},a.endAngle=function(s){return arguments.length?(i=typeof s=="function"?s:Ot(+s),a):i},a.padAngle=function(s){return arguments.length?(o=typeof s=="function"?s:Ot(+s),a):o},a}function Do(e,t,n){this.k=e,this.x=t,this.y=n}Do.prototype={constructor:Do,scale:function(e){return e===1?this:new Do(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Do(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},Do.prototype;var sX=Object.defineProperty,cX=Object.defineProperties,lX=Object.getOwnPropertyDescriptors,hw=Object.getOwnPropertySymbols,uX=Object.prototype.hasOwnProperty,hX=Object.prototype.propertyIsEnumerable,dw=(e,t,n)=>t in e?sX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,dX=(e,t)=>{for(var n in t||(t={}))uX.call(t,n)&&dw(e,n,t[n]);if(hw)for(var n of hw(t))hX.call(t,n)&&dw(e,n,t[n]);return e},fX=(e,t)=>cX(e,lX(t));const fw=e=>{const[{datum:t,data:n,indexes:r,width:i=280,height:o=120,iconSize:a=32,gap:s=12,progressHeight:c=8,borderRadius:l=12,positionH:u="normal",themeColors:h,valueFormatter:d=F=>`${F}%`},f]=st(e,["width","height","iconSize","gap","progressHeight","borderRadius"]),g=t.value,y=g!=null?g:0,m=Math.max(...n.items.map(F=>{var z;return(z=F.value)!=null?z:0}),100),v=i-2*s,_=Lo().domain([0,m]).range([0,v])(y),x=`${h.colorPrimary}-progress`,w=`${h.colorPrimaryBg}-progress-bg`,P=se(p(Ge,{indexes:r})),$=s,C=u==="flipped"?i-s-a:s,M=$,S=u==="flipped"?s:a+2*s,E=i-a-3*s,A=M,O=o-s-c,T=g!==void 0;return L(Y,fX(dX({},f),{children:[L(Ke,{children:[L("linearGradient",{id:x,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p("stop",{offset:"0%",stopColor:h.colorPrimary}),p("stop",{offset:"100%",stopColor:be.mix(h.colorPrimary,"#fff",20).toHexString()})]}),L("linearGradient",{id:w,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p("stop",{offset:"0%",stopColor:h.colorPrimaryBg}),p("stop",{offset:"100%",stopColor:h.colorBg})]})]}),p(Re,{x:0,y:0,width:i,height:o,fill:h.colorBgElevated,stroke:h.colorPrimaryBg,strokeWidth:1,rx:l,ry:l,"data-element-type":"shape"}),p(Ht,{indexes:r,x:C,y:M,size:a,fill:h.colorPrimary}),p(Ge,{indexes:r,x:S,y:A,width:E,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",fontSize:16,fontWeight:"medium",fill:h.colorText,children:t.label}),T&&p(xo,{indexes:r,x:S,y:A+P.height,width:E,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",lineHeight:1,fontSize:24,fontWeight:"bold",fill:h.colorPrimary,value:y,formatter:d}),p(ut,{indexes:r,x:S,y:A+P.height+(T?27:4),width:E,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",fontSize:11,fill:h.colorTextSecondary,lineNumber:T?2:3,wordWrap:!0,children:t.desc}),p(Re,{x:s,y:O,width:v,height:c,fill:`url(#${w})`,rx:c/2,ry:c/2,"data-element-type":"shape"}),p(Re,{x:s,y:O,width:_,height:c,fill:`url(#${x})`,rx:c/2,ry:c/2,"data-element-type":"shape"})]}))};ct("progress-card",{component:fw,composites:["icon","label","value","desc"]});var pX=Object.defineProperty,gX=Object.defineProperties,mX=Object.getOwnPropertyDescriptors,pw=Object.getOwnPropertySymbols,yX=Object.prototype.hasOwnProperty,vX=Object.prototype.propertyIsEnumerable,gw=(e,t,n)=>t in e?pX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bX=(e,t)=>{for(var n in t||(t={}))yX.call(t,n)&&gw(e,n,t[n]);if(pw)for(var n of pw(t))vX.call(t,n)&&gw(e,n,t[n]);return e},_X=(e,t)=>gX(e,mX(t));const mw=e=>{const[{datum:t,indexes:n,width:r=280,height:i=120,iconSize:o=30,circleRadius:a=80,positionH:s="normal",positionV:c="normal",themeColors:l},u]=st(e,["width","height","iconSize","circleRadius"]),h=4*a/(3*Math.PI),d=2,f=4,g=28,y=20,m=y+20,v=y,b=8,_=35,x=40,w=30,P=String(n[0]+1).padStart(2,"0"),$=s==="flipped",C=c==="flipped",M=()=>$?{diagonalStartX:r-f,diagonalStartY:C?i-_:_,diagonalEndX:r-x,diagonalEndY:C?i-f:f,topLineStartX:r-x,topLineEndX:h,topLineY:C?i-f:f}:{diagonalStartX:f,diagonalStartY:C?i-_:_,diagonalEndX:x,diagonalEndY:C?i-f:f,topLineStartX:x,topLineEndX:r-h,topLineY:C?i-f:f},S=()=>{if($){const j=a+10,D=r-j-x;return{valueX:r-w,contentX:j,contentWidth:D,circleX:0,circleY:C?0:i,iconX:h-o/2}}else return{valueX:0,contentX:x,contentWidth:r-x-a-10,circleX:r,circleY:C?0:i,iconX:r-h-o/2}},E=M(),A=S(),O=C?h-o/2:i-h-o/2,T=se(p(Ge,{indexes:n,width:A.contentWidth,children:t.label})),F=v+T.height+b,z=()=>{const{circleX:j,circleY:D}=A;return $?C?`M ${j} ${D} L ${j} ${D+a} A ${a} ${a} 0 0 0 ${j+a} ${D} Z`:`M ${j} ${D} L ${j} ${D-a} A ${a} ${a} 0 0 1 ${j+a} ${D} Z`:C?`M ${j} ${D} L ${j} ${D+a} A ${a} ${a} 0 0 1 ${j-a} ${D} Z`:`M ${j} ${D} L ${j} ${D-a} A ${a} ${a} 0 0 0 ${j-a} ${D} Z`};return L(Y,_X(bX({},u),{width:r,height:i,children:[L(xt,{children:[p(Pe,{d:`M ${E.diagonalStartX} ${E.diagonalStartY} L ${E.diagonalEndX} ${E.diagonalEndY}`,stroke:l.colorPrimary,strokeWidth:d,fill:"none"}),p(Pe,{d:`M ${E.topLineStartX} ${E.topLineY} L ${E.topLineEndX} ${E.topLineY}`,stroke:l.colorPrimary,strokeWidth:d,fill:"none"}),p(Ze,{x:E.diagonalStartX-f,y:E.diagonalStartY-f,width:f*2,height:f*2,fill:l.colorPrimary}),p(Ze,{x:E.topLineEndX-f,y:E.topLineY-f,width:f*2,height:f*2,fill:l.colorPrimary})]}),L(Y,{children:[p(ze,{x:A.valueX,y:m,fontSize:g,fontWeight:"bold",fill:l.colorPrimary,children:P}),p(Pe,{d:z(),fill:l.colorPrimary,"data-element-type":"shape"}),t.icon&&p(Ht,{indexes:n,x:A.iconX,y:O,size:o,fill:l.colorWhite}),t.label&&p(Ge,{indexes:n,x:A.contentX,y:v,width:A.contentWidth,fontWeight:"bold",fill:l.colorText,alignHorizontal:$?"right":"left",children:t.label}),t.desc&&p(ut,{indexes:n,x:A.contentX,y:F,width:A.contentWidth,fill:l.colorTextSecondary,alignHorizontal:$?"right":"left",children:t.desc})]})]}))};ct("quarter-circular",{component:mw,composites:["icon","label","desc"]});var xX=Object.defineProperty,wX=Object.defineProperties,PX=Object.getOwnPropertyDescriptors,yw=Object.getOwnPropertySymbols,$X=Object.prototype.hasOwnProperty,CX=Object.prototype.propertyIsEnumerable,vw=(e,t,n)=>t in e?xX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,OX=(e,t)=>{for(var n in t||(t={}))$X.call(t,n)&&vw(e,n,t[n]);if(yw)for(var n of yw(t))CX.call(t,n)&&vw(e,n,t[n]);return e},SX=(e,t)=>wX(e,PX(t));const bw=e=>{const[{datum:t,indexes:n,width:r=150,height:i=150,iconSize:o=30,padding:a=20,borderRadius:s=16,positionH:c="center",positionV:l="middle",themeColors:u},h]=st(e,["width","height","iconSize","padding","borderRadius"]),d=r-a*2,f=a,g=a,y=c==="flipped"?r-a-o:c==="center"?(r-o)/2:f,m=g,v=m+o+8,b=se(p(Ge,{indexes:n,width:d,children:t.label})),_=c==="flipped"?r-a-d:c==="center"?a:f,x=v+b.height+4,w=_,P=s;let $="";return c==="center"&&l==="middle"?$=`
|
|
41
|
-
M ${
|
|
42
|
-
L ${r-
|
|
43
|
-
Q ${r} 0 ${r} ${
|
|
44
|
-
L ${r} ${i-
|
|
45
|
-
Q ${r} ${i} ${r-
|
|
46
|
-
L ${
|
|
47
|
-
Q 0 ${i} 0 ${i-
|
|
48
|
-
L 0 ${
|
|
49
|
-
Q 0 0 ${
|
|
39
|
+
${o(c)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push(s("title","string",1)),i.push(s("desc","string",1))),n.includes("item")&&r.length>0&&i.push(s("items",`Array<${a(0,1)}>`,1)),i.push("}"),i.join(`
|
|
40
|
+
`)}function T_(e){let t=0;if(e.length===0)return t.toString();for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);t=(t<<5)-t+r,t=t&t}return Math.abs(t).toString()}var gH=Object.defineProperty,mH=Object.defineProperties,yH=Object.getOwnPropertyDescriptors,R_=Object.getOwnPropertySymbols,vH=Object.prototype.hasOwnProperty,bH=Object.prototype.propertyIsEnumerable,k_=(e,t,n)=>t in e?gH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_H=(e,t)=>{for(var n in t||(t={}))vH.call(t,n)&&k_(e,n,t[n]);if(R_)for(var n of R_(t))bH.call(t,n)&&k_(e,n,t[n]);return e},wH=(e,t)=>mH(e,yH(t));const xH=new WeakMap;function CH(e,t={}){const n=Me("use",wH(_H({},t),{href:Tb(e)}));return L_(n),xH.set(n,e),n}function L_(e){const{stroke:t,fill:n}=cn(e,["fill","stroke"]);e.style.color=n||t||"currentColor"}function ma(e){return e.tagName==="use"?e:e.querySelector("use")}function ch(e){const t=ma(e);return t?cn(t,["width","height","x","y","width","height","fill","fill-opacity","stroke","opacity"]):{}}function PH(e,t,n){const r=ma(e);r&&(n&&ut(r,n),L_(r))}const uh=!!(typeof process!="undefined"&&process.versions&&process.versions.node),OH=",",SH=(e,t=OH)=>e.split(t).map(n=>parseInt(n,10)),N_=e=>SH(e);function hh(...e){return e.map(t=>t.replace(/^\/+|\/+$/g,"")).filter(t=>t.trim().length>0).join("/")}function fh(e){const t=e.getAttribute("viewBox");if(t){const[s,a,l,c]=t.split(" ").map(Number);return{x:s,y:a,width:l,height:c}}const n=e.getAttribute("width"),r=e.getAttribute("height"),i=Number(n)||0,o=Number(r)||0;return{x:0,y:0,width:i,height:o}}function Lr(e){return e?typeof e=="number"?[e,e,e,e]:e.length===1?[e[0],e[0],e[0],e[0]]:e.length===2?[e[0],e[1],e[0],e[1]]:e.length===3?[e[0],e[1],e[2],e[1]]:e.length===4?[e[0],e[1],e[2],e[3]]:[0,0,0,0]:[0,0,0,0]}function z_(e,t){if(uh)D_(e,t);else if(document.contains(e))q_(e,t);else try{const n=new MutationObserver(r=>{r.forEach(i=>{i.addedNodes.forEach(o=>{(o===e||o.contains(e))&&($H(e,()=>{q_(e,t)}),n.disconnect())})})});n.observe(document,{childList:!0,subtree:!0})}catch(n){D_(e,t)}}function D_(e,t){const n=fh(e),[r,i,o,s]=t;ut(e,{viewBox:`${n.x-s} ${n.y-r} ${n.width+s+i} ${n.height+r+o}`})}function q_(e,t){const n=e.getBBox(),r=e.getBoundingClientRect(),i=r.width>0?n.width/r.width:1,o=r.height>0?n.height/r.height:1,[s,a,l,c]=t,u=s*o,h=a*i,f=l*o,d=c*i,p=n.x-d,g=n.y-u,m=n.width+d+h,v=n.height+u+f;ut(e,{viewBox:`${p} ${g} ${m} ${v}`})}function $H(e,t){requestAnimationFrame(()=>{const n=()=>{const r=e.getBoundingClientRect();r.width>0&&r.height>0?t():requestAnimationFrame(n)};n()})}function An(e,t){if(document.getElementById(e))return;const n=document.createElement("style");n.id=e,n.textContent=t,document.head.appendChild(n)}function EH(){return crypto&&crypto.randomUUID?crypto.randomUUID():"xxxx-xxxx-4xxx-yxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e==="x"?t:t&3|8).toString(16)})}var MH=Object.defineProperty,IH=Object.defineProperties,AH=Object.getOwnPropertyDescriptors,ya=Object.getOwnPropertySymbols,H_=Object.prototype.hasOwnProperty,j_=Object.prototype.propertyIsEnumerable,F_=(e,t,n)=>t in e?MH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ut=(e,t)=>{for(var n in t||(t={}))H_.call(t,n)&&F_(e,n,t[n]);if(ya)for(var n of ya(t))j_.call(t,n)&&F_(e,n,t[n]);return e},dh=(e,t)=>IH(e,AH(t)),TH=(e,t)=>{var n={};for(var r in e)H_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&ya)for(var r of ya(e))t.indexOf(r)<0&&j_.call(e,r)&&(n[r]=e[r]);return n};function Ne(e){const t=e,{id:n,x:r=0,y:i=0,width:o,height:s,alignHorizontal:a="left",alignVertical:l="top",children:c,fontSize:u=14,fontFamily:h,fontStyle:f,fontWeight:d,textDecoration:p,letterSpacing:g,wordSpacing:m,opacity:v,fill:b="black",lineHeight:_,wordWrap:x,backgroundColor:w="none",backgroundOpacity:C=1,backgroundRadius:P=0}=t,O=TH(t,["id","x","y","width","height","alignHorizontal","alignVertical","children","fontSize","fontFamily","fontStyle","fontWeight","textDecoration","letterSpacing","wordSpacing","opacity","fill","lineHeight","wordWrap","backgroundColor","backgroundOpacity","backgroundRadius"]);let $=o,S=s,M=0,I=0;if(!$||!S){const F=C_(c,e);$||($=F.width),S||(S=F.height)}o&&(M=a==="center"?$/2:a==="right"?$:0),s&&(I=l==="middle"?S/2:l==="bottom"?S:0);const E=Object.entries(Ut(Ut({width:$,height:S},_!==void 0&&{"line-height":_}),x!==void 0&&{"data-word-wrap":x})).reduce((F,[X,G])=>dh(Ut({},F),{[X]:G}),{}),N=Ut(Ut(Ut(Ut(Ut(Ut(Ut(Ut(Ut({"data-element-type":"text",width:$,height:S,x:M,y:I,"data-x":0,"data-y":0,fill:b,fontSize:u,textAnchor:a==="center"?"middle":a==="right"?"end":"start",dominantBaseline:l==="middle"?"central":l==="bottom"?"baseline":"hanging","data-horizontal-align":a.toUpperCase(),"data-vertical-align":l.toUpperCase(),children:c},E),O),h&&{fontFamily:h}),f&&{fontStyle:f}),d&&{fontWeight:d}),p&&p!=="none"&&{textDecoration:p}),g&&{letterSpacing:g}),m&&{wordSpacing:m}),v!==void 0&&v!==1&&{opacity:v}),H=Ut(dh(Ut({},r!==0||i!==0?{x:r,y:i,transform:`translate(${r}, ${i})`}:{}),{width:$,height:S}),n&&{id:n}),B=w&&w!=="none"?{"data-element-type":"shape",x:0,y:0,width:$,height:S,fill:w,fillOpacity:C,rx:P,ry:P}:void 0;return{type:"g",props:dh(Ut({},H),{children:[...B?[{type:"rect",props:B}]:[],{type:"text",props:N}]})}}const Co=Symbol.for("@antv/infographic/Fragment");function va(e,t={}){return{type:e,props:t}}function RH(e={}){return va(Co,e)}const kH=va,LH=va;function NH(e){return!e||typeof e!="object"||Array.isArray(e)?!1:e.type===Co}function B_(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&"type"in e}function Po(e){return Oo(e).filter(B_)}function Oo(e,t=[]){var n;if(!e||typeof e=="boolean")return t;if(Array.isArray(e))e.forEach(r=>Oo(r,t));else if(NH(e)){const r=(n=e.props)==null?void 0:n.children;(Array.isArray(r)?r:[r]).filter(Boolean).forEach(i=>{Oo(i,t)})}else t.push(e);return t}function at(e){return typeof e=="number"&&!Number.isNaN(e)&&Number.isFinite(e)}const ba=()=>({x:0,y:0,width:0,height:0});function Ci(e){if(!e||e.length===0)return ba();let t=1/0,n=1/0,r=-1/0,i=-1/0;for(const o of e){const{x:s,y:a,width:l,height:c}=o,u=s+l,h=a+c;s<t&&(t=s),a<n&&(n=a),u>r&&(r=u),h>i&&(i=h)}return t===1/0||n===1/0||r===-1/0||i===-1/0?{x:0,y:0,width:0,height:0}:{x:t,y:n,width:Math.max(0,r-t),height:Math.max(0,i-n)}}function ae(e){var t,n,r,i;if(!e)return ba();if(Array.isArray(e)){const d=Po(e);return Nr(d)}if(typeof e!="object")return ba();const{type:o,props:s={}}=e;if(bh(e)){const d=K_(e);return ae(d)}if(typeof o=="function"){const d=(t=s.x)!=null?t:0,p=(n=s.y)!=null?n:0,g=s.width,m=s.height;if(at(g)&&at(m))return{x:d,y:p,width:g,height:m};const v=o(s);if(!v)return{x:d,y:p,width:g!=null?g:0,height:m!=null?m:0};if(Array.isArray(v)){const b=Po(v),_=Nr(b);if(at(g)&&at(m))return{x:d,y:p,width:g,height:m};const x=_.width!==0?_.width:g!=null?g:0,w=_.height!==0?_.height:m!=null?m:0;return{x:d+_.x,y:p+_.y,width:x,height:w}}if(B_(v)){const b=v,_=ae(b);if(zH(b,s))return _;const x=b.props&&at(b.props.width)&&at(b.props.height),P=W_(b).flatMap(M=>Po(M)).length>0,O=b.props&&b.props.x===s.x&&b.props.y===s.y;if(x)return{x:O?_.x:d+_.x,y:O?_.y:p+_.y,width:_.width,height:_.height};if(at(g)&&at(m))return P?{x:O?_.x:d,y:O?_.y:p,width:g,height:m}:{x:O?_.x:d+_.x,y:O?_.y:p+_.y,width:g,height:m};const $=_.width!==0?_.width:g!=null?g:0,S=_.height!==0?_.height:m!=null?m:0;return{x:O?_.x:d+_.x,y:O?_.y:p+_.y,width:$,height:S}}return{x:d,y:p,width:g!=null?g:0,height:m!=null?m:0}}const a=(r=s.x)!=null?r:0,l=(i=s.y)!=null?i:0,c=at(s.width)?s.width:void 0,u=at(s.height)?s.height:void 0;if(at(c)&&at(u))return{x:a,y:l,width:c,height:u};const f=W_(e).flatMap(d=>Po(d));if(f.length>0){const d=Nr(f);return{x:a+d.x,y:l+d.y,width:at(c)?c:d.width,height:at(u)?u:d.height}}return{x:a,y:l,width:c!=null?c:0,height:u!=null?u:0}}function Nr(e){if(!e||!Array.isArray(e)||e.length===0)return ba();const t=[];for(const n of e){const r=Po(n);for(const i of r){const o=ae(i);o&&t.push(o)}}return Ci(t)}function zH(e,t){if(!(e!=null&&e.props)||!t)return!1;const n=e.props;if(at(n.x)&&at(n.y)&&at(t.x)&&at(t.y)&&n.x===t.x&&n.y===t.y){const r=at(n.width)&&at(n.height),i=at(t.width)&&at(t.height);if(!r&&!i)return!0}return at(n.x)&&at(n.y)&&at(n.width)&&at(n.height)&&at(t.x)&&at(t.y)&&at(t.width)&&at(t.height)?n.x===t.x&&n.y===t.y&&n.width===t.width&&n.height===t.height:!1}function W_(e){var t;const n=(t=e.props)==null?void 0:t.children;return n?Array.isArray(n)?n:[n]:[]}function ph(e){var t;return e==null||typeof e=="boolean"?[]:Array.isArray(e)?Oo(e):typeof e=="object"?Oo((t=e.props)==null?void 0:t.children):[e]}var DH=Object.defineProperty,_a=Object.getOwnPropertySymbols,V_=Object.prototype.hasOwnProperty,G_=Object.prototype.propertyIsEnumerable,Y_=(e,t,n)=>t in e?DH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gh=(e,t)=>{for(var n in t||(t={}))V_.call(t,n)&&Y_(e,n,t[n]);if(_a)for(var n of _a(t))G_.call(t,n)&&Y_(e,n,t[n]);return e},qH=(e,t)=>{var n={};for(var r in e)V_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_a)for(var r of _a(e))t.indexOf(r)<0&&G_.call(e,r)&&(n[r]=e[r]);return n};const dr=(e,t)=>{const n=e,{type:r,props:i}=n,o=qH(n,["type","props"]);return gh({type:r,props:gh(gh({},i),t)},o)},X_=()=>({defs:new Map});function mh(e){const t={"&":"&","<":"<",">":">",'"':""","'":"'"};return String(e).replace(/[&<>"']/g,n=>t[n])}const U_={className:"class",viewBox:"viewBox",preserveAspectRatio:"preserveAspectRatio",gradientUnits:"gradientUnits",gradientTransform:"gradientTransform",patternUnits:"patternUnits",patternContentUnits:"patternContentUnits",patternTransform:"patternTransform",maskUnits:"maskUnits",maskContentUnits:"maskContentUnits",clipPathUnits:"clipPathUnits",primitiveUnits:"primitiveUnits",filterUnits:"filterUnits",markerUnits:"markerUnits",markerWidth:"markerWidth",markerHeight:"markerHeight",refX:"refX",refY:"refY",xmlLang:"xml:lang",xmlSpace:"xml:space",xmlnsXlink:"xmlns:xlink",xlinkHref:"href",xlinkTitle:"xlink:title",xlinkShow:"xlink:show",xlinkActuate:"xlink:actuate",textLength:"textLength",lengthAdjust:"lengthAdjust",attributeName:"attributeName",attributeType:"attributeType",repeatCount:"repeatCount",repeatDur:"repeatDur",calcMode:"calcMode",keyTimes:"keyTimes",keySplines:"keySplines",keyPoints:"keyPoints",stdDeviation:"stdDeviation",baseFrequency:"baseFrequency",numOctaves:"numOctaves",pathLength:"pathLength",systemLanguage:"systemLanguage",requiredFeatures:"requiredFeatures",requiredExtensions:"requiredExtensions"};function HH(e){return U_[e]?U_[e]:e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}const yh=new Map;function vh(e){const t=Symbol("layout");return yh.set(t,e),r=>({type:t,props:r})}function bh(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.type=="symbol"&&yh.has(e.type)}function K_(e,t=X_()){const n=yh.get(e.type);if(!n)return console.warn("Layout function not found for symbol:",e.type),e;const r=ph(e).filter(i=>typeof i=="object");return n(r,e.props,t)}var jH=Object.defineProperty,FH=Object.defineProperties,BH=Object.getOwnPropertyDescriptors,wa=Object.getOwnPropertySymbols,Z_=Object.prototype.hasOwnProperty,Q_=Object.prototype.propertyIsEnumerable,J_=(e,t,n)=>t in e?jH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WH=(e,t)=>{for(var n in t||(t={}))Z_.call(t,n)&&J_(e,n,t[n]);if(wa)for(var n of wa(t))Q_.call(t,n)&&J_(e,n,t[n]);return e},VH=(e,t)=>FH(e,BH(t)),ew=(e,t)=>{var n={};for(var r in e)Z_.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&wa)for(var r of wa(e))t.indexOf(r)<0&&Q_.call(e,r)&&(n[r]=e[r]);return n};function So(e,t){if(e==null||typeof e=="boolean")return null;if(typeof e=="string"||typeof e=="number")return e;if(Array.isArray(e))return e.map(r=>So(r,t)).filter(Boolean);if(bh(e)){const r=K_(e,t);return So(r,t)}if(typeof e.type=="function"){const r=e.type(e.props);return So(r,t)}const n=ph(e).map(r=>So(r,t)).filter(Boolean);return e.type===Co?n:e.type===Sc?(n.forEach(r=>{typeof r=="object"&&r.props.id&&t.defs.set(r.props.id,r)}),null):n.length?dr(e,{children:n}):e}function $o(e,t){if(e==null)return"";if(typeof e=="string")return mh(e);if(typeof e=="number")return String(e);const{type:n,props:r}=e;if(!n)return"";const i=ph(e);if(n===Co)return i.map(l=>$o(l)).filter(Boolean).join("");if(n===Sc)return"";if(typeof n=="function"||bh(e))return console.warn("Unexpected unprocessed component in render:",e),"";const o=nw(r),s=i.map(l=>$o(l)).filter(Boolean).join(""),a=String(n);return s?`<${a}${o}>${s}</${a}>`:`<${a}${o} />`}function tw(e,t={}){const n=X_(),r=So(e,n);if(!r)return"";const i=Array.isArray(r)?r.map(m=>$o(m)).join(""):$o(r),o=t,{x:s,y:a,width:l,height:c,style:u}=o,h=ew(o,["x","y","width","height","style"]),f=VH(WH({},h),{xmlns:"http://www.w3.org/2000/svg"});if(!f.viewBox)if(l&&c)f.viewBox=`${s!=null?s:0} ${a!=null?a:0} ${l!=null?l:0} ${c!=null?c:0}`;else{const m=ae(r);if(m){const{x:v,y:b,width:_,height:x}=m;f.viewBox=`${v} ${b} ${_} ${x}`}}const d=nw(f),p=GH(u),g=n.defs.size?`<defs>${Array.from(n.defs.values()).map(m=>$o(m)).join("")}</defs>`:"";return`<svg${d}${p}>${g}${i}</svg>`}function nw(e){if(!e)return"";const t=e,{children:n}=t,r=ew(t,["children"]);return Object.entries(r).filter(([,i])=>i!=null).map(([i,o])=>{const s=HH(i),a=typeof o=="string"?mh(String(o)):String(o);return` ${s}="${a}"`}).join("")}function GH(e){if(!e||Object.keys(e).length===0)return"";const t=Object.entries(e).map(([n,r])=>`${n.replace(/[A-Z]/g,o=>`-${o.toLowerCase()}`)}: ${r};`).join("");return` style="${mh(t)}"`}var YH=Object.defineProperty,xa=Object.getOwnPropertySymbols,rw=Object.prototype.hasOwnProperty,iw=Object.prototype.propertyIsEnumerable,ow=(e,t,n)=>t in e?YH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ca=(e,t)=>{for(var n in t||(t={}))rw.call(t,n)&&ow(e,n,t[n]);if(xa)for(var n of xa(t))iw.call(t,n)&&ow(e,n,t[n]);return e},sw=(e,t)=>{var n={};for(var r in e)rw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&xa)for(var r of xa(e))t.indexOf(r)<0&&iw.call(e,r)&&(n[r]=e[r]);return n};const Q=e=>{const t=e,{indexes:n}=t,r=sw(t,["indexes"]),i={fill:"#B9EBCA",fillOpacity:.3,width:20,height:20,"data-indexes":n,"data-element-type":Ge.BtnAdd};return y(ke,Ca(Ca({},i),r))},nt=e=>{const t=e,{indexes:n}=t,r=sw(t,["indexes"]),i={fill:"#F9C0C0",fillOpacity:.3,width:20,height:20,"data-indexes":n,"data-element-type":Ge.BtnRemove};return y(ke,Ca(Ca({},i),r))};var XH=Object.defineProperty,UH=Object.defineProperties,KH=Object.getOwnPropertyDescriptors,aw=Object.getOwnPropertySymbols,ZH=Object.prototype.hasOwnProperty,QH=Object.prototype.propertyIsEnumerable,lw=(e,t,n)=>t in e?XH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,JH=(e,t)=>{for(var n in t||(t={}))ZH.call(t,n)&&lw(e,n,t[n]);if(aw)for(var n of aw(t))QH.call(t,n)&&lw(e,n,t[n]);return e},ej=(e,t)=>UH(e,KH(t));const qe=e=>y(Y,ej(JH({"data-element-type":Ge.BtnsGroup,width:0,height:0},e),{display:"none"})),yt=()=>y(tt,{});var tj=Object.defineProperty,Pa=Object.getOwnPropertySymbols,cw=Object.prototype.hasOwnProperty,uw=Object.prototype.propertyIsEnumerable,hw=(e,t,n)=>t in e?tj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_h=(e,t)=>{for(var n in t||(t={}))cw.call(t,n)&&hw(e,n,t[n]);if(Pa)for(var n of Pa(t))uw.call(t,n)&&hw(e,n,t[n]);return e},nj=(e,t)=>{var n={};for(var r in e)cw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Pa)for(var r of Pa(e))t.indexOf(r)<0&&uw.call(e,r)&&(n[r]=e[r]);return n};const fw=e=>{var t=e,{indexes:n}=t,r=nj(t,["indexes"]);const o=_h(_h({},{fill:"lightgray"}),r);return n?(o["data-indexes"]=n,o["data-element-type"]=Ge.ItemIllus):o["data-element-type"]=Ge.Illus,y(ke,_h({},o))};var rj=Object.defineProperty,ij=Object.defineProperties,oj=Object.getOwnPropertyDescriptors,Oa=Object.getOwnPropertySymbols,dw=Object.prototype.hasOwnProperty,pw=Object.prototype.propertyIsEnumerable,gw=(e,t,n)=>t in e?rj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mw=(e,t)=>{for(var n in t||(t={}))dw.call(t,n)&&gw(e,n,t[n]);if(Oa)for(var n of Oa(t))pw.call(t,n)&&gw(e,n,t[n]);return e},sj=(e,t)=>ij(e,oj(t)),aj=(e,t)=>{var n={};for(var r in e)dw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Oa)for(var r of Oa(e))t.indexOf(r)<0&&pw.call(e,r)&&(n[r]=e[r]);return n};const ft=e=>{var t=e,{indexes:n,lineNumber:r=2,children:i}=t,o=aj(t,["indexes","lineNumber","children"]),s;if(!i)return null;const a=mw({fontSize:14,fill:"#666",wordWrap:!0,lineHeight:1.4,children:i},o);return(s=a.height)!=null||(a.height=Math.ceil(r*+a.lineHeight*+a.fontSize)),y(Ne,sj(mw({},a),{"data-indexes":n,"data-element-type":Ge.ItemDesc}))};var lj=Object.defineProperty,cj=Object.defineProperties,uj=Object.getOwnPropertyDescriptors,Sa=Object.getOwnPropertySymbols,yw=Object.prototype.hasOwnProperty,vw=Object.prototype.propertyIsEnumerable,bw=(e,t,n)=>t in e?lj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Eo=(e,t)=>{for(var n in t||(t={}))yw.call(t,n)&&bw(e,n,t[n]);if(Sa)for(var n of Sa(t))vw.call(t,n)&&bw(e,n,t[n]);return e},$a=(e,t)=>cj(e,uj(t)),_w=(e,t)=>{var n={};for(var r in e)yw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Sa)for(var r of Sa(e))t.indexOf(r)<0&&vw.call(e,r)&&(n[r]=e[r]);return n};const Ft=e=>{const t=e,{indexes:n,size:r=32}=t,i=_w(t,["indexes","size"]),o=Eo({fill:"lightgray",width:r,height:r},i);return y(ke,$a(Eo({},o),{"data-indexes":n,"data-element-type":"item-icon"}))},zr=e=>{const t=e,{indexes:n,size:r=50,fill:i,colorBg:o="white"}=t,s=_w(t,["indexes","size","fill","colorBg"]),a=r/Math.SQRT2*.9,l=(r-a)/2,c=$a(Eo({fill:o},s),{x:l,y:l,width:a,height:a});return k(Y,$a(Eo({},s),{width:r,height:r,"data-element-type":Ge.ItemIconGroup,children:[y(Ze,{width:r,height:r,fill:i,"data-element-type":"shape"}),y(ke,$a(Eo({},c),{"data-indexes":n,"data-element-type":Ge.ItemIcon}))]}))};var hj=Object.defineProperty,fj=Object.defineProperties,dj=Object.getOwnPropertyDescriptors,Ea=Object.getOwnPropertySymbols,ww=Object.prototype.hasOwnProperty,xw=Object.prototype.propertyIsEnumerable,Cw=(e,t,n)=>t in e?hj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Pw=(e,t)=>{for(var n in t||(t={}))ww.call(t,n)&&Cw(e,n,t[n]);if(Ea)for(var n of Ea(t))xw.call(t,n)&&Cw(e,n,t[n]);return e},pj=(e,t)=>fj(e,dj(t)),gj=(e,t)=>{var n={};for(var r in e)ww.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ea)for(var r of Ea(e))t.indexOf(r)<0&&xw.call(e,r)&&(n[r]=e[r]);return n};const Ve=e=>{var t=e,{indexes:n,children:r}=t,i=gj(t,["indexes","children"]),o;const s=Pw({fontSize:18,fontWeight:"bold",fill:"#252525",lineHeight:1.4,children:r},i);return(o=s.height)!=null||(s.height=Math.ceil(+s.lineHeight*+s.fontSize)),y(Ne,pj(Pw({},s),{"data-indexes":n,"data-element-type":Ge.ItemLabel}))};var mj=Object.defineProperty,Ow=Object.getOwnPropertySymbols,yj=Object.prototype.hasOwnProperty,vj=Object.prototype.propertyIsEnumerable,Sw=(e,t,n)=>t in e?mj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,bj=(e,t)=>{for(var n in t||(t={}))yj.call(t,n)&&Sw(e,n,t[n]);if(Ow)for(var n of Ow(t))vj.call(t,n)&&Sw(e,n,t[n]);return e};const ze=e=>y(Y,bj({"data-element-type":Ge.ItemsGroup},e));var _j=Object.defineProperty,wj=Object.defineProperties,xj=Object.getOwnPropertyDescriptors,Ma=Object.getOwnPropertySymbols,$w=Object.prototype.hasOwnProperty,Ew=Object.prototype.propertyIsEnumerable,Mw=(e,t,n)=>t in e?_j(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Iw=(e,t)=>{for(var n in t||(t={}))$w.call(t,n)&&Mw(e,n,t[n]);if(Ma)for(var n of Ma(t))Ew.call(t,n)&&Mw(e,n,t[n]);return e},Cj=(e,t)=>wj(e,xj(t)),Pj=(e,t)=>{var n={};for(var r in e)$w.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ma)for(var r of Ma(e))t.indexOf(r)<0&&Ew.call(e,r)&&(n[r]=e[r]);return n};const Mo=e=>{var t=e,{indexes:n,value:r,formatter:i=l=>String(l)}=t,o=Pj(t,["indexes","value","formatter"]),s;const a=Iw({fontSize:14,fill:"#666",wordWrap:!0,lineHeight:1.4,children:i(r),"data-value":r},o);return(s=a.height)!=null||(a.height=Math.ceil(+a.lineHeight*+a.fontSize)),y(Ne,Cj(Iw({},a),{"data-indexes":n,"data-element-type":Ge.ItemValue}))};var Oj=Object.defineProperty,Aw=Object.getOwnPropertySymbols,Sj=Object.prototype.hasOwnProperty,$j=Object.prototype.propertyIsEnumerable,Tw=(e,t,n)=>t in e?Oj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ej=(e,t)=>{for(var n in t||(t={}))Sj.call(t,n)&&Tw(e,n,t[n]);if(Aw)for(var n of Aw(t))$j.call(t,n)&&Tw(e,n,t[n]);return e};const Pt=e=>y(Y,Ej({"data-element-type":"shapes-group"},e));var Mj=Object.defineProperty,Ij=Object.defineProperties,Aj=Object.getOwnPropertyDescriptors,Ia=Object.getOwnPropertySymbols,Rw=Object.prototype.hasOwnProperty,kw=Object.prototype.propertyIsEnumerable,Lw=(e,t,n)=>t in e?Mj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Aa=(e,t)=>{for(var n in t||(t={}))Rw.call(t,n)&&Lw(e,n,t[n]);if(Ia)for(var n of Ia(t))kw.call(t,n)&&Lw(e,n,t[n]);return e},Nw=(e,t)=>Ij(e,Aj(t)),Tj=(e,t)=>{var n={};for(var r in e)Rw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ia)for(var r of Ia(e))t.indexOf(r)<0&&kw.call(e,r)&&(n[r]=e[r]);return n};const Pi=vh((e,t)=>{var n=t,{horizontal:r,vertical:i}=n,o=Tj(n,["horizontal","vertical"]),s,a,l,c;if(!e||e.length===0)return y(Y,Aa({},o));const u=e.map(b=>ae(b)),h=Nr(e),f=(s=o.x)!=null?s:h.x,d=(a=o.y)!=null?a:h.y,p=(l=o.width)!=null?l:h.width,g=(c=o.height)!=null?c:h.height,m=e.map((b,_)=>{const x=u[_],w=Aa({},b.props);if(r!==void 0)switch(r){case"left":w.x=-x.x;break;case"center":w.x=(p-x.width)/2-x.x;break;case"right":w.x=p-x.width-x.x;break}else w.x===void 0&&(w.x=x.x-f);if(i!==void 0)switch(i){case"top":w.y=-x.y;break;case"middle":w.y=(g-x.height)/2-x.y;break;case"bottom":w.y=g-x.height-x.y;break}else w.y===void 0&&(w.y=x.y-d);return dr(b,w)}),v=Nw(Aa({},o),{x:f,y:d,width:p,height:g});return y(Y,Nw(Aa({},v),{children:m}))});var Rj=Object.defineProperty,kj=Object.defineProperties,Lj=Object.getOwnPropertyDescriptors,Ta=Object.getOwnPropertySymbols,zw=Object.prototype.hasOwnProperty,Dw=Object.prototype.propertyIsEnumerable,qw=(e,t,n)=>t in e?Rj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Dr=(e,t)=>{for(var n in t||(t={}))zw.call(t,n)&&qw(e,n,t[n]);if(Ta)for(var n of Ta(t))Dw.call(t,n)&&qw(e,n,t[n]);return e},Hw=(e,t)=>kj(e,Lj(t)),Nj=(e,t)=>{var n={};for(var r in e)zw.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ta)for(var r of Ta(e))t.indexOf(r)<0&&Dw.call(e,r)&&(n[r]=e[r]);return n};const ve=vh((e,t)=>{var n=t,{flexDirection:r="row",justifyContent:i="flex-start",alignItems:o="flex-start",alignContent:s="flex-start",flexWrap:a="nowrap",gap:l=0}=n,c=Nj(n,["flexDirection","justifyContent","alignItems","alignContent","flexWrap","gap"]),u,h,f,d,p,g;if(!e||e.length===0)return y(Y,Dr({},c));const m=r==="row"||r==="row-reverse",v=r==="row-reverse"||r==="column-reverse",b=e.map(E=>ae(E)),_=Nr(e),x=(u=c.width)!=null?u:_.width,w=(h=c.height)!=null?h:_.height,C=c.width!==void 0&&c.height!==void 0,P=[];if(a==="wrap"&&C){let E=[],A=[],T=0;for(let N=0;N<e.length;N++){const H=e[N],D=b[N],B=m?D.width:D.height,F=m?x:w;E.length===0||T+l+B<=F?(E.push(H),A.push(D),T+=(E.length>1?l:0)+B):(P.push({children:E,bounds:A}),E=[H],A=[D],T=B)}E.length>0&&P.push({children:E,bounds:A})}else P.push({children:e,bounds:b});const O=[];let $=0;const S=[];if(P.forEach(E=>{const{children:A,bounds:T}=E,N=T.reduce((G,L,R)=>{const z=m?L.width:L.height;return G+z+(R>0?l:0)},0),H=Math.max(...T.map(G=>m?G.height:G.width));S.push(H);let D=0;const B=(m?x:w)-N;if(C)switch(i){case"flex-end":D=B;break;case"center":D=B/2;break;case"space-between":D=0;break;default:D=0;break}let F=l;C&&i==="space-between"&&A.length>1&&(F=B/(A.length-1)+l);let X=D;A.forEach((G,L)=>{const R=T[L],z=m?R.width:R.height,q=m?R.height:R.width,j=m?R.x:R.y,V=m?R.y:R.x;let U=$;if(C)switch(o){case"flex-end":U=$+H-q;break;case"center":U=$+(H-q)/2;break;default:U=$;break}let K,ne;m?(K=v?x-X-z-j:X-j,ne=U-V):(K=U-V,ne=v?w-X-z-j:X-j);const J=dr(G,{x:K,y:ne});O.push(J),X+=z+F}),$+=H+l}),P.length>1&&C){const E=S.reduce((N,H)=>N+H,0)+(P.length-1)*l,A=(m?w:x)-E;let T=0;switch(s){case"flex-end":T=A;break;case"center":T=A/2;break;case"space-between":if(P.length>1){const N=A/(P.length-1);let H=0;P.forEach((D,B)=>{const F=P.slice(0,B).reduce((G,L)=>G+L.children.length,0),X=F+D.children.length;for(let G=F;G<X;G++){const L=O[G],R=Dr({},L.props);m?R.y=(R.y||0)+H:R.x=(R.x||0)+H,O[G]=dr(L,R)}H+=S[B]+l+(B<P.length-1?N:0)});break}break;default:T=0;break}T!==0&&s!=="space-between"&&O.forEach((N,H)=>{const D=Dr({},N.props);m?D.y=(D.y||0)+T:D.x=(D.x||0)+T,O[H]=dr(N,D)})}if(!C&&o==="center")if(m){const E=Math.max(...b.map(A=>A.height));O.forEach((A,T)=>{const N=b[T],H=(E-N.height)/2,D=Dr({},A.props);D.y=(D.y||0)+H,O[T]=dr(A,D)})}else{const E=Math.max(...b.map(A=>A.width));O.forEach((A,T)=>{const N=b[T],H=(E-N.width)/2,D=Dr({},A.props);D.x=(D.x||0)+H,O[T]=dr(A,D)})}const M=Nr(O),I=Hw(Dr({},c),{x:(f=c.x)!=null?f:_.x,y:(d=c.y)!=null?d:_.y,width:(p=c.width)!=null?p:M.width,height:(g=c.height)!=null?g:M.height});return y(Y,Hw(Dr({},I),{children:O}))});var zj=Object.defineProperty,Dj=Object.defineProperties,qj=Object.getOwnPropertyDescriptors,jw=Object.getOwnPropertySymbols,Hj=Object.prototype.hasOwnProperty,jj=Object.prototype.propertyIsEnumerable,Fw=(e,t,n)=>t in e?zj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ra=(e,t)=>{for(var n in t||(t={}))Hj.call(t,n)&&Fw(e,n,t[n]);if(jw)for(var n of jw(t))jj.call(t,n)&&Fw(e,n,t[n]);return e},Bw=(e,t)=>Dj(e,qj(t));const Ww=e=>{const{x:t=0,y:n=0,alignHorizontal:r="center",title:i,desc:o,descLineNumber:s=2,themeColors:a}=e,l=u=>{const h={fontSize:24,fill:a.colorPrimaryText,lineHeight:1.4,alignHorizontal:r};return y(Ne,Bw(Ra(Ra({},h),u),{"data-element-type":"title",children:i}))},c=u=>{const h={fontSize:16,fill:a.colorTextSecondary,alignHorizontal:r,lineHeight:1.4,height:s*24};return y(Ne,Bw(Ra(Ra({},h),u),{"data-element-type":"desc",children:o}))};return!i&&!o?null:k(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",x:t,y:n,gap:8,children:[i&&y(l,{}),o&&y(c,{})]})},wh=new Map;function xh(e,t){wh.set(e,t)}function Vw(e){return wh.get(e)}function Fj(){return Array.from(wh.keys())}xh("dark",{colorBg:"#1F1F1F",base:{text:{fill:"#fff"}}}),xh("hand-drawn",{base:{text:{"font-family":"851tegakizatsu"}},stylize:{type:"rough"}});var Bj=Object.defineProperty,Wj=Object.defineProperties,Vj=Object.getOwnPropertyDescriptors,Gw=Object.getOwnPropertySymbols,Gj=Object.prototype.hasOwnProperty,Yj=Object.prototype.propertyIsEnumerable,Yw=(e,t,n)=>t in e?Bj(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Io=(e,t)=>{for(var n in t||(t={}))Gj.call(t,n)&&Yw(e,n,t[n]);if(Gw)for(var n of Gw(t))Yj.call(t,n)&&Yw(e,n,t[n]);return e},Ao=(e,t)=>Wj(e,Vj(t));ot($2);const Xw=({colorPrimary:e,colorBg:t="#ffffff",isDarkMode:n=!1})=>{const r=En(e),i=En(t),o=Jj({primaryColor:r,bgColor:i});return eF(o,{primaryColor:r,bgColor:i,isDarkMode:n})},Xj=(e,t)=>_A(Ao(Io({},e),{alpha:t?.2:.1}))||"#ffffff",Uj=(e,t)=>{if(t)return"#ffffff";const n=En("#262626");return fu(n,e)>=7?io(n):"#000000"},Kj=e=>{const t=q2(En(e)),n=Ao(Io({},t),{l:Math.min(1,t.l+.2)});return io(n)},Zj=(e,t)=>{const n=En(e),r=En("#262626"),i=En("#ffffff"),o=fu(r,n);return fu(i,n)>=3?io(i):o>=4.5?io(r):"#ffffff"},Qj=(e,t)=>{const n=q2(e);if(t){const r=Ao(Io({},n),{l:Math.min(1,n.l+.1)});return ka(r,"#1f1f1f")}else{if(n.l>.95)return"#ffffff";{const r=Ao(Io({},n),{l:Math.min(1,n.l+.05)});return ka(r,"#ffffff")}}},Jj=({primaryColor:e,bgColor:t})=>({colorPrimary:ka(e,"#FF356A"),colorBg:ka(t,"#ffffff"),colorWhite:"#ffffff"}),eF=(e,{primaryColor:t,bgColor:n,isDarkMode:r})=>{const i=Uj(n,r),o=Xj(t,r);return Ao(Io({},e),{isDarkMode:r,colorPrimaryBg:o,colorText:i,colorTextSecondary:Kj(i),colorPrimaryText:Zj(o,r),colorBgElevated:Qj(n,r)})};function ka(e,t="#000000"){var n;return(n=io(e))!=null?n:t}const Ch="#FF356A";function Ot(e){var t;return((t=e==null?void 0:e.themeConfig)==null?void 0:t.colorPrimary)||Ch}function Uw(e){var t;const{themeConfig:n={},data:r}=e,{colorPrimary:i,palette:o}=n;return!o||o.length===0?Array(((t=r==null?void 0:r.items)==null?void 0:t.length)||1).fill(i||Ch):r.items.map((s,a)=>Vs(o,[a],r.items.length)||Ch)}function He(e,t){var n,r,i;return Vs((n=e==null?void 0:e.themeConfig)==null?void 0:n.palette,t,(i=(r=e.data)==null?void 0:r.items)==null?void 0:i.length)}function Et(e,t){var n;const{colorBg:r=((n=t==null?void 0:t.themeConfig)==null?void 0:n.colorBg)||"white",colorPrimary:i=t?Ot(t):"black"}=e;return Xw({colorPrimary:i,isDarkMode:H2(r),colorBg:r})}function Kw(e,t){const{depth:n,originalIndexes:r,flatIndex:i}=e;switch(t){case"level":return[n];case"branch":return n===0?[0]:n===1?[r[1]+1]:[r[1]+1];case"node":return r;case"node-flat":return i!==void 0?[i]:(console.warn("node-flat mode requires flatIndex in HierarchyNode, falling back to originalIndexes"),r);default:return[0]}}var tF=Object.defineProperty,Zw=Object.getOwnPropertySymbols,nF=Object.prototype.hasOwnProperty,rF=Object.prototype.propertyIsEnumerable,Qw=(e,t,n)=>t in e?tF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,iF=(e,t)=>{for(var n in t||(t={}))nF.call(t,n)&&Qw(e,n,t[n]);if(Zw)for(var n of Zw(t))rF.call(t,n)&&Qw(e,n,t[n]);return e};function lt(e,t=[]){const n=iF({},e),r={};return["indexes","data","datum","positionH","positionV","themeColors","valueFormatter",...t].forEach(o=>{o in n&&(r[o]=n[o],delete n[o])}),["x","y","width","height"].forEach(o=>{o in e&&(n[o]=e[o])}),[r,n]}function La(e,t){var n;return e.length===0?()=>null:t===void 0?e[0]:(n=e[t])!=null?n:e[0]}const Ph=new Map;function ct(e,t){Ph.set(e,t)}function Jw(e){return Ph.get(e)}function oF(){return Array.from(Ph.keys())}var sF=Object.defineProperty,aF=Object.defineProperties,lF=Object.getOwnPropertyDescriptors,e3=Object.getOwnPropertySymbols,cF=Object.prototype.hasOwnProperty,uF=Object.prototype.propertyIsEnumerable,t3=(e,t,n)=>t in e?sF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hF=(e,t)=>{for(var n in t||(t={}))cF.call(t,n)&&t3(e,n,t[n]);if(e3)for(var n of e3(t))uF.call(t,n)&&t3(e,n,t[n]);return e},fF=(e,t)=>aF(e,lF(t));const n3=e=>{const[{datum:t,indexes:n,width:r=200,height:i=80,iconSize:o=24,badgeSize:s=32,gap:a=8,positionH:l="normal",themeColors:c,valueFormatter:u},h]=lt(e,["width","height","iconSize","badgeSize","gap"]),f=t.value,d=f!==void 0,p=!!t.desc,g=!!t.icon,m=`${c.colorPrimary}-badge`,v=l==="flipped"?r-a-s:a,b=g?l==="flipped"?a:s+2*a:a,_=r-a*2,x=g?r-s-3*a:_,w=a+14+18+8,C=w-a,P=p?a:(i-s)/2,O=!d&&!p?(i-14)/2:a,$=!g&&l==="center"?"center":l==="flipped"?"right":"left";return k(Y,fF(hF({},h),{width:r,height:i,children:[y(Ke,{children:k("radialGradient",{id:m,cx:"50%",cy:"50%",r:"50%",children:[y("stop",{offset:"0%",stopColor:c.colorPrimary}),y("stop",{offset:"100%",stopColor:be(c.colorPrimary).darken(20).toHexString()})]})}),y(ke,{"data-element-type":"shape",x:0,y:0,width:r,height:i,fill:c.colorPrimaryBg,rx:8,ry:8}),g&&k(tt,{children:[y(Ze,{x:v,y:P,width:s,height:s,fill:`url(#${m})`}),y(Ft,{indexes:n,x:v+(s-o)/2,y:P+(s-o)/2,size:o,fill:c.colorWhite})]}),k(ve,{flexDirection:"column",x:b,y:O,width:x,height:!d&&!p?void 0:C,alignItems:"center",justifyContent:"center",children:[y(Ve,{indexes:n,width:x,alignHorizontal:$,alignVertical:"middle",fontSize:14,fill:c.colorText,children:t.label}),d&&y(Mo,{indexes:n,width:x,alignHorizontal:l==="flipped"?"right":"left",alignVertical:"middle",fontSize:18,lineHeight:1,fontWeight:"bold",fill:c.colorPrimary,value:f,formatter:u})]}),p&&y(ft,{indexes:n,x:a,y:w,width:_,alignHorizontal:$,fontSize:11,fill:c.colorTextSecondary,lineNumber:2,lineHeight:1.2,wordWrap:!0,children:t.desc})]}))};ct("badge-card",{component:n3,composites:["icon","label","value","desc"]});var dF=Object.defineProperty,pF=Object.defineProperties,gF=Object.getOwnPropertyDescriptors,r3=Object.getOwnPropertySymbols,mF=Object.prototype.hasOwnProperty,yF=Object.prototype.propertyIsEnumerable,i3=(e,t,n)=>t in e?dF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,vF=(e,t)=>{for(var n in t||(t={}))mF.call(t,n)&&i3(e,n,t[n]);if(r3)for(var n of r3(t))yF.call(t,n)&&i3(e,n,t[n]);return e},bF=(e,t)=>pF(e,gF(t));const o3=e=>{const[{indexes:t,datum:n,width:r=280,height:i=140,themeColors:o},s]=lt(e,["width","height"]);return k(Y,bF(vF({},s),{children:[y("rect",{x:0,y:0,width:r,height:i,rx:22,ry:22,fill:o.colorPrimaryBg,stroke:o.colorPrimary,"data-element-type":"shape"}),y(Ce,{x:r-85,y:.5,width:85,height:65,d:"M0 0H62.4495C74.9557 0 85.4549 10.8574 84.4557 23.1875V60.1875L77.8772 62.5839C64.3776 67.6876 48.51 64.6893 37.8662 53.7441L10.2361 25.3312C4.91402 19.8571 1.65356 13.1736 0.435652 6.21819L0 0Z",fill:o.colorBg,"data-element-type":"shape"}),y(Ve,{indexes:t,x:20,y:24,width:200,alignHorizontal:"left",alignVertical:"middle",fill:o.colorText,children:n.label}),y(ft,{indexes:t,x:20,y:58,width:220,height:70,fill:o.colorTextSecondary,alignHorizontal:"left",alignVertical:"top",children:n.desc}),y(Ft,{indexes:t,x:r-48,y:12,width:32,height:32,fill:o.colorPrimary})]}))};ct("candy-card-lite",{component:o3,composites:["icon","label","desc"]});var _F=Object.defineProperty,wF=Object.defineProperties,xF=Object.getOwnPropertyDescriptors,Na=Object.getOwnPropertySymbols,s3=Object.prototype.hasOwnProperty,a3=Object.prototype.propertyIsEnumerable,l3=(e,t,n)=>t in e?_F(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,CF=(e,t)=>{for(var n in t||(t={}))s3.call(t,n)&&l3(e,n,t[n]);if(Na)for(var n of Na(t))a3.call(t,n)&&l3(e,n,t[n]);return e},PF=(e,t)=>wF(e,xF(t)),OF=(e,t)=>{var n={};for(var r in e)s3.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Na)for(var r of Na(e))t.indexOf(r)<0&&a3.call(e,r)&&(n[r]=e[r]);return n};const Oh=e=>{const t=e,{color:n="black",opacity:r=.8}=t,i=OF(t,["color","opacity"]);return y("filter",PF(CF({id:"drop-shadow",x:"-25%",y:"-25%",width:"200%",height:"200%"},i),{children:y("feDropShadow",{dx:"4",dy:"4",stdDeviation:"4","flood-color":n,"flood-opacity":r})}))};var SF=Object.defineProperty,$F=Object.defineProperties,EF=Object.getOwnPropertyDescriptors,c3=Object.getOwnPropertySymbols,MF=Object.prototype.hasOwnProperty,IF=Object.prototype.propertyIsEnumerable,u3=(e,t,n)=>t in e?SF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,AF=(e,t)=>{for(var n in t||(t={}))MF.call(t,n)&&u3(e,n,t[n]);if(c3)for(var n of c3(t))IF.call(t,n)&&u3(e,n,t[n]);return e},TF=(e,t)=>$F(e,EF(t));const Sh=e=>{const{id:t="linear-gradient",startColor:n="black",stopColor:r="white",direction:i="left-right"}=e;return k("linearGradient",TF(AF({id:t},{"left-right":{x1:"0%",y1:"0%",x2:"100%",y2:"0%"},"right-left":{x1:"100%",y1:"0%",x2:"0%",y2:"0%"},"top-bottom":{x1:"0%",y1:"0%",x2:"0%",y2:"100%"},"bottom-top":{x1:"0%",y1:"100%",x2:"0%",y2:"0%"}}[i]),{children:[y("stop",{offset:"0%",stopColor:n}),y("stop",{offset:"100%",stopColor:r})]}))};var RF=Object.defineProperty,kF=Object.defineProperties,LF=Object.getOwnPropertyDescriptors,h3=Object.getOwnPropertySymbols,NF=Object.prototype.hasOwnProperty,zF=Object.prototype.propertyIsEnumerable,f3=(e,t,n)=>t in e?RF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,To=(e,t)=>{for(var n in t||(t={}))NF.call(t,n)&&f3(e,n,t[n]);if(h3)for(var n of h3(t))zF.call(t,n)&&f3(e,n,t[n]);return e},Ro=(e,t)=>kF(e,LF(t));const d3=e=>{const[{datum:t,indexes:n,width:r=300,height:i=80,gap:o=12,positionH:s="normal",iconPadding:a=i/10,themeColors:l},c]=lt(e,["width","height","gap","iconPadding"]),u=i/2,h=i-a*2,f=s==="flipped",d=!!t.icon,p=d?r-i-o:r-o*2,g=d?f?o:i:o,m=d?f?"right":"left":"center",v={indexes:n,width:p,alignHorizontal:m,alignVertical:"middle",fontSize:16,fontWeight:"600",fill:l.colorWhite},b=ae(y(Ve,Ro(To({},v),{children:t.label}))),_={indexes:n,width:p,alignHorizontal:m,alignVertical:"top",fontSize:12,lineNumber:1,fill:l.colorWhite},x=ae(t.desc?y(ft,Ro(To({},_),{children:t.desc})):null),w=4,C=b.height+w+x.height,O=(i-C)/2,$=O+b.height+w,S=f?r-i+a:a,M=a;return k(Y,Ro(To({},c),{children:[y(Ke,{children:y(Oh,{})}),y(ke,{x:0,y:0,width:r,height:i,fill:l.colorPrimary,rx:u,ry:u,"data-element-type":"shape"}),t.icon&&k(tt,{children:[y(Ze,{x:S,y:M,width:h,height:h,fillOpacity:.5,fill:l.colorBg,filter:"url(#drop-shadow)"}),y(zr,{indexes:n,x:S,y:M,size:h,fill:l.colorBg,colorBg:l.colorPrimary})]}),t.label&&y(Ve,Ro(To({x:g,y:O},v),{children:t.label})),t.desc&&y(ft,Ro(To({x:g,y:$},_),{children:t.desc}))]}))};ct("capsule-item",{component:d3,composites:["icon","label","desc"]});var DF=Object.defineProperty,qF=Object.defineProperties,HF=Object.getOwnPropertyDescriptors,p3=Object.getOwnPropertySymbols,jF=Object.prototype.hasOwnProperty,FF=Object.prototype.propertyIsEnumerable,g3=(e,t,n)=>t in e?DF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,$h=(e,t)=>{for(var n in t||(t={}))jF.call(t,n)&&g3(e,n,t[n]);if(p3)for(var n of p3(t))FF.call(t,n)&&g3(e,n,t[n]);return e},Eh=(e,t)=>qF(e,HF(t));const m3=e=>{const[{indexes:t,datum:n,themeColors:r,positionH:i="normal",width:o=240,height:s=o},a]=lt(e,["width","height"]),l=Math.min(o,s),c=l*.7,u=(l-c)/2,h=c*Math.sqrt(2)/2,f=(l-h)/2,d=be(r.colorPrimary),p=za(d,80,.2),g=za(d,20,.8),m=za(d,75,.32),v=za(d,45,.4),b=d.clone().darken(5).toRgbString(),_=`${r.colorPrimary}-${i}-outer`,x=`${r.colorPrimary}-${i}-inner`,w=i==="flipped"?{x1:"0%",y1:"0%",x2:"100%",y2:"0%"}:{x1:"100%",y1:"0%",x2:"0%",y2:"0%"};return k(Y,Eh($h({},a),{children:[k(Ke,{children:[k("linearGradient",Eh($h({id:_},w),{children:[y("stop",{offset:"0%",stopColor:p}),y("stop",{offset:"100%",stopColor:g})]})),k("linearGradient",Eh($h({id:x},w),{children:[y("stop",{offset:"0%",stopColor:m}),y("stop",{offset:"100%",stopColor:v})]}))]}),y(Ze,{width:l,height:l,fill:`url(#${_})`,"data-element-type":"shape"}),y(Ze,{x:u,y:u,width:c,height:c,fill:`url(#${x})`,stroke:"#FFFFFF",strokeWidth:1,"data-element-type":"shape"}),y(Ve,{indexes:t,x:f,y:f,width:h,height:h,lineHeight:1.1,alignHorizontal:"center",alignVertical:"middle",fill:b,fontWeight:"500",children:n.label})]}))};ct("circle-node",{component:m3,composites:["label"]});function za(e,t,n){return be.mix(e,"#ffffff",t).setAlpha(n).toRgbString()}var BF=Object.defineProperty,WF=Object.defineProperties,VF=Object.getOwnPropertyDescriptors,y3=Object.getOwnPropertySymbols,GF=Object.prototype.hasOwnProperty,YF=Object.prototype.propertyIsEnumerable,v3=(e,t,n)=>t in e?BF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Mh=(e,t)=>{for(var n in t||(t={}))GF.call(t,n)&&v3(e,n,t[n]);if(y3)for(var n of y3(t))YF.call(t,n)&&v3(e,n,t[n]);return e},Ih=(e,t)=>WF(e,VF(t));const b3=e=>{var t;const[{datum:n,indexes:r,size:i=120,strokeWidth:o=12,gap:s=8,themeColors:a,valueFormatter:l=w=>`${Math.round(w)}%`},c]=lt(e,["size","strokeWidth","gap"]),u=(t=n.value)!=null?t:0,f=Math.min(Math.max(u/100,0),1),d=(i-o)/2,p=i/2,g=o/2,m=i-o,v=f>=1,b=f*360,_=XF(p,p,d,0,b),x={x:g,y:g,width:m,height:m};return k(Y,Ih(Mh({},c),{width:i,height:i+s+20,children:[y(ke,{width:i,height:i,fill:"none"}),y(Ze,Ih(Mh({},x),{fill:"none",stroke:"#f0f0f0",strokeWidth:o,"data-element-type":"shape"})),v?y(Ze,Ih(Mh({},x),{fill:"none",stroke:a.colorPrimary,strokeWidth:o,"data-element-type":"shape"})):y(Ce,{d:_,fill:"none",stroke:a.colorPrimary,strokeWidth:o,strokeLinecap:"round","data-element-type":"shape"}),y(Mo,{indexes:r,x:o,y:o,width:m-o,height:m-o,fontSize:24,fontWeight:"bold",fill:a.colorPrimary,alignHorizontal:"center",alignVertical:"middle",value:u,formatter:l}),y(Ve,{indexes:r,x:0,y:i+s,width:i,alignHorizontal:"center",fontSize:12,fill:a.colorTextSecondary,children:n.label})]}))};function XF(e,t,n,r,i){const o=_3(e,t,n,i),s=_3(e,t,n,r),a=i-r<=180?"0":"1";return`M ${o.x} ${o.y} A ${n} ${n} 0 ${a} 0 ${s.x} ${s.y}`}function _3(e,t,n,r){const i=(r-90)*Math.PI/180;return{x:e+n*Math.cos(i),y:t+n*Math.sin(i)}}ct("circular-progress",{component:b3,composites:["label","value"]});var UF=Object.defineProperty,KF=Object.defineProperties,ZF=Object.getOwnPropertyDescriptors,w3=Object.getOwnPropertySymbols,QF=Object.prototype.hasOwnProperty,JF=Object.prototype.propertyIsEnumerable,x3=(e,t,n)=>t in e?UF(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eB=(e,t)=>{for(var n in t||(t={}))QF.call(t,n)&&x3(e,n,t[n]);if(w3)for(var n of w3(t))JF.call(t,n)&&x3(e,n,t[n]);return e},tB=(e,t)=>KF(e,ZF(t));const C3=e=>{const[{datum:t,indexes:n,width:r=200,height:i=60,iconSize:o=20,gap:s=8,positionH:a="normal",themeColors:l,valueFormatter:c},u]=lt(e,["width","height","iconSize","gap"]),h=t.value,f=h!=null,d="compact-shadow",p=a==="flipped"?r-s-o:s,g=a==="flipped"?s:o+2*s,m=r-o-3*s,v=f?m*.8:m,b=f?m*.2:0;return k(Y,tB(eB({},u),{children:[y(Ke,{children:y("filter",{id:d,children:y("feDropShadow",{dx:"0",dy:"2",stdDeviation:"2",floodOpacity:"0.15"})})}),y(ke,{x:0,y:0,width:r,height:i,fill:l.colorBgElevated,stroke:l.colorBgElevated,strokeWidth:1,rx:6,ry:6,filter:`url(#${d})`,"data-element-type":"shape"}),y(ke,{x:a==="flipped"?r-3:0,y:0,width:3,height:i,fill:l.colorPrimary,rx:1.5,ry:1.5,"data-element-type":"shape"}),y(Ft,{indexes:n,x:p,y:(i-o)/2,size:o,fill:l.colorPrimary}),k(ve,{x:g,y:s,width:m,height:i-s*2,flexDirection:"column",justifyContent:"center",alignItems:"flex-start",children:[k(ve,{width:m,flexDirection:"row",justifyContent:"space-between",alignItems:"center",children:[y(Ve,{indexes:n,width:v,alignHorizontal:"left",fontSize:12,fill:l.colorText,children:t.label}),f&&y(Mo,{indexes:n,width:b,alignHorizontal:"right",fontSize:12,fontWeight:"bold",fill:l.colorPrimary,value:h,formatter:c})]}),y(ft,{indexes:n,width:m,alignHorizontal:"left",alignVertical:"middle",fontSize:10,fill:l.colorTextSecondary,lineNumber:2,wordWrap:!0,children:t.desc})]})]}))};ct("compact-card",{component:C3,composites:["icon","label","value","desc"]});var nB=Object.defineProperty,rB=Object.defineProperties,iB=Object.getOwnPropertyDescriptors,P3=Object.getOwnPropertySymbols,oB=Object.prototype.hasOwnProperty,sB=Object.prototype.propertyIsEnumerable,O3=(e,t,n)=>t in e?nB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,aB=(e,t)=>{for(var n in t||(t={}))oB.call(t,n)&&O3(e,n,t[n]);if(P3)for(var n of P3(t))sB.call(t,n)&&O3(e,n,t[n]);return e},lB=(e,t)=>rB(e,iB(t));const S3=e=>{const[{datum:t,indexes:n,width:r=300,height:i=30,iconSize:o=30,gap:s=5,positionH:a="normal",positionV:l="middle",themeColors:c},u]=lt(e,["width","height","iconSize","gap"]),h=r-o-s,f=l==="middle"?(i-o)/2:l==="flipped"?i-o:0;return k(Y,lB(aB({},u),{children:[y(Ce,{"data-element-type":"shape",x:a==="flipped"?h+s:0,y:f,fill:c.colorPrimary,width:o,height:o,d:"M14.7273 30C6.54538 30 0 22.9077 0 14.7269C0 6.54617 6.54538 0 14.7273 0C22.9092 0 30 6.54617 30 14.7269C30 22.9077 22.9092 30 14.7273 30ZM24.5454 10.9077C22.9092 9.27307 22.9092 9.27307 22.9092 9.27307C22.3638 8.72692 22.3638 8.7269 21.8181 8.7269C21.2727 8.7269 21.2727 8.72692 20.7273 9.27307C13.0908 16.9077 13.0908 16.9077 13.0908 16.9077C8.72731 12.5461 8.72731 12.5462 8.72731 12.5462C8.18193 12.5462 8.18193 12 7.63654 12L7.09077 12.5462C4.90923 14.1808 4.90923 14.1808 4.90923 14.1808C4.90923 14.7269 4.90923 14.7269 4.90923 15.2731C4.90923 15.8192 4.90923 15.8192 4.90923 16.3654C12 23.4539 12 23.4538 12 23.4538C12.5454 23.4538 12.5454 23.4538 13.0908 23.4538C13.6365 23.4538 13.6365 23.4538 14.1819 23.4538C24.5454 12.5461 24.5454 12.5462 24.5454 12.5462L25.0908 12C25.0908 11.4538 24.5454 10.9077 24.5454 10.9077Z"}),y(Ve,{indexes:n,x:a==="flipped"?0:o+s,width:h,height:i,fontWeight:"normal",alignVertical:"middle",wordWrap:!1,fill:"#666",children:t.label||t.desc})]}))};ct("done-list",{component:S3,composites:["label"]});var cB=Object.defineProperty,uB=Object.defineProperties,hB=Object.getOwnPropertyDescriptors,$3=Object.getOwnPropertySymbols,fB=Object.prototype.hasOwnProperty,dB=Object.prototype.propertyIsEnumerable,E3=(e,t,n)=>t in e?cB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pB=(e,t)=>{for(var n in t||(t={}))fB.call(t,n)&&E3(e,n,t[n]);if($3)for(var n of $3(t))dB.call(t,n)&&E3(e,n,t[n]);return e},gB=(e,t)=>uB(e,hB(t));const M3=e=>{const[{indexes:t,datum:n,width:r=140,themeColors:i,positionV:o="normal"},s]=lt(e,["width"]),a=o!=="flipped",l=o==="normal"?"bottom":"top",c=y(Ve,{indexes:t,width:r,fill:i.colorText,alignHorizontal:"center",alignVertical:l,fontSize:14,children:n.label}),u=y(ft,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:"center",alignVertical:l,children:n.desc}),h=y(zr,{indexes:t,fill:i.colorPrimary,colorBg:i.colorWhite}),f=y(yB,{width:8,height:30,fill:i.colorPrimary,positionV:o}),d=5,p=25,g=30,m=ae(c),v=ae(u),b=ae(h),_=ae(f),x=m.height+v.height+d+_.height-b.height-p,w=b.height+p+g+_.height+d+m.height+v.height;return y(Y,gB(pB({width:r,height:w},s),{children:k(ve,{flexDirection:"column",alignItems:"center",children:[a?k(tt,{children:[u,c,y(yt,{height:d}),f]}):k(tt,{children:[y(yt,{height:x}),h,y(yt,{height:p})]}),k(Pi,{horizontal:"center",vertical:"middle",width:r,height:g,children:[y(mB,{width:r,height:g,fill:i.colorPrimary}),y(Ne,{width:r,height:g,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:n.time?n.time:String(t[0]+1).padStart(2,"0").slice(-2)})]}),a?k(tt,{children:[y(yt,{height:p}),h]}):k(tt,{children:[f,y(yt,{height:d}),c,u]})]})}))},mB=e=>{const{x:t=0,y:n=0,width:r=100,height:i=40,fill:o="#FF356A",size:s=10}=e;return y(Yt,{width:r,height:i,points:[{x:t,y:n},{x:t+r-s,y:n},{x:t+r,y:n+i/2},{x:t+r-s,y:n+i},{x:t,y:n+i},{x:t+s,y:n+i/2}],fill:o,"data-element-type":"shape"})},yB=e=>{const{x:t=0,y:n=0,width:r=10,height:i=50,fill:o,positionV:s="top"}=e,a=r/2,l=i-a,c=2,u=a;return k(Pt,{x:t,y:n,width:r,height:i,children:[y(Ze,{width:r,height:r,fill:o,y:s==="top"?0:l-a}),y(Ce,{d:s==="top"?`M${u},${a} L${u},${a+l}`:`M${u},0 L${u},${l-a}`,strokeWidth:c,stroke:o})]})};ct("horizontal-icon-arrow",{component:M3,composites:["icon","label","desc","time"]});var vB=Object.defineProperty,bB=Object.defineProperties,_B=Object.getOwnPropertyDescriptors,I3=Object.getOwnPropertySymbols,wB=Object.prototype.hasOwnProperty,xB=Object.prototype.propertyIsEnumerable,A3=(e,t,n)=>t in e?vB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,T3=(e,t)=>{for(var n in t||(t={}))wB.call(t,n)&&A3(e,n,t[n]);if(I3)for(var n of I3(t))xB.call(t,n)&&A3(e,n,t[n]);return e},R3=(e,t)=>bB(e,_B(t));const k3=e=>{const[{indexes:t,datum:n,width:r=160,themeColors:i,positionH:o="center",positionV:s="normal"},a]=lt(e,["width"]),l=o==="normal"?"left":o==="flipped"?"right":"center",c=y(Ve,{indexes:t,width:r,alignHorizontal:l,fill:i.colorPrimary,children:n.label}),u=ae(c),h=n.desc?y(ft,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:l,alignVertical:s==="flipped"?"top":"bottom",children:n.desc}):null,f=ae(h),p=n.icon?y(zr,{size:45,indexes:t,colorBg:i.colorBg,fill:i.colorPrimary}):null,g=ae(p),m=n.time?y(Ne,{width:r,height:30,alignHorizontal:"center",alignVertical:"middle",fill:i.colorPrimary,fontSize:18,fontWeight:"bold",children:n.time}):null,v=ae(m),b=18,_=k(Pi,{horizontal:"center",vertical:"middle",width:r,height:b,children:[y(ke,{width:r,height:b,fill:i.colorPrimary,"data-element-type":"shape"}),y(Ze,{width:b+6,height:b+6,fill:i.colorBg,fillOpacity:.5,"data-element-type":"shape"}),y(Ze,{width:12,height:12,fill:"white","data-element-type":"shape"})]}),x=u.height+f.height,w=g.height+v.height+5,C=Math.abs(w-x),P=w>x?C:0,O=x>w?C:0;return s==="flipped"?k(ve,R3(T3({},a),{flexDirection:"column",alignItems:"center",children:[y(yt,{height:O}),m,p,y(yt,{height:5}),_,c,h,y(yt,{height:P})]})):k(ve,R3(T3({},a),{flexDirection:"column",alignItems:"center",children:[y(yt,{height:P}),c,h,_,y(yt,{height:5}),p,m,y(yt,{height:O})]}))};ct("horizontal-icon-line",{component:k3,composites:["icon","label","desc"]});var CB=Object.defineProperty,PB=Object.defineProperties,OB=Object.getOwnPropertyDescriptors,L3=Object.getOwnPropertySymbols,SB=Object.prototype.hasOwnProperty,$B=Object.prototype.propertyIsEnumerable,N3=(e,t,n)=>t in e?CB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,EB=(e,t)=>{for(var n in t||(t={}))SB.call(t,n)&&N3(e,n,t[n]);if(L3)for(var n of L3(t))$B.call(t,n)&&N3(e,n,t[n]);return e},MB=(e,t)=>PB(e,OB(t));const z3=e=>{var t;const[{datum:n,indexes:r,size:i=80,iconSize:o=28,badgeSize:s=24,gap:a=8,themeColors:l,width:c=84,height:u=105},h]=lt(e,["size","iconSize","badgeSize","gap"]),f=(t=n.value)!=null?t:0,d=`${l.colorPrimary}-icon`,p="#ff6b6b-badge";return k(Y,MB(EB({},h),{width:c,height:u,children:[k(Ke,{children:[k("radialGradient",{id:d,cx:"50%",cy:"30%",r:"70%",children:[y("stop",{offset:"0%",stopColor:be(l.colorPrimary).lighten(30).toHexString()}),y("stop",{offset:"100%",stopColor:l.colorPrimary})]}),k("linearGradient",{id:p,x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:"#ff6b6b"}),y("stop",{offset:"100%",stopColor:"#ee5a52"})]})]}),y(Ze,{x:0,y:0,width:i,height:i,fill:`url(#${d})`,"data-element-type":"shape"}),y(Ft,{indexes:r,x:(i-o)/2,y:(i-o)/2,size:o,fill:l.colorPrimaryText}),y(Ze,{x:i-s+4,width:s,height:s,fill:`url(#${p})`}),y(Ne,{x:i-s+4,width:s,height:s,fontSize:10,fontWeight:"bold",fill:l.colorWhite,alignHorizontal:"center",alignVertical:"middle",children:f>99?"99+":Math.round(f)}),y(Ve,{indexes:r,x:0,y:i+a,width:i,alignHorizontal:"center",fontSize:12,fill:l.colorText,children:n.label})]}))};ct("icon-badge",{component:z3,composites:["icon","label"]});var IB=Object.defineProperty,AB=Object.defineProperties,TB=Object.getOwnPropertyDescriptors,D3=Object.getOwnPropertySymbols,RB=Object.prototype.hasOwnProperty,kB=Object.prototype.propertyIsEnumerable,q3=(e,t,n)=>t in e?IB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,LB=(e,t)=>{for(var n in t||(t={}))RB.call(t,n)&&q3(e,n,t[n]);if(D3)for(var n of D3(t))kB.call(t,n)&&q3(e,n,t[n]);return e},NB=(e,t)=>AB(e,TB(t));const H3=e=>{const[{datum:t,indexes:n,width:r=200,borderRadius:i=12,padding:o=16,separatorHeight:s=2,indexFontSize:a=20,labelFontSize:l=16,gap:c=8,themeColors:u},h]=lt(e,["width","height","borderRadius","padding","separatorHeight","indexFontSize","labelFontSize","gap"]),f=n[0]+1,d=String(f).padStart(2,"0"),p=t.label!==void 0,g=t.desc!==void 0,m=be.mix(u.colorPrimary,u.colorWhite,40).toHexString(),v=u.colorBgElevated||u.colorWhite,b=r-2*o,_=ae(y(Ne,{fontSize:a,fontWeight:"bold",children:d})),x=b-_.width-c,w=p?ae(y(Ve,{indexes:n,width:x,fontSize:l,fontWeight:"bold",x:a,children:t.label})):{height:0},C=g?ae(y(ft,{indexes:n,width:b,fontSize:14,lineHeight:1.5,wordWrap:!0,children:t.desc})):{height:0},P=Math.max(_.height,w.height),O=o*2+P+(p||g?c:0)+s+(g?c:0)+C.height;return k(Y,NB(LB({},h),{width:r,height:O,children:[y(ke,{x:0,y:0,width:r,height:O,rx:i,ry:i,fill:v,stroke:be(v).darken(5).toHexString(),strokeWidth:.5,"data-element-type":"shape"}),k(Y,{x:o,y:o,children:[k(Y,{x:0,y:0,children:[y(Ne,{x:0,y:0,fontSize:a,fontWeight:"bold",fill:u.colorPrimary,alignVertical:"top",children:d}),p&&y(Ve,{indexes:n,x:a+c,y:0,width:x,fontSize:l,fontWeight:"bold",fill:u.colorTextSecondary,alignVertical:"top",children:t.label})]}),y(ke,{x:0,y:P+c,width:b,height:s,fill:m,"data-element-type":"shape"}),g&&y(ft,{indexes:n,x:0,y:P+c+s+c,width:b,fontSize:14,lineHeight:1.5,wordWrap:!0,fill:u.colorTextSecondary,children:t.desc})]})]}))};ct("indexed-card",{component:H3,composites:["label","desc"]});var zB=Object.defineProperty,DB=Object.defineProperties,qB=Object.getOwnPropertyDescriptors,j3=Object.getOwnPropertySymbols,HB=Object.prototype.hasOwnProperty,jB=Object.prototype.propertyIsEnumerable,F3=(e,t,n)=>t in e?zB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,FB=(e,t)=>{for(var n in t||(t={}))HB.call(t,n)&&F3(e,n,t[n]);if(j3)for(var n of j3(t))jB.call(t,n)&&F3(e,n,t[n]);return e},BB=(e,t)=>DB(e,qB(t));const B3=e=>{const[{indexes:t,datum:n,width:r=140,iconSize:i=24,themeColors:o},s]=lt(e,["width","iconSize"]),{label:a,desc:l}=n,c=8,u=16,h=12,f=u+h,d=r-f,p=60,g=i+44,m=u,v=p+h,b=p+u+h,_=[{x:0,y:b},{x:m,y:v},{x:m,y:b}],x=r-m-h,w=m+h,C=w+x,P=v+c/2,O=P+g,$=`M ${w} ${O} L ${w} ${P} L ${C} ${P}`,S=c/2,M=w+S,I=P+S,E=8;return k(Y,BB(FB({},s),{children:[y(ft,{indexes:t,x:f,width:d,height:p,fontSize:12,alignHorizontal:"left",alignVertical:"bottom",fill:o.colorTextSecondary,children:l}),y(Yt,{points:_,fill:o.colorPrimary,opacity:.9,width:u,height:u,"data-element-type":"shape"}),y(Ce,{d:$,stroke:o.colorPrimary,strokeWidth:c,fill:"none","data-element-type":"shape"}),y(Ft,{indexes:t,x:M+x/2-i/2,y:I+E,size:i,fill:o.colorPrimary}),y(Ve,{indexes:t,x:M,y:I+i+E*2,width:x,fontSize:14,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:o.colorText,children:a})]}))};ct("l-corner-card",{component:B3,composites:["icon","label","desc"]});var WB=Object.defineProperty,VB=Object.defineProperties,GB=Object.getOwnPropertyDescriptors,W3=Object.getOwnPropertySymbols,YB=Object.prototype.hasOwnProperty,XB=Object.prototype.propertyIsEnumerable,V3=(e,t,n)=>t in e?WB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,UB=(e,t)=>{for(var n in t||(t={}))YB.call(t,n)&&V3(e,n,t[n]);if(W3)for(var n of W3(t))XB.call(t,n)&&V3(e,n,t[n]);return e},KB=(e,t)=>VB(e,GB(t));const G3=e=>{var t,n;const[{datum:r,indexes:i,width:o=280,height:s=160,showStripe:a=!0,showGradient:l=!0,showBottomShade:c=!0,themeColors:u},h]=lt(e,["width","height","showStripe","showGradient","showBottomShade"]),f=(t=r.label)==null?void 0:t[0].toUpperCase(),d=(n=r.label)==null?void 0:n.toUpperCase(),p=u.colorPrimary,g=be(p),m=4,v=6,b=45,_=40,x=12,C=g.clone().darken(4).toHexString(),P=g.clone().lighten(x).toHexString(),O="rgba(255, 255, 255, 0)",$="rgba(0, 0, 0, 0.03)",S=`letter-card-${i.join("-")}`,M=`${S}-gradient`,I=`${S}-pattern`,E=`${S}-shade`,A=m+v,T=1,N=96,H=N*T,D=16,B=D*T,F=s/16,X=H+F+B,G=(s-X)/2,L=G+H+F;return k(Y,KB(UB({},h),{width:o,height:s,children:[k(Ke,{children:[l&&k("linearGradient",{id:M,x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:C}),y("stop",{offset:"100%",stopColor:P})]}),a&&k("pattern",{id:I,patternUnits:"userSpaceOnUse",width:A,height:A,patternTransform:`rotate(${b})`,children:[y("rect",{x:"0",y:"0",width:A,height:A,fill:O}),y("rect",{x:"0",y:"0",width:m,height:A,fill:$})]}),c&&k("linearGradient",{id:E,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:"rgba(0,0,0,0)"}),y("stop",{offset:"100%",stopColor:"rgba(0,0,0,0.16)"})]})]}),y(ke,{x:0,y:0,width:o,height:s,fill:l?`url(#${M})`:p,rx:0,ry:0,"data-element-type":"shape"}),a&&y(ke,{x:0,y:0,width:o,height:s,fill:`url(#${I})`,rx:0,ry:0}),c&&y(ke,{x:0,y:s-_,width:o,height:_,fill:`url(#${E})`,rx:0,ry:0}),f&&y(Ve,{indexes:i,x:0,y:G,width:o,fontSize:N,fontWeight:"bold",fill:"#FFFFFF",alignHorizontal:"center",alignVertical:"top",lineHeight:1,children:f}),y(Ve,{indexes:i,x:0,y:L,width:o,fontSize:D,fontWeight:"bold",fill:"#FFFFFF",alignHorizontal:"center",alignVertical:"middle",lineHeight:1,children:d})]}))};ct("letter-card",{component:G3,composites:["label"]});var ZB=Object.defineProperty,QB=Object.defineProperties,JB=Object.getOwnPropertyDescriptors,Y3=Object.getOwnPropertySymbols,eW=Object.prototype.hasOwnProperty,tW=Object.prototype.propertyIsEnumerable,X3=(e,t,n)=>t in e?ZB(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nW=(e,t)=>{for(var n in t||(t={}))eW.call(t,n)&&X3(e,n,t[n]);if(Y3)for(var n of Y3(t))tW.call(t,n)&&X3(e,n,t[n]);return e},rW=(e,t)=>QB(e,JB(t));const U3=e=>{var t,n,r;const[{datum:i,indexes:o,width:s,themeColors:a,positionH:l="normal",positionV:c="center",formatter:u=T=>T||"",usePaletteColor:h=!1,showUnderline:f=!1,underlineGap:d=6,underlineExtend:p=8,underlineThickness:g=2},m]=lt(e,["width","formatter","usePaletteColor","showUnderline","underlineGap","underlineExtend","underlineThickness"]),v=u((n=(t=i.label)!=null?t:i.desc)!=null?n:""),b=l==="flipped"?"right":l==="center"?"center":"left",_=ae(y(Ve,{indexes:o,width:s,children:v})),x=s!=null?s:_.width,w=_.height,C=f?x+p*2:0,P=w+(f?d+g:0),O=f?Math.max(x,C):x,$=(r=m.height)!=null?r:P,S=c==="middle"?($-P)/2:c==="flipped"?$-P:0,M=b==="right"?O-x:b==="center"?(O-x)/2:0,I=S,E=b==="right"?O-C:b==="center"?(O-C)/2:0,A=$;return k(Y,rW(nW({},m),{width:O,height:$,children:[y(Ve,{indexes:o,x:M,y:I,width:x,height:w,alignHorizontal:b,alignVertical:c==="flipped"?"bottom":c==="center"?"middle":"top",fill:h?a.colorPrimary:a.colorText,children:v}),f&&y(Ce,{d:`M 0 ${g/2} L ${C} ${g/2}`,x:E,y:A-g/2,width:C,height:g,stroke:a.colorPrimary,strokeWidth:g,fill:"none",strokeLinecap:"round","data-element-type":"shape"})]}))};ct("lined-text",{component:U3,composites:["label"]});var iW=Object.defineProperty,oW=Object.defineProperties,sW=Object.getOwnPropertyDescriptors,K3=Object.getOwnPropertySymbols,aW=Object.prototype.hasOwnProperty,lW=Object.prototype.propertyIsEnumerable,Z3=(e,t,n)=>t in e?iW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cW=(e,t)=>{for(var n in t||(t={}))aW.call(t,n)&&Z3(e,n,t[n]);if(K3)for(var n of K3(t))lW.call(t,n)&&Z3(e,n,t[n]);return e},uW=(e,t)=>oW(e,sW(t));const Q3=e=>{const[{datum:t,indexes:n,width:r=300,pillWidth:i=120,pillHeight:o=36,gap:s=16,positionH:a="normal",themeColors:l},c]=lt(e,["width","pillWidth","pillHeight","gap"]),u=!!t.desc,h=u?r:i,f=u?a==="center"?(h-i)/2:a==="flipped"?h-i:0:0,d=0,p=0,g=o+s,m=h,v=`drop-shadow-${l.colorPrimary}`,b="linear-gradient-white-top-bottom";return k(Y,uW(cW({},c),{children:[k(Ke,{children:[y(Oh,{id:v,color:l.colorPrimary}),y(Sh,{id:b,startColor:"#fff",stopColor:"#ffffff33",direction:"top-bottom"})]}),y(ke,{x:f,y:d,width:i,height:o,fill:l.colorPrimaryBg,stroke:l.colorPrimary,rx:o/2,ry:o/2,filter:`url(#${v})`,"data-element-type":"shape"}),y(ke,{x:f,y:d,width:i,height:o,fill:`url(#${b})`,opacity:l.isDarkMode?.4:.7,rx:o/2,ry:o/2}),y(Ve,{indexes:n,x:f,y:d,width:i,height:o,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"500",fill:l.colorText,children:t.label}),t.desc&&y(ft,{indexes:n,x:p,y:g,width:m,alignHorizontal:a==="center"?"center":a==="flipped"?"right":"left",fontSize:12,fill:l.colorTextSecondary,lineNumber:2,wordWrap:!0,children:t.desc})]}))};ct("pill-badge",{component:Q3,composites:["label","desc"]});var hW=Object.defineProperty,fW=Object.defineProperties,dW=Object.getOwnPropertyDescriptors,J3=Object.getOwnPropertySymbols,pW=Object.prototype.hasOwnProperty,gW=Object.prototype.propertyIsEnumerable,ex=(e,t,n)=>t in e?hW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,mW=(e,t)=>{for(var n in t||(t={}))pW.call(t,n)&&ex(e,n,t[n]);if(J3)for(var n of J3(t))gW.call(t,n)&&ex(e,n,t[n]);return e},yW=(e,t)=>fW(e,dW(t));const tx=e=>{var t;const[{indexes:n,datum:r,width:i=120,themeColors:o,positionH:s="normal",positionV:a="center",formatter:l=g=>g||"",usePaletteColor:c=!1,lineNumber:u=1},h]=lt(e,["width","formatter","usePaletteColor","lineNumber"]),f=14,d=1.4,p=(t=h.height)!=null?t:Math.ceil(u*d*f);return y(Ve,yW(mW({},h),{indexes:n,width:i,height:p,lineHeight:d,fill:c?o.colorPrimary:o.colorText,fontSize:f,fontWeight:"regular",alignHorizontal:s==="flipped"?"right":s==="center"?"center":"left",alignVertical:a==="flipped"?"bottom":a==="center"?"middle":"top",children:l(r.label||r.desc)}))};ct("plain-text",{component:tx,composites:["label"]});function Da(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function vW(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function nx(e){let t,n,r;e.length!==2?(t=Da,n=(a,l)=>Da(e(a),l),r=(a,l)=>e(a)-l):(t=e===Da||e===vW?e:bW,n=e,r=e);function i(a,l,c=0,u=a.length){if(c<u){if(t(l,l)!==0)return u;do{const h=c+u>>>1;n(a[h],l)<0?c=h+1:u=h}while(c<u)}return c}function o(a,l,c=0,u=a.length){if(c<u){if(t(l,l)!==0)return u;do{const h=c+u>>>1;n(a[h],l)<=0?c=h+1:u=h}while(c<u)}return c}function s(a,l,c=0,u=a.length){const h=i(a,l,c,u-1);return h>c&&r(a[h-1],l)>-r(a[h],l)?h-1:h}return{left:i,center:s,right:o}}function bW(){return 0}function _W(e){return e===null?NaN:+e}const wW=nx(Da).right;nx(_W).center;const xW=Math.sqrt(50),CW=Math.sqrt(10),PW=Math.sqrt(2);function qa(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),s=o>=xW?10:o>=CW?5:o>=PW?2:1;let a,l,c;return i<0?(c=Math.pow(10,-i)/s,a=Math.round(e*c),l=Math.round(t*c),a/c<e&&++a,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*s,a=Math.round(e/c),l=Math.round(t/c),a*c<e&&++a,l*c>t&&--l),l<a&&.5<=n&&n<2?qa(e,t,n*2):[a,l,c]}function OW(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,s]=r?qa(t,e,n):qa(e,t,n);if(!(o>=i))return[];const a=o-i+1,l=new Array(a);if(r)if(s<0)for(let c=0;c<a;++c)l[c]=(o-c)/-s;else for(let c=0;c<a;++c)l[c]=(o-c)*s;else if(s<0)for(let c=0;c<a;++c)l[c]=(i+c)/-s;else for(let c=0;c<a;++c)l[c]=(i+c)*s;return l}function Ah(e,t,n){return t=+t,e=+e,n=+n,qa(e,t,n)[2]}function SW(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?Ah(t,e,n):Ah(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}var $W={value:()=>{}};function Th(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new Ha(n)}function Ha(e){this._=e}function EW(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",i=n.indexOf(".");if(i>=0&&(r=n.slice(i+1),n=n.slice(0,i)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}Ha.prototype=Th.prototype={constructor:Ha,on:function(e,t){var n=this._,r=EW(e+"",n),i,o=-1,s=r.length;if(arguments.length<2){for(;++o<s;)if((i=(e=r[o]).type)&&(i=MW(n[i],e.name)))return i;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<s;)if(i=(e=r[o]).type)n[i]=rx(n[i],e.name,t);else if(t==null)for(i in n)n[i]=rx(n[i],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new Ha(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var n=new Array(i),r=0,i,o;r<i;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],r=0,i=o.length;r<i;++r)o[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],i=0,o=r.length;i<o;++i)r[i].value.apply(t,n)}};function MW(e,t){for(var n=0,r=e.length,i;n<r;++n)if((i=e[n]).name===t)return i.value}function rx(e,t,n){for(var r=0,i=e.length;r<i;++r)if(e[r].name===t){e[r]=$W,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var Rh="http://www.w3.org/1999/xhtml";const ix={svg:"http://www.w3.org/2000/svg",xhtml:Rh,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function ja(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),ix.hasOwnProperty(t)?{space:ix[t],local:e}:e}function IW(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Rh&&t.documentElement.namespaceURI===Rh?t.createElement(e):t.createElementNS(n,e)}}function AW(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function ox(e){var t=ja(e);return(t.local?AW:IW)(t)}function TW(){}function kh(e){return e==null?TW:function(){return this.querySelector(e)}}function RW(e){typeof e!="function"&&(e=kh(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=new Array(s),l,c,u=0;u<s;++u)(l=o[u])&&(c=e.call(l,l.__data__,u,o))&&("__data__"in l&&(c.__data__=l.__data__),a[u]=c);return new yn(r,this._parents)}function kW(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function LW(){return[]}function sx(e){return e==null?LW:function(){return this.querySelectorAll(e)}}function NW(e){return function(){return kW(e.apply(this,arguments))}}function zW(e){typeof e=="function"?e=NW(e):e=sx(e);for(var t=this._groups,n=t.length,r=[],i=[],o=0;o<n;++o)for(var s=t[o],a=s.length,l,c=0;c<a;++c)(l=s[c])&&(r.push(e.call(l,l.__data__,c,s)),i.push(l));return new yn(r,i)}function ax(e){return function(){return this.matches(e)}}function lx(e){return function(t){return t.matches(e)}}var DW=Array.prototype.find;function qW(e){return function(){return DW.call(this.children,e)}}function HW(){return this.firstElementChild}function jW(e){return this.select(e==null?HW:qW(typeof e=="function"?e:lx(e)))}var FW=Array.prototype.filter;function BW(){return Array.from(this.children)}function WW(e){return function(){return FW.call(this.children,e)}}function VW(e){return this.selectAll(e==null?BW:WW(typeof e=="function"?e:lx(e)))}function GW(e){typeof e!="function"&&(e=ax(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,c=0;c<s;++c)(l=o[c])&&e.call(l,l.__data__,c,o)&&a.push(l);return new yn(r,this._parents)}function cx(e){return new Array(e.length)}function YW(){return new yn(this._enter||this._groups.map(cx),this._parents)}function Fa(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Fa.prototype={constructor:Fa,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function XW(e){return function(){return e}}function UW(e,t,n,r,i,o){for(var s=0,a,l=t.length,c=o.length;s<c;++s)(a=t[s])?(a.__data__=o[s],r[s]=a):n[s]=new Fa(e,o[s]);for(;s<l;++s)(a=t[s])&&(i[s]=a)}function KW(e,t,n,r,i,o,s){var a,l,c=new Map,u=t.length,h=o.length,f=new Array(u),d;for(a=0;a<u;++a)(l=t[a])&&(f[a]=d=s.call(l,l.__data__,a,t)+"",c.has(d)?i[a]=l:c.set(d,l));for(a=0;a<h;++a)d=s.call(e,o[a],a,o)+"",(l=c.get(d))?(r[a]=l,l.__data__=o[a],c.delete(d)):n[a]=new Fa(e,o[a]);for(a=0;a<u;++a)(l=t[a])&&c.get(f[a])===l&&(i[a]=l)}function ZW(e){return e.__data__}function QW(e,t){if(!arguments.length)return Array.from(this,ZW);var n=t?KW:UW,r=this._parents,i=this._groups;typeof e!="function"&&(e=XW(e));for(var o=i.length,s=new Array(o),a=new Array(o),l=new Array(o),c=0;c<o;++c){var u=r[c],h=i[c],f=h.length,d=JW(e.call(u,u&&u.__data__,c,r)),p=d.length,g=a[c]=new Array(p),m=s[c]=new Array(p),v=l[c]=new Array(f);n(u,h,g,m,v,d,t);for(var b=0,_=0,x,w;b<p;++b)if(x=g[b]){for(b>=_&&(_=b+1);!(w=m[_])&&++_<p;);x._next=w||null}}return s=new yn(s,r),s._enter=a,s._exit=l,s}function JW(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function eV(){return new yn(this._exit||this._groups.map(cx),this._parents)}function tV(e,t,n){var r=this.enter(),i=this,o=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(i=t(i),i&&(i=i.selection())),n==null?o.remove():n(o),r&&i?r.merge(i).order():i}function nV(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,i=n.length,o=r.length,s=Math.min(i,o),a=new Array(i),l=0;l<s;++l)for(var c=n[l],u=r[l],h=c.length,f=a[l]=new Array(h),d,p=0;p<h;++p)(d=c[p]||u[p])&&(f[p]=d);for(;l<i;++l)a[l]=n[l];return new yn(a,this._parents)}function rV(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],i=r.length-1,o=r[i],s;--i>=0;)(s=r[i])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function iV(e){e||(e=oV);function t(h,f){return h&&f?e(h.__data__,f.__data__):!h-!f}for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var s=n[o],a=s.length,l=i[o]=new Array(a),c,u=0;u<a;++u)(c=s[u])&&(l[u]=c);l.sort(t)}return new yn(i,this._parents).order()}function oV(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function sV(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function aV(){return Array.from(this)}function lV(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length;i<o;++i){var s=r[i];if(s)return s}return null}function cV(){let e=0;for(const t of this)++e;return e}function uV(){return!this.node()}function hV(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var i=t[n],o=0,s=i.length,a;o<s;++o)(a=i[o])&&e.call(a,a.__data__,o,i);return this}function fV(e){return function(){this.removeAttribute(e)}}function dV(e){return function(){this.removeAttributeNS(e.space,e.local)}}function pV(e,t){return function(){this.setAttribute(e,t)}}function gV(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function mV(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function yV(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function vV(e,t){var n=ja(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?dV:fV:typeof t=="function"?n.local?yV:mV:n.local?gV:pV)(n,t))}function ux(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function bV(e){return function(){this.style.removeProperty(e)}}function _V(e,t,n){return function(){this.style.setProperty(e,t,n)}}function wV(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function xV(e,t,n){return arguments.length>1?this.each((t==null?bV:typeof t=="function"?wV:_V)(e,t,n==null?"":n)):Oi(this.node(),e)}function Oi(e,t){return e.style.getPropertyValue(t)||ux(e).getComputedStyle(e,null).getPropertyValue(t)}function CV(e){return function(){delete this[e]}}function PV(e,t){return function(){this[e]=t}}function OV(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function SV(e,t){return arguments.length>1?this.each((t==null?CV:typeof t=="function"?OV:PV)(e,t)):this.node()[e]}function hx(e){return e.trim().split(/^|\s+/)}function Lh(e){return e.classList||new fx(e)}function fx(e){this._node=e,this._names=hx(e.getAttribute("class")||"")}fx.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function dx(e,t){for(var n=Lh(e),r=-1,i=t.length;++r<i;)n.add(t[r])}function px(e,t){for(var n=Lh(e),r=-1,i=t.length;++r<i;)n.remove(t[r])}function $V(e){return function(){dx(this,e)}}function EV(e){return function(){px(this,e)}}function MV(e,t){return function(){(t.apply(this,arguments)?dx:px)(this,e)}}function IV(e,t){var n=hx(e+"");if(arguments.length<2){for(var r=Lh(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each((typeof t=="function"?MV:t?$V:EV)(n,t))}function AV(){this.textContent=""}function TV(e){return function(){this.textContent=e}}function RV(e){return function(){var t=e.apply(this,arguments);this.textContent=t==null?"":t}}function kV(e){return arguments.length?this.each(e==null?AV:(typeof e=="function"?RV:TV)(e)):this.node().textContent}function LV(){this.innerHTML=""}function NV(e){return function(){this.innerHTML=e}}function zV(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t==null?"":t}}function DV(e){return arguments.length?this.each(e==null?LV:(typeof e=="function"?zV:NV)(e)):this.node().innerHTML}function qV(){this.nextSibling&&this.parentNode.appendChild(this)}function HV(){return this.each(qV)}function jV(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function FV(){return this.each(jV)}function BV(e){var t=typeof e=="function"?e:ox(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function WV(){return null}function VV(e,t){var n=typeof e=="function"?e:ox(e),r=t==null?WV:typeof t=="function"?t:kh(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function GV(){var e=this.parentNode;e&&e.removeChild(this)}function YV(){return this.each(GV)}function XV(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function UV(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function KV(e){return this.select(e?UV:XV)}function ZV(e){return arguments.length?this.property("__data__",e):this.node().__data__}function QV(e){return function(t){e.call(this,t,this.__data__)}}function JV(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function eG(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,i=t.length,o;n<i;++n)o=t[n],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++r]=o;++r?t.length=r:delete this.__on}}}function tG(e,t,n){return function(){var r=this.__on,i,o=QV(t);if(r){for(var s=0,a=r.length;s<a;++s)if((i=r[s]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=n),i.value=t;return}}this.addEventListener(e.type,o,n),i={type:e.type,name:e.name,value:t,listener:o,options:n},r?r.push(i):this.__on=[i]}}function nG(e,t,n){var r=JV(e+""),i,o=r.length,s;if(arguments.length<2){var a=this.node().__on;if(a){for(var l=0,c=a.length,u;l<c;++l)for(i=0,u=a[l];i<o;++i)if((s=r[i]).type===u.type&&s.name===u.name)return u.value}return}for(a=t?tG:eG,i=0;i<o;++i)this.each(a(r[i],t,n));return this}function gx(e,t,n){var r=ux(e),i=r.CustomEvent;typeof i=="function"?i=new i(t,n):(i=r.document.createEvent("Event"),n?(i.initEvent(t,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(t,!1,!1)),e.dispatchEvent(i)}function rG(e,t){return function(){return gx(this,e,t)}}function iG(e,t){return function(){return gx(this,e,t.apply(this,arguments))}}function oG(e,t){return this.each((typeof t=="function"?iG:rG)(e,t))}function*sG(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],i=0,o=r.length,s;i<o;++i)(s=r[i])&&(yield s)}var aG=[null];function yn(e,t){this._groups=e,this._parents=t}function ko(){return new yn([[document.documentElement]],aG)}function lG(){return this}yn.prototype=ko.prototype={constructor:yn,select:RW,selectAll:zW,selectChild:jW,selectChildren:VW,filter:GW,data:QW,enter:YW,exit:eV,join:tV,merge:nV,selection:lG,order:rV,sort:iV,call:sV,nodes:aV,node:lV,size:cV,empty:uV,each:hV,attr:vV,style:xV,property:SV,classed:IV,text:kV,html:DV,raise:HV,lower:FV,append:BV,insert:VV,remove:YV,clone:KV,datum:ZV,on:nG,dispatch:oG,[Symbol.iterator]:sG};function Nh(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function mx(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Lo(){}var No=.7,Ba=1/No,Si="\\s*([+-]?\\d+)\\s*",zo="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Tn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",cG=/^#([0-9a-f]{3,8})$/,uG=new RegExp(`^rgb\\(${Si},${Si},${Si}\\)$`),hG=new RegExp(`^rgb\\(${Tn},${Tn},${Tn}\\)$`),fG=new RegExp(`^rgba\\(${Si},${Si},${Si},${zo}\\)$`),dG=new RegExp(`^rgba\\(${Tn},${Tn},${Tn},${zo}\\)$`),pG=new RegExp(`^hsl\\(${zo},${Tn},${Tn}\\)$`),gG=new RegExp(`^hsla\\(${zo},${Tn},${Tn},${zo}\\)$`),yx={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Nh(Lo,qr,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:vx,formatHex:vx,formatHex8:mG,formatHsl:yG,formatRgb:bx,toString:bx});function vx(){return this.rgb().formatHex()}function mG(){return this.rgb().formatHex8()}function yG(){return Px(this).formatHsl()}function bx(){return this.rgb().formatRgb()}function qr(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=cG.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?_x(t):n===3?new nn(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Wa(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Wa(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=uG.exec(e))?new nn(t[1],t[2],t[3],1):(t=hG.exec(e))?new nn(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=fG.exec(e))?Wa(t[1],t[2],t[3],t[4]):(t=dG.exec(e))?Wa(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=pG.exec(e))?Cx(t[1],t[2]/100,t[3]/100,1):(t=gG.exec(e))?Cx(t[1],t[2]/100,t[3]/100,t[4]):yx.hasOwnProperty(e)?_x(yx[e]):e==="transparent"?new nn(NaN,NaN,NaN,0):null}function _x(e){return new nn(e>>16&255,e>>8&255,e&255,1)}function Wa(e,t,n,r){return r<=0&&(e=t=n=NaN),new nn(e,t,n,r)}function vG(e){return e instanceof Lo||(e=qr(e)),e?(e=e.rgb(),new nn(e.r,e.g,e.b,e.opacity)):new nn}function zh(e,t,n,r){return arguments.length===1?vG(e):new nn(e,t,n,r==null?1:r)}function nn(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Nh(nn,zh,mx(Lo,{brighter(e){return e=e==null?Ba:Math.pow(Ba,e),new nn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?No:Math.pow(No,e),new nn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new nn(Hr(this.r),Hr(this.g),Hr(this.b),Va(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:wx,formatHex:wx,formatHex8:bG,formatRgb:xx,toString:xx}));function wx(){return`#${jr(this.r)}${jr(this.g)}${jr(this.b)}`}function bG(){return`#${jr(this.r)}${jr(this.g)}${jr(this.b)}${jr((isNaN(this.opacity)?1:this.opacity)*255)}`}function xx(){const e=Va(this.opacity);return`${e===1?"rgb(":"rgba("}${Hr(this.r)}, ${Hr(this.g)}, ${Hr(this.b)}${e===1?")":`, ${e})`}`}function Va(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Hr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function jr(e){return e=Hr(e),(e<16?"0":"")+e.toString(16)}function Cx(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new vn(e,t,n,r)}function Px(e){if(e instanceof vn)return new vn(e.h,e.s,e.l,e.opacity);if(e instanceof Lo||(e=qr(e)),!e)return new vn;if(e instanceof vn)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),s=NaN,a=o-i,l=(o+i)/2;return a?(t===o?s=(n-r)/a+(n<r)*6:n===o?s=(r-t)/a+2:s=(t-n)/a+4,a/=l<.5?o+i:2-o-i,s*=60):a=l>0&&l<1?0:s,new vn(s,a,l,e.opacity)}function _G(e,t,n,r){return arguments.length===1?Px(e):new vn(e,t,n,r==null?1:r)}function vn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Nh(vn,_G,mx(Lo,{brighter(e){return e=e==null?Ba:Math.pow(Ba,e),new vn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?No:Math.pow(No,e),new vn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new nn(Dh(e>=240?e-240:e+120,i,r),Dh(e,i,r),Dh(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new vn(Ox(this.h),Ga(this.s),Ga(this.l),Va(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Va(this.opacity);return`${e===1?"hsl(":"hsla("}${Ox(this.h)}, ${Ga(this.s)*100}%, ${Ga(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ox(e){return e=(e||0)%360,e<0?e+360:e}function Ga(e){return Math.max(0,Math.min(1,e||0))}function Dh(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const qh=e=>()=>e;function wG(e,t){return function(n){return e+n*t}}function xG(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function CG(e){return(e=+e)==1?Sx:function(t,n){return n-t?xG(t,n,e):qh(isNaN(t)?n:t)}}function Sx(e,t){var n=t-e;return n?wG(e,n):qh(isNaN(e)?t:e)}const Ya=(function e(t){var n=CG(t);function r(i,o){var s=n((i=zh(i)).r,(o=zh(o)).r),a=n(i.g,o.g),l=n(i.b,o.b),c=Sx(i.opacity,o.opacity);return function(u){return i.r=s(u),i.g=a(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r})(1);function PG(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function OG(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function SG(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),s;for(s=0;s<r;++s)i[s]=Fh(e[s],t[s]);for(;s<n;++s)o[s]=t[s];return function(a){for(s=0;s<r;++s)o[s]=i[s](a);return o}}function $G(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function bn(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function EG(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=Fh(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var Hh=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,jh=new RegExp(Hh.source,"g");function MG(e){return function(){return e}}function IG(e){return function(t){return e(t)+""}}function $x(e,t){var n=Hh.lastIndex=jh.lastIndex=0,r,i,o,s=-1,a=[],l=[];for(e=e+"",t=t+"";(r=Hh.exec(e))&&(i=jh.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),a[s]?a[s]+=o:a[++s]=o),(r=r[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:bn(r,i)})),n=jh.lastIndex;return n<t.length&&(o=t.slice(n),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?IG(l[0].x):MG(t):(t=l.length,function(c){for(var u=0,h;u<t;++u)a[(h=l[u]).i]=h.x(c);return a.join("")})}function Fh(e,t){var n=typeof t,r;return t==null||n==="boolean"?qh(t):(n==="number"?bn:n==="string"?(r=qr(t))?(t=r,Ya):$x:t instanceof qr?Ya:t instanceof Date?$G:OG(t)?PG:Array.isArray(t)?SG:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?EG:bn)(e,t)}function AG(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var Ex=180/Math.PI,Bh={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Mx(e,t,n,r,i,o){var s,a,l;return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(a=Math.sqrt(n*n+r*r))&&(n/=a,r/=a,l/=a),e*r<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:i,translateY:o,rotate:Math.atan2(t,e)*Ex,skewX:Math.atan(l)*Ex,scaleX:s,scaleY:a}}var Xa;function TG(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Bh:Mx(t.a,t.b,t.c,t.d,t.e,t.f)}function RG(e){return e==null||(Xa||(Xa=document.createElementNS("http://www.w3.org/2000/svg","g")),Xa.setAttribute("transform",e),!(e=Xa.transform.baseVal.consolidate()))?Bh:(e=e.matrix,Mx(e.a,e.b,e.c,e.d,e.e,e.f))}function Ix(e,t,n,r){function i(c){return c.length?c.pop()+" ":""}function o(c,u,h,f,d,p){if(c!==h||u!==f){var g=d.push("translate(",null,t,null,n);p.push({i:g-4,x:bn(c,h)},{i:g-2,x:bn(u,f)})}else(h||f)&&d.push("translate("+h+t+f+n)}function s(c,u,h,f){c!==u?(c-u>180?u+=360:u-c>180&&(c+=360),f.push({i:h.push(i(h)+"rotate(",null,r)-2,x:bn(c,u)})):u&&h.push(i(h)+"rotate("+u+r)}function a(c,u,h,f){c!==u?f.push({i:h.push(i(h)+"skewX(",null,r)-2,x:bn(c,u)}):u&&h.push(i(h)+"skewX("+u+r)}function l(c,u,h,f,d,p){if(c!==h||u!==f){var g=d.push(i(d)+"scale(",null,",",null,")");p.push({i:g-4,x:bn(c,h)},{i:g-2,x:bn(u,f)})}else(h!==1||f!==1)&&d.push(i(d)+"scale("+h+","+f+")")}return function(c,u){var h=[],f=[];return c=e(c),u=e(u),o(c.translateX,c.translateY,u.translateX,u.translateY,h,f),s(c.rotate,u.rotate,h,f),a(c.skewX,u.skewX,h,f),l(c.scaleX,c.scaleY,u.scaleX,u.scaleY,h,f),c=u=null,function(d){for(var p=-1,g=f.length,m;++p<g;)h[(m=f[p]).i]=m.x(d);return h.join("")}}}var kG=Ix(TG,"px, ","px)","deg)"),LG=Ix(RG,", ",")",")"),$i=0,Do=0,qo=0,Ax=1e3,Ua,Ho,Ka=0,Fr=0,Za=0,jo=typeof performance=="object"&&performance.now?performance:Date,Tx=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Wh(){return Fr||(Tx(NG),Fr=jo.now()+Za)}function NG(){Fr=0}function Qa(){this._call=this._time=this._next=null}Qa.prototype=Vh.prototype={constructor:Qa,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Wh():+n)+(t==null?0:+t),!this._next&&Ho!==this&&(Ho?Ho._next=this:Ua=this,Ho=this),this._call=e,this._time=n,Gh()},stop:function(){this._call&&(this._call=null,this._time=1/0,Gh())}};function Vh(e,t,n){var r=new Qa;return r.restart(e,t,n),r}function zG(){Wh(),++$i;for(var e=Ua,t;e;)(t=Fr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--$i}function Rx(){Fr=(Ka=jo.now())+Za,$i=Do=0;try{zG()}finally{$i=0,qG(),Fr=0}}function DG(){var e=jo.now(),t=e-Ka;t>Ax&&(Za-=t,Ka=e)}function qG(){for(var e,t=Ua,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Ua=n);Ho=e,Gh(r)}function Gh(e){if(!$i){Do&&(Do=clearTimeout(Do));var t=e-Fr;t>24?(e<1/0&&(Do=setTimeout(Rx,e-jo.now()-Za)),qo&&(qo=clearInterval(qo))):(qo||(Ka=jo.now(),qo=setInterval(DG,Ax)),$i=1,Tx(Rx))}}function kx(e,t,n){var r=new Qa;return t=t==null?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,n),r}var HG=Th("start","end","cancel","interrupt"),jG=[],Lx=0,Nx=1,Yh=2,Ja=3,zx=4,Xh=5,el=6;function tl(e,t,n,r,i,o){var s=e.__transition;if(!s)e.__transition={};else if(n in s)return;FG(e,n,{name:t,index:r,group:i,on:HG,tween:jG,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:Lx})}function Uh(e,t){var n=_n(e,t);if(n.state>Lx)throw new Error("too late; already scheduled");return n}function Rn(e,t){var n=_n(e,t);if(n.state>Ja)throw new Error("too late; already running");return n}function _n(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function FG(e,t,n){var r=e.__transition,i;r[t]=n,n.timer=Vh(o,0,n.time);function o(c){n.state=Nx,n.timer.restart(s,n.delay,n.time),n.delay<=c&&s(c-n.delay)}function s(c){var u,h,f,d;if(n.state!==Nx)return l();for(u in r)if(d=r[u],d.name===n.name){if(d.state===Ja)return kx(s);d.state===zx?(d.state=el,d.timer.stop(),d.on.call("interrupt",e,e.__data__,d.index,d.group),delete r[u]):+u<t&&(d.state=el,d.timer.stop(),d.on.call("cancel",e,e.__data__,d.index,d.group),delete r[u])}if(kx(function(){n.state===Ja&&(n.state=zx,n.timer.restart(a,n.delay,n.time),a(c))}),n.state=Yh,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Yh){for(n.state=Ja,i=new Array(f=n.tween.length),u=0,h=-1;u<f;++u)(d=n.tween[u].value.call(e,e.__data__,n.index,n.group))&&(i[++h]=d);i.length=h+1}}function a(c){for(var u=c<n.duration?n.ease.call(null,c/n.duration):(n.timer.restart(l),n.state=Xh,1),h=-1,f=i.length;++h<f;)i[h].call(e,u);n.state===Xh&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=el,n.timer.stop(),delete r[t];for(var c in r)return;delete e.__transition}}function BG(e,t){var n=e.__transition,r,i,o=!0,s;if(n){t=t==null?null:t+"";for(s in n){if((r=n[s]).name!==t){o=!1;continue}i=r.state>Yh&&r.state<Xh,r.state=el,r.timer.stop(),r.on.call(i?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[s]}o&&delete e.__transition}}function WG(e){return this.each(function(){BG(this,e)})}function VG(e,t){var n,r;return function(){var i=Rn(this,e),o=i.tween;if(o!==n){r=n=o;for(var s=0,a=r.length;s<a;++s)if(r[s].name===t){r=r.slice(),r.splice(s,1);break}}i.tween=r}}function GG(e,t,n){var r,i;if(typeof n!="function")throw new Error;return function(){var o=Rn(this,e),s=o.tween;if(s!==r){i=(r=s).slice();for(var a={name:t,value:n},l=0,c=i.length;l<c;++l)if(i[l].name===t){i[l]=a;break}l===c&&i.push(a)}o.tween=i}}function YG(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=_n(this.node(),n).tween,i=0,o=r.length,s;i<o;++i)if((s=r[i]).name===e)return s.value;return null}return this.each((t==null?VG:GG)(n,e,t))}function Kh(e,t,n){var r=e._id;return e.each(function(){var i=Rn(this,r);(i.value||(i.value={}))[t]=n.apply(this,arguments)}),function(i){return _n(i,r).value[t]}}function Dx(e,t){var n;return(typeof t=="number"?bn:t instanceof qr?Ya:(n=qr(t))?(t=n,Ya):$x)(e,t)}function XG(e){return function(){this.removeAttribute(e)}}function UG(e){return function(){this.removeAttributeNS(e.space,e.local)}}function KG(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttribute(e);return s===i?null:s===r?o:o=t(r=s,n)}}function ZG(e,t,n){var r,i=n+"",o;return function(){var s=this.getAttributeNS(e.space,e.local);return s===i?null:s===r?o:o=t(r=s,n)}}function QG(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttribute(e):(s=this.getAttribute(e),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function JG(e,t,n){var r,i,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttributeNS(e.space,e.local):(s=this.getAttributeNS(e.space,e.local),l=a+"",s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a)))}}function eY(e,t){var n=ja(e),r=n==="transform"?LG:Dx;return this.attrTween(e,typeof t=="function"?(n.local?JG:QG)(n,r,Kh(this,"attr."+e,t)):t==null?(n.local?UG:XG)(n):(n.local?ZG:KG)(n,r,t))}function tY(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function nY(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function rY(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&nY(e,o)),n}return i._value=t,i}function iY(e,t){var n,r;function i(){var o=t.apply(this,arguments);return o!==r&&(n=(r=o)&&tY(e,o)),n}return i._value=t,i}function oY(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=ja(e);return this.tween(n,(r.local?rY:iY)(r,t))}function sY(e,t){return function(){Uh(this,e).delay=+t.apply(this,arguments)}}function aY(e,t){return t=+t,function(){Uh(this,e).delay=t}}function lY(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?sY:aY)(t,e)):_n(this.node(),t).delay}function cY(e,t){return function(){Rn(this,e).duration=+t.apply(this,arguments)}}function uY(e,t){return t=+t,function(){Rn(this,e).duration=t}}function hY(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?cY:uY)(t,e)):_n(this.node(),t).duration}function fY(e,t){if(typeof t!="function")throw new Error;return function(){Rn(this,e).ease=t}}function dY(e){var t=this._id;return arguments.length?this.each(fY(t,e)):_n(this.node(),t).ease}function pY(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;Rn(this,e).ease=n}}function gY(e){if(typeof e!="function")throw new Error;return this.each(pY(this._id,e))}function mY(e){typeof e!="function"&&(e=ax(e));for(var t=this._groups,n=t.length,r=new Array(n),i=0;i<n;++i)for(var o=t[i],s=o.length,a=r[i]=[],l,c=0;c<s;++c)(l=o[c])&&e.call(l,l.__data__,c,o)&&a.push(l);return new Yn(r,this._parents,this._name,this._id)}function yY(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,i=n.length,o=Math.min(r,i),s=new Array(r),a=0;a<o;++a)for(var l=t[a],c=n[a],u=l.length,h=s[a]=new Array(u),f,d=0;d<u;++d)(f=l[d]||c[d])&&(h[d]=f);for(;a<r;++a)s[a]=t[a];return new Yn(s,this._parents,this._name,this._id)}function vY(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function bY(e,t,n){var r,i,o=vY(t)?Uh:Rn;return function(){var s=o(this,e),a=s.on;a!==r&&(i=(r=a).copy()).on(t,n),s.on=i}}function _Y(e,t){var n=this._id;return arguments.length<2?_n(this.node(),n).on.on(e):this.each(bY(n,e,t))}function wY(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function xY(){return this.on("end.remove",wY(this._id))}function CY(e){var t=this._name,n=this._id;typeof e!="function"&&(e=kh(e));for(var r=this._groups,i=r.length,o=new Array(i),s=0;s<i;++s)for(var a=r[s],l=a.length,c=o[s]=new Array(l),u,h,f=0;f<l;++f)(u=a[f])&&(h=e.call(u,u.__data__,f,a))&&("__data__"in u&&(h.__data__=u.__data__),c[f]=h,tl(c[f],t,n,f,c,_n(u,n)));return new Yn(o,this._parents,t,n)}function PY(e){var t=this._name,n=this._id;typeof e!="function"&&(e=sx(e));for(var r=this._groups,i=r.length,o=[],s=[],a=0;a<i;++a)for(var l=r[a],c=l.length,u,h=0;h<c;++h)if(u=l[h]){for(var f=e.call(u,u.__data__,h,l),d,p=_n(u,n),g=0,m=f.length;g<m;++g)(d=f[g])&&tl(d,t,n,g,f,p);o.push(f),s.push(u)}return new Yn(o,s,t,n)}var OY=ko.prototype.constructor;function SY(){return new OY(this._groups,this._parents)}function $Y(e,t){var n,r,i;return function(){var o=Oi(this,e),s=(this.style.removeProperty(e),Oi(this,e));return o===s?null:o===n&&s===r?i:i=t(n=o,r=s)}}function qx(e){return function(){this.style.removeProperty(e)}}function EY(e,t,n){var r,i=n+"",o;return function(){var s=Oi(this,e);return s===i?null:s===r?o:o=t(r=s,n)}}function MY(e,t,n){var r,i,o;return function(){var s=Oi(this,e),a=n(this),l=a+"";return a==null&&(l=a=(this.style.removeProperty(e),Oi(this,e))),s===l?null:s===r&&l===i?o:(i=l,o=t(r=s,a))}}function IY(e,t){var n,r,i,o="style."+t,s="end."+o,a;return function(){var l=Rn(this,e),c=l.on,u=l.value[o]==null?a||(a=qx(t)):void 0;(c!==n||i!==u)&&(r=(n=c).copy()).on(s,i=u),l.on=r}}function AY(e,t,n){var r=(e+="")=="transform"?kG:Dx;return t==null?this.styleTween(e,$Y(e,r)).on("end.style."+e,qx(e)):typeof t=="function"?this.styleTween(e,MY(e,r,Kh(this,"style."+e,t))).each(IY(this._id,e)):this.styleTween(e,EY(e,r,t),n).on("end.style."+e,null)}function TY(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function RY(e,t,n){var r,i;function o(){var s=t.apply(this,arguments);return s!==i&&(r=(i=s)&&TY(e,s,n)),r}return o._value=t,o}function kY(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,RY(e,t,n==null?"":n))}function LY(e){return function(){this.textContent=e}}function NY(e){return function(){var t=e(this);this.textContent=t==null?"":t}}function zY(e){return this.tween("text",typeof e=="function"?NY(Kh(this,"text",e)):LY(e==null?"":e+""))}function DY(e){return function(t){this.textContent=e.call(this,t)}}function qY(e){var t,n;function r(){var i=e.apply(this,arguments);return i!==n&&(t=(n=i)&&DY(i)),t}return r._value=e,r}function HY(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,qY(e))}function jY(){for(var e=this._name,t=this._id,n=Hx(),r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,c=0;c<a;++c)if(l=s[c]){var u=_n(l,t);tl(l,e,n,c,s,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new Yn(r,this._parents,e,n)}function FY(){var e,t,n=this,r=n._id,i=n.size();return new Promise(function(o,s){var a={value:s},l={value:function(){--i===0&&o()}};n.each(function(){var c=Rn(this,r),u=c.on;u!==e&&(t=(e=u).copy(),t._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),c.on=t}),i===0&&o()})}var BY=0;function Yn(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function Hx(){return++BY}var Xn=ko.prototype;Yn.prototype={constructor:Yn,select:CY,selectAll:PY,selectChild:Xn.selectChild,selectChildren:Xn.selectChildren,filter:mY,merge:yY,selection:SY,transition:jY,call:Xn.call,nodes:Xn.nodes,node:Xn.node,size:Xn.size,empty:Xn.empty,each:Xn.each,on:_Y,attr:eY,attrTween:oY,style:AY,styleTween:kY,text:zY,textTween:HY,remove:xY,tween:YG,delay:lY,duration:hY,ease:dY,easeVarying:gY,end:FY,[Symbol.iterator]:Xn[Symbol.iterator]};function WY(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var VY={time:null,delay:0,duration:250,ease:WY};function GY(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function YY(e){var t,n;e instanceof Yn?(t=e._id,e=e._name):(t=Hx(),(n=VY).time=Wh(),e=e==null?null:e+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,l,c=0;c<a;++c)(l=s[c])&&tl(l,e,t,c,s,n||GY(l,t));return new Yn(r,this._parents,e,t)}ko.prototype.interrupt=WG,ko.prototype.transition=YY;const Zh=Math.PI,Qh=2*Zh,Br=1e-6,XY=Qh-Br;function jx(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function UY(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return jx;const n=ds(10,t);return function(r){this._+=r[0];for(let i=1,o=r.length;i<o;++i)this._+=Math.round(arguments[i]*n)/n+r[i]}}class KY{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?jx:UY(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,r,i){this._append`Q${+t},${+n},${this._x1=+r},${this._y1=+i}`}bezierCurveTo(t,n,r,i,o,s){this._append`C${+t},${+n},${+r},${+i},${this._x1=+o},${this._y1=+s}`}arcTo(t,n,r,i,o){if(t=+t,n=+n,r=+r,i=+i,o=+o,o<0)throw new Error(`negative radius: ${o}`);let s=this._x1,a=this._y1,l=r-t,c=i-n,u=s-t,h=a-n,f=u*u+h*h;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(f>Br)if(!(Math.abs(h*l-c*u)>Br)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let d=r-s,p=i-a,g=l*l+c*c,m=d*d+p*p,v=Math.sqrt(g),b=Math.sqrt(f),_=o*Math.tan((Zh-Math.acos((g+f-m)/(2*v*b)))/2),x=_/b,w=_/v;Math.abs(x-1)>Br&&this._append`L${t+x*u},${n+x*h}`,this._append`A${o},${o},0,0,${+(h*d>u*p)},${this._x1=t+w*l},${this._y1=n+w*c}`}}arc(t,n,r,i,o,s){if(t=+t,n=+n,r=+r,s=!!s,r<0)throw new Error(`negative radius: ${r}`);let a=r*Math.cos(i),l=r*Math.sin(i),c=t+a,u=n+l,h=1^s,f=s?i-o:o-i;this._x1===null?this._append`M${c},${u}`:(Math.abs(this._x1-c)>Br||Math.abs(this._y1-u)>Br)&&this._append`L${c},${u}`,r&&(f<0&&(f=f%Qh+Qh),f>XY?this._append`A${r},${r},0,1,${h},${t-a},${n-l}A${r},${r},0,1,${h},${this._x1=c},${this._y1=u}`:f>Br&&this._append`A${r},${r},0,${+(f>=Zh)},${h},${this._x1=t+r*Math.cos(o)},${this._y1=n+r*Math.sin(o)}`)}rect(t,n,r,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${r=+r}v${+i}h${-r}Z`}toString(){return this._}}function ZY(e,t){var n,r=1;e==null&&(e=0),t==null&&(t=0);function i(){var o,s=n.length,a,l=0,c=0;for(o=0;o<s;++o)a=n[o],l+=a.x,c+=a.y;for(l=(l/s-e)*r,c=(c/s-t)*r,o=0;o<s;++o)a=n[o],a.x-=l,a.y-=c}return i.initialize=function(o){n=o},i.x=function(o){return arguments.length?(e=+o,i):e},i.y=function(o){return arguments.length?(t=+o,i):t},i.strength=function(o){return arguments.length?(r=+o,i):r},i}function QY(e){const t=+this._x.call(null,e),n=+this._y.call(null,e);return Fx(this.cover(t,n),t,n,e)}function Fx(e,t,n,r){if(isNaN(t)||isNaN(n))return e;var i,o=e._root,s={data:r},a=e._x0,l=e._y0,c=e._x1,u=e._y1,h,f,d,p,g,m,v,b;if(!o)return e._root=s,e;for(;o.length;)if((g=t>=(h=(a+c)/2))?a=h:c=h,(m=n>=(f=(l+u)/2))?l=f:u=f,i=o,!(o=o[v=m<<1|g]))return i[v]=s,e;if(d=+e._x.call(null,o.data),p=+e._y.call(null,o.data),t===d&&n===p)return s.next=o,i?i[v]=s:e._root=s,e;do i=i?i[v]=new Array(4):e._root=new Array(4),(g=t>=(h=(a+c)/2))?a=h:c=h,(m=n>=(f=(l+u)/2))?l=f:u=f;while((v=m<<1|g)===(b=(p>=f)<<1|d>=h));return i[b]=o,i[v]=s,e}function JY(e){var t,n,r=e.length,i,o,s=new Array(r),a=new Array(r),l=1/0,c=1/0,u=-1/0,h=-1/0;for(n=0;n<r;++n)isNaN(i=+this._x.call(null,t=e[n]))||isNaN(o=+this._y.call(null,t))||(s[n]=i,a[n]=o,i<l&&(l=i),i>u&&(u=i),o<c&&(c=o),o>h&&(h=o));if(l>u||c>h)return this;for(this.cover(l,c).cover(u,h),n=0;n<r;++n)Fx(this,s[n],a[n],e[n]);return this}function eX(e,t){if(isNaN(e=+e)||isNaN(t=+t))return this;var n=this._x0,r=this._y0,i=this._x1,o=this._y1;if(isNaN(n))i=(n=Math.floor(e))+1,o=(r=Math.floor(t))+1;else{for(var s=i-n||1,a=this._root,l,c;n>e||e>=i||r>t||t>=o;)switch(c=(t<r)<<1|e<n,l=new Array(4),l[c]=a,a=l,s*=2,c){case 0:i=n+s,o=r+s;break;case 1:n=i-s,o=r+s;break;case 2:i=n+s,r=o-s;break;case 3:n=i-s,r=o-s;break}this._root&&this._root.length&&(this._root=a)}return this._x0=n,this._y0=r,this._x1=i,this._y1=o,this}function tX(){var e=[];return this.visit(function(t){if(!t.length)do e.push(t.data);while(t=t.next)}),e}function nX(e){return arguments.length?this.cover(+e[0][0],+e[0][1]).cover(+e[1][0],+e[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]}function Kt(e,t,n,r,i){this.node=e,this.x0=t,this.y0=n,this.x1=r,this.y1=i}function rX(e,t,n){var r,i=this._x0,o=this._y0,s,a,l,c,u=this._x1,h=this._y1,f=[],d=this._root,p,g;for(d&&f.push(new Kt(d,i,o,u,h)),n==null?n=1/0:(i=e-n,o=t-n,u=e+n,h=t+n,n*=n);p=f.pop();)if(!(!(d=p.node)||(s=p.x0)>u||(a=p.y0)>h||(l=p.x1)<i||(c=p.y1)<o))if(d.length){var m=(s+l)/2,v=(a+c)/2;f.push(new Kt(d[3],m,v,l,c),new Kt(d[2],s,v,m,c),new Kt(d[1],m,a,l,v),new Kt(d[0],s,a,m,v)),(g=(t>=v)<<1|e>=m)&&(p=f[f.length-1],f[f.length-1]=f[f.length-1-g],f[f.length-1-g]=p)}else{var b=e-+this._x.call(null,d.data),_=t-+this._y.call(null,d.data),x=b*b+_*_;if(x<n){var w=Math.sqrt(n=x);i=e-w,o=t-w,u=e+w,h=t+w,r=d.data}}return r}function iX(e){if(isNaN(u=+this._x.call(null,e))||isNaN(h=+this._y.call(null,e)))return this;var t,n=this._root,r,i,o,s=this._x0,a=this._y0,l=this._x1,c=this._y1,u,h,f,d,p,g,m,v;if(!n)return this;if(n.length)for(;;){if((p=u>=(f=(s+l)/2))?s=f:l=f,(g=h>=(d=(a+c)/2))?a=d:c=d,t=n,!(n=n[m=g<<1|p]))return this;if(!n.length)break;(t[m+1&3]||t[m+2&3]||t[m+3&3])&&(r=t,v=m)}for(;n.data!==e;)if(i=n,!(n=n.next))return this;return(o=n.next)&&delete n.next,i?(o?i.next=o:delete i.next,this):t?(o?t[m]=o:delete t[m],(n=t[0]||t[1]||t[2]||t[3])&&n===(t[3]||t[2]||t[1]||t[0])&&!n.length&&(r?r[v]=n:this._root=n),this):(this._root=o,this)}function oX(e){for(var t=0,n=e.length;t<n;++t)this.remove(e[t]);return this}function sX(){return this._root}function aX(){var e=0;return this.visit(function(t){if(!t.length)do++e;while(t=t.next)}),e}function lX(e){var t=[],n,r=this._root,i,o,s,a,l;for(r&&t.push(new Kt(r,this._x0,this._y0,this._x1,this._y1));n=t.pop();)if(!e(r=n.node,o=n.x0,s=n.y0,a=n.x1,l=n.y1)&&r.length){var c=(o+a)/2,u=(s+l)/2;(i=r[3])&&t.push(new Kt(i,c,u,a,l)),(i=r[2])&&t.push(new Kt(i,o,u,c,l)),(i=r[1])&&t.push(new Kt(i,c,s,a,u)),(i=r[0])&&t.push(new Kt(i,o,s,c,u))}return this}function cX(e){var t=[],n=[],r;for(this._root&&t.push(new Kt(this._root,this._x0,this._y0,this._x1,this._y1));r=t.pop();){var i=r.node;if(i.length){var o,s=r.x0,a=r.y0,l=r.x1,c=r.y1,u=(s+l)/2,h=(a+c)/2;(o=i[0])&&t.push(new Kt(o,s,a,u,h)),(o=i[1])&&t.push(new Kt(o,u,a,l,h)),(o=i[2])&&t.push(new Kt(o,s,h,u,c)),(o=i[3])&&t.push(new Kt(o,u,h,l,c))}n.push(r)}for(;r=n.pop();)e(r.node,r.x0,r.y0,r.x1,r.y1);return this}function uX(e){return e[0]}function hX(e){return arguments.length?(this._x=e,this):this._x}function fX(e){return e[1]}function dX(e){return arguments.length?(this._y=e,this):this._y}function Jh(e,t,n){var r=new ef(t==null?uX:t,n==null?fX:n,NaN,NaN,NaN,NaN);return e==null?r:r.addAll(e)}function ef(e,t,n,r,i,o){this._x=e,this._y=t,this._x0=n,this._y0=r,this._x1=i,this._y1=o,this._root=void 0}function Bx(e){for(var t={data:e.data},n=t;e=e.next;)n=n.next={data:e.data};return t}var Zt=Jh.prototype=ef.prototype;Zt.copy=function(){var e=new ef(this._x,this._y,this._x0,this._y0,this._x1,this._y1),t=this._root,n,r;if(!t)return e;if(!t.length)return e._root=Bx(t),e;for(n=[{source:t,target:e._root=new Array(4)}];t=n.pop();)for(var i=0;i<4;++i)(r=t.source[i])&&(r.length?n.push({source:r,target:t.target[i]=new Array(4)}):t.target[i]=Bx(r));return e},Zt.add=QY,Zt.addAll=JY,Zt.cover=eX,Zt.data=tX,Zt.extent=nX,Zt.find=rX,Zt.remove=iX,Zt.removeAll=oX,Zt.root=sX,Zt.size=aX,Zt.visit=lX,Zt.visitAfter=cX,Zt.x=hX,Zt.y=dX;function Wr(e){return function(){return e}}function pr(e){return(e()-.5)*1e-6}function pX(e){return e.x+e.vx}function gX(e){return e.y+e.vy}function mX(e){var t,n,r,i=1,o=1;typeof e!="function"&&(e=Wr(e==null?1:+e));function s(){for(var c,u=t.length,h,f,d,p,g,m,v=0;v<o;++v)for(h=Jh(t,pX,gX).visitAfter(a),c=0;c<u;++c)f=t[c],g=n[f.index],m=g*g,d=f.x+f.vx,p=f.y+f.vy,h.visit(b);function b(_,x,w,C,P){var O=_.data,$=_.r,S=g+$;if(O){if(O.index>f.index){var M=d-O.x-O.vx,I=p-O.y-O.vy,E=M*M+I*I;E<S*S&&(M===0&&(M=pr(r),E+=M*M),I===0&&(I=pr(r),E+=I*I),E=(S-(E=Math.sqrt(E)))/E*i,f.vx+=(M*=E)*(S=($*=$)/(m+$)),f.vy+=(I*=E)*S,O.vx-=M*(S=1-S),O.vy-=I*S)}return}return x>d+S||C<d-S||w>p+S||P<p-S}}function a(c){if(c.data)return c.r=n[c.data.index];for(var u=c.r=0;u<4;++u)c[u]&&c[u].r>c.r&&(c.r=c[u].r)}function l(){if(t){var c,u=t.length,h;for(n=new Array(u),c=0;c<u;++c)h=t[c],n[h.index]=+e(h,c,t)}}return s.initialize=function(c,u){t=c,r=u,l()},s.iterations=function(c){return arguments.length?(o=+c,s):o},s.strength=function(c){return arguments.length?(i=+c,s):i},s.radius=function(c){return arguments.length?(e=typeof c=="function"?c:Wr(+c),l(),s):e},s}function yX(e){return e.index}function Wx(e,t){var n=e.get(t);if(!n)throw new Error("node not found: "+t);return n}function vX(e){var t=yX,n=h,r,i=Wr(30),o,s,a,l,c,u=1;e==null&&(e=[]);function h(m){return 1/Math.min(a[m.source.index],a[m.target.index])}function f(m){for(var v=0,b=e.length;v<u;++v)for(var _=0,x,w,C,P,O,$,S;_<b;++_)x=e[_],w=x.source,C=x.target,P=C.x+C.vx-w.x-w.vx||pr(c),O=C.y+C.vy-w.y-w.vy||pr(c),$=Math.sqrt(P*P+O*O),$=($-o[_])/$*m*r[_],P*=$,O*=$,C.vx-=P*(S=l[_]),C.vy-=O*S,w.vx+=P*(S=1-S),w.vy+=O*S}function d(){if(s){var m,v=s.length,b=e.length,_=new Map(s.map((w,C)=>[t(w,C,s),w])),x;for(m=0,a=new Array(v);m<b;++m)x=e[m],x.index=m,typeof x.source!="object"&&(x.source=Wx(_,x.source)),typeof x.target!="object"&&(x.target=Wx(_,x.target)),a[x.source.index]=(a[x.source.index]||0)+1,a[x.target.index]=(a[x.target.index]||0)+1;for(m=0,l=new Array(b);m<b;++m)x=e[m],l[m]=a[x.source.index]/(a[x.source.index]+a[x.target.index]);r=new Array(b),p(),o=new Array(b),g()}}function p(){if(s)for(var m=0,v=e.length;m<v;++m)r[m]=+n(e[m],m,e)}function g(){if(s)for(var m=0,v=e.length;m<v;++m)o[m]=+i(e[m],m,e)}return f.initialize=function(m,v){s=m,c=v,d()},f.links=function(m){return arguments.length?(e=m,d(),f):e},f.id=function(m){return arguments.length?(t=m,f):t},f.iterations=function(m){return arguments.length?(u=+m,f):u},f.strength=function(m){return arguments.length?(n=typeof m=="function"?m:Wr(+m),p(),f):n},f.distance=function(m){return arguments.length?(i=typeof m=="function"?m:Wr(+m),g(),f):i},f}const bX=1664525,_X=1013904223,Vx=4294967296;function wX(){let e=1;return()=>(e=(bX*e+_X)%Vx)/Vx}function xX(e){return e.x}function CX(e){return e.y}var PX=10,OX=Math.PI*(3-Math.sqrt(5));function SX(e){var t,n=1,r=.001,i=1-Math.pow(r,1/300),o=0,s=.6,a=new Map,l=Vh(h),c=Th("tick","end"),u=wX();e==null&&(e=[]);function h(){f(),c.call("tick",t),n<r&&(l.stop(),c.call("end",t))}function f(g){var m,v=e.length,b;g===void 0&&(g=1);for(var _=0;_<g;++_)for(n+=(o-n)*i,a.forEach(function(x){x(n)}),m=0;m<v;++m)b=e[m],b.fx==null?b.x+=b.vx*=s:(b.x=b.fx,b.vx=0),b.fy==null?b.y+=b.vy*=s:(b.y=b.fy,b.vy=0);return t}function d(){for(var g=0,m=e.length,v;g<m;++g){if(v=e[g],v.index=g,v.fx!=null&&(v.x=v.fx),v.fy!=null&&(v.y=v.fy),isNaN(v.x)||isNaN(v.y)){var b=PX*Math.sqrt(.5+g),_=g*OX;v.x=b*Math.cos(_),v.y=b*Math.sin(_)}(isNaN(v.vx)||isNaN(v.vy))&&(v.vx=v.vy=0)}}function p(g){return g.initialize&&g.initialize(e,u),g}return d(),t={tick:f,restart:function(){return l.restart(h),t},stop:function(){return l.stop(),t},nodes:function(g){return arguments.length?(e=g,d(),a.forEach(p),t):e},alpha:function(g){return arguments.length?(n=+g,t):n},alphaMin:function(g){return arguments.length?(r=+g,t):r},alphaDecay:function(g){return arguments.length?(i=+g,t):+i},alphaTarget:function(g){return arguments.length?(o=+g,t):o},velocityDecay:function(g){return arguments.length?(s=1-g,t):1-s},randomSource:function(g){return arguments.length?(u=g,a.forEach(p),t):u},force:function(g,m){return arguments.length>1?(m==null?a.delete(g):a.set(g,p(m)),t):a.get(g)},find:function(g,m,v){var b=0,_=e.length,x,w,C,P,O;for(v==null?v=1/0:v*=v,b=0;b<_;++b)P=e[b],x=g-P.x,w=m-P.y,C=x*x+w*w,C<v&&(O=P,v=C);return O},on:function(g,m){return arguments.length>1?(c.on(g,m),t):c.on(g)}}}function $X(){var e,t,n,r,i=Wr(-30),o,s=1,a=1/0,l=.81;function c(d){var p,g=e.length,m=Jh(e,xX,CX).visitAfter(h);for(r=d,p=0;p<g;++p)t=e[p],m.visit(f)}function u(){if(e){var d,p=e.length,g;for(o=new Array(p),d=0;d<p;++d)g=e[d],o[g.index]=+i(g,d,e)}}function h(d){var p=0,g,m,v=0,b,_,x;if(d.length){for(b=_=x=0;x<4;++x)(g=d[x])&&(m=Math.abs(g.value))&&(p+=g.value,v+=m,b+=m*g.x,_+=m*g.y);d.x=b/v,d.y=_/v}else{g=d,g.x=g.data.x,g.y=g.data.y;do p+=o[g.data.index];while(g=g.next)}d.value=p}function f(d,p,g,m){if(!d.value)return!0;var v=d.x-t.x,b=d.y-t.y,_=m-p,x=v*v+b*b;if(_*_/l<x)return x<a&&(v===0&&(v=pr(n),x+=v*v),b===0&&(b=pr(n),x+=b*b),x<s&&(x=Math.sqrt(s*x)),t.vx+=v*d.value*r/x,t.vy+=b*d.value*r/x),!0;if(d.length||x>=a)return;(d.data!==t||d.next)&&(v===0&&(v=pr(n),x+=v*v),b===0&&(b=pr(n),x+=b*b),x<s&&(x=Math.sqrt(s*x)));do d.data!==t&&(_=o[d.data.index]*r/x,t.vx+=v*_,t.vy+=b*_);while(d=d.next)}return c.initialize=function(d,p){e=d,n=p,u()},c.strength=function(d){return arguments.length?(i=typeof d=="function"?d:Wr(+d),u(),c):i},c.distanceMin=function(d){return arguments.length?(s=d*d,c):Math.sqrt(s)},c.distanceMax=function(d){return arguments.length?(a=d*d,c):Math.sqrt(a)},c.theta=function(d){return arguments.length?(l=d*d,c):Math.sqrt(l)},c}function EX(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function nl(e,t){if(!isFinite(e)||e===0)return null;var n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"),r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function Ei(e){return e=nl(Math.abs(e)),e?e[1]:NaN}function MX(e,t){return function(n,r){for(var i=n.length,o=[],s=0,a=e[0],l=0;i>0&&a>0&&(l+a+1>r&&(a=Math.max(1,r-l)),o.push(n.substring(i-=a,i+a)),!((l+=a+1)>r));)a=e[s=(s+1)%e.length];return o.reverse().join(t)}}function IX(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var AX=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function rl(e){if(!(t=AX.exec(e)))throw new Error("invalid format: "+e);var t;return new tf({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}rl.prototype=tf.prototype;function tf(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}tf.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function TX(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var il;function RX(e,t){var n=nl(e,t);if(!n)return il=void 0,e.toPrecision(t);var r=n[0],i=n[1],o=i-(il=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=r.length;return o===s?r:o>s?r+new Array(o-s+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+nl(e,Math.max(0,t+o-1))[0]}function Gx(e,t){var n=nl(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const Yx={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:EX,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>Gx(e*100,t),r:Gx,s:RX,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Xx(e){return e}var Ux=Array.prototype.map,Kx=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function kX(e){var t=e.grouping===void 0||e.thousands===void 0?Xx:MX(Ux.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?Xx:IX(Ux.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(h,f){h=rl(h);var d=h.fill,p=h.align,g=h.sign,m=h.symbol,v=h.zero,b=h.width,_=h.comma,x=h.precision,w=h.trim,C=h.type;C==="n"?(_=!0,C="g"):Yx[C]||(x===void 0&&(x=12),w=!0,C="g"),(v||d==="0"&&p==="=")&&(v=!0,d="0",p="=");var P=(f&&f.prefix!==void 0?f.prefix:"")+(m==="$"?n:m==="#"&&/[boxX]/.test(C)?"0"+C.toLowerCase():""),O=(m==="$"?r:/[%p]/.test(C)?s:"")+(f&&f.suffix!==void 0?f.suffix:""),$=Yx[C],S=/[defgprs%]/.test(C);x=x===void 0?6:/[gprs]/.test(C)?Math.max(1,Math.min(21,x)):Math.max(0,Math.min(20,x));function M(I){var E=P,A=O,T,N,H;if(C==="c")A=$(I)+A,I="";else{I=+I;var D=I<0||1/I<0;if(I=isNaN(I)?l:$(Math.abs(I),x),w&&(I=TX(I)),D&&+I==0&&g!=="+"&&(D=!1),E=(D?g==="("?g:a:g==="-"||g==="("?"":g)+E,A=(C==="s"&&!isNaN(I)&&il!==void 0?Kx[8+il/3]:"")+A+(D&&g==="("?")":""),S){for(T=-1,N=I.length;++T<N;)if(H=I.charCodeAt(T),48>H||H>57){A=(H===46?i+I.slice(T+1):I.slice(T))+A,I=I.slice(0,T);break}}}_&&!v&&(I=t(I,1/0));var B=E.length+I.length+A.length,F=B<b?new Array(b-B+1).join(d):"";switch(_&&v&&(I=t(F+I,F.length?b-A.length:1/0),F=""),p){case"<":I=E+I+A+F;break;case"=":I=E+F+I+A;break;case"^":I=F.slice(0,B=F.length>>1)+E+I+A+F.slice(B);break;default:I=F+E+I+A;break}return o(I)}return M.toString=function(){return h+""},M}function u(h,f){var d=Math.max(-8,Math.min(8,Math.floor(Ei(f)/3)))*3,p=Math.pow(10,-d),g=c((h=rl(h),h.type="f",h),{suffix:Kx[8+d/3]});return function(m){return g(p*m)}}return{format:c,formatPrefix:u}}var ol,Zx,Qx;LX({thousands:",",grouping:[3],currency:["$",""]});function LX(e){return ol=kX(e),Zx=ol.format,Qx=ol.formatPrefix,ol}function NX(e){return Math.max(0,-Ei(Math.abs(e)))}function zX(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Ei(t)/3)))*3-Ei(Math.abs(e)))}function DX(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Ei(t)-Ei(e))+1}function qX(e){var t=0,n=e.children,r=n&&n.length;if(!r)t=1;else for(;--r>=0;)t+=n[r].value;e.value=t}function HX(){return this.eachAfter(qX)}function jX(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this}function FX(e,t){for(var n=this,r=[n],i,o,s=-1;n=r.pop();)if(e.call(t,n,++s,this),i=n.children)for(o=i.length-1;o>=0;--o)r.push(i[o]);return this}function BX(e,t){for(var n=this,r=[n],i=[],o,s,a,l=-1;n=r.pop();)if(i.push(n),o=n.children)for(s=0,a=o.length;s<a;++s)r.push(o[s]);for(;n=i.pop();)e.call(t,n,++l,this);return this}function WX(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r}function VX(e){return this.eachAfter(function(t){for(var n=+e(t.data)||0,r=t.children,i=r&&r.length;--i>=0;)n+=r[i].value;t.value=n})}function GX(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function YX(e){for(var t=this,n=XX(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var i=r.length;e!==n;)r.splice(i,0,e),e=e.parent;return r}function XX(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),i=null;for(e=n.pop(),t=r.pop();e===t;)i=e,e=n.pop(),t=r.pop();return i}function UX(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function KX(){return Array.from(this)}function ZX(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function QX(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*JX(){var e=this,t,n=[e],r,i,o;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,r=e.children)for(i=0,o=r.length;i<o;++i)n.push(r[i]);while(n.length)}function nf(e,t){e instanceof Map?(e=[void 0,e],t===void 0&&(t=nU)):t===void 0&&(t=tU);for(var n=new Fo(e),r,i=[n],o,s,a,l;r=i.pop();)if((s=t(r.data))&&(l=(s=Array.from(s)).length))for(r.children=s,a=l-1;a>=0;--a)i.push(o=s[a]=new Fo(s[a])),o.parent=r,o.depth=r.depth+1;return n.eachBefore(iU)}function eU(){return nf(this).eachBefore(rU)}function tU(e){return e.children}function nU(e){return Array.isArray(e)?e[1]:null}function rU(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function iU(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function Fo(e){this.data=e,this.depth=this.height=0,this.parent=null}Fo.prototype=nf.prototype={constructor:Fo,count:HX,each:jX,eachAfter:BX,eachBefore:FX,find:WX,sum:VX,sort:GX,path:YX,ancestors:UX,descendants:KX,leaves:ZX,links:QX,copy:eU,[Symbol.iterator]:JX};function oU(e,t){return e.parent===t.parent?1:2}function rf(e){var t=e.children;return t?t[0]:e.t}function of(e){var t=e.children;return t?t[t.length-1]:e.t}function sU(e,t,n){var r=n/(t.i-e.i);t.c-=r,t.s+=n,e.c+=r,t.z+=n,t.m+=n}function aU(e){for(var t=0,n=0,r=e.children,i=r.length,o;--i>=0;)o=r[i],o.z+=t,o.m+=t,t+=o.s+(n+=o.c)}function lU(e,t,n){return e.a.parent===t.parent?e.a:n}function sl(e,t){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=t}sl.prototype=Object.create(Fo.prototype);function cU(e){for(var t=new sl(e,0),n,r=[t],i,o,s,a;n=r.pop();)if(o=n._.children)for(n.children=new Array(a=o.length),s=a-1;s>=0;--s)r.push(i=n.children[s]=new sl(o[s],s)),i.parent=n;return(t.parent=new sl(null,0)).children=[t],t}function uU(){var e=oU,t=1,n=1,r=null;function i(c){var u=cU(c);if(u.eachAfter(o),u.parent.m=-u.z,u.eachBefore(s),r)c.eachBefore(l);else{var h=c,f=c,d=c;c.eachBefore(function(b){b.x<h.x&&(h=b),b.x>f.x&&(f=b),b.depth>d.depth&&(d=b)});var p=h===f?1:e(h,f)/2,g=p-h.x,m=t/(f.x+p+g),v=n/(d.depth||1);c.eachBefore(function(b){b.x=(b.x+g)*m,b.y=b.depth*v})}return c}function o(c){var u=c.children,h=c.parent.children,f=c.i?h[c.i-1]:null;if(u){aU(c);var d=(u[0].z+u[u.length-1].z)/2;f?(c.z=f.z+e(c._,f._),c.m=c.z-d):c.z=d}else f&&(c.z=f.z+e(c._,f._));c.parent.A=a(c,f,c.parent.A||h[0])}function s(c){c._.x=c.z+c.parent.m,c.m+=c.parent.m}function a(c,u,h){if(u){for(var f=c,d=c,p=u,g=f.parent.children[0],m=f.m,v=d.m,b=p.m,_=g.m,x;p=of(p),f=rf(f),p&&f;)g=rf(g),d=of(d),d.a=c,x=p.z+b-f.z-m+e(p._,f._),x>0&&(sU(lU(p,c,h),c,x),m+=x,v+=x),b+=p.m,m+=f.m,_+=g.m,v+=d.m;p&&!of(d)&&(d.t=p,d.m+=b-v),f&&!rf(g)&&(g.t=f,g.m+=m-_,h=c)}return h}function l(c){c.x*=t,c.y=c.depth*n}return i.separation=function(c){return arguments.length?(e=c,i):e},i.size=function(c){return arguments.length?(r=!1,t=+c[0],n=+c[1],i):r?null:[t,n]},i.nodeSize=function(c){return arguments.length?(r=!0,t=+c[0],n=+c[1],i):r?[t,n]:null},i}function hU(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function fU(e){return function(){return e}}function dU(e){return+e}var Jx=[0,1];function Mi(e){return e}function sf(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:fU(isNaN(t)?NaN:.5)}function pU(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function gU(e,t,n){var r=e[0],i=e[1],o=t[0],s=t[1];return i<r?(r=sf(i,r),o=n(s,o)):(r=sf(r,i),o=n(o,s)),function(a){return o(r(a))}}function mU(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),s=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<r;)i[s]=sf(e[s],e[s+1]),o[s]=n(t[s],t[s+1]);return function(a){var l=wW(e,a,1,r)-1;return o[l](i[l](a))}}function yU(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function vU(){var e=Jx,t=Jx,n=Fh,r,i,o,s=Mi,a,l,c;function u(){var f=Math.min(e.length,t.length);return s!==Mi&&(s=pU(e[0],e[f-1])),a=f>2?mU:gU,l=c=null,h}function h(f){return f==null||isNaN(f=+f)?o:(l||(l=a(e.map(r),t,n)))(r(s(f)))}return h.invert=function(f){return s(i((c||(c=a(t,e.map(r),bn)))(f)))},h.domain=function(f){return arguments.length?(e=Array.from(f,dU),u()):e.slice()},h.range=function(f){return arguments.length?(t=Array.from(f),u()):t.slice()},h.rangeRound=function(f){return t=Array.from(f),n=AG,u()},h.clamp=function(f){return arguments.length?(s=f?!0:Mi,u()):s!==Mi},h.interpolate=function(f){return arguments.length?(n=f,u()):n},h.unknown=function(f){return arguments.length?(o=f,h):o},function(f,d){return r=f,i=d,u()}}function bU(){return vU()(Mi,Mi)}function _U(e,t,n,r){var i=SW(e,t,n),o;switch(r=rl(r==null?",f":r),r.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=zX(i,s))&&(r.precision=o),Qx(r,s)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=DX(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=NX(i))&&(r.precision=o-(r.type==="%")*2);break}}return Zx(r)}function wU(e){var t=e.domain;return e.ticks=function(n){var r=t();return OW(r[0],r[r.length-1],n==null?10:n)},e.tickFormat=function(n,r){var i=t();return _U(i[0],i[i.length-1],n==null?10:n,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,s=r[i],a=r[o],l,c,u=10;for(a<s&&(c=s,s=a,a=c,c=i,i=o,o=c);u-- >0;){if(c=Ah(s,a,n),c===l)return r[i]=s,r[o]=a,t(r);if(c>0)s=Math.floor(s/c)*c,a=Math.ceil(a/c)*c;else if(c<0)s=Math.ceil(s*c)/c,a=Math.floor(a*c)/c;else break;l=c}return e},e}function Bo(){var e=bU();return e.copy=function(){return yU(e,Bo())},hU.apply(e,arguments),wU(e)}function Mt(e){return function(){return e}}const e4=Math.abs,Vt=Math.atan2,Vr=Math.cos,xU=Math.max,af=Math.min,kn=Math.sin,Ii=Math.sqrt,rn=1e-12,Wo=Math.PI,al=Wo/2,ll=2*Wo;function CU(e){return e>1?0:e<-1?Wo:Math.acos(e)}function t4(e){return e>=1?al:e<=-1?-al:Math.asin(e)}function n4(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const r=Math.floor(n);if(!(r>=0))throw new RangeError(`invalid digits: ${n}`);t=r}return e},()=>new KY(t)}function PU(e){return e.innerRadius}function OU(e){return e.outerRadius}function SU(e){return e.startAngle}function $U(e){return e.endAngle}function EU(e){return e&&e.padAngle}function MU(e,t,n,r,i,o,s,a){var l=n-e,c=r-t,u=s-i,h=a-o,f=h*l-u*c;if(!(f*f<rn))return f=(u*(t-o)-h*(e-i))/f,[e+f*l,t+f*c]}function cl(e,t,n,r,i,o,s){var a=e-n,l=t-r,c=(s?o:-o)/Ii(a*a+l*l),u=c*l,h=-c*a,f=e+u,d=t+h,p=n+u,g=r+h,m=(f+p)/2,v=(d+g)/2,b=p-f,_=g-d,x=b*b+_*_,w=i-o,C=f*g-p*d,P=(_<0?-1:1)*Ii(xU(0,w*w*x-C*C)),O=(C*_-b*P)/x,$=(-C*b-_*P)/x,S=(C*_+b*P)/x,M=(-C*b+_*P)/x,I=O-m,E=$-v,A=S-m,T=M-v;return I*I+E*E>A*A+T*T&&(O=S,$=M),{cx:O,cy:$,x01:-u,y01:-h,x11:O*(i/w-1),y11:$*(i/w-1)}}function Vo(){var e=PU,t=OU,n=Mt(0),r=null,i=SU,o=$U,s=EU,a=null,l=n4(c);function c(){var u,h,f=+e.apply(this,arguments),d=+t.apply(this,arguments),p=i.apply(this,arguments)-al,g=o.apply(this,arguments)-al,m=e4(g-p),v=g>p;if(a||(a=u=l()),d<f&&(h=d,d=f,f=h),!(d>rn))a.moveTo(0,0);else if(m>ll-rn)a.moveTo(d*Vr(p),d*kn(p)),a.arc(0,0,d,p,g,!v),f>rn&&(a.moveTo(f*Vr(g),f*kn(g)),a.arc(0,0,f,g,p,v));else{var b=p,_=g,x=p,w=g,C=m,P=m,O=s.apply(this,arguments)/2,$=O>rn&&(r?+r.apply(this,arguments):Ii(f*f+d*d)),S=af(e4(d-f)/2,+n.apply(this,arguments)),M=S,I=S,E,A;if($>rn){var T=t4($/f*kn(O)),N=t4($/d*kn(O));(C-=T*2)>rn?(T*=v?1:-1,x+=T,w-=T):(C=0,x=w=(p+g)/2),(P-=N*2)>rn?(N*=v?1:-1,b+=N,_-=N):(P=0,b=_=(p+g)/2)}var H=d*Vr(b),D=d*kn(b),B=f*Vr(w),F=f*kn(w);if(S>rn){var X=d*Vr(_),G=d*kn(_),L=f*Vr(x),R=f*kn(x),z;if(m<Wo)if(z=MU(H,D,L,R,X,G,B,F)){var q=H-z[0],j=D-z[1],V=X-z[0],U=G-z[1],K=1/kn(CU((q*V+j*U)/(Ii(q*q+j*j)*Ii(V*V+U*U)))/2),ne=Ii(z[0]*z[0]+z[1]*z[1]);M=af(S,(f-ne)/(K-1)),I=af(S,(d-ne)/(K+1))}else M=I=0}P>rn?I>rn?(E=cl(L,R,H,D,d,I,v),A=cl(X,G,B,F,d,I,v),a.moveTo(E.cx+E.x01,E.cy+E.y01),I<S?a.arc(E.cx,E.cy,I,Vt(E.y01,E.x01),Vt(A.y01,A.x01),!v):(a.arc(E.cx,E.cy,I,Vt(E.y01,E.x01),Vt(E.y11,E.x11),!v),a.arc(0,0,d,Vt(E.cy+E.y11,E.cx+E.x11),Vt(A.cy+A.y11,A.cx+A.x11),!v),a.arc(A.cx,A.cy,I,Vt(A.y11,A.x11),Vt(A.y01,A.x01),!v))):(a.moveTo(H,D),a.arc(0,0,d,b,_,!v)):a.moveTo(H,D),!(f>rn)||!(C>rn)?a.lineTo(B,F):M>rn?(E=cl(B,F,X,G,f,-M,v),A=cl(H,D,L,R,f,-M,v),a.lineTo(E.cx+E.x01,E.cy+E.y01),M<S?a.arc(E.cx,E.cy,M,Vt(E.y01,E.x01),Vt(A.y01,A.x01),!v):(a.arc(E.cx,E.cy,M,Vt(E.y01,E.x01),Vt(E.y11,E.x11),!v),a.arc(0,0,f,Vt(E.cy+E.y11,E.cx+E.x11),Vt(A.cy+A.y11,A.cx+A.x11),v),a.arc(A.cx,A.cy,M,Vt(A.y11,A.x11),Vt(A.y01,A.x01),!v))):a.arc(0,0,f,w,x,v)}if(a.closePath(),u)return a=null,u+""||null}return c.centroid=function(){var u=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,h=(+i.apply(this,arguments)+ +o.apply(this,arguments))/2-Wo/2;return[Vr(h)*u,kn(h)*u]},c.innerRadius=function(u){return arguments.length?(e=typeof u=="function"?u:Mt(+u),c):e},c.outerRadius=function(u){return arguments.length?(t=typeof u=="function"?u:Mt(+u),c):t},c.cornerRadius=function(u){return arguments.length?(n=typeof u=="function"?u:Mt(+u),c):n},c.padRadius=function(u){return arguments.length?(r=u==null?null:typeof u=="function"?u:Mt(+u),c):r},c.startAngle=function(u){return arguments.length?(i=typeof u=="function"?u:Mt(+u),c):i},c.endAngle=function(u){return arguments.length?(o=typeof u=="function"?u:Mt(+u),c):o},c.padAngle=function(u){return arguments.length?(s=typeof u=="function"?u:Mt(+u),c):s},c.context=function(u){return arguments.length?(a=u==null?null:u,c):a},c}function r4(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function i4(e){this._context=e}i4.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function o4(e){return new i4(e)}function IU(e){return e[0]}function AU(e){return e[1]}function TU(e,t){var n=Mt(!0),r=null,i=o4,o=null,s=n4(a);e=typeof e=="function"?e:e===void 0?IU:Mt(e),t=typeof t=="function"?t:t===void 0?AU:Mt(t);function a(l){var c,u=(l=r4(l)).length,h,f=!1,d;for(r==null&&(o=i(d=s())),c=0;c<=u;++c)!(c<u&&n(h=l[c],c,l))===f&&((f=!f)?o.lineStart():o.lineEnd()),f&&o.point(+e(h,c,l),+t(h,c,l));if(d)return o=null,d+""||null}return a.x=function(l){return arguments.length?(e=typeof l=="function"?l:Mt(+l),a):e},a.y=function(l){return arguments.length?(t=typeof l=="function"?l:Mt(+l),a):t},a.defined=function(l){return arguments.length?(n=typeof l=="function"?l:Mt(!!l),a):n},a.curve=function(l){return arguments.length?(i=l,r!=null&&(o=i(r)),a):i},a.context=function(l){return arguments.length?(l==null?r=o=null:o=i(r=l),a):r},a}function RU(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function kU(e){return e}function LU(){var e=kU,t=RU,n=null,r=Mt(0),i=Mt(ll),o=Mt(0);function s(a){var l,c=(a=r4(a)).length,u,h,f=0,d=new Array(c),p=new Array(c),g=+r.apply(this,arguments),m=Math.min(ll,Math.max(-ll,i.apply(this,arguments)-g)),v,b=Math.min(Math.abs(m)/c,o.apply(this,arguments)),_=b*(m<0?-1:1),x;for(l=0;l<c;++l)(x=p[d[l]=l]=+e(a[l],l,a))>0&&(f+=x);for(t!=null?d.sort(function(w,C){return t(p[w],p[C])}):n!=null&&d.sort(function(w,C){return n(a[w],a[C])}),l=0,h=f?(m-c*_)/f:0;l<c;++l,g=v)u=d[l],x=p[u],v=g+(x>0?x*h:0)+_,p[u]={data:a[u],index:l,value:x,startAngle:g,endAngle:v,padAngle:b};return p}return s.value=function(a){return arguments.length?(e=typeof a=="function"?a:Mt(+a),s):e},s.sortValues=function(a){return arguments.length?(t=a,n=null,s):t},s.sort=function(a){return arguments.length?(n=a,t=null,s):n},s.startAngle=function(a){return arguments.length?(r=typeof a=="function"?a:Mt(+a),s):r},s.endAngle=function(a){return arguments.length?(i=typeof a=="function"?a:Mt(+a),s):i},s.padAngle=function(a){return arguments.length?(o=typeof a=="function"?a:Mt(+a),s):o},s}function Go(e,t,n){this.k=e,this.x=t,this.y=n}Go.prototype={constructor:Go,scale:function(e){return e===1?this:new Go(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Go(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},Go.prototype;var NU=Object.defineProperty,zU=Object.defineProperties,DU=Object.getOwnPropertyDescriptors,s4=Object.getOwnPropertySymbols,qU=Object.prototype.hasOwnProperty,HU=Object.prototype.propertyIsEnumerable,a4=(e,t,n)=>t in e?NU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,jU=(e,t)=>{for(var n in t||(t={}))qU.call(t,n)&&a4(e,n,t[n]);if(s4)for(var n of s4(t))HU.call(t,n)&&a4(e,n,t[n]);return e},FU=(e,t)=>zU(e,DU(t));const l4=e=>{const[{datum:t,data:n,indexes:r,width:i=280,height:o=120,iconSize:s=32,gap:a=12,progressHeight:l=8,borderRadius:c=12,positionH:u="normal",themeColors:h,valueFormatter:f=T=>`${T}%`},d]=lt(e,["width","height","iconSize","gap","progressHeight","borderRadius"]),p=t.value,g=p!=null?p:0,m=Math.max(...n.items.map(T=>{var N;return(N=T.value)!=null?N:0}),100),v=i-2*a,_=Bo().domain([0,m]).range([0,v])(g),x=`${h.colorPrimary}-progress`,w=`${h.colorPrimaryBg}-progress-bg`,C=ae(y(Ve,{indexes:r})),P=a,O=u==="flipped"?i-a-s:a,$=P,S=u==="flipped"?a:s+2*a,M=i-s-3*a,I=$,E=o-a-l,A=p!==void 0;return k(Y,FU(jU({},d),{children:[k(Ke,{children:[k("linearGradient",{id:x,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[y("stop",{offset:"0%",stopColor:h.colorPrimary}),y("stop",{offset:"100%",stopColor:be.mix(h.colorPrimary,"#fff",20).toHexString()})]}),k("linearGradient",{id:w,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[y("stop",{offset:"0%",stopColor:h.colorPrimaryBg}),y("stop",{offset:"100%",stopColor:h.colorBg})]})]}),y(ke,{x:0,y:0,width:i,height:o,fill:h.colorBgElevated,stroke:h.colorPrimaryBg,strokeWidth:1,rx:c,ry:c,"data-element-type":"shape"}),y(Ft,{indexes:r,x:O,y:$,size:s,fill:h.colorPrimary}),y(Ve,{indexes:r,x:S,y:I,width:M,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",fontSize:16,fontWeight:"medium",fill:h.colorText,children:t.label}),A&&y(Mo,{indexes:r,x:S,y:I+C.height,width:M,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",lineHeight:1,fontSize:24,fontWeight:"bold",fill:h.colorPrimary,value:g,formatter:f}),y(ft,{indexes:r,x:S,y:I+C.height+(A?27:4),width:M,alignHorizontal:u==="flipped"?"right":"left",alignVertical:"top",fontSize:11,fill:h.colorTextSecondary,lineNumber:A?2:3,wordWrap:!0,children:t.desc}),y(ke,{x:a,y:E,width:v,height:l,fill:`url(#${w})`,rx:l/2,ry:l/2,"data-element-type":"shape"}),y(ke,{x:a,y:E,width:_,height:l,fill:`url(#${x})`,rx:l/2,ry:l/2,"data-element-type":"shape"})]}))};ct("progress-card",{component:l4,composites:["icon","label","value","desc"]});var BU=Object.defineProperty,WU=Object.defineProperties,VU=Object.getOwnPropertyDescriptors,c4=Object.getOwnPropertySymbols,GU=Object.prototype.hasOwnProperty,YU=Object.prototype.propertyIsEnumerable,u4=(e,t,n)=>t in e?BU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,XU=(e,t)=>{for(var n in t||(t={}))GU.call(t,n)&&u4(e,n,t[n]);if(c4)for(var n of c4(t))YU.call(t,n)&&u4(e,n,t[n]);return e},UU=(e,t)=>WU(e,VU(t));const h4=e=>{const[{datum:t,indexes:n,width:r=280,height:i=120,iconSize:o=30,circleRadius:s=80,positionH:a="normal",positionV:l="normal",themeColors:c},u]=lt(e,["width","height","iconSize","circleRadius"]),h=4*s/(3*Math.PI),f=2,d=4,p=28,g=20,m=g+20,v=g,b=8,_=35,x=40,w=30,C=String(n[0]+1).padStart(2,"0"),P=a==="flipped",O=l==="flipped",$=()=>P?{diagonalStartX:r-d,diagonalStartY:O?i-_:_,diagonalEndX:r-x,diagonalEndY:O?i-d:d,topLineStartX:r-x,topLineEndX:h,topLineY:O?i-d:d}:{diagonalStartX:d,diagonalStartY:O?i-_:_,diagonalEndX:x,diagonalEndY:O?i-d:d,topLineStartX:x,topLineEndX:r-h,topLineY:O?i-d:d},S=()=>{if(P){const H=s+10,D=r-H-x;return{valueX:r-w,contentX:H,contentWidth:D,circleX:0,circleY:O?0:i,iconX:h-o/2}}else return{valueX:0,contentX:x,contentWidth:r-x-s-10,circleX:r,circleY:O?0:i,iconX:r-h-o/2}},M=$(),I=S(),E=O?h-o/2:i-h-o/2,A=ae(y(Ve,{indexes:n,width:I.contentWidth,children:t.label})),T=v+A.height+b,N=()=>{const{circleX:H,circleY:D}=I;return P?O?`M ${H} ${D} L ${H} ${D+s} A ${s} ${s} 0 0 0 ${H+s} ${D} Z`:`M ${H} ${D} L ${H} ${D-s} A ${s} ${s} 0 0 1 ${H+s} ${D} Z`:O?`M ${H} ${D} L ${H} ${D+s} A ${s} ${s} 0 0 1 ${H-s} ${D} Z`:`M ${H} ${D} L ${H} ${D-s} A ${s} ${s} 0 0 0 ${H-s} ${D} Z`};return k(Y,UU(XU({},u),{width:r,height:i,children:[k(Pt,{children:[y(Ce,{d:`M ${M.diagonalStartX} ${M.diagonalStartY} L ${M.diagonalEndX} ${M.diagonalEndY}`,stroke:c.colorPrimary,strokeWidth:f,fill:"none"}),y(Ce,{d:`M ${M.topLineStartX} ${M.topLineY} L ${M.topLineEndX} ${M.topLineY}`,stroke:c.colorPrimary,strokeWidth:f,fill:"none"}),y(Ze,{x:M.diagonalStartX-d,y:M.diagonalStartY-d,width:d*2,height:d*2,fill:c.colorPrimary}),y(Ze,{x:M.topLineEndX-d,y:M.topLineY-d,width:d*2,height:d*2,fill:c.colorPrimary})]}),k(Y,{children:[y(Ne,{x:I.valueX,y:m,fontSize:p,fontWeight:"bold",fill:c.colorPrimary,children:C}),y(Ce,{d:N(),fill:c.colorPrimary,"data-element-type":"shape"}),t.icon&&y(Ft,{indexes:n,x:I.iconX,y:E,size:o,fill:c.colorWhite}),t.label&&y(Ve,{indexes:n,x:I.contentX,y:v,width:I.contentWidth,fontWeight:"bold",fill:c.colorText,alignHorizontal:P?"right":"left",children:t.label}),t.desc&&y(ft,{indexes:n,x:I.contentX,y:T,width:I.contentWidth,fill:c.colorTextSecondary,alignHorizontal:P?"right":"left",children:t.desc})]})]}))};ct("quarter-circular",{component:h4,composites:["icon","label","desc"]});var KU=Object.defineProperty,ZU=Object.defineProperties,QU=Object.getOwnPropertyDescriptors,f4=Object.getOwnPropertySymbols,JU=Object.prototype.hasOwnProperty,eK=Object.prototype.propertyIsEnumerable,d4=(e,t,n)=>t in e?KU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,tK=(e,t)=>{for(var n in t||(t={}))JU.call(t,n)&&d4(e,n,t[n]);if(f4)for(var n of f4(t))eK.call(t,n)&&d4(e,n,t[n]);return e},nK=(e,t)=>ZU(e,QU(t));const p4=e=>{const[{datum:t,indexes:n,width:r=150,height:i=150,iconSize:o=30,padding:s=20,borderRadius:a=16,positionH:l="center",positionV:c="middle",themeColors:u},h]=lt(e,["width","height","iconSize","padding","borderRadius"]),f=r-s*2,d=s,p=s,g=l==="flipped"?r-s-o:l==="center"?(r-o)/2:d,m=p,v=m+o+8,b=ae(y(Ve,{indexes:n,width:f,children:t.label})),_=l==="flipped"?r-s-f:l==="center"?s:d,x=v+b.height+4,w=_,C=a;let P="";return l==="center"&&c==="middle"?P=`
|
|
41
|
+
M ${C} 0
|
|
42
|
+
L ${r-C} 0
|
|
43
|
+
Q ${r} 0 ${r} ${C}
|
|
44
|
+
L ${r} ${i-C}
|
|
45
|
+
Q ${r} ${i} ${r-C} ${i}
|
|
46
|
+
L ${C} ${i}
|
|
47
|
+
Q 0 ${i} 0 ${i-C}
|
|
48
|
+
L 0 ${C}
|
|
49
|
+
Q 0 0 ${C} 0
|
|
50
50
|
Z
|
|
51
|
-
`:
|
|
52
|
-
M ${
|
|
53
|
-
L ${r-
|
|
54
|
-
Q ${r} 0 ${r} ${
|
|
55
|
-
L ${r} ${i-
|
|
56
|
-
Q ${r} ${i} ${r-
|
|
57
|
-
L ${
|
|
58
|
-
Q 0 ${i} 0 ${i-
|
|
51
|
+
`:l==="flipped"&&c==="flipped"?P=`
|
|
52
|
+
M ${C} 0
|
|
53
|
+
L ${r-C} 0
|
|
54
|
+
Q ${r} 0 ${r} ${C}
|
|
55
|
+
L ${r} ${i-C}
|
|
56
|
+
Q ${r} ${i} ${r-C} ${i}
|
|
57
|
+
L ${C} ${i}
|
|
58
|
+
Q 0 ${i} 0 ${i-C}
|
|
59
59
|
L 0 0
|
|
60
|
-
L ${
|
|
60
|
+
L ${C} 0
|
|
61
61
|
Z
|
|
62
|
-
`:
|
|
62
|
+
`:l==="normal"&&c==="flipped"?P=`
|
|
63
63
|
M 0 0
|
|
64
64
|
L ${r} 0
|
|
65
|
-
L ${r} ${i-
|
|
66
|
-
Q ${r} ${i} ${r-
|
|
67
|
-
L ${
|
|
68
|
-
Q 0 ${i} 0 ${i-
|
|
69
|
-
L 0 ${
|
|
70
|
-
Q 0 0 ${
|
|
65
|
+
L ${r} ${i-C}
|
|
66
|
+
Q ${r} ${i} ${r-C} ${i}
|
|
67
|
+
L ${C} ${i}
|
|
68
|
+
Q 0 ${i} 0 ${i-C}
|
|
69
|
+
L 0 ${C}
|
|
70
|
+
Q 0 0 ${C} 0
|
|
71
71
|
Z
|
|
72
|
-
`:
|
|
73
|
-
M ${
|
|
74
|
-
L ${r-
|
|
75
|
-
Q ${r} 0 ${r} ${
|
|
76
|
-
L ${r} ${i-
|
|
77
|
-
Q ${r} ${i} ${r-
|
|
72
|
+
`:l==="flipped"?P=`
|
|
73
|
+
M ${C} 0
|
|
74
|
+
L ${r-C} 0
|
|
75
|
+
Q ${r} 0 ${r} ${C}
|
|
76
|
+
L ${r} ${i-C}
|
|
77
|
+
Q ${r} ${i} ${r-C} ${i}
|
|
78
78
|
L 0 ${i}
|
|
79
|
-
L 0 ${
|
|
80
|
-
Q 0 0 ${
|
|
79
|
+
L 0 ${C}
|
|
80
|
+
Q 0 0 ${C} 0
|
|
81
81
|
Z
|
|
82
|
-
|
|
83
|
-
M ${
|
|
84
|
-
L ${r-
|
|
85
|
-
Q ${r} 0 ${r} ${
|
|
82
|
+
`:P=`
|
|
83
|
+
M ${C} 0
|
|
84
|
+
L ${r-C} 0
|
|
85
|
+
Q ${r} 0 ${r} ${C}
|
|
86
86
|
L ${r} ${i}
|
|
87
|
-
L ${
|
|
88
|
-
Q 0 ${i} 0 ${i-
|
|
89
|
-
L 0 ${
|
|
90
|
-
Q 0 0 ${
|
|
87
|
+
L ${C} ${i}
|
|
88
|
+
Q 0 ${i} 0 ${i-C}
|
|
89
|
+
L 0 ${C}
|
|
90
|
+
Q 0 0 ${C} 0
|
|
91
91
|
Z
|
|
92
|
-
`,L(Y,SX(OX({},h),{children:[p(Pe,{d:$,x:0,y:0,width:r,height:i,fill:u.colorPrimary,"data-element-type":"shape"}),p(Ht,{indexes:n,x:y,y:m,size:o,fill:u.colorBg}),p(Ge,{indexes:n,x:_,y:v,width:d,fontSize:14,fontWeight:"bold",fill:u.colorBg,alignHorizontal:c==="flipped"?"right":"left",children:t.label}),t.desc&&p(ut,{indexes:n,x:w,y:x,width:d,fontSize:11,wordWrap:!0,fill:u.colorBg,alignHorizontal:c==="flipped"?"right":"left",children:t.desc})]}))};ct("quarter-simple-card",{component:bw,composites:["icon","label","desc"]});var MX=Object.defineProperty,EX=Object.defineProperties,IX=Object.getOwnPropertyDescriptors,_w=Object.getOwnPropertySymbols,AX=Object.prototype.hasOwnProperty,TX=Object.prototype.propertyIsEnumerable,xw=(e,t,n)=>t in e?MX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kX=(e,t)=>{for(var n in t||(t={}))AX.call(t,n)&&xw(e,n,t[n]);if(_w)for(var n of _w(t))TX.call(t,n)&&xw(e,n,t[n]);return e},RX=(e,t)=>EX(e,IX(t));const ww=e=>{const[{datum:t,indexes:n,width:r=240,height:i=140,iconSize:o=28,gap:a=12,ribbonHeight:s=32,themeColors:c},l]=st(e,["width","height","iconSize","gap","ribbonHeight"]),u=`${c.colorPrimary}-ribbon`;return L(Y,RX(kX({},l),{children:[p(Ke,{children:L("linearGradient",{id:u,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p("stop",{offset:"0%",stopColor:c.colorPrimary}),p("stop",{offset:"100%",stopColor:be(c.colorPrimary).darken(15).toHexString()})]})}),L(xt,{children:[p(Re,{x:0,y:0,width:r,height:i,fill:c.colorBgElevated,stroke:c.colorPrimaryBg,strokeWidth:1,rx:8,ry:8}),p(Re,{x:0,y:0,width:r,height:s,fill:`url(#${u})`,rx:8,ry:8}),p(Re,{x:0,y:8,width:r,height:s-8,fill:`url(#${u})`}),p(Pe,{x:r-20,y:s,width:20,height:8,fill:be(c.colorPrimary).darken(25).toHexString(),d:"M0,0 L20,0 L15,8 L5,8 Z"})]}),p(Ht,{indexes:n,x:a,y:s+a,size:o,fill:c.colorPrimary}),p(Ge,{indexes:n,x:o+2*a,y:s+a,width:r-o-3*a,height:o,alignHorizontal:"left",alignVertical:"middle",lineHeight:1,fontWeight:"bold",fill:c.colorText,children:t.label}),p(ut,{indexes:n,x:a,y:s+o+a+5,width:r-2*a,alignHorizontal:"left",fill:c.colorTextSecondary,lineNumber:3,wordWrap:!0,children:t.desc}),p(Ht,{indexes:n,x:r-a-8,y:a/2,size:16,fill:c.colorWhite})]}))};ct("ribbon-card",{component:ww,composites:["icon","label","desc"]});var LX=Object.defineProperty,zX=Object.defineProperties,NX=Object.getOwnPropertyDescriptors,Pw=Object.getOwnPropertySymbols,DX=Object.prototype.hasOwnProperty,HX=Object.prototype.propertyIsEnumerable,$w=(e,t,n)=>t in e?LX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qX=(e,t)=>{for(var n in t||(t={}))DX.call(t,n)&&$w(e,n,t[n]);if(Pw)for(var n of Pw(t))HX.call(t,n)&&$w(e,n,t[n]);return e},jX=(e,t)=>zX(e,NX(t));const Cw=e=>{const[{indexes:t,datum:n,themeColors:r,width:i=300,height:o=40,padding:a=4,positionH:s="normal"},c]=st(e,["width","height","borderRadius","padding"]),l=o/2,u=l,h=a,d=i-l*2,f=o-a*2;return L(Y,jX(qX({},c),{children:[p(Re,{"data-element-type":"shape",width:i,height:o,rx:l,ry:l,fill:r.colorPrimaryBg,stroke:r.colorPrimary,strokeWidth:1,opacity:.8}),p(Ge,{indexes:t,x:u,y:h,width:d,height:f,alignHorizontal:s==="flipped"?"right":s==="center"?"center":"left",alignVertical:"middle",fontSize:14,fontWeight:"500",fill:r.colorText,children:n.label})]}))};ct("rounded-rect-node",{component:Cw,composites:["label"]});var FX=Object.defineProperty,BX=Object.defineProperties,WX=Object.getOwnPropertyDescriptors,Ow=Object.getOwnPropertySymbols,GX=Object.prototype.hasOwnProperty,VX=Object.prototype.propertyIsEnumerable,Sw=(e,t,n)=>t in e?FX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,YX=(e,t)=>{for(var n in t||(t={}))GX.call(t,n)&&Sw(e,n,t[n]);if(Ow)for(var n of Ow(t))VX.call(t,n)&&Sw(e,n,t[n]);return e},XX=(e,t)=>BX(e,WX(t));const Mw=e=>{const[{width:t=24,height:n=t,strokeWidth:r=2,themeColors:i,datum:o},a]=st(e,["width","height"]),s=Math.min(t,n)-r,c=r/2;return L(Y,XX(YX({},a),{width:t,height:n,children:[p(Re,{width:t,height:n,fill:"none",visibility:"hidden"}),p(Ze,{x:c,y:c,width:s,height:s,fill:i.colorPrimary,stroke:i.isDarkMode?"#FFF":"#000",strokeWidth:r,"data-element-type":"shape",children:p("title",{children:o.label||o.desc})})]}))};ct("simple-circle-node",{component:Mw,composites:[]});var UX=Object.defineProperty,KX=Object.defineProperties,ZX=Object.getOwnPropertyDescriptors,Ew=Object.getOwnPropertySymbols,QX=Object.prototype.hasOwnProperty,JX=Object.prototype.propertyIsEnumerable,Iw=(e,t,n)=>t in e?UX(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,eU=(e,t)=>{for(var n in t||(t={}))QX.call(t,n)&&Iw(e,n,t[n]);if(Ew)for(var n of Ew(t))JX.call(t,n)&&Iw(e,n,t[n]);return e},tU=(e,t)=>KX(e,ZX(t));const Aw=e=>{const[{indexes:t,datum:n,width:r=140,themeColors:i,positionV:o="normal"},a]=st(e,["width"]),s=o!=="flipped",c=s?"bottom":"top",l=p(Ge,{indexes:t,width:r,fill:i.colorText,alignHorizontal:"center",alignVertical:c,fontSize:14,children:n.label}),u=p(ut,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:"center",alignVertical:c,children:n.desc}),h=30,d=10,f=se(l),g=se(u),y=f.height+g.height,m=y+d+h+d+y;return p(Y,tU(eU({width:r,height:m},a),{children:L(ve,{flexDirection:"column",alignItems:"center",children:[s?L(tt,{children:[u,l,p(mt,{height:d})]}):p(tt,{children:p(mt,{height:y+d})}),L(vi,{horizontal:"center",vertical:"middle",children:[p(nU,{width:r,height:h,fill:i.colorPrimary}),p(ze,{width:r,height:h,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:n.time?n.time:String(t[0]+1).padStart(2,"0").slice(-2)})]}),s?p(tt,{children:p(mt,{height:y+d})}):L(tt,{children:[p(mt,{height:d}),l,u]})]})}))},nU=e=>{const{x:t=0,y:n=0,width:r=100,height:i=40,fill:o="#FF356A",size:a=10}=e;return p(Wt,{width:r,height:i,points:[{x:t,y:n},{x:t+r-a,y:n},{x:t+r,y:n+i/2},{x:t+r-a,y:n+i},{x:t,y:n+i},{x:t+a,y:n+i/2}],fill:o,"data-element-type":"shape"})};ct("simple-horizontal-arrow",{component:Aw,composites:["label","desc","time"]});var rU=Object.defineProperty,iU=Object.defineProperties,oU=Object.getOwnPropertyDescriptors,Tw=Object.getOwnPropertySymbols,aU=Object.prototype.hasOwnProperty,sU=Object.prototype.propertyIsEnumerable,kw=(e,t,n)=>t in e?rU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cU=(e,t)=>{for(var n in t||(t={}))aU.call(t,n)&&kw(e,n,t[n]);if(Tw)for(var n of Tw(t))sU.call(t,n)&&kw(e,n,t[n]);return e},lU=(e,t)=>iU(e,oU(t));const Rw=e=>{const[{indexes:t,datum:n,width:r=180,illusSize:i=r,gap:o=8,themeColors:a,usePaletteColor:s=!1},c]=st(e,["width","illusSize","gap","usePaletteColor"]),{label:l,desc:u}=n,h=s?a.colorPrimary:a.colorText,d=p(Ge,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"middle",fill:h,children:l}),f=se(d);return L(ve,lU(cU({},c),{width:r,height:i+o+f.height+o+48,flexDirection:"column",alignItems:"center",justifyContent:"center",gap:o,children:[p(y_,{indexes:t,width:i,height:i}),d,p(ut,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"top",fill:a.colorTextSecondary,lineNumber:3,children:u})]}))};ct("simple-illus",{component:Rw,composites:["illus","label","desc"]});var uU=Object.defineProperty,hU=Object.defineProperties,dU=Object.getOwnPropertyDescriptors,Lw=Object.getOwnPropertySymbols,fU=Object.prototype.hasOwnProperty,pU=Object.prototype.propertyIsEnumerable,zw=(e,t,n)=>t in e?uU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Bh=(e,t)=>{for(var n in t||(t={}))fU.call(t,n)&&zw(e,n,t[n]);if(Lw)for(var n of Lw(t))pU.call(t,n)&&zw(e,n,t[n]);return e},Wh=(e,t)=>hU(e,dU(t));const Nw=e=>{const[{indexes:t,datum:n,width:r=200,height:i,gap:o=4,showIcon:a=!0,iconSize:s=30,iconType:c="default",positionH:l="normal",positionV:u="normal",usePaletteColor:h=!1,themeColors:d},f]=st(e,["width","height","gap","showIcon","iconSize","iconType","usePaletteColor"]),{label:g,desc:y,icon:m}=n,b=(z=>z==="normal"?"left":z==="flipped"?"right":"center")(l),_=h?d.colorPrimary:d.colorText,x=14,w=1.4,$=se(p(Ge,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"middle",fill:_,children:g})),C=a?c==="circle"?p(kr,{indexes:t,size:s,fill:d.colorPrimary,colorBg:d.colorBg}):p(Ht,{indexes:t,size:s,fill:d.colorTextSecondary}):null;if(!a||!m){const z=i?Math.max(0,i-$.height-o):void 0,j=z?z<=60?1:Math.floor(z/(w*x)):2,D=i?u==="middle"?(i-$.height-(z||0)-o)/2:u==="flipped"?i-$.height-(z||0)-o:0:0;return L(Y,Wh(Bh({},f),{children:[p(Ge,{indexes:t,width:r,y:D,alignHorizontal:b,alignVertical:"middle",fill:_,children:g}),p(ut,{indexes:t,width:r,height:z,y:D+$.height+o,alignHorizontal:b,alignVertical:T(),lineNumber:j,fill:d.colorTextSecondary,children:y})]}))}if(l==="center"){const z=a&&m?s:0,j=i?Math.max(0,i-$.height-z-o*2):void 0,D=j?j<=60?1:Math.floor(j/(w*x)):2,W=$.height+(j||0)+o,B=i?u==="middle"?(i-W-z-o)/2:u==="flipped"?i-W-z-o:0:0;return p(ve,Wh(Bh({},f),{flexDirection:"column",gap:o,alignItems:"center",children:u==="flipped"?L(tt,{children:[L(Y,{children:[p(Ge,{indexes:t,width:r,y:B,alignHorizontal:"center",alignVertical:"middle",fill:_,children:g}),p(ut,{indexes:t,width:r,height:j,y:B+$.height+o,alignHorizontal:"center",alignVertical:"bottom",lineNumber:D,fill:d.colorTextSecondary,children:y})]}),C]}):L(tt,{children:[C,L(Y,{children:[p(Ge,{indexes:t,width:r,y:B,alignHorizontal:"center",alignVertical:"middle",fill:_,children:g}),p(ut,{indexes:t,width:r,height:j,y:B+$.height+o,alignHorizontal:"center",alignVertical:"top",lineNumber:D,fill:d.colorTextSecondary,children:y})]})]})}))}const M=se(C),S=Math.max(r-M.width-o,0),E=i?Math.max(0,i-$.height-o):void 0,A=E?E<=60?1:Math.floor(E/(w*x)):2,O=i?u==="middle"?(i-$.height-(E||0)-o)/2:u==="flipped"?i-$.height-(E||0)-o:0:0;return p(ve,Wh(Bh({},f),{flexDirection:"row",gap:o,alignItems:F(u),children:l==="flipped"?L(tt,{children:[L(Y,{children:[p(Ge,{indexes:t,width:S,y:O,alignHorizontal:"right",alignVertical:"middle",fill:_,children:g}),p(ut,{indexes:t,width:S,height:E,y:O+$.height+o,alignHorizontal:"right",alignVertical:T(),lineNumber:A,fill:d.colorTextSecondary,children:y})]}),C]}):L(tt,{children:[C,L(Y,{children:[p(Ge,{indexes:t,width:S,y:O,alignHorizontal:"left",alignVertical:"middle",fill:_,children:g}),p(ut,{indexes:t,width:S,height:E,y:O+$.height+o,alignHorizontal:"left",alignVertical:T(),lineNumber:A,fill:d.colorTextSecondary,children:y})]})]})}));function T(z,j){return"top"}function F(z){return z==="normal"?"flex-start":z==="flipped"?"flex-end":"center"}};ct("simple",{component:Nw,composites:["icon","label","desc"]});var gU=Object.defineProperty,mU=Object.defineProperties,yU=Object.getOwnPropertyDescriptors,Dw=Object.getOwnPropertySymbols,vU=Object.prototype.hasOwnProperty,bU=Object.prototype.propertyIsEnumerable,Hw=(e,t,n)=>t in e?gU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,_U=(e,t)=>{for(var n in t||(t={}))vU.call(t,n)&&Hw(e,n,t[n]);if(Dw)for(var n of Dw(t))bU.call(t,n)&&Hw(e,n,t[n]);return e},xU=(e,t)=>mU(e,yU(t));const qw=e=>{const[{indexes:t,datum:n,height:r=140,themeColors:i,positionH:o="normal"},a]=st(e,["height"]),s=o==="normal"?"right":"left",c=p(Ge,{indexes:t,width:120,fill:i.colorText,alignHorizontal:s,alignVertical:"middle",fontSize:14,children:n.label}),l=p(ut,{indexes:t,width:120,fill:i.colorTextSecondary,alignHorizontal:s,alignVertical:"top",children:n.desc}),u=o!=="flipped",h=15,d=30,f=120,g=f+h+d+h+f;return p(Y,xU(_U({width:g,height:r},a),{children:L(ve,{flexDirection:"row",alignItems:"center",children:[u?L(tt,{children:[L(ve,{flexDirection:"column",alignItems:"flex-end",children:[c,l]}),p(mt,{width:h})]}):p(tt,{children:p(mt,{width:f+h})}),L(vi,{horizontal:"center",vertical:"middle",children:[p(wU,{width:d,height:r,fill:i.colorPrimary}),p(ze,{width:d,height:r,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:String(t[0]+1).padStart(2,"0").slice(-2)})]}),u?p(tt,{children:p(mt,{width:f+h})}):L(tt,{children:[p(mt,{width:h}),L(ve,{flexDirection:"column",alignItems:"flex-start",children:[c,l]})]})]})}))},wU=e=>{const{x:t=0,y:n=0,width:r=30,height:i=100,fill:o="#FF356A",size:a=10}=e;return p(Wt,{width:r,height:i,points:[{x:t,y:n},{x:t+r/2,y:n+a},{x:t+r,y:n},{x:t+r,y:n+i-a},{x:t+r/2,y:n+i},{x:t,y:n+i-a}],fill:o,"data-element-type":"shape"})};ct("simple-vertical-arrow",{component:qw,composites:["label","desc"]});var PU=Object.defineProperty,$U=Object.defineProperties,CU=Object.getOwnPropertyDescriptors,jw=Object.getOwnPropertySymbols,OU=Object.prototype.hasOwnProperty,SU=Object.prototype.propertyIsEnumerable,Fw=(e,t,n)=>t in e?PU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MU=(e,t)=>{for(var n in t||(t={}))OU.call(t,n)&&Fw(e,n,t[n]);if(jw)for(var n of jw(t))SU.call(t,n)&&Fw(e,n,t[n]);return e},EU=(e,t)=>$U(e,CU(t));const Gh=80,Vh=3,Bw=e=>{const[{datum:t,indexes:n,width:r=200,gap:i=4,positionH:o="center",themeColors:a},s]=st(e,["width","height","gap"]),c=se(p(Ge,{indexes:n,fontSize:18,fontWeight:"bold",width:r,children:t.label})),l=t.desc?se(p(ut,{indexes:n,width:r,wordWrap:!0,children:t.desc})):{height:0},u=c.height+i+Vh+(t.desc?i*2+l.height:0),h=0,d=0,f=o==="center"?"center":o==="flipped"?"right":"left",g=o==="center"?(r-Gh)/2:o==="flipped"?r-Gh:0,y=d+c.height+i,m=0,v=y+Vh+i*2;return L(Y,EU(MU({width:r,height:u},s),{children:[t.label&&p(Ge,{indexes:n,x:h,y:d,width:r,alignHorizontal:f,fill:a.colorPrimary,fontSize:18,fontWeight:"bold",children:t.label}),t.label&&p(Re,{x:g,y,width:Gh,height:Vh,fill:a.colorPrimary,"data-element-type":"shape"}),t.desc&&p(ut,{indexes:n,width:r,x:m,y:v,alignHorizontal:f,wordWrap:!0,fill:a.colorText,children:t.desc})]}))};ct("underline-text",{component:Bw,composites:["label","desc"]});var IU=Object.defineProperty,AU=Object.defineProperties,TU=Object.getOwnPropertyDescriptors,Ww=Object.getOwnPropertySymbols,kU=Object.prototype.hasOwnProperty,RU=Object.prototype.propertyIsEnumerable,Gw=(e,t,n)=>t in e?IU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,LU=(e,t)=>{for(var n in t||(t={}))kU.call(t,n)&&Gw(e,n,t[n]);if(Ww)for(var n of Ww(t))RU.call(t,n)&&Gw(e,n,t[n]);return e},zU=(e,t)=>AU(e,TU(t));const Vw=e=>{const[{indexes:t,datum:n,height:r=140,themeColors:i,positionH:o="normal"},a]=st(e,["height"]),c=o!=="flipped"?"right":"left",l=p(Ge,{indexes:t,width:120,fill:i.colorText,alignHorizontal:c,alignVertical:"middle",fontSize:14,children:n.label}),u=p(ut,{indexes:t,width:120,fill:i.colorTextSecondary,alignHorizontal:c,alignVertical:"top",children:n.desc}),h=p(kr,{indexes:t,fill:i.colorPrimary,colorBg:i.colorWhite}),d=p(DU,{width:30,height:8,fill:i.colorPrimary,positionH:o}),f=o!=="flipped",g=5,y=25,m=30,v=se(l),b=se(h),_=se(d),x=v.width+g+_.width-b.width-y,w=Math.max(v.width+g+_.width,y+b.width)*2+m;return p(Y,zU(LU({width:w,height:r},a),{children:L(ve,{flexDirection:"row",alignItems:"center",children:[f?L(tt,{children:[L(ve,{flexDirection:"column",alignItems:"flex-end",children:[l,u]}),p(mt,{width:g}),d]}):L(tt,{children:[p(mt,{width:x}),h,p(mt,{width:y})]}),L(vi,{horizontal:"center",vertical:"middle",children:[p(NU,{width:m,height:r,fill:i.colorPrimary}),p(ze,{width:m,height:r,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:String(t[0]+1).padStart(2,"0").slice(-2)})]}),f?L(tt,{children:[p(mt,{width:y}),h]}):L(tt,{children:[d,p(mt,{width:g}),L(ve,{flexDirection:"column",alignItems:"flex-start",children:[l,u]})]})]})}))},NU=e=>{const{x:t=0,y:n=0,width:r=30,height:i=100,fill:o="#FF356A",size:a=10}=e;return p(Wt,{width:r,height:i,points:[{x:t,y:n},{x:t+r/2,y:n+a},{x:t+r,y:n},{x:t+r,y:n+i-a},{x:t+r/2,y:n+i},{x:t,y:n+i-a}],fill:o,"data-element-type":"shape"})},DU=e=>{const{x:t=0,y:n=0,width:r=50,height:i=10,fill:o,positionH:a="normal"}=e,s=i/2,c=r-s,l=2,u=s;return L(Y,{x:t,y:n,width:r,height:i,children:[p(Ze,{width:i,height:i,fill:o,x:a==="normal"?0:c-s,"data-element-type":"shape"}),p(Pe,{d:a==="normal"?`M${s},${u} L${s+c},${u}`:`M0,${u} L${c-s},${u}`,strokeWidth:l,stroke:o,"data-element-type":"shape"})]})};ct("vertical-icon-arrow",{component:Vw,composites:["icon","label","desc"]});const Yh=new Map;function We(e,t){Yh.set(e,t)}function Yw(e){return Yh.get(e)}function HU(){return Array.from(Yh.keys())}const Xw=e=>{var t,n,r;const{Title:i,Item:o,data:a,width:s,gap:c,barGap:l,barHeight:u=28,barAreaWidth:h,labelGap:d=16,padding:f=24,showValue:g=!0,options:y,valueFormatter:m=je=>je.toString()}=e,v=(t=h!=null?h:s)!=null?t:480,{title:b,desc:_,items:x=[],xTitle:w,yTitle:P}=a,$=i?p(i,{title:b,desc:_}):null;if(x.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:$});const[C,M,S,E]=Ar(f),A=(n=x[0])!=null?n:{label:"",value:0},O=se(p(o,{indexes:[0],datum:A,data:a})),T=O.width||140,F=O.height||u,z=Math.max(u,F),j=Math.max(12,z*.35),D=(r=l!=null?l:c)!=null?r:j,W=x.map(je=>{var Fe;return(Fe=je.value)!=null?Fe:0}),B=Math.max(...W,0),X=Math.min(...W,0),H=X<0?X*1.1:0;let k=B>0?B*1.1:0;k===H&&(k=H+1);const I=Lo().domain([H,k]).range([0,v]),R=Math.min(Math.max(I(0),0),v),N=Math.max(2,v*.02),q=x.length*(z+D)-D,G=P?24:0,U=20,K=w?24:0,oe=C+G,te=E+T+d,ae=g?80:0,Z=Math.max(8,z*.2),ee=te+v+ae+M,ue=oe+q+Z+U+K+S,ne=Ct(y.themeConfig),J=ne.colorText||"#666",ie=wt(y),re=[],ce=[],pe=[],he=[],ge=[],de=[],we=[],Se=oe+q+Z,Ie=je=>Number.isInteger(je)?je.toString():je.toFixed(1);x.forEach((je,Fe)=>{var ye;const xe=[Fe],Ae=(ye=je.value)!=null?ye:0,Me=oe+Fe*(z+D),le=Me+(z-u)/2,me=Ae>=0?te+R:te+I(Ae),Ce=Ae>=0?I(Ae)-R:R-I(Ae),Ye=Ce===0?N:Ce,rt=qe(y,[Fe])||ne.colorPrimary;if(re.push(p(Re,{x:me,y:le,width:Ye,height:u,fill:rt,rx:6,ry:6,"data-element-type":"shape"})),g){const Oe=Ae>=0?me+Ye+8:me-8;ce.push(p(ze,{x:Oe,y:le+u/2,alignHorizontal:Ae>=0?"left":"right",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:rt,children:m(Ae,je)}))}pe.push(p(o,{indexes:xe,datum:je,data:a,x:E,y:Me+(z-F)/2,width:T,height:F,positionV:"middle"}))});const $e=Math.max(3,Math.min(7,Math.floor(v/80)));return I.ticks($e).forEach(je=>{const Fe=te+I(je);de.push(p(Pe,{d:`M${Fe} ${oe} L${Fe} ${oe+q}`,stroke:J,strokeOpacity:.08,"data-element-type":"shape"})),ge.push(p(Pe,{d:`M${Fe-.5} ${Se} L${Fe-.5} ${Se+6}`,stroke:J,"data-element-type":"shape"})),ge.push(p(ze,{x:Fe,y:Se+14,alignHorizontal:"center",alignVertical:"middle",fontSize:12,fill:J,children:Ie(je)}))}),he.push(p(Pe,{d:`M${te} ${Se} L${te+v} ${Se}`,stroke:J,"data-element-type":"shape"})),H<0&&he.push(p(Re,{x:te+R-.5,y:oe,width:1,height:q,fill:ie,"data-element-type":"shape"})),P&&we.push(p(ze,{x:E+T/2,y:C+G/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:J,children:P})),w&&we.push(p(ze,{x:te+v/2,y:Se+U+K/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:J,children:w})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[$,L(Y,{width:ee,height:ue,children:[p(Y,{children:de}),p(Y,{children:re}),p(Y,{children:ce}),p(Y,{children:we}),p(Y,{children:[...he,...ge]}),p(Ne,{children:pe})]})]})};We("chart-bar",{component:Xw,composites:["title","item","xTitle","yTitle"]});const Uw=e=>{const{Title:t,Item:n,data:r,columnGap:i=60,columnWidth:o=50,padding:a=20,showValue:s=!0,options:c,valueFormatter:l=W=>W.toString()}=e,{title:u,desc:h,items:d=[]}=r,f=t?p(t,{title:u,desc:h}):null;if(d.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:f});const g=Ct(c.themeConfig),m=[...d.map(W=>{var B;return(B=W.value)!=null?B:0}),0].sort((W,B)=>W-B),v=m[0]<0,b=d.length*o+(d.length-1)*i,_=300,[x,w,P,$]=Ar(a),C=s?24:0,M=10,S=v&&s?C+M:M,E=b+$+w,A=_+x+P+S,O=Lo().domain([m[0],m[m.length-1]]).range([_,0]),T=O(0),F=[],z=[],j=[],D=[];return d.forEach((W,B)=>{var X;const H=[B],k=(X=W.value)!=null?X:0,I=$+B*(o+i),R=k>=0?O(k):T,N=Math.abs(O(k)-T),q=qe(c,[B])||g.colorPrimary,G=`${q}-column-positive-${B}`,U=`${q}-column-negative-${B}`;D.push(L("linearGradient",{id:k>=0?G:U,x1:"0%",y1:k>=0?"0%":"100%",x2:"0%",y2:k>=0?"100%":"0%",children:[p("stop",{offset:"0%",stopColor:q}),p("stop",{offset:"100%",stopColor:be.mix(q,"#fff",40).toHexString()})]})),F.push(p(Re,{x:I,y:x+R,width:o,height:N,fill:`url(#${k>=0?G:U})`,rx:8,ry:8,"data-element-type":"shape"})),s&&z.push(p(ze,{x:I+o/2,y:k>=0?x+R-10:x+R+N+20,fontSize:16,fontWeight:"bold",alignHorizontal:"center",alignVertical:k>=0?"bottom":"top",fill:q,children:l(k,W)}));const K=o+i,oe=x+_+S;j.push(p(n,{indexes:H,datum:W,data:r,x:I+o/2-K/2,y:oe,width:K,positionH:"center"}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,L(Y,{width:E,height:A,children:[p(Ke,{children:D}),p(Y,{children:F}),p(Y,{children:z}),p(Ne,{children:j})]})]})};We("chart-column",{component:Uw,composites:["title","item"]});var qU=Object.defineProperty,jU=Object.defineProperties,FU=Object.getOwnPropertyDescriptors,Kw=Object.getOwnPropertySymbols,BU=Object.prototype.hasOwnProperty,WU=Object.prototype.propertyIsEnumerable,Zw=(e,t,n)=>t in e?qU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Qw=(e,t)=>{for(var n in t||(t={}))BU.call(t,n)&&Zw(e,n,t[n]);if(Kw)for(var n of Kw(t))WU.call(t,n)&&Zw(e,n,t[n]);return e},GU=(e,t)=>jU(e,FU(t));const Jw=e=>{const{Title:t,Item:n,data:r,width:i,height:o=260,gap:a=10,padding:s=24,showValue:c=!0,options:l,valueFormatter:u=le=>le.toString()}=e,{title:h,desc:d,items:f=[],xTitle:g,yTitle:y}=r,m=t?p(t,{title:h,desc:d}):null;if(f.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:m});const[v,b,_,x]=Ar(s),w={indexes:[0],datum:f[0],data:r,positionH:"center",positionV:"normal"},P=se(p(n,Qw({},w))),$=P.width,C=P.height,M=Math.max(28,C+14),S=44,E=y?26:0,A=g?22:0,O=$+a,T=f.length>0?(f.length-1)*O+$:0,F=i!==void 0?i:Math.max(200,T||320),z=f.length>1?Math.max(O,(F-$)/(f.length-1)):0,j=f.length>0?Math.max($,(f.length-1)*z+$):0,D=x+S+E,W=v+E,B=D+j+b,X=W+o+M+A+_,H=f.map(le=>{var me;return(me=le.value)!=null?me:0}),k=Math.max(...H,0),I=Math.min(...H,0),R=Math.max(Math.abs(k),Math.abs(I))*.1,N=I<0?I-R:0;let q=k>0?k+R:1;q===N&&(q=N+1);const G=Lo().domain([N,q]).nice().range([o,0]),U=Math.max(0,Math.min(o,G(0))),K=q<=0?0:N>=0?o:U,oe=wt(l),te=Ct(l.themeConfig),ae=te.colorText||"#666",Z=[],ee=[],ue=[],ne=[],J=[],ie=[],re=[];G.ticks(6).forEach(le=>{const me=W+G(le);Z.push(p(Pe,{d:`M ${D} ${me} L ${D+j} ${me}`,width:j,height:1,stroke:ae,strokeWidth:1,"data-element-type":"shape",opacity:.08})),re.push(p(ze,{x:D-8,y:me,alignHorizontal:"right",alignVertical:"middle",fontSize:12,fill:ae,children:Number.isInteger(le)?le.toString():le.toFixed(1)}))});const pe=[],he=[],ge=[],de=le=>{if(le.length===0)return"";if(le.length===1){const Ce=le[0];return`M ${Ce.x} ${Ce.y}`}const me=[];me.push(`M ${le[0].x} ${le[0].y}`);for(let Ce=0;Ce<le.length-1;Ce++){const Ye=le[Ce-1]||le[Ce],rt=le[Ce],Oe=le[Ce+1],Be=le[Ce+2]||Oe,Qe=rt.x+(Oe.x-Ye.x)/6,Je=rt.y+(Oe.y-Ye.y)/6,Xe=Oe.x-(Be.x-rt.x)/6,ft=Oe.y-(Be.y-rt.y)/6;me.push(`C ${Qe} ${Je} ${Xe} ${ft} ${Oe.x} ${Oe.y}`)}return me.join(" ")};f.forEach((le,me)=>{var Ce;const Ye=D+me*z+$/2,rt=W+G((Ce=le.value)!=null?Ce:0);he.push({x:Ye,y:rt,datum:le}),pe.push(p(n,GU(Qw({},w),{indexes:[me],datum:le,x:Ye-$/2,y:W+o+4})));const Oe=qe(l,[me])||te.colorPrimary;ge.push({x:Ye,color:Oe})});const we=ge.length>0?Math.min(...ge.map(le=>le.x)):D,Se=ge.length>0?Math.max(...ge.map(le=>le.x)):D+j,Ie=Math.max(1,Se-we),$e=ge.map(le=>p("stop",{offset:`${(le.x-we)/Ie*100}%`,stopColor:le.color})),Le=ge.map(le=>p("stop",{offset:`${(le.x-we)/Ie*100}%`,stopColor:le.color,stopOpacity:"0.18"}));if(ge.length>0){const le=ge[ge.length-1].color;$e.push(p("stop",{offset:"100%",stopColor:le})),Le.push(p("stop",{offset:"100%",stopColor:le,stopOpacity:"0.04"}))}const je=`chart-line-${Nb([j,o,ae,oe,ge.map(le=>`${le.x.toFixed(2)}-${le.color}`).join()].join(":"))}`,Fe=`${je}-stroke`,ye=`${je}-area`,xe=de(he);ue.push(p(Pe,{d:xe,width:j,height:o,stroke:`url(#${Fe})`,strokeWidth:3,fill:"none","data-element-type":"shape"}));const Ae=xe.includes("C")?xe.slice(xe.indexOf("C")):"",Me=[`M ${he[0].x} ${W+K}`,`L ${he[0].x} ${he[0].y}`,Ae,`L ${he[he.length-1].x} ${W+K}`,"Z"].join(" ");return ue.push(p(Pe,{d:Me,width:j,height:o,fill:`url(#${ye})`,stroke:"none","data-element-type":"shape"})),he.forEach((le,me)=>{var Ce;const Ye=qe(l,[me])||te.colorPrimary;ne.push(p(Ze,{x:le.x-6,y:le.y-6,width:12,height:12,fill:Ye,"data-element-type":"shape"})),c&&J.push(p(ze,{x:le.x,y:le.y-12,alignHorizontal:"center",alignVertical:"bottom",fontSize:12,fontWeight:"bold",fill:Ye,children:u((Ce=le.datum.value)!=null?Ce:0,le.datum)}))}),ee.push(p(Pe,{d:`M ${D} ${W+K} L ${D+j} ${W+K}`,width:j,height:1,stroke:ae,strokeWidth:1,"data-element-type":"shape"})),ee.push(p(Pe,{d:`M ${D} ${W} L ${D} ${W+o}`,width:1,height:o,stroke:ae,strokeWidth:1,"data-element-type":"shape"})),g&&ie.push(p(ze,{x:D+j/2,y:W+o+M+A/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:ae,children:g})),y&&ie.push(p(ze,{x:x+E/2,y:W+o/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:ae,children:y})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[m,L(Y,{width:B,height:X,children:[L(Ke,{children:[p("linearGradient",{id:Fe,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:$e}),L("linearGradient",{id:ye,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[Le,p("stop",{offset:"100%",stopColor:oe,stopOpacity:"0.04"})]})]}),p(Y,{children:Z}),p(Y,{children:[...ee,...re]}),p(Y,{children:ue}),p(Y,{children:ne}),p(Y,{children:J}),p(Y,{children:ie}),p(Ne,{children:pe})]})]})};We("chart-line",{component:Jw,composites:["title","item","xTitle","yTitle"]});const e4=e=>{var t;const{Title:n,Item:r,data:i,radius:o=140,innerRadius:a=0,padding:s=30,showPercentage:c=!0,options:l}=e,{title:u,desc:h,items:d=[]}=i,f=n?p(n,{title:u,desc:h}):null,g=se(p(Q,{indexes:[0]})),y=(t=d[0])!=null?t:{label:"",value:0},m=se(p(r,{indexes:[0],datum:y,data:i,positionH:"center",positionV:"middle"})),v=m.width||140,b=m.height||32,_=Math.max(o,60),x=1.35,w=8,P=_*x+w+v,$=_,C=s+P,M=s+$,S=C*2,E=M*2;if(d.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,p(Y,{width:S,height:E,children:p(He,{children:p(Q,{indexes:[0],x:C-g.width/2,y:M-g.height/2})})})]});const A=d.reduce((G,U)=>{var K;return G+Math.max((K=U.value)!=null?K:0,0)},0),O=wt(l),T=Ct(l.themeConfig),z=aX().value(G=>{var U;return Math.max((U=G.value)!=null?U:0,0)}).sort(null).startAngle(0).endAngle(Math.PI*2)(d),j=No().innerRadius(a).outerRadius(_).cornerRadius(2),D=No().innerRadius(_).outerRadius(_),W=No().innerRadius(_*1.15).outerRadius(_*1.15),B=a+(_-a)*.5,X=No().innerRadius(B).outerRadius(B),H=No().innerRadius(_*.85).outerRadius(_*.85),k=[],I=[],R=[],N=[],q=[];return z.forEach(G=>{const U=G.data,K=G.index,oe=qe(l,[K])||T.colorPrimary||O,te=j(G)||"";k.push(p(Pe,{d:te,fill:oe,stroke:T.colorBg,strokeWidth:1,"data-element-type":"shape",width:_*2,height:_*2}));const Z=G.startAngle+(G.endAngle-G.startAngle)/2<Math.PI,ee=D.centroid(G),ue=W.centroid(G),J=[_*x*(Z?1:-1),ue[1]];R.push(p(Pe,{d:`M${C+ee[0]} ${M+ee[1]} L${C+ue[0]} ${M+ue[1]} L${C+J[0]} ${M+J[1]}`,stroke:O,strokeOpacity:.45,strokeWidth:2,fill:"none","data-element-type":"shape"}));const ie=C+J[0]+(Z?w:-w-v),re=M+J[1]-b/2;if(N.push(p(r,{indexes:[K],datum:U,data:i,x:ie,y:re,width:v,height:b,positionH:Z?"normal":"flipped",positionV:"middle",themeColors:Ct({colorPrimary:oe},l)})),c&&A>0){const pe=X.centroid(G),he=Math.max(G.value,0),ge=(he*100/A).toFixed(1),de=50,we=20;I.push(p(ze,{x:C+pe[0]-de/2,y:M+pe[1]-we/2,width:de,height:we,alignHorizontal:"center",alignVertical:"middle",fontSize:12,fontWeight:"bold",fill:"#ffffff","data-value":he,"data-indexes":[K],"data-element-type":Ve.ItemValue,children:`${ge}%`}))}const ce=H.centroid(G);q.push(p(nt,{indexes:[K],x:C+ce[0]-g.width/2,y:M+ce[1]-g.height/2}))}),z.forEach((G,U)=>{const K=(U+1)%z.length,oe=G.endAngle,te=z[K].startAngle+(K===0?Math.PI*2:0),ae=(oe+te)/2,Z=_*1,ee=Math.sin(ae)*Z,ue=-Math.cos(ae)*Z;q.push(p(Q,{indexes:[U+1],x:C+ee-g.width/2,y:M+ue-g.height/2}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[f,L(Y,{width:S,height:E,children:[p(Y,{x:C,y:M,children:k}),p(Y,{children:R}),p(Y,{children:I}),p(Ne,{children:N}),p(He,{children:q})]})]})};We("chart-pie",{component:e4,composites:["title","item"]});var VU=Object.defineProperty,YU=Object.defineProperties,XU=Object.getOwnPropertyDescriptors,t4=Object.getOwnPropertySymbols,UU=Object.prototype.hasOwnProperty,KU=Object.prototype.propertyIsEnumerable,n4=(e,t,n)=>t in e?VU(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,r4=(e,t)=>{for(var n in t||(t={}))UU.call(t,n)&&n4(e,n,t[n]);if(t4)for(var n of t4(t))KU.call(t,n)&&n4(e,n,t[n]);return e},i4=(e,t)=>YU(e,XU(t));const ZU=[0,30,-30,60,-60],QU=Math.PI*(3-Math.sqrt(5));function o4(e,t,n){const r=Math.PI/180*n,i=Math.cos(r),o=Math.sin(r);return{width:Math.abs(e*i)+Math.abs(t*o),height:Math.abs(e*o)+Math.abs(t*i)}}function JU(e,t,n,r,i,o){const a=e-o,s=e+n+o,c=t-o,l=t+r+o;return i.some(u=>{const h=u.box.x-o,d=u.box.x+u.box.width+o,f=u.box.y-o,g=u.box.y+u.box.height+o;return!(s<=h||a>=d||l<=f||c>=g)})}function eK(e,t,n,r,i){const o=[],a=t?ZU:[0],s=Math.max(1600,e.length*28);return e.forEach((c,l)=>{const u=Math.max(c.width,c.height),h=l*QU;let d=0,f=null;for(let g=0;g<s&&!f;g++){g===Math.floor(s*.6)&&(d=u);const y=h+g*r,m=i*Math.sqrt(g+1)+d+u*.25,v=m*Math.cos(y),b=m*Math.sin(y);for(const _ of a){const x=o4(c.width,c.height,_),w=v-x.width/2,P=b-x.height/2;if(!JU(w,P,x.width,x.height,o,n)){f=i4(r4({},c),{angle:_,centerX:v,centerY:b,box:{x:w,y:P,width:x.width,height:x.height}});break}}}if(!f){const g=a[l%a.length],y=i*Math.sqrt(s+1)+u,m=h,v=y*Math.cos(m),b=y*Math.sin(m),_=o4(c.width,c.height,g);f=i4(r4({},c),{angle:g,centerX:v,centerY:b,box:{x:v-_.width/2,y:b-_.height/2,width:_.width,height:_.height}})}o.push(f)}),o}const a4=e=>{const{data:t,options:n,minFontSize:r=16,maxFontSize:i=48,enableRotate:o=!0,padding:a=6,spiralStep:s=.45,radiusStep:c=10}=e,{items:l=[]}=t,u=l.map((O,T)=>({datum:O,index:T})).filter(({datum:O})=>O.label);if(u.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:p(Y,{children:p(Ne,{})})});const h=u.map(({datum:O})=>O.value).filter(O=>typeof O=="number"),d=h.length>0,f=d?Math.min(...h):0,g=d?Math.max(...h):0,y=d&&f===g,m=(r+i)/2,v=O=>{if(!d||y)return m;if(O==null)return r;const T=(O-f)/(g-f||1);return r+T*(i-r)},b=u.map(({datum:O,index:T})=>{const F=v(O.value),z=se(p(ze,{fontSize:F,fontWeight:"bold",children:O.label})),j=qe(n,[T])||wt(n);return{label:O.label,value:O.value,color:j,fontSize:F,width:z.width*1.05,height:z.height}}).sort((O,T)=>T.fontSize-O.fontSize),_=eK(b,o,a,s,c),x=Math.min(..._.map(O=>O.box.x)),w=Math.min(..._.map(O=>O.box.y)),P=Math.max(..._.map(O=>O.box.x+O.box.width)),$=Math.max(..._.map(O=>O.box.y+O.box.height)),C=-x+a,M=-w+a,S=P-x+a*2,E=$-w+a*2,A=_.map((O,T)=>{const F=O.centerX-O.width/2+C,z=O.centerY-O.height/2+M,j=O.width/2,D=O.height/2,W=`translate(${F}, ${z}) rotate(${O.angle}, ${j}, ${D})`;return p(Y,{transform:W,children:p(ze,{width:O.width,height:O.height,fontSize:O.fontSize,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:O.color,"data-indexes":T,"data-element-type":Ve.ItemLabel,children:O.label})})});return p(Ne,{id:"infographic-container",width:S,height:E,children:A})};We("chart-wordcloud",{component:a4,composites:[]});const s4=new Map,Xh=(e,t)=>{s4.set(e,t)},tK=e=>{var t;return e&&(t=s4.get(e))!=null?t:null};var nK=Object.defineProperty,rK=Object.defineProperties,iK=Object.getOwnPropertyDescriptors,c4=Object.getOwnPropertySymbols,oK=Object.prototype.hasOwnProperty,aK=Object.prototype.propertyIsEnumerable,l4=(e,t,n)=>t in e?nK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,u4=(e,t)=>{for(var n in t||(t={}))oK.call(t,n)&&l4(e,n,t[n]);if(c4)for(var n of c4(t))aK.call(t,n)&&l4(e,n,t[n]);return e},h4=(e,t)=>rK(e,iK(t));Xh("pros-cons-arrow",e=>{const{x:t,y:n,colorPositive:r,colorNegative:i,colorBg:o}=e,a=200,s=141,c={width:90,height:40,fontSize:22,alignHorizontal:"center",alignVertical:"middle",fontWeight:"bold",fill:o};return L(Y,{x:t,y:n,width:a,height:s,children:[L(xt,{children:[p("path",{d:"M137 54C137 54.2903 137 54.5806 136.706 54.7742L108.614 86.0323H64.7619C64.4071 86.0204 64.0557 86.1043 63.7453 86.2747C63.4349 86.4452 63.1773 86.6959 63 87C63.0037 86.7447 63.1092 86.5012 63.2936 86.3226L91.3862 55.0645H135.238C135.593 55.0763 135.944 54.9925 136.255 54.822C136.565 54.6516 136.823 54.4009 137 54.0968V54Z",fill:"#D9D9D9"}),p("path",{d:"M39.3272 0.484649C39.6146 0.234929 39.9662 0.0736935 40.3407 0.0198929C40.7152 -0.0339076 41.0971 0.0219605 41.4414 0.180925C41.7857 0.33989 42.0783 0.595358 42.2846 0.917314C42.491 1.23927 42.6026 1.61434 42.6063 1.99848V14.8156H136.013C136.54 14.8156 137.045 15.0282 137.418 15.4068C137.791 15.7853 138 16.2987 138 16.834V53.166C138 53.7013 137.791 54.2147 137.418 54.5932C137.045 54.9718 136.54 55.1844 136.013 55.1844H42.6063V68.0015C42.6026 68.3857 42.491 68.7607 42.2846 69.0827C42.0783 69.4046 41.7857 69.6601 41.4414 69.8191C41.0971 69.9781 40.7152 70.0339 40.3407 69.9801C39.9662 69.9263 39.6146 69.7651 39.3272 69.5154L0.672847 36.5138C0.461378 36.3244 0.292014 36.0915 0.176005 35.8305C0.0599968 35.5695 0 35.2864 0 35C0 34.7136 0.0599968 34.4306 0.176005 34.1696C0.292014 33.9085 0.461378 33.6756 0.672847 33.4862L39.4265 0.484649H39.3272Z",fill:r}),p("path",{d:"M157.394 73.0007C157.397 72.6162 157.509 72.2407 157.715 71.9183C157.922 71.596 158.214 71.3403 158.559 71.1811C158.903 71.022 159.285 70.9661 159.659 71.0199C160.034 71.0738 160.385 71.2352 160.673 71.4852L199.327 104.524C199.539 104.714 199.708 104.947 199.824 105.208C199.94 105.47 200 105.753 200 106.04C200 106.326 199.94 106.61 199.824 106.871C199.708 107.132 199.539 107.366 199.327 107.555L160.573 140.594C160.285 140.815 159.943 140.951 159.584 140.989C159.225 141.027 158.862 140.965 158.535 140.809C158.208 140.653 157.929 140.41 157.728 140.105C157.527 139.8 157.411 139.445 157.394 139.078V126.247H63.9874C63.4603 126.247 62.9548 126.034 62.5821 125.655C62.2094 125.276 62 124.762 62 124.226V87.8531C62 87.3172 62.2094 86.8032 62.5821 86.4242C62.9548 86.0453 63.4603 85.8324 63.9874 85.8324H157.394V73.0007Z",fill:i})]}),p(ze,h4(u4({x:40,y:15},c),{children:"Pros"})),p(ze,h4(u4({x:70,y:85},c),{children:"Cons"}))]})});var sK=Object.defineProperty,cK=Object.defineProperties,lK=Object.getOwnPropertyDescriptors,d4=Object.getOwnPropertySymbols,uK=Object.prototype.hasOwnProperty,hK=Object.prototype.propertyIsEnumerable,f4=(e,t,n)=>t in e?sK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p4=(e,t)=>{for(var n in t||(t={}))uK.call(t,n)&&f4(e,n,t[n]);if(d4)for(var n of d4(t))hK.call(t,n)&&f4(e,n,t[n]);return e},g4=(e,t)=>cK(e,lK(t));Xh("pros-cons-fold",e=>{const{x:t,y:n,colorPositive:r,colorNegative:i,colorBg:o}=e,a=240,s=300,c={width:85,height:30,fontSize:20,alignHorizontal:"center",alignVertical:"middle",fontWeight:"bold",fill:o};return L(Y,{x:t,y:n,width:a,height:s,children:[L(xt,{children:[p("path",{d:"M136.914 38.7755C137.303 38.7733 137.683 38.6617 138.011 38.4534C138.339 38.2451 138.602 37.9485 138.77 37.5977C138.937 37.247 139.002 36.8561 138.957 36.4701C138.913 36.084 138.76 35.7183 138.517 35.415L110.741 0.982313C110.548 0.735138 110.301 0.535238 110.018 0.397762C109.736 0.260286 109.426 0.188841 109.112 0.188841C108.798 0.188841 108.488 0.260286 108.206 0.397762C107.924 0.535238 107.676 0.735138 107.483 0.982313L79.7069 35.415C79.4639 35.7183 79.3113 36.084 79.2667 36.4701C79.222 36.8561 79.2871 37.247 79.4545 37.5977C79.6219 37.9485 79.8847 38.2451 80.213 38.4534C80.5412 38.6617 80.9216 38.7733 81.3104 38.7755H92.8965C93.0517 57.1293 97.5517 64.9878 105.259 73.7252C107.017 75.7932 108.983 77.8612 111.103 80.1361C113.276 82.4626 122.121 88.9252 131.069 95.181C129.362 88.7701 128.172 81.2218 127.293 73.7252C125.224 55.9918 125.017 38.7755 125.017 38.7755H136.914Z",fill:r,fillOpacity:.4}),p("path",{d:"M237.931 109.967C238.48 109.967 239.006 109.749 239.394 109.362C239.782 108.974 240 108.448 240 107.899V75.7932C240 75.2447 239.782 74.7187 239.394 74.3309C239.006 73.9431 238.48 73.7252 237.931 73.7252H127.241C128.172 81.2218 129.362 88.7701 131.069 95.181C138.182 100.171 145.337 105.1 152.534 109.967H237.931Z",fill:r}),p("path",{d:"M152.586 109.967C152.586 109.967 141.724 102.678 131.069 95.181C124.122 90.5838 117.455 85.5772 111.103 80.1878C109.034 77.8612 107.017 75.7415 105.259 73.7252H48.6207V56.6639C48.6091 56.2797 48.4905 55.9063 48.2784 55.5857C48.0662 55.2651 47.7689 55.0099 47.4197 54.8488C47.0705 54.6878 46.6833 54.6271 46.3016 54.6738C45.9199 54.7204 45.5587 54.8725 45.2586 55.1129L1.50002 90.2694C1.26208 90.4633 1.07029 90.7078 0.938585 90.985C0.80688 91.2622 0.738558 91.5652 0.738558 91.8721C0.738558 92.179 0.80688 92.482 0.938585 92.7592C1.07029 93.0365 1.26208 93.2809 1.50002 93.4748L45.2586 128.631C45.5621 128.874 45.928 129.027 46.3142 129.071C46.7005 129.116 47.0914 129.051 47.4424 128.884C47.7933 128.716 48.09 128.454 48.2984 128.125C48.5068 127.797 48.6185 127.417 48.6207 127.029V109.967H152.586Z",fill:"#BFBFBF"}),p("path",{d:"M36.1034 88.9252H28.9655V93.785H36.1034V101.85H41.4828V93.785H48.6207V88.8735H41.4828V81.1701H36.1034V88.9252Z",fill:"#404040"}),p("path",{d:"M103.086 261.224C102.697 261.227 102.317 261.338 101.989 261.547C101.661 261.755 101.398 262.051 101.23 262.402C101.063 262.753 100.998 263.144 101.043 263.53C101.087 263.916 101.24 264.282 101.483 264.585L129.259 299.018C129.452 299.265 129.699 299.465 129.982 299.602C130.264 299.74 130.574 299.811 130.888 299.811C131.202 299.811 131.512 299.74 131.794 299.602C132.076 299.465 132.324 299.265 132.517 299.018L160.293 264.585C160.536 264.282 160.689 263.916 160.733 263.53C160.778 263.144 160.713 262.753 160.546 262.402C160.378 262.051 160.115 261.755 159.787 261.547C159.459 261.338 159.078 261.227 158.69 261.224H147.103C146.948 242.871 142.448 235.012 134.741 226.275C132.983 224.207 131.017 222.139 128.897 219.864C126.724 217.537 117.879 211.075 108.931 204.819C110.677 211.877 111.938 219.045 112.707 226.275C114.776 244.008 114.983 261.224 114.983 261.224H103.086Z",fill:i,fillOpacity:.4}),p("path",{d:"M2.06897 190.033C1.52025 190.033 0.993996 190.251 0.605989 190.638C0.217983 191.026 5.00679e-06 191.552 5.00679e-06 192.101V224.207C5.00679e-06 224.755 0.217983 225.281 0.605989 225.669C0.993996 226.057 1.52025 226.275 2.06897 226.275H112.759C111.828 218.778 110.638 211.23 108.931 204.819C99.9827 198.512 90.931 192.411 88.2414 190.55C87.7206 190.204 87.1077 190.024 86.4828 190.033H2.06897Z",fill:i}),p("path",{d:"M87.4138 190.033C87.4138 190.033 98.2759 197.322 108.931 204.819C115.878 209.416 122.545 214.423 128.897 219.812C130.966 222.139 132.983 224.258 134.741 226.275H191.379V243.336C191.391 243.72 191.51 244.094 191.722 244.414C191.934 244.735 192.231 244.99 192.58 245.151C192.929 245.312 193.317 245.373 193.698 245.326C194.08 245.28 194.441 245.128 194.741 244.887L238.5 209.731C238.738 209.537 238.93 209.292 239.061 209.015C239.193 208.738 239.261 208.435 239.261 208.128C239.261 207.821 239.193 207.518 239.061 207.241C238.93 206.964 238.738 206.719 238.5 206.525L194.741 171.369C194.438 171.126 194.072 170.973 193.686 170.929C193.3 170.884 192.909 170.949 192.558 171.116C192.207 171.284 191.91 171.546 191.702 171.875C191.493 172.203 191.382 172.583 191.379 172.971V190.033H87.4138Z",fill:"#BFBFBF"}),p("path",{d:"M192.414 205.905V210.816H212.069V205.905H192.414Z",fill:"#404040"})]}),p(ze,g4(p4({x:153,y:77},c),{children:"PROS"})),p(ze,g4(p4({x:2,y:193},c),{children:"CONS"}))]})}),Xh("vs",e=>{const{x:t,y:n,colorPrimary:r,colorBg:i}=e,o=100,a=100,s=be(r).lighten(20).toString();return L(Y,{x:t,y:n,width:o,height:a,children:[L(Ke,{children:[p("filter",{id:"vs-divider-glow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",children:p("feGaussianBlur",{in:"SourceGraphic",stdDeviation:"8",result:"blur"})}),p(sh,{})]}),p(Ze,{x:0,y:0,width:o,height:a,fill:s,filter:"url(#vs-divider-glow-filter)",opacity:.6}),p(Ze,{x:0,y:0,width:o,height:a,fill:r,"data-element-type":"shape"}),p("text",{x:o/2,y:a/2,fontSize:Math.min(o,a)/1.5,fontWeight:"bold",fill:i,textAnchor:"middle",dominantBaseline:"central",filter:"url(#drop-shadow)",children:"VS"})]})});const m4=e=>{const{Title:t,Item:n,data:r,gap:i=20,groupGap:o=20,opposite:a=!0,flipped:s=!0,dividerType:c="vs",options:l}=e,{title:u,desc:h,items:d=[]}=r,f=t?p(t,{title:u,desc:h}):null;if(d.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const g=d[0]||{children:[]},y=d[1]||{children:[]},m=g.children||[],v=y.children||[],b=Ct(l.themeConfig),_=se(p(n,{indexes:[0,0],data:r,datum:m[0]||{}})),x=se(p(Q,{indexes:[0]})),w=tK(c),P=w?se(p(w,{x:0,y:0,colorPrimary:b.colorPrimary,colorBg:b.colorBg,colorPositive:b.colorPrimary,colorNegative:b.colorPrimary})):{width:0,height:0},$=[],C=[],M=[],S=Math.max(m.length,v.length),E=S>0?S*(_.height+i)-i:0,A=5,O=S>0?i/2+x.height/2:x.height/2,T=x.width+A,F=T+_.width+o,z=F+P.width+o,j=s?"flipped":"normal",D=s?"normal":a?"flipped":"normal";if(m.forEach((W,B)=>{const X=O+B*(_.height+i),H=[0,B];$.push(p(n,{indexes:H,datum:W,data:r,x:T,y:X,positionH:j,positionV:"middle"})),C.push(p(nt,{indexes:H,x:T-x.width-A,y:X+(_.height-x.height)/2})),B<m.length-1&&C.push(p(Q,{indexes:[0,B+1],x:T+(_.width-x.width)/2,y:X+_.height+i/2-x.height/2}))}),m.length>0){C.push(p(Q,{indexes:[0,0],x:T+(_.width-x.width)/2,y:O-i/2-x.height/2}));const W=O+(m.length-1)*(_.height+i);C.push(p(Q,{indexes:[0,m.length],x:T+(_.width-x.width)/2,y:W+_.height+i/2-x.height/2}))}else d.length>=1&&C.push(p(Q,{indexes:[0,0],x:T+(_.width-x.width)/2,y:O-x.height/2}));if(v.forEach((W,B)=>{const X=O+B*(_.height+i),H=[1,B];$.push(p(n,{indexes:H,datum:W,data:r,x:z,y:X,positionH:D,positionV:"middle"})),C.push(p(nt,{indexes:H,x:z+_.width+A,y:X+(_.height-x.height)/2})),B<v.length-1&&C.push(p(Q,{indexes:[1,B+1],x:z+(_.width-x.width)/2,y:X+_.height+i/2-x.height/2}))}),v.length>0){C.push(p(Q,{indexes:[1,0],x:z+(_.width-x.width)/2,y:O-i/2-x.height/2}));const W=O+(v.length-1)*(_.height+i);C.push(p(Q,{indexes:[1,v.length],x:z+(_.width-x.width)/2,y:W+_.height+i/2-x.height/2}))}else d.length>=2&&C.push(p(Q,{indexes:[1,0],x:z+(_.width-x.width)/2,y:O-x.height/2}));return d.length<2&&C.push(p(Q,{indexes:[1],x:z+(_.width-x.width)/2,y:O+(E-x.height)/2})),w&&M.push(p(w,{x:F,y:O+(E-P.height)/2,colorPrimary:b.colorPrimary,colorBg:b.colorBg,colorPositive:qe(l,[0])||b.colorPrimary,colorNegative:qe(l,[1])||b.colorPrimary})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,L(Y,{children:[p(Y,{children:M}),p(Ne,{children:$}),p(He,{children:C})]})]})};We("compare-binary-horizontal",{component:m4,composites:["title","item"]});var dK=Object.defineProperty,y4=Object.getOwnPropertySymbols,fK=Object.prototype.hasOwnProperty,pK=Object.prototype.propertyIsEnumerable,v4=(e,t,n)=>t in e?dK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,b4=(e,t)=>{for(var n in t||(t={}))fK.call(t,n)&&v4(e,n,t[n]);if(y4)for(var n of y4(t))pK.call(t,n)&&v4(e,n,t[n]);return e};const gK={none:5,"dot-line":100,"arc-dot":20,"split-line":5},_4=e=>{var t,n;const{Title:r,Items:i,data:o,gap:a=20,groupGap:s=0,decoration:c="none",surround:l=!0,flipRoot:u=!1,flipLeaf:h=!1,options:d}=e,[f,g]=i,{title:y,desc:m,items:v=[]}=o,b=r?p(r,{title:y,desc:m}):null,_=p(f,{indexes:[0],data:o,datum:o.items[0],themeColors:{}}),x=p(g,{indexes:[0,0],data:o,datum:((n=(t=v[0])==null?void 0:t.children)==null?void 0:n[0])||v[2]}),w=se(_),P=se(x),$=[],C=[],[M,S]=v,E=(M==null?void 0:M.children)||[],A=(S==null?void 0:S.children)||[],O=Math.max(w.height,E.length*(P.height+a)-a,A.length*(P.height+a)-a),T=gK[c]||0,F=P.width+T,z=F+w.width+s,j=(O-w.height)/2;M&&$.push(p(f,{indexes:[0],x:F,y:j,data:o,datum:M,positionH:u?"normal":"flipped"})),S&&$.push(p(f,{indexes:[1],x:z,y:j,data:o,datum:S,positionH:u?"flipped":"normal"}));const D=(W,B,X)=>{if(c==="none")return;const[H,k]=B,I=qe(d,X),R={x:H,y:k,width:P.width,height:P.height,side:W,color:I||"#ccc",colorBg:d.themeConfig.colorBg||"#fff"};c==="split-line"?C.push(p(mK,b4({},R))):c==="dot-line"&&C.push(p(yK,b4({},R)))};if(l){const B=(2*w.width+s+P.width)/2+T,X=F+w.width+s/2,H=j+w.height/2;E.forEach((k,I)=>{const R=E.length*(P.height+a)-a,q=(O-R)/2+I*(P.height+a),U=q+P.height/2-H,K=Math.max(0,B*B-U*U),te=X-Math.sqrt(K)-P.width/2;$.push(p(g,{indexes:[0,I],datum:k,data:o,x:te,y:q,positionH:h?"flipped":"normal"})),D("left",[te,q],[0,I])}),A.forEach((k,I)=>{const R=A.length*(P.height+a)-a,q=(O-R)/2+I*(P.height+a),U=q+P.height/2-H,K=Math.max(0,B*B-U*U),te=X+Math.sqrt(K)-P.width/2;$.push(p(g,{indexes:[1,I],datum:k,data:o,x:te,y:q,positionH:h?"normal":"flipped"})),D("right",[te,q],[1,I])})}else E.forEach((W,B)=>{const X=E.length*(P.height+a)-a,k=(O-X)/2+B*(P.height+a),I=[0,B],R=0;$.push(p(g,{indexes:I,datum:W,data:o,x:R,y:k,positionH:h?"flipped":"normal"})),D("left",[R,k],I)}),A.forEach((W,B)=>{const X=A.length*(P.height+a)-a,k=(O-X)/2+B*(P.height+a),I=[1,B],R=z+w.width+T;$.push(p(g,{indexes:I,datum:W,data:o,x:R,y:k,positionH:h?"normal":"flipped"})),D("right",[R,k],I)});return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[b,L(Y,{children:[p(Ne,{children:$}),p(Y,{width:0,height:0,children:C})]})]})},mK=e=>{const{x:t,y:n,width:r,height:i,color:o,colorBg:a,side:s}=e,c=n+i,l=`split-line-linear-gradient-${s}`;return L(tt,{children:[p(Ke,{children:p(ch,{id:l,startColor:o,stopColor:a,direction:s==="left"?"left-right":"right-left"})}),p(Re,{x:t,y:c,width:r,height:1,fill:`url(#${l})`})]})},yK=e=>{const{x:t,y:n,side:r,width:i,height:o,color:a,colorBg:s}=e,c=6,l=c/3,u=c*2,h=l*2,d=5,f=r==="left"?t+i+c+d:t-c-d,g=n+o/2,y=f-l,m=g-l,v=80,b=r==="left"?v:-v,_=`dot-line-linear-gradient-${r}`;return L(Y,{children:[p(Ke,{children:p(ch,{id:_,startColor:a,stopColor:s,direction:r==="left"?"left-right":"right-left"})}),L(xt,{children:[p(Ze,{x:f-c,y:g-c,width:u,height:u,fill:"none",strokeWidth:1,stroke:a}),p(Ze,{x:y,y:m,width:h,height:h,fill:a})]}),p(Re,{x:r==="left"?f:f+b,y:g-.5,width:v,height:1,fill:`url(#${_})`})]})};We("compare-hierarchy-left-right",{component:_4,composites:["title","item"]});const x4=e=>{var t,n;const{Title:r,Items:i,data:o,gap:a=0,itemGap:s=20,columnWidth:c=280,itemPadding:l=5,showColumnBackground:u=!0,columnBackgroundAlpha:h=.08,options:d}=e,[f,g]=i,{title:y,desc:m,items:v=[]}=o,b=r?p(r,{title:y,desc:m}):null,_=e3(d),x=[],w=[],P=c-l*2,$=se(p(f,{indexes:[0],data:o,datum:v[0],width:c})),C=se(p(g,{indexes:[0,0],data:o,datum:((n=(t=v[0])==null?void 0:t.children)==null?void 0:n[0])||{},width:P})),M=se(p(Q,{indexes:[0]})),S=Math.max(...v.map(A=>{var O;return((O=A.children)==null?void 0:O.length)||0}),0),E=$.height+s+S*(C.height+s);if(v.forEach((A,O)=>{const{children:T=[]}=A,F=O*(c+a),z=F,j=0;if(u){const X=`${_[O%_.length]}${Math.round(h*255).toString(16).padStart(2,"0")}`;x.push(p(Re,{x:F,y:j,width:c,height:E,fill:X,rx:0,ry:0,"data-element-type":"shape"}))}x.push(p(f,{indexes:[O],datum:A,data:o,x:z,y:j,width:c})),w.push(p(nt,{indexes:[O],x:z+$.width-M.width-10,y:j+10})),O===0&&w.push(p(Q,{indexes:[O],x:z+$.width/2-M.width/2,y:j-M.height-5}));const D=j+$.height+s;T.forEach((B,X)=>{const H=D+X*(C.height+s),k=z+l,I=[O,X];x.push(p(g,{indexes:I,datum:B,data:o,x:k,y:H,width:P})),w.push(p(nt,{indexes:I,x:k+C.width-M.width-10,y:H+(C.height-M.height)/2})),X<T.length-1&&w.push(p(Q,{indexes:[O,X+1],x:k+C.width/2-M.width/2,y:H+C.height-M.height/2}))});const W=z+l;if(T.length>0){const B=D+T.length*(C.height+s);w.push(p(Q,{indexes:[O,T.length],x:W+C.width/2-M.width/2,y:B-C.height/2-M.height/2}))}else w.push(p(Q,{indexes:[O,0],x:W+C.width/2-M.width/2,y:D-s/2-M.height/2}))}),v.length>0){const A=v.length*(c+a);w.push(p(Q,{indexes:[v.length],x:A-a/2-M.width/2,y:-M.height-5}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[b,L(Y,{children:[p(Ne,{children:x}),p(He,{children:w})]})]})};We("compare-hierarchy-row",{component:x4,composites:["title","item"]});const Uh={axisColor:"#D9D9D9",axisArrowSize:5,strokeWidth:1,dashArray:"4,2",defaultExtraSpacing:20},w4=e=>{const{Title:t,Item:n,data:r,quadrantWidth:i,quadrantHeight:o,showAxis:a=!0,dashedAxis:s=!0}=e,{title:c,desc:l,items:u=[]}=r,h=t?p(t,{title:c,desc:l}):null,d=Array.from({length:4},(_,x)=>u[x]),f=d[0]?se(p(n,{indexes:[0],data:r,datum:d[0]})):{width:0,height:0},g=i!=null?i:f.width+Uh.defaultExtraSpacing,y=o!=null?o:f.height+Uh.defaultExtraSpacing,m=bK(g,y,f),v=d.map((_,x)=>{if(!_)return null;const w=m[x];return p(n,{indexes:[x],datum:_,data:r,x:w.x,y:w.y,positionH:x%2?"flipped":"normal",positionV:x<2?"normal":"flipped"})}).filter(Boolean),b=vK(g,y,a,s);return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[h,L(Y,{width:g*2,height:y*2,children:[b,p(Ne,{children:v})]})]})};function vK(e,t,n,r){if(!n)return[];const{axisColor:i,axisArrowSize:o,strokeWidth:a,dashArray:s}=Uh,c=e,l=t,u=e*2,h=t*2,d=r?s:void 0;return[p(Pe,{d:`M 0 ${l} L ${u} ${l}`,stroke:i,strokeWidth:a,strokeDasharray:d,fill:"none","data-element-type":"shape"}),L(xt,{transform:`translate(${u}, ${l})`,children:[p(Pe,{d:`M 0 0 L ${-o} ${-o/2}`,stroke:i,strokeWidth:a,fill:"none"}),p(Pe,{d:`M 0 0 L ${-o} ${o/2}`,stroke:i,strokeWidth:a,fill:"none"})]}),L(xt,{transform:`translate(0, ${l})`,children:[p(Pe,{d:`M 0 0 L ${o} ${-o/2}`,stroke:i,strokeWidth:a,fill:"none"}),p(Pe,{d:`M 0 0 L ${o} ${o/2}`,stroke:i,strokeWidth:a,fill:"none"})]}),p(Pe,{d:`M ${c} 0 L ${c} ${h}`,stroke:i,strokeWidth:a,strokeDasharray:d,fill:"none","data-element-type":"shape"}),L(xt,{transform:`translate(${c}, 0)`,children:[p(Pe,{d:`M 0 0 L ${-o/2} ${o}`,stroke:i,strokeWidth:a,fill:"none"}),p(Pe,{d:`M 0 0 L ${o/2} ${o}`,stroke:i,strokeWidth:a,fill:"none"})]}),L(xt,{transform:`translate(${c}, ${h})`,children:[p(Pe,{d:`M 0 0 L ${-o/2} ${-o}`,stroke:i,strokeWidth:a,fill:"none"}),p(Pe,{d:`M 0 0 L ${o/2} ${-o}`,stroke:i,strokeWidth:a,fill:"none"})]})]}function bK(e,t,n){const r=e/2,i=t/2;return[{x:r-n.width/2,y:i-n.height/2},{x:e+r-n.width/2,y:i-n.height/2},{x:r-n.width/2,y:t+i-n.height/2},{x:e+r-n.width/2,y:t+i-n.height/2}]}We("quadrant",{component:w4,composites:["title","item"]});const Kh=Object.assign,_K={getId:e=>e.id||e.name,getPreH:e=>e.preH||0,getPreV:e=>e.preV||0,getHGap:e=>e.hgap||18,getVGap:e=>e.vgap||18,getChildren:e=>e.children,getHeight:e=>e.height||36,getWidth(e){const t=e.label||" ";return e.width||18*t.split("").length}};let P4=class OS{constructor(t,n){if(this.x=0,this.y=0,this.depth=0,this.children=[],this.hgap=0,this.vgap=0,t instanceof OS||"x"in t&&"y"in t&&"children"in t){const o=t;return this.data=o.data,this.id=o.id,this.x=o.x,this.y=o.y,this.width=o.width,this.height=o.height,this.depth=o.depth,this.children=o.children,this.parent=o.parent,this.hgap=o.hgap,this.vgap=o.vgap,this.preH=o.preH,void(this.preV=o.preV)}this.data=t;const r=n.getHGap(t),i=n.getVGap(t);this.preH=n.getPreH(t),this.preV=n.getPreV(t),this.width=n.getWidth(t),this.height=n.getHeight(t),this.width+=this.preH,this.height+=this.preV,this.id=n.getId(t),this.addGap(r,i)}isRoot(){return this.depth===0}isLeaf(){return this.children.length===0}addGap(t,n){this.hgap+=t,this.vgap+=n,this.width+=2*t,this.height+=2*n}eachNode(t){let n,r=[this];for(;n=r.shift();)t(n),r=n.children.concat(r)}DFTraverse(t){this.eachNode(t)}BFTraverse(t){let n,r=[this];for(;n=r.shift();)t(n),r=r.concat(n.children)}getBoundingBox(){const t={left:Number.MAX_VALUE,top:Number.MAX_VALUE,width:0,height:0};return this.eachNode(n=>{t.left=Math.min(t.left,n.x),t.top=Math.min(t.top,n.y),t.width=Math.max(t.width,n.x+n.width),t.height=Math.max(t.height,n.y+n.height)}),t}translate(t=0,n=0){this.eachNode(r=>{r.x+=t,r.y+=n,r.x+=r.preH,r.y+=r.preV})}right2left(){const t=this.getBoundingBox();this.eachNode(n=>{n.x=n.x-2*(n.x-t.left)-n.width}),this.translate(t.width,0)}bottom2top(){const t=this.getBoundingBox();this.eachNode(n=>{n.y=n.y-2*(n.y-t.top)-n.height}),this.translate(0,t.height)}};function Zh(e,t={},n){t=Kh({},_K,t);const r=new P4(e,t),i=[r];let o;if(!n&&!e.collapsed){for(;o=i.shift();)if(!o.data.collapsed){const a=t.getChildren(o.data),s=a?a.length:0;if(o.children=new Array(s),a&&s)for(let c=0;c<s;c++){const l=new P4(a[c],t);o.children[c]=l,i.push(l),l.parent=o,l.depth=o.depth+1}}}return r}let xK=class{constructor(t,n={}){this.options=n,this.rootNode=Zh(t,n)}execute(){throw new Error("please override this method")}};function wK(e,t){const n=Zh(e.data,t,!0),r=Zh(e.data,t,!0),i=e.children.length,o=Math.round(i/2),a=t.getSide||function(s,c){return c<o?"right":"left"};for(let s=0;s<i;s++){const c=e.children[s];a(c,s)==="right"?r.children.push(c):n.children.push(c)}return n.eachNode(s=>{s.isRoot()||(s.side="left")}),r.eachNode(s=>{s.isRoot()||(s.side="right")}),{left:n,right:r}}const hr=["LR","RL","TB","BT","H","V"],PK=["LR","RL","H"],$K=hr[0];function CK(e,t,n){const r=t.direction||$K;if(t.isHorizontal=(o=>PK.indexOf(o)>-1)(r),hr.indexOf(r)===-1)throw new TypeError(`Invalid direction: ${r}`);if(r===hr[0])n(e,t);else if(r===hr[1])n(e,t),e.right2left();else if(r===hr[2])n(e,t);else if(r===hr[3])n(e,t),e.bottom2top();else if(r===hr[4]||r===hr[5]){const{left:o,right:a}=wK(e,t);n(o,t),n(a,t),t.isHorizontal?o.right2left():o.bottom2top(),a.translate(o.x-a.x,o.y-a.y),e.x=o.x,e.y=a.y;const s=e.getBoundingBox();t.isHorizontal?s.top<0&&e.translate(0,-s.top):s.left<0&&e.translate(-s.left,0)}let i=t.fixedRoot;return i===void 0&&(i=!0),i&&e.translate(-(e.x+e.width/2+e.hgap),-(e.y+e.height/2+e.vgap)),(function(o,a){if(a.radial){const[s,c]=a.isHorizontal?["x","y"]:["y","x"],l={x:1/0,y:1/0},u={x:-1/0,y:-1/0};let h=0;o.DFTraverse(g=>{h++;const{x:y,y:m}=g;l.x=Math.min(l.x,y),l.y=Math.min(l.y,m),u.x=Math.max(u.x,y),u.y=Math.max(u.y,m)});const d=u[c]-l[c];if(d===0)return;const f=2*Math.PI/h;o.DFTraverse(g=>{const y=g[c],m=l[c],v=g[s],b=o[s],_=(y-m)/d*(2*Math.PI-f)+f,x=v-b;g.x=Math.cos(_)*x,g.y=Math.sin(_)*x})}})(e,t),e}function $4(e,t){let n=0;return e.children.length?e.children.forEach(r=>{n+=$4(r,t)}):n=e.height,e._subTreeSep=t.getSubTreeSep(e.data),e.totalHeight=Math.max(e.height,n)+2*e._subTreeSep,e.totalHeight}function C4(e){const t=e.children,n=t.length;if(n){t.forEach(s=>{C4(s)});const r=t[0],i=t[n-1],o=i.y-r.y+i.height;let a=0;if(t.forEach(s=>{a+=s.totalHeight}),o>e.height)e.y=r.y+o/2-e.height/2;else if(t.length!==1||e.height>a){const s=e.y+(e.height-o)/2-r.y;t.forEach(c=>{c.translate(0,s)})}else e.y=(r.y+r.height/2+i.y+i.height/2)/2-e.height/2}}const OK={getSubTreeSep:()=>0};function SK(e,t={}){return t=Kh({},OK,t),e.parent={x:0,width:0,height:0,y:0},e.BFTraverse(n=>{n.x=n.parent.x+n.parent.width}),e.parent=void 0,$4(e,t),e.startY=0,e.y=e.totalHeight/2-e.height/2,e.eachNode(n=>{const r=n.children,i=r.length;if(i){const o=r[0];if(o.startY=n.startY+n._subTreeSep,i===1)o.y=n.y+n.height/2-o.height/2;else{o.y=o.startY+o.totalHeight/2-o.height/2;for(let a=1;a<i;a++){const s=r[a];s.startY=r[a-1].startY+r[a-1].totalHeight,s.y=s.startY+s.totalHeight/2-s.height/2}}}}),C4(e),e}class MK extends xK{execute(){return CK(this.rootNode,this.options,SK)}}const EK={};function IK(e,t){const n=Kh({},EK,t);return new MK(e,n).execute()}var AK=Object.defineProperty,TK=Object.defineProperties,kK=Object.getOwnPropertyDescriptors,O4=Object.getOwnPropertySymbols,RK=Object.prototype.hasOwnProperty,LK=Object.prototype.propertyIsEnumerable,S4=(e,t,n)=>t in e?AK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zK=(e,t)=>{for(var n in t||(t={}))RK.call(t,n)&&S4(e,n,t[n]);if(O4)for(var n of O4(t))LK.call(t,n)&&S4(e,n,t[n]);return e},NK=(e,t)=>TK(e,kK(t));const DK=60,HK=14,M4=30,E4="center",qK="curved",jK=2,FK="node",BK="solid",I4=(e,t=[],n=0)=>{var r,i;const o=[...t,n];return NK(zK({},e),{_indexes:o,children:(i=(r=e.children)==null?void 0:r.map((a,s)=>I4(a,o,s)))!=null?i:[]})},A4=(e,t,n,r)=>{var i,o;t.push(e),(o=(i=e.data)._flatIndex)!=null||(i._flatIndex=t.length-1),r&&n.push({parent:r,child:e});const a=e.children;a==null||a.forEach(s=>A4(s,t,n,e))},WK=(e,t,n,r)=>{const i=Math.abs(n-e)/2,o=n>e?e+i:e-i,a=n>e?n-i:n+i;return`M ${e} ${t} C ${o} ${t} ${a} ${r} ${n} ${r}`},GK=(e,t,n,r)=>`M ${e} ${t} L ${n} ${r}`,VK=(e,t,n,r=E4)=>{const i=l=>Math.max(0,Math.min(1,l)),a=(l=>l==="top"?0:l==="bottom"?1:l==="center"?.5:i(l))(r),s=e.y+e.height*a,c=t.y+t.height*a;return n==="left"?{sx:e.x,sy:s,tx:t.x+t.width,ty:c}:{sx:e.x+e.width,sy:s,tx:t.x,ty:c}},T4=e=>{var t,n;const{Title:r,Items:i,data:o,levelGap:a=DK,nodeGap:s=HK,edgeAlign:c=E4,colorMode:l=FK,edgeColorMode:u=BK,edgeType:h=qK,edgeWidth:d=jK,options:f}=e,{title:g,desc:y,items:m=[]}=o,v=r?p(r,{title:g,desc:y}):null,b=wt(f),_=se(p(Q,{indexes:[0]})),x=new Map;let w=0;if(!m.length||!(i!=null&&i.length))return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,p(Y,{children:p(Q,{indexes:[0],x:0,y:0})})]});const P=I4(m[0]),$=new WeakMap,C=new WeakMap,M=new WeakMap,S=(N,q)=>{var G;if(l==="group"){const U=String((G=N.group)!=null?G:"");let K=x.get(U);return K==null&&(K=w,x.set(U,K),w+=1),[K]}return t3({depth:q,originalIndexes:N._indexes,flatIndex:N._flatIndex},l)},E=(N,q)=>{const G=M.get(N);if(G)return G;const U=S(N,q),K=qe(f,U),oe=Ct({colorPrimary:K},f);return M.set(N,oe),C.set(N,K),oe},A=N=>{const q=$.get(N);if(q)return q;const G=Math.max(N._indexes.length-1,0),U=Os(i,G),K=se(p(U,{indexes:N._indexes,data:o,datum:N,positionH:"center",positionV:"middle",themeColors:E(N,G)}));return $.set(N,K),K},O=IK(P,{direction:"H",getSide:(N,q)=>{if(!N.parent)return"right";const G=(N.parent.children||[]).indexOf(N);return(G>=0?G:q)%2===0?"left":"right"},getWidth:N=>A(N).width,getHeight:N=>A(N).height,getHGap:()=>a,getVGap:()=>s}),T=[],F=[];A4(O,T,F);const z=T.length>0?Math.min(...T.map(N=>N.x)):0,j=T.length>0?Math.min(...T.map(N=>N.y)):0,D=M4-z,W=M4-j,B=[],X=[],H=[],k=[],I=new WeakMap;T.forEach(N=>{var q,G;const U=N.data,K=A(U),oe=N.x+D+((q=N.hgap)!=null?q:0),te=N.y+W+((G=N.vgap)!=null?G:0),ae=Os(i,N.depth),Z=N.depth===0?"center":N.side==="left"?"flipped":"normal",ee=E(U,N.depth);H.push(p(ae,{indexes:U._indexes,data:o,datum:U,x:oe,y:te,positionH:Z,positionV:"middle",themeColors:ee})),I.set(N,{x:oe,y:te,width:K.width,height:K.height,centerX:oe+K.width/2,centerY:te+K.height/2})}),F.forEach(N=>{var q,G,U,K;const{parent:oe,child:te}=N,ae=I.get(te),Z=I.get(oe);if(!ae||!Z)return;const ee=te.data,{sx:ue,sy:ne,tx:J,ty:ie}=VK(Z,ae,te.side,c),re=(q=C.get(ee))!=null?q:qe(f,S(ee,te.depth)),ce=(G=C.get(oe.data))!=null?G:qe(f,S(oe.data,oe.depth)),pe=h==="straight"?GK(ue,ne,J,ie):WK(ue,ne,J,ie),he=`edge-gradient-${ee._indexes.join("-")}`;X.push(p(Pe,{d:pe,stroke:u==="gradient"?`url(#${he})`:re!=null?re:b,strokeWidth:d,fill:"none"})),u==="gradient"&&B.push(L("linearGradient",{id:he,gradientUnits:"userSpaceOnUse",x1:ue,y1:ne,x2:J,y2:ie,children:[p("stop",{offset:"0%",stopColor:ce!=null?ce:b}),p("stop",{offset:"100%",stopColor:re!=null?re:b})]}));const ge=(K=(U=ee.children)==null?void 0:U.length)!=null?K:0,de=[...ee._indexes,ge],we=ae.x+(ae.width-_.width)/2,Se=ae.y+ae.height+8,Ie=Se+_.height+6;te.depth>0&&k.push(p(nt,{indexes:ee._indexes,x:we,y:Se})),k.push(p(Q,{indexes:de,x:we,y:Ie}))});const R=I.get(O);if(R){const N=O.data,q=(n=(t=N.children)==null?void 0:t.length)!=null?n:0,G=[...N._indexes,q],U=R.x+(R.width-_.width)/2,K=R.y+R.height+8+_.height+6;k.push(p(Q,{indexes:G,x:U,y:K}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,L(Y,{children:[B.length>0?p(Ke,{children:B}):null,p(Y,{children:X}),p(Ne,{children:H}),p(He,{children:k})]})]})};We("hierarchy-mindmap",{component:T4,composites:["title","item"]});const Ci=(e,t)=>{if(e[0]!=="#"||e.length!==7)return e;const n=Math.max(0,Math.min(1,t)),r=Math.round(n*255).toString(16).padStart(2,"0");return`${e}${r}`},Oi=e=>e==null?"":String(e),tc=(e,t,n)=>se(p(ze,{fontSize:t,fontWeight:n,children:e})),YK=(e,t,n,r=" ")=>{const i=tc(r,t,n);let o=i.width,a=i.height;return e.forEach(s=>{const c=tc(s||" ",t,n);o=Math.max(o,c.width),a=Math.max(a,c.height)}),{width:o,height:a}},k4=(e,t,n,r)=>{const i=YK(e,t,"normal","Item");return{pillWidth:i.width+n*2,pillHeight:i.height+r*2}},R4=e=>{const{Title:t,data:n,options:r,rowGap:i=20,labelGap:o=20,groupGap:a=20,pillGap:s=14,pillColumns:c=2,ungroupedColumns:l=6,layerLabelPosition:u="left",rowPadding:h=20,groupPadding:d=16,labelPaddingX:f=28,labelPaddingY:g=16,pillPaddingX:y=18,pillPaddingY:m=10,labelFontSize:v=20,groupTitleFontSize:b=18,pillFontSize:_=16,groupTitleGap:x=10,rowRadius:w=12,groupRadius:P=10,pillRadius:$=12}=e,{title:C,desc:M,items:S=[]}=n,E=t?p(t,{title:C,desc:M}):null;if(S.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[E,p(Y,{children:p(Ne,{})})]});const A=Ct(r.themeConfig),O=[],T=[],F=u==="right",z=.12,j=.55,D=.08,W=.4,B=.06,X=.35,H=S.map(te=>{const ae=Oi(te.label),Z=tc(ae||" ",v,"bold"),ee=Z.width+f*2,ue=Z.height+g*2,ne=te.children||[];if(ne.some(we=>{var Se;return(((Se=we.children)==null?void 0:Se.length)||0)>0})){const we=[];ne.forEach(Fe=>{(Fe.children||[]).forEach(ye=>{we.push(Oi(ye.label))})});const{pillWidth:Se,pillHeight:Ie}=k4(we,_,y,m),$e=ne.map(Fe=>{const ye=Oi(Fe.label),xe=tc(ye||" ",b,"bold"),Ae=Fe.children||[],Me=Ae.length>0?Math.min(c,Ae.length):0,le=Me>0?Math.ceil(Ae.length/Me):0,me=Me>0?Me*Se+(Me-1)*s:0,Ce=le>0?le*Ie+(le-1)*s:0,rt=Math.max(xe.width,me)+d*2,Oe=d*2+xe.height+(le>0?x+Ce:0);return{label:ye,children:Ae,width:rt,height:Oe,titleHeight:xe.height,columns:Me,contentWidth:me,pillWidth:Se,pillHeight:Ie}}),Le=$e.reduce((Fe,ye)=>Fe+ye.width,0)+($e.length>1?($e.length-1)*a:0),je=$e.reduce((Fe,ye)=>Math.max(Fe,ye.height),0);return{label:ae,labelWidth:ee,labelHeight:ue,hasGroups:!0,children:ne,groupMetrics:$e,contentInnerWidth:Le,contentInnerHeight:je}}const ie=ne.map(we=>Oi(we.label)),{pillWidth:re,pillHeight:ce}=k4(ie,_,y,m),pe=ne.length>0?Math.min(l,ne.length):0,he=pe>0?Math.ceil(ne.length/pe):0,ge=pe>0?pe*re+(pe-1)*s:0,de=he>0?he*ce+(he-1)*s:0;return{label:ae,labelWidth:ee,labelHeight:ue,hasGroups:!1,children:ne,pillWidth:re,pillHeight:ce,columns:pe,contentInnerWidth:ge,contentInnerHeight:de}}),k=H.reduce((te,ae)=>Math.max(te,ae.labelWidth),0),I=H.reduce((te,ae)=>Math.max(te,ae.contentInnerWidth),0),R=te=>{const ae=qe(r,[te])||A.colorPrimary||"#6c7dff";return{rowFill:Ci(ae,z),rowStroke:Ci(ae,j),groupFill:Ci(ae,D),groupStroke:Ci(ae,W),pillFill:Ci(ae,B),pillStroke:Ci(ae,X)}},N=(te,ae,Z,ee,ue,ne,J,ie,re,ce,pe,he,ge,de)=>{O.push(p(Re,{x:Z,y:J,width:ue,height:ie,fill:ge,stroke:de,rx:w,ry:w,"data-element-type":"shape"})),O.push(p(Re,{x:re,y:ce,width:pe,height:he,fill:ge,stroke:de,rx:w,ry:w,"data-element-type":"shape"})),T.push(p(ze,{x:Z,y:ee,width:ue,height:ne,fontSize:v,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:A.colorText,"data-element-type":Ve.ItemLabel,"data-indexes":ae,children:te}))},q=(te,ae,Z,ee)=>{const ue=te.groupMetrics||[],ne=te.label,J=[ae],ie=k,re=te.labelHeight,ce=te.contentInnerHeight,pe=Math.max(0,I-te.contentInnerWidth),he=ue.length>0?pe/ue.length:0,de=te.contentInnerWidth+(ue.length>0?pe:0)+h*2,we=ce+h*2,Se=Math.max(re,we),Ie=F?0:ie+o,$e=F?Ie+de+o:0,Le=Z+(Se-re)/2,je=Z+(Se-we)/2;N(ne,J,$e,Le,ie,re,Z,Se,Ie,je,de,we,ee.rowFill,ee.rowStroke);let Fe=Ie+h;return ue.forEach((xe,Ae)=>{const Me=[...J,Ae],le=xe.width+he,me=je+h+(ce-xe.height)/2;O.push(p(Re,{x:Fe,y:me,width:le,height:xe.height,fill:ee.groupFill,stroke:ee.groupStroke,rx:P,ry:P,"data-element-type":"shape"}));const Ce=xe.children.length>0,Ye=Ce?me+d:me,rt=Ce?xe.titleHeight:xe.height,Oe=Ce?"top":"middle";if(T.push(p(ze,{x:Fe+d,y:Ye,width:le-d*2,height:rt,fontSize:b,fontWeight:"bold",alignHorizontal:"center",alignVertical:Oe,fill:A.colorText,"data-element-type":Ve.ItemLabel,"data-indexes":Me,children:xe.label})),xe.columns>0){const Be=le-d*2,Qe=Be-xe.contentWidth,Je=Qe>0?Qe/xe.columns:0,Xe=xe.pillWidth+Je,ft=xe.columns*Xe+(xe.columns-1)*s,et=(Be-ft)/2,jt=Fe+d+Math.max(0,et),Bt=me+d+xe.titleHeight+x;xe.children.forEach((Ue,$t)=>{const Rt=[...Me,$t],Ut=Math.floor($t/xe.columns),Ln=$t%xe.columns,Jr=jt+Ln*(Xe+s),ei=Bt+Ut*(xe.pillHeight+s),zn=Math.min($,xe.pillHeight/2);O.push(p(Re,{x:Jr,y:ei,width:Xe,height:xe.pillHeight,fill:ee.pillFill,stroke:ee.pillStroke,rx:zn,ry:zn,"data-element-type":"shape"})),T.push(p(ze,{x:Jr,y:ei,width:Xe,height:xe.pillHeight,fontSize:_,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:A.colorText,"data-element-type":Ve.ItemLabel,"data-indexes":Rt,children:Oi(Ue.label)}))})}Fe+=le+a}),{rowWidth:F?$e+ie:Ie+de,rowHeight:Se}},G=(te,ae,Z,ee)=>{const ue=te.label,ne=[ae],J=k,ie=te.labelHeight,re=te.contentInnerHeight,ce=Math.max(0,I-te.contentInnerWidth),pe=te.columns||0,he=te.pillWidth||0,ge=te.pillHeight||0,de=pe>0?ce/pe:0,we=he+de,Ie=(pe>0?pe*we+(pe-1)*s:0)+h*2,$e=re+h*2,Le=Math.max(ie,$e),je=F?0:J+o,Fe=F?je+Ie+o:0,ye=Z+(Le-ie)/2,xe=Z+(Le-$e)/2;if(N(ue,ne,Fe,ye,J,ie,Z,Le,je,xe,Ie,$e,ee.rowFill,ee.rowStroke),pe>0){const Me=je+h,le=xe+h;(te.children||[]).forEach((Ce,Ye)=>{const rt=[...ne,Ye],Oe=Math.floor(Ye/pe),Be=Ye%pe,Qe=Me+Be*(we+s),Je=le+Oe*(ge+s),Xe=Math.min($,ge/2);O.push(p(Re,{x:Qe,y:Je,width:we,height:ge,fill:ee.pillFill,stroke:ee.pillStroke,rx:Xe,ry:Xe,"data-element-type":"shape"})),T.push(p(ze,{x:Qe,y:Je,width:we,height:ge,fontSize:_,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:A.colorText,"data-element-type":Ve.ItemLabel,"data-indexes":rt,children:Oi(Ce.label)}))})}return{rowWidth:F?Fe+J:je+Ie,rowHeight:Le}};let U=0,K=0;H.forEach((te,ae)=>{const Z=R(ae),{rowWidth:ee,rowHeight:ue}=te.hasGroups?q(te,ae,U,Z):G(te,ae,U,Z);K=Math.max(K,ee),U+=ue+i});const oe=Math.max(U-i,0);return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[E,L(Y,{width:K,height:oe,children:[p(Y,{children:O}),p(Ne,{children:T})]})]})};We("hierarchy-structure",{component:R4,composites:["title"]});var XK=Object.defineProperty,UK=Object.defineProperties,KK=Object.getOwnPropertyDescriptors,L4=Object.getOwnPropertySymbols,ZK=Object.prototype.hasOwnProperty,QK=Object.prototype.propertyIsEnumerable,z4=(e,t,n)=>t in e?XK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nc=(e,t)=>{for(var n in t||(t={}))ZK.call(t,n)&&z4(e,n,t[n]);if(L4)for(var n of L4(t))QK.call(t,n)&&z4(e,n,t[n]);return e},rc=(e,t)=>UK(e,KK(t));const N4=(e,t)=>{const n=Math.max(0,t/2-1);return Math.min(e,n)},D4=e=>{const{Title:t,Items:n,data:r,levelGap:i=80,nodeGap:o=60,edgeType:a="straight",edgeColorMode:s="gradient",edgeWidth:c=3,edgeStyle:l="solid",edgeDashPattern:u="5,5",edgeCornerRadius:h=0,edgeOffset:d=0,edgeOrigin:f="center",edgeOriginPadding:g=20,edgeMarker:y="none",markerSize:m=12,colorMode:v="branch",orientation:b="top-bottom",options:_}=e,x=b==="left-right"||b==="right-left",w=b==="bottom-top"||b==="right-left"?-1:1,{title:P,desc:$}=r,C=wt(_),M=new Map;let S=0;const E=J=>{var ie;const re=[...J];return(ie=re[0])!=null&&ie.children||(re[0]=rc(nc({},re[0]),{children:re.slice(1)}),re.splice(1)),re},A=(J,ie,re,ce,pe,he="vertical")=>{const ge=he==="vertical",de=ge?ce-ie:re-J,we=ge?re-J:ce-ie,Se=de===0?1:Math.sign(de),Ie=we===0?1:Math.sign(we),$e=ge?ie+de/2:J+de/2,Le=Math.min(pe,Math.abs(de)/2,Math.abs(we)/2);return Le===0?ge?`M ${J} ${ie} L ${J} ${$e} L ${re} ${$e} L ${re} ${ce}`:`M ${J} ${ie} L ${$e} ${ie} L ${$e} ${ce} L ${re} ${ce}`:ge?`M ${J} ${ie}
|
|
93
|
-
L ${
|
|
94
|
-
Q ${
|
|
95
|
-
L ${
|
|
96
|
-
Q ${
|
|
97
|
-
L ${
|
|
98
|
-
L ${
|
|
99
|
-
Q ${
|
|
100
|
-
L ${
|
|
101
|
-
Q ${
|
|
102
|
-
L ${re} ${ce}`},O=J=>{const{x:ie,y:re}=J;return x?{x:re*w,y:ie}:{x:ie,y:re*w}},T=(J,ie,re)=>{const{x:ce,y:pe}=O(J),he=ce+re.x,ge=pe+re.y,de=ge+ie.height/2;return{centerX:he,centerY:de,left:he-ie.width/2,right:he+ie.width/2,top:ge,bottom:ge+ie.height}},F=J=>{var ie;if(!J.length)return null;const re=J[0],ce=(pe,he=[],ge=0)=>{var de,we;const Se=[...he,ge];return rc(nc({},pe),{_originalIndex:Se,_depth:Se.length-1,children:(we=(de=pe.children)==null?void 0:de.map((Ie,$e)=>ce(Ie,Se,$e)))!=null?we:[]})};return(ie=re.children)!=null&&ie.length?ce(re):rc(nc({},re),{_originalIndex:[0],_depth:0,children:J.slice(1).map((pe,he)=>rc(nc({},pe),{_originalIndex:[he+1],_depth:1}))})},z=J=>{var ie,re;let ce=0,pe=0;const he=new Map,ge=new Map;J.each(de=>{ge.has(de.depth)||ge.set(de.depth,de.data)});for(let de=0;de<J.height+1;de++){const we=Os(n,de),Se=(ie=ge.get(de))!=null?ie:{},Ie=(re=Se._originalIndex)!=null?re:Array(de+1).fill(0),$e=se(p(we,{indexes:Ie,data:r,datum:Se,positionH:"center"}));he.set(de,$e),ce=Math.max(ce,$e.width),pe=Math.max(pe,$e.height)}return{levelBounds:he,maxWidth:ce,maxHeight:pe}},j=(J,ie)=>{var re;if(v==="group"){const ce=String((re=J==null?void 0:J.group)!=null?re:"");let pe=M.get(ce);return pe==null&&(pe=S,M.set(ce,pe),S+=1),[pe]}return t3({depth:ie,originalIndexes:J._originalIndex,flatIndex:J._flatIndex},v)},D=(J,ie,re,ce,pe,he)=>{const{depth:ge,data:de,parent:we}=J,Se=de._originalIndex,Ie=Os(n,ge),$e=ie.get(ge),Le=T(J,$e,ce),je=Le.left,Fe=Le.top,ye={items:[],btns:[],deco:[]},xe=j(de,ge),Ae=qe(_,xe),Me=Ct({colorPrimary:Ae},_);if(ye.items.push(p(Ie,{indexes:Se,datum:de,data:r,x:je,y:Fe,positionH:"center",themeColors:Me})),ye.btns.push(p(nt,{indexes:Se,x:je+($e.width-re.width)/2,y:Fe+$e.height+5}),p(Q,{indexes:[...Se,0],x:je+($e.width-re.width)/2,y:Fe+$e.height+re.height+10})),we){const le=ie.get(we.depth),me=T(we,le,ce),Ce=he.filter(Ue=>Ue.parent===we),Ye=Ce.findIndex(Ue=>Ue===J),rt=Ce.length;let Oe,Be;if(f==="distributed"&&rt>1)if(x){const Ue=N4(g,le.height),$t=me.top+Ue,Ut=(me.bottom-Ue-$t)/rt;Be=$t+Ut*Ye+Ut/2,Oe=(w>0?me.right:me.left)+d*w}else{const Ue=N4(g,le.width),$t=me.left+Ue,Ut=(me.right-Ue-$t)/rt;Oe=$t+Ut*Ye+Ut/2,Be=(w>0?me.bottom:me.top)+d*w}else Oe=x?(w>0?me.right:me.left)+d*w:me.centerX,Be=x?me.centerY:(w>0?me.bottom:me.top)+d*w;const Qe=x?(w>0?Le.left:Le.right)-d*w:Le.centerX,Je=x?Le.centerY:(w>0?Le.top:Le.bottom)-d*w;let Xe=Qe,ft=Je;y==="arrow"&&(x?Xe-=m*w:ft-=m*w);let et;if(a==="curved")if(x){const Ue=Oe+(Xe-Oe)/2;et=`M ${Oe} ${Be} C ${Ue} ${Be}, ${Ue} ${ft}, ${Xe} ${ft}`}else{const Ue=Be+(ft-Be)/2;et=`M ${Oe} ${Be} C ${Oe} ${Ue}, ${Xe} ${Ue}, ${Xe} ${ft}`}else if(h>0)et=A(Oe,Be,Xe,ft,h,x?"horizontal":"vertical");else if(x){const Ue=Oe+(Xe-Oe)/2;et=`M ${Oe} ${Be} L ${Ue} ${Be} L ${Ue} ${ft} L ${Xe} ${ft}`}else{const Ue=Be+(ft-Be)/2;et=`M ${Oe} ${Be} L ${Oe} ${Ue} L ${Xe} ${Ue} L ${Xe} ${ft}`}let jt=C;if(s==="gradient"){const Ue=j(we.data,we.depth),$t=j(de,ge),Rt=qe(_,Ue),Ut=qe(_,$t),Ln=`gradient-${we.data._originalIndex.join("-")}-${Se.join("-")}`;pe.push(L("linearGradient",{id:Ln,x1:Oe,y1:Be,x2:Xe,y2:ft,gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0%",stopColor:Rt}),p("stop",{offset:"100%",stopColor:Ut})]})),jt=`url(#${Ln})`}const Bt=l==="dashed"?u:"";if(ye.deco.push(p(Pe,{d:et,stroke:jt,strokeWidth:c,strokeDasharray:Bt,fill:"none"})),y==="arrow"){const Ue=s==="gradient"?qe(_,xe):wt(_),$t=x?[{x:Qe,y:Je},{x:Qe-m*w,y:Je-m/2},{x:Qe-m*w,y:Je+m/2}]:[{x:Qe,y:Je},{x:Qe-m/2,y:Je-m*w},{x:Qe+m/2,y:Je-m*w}];ye.deco.push(p(Wt,{points:$t,fill:Ue,width:m,height:m}))}if(y==="dot"){const Ue=j(we.data,we.depth),$t=s==="gradient"?qe(_,Ue):wt(_);ye.deco.push(p(Ze,{x:(x?w>0?me.right+d:me.left-d:Oe)-m,y:(x?Be:w>0?me.bottom+d:me.top-d)-m,width:m*2,height:m*2,fill:$t}));const Rt=s==="gradient"?qe(_,xe):wt(_);ye.deco.push(p(Ze,{x:Qe-m,y:Je-m,width:m*2,height:m*2,fill:Rt}))}}return ye},W=(J,ie,re)=>{const ce=new Map;J.forEach(he=>{var ge;const de=he.parent?he.parent.data._originalIndex.join("-"):"root";((ge=ce.get(de))!=null?ge:ce.set(de,[]).get(de)).push(he)});const pe=[];return ce.forEach(he=>{if(he.length<=1)return;const ge=he.slice().sort((de,we)=>x?O(de).y-O(we).y:O(de).x-O(we).x);if(ge.length!==0)for(let de=0;de<ge.length-1;de++){const we=O(ge[de]),Se=O(ge[de+1]),Ie=ge[de].data._originalIndex.slice(0,-1),$e=ge[de].data._originalIndex.at(-1)+1;if(x){const Le=we.x+re.x+(w>0?-ie.width-5:ie.width+5),je=(we.y+Se.y)/2+re.y-ie.height/2;pe.push(p(Q,{indexes:[...Ie,$e],x:Le,y:je}))}else{const Le=we.y+re.y-ie.height-5,je=(we.x+Se.x)/2+re.x-ie.width/2;pe.push(p(Q,{indexes:[...Ie,$e],x:je,y:Le}))}}}),pe},B=E(r.items),X=t?p(t,{title:P,desc:$}):null,H=se(p(Q,{indexes:[0]}));if(!B.length)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[X,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:-H.width/2,y:-H.height/2})})})]});const k=F(B),I=Dh(k),{levelBounds:R,maxWidth:N,maxHeight:q}=z(I),U=LY().nodeSize(x?[q+o,N+i]:[N+o,q+i]).separation(()=>1)(I).descendants(),K=U.map(J=>O(J)),oe=Math.min(...K.map(J=>J.x)),te=Math.min(...K.map(J=>J.y)),ae={x:Math.max(0,-oe+N/2),y:Math.max(0,-te+H.height+10)},Z=[],ee=[],ue=[],ne=[];return U.forEach((J,ie)=>{J.data._flatIndex=ie;const{x:re,y:ce}=O(J);J.__layout={x:re,y:ce}}),U.forEach(J=>{const{items:ie,btns:re,deco:ce}=D(J,R,H,ae,ne,U);Z.push(...ie),ee.push(...re),ue.push(...ce)}),ee.push(...W(U,H,ae)),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[X,L(Y,{children:[ne.length>0&&p(Ke,{children:ne}),p(xt,{children:ue}),p(Ne,{children:Z}),p(He,{children:ee})]})]})};We("hierarchy-tree",{component:D4,composites:["title","item"]});const H4=e=>{const{Title:t,Item:n,data:r,gap:i=20,width:o,zigzag:a}=e,{title:s,desc:c,items:l=[]}=r,u=se(p(Q,{indexes:[0]})),h=se(p(n,{indexes:[0],data:r,datum:l[0]})),d=o||h.width,f=t?p(t,{title:s,desc:c}):null,g=[],y=[],m=(d-u.width)/2;if(l.forEach((v,b)=>{const _=(h.height+i)*b,x=[b];y.push(p(n,{indexes:x,datum:v,data:r,y:_,width:d,positionV:"middle",positionH:a?b%2===0?"normal":"flipped":"normal"})),g.push(p(nt,{indexes:x,x:-u.width-10,y:_+(h.height-u.height)/2}));const w=b===0?-u.height:_-i/2-u.height/2;g.push(p(Q,{indexes:x,x:m,y:w}))}),l.length>0){const b=(h.height+i)*(l.length-1)+h.height;g.push(p(Q,{indexes:[l.length],x:m,y:b}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,L(Y,{children:[p(Ne,{children:y}),p(He,{children:g})]})]})};We("list-column",{component:H4,composites:["title","item"]});const q4=e=>{const{Title:t,Item:n,data:r,columns:i=3,gap:o=24,zigzag:a}=e,{title:s,desc:c,items:l=[]}=r,u=t?p(t,{title:s,desc:c}):null,h=se(p(Q,{indexes:[0]})),d=se(p(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),f=[],g=[],y=d.height+o,m=d.width+o,v=new Set;return l.forEach((b,_)=>{const x=Math.floor(_/i),w=_%i,P=w*m,$=x*y,C=[_];g.push(p(n,{indexes:C,datum:b,data:r,x:P,y:$,positionH:"center",positionV:a&&_%2===0?"normal":"flipped"})),f.push(p(nt,{indexes:C,x:P+(d.width-h.width)/2,y:$+d.height})),w<i-1&&f.push(p(Q,{indexes:[_+1],x:P+d.width+(o-h.width)/2,y:$+(d.height-h.height)/2})),w===0&&!v.has(x)&&(f.push(p(Q,{indexes:[_],x:P-o/2-h.width/2,y:$+(d.height-h.height)/2})),v.add(x)),(w===i-1||_===l.length-1)&&f.push(p(Q,{indexes:[_+1],x:P+d.width+o/2-h.width/2,y:$+(d.height-h.height)/2}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,L(Y,{children:[p(Ne,{children:g}),p(He,{children:f})]})]})};We("list-grid",{component:q4,composites:["title","item"]});const j4=e=>{const{Title:t,Item:n,data:r,gap:i=20,levelGap:o=20}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=se(p(Q,{indexes:[0]})),h=se(p(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),d=[],f=[],g=Math.ceil(Math.sqrt(c.length)),y=[];let m=c.length;for(let w=0;w<g;w++){const P=Math.min(w+1,m);if(y.push(P),m-=P,m<=0)break}let v=0;const b=Math.max(...y),x=(b*h.width+(b-1)*i)/2;return y.forEach((w,P)=>{const $=P*(h.height+o),C=w*h.width+(w-1)*i,M=x-C/2;for(let S=0;S<w&&v<c.length;S++){const E=M+S*(h.width+i),A=c[v],O=[v];f.push(p(n,{indexes:O,datum:A,data:r,x:E,y:$,positionH:"center"})),d.push(p(nt,{indexes:O,x:E+(h.width-u.width)/2,y:$+h.height})),S<w-1&&d.push(p(Q,{indexes:[v+1],x:E+h.width+(i-u.width)/2,y:$+(h.height-u.height)/2})),S===0&&d.push(p(Q,{indexes:[v],x:E-i/2-u.width/2,y:$+(h.height-u.height)/2})),S===w-1&&d.push(p(Q,{indexes:[v+1],x:E+h.width+i/2-u.width/2,y:$+(h.height-u.height)/2})),v++}}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(Ne,{children:f}),p(He,{children:d})]})]})};We("list-pyramid",{component:j4,composites:["title","item"]});const F4=e=>{const{Title:t,Item:n,data:r,gap:i=20,zigzag:o}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=se(p(Q,{indexes:[0]})),h=se(p(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),d=[],f=[],g=(h.height-u.height)/2,y=h.height;if(c.forEach((m,v)=>{const b=(h.width+i)*v,_=[v];f.push(p(n,{indexes:_,datum:m,data:r,x:b,positionH:"center",positionV:o&&v%2===0?"normal":"flipped"})),d.push(p(nt,{indexes:_,x:b+(h.width-u.width)/2,y}));const x=v===0?-(i+u.width)/2:b-(i+u.width)/2;d.push(p(Q,{indexes:_,x,y:g}))}),c.length>0){const v=(h.width+i)*(c.length-1)+h.width+(i-u.width)/2;d.push(p(Q,{indexes:[c.length],x:v,y:g}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(Ne,{children:f}),p(He,{children:d})]})]})};We("list-row",{component:F4,composites:["title","item"]});var JK=Object.defineProperty,B4=Object.getOwnPropertySymbols,eZ=Object.prototype.hasOwnProperty,tZ=Object.prototype.propertyIsEnumerable,W4=(e,t,n)=>t in e?JK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nZ=(e,t)=>{for(var n in t||(t={}))eZ.call(t,n)&&W4(e,n,t[n]);if(B4)for(var n of B4(t))tZ.call(t,n)&&W4(e,n,t[n]);return e};const G4=e=>{const{Item:t,data:n,outerRadius:r=250,innerRadius:i=120,startAngle:o=-90,endAngle:a=270,gapAngle:s=1,options:c}=e,{title:l,items:u=[]}=n,h=Ct(c.themeConfig),d=se(p(Q,{indexes:[0]})),f=[],g=[],y=[],m=r+100,v=r+100,b=a-o,_=Math.abs(b-360)<.01,x=u.length>0?s*(_?u.length:u.length-1):0,w=b-x,P=u.length>0?w/u.length:0;if(u.forEach((O,T)=>{var F;const z=[T],j=o+(P+s)*T,D=j+P,B=s*Math.PI*r/180/i*(180/Math.PI),X=s,H=(j+X/2)*Math.PI/180,k=(D-X/2)*Math.PI/180,I=(j+B/2)*Math.PI/180,R=(D-B/2)*Math.PI/180,N=m+r*Math.cos(H),q=v+r*Math.sin(H),G=m+r*Math.cos(k),U=v+r*Math.sin(k),K=m+i*Math.cos(I),oe=v+i*Math.sin(I),te=m+i*Math.cos(R),ae=v+i*Math.sin(R),Z=P>180?1:0,ee=`
|
|
103
|
-
M ${
|
|
104
|
-
A ${r} ${r} 0 ${Z} 1 ${
|
|
105
|
-
L ${
|
|
106
|
-
A ${i} ${i} 0 ${Z} 0 ${K} ${
|
|
92
|
+
`,k(Y,nK(tK({},h),{children:[y(Ce,{d:P,x:0,y:0,width:r,height:i,fill:u.colorPrimary,"data-element-type":"shape"}),y(Ft,{indexes:n,x:g,y:m,size:o,fill:u.colorBg}),y(Ve,{indexes:n,x:_,y:v,width:f,fontSize:14,fontWeight:"bold",fill:u.colorBg,alignHorizontal:l==="flipped"?"right":"left",children:t.label}),t.desc&&y(ft,{indexes:n,x:w,y:x,width:f,fontSize:11,wordWrap:!0,fill:u.colorBg,alignHorizontal:l==="flipped"?"right":"left",children:t.desc})]}))};ct("quarter-simple-card",{component:p4,composites:["icon","label","desc"]});var rK=Object.defineProperty,iK=Object.defineProperties,oK=Object.getOwnPropertyDescriptors,g4=Object.getOwnPropertySymbols,sK=Object.prototype.hasOwnProperty,aK=Object.prototype.propertyIsEnumerable,m4=(e,t,n)=>t in e?rK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lK=(e,t)=>{for(var n in t||(t={}))sK.call(t,n)&&m4(e,n,t[n]);if(g4)for(var n of g4(t))aK.call(t,n)&&m4(e,n,t[n]);return e},cK=(e,t)=>iK(e,oK(t));const y4=e=>{const[{datum:t,indexes:n,width:r=240,height:i=140,iconSize:o=28,gap:s=12,ribbonHeight:a=32,themeColors:l},c]=lt(e,["width","height","iconSize","gap","ribbonHeight"]),u=`${l.colorPrimary}-ribbon`;return k(Y,cK(lK({},c),{children:[y(Ke,{children:k("linearGradient",{id:u,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[y("stop",{offset:"0%",stopColor:l.colorPrimary}),y("stop",{offset:"100%",stopColor:be(l.colorPrimary).darken(15).toHexString()})]})}),k(Pt,{children:[y(ke,{x:0,y:0,width:r,height:i,fill:l.colorBgElevated,stroke:l.colorPrimaryBg,strokeWidth:1,rx:8,ry:8}),y(ke,{x:0,y:0,width:r,height:a,fill:`url(#${u})`,rx:8,ry:8}),y(ke,{x:0,y:8,width:r,height:a-8,fill:`url(#${u})`}),y(Ce,{x:r-20,y:a,width:20,height:8,fill:be(l.colorPrimary).darken(25).toHexString(),d:"M0,0 L20,0 L15,8 L5,8 Z"})]}),y(Ft,{indexes:n,x:s,y:a+s,size:o,fill:l.colorPrimary}),y(Ve,{indexes:n,x:o+2*s,y:a+s,width:r-o-3*s,height:o,alignHorizontal:"left",alignVertical:"middle",lineHeight:1,fontWeight:"bold",fill:l.colorText,children:t.label}),y(ft,{indexes:n,x:s,y:a+o+s+5,width:r-2*s,alignHorizontal:"left",fill:l.colorTextSecondary,lineNumber:3,wordWrap:!0,children:t.desc}),y(Ft,{indexes:n,x:r-s-8,y:s/2,size:16,fill:l.colorWhite})]}))};ct("ribbon-card",{component:y4,composites:["icon","label","desc"]});var uK=Object.defineProperty,hK=Object.defineProperties,fK=Object.getOwnPropertyDescriptors,v4=Object.getOwnPropertySymbols,dK=Object.prototype.hasOwnProperty,pK=Object.prototype.propertyIsEnumerable,b4=(e,t,n)=>t in e?uK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gK=(e,t)=>{for(var n in t||(t={}))dK.call(t,n)&&b4(e,n,t[n]);if(v4)for(var n of v4(t))pK.call(t,n)&&b4(e,n,t[n]);return e},mK=(e,t)=>hK(e,fK(t));const _4=e=>{const[{indexes:t,datum:n,themeColors:r,width:i=300,height:o=40,padding:s=4,positionH:a="normal"},l]=lt(e,["width","height","borderRadius","padding"]),c=o/2,u=c,h=s,f=i-c*2,d=o-s*2;return k(Y,mK(gK({},l),{children:[y(ke,{"data-element-type":"shape",width:i,height:o,rx:c,ry:c,fill:r.colorPrimaryBg,stroke:r.colorPrimary,strokeWidth:1,opacity:.8}),y(Ve,{indexes:t,x:u,y:h,width:f,height:d,alignHorizontal:a==="flipped"?"right":a==="center"?"center":"left",alignVertical:"middle",fontSize:14,fontWeight:"500",fill:r.colorText,children:n.label})]}))};ct("rounded-rect-node",{component:_4,composites:["label"]});var yK=Object.defineProperty,vK=Object.defineProperties,bK=Object.getOwnPropertyDescriptors,w4=Object.getOwnPropertySymbols,_K=Object.prototype.hasOwnProperty,wK=Object.prototype.propertyIsEnumerable,x4=(e,t,n)=>t in e?yK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,xK=(e,t)=>{for(var n in t||(t={}))_K.call(t,n)&&x4(e,n,t[n]);if(w4)for(var n of w4(t))wK.call(t,n)&&x4(e,n,t[n]);return e},CK=(e,t)=>vK(e,bK(t));const C4=e=>{const[{width:t=24,height:n=t,strokeWidth:r=2,themeColors:i,datum:o},s]=lt(e,["width","height"]),a=Math.min(t,n)-r,l=r/2;return k(Y,CK(xK({},s),{width:t,height:n,children:[y(ke,{width:t,height:n,fill:"none",visibility:"hidden"}),y(Ze,{x:l,y:l,width:a,height:a,fill:i.colorPrimary,stroke:i.isDarkMode?"#FFF":"#000",strokeWidth:r,"data-element-type":"shape",children:y("title",{children:o.label||o.desc})})]}))};ct("simple-circle-node",{component:C4,composites:[]});var PK=Object.defineProperty,OK=Object.defineProperties,SK=Object.getOwnPropertyDescriptors,P4=Object.getOwnPropertySymbols,$K=Object.prototype.hasOwnProperty,EK=Object.prototype.propertyIsEnumerable,O4=(e,t,n)=>t in e?PK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,MK=(e,t)=>{for(var n in t||(t={}))$K.call(t,n)&&O4(e,n,t[n]);if(P4)for(var n of P4(t))EK.call(t,n)&&O4(e,n,t[n]);return e},IK=(e,t)=>OK(e,SK(t));const S4=e=>{const[{indexes:t,datum:n,width:r=140,themeColors:i,positionV:o="normal"},s]=lt(e,["width"]),a=o!=="flipped",l=a?"bottom":"top",c=y(Ve,{indexes:t,width:r,fill:i.colorText,alignHorizontal:"center",alignVertical:l,fontSize:14,children:n.label}),u=y(ft,{indexes:t,width:r,fill:i.colorTextSecondary,alignHorizontal:"center",alignVertical:l,children:n.desc}),h=30,f=10,d=ae(c),p=ae(u),g=d.height+p.height,m=g+f+h+f+g;return y(Y,IK(MK({width:r,height:m},s),{children:k(ve,{flexDirection:"column",alignItems:"center",children:[a?k(tt,{children:[u,c,y(yt,{height:f})]}):y(tt,{children:y(yt,{height:g+f})}),k(Pi,{horizontal:"center",vertical:"middle",children:[y(AK,{width:r,height:h,fill:i.colorPrimary}),y(Ne,{width:r,height:h,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:n.time?n.time:String(t[0]+1).padStart(2,"0").slice(-2)})]}),a?y(tt,{children:y(yt,{height:g+f})}):k(tt,{children:[y(yt,{height:f}),c,u]})]})}))},AK=e=>{const{x:t=0,y:n=0,width:r=100,height:i=40,fill:o="#FF356A",size:s=10}=e;return y(Yt,{width:r,height:i,points:[{x:t,y:n},{x:t+r-s,y:n},{x:t+r,y:n+i/2},{x:t+r-s,y:n+i},{x:t,y:n+i},{x:t+s,y:n+i/2}],fill:o,"data-element-type":"shape"})};ct("simple-horizontal-arrow",{component:S4,composites:["label","desc","time"]});var TK=Object.defineProperty,RK=Object.defineProperties,kK=Object.getOwnPropertyDescriptors,$4=Object.getOwnPropertySymbols,LK=Object.prototype.hasOwnProperty,NK=Object.prototype.propertyIsEnumerable,E4=(e,t,n)=>t in e?TK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,zK=(e,t)=>{for(var n in t||(t={}))LK.call(t,n)&&E4(e,n,t[n]);if($4)for(var n of $4(t))NK.call(t,n)&&E4(e,n,t[n]);return e},DK=(e,t)=>RK(e,kK(t));const M4=e=>{const[{indexes:t,datum:n,width:r=180,illusSize:i=r,gap:o=8,themeColors:s,usePaletteColor:a=!1},l]=lt(e,["width","illusSize","gap","usePaletteColor"]),{label:c,desc:u}=n,h=a?s.colorPrimary:s.colorText,f=y(Ve,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"middle",fill:h,children:c}),d=ae(f);return k(ve,DK(zK({},l),{width:r,height:i+o+d.height+o+48,flexDirection:"column",alignItems:"center",justifyContent:"center",gap:o,children:[y(fw,{indexes:t,width:i,height:i}),f,y(ft,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"top",fill:s.colorTextSecondary,lineNumber:3,children:u})]}))};ct("simple-illus",{component:M4,composites:["illus","label","desc"]});var qK=Object.defineProperty,HK=Object.defineProperties,jK=Object.getOwnPropertyDescriptors,I4=Object.getOwnPropertySymbols,FK=Object.prototype.hasOwnProperty,BK=Object.prototype.propertyIsEnumerable,A4=(e,t,n)=>t in e?qK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,lf=(e,t)=>{for(var n in t||(t={}))FK.call(t,n)&&A4(e,n,t[n]);if(I4)for(var n of I4(t))BK.call(t,n)&&A4(e,n,t[n]);return e},cf=(e,t)=>HK(e,jK(t));const T4=e=>{const[{indexes:t,datum:n,width:r=200,height:i,gap:o=4,showIcon:s=!0,iconSize:a=30,iconType:l="default",positionH:c="normal",positionV:u="normal",usePaletteColor:h=!1,themeColors:f},d]=lt(e,["width","height","gap","showIcon","iconSize","iconType","usePaletteColor"]),{label:p,desc:g,icon:m}=n,b=(N=>N==="normal"?"left":N==="flipped"?"right":"center")(c),_=h?f.colorPrimary:f.colorText,x=14,w=1.4,P=ae(y(Ve,{indexes:t,width:r,alignHorizontal:"center",alignVertical:"middle",fill:_,children:p})),O=s?l==="circle"?y(zr,{indexes:t,size:a,fill:f.colorPrimary,colorBg:f.colorBg}):y(Ft,{indexes:t,size:a,fill:f.colorTextSecondary}):null;if(!s||!m){const N=i?Math.max(0,i-P.height-o):void 0,H=N?N<=60?1:Math.floor(N/(w*x)):2,D=i?u==="middle"?(i-P.height-(N||0)-o)/2:u==="flipped"?i-P.height-(N||0)-o:0:0;return k(Y,cf(lf({},d),{children:[y(Ve,{indexes:t,width:r,y:D,alignHorizontal:b,alignVertical:"middle",fill:_,children:p}),y(ft,{indexes:t,width:r,height:N,y:D+P.height+o,alignHorizontal:b,alignVertical:A(),lineNumber:H,fill:f.colorTextSecondary,children:g})]}))}if(c==="center"){const N=s&&m?a:0,H=i?Math.max(0,i-P.height-N-o*2):void 0,D=H?H<=60?1:Math.floor(H/(w*x)):2,B=P.height+(H||0)+o,F=i?u==="middle"?(i-B-N-o)/2:u==="flipped"?i-B-N-o:0:0;return y(ve,cf(lf({},d),{flexDirection:"column",gap:o,alignItems:"center",children:u==="flipped"?k(tt,{children:[k(Y,{children:[y(Ve,{indexes:t,width:r,y:F,alignHorizontal:"center",alignVertical:"middle",fill:_,children:p}),y(ft,{indexes:t,width:r,height:H,y:F+P.height+o,alignHorizontal:"center",alignVertical:"bottom",lineNumber:D,fill:f.colorTextSecondary,children:g})]}),O]}):k(tt,{children:[O,k(Y,{children:[y(Ve,{indexes:t,width:r,y:F,alignHorizontal:"center",alignVertical:"middle",fill:_,children:p}),y(ft,{indexes:t,width:r,height:H,y:F+P.height+o,alignHorizontal:"center",alignVertical:"top",lineNumber:D,fill:f.colorTextSecondary,children:g})]})]})}))}const $=ae(O),S=Math.max(r-$.width-o,0),M=i?Math.max(0,i-P.height-o):void 0,I=M?M<=60?1:Math.floor(M/(w*x)):2,E=i?u==="middle"?(i-P.height-(M||0)-o)/2:u==="flipped"?i-P.height-(M||0)-o:0:0;return y(ve,cf(lf({},d),{flexDirection:"row",gap:o,alignItems:T(u),children:c==="flipped"?k(tt,{children:[k(Y,{children:[y(Ve,{indexes:t,width:S,y:E,alignHorizontal:"right",alignVertical:"middle",fill:_,children:p}),y(ft,{indexes:t,width:S,height:M,y:E+P.height+o,alignHorizontal:"right",alignVertical:A(),lineNumber:I,fill:f.colorTextSecondary,children:g})]}),O]}):k(tt,{children:[O,k(Y,{children:[y(Ve,{indexes:t,width:S,y:E,alignHorizontal:"left",alignVertical:"middle",fill:_,children:p}),y(ft,{indexes:t,width:S,height:M,y:E+P.height+o,alignHorizontal:"left",alignVertical:A(),lineNumber:I,fill:f.colorTextSecondary,children:g})]})]})}));function A(N,H){return"top"}function T(N){return N==="normal"?"flex-start":N==="flipped"?"flex-end":"center"}};ct("simple",{component:T4,composites:["icon","label","desc"]});var WK=Object.defineProperty,VK=Object.defineProperties,GK=Object.getOwnPropertyDescriptors,R4=Object.getOwnPropertySymbols,YK=Object.prototype.hasOwnProperty,XK=Object.prototype.propertyIsEnumerable,k4=(e,t,n)=>t in e?WK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,UK=(e,t)=>{for(var n in t||(t={}))YK.call(t,n)&&k4(e,n,t[n]);if(R4)for(var n of R4(t))XK.call(t,n)&&k4(e,n,t[n]);return e},KK=(e,t)=>VK(e,GK(t));const L4=e=>{const[{indexes:t,datum:n,height:r=140,themeColors:i,positionH:o="normal"},s]=lt(e,["height"]),a=o==="normal"?"right":"left",l=y(Ve,{indexes:t,width:120,fill:i.colorText,alignHorizontal:a,alignVertical:"middle",fontSize:14,children:n.label}),c=y(ft,{indexes:t,width:120,fill:i.colorTextSecondary,alignHorizontal:a,alignVertical:"top",children:n.desc}),u=o!=="flipped",h=15,f=30,d=120,p=d+h+f+h+d;return y(Y,KK(UK({width:p,height:r},s),{children:k(ve,{flexDirection:"row",alignItems:"center",children:[u?k(tt,{children:[k(ve,{flexDirection:"column",alignItems:"flex-end",children:[l,c]}),y(yt,{width:h})]}):y(tt,{children:y(yt,{width:d+h})}),k(Pi,{horizontal:"center",vertical:"middle",children:[y(ZK,{width:f,height:r,fill:i.colorPrimary}),y(Ne,{width:f,height:r,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:String(t[0]+1).padStart(2,"0").slice(-2)})]}),u?y(tt,{children:y(yt,{width:d+h})}):k(tt,{children:[y(yt,{width:h}),k(ve,{flexDirection:"column",alignItems:"flex-start",children:[l,c]})]})]})}))},ZK=e=>{const{x:t=0,y:n=0,width:r=30,height:i=100,fill:o="#FF356A",size:s=10}=e;return y(Yt,{width:r,height:i,points:[{x:t,y:n},{x:t+r/2,y:n+s},{x:t+r,y:n},{x:t+r,y:n+i-s},{x:t+r/2,y:n+i},{x:t,y:n+i-s}],fill:o,"data-element-type":"shape"})};ct("simple-vertical-arrow",{component:L4,composites:["label","desc"]});var QK=Object.defineProperty,JK=Object.defineProperties,eZ=Object.getOwnPropertyDescriptors,N4=Object.getOwnPropertySymbols,tZ=Object.prototype.hasOwnProperty,nZ=Object.prototype.propertyIsEnumerable,z4=(e,t,n)=>t in e?QK(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,rZ=(e,t)=>{for(var n in t||(t={}))tZ.call(t,n)&&z4(e,n,t[n]);if(N4)for(var n of N4(t))nZ.call(t,n)&&z4(e,n,t[n]);return e},iZ=(e,t)=>JK(e,eZ(t));const uf=80,hf=3,D4=e=>{const[{datum:t,indexes:n,width:r=200,gap:i=4,positionH:o="center",themeColors:s},a]=lt(e,["width","height","gap"]),l=ae(y(Ve,{indexes:n,fontSize:18,fontWeight:"bold",width:r,children:t.label})),c=t.desc?ae(y(ft,{indexes:n,width:r,wordWrap:!0,children:t.desc})):{height:0},u=l.height+i+hf+(t.desc?i*2+c.height:0),h=0,f=0,d=o==="center"?"center":o==="flipped"?"right":"left",p=o==="center"?(r-uf)/2:o==="flipped"?r-uf:0,g=f+l.height+i,m=0,v=g+hf+i*2;return k(Y,iZ(rZ({width:r,height:u},a),{children:[t.label&&y(Ve,{indexes:n,x:h,y:f,width:r,alignHorizontal:d,fill:s.colorPrimary,fontSize:18,fontWeight:"bold",children:t.label}),t.label&&y(ke,{x:p,y:g,width:uf,height:hf,fill:s.colorPrimary,"data-element-type":"shape"}),t.desc&&y(ft,{indexes:n,width:r,x:m,y:v,alignHorizontal:d,wordWrap:!0,fill:s.colorText,children:t.desc})]}))};ct("underline-text",{component:D4,composites:["label","desc"]});var oZ=Object.defineProperty,sZ=Object.defineProperties,aZ=Object.getOwnPropertyDescriptors,q4=Object.getOwnPropertySymbols,lZ=Object.prototype.hasOwnProperty,cZ=Object.prototype.propertyIsEnumerable,H4=(e,t,n)=>t in e?oZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,uZ=(e,t)=>{for(var n in t||(t={}))lZ.call(t,n)&&H4(e,n,t[n]);if(q4)for(var n of q4(t))cZ.call(t,n)&&H4(e,n,t[n]);return e},hZ=(e,t)=>sZ(e,aZ(t));const j4=e=>{const[{indexes:t,datum:n,height:r=140,themeColors:i,positionH:o="normal"},s]=lt(e,["height"]),l=o!=="flipped"?"right":"left",c=y(Ve,{indexes:t,width:120,fill:i.colorText,alignHorizontal:l,alignVertical:"middle",fontSize:14,children:n.label}),u=y(ft,{indexes:t,width:120,fill:i.colorTextSecondary,alignHorizontal:l,alignVertical:"top",children:n.desc}),h=y(zr,{indexes:t,fill:i.colorPrimary,colorBg:i.colorWhite}),f=y(dZ,{width:30,height:8,fill:i.colorPrimary,positionH:o}),d=o!=="flipped",p=5,g=25,m=30,v=ae(c),b=ae(h),_=ae(f),x=v.width+p+_.width-b.width-g,w=Math.max(v.width+p+_.width,g+b.width)*2+m;return y(Y,hZ(uZ({width:w,height:r},s),{children:k(ve,{flexDirection:"row",alignItems:"center",children:[d?k(tt,{children:[k(ve,{flexDirection:"column",alignItems:"flex-end",children:[c,u]}),y(yt,{width:p}),f]}):k(tt,{children:[y(yt,{width:x}),h,y(yt,{width:g})]}),k(Pi,{horizontal:"center",vertical:"middle",children:[y(fZ,{width:m,height:r,fill:i.colorPrimary}),y(Ne,{width:m,height:r,alignHorizontal:"center",alignVertical:"middle",fill:i.colorWhite,fontWeight:"bold",fontSize:16,children:String(t[0]+1).padStart(2,"0").slice(-2)})]}),d?k(tt,{children:[y(yt,{width:g}),h]}):k(tt,{children:[f,y(yt,{width:p}),k(ve,{flexDirection:"column",alignItems:"flex-start",children:[c,u]})]})]})}))},fZ=e=>{const{x:t=0,y:n=0,width:r=30,height:i=100,fill:o="#FF356A",size:s=10}=e;return y(Yt,{width:r,height:i,points:[{x:t,y:n},{x:t+r/2,y:n+s},{x:t+r,y:n},{x:t+r,y:n+i-s},{x:t+r/2,y:n+i},{x:t,y:n+i-s}],fill:o,"data-element-type":"shape"})},dZ=e=>{const{x:t=0,y:n=0,width:r=50,height:i=10,fill:o,positionH:s="normal"}=e,a=i/2,l=r-a,c=2,u=a;return k(Y,{x:t,y:n,width:r,height:i,children:[y(Ze,{width:i,height:i,fill:o,x:s==="normal"?0:l-a,"data-element-type":"shape"}),y(Ce,{d:s==="normal"?`M${a},${u} L${a+l},${u}`:`M0,${u} L${l-a},${u}`,strokeWidth:c,stroke:o,"data-element-type":"shape"})]})};ct("vertical-icon-arrow",{component:j4,composites:["icon","label","desc"]});const ff=new Map;function We(e,t){ff.set(e,t)}function F4(e){return ff.get(e)}function pZ(){return Array.from(ff.keys())}const B4=e=>{var t,n,r;const{Title:i,Item:o,data:s,width:a,gap:l,barGap:c,barHeight:u=28,barAreaWidth:h,labelGap:f=16,padding:d=24,showValue:p=!0,options:g,valueFormatter:m=je=>je.toString()}=e,v=(t=h!=null?h:a)!=null?t:480,{title:b,desc:_,items:x=[],xTitle:w,yTitle:C}=s,P=i?y(i,{title:b,desc:_}):null;if(x.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:P});const[O,$,S,M]=Lr(d),I=(n=x[0])!=null?n:{label:"",value:0},E=ae(y(o,{indexes:[0],datum:I,data:s})),A=E.width||140,T=E.height||u,N=Math.max(u,T),H=Math.max(12,N*.35),D=(r=c!=null?c:l)!=null?r:H,B=x.map(je=>{var Fe;return(Fe=je.value)!=null?Fe:0}),F=Math.max(...B,0),X=Math.min(...B,0),G=X<0?X*1.1:0;let L=F>0?F*1.1:0;L===G&&(L=G+1);const R=Bo().domain([G,L]).range([0,v]),z=Math.min(Math.max(R(0),0),v),q=Math.max(2,v*.02),j=x.length*(N+D)-D,V=C?24:0,U=20,K=w?24:0,ne=O+V,J=M+A+f,se=p?80:0,Z=Math.max(8,N*.2),te=J+v+se+$,ue=ne+j+Z+U+K+S,re=Et(g.themeConfig),ee=re.colorText||"#666",oe=Ot(g),ie=[],le=[],pe=[],he=[],ge=[],fe=[],xe=[],$e=ne+j+Z,Ie=je=>Number.isInteger(je)?je.toString():je.toFixed(1);x.forEach((je,Fe)=>{var ye;const we=[Fe],Ae=(ye=je.value)!=null?ye:0,Ee=ne+Fe*(N+D),ce=Ee+(N-u)/2,me=Ae>=0?J+z:J+R(Ae),Oe=Ae>=0?R(Ae)-z:z-R(Ae),Ye=Oe===0?q:Oe,rt=He(g,[Fe])||re.colorPrimary;if(ie.push(y(ke,{x:me,y:ce,width:Ye,height:u,fill:rt,rx:6,ry:6,"data-element-type":"shape"})),p){const Se=Ae>=0?me+Ye+8:me-8;le.push(y(Ne,{x:Se,y:ce+u/2,alignHorizontal:Ae>=0?"left":"right",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:rt,children:m(Ae,je)}))}pe.push(y(o,{indexes:we,datum:je,data:s,x:M,y:Ee+(N-T)/2,width:A,height:T,positionV:"middle"}))});const Pe=Math.max(3,Math.min(7,Math.floor(v/80)));return R.ticks(Pe).forEach(je=>{const Fe=J+R(je);fe.push(y(Ce,{d:`M${Fe} ${ne} L${Fe} ${ne+j}`,stroke:ee,strokeOpacity:.08,"data-element-type":"shape"})),ge.push(y(Ce,{d:`M${Fe-.5} ${$e} L${Fe-.5} ${$e+6}`,stroke:ee,"data-element-type":"shape"})),ge.push(y(Ne,{x:Fe,y:$e+14,alignHorizontal:"center",alignVertical:"middle",fontSize:12,fill:ee,children:Ie(je)}))}),he.push(y(Ce,{d:`M${J} ${$e} L${J+v} ${$e}`,stroke:ee,"data-element-type":"shape"})),G<0&&he.push(y(ke,{x:J+z-.5,y:ne,width:1,height:j,fill:oe,"data-element-type":"shape"})),C&&xe.push(y(Ne,{x:M+A/2,y:O+V/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:ee,children:C})),w&&xe.push(y(Ne,{x:J+v/2,y:$e+U+K/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:ee,children:w})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[P,k(Y,{width:te,height:ue,children:[y(Y,{children:fe}),y(Y,{children:ie}),y(Y,{children:le}),y(Y,{children:xe}),y(Y,{children:[...he,...ge]}),y(ze,{children:pe})]})]})};We("chart-bar",{component:B4,composites:["title","item","xTitle","yTitle"]});const W4=e=>{const{Title:t,Item:n,data:r,columnGap:i=60,columnWidth:o=50,padding:s=20,showValue:a=!0,options:l,valueFormatter:c=B=>B.toString()}=e,{title:u,desc:h,items:f=[]}=r,d=t?y(t,{title:u,desc:h}):null;if(f.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:d});const p=Et(l.themeConfig),m=[...f.map(B=>{var F;return(F=B.value)!=null?F:0}),0].sort((B,F)=>B-F),v=m[0]<0,b=f.length*o+(f.length-1)*i,_=300,[x,w,C,P]=Lr(s),O=a?24:0,$=10,S=v&&a?O+$:$,M=b+P+w,I=_+x+C+S,E=Bo().domain([m[0],m[m.length-1]]).range([_,0]),A=E(0),T=[],N=[],H=[],D=[];return f.forEach((B,F)=>{var X;const G=[F],L=(X=B.value)!=null?X:0,R=P+F*(o+i),z=L>=0?E(L):A,q=Math.abs(E(L)-A),j=He(l,[F])||p.colorPrimary,V=`${j}-column-positive-${F}`,U=`${j}-column-negative-${F}`;D.push(k("linearGradient",{id:L>=0?V:U,x1:"0%",y1:L>=0?"0%":"100%",x2:"0%",y2:L>=0?"100%":"0%",children:[y("stop",{offset:"0%",stopColor:j}),y("stop",{offset:"100%",stopColor:be.mix(j,"#fff",40).toHexString()})]})),T.push(y(ke,{x:R,y:x+z,width:o,height:q,fill:`url(#${L>=0?V:U})`,rx:8,ry:8,"data-element-type":"shape"})),a&&N.push(y(Ne,{x:R+o/2,y:L>=0?x+z-10:x+z+q+20,fontSize:16,fontWeight:"bold",alignHorizontal:"center",alignVertical:L>=0?"bottom":"top",fill:j,children:c(L,B)}));const K=o+i,ne=x+_+S;H.push(y(n,{indexes:G,datum:B,data:r,x:R+o/2-K/2,y:ne,width:K,positionH:"center"}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,k(Y,{width:M,height:I,children:[y(Ke,{children:D}),y(Y,{children:T}),y(Y,{children:N}),y(ze,{children:H})]})]})};We("chart-column",{component:W4,composites:["title","item"]});var gZ=Object.defineProperty,mZ=Object.defineProperties,yZ=Object.getOwnPropertyDescriptors,V4=Object.getOwnPropertySymbols,vZ=Object.prototype.hasOwnProperty,bZ=Object.prototype.propertyIsEnumerable,G4=(e,t,n)=>t in e?gZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Y4=(e,t)=>{for(var n in t||(t={}))vZ.call(t,n)&&G4(e,n,t[n]);if(V4)for(var n of V4(t))bZ.call(t,n)&&G4(e,n,t[n]);return e},_Z=(e,t)=>mZ(e,yZ(t));const X4=e=>{const{Title:t,Item:n,data:r,width:i,height:o=260,gap:s=10,padding:a=24,showValue:l=!0,options:c,valueFormatter:u=ce=>ce.toString()}=e,{title:h,desc:f,items:d=[],xTitle:p,yTitle:g}=r,m=t?y(t,{title:h,desc:f}):null;if(d.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:m});const[v,b,_,x]=Lr(a),w={indexes:[0],datum:d[0],data:r,positionH:"center",positionV:"normal"},C=ae(y(n,Y4({},w))),P=C.width,O=C.height,$=Math.max(28,O+14),S=44,M=g?26:0,I=p?22:0,E=P+s,A=d.length>0?(d.length-1)*E+P:0,T=i!==void 0?i:Math.max(200,A||320),N=d.length>1?Math.max(E,(T-P)/(d.length-1)):0,H=d.length>0?Math.max(P,(d.length-1)*N+P):0,D=x+S+M,B=v+M,F=D+H+b,X=B+o+$+I+_,G=d.map(ce=>{var me;return(me=ce.value)!=null?me:0}),L=Math.max(...G,0),R=Math.min(...G,0),z=Math.max(Math.abs(L),Math.abs(R))*.1,q=R<0?R-z:0;let j=L>0?L+z:1;j===q&&(j=q+1);const V=Bo().domain([q,j]).nice().range([o,0]),U=Math.max(0,Math.min(o,V(0))),K=j<=0?0:q>=0?o:U,ne=Ot(c),J=Et(c.themeConfig),se=J.colorText||"#666",Z=[],te=[],ue=[],re=[],ee=[],oe=[],ie=[];V.ticks(6).forEach(ce=>{const me=B+V(ce);Z.push(y(Ce,{d:`M ${D} ${me} L ${D+H} ${me}`,width:H,height:1,stroke:se,strokeWidth:1,"data-element-type":"shape",opacity:.08})),ie.push(y(Ne,{x:D-8,y:me,alignHorizontal:"right",alignVertical:"middle",fontSize:12,fill:se,children:Number.isInteger(ce)?ce.toString():ce.toFixed(1)}))});const pe=[],he=[],ge=[],fe=ce=>{if(ce.length===0)return"";if(ce.length===1){const Oe=ce[0];return`M ${Oe.x} ${Oe.y}`}const me=[];me.push(`M ${ce[0].x} ${ce[0].y}`);for(let Oe=0;Oe<ce.length-1;Oe++){const Ye=ce[Oe-1]||ce[Oe],rt=ce[Oe],Se=ce[Oe+1],Be=ce[Oe+2]||Se,Qe=rt.x+(Se.x-Ye.x)/6,Je=rt.y+(Se.y-Ye.y)/6,Xe=Se.x-(Be.x-rt.x)/6,pt=Se.y-(Be.y-rt.y)/6;me.push(`C ${Qe} ${Je} ${Xe} ${pt} ${Se.x} ${Se.y}`)}return me.join(" ")};d.forEach((ce,me)=>{var Oe;const Ye=D+me*N+P/2,rt=B+V((Oe=ce.value)!=null?Oe:0);he.push({x:Ye,y:rt,datum:ce}),pe.push(y(n,_Z(Y4({},w),{indexes:[me],datum:ce,x:Ye-P/2,y:B+o+4})));const Se=He(c,[me])||J.colorPrimary;ge.push({x:Ye,color:Se})});const xe=ge.length>0?Math.min(...ge.map(ce=>ce.x)):D,$e=ge.length>0?Math.max(...ge.map(ce=>ce.x)):D+H,Ie=Math.max(1,$e-xe),Pe=ge.map(ce=>y("stop",{offset:`${(ce.x-xe)/Ie*100}%`,stopColor:ce.color})),Le=ge.map(ce=>y("stop",{offset:`${(ce.x-xe)/Ie*100}%`,stopColor:ce.color,stopOpacity:"0.18"}));if(ge.length>0){const ce=ge[ge.length-1].color;Pe.push(y("stop",{offset:"100%",stopColor:ce})),Le.push(y("stop",{offset:"100%",stopColor:ce,stopOpacity:"0.04"}))}const je=`chart-line-${T_([H,o,se,ne,ge.map(ce=>`${ce.x.toFixed(2)}-${ce.color}`).join()].join(":"))}`,Fe=`${je}-stroke`,ye=`${je}-area`,we=fe(he);ue.push(y(Ce,{d:we,width:H,height:o,stroke:`url(#${Fe})`,strokeWidth:3,fill:"none","data-element-type":"shape"}));const Ae=we.includes("C")?we.slice(we.indexOf("C")):"",Ee=[`M ${he[0].x} ${B+K}`,`L ${he[0].x} ${he[0].y}`,Ae,`L ${he[he.length-1].x} ${B+K}`,"Z"].join(" ");return ue.push(y(Ce,{d:Ee,width:H,height:o,fill:`url(#${ye})`,stroke:"none","data-element-type":"shape"})),he.forEach((ce,me)=>{var Oe;const Ye=He(c,[me])||J.colorPrimary;re.push(y(Ze,{x:ce.x-6,y:ce.y-6,width:12,height:12,fill:Ye,"data-element-type":"shape"})),l&&ee.push(y(Ne,{x:ce.x,y:ce.y-12,alignHorizontal:"center",alignVertical:"bottom",fontSize:12,fontWeight:"bold",fill:Ye,children:u((Oe=ce.datum.value)!=null?Oe:0,ce.datum)}))}),te.push(y(Ce,{d:`M ${D} ${B+K} L ${D+H} ${B+K}`,width:H,height:1,stroke:se,strokeWidth:1,"data-element-type":"shape"})),te.push(y(Ce,{d:`M ${D} ${B} L ${D} ${B+o}`,width:1,height:o,stroke:se,strokeWidth:1,"data-element-type":"shape"})),p&&oe.push(y(Ne,{x:D+H/2,y:B+o+$+I/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:se,children:p})),g&&oe.push(y(Ne,{x:x+M/2,y:B+o/2,alignHorizontal:"center",alignVertical:"middle",fontSize:14,fontWeight:"bold",fill:se,children:g})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[m,k(Y,{width:F,height:X,children:[k(Ke,{children:[y("linearGradient",{id:Fe,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:Pe}),k("linearGradient",{id:ye,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[Le,y("stop",{offset:"100%",stopColor:ne,stopOpacity:"0.04"})]})]}),y(Y,{children:Z}),y(Y,{children:[...te,...ie]}),y(Y,{children:ue}),y(Y,{children:re}),y(Y,{children:ee}),y(Y,{children:oe}),y(ze,{children:pe})]})]})};We("chart-line",{component:X4,composites:["title","item","xTitle","yTitle"]});const U4=e=>{var t;const{Title:n,Item:r,data:i,radius:o=140,innerRadius:s=0,padding:a=30,showPercentage:l=!0,options:c}=e,{title:u,desc:h,items:f=[]}=i,d=n?y(n,{title:u,desc:h}):null,p=ae(y(Q,{indexes:[0]})),g=(t=f[0])!=null?t:{label:"",value:0},m=ae(y(r,{indexes:[0],datum:g,data:i,positionH:"center",positionV:"middle"})),v=m.width||140,b=m.height||32,_=Math.max(o,60),x=1.35,w=8,C=_*x+w+v,P=_,O=a+C,$=a+P,S=O*2,M=$*2;if(f.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,y(Y,{width:S,height:M,children:y(qe,{children:y(Q,{indexes:[0],x:O-p.width/2,y:$-p.height/2})})})]});const I=f.reduce((V,U)=>{var K;return V+Math.max((K=U.value)!=null?K:0,0)},0),E=Ot(c),A=Et(c.themeConfig),N=LU().value(V=>{var U;return Math.max((U=V.value)!=null?U:0,0)}).sort(null).startAngle(0).endAngle(Math.PI*2)(f),H=Vo().innerRadius(s).outerRadius(_).cornerRadius(2),D=Vo().innerRadius(_).outerRadius(_),B=Vo().innerRadius(_*1.15).outerRadius(_*1.15),F=s+(_-s)*.5,X=Vo().innerRadius(F).outerRadius(F),G=Vo().innerRadius(_*.85).outerRadius(_*.85),L=[],R=[],z=[],q=[],j=[];return N.forEach(V=>{const U=V.data,K=V.index,ne=He(c,[K])||A.colorPrimary||E,J=H(V)||"";L.push(y(Ce,{d:J,fill:ne,stroke:A.colorBg,strokeWidth:1,"data-element-type":"shape",width:_*2,height:_*2}));const Z=V.startAngle+(V.endAngle-V.startAngle)/2<Math.PI,te=D.centroid(V),ue=B.centroid(V),ee=[_*x*(Z?1:-1),ue[1]];z.push(y(Ce,{d:`M${O+te[0]} ${$+te[1]} L${O+ue[0]} ${$+ue[1]} L${O+ee[0]} ${$+ee[1]}`,stroke:E,strokeOpacity:.45,strokeWidth:2,fill:"none","data-element-type":"shape"}));const oe=O+ee[0]+(Z?w:-w-v),ie=$+ee[1]-b/2;if(q.push(y(r,{indexes:[K],datum:U,data:i,x:oe,y:ie,width:v,height:b,positionH:Z?"normal":"flipped",positionV:"middle",themeColors:Et({colorPrimary:ne},c)})),l&&I>0){const pe=X.centroid(V),he=Math.max(V.value,0),ge=(he*100/I).toFixed(1),fe=50,xe=20;R.push(y(Ne,{x:O+pe[0]-fe/2,y:$+pe[1]-xe/2,width:fe,height:xe,alignHorizontal:"center",alignVertical:"middle",fontSize:12,fontWeight:"bold",fill:"#ffffff","data-value":he,"data-indexes":[K],"data-element-type":Ge.ItemValue,children:`${ge}%`}))}const le=G.centroid(V);j.push(y(nt,{indexes:[K],x:O+le[0]-p.width/2,y:$+le[1]-p.height/2}))}),N.forEach((V,U)=>{const K=(U+1)%N.length,ne=V.endAngle,J=N[K].startAngle+(K===0?Math.PI*2:0),se=(ne+J)/2,Z=_*1,te=Math.sin(se)*Z,ue=-Math.cos(se)*Z;j.push(y(Q,{indexes:[U+1],x:O+te-p.width/2,y:$+ue-p.height/2}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[d,k(Y,{width:S,height:M,children:[y(Y,{x:O,y:$,children:L}),y(Y,{children:z}),y(Y,{children:R}),y(ze,{children:q}),y(qe,{children:j})]})]})};We("chart-pie",{component:U4,composites:["title","item"]});var wZ=Object.defineProperty,xZ=Object.defineProperties,CZ=Object.getOwnPropertyDescriptors,K4=Object.getOwnPropertySymbols,PZ=Object.prototype.hasOwnProperty,OZ=Object.prototype.propertyIsEnumerable,Z4=(e,t,n)=>t in e?wZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Q4=(e,t)=>{for(var n in t||(t={}))PZ.call(t,n)&&Z4(e,n,t[n]);if(K4)for(var n of K4(t))OZ.call(t,n)&&Z4(e,n,t[n]);return e},J4=(e,t)=>xZ(e,CZ(t));const SZ=[0,30,-30,60,-60],$Z=Math.PI*(3-Math.sqrt(5));function e5(e,t,n){const r=Math.PI/180*n,i=Math.cos(r),o=Math.sin(r);return{width:Math.abs(e*i)+Math.abs(t*o),height:Math.abs(e*o)+Math.abs(t*i)}}function EZ(e,t,n,r,i,o){const s=e-o,a=e+n+o,l=t-o,c=t+r+o;return i.some(u=>{const h=u.box.x-o,f=u.box.x+u.box.width+o,d=u.box.y-o,p=u.box.y+u.box.height+o;return!(a<=h||s>=f||c<=d||l>=p)})}function MZ(e,t,n,r,i){const o=[],s=t?SZ:[0],a=Math.max(1600,e.length*28);return e.forEach((l,c)=>{const u=Math.max(l.width,l.height),h=c*$Z;let f=0,d=null;for(let p=0;p<a&&!d;p++){p===Math.floor(a*.6)&&(f=u);const g=h+p*r,m=i*Math.sqrt(p+1)+f+u*.25,v=m*Math.cos(g),b=m*Math.sin(g);for(const _ of s){const x=e5(l.width,l.height,_),w=v-x.width/2,C=b-x.height/2;if(!EZ(w,C,x.width,x.height,o,n)){d=J4(Q4({},l),{angle:_,centerX:v,centerY:b,box:{x:w,y:C,width:x.width,height:x.height}});break}}}if(!d){const p=s[c%s.length],g=i*Math.sqrt(a+1)+u,m=h,v=g*Math.cos(m),b=g*Math.sin(m),_=e5(l.width,l.height,p);d=J4(Q4({},l),{angle:p,centerX:v,centerY:b,box:{x:v-_.width/2,y:b-_.height/2,width:_.width,height:_.height}})}o.push(d)}),o}const t5=e=>{const{data:t,options:n,minFontSize:r=16,maxFontSize:i=48,enableRotate:o=!0,padding:s=6,spiralStep:a=.45,radiusStep:l=10}=e,{items:c=[]}=t,u=c.map((E,A)=>({datum:E,index:A})).filter(({datum:E})=>E.label);if(u.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:y(Y,{children:y(ze,{})})});const h=u.map(({datum:E})=>E.value).filter(E=>typeof E=="number"),f=h.length>0,d=f?Math.min(...h):0,p=f?Math.max(...h):0,g=f&&d===p,m=(r+i)/2,v=E=>{if(!f||g)return m;if(E==null)return r;const A=(E-d)/(p-d||1);return r+A*(i-r)},b=u.map(({datum:E,index:A})=>{const T=v(E.value),N=ae(y(Ne,{fontSize:T,fontWeight:"bold",children:E.label})),H=He(n,[A])||Ot(n);return{label:E.label,value:E.value,color:H,fontSize:T,width:N.width*1.05,height:N.height}}).sort((E,A)=>A.fontSize-E.fontSize),_=MZ(b,o,s,a,l),x=Math.min(..._.map(E=>E.box.x)),w=Math.min(..._.map(E=>E.box.y)),C=Math.max(..._.map(E=>E.box.x+E.box.width)),P=Math.max(..._.map(E=>E.box.y+E.box.height)),O=-x+s,$=-w+s,S=C-x+s*2,M=P-w+s*2,I=_.map((E,A)=>{const T=E.centerX-E.width/2+O,N=E.centerY-E.height/2+$,H=E.width/2,D=E.height/2,B=`translate(${T}, ${N}) rotate(${E.angle}, ${H}, ${D})`;return y(Y,{transform:B,children:y(Ne,{width:E.width,height:E.height,fontSize:E.fontSize,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:E.color,"data-indexes":A,"data-element-type":Ge.ItemLabel,children:E.label})})});return y(ze,{id:"infographic-container",width:S,height:M,children:I})};We("chart-wordcloud",{component:t5,composites:[]});const n5=new Map,df=(e,t)=>{n5.set(e,t)},IZ=e=>{var t;return e&&(t=n5.get(e))!=null?t:null};var AZ=Object.defineProperty,TZ=Object.defineProperties,RZ=Object.getOwnPropertyDescriptors,r5=Object.getOwnPropertySymbols,kZ=Object.prototype.hasOwnProperty,LZ=Object.prototype.propertyIsEnumerable,i5=(e,t,n)=>t in e?AZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,o5=(e,t)=>{for(var n in t||(t={}))kZ.call(t,n)&&i5(e,n,t[n]);if(r5)for(var n of r5(t))LZ.call(t,n)&&i5(e,n,t[n]);return e},s5=(e,t)=>TZ(e,RZ(t));df("pros-cons-arrow",e=>{const{x:t,y:n,colorPositive:r,colorNegative:i,colorBg:o}=e,s=200,a=141,l={width:90,height:40,fontSize:22,alignHorizontal:"center",alignVertical:"middle",fontWeight:"bold",fill:o};return k(Y,{x:t,y:n,width:s,height:a,children:[k(Pt,{children:[y("path",{d:"M137 54C137 54.2903 137 54.5806 136.706 54.7742L108.614 86.0323H64.7619C64.4071 86.0204 64.0557 86.1043 63.7453 86.2747C63.4349 86.4452 63.1773 86.6959 63 87C63.0037 86.7447 63.1092 86.5012 63.2936 86.3226L91.3862 55.0645H135.238C135.593 55.0763 135.944 54.9925 136.255 54.822C136.565 54.6516 136.823 54.4009 137 54.0968V54Z",fill:"#D9D9D9"}),y("path",{d:"M39.3272 0.484649C39.6146 0.234929 39.9662 0.0736935 40.3407 0.0198929C40.7152 -0.0339076 41.0971 0.0219605 41.4414 0.180925C41.7857 0.33989 42.0783 0.595358 42.2846 0.917314C42.491 1.23927 42.6026 1.61434 42.6063 1.99848V14.8156H136.013C136.54 14.8156 137.045 15.0282 137.418 15.4068C137.791 15.7853 138 16.2987 138 16.834V53.166C138 53.7013 137.791 54.2147 137.418 54.5932C137.045 54.9718 136.54 55.1844 136.013 55.1844H42.6063V68.0015C42.6026 68.3857 42.491 68.7607 42.2846 69.0827C42.0783 69.4046 41.7857 69.6601 41.4414 69.8191C41.0971 69.9781 40.7152 70.0339 40.3407 69.9801C39.9662 69.9263 39.6146 69.7651 39.3272 69.5154L0.672847 36.5138C0.461378 36.3244 0.292014 36.0915 0.176005 35.8305C0.0599968 35.5695 0 35.2864 0 35C0 34.7136 0.0599968 34.4306 0.176005 34.1696C0.292014 33.9085 0.461378 33.6756 0.672847 33.4862L39.4265 0.484649H39.3272Z",fill:r}),y("path",{d:"M157.394 73.0007C157.397 72.6162 157.509 72.2407 157.715 71.9183C157.922 71.596 158.214 71.3403 158.559 71.1811C158.903 71.022 159.285 70.9661 159.659 71.0199C160.034 71.0738 160.385 71.2352 160.673 71.4852L199.327 104.524C199.539 104.714 199.708 104.947 199.824 105.208C199.94 105.47 200 105.753 200 106.04C200 106.326 199.94 106.61 199.824 106.871C199.708 107.132 199.539 107.366 199.327 107.555L160.573 140.594C160.285 140.815 159.943 140.951 159.584 140.989C159.225 141.027 158.862 140.965 158.535 140.809C158.208 140.653 157.929 140.41 157.728 140.105C157.527 139.8 157.411 139.445 157.394 139.078V126.247H63.9874C63.4603 126.247 62.9548 126.034 62.5821 125.655C62.2094 125.276 62 124.762 62 124.226V87.8531C62 87.3172 62.2094 86.8032 62.5821 86.4242C62.9548 86.0453 63.4603 85.8324 63.9874 85.8324H157.394V73.0007Z",fill:i})]}),y(Ne,s5(o5({x:40,y:15},l),{children:"Pros"})),y(Ne,s5(o5({x:70,y:85},l),{children:"Cons"}))]})});var NZ=Object.defineProperty,zZ=Object.defineProperties,DZ=Object.getOwnPropertyDescriptors,a5=Object.getOwnPropertySymbols,qZ=Object.prototype.hasOwnProperty,HZ=Object.prototype.propertyIsEnumerable,l5=(e,t,n)=>t in e?NZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,c5=(e,t)=>{for(var n in t||(t={}))qZ.call(t,n)&&l5(e,n,t[n]);if(a5)for(var n of a5(t))HZ.call(t,n)&&l5(e,n,t[n]);return e},u5=(e,t)=>zZ(e,DZ(t));df("pros-cons-fold",e=>{const{x:t,y:n,colorPositive:r,colorNegative:i,colorBg:o}=e,s=240,a=300,l={width:85,height:30,fontSize:20,alignHorizontal:"center",alignVertical:"middle",fontWeight:"bold",fill:o};return k(Y,{x:t,y:n,width:s,height:a,children:[k(Pt,{children:[y("path",{d:"M136.914 38.7755C137.303 38.7733 137.683 38.6617 138.011 38.4534C138.339 38.2451 138.602 37.9485 138.77 37.5977C138.937 37.247 139.002 36.8561 138.957 36.4701C138.913 36.084 138.76 35.7183 138.517 35.415L110.741 0.982313C110.548 0.735138 110.301 0.535238 110.018 0.397762C109.736 0.260286 109.426 0.188841 109.112 0.188841C108.798 0.188841 108.488 0.260286 108.206 0.397762C107.924 0.535238 107.676 0.735138 107.483 0.982313L79.7069 35.415C79.4639 35.7183 79.3113 36.084 79.2667 36.4701C79.222 36.8561 79.2871 37.247 79.4545 37.5977C79.6219 37.9485 79.8847 38.2451 80.213 38.4534C80.5412 38.6617 80.9216 38.7733 81.3104 38.7755H92.8965C93.0517 57.1293 97.5517 64.9878 105.259 73.7252C107.017 75.7932 108.983 77.8612 111.103 80.1361C113.276 82.4626 122.121 88.9252 131.069 95.181C129.362 88.7701 128.172 81.2218 127.293 73.7252C125.224 55.9918 125.017 38.7755 125.017 38.7755H136.914Z",fill:r,fillOpacity:.4}),y("path",{d:"M237.931 109.967C238.48 109.967 239.006 109.749 239.394 109.362C239.782 108.974 240 108.448 240 107.899V75.7932C240 75.2447 239.782 74.7187 239.394 74.3309C239.006 73.9431 238.48 73.7252 237.931 73.7252H127.241C128.172 81.2218 129.362 88.7701 131.069 95.181C138.182 100.171 145.337 105.1 152.534 109.967H237.931Z",fill:r}),y("path",{d:"M152.586 109.967C152.586 109.967 141.724 102.678 131.069 95.181C124.122 90.5838 117.455 85.5772 111.103 80.1878C109.034 77.8612 107.017 75.7415 105.259 73.7252H48.6207V56.6639C48.6091 56.2797 48.4905 55.9063 48.2784 55.5857C48.0662 55.2651 47.7689 55.0099 47.4197 54.8488C47.0705 54.6878 46.6833 54.6271 46.3016 54.6738C45.9199 54.7204 45.5587 54.8725 45.2586 55.1129L1.50002 90.2694C1.26208 90.4633 1.07029 90.7078 0.938585 90.985C0.80688 91.2622 0.738558 91.5652 0.738558 91.8721C0.738558 92.179 0.80688 92.482 0.938585 92.7592C1.07029 93.0365 1.26208 93.2809 1.50002 93.4748L45.2586 128.631C45.5621 128.874 45.928 129.027 46.3142 129.071C46.7005 129.116 47.0914 129.051 47.4424 128.884C47.7933 128.716 48.09 128.454 48.2984 128.125C48.5068 127.797 48.6185 127.417 48.6207 127.029V109.967H152.586Z",fill:"#BFBFBF"}),y("path",{d:"M36.1034 88.9252H28.9655V93.785H36.1034V101.85H41.4828V93.785H48.6207V88.8735H41.4828V81.1701H36.1034V88.9252Z",fill:"#404040"}),y("path",{d:"M103.086 261.224C102.697 261.227 102.317 261.338 101.989 261.547C101.661 261.755 101.398 262.051 101.23 262.402C101.063 262.753 100.998 263.144 101.043 263.53C101.087 263.916 101.24 264.282 101.483 264.585L129.259 299.018C129.452 299.265 129.699 299.465 129.982 299.602C130.264 299.74 130.574 299.811 130.888 299.811C131.202 299.811 131.512 299.74 131.794 299.602C132.076 299.465 132.324 299.265 132.517 299.018L160.293 264.585C160.536 264.282 160.689 263.916 160.733 263.53C160.778 263.144 160.713 262.753 160.546 262.402C160.378 262.051 160.115 261.755 159.787 261.547C159.459 261.338 159.078 261.227 158.69 261.224H147.103C146.948 242.871 142.448 235.012 134.741 226.275C132.983 224.207 131.017 222.139 128.897 219.864C126.724 217.537 117.879 211.075 108.931 204.819C110.677 211.877 111.938 219.045 112.707 226.275C114.776 244.008 114.983 261.224 114.983 261.224H103.086Z",fill:i,fillOpacity:.4}),y("path",{d:"M2.06897 190.033C1.52025 190.033 0.993996 190.251 0.605989 190.638C0.217983 191.026 5.00679e-06 191.552 5.00679e-06 192.101V224.207C5.00679e-06 224.755 0.217983 225.281 0.605989 225.669C0.993996 226.057 1.52025 226.275 2.06897 226.275H112.759C111.828 218.778 110.638 211.23 108.931 204.819C99.9827 198.512 90.931 192.411 88.2414 190.55C87.7206 190.204 87.1077 190.024 86.4828 190.033H2.06897Z",fill:i}),y("path",{d:"M87.4138 190.033C87.4138 190.033 98.2759 197.322 108.931 204.819C115.878 209.416 122.545 214.423 128.897 219.812C130.966 222.139 132.983 224.258 134.741 226.275H191.379V243.336C191.391 243.72 191.51 244.094 191.722 244.414C191.934 244.735 192.231 244.99 192.58 245.151C192.929 245.312 193.317 245.373 193.698 245.326C194.08 245.28 194.441 245.128 194.741 244.887L238.5 209.731C238.738 209.537 238.93 209.292 239.061 209.015C239.193 208.738 239.261 208.435 239.261 208.128C239.261 207.821 239.193 207.518 239.061 207.241C238.93 206.964 238.738 206.719 238.5 206.525L194.741 171.369C194.438 171.126 194.072 170.973 193.686 170.929C193.3 170.884 192.909 170.949 192.558 171.116C192.207 171.284 191.91 171.546 191.702 171.875C191.493 172.203 191.382 172.583 191.379 172.971V190.033H87.4138Z",fill:"#BFBFBF"}),y("path",{d:"M192.414 205.905V210.816H212.069V205.905H192.414Z",fill:"#404040"})]}),y(Ne,u5(c5({x:153,y:77},l),{children:"PROS"})),y(Ne,u5(c5({x:2,y:193},l),{children:"CONS"}))]})}),df("vs",e=>{const{x:t,y:n,colorPrimary:r,colorBg:i}=e,o=100,s=100,a=be(r).lighten(20).toString();return k(Y,{x:t,y:n,width:o,height:s,children:[k(Ke,{children:[y("filter",{id:"vs-divider-glow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",children:y("feGaussianBlur",{in:"SourceGraphic",stdDeviation:"8",result:"blur"})}),y(Oh,{})]}),y(Ze,{x:0,y:0,width:o,height:s,fill:a,filter:"url(#vs-divider-glow-filter)",opacity:.6}),y(Ze,{x:0,y:0,width:o,height:s,fill:r,"data-element-type":"shape"}),y("text",{x:o/2,y:s/2,fontSize:Math.min(o,s)/1.5,fontWeight:"bold",fill:i,textAnchor:"middle",dominantBaseline:"central",filter:"url(#drop-shadow)",children:"VS"})]})});const h5=e=>{const{Title:t,Item:n,data:r,gap:i=20,groupGap:o=20,opposite:s=!0,flipped:a=!0,dividerType:l="vs",options:c}=e,{title:u,desc:h,items:f=[]}=r,d=t?y(t,{title:u,desc:h}):null;if(f.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const p=f[0]||{children:[]},g=f[1]||{children:[]},m=p.children||[],v=g.children||[],b=Et(c.themeConfig),_=ae(y(n,{indexes:[0,0],data:r,datum:m[0]||{}})),x=ae(y(Q,{indexes:[0]})),w=IZ(l),C=w?ae(y(w,{x:0,y:0,colorPrimary:b.colorPrimary,colorBg:b.colorBg,colorPositive:b.colorPrimary,colorNegative:b.colorPrimary})):{width:0,height:0},P=[],O=[],$=[],S=Math.max(m.length,v.length),M=S>0?S*(_.height+i)-i:0,I=5,E=S>0?i/2+x.height/2:x.height/2,A=x.width+I,T=A+_.width+o,N=T+C.width+o,H=a?"flipped":"normal",D=a?"normal":s?"flipped":"normal";if(m.forEach((B,F)=>{const X=E+F*(_.height+i),G=[0,F];P.push(y(n,{indexes:G,datum:B,data:r,x:A,y:X,positionH:H,positionV:"middle"})),O.push(y(nt,{indexes:G,x:A-x.width-I,y:X+(_.height-x.height)/2})),F<m.length-1&&O.push(y(Q,{indexes:[0,F+1],x:A+(_.width-x.width)/2,y:X+_.height+i/2-x.height/2}))}),m.length>0){O.push(y(Q,{indexes:[0,0],x:A+(_.width-x.width)/2,y:E-i/2-x.height/2}));const B=E+(m.length-1)*(_.height+i);O.push(y(Q,{indexes:[0,m.length],x:A+(_.width-x.width)/2,y:B+_.height+i/2-x.height/2}))}else f.length>=1&&O.push(y(Q,{indexes:[0,0],x:A+(_.width-x.width)/2,y:E-x.height/2}));if(v.forEach((B,F)=>{const X=E+F*(_.height+i),G=[1,F];P.push(y(n,{indexes:G,datum:B,data:r,x:N,y:X,positionH:D,positionV:"middle"})),O.push(y(nt,{indexes:G,x:N+_.width+I,y:X+(_.height-x.height)/2})),F<v.length-1&&O.push(y(Q,{indexes:[1,F+1],x:N+(_.width-x.width)/2,y:X+_.height+i/2-x.height/2}))}),v.length>0){O.push(y(Q,{indexes:[1,0],x:N+(_.width-x.width)/2,y:E-i/2-x.height/2}));const B=E+(v.length-1)*(_.height+i);O.push(y(Q,{indexes:[1,v.length],x:N+(_.width-x.width)/2,y:B+_.height+i/2-x.height/2}))}else f.length>=2&&O.push(y(Q,{indexes:[1,0],x:N+(_.width-x.width)/2,y:E-x.height/2}));return f.length<2&&O.push(y(Q,{indexes:[1],x:N+(_.width-x.width)/2,y:E+(M-x.height)/2})),w&&$.push(y(w,{x:T,y:E+(M-C.height)/2,colorPrimary:b.colorPrimary,colorBg:b.colorBg,colorPositive:He(c,[0])||b.colorPrimary,colorNegative:He(c,[1])||b.colorPrimary})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,k(Y,{children:[y(Y,{children:$}),y(ze,{children:P}),y(qe,{children:O})]})]})};We("compare-binary-horizontal",{component:h5,composites:["title","item"]});var jZ=Object.defineProperty,f5=Object.getOwnPropertySymbols,FZ=Object.prototype.hasOwnProperty,BZ=Object.prototype.propertyIsEnumerable,d5=(e,t,n)=>t in e?jZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,p5=(e,t)=>{for(var n in t||(t={}))FZ.call(t,n)&&d5(e,n,t[n]);if(f5)for(var n of f5(t))BZ.call(t,n)&&d5(e,n,t[n]);return e};const WZ={none:5,"dot-line":100,"arc-dot":20,"split-line":5},g5=e=>{var t,n;const{Title:r,Items:i,data:o,gap:s=20,groupGap:a=0,decoration:l="none",surround:c=!0,flipRoot:u=!1,flipLeaf:h=!1,options:f}=e,[d,p]=i,{title:g,desc:m,items:v=[]}=o,b=r?y(r,{title:g,desc:m}):null,_=y(d,{indexes:[0],data:o,datum:o.items[0],themeColors:{}}),x=y(p,{indexes:[0,0],data:o,datum:((n=(t=v[0])==null?void 0:t.children)==null?void 0:n[0])||v[2]}),w=ae(_),C=ae(x),P=[],O=[],[$,S]=v,M=($==null?void 0:$.children)||[],I=(S==null?void 0:S.children)||[],E=Math.max(w.height,M.length*(C.height+s)-s,I.length*(C.height+s)-s),A=WZ[l]||0,T=C.width+A,N=T+w.width+a,H=(E-w.height)/2;$&&P.push(y(d,{indexes:[0],x:T,y:H,data:o,datum:$,positionH:u?"normal":"flipped"})),S&&P.push(y(d,{indexes:[1],x:N,y:H,data:o,datum:S,positionH:u?"flipped":"normal"}));const D=(B,F,X)=>{if(l==="none")return;const[G,L]=F,R=He(f,X),z={x:G,y:L,width:C.width,height:C.height,side:B,color:R||"#ccc",colorBg:f.themeConfig.colorBg||"#fff"};l==="split-line"?O.push(y(VZ,p5({},z))):l==="dot-line"&&O.push(y(GZ,p5({},z)))};if(c){const F=(2*w.width+a+C.width)/2+A,X=T+w.width+a/2,G=H+w.height/2;M.forEach((L,R)=>{const z=M.length*(C.height+s)-s,j=(E-z)/2+R*(C.height+s),U=j+C.height/2-G,K=Math.max(0,F*F-U*U),J=X-Math.sqrt(K)-C.width/2;P.push(y(p,{indexes:[0,R],datum:L,data:o,x:J,y:j,positionH:h?"flipped":"normal"})),D("left",[J,j],[0,R])}),I.forEach((L,R)=>{const z=I.length*(C.height+s)-s,j=(E-z)/2+R*(C.height+s),U=j+C.height/2-G,K=Math.max(0,F*F-U*U),J=X+Math.sqrt(K)-C.width/2;P.push(y(p,{indexes:[1,R],datum:L,data:o,x:J,y:j,positionH:h?"normal":"flipped"})),D("right",[J,j],[1,R])})}else M.forEach((B,F)=>{const X=M.length*(C.height+s)-s,L=(E-X)/2+F*(C.height+s),R=[0,F],z=0;P.push(y(p,{indexes:R,datum:B,data:o,x:z,y:L,positionH:h?"flipped":"normal"})),D("left",[z,L],R)}),I.forEach((B,F)=>{const X=I.length*(C.height+s)-s,L=(E-X)/2+F*(C.height+s),R=[1,F],z=N+w.width+A;P.push(y(p,{indexes:R,datum:B,data:o,x:z,y:L,positionH:h?"normal":"flipped"})),D("right",[z,L],R)});return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[b,k(Y,{children:[y(ze,{children:P}),y(Y,{width:0,height:0,children:O})]})]})},VZ=e=>{const{x:t,y:n,width:r,height:i,color:o,colorBg:s,side:a}=e,l=n+i,c=`split-line-linear-gradient-${a}`;return k(tt,{children:[y(Ke,{children:y(Sh,{id:c,startColor:o,stopColor:s,direction:a==="left"?"left-right":"right-left"})}),y(ke,{x:t,y:l,width:r,height:1,fill:`url(#${c})`})]})},GZ=e=>{const{x:t,y:n,side:r,width:i,height:o,color:s,colorBg:a}=e,l=6,c=l/3,u=l*2,h=c*2,f=5,d=r==="left"?t+i+l+f:t-l-f,p=n+o/2,g=d-c,m=p-c,v=80,b=r==="left"?v:-v,_=`dot-line-linear-gradient-${r}`;return k(Y,{children:[y(Ke,{children:y(Sh,{id:_,startColor:s,stopColor:a,direction:r==="left"?"left-right":"right-left"})}),k(Pt,{children:[y(Ze,{x:d-l,y:p-l,width:u,height:u,fill:"none",strokeWidth:1,stroke:s}),y(Ze,{x:g,y:m,width:h,height:h,fill:s})]}),y(ke,{x:r==="left"?d:d+b,y:p-.5,width:v,height:1,fill:`url(#${_})`})]})};We("compare-hierarchy-left-right",{component:g5,composites:["title","item"]});const m5=e=>{var t,n;const{Title:r,Items:i,data:o,gap:s=0,itemGap:a=20,columnWidth:l=280,itemPadding:c=5,showColumnBackground:u=!0,columnBackgroundAlpha:h=.08,options:f}=e,[d,p]=i,{title:g,desc:m,items:v=[]}=o,b=r?y(r,{title:g,desc:m}):null,_=Uw(f),x=[],w=[],C=l-c*2,P=ae(y(d,{indexes:[0],data:o,datum:v[0],width:l})),O=ae(y(p,{indexes:[0,0],data:o,datum:((n=(t=v[0])==null?void 0:t.children)==null?void 0:n[0])||{},width:C})),$=ae(y(Q,{indexes:[0]})),S=Math.max(...v.map(I=>{var E;return((E=I.children)==null?void 0:E.length)||0}),0),M=P.height+a+S*(O.height+a);if(v.forEach((I,E)=>{const{children:A=[]}=I,T=E*(l+s),N=T,H=0;if(u){const X=`${_[E%_.length]}${Math.round(h*255).toString(16).padStart(2,"0")}`;x.push(y(ke,{x:T,y:H,width:l,height:M,fill:X,rx:0,ry:0,"data-element-type":"shape"}))}x.push(y(d,{indexes:[E],datum:I,data:o,x:N,y:H,width:l})),w.push(y(nt,{indexes:[E],x:N+P.width-$.width-10,y:H+10})),E===0&&w.push(y(Q,{indexes:[E],x:N+P.width/2-$.width/2,y:H-$.height-5}));const D=H+P.height+a;A.forEach((F,X)=>{const G=D+X*(O.height+a),L=N+c,R=[E,X];x.push(y(p,{indexes:R,datum:F,data:o,x:L,y:G,width:C})),w.push(y(nt,{indexes:R,x:L+O.width-$.width-10,y:G+(O.height-$.height)/2})),X<A.length-1&&w.push(y(Q,{indexes:[E,X+1],x:L+O.width/2-$.width/2,y:G+O.height-$.height/2}))});const B=N+c;if(A.length>0){const F=D+A.length*(O.height+a);w.push(y(Q,{indexes:[E,A.length],x:B+O.width/2-$.width/2,y:F-O.height/2-$.height/2}))}else w.push(y(Q,{indexes:[E,0],x:B+O.width/2-$.width/2,y:D-a/2-$.height/2}))}),v.length>0){const I=v.length*(l+s);w.push(y(Q,{indexes:[v.length],x:I-s/2-$.width/2,y:-$.height-5}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[b,k(Y,{children:[y(ze,{children:x}),y(qe,{children:w})]})]})};We("compare-hierarchy-row",{component:m5,composites:["title","item"]});const pf={axisColor:"#D9D9D9",axisArrowSize:5,strokeWidth:1,dashArray:"4,2",defaultExtraSpacing:20},y5=e=>{const{Title:t,Item:n,data:r,quadrantWidth:i,quadrantHeight:o,showAxis:s=!0,dashedAxis:a=!0}=e,{title:l,desc:c,items:u=[]}=r,h=t?y(t,{title:l,desc:c}):null,f=Array.from({length:4},(_,x)=>u[x]),d=f[0]?ae(y(n,{indexes:[0],data:r,datum:f[0]})):{width:0,height:0},p=i!=null?i:d.width+pf.defaultExtraSpacing,g=o!=null?o:d.height+pf.defaultExtraSpacing,m=XZ(p,g,d),v=f.map((_,x)=>{if(!_)return null;const w=m[x];return y(n,{indexes:[x],datum:_,data:r,x:w.x,y:w.y,positionH:x%2?"flipped":"normal",positionV:x<2?"normal":"flipped"})}).filter(Boolean),b=YZ(p,g,s,a);return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[h,k(Y,{width:p*2,height:g*2,children:[b,y(ze,{children:v})]})]})};function YZ(e,t,n,r){if(!n)return[];const{axisColor:i,axisArrowSize:o,strokeWidth:s,dashArray:a}=pf,l=e,c=t,u=e*2,h=t*2,f=r?a:void 0;return[y(Ce,{d:`M 0 ${c} L ${u} ${c}`,stroke:i,strokeWidth:s,strokeDasharray:f,fill:"none","data-element-type":"shape"}),k(Pt,{transform:`translate(${u}, ${c})`,children:[y(Ce,{d:`M 0 0 L ${-o} ${-o/2}`,stroke:i,strokeWidth:s,fill:"none"}),y(Ce,{d:`M 0 0 L ${-o} ${o/2}`,stroke:i,strokeWidth:s,fill:"none"})]}),k(Pt,{transform:`translate(0, ${c})`,children:[y(Ce,{d:`M 0 0 L ${o} ${-o/2}`,stroke:i,strokeWidth:s,fill:"none"}),y(Ce,{d:`M 0 0 L ${o} ${o/2}`,stroke:i,strokeWidth:s,fill:"none"})]}),y(Ce,{d:`M ${l} 0 L ${l} ${h}`,stroke:i,strokeWidth:s,strokeDasharray:f,fill:"none","data-element-type":"shape"}),k(Pt,{transform:`translate(${l}, 0)`,children:[y(Ce,{d:`M 0 0 L ${-o/2} ${o}`,stroke:i,strokeWidth:s,fill:"none"}),y(Ce,{d:`M 0 0 L ${o/2} ${o}`,stroke:i,strokeWidth:s,fill:"none"})]}),k(Pt,{transform:`translate(${l}, ${h})`,children:[y(Ce,{d:`M 0 0 L ${-o/2} ${-o}`,stroke:i,strokeWidth:s,fill:"none"}),y(Ce,{d:`M 0 0 L ${o/2} ${-o}`,stroke:i,strokeWidth:s,fill:"none"})]})]}function XZ(e,t,n){const r=e/2,i=t/2;return[{x:r-n.width/2,y:i-n.height/2},{x:e+r-n.width/2,y:i-n.height/2},{x:r-n.width/2,y:t+i-n.height/2},{x:e+r-n.width/2,y:t+i-n.height/2}]}We("quadrant",{component:y5,composites:["title","item"]});const gf=Object.assign,UZ={getId:e=>e.id||e.name,getPreH:e=>e.preH||0,getPreV:e=>e.preV||0,getHGap:e=>e.hgap||18,getVGap:e=>e.vgap||18,getChildren:e=>e.children,getHeight:e=>e.height||36,getWidth(e){const t=e.label||" ";return e.width||18*t.split("").length}};let v5=class iM{constructor(t,n){if(this.x=0,this.y=0,this.depth=0,this.children=[],this.hgap=0,this.vgap=0,t instanceof iM||"x"in t&&"y"in t&&"children"in t){const o=t;return this.data=o.data,this.id=o.id,this.x=o.x,this.y=o.y,this.width=o.width,this.height=o.height,this.depth=o.depth,this.children=o.children,this.parent=o.parent,this.hgap=o.hgap,this.vgap=o.vgap,this.preH=o.preH,void(this.preV=o.preV)}this.data=t;const r=n.getHGap(t),i=n.getVGap(t);this.preH=n.getPreH(t),this.preV=n.getPreV(t),this.width=n.getWidth(t),this.height=n.getHeight(t),this.width+=this.preH,this.height+=this.preV,this.id=n.getId(t),this.addGap(r,i)}isRoot(){return this.depth===0}isLeaf(){return this.children.length===0}addGap(t,n){this.hgap+=t,this.vgap+=n,this.width+=2*t,this.height+=2*n}eachNode(t){let n,r=[this];for(;n=r.shift();)t(n),r=n.children.concat(r)}DFTraverse(t){this.eachNode(t)}BFTraverse(t){let n,r=[this];for(;n=r.shift();)t(n),r=r.concat(n.children)}getBoundingBox(){const t={left:Number.MAX_VALUE,top:Number.MAX_VALUE,width:0,height:0};return this.eachNode(n=>{t.left=Math.min(t.left,n.x),t.top=Math.min(t.top,n.y),t.width=Math.max(t.width,n.x+n.width),t.height=Math.max(t.height,n.y+n.height)}),t}translate(t=0,n=0){this.eachNode(r=>{r.x+=t,r.y+=n,r.x+=r.preH,r.y+=r.preV})}right2left(){const t=this.getBoundingBox();this.eachNode(n=>{n.x=n.x-2*(n.x-t.left)-n.width}),this.translate(t.width,0)}bottom2top(){const t=this.getBoundingBox();this.eachNode(n=>{n.y=n.y-2*(n.y-t.top)-n.height}),this.translate(0,t.height)}};function mf(e,t={},n){t=gf({},UZ,t);const r=new v5(e,t),i=[r];let o;if(!n&&!e.collapsed){for(;o=i.shift();)if(!o.data.collapsed){const s=t.getChildren(o.data),a=s?s.length:0;if(o.children=new Array(a),s&&a)for(let l=0;l<a;l++){const c=new v5(s[l],t);o.children[l]=c,i.push(c),c.parent=o,c.depth=o.depth+1}}}return r}let KZ=class{constructor(t,n={}){this.options=n,this.rootNode=mf(t,n)}execute(){throw new Error("please override this method")}};function ZZ(e,t){const n=mf(e.data,t,!0),r=mf(e.data,t,!0),i=e.children.length,o=Math.round(i/2),s=t.getSide||function(a,l){return l<o?"right":"left"};for(let a=0;a<i;a++){const l=e.children[a];s(l,a)==="right"?r.children.push(l):n.children.push(l)}return n.eachNode(a=>{a.isRoot()||(a.side="left")}),r.eachNode(a=>{a.isRoot()||(a.side="right")}),{left:n,right:r}}const gr=["LR","RL","TB","BT","H","V"],QZ=["LR","RL","H"],JZ=gr[0];function eQ(e,t,n){const r=t.direction||JZ;if(t.isHorizontal=(o=>QZ.indexOf(o)>-1)(r),gr.indexOf(r)===-1)throw new TypeError(`Invalid direction: ${r}`);if(r===gr[0])n(e,t);else if(r===gr[1])n(e,t),e.right2left();else if(r===gr[2])n(e,t);else if(r===gr[3])n(e,t),e.bottom2top();else if(r===gr[4]||r===gr[5]){const{left:o,right:s}=ZZ(e,t);n(o,t),n(s,t),t.isHorizontal?o.right2left():o.bottom2top(),s.translate(o.x-s.x,o.y-s.y),e.x=o.x,e.y=s.y;const a=e.getBoundingBox();t.isHorizontal?a.top<0&&e.translate(0,-a.top):a.left<0&&e.translate(-a.left,0)}let i=t.fixedRoot;return i===void 0&&(i=!0),i&&e.translate(-(e.x+e.width/2+e.hgap),-(e.y+e.height/2+e.vgap)),(function(o,s){if(s.radial){const[a,l]=s.isHorizontal?["x","y"]:["y","x"],c={x:1/0,y:1/0},u={x:-1/0,y:-1/0};let h=0;o.DFTraverse(p=>{h++;const{x:g,y:m}=p;c.x=Math.min(c.x,g),c.y=Math.min(c.y,m),u.x=Math.max(u.x,g),u.y=Math.max(u.y,m)});const f=u[l]-c[l];if(f===0)return;const d=2*Math.PI/h;o.DFTraverse(p=>{const g=p[l],m=c[l],v=p[a],b=o[a],_=(g-m)/f*(2*Math.PI-d)+d,x=v-b;p.x=Math.cos(_)*x,p.y=Math.sin(_)*x})}})(e,t),e}function b5(e,t){let n=0;return e.children.length?e.children.forEach(r=>{n+=b5(r,t)}):n=e.height,e._subTreeSep=t.getSubTreeSep(e.data),e.totalHeight=Math.max(e.height,n)+2*e._subTreeSep,e.totalHeight}function _5(e){const t=e.children,n=t.length;if(n){t.forEach(a=>{_5(a)});const r=t[0],i=t[n-1],o=i.y-r.y+i.height;let s=0;if(t.forEach(a=>{s+=a.totalHeight}),o>e.height)e.y=r.y+o/2-e.height/2;else if(t.length!==1||e.height>s){const a=e.y+(e.height-o)/2-r.y;t.forEach(l=>{l.translate(0,a)})}else e.y=(r.y+r.height/2+i.y+i.height/2)/2-e.height/2}}const tQ={getSubTreeSep:()=>0};function nQ(e,t={}){return t=gf({},tQ,t),e.parent={x:0,width:0,height:0,y:0},e.BFTraverse(n=>{n.x=n.parent.x+n.parent.width}),e.parent=void 0,b5(e,t),e.startY=0,e.y=e.totalHeight/2-e.height/2,e.eachNode(n=>{const r=n.children,i=r.length;if(i){const o=r[0];if(o.startY=n.startY+n._subTreeSep,i===1)o.y=n.y+n.height/2-o.height/2;else{o.y=o.startY+o.totalHeight/2-o.height/2;for(let s=1;s<i;s++){const a=r[s];a.startY=r[s-1].startY+r[s-1].totalHeight,a.y=a.startY+a.totalHeight/2-a.height/2}}}}),_5(e),e}class rQ extends KZ{execute(){return eQ(this.rootNode,this.options,nQ)}}const iQ={};function oQ(e,t){const n=gf({},iQ,t);return new rQ(e,n).execute()}var sQ=Object.defineProperty,aQ=Object.defineProperties,lQ=Object.getOwnPropertyDescriptors,w5=Object.getOwnPropertySymbols,cQ=Object.prototype.hasOwnProperty,uQ=Object.prototype.propertyIsEnumerable,x5=(e,t,n)=>t in e?sQ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hQ=(e,t)=>{for(var n in t||(t={}))cQ.call(t,n)&&x5(e,n,t[n]);if(w5)for(var n of w5(t))uQ.call(t,n)&&x5(e,n,t[n]);return e},fQ=(e,t)=>aQ(e,lQ(t));const dQ=60,pQ=14,C5=30,P5="center",gQ="curved",mQ=2,yQ="node",vQ="solid",O5=(e,t=[],n=0)=>{var r,i;const o=[...t,n];return fQ(hQ({},e),{_indexes:o,children:(i=(r=e.children)==null?void 0:r.map((s,a)=>O5(s,o,a)))!=null?i:[]})},S5=(e,t,n,r)=>{var i,o;t.push(e),(o=(i=e.data)._flatIndex)!=null||(i._flatIndex=t.length-1),r&&n.push({parent:r,child:e});const s=e.children;s==null||s.forEach(a=>S5(a,t,n,e))},bQ=(e,t,n,r)=>{const i=Math.abs(n-e)/2,o=n>e?e+i:e-i,s=n>e?n-i:n+i;return`M ${e} ${t} C ${o} ${t} ${s} ${r} ${n} ${r}`},_Q=(e,t,n,r)=>`M ${e} ${t} L ${n} ${r}`,wQ=(e,t,n,r=P5)=>{const i=c=>Math.max(0,Math.min(1,c)),s=(c=>c==="top"?0:c==="bottom"?1:c==="center"?.5:i(c))(r),a=e.y+e.height*s,l=t.y+t.height*s;return n==="left"?{sx:e.x,sy:a,tx:t.x+t.width,ty:l}:{sx:e.x+e.width,sy:a,tx:t.x,ty:l}},$5=e=>{var t,n;const{Title:r,Items:i,data:o,levelGap:s=dQ,nodeGap:a=pQ,edgeAlign:l=P5,colorMode:c=yQ,edgeColorMode:u=vQ,edgeType:h=gQ,edgeWidth:f=mQ,options:d}=e,{title:p,desc:g,items:m=[]}=o,v=r?y(r,{title:p,desc:g}):null,b=Ot(d),_=ae(y(Q,{indexes:[0]})),x=new Map;let w=0;if(!m.length||!(i!=null&&i.length))return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,y(Y,{children:y(Q,{indexes:[0],x:0,y:0})})]});const C=O5(m[0]),P=new WeakMap,O=new WeakMap,$=new WeakMap,S=(q,j)=>{var V;if(c==="group"){const U=String((V=q.group)!=null?V:"");let K=x.get(U);return K==null&&(K=w,x.set(U,K),w+=1),[K]}return Kw({depth:j,originalIndexes:q._indexes,flatIndex:q._flatIndex},c)},M=(q,j)=>{const V=$.get(q);if(V)return V;const U=S(q,j),K=He(d,U),ne=Et({colorPrimary:K},d);return $.set(q,ne),O.set(q,K),ne},I=q=>{const j=P.get(q);if(j)return j;const V=Math.max(q._indexes.length-1,0),U=La(i,V),K=ae(y(U,{indexes:q._indexes,data:o,datum:q,positionH:"center",positionV:"middle",themeColors:M(q,V)}));return P.set(q,K),K},E=oQ(C,{direction:"H",getSide:(q,j)=>{if(!q.parent)return"right";const V=(q.parent.children||[]).indexOf(q);return(V>=0?V:j)%2===0?"left":"right"},getWidth:q=>I(q).width,getHeight:q=>I(q).height,getHGap:()=>s,getVGap:()=>a}),A=[],T=[];S5(E,A,T);const N=A.length>0?Math.min(...A.map(q=>q.x)):0,H=A.length>0?Math.min(...A.map(q=>q.y)):0,D=C5-N,B=C5-H,F=[],X=[],G=[],L=[],R=new WeakMap;A.forEach(q=>{var j,V;const U=q.data,K=I(U),ne=q.x+D+((j=q.hgap)!=null?j:0),J=q.y+B+((V=q.vgap)!=null?V:0),se=La(i,q.depth),Z=q.depth===0?"center":q.side==="left"?"flipped":"normal",te=M(U,q.depth);G.push(y(se,{indexes:U._indexes,data:o,datum:U,x:ne,y:J,positionH:Z,positionV:"middle",themeColors:te})),R.set(q,{x:ne,y:J,width:K.width,height:K.height,centerX:ne+K.width/2,centerY:J+K.height/2})}),T.forEach(q=>{var j,V,U,K;const{parent:ne,child:J}=q,se=R.get(J),Z=R.get(ne);if(!se||!Z)return;const te=J.data,{sx:ue,sy:re,tx:ee,ty:oe}=wQ(Z,se,J.side,l),ie=(j=O.get(te))!=null?j:He(d,S(te,J.depth)),le=(V=O.get(ne.data))!=null?V:He(d,S(ne.data,ne.depth)),pe=h==="straight"?_Q(ue,re,ee,oe):bQ(ue,re,ee,oe),he=`edge-gradient-${te._indexes.join("-")}`;X.push(y(Ce,{d:pe,stroke:u==="gradient"?`url(#${he})`:ie!=null?ie:b,strokeWidth:f,fill:"none"})),u==="gradient"&&F.push(k("linearGradient",{id:he,gradientUnits:"userSpaceOnUse",x1:ue,y1:re,x2:ee,y2:oe,children:[y("stop",{offset:"0%",stopColor:le!=null?le:b}),y("stop",{offset:"100%",stopColor:ie!=null?ie:b})]}));const ge=(K=(U=te.children)==null?void 0:U.length)!=null?K:0,fe=[...te._indexes,ge],xe=se.x+(se.width-_.width)/2,$e=se.y+se.height+8,Ie=$e+_.height+6;J.depth>0&&L.push(y(nt,{indexes:te._indexes,x:xe,y:$e})),L.push(y(Q,{indexes:fe,x:xe,y:Ie}))});const z=R.get(E);if(z){const q=E.data,j=(n=(t=q.children)==null?void 0:t.length)!=null?n:0,V=[...q._indexes,j],U=z.x+(z.width-_.width)/2,K=z.y+z.height+8+_.height+6;L.push(y(Q,{indexes:V,x:U,y:K}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,k(Y,{children:[F.length>0?y(Ke,{children:F}):null,y(Y,{children:X}),y(ze,{children:G}),y(qe,{children:L})]})]})};We("hierarchy-mindmap",{component:$5,composites:["title","item"]});const Ai=(e,t)=>{if(e[0]!=="#"||e.length!==7)return e;const n=Math.max(0,Math.min(1,t)),r=Math.round(n*255).toString(16).padStart(2,"0");return`${e}${r}`},Ti=e=>e==null?"":String(e),ul=(e,t,n)=>ae(y(Ne,{fontSize:t,fontWeight:n,children:e})),xQ=(e,t,n,r=" ")=>{const i=ul(r,t,n);let o=i.width,s=i.height;return e.forEach(a=>{const l=ul(a||" ",t,n);o=Math.max(o,l.width),s=Math.max(s,l.height)}),{width:o,height:s}},E5=(e,t,n,r)=>{const i=xQ(e,t,"normal","Item");return{pillWidth:i.width+n*2,pillHeight:i.height+r*2}},M5=e=>{const{Title:t,data:n,options:r,rowGap:i=20,labelGap:o=20,groupGap:s=20,pillGap:a=14,pillColumns:l=2,ungroupedColumns:c=6,layerLabelPosition:u="left",rowPadding:h=20,groupPadding:f=16,labelPaddingX:d=28,labelPaddingY:p=16,pillPaddingX:g=18,pillPaddingY:m=10,labelFontSize:v=20,groupTitleFontSize:b=18,pillFontSize:_=16,groupTitleGap:x=10,rowRadius:w=12,groupRadius:C=10,pillRadius:P=12}=e,{title:O,desc:$,items:S=[]}=n,M=t?y(t,{title:O,desc:$}):null;if(S.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[M,y(Y,{children:y(ze,{})})]});const I=Et(r.themeConfig),E=[],A=[],T=u==="right",N=.12,H=.55,D=.08,B=.4,F=.06,X=.35,G=S.map(J=>{const se=Ti(J.label),Z=ul(se||" ",v,"bold"),te=Z.width+d*2,ue=Z.height+p*2,re=J.children||[];if(re.some(xe=>{var $e;return((($e=xe.children)==null?void 0:$e.length)||0)>0})){const xe=[];re.forEach(Fe=>{(Fe.children||[]).forEach(ye=>{xe.push(Ti(ye.label))})});const{pillWidth:$e,pillHeight:Ie}=E5(xe,_,g,m),Pe=re.map(Fe=>{const ye=Ti(Fe.label),we=ul(ye||" ",b,"bold"),Ae=Fe.children||[],Ee=Ae.length>0?Math.min(l,Ae.length):0,ce=Ee>0?Math.ceil(Ae.length/Ee):0,me=Ee>0?Ee*$e+(Ee-1)*a:0,Oe=ce>0?ce*Ie+(ce-1)*a:0,rt=Math.max(we.width,me)+f*2,Se=f*2+we.height+(ce>0?x+Oe:0);return{label:ye,children:Ae,width:rt,height:Se,titleHeight:we.height,columns:Ee,contentWidth:me,pillWidth:$e,pillHeight:Ie}}),Le=Pe.reduce((Fe,ye)=>Fe+ye.width,0)+(Pe.length>1?(Pe.length-1)*s:0),je=Pe.reduce((Fe,ye)=>Math.max(Fe,ye.height),0);return{label:se,labelWidth:te,labelHeight:ue,hasGroups:!0,children:re,groupMetrics:Pe,contentInnerWidth:Le,contentInnerHeight:je}}const oe=re.map(xe=>Ti(xe.label)),{pillWidth:ie,pillHeight:le}=E5(oe,_,g,m),pe=re.length>0?Math.min(c,re.length):0,he=pe>0?Math.ceil(re.length/pe):0,ge=pe>0?pe*ie+(pe-1)*a:0,fe=he>0?he*le+(he-1)*a:0;return{label:se,labelWidth:te,labelHeight:ue,hasGroups:!1,children:re,pillWidth:ie,pillHeight:le,columns:pe,contentInnerWidth:ge,contentInnerHeight:fe}}),L=G.reduce((J,se)=>Math.max(J,se.labelWidth),0),R=G.reduce((J,se)=>Math.max(J,se.contentInnerWidth),0),z=J=>{const se=He(r,[J])||I.colorPrimary||"#6c7dff";return{rowFill:Ai(se,N),rowStroke:Ai(se,H),groupFill:Ai(se,D),groupStroke:Ai(se,B),pillFill:Ai(se,F),pillStroke:Ai(se,X)}},q=(J,se,Z,te,ue,re,ee,oe,ie,le,pe,he,ge,fe)=>{E.push(y(ke,{x:Z,y:ee,width:ue,height:oe,fill:ge,stroke:fe,rx:w,ry:w,"data-element-type":"shape"})),E.push(y(ke,{x:ie,y:le,width:pe,height:he,fill:ge,stroke:fe,rx:w,ry:w,"data-element-type":"shape"})),A.push(y(Ne,{x:Z,y:te,width:ue,height:re,fontSize:v,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:I.colorText,"data-element-type":Ge.ItemLabel,"data-indexes":se,children:J}))},j=(J,se,Z,te)=>{const ue=J.groupMetrics||[],re=J.label,ee=[se],oe=L,ie=J.labelHeight,le=J.contentInnerHeight,pe=Math.max(0,R-J.contentInnerWidth),he=ue.length>0?pe/ue.length:0,fe=J.contentInnerWidth+(ue.length>0?pe:0)+h*2,xe=le+h*2,$e=Math.max(ie,xe),Ie=T?0:oe+o,Pe=T?Ie+fe+o:0,Le=Z+($e-ie)/2,je=Z+($e-xe)/2;q(re,ee,Pe,Le,oe,ie,Z,$e,Ie,je,fe,xe,te.rowFill,te.rowStroke);let Fe=Ie+h;return ue.forEach((we,Ae)=>{const Ee=[...ee,Ae],ce=we.width+he,me=je+h+(le-we.height)/2;E.push(y(ke,{x:Fe,y:me,width:ce,height:we.height,fill:te.groupFill,stroke:te.groupStroke,rx:C,ry:C,"data-element-type":"shape"}));const Oe=we.children.length>0,Ye=Oe?me+f:me,rt=Oe?we.titleHeight:we.height,Se=Oe?"top":"middle";if(A.push(y(Ne,{x:Fe+f,y:Ye,width:ce-f*2,height:rt,fontSize:b,fontWeight:"bold",alignHorizontal:"center",alignVertical:Se,fill:I.colorText,"data-element-type":Ge.ItemLabel,"data-indexes":Ee,children:we.label})),we.columns>0){const Be=ce-f*2,Qe=Be-we.contentWidth,Je=Qe>0?Qe/we.columns:0,Xe=we.pillWidth+Je,pt=we.columns*Xe+(we.columns-1)*a,et=(Be-pt)/2,Wt=Fe+f+Math.max(0,et),Gt=me+f+we.titleHeight+x;we.children.forEach((Ue,$t)=>{const Nt=[...Ee,$t],Qt=Math.floor($t/we.columns),qn=$t%we.columns,ii=Wt+qn*(Xe+a),oi=Gt+Qt*(we.pillHeight+a),Hn=Math.min(P,we.pillHeight/2);E.push(y(ke,{x:ii,y:oi,width:Xe,height:we.pillHeight,fill:te.pillFill,stroke:te.pillStroke,rx:Hn,ry:Hn,"data-element-type":"shape"})),A.push(y(Ne,{x:ii,y:oi,width:Xe,height:we.pillHeight,fontSize:_,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:I.colorText,"data-element-type":Ge.ItemLabel,"data-indexes":Nt,children:Ti(Ue.label)}))})}Fe+=ce+s}),{rowWidth:T?Pe+oe:Ie+fe,rowHeight:$e}},V=(J,se,Z,te)=>{const ue=J.label,re=[se],ee=L,oe=J.labelHeight,ie=J.contentInnerHeight,le=Math.max(0,R-J.contentInnerWidth),pe=J.columns||0,he=J.pillWidth||0,ge=J.pillHeight||0,fe=pe>0?le/pe:0,xe=he+fe,Ie=(pe>0?pe*xe+(pe-1)*a:0)+h*2,Pe=ie+h*2,Le=Math.max(oe,Pe),je=T?0:ee+o,Fe=T?je+Ie+o:0,ye=Z+(Le-oe)/2,we=Z+(Le-Pe)/2;if(q(ue,re,Fe,ye,ee,oe,Z,Le,je,we,Ie,Pe,te.rowFill,te.rowStroke),pe>0){const Ee=je+h,ce=we+h;(J.children||[]).forEach((Oe,Ye)=>{const rt=[...re,Ye],Se=Math.floor(Ye/pe),Be=Ye%pe,Qe=Ee+Be*(xe+a),Je=ce+Se*(ge+a),Xe=Math.min(P,ge/2);E.push(y(ke,{x:Qe,y:Je,width:xe,height:ge,fill:te.pillFill,stroke:te.pillStroke,rx:Xe,ry:Xe,"data-element-type":"shape"})),A.push(y(Ne,{x:Qe,y:Je,width:xe,height:ge,fontSize:_,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:I.colorText,"data-element-type":Ge.ItemLabel,"data-indexes":rt,children:Ti(Oe.label)}))})}return{rowWidth:T?Fe+ee:je+Ie,rowHeight:Le}};let U=0,K=0;G.forEach((J,se)=>{const Z=z(se),{rowWidth:te,rowHeight:ue}=J.hasGroups?j(J,se,U,Z):V(J,se,U,Z);K=Math.max(K,te),U+=ue+i});const ne=Math.max(U-i,0);return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[M,k(Y,{width:K,height:ne,children:[y(Y,{children:E}),y(ze,{children:A})]})]})};We("hierarchy-structure",{component:M5,composites:["title"]});var CQ=Object.defineProperty,PQ=Object.defineProperties,OQ=Object.getOwnPropertyDescriptors,I5=Object.getOwnPropertySymbols,SQ=Object.prototype.hasOwnProperty,$Q=Object.prototype.propertyIsEnumerable,A5=(e,t,n)=>t in e?CQ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hl=(e,t)=>{for(var n in t||(t={}))SQ.call(t,n)&&A5(e,n,t[n]);if(I5)for(var n of I5(t))$Q.call(t,n)&&A5(e,n,t[n]);return e},fl=(e,t)=>PQ(e,OQ(t));const T5=(e,t)=>{const n=Math.max(0,t/2-1);return Math.min(e,n)},R5=e=>{const{Title:t,Items:n,data:r,levelGap:i=80,nodeGap:o=60,edgeType:s="straight",edgeColorMode:a="gradient",edgeWidth:l=3,edgeStyle:c="solid",edgeDashPattern:u="5,5",edgeCornerRadius:h=0,edgeOffset:f=0,edgeOrigin:d="center",edgeOriginPadding:p=20,edgeMarker:g="none",markerSize:m=12,colorMode:v="branch",orientation:b="top-bottom",options:_}=e,x=b==="left-right"||b==="right-left",w=b==="bottom-top"||b==="right-left"?-1:1,{title:C,desc:P}=r,O=Ot(_),$=new Map;let S=0;const M=ee=>{var oe;const ie=[...ee];return(oe=ie[0])!=null&&oe.children||(ie[0]=fl(hl({},ie[0]),{children:ie.slice(1)}),ie.splice(1)),ie},I=(ee,oe,ie,le,pe,he="vertical")=>{const ge=he==="vertical",fe=ge?le-oe:ie-ee,xe=ge?ie-ee:le-oe,$e=fe===0?1:Math.sign(fe),Ie=xe===0?1:Math.sign(xe),Pe=ge?oe+fe/2:ee+fe/2,Le=Math.min(pe,Math.abs(fe)/2,Math.abs(xe)/2);return Le===0?ge?`M ${ee} ${oe} L ${ee} ${Pe} L ${ie} ${Pe} L ${ie} ${le}`:`M ${ee} ${oe} L ${Pe} ${oe} L ${Pe} ${le} L ${ie} ${le}`:ge?`M ${ee} ${oe}
|
|
93
|
+
L ${ee} ${Pe-$e*Le}
|
|
94
|
+
Q ${ee} ${Pe} ${ee+Ie*Le} ${Pe}
|
|
95
|
+
L ${ie-Ie*Le} ${Pe}
|
|
96
|
+
Q ${ie} ${Pe} ${ie} ${Pe+$e*Le}
|
|
97
|
+
L ${ie} ${le}`:`M ${ee} ${oe}
|
|
98
|
+
L ${Pe-$e*Le} ${oe}
|
|
99
|
+
Q ${Pe} ${oe} ${Pe} ${oe+Ie*Le}
|
|
100
|
+
L ${Pe} ${le-Ie*Le}
|
|
101
|
+
Q ${Pe} ${le} ${Pe+$e*Le} ${le}
|
|
102
|
+
L ${ie} ${le}`},E=ee=>{const{x:oe,y:ie}=ee;return x?{x:ie*w,y:oe}:{x:oe,y:ie*w}},A=(ee,oe,ie)=>{const{x:le,y:pe}=E(ee),he=le+ie.x,ge=pe+ie.y,fe=ge+oe.height/2;return{centerX:he,centerY:fe,left:he-oe.width/2,right:he+oe.width/2,top:ge,bottom:ge+oe.height}},T=ee=>{var oe;if(!ee.length)return null;const ie=ee[0],le=(pe,he=[],ge=0)=>{var fe,xe;const $e=[...he,ge];return fl(hl({},pe),{_originalIndex:$e,_depth:$e.length-1,children:(xe=(fe=pe.children)==null?void 0:fe.map((Ie,Pe)=>le(Ie,$e,Pe)))!=null?xe:[]})};return(oe=ie.children)!=null&&oe.length?le(ie):fl(hl({},ie),{_originalIndex:[0],_depth:0,children:ee.slice(1).map((pe,he)=>fl(hl({},pe),{_originalIndex:[he+1],_depth:1}))})},N=ee=>{var oe,ie;let le=0,pe=0;const he=new Map,ge=new Map;ee.each(fe=>{ge.has(fe.depth)||ge.set(fe.depth,fe.data)});for(let fe=0;fe<ee.height+1;fe++){const xe=La(n,fe),$e=(oe=ge.get(fe))!=null?oe:{},Ie=(ie=$e._originalIndex)!=null?ie:Array(fe+1).fill(0),Pe=ae(y(xe,{indexes:Ie,data:r,datum:$e,positionH:"center"}));he.set(fe,Pe),le=Math.max(le,Pe.width),pe=Math.max(pe,Pe.height)}return{levelBounds:he,maxWidth:le,maxHeight:pe}},H=(ee,oe)=>{var ie;if(v==="group"){const le=String((ie=ee==null?void 0:ee.group)!=null?ie:"");let pe=$.get(le);return pe==null&&(pe=S,$.set(le,pe),S+=1),[pe]}return Kw({depth:oe,originalIndexes:ee._originalIndex,flatIndex:ee._flatIndex},v)},D=(ee,oe,ie,le,pe,he)=>{const{depth:ge,data:fe,parent:xe}=ee,$e=fe._originalIndex,Ie=La(n,ge),Pe=oe.get(ge),Le=A(ee,Pe,le),je=Le.left,Fe=Le.top,ye={items:[],btns:[],deco:[]},we=H(fe,ge),Ae=He(_,we),Ee=Et({colorPrimary:Ae},_);if(ye.items.push(y(Ie,{indexes:$e,datum:fe,data:r,x:je,y:Fe,positionH:"center",themeColors:Ee})),ye.btns.push(y(nt,{indexes:$e,x:je+(Pe.width-ie.width)/2,y:Fe+Pe.height+5}),y(Q,{indexes:[...$e,0],x:je+(Pe.width-ie.width)/2,y:Fe+Pe.height+ie.height+10})),xe){const ce=oe.get(xe.depth),me=A(xe,ce,le),Oe=he.filter(Ue=>Ue.parent===xe),Ye=Oe.findIndex(Ue=>Ue===ee),rt=Oe.length;let Se,Be;if(d==="distributed"&&rt>1)if(x){const Ue=T5(p,ce.height),$t=me.top+Ue,Qt=(me.bottom-Ue-$t)/rt;Be=$t+Qt*Ye+Qt/2,Se=(w>0?me.right:me.left)+f*w}else{const Ue=T5(p,ce.width),$t=me.left+Ue,Qt=(me.right-Ue-$t)/rt;Se=$t+Qt*Ye+Qt/2,Be=(w>0?me.bottom:me.top)+f*w}else Se=x?(w>0?me.right:me.left)+f*w:me.centerX,Be=x?me.centerY:(w>0?me.bottom:me.top)+f*w;const Qe=x?(w>0?Le.left:Le.right)-f*w:Le.centerX,Je=x?Le.centerY:(w>0?Le.top:Le.bottom)-f*w;let Xe=Qe,pt=Je;g==="arrow"&&(x?Xe-=m*w:pt-=m*w);let et;if(s==="curved")if(x){const Ue=Se+(Xe-Se)/2;et=`M ${Se} ${Be} C ${Ue} ${Be}, ${Ue} ${pt}, ${Xe} ${pt}`}else{const Ue=Be+(pt-Be)/2;et=`M ${Se} ${Be} C ${Se} ${Ue}, ${Xe} ${Ue}, ${Xe} ${pt}`}else if(h>0)et=I(Se,Be,Xe,pt,h,x?"horizontal":"vertical");else if(x){const Ue=Se+(Xe-Se)/2;et=`M ${Se} ${Be} L ${Ue} ${Be} L ${Ue} ${pt} L ${Xe} ${pt}`}else{const Ue=Be+(pt-Be)/2;et=`M ${Se} ${Be} L ${Se} ${Ue} L ${Xe} ${Ue} L ${Xe} ${pt}`}let Wt=O;if(a==="gradient"){const Ue=H(xe.data,xe.depth),$t=H(fe,ge),Nt=He(_,Ue),Qt=He(_,$t),qn=`gradient-${xe.data._originalIndex.join("-")}-${$e.join("-")}`;pe.push(k("linearGradient",{id:qn,x1:Se,y1:Be,x2:Xe,y2:pt,gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0%",stopColor:Nt}),y("stop",{offset:"100%",stopColor:Qt})]})),Wt=`url(#${qn})`}const Gt=c==="dashed"?u:"";if(ye.deco.push(y(Ce,{d:et,stroke:Wt,strokeWidth:l,strokeDasharray:Gt,fill:"none"})),g==="arrow"){const Ue=a==="gradient"?He(_,we):Ot(_),$t=x?[{x:Qe,y:Je},{x:Qe-m*w,y:Je-m/2},{x:Qe-m*w,y:Je+m/2}]:[{x:Qe,y:Je},{x:Qe-m/2,y:Je-m*w},{x:Qe+m/2,y:Je-m*w}];ye.deco.push(y(Yt,{points:$t,fill:Ue,width:m,height:m}))}if(g==="dot"){const Ue=H(xe.data,xe.depth),$t=a==="gradient"?He(_,Ue):Ot(_);ye.deco.push(y(Ze,{x:(x?w>0?me.right+f:me.left-f:Se)-m,y:(x?Be:w>0?me.bottom+f:me.top-f)-m,width:m*2,height:m*2,fill:$t}));const Nt=a==="gradient"?He(_,we):Ot(_);ye.deco.push(y(Ze,{x:Qe-m,y:Je-m,width:m*2,height:m*2,fill:Nt}))}}return ye},B=(ee,oe,ie)=>{const le=new Map;ee.forEach(he=>{var ge;const fe=he.parent?he.parent.data._originalIndex.join("-"):"root";((ge=le.get(fe))!=null?ge:le.set(fe,[]).get(fe)).push(he)});const pe=[];return le.forEach(he=>{if(he.length<=1)return;const ge=he.slice().sort((fe,xe)=>x?E(fe).y-E(xe).y:E(fe).x-E(xe).x);if(ge.length!==0)for(let fe=0;fe<ge.length-1;fe++){const xe=E(ge[fe]),$e=E(ge[fe+1]),Ie=ge[fe].data._originalIndex.slice(0,-1),Pe=ge[fe].data._originalIndex.at(-1)+1;if(x){const Le=xe.x+ie.x+(w>0?-oe.width-5:oe.width+5),je=(xe.y+$e.y)/2+ie.y-oe.height/2;pe.push(y(Q,{indexes:[...Ie,Pe],x:Le,y:je}))}else{const Le=xe.y+ie.y-oe.height-5,je=(xe.x+$e.x)/2+ie.x-oe.width/2;pe.push(y(Q,{indexes:[...Ie,Pe],x:je,y:Le}))}}}),pe},F=M(r.items),X=t?y(t,{title:C,desc:P}):null,G=ae(y(Q,{indexes:[0]}));if(!F.length)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[X,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:-G.width/2,y:-G.height/2})})})]});const L=T(F),R=nf(L),{levelBounds:z,maxWidth:q,maxHeight:j}=N(R),U=uU().nodeSize(x?[j+o,q+i]:[q+o,j+i]).separation(()=>1)(R).descendants(),K=U.map(ee=>E(ee)),ne=Math.min(...K.map(ee=>ee.x)),J=Math.min(...K.map(ee=>ee.y)),se={x:Math.max(0,-ne+q/2),y:Math.max(0,-J+G.height+10)},Z=[],te=[],ue=[],re=[];return U.forEach((ee,oe)=>{ee.data._flatIndex=oe;const{x:ie,y:le}=E(ee);ee.__layout={x:ie,y:le}}),U.forEach(ee=>{const{items:oe,btns:ie,deco:le}=D(ee,z,G,se,re,U);Z.push(...oe),te.push(...ie),ue.push(...le)}),te.push(...B(U,G,se)),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[X,k(Y,{children:[re.length>0&&y(Ke,{children:re}),y(Pt,{children:ue}),y(ze,{children:Z}),y(qe,{children:te})]})]})};We("hierarchy-tree",{component:R5,composites:["title","item"]});const k5=e=>{const{Title:t,Item:n,data:r,gap:i=20,width:o,zigzag:s}=e,{title:a,desc:l,items:c=[]}=r,u=ae(y(Q,{indexes:[0]})),h=ae(y(n,{indexes:[0],data:r,datum:c[0]})),f=o||h.width,d=t?y(t,{title:a,desc:l}):null,p=[],g=[],m=(f-u.width)/2;if(c.forEach((v,b)=>{const _=(h.height+i)*b,x=[b];g.push(y(n,{indexes:x,datum:v,data:r,y:_,width:f,positionV:"middle",positionH:s?b%2===0?"normal":"flipped":"normal"})),p.push(y(nt,{indexes:x,x:-u.width-10,y:_+(h.height-u.height)/2}));const w=b===0?-u.height:_-i/2-u.height/2;p.push(y(Q,{indexes:x,x:m,y:w}))}),c.length>0){const b=(h.height+i)*(c.length-1)+h.height;p.push(y(Q,{indexes:[c.length],x:m,y:b}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,k(Y,{children:[y(ze,{children:g}),y(qe,{children:p})]})]})};We("list-column",{component:k5,composites:["title","item"]});const L5=e=>{const{Title:t,Item:n,data:r,columns:i=3,gap:o=24,zigzag:s}=e,{title:a,desc:l,items:c=[]}=r,u=t?y(t,{title:a,desc:l}):null,h=ae(y(Q,{indexes:[0]})),f=ae(y(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),d=[],p=[],g=f.height+o,m=f.width+o,v=new Set;return c.forEach((b,_)=>{const x=Math.floor(_/i),w=_%i,C=w*m,P=x*g,O=[_];p.push(y(n,{indexes:O,datum:b,data:r,x:C,y:P,positionH:"center",positionV:s&&_%2===0?"normal":"flipped"})),d.push(y(nt,{indexes:O,x:C+(f.width-h.width)/2,y:P+f.height})),w<i-1&&d.push(y(Q,{indexes:[_+1],x:C+f.width+(o-h.width)/2,y:P+(f.height-h.height)/2})),w===0&&!v.has(x)&&(d.push(y(Q,{indexes:[_],x:C-o/2-h.width/2,y:P+(f.height-h.height)/2})),v.add(x)),(w===i-1||_===c.length-1)&&d.push(y(Q,{indexes:[_+1],x:C+f.width+o/2-h.width/2,y:P+(f.height-h.height)/2}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,k(Y,{children:[y(ze,{children:p}),y(qe,{children:d})]})]})};We("list-grid",{component:L5,composites:["title","item"]});const N5=e=>{const{Title:t,Item:n,data:r,gap:i=20,levelGap:o=20}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=ae(y(Q,{indexes:[0]})),h=ae(y(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),f=[],d=[],p=Math.ceil(Math.sqrt(l.length)),g=[];let m=l.length;for(let w=0;w<p;w++){const C=Math.min(w+1,m);if(g.push(C),m-=C,m<=0)break}let v=0;const b=Math.max(...g),x=(b*h.width+(b-1)*i)/2;return g.forEach((w,C)=>{const P=C*(h.height+o),O=w*h.width+(w-1)*i,$=x-O/2;for(let S=0;S<w&&v<l.length;S++){const M=$+S*(h.width+i),I=l[v],E=[v];d.push(y(n,{indexes:E,datum:I,data:r,x:M,y:P,positionH:"center"})),f.push(y(nt,{indexes:E,x:M+(h.width-u.width)/2,y:P+h.height})),S<w-1&&f.push(y(Q,{indexes:[v+1],x:M+h.width+(i-u.width)/2,y:P+(h.height-u.height)/2})),S===0&&f.push(y(Q,{indexes:[v],x:M-i/2-u.width/2,y:P+(h.height-u.height)/2})),S===w-1&&f.push(y(Q,{indexes:[v+1],x:M+h.width+i/2-u.width/2,y:P+(h.height-u.height)/2})),v++}}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(ze,{children:d}),y(qe,{children:f})]})]})};We("list-pyramid",{component:N5,composites:["title","item"]});const z5=e=>{const{Title:t,Item:n,data:r,gap:i=20,zigzag:o}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=ae(y(Q,{indexes:[0]})),h=ae(y(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),f=[],d=[],p=(h.height-u.height)/2,g=h.height;if(l.forEach((m,v)=>{const b=(h.width+i)*v,_=[v];d.push(y(n,{indexes:_,datum:m,data:r,x:b,positionH:"center",positionV:o&&v%2===0?"normal":"flipped"})),f.push(y(nt,{indexes:_,x:b+(h.width-u.width)/2,y:g}));const x=v===0?-(i+u.width)/2:b-(i+u.width)/2;f.push(y(Q,{indexes:_,x,y:p}))}),l.length>0){const v=(h.width+i)*(l.length-1)+h.width+(i-u.width)/2;f.push(y(Q,{indexes:[l.length],x:v,y:p}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(ze,{children:d}),y(qe,{children:f})]})]})};We("list-row",{component:z5,composites:["title","item"]});var EQ=Object.defineProperty,D5=Object.getOwnPropertySymbols,MQ=Object.prototype.hasOwnProperty,IQ=Object.prototype.propertyIsEnumerable,q5=(e,t,n)=>t in e?EQ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,AQ=(e,t)=>{for(var n in t||(t={}))MQ.call(t,n)&&q5(e,n,t[n]);if(D5)for(var n of D5(t))IQ.call(t,n)&&q5(e,n,t[n]);return e};const H5=e=>{const{Item:t,data:n,outerRadius:r=250,innerRadius:i=120,startAngle:o=-90,endAngle:s=270,gapAngle:a=1,options:l}=e,{title:c,items:u=[]}=n,h=Et(l.themeConfig),f=ae(y(Q,{indexes:[0]})),d=[],p=[],g=[],m=r+100,v=r+100,b=s-o,_=Math.abs(b-360)<.01,x=u.length>0?a*(_?u.length:u.length-1):0,w=b-x,C=u.length>0?w/u.length:0;if(u.forEach((E,A)=>{var T;const N=[A],H=o+(C+a)*A,D=H+C,F=a*Math.PI*r/180/i*(180/Math.PI),X=a,G=(H+X/2)*Math.PI/180,L=(D-X/2)*Math.PI/180,R=(H+F/2)*Math.PI/180,z=(D-F/2)*Math.PI/180,q=m+r*Math.cos(G),j=v+r*Math.sin(G),V=m+r*Math.cos(L),U=v+r*Math.sin(L),K=m+i*Math.cos(R),ne=v+i*Math.sin(R),J=m+i*Math.cos(z),se=v+i*Math.sin(z),Z=C>180?1:0,te=`
|
|
103
|
+
M ${q} ${j}
|
|
104
|
+
A ${r} ${r} 0 ${Z} 1 ${V} ${U}
|
|
105
|
+
L ${J} ${se}
|
|
106
|
+
A ${i} ${i} 0 ${Z} 0 ${K} ${ne}
|
|
107
107
|
Z
|
|
108
|
-
`.trim(),ue=
|
|
108
|
+
`.trim(),ue=He(l,N);g.push(y(Ce,{id:"shape-sector",d:te,fill:ue,width:r*2+200,height:r*2+200,"data-element-type":"shape"}));const ee=(H+C/2)*Math.PI/180,oe=(r+i)/2,ie=r-i,le=C*Math.PI/180,pe=oe*le,he=Math.min(pe*.8,ie*.9),ge=Math.min(ie*.9,pe*.8),fe=ae(y(t,{indexes:[0],data:n,datum:u[0],positionH:"center",width:he,height:ge})),xe=m+oe*Math.cos(ee)-fe.width/2,$e=v+oe*Math.sin(ee)-fe.height/2;p.push(y(t,{indexes:N,datum:E,data:n,x:xe,y:$e,positionH:"center",width:he,height:ge,themeColors:AQ({},Et({colorBg:He(l,N),colorPrimary:((T=l.themeConfig)==null?void 0:T.colorBg)||"white"}))}));const Ie=r+10,Pe=m+Ie*Math.cos(ee)-f.width/2,Le=v+Ie*Math.sin(ee)-f.height/2;if(d.push(y(nt,{indexes:N,x:Pe,y:Le})),_||A<u.length-1){const Fe=(D+a/2)*Math.PI/180,ye=oe,we=m+ye*Math.cos(Fe)-f.width/2,Ae=v+ye*Math.sin(Fe)-f.height/2;d.push(y(Q,{indexes:[A+1],x:we,y:Ae}))}}),u.length>0){const A=(o-a/2)*Math.PI/180,T=(r+i)/2,N=m+T*Math.cos(A)-f.width/2,H=v+T*Math.sin(A)-f.height/2;d.push(y(Q,{indexes:[0],x:N,y:H}))}const P=i*.9;let O=m,$=v,S=P*1.4,M=P*1.4;if(!_){const A=(o+s)/2*Math.PI/180,T=P*.5;O=m+T*Math.cos(A),$=v+T*Math.sin(A);const N=b*Math.PI*T/180;S=Math.min(N*.8,P*1.4),M=Math.min(T*1.5,P*1.4)}let I="";if(_)I="";else{const E=o*Math.PI/180,A=s*Math.PI/180,T=m+P*Math.cos(E),N=v+P*Math.sin(E),H=m+P*Math.cos(A),D=v+P*Math.sin(A),B=b>180?1:0;I=`
|
|
109
109
|
M ${m} ${v}
|
|
110
|
-
L ${
|
|
111
|
-
A ${
|
|
110
|
+
L ${T} ${N}
|
|
111
|
+
A ${P} ${P} 0 ${B} 1 ${H} ${D}
|
|
112
112
|
Z
|
|
113
|
-
`.trim()}return L(Y,{id:"infographic-container",children:[p(Y,{children:y}),_?p(Ze,{id:"shape-center-circle",x:m-$,y:v-$,width:$*2,height:$*2,fill:h.colorPrimaryBg,fillOpacity:.5,"data-element-type":"shape"}):p(Pe,{id:"shape-center-sector",d:A,fill:h.colorPrimaryBg,fillOpacity:.5,width:r*2+200,height:r*2+200,"data-element-type":"shape"}),p(ze,{x:C-S/2,y:M-E/2,width:S,height:E,alignHorizontal:"center",alignVertical:"middle",fontSize:24,fontWeight:"bold",fill:h.colorText,"data-element-type":Ve.Title,children:l}),p(Ne,{children:g}),p(He,{children:f})]})};We("list-sector",{component:G4,composites:["title","item"]});const V4=e=>{const{Title:t,Item:n,data:r,columns:i=4,gap:o=20,stepOffset:a=40}=e,{title:s,desc:c,items:l=[]}=r,u=t?p(t,{title:s,desc:c}):null,h=se(p(Q,{indexes:[0]})),d=se(p(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),f=[],g=[],y=d.width+o;return l.forEach((m,v)=>{const b=v%i,_=Math.floor(v/i),x=b*y,w=_*(d.height+o),P=b*a,$=w+P,C=[v];g.push(p(n,{indexes:C,datum:m,data:r,x,y:$,positionH:"center"})),f.push(p(nt,{indexes:C,x:x+(d.width-h.width)/2,y:$+d.height+5}))}),l.forEach((m,v)=>{const b=v%i,_=Math.floor(v/i),x=b*y,w=_*(d.height+o),P=b*a,$=w+P;if(v===0&&f.push(p(Q,{indexes:[0],x:x-o/2-h.width/2,y:$+(d.height-h.height)/2})),b<i-1&&v<l.length-1){const C=Math.floor((v+1)/i);_===C&&f.push(p(Q,{indexes:[v+1],x:x+d.width+(o-h.width)/2,y:$+(d.height-h.height)/2}))}(b===i-1||v===l.length-1)&&f.push(p(Q,{indexes:[v+1],x:x+d.width+(o-h.width)/2,y:$+(d.height-h.height)/2}))}),l.length===0&&f.push(p(Q,{indexes:[0],x:(i-1)*y/2+(d.width-h.width)/2,y:0})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,L(Y,{children:[p(Ne,{children:g}),p(He,{children:f})]})]})};We("list-waterfall",{component:V4,composites:["title","item"]});const rZ=6,Qh=700,Y4=330,X4=333,iZ={1:[{x:.5,y:.6,anchor:"top-right"}],2:[{x:.42,y:.5,anchor:"top-right"},{x:.72,y:.4,anchor:"bottom"}],3:[{x:.3,y:.5,anchor:"top-right"},{x:.48,y:.3,anchor:"bottom-left"},{x:.8,y:.75,anchor:"top-right"}],4:[{x:.3,y:.5,anchor:"top-right"},{x:.35,y:.2,anchor:"bottom-left"},{x:.65,y:.73,anchor:"top-right"},{x:.8,y:.52,anchor:"bottom-left"}],5:[{x:.19,y:.4,anchor:"top-right"},{x:.38,y:.2,anchor:"bottom"},{x:.52,y:.62,anchor:"top-right"},{x:.7,y:.43,anchor:"bottom"},{x:.82,y:.8,anchor:"top-right"}],6:[{x:.16,y:.35,anchor:"top-right"},{x:.38,y:.2,anchor:"bottom"},{x:.48,y:.54,anchor:"top-right"},{x:.55,y:.43,anchor:"bottom-left"},{x:.8,y:.75,anchor:"top-right"},{x:.86,y:.65,anchor:"bottom-left"}]},oZ={1:[{x:.5,y:.4,anchor:"bottom-right"}],2:[{x:.42,y:.5,anchor:"bottom-right"},{x:.72,y:.6,anchor:"top"}],3:[{x:.3,y:.5,anchor:"bottom-right"},{x:.48,y:.7,anchor:"top-left"},{x:.8,y:.25,anchor:"bottom-right"}],4:[{x:.3,y:.5,anchor:"bottom-right"},{x:.35,y:.8,anchor:"top-left"},{x:.65,y:.27,anchor:"bottom-right"},{x:.8,y:.48,anchor:"top-left"}],5:[{x:.19,y:.6,anchor:"bottom-right"},{x:.38,y:.8,anchor:"top"},{x:.52,y:.38,anchor:"bottom-right"},{x:.7,y:.57,anchor:"top"},{x:.82,y:.2,anchor:"bottom-right"}],6:[{x:.16,y:.65,anchor:"bottom-right"},{x:.38,y:.8,anchor:"top"},{x:.48,y:.46,anchor:"bottom-right"},{x:.55,y:.57,anchor:"top-left"},{x:.8,y:.25,anchor:"bottom-right"},{x:.86,y:.35,anchor:"top-left"}]},U4=(e,t,n)=>{const r=t[e];return r?r.map(i=>({x:i.x*Qh,y:i.y*n,anchor:i.anchor})):null},aZ=(e,t)=>{const n=e.anchor||"center";let r=e.x-t.width/2,i=e.y-t.height/2,o=e.y;switch(n){case"top":r=e.x-t.width/2,i=e.y,o=e.y+t.height/2;break;case"bottom":r=e.x-t.width/2,i=e.y-t.height,o=e.y-t.height/2;break;case"top-left":r=e.x,i=e.y,o=e.y+t.height/2;break;case"top-right":r=e.x-t.width,i=e.y,o=e.y+t.height/2;break;case"bottom-left":r=e.x,i=e.y-t.height,o=e.y-t.height/2;break;case"bottom-right":r=e.x-t.width,i=e.y-t.height,o=e.y-t.height/2;break}return{x:r,y:i,centerY:o}},Jh=(e,t)=>{const n=t.x-e.x,r=t.y-e.y,i=Math.hypot(n,r)||1;return{x:n/i,y:r/i}},K4=e=>{const{presetRatios:t,arrowHeight:n,Arrow:r}=e;return o=>{var a;const{Title:s,Item:c,data:l,options:u,itemGap:h=24}=o,{title:d,desc:f,items:g=[]}=l,y=Math.min(g.length,rZ),m=g.slice(0,y),v=s?p(s,{title:d,desc:f}):null,b=wt(u),x=Ct({colorPrimary:b},u).colorTextSecondary||"#737373",w=se(p(Q,{indexes:[0]}));if(g.length===0){const z=(a=U4(1,t,n))==null?void 0:a[0];if(!z)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,p(Y,{children:p(r,{colorPrimary:b,colorShadow:x})})]});const j=z.x-w.width/2,D=z.y-w.height/2;return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,L(Y,{children:[p(r,{colorPrimary:b,colorShadow:x}),p(Ne,{}),p(He,{children:p(Q,{indexes:[0],x:j,y:D})})]})]})}const P=se(p(c,{indexes:[0],data:l,datum:g[0],positionH:"center"})),$=[],C=[],M=U4(y,t,n);if(!M)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,L(Y,{children:[p(r,{colorPrimary:b,colorShadow:x}),p(Ne,{})]})]});const S=M,E=S.length>1?Jh(S[0],S[S.length-1]):{x:1,y:0},A=S.length>1?Jh(S[0],S[1]):E,O=S.length>1?Jh(S[S.length-2],S[S.length-1]):E,T=Math.max(P.width,P.height)*.45+h,F=z=>{const{x:j,y:D,centerY:W}=aZ(z,P);return{x:j,y:D,centerY:W}};if(S.forEach((z,j)=>{const D=F(z),W=D.centerY<n/2,B=[j],X=m[j];if(!X)return;C.push(p(c,{indexes:B,datum:X,data:l,x:D.x,y:D.y,positionH:"center"}));const H=D.x+P.width-w.width/2,k=W?D.y-w.height/2:D.y+P.height-w.height/2;$.push(p(nt,{indexes:B,x:H,y:k}))}),S.length>0){const z=S[0],j=z.x-A.x*T-w.width/2,D=z.y-A.y*T-w.height/2;$.push(p(Q,{indexes:[0],x:j,y:D}));for(let H=0;H<S.length-1;H++){const k=S[H],I=S[H+1],R=(k.x+I.x)/2,N=(k.y+I.y)/2,q=R-w.width/2,G=N-w.height/2;$.push(p(Q,{indexes:[H+1],x:q,y:G}))}const W=S[S.length-1],B=W.x+O.x*T-w.width/2,X=W.y+O.y*T-w.height/2;$.push(p(Q,{indexes:[y],x:B,y:X}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,L(Y,{children:[p(r,{colorPrimary:b,colorShadow:x}),p(Ne,{children:C}),p(He,{children:$})]})]})}},sZ=({colorPrimary:e="#17CA2C",colorShadow:t="#737373"})=>{const n=be(e).darken(20).toHexString();return L(Y,{width:Qh,height:Y4,children:[p("path",{d:"M228.864 159.446C230.266 159.446 231.623 158.768 232.689 157.535L274.263 110.162L265.717 102.923L227.311 148.082C225.977 149.623 224.281 150.47 222.529 150.47H175.404L182.03 158.367C182.795 159.445 182.795 159.446 183.734 159.446H228.864Z",fill:t}),p("path",{d:"M462.869 234.92C464.271 234.92 465.628 234.242 466.695 233.01L508.268 185.636L499.722 178.397L461.316 223.557C459.983 225.098 458.287 225.945 456.534 225.945H409.409L416.035 233.841C416.8 234.92 416.8 234.92 417.74 234.92H462.869Z",fill:t}),p("path",{d:"M697.005 330C698.783 330 700 328.82 700 327.001V256.638C700 254.857 697.848 253.965 696.591 255.225L693.409 258.411V320.402C693.409 322.058 692.069 323.401 690.414 323.401H630.718L627.536 326.587C626.278 327.847 627.169 330 628.947 330H697.005Z",fill:t}),p("path",{d:"M689.642 321.89C690.744 321.89 691.638 320.995 691.638 319.891V250.743C691.638 248.962 689.488 248.07 688.23 249.329L662.647 274.947L520.987 153.863C519.541 152.627 517.703 151.948 515.802 151.948H469.518C470.236 151.949 470.956 152.206 471.53 152.729L498.163 176.978L498.13 177.018L639.84 297.784L619.174 318.477C617.916 319.737 618.807 321.89 620.586 321.89H689.642Z",fill:e}),p("path",{d:"M429.279 198.995L467.208 153.03C468.3 151.716 470.268 151.579 471.531 152.729L498.163 176.978L460.69 221.107C459.173 222.894 456.946 223.924 454.6 223.924H408.473C409.366 223.924 410.252 223.527 410.845 222.764L429.279 198.995Z",fill:n}),p("path",{d:"M408.473 223.924H408.314L408.318 223.92C408.369 223.922 408.421 223.924 408.473 223.924Z",fill:n}),p("path",{d:"M406.524 223.203C407.826 224.318 409.796 224.116 410.845 222.761L429.279 198.932L287.411 77.8866C285.964 76.6523 284.125 75.9742 282.223 75.9742H234.606L234.625 75.9907C235.429 75.9118 236.263 76.1557 236.915 76.7378L263.662 100.621L263.546 100.758L406.524 223.203Z",fill:e}),p("path",{d:"M236.914 76.7386C235.651 75.6097 233.707 75.7513 232.621 77.0513L194.557 123.104L175.644 146.821C175.076 147.535 174.25 147.917 173.409 147.947L173.407 147.95H219.923C222.271 147.95 224.499 146.915 226.017 145.122L263.645 100.649L236.914 76.7386Z",fill:n}),p("path",{d:"M175.648 146.816C174.589 148.145 172.637 148.329 171.348 147.221L4.09334 3.51697C2.68586 2.30767 3.54106 0 5.39671 0H47.5805C49.4864 0 51.3297 0.680433 52.7785 1.91877L194.557 123.104L175.648 146.816Z",fill:e})]})},cZ=({colorPrimary:e="#17CA2C",colorShadow:t="#737373"})=>{const n=be(e).darken(20).toHexString();return L(Y,{width:Qh,height:X4,children:[p("path",{d:"M19.0526 324L12.6762 329.482C11.2703 330.691 12.1234 333 13.976 333H56.1578C58.058 333 59.896 332.321 61.3413 331.085L201.854 210.901L194.249 201.693L54.0527 321.606C52.246 323.151 49.9486 324 47.5732 324H19.0526Z",fill:t}),p("path",{d:"M234.587 248L241.131 255.922C241.656 256.552 242.382 256.909 243.134 256.983L243.115 257H290.716C292.618 257 294.457 256.322 295.903 255.087L437.091 134.536L429.305 125.5L288.613 245.609C286.805 247.153 284.507 248 282.132 248H234.587Z",fill:t}),p("path",{d:"M461.123 162.429L475.642 179.918C476.237 180.635 477.092 181.001 477.951 181H524.22C526.121 181 527.959 180.321 529.404 179.085L670.786 58.1578L662.326 49.6809L522.115 169.606C520.309 171.151 518.011 172 515.636 172H469.369L461.123 162.429Z",fill:t}),p("path",{d:"M687.912 74.8875C690.374 75.9052 693.412 74.1668 693.412 71.1716V11H698.004C699.106 11 700 11.8954 700 13V82.1716C700 83.9534 697.85 84.8457 696.593 83.5858L687.912 74.8875Z",fill:t}),p("path",{d:"M689.419 0C690.522 0 691.415 0.895432 691.415 2V71.1716C691.415 72.9534 689.265 73.8457 688.008 72.5858L662.433 46.9598L520.819 168.085C519.374 169.321 517.536 170 515.636 170H469.367C470.084 169.999 470.804 169.742 471.379 169.219L498.003 144.961L497.969 144.922L639.634 24.115L618.975 3.41421C617.717 2.15428 618.608 0 620.386 0H689.419Z",fill:e}),p("path",{d:"M429.141 122.937L467.058 168.918C468.149 170.232 470.116 170.369 471.378 169.219L498.003 144.961L460.542 100.818C459.025 99.0305 456.798 98 454.453 98H408.341C409.234 98.0001 410.12 98.3968 410.712 99.1606L429.141 122.937Z",fill:n}),p("path",{d:"M408.341 98H408.183L408.186 98.004C408.237 98.0013 408.289 98 408.341 98Z",fill:n}),p("path",{d:"M406.393 98.721C407.695 97.606 409.664 97.8077 410.712 99.1633L429.141 123L287.318 244.087C285.872 245.322 284.033 246 282.132 246H234.53L234.55 245.983C235.353 246.062 236.187 245.818 236.839 245.236L263.577 221.345L263.461 221.208L406.393 98.721Z",fill:e}),p("path",{d:"M236.837 245.235C235.575 246.365 233.631 246.223 232.546 244.922L194.494 198.854L175.588 175.129C175.019 174.415 174.194 174.032 173.353 174.002L173.351 174H219.852C222.199 174 224.427 175.035 225.944 176.829L263.56 221.317L236.837 245.235Z",fill:n}),p("path",{d:"M175.593 175.135C174.533 173.805 172.581 173.622 171.291 174.73L4.09013 318.484C2.68329 319.693 3.53868 322 5.394 322H47.5627C49.4695 322 51.3136 321.319 52.7627 320.08L194.494 198.854L175.593 175.135Z",fill:e})]})},Z4=K4({arrowHeight:Y4,presetRatios:iZ,Arrow:sZ}),Q4=K4({arrowHeight:X4,presetRatios:oZ,Arrow:cZ});We("list-zigzag-down",{component:Z4,composites:["title","item"]}),We("list-zigzag-up",{component:Q4,composites:["title","item"]});const J4=e=>{const{Title:t,Item:n,data:r,radius:i=150,startMode:o="top"}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=se(p(Q,{indexes:[0]})),h=se(p(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),d=[],f=[];if(c.length===0)return d.push(p(Q,{indexes:[0],x:-u.width/2,y:-u.height/2})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,p(Y,{children:p(He,{children:d})})]});const g=Math.max(h.width,h.height),y=Math.max(i,g),m=y+g/2,v=c.map(()=>{const P=h.width,$=h.height;return(P+$)/2}),b=v.reduce((P,$)=>P+$,0);let _;o==="equal"?_=-Math.PI/2:_=-Math.PI/2+2*Math.PI/c.length/2;let x=_;c.forEach((P,$)=>{const C=v[$]/b*2*Math.PI,M=x+C/2;x+=C;const S=m+y*Math.cos(M)-h.width/2,E=m+y*Math.sin(M)-h.height/2;f.push(p(n,{indexes:[$],datum:P,data:r,x:S,y:E}));const A=y-Math.max(h.width,h.height)/2-20,O=m+A*Math.cos(M)-u.width/2,T=m+A*Math.sin(M)-u.height/2;d.push(p(nt,{indexes:[$],x:O,y:T}))});const w=y-Math.max(h.width,h.height)/2-20;if(c.length>0)for(let P=0;P<c.length;P++){const $=P*2*Math.PI/c.length-Math.PI/2,C=(P+1)%c.length*2*Math.PI/c.length-Math.PI/2;let M;if(P===c.length-1){const A=C+2*Math.PI-$;M=$+A/2}else M=($+C)/2;const S=m+w*Math.cos(M)-u.width/2,E=m+w*Math.sin(M)-u.height/2;d.push(p(Q,{indexes:[P+1],x:S,y:E}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(Ne,{children:f}),p(He,{children:d})]})]})};We("relation-circle",{component:J4,composites:["title","item"]});function Ho(e,t,n,r){function i(o){return o instanceof n?o:new n(function(a){a(o)})}return new(n||(n=Promise))(function(o,a){function s(u){try{l(r.next(u))}catch(h){a(h)}}function c(u){try{l(r.throw(u))}catch(h){a(h)}}function l(u){u.done?o(u.value):i(u.value).then(s,c)}l((r=r.apply(e,[])).next())})}typeof SuppressedError=="function"&&SuppressedError;const lZ={abs:Math.abs,ceil:Math.ceil,floor:Math.floor,max:Math.max,min:Math.min,round:Math.round,sqrt:Math.sqrt,pow:Math.pow};class Et extends Error{constructor(t,n,r){super(t),this.position=n,this.token=r,this.name="ExpressionError"}}var De;(function(e){e[e.STRING=0]="STRING",e[e.NUMBER=1]="NUMBER",e[e.BOOLEAN=2]="BOOLEAN",e[e.NULL=3]="NULL",e[e.IDENTIFIER=4]="IDENTIFIER",e[e.OPERATOR=5]="OPERATOR",e[e.FUNCTION=6]="FUNCTION",e[e.DOT=7]="DOT",e[e.BRACKET_LEFT=8]="BRACKET_LEFT",e[e.BRACKET_RIGHT=9]="BRACKET_RIGHT",e[e.PAREN_LEFT=10]="PAREN_LEFT",e[e.PAREN_RIGHT=11]="PAREN_RIGHT",e[e.COMMA=12]="COMMA",e[e.QUESTION=13]="QUESTION",e[e.COLON=14]="COLON",e[e.DOLLAR=15]="DOLLAR"})(De||(De={}));const uZ=new Set([32,9,10,13]),hZ=new Set([43,45,42,47,37,33,38,124,61,60,62]),dZ=new Map([["true",De.BOOLEAN],["false",De.BOOLEAN],["null",De.NULL]]),ed=new Map([["===",!0],["!==",!0],["<=",!0],[">=",!0],["&&",!0],["||",!0],["+",!0],["-",!0],["*",!0],["/",!0],["%",!0],["!",!0],["<",!0],[">",!0]]),fZ=new Map([[46,De.DOT],[91,De.BRACKET_LEFT],[93,De.BRACKET_RIGHT],[40,De.PAREN_LEFT],[41,De.PAREN_RIGHT],[44,De.COMMA],[63,De.QUESTION],[58,De.COLON],[36,De.DOLLAR]]),e5=new Map;for(const[e,t]of fZ.entries())e5.set(e,{type:t,value:String.fromCharCode(e)});function qo(e){return e>=48&&e<=57}function td(e){return e>=97&&e<=122||e>=65&&e<=90||e===95}function t5(e){return td(e)||qo(e)}function pZ(e){return hZ.has(e)}var Pt;(function(e){e[e.Program=0]="Program",e[e.Literal=1]="Literal",e[e.Identifier=2]="Identifier",e[e.MemberExpression=3]="MemberExpression",e[e.CallExpression=4]="CallExpression",e[e.BinaryExpression=5]="BinaryExpression",e[e.UnaryExpression=6]="UnaryExpression",e[e.ConditionalExpression=7]="ConditionalExpression"})(Pt||(Pt={}));const gZ=new Map([["||",2],["&&",3],["===",4],["!==",4],[">",5],[">=",5],["<",5],["<=",5],["+",6],["-",6],["*",7],["/",7],["%",7],["!",8]]),mZ={type:Pt.Literal,value:null},yZ={type:Pt.Literal,value:!0},vZ={type:Pt.Literal,value:!1},bZ=e=>{let t=0;const n=e.length,r=()=>t>=n?null:e[t],i=()=>e[t++],o=h=>{const d=r();return d!==null&&d.type===h},a=h=>h.type===De.OPERATOR?gZ.get(h.value)||-1:h.type===De.DOT||h.type===De.BRACKET_LEFT?9:h.type===De.QUESTION?1:-1,s=h=>{let d,f;if(i().type===De.DOT){if(!o(De.IDENTIFIER)){const y=r();throw new Et("Expected property name",t,y?y.value:"<end of input>")}const g=i();d={type:Pt.Identifier,name:g.value},f=!1}else{if(d=l(0),!o(De.BRACKET_RIGHT)){const g=r();throw new Et("Expected closing bracket",t,g?g.value:"<end of input>")}i(),f=!0}return{type:Pt.MemberExpression,object:h,property:d,computed:f}},c=()=>{const h=r();if(!h)throw new Et("Unexpected end of input",t,"<end of input>");if(h.type===De.OPERATOR&&(h.value==="!"||h.value==="-")){i();const d=c();return{type:Pt.UnaryExpression,operator:h.value,argument:d,prefix:!0}}switch(h.type){case De.NUMBER:return i(),{type:Pt.Literal,value:Number(h.value)};case De.STRING:return i(),{type:Pt.Literal,value:h.value};case De.BOOLEAN:return i(),h.value==="true"?yZ:vZ;case De.NULL:return i(),mZ;case De.IDENTIFIER:return i(),{type:Pt.Identifier,name:h.value};case De.FUNCTION:return(()=>{const d=i(),f=[];if(!o(De.PAREN_LEFT)){const g=r();throw new Et("Expected opening parenthesis after function name",t,g?g.value:"<end of input>")}for(i();;){if(o(De.PAREN_RIGHT)){i();break}if(!r()){const y=r();throw new Et("Expected closing parenthesis",t,y?y.value:"<end of input>")}if(f.length>0){if(!o(De.COMMA)){const y=r();throw new Et("Expected comma between function arguments",t,y?y.value:"<end of input>")}i()}const g=l(0);f.push(g)}return{type:Pt.CallExpression,callee:{type:Pt.Identifier,name:d.value},arguments:f}})();case De.PAREN_LEFT:{i();const d=l(0);if(!o(De.PAREN_RIGHT)){const f=r();throw new Et("Expected closing parenthesis",t,f?f.value:"<end of input>")}return i(),d}default:throw new Et(`Unexpected token: ${h.type}`,t,h.value)}},l=(h=0)=>{let d=c();for(;t<n;){const f=e[t],g=a(f);if(g<=h)break;if(f.type!==De.QUESTION)if(f.type!==De.OPERATOR){if(f.type!==De.DOT&&f.type!==De.BRACKET_LEFT)break;d=s(d)}else{i();const y=l(g);d={type:Pt.BinaryExpression,operator:f.value,left:d,right:y}}else{i();const y=l(0);if(!o(De.COLON)){const v=r();throw new Et("Expected : in conditional expression",t,v?v.value:"<end of input>")}i();const m=l(0);d={type:Pt.ConditionalExpression,test:d,consequent:y,alternate:m}}}return d},u=l();return{type:Pt.Program,body:u}},_Z=(e,t,n)=>{let r=t;n&&(r=Kt(At({},t),{context:At(At({},t.context),n)}));const i=o=>{switch(o.type){case Pt.Literal:return(a=>a.value)(o);case Pt.Identifier:return(a=>{if(!(a.name in r.context))throw new Et(`Undefined variable: ${a.name}`);return r.context[a.name]})(o);case Pt.MemberExpression:return(a=>{const s=i(a.object);if(s==null)throw new Et("Cannot access property of null or undefined");return s[a.computed?i(a.property):a.property.name]})(o);case Pt.CallExpression:return(a=>{const s=r.functions[a.callee.name];if(!s)throw new Et(`Undefined function: ${a.callee.name}`);return s(...a.arguments.map((c=>i(c))))})(o);case Pt.BinaryExpression:return(a=>{if(a.operator==="&&"){const l=i(a.left);return l&&i(a.right)}if(a.operator==="||")return i(a.left)||i(a.right);const s=i(a.left),c=i(a.right);switch(a.operator){case"+":return s+c;case"-":return s-c;case"*":return s*c;case"/":return s/c;case"%":return s%c;case"===":return s===c;case"!==":return s!==c;case">":return s>c;case">=":return s>=c;case"<":return s<c;case"<=":return s<=c;default:throw new Et(`Unknown operator: ${a.operator}`)}})(o);case Pt.UnaryExpression:return(a=>{const s=i(a.argument);if(a.prefix)switch(a.operator){case"!":return!s;case"-":if(typeof s!="number")throw new Et(`Cannot apply unary - to non-number: ${s}`);return-s;default:throw new Et(`Unknown operator: ${a.operator}`)}throw new Et(`Postfix operators are not supported: ${a.operator}`)})(o);case Pt.ConditionalExpression:return(a=>{const s=i(a.test);return i(s?a.consequent:a.alternate)})(o);default:throw new Et(`Evaluation error: Unsupported node type: ${o.type}`)}};return i(e.body)};function n5(e){const t=(i=>{const o=i,a=o.length,s=new Array(Math.ceil(a/3));let c=0,l=0;function u(m){const v=l+1;l++;let b="",_=!1;for(;l<a;){const x=o.charCodeAt(l);if(x===m)return _||(b=o.substring(v,l)),l++,{type:De.STRING,value:b};x===92?(_||(b=o.substring(v,l),_=!0),l++,b+=o[l]):_&&(b+=o[l]),l++}throw new Et(`Unterminated string starting with ${String.fromCharCode(m)}`,l,o.substring(Math.max(0,l-10),l))}function h(){const m=l;for(o.charCodeAt(l)===45&&l++;l<a&&qo(o.charCodeAt(l));)l++;if(l<a&&o.charCodeAt(l)===46)for(l++;l<a&&qo(o.charCodeAt(l));)l++;const v=o.slice(m,l);return{type:De.NUMBER,value:v}}function d(){l++;const m=l;if(l<a&&td(o.charCodeAt(l)))for(l++;l<a&&t5(o.charCodeAt(l));)l++;const v=o.slice(m,l);return{type:De.FUNCTION,value:v}}function f(){const m=l++;for(;l<a&&t5(o.charCodeAt(l));)l++;const v=o.slice(m,l),b=dZ.get(v);return b?{type:b,value:v}:{type:De.IDENTIFIER,value:v}}function g(){if(l+2<a){const v=o.substring(l,l+3);if(ed.has(v))return l+=3,{type:De.OPERATOR,value:v}}if(l+1<a){const v=o.substring(l,l+2);if(ed.has(v))return l+=2,{type:De.OPERATOR,value:v}}const m=o[l];if(ed.has(m))return l++,{type:De.OPERATOR,value:m};throw new Et(`Unknown operator at position ${l}: ${o.substring(l,l+1)}`,l,o.substring(Math.max(0,l-10),l))}for(;l<a;){const m=o.charCodeAt(l);if(y=m,uZ.has(y)){l++;continue}const v=e5.get(m);if(v)s[c++]=v,l++;else if(m!==34&&m!==39)if(qo(m)||m===45&&l+1<a&&qo(o.charCodeAt(l+1)))s[c++]=h();else if(m!==64)if(td(m))s[c++]=f();else{if(!pZ(m))throw new Et(`Unexpected character: ${o[l]}`,l,o.substring(Math.max(0,l-10),l));s[c++]=g()}else s[c++]=d();else s[c++]=u(m)}var y;return c===s.length?s:s.slice(0,c)})(e),n=bZ(t),r=((i={},o={})=>({context:i,functions:o}))({},lZ);return(i={})=>_Z(n,r,i)}function xZ(e,t={}){return n5(e)(t)}function wZ(e,t){if(typeof e!="string")return;const n=e.trim();if(n)try{return n5(n),xZ(n,t)}catch(r){return}}function Si(e){return typeof e=="number"}function r5(e){if(!e)return[0,0,0];if(Si(e))return[e,e,e];if(Array.isArray(e)&&e.length===0)return[0,0,0];const[t,n=t,r=t]=e;return[t,n,r]}function PZ(e){return Si(e)?!0:Array.isArray(e)?e.every(t=>Si(t)):!1}function ln(e){return e==null}function i5(e){return typeof e=="string"}function o5(e){return typeof e=="function"}function nd(e,t){if(typeof e=="function")return e;if(typeof e=="string"){const n=e;return(...r)=>{const i={};for(let o=0;o<t.length;o++)i[t[o]]=r[o];return wZ(n,i)}}return()=>e}function rd(e,t,n="node"){if(ln(e))return()=>t;if(i5(e)){const r=nd(e,[n]);return i=>{const o=r(i);return Si(o)?o:t}}return o5(e)?e:Si(e)?()=>e:()=>t}function a5(e,t=10,n="node"){if(ln(e))return()=>t;if(i5(e)){const r=nd(e,[n]);return i=>{const o=r(i);return PZ(o)?o:t}}return o5(e)?e:Si(e)?()=>e:Array.isArray(e)?()=>e:()=>t}function $Z(e){var t;return[e.x,e.y,(t=e.z)!==null&&t!==void 0?t:0]}class CZ{constructor(t,n={}){this.edgeIdCounter=new Map,this.nodeMap=MZ(t.nodes,n.node),this.edgeMap=EZ(t.edges||[],n.edge,this.getEdgeId.bind(this))}data(){return{nodes:this.nodeMap,edges:this.edgeMap}}replace(t){this.nodeMap=t.nodes,this.edgeMap=t.edges,this.clearCache()}nodes(){return Array.from(this.nodeMap.values())}node(t){return this.nodeMap.get(t)}nodeAt(t){this.indexNodeCache||this.buildNodeIndexCache();const n=this.indexNodeCache.get(t);return n?this.nodeMap.get(n):void 0}nodeIndexOf(t){var n;return this.nodeIndexCache||this.buildNodeIndexCache(),(n=this.nodeIndexCache.get(t))!==null&&n!==void 0?n:-1}firstNode(){return this.nodeMap.values().next().value}forEachNode(t){let n=0;this.nodeMap.forEach(r=>t(r,n++))}originalNode(t){const n=this.nodeMap.get(t);return n==null?void 0:n._original}nodeCount(){return this.nodeMap.size}edges(){return Array.from(this.edgeMap.values())}edge(t){return this.edgeMap.get(t)}firstEdge(){return this.edgeMap.values().next().value}forEachEdge(t){let n=0;this.edgeMap.forEach(r=>t(r,n++))}originalEdge(t){const n=this.edgeMap.get(t);return n==null?void 0:n._original}edgeCount(){return this.edgeMap.size}getEdgeId(t){if(t.id)return t.id;const n=`${t.source}-${t.target}`,r=this.edgeIdCounter.get(n)||0,i=r===0?n:`${n}-${r}`;return this.edgeIdCounter.set(n,r+1),i}degree(t,n="both"){this.degreeCache||this.buildDegreeCache();const r=this.degreeCache.get(t);return r?r[n]:0}neighbors(t,n="both"){if((!this.outAdjacencyCache||!this.inAdjacencyCache)&&this.buildAdjacencyCache(),n==="out")return Array.from(this.outAdjacencyCache.get(t)||[]);if(n==="in")return Array.from(this.inAdjacencyCache.get(t)||[]);if(this.bothAdjacencyCache)return Array.from(this.bothAdjacencyCache.get(t)||[]);const r=this.inAdjacencyCache.get(t),i=this.outAdjacencyCache.get(t);if(!r&&!i)return[];if(!r)return Array.from(i);if(!i)return Array.from(r);const o=new Set;return r.forEach(a=>o.add(a)),i.forEach(a=>o.add(a)),Array.from(o)}successors(t){return this.neighbors(t,"out")}predecessors(t){return this.neighbors(t,"in")}setNodeOrder(t){const n=new Map;for(const r of t)n.set(r.id,r);this.nodeMap=n,this.nodeIndexCache=void 0,this.indexNodeCache=void 0}clearCache(){this.degreeCache=void 0,this.inAdjacencyCache=void 0,this.outAdjacencyCache=void 0,this.bothAdjacencyCache=void 0,this.nodeIndexCache=void 0,this.indexNodeCache=void 0}buildDegreeCache(){this.degreeCache=new Map;for(const t of this.edges()){const{source:n,target:r}=t;if(t.source===t.target)continue;this.degreeCache.has(n)||this.degreeCache.set(n,{in:0,out:0,both:0});const i=this.degreeCache.get(t.source);i&&(i.out++,i.both++),this.degreeCache.has(r)||this.degreeCache.set(r,{in:0,out:0,both:0});const o=this.degreeCache.get(t.target);o&&(o.in++,o.both++)}}buildAdjacencyCache(){this.inAdjacencyCache=new Map,this.outAdjacencyCache=new Map;for(const t of this.edges())!this.nodeMap.has(t.source)||!this.nodeMap.has(t.target)||(this.outAdjacencyCache.has(t.source)||this.outAdjacencyCache.set(t.source,new Set),this.outAdjacencyCache.get(t.source).add(t.target),this.inAdjacencyCache.has(t.target)||this.inAdjacencyCache.set(t.target,new Set),this.inAdjacencyCache.get(t.target).add(t.source))}buildNodeIndexCache(){this.nodeIndexCache=new Map,this.indexNodeCache=new Map;let t=0;this.nodeMap.forEach((n,r)=>{this.nodeIndexCache.set(r,t),this.indexNodeCache.set(t,r),t++})}destroy(){this.clearCache(),this.nodeMap.clear(),this.edgeMap.clear(),this.edgeIdCounter.clear()}}const OZ=["id","x","y","z","vx","vy","vz","fx","fy","fz","parentId"],SZ=["id","source","target","points"];function MZ(e,t){if(!e)throw new Error("Data.nodes is required");const n=new Map;for(const r of e){const i={_original:r};for(const o of OZ){const a=r[o];ln(a)||(i[o]=a)}if(t){const o=t(r);for(const a in o){const s=o[a];ln(s)||(i[a]=s)}}if(ln(i.id))throw new Error("Node is missing id field");n.set(i.id,i)}return n}function EZ(e,t,n){const r=new Map;for(const i of e){const o={_original:i};for(const a of SZ){const s=i[a];ln(s)||(o[a]=s)}if(t){const a=t(i);for(const s in a){const c=a[s];ln(c)||(o[s]=c)}}if(ln(o.source)||ln(o.target))throw new Error("Edge is missing source or target field");ln(o.id)&&(o.id=n==null?void 0:n(i)),r.set(o.id,o)}return r}class IZ{constructor(t,n={}){this.graph=new CZ(t,n)}export(){return this.graph.data()}replace(t){this.graph.replace(t)}forEachNode(t){this.graph.forEachNode(t)}forEachEdge(t){this.graph.forEachEdge((n,r)=>{n.sourceNode=this.graph.node(n.source),n.targetNode=this.graph.node(n.target),t(n,r)})}destroy(){this.graph.destroy()}}const s5=Symbol("Comlink.proxy"),AZ=Symbol("Comlink.endpoint"),TZ=Symbol("Comlink.releaseProxy"),id=Symbol("Comlink.finalizer"),ic=Symbol("Comlink.thrown"),c5=e=>typeof e=="object"&&e!==null||typeof e=="function",kZ={canHandle:e=>c5(e)&&e[s5],serialize(e){const{port1:t,port2:n}=new MessageChannel;return u5(e,t),[n,[n]]},deserialize(e){return e.start(),d5(e)}},RZ={canHandle:e=>c5(e)&&ic in e,serialize({value:e}){let t;return e instanceof Error?t={isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:t={isError:!1,value:e},[t,[]]},deserialize(e){throw e.isError?Object.assign(new Error(e.value.message),e.value):e.value}},l5=new Map([["proxy",kZ],["throw",RZ]]);function LZ(e,t){for(const n of e)if(t===n||n==="*"||n instanceof RegExp&&n.test(t))return!0;return!1}function u5(e,t=globalThis,n=["*"]){t.addEventListener("message",function r(i){if(!i||!i.data)return;if(!LZ(n,i.origin)){console.warn(`Invalid origin '${i.origin}' for comlink proxy`);return}const{id:o,type:a,path:s}=Object.assign({path:[]},i.data),c=(i.data.argumentList||[]).map(Fr);let l;try{const u=s.slice(0,-1).reduce((d,f)=>d[f],e),h=s.reduce((d,f)=>d[f],e);switch(a){case"GET":l=h;break;case"SET":u[s.slice(-1)[0]]=Fr(i.data.value),l=!0;break;case"APPLY":l=h.apply(u,c);break;case"CONSTRUCT":{const d=new h(...c);l=jZ(d)}break;case"ENDPOINT":{const{port1:d,port2:f}=new MessageChannel;u5(e,f),l=qZ(d,[d])}break;case"RELEASE":l=void 0;break;default:return}}catch(u){l={value:u,[ic]:0}}Promise.resolve(l).catch(u=>({value:u,[ic]:0})).then(u=>{const[h,d]=cc(u);t.postMessage(Object.assign(Object.assign({},h),{id:o}),d),a==="RELEASE"&&(t.removeEventListener("message",r),h5(t),id in e&&typeof e[id]=="function"&&e[id]())}).catch(u=>{const[h,d]=cc({value:new TypeError("Unserializable return value"),[ic]:0});t.postMessage(Object.assign(Object.assign({},h),{id:o}),d)})}),t.start&&t.start()}function zZ(e){return e.constructor.name==="MessagePort"}function h5(e){zZ(e)&&e.close()}function d5(e,t){const n=new Map;return e.addEventListener("message",function(i){const{data:o}=i;if(!o||!o.id)return;const a=n.get(o.id);if(a)try{a(o)}finally{n.delete(o.id)}}),od(e,n,[],t)}function oc(e){if(e)throw new Error("Proxy has been released and is not useable")}function f5(e){return Mi(e,new Map,{type:"RELEASE"}).then(()=>{h5(e)})}const ac=new WeakMap,sc="FinalizationRegistry"in globalThis&&new FinalizationRegistry(e=>{const t=(ac.get(e)||0)-1;ac.set(e,t),t===0&&f5(e)});function NZ(e,t){const n=(ac.get(t)||0)+1;ac.set(t,n),sc&&sc.register(e,t,e)}function DZ(e){sc&&sc.unregister(e)}function od(e,t,n=[],r=function(){}){let i=!1;const o=new Proxy(r,{get(a,s){if(oc(i),s===TZ)return()=>{DZ(o),f5(e),t.clear(),i=!0};if(s==="then"){if(n.length===0)return{then:()=>o};const c=Mi(e,t,{type:"GET",path:n.map(l=>l.toString())}).then(Fr);return c.then.bind(c)}return od(e,t,[...n,s])},set(a,s,c){oc(i);const[l,u]=cc(c);return Mi(e,t,{type:"SET",path:[...n,s].map(h=>h.toString()),value:l},u).then(Fr)},apply(a,s,c){oc(i);const l=n[n.length-1];if(l===AZ)return Mi(e,t,{type:"ENDPOINT"}).then(Fr);if(l==="bind")return od(e,t,n.slice(0,-1));const[u,h]=p5(c);return Mi(e,t,{type:"APPLY",path:n.map(d=>d.toString()),argumentList:u},h).then(Fr)},construct(a,s){oc(i);const[c,l]=p5(s);return Mi(e,t,{type:"CONSTRUCT",path:n.map(u=>u.toString()),argumentList:c},l).then(Fr)}});return NZ(o,e),o}function HZ(e){return Array.prototype.concat.apply([],e)}function p5(e){const t=e.map(cc);return[t.map(n=>n[0]),HZ(t.map(n=>n[1]))]}const g5=new WeakMap;function qZ(e,t){return g5.set(e,t),e}function jZ(e){return Object.assign(e,{[s5]:!0})}function cc(e){for(const[t,n]of l5)if(n.canHandle(e)){const[r,i]=n.serialize(e);return[{type:"HANDLER",name:t,value:r},i]}return[{type:"RAW",value:e},g5.get(e)||[]]}function Fr(e){switch(e.type){case"HANDLER":return l5.get(e.name).deserialize(e.value);case"RAW":return e.value}}function Mi(e,t,n,r){return new Promise(i=>{const o=FZ();t.set(o,i),e.start&&e.start(),e.postMessage(Object.assign({id:o},n),r)})}function FZ(){return new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-")}class BZ{constructor(){this.worker=null,this.workerApi=null}execute(t,n,r){return Ho(this,void 0,void 0,function*(){if(this.worker||(yield this.initWorker()),!this.workerApi)throw new Error("Worker API not initialized");return yield this.workerApi.execute(t,n,r)})}destroy(){this.workerApi&&this.workerApi.destroy(),this.worker&&(this.worker.terminate(),this.worker=null,this.workerApi=null)}initWorker(){return Ho(this,void 0,void 0,function*(){const t=this.resolveWorkerPath(),r=t.includes("/lib/")||t.endsWith(".mjs")?"module":"classic";this.worker=new Worker(t,{type:r}),this.workerApi=d5(this.worker)})}resolveWorkerPath(){if(typeof{url:typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:ht&&ht.tagName.toUpperCase()==="SCRIPT"&&ht.src||new URL("infographic.min.js",document.baseURI).href}!="undefined"&&(typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:ht&&ht.tagName.toUpperCase()==="SCRIPT"&&ht.src||new URL("infographic.min.js",document.baseURI).href)){const t=new URL(typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:ht&&ht.tagName.toUpperCase()==="SCRIPT"&&ht.src||new URL("infographic.min.js",document.baseURI).href),n=t.href.replace(/\/runtime\/[^/]+\.js$/,"/worker.js");return n!==t.href?n:t.href.replace(/\/[^/]+\.js$/,"/worker.js")}if(typeof document!="undefined"){const t=document.getElementsByTagName("script");for(let n=t.length-1;n>=0;n--){const r=t[n].src;if(r&&(r.includes("index.js")||r.includes("index.min.js")))return r.replace(/index(\.min)?\.js/,"worker.js")}}return"./worker.js"}}class WZ{constructor(t){this.supervisor=null,this.initialOptions=this.mergeOptions(this.getDefaultOptions(),t)}get options(){return this.runtimeOptions||this.initialOptions}mergeOptions(t,n){return Object.assign({},t,n||{})}execute(t,n){return Ho(this,void 0,void 0,function*(){this.runtimeOptions=this.mergeOptions(this.initialOptions,n);const{node:r,edge:i,enableWorker:o}=this.runtimeOptions;this.context=new IZ(t,{node:r,edge:i}),this.model=this.context.graph,o&&typeof Worker!="undefined"?yield this.layoutInWorker(t,this.runtimeOptions):yield this.layout(this.runtimeOptions)})}layoutInWorker(t,n){var r;return Ho(this,void 0,void 0,function*(){try{this.supervisor||(this.supervisor=new BZ);const i=yield this.supervisor.execute(this.id,t,n);(r=this.context)===null||r===void 0||r.replace(i)}catch(i){console.error("Layout in worker failed, fallback to main thread layout.",i),yield this.layout(n)}})}forEachNode(t){this.context.forEachNode(t)}forEachEdge(t){this.context.forEachEdge(t)}destroy(){var t;(t=this.context)===null||t===void 0||t.destroy(),this.model=null,this.context=null,this.supervisor&&(this.supervisor.destroy(),this.supervisor=null)}}function GZ(e){return Array.isArray(e)}var VZ=(function(e){var t=typeof e;return e!==null&&t==="object"||t==="function"}),YZ=function(e){return typeof e=="object"&&e!==null},XZ={}.toString,m5=function(e,t){return XZ.call(e)==="[object "+t+"]"},UZ=function(e){if(!YZ(e)||!m5(e,"Object"))return!1;if(Object.getPrototypeOf(e)===null)return!0;for(var t=e;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t},lc=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function KZ(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ad(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var sd,y5;function ZZ(){if(y5)return sd;y5=1;function e(){this.__data__=[],this.size=0}return sd=e,sd}var cd,v5;function Ei(){if(v5)return cd;v5=1;function e(t,n){return t===n||t!==t&&n!==n}return cd=e,cd}var ld,b5;function uc(){if(b5)return ld;b5=1;var e=Ei();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return ld=t,ld}var ud,_5;function QZ(){if(_5)return ud;_5=1;var e=uc(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,a=e(o,i);if(a<0)return!1;var s=o.length-1;return a==s?o.pop():n.call(o,a,1),--this.size,!0}return ud=r,ud}var hd,x5;function JZ(){if(x5)return hd;x5=1;var e=uc();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return hd=t,hd}var dd,w5;function eQ(){if(w5)return dd;w5=1;var e=uc();function t(n){return e(this.__data__,n)>-1}return dd=t,dd}var fd,P5;function tQ(){if(P5)return fd;P5=1;var e=uc();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return fd=t,fd}var pd,$5;function hc(){if($5)return pd;$5=1;var e=ZZ(),t=QZ(),n=JZ(),r=eQ(),i=tQ();function o(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var l=a[s];this.set(l[0],l[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,pd=o,pd}var gd,C5;function nQ(){if(C5)return gd;C5=1;var e=hc();function t(){this.__data__=new e,this.size=0}return gd=t,gd}var md,O5;function rQ(){if(O5)return md;O5=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return md=e,md}var yd,S5;function iQ(){if(S5)return yd;S5=1;function e(t){return this.__data__.get(t)}return yd=e,yd}var vd,M5;function oQ(){if(M5)return vd;M5=1;function e(t){return this.__data__.has(t)}return vd=e,vd}var bd,E5;function I5(){if(E5)return bd;E5=1;var e=typeof lc=="object"&&lc&&lc.Object===Object&&lc;return bd=e,bd}var _d,A5;function vn(){if(A5)return _d;A5=1;var e=I5(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return _d=n,_d}var xd,T5;function Ii(){if(T5)return xd;T5=1;var e=vn(),t=e.Symbol;return xd=t,xd}var wd,k5;function aQ(){if(k5)return wd;k5=1;var e=Ii(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(a){var s=n.call(a,i),c=a[i];try{a[i]=void 0;var l=!0}catch(h){}var u=r.call(a);return l&&(s?a[i]=c:delete a[i]),u}return wd=o,wd}var Pd,R5;function sQ(){if(R5)return Pd;R5=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return Pd=n,Pd}var $d,L5;function Br(){if(L5)return $d;L5=1;var e=Ii(),t=aQ(),n=sQ(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function a(s){return s==null?s===void 0?i:r:o&&o in Object(s)?t(s):n(s)}return $d=a,$d}var Cd,z5;function un(){if(z5)return Cd;z5=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return Cd=e,Cd}var Od,N5;function jo(){if(N5)return Od;N5=1;var e=Br(),t=un(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function a(s){if(!t(s))return!1;var c=e(s);return c==r||c==i||c==n||c==o}return Od=a,Od}var Sd,D5;function cQ(){if(D5)return Sd;D5=1;var e=vn(),t=e["__core-js_shared__"];return Sd=t,Sd}var Md,H5;function lQ(){if(H5)return Md;H5=1;var e=cQ(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return Md=n,Md}var Ed,q5;function j5(){if(q5)return Ed;q5=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch(i){}try{return r+""}catch(i){}}return""}return Ed=n,Ed}var Id,F5;function uQ(){if(F5)return Id;F5=1;var e=jo(),t=lQ(),n=un(),r=j5(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,a=Function.prototype,s=Object.prototype,c=a.toString,l=s.hasOwnProperty,u=RegExp("^"+c.call(l).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function h(d){if(!n(d)||t(d))return!1;var f=e(d)?u:o;return f.test(r(d))}return Id=h,Id}var Ad,B5;function hQ(){if(B5)return Ad;B5=1;function e(t,n){return t==null?void 0:t[n]}return Ad=e,Ad}var Td,W5;function Wr(){if(W5)return Td;W5=1;var e=uQ(),t=hQ();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return Td=n,Td}var kd,G5;function Rd(){if(G5)return kd;G5=1;var e=Wr(),t=vn(),n=e(t,"Map");return kd=n,kd}var Ld,V5;function dc(){if(V5)return Ld;V5=1;var e=Wr(),t=e(Object,"create");return Ld=t,Ld}var zd,Y5;function dQ(){if(Y5)return zd;Y5=1;var e=dc();function t(){this.__data__=e?e(null):{},this.size=0}return zd=t,zd}var Nd,X5;function fQ(){if(X5)return Nd;X5=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return Nd=e,Nd}var Dd,U5;function pQ(){if(U5)return Dd;U5=1;var e=dc(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var a=this.__data__;if(e){var s=a[o];return s===t?void 0:s}return r.call(a,o)?a[o]:void 0}return Dd=i,Dd}var Hd,K5;function gQ(){if(K5)return Hd;K5=1;var e=dc(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return Hd=r,Hd}var qd,Z5;function mQ(){if(Z5)return qd;Z5=1;var e=dc(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return qd=n,qd}var jd,Q5;function yQ(){if(Q5)return jd;Q5=1;var e=dQ(),t=fQ(),n=pQ(),r=gQ(),i=mQ();function o(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var l=a[s];this.set(l[0],l[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,jd=o,jd}var Fd,J5;function vQ(){if(J5)return Fd;J5=1;var e=yQ(),t=hc(),n=Rd();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return Fd=r,Fd}var Bd,e6;function bQ(){if(e6)return Bd;e6=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return Bd=e,Bd}var Wd,t6;function fc(){if(t6)return Wd;t6=1;var e=bQ();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return Wd=t,Wd}var Gd,n6;function _Q(){if(n6)return Gd;n6=1;var e=fc();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return Gd=t,Gd}var Vd,r6;function xQ(){if(r6)return Vd;r6=1;var e=fc();function t(n){return e(this,n).get(n)}return Vd=t,Vd}var Yd,i6;function wQ(){if(i6)return Yd;i6=1;var e=fc();function t(n){return e(this,n).has(n)}return Yd=t,Yd}var Xd,o6;function PQ(){if(o6)return Xd;o6=1;var e=fc();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return Xd=t,Xd}var Ud,a6;function Kd(){if(a6)return Ud;a6=1;var e=vQ(),t=_Q(),n=xQ(),r=wQ(),i=PQ();function o(a){var s=-1,c=a==null?0:a.length;for(this.clear();++s<c;){var l=a[s];this.set(l[0],l[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Ud=o,Ud}var Zd,s6;function $Q(){if(s6)return Zd;s6=1;var e=hc(),t=Rd(),n=Kd(),r=200;function i(o,a){var s=this.__data__;if(s instanceof e){var c=s.__data__;if(!t||c.length<r-1)return c.push([o,a]),this.size=++s.size,this;s=this.__data__=new n(c)}return s.set(o,a),this.size=s.size,this}return Zd=i,Zd}var Qd,c6;function pc(){if(c6)return Qd;c6=1;var e=hc(),t=nQ(),n=rQ(),r=iQ(),i=oQ(),o=$Q();function a(s){var c=this.__data__=new e(s);this.size=c.size}return a.prototype.clear=t,a.prototype.delete=n,a.prototype.get=r,a.prototype.has=i,a.prototype.set=o,Qd=a,Qd}var Jd,l6;function ef(){if(l6)return Jd;l6=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i&&n(t[r],r,t)!==!1;);return t}return Jd=e,Jd}var tf,u6;function h6(){if(u6)return tf;u6=1;var e=Wr(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch(r){}})();return tf=t,tf}var nf,d6;function gc(){if(d6)return nf;d6=1;var e=h6();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return nf=t,nf}var rf,f6;function mc(){if(f6)return rf;f6=1;var e=gc(),t=Ei(),n=Object.prototype,r=n.hasOwnProperty;function i(o,a,s){var c=o[a];(!(r.call(o,a)&&t(c,s))||s===void 0&&!(a in o))&&e(o,a,s)}return rf=i,rf}var of,p6;function Fo(){if(p6)return of;p6=1;var e=mc(),t=gc();function n(r,i,o,a){var s=!o;o||(o={});for(var c=-1,l=i.length;++c<l;){var u=i[c],h=a?a(o[u],r[u],u,o,r):void 0;h===void 0&&(h=r[u]),s?t(o,u,h):e(o,u,h)}return o}return of=n,of}var af,g6;function CQ(){if(g6)return af;g6=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return af=e,af}var sf,m6;function An(){if(m6)return sf;m6=1;function e(t){return t!=null&&typeof t=="object"}return sf=e,sf}var cf,y6;function OQ(){if(y6)return cf;y6=1;var e=Br(),t=An(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return cf=r,cf}var lf,v6;function Bo(){if(v6)return lf;v6=1;var e=OQ(),t=An(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(a){return t(a)&&r.call(a,"callee")&&!i.call(a,"callee")};return lf=o,lf}var uf,b6;function It(){if(b6)return uf;b6=1;var e=Array.isArray;return uf=e,uf}var Wo={exports:{}},hf,_6;function SQ(){if(_6)return hf;_6=1;function e(){return!1}return hf=e,hf}Wo.exports;var x6;function Ai(){return x6||(x6=1,(function(e,t){var n=vn(),r=SQ(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,a=o&&o.exports===i,s=a?n.Buffer:void 0,c=s?s.isBuffer:void 0,l=c||r;e.exports=l})(Wo,Wo.exports)),Wo.exports}var df,w6;function yc(){if(w6)return df;w6=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i==null?e:i,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return df=n,df}var ff,P6;function pf(){if(P6)return ff;P6=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return ff=t,ff}var gf,$6;function MQ(){if($6)return gf;$6=1;var e=Br(),t=pf(),n=An(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",a="[object Date]",s="[object Error]",c="[object Function]",l="[object Map]",u="[object Number]",h="[object Object]",d="[object RegExp]",f="[object Set]",g="[object String]",y="[object WeakMap]",m="[object ArrayBuffer]",v="[object DataView]",b="[object Float32Array]",_="[object Float64Array]",x="[object Int8Array]",w="[object Int16Array]",P="[object Int32Array]",$="[object Uint8Array]",C="[object Uint8ClampedArray]",M="[object Uint16Array]",S="[object Uint32Array]",E={};E[b]=E[_]=E[x]=E[w]=E[P]=E[$]=E[C]=E[M]=E[S]=!0,E[r]=E[i]=E[m]=E[o]=E[v]=E[a]=E[s]=E[c]=E[l]=E[u]=E[h]=E[d]=E[f]=E[g]=E[y]=!1;function A(O){return n(O)&&t(O.length)&&!!E[e(O)]}return gf=A,gf}var mf,C6;function vc(){if(C6)return mf;C6=1;function e(t){return function(n){return t(n)}}return mf=e,mf}var Go={exports:{}};Go.exports;var O6;function yf(){return O6||(O6=1,(function(e,t){var n=I5(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,a=o&&n.process,s=(function(){try{var c=i&&i.require&&i.require("util").types;return c||a&&a.binding&&a.binding("util")}catch(l){}})();e.exports=s})(Go,Go.exports)),Go.exports}var vf,S6;function Vo(){if(S6)return vf;S6=1;var e=MQ(),t=vc(),n=yf(),r=n&&n.isTypedArray,i=r?t(r):e;return vf=i,vf}var bf,M6;function E6(){if(M6)return bf;M6=1;var e=CQ(),t=Bo(),n=It(),r=Ai(),i=yc(),o=Vo(),a=Object.prototype,s=a.hasOwnProperty;function c(l,u){var h=n(l),d=!h&&t(l),f=!h&&!d&&r(l),g=!h&&!d&&!f&&o(l),y=h||d||f||g,m=y?e(l.length,String):[],v=m.length;for(var b in l)(u||s.call(l,b))&&!(y&&(b=="length"||f&&(b=="offset"||b=="parent")||g&&(b=="buffer"||b=="byteLength"||b=="byteOffset")||i(b,v)))&&m.push(b);return m}return bf=c,bf}var _f,I6;function bc(){if(I6)return _f;I6=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return _f=t,_f}var xf,A6;function T6(){if(A6)return xf;A6=1;function e(t,n){return function(r){return t(n(r))}}return xf=e,xf}var wf,k6;function EQ(){if(k6)return wf;k6=1;var e=T6(),t=e(Object.keys,Object);return wf=t,wf}var Pf,R6;function $f(){if(R6)return Pf;R6=1;var e=bc(),t=EQ(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var a=[];for(var s in Object(o))r.call(o,s)&&s!="constructor"&&a.push(s);return a}return Pf=i,Pf}var Cf,L6;function Gn(){if(L6)return Cf;L6=1;var e=jo(),t=pf();function n(r){return r!=null&&t(r.length)&&!e(r)}return Cf=n,Cf}var Of,z6;function dr(){if(z6)return Of;z6=1;var e=E6(),t=$f(),n=Gn();function r(i){return n(i)?e(i):t(i)}return Of=r,Of}var Sf,N6;function IQ(){if(N6)return Sf;N6=1;var e=Fo(),t=dr();function n(r,i){return r&&e(i,t(i),r)}return Sf=n,Sf}var Mf,D6;function AQ(){if(D6)return Mf;D6=1;function e(t){var n=[];if(t!=null)for(var r in Object(t))n.push(r);return n}return Mf=e,Mf}var Ef,H6;function TQ(){if(H6)return Ef;H6=1;var e=un(),t=bc(),n=AQ(),r=Object.prototype,i=r.hasOwnProperty;function o(a){if(!e(a))return n(a);var s=t(a),c=[];for(var l in a)l=="constructor"&&(s||!i.call(a,l))||c.push(l);return c}return Ef=o,Ef}var If,q6;function Gr(){if(q6)return If;q6=1;var e=E6(),t=TQ(),n=Gn();function r(i){return n(i)?e(i,!0):t(i)}return If=r,If}var Af,j6;function kQ(){if(j6)return Af;j6=1;var e=Fo(),t=Gr();function n(r,i){return r&&e(i,t(i),r)}return Af=n,Af}var Yo={exports:{}};Yo.exports;var F6;function B6(){return F6||(F6=1,(function(e,t){var n=vn(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,a=o?n.Buffer:void 0,s=a?a.allocUnsafe:void 0;function c(l,u){if(u)return l.slice();var h=l.length,d=s?s(h):new l.constructor(h);return l.copy(d),d}e.exports=c})(Yo,Yo.exports)),Yo.exports}var Tf,W6;function G6(){if(W6)return Tf;W6=1;function e(t,n){var r=-1,i=t.length;for(n||(n=Array(i));++r<i;)n[r]=t[r];return n}return Tf=e,Tf}var kf,V6;function Y6(){if(V6)return kf;V6=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,a=[];++r<i;){var s=t[r];n(s,r,t)&&(a[o++]=s)}return a}return kf=e,kf}var Rf,X6;function U6(){if(X6)return Rf;X6=1;function e(){return[]}return Rf=e,Rf}var Lf,K6;function zf(){if(K6)return Lf;K6=1;var e=Y6(),t=U6(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(a){return a==null?[]:(a=Object(a),e(i(a),function(s){return r.call(a,s)}))}:t;return Lf=o,Lf}var Nf,Z6;function RQ(){if(Z6)return Nf;Z6=1;var e=Fo(),t=zf();function n(r,i){return e(r,t(r),i)}return Nf=n,Nf}var Df,Q6;function Hf(){if(Q6)return Df;Q6=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return Df=e,Df}var qf,J6;function _c(){if(J6)return qf;J6=1;var e=T6(),t=e(Object.getPrototypeOf,Object);return qf=t,qf}var jf,e7;function t7(){if(e7)return jf;e7=1;var e=Hf(),t=_c(),n=zf(),r=U6(),i=Object.getOwnPropertySymbols,o=i?function(a){for(var s=[];a;)e(s,n(a)),a=t(a);return s}:r;return jf=o,jf}var Ff,n7;function LQ(){if(n7)return Ff;n7=1;var e=Fo(),t=t7();function n(r,i){return e(r,t(r),i)}return Ff=n,Ff}var Bf,r7;function i7(){if(r7)return Bf;r7=1;var e=Hf(),t=It();function n(r,i,o){var a=i(r);return t(r)?a:e(a,o(r))}return Bf=n,Bf}var Wf,o7;function a7(){if(o7)return Wf;o7=1;var e=i7(),t=zf(),n=dr();function r(i){return e(i,n,t)}return Wf=r,Wf}var Gf,s7;function zQ(){if(s7)return Gf;s7=1;var e=i7(),t=t7(),n=Gr();function r(i){return e(i,n,t)}return Gf=r,Gf}var Vf,c7;function NQ(){if(c7)return Vf;c7=1;var e=Wr(),t=vn(),n=e(t,"DataView");return Vf=n,Vf}var Yf,l7;function DQ(){if(l7)return Yf;l7=1;var e=Wr(),t=vn(),n=e(t,"Promise");return Yf=n,Yf}var Xf,u7;function h7(){if(u7)return Xf;u7=1;var e=Wr(),t=vn(),n=e(t,"Set");return Xf=n,Xf}var Uf,d7;function HQ(){if(d7)return Uf;d7=1;var e=Wr(),t=vn(),n=e(t,"WeakMap");return Uf=n,Uf}var Kf,f7;function Ti(){if(f7)return Kf;f7=1;var e=NQ(),t=Rd(),n=DQ(),r=h7(),i=HQ(),o=Br(),a=j5(),s="[object Map]",c="[object Object]",l="[object Promise]",u="[object Set]",h="[object WeakMap]",d="[object DataView]",f=a(e),g=a(t),y=a(n),m=a(r),v=a(i),b=o;return(e&&b(new e(new ArrayBuffer(1)))!=d||t&&b(new t)!=s||n&&b(n.resolve())!=l||r&&b(new r)!=u||i&&b(new i)!=h)&&(b=function(_){var x=o(_),w=x==c?_.constructor:void 0,P=w?a(w):"";if(P)switch(P){case f:return d;case g:return s;case y:return l;case m:return u;case v:return h}return x}),Kf=b,Kf}var Zf,p7;function qQ(){if(p7)return Zf;p7=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r){var i=r.length,o=new r.constructor(i);return i&&typeof r[0]=="string"&&t.call(r,"index")&&(o.index=r.index,o.input=r.input),o}return Zf=n,Zf}var Qf,g7;function m7(){if(g7)return Qf;g7=1;var e=vn(),t=e.Uint8Array;return Qf=t,Qf}var Jf,y7;function ep(){if(y7)return Jf;y7=1;var e=m7();function t(n){var r=new n.constructor(n.byteLength);return new e(r).set(new e(n)),r}return Jf=t,Jf}var tp,v7;function jQ(){if(v7)return tp;v7=1;var e=ep();function t(n,r){var i=r?e(n.buffer):n.buffer;return new n.constructor(i,n.byteOffset,n.byteLength)}return tp=t,tp}var np,b7;function FQ(){if(b7)return np;b7=1;var e=/\w*$/;function t(n){var r=new n.constructor(n.source,e.exec(n));return r.lastIndex=n.lastIndex,r}return np=t,np}var rp,_7;function BQ(){if(_7)return rp;_7=1;var e=Ii(),t=e?e.prototype:void 0,n=t?t.valueOf:void 0;function r(i){return n?Object(n.call(i)):{}}return rp=r,rp}var ip,x7;function w7(){if(x7)return ip;x7=1;var e=ep();function t(n,r){var i=r?e(n.buffer):n.buffer;return new n.constructor(i,n.byteOffset,n.length)}return ip=t,ip}var op,P7;function WQ(){if(P7)return op;P7=1;var e=ep(),t=jQ(),n=FQ(),r=BQ(),i=w7(),o="[object Boolean]",a="[object Date]",s="[object Map]",c="[object Number]",l="[object RegExp]",u="[object Set]",h="[object String]",d="[object Symbol]",f="[object ArrayBuffer]",g="[object DataView]",y="[object Float32Array]",m="[object Float64Array]",v="[object Int8Array]",b="[object Int16Array]",_="[object Int32Array]",x="[object Uint8Array]",w="[object Uint8ClampedArray]",P="[object Uint16Array]",$="[object Uint32Array]";function C(M,S,E){var A=M.constructor;switch(S){case f:return e(M);case o:case a:return new A(+M);case g:return t(M,E);case y:case m:case v:case b:case _:case x:case w:case P:case $:return i(M,E);case s:return new A;case c:case h:return new A(M);case l:return n(M);case u:return new A;case d:return r(M)}}return op=C,op}var ap,$7;function C7(){if($7)return ap;$7=1;var e=un(),t=Object.create,n=(function(){function r(){}return function(i){if(!e(i))return{};if(t)return t(i);r.prototype=i;var o=new r;return r.prototype=void 0,o}})();return ap=n,ap}var sp,O7;function S7(){if(O7)return sp;O7=1;var e=C7(),t=_c(),n=bc();function r(i){return typeof i.constructor=="function"&&!n(i)?e(t(i)):{}}return sp=r,sp}var cp,M7;function GQ(){if(M7)return cp;M7=1;var e=Ti(),t=An(),n="[object Map]";function r(i){return t(i)&&e(i)==n}return cp=r,cp}var lp,E7;function VQ(){if(E7)return lp;E7=1;var e=GQ(),t=vc(),n=yf(),r=n&&n.isMap,i=r?t(r):e;return lp=i,lp}var up,I7;function YQ(){if(I7)return up;I7=1;var e=Ti(),t=An(),n="[object Set]";function r(i){return t(i)&&e(i)==n}return up=r,up}var hp,A7;function XQ(){if(A7)return hp;A7=1;var e=YQ(),t=vc(),n=yf(),r=n&&n.isSet,i=r?t(r):e;return hp=i,hp}var dp,T7;function k7(){if(T7)return dp;T7=1;var e=pc(),t=ef(),n=mc(),r=IQ(),i=kQ(),o=B6(),a=G6(),s=RQ(),c=LQ(),l=a7(),u=zQ(),h=Ti(),d=qQ(),f=WQ(),g=S7(),y=It(),m=Ai(),v=VQ(),b=un(),_=XQ(),x=dr(),w=Gr(),P=1,$=2,C=4,M="[object Arguments]",S="[object Array]",E="[object Boolean]",A="[object Date]",O="[object Error]",T="[object Function]",F="[object GeneratorFunction]",z="[object Map]",j="[object Number]",D="[object Object]",W="[object RegExp]",B="[object Set]",X="[object String]",H="[object Symbol]",k="[object WeakMap]",I="[object ArrayBuffer]",R="[object DataView]",N="[object Float32Array]",q="[object Float64Array]",G="[object Int8Array]",U="[object Int16Array]",K="[object Int32Array]",oe="[object Uint8Array]",te="[object Uint8ClampedArray]",ae="[object Uint16Array]",Z="[object Uint32Array]",ee={};ee[M]=ee[S]=ee[I]=ee[R]=ee[E]=ee[A]=ee[N]=ee[q]=ee[G]=ee[U]=ee[K]=ee[z]=ee[j]=ee[D]=ee[W]=ee[B]=ee[X]=ee[H]=ee[oe]=ee[te]=ee[ae]=ee[Z]=!0,ee[O]=ee[T]=ee[k]=!1;function ue(ne,J,ie,re,ce,pe){var he,ge=J&P,de=J&$,we=J&C;if(ie&&(he=ce?ie(ne,re,ce,pe):ie(ne)),he!==void 0)return he;if(!b(ne))return ne;var Se=y(ne);if(Se){if(he=d(ne),!ge)return a(ne,he)}else{var Ie=h(ne),$e=Ie==T||Ie==F;if(m(ne))return o(ne,ge);if(Ie==D||Ie==M||$e&&!ce){if(he=de||$e?{}:g(ne),!ge)return de?c(ne,i(he,ne)):s(ne,r(he,ne))}else{if(!ee[Ie])return ce?ne:{};he=f(ne,Ie,ge)}}pe||(pe=new e);var Le=pe.get(ne);if(Le)return Le;pe.set(ne,he),_(ne)?ne.forEach(function(ye){he.add(ue(ye,J,ie,ye,ne,pe))}):v(ne)&&ne.forEach(function(ye,xe){he.set(xe,ue(ye,J,ie,xe,ne,pe))});var je=we?de?u:l:de?w:x,Fe=Se?void 0:je(ne);return t(Fe||ne,function(ye,xe){Fe&&(xe=ye,ye=ne[xe]),n(he,xe,ue(ye,J,ie,xe,ne,pe))}),he}return dp=ue,dp}var fp,R7;function UQ(){if(R7)return fp;R7=1;var e=k7(),t=4;function n(r){return e(r,t)}return fp=n,fp}var pp,L7;function gp(){if(L7)return pp;L7=1;function e(t){return function(){return t}}return pp=e,pp}var mp,z7;function KQ(){if(z7)return mp;z7=1;function e(t){return function(n,r,i){for(var o=-1,a=Object(n),s=i(n),c=s.length;c--;){var l=s[t?c:++o];if(r(a[l],l,a)===!1)break}return n}}return mp=e,mp}var yp,N7;function vp(){if(N7)return yp;N7=1;var e=KQ(),t=e();return yp=t,yp}var bp,D7;function _p(){if(D7)return bp;D7=1;var e=vp(),t=dr();function n(r,i){return r&&e(r,i,t)}return bp=n,bp}var xp,H7;function ZQ(){if(H7)return xp;H7=1;var e=Gn();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var a=i.length,s=r?a:-1,c=Object(i);(r?s--:++s<a)&&o(c[s],s,c)!==!1;);return i}}return xp=t,xp}var wp,q7;function xc(){if(q7)return wp;q7=1;var e=_p(),t=ZQ(),n=t(e);return wp=n,wp}var Pp,j7;function Vr(){if(j7)return Pp;j7=1;function e(t){return t}return Pp=e,Pp}var $p,F7;function B7(){if(F7)return $p;F7=1;var e=Vr();function t(n){return typeof n=="function"?n:e}return $p=t,$p}var Cp,W7;function G7(){if(W7)return Cp;W7=1;var e=ef(),t=xc(),n=B7(),r=It();function i(o,a){var s=r(o)?e:t;return s(o,n(a))}return Cp=i,Cp}var Op,V7;function Y7(){return V7||(V7=1,Op=G7()),Op}var Sp,X7;function QQ(){if(X7)return Sp;X7=1;var e=xc();function t(n,r){var i=[];return e(n,function(o,a,s){r(o,a,s)&&i.push(o)}),i}return Sp=t,Sp}var Mp,U7;function JQ(){if(U7)return Mp;U7=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Mp=t,Mp}var Ep,K7;function eJ(){if(K7)return Ep;K7=1;function e(t){return this.__data__.has(t)}return Ep=e,Ep}var Ip,Z7;function Q7(){if(Z7)return Ip;Z7=1;var e=Kd(),t=JQ(),n=eJ();function r(i){var o=-1,a=i==null?0:i.length;for(this.__data__=new e;++o<a;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Ip=r,Ip}var Ap,J7;function tJ(){if(J7)return Ap;J7=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return Ap=e,Ap}var Tp,e9;function t9(){if(e9)return Tp;e9=1;function e(t,n){return t.has(n)}return Tp=e,Tp}var kp,n9;function r9(){if(n9)return kp;n9=1;var e=Q7(),t=tJ(),n=t9(),r=1,i=2;function o(a,s,c,l,u,h){var d=c&r,f=a.length,g=s.length;if(f!=g&&!(d&&g>f))return!1;var y=h.get(a),m=h.get(s);if(y&&m)return y==s&&m==a;var v=-1,b=!0,_=c&i?new e:void 0;for(h.set(a,s),h.set(s,a);++v<f;){var x=a[v],w=s[v];if(l)var P=d?l(w,x,v,s,a,h):l(x,w,v,a,s,h);if(P!==void 0){if(P)continue;b=!1;break}if(_){if(!t(s,function($,C){if(!n(_,C)&&(x===$||u(x,$,c,l,h)))return _.push(C)})){b=!1;break}}else if(!(x===w||u(x,w,c,l,h))){b=!1;break}}return h.delete(a),h.delete(s),b}return kp=o,kp}var Rp,i9;function nJ(){if(i9)return Rp;i9=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return Rp=e,Rp}var Lp,o9;function zp(){if(o9)return Lp;o9=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return Lp=e,Lp}var Np,a9;function rJ(){if(a9)return Np;a9=1;var e=Ii(),t=m7(),n=Ei(),r=r9(),i=nJ(),o=zp(),a=1,s=2,c="[object Boolean]",l="[object Date]",u="[object Error]",h="[object Map]",d="[object Number]",f="[object RegExp]",g="[object Set]",y="[object String]",m="[object Symbol]",v="[object ArrayBuffer]",b="[object DataView]",_=e?e.prototype:void 0,x=_?_.valueOf:void 0;function w(P,$,C,M,S,E,A){switch(C){case b:if(P.byteLength!=$.byteLength||P.byteOffset!=$.byteOffset)return!1;P=P.buffer,$=$.buffer;case v:return!(P.byteLength!=$.byteLength||!E(new t(P),new t($)));case c:case l:case d:return n(+P,+$);case u:return P.name==$.name&&P.message==$.message;case f:case y:return P==$+"";case h:var O=i;case g:var T=M&a;if(O||(O=o),P.size!=$.size&&!T)return!1;var F=A.get(P);if(F)return F==$;M|=s,A.set(P,$);var z=r(O(P),O($),M,S,E,A);return A.delete(P),z;case m:if(x)return x.call(P)==x.call($)}return!1}return Np=w,Np}var Dp,s9;function iJ(){if(s9)return Dp;s9=1;var e=a7(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,a,s,c,l,u){var h=s&t,d=e(o),f=d.length,g=e(a),y=g.length;if(f!=y&&!h)return!1;for(var m=f;m--;){var v=d[m];if(!(h?v in a:r.call(a,v)))return!1}var b=u.get(o),_=u.get(a);if(b&&_)return b==a&&_==o;var x=!0;u.set(o,a),u.set(a,o);for(var w=h;++m<f;){v=d[m];var P=o[v],$=a[v];if(c)var C=h?c($,P,v,a,o,u):c(P,$,v,o,a,u);if(!(C===void 0?P===$||l(P,$,s,c,u):C)){x=!1;break}w||(w=v=="constructor")}if(x&&!w){var M=o.constructor,S=a.constructor;M!=S&&"constructor"in o&&"constructor"in a&&!(typeof M=="function"&&M instanceof M&&typeof S=="function"&&S instanceof S)&&(x=!1)}return u.delete(o),u.delete(a),x}return Dp=i,Dp}var Hp,c9;function oJ(){if(c9)return Hp;c9=1;var e=pc(),t=r9(),n=rJ(),r=iJ(),i=Ti(),o=It(),a=Ai(),s=Vo(),c=1,l="[object Arguments]",u="[object Array]",h="[object Object]",d=Object.prototype,f=d.hasOwnProperty;function g(y,m,v,b,_,x){var w=o(y),P=o(m),$=w?u:i(y),C=P?u:i(m);$=$==l?h:$,C=C==l?h:C;var M=$==h,S=C==h,E=$==C;if(E&&a(y)){if(!a(m))return!1;w=!0,M=!1}if(E&&!M)return x||(x=new e),w||s(y)?t(y,m,v,b,_,x):n(y,m,$,v,b,_,x);if(!(v&c)){var A=M&&f.call(y,"__wrapped__"),O=S&&f.call(m,"__wrapped__");if(A||O){var T=A?y.value():y,F=O?m.value():m;return x||(x=new e),_(T,F,v,b,x)}}return E?(x||(x=new e),r(y,m,v,b,_,x)):!1}return Hp=g,Hp}var qp,l9;function u9(){if(l9)return qp;l9=1;var e=oJ(),t=An();function n(r,i,o,a,s){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,a,n,s)}return qp=n,qp}var jp,h9;function aJ(){if(h9)return jp;h9=1;var e=pc(),t=u9(),n=1,r=2;function i(o,a,s,c){var l=s.length,u=l,h=!c;if(o==null)return!u;for(o=Object(o);l--;){var d=s[l];if(h&&d[2]?d[1]!==o[d[0]]:!(d[0]in o))return!1}for(;++l<u;){d=s[l];var f=d[0],g=o[f],y=d[1];if(h&&d[2]){if(g===void 0&&!(f in o))return!1}else{var m=new e;if(c)var v=c(g,y,f,o,a,m);if(!(v===void 0?t(y,g,n|r,c,m):v))return!1}}return!0}return jp=i,jp}var Fp,d9;function f9(){if(d9)return Fp;d9=1;var e=un();function t(n){return n===n&&!e(n)}return Fp=t,Fp}var Bp,p9;function sJ(){if(p9)return Bp;p9=1;var e=f9(),t=dr();function n(r){for(var i=t(r),o=i.length;o--;){var a=i[o],s=r[a];i[o]=[a,s,e(s)]}return i}return Bp=n,Bp}var Wp,g9;function m9(){if(g9)return Wp;g9=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return Wp=e,Wp}var Gp,y9;function cJ(){if(y9)return Gp;y9=1;var e=aJ(),t=sJ(),n=m9();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(a){return a===i||e(a,i,o)}}return Gp=r,Gp}var Vp,v9;function ki(){if(v9)return Vp;v9=1;var e=Br(),t=An(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return Vp=r,Vp}var Yp,b9;function Xp(){if(b9)return Yp;b9=1;var e=It(),t=ki(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,a){if(e(o))return!1;var s=typeof o;return s=="number"||s=="symbol"||s=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||a!=null&&o in Object(a)}return Yp=i,Yp}var Up,_9;function lJ(){if(_9)return Up;_9=1;var e=Kd(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var a=arguments,s=i?i.apply(this,a):a[0],c=o.cache;if(c.has(s))return c.get(s);var l=r.apply(this,a);return o.cache=c.set(s,l)||c,l};return o.cache=new(n.Cache||e),o}return n.Cache=e,Up=n,Up}var Kp,x9;function uJ(){if(x9)return Kp;x9=1;var e=lJ(),t=500;function n(r){var i=e(r,function(a){return o.size===t&&o.clear(),a}),o=i.cache;return i}return Kp=n,Kp}var Zp,w9;function hJ(){if(w9)return Zp;w9=1;var e=uJ(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(a,s,c,l){o.push(c?l.replace(n,"$1"):s||a)}),o});return Zp=r,Zp}var Qp,P9;function wc(){if(P9)return Qp;P9=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return Qp=e,Qp}var Jp,$9;function dJ(){if($9)return Jp;$9=1;var e=Ii(),t=wc(),n=It(),r=ki(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function a(s){if(typeof s=="string")return s;if(n(s))return t(s,a)+"";if(r(s))return o?o.call(s):"";var c=s+"";return c=="0"&&1/s==-1/0?"-0":c}return Jp=a,Jp}var e0,C9;function O9(){if(C9)return e0;C9=1;var e=dJ();function t(n){return n==null?"":e(n)}return e0=t,e0}var t0,S9;function Pc(){if(S9)return t0;S9=1;var e=It(),t=Xp(),n=hJ(),r=O9();function i(o,a){return e(o)?o:t(o,a)?[o]:n(r(o))}return t0=i,t0}var n0,M9;function Xo(){if(M9)return n0;M9=1;var e=ki();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return n0=t,n0}var r0,E9;function $c(){if(E9)return r0;E9=1;var e=Pc(),t=Xo();function n(r,i){i=e(i,r);for(var o=0,a=i.length;r!=null&&o<a;)r=r[t(i[o++])];return o&&o==a?r:void 0}return r0=n,r0}var i0,I9;function fJ(){if(I9)return i0;I9=1;var e=$c();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return i0=t,i0}var o0,A9;function pJ(){if(A9)return o0;A9=1;function e(t,n){return t!=null&&n in Object(t)}return o0=e,o0}var a0,T9;function k9(){if(T9)return a0;T9=1;var e=Pc(),t=Bo(),n=It(),r=yc(),i=pf(),o=Xo();function a(s,c,l){c=e(c,s);for(var u=-1,h=c.length,d=!1;++u<h;){var f=o(c[u]);if(!(d=s!=null&&l(s,f)))break;s=s[f]}return d||++u!=h?d:(h=s==null?0:s.length,!!h&&i(h)&&r(f,h)&&(n(s)||t(s)))}return a0=a,a0}var s0,R9;function L9(){if(R9)return s0;R9=1;var e=pJ(),t=k9();function n(r,i){return r!=null&&t(r,i,e)}return s0=n,s0}var c0,z9;function gJ(){if(z9)return c0;z9=1;var e=u9(),t=fJ(),n=L9(),r=Xp(),i=f9(),o=m9(),a=Xo(),s=1,c=2;function l(u,h){return r(u)&&i(h)?o(a(u),h):function(d){var f=t(d,u);return f===void 0&&f===h?n(d,u):e(h,f,s|c)}}return c0=l,c0}var l0,N9;function D9(){if(N9)return l0;N9=1;function e(t){return function(n){return n==null?void 0:n[t]}}return l0=e,l0}var u0,H9;function mJ(){if(H9)return u0;H9=1;var e=$c();function t(n){return function(r){return e(r,n)}}return u0=t,u0}var h0,q9;function yJ(){if(q9)return h0;q9=1;var e=D9(),t=mJ(),n=Xp(),r=Xo();function i(o){return n(o)?e(r(o)):t(o)}return h0=i,h0}var d0,j9;function Vn(){if(j9)return d0;j9=1;var e=cJ(),t=gJ(),n=Vr(),r=It(),i=yJ();function o(a){return typeof a=="function"?a:a==null?n:typeof a=="object"?r(a)?t(a[0],a[1]):e(a):i(a)}return d0=o,d0}var f0,F9;function B9(){if(F9)return f0;F9=1;var e=Y6(),t=QQ(),n=Vn(),r=It();function i(o,a){var s=r(o)?e:t;return s(o,n(a,3))}return f0=i,f0}var p0,W9;function vJ(){if(W9)return p0;W9=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r,i){return r!=null&&t.call(r,i)}return p0=n,p0}var g0,G9;function V9(){if(G9)return g0;G9=1;var e=vJ(),t=k9();function n(r,i){return r!=null&&t(r,i,e)}return g0=n,g0}var m0,Y9;function bJ(){if(Y9)return m0;Y9=1;var e=$f(),t=Ti(),n=Bo(),r=It(),i=Gn(),o=Ai(),a=bc(),s=Vo(),c="[object Map]",l="[object Set]",u=Object.prototype,h=u.hasOwnProperty;function d(f){if(f==null)return!0;if(i(f)&&(r(f)||typeof f=="string"||typeof f.splice=="function"||o(f)||s(f)||n(f)))return!f.length;var g=t(f);if(g==c||g==l)return!f.size;if(a(f))return!e(f).length;for(var y in f)if(h.call(f,y))return!1;return!0}return m0=d,m0}var y0,X9;function U9(){if(X9)return y0;X9=1;function e(t){return t===void 0}return y0=e,y0}var v0,K9;function Z9(){if(K9)return v0;K9=1;var e=xc(),t=Gn();function n(r,i){var o=-1,a=t(r)?Array(r.length):[];return e(r,function(s,c,l){a[++o]=i(s,c,l)}),a}return v0=n,v0}var b0,Q9;function J9(){if(Q9)return b0;Q9=1;var e=wc(),t=Vn(),n=Z9(),r=It();function i(o,a){var s=r(o)?e:n;return s(o,t(a,3))}return b0=i,b0}var _0,e8;function _J(){if(e8)return _0;e8=1;function e(t,n,r,i){var o=-1,a=t==null?0:t.length;for(i&&a&&(r=t[++o]);++o<a;)r=n(r,t[o],o,t);return r}return _0=e,_0}var x0,t8;function xJ(){if(t8)return x0;t8=1;function e(t,n,r,i,o){return o(t,function(a,s,c){r=i?(i=!1,a):n(r,a,s,c)}),r}return x0=e,x0}var w0,n8;function r8(){if(n8)return w0;n8=1;var e=_J(),t=xc(),n=Vn(),r=xJ(),i=It();function o(a,s,c){var l=i(a)?e:r,u=arguments.length<3;return l(a,n(s,4),c,u,t)}return w0=o,w0}var P0,i8;function wJ(){if(i8)return P0;i8=1;var e=Br(),t=It(),n=An(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return P0=i,P0}var $0,o8;function PJ(){if(o8)return $0;o8=1;var e=D9(),t=e("length");return $0=t,$0}var C0,a8;function $J(){if(a8)return C0;a8=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",a="\\u200d",s=RegExp("["+a+e+i+o+"]");function c(l){return s.test(l)}return C0=c,C0}var O0,s8;function CJ(){if(s8)return O0;s8=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",a="["+e+"]",s="["+i+"]",c="\\ud83c[\\udffb-\\udfff]",l="(?:"+s+"|"+c+")",u="[^"+e+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",d="[\\ud800-\\udbff][\\udc00-\\udfff]",f="\\u200d",g=l+"?",y="["+o+"]?",m="(?:"+f+"(?:"+[u,h,d].join("|")+")"+y+g+")*",v=y+g+m,b="(?:"+[u+s+"?",s,h,d,a].join("|")+")",_=RegExp(c+"(?="+c+")|"+b+v,"g");function x(w){for(var P=_.lastIndex=0;_.test(w);)++P;return P}return O0=x,O0}var S0,c8;function OJ(){if(c8)return S0;c8=1;var e=PJ(),t=$J(),n=CJ();function r(i){return t(i)?n(i):e(i)}return S0=r,S0}var M0,l8;function SJ(){if(l8)return M0;l8=1;var e=$f(),t=Ti(),n=Gn(),r=wJ(),i=OJ(),o="[object Map]",a="[object Set]";function s(c){if(c==null)return 0;if(n(c))return r(c)?i(c):c.length;var l=t(c);return l==o||l==a?c.size:e(c).length}return M0=s,M0}var E0,u8;function MJ(){if(u8)return E0;u8=1;var e=ef(),t=C7(),n=_p(),r=Vn(),i=_c(),o=It(),a=Ai(),s=jo(),c=un(),l=Vo();function u(h,d,f){var g=o(h),y=g||a(h)||l(h);if(d=r(d,4),f==null){var m=h&&h.constructor;y?f=g?new m:[]:c(h)?f=s(m)?t(i(h)):{}:f={}}return(y?e:n)(h,function(v,b,_){return d(f,v,b,_)}),f}return E0=u,E0}var I0,h8;function EJ(){if(h8)return I0;h8=1;var e=Ii(),t=Bo(),n=It(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return I0=i,I0}var A0,d8;function T0(){if(d8)return A0;d8=1;var e=Hf(),t=EJ();function n(r,i,o,a,s){var c=-1,l=r.length;for(o||(o=t),s||(s=[]);++c<l;){var u=r[c];i>0&&o(u)?i>1?n(u,i-1,o,a,s):e(s,u):a||(s[s.length]=u)}return s}return A0=n,A0}var k0,f8;function IJ(){if(f8)return k0;f8=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return k0=e,k0}var R0,p8;function g8(){if(p8)return R0;p8=1;var e=IJ(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var a=arguments,s=-1,c=t(a.length-i,0),l=Array(c);++s<c;)l[s]=a[i+s];s=-1;for(var u=Array(i+1);++s<i;)u[s]=a[s];return u[i]=o(l),e(r,this,u)}}return R0=n,R0}var L0,m8;function AJ(){if(m8)return L0;m8=1;var e=gp(),t=h6(),n=Vr(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return L0=r,L0}var z0,y8;function TJ(){if(y8)return z0;y8=1;var e=800,t=16,n=Date.now;function r(i){var o=0,a=0;return function(){var s=n(),c=t-(s-a);if(a=s,c>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return z0=r,z0}var N0,v8;function b8(){if(v8)return N0;v8=1;var e=AJ(),t=TJ(),n=t(e);return N0=n,N0}var D0,_8;function Cc(){if(_8)return D0;_8=1;var e=Vr(),t=g8(),n=b8();function r(i,o){return n(t(i,o,e),i+"")}return D0=r,D0}var H0,x8;function w8(){if(x8)return H0;x8=1;function e(t,n,r,i){for(var o=t.length,a=r+(i?1:-1);i?a--:++a<o;)if(n(t[a],a,t))return a;return-1}return H0=e,H0}var q0,P8;function kJ(){if(P8)return q0;P8=1;function e(t){return t!==t}return q0=e,q0}var j0,$8;function RJ(){if($8)return j0;$8=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return j0=e,j0}var F0,C8;function LJ(){if(C8)return F0;C8=1;var e=w8(),t=kJ(),n=RJ();function r(i,o,a){return o===o?n(i,o,a):e(i,t,a)}return F0=r,F0}var B0,O8;function zJ(){if(O8)return B0;O8=1;var e=LJ();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return B0=t,B0}var W0,S8;function NJ(){if(S8)return W0;S8=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return W0=e,W0}var G0,M8;function DJ(){if(M8)return G0;M8=1;function e(){}return G0=e,G0}var V0,E8;function HJ(){if(E8)return V0;E8=1;var e=h7(),t=DJ(),n=zp(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return V0=i,V0}var Y0,I8;function qJ(){if(I8)return Y0;I8=1;var e=Q7(),t=zJ(),n=NJ(),r=t9(),i=HJ(),o=zp(),a=200;function s(c,l,u){var h=-1,d=t,f=c.length,g=!0,y=[],m=y;if(u)g=!1,d=n;else if(f>=a){var v=l?null:i(c);if(v)return o(v);g=!1,d=r,m=new e}else m=l?[]:y;e:for(;++h<f;){var b=c[h],_=l?l(b):b;if(b=u||b!==0?b:0,g&&_===_){for(var x=m.length;x--;)if(m[x]===_)continue e;l&&m.push(_),y.push(b)}else d(m,_,u)||(m!==y&&m.push(_),y.push(b))}return y}return Y0=s,Y0}var X0,A8;function T8(){if(A8)return X0;A8=1;var e=Gn(),t=An();function n(r){return t(r)&&e(r)}return X0=n,X0}var U0,k8;function jJ(){if(k8)return U0;k8=1;var e=T0(),t=Cc(),n=qJ(),r=T8(),i=t(function(o){return n(e(o,1,r,!0))});return U0=i,U0}var K0,R8;function FJ(){if(R8)return K0;R8=1;var e=wc();function t(n,r){return e(r,function(i){return n[i]})}return K0=t,K0}var Z0,L8;function z8(){if(L8)return Z0;L8=1;var e=FJ(),t=dr();function n(r){return r==null?[]:e(r,t(r))}return Z0=n,Z0}var Q0,N8;function hn(){if(N8)return Q0;N8=1;var e;if(typeof ad=="function")try{e={clone:UQ(),constant:gp(),each:Y7(),filter:B9(),has:V9(),isArray:It(),isEmpty:bJ(),isFunction:jo(),isUndefined:U9(),keys:dr(),map:J9(),reduce:r8(),size:SJ(),transform:MJ(),union:jJ(),values:z8()}}catch(t){}return e||(e=window._),Q0=e,Q0}var J0,D8;function eg(){if(D8)return J0;D8=1;var e=hn();J0=i;var t="\0",n="\0",r="";function i(u){this._isDirected=e.has(u,"directed")?u.directed:!0,this._isMultigraph=e.has(u,"multigraph")?u.multigraph:!1,this._isCompound=e.has(u,"compound")?u.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[n]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}i.prototype._nodeCount=0,i.prototype._edgeCount=0,i.prototype.isDirected=function(){return this._isDirected},i.prototype.isMultigraph=function(){return this._isMultigraph},i.prototype.isCompound=function(){return this._isCompound},i.prototype.setGraph=function(u){return this._label=u,this},i.prototype.graph=function(){return this._label},i.prototype.setDefaultNodeLabel=function(u){return e.isFunction(u)||(u=e.constant(u)),this._defaultNodeLabelFn=u,this},i.prototype.nodeCount=function(){return this._nodeCount},i.prototype.nodes=function(){return e.keys(this._nodes)},i.prototype.sources=function(){var u=this;return e.filter(this.nodes(),function(h){return e.isEmpty(u._in[h])})},i.prototype.sinks=function(){var u=this;return e.filter(this.nodes(),function(h){return e.isEmpty(u._out[h])})},i.prototype.setNodes=function(u,h){var d=arguments,f=this;return e.each(u,function(g){d.length>1?f.setNode(g,h):f.setNode(g)}),this},i.prototype.setNode=function(u,h){return e.has(this._nodes,u)?(arguments.length>1&&(this._nodes[u]=h),this):(this._nodes[u]=arguments.length>1?h:this._defaultNodeLabelFn(u),this._isCompound&&(this._parent[u]=n,this._children[u]={},this._children[n][u]=!0),this._in[u]={},this._preds[u]={},this._out[u]={},this._sucs[u]={},++this._nodeCount,this)},i.prototype.node=function(u){return this._nodes[u]},i.prototype.hasNode=function(u){return e.has(this._nodes,u)},i.prototype.removeNode=function(u){var h=this;if(e.has(this._nodes,u)){var d=function(f){h.removeEdge(h._edgeObjs[f])};delete this._nodes[u],this._isCompound&&(this._removeFromParentsChildList(u),delete this._parent[u],e.each(this.children(u),function(f){h.setParent(f)}),delete this._children[u]),e.each(e.keys(this._in[u]),d),delete this._in[u],delete this._preds[u],e.each(e.keys(this._out[u]),d),delete this._out[u],delete this._sucs[u],--this._nodeCount}return this},i.prototype.setParent=function(u,h){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(h))h=n;else{h+="";for(var d=h;!e.isUndefined(d);d=this.parent(d))if(d===u)throw new Error("Setting "+h+" as parent of "+u+" would create a cycle");this.setNode(h)}return this.setNode(u),this._removeFromParentsChildList(u),this._parent[u]=h,this._children[h][u]=!0,this},i.prototype._removeFromParentsChildList=function(u){delete this._children[this._parent[u]][u]},i.prototype.parent=function(u){if(this._isCompound){var h=this._parent[u];if(h!==n)return h}},i.prototype.children=function(u){if(e.isUndefined(u)&&(u=n),this._isCompound){var h=this._children[u];if(h)return e.keys(h)}else{if(u===n)return this.nodes();if(this.hasNode(u))return[]}},i.prototype.predecessors=function(u){var h=this._preds[u];if(h)return e.keys(h)},i.prototype.successors=function(u){var h=this._sucs[u];if(h)return e.keys(h)},i.prototype.neighbors=function(u){var h=this.predecessors(u);if(h)return e.union(h,this.successors(u))},i.prototype.isLeaf=function(u){var h;return this.isDirected()?h=this.successors(u):h=this.neighbors(u),h.length===0},i.prototype.filterNodes=function(u){var h=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});h.setGraph(this.graph());var d=this;e.each(this._nodes,function(y,m){u(m)&&h.setNode(m,y)}),e.each(this._edgeObjs,function(y){h.hasNode(y.v)&&h.hasNode(y.w)&&h.setEdge(y,d.edge(y))});var f={};function g(y){var m=d.parent(y);return m===void 0||h.hasNode(m)?(f[y]=m,m):m in f?f[m]:g(m)}return this._isCompound&&e.each(h.nodes(),function(y){h.setParent(y,g(y))}),h},i.prototype.setDefaultEdgeLabel=function(u){return e.isFunction(u)||(u=e.constant(u)),this._defaultEdgeLabelFn=u,this},i.prototype.edgeCount=function(){return this._edgeCount},i.prototype.edges=function(){return e.values(this._edgeObjs)},i.prototype.setPath=function(u,h){var d=this,f=arguments;return e.reduce(u,function(g,y){return f.length>1?d.setEdge(g,y,h):d.setEdge(g,y),y}),this},i.prototype.setEdge=function(){var u,h,d,f,g=!1,y=arguments[0];typeof y=="object"&&y!==null&&"v"in y?(u=y.v,h=y.w,d=y.name,arguments.length===2&&(f=arguments[1],g=!0)):(u=y,h=arguments[1],d=arguments[3],arguments.length>2&&(f=arguments[2],g=!0)),u=""+u,h=""+h,e.isUndefined(d)||(d=""+d);var m=s(this._isDirected,u,h,d);if(e.has(this._edgeLabels,m))return g&&(this._edgeLabels[m]=f),this;if(!e.isUndefined(d)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(u),this.setNode(h),this._edgeLabels[m]=g?f:this._defaultEdgeLabelFn(u,h,d);var v=c(this._isDirected,u,h,d);return u=v.v,h=v.w,Object.freeze(v),this._edgeObjs[m]=v,o(this._preds[h],u),o(this._sucs[u],h),this._in[h][m]=v,this._out[u][m]=v,this._edgeCount++,this},i.prototype.edge=function(u,h,d){var f=arguments.length===1?l(this._isDirected,arguments[0]):s(this._isDirected,u,h,d);return this._edgeLabels[f]},i.prototype.hasEdge=function(u,h,d){var f=arguments.length===1?l(this._isDirected,arguments[0]):s(this._isDirected,u,h,d);return e.has(this._edgeLabels,f)},i.prototype.removeEdge=function(u,h,d){var f=arguments.length===1?l(this._isDirected,arguments[0]):s(this._isDirected,u,h,d),g=this._edgeObjs[f];return g&&(u=g.v,h=g.w,delete this._edgeLabels[f],delete this._edgeObjs[f],a(this._preds[h],u),a(this._sucs[u],h),delete this._in[h][f],delete this._out[u][f],this._edgeCount--),this},i.prototype.inEdges=function(u,h){var d=this._in[u];if(d){var f=e.values(d);return h?e.filter(f,function(g){return g.v===h}):f}},i.prototype.outEdges=function(u,h){var d=this._out[u];if(d){var f=e.values(d);return h?e.filter(f,function(g){return g.w===h}):f}},i.prototype.nodeEdges=function(u,h){var d=this.inEdges(u,h);if(d)return d.concat(this.outEdges(u,h))};function o(u,h){u[h]?u[h]++:u[h]=1}function a(u,h){--u[h]||delete u[h]}function s(u,h,d,f){var g=""+h,y=""+d;if(!u&&g>y){var m=g;g=y,y=m}return g+r+y+r+(e.isUndefined(f)?t:f)}function c(u,h,d,f){var g=""+h,y=""+d;if(!u&&g>y){var m=g;g=y,y=m}var v={v:g,w:y};return f&&(v.name=f),v}function l(u,h){return s(u,h.v,h.w,h.name)}return J0}var tg,H8;function BJ(){return H8||(H8=1,tg="2.1.8"),tg}var ng,q8;function WJ(){return q8||(q8=1,ng={Graph:eg(),version:BJ()}),ng}var rg,j8;function GJ(){if(j8)return rg;j8=1;var e=hn(),t=eg();rg={write:n,read:o};function n(a){var s={options:{directed:a.isDirected(),multigraph:a.isMultigraph(),compound:a.isCompound()},nodes:r(a),edges:i(a)};return e.isUndefined(a.graph())||(s.value=e.clone(a.graph())),s}function r(a){return e.map(a.nodes(),function(s){var c=a.node(s),l=a.parent(s),u={v:s};return e.isUndefined(c)||(u.value=c),e.isUndefined(l)||(u.parent=l),u})}function i(a){return e.map(a.edges(),function(s){var c=a.edge(s),l={v:s.v,w:s.w};return e.isUndefined(s.name)||(l.name=s.name),e.isUndefined(c)||(l.value=c),l})}function o(a){var s=new t(a.options).setGraph(a.value);return e.each(a.nodes,function(c){s.setNode(c.v,c.value),c.parent&&s.setParent(c.v,c.parent)}),e.each(a.edges,function(c){s.setEdge({v:c.v,w:c.w,name:c.name},c.value)}),s}return rg}var ig,F8;function VJ(){if(F8)return ig;F8=1;var e=hn();ig=t;function t(n){var r={},i=[],o;function a(s){e.has(r,s)||(r[s]=!0,o.push(s),e.each(n.successors(s),a),e.each(n.predecessors(s),a))}return e.each(n.nodes(),function(s){o=[],a(s),o.length&&i.push(o)}),i}return ig}var og,B8;function W8(){if(B8)return og;B8=1;var e=hn();og=t;function t(){this._arr=[],this._keyIndices={}}return t.prototype.size=function(){return this._arr.length},t.prototype.keys=function(){return this._arr.map(function(n){return n.key})},t.prototype.has=function(n){return e.has(this._keyIndices,n)},t.prototype.priority=function(n){var r=this._keyIndices[n];if(r!==void 0)return this._arr[r].priority},t.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},t.prototype.add=function(n,r){var i=this._keyIndices;if(n=String(n),!e.has(i,n)){var o=this._arr,a=o.length;return i[n]=a,o.push({key:n,priority:r}),this._decrease(a),!0}return!1},t.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var n=this._arr.pop();return delete this._keyIndices[n.key],this._heapify(0),n.key},t.prototype.decrease=function(n,r){var i=this._keyIndices[n];if(r>this._arr[i].priority)throw new Error("New priority is greater than current priority. Key: "+n+" Old: "+this._arr[i].priority+" New: "+r);this._arr[i].priority=r,this._decrease(i)},t.prototype._heapify=function(n){var r=this._arr,i=2*n,o=i+1,a=n;i<r.length&&(a=r[i].priority<r[a].priority?i:a,o<r.length&&(a=r[o].priority<r[a].priority?o:a),a!==n&&(this._swap(n,a),this._heapify(a)))},t.prototype._decrease=function(n){for(var r=this._arr,i=r[n].priority,o;n!==0&&(o=n>>1,!(r[o].priority<i));)this._swap(n,o),n=o},t.prototype._swap=function(n,r){var i=this._arr,o=this._keyIndices,a=i[n],s=i[r];i[n]=s,i[r]=a,o[s.key]=n,o[a.key]=r},og}var ag,G8;function V8(){if(G8)return ag;G8=1;var e=hn(),t=W8();ag=r;var n=e.constant(1);function r(o,a,s,c){return i(o,String(a),s||n,c||function(l){return o.outEdges(l)})}function i(o,a,s,c){var l={},u=new t,h,d,f=function(g){var y=g.v!==h?g.v:g.w,m=l[y],v=s(g),b=d.distance+v;if(v<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+g+" Weight: "+v);b<m.distance&&(m.distance=b,m.predecessor=h,u.decrease(y,b))};for(o.nodes().forEach(function(g){var y=g===a?0:Number.POSITIVE_INFINITY;l[g]={distance:y},u.add(g,y)});u.size()>0&&(h=u.removeMin(),d=l[h],d.distance!==Number.POSITIVE_INFINITY);)c(h).forEach(f);return l}return ag}var sg,Y8;function YJ(){if(Y8)return sg;Y8=1;var e=V8(),t=hn();sg=n;function n(r,i,o){return t.transform(r.nodes(),function(a,s){a[s]=e(r,s,i,o)},{})}return sg}var cg,X8;function U8(){if(X8)return cg;X8=1;var e=hn();cg=t;function t(n){var r=0,i=[],o={},a=[];function s(c){var l=o[c]={onStack:!0,lowlink:r,index:r++};if(i.push(c),n.successors(c).forEach(function(d){e.has(o,d)?o[d].onStack&&(l.lowlink=Math.min(l.lowlink,o[d].index)):(s(d),l.lowlink=Math.min(l.lowlink,o[d].lowlink))}),l.lowlink===l.index){var u=[],h;do h=i.pop(),o[h].onStack=!1,u.push(h);while(c!==h);a.push(u)}}return n.nodes().forEach(function(c){e.has(o,c)||s(c)}),a}return cg}var lg,K8;function XJ(){if(K8)return lg;K8=1;var e=hn(),t=U8();lg=n;function n(r){return e.filter(t(r),function(i){return i.length>1||i.length===1&&r.hasEdge(i[0],i[0])})}return lg}var ug,Z8;function UJ(){if(Z8)return ug;Z8=1;var e=hn();ug=n;var t=e.constant(1);function n(i,o,a){return r(i,o||t,a||function(s){return i.outEdges(s)})}function r(i,o,a){var s={},c=i.nodes();return c.forEach(function(l){s[l]={},s[l][l]={distance:0},c.forEach(function(u){l!==u&&(s[l][u]={distance:Number.POSITIVE_INFINITY})}),a(l).forEach(function(u){var h=u.v===l?u.w:u.v,d=o(u);s[l][h]={distance:d,predecessor:l}})}),c.forEach(function(l){var u=s[l];c.forEach(function(h){var d=s[h];c.forEach(function(f){var g=d[l],y=u[f],m=d[f],v=g.distance+y.distance;v<m.distance&&(m.distance=v,m.predecessor=y.predecessor)})})}),s}return ug}var hg,Q8;function J8(){if(Q8)return hg;Q8=1;var e=hn();hg=t,t.CycleException=n;function t(r){var i={},o={},a=[];function s(c){if(e.has(o,c))throw new n;e.has(i,c)||(o[c]=!0,i[c]=!0,e.each(r.predecessors(c),s),delete o[c],a.push(c))}if(e.each(r.sinks(),s),e.size(i)!==r.nodeCount())throw new n;return a}function n(){}return n.prototype=new Error,hg}var dg,eP;function KJ(){if(eP)return dg;eP=1;var e=J8();dg=t;function t(n){try{e(n)}catch(r){if(r instanceof e.CycleException)return!1;throw r}return!0}return dg}var fg,tP;function nP(){if(tP)return fg;tP=1;var e=hn();fg=t;function t(r,i,o){e.isArray(i)||(i=[i]);var a=(r.isDirected()?r.successors:r.neighbors).bind(r),s=[],c={};return e.each(i,function(l){if(!r.hasNode(l))throw new Error("Graph does not have node: "+l);n(r,l,o==="post",c,a,s)}),s}function n(r,i,o,a,s,c){e.has(a,i)||(a[i]=!0,o||c.push(i),e.each(s(i),function(l){n(r,l,o,a,s,c)}),o&&c.push(i))}return fg}var pg,rP;function ZJ(){if(rP)return pg;rP=1;var e=nP();pg=t;function t(n,r){return e(n,r,"post")}return pg}var gg,iP;function QJ(){if(iP)return gg;iP=1;var e=nP();gg=t;function t(n,r){return e(n,r,"pre")}return gg}var mg,oP;function JJ(){if(oP)return mg;oP=1;var e=hn(),t=eg(),n=W8();mg=r;function r(i,o){var a=new t,s={},c=new n,l;function u(d){var f=d.v===l?d.w:d.v,g=c.priority(f);if(g!==void 0){var y=o(d);y<g&&(s[f]=l,c.decrease(f,y))}}if(i.nodeCount()===0)return a;e.each(i.nodes(),function(d){c.add(d,Number.POSITIVE_INFINITY),a.setNode(d)}),c.decrease(i.nodes()[0],0);for(var h=!1;c.size()>0;){if(l=c.removeMin(),e.has(s,l))a.setEdge(l,s[l]);else{if(h)throw new Error("Input graph is not connected: "+i);h=!0}i.nodeEdges(l).forEach(u)}return a}return mg}var yg,aP;function eee(){return aP||(aP=1,yg={components:VJ(),dijkstra:V8(),dijkstraAll:YJ(),findCycles:XJ(),floydWarshall:UJ(),isAcyclic:KJ(),postorder:ZJ(),preorder:QJ(),prim:JJ(),tarjan:U8(),topsort:J8()}),yg}var vg,sP;function tee(){if(sP)return vg;sP=1;var e=WJ();return vg={Graph:e.Graph,json:GJ(),alg:eee(),version:e.version},vg}var bg,cP;function bn(){if(cP)return bg;cP=1;var e;if(typeof ad=="function")try{e=tee()}catch(t){}return e||(e=window.graphlib),bg=e,bg}var _g,lP;function nee(){if(lP)return _g;lP=1;var e=k7(),t=1,n=4;function r(i){return e(i,t|n)}return _g=r,_g}var xg,uP;function Oc(){if(uP)return xg;uP=1;var e=Ei(),t=Gn(),n=yc(),r=un();function i(o,a,s){if(!r(s))return!1;var c=typeof a;return(c=="number"?t(s)&&n(a,s.length):c=="string"&&a in s)?e(s[a],o):!1}return xg=i,xg}var wg,hP;function ree(){if(hP)return wg;hP=1;var e=Cc(),t=Ei(),n=Oc(),r=Gr(),i=Object.prototype,o=i.hasOwnProperty,a=e(function(s,c){s=Object(s);var l=-1,u=c.length,h=u>2?c[2]:void 0;for(h&&n(c[0],c[1],h)&&(u=1);++l<u;)for(var d=c[l],f=r(d),g=-1,y=f.length;++g<y;){var m=f[g],v=s[m];(v===void 0||t(v,i[m])&&!o.call(s,m))&&(s[m]=d[m])}return s});return wg=a,wg}var Pg,dP;function iee(){if(dP)return Pg;dP=1;var e=Vn(),t=Gn(),n=dr();function r(i){return function(o,a,s){var c=Object(o);if(!t(o)){var l=e(a,3);o=n(o),a=function(h){return l(c[h],h,c)}}var u=i(o,a,s);return u>-1?c[l?o[u]:u]:void 0}}return Pg=r,Pg}var $g,fP;function oee(){if(fP)return $g;fP=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return $g=t,$g}var Cg,pP;function aee(){if(pP)return Cg;pP=1;var e=oee(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return Cg=n,Cg}var Og,gP;function see(){if(gP)return Og;gP=1;var e=aee(),t=un(),n=ki(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,a=/^0o[0-7]+$/i,s=parseInt;function c(l){if(typeof l=="number")return l;if(n(l))return r;if(t(l)){var u=typeof l.valueOf=="function"?l.valueOf():l;l=t(u)?u+"":u}if(typeof l!="string")return l===0?l:+l;l=e(l);var h=o.test(l);return h||a.test(l)?s(l.slice(2),h?2:8):i.test(l)?r:+l}return Og=c,Og}var Sg,mP;function yP(){if(mP)return Sg;mP=1;var e=see(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return Sg=r,Sg}var Mg,vP;function cee(){if(vP)return Mg;vP=1;var e=yP();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return Mg=t,Mg}var Eg,bP;function lee(){if(bP)return Eg;bP=1;var e=w8(),t=Vn(),n=cee(),r=Math.max;function i(o,a,s){var c=o==null?0:o.length;if(!c)return-1;var l=s==null?0:n(s);return l<0&&(l=r(c+l,0)),e(o,t(a,3),l)}return Eg=i,Eg}var Ig,_P;function uee(){if(_P)return Ig;_P=1;var e=iee(),t=lee(),n=e(t);return Ig=n,Ig}var Ag,xP;function wP(){if(xP)return Ag;xP=1;var e=T0();function t(n){var r=n==null?0:n.length;return r?e(n,1):[]}return Ag=t,Ag}var Tg,PP;function hee(){if(PP)return Tg;PP=1;var e=vp(),t=B7(),n=Gr();function r(i,o){return i==null?i:e(i,t(o),n)}return Tg=r,Tg}var kg,$P;function dee(){if($P)return kg;$P=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return kg=e,kg}var Rg,CP;function fee(){if(CP)return Rg;CP=1;var e=gc(),t=_p(),n=Vn();function r(i,o){var a={};return o=n(o,3),t(i,function(s,c,l){e(a,c,o(s,c,l))}),a}return Rg=r,Rg}var Lg,OP;function zg(){if(OP)return Lg;OP=1;var e=ki();function t(n,r,i){for(var o=-1,a=n.length;++o<a;){var s=n[o],c=r(s);if(c!=null&&(l===void 0?c===c&&!e(c):i(c,l)))var l=c,u=s}return u}return Lg=t,Lg}var Ng,SP;function pee(){if(SP)return Ng;SP=1;function e(t,n){return t>n}return Ng=e,Ng}var Dg,MP;function gee(){if(MP)return Dg;MP=1;var e=zg(),t=pee(),n=Vr();function r(i){return i&&i.length?e(i,n,t):void 0}return Dg=r,Dg}var Hg,EP;function IP(){if(EP)return Hg;EP=1;var e=gc(),t=Ei();function n(r,i,o){(o!==void 0&&!t(r[i],o)||o===void 0&&!(i in r))&&e(r,i,o)}return Hg=n,Hg}var qg,AP;function mee(){if(AP)return qg;AP=1;var e=Br(),t=_c(),n=An(),r="[object Object]",i=Function.prototype,o=Object.prototype,a=i.toString,s=o.hasOwnProperty,c=a.call(Object);function l(u){if(!n(u)||e(u)!=r)return!1;var h=t(u);if(h===null)return!0;var d=s.call(h,"constructor")&&h.constructor;return typeof d=="function"&&d instanceof d&&a.call(d)==c}return qg=l,qg}var jg,TP;function kP(){if(TP)return jg;TP=1;function e(t,n){if(!(n==="constructor"&&typeof t[n]=="function")&&n!="__proto__")return t[n]}return jg=e,jg}var Fg,RP;function yee(){if(RP)return Fg;RP=1;var e=Fo(),t=Gr();function n(r){return e(r,t(r))}return Fg=n,Fg}var Bg,LP;function vee(){if(LP)return Bg;LP=1;var e=IP(),t=B6(),n=w7(),r=G6(),i=S7(),o=Bo(),a=It(),s=T8(),c=Ai(),l=jo(),u=un(),h=mee(),d=Vo(),f=kP(),g=yee();function y(m,v,b,_,x,w,P){var $=f(m,b),C=f(v,b),M=P.get(C);if(M){e(m,b,M);return}var S=w?w($,C,b+"",m,v,P):void 0,E=S===void 0;if(E){var A=a(C),O=!A&&c(C),T=!A&&!O&&d(C);S=C,A||O||T?a($)?S=$:s($)?S=r($):O?(E=!1,S=t(C,!0)):T?(E=!1,S=n(C,!0)):S=[]:h(C)||o(C)?(S=$,o($)?S=g($):(!u($)||l($))&&(S=i(C))):E=!1}E&&(P.set(C,S),x(S,C,_,w,P),P.delete(C)),e(m,b,S)}return Bg=y,Bg}var Wg,zP;function bee(){if(zP)return Wg;zP=1;var e=pc(),t=IP(),n=vp(),r=vee(),i=un(),o=Gr(),a=kP();function s(c,l,u,h,d){c!==l&&n(l,function(f,g){if(d||(d=new e),i(f))r(c,l,g,u,s,h,d);else{var y=h?h(a(c,g),f,g+"",c,l,d):void 0;y===void 0&&(y=f),t(c,g,y)}},o)}return Wg=s,Wg}var Gg,NP;function _ee(){if(NP)return Gg;NP=1;var e=Cc(),t=Oc();function n(r){return e(function(i,o){var a=-1,s=o.length,c=s>1?o[s-1]:void 0,l=s>2?o[2]:void 0;for(c=r.length>3&&typeof c=="function"?(s--,c):void 0,l&&t(o[0],o[1],l)&&(c=s<3?void 0:c,s=1),i=Object(i);++a<s;){var u=o[a];u&&r(i,u,a,c)}return i})}return Gg=n,Gg}var Vg,DP;function xee(){if(DP)return Vg;DP=1;var e=bee(),t=_ee(),n=t(function(r,i,o){e(r,i,o)});return Vg=n,Vg}var Yg,HP;function qP(){if(HP)return Yg;HP=1;function e(t,n){return t<n}return Yg=e,Yg}var Xg,jP;function wee(){if(jP)return Xg;jP=1;var e=zg(),t=qP(),n=Vr();function r(i){return i&&i.length?e(i,n,t):void 0}return Xg=r,Xg}var Ug,FP;function Pee(){if(FP)return Ug;FP=1;var e=zg(),t=Vn(),n=qP();function r(i,o){return i&&i.length?e(i,t(o,2),n):void 0}return Ug=r,Ug}var Kg,BP;function $ee(){if(BP)return Kg;BP=1;var e=vn(),t=function(){return e.Date.now()};return Kg=t,Kg}var Zg,WP;function Cee(){if(WP)return Zg;WP=1;var e=mc(),t=Pc(),n=yc(),r=un(),i=Xo();function o(a,s,c,l){if(!r(a))return a;s=t(s,a);for(var u=-1,h=s.length,d=h-1,f=a;f!=null&&++u<h;){var g=i(s[u]),y=c;if(g==="__proto__"||g==="constructor"||g==="prototype")return a;if(u!=d){var m=f[g];y=l?l(m,g,f):void 0,y===void 0&&(y=r(m)?m:n(s[u+1])?[]:{})}e(f,g,y),f=f[g]}return a}return Zg=o,Zg}var Qg,GP;function Oee(){if(GP)return Qg;GP=1;var e=$c(),t=Cee(),n=Pc();function r(i,o,a){for(var s=-1,c=o.length,l={};++s<c;){var u=o[s],h=e(i,u);a(h,u)&&t(l,n(u,i),h)}return l}return Qg=r,Qg}var Jg,VP;function See(){if(VP)return Jg;VP=1;var e=Oee(),t=L9();function n(r,i){return e(r,i,function(o,a){return t(r,a)})}return Jg=n,Jg}var e1,YP;function Mee(){if(YP)return e1;YP=1;var e=wP(),t=g8(),n=b8();function r(i){return n(t(i,void 0,e),i+"")}return e1=r,e1}var t1,XP;function Eee(){if(XP)return t1;XP=1;var e=See(),t=Mee(),n=t(function(r,i){return r==null?{}:e(r,i)});return t1=n,t1}var n1,UP;function Iee(){if(UP)return n1;UP=1;var e=Math.ceil,t=Math.max;function n(r,i,o,a){for(var s=-1,c=t(e((i-r)/(o||1)),0),l=Array(c);c--;)l[a?c:++s]=r,r+=o;return l}return n1=n,n1}var r1,KP;function Aee(){if(KP)return r1;KP=1;var e=Iee(),t=Oc(),n=yP();function r(i){return function(o,a,s){return s&&typeof s!="number"&&t(o,a,s)&&(a=s=void 0),o=n(o),a===void 0?(a=o,o=0):a=n(a),s=s===void 0?o<a?1:-1:n(s),e(o,a,s,i)}}return r1=r,r1}var i1,ZP;function Tee(){if(ZP)return i1;ZP=1;var e=Aee(),t=e();return i1=t,i1}var o1,QP;function kee(){if(QP)return o1;QP=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return o1=e,o1}var a1,JP;function Ree(){if(JP)return a1;JP=1;var e=ki();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,a=n===n,s=e(n),c=r!==void 0,l=r===null,u=r===r,h=e(r);if(!l&&!h&&!s&&n>r||s&&c&&u&&!l&&!h||o&&c&&u||!i&&u||!a)return 1;if(!o&&!s&&!h&&n<r||h&&i&&a&&!o&&!s||l&&i&&a||!c&&a||!u)return-1}return 0}return a1=t,a1}var s1,e$;function Lee(){if(e$)return s1;e$=1;var e=Ree();function t(n,r,i){for(var o=-1,a=n.criteria,s=r.criteria,c=a.length,l=i.length;++o<c;){var u=e(a[o],s[o]);if(u){if(o>=l)return u;var h=i[o];return u*(h=="desc"?-1:1)}}return n.index-r.index}return s1=t,s1}var c1,t$;function zee(){if(t$)return c1;t$=1;var e=wc(),t=$c(),n=Vn(),r=Z9(),i=kee(),o=vc(),a=Lee(),s=Vr(),c=It();function l(u,h,d){h.length?h=e(h,function(y){return c(y)?function(m){return t(m,y.length===1?y[0]:y)}:y}):h=[s];var f=-1;h=e(h,o(n));var g=r(u,function(y,m,v){var b=e(h,function(_){return _(y)});return{criteria:b,index:++f,value:y}});return i(g,function(y,m){return a(y,m,d)})}return c1=l,c1}var l1,n$;function Nee(){if(n$)return l1;n$=1;var e=T0(),t=zee(),n=Cc(),r=Oc(),i=n(function(o,a){if(o==null)return[];var s=a.length;return s>1&&r(o,a[0],a[1])?a=[]:s>2&&r(a[0],a[1],a[2])&&(a=[a[0]]),t(o,e(a,1),[])});return l1=i,l1}var u1,r$;function Dee(){if(r$)return u1;r$=1;var e=O9(),t=0;function n(r){var i=++t;return e(r)+i}return u1=n,u1}var h1,i$;function Hee(){if(i$)return h1;i$=1;function e(t,n,r){for(var i=-1,o=t.length,a=n.length,s={};++i<o;){var c=i<a?n[i]:void 0;r(s,t[i],c)}return s}return h1=e,h1}var d1,o$;function qee(){if(o$)return d1;o$=1;var e=mc(),t=Hee();function n(r,i){return t(r||[],i||[],e)}return d1=n,d1}var f1,a$;function bt(){if(a$)return f1;a$=1;var e;if(typeof ad=="function")try{e={cloneDeep:nee(),constant:gp(),defaults:ree(),each:Y7(),filter:B9(),find:uee(),flatten:wP(),forEach:G7(),forIn:hee(),has:V9(),isUndefined:U9(),last:dee(),map:J9(),mapValues:fee(),max:gee(),merge:xee(),min:wee(),minBy:Pee(),now:$ee(),pick:Eee(),range:Tee(),reduce:r8(),sortBy:Nee(),uniqueId:Dee(),values:z8(),zipObject:qee()}}catch(t){}return e||(e=window._),f1=e,f1}var p1,s$;function jee(){if(s$)return p1;s$=1,p1=e;function e(){var r={};r._next=r._prev=r,this._sentinel=r}e.prototype.dequeue=function(){var r=this._sentinel,i=r._prev;if(i!==r)return t(i),i},e.prototype.enqueue=function(r){var i=this._sentinel;r._prev&&r._next&&t(r),r._next=i._next,i._next._prev=r,i._next=r,r._prev=i},e.prototype.toString=function(){for(var r=[],i=this._sentinel,o=i._prev;o!==i;)r.push(JSON.stringify(o,n)),o=o._prev;return"["+r.join(", ")+"]"};function t(r){r._prev._next=r._next,r._next._prev=r._prev,delete r._next,delete r._prev}function n(r,i){if(r!=="_next"&&r!=="_prev")return i}return p1}var g1,c$;function Fee(){if(c$)return g1;c$=1;var e=bt(),t=bn().Graph,n=jee();g1=i;var r=e.constant(1);function i(l,u){if(l.nodeCount()<=1)return[];var h=s(l,u||r),d=o(h.graph,h.buckets,h.zeroIdx);return e.flatten(e.map(d,function(f){return l.outEdges(f.v,f.w)}),!0)}function o(l,u,h){for(var d=[],f=u[u.length-1],g=u[0],y;l.nodeCount();){for(;y=g.dequeue();)a(l,u,h,y);for(;y=f.dequeue();)a(l,u,h,y);if(l.nodeCount()){for(var m=u.length-2;m>0;--m)if(y=u[m].dequeue(),y){d=d.concat(a(l,u,h,y,!0));break}}}return d}function a(l,u,h,d,f){var g=f?[]:void 0;return e.forEach(l.inEdges(d.v),function(y){var m=l.edge(y),v=l.node(y.v);f&&g.push({v:y.v,w:y.w}),v.out-=m,c(u,h,v)}),e.forEach(l.outEdges(d.v),function(y){var m=l.edge(y),v=y.w,b=l.node(v);b.in-=m,c(u,h,b)}),l.removeNode(d.v),g}function s(l,u){var h=new t,d=0,f=0;e.forEach(l.nodes(),function(m){h.setNode(m,{v:m,in:0,out:0})}),e.forEach(l.edges(),function(m){var v=h.edge(m.v,m.w)||0,b=u(m),_=v+b;h.setEdge(m.v,m.w,_),f=Math.max(f,h.node(m.v).out+=b),d=Math.max(d,h.node(m.w).in+=b)});var g=e.range(f+d+3).map(function(){return new n}),y=d+1;return e.forEach(h.nodes(),function(m){c(g,y,h.node(m))}),{graph:h,buckets:g,zeroIdx:y}}function c(l,u,h){h.out?h.in?l[h.out-h.in+u].enqueue(h):l[l.length-1].enqueue(h):l[0].enqueue(h)}return g1}var m1,l$;function Bee(){if(l$)return m1;l$=1;var e=bt(),t=Fee();m1={run:n,undo:i};function n(o){var a=o.graph().acyclicer==="greedy"?t(o,s(o)):r(o);e.forEach(a,function(c){var l=o.edge(c);o.removeEdge(c),l.forwardName=c.name,l.reversed=!0,o.setEdge(c.w,c.v,l,e.uniqueId("rev"))});function s(c){return function(l){return c.edge(l).weight}}}function r(o){var a=[],s={},c={};function l(u){e.has(c,u)||(c[u]=!0,s[u]=!0,e.forEach(o.outEdges(u),function(h){e.has(s,h.w)?a.push(h):l(h.w)}),delete s[u])}return e.forEach(o.nodes(),l),a}function i(o){e.forEach(o.edges(),function(a){var s=o.edge(a);if(s.reversed){o.removeEdge(a);var c=s.forwardName;delete s.reversed,delete s.forwardName,o.setEdge(a.w,a.v,s,c)}})}return m1}var y1,u$;function nn(){if(u$)return y1;u$=1;var e=bt(),t=bn().Graph;y1={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:o,predecessorWeights:a,intersectRect:s,buildLayerMatrix:c,normalizeRanks:l,removeEmptyRanks:u,addBorderNode:h,maxRank:d,partition:f,time:g,notime:y};function n(m,v,b,_){var x;do x=e.uniqueId(_);while(m.hasNode(x));return b.dummy=v,m.setNode(x,b),x}function r(m){var v=new t().setGraph(m.graph());return e.forEach(m.nodes(),function(b){v.setNode(b,m.node(b))}),e.forEach(m.edges(),function(b){var _=v.edge(b.v,b.w)||{weight:0,minlen:1},x=m.edge(b);v.setEdge(b.v,b.w,{weight:_.weight+x.weight,minlen:Math.max(_.minlen,x.minlen)})}),v}function i(m){var v=new t({multigraph:m.isMultigraph()}).setGraph(m.graph());return e.forEach(m.nodes(),function(b){m.children(b).length||v.setNode(b,m.node(b))}),e.forEach(m.edges(),function(b){v.setEdge(b,m.edge(b))}),v}function o(m){var v=e.map(m.nodes(),function(b){var _={};return e.forEach(m.outEdges(b),function(x){_[x.w]=(_[x.w]||0)+m.edge(x).weight}),_});return e.zipObject(m.nodes(),v)}function a(m){var v=e.map(m.nodes(),function(b){var _={};return e.forEach(m.inEdges(b),function(x){_[x.v]=(_[x.v]||0)+m.edge(x).weight}),_});return e.zipObject(m.nodes(),v)}function s(m,v){var b=m.x,_=m.y,x=v.x-b,w=v.y-_,P=m.width/2,$=m.height/2;if(!x&&!w)throw new Error("Not possible to find intersection inside of the rectangle");var C,M;return Math.abs(w)*P>Math.abs(x)*$?(w<0&&($=-$),C=$*x/w,M=$):(x<0&&(P=-P),C=P,M=P*w/x),{x:b+C,y:_+M}}function c(m){var v=e.map(e.range(d(m)+1),function(){return[]});return e.forEach(m.nodes(),function(b){var _=m.node(b),x=_.rank;e.isUndefined(x)||(v[x][_.order]=b)}),v}function l(m){var v=e.min(e.map(m.nodes(),function(b){return m.node(b).rank}));e.forEach(m.nodes(),function(b){var _=m.node(b);e.has(_,"rank")&&(_.rank-=v)})}function u(m){var v=e.min(e.map(m.nodes(),function(w){return m.node(w).rank})),b=[];e.forEach(m.nodes(),function(w){var P=m.node(w).rank-v;b[P]||(b[P]=[]),b[P].push(w)});var _=0,x=m.graph().nodeRankFactor;e.forEach(b,function(w,P){e.isUndefined(w)&&P%x!==0?--_:_&&e.forEach(w,function($){m.node($).rank+=_})})}function h(m,v,b,_){var x={width:0,height:0};return arguments.length>=4&&(x.rank=b,x.order=_),n(m,"border",x,v)}function d(m){return e.max(e.map(m.nodes(),function(v){var b=m.node(v).rank;if(!e.isUndefined(b))return b}))}function f(m,v){var b={lhs:[],rhs:[]};return e.forEach(m,function(_){v(_)?b.lhs.push(_):b.rhs.push(_)}),b}function g(m,v){var b=e.now();try{return v()}finally{console.log(m+" time: "+(e.now()-b)+"ms")}}function y(m,v){return v()}return y1}var v1,h$;function Wee(){if(h$)return v1;h$=1;var e=bt(),t=nn();v1={run:n,undo:i};function n(o){o.graph().dummyChains=[],e.forEach(o.edges(),function(a){r(o,a)})}function r(o,a){var s=a.v,c=o.node(s).rank,l=a.w,u=o.node(l).rank,h=a.name,d=o.edge(a),f=d.labelRank;if(u!==c+1){o.removeEdge(a);var g,y,m;for(m=0,++c;c<u;++m,++c)d.points=[],y={width:0,height:0,edgeLabel:d,edgeObj:a,rank:c},g=t.addDummyNode(o,"edge",y,"_d"),c===f&&(y.width=d.width,y.height=d.height,y.dummy="edge-label",y.labelpos=d.labelpos),o.setEdge(s,g,{weight:d.weight},h),m===0&&o.graph().dummyChains.push(g),s=g;o.setEdge(s,l,{weight:d.weight},h)}}function i(o){e.forEach(o.graph().dummyChains,function(a){var s=o.node(a),c=s.edgeLabel,l;for(o.setEdge(s.edgeObj,c);s.dummy;)l=o.successors(a)[0],o.removeNode(a),c.points.push({x:s.x,y:s.y}),s.dummy==="edge-label"&&(c.x=s.x,c.y=s.y,c.width=s.width,c.height=s.height),a=l,s=o.node(a)})}return v1}var b1,d$;function Sc(){if(d$)return b1;d$=1;var e=bt();b1={longestPath:t,slack:n};function t(r){var i={};function o(a){var s=r.node(a);if(e.has(i,a))return s.rank;i[a]=!0;var c=e.min(e.map(r.outEdges(a),function(l){return o(l.w)-r.edge(l).minlen}));return(c===Number.POSITIVE_INFINITY||c===void 0||c===null)&&(c=0),s.rank=c}e.forEach(r.sources(),o)}function n(r,i){return r.node(i.w).rank-r.node(i.v).rank-r.edge(i).minlen}return b1}var _1,f$;function p$(){if(f$)return _1;f$=1;var e=bt(),t=bn().Graph,n=Sc().slack;_1=r;function r(s){var c=new t({directed:!1}),l=s.nodes()[0],u=s.nodeCount();c.setNode(l,{});for(var h,d;i(c,s)<u;)h=o(c,s),d=c.hasNode(h.v)?n(s,h):-n(s,h),a(c,s,d);return c}function i(s,c){function l(u){e.forEach(c.nodeEdges(u),function(h){var d=h.v,f=u===d?h.w:d;!s.hasNode(f)&&!n(c,h)&&(s.setNode(f,{}),s.setEdge(u,f,{}),l(f))})}return e.forEach(s.nodes(),l),s.nodeCount()}function o(s,c){return e.minBy(c.edges(),function(l){if(s.hasNode(l.v)!==s.hasNode(l.w))return n(c,l)})}function a(s,c,l){e.forEach(s.nodes(),function(u){c.node(u).rank+=l})}return _1}var x1,g$;function Gee(){if(g$)return x1;g$=1;var e=bt(),t=p$(),n=Sc().slack,r=Sc().longestPath,i=bn().alg.preorder,o=bn().alg.postorder,a=nn().simplify;x1=s,s.initLowLimValues=h,s.initCutValues=c,s.calcCutValue=u,s.leaveEdge=f,s.enterEdge=g,s.exchangeEdges=y;function s(_){_=a(_),r(_);var x=t(_);h(x),c(x,_);for(var w,P;w=f(x);)P=g(x,_,w),y(x,_,w,P)}function c(_,x){var w=o(_,_.nodes());w=w.slice(0,w.length-1),e.forEach(w,function(P){l(_,x,P)})}function l(_,x,w){var P=_.node(w),$=P.parent;_.edge(w,$).cutvalue=u(_,x,w)}function u(_,x,w){var P=_.node(w),$=P.parent,C=!0,M=x.edge(w,$),S=0;return M||(C=!1,M=x.edge($,w)),S=M.weight,e.forEach(x.nodeEdges(w),function(E){var A=E.v===w,O=A?E.w:E.v;if(O!==$){var T=A===C,F=x.edge(E).weight;if(S+=T?F:-F,v(_,w,O)){var z=_.edge(w,O).cutvalue;S+=T?-z:z}}}),S}function h(_,x){arguments.length<2&&(x=_.nodes()[0]),d(_,{},1,x)}function d(_,x,w,P,$){var C=w,M=_.node(P);return x[P]=!0,e.forEach(_.neighbors(P),function(S){e.has(x,S)||(w=d(_,x,w,S,P))}),M.low=C,M.lim=w++,$?M.parent=$:delete M.parent,w}function f(_){return e.find(_.edges(),function(x){return _.edge(x).cutvalue<0})}function g(_,x,w){var P=w.v,$=w.w;x.hasEdge(P,$)||(P=w.w,$=w.v);var C=_.node(P),M=_.node($),S=C,E=!1;C.lim>M.lim&&(S=M,E=!0);var A=e.filter(x.edges(),function(O){return E===b(_,_.node(O.v),S)&&E!==b(_,_.node(O.w),S)});return e.minBy(A,function(O){return n(x,O)})}function y(_,x,w,P){var $=w.v,C=w.w;_.removeEdge($,C),_.setEdge(P.v,P.w,{}),h(_),c(_,x),m(_,x)}function m(_,x){var w=e.find(_.nodes(),function($){return!x.node($).parent}),P=i(_,w);P=P.slice(1),e.forEach(P,function($){var C=_.node($).parent,M=x.edge($,C),S=!1;M||(M=x.edge(C,$),S=!0),x.node($).rank=x.node(C).rank+(S?M.minlen:-M.minlen)})}function v(_,x,w){return _.hasEdge(x,w)}function b(_,x,w){return w.low<=x.lim&&x.lim<=w.lim}return x1}var w1,m$;function Vee(){if(m$)return w1;m$=1;var e=Sc(),t=e.longestPath,n=p$(),r=Gee();w1=i;function i(c){switch(c.graph().ranker){case"network-simplex":s(c);break;case"tight-tree":a(c);break;case"longest-path":o(c);break;default:s(c)}}var o=t;function a(c){t(c),n(c)}function s(c){r(c)}return w1}var P1,y$;function Yee(){if(y$)return P1;y$=1;var e=bt();P1=t;function t(i){var o=r(i);e.forEach(i.graph().dummyChains,function(a){for(var s=i.node(a),c=s.edgeObj,l=n(i,o,c.v,c.w),u=l.path,h=l.lca,d=0,f=u[d],g=!0;a!==c.w;){if(s=i.node(a),g){for(;(f=u[d])!==h&&i.node(f).maxRank<s.rank;)d++;f===h&&(g=!1)}if(!g){for(;d<u.length-1&&i.node(f=u[d+1]).minRank<=s.rank;)d++;f=u[d]}i.setParent(a,f),a=i.successors(a)[0]}})}function n(i,o,a,s){var c=[],l=[],u=Math.min(o[a].low,o[s].low),h=Math.max(o[a].lim,o[s].lim),d,f;d=a;do d=i.parent(d),c.push(d);while(d&&(o[d].low>u||h>o[d].lim));for(f=d,d=s;(d=i.parent(d))!==f;)l.push(d);return{path:c.concat(l.reverse()),lca:f}}function r(i){var o={},a=0;function s(c){var l=a;e.forEach(i.children(c),s),o[c]={low:l,lim:a++}}return e.forEach(i.children(),s),o}return P1}var $1,v$;function Xee(){if(v$)return $1;v$=1;var e=bt(),t=nn();$1={run:n,cleanup:a};function n(s){var c=t.addDummyNode(s,"root",{},"_root"),l=i(s),u=e.max(e.values(l))-1,h=2*u+1;s.graph().nestingRoot=c,e.forEach(s.edges(),function(f){s.edge(f).minlen*=h});var d=o(s)+1;e.forEach(s.children(),function(f){r(s,c,h,d,u,l,f)}),s.graph().nodeRankFactor=h}function r(s,c,l,u,h,d,f){var g=s.children(f);if(!g.length){f!==c&&s.setEdge(c,f,{weight:0,minlen:l});return}var y=t.addBorderNode(s,"_bt"),m=t.addBorderNode(s,"_bb"),v=s.node(f);s.setParent(y,f),v.borderTop=y,s.setParent(m,f),v.borderBottom=m,e.forEach(g,function(b){r(s,c,l,u,h,d,b);var _=s.node(b),x=_.borderTop?_.borderTop:b,w=_.borderBottom?_.borderBottom:b,P=_.borderTop?u:2*u,$=x!==w?1:h-d[f]+1;s.setEdge(y,x,{weight:P,minlen:$,nestingEdge:!0}),s.setEdge(w,m,{weight:P,minlen:$,nestingEdge:!0})}),s.parent(f)||s.setEdge(c,y,{weight:0,minlen:h+d[f]})}function i(s){var c={};function l(u,h){var d=s.children(u);d&&d.length&&e.forEach(d,function(f){l(f,h+1)}),c[u]=h}return e.forEach(s.children(),function(u){l(u,1)}),c}function o(s){return e.reduce(s.edges(),function(c,l){return c+s.edge(l).weight},0)}function a(s){var c=s.graph();s.removeNode(c.nestingRoot),delete c.nestingRoot,e.forEach(s.edges(),function(l){var u=s.edge(l);u.nestingEdge&&s.removeEdge(l)})}return $1}var C1,b$;function Uee(){if(b$)return C1;b$=1;var e=bt(),t=nn();C1=n;function n(i){function o(a){var s=i.children(a),c=i.node(a);if(s.length&&e.forEach(s,o),e.has(c,"minRank")){c.borderLeft=[],c.borderRight=[];for(var l=c.minRank,u=c.maxRank+1;l<u;++l)r(i,"borderLeft","_bl",a,c,l),r(i,"borderRight","_br",a,c,l)}}e.forEach(i.children(),o)}function r(i,o,a,s,c,l){var u={width:0,height:0,rank:l,borderType:o},h=c[o][l-1],d=t.addDummyNode(i,"border",u,a);c[o][l]=d,i.setParent(d,s),h&&i.setEdge(h,d,{weight:1})}return C1}var O1,_$;function Kee(){if(_$)return O1;_$=1;var e=bt();O1={adjust:t,undo:n};function t(l){var u=l.graph().rankdir.toLowerCase();(u==="lr"||u==="rl")&&r(l)}function n(l){var u=l.graph().rankdir.toLowerCase();(u==="bt"||u==="rl")&&o(l),(u==="lr"||u==="rl")&&(s(l),r(l))}function r(l){e.forEach(l.nodes(),function(u){i(l.node(u))}),e.forEach(l.edges(),function(u){i(l.edge(u))})}function i(l){var u=l.width;l.width=l.height,l.height=u}function o(l){e.forEach(l.nodes(),function(u){a(l.node(u))}),e.forEach(l.edges(),function(u){var h=l.edge(u);e.forEach(h.points,a),e.has(h,"y")&&a(h)})}function a(l){l.y=-l.y}function s(l){e.forEach(l.nodes(),function(u){c(l.node(u))}),e.forEach(l.edges(),function(u){var h=l.edge(u);e.forEach(h.points,c),e.has(h,"x")&&c(h)})}function c(l){var u=l.x;l.x=l.y,l.y=u}return O1}var S1,x$;function Zee(){if(x$)return S1;x$=1;var e=bt();S1=t;function t(n){var r={},i=e.filter(n.nodes(),function(l){return!n.children(l).length}),o=e.max(e.map(i,function(l){return n.node(l).rank})),a=e.map(e.range(o+1),function(){return[]});function s(l){if(!e.has(r,l)){r[l]=!0;var u=n.node(l);a[u.rank].push(l),e.forEach(n.successors(l),s)}}var c=e.sortBy(i,function(l){return n.node(l).rank});return e.forEach(c,s),a}return S1}var M1,w$;function Qee(){if(w$)return M1;w$=1;var e=bt();M1=t;function t(r,i){for(var o=0,a=1;a<i.length;++a)o+=n(r,i[a-1],i[a]);return o}function n(r,i,o){for(var a=e.zipObject(o,e.map(o,function(d,f){return f})),s=e.flatten(e.map(i,function(d){return e.sortBy(e.map(r.outEdges(d),function(f){return{pos:a[f.w],weight:r.edge(f).weight}}),"pos")}),!0),c=1;c<o.length;)c<<=1;var l=2*c-1;c-=1;var u=e.map(new Array(l),function(){return 0}),h=0;return e.forEach(s.forEach(function(d){var f=d.pos+c;u[f]+=d.weight;for(var g=0;f>0;)f%2&&(g+=u[f+1]),f=f-1>>1,u[f]+=d.weight;h+=d.weight*g})),h}return M1}var E1,P$;function Jee(){if(P$)return E1;P$=1;var e=bt();E1=t;function t(n,r){return e.map(r,function(i){var o=n.inEdges(i);if(o.length){var a=e.reduce(o,function(s,c){var l=n.edge(c),u=n.node(c.v);return{sum:s.sum+l.weight*u.order,weight:s.weight+l.weight}},{sum:0,weight:0});return{v:i,barycenter:a.sum/a.weight,weight:a.weight}}else return{v:i}})}return E1}var I1,$$;function ete(){if($$)return I1;$$=1;var e=bt();I1=t;function t(i,o){var a={};e.forEach(i,function(c,l){var u=a[c.v]={indegree:0,in:[],out:[],vs:[c.v],i:l};e.isUndefined(c.barycenter)||(u.barycenter=c.barycenter,u.weight=c.weight)}),e.forEach(o.edges(),function(c){var l=a[c.v],u=a[c.w];!e.isUndefined(l)&&!e.isUndefined(u)&&(u.indegree++,l.out.push(a[c.w]))});var s=e.filter(a,function(c){return!c.indegree});return n(s)}function n(i){var o=[];function a(l){return function(u){u.merged||(e.isUndefined(u.barycenter)||e.isUndefined(l.barycenter)||u.barycenter>=l.barycenter)&&r(l,u)}}function s(l){return function(u){u.in.push(l),--u.indegree===0&&i.push(u)}}for(;i.length;){var c=i.pop();o.push(c),e.forEach(c.in.reverse(),a(c)),e.forEach(c.out,s(c))}return e.map(e.filter(o,function(l){return!l.merged}),function(l){return e.pick(l,["vs","i","barycenter","weight"])})}function r(i,o){var a=0,s=0;i.weight&&(a+=i.barycenter*i.weight,s+=i.weight),o.weight&&(a+=o.barycenter*o.weight,s+=o.weight),i.vs=o.vs.concat(i.vs),i.barycenter=a/s,i.weight=s,i.i=Math.min(o.i,i.i),o.merged=!0}return I1}var A1,C$;function tte(){if(C$)return A1;C$=1;var e=bt(),t=nn();A1=n;function n(o,a){var s=t.partition(o,function(y){return e.has(y,"barycenter")}),c=s.lhs,l=e.sortBy(s.rhs,function(y){return-y.i}),u=[],h=0,d=0,f=0;c.sort(i(!!a)),f=r(u,l,f),e.forEach(c,function(y){f+=y.vs.length,u.push(y.vs),h+=y.barycenter*y.weight,d+=y.weight,f=r(u,l,f)});var g={vs:e.flatten(u,!0)};return d&&(g.barycenter=h/d,g.weight=d),g}function r(o,a,s){for(var c;a.length&&(c=e.last(a)).i<=s;)a.pop(),o.push(c.vs),s++;return s}function i(o){return function(a,s){return a.barycenter<s.barycenter?-1:a.barycenter>s.barycenter?1:o?s.i-a.i:a.i-s.i}}return A1}var T1,O$;function nte(){if(O$)return T1;O$=1;var e=bt(),t=Jee(),n=ete(),r=tte();T1=i;function i(s,c,l,u){var h=s.children(c),d=s.node(c),f=d?d.borderLeft:void 0,g=d?d.borderRight:void 0,y={};f&&(h=e.filter(h,function(w){return w!==f&&w!==g}));var m=t(s,h);e.forEach(m,function(w){if(s.children(w.v).length){var P=i(s,w.v,l,u);y[w.v]=P,e.has(P,"barycenter")&&a(w,P)}});var v=n(m,l);o(v,y);var b=r(v,u);if(f&&(b.vs=e.flatten([f,b.vs,g],!0),s.predecessors(f).length)){var _=s.node(s.predecessors(f)[0]),x=s.node(s.predecessors(g)[0]);e.has(b,"barycenter")||(b.barycenter=0,b.weight=0),b.barycenter=(b.barycenter*b.weight+_.order+x.order)/(b.weight+2),b.weight+=2}return b}function o(s,c){e.forEach(s,function(l){l.vs=e.flatten(l.vs.map(function(u){return c[u]?c[u].vs:u}),!0)})}function a(s,c){e.isUndefined(s.barycenter)?(s.barycenter=c.barycenter,s.weight=c.weight):(s.barycenter=(s.barycenter*s.weight+c.barycenter*c.weight)/(s.weight+c.weight),s.weight+=c.weight)}return T1}var k1,S$;function rte(){if(S$)return k1;S$=1;var e=bt(),t=bn().Graph;k1=n;function n(i,o,a){var s=r(i),c=new t({compound:!0}).setGraph({root:s}).setDefaultNodeLabel(function(l){return i.node(l)});return e.forEach(i.nodes(),function(l){var u=i.node(l),h=i.parent(l);(u.rank===o||u.minRank<=o&&o<=u.maxRank)&&(c.setNode(l),c.setParent(l,h||s),e.forEach(i[a](l),function(d){var f=d.v===l?d.w:d.v,g=c.edge(f,l),y=e.isUndefined(g)?0:g.weight;c.setEdge(f,l,{weight:i.edge(d).weight+y})}),e.has(u,"minRank")&&c.setNode(l,{borderLeft:u.borderLeft[o],borderRight:u.borderRight[o]}))}),c}function r(i){for(var o;i.hasNode(o=e.uniqueId("_root")););return o}return k1}var R1,M$;function ite(){if(M$)return R1;M$=1;var e=bt();R1=t;function t(n,r,i){var o={},a;e.forEach(i,function(s){for(var c=n.parent(s),l,u;c;){if(l=n.parent(c),l?(u=o[l],o[l]=c):(u=a,a=c),u&&u!==c){r.setEdge(u,c);return}c=l}})}return R1}var L1,E$;function ote(){if(E$)return L1;E$=1;var e=bt(),t=Zee(),n=Qee(),r=nte(),i=rte(),o=ite(),a=bn().Graph,s=nn();L1=c;function c(d){var f=s.maxRank(d),g=l(d,e.range(1,f+1),"inEdges"),y=l(d,e.range(f-1,-1,-1),"outEdges"),m=t(d);h(d,m);for(var v=Number.POSITIVE_INFINITY,b,_=0,x=0;x<4;++_,++x){u(_%2?g:y,_%4>=2),m=s.buildLayerMatrix(d);var w=n(d,m);w<v&&(x=0,b=e.cloneDeep(m),v=w)}h(d,b)}function l(d,f,g){return e.map(f,function(y){return i(d,y,g)})}function u(d,f){var g=new a;e.forEach(d,function(y){var m=y.graph().root,v=r(y,m,g,f);e.forEach(v.vs,function(b,_){y.node(b).order=_}),o(y,g,v.vs)})}function h(d,f){e.forEach(f,function(g){e.forEach(g,function(y,m){d.node(y).order=m})})}return L1}var z1,I$;function ate(){if(I$)return z1;I$=1;var e=bt(),t=bn().Graph,n=nn();z1={positionX:g,findType1Conflicts:r,findType2Conflicts:i,addConflict:a,hasConflict:s,verticalAlignment:c,horizontalCompaction:l,alignCoordinates:d,findSmallestWidthAlignment:h,balance:f};function r(v,b){var _={};function x(w,P){var $=0,C=0,M=w.length,S=e.last(P);return e.forEach(P,function(E,A){var O=o(v,E),T=O?v.node(O).order:M;(O||E===S)&&(e.forEach(P.slice(C,A+1),function(F){e.forEach(v.predecessors(F),function(z){var j=v.node(z),D=j.order;(D<$||T<D)&&!(j.dummy&&v.node(F).dummy)&&a(_,z,F)})}),C=A+1,$=T)}),P}return e.reduce(b,x),_}function i(v,b){var _={};function x(P,$,C,M,S){var E;e.forEach(e.range($,C),function(A){E=P[A],v.node(E).dummy&&e.forEach(v.predecessors(E),function(O){var T=v.node(O);T.dummy&&(T.order<M||T.order>S)&&a(_,O,E)})})}function w(P,$){var C=-1,M,S=0;return e.forEach($,function(E,A){if(v.node(E).dummy==="border"){var O=v.predecessors(E);O.length&&(M=v.node(O[0]).order,x($,S,A,C,M),S=A,C=M)}x($,S,$.length,M,P.length)}),$}return e.reduce(b,w),_}function o(v,b){if(v.node(b).dummy)return e.find(v.predecessors(b),function(_){return v.node(_).dummy})}function a(v,b,_){if(b>_){var x=b;b=_,_=x}var w=v[b];w||(v[b]=w={}),w[_]=!0}function s(v,b,_){if(b>_){var x=b;b=_,_=x}return e.has(v[b],_)}function c(v,b,_,x){var w={},P={},$={};return e.forEach(b,function(C){e.forEach(C,function(M,S){w[M]=M,P[M]=M,$[M]=S})}),e.forEach(b,function(C){var M=-1;e.forEach(C,function(S){var E=x(S);if(E.length){E=e.sortBy(E,function(z){return $[z]});for(var A=(E.length-1)/2,O=Math.floor(A),T=Math.ceil(A);O<=T;++O){var F=E[O];P[S]===S&&M<$[F]&&!s(_,S,F)&&(P[F]=S,P[S]=w[S]=w[F],M=$[F])}}})}),{root:w,align:P}}function l(v,b,_,x,w){var P={},$=u(v,b,_,w),C=w?"borderLeft":"borderRight";function M(A,O){for(var T=$.nodes(),F=T.pop(),z={};F;)z[F]?A(F):(z[F]=!0,T.push(F),T=T.concat(O(F))),F=T.pop()}function S(A){P[A]=$.inEdges(A).reduce(function(O,T){return Math.max(O,P[T.v]+$.edge(T))},0)}function E(A){var O=$.outEdges(A).reduce(function(F,z){return Math.min(F,P[z.w]-$.edge(z))},Number.POSITIVE_INFINITY),T=v.node(A);O!==Number.POSITIVE_INFINITY&&T.borderType!==C&&(P[A]=Math.max(P[A],O))}return M(S,$.predecessors.bind($)),M(E,$.successors.bind($)),e.forEach(x,function(A){P[A]=P[_[A]]}),P}function u(v,b,_,x){var w=new t,P=v.graph(),$=y(P.nodesep,P.edgesep,x);return e.forEach(b,function(C){var M;e.forEach(C,function(S){var E=_[S];if(w.setNode(E),M){var A=_[M],O=w.edge(A,E);w.setEdge(A,E,Math.max($(v,S,M),O||0))}M=S})}),w}function h(v,b){return e.minBy(e.values(b),function(_){var x=Number.NEGATIVE_INFINITY,w=Number.POSITIVE_INFINITY;return e.forIn(_,function(P,$){var C=m(v,$)/2;x=Math.max(P+C,x),w=Math.min(P-C,w)}),x-w})}function d(v,b){var _=e.values(b),x=e.min(_),w=e.max(_);e.forEach(["u","d"],function(P){e.forEach(["l","r"],function($){var C=P+$,M=v[C],S;if(M!==b){var E=e.values(M);S=$==="l"?x-e.min(E):w-e.max(E),S&&(v[C]=e.mapValues(M,function(A){return A+S}))}})})}function f(v,b){return e.mapValues(v.ul,function(_,x){if(b)return v[b.toLowerCase()][x];var w=e.sortBy(e.map(v,x));return(w[1]+w[2])/2})}function g(v){var b=n.buildLayerMatrix(v),_=e.merge(r(v,b),i(v,b)),x={},w;e.forEach(["u","d"],function($){w=$==="u"?b:e.values(b).reverse(),e.forEach(["l","r"],function(C){C==="r"&&(w=e.map(w,function(A){return e.values(A).reverse()}));var M=($==="u"?v.predecessors:v.successors).bind(v),S=c(v,w,_,M),E=l(v,w,S.root,S.align,C==="r");C==="r"&&(E=e.mapValues(E,function(A){return-A})),x[$+C]=E})});var P=h(v,x);return d(x,P),f(x,v.graph().align)}function y(v,b,_){return function(x,w,P){var $=x.node(w),C=x.node(P),M=0,S;if(M+=$.width/2,e.has($,"labelpos"))switch($.labelpos.toLowerCase()){case"l":S=-$.width/2;break;case"r":S=$.width/2;break}if(S&&(M+=_?S:-S),S=0,M+=($.dummy?b:v)/2,M+=(C.dummy?b:v)/2,M+=C.width/2,e.has(C,"labelpos"))switch(C.labelpos.toLowerCase()){case"l":S=C.width/2;break;case"r":S=-C.width/2;break}return S&&(M+=_?S:-S),S=0,M}}function m(v,b){return v.node(b).width}return z1}var N1,A$;function ste(){if(A$)return N1;A$=1;var e=bt(),t=nn(),n=ate().positionX;N1=r;function r(o){o=t.asNonCompoundGraph(o),i(o),e.forEach(n(o),function(a,s){o.node(s).x=a})}function i(o){var a=t.buildLayerMatrix(o),s=o.graph().ranksep,c=0;e.forEach(a,function(l){var u=e.max(e.map(l,function(h){return o.node(h).height}));e.forEach(l,function(h){o.node(h).y=c+u/2}),c+=u+s})}return N1}var D1,T$;function cte(){if(T$)return D1;T$=1;var e=bt(),t=Bee(),n=Wee(),r=Vee(),i=nn().normalizeRanks,o=Yee(),a=nn().removeEmptyRanks,s=Xee(),c=Uee(),l=Kee(),u=ote(),h=ste(),d=nn(),f=bn().Graph;D1=g;function g(I,R){var N=R&&R.debugTiming?d.time:d.notime;N("layout",function(){var q=N(" buildLayoutGraph",function(){return M(I)});N(" runLayout",function(){y(q,N)}),N(" updateInputGraph",function(){m(I,q)})})}function y(I,R){R(" makeSpaceForEdgeLabels",function(){S(I)}),R(" removeSelfEdges",function(){W(I)}),R(" acyclic",function(){t.run(I)}),R(" nestingGraph.run",function(){s.run(I)}),R(" rank",function(){r(d.asNonCompoundGraph(I))}),R(" injectEdgeLabelProxies",function(){E(I)}),R(" removeEmptyRanks",function(){a(I)}),R(" nestingGraph.cleanup",function(){s.cleanup(I)}),R(" normalizeRanks",function(){i(I)}),R(" assignRankMinMax",function(){A(I)}),R(" removeEdgeLabelProxies",function(){O(I)}),R(" normalize.run",function(){n.run(I)}),R(" parentDummyChains",function(){o(I)}),R(" addBorderSegments",function(){c(I)}),R(" order",function(){u(I)}),R(" insertSelfEdges",function(){B(I)}),R(" adjustCoordinateSystem",function(){l.adjust(I)}),R(" position",function(){h(I)}),R(" positionSelfEdges",function(){X(I)}),R(" removeBorderNodes",function(){D(I)}),R(" normalize.undo",function(){n.undo(I)}),R(" fixupEdgeLabelCoords",function(){z(I)}),R(" undoCoordinateSystem",function(){l.undo(I)}),R(" translateGraph",function(){T(I)}),R(" assignNodeIntersects",function(){F(I)}),R(" reversePoints",function(){j(I)}),R(" acyclic.undo",function(){t.undo(I)})}function m(I,R){e.forEach(I.nodes(),function(N){var q=I.node(N),G=R.node(N);q&&(q.x=G.x,q.y=G.y,R.children(N).length&&(q.width=G.width,q.height=G.height))}),e.forEach(I.edges(),function(N){var q=I.edge(N),G=R.edge(N);q.points=G.points,e.has(G,"x")&&(q.x=G.x,q.y=G.y)}),I.graph().width=R.graph().width,I.graph().height=R.graph().height}var v=["nodesep","edgesep","ranksep","marginx","marginy"],b={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},_=["acyclicer","ranker","rankdir","align"],x=["width","height"],w={width:0,height:0},P=["minlen","weight","width","height","labeloffset"],$={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},C=["labelpos"];function M(I){var R=new f({multigraph:!0,compound:!0}),N=k(I.graph());return R.setGraph(e.merge({},b,H(N,v),e.pick(N,_))),e.forEach(I.nodes(),function(q){var G=k(I.node(q));R.setNode(q,e.defaults(H(G,x),w)),R.setParent(q,I.parent(q))}),e.forEach(I.edges(),function(q){var G=k(I.edge(q));R.setEdge(q,e.merge({},$,H(G,P),e.pick(G,C)))}),R}function S(I){var R=I.graph();R.ranksep/=2,e.forEach(I.edges(),function(N){var q=I.edge(N);q.minlen*=2,q.labelpos.toLowerCase()!=="c"&&(R.rankdir==="TB"||R.rankdir==="BT"?q.width+=q.labeloffset:q.height+=q.labeloffset)})}function E(I){e.forEach(I.edges(),function(R){var N=I.edge(R);if(N.width&&N.height){var q=I.node(R.v),G=I.node(R.w),U={rank:(G.rank-q.rank)/2+q.rank,e:R};d.addDummyNode(I,"edge-proxy",U,"_ep")}})}function A(I){var R=0;e.forEach(I.nodes(),function(N){var q=I.node(N);q.borderTop&&(q.minRank=I.node(q.borderTop).rank,q.maxRank=I.node(q.borderBottom).rank,R=e.max(R,q.maxRank))}),I.graph().maxRank=R}function O(I){e.forEach(I.nodes(),function(R){var N=I.node(R);N.dummy==="edge-proxy"&&(I.edge(N.e).labelRank=N.rank,I.removeNode(R))})}function T(I){var R=Number.POSITIVE_INFINITY,N=0,q=Number.POSITIVE_INFINITY,G=0,U=I.graph(),K=U.marginx||0,oe=U.marginy||0;function te(ae){var Z=ae.x,ee=ae.y,ue=ae.width,ne=ae.height;R=Math.min(R,Z-ue/2),N=Math.max(N,Z+ue/2),q=Math.min(q,ee-ne/2),G=Math.max(G,ee+ne/2)}e.forEach(I.nodes(),function(ae){te(I.node(ae))}),e.forEach(I.edges(),function(ae){var Z=I.edge(ae);e.has(Z,"x")&&te(Z)}),R-=K,q-=oe,e.forEach(I.nodes(),function(ae){var Z=I.node(ae);Z.x-=R,Z.y-=q}),e.forEach(I.edges(),function(ae){var Z=I.edge(ae);e.forEach(Z.points,function(ee){ee.x-=R,ee.y-=q}),e.has(Z,"x")&&(Z.x-=R),e.has(Z,"y")&&(Z.y-=q)}),U.width=N-R+K,U.height=G-q+oe}function F(I){e.forEach(I.edges(),function(R){var N=I.edge(R),q=I.node(R.v),G=I.node(R.w),U,K;N.points?(U=N.points[0],K=N.points[N.points.length-1]):(N.points=[],U=G,K=q),N.points.unshift(d.intersectRect(q,U)),N.points.push(d.intersectRect(G,K))})}function z(I){e.forEach(I.edges(),function(R){var N=I.edge(R);if(e.has(N,"x"))switch((N.labelpos==="l"||N.labelpos==="r")&&(N.width-=N.labeloffset),N.labelpos){case"l":N.x-=N.width/2+N.labeloffset;break;case"r":N.x+=N.width/2+N.labeloffset;break}})}function j(I){e.forEach(I.edges(),function(R){var N=I.edge(R);N.reversed&&N.points.reverse()})}function D(I){e.forEach(I.nodes(),function(R){if(I.children(R).length){var N=I.node(R),q=I.node(N.borderTop),G=I.node(N.borderBottom),U=I.node(e.last(N.borderLeft)),K=I.node(e.last(N.borderRight));N.width=Math.abs(K.x-U.x),N.height=Math.abs(G.y-q.y),N.x=U.x+N.width/2,N.y=q.y+N.height/2}}),e.forEach(I.nodes(),function(R){I.node(R).dummy==="border"&&I.removeNode(R)})}function W(I){e.forEach(I.edges(),function(R){if(R.v===R.w){var N=I.node(R.v);N.selfEdges||(N.selfEdges=[]),N.selfEdges.push({e:R,label:I.edge(R)}),I.removeEdge(R)}})}function B(I){var R=d.buildLayerMatrix(I);e.forEach(R,function(N){var q=0;e.forEach(N,function(G,U){var K=I.node(G);K.order=U+q,e.forEach(K.selfEdges,function(oe){d.addDummyNode(I,"selfedge",{width:oe.label.width,height:oe.label.height,rank:K.rank,order:U+ ++q,e:oe.e,label:oe.label},"_se")}),delete K.selfEdges})})}function X(I){e.forEach(I.nodes(),function(R){var N=I.node(R);if(N.dummy==="selfedge"){var q=I.node(N.e.v),G=q.x+q.width/2,U=q.y,K=N.x-G,oe=q.height/2;I.setEdge(N.e,N.label),I.removeNode(R),N.label.points=[{x:G+2*K/3,y:U-oe},{x:G+5*K/6,y:U-oe},{x:G+K,y:U},{x:G+5*K/6,y:U+oe},{x:G+2*K/3,y:U+oe}],N.label.x=N.x,N.label.y=N.y}})}function H(I,R){return e.mapValues(e.pick(I,R),Number)}function k(I){var R={};return e.forEach(I,function(N,q){R[q.toLowerCase()]=N}),R}return D1}var H1,k$;function lte(){if(k$)return H1;k$=1;var e=bt(),t=nn(),n=bn().Graph;H1={debugOrdering:r};function r(i){var o=t.buildLayerMatrix(i),a=new n({compound:!0,multigraph:!0}).setGraph({});return e.forEach(i.nodes(),function(s){a.setNode(s,{label:s}),a.setParent(s,"layer"+i.node(s).rank)}),e.forEach(i.edges(),function(s){a.setEdge(s.v,s.w,{},s.name)}),e.forEach(o,function(s,c){var l="layer"+c;a.setNode(l,{rank:"same"}),e.reduce(s,function(u,h){return a.setEdge(u,h,{style:"invis"}),h})}),a}return H1}var q1,R$;function ute(){return R$||(R$=1,q1="0.8.5"),q1}var j1,L$;function hte(){return L$||(L$=1,j1={graphlib:bn(),layout:cte(),debug:lte(),util:{time:nn().time,notime:nn().notime},version:ute()}),j1}var z$=hte(),dte=KZ(z$),fte=function(e){return m5(e,"Boolean")};function pte(e,t){if(e){var n;if(GZ(e))for(var r=0,i=e.length;r<i&&(n=t(e[r],r),n!==!1);r++);else if(VZ(e)){for(var o in e)if(e.hasOwnProperty(o)&&(n=t(e[o],o),n===!1))break}}}var gte=Object.prototype.hasOwnProperty,mte=(function(e,t){if(e===null||!UZ(e))return{};var n={};return pte(t,function(r){gte.call(e,r)&&(n[r]=e[r])}),n});class yte extends WZ{constructor(){super(...arguments),this.id="dagre",this.isCompoundGraph=null,this.config={graphAttributes:["rankdir","align","nodesep","edgesep","ranksep","marginx","marginy","acyclicer","ranker"],nodeAttributes:["width","height"],edgeAttributes:["minlen","weight","width","height","labelpos","labeloffset"]}}getDefaultOptions(){return{directed:!0,multigraph:!0,rankdir:"TB",align:void 0,nodesep:50,edgesep:10,ranksep:50,marginx:0,marginy:0,acyclicer:void 0,ranker:"network-simplex",nodeSize:[0,0],edgeMinLen:1,edgeWeight:1,edgeLabelSize:[0,0],edgeLabelPos:"r",edgeLabelOffset:10}}layout(){return Ho(this,void 0,void 0,function*(){const t=new z$.graphlib.Graph({directed:!!this.options.directed,multigraph:!!this.options.multigraph,compound:this.isCompound()});t.setGraph(mte(this.options,this.config.graphAttributes)),t.setDefaultEdgeLabel(()=>({}));const n=a5(this.options.nodeSize,0);this.model.forEachNode(f=>{const g=f._original,[y,m]=r5(n(g)),v={width:y,height:m};if(t.setNode(String(f.id),v),this.isCompound()){if(ln(f.parentId))return;t.setParent(String(f.id),String(f.parentId))}});const{edgeLabelSize:r,edgeLabelOffset:i,edgeLabelPos:o,edgeMinLen:a,edgeWeight:s}=this.options,c=a5(r,0,"edge"),l=rd(i,10,"edge"),u=typeof o=="string"?()=>o:nd(o,["edge"]),h=rd(a,1,"edge"),d=rd(s,1,"edge");this.model.forEachEdge(f=>{const g=f._original,[y,m]=r5(c(g)),v={width:y,height:m,labelpos:u(g),labeloffset:l(g),minlen:h(g),weight:d(g)};t.setEdge(String(f.source),String(f.target),v,String(f.id))}),dte.layout(t),this.model.forEachNode(f=>{const g=t.node(String(f.id));g&&(f.x=g.x,f.y=g.y,f.size=[g.width,g.height])}),this.model.forEachEdge(f=>{const g=t.edge(String(f.source),String(f.target),String(f.id));if(!g)return;const{width:y,height:m,weight:v,minlen:b,labelpos:_,labeloffset:x,points:w}=g;f.labelSize=[y,m],f.weight=v,f.minLen=b,f.labelPos=_,f.labelOffset=x,f.points=w.map($Z)})})}isCompound(){return this.isCompoundGraph!==null?this.isCompoundGraph:fte(this.options.compound)?this.isCompoundGraph=this.options.compound:(this.isCompoundGraph=this.model.nodes().some(t=>!ln(t.parentId)),this.isCompoundGraph)}}var vte=Object.defineProperty,bte=Object.defineProperties,_te=Object.getOwnPropertyDescriptors,N$=Object.getOwnPropertySymbols,xte=Object.prototype.hasOwnProperty,wte=Object.prototype.propertyIsEnumerable,D$=(e,t,n)=>t in e?vte(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,H$=(e,t)=>{for(var n in t||(t={}))xte.call(t,n)&&D$(e,n,t[n]);if(N$)for(var n of N$(t))wte.call(t,n)&&D$(e,n,t[n]);return e},q$=(e,t)=>bte(e,_te(t));const Pte=50,$te=70,Cte=10,Ote=2,Ste=30,Mte=(e,t)=>{var n,r;const i=new Map;e.forEach(s=>i.set(s,[]));for(const s of t){if(s.source===s.target)return!0;(n=i.get(s.source))==null||n.push({target:s.target,edgeId:s.id}),(r=i.get(s.target))==null||r.push({target:s.source,edgeId:s.id})}const o=new Set,a=(s,c)=>{o.add(s);const l=i.get(s)||[];for(const{target:u,edgeId:h}of l)if(h!==c&&(o.has(u)||a(u,h)))return!0;return!1};for(const s of e)if(!o.has(s)&&a(s,null))return!0;return!1},j$=e=>{var t,n;const{Title:r,Item:i,data:o,rankdir:a="TB",nodesep:s=Pte,ranksep:c=$te,edgesep:l=Cte,edgeWidth:u=Ote,showConnections:h=!0,edgeColorMode:d="gradient",edgeStyle:f="solid",edgeDashPattern:g="5,5",edgeCornerRadius:y=12,edgeRouting:m="orth",showArrow:v=!0,arrowType:b="triangle",padding:_=Ste,edgeAnimation:x="none",edgeAnimationSpeed:w=1,options:P}=e,{title:$,desc:C,items:M=[],relations:S=[]}=o,E=r?p(r,{title:$,desc:C}):null;if(!i||M.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[E,p(Y,{children:p(Q,{indexes:[0],x:0,y:0})})]});const A=new Map,O=new Map,T=new Map,F=new Map,z=new Set,j=new Map;let D=0;const W=M.map((Z,ee)=>{var ue,ne;const J=Z,ie=String((ue=J.id)!=null?ue:ee),re=[ee];let ce;const pe=String((ne=J.group)!=null?ne:"");if(pe){let de=j.get(pe);de==null&&(de=D,j.set(pe,de),D+=1),ce=qe(P,[de])}else ce=qe(P,re);const he=ce?Ct({colorPrimary:ce},P):void 0;ce&&T.set(ie,ce);const ge=se(p(i,{indexes:re,data:o,datum:J,positionH:"center",positionV:"middle",themeColors:he}));return O.set(ie,ge),A.set(ie,{id:ie,indexes:re,datum:J,themeColors:he}),F.set(ee,ie),z.add(ie),{id:ie,parentId:J.parentId}}),B=Z=>{if(Z==null)return null;const ee=String(Z);if(z.has(ee))return ee;const ue=Number(Z);if(!Number.isNaN(ue)){const ne=F.get(ue);if(ne)return ne}return null},X=S.map((Z,ee)=>{const ue=B(Z.from),ne=B(Z.to);return!ue||!ne?null:{id:Z.id?String(Z.id):`edge-${ee}`,source:ue,target:ne,relation:Z}}).filter(Boolean),k=Mte(Array.from(z),X)?"dagre":m,I=new yte({rankdir:a,nodesep:s,ranksep:c,edgesep:l,controlPoints:!0,nodeSize:Z=>{var ee;const ue=String((ee=Z.id)!=null?ee:""),ne=O.get(ue);return ne?[ne.width,ne.height]:[0,0]}});I.execute({nodes:W,edges:X});const R=[];if(I.forEachNode(Z=>{var ee,ue,ne,J;const ie=String(Z.id),re=A.get(ie);if(!re)return;const ce=O.get(ie),pe=(ee=ce==null?void 0:ce.width)!=null?ee:0,he=(ue=ce==null?void 0:ce.height)!=null?ue:0,ge=((ne=Z.x)!=null?ne:0)-pe/2,de=((J=Z.y)!=null?J:0)-he/2;R.push(q$(H$({},re),{x:ge,y:de,width:pe,height:he,centerX:ge+pe/2,centerY:de+he/2}))}),R.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[E,p(Y,{children:p(Q,{indexes:[0],x:0,y:0})})]});const N=Math.min(...R.map(Z=>Z.x)),q=Math.min(...R.map(Z=>Z.y)),G=_-N,U=_-q,K=new Map,oe=[];R.forEach(Z=>{const ee=Z.x+G,ue=Z.y+U,ne=a==="LR"?"normal":a==="RL"?"flipped":"center",J=a==="TB"?"normal":a==="BT"?"flipped":"middle";oe.push(p(i,{indexes:Z.indexes,datum:Z.datum,data:o,x:ee,y:ue,positionH:ne,positionV:J,themeColors:Z.themeColors})),K.set(Z.id,q$(H$({},Z),{x:ee,y:ue,centerX:ee+Z.width/2,centerY:ue+Z.height/2}))});const te=[],ae=[];if(h){const Z=wt(P),ee=Ct(P.themeConfig,P),ue=(t=ee==null?void 0:ee.colorBg)!=null?t:"#ffffff",ne=(n=ee==null?void 0:ee.colorText)!=null?n:Z,J=Math.max(10,u*4),ie=a==="TB"||a==="BT",re=x==="ant-line",ce=re?g:"",he=re?ce:!re&&f==="dashed"?g:"",ge=re?ce.split(",").reduce((ye,xe)=>ye+parseFloat(xe.trim()||"0"),0):0,de=re&&ge>0?`${ge/(w*10)}s`:"1s",we=y,Se=(ye,xe,Ae)=>ye.map(([Me,le],me)=>`${me===0?"M":"L"} ${Me+xe} ${le+Ae}`).join(" "),Ie=(ye,xe,Ae,Me)=>{if(ye.length<2)return"";const le=(Oe,Be,Qe)=>Math.min(Qe,Math.max(Be,Oe)),me=([Oe,Be])=>({x:Oe+Ae,y:Be+Me}),Ce=[],Ye=me(ye[0]);if(Ce.push(`M ${Ye.x} ${Ye.y}`),ye.length===2){const Oe=me(ye[1]);return Ce.push(`L ${Oe.x} ${Oe.y}`),Ce.join(" ")}for(let Oe=1;Oe<ye.length-1;Oe+=1){const Be=ye[Oe-1],Qe=ye[Oe],Je=ye[Oe+1],Xe=Qe[0]-Be[0],ft=Qe[1]-Be[1],et=Je[0]-Qe[0],jt=Je[1]-Qe[1],Bt=Math.hypot(Xe,ft),Ue=Math.hypot(et,jt);if(Bt===0||Ue===0){const ti=me(Qe);Ce.push(`L ${ti.x} ${ti.y}`);continue}const $t=le(xe,0,Math.min(Bt,Ue)/2);if($t===0){const ti=me(Qe);Ce.push(`L ${ti.x} ${ti.y}`);continue}const Rt=Xe/Bt,Ut=ft/Bt,Ln=et/Ue,Jr=jt/Ue,ei=me([Qe[0]-Rt*$t,Qe[1]-Ut*$t]),zn=me([Qe[0]+Ln*$t,Qe[1]+Jr*$t]);Ce.push(`L ${ei.x} ${ei.y}`);const ol=me(Qe);Ce.push(`Q ${ol.x} ${ol.y} ${zn.x} ${zn.y}`)}const rt=me(ye[ye.length-1]);return Ce.push(`L ${rt.x} ${rt.y}`),Ce.join(" ")},$e=(ye,xe,Ae,Me,le)=>{const me=Math.cos(Ae),Ce=Math.sin(Ae),Ye=-Ce,rt=me,Oe=J,Be=J*.55;if(Me==="arrow"){const Je=ye-me*Oe+Ye*Be,Xe=xe-Ce*Oe+rt*Be,ft=ye-me*Oe-Ye*Be,et=xe-Ce*Oe-rt*Be;return[p(Pe,{d:`M ${Je} ${Xe} L ${ye} ${xe} L ${ft} ${et}`,stroke:le,strokeWidth:Math.max(1.5,u),strokeLinecap:"round",strokeLinejoin:"round",fill:"none"})]}if(Me==="diamond"){const Je=Oe*1.25,Xe=Be*.75,ft=ye-me*Je*.5,et=xe-Ce*Je*.5,jt=[{x:ye,y:xe},{x:ft+Ye*Xe,y:et+rt*Xe},{x:ye-me*Je,y:xe-Ce*Je},{x:ft-Ye*Xe,y:et-rt*Xe}];return[p(Wt,{points:jt,fill:le,stroke:le,strokeWidth:Math.max(1,u*.8)})]}const Qe=[{x:ye,y:xe},{x:ye-me*Oe+Ye*Be,y:xe-Ce*Oe+rt*Be},{x:ye-me*Oe-Ye*Be,y:xe-Ce*Oe-rt*Be}];return[p(Wt,{points:Qe,fill:le,stroke:le,strokeWidth:Math.max(1,u*.8)})]},Le=ye=>{if(ye.length===0)return null;if(ye.length===1)return ye[0];let xe=0;const Ae=[];for(let le=0;le<ye.length-1;le+=1){const me=ye[le],Ce=ye[le+1],Ye=Math.hypot(Ce[0]-me[0],Ce[1]-me[1]);Ae.push({length:Ye,start:me,end:Ce}),xe+=Ye}if(xe===0)return ye[0];let Me=xe/2;for(let le=0;le<Ae.length;le+=1){const me=Ae[le];if(Me<=me.length||le===Ae.length-1){const Ce=me.length===0?0:Math.max(0,Math.min(1,Me/me.length));return[me.start[0]+(me.end[0]-me.start[0])*Ce,me.start[1]+(me.end[1]-me.start[1])*Ce]}Me-=me.length}return ye[Math.floor(ye.length/2)]},je=(ye,xe)=>{const Ae=K.get(ye),Me=K.get(xe);return!Ae||!Me?null:a==="TB"?{start:[Ae.centerX,Ae.y+Ae.height],end:[Me.centerX,Me.y]}:a==="BT"?{start:[Ae.centerX,Ae.y],end:[Me.centerX,Me.y+Me.height]}:a==="LR"?{start:[Ae.x+Ae.width,Ae.centerY],end:[Me.x,Me.centerY]}:{start:[Ae.x,Ae.centerY],end:[Me.x+Me.width,Me.centerY]}},Fe=(ye,xe)=>{const Ae=je(ye,xe);if(!Ae)return null;const{start:Me,end:le}=Ae;if(ie){const Ce=Me[1]+(le[1]-Me[1])/2;return{start:Me,end:le,points:[Me,[Me[0],Ce],[le[0],Ce],le]}}const me=Me[0]+(le[0]-Me[0])/2;return{start:Me,end:le,points:[Me,[me,Me[1]],[me,le[1]],le]}};I.forEachEdge(ye=>{var xe,Ae,Me,le,me,Ce,Ye,rt,Oe;const Be=_t=>Array.isArray(_t)?_t.map(pt=>pt&&Array.isArray(pt)&&pt.length>=2?[Number(pt[0]),Number(pt[1])]:null).filter(pt=>!!pt&&Number.isFinite(pt[0])&&Number.isFinite(pt[1])):[],Qe=()=>{const _t=K.get(String(ye.source)),pt=K.get(String(ye.target));return!_t||!pt?[]:[[_t.centerX-G,_t.centerY-U],[pt.centerX-G,pt.centerY-U]]},Je=k==="orth",Xe=Je?Fe(String(ye.source),String(ye.target)):null,ft=Je?[]:Be(ye.points),et=Je?(xe=Xe==null?void 0:Xe.points)!=null?xe:[]:ft.length?ft:Qe();if(!et.length)return;const jt=Je?0:G,Bt=Je?0:U,Ue=Je&&(Ae=Xe==null?void 0:Xe.start)!=null?Ae:et[0],$t=Je&&(Me=Xe==null?void 0:Xe.end)!=null?Me:et[et.length-1],Rt=(le=ye._original)==null?void 0:le.relation,Ut=(me=T.get(String(ye.source)))!=null?me:Z,Ln=(Ce=T.get(String(ye.target)))!=null?Ce:Z,Jr=`edge-gradient-${String(Ut)}-${String(Ln)}`.replace(/[^a-zA-Z0-9_-]/g,""),ei=d==="gradient"?`url(#${Jr})`:Z;let zn="";if(we>0?zn=Ie(et,we,jt,Bt):zn=Se(et,jt,Bt),!zn)return;const ol=p(Pe,{d:zn,stroke:ei,strokeWidth:u,strokeDasharray:he,fill:"none","data-element-type":"shape",children:re&&p("animate",{attributeName:"stroke-dashoffset",from:String(ge),to:"0",dur:de,repeatCount:"indefinite"})});if(ae.push(ol),d==="gradient"){const _t=Ue,pt=$t;te.push(L("linearGradient",{id:Jr,gradientUnits:"userSpaceOnUse",x1:_t[0]+jt,y1:_t[1]+Bt,x2:pt[0]+jt,y2:pt[1]+Bt,children:[p("stop",{offset:"0%",stopColor:Ut}),p("stop",{offset:"100%",stopColor:Ln})]}))}if(Rt!=null&&Rt.label){let _t=null;const pt=Le(et);if(pt&&(_t=[pt[0]+jt,pt[1]+Bt]),_t){const ji=String(Rt.label),mr=se(p(ze,{fontSize:14,fontWeight:"normal",children:ji})),ra=_t[0]-mr.width/2,vae=_t[1]-mr.height/2;ae.push(p(ze,{x:ra,y:vae,width:mr.width,height:mr.height,fontSize:14,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:ne,backgroundColor:ue,children:ji}))}}const ti=(Ye=Rt==null?void 0:Rt.showArrow)!=null?Ye:v,pm=(rt=Rt==null?void 0:Rt.direction)!=null?rt:"forward",wS=(Oe=Rt==null?void 0:Rt.arrowType)!=null?Oe:b,PS=et.length-1;if(ti&&et.length>1){if(pm==="forward"||pm==="both"){const _t=et[PS],pt=et[PS-1],ji=Math.atan2(_t[1]-pt[1],_t[0]-pt[0]),mr=d==="gradient"?Ln:Z,ra=$e(_t[0]+jt,_t[1]+Bt,ji,wS,mr);ae.push(...ra)}if(pm==="both"){const _t=et[0],pt=et[1],ji=Math.atan2(_t[1]-pt[1],_t[0]-pt[0]),mr=d==="gradient"?Ut:Z,ra=$e(_t[0]+jt,_t[1]+Bt,ji,wS,mr);ae.push(...ra)}}})}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[E,L(Y,{children:[p(Ke,{children:te}),p(Y,{width:0,height:0,children:ae}),p(Ne,{children:oe}),p(He,{})]})]})};We("relation-dagre-flow",{component:j$,composites:["title","item"]});const F$=e=>{const{Title:t,Item:n,data:r,spacing:i=120,showConnections:o=!0,options:a}=e,{title:s,desc:c,items:l=[]}=r,u=t?p(t,{title:s,desc:c}):null;if(l.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,p(Y,{children:p(Ne,{})})]});const h=se(p(n,{indexes:[0],data:r,datum:l[0],positionH:"center"}));function d(){const $=l.map((S,E)=>({id:E,data:S,isCenter:E===0,_originalIndex:[E]})),C=l.slice(1).map((S,E)=>({source:0,target:E+1})),M=ZV($).force("link",BV(C).id(S=>S.id).distance(i)).force("charge",QV().strength(-50)).force("center",wV(0,0)).force("collision",jV().radius(Math.max(h.width,h.height)/2+10));for(let S=0;S<300;++S)M.tick();return{nodes:$,links:C}}const{nodes:f,links:g}=d(),y=Math.min(...f.map($=>{var C;return(C=$.x)!=null?C:0})),m=Math.min(...f.map($=>{var C;return(C=$.y)!=null?C:0})),v=Math.max(0,-y+h.width/2),b=Math.max(0,-m+h.height/2),_=($,C)=>({positionH:$<-50?"flipped":$>50?"normal":"center",positionV:C<-50?"flipped":C>50?"normal":"middle"}),x=f.map($=>{if($.x==null||$.y==null)return null;const C=$.x+v-h.width/2,M=$.y+b-h.height/2,{positionH:S,positionV:E}=_($.x,$.y);return p(n,{indexes:$._originalIndex,datum:$.data,data:r,x:C,y:M,positionH:S,positionV:E},$.id)}).filter(Boolean),w=new Map(f.map($=>[$.id,$])),P=o?g.map($=>{const C=typeof $.source=="object"?$.source:w.get($.source),M=typeof $.target=="object"?$.target:w.get($.target);if(!C||!M||C.x==null||C.y==null||M.x==null||M.y==null)return null;const S=`M ${C.x+v} ${C.y+b} L ${M.x+v} ${M.y+b}`;return p(Pe,{d:S,stroke:wt(a),strokeWidth:2,strokeOpacity:.6})}).filter(Boolean):[];return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,L(Y,{children:[p(Y,{children:P}),p(Ne,{children:x})]})]})};We("relation-network",{component:F$,composites:["title","item"]});var Ete=Object.defineProperty,Ite=Object.defineProperties,Ate=Object.getOwnPropertyDescriptors,Mc=Object.getOwnPropertySymbols,B$=Object.prototype.hasOwnProperty,W$=Object.prototype.propertyIsEnumerable,G$=(e,t,n)=>t in e?Ete(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tte=(e,t)=>{for(var n in t||(t={}))B$.call(t,n)&&G$(e,n,t[n]);if(Mc)for(var n of Mc(t))W$.call(t,n)&&G$(e,n,t[n]);return e},kte=(e,t)=>Ite(e,Ate(t)),Rte=(e,t)=>{var n={};for(var r in e)B$.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Mc)for(var r of Mc(e))t.indexOf(r)<0&&W$.call(e,r)&&(n[r]=e[r]);return n};const F1=e=>{var t=e,{width:n=25,height:r=25,colorPrimary:i="#6699FF",rotation:o=0}=t,a=Rte(t,["width","height","colorPrimary","rotation"]);const s=`gradient-arrow-stroke-${i.replace("#","")}`,c=`gradient-arrow-fill-${i.replace("#","")}`,l=Math.round(n*.515),u=Math.round(r*.275),h=Math.round(r*.875),d=[{x:0,y:u},{x:l,y:u},{x:l,y:r*.075},{x:n,y:r*.575},{x:l,y:r*1.075},{x:l,y:h},{x:0,y:h}],f=n/2,g=r/2,y=`rotate(${o} ${f} ${g})`;return L(tt,{children:[p(Wt,kte(Tte({},a),{width:n,height:r,points:d,fill:`url(#${c})`,stroke:`url(#${s})`,transform:y,"data-element-type":"shape"})),L(Ke,{children:[L("linearGradient",{id:c,x1:"100%",y1:"0%",x2:"0%",y2:"0%",children:[p("stop",{offset:"0%","stop-color":i,"stop-opacity":"0.36"}),p("stop",{offset:"100%","stop-color":i,"stop-opacity":"0"})]}),L("linearGradient",{id:s,x1:"100%",y1:"0%",x2:"0%",y2:"0%",children:[p("stop",{offset:"0%","stop-color":i}),p("stop",{offset:"58%","stop-color":i,"stop-opacity":"0"})]})]})]})},Lte=({text:e,x:t=0,y:n=0,fontSize:r=56,fontWeight:i="bold",fill:o="#FFFFFF",textAnchor:a="middle",dominantBaseline:s="middle",shadowOffsetX:c=2,shadowOffsetY:l=4,midShadowOffsetX:u=1,midShadowOffsetY:h=2,deepShadowOpacity:d=.3,midShadowOpacity:f=.5})=>L(Y,{children:[p("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,fillOpacity:d,textAnchor:a,dominantBaseline:s,transform:`translate(${c}, ${l})`,children:e}),p("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,fillOpacity:f,textAnchor:a,dominantBaseline:s,transform:`translate(${u}, ${h})`,children:e}),p("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,textAnchor:a,dominantBaseline:s,children:e})]});var zte=Object.defineProperty,Nte=Object.defineProperties,Dte=Object.getOwnPropertyDescriptors,Ec=Object.getOwnPropertySymbols,V$=Object.prototype.hasOwnProperty,Y$=Object.prototype.propertyIsEnumerable,X$=(e,t,n)=>t in e?zte(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Hte=(e,t)=>{for(var n in t||(t={}))V$.call(t,n)&&X$(e,n,t[n]);if(Ec)for(var n of Ec(t))Y$.call(t,n)&&X$(e,n,t[n]);return e},qte=(e,t)=>Nte(e,Dte(t)),jte=(e,t)=>{var n={};for(var r in e)V$.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ec)for(var r of Ec(e))t.indexOf(r)<0&&Y$.call(e,r)&&(n[r]=e[r]);return n};const Fte=e=>{var t=e,{width:n=25,height:r=25,colorPrimary:i="#6699FF",rotation:o=0,strokeWidth:a=4}=t,s=jte(t,["width","height","colorPrimary","rotation","strokeWidth"]);const c=[{x:n/2,y:0},{x:n,y:r},{x:0,y:r}],l=n/2,u=r/2,h=`rotate(${o} ${l} ${u})`;return p(Wt,qte(Hte({},s),{width:n,height:r,points:c,fill:i,stroke:i,strokeWidth:a,strokeLinecap:"round",strokeLinejoin:"round",transform:h}))},Bte=-118,U$=118,K$=240,Wte=180,Gte=40,Vte="M238.9 69.7a6 6 0 0 1-.1 1v.2l-.2.3v.3l-.1.3a6.2 6.2 0 0 1-.3.6l-.1.3-.2.3-.2.4-.3.5-.1.1a10.9 10.9 0 0 1-.8 1v.1l-.5.5h-.1l-.4.4-.3.3-.3.2-.3.3-.4.2a13 13 0 0 1-.7.5l-.4.3-.5.3-97.5 56.7-.7.4h-.2l-.6.4h-.1l-.8.4h-.2l-.6.4h-.2l-.8.3h-.2l-.5.3-.5.1-.5.1-.5.2h-.5a33.7 33.7 0 0 1-3.2.7h-.2l-1 .2h-1.6l-.7.1h-4.7l-.8-.1h-.2a38.2 38.2 0 0 1-2-.4h-.4l-.7-.2h-.4l-.7-.2-.4-.1a27.3 27.3 0 0 1-2.2-.7h-.2a44.2 44.2 0 0 1-.9-.3l-.5-.3-.4-.1-.5-.2-.3-.2-.5-.2-.3-.2-.8-.4L6.5 78C2.2 75.6 0 72.4 0 69v41.7c0 3.2 2.1 6.5 6.4 9l98.1 56.6a23.2 23.2 0 0 0 1 .6l.6.3.3.1.5.2.4.2.3.1h.2l.2.2a21.4 21.4 0 0 0 1.9.6l.3.1h.2l.7.2a77.6 77.6 0 0 1 1.1.3h.3l.7.2h.4a42.5 42.5 0 0 0 1 .2l1 .2h1.1l.4.1h2.1l.7.1h1.5a22 22 0 0 0 1.8-.2h.4l1.1-.1h.2l1.2-.2h.1l.3-.1.6-.1a12.5 12.5 0 0 0 1-.3h.5l.5-.2a29 29 0 0 0 1-.3h.2l.3-.2h.2a27 27 0 0 0 1.6-.7h.2l.8-.4a19.4 19.4 0 0 0 1.6-.9l97.5-56.7.3-.1.2-.2.4-.2.4-.3.3-.2.3-.3.4-.2.3-.3.3-.3h.1l.3-.3.5-.6h.1l.3-.5h.1v-.1l.4-.4v-.1l.4-.5v-.1l.1-.2.1-.2.2-.3.1-.3.1-.3.1-.1a6.9 6.9 0 0 0 .2-.8l.1-.3v-.4l.1-.3v-1l.2-41.4v.4Z",Yte="M232.5 60.4c8.5 4.9 8.5 12.8.1 17.7l-97.5 56.7c-8.4 4.9-22 4.9-30.5 0L6.5 78C-2 73-2 65.3 6.4 60.4l97.5-56.7c8.4-5 22-5 30.5 0l98.1 56.7Z",Xte="M119.1 0A31 31 0 0 0 104 3.7L6.4 60.4C-2 65.3-2 73.2 6.4 78l98.2 56.7c4.2 2.4 9.8 3.7 15.3 3.7a31 31 0 0 0 15.2-3.7L232.6 78c8.4-5 8.4-12.8 0-17.7L134.3 3.7A31.2 31.2 0 0 0 119.1 0Zm0 2.5c5.4 0 10.3 1.2 14 3.3l98.2 56.7c3.3 2 5.1 4.3 5.1 6.8 0 2.4-1.8 4.7-5 6.6l-97.5 56.7a28.3 28.3 0 0 1-14 3.4c-5.3 0-10.3-1.2-14-3.4L7.7 76c-3.3-1.9-5-4.3-5-6.7 0-2.4 1.7-4.8 5-6.7L105 5.8a29 29 0 0 1 14-3.3Z",Z$=L("filter",{id:"sequence-ascending-stairs-3d-shadow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[p("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),p("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),p("feOffset",{dx:"0",dy:"4"}),p("feGaussianBlur",{stdDeviation:"6"}),p("feComposite",{in2:"hardAlpha",operator:"out"}),p("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"}),p("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow"}),p("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow",result:"shape"})]}),Q$=e=>{const{Title:t,Item:n,data:r,options:i,cubeWidth:o=K$}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null;if(c.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[p(Ke,{children:Z$}),l,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const u=se(p(Q,{indexes:[0]})),h=[],d=[],f=[],g=o/K$,y=Wte*g;return c.forEach((m,v)=>{const b=[v],_=qe(i,b),x=v*(o+Bte),w=(c.length-1-v)*U$,P=`cube-gradient-bottom-${v}`,$=`cube-gradient-top-${v}`,C=`cube-gradient-stroke-${v}`;f.push(L(Y,{x,y:w,id:`cube-${v}`,width:o,height:y,filter:"url(#sequence-ascending-stairs-3d-shadow-filter)",children:[L(Ke,{children:[L("linearGradient",{id:P,x1:"0",y1:"124.5",x2:"238.9",y2:"124.5",gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0",stopColor:_,stopOpacity:"0.8"}),p("stop",{offset:"1",stopColor:_,stopOpacity:"0.4"})]}),L("linearGradient",{id:$,x1:"119.5",y1:"0",x2:"119.5",y2:"138.5",gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0",stopColor:_,stopOpacity:"0.9"}),p("stop",{offset:"1",stopColor:_,stopOpacity:"0.5"})]}),L("linearGradient",{id:C,x1:"119.5",y1:"0",x2:"119.5",y2:"138.5",gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0",stopColor:_}),p("stop",{offset:"1",stopColor:_,stopOpacity:"0.7"})]})]}),L(xt,{transform:`scale(${g})`,children:[p(Pe,{d:Vte,fill:`url(#${P})`}),p(Pe,{d:Yte,fill:`url(#${$})`}),p(Pe,{d:Xte,fill:`url(#${C})`})]}),p(Lte,{text:v+1,x:115,y:65,fontSize:56})]}));const M=x+o+Gte,S=w+y/2;if(d.push(p(n,{indexes:b,datum:m,data:r,x:M,y:S,positionH:"normal"})),h.push(p(nt,{indexes:b,x:x+o-u.width/2,y:w-u.height/2})),v===0&&h.push(p(Q,{indexes:[0],x:x-30-u.width/2,y:w+y/2-u.height/2})),v<c.length-1){const E=(c.length-1-(v+1))*U$,A=x+o-u.width/2,O=(w+y/2+E+y/2)/2-u.height/2;h.push(p(Q,{indexes:[v+1],x:A,y:O}))}else h.push(p(Q,{indexes:[c.length],x:x+o+30-u.width/2,y:w+y/2-u.height/2}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[p(Ke,{children:Z$}),l,L(Y,{x:0,y:0,children:[p(Y,{children:f}),p(Ne,{children:d}),p(He,{children:h})]})]})};We("sequence-ascending-stairs-3d",{component:Q$,composites:["title","item"]});const J$=e=>{const{Title:t,Item:n,data:r,hGap:i=0,vGap:o=0}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=se(p(n,{indexes:[0],data:r,datum:c[0]})),h=[],d=[],f=c.length,g=u.width+i,y=u.height/2+o,m=u.width/2,b=0+(f-1)*y;return c.forEach((_,x)=>{const w=m+x*g,P=b-x*y,$=[x];h.push(p(n,{indexes:$,datum:_,data:r,x:w,y:P})),d.push(p(nt,{indexes:$,x:w+u.width-30,y:P+u.height/2+10})),d.push(p(Q,{indexes:$,x:w+u.width+i/2,y:P-30}))}),L(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(Ne,{children:h}),p(He,{children:d})]})]})};We("sequence-ascending-steps",{component:J$,composites:["title","item"]});const Ute=20,eC=5,tC=e=>{const{Title:t,Item:n,data:r,options:i,radius:o=150,arrowSize:a=4,strokeWidth:s=10}=e,{title:c,desc:l,items:u=[]}=r,h=se(p(Q,{indexes:[0]})),d=wt(i);if(!n)return L(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[t?p(t,{title:c,desc:l}):null,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const f=u.length;if(f===0)return L(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[t?p(t,{title:c,desc:l}):null,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const g=se(p(n,{indexes:[0],data:r,datum:u[0]})),y=0,m=0,v=2*Math.PI/f,b=[];let _=1/0,x=1/0,w=-1/0,P=-1/0;for(let z=0;z<f;z++){const j=z*v-Math.PI/2,D=y+o*Math.cos(j),W=m+o*Math.sin(j);b.push({x:D,y:W}),_=Math.min(_,D),x=Math.min(x,W),w=Math.max(w,D),P=Math.max(P,W)}const $=[];for(let z=0;z<f;z++){const j=b[z],D=b[(z+1)%f],W=Math.sqrt(Math.pow(D.x-j.x,2)+Math.pow(D.y-j.y,2)),B=Math.min(W*.5,100),X=(j.x+D.x)/2,H=(j.y+D.y)/2;_=Math.min(_,X-B/2),x=Math.min(x,H-B/2),w=Math.max(w,X+B/2),P=Math.max(P,H+B/2);const k=Math.atan2(H-m,X-y),I=k<0?k+2*Math.PI:k;let R,N;const q=I*180/Math.PI,G=B/2+Ute,U=X+Math.cos(k)*G,K=H+Math.sin(k)*G;q>=337.5||q<22.5?(R=U,N=K-g.height/2):q>=22.5&&q<67.5?(R=U,N=K):q>=67.5&&q<112.5?(R=U-g.width/2,N=K):q>=112.5&&q<157.5?(R=U-g.width,N=K):q>=157.5&&q<202.5?(R=U-g.width,N=K-g.height/2):q>=202.5&&q<247.5?(R=U-g.width,N=K-g.height):q>=247.5&&q<292.5?(R=U-g.width/2,N=K-g.height):(R=U,N=K-g.height),$.push({lineLength:W,circleBigW:B,midX:X,midY:H,itemX:R,itemY:N}),_=Math.min(_,R),x=Math.min(x,N),w=Math.max(w,R+g.width+h.width+5),P=Math.max(P,N+g.height)}const C=Math.max(0,-_),M=Math.max(0,-x),S=t?p(t,{title:c,desc:l}):null,E=[],A=[],O=[],T=[],F=b.map(z=>({x:z.x+C,y:z.y+M}));for(let z=0;z<f;z++){const j=F[z],D=F[(z+1)%f],W=(z+1)%f,B=[z],{lineLength:X,circleBigW:H,midX:k,midY:I}=$[z],R=Math.max(H-20,20),N=Math.max(R*.4,16),q=qe(i,B)||d,G=D.x-j.x,U=D.y-j.y,K=X,oe=G/K,te=U/K,ae=eC*2+a,Z=Math.min(eC,(K-ae)/2),ee=Math.max(0,j.x+oe*Z),ue=Math.max(0,j.y+te*Z),ne=Math.max(0,D.x-oe*Z),J=Math.max(0,D.y-te*Z),re=rX().x($e=>Math.max(0,$e.x)).y($e=>Math.max(0,$e.y)).curve(uw)([{x:ee,y:ue},{x:ne,y:J}])||"",pe=`fork-arrow-${q.replace(/[^a-zA-Z0-9]/g,"")}-${z}`,he=`
|
|
114
|
-
M ${-
|
|
113
|
+
`.trim()}return k(Y,{id:"infographic-container",children:[y(Y,{children:g}),_?y(Ze,{id:"shape-center-circle",x:m-P,y:v-P,width:P*2,height:P*2,fill:h.colorPrimaryBg,fillOpacity:.5,"data-element-type":"shape"}):y(Ce,{id:"shape-center-sector",d:I,fill:h.colorPrimaryBg,fillOpacity:.5,width:r*2+200,height:r*2+200,"data-element-type":"shape"}),y(Ne,{x:O-S/2,y:$-M/2,width:S,height:M,alignHorizontal:"center",alignVertical:"middle",fontSize:24,fontWeight:"bold",fill:h.colorText,"data-element-type":Ge.Title,children:c}),y(ze,{children:p}),y(qe,{children:d})]})};We("list-sector",{component:H5,composites:["title","item"]});const j5=e=>{const{Title:t,Item:n,data:r,columns:i=4,gap:o=20,stepOffset:s=40}=e,{title:a,desc:l,items:c=[]}=r,u=t?y(t,{title:a,desc:l}):null,h=ae(y(Q,{indexes:[0]})),f=ae(y(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),d=[],p=[],g=f.width+o;return c.forEach((m,v)=>{const b=v%i,_=Math.floor(v/i),x=b*g,w=_*(f.height+o),C=b*s,P=w+C,O=[v];p.push(y(n,{indexes:O,datum:m,data:r,x,y:P,positionH:"center"})),d.push(y(nt,{indexes:O,x:x+(f.width-h.width)/2,y:P+f.height+5}))}),c.forEach((m,v)=>{const b=v%i,_=Math.floor(v/i),x=b*g,w=_*(f.height+o),C=b*s,P=w+C;if(v===0&&d.push(y(Q,{indexes:[0],x:x-o/2-h.width/2,y:P+(f.height-h.height)/2})),b<i-1&&v<c.length-1){const O=Math.floor((v+1)/i);_===O&&d.push(y(Q,{indexes:[v+1],x:x+f.width+(o-h.width)/2,y:P+(f.height-h.height)/2}))}(b===i-1||v===c.length-1)&&d.push(y(Q,{indexes:[v+1],x:x+f.width+(o-h.width)/2,y:P+(f.height-h.height)/2}))}),c.length===0&&d.push(y(Q,{indexes:[0],x:(i-1)*g/2+(f.width-h.width)/2,y:0})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,k(Y,{children:[y(ze,{children:p}),y(qe,{children:d})]})]})};We("list-waterfall",{component:j5,composites:["title","item"]});const TQ=6,yf=700,F5=330,B5=333,RQ={1:[{x:.5,y:.6,anchor:"top-right"}],2:[{x:.42,y:.5,anchor:"top-right"},{x:.72,y:.4,anchor:"bottom"}],3:[{x:.3,y:.5,anchor:"top-right"},{x:.48,y:.3,anchor:"bottom-left"},{x:.8,y:.75,anchor:"top-right"}],4:[{x:.3,y:.5,anchor:"top-right"},{x:.35,y:.2,anchor:"bottom-left"},{x:.65,y:.73,anchor:"top-right"},{x:.8,y:.52,anchor:"bottom-left"}],5:[{x:.19,y:.4,anchor:"top-right"},{x:.38,y:.2,anchor:"bottom"},{x:.52,y:.62,anchor:"top-right"},{x:.7,y:.43,anchor:"bottom"},{x:.82,y:.8,anchor:"top-right"}],6:[{x:.16,y:.35,anchor:"top-right"},{x:.38,y:.2,anchor:"bottom"},{x:.48,y:.54,anchor:"top-right"},{x:.55,y:.43,anchor:"bottom-left"},{x:.8,y:.75,anchor:"top-right"},{x:.86,y:.65,anchor:"bottom-left"}]},kQ={1:[{x:.5,y:.4,anchor:"bottom-right"}],2:[{x:.42,y:.5,anchor:"bottom-right"},{x:.72,y:.6,anchor:"top"}],3:[{x:.3,y:.5,anchor:"bottom-right"},{x:.48,y:.7,anchor:"top-left"},{x:.8,y:.25,anchor:"bottom-right"}],4:[{x:.3,y:.5,anchor:"bottom-right"},{x:.35,y:.8,anchor:"top-left"},{x:.65,y:.27,anchor:"bottom-right"},{x:.8,y:.48,anchor:"top-left"}],5:[{x:.19,y:.6,anchor:"bottom-right"},{x:.38,y:.8,anchor:"top"},{x:.52,y:.38,anchor:"bottom-right"},{x:.7,y:.57,anchor:"top"},{x:.82,y:.2,anchor:"bottom-right"}],6:[{x:.16,y:.65,anchor:"bottom-right"},{x:.38,y:.8,anchor:"top"},{x:.48,y:.46,anchor:"bottom-right"},{x:.55,y:.57,anchor:"top-left"},{x:.8,y:.25,anchor:"bottom-right"},{x:.86,y:.35,anchor:"top-left"}]},W5=(e,t,n)=>{const r=t[e];return r?r.map(i=>({x:i.x*yf,y:i.y*n,anchor:i.anchor})):null},LQ=(e,t)=>{const n=e.anchor||"center";let r=e.x-t.width/2,i=e.y-t.height/2,o=e.y;switch(n){case"top":r=e.x-t.width/2,i=e.y,o=e.y+t.height/2;break;case"bottom":r=e.x-t.width/2,i=e.y-t.height,o=e.y-t.height/2;break;case"top-left":r=e.x,i=e.y,o=e.y+t.height/2;break;case"top-right":r=e.x-t.width,i=e.y,o=e.y+t.height/2;break;case"bottom-left":r=e.x,i=e.y-t.height,o=e.y-t.height/2;break;case"bottom-right":r=e.x-t.width,i=e.y-t.height,o=e.y-t.height/2;break}return{x:r,y:i,centerY:o}},vf=(e,t)=>{const n=t.x-e.x,r=t.y-e.y,i=Math.hypot(n,r)||1;return{x:n/i,y:r/i}},V5=e=>{const{presetRatios:t,arrowHeight:n,Arrow:r}=e;return o=>{var s;const{Title:a,Item:l,data:c,options:u,itemGap:h=24}=o,{title:f,desc:d,items:p=[]}=c,g=Math.min(p.length,TQ),m=p.slice(0,g),v=a?y(a,{title:f,desc:d}):null,b=Ot(u),x=Et({colorPrimary:b},u).colorTextSecondary||"#737373",w=ae(y(Q,{indexes:[0]}));if(p.length===0){const N=(s=W5(1,t,n))==null?void 0:s[0];if(!N)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,y(Y,{children:y(r,{colorPrimary:b,colorShadow:x})})]});const H=N.x-w.width/2,D=N.y-w.height/2;return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,k(Y,{children:[y(r,{colorPrimary:b,colorShadow:x}),y(ze,{}),y(qe,{children:y(Q,{indexes:[0],x:H,y:D})})]})]})}const C=ae(y(l,{indexes:[0],data:c,datum:p[0],positionH:"center"})),P=[],O=[],$=W5(g,t,n);if(!$)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,k(Y,{children:[y(r,{colorPrimary:b,colorShadow:x}),y(ze,{})]})]});const S=$,M=S.length>1?vf(S[0],S[S.length-1]):{x:1,y:0},I=S.length>1?vf(S[0],S[1]):M,E=S.length>1?vf(S[S.length-2],S[S.length-1]):M,A=Math.max(C.width,C.height)*.45+h,T=N=>{const{x:H,y:D,centerY:B}=LQ(N,C);return{x:H,y:D,centerY:B}};if(S.forEach((N,H)=>{const D=T(N),B=D.centerY<n/2,F=[H],X=m[H];if(!X)return;O.push(y(l,{indexes:F,datum:X,data:c,x:D.x,y:D.y,positionH:"center"}));const G=D.x+C.width-w.width/2,L=B?D.y-w.height/2:D.y+C.height-w.height/2;P.push(y(nt,{indexes:F,x:G,y:L}))}),S.length>0){const N=S[0],H=N.x-I.x*A-w.width/2,D=N.y-I.y*A-w.height/2;P.push(y(Q,{indexes:[0],x:H,y:D}));for(let G=0;G<S.length-1;G++){const L=S[G],R=S[G+1],z=(L.x+R.x)/2,q=(L.y+R.y)/2,j=z-w.width/2,V=q-w.height/2;P.push(y(Q,{indexes:[G+1],x:j,y:V}))}const B=S[S.length-1],F=B.x+E.x*A-w.width/2,X=B.y+E.y*A-w.height/2;P.push(y(Q,{indexes:[g],x:F,y:X}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[v,k(Y,{children:[y(r,{colorPrimary:b,colorShadow:x}),y(ze,{children:O}),y(qe,{children:P})]})]})}},NQ=({colorPrimary:e="#17CA2C",colorShadow:t="#737373"})=>{const n=be(e).darken(20).toHexString();return k(Y,{width:yf,height:F5,children:[y("path",{d:"M228.864 159.446C230.266 159.446 231.623 158.768 232.689 157.535L274.263 110.162L265.717 102.923L227.311 148.082C225.977 149.623 224.281 150.47 222.529 150.47H175.404L182.03 158.367C182.795 159.445 182.795 159.446 183.734 159.446H228.864Z",fill:t}),y("path",{d:"M462.869 234.92C464.271 234.92 465.628 234.242 466.695 233.01L508.268 185.636L499.722 178.397L461.316 223.557C459.983 225.098 458.287 225.945 456.534 225.945H409.409L416.035 233.841C416.8 234.92 416.8 234.92 417.74 234.92H462.869Z",fill:t}),y("path",{d:"M697.005 330C698.783 330 700 328.82 700 327.001V256.638C700 254.857 697.848 253.965 696.591 255.225L693.409 258.411V320.402C693.409 322.058 692.069 323.401 690.414 323.401H630.718L627.536 326.587C626.278 327.847 627.169 330 628.947 330H697.005Z",fill:t}),y("path",{d:"M689.642 321.89C690.744 321.89 691.638 320.995 691.638 319.891V250.743C691.638 248.962 689.488 248.07 688.23 249.329L662.647 274.947L520.987 153.863C519.541 152.627 517.703 151.948 515.802 151.948H469.518C470.236 151.949 470.956 152.206 471.53 152.729L498.163 176.978L498.13 177.018L639.84 297.784L619.174 318.477C617.916 319.737 618.807 321.89 620.586 321.89H689.642Z",fill:e}),y("path",{d:"M429.279 198.995L467.208 153.03C468.3 151.716 470.268 151.579 471.531 152.729L498.163 176.978L460.69 221.107C459.173 222.894 456.946 223.924 454.6 223.924H408.473C409.366 223.924 410.252 223.527 410.845 222.764L429.279 198.995Z",fill:n}),y("path",{d:"M408.473 223.924H408.314L408.318 223.92C408.369 223.922 408.421 223.924 408.473 223.924Z",fill:n}),y("path",{d:"M406.524 223.203C407.826 224.318 409.796 224.116 410.845 222.761L429.279 198.932L287.411 77.8866C285.964 76.6523 284.125 75.9742 282.223 75.9742H234.606L234.625 75.9907C235.429 75.9118 236.263 76.1557 236.915 76.7378L263.662 100.621L263.546 100.758L406.524 223.203Z",fill:e}),y("path",{d:"M236.914 76.7386C235.651 75.6097 233.707 75.7513 232.621 77.0513L194.557 123.104L175.644 146.821C175.076 147.535 174.25 147.917 173.409 147.947L173.407 147.95H219.923C222.271 147.95 224.499 146.915 226.017 145.122L263.645 100.649L236.914 76.7386Z",fill:n}),y("path",{d:"M175.648 146.816C174.589 148.145 172.637 148.329 171.348 147.221L4.09334 3.51697C2.68586 2.30767 3.54106 0 5.39671 0H47.5805C49.4864 0 51.3297 0.680433 52.7785 1.91877L194.557 123.104L175.648 146.816Z",fill:e})]})},zQ=({colorPrimary:e="#17CA2C",colorShadow:t="#737373"})=>{const n=be(e).darken(20).toHexString();return k(Y,{width:yf,height:B5,children:[y("path",{d:"M19.0526 324L12.6762 329.482C11.2703 330.691 12.1234 333 13.976 333H56.1578C58.058 333 59.896 332.321 61.3413 331.085L201.854 210.901L194.249 201.693L54.0527 321.606C52.246 323.151 49.9486 324 47.5732 324H19.0526Z",fill:t}),y("path",{d:"M234.587 248L241.131 255.922C241.656 256.552 242.382 256.909 243.134 256.983L243.115 257H290.716C292.618 257 294.457 256.322 295.903 255.087L437.091 134.536L429.305 125.5L288.613 245.609C286.805 247.153 284.507 248 282.132 248H234.587Z",fill:t}),y("path",{d:"M461.123 162.429L475.642 179.918C476.237 180.635 477.092 181.001 477.951 181H524.22C526.121 181 527.959 180.321 529.404 179.085L670.786 58.1578L662.326 49.6809L522.115 169.606C520.309 171.151 518.011 172 515.636 172H469.369L461.123 162.429Z",fill:t}),y("path",{d:"M687.912 74.8875C690.374 75.9052 693.412 74.1668 693.412 71.1716V11H698.004C699.106 11 700 11.8954 700 13V82.1716C700 83.9534 697.85 84.8457 696.593 83.5858L687.912 74.8875Z",fill:t}),y("path",{d:"M689.419 0C690.522 0 691.415 0.895432 691.415 2V71.1716C691.415 72.9534 689.265 73.8457 688.008 72.5858L662.433 46.9598L520.819 168.085C519.374 169.321 517.536 170 515.636 170H469.367C470.084 169.999 470.804 169.742 471.379 169.219L498.003 144.961L497.969 144.922L639.634 24.115L618.975 3.41421C617.717 2.15428 618.608 0 620.386 0H689.419Z",fill:e}),y("path",{d:"M429.141 122.937L467.058 168.918C468.149 170.232 470.116 170.369 471.378 169.219L498.003 144.961L460.542 100.818C459.025 99.0305 456.798 98 454.453 98H408.341C409.234 98.0001 410.12 98.3968 410.712 99.1606L429.141 122.937Z",fill:n}),y("path",{d:"M408.341 98H408.183L408.186 98.004C408.237 98.0013 408.289 98 408.341 98Z",fill:n}),y("path",{d:"M406.393 98.721C407.695 97.606 409.664 97.8077 410.712 99.1633L429.141 123L287.318 244.087C285.872 245.322 284.033 246 282.132 246H234.53L234.55 245.983C235.353 246.062 236.187 245.818 236.839 245.236L263.577 221.345L263.461 221.208L406.393 98.721Z",fill:e}),y("path",{d:"M236.837 245.235C235.575 246.365 233.631 246.223 232.546 244.922L194.494 198.854L175.588 175.129C175.019 174.415 174.194 174.032 173.353 174.002L173.351 174H219.852C222.199 174 224.427 175.035 225.944 176.829L263.56 221.317L236.837 245.235Z",fill:n}),y("path",{d:"M175.593 175.135C174.533 173.805 172.581 173.622 171.291 174.73L4.09013 318.484C2.68329 319.693 3.53868 322 5.394 322H47.5627C49.4695 322 51.3136 321.319 52.7627 320.08L194.494 198.854L175.593 175.135Z",fill:e})]})},G5=V5({arrowHeight:F5,presetRatios:RQ,Arrow:NQ}),Y5=V5({arrowHeight:B5,presetRatios:kQ,Arrow:zQ});We("list-zigzag-down",{component:G5,composites:["title","item"]}),We("list-zigzag-up",{component:Y5,composites:["title","item"]});const X5=e=>{const{Title:t,Item:n,data:r,radius:i=150,startMode:o="top"}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=ae(y(Q,{indexes:[0]})),h=ae(y(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),f=[],d=[];if(l.length===0)return f.push(y(Q,{indexes:[0],x:-u.width/2,y:-u.height/2})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,y(Y,{children:y(qe,{children:f})})]});const p=Math.max(h.width,h.height),g=Math.max(i,p),m=g+p/2,v=l.map(()=>{const C=h.width,P=h.height;return(C+P)/2}),b=v.reduce((C,P)=>C+P,0);let _;o==="equal"?_=-Math.PI/2:_=-Math.PI/2+2*Math.PI/l.length/2;let x=_;l.forEach((C,P)=>{const O=v[P]/b*2*Math.PI,$=x+O/2;x+=O;const S=m+g*Math.cos($)-h.width/2,M=m+g*Math.sin($)-h.height/2;d.push(y(n,{indexes:[P],datum:C,data:r,x:S,y:M}));const I=g-Math.max(h.width,h.height)/2-20,E=m+I*Math.cos($)-u.width/2,A=m+I*Math.sin($)-u.height/2;f.push(y(nt,{indexes:[P],x:E,y:A}))});const w=g-Math.max(h.width,h.height)/2-20;if(l.length>0)for(let C=0;C<l.length;C++){const P=C*2*Math.PI/l.length-Math.PI/2,O=(C+1)%l.length*2*Math.PI/l.length-Math.PI/2;let $;if(C===l.length-1){const I=O+2*Math.PI-P;$=P+I/2}else $=(P+O)/2;const S=m+w*Math.cos($)-u.width/2,M=m+w*Math.sin($)-u.height/2;f.push(y(Q,{indexes:[C+1],x:S,y:M}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(ze,{children:d}),y(qe,{children:f})]})]})};We("relation-circle",{component:X5,composites:["title","item"]});function Yo(e,t,n,r){function i(o){return o instanceof n?o:new n(function(s){s(o)})}return new(n||(n=Promise))(function(o,s){function a(u){try{c(r.next(u))}catch(h){s(h)}}function l(u){try{c(r.throw(u))}catch(h){s(h)}}function c(u){u.done?o(u.value):i(u.value).then(a,l)}c((r=r.apply(e,[])).next())})}typeof SuppressedError=="function"&&SuppressedError;const DQ={abs:Math.abs,ceil:Math.ceil,floor:Math.floor,max:Math.max,min:Math.min,round:Math.round,sqrt:Math.sqrt,pow:Math.pow};class Tt extends Error{constructor(t,n,r){super(t),this.position=n,this.token=r,this.name="ExpressionError"}}var De;(function(e){e[e.STRING=0]="STRING",e[e.NUMBER=1]="NUMBER",e[e.BOOLEAN=2]="BOOLEAN",e[e.NULL=3]="NULL",e[e.IDENTIFIER=4]="IDENTIFIER",e[e.OPERATOR=5]="OPERATOR",e[e.FUNCTION=6]="FUNCTION",e[e.DOT=7]="DOT",e[e.BRACKET_LEFT=8]="BRACKET_LEFT",e[e.BRACKET_RIGHT=9]="BRACKET_RIGHT",e[e.PAREN_LEFT=10]="PAREN_LEFT",e[e.PAREN_RIGHT=11]="PAREN_RIGHT",e[e.COMMA=12]="COMMA",e[e.QUESTION=13]="QUESTION",e[e.COLON=14]="COLON",e[e.DOLLAR=15]="DOLLAR"})(De||(De={}));const qQ=new Set([32,9,10,13]),HQ=new Set([43,45,42,47,37,33,38,124,61,60,62]),jQ=new Map([["true",De.BOOLEAN],["false",De.BOOLEAN],["null",De.NULL]]),bf=new Map([["===",!0],["!==",!0],["<=",!0],[">=",!0],["&&",!0],["||",!0],["+",!0],["-",!0],["*",!0],["/",!0],["%",!0],["!",!0],["<",!0],[">",!0]]),FQ=new Map([[46,De.DOT],[91,De.BRACKET_LEFT],[93,De.BRACKET_RIGHT],[40,De.PAREN_LEFT],[41,De.PAREN_RIGHT],[44,De.COMMA],[63,De.QUESTION],[58,De.COLON],[36,De.DOLLAR]]),U5=new Map;for(const[e,t]of FQ.entries())U5.set(e,{type:t,value:String.fromCharCode(e)});function Xo(e){return e>=48&&e<=57}function _f(e){return e>=97&&e<=122||e>=65&&e<=90||e===95}function K5(e){return _f(e)||Xo(e)}function BQ(e){return HQ.has(e)}var St;(function(e){e[e.Program=0]="Program",e[e.Literal=1]="Literal",e[e.Identifier=2]="Identifier",e[e.MemberExpression=3]="MemberExpression",e[e.CallExpression=4]="CallExpression",e[e.BinaryExpression=5]="BinaryExpression",e[e.UnaryExpression=6]="UnaryExpression",e[e.ConditionalExpression=7]="ConditionalExpression"})(St||(St={}));const WQ=new Map([["||",2],["&&",3],["===",4],["!==",4],[">",5],[">=",5],["<",5],["<=",5],["+",6],["-",6],["*",7],["/",7],["%",7],["!",8]]),VQ={type:St.Literal,value:null},GQ={type:St.Literal,value:!0},YQ={type:St.Literal,value:!1},XQ=e=>{let t=0;const n=e.length,r=()=>t>=n?null:e[t],i=()=>e[t++],o=h=>{const f=r();return f!==null&&f.type===h},s=h=>h.type===De.OPERATOR?WQ.get(h.value)||-1:h.type===De.DOT||h.type===De.BRACKET_LEFT?9:h.type===De.QUESTION?1:-1,a=h=>{let f,d;if(i().type===De.DOT){if(!o(De.IDENTIFIER)){const g=r();throw new Tt("Expected property name",t,g?g.value:"<end of input>")}const p=i();f={type:St.Identifier,name:p.value},d=!1}else{if(f=c(0),!o(De.BRACKET_RIGHT)){const p=r();throw new Tt("Expected closing bracket",t,p?p.value:"<end of input>")}i(),d=!0}return{type:St.MemberExpression,object:h,property:f,computed:d}},l=()=>{const h=r();if(!h)throw new Tt("Unexpected end of input",t,"<end of input>");if(h.type===De.OPERATOR&&(h.value==="!"||h.value==="-")){i();const f=l();return{type:St.UnaryExpression,operator:h.value,argument:f,prefix:!0}}switch(h.type){case De.NUMBER:return i(),{type:St.Literal,value:Number(h.value)};case De.STRING:return i(),{type:St.Literal,value:h.value};case De.BOOLEAN:return i(),h.value==="true"?GQ:YQ;case De.NULL:return i(),VQ;case De.IDENTIFIER:return i(),{type:St.Identifier,name:h.value};case De.FUNCTION:return(()=>{const f=i(),d=[];if(!o(De.PAREN_LEFT)){const p=r();throw new Tt("Expected opening parenthesis after function name",t,p?p.value:"<end of input>")}for(i();;){if(o(De.PAREN_RIGHT)){i();break}if(!r()){const g=r();throw new Tt("Expected closing parenthesis",t,g?g.value:"<end of input>")}if(d.length>0){if(!o(De.COMMA)){const g=r();throw new Tt("Expected comma between function arguments",t,g?g.value:"<end of input>")}i()}const p=c(0);d.push(p)}return{type:St.CallExpression,callee:{type:St.Identifier,name:f.value},arguments:d}})();case De.PAREN_LEFT:{i();const f=c(0);if(!o(De.PAREN_RIGHT)){const d=r();throw new Tt("Expected closing parenthesis",t,d?d.value:"<end of input>")}return i(),f}default:throw new Tt(`Unexpected token: ${h.type}`,t,h.value)}},c=(h=0)=>{let f=l();for(;t<n;){const d=e[t],p=s(d);if(p<=h)break;if(d.type!==De.QUESTION)if(d.type!==De.OPERATOR){if(d.type!==De.DOT&&d.type!==De.BRACKET_LEFT)break;f=a(f)}else{i();const g=c(p);f={type:St.BinaryExpression,operator:d.value,left:f,right:g}}else{i();const g=c(0);if(!o(De.COLON)){const v=r();throw new Tt("Expected : in conditional expression",t,v?v.value:"<end of input>")}i();const m=c(0);f={type:St.ConditionalExpression,test:f,consequent:g,alternate:m}}}return f},u=c();return{type:St.Program,body:u}},UQ=(e,t,n)=>{let r=t;n&&(r=zt(ht({},t),{context:ht(ht({},t.context),n)}));const i=o=>{switch(o.type){case St.Literal:return(s=>s.value)(o);case St.Identifier:return(s=>{if(!(s.name in r.context))throw new Tt(`Undefined variable: ${s.name}`);return r.context[s.name]})(o);case St.MemberExpression:return(s=>{const a=i(s.object);if(a==null)throw new Tt("Cannot access property of null or undefined");return a[s.computed?i(s.property):s.property.name]})(o);case St.CallExpression:return(s=>{const a=r.functions[s.callee.name];if(!a)throw new Tt(`Undefined function: ${s.callee.name}`);return a(...s.arguments.map((l=>i(l))))})(o);case St.BinaryExpression:return(s=>{if(s.operator==="&&"){const c=i(s.left);return c&&i(s.right)}if(s.operator==="||")return i(s.left)||i(s.right);const a=i(s.left),l=i(s.right);switch(s.operator){case"+":return a+l;case"-":return a-l;case"*":return a*l;case"/":return a/l;case"%":return a%l;case"===":return a===l;case"!==":return a!==l;case">":return a>l;case">=":return a>=l;case"<":return a<l;case"<=":return a<=l;default:throw new Tt(`Unknown operator: ${s.operator}`)}})(o);case St.UnaryExpression:return(s=>{const a=i(s.argument);if(s.prefix)switch(s.operator){case"!":return!a;case"-":if(typeof a!="number")throw new Tt(`Cannot apply unary - to non-number: ${a}`);return-a;default:throw new Tt(`Unknown operator: ${s.operator}`)}throw new Tt(`Postfix operators are not supported: ${s.operator}`)})(o);case St.ConditionalExpression:return(s=>{const a=i(s.test);return i(a?s.consequent:s.alternate)})(o);default:throw new Tt(`Evaluation error: Unsupported node type: ${o.type}`)}};return i(e.body)};function Z5(e){const t=(i=>{const o=i,s=o.length,a=new Array(Math.ceil(s/3));let l=0,c=0;function u(m){const v=c+1;c++;let b="",_=!1;for(;c<s;){const x=o.charCodeAt(c);if(x===m)return _||(b=o.substring(v,c)),c++,{type:De.STRING,value:b};x===92?(_||(b=o.substring(v,c),_=!0),c++,b+=o[c]):_&&(b+=o[c]),c++}throw new Tt(`Unterminated string starting with ${String.fromCharCode(m)}`,c,o.substring(Math.max(0,c-10),c))}function h(){const m=c;for(o.charCodeAt(c)===45&&c++;c<s&&Xo(o.charCodeAt(c));)c++;if(c<s&&o.charCodeAt(c)===46)for(c++;c<s&&Xo(o.charCodeAt(c));)c++;const v=o.slice(m,c);return{type:De.NUMBER,value:v}}function f(){c++;const m=c;if(c<s&&_f(o.charCodeAt(c)))for(c++;c<s&&K5(o.charCodeAt(c));)c++;const v=o.slice(m,c);return{type:De.FUNCTION,value:v}}function d(){const m=c++;for(;c<s&&K5(o.charCodeAt(c));)c++;const v=o.slice(m,c),b=jQ.get(v);return b?{type:b,value:v}:{type:De.IDENTIFIER,value:v}}function p(){if(c+2<s){const v=o.substring(c,c+3);if(bf.has(v))return c+=3,{type:De.OPERATOR,value:v}}if(c+1<s){const v=o.substring(c,c+2);if(bf.has(v))return c+=2,{type:De.OPERATOR,value:v}}const m=o[c];if(bf.has(m))return c++,{type:De.OPERATOR,value:m};throw new Tt(`Unknown operator at position ${c}: ${o.substring(c,c+1)}`,c,o.substring(Math.max(0,c-10),c))}for(;c<s;){const m=o.charCodeAt(c);if(g=m,qQ.has(g)){c++;continue}const v=U5.get(m);if(v)a[l++]=v,c++;else if(m!==34&&m!==39)if(Xo(m)||m===45&&c+1<s&&Xo(o.charCodeAt(c+1)))a[l++]=h();else if(m!==64)if(_f(m))a[l++]=d();else{if(!BQ(m))throw new Tt(`Unexpected character: ${o[c]}`,c,o.substring(Math.max(0,c-10),c));a[l++]=p()}else a[l++]=f();else a[l++]=u(m)}var g;return l===a.length?a:a.slice(0,l)})(e),n=XQ(t),r=((i={},o={})=>({context:i,functions:o}))({},DQ);return(i={})=>UQ(n,r,i)}function KQ(e,t={}){return Z5(e)(t)}function ZQ(e,t){if(typeof e!="string")return;const n=e.trim();if(n)try{return Z5(n),KQ(n,t)}catch(r){return}}function Ri(e){return typeof e=="number"}function Q5(e){if(!e)return[0,0,0];if(Ri(e))return[e,e,e];if(Array.isArray(e)&&e.length===0)return[0,0,0];const[t,n=t,r=t]=e;return[t,n,r]}function QQ(e){return Ri(e)?!0:Array.isArray(e)?e.every(t=>Ri(t)):!1}function hn(e){return e==null}function J5(e){return typeof e=="string"}function e6(e){return typeof e=="function"}function wf(e,t){if(typeof e=="function")return e;if(typeof e=="string"){const n=e;return(...r)=>{const i={};for(let o=0;o<t.length;o++)i[t[o]]=r[o];return ZQ(n,i)}}return()=>e}function xf(e,t,n="node"){if(hn(e))return()=>t;if(J5(e)){const r=wf(e,[n]);return i=>{const o=r(i);return Ri(o)?o:t}}return e6(e)?e:Ri(e)?()=>e:()=>t}function t6(e,t=10,n="node"){if(hn(e))return()=>t;if(J5(e)){const r=wf(e,[n]);return i=>{const o=r(i);return QQ(o)?o:t}}return e6(e)?e:Ri(e)?()=>e:Array.isArray(e)?()=>e:()=>t}function JQ(e){var t;return[e.x,e.y,(t=e.z)!==null&&t!==void 0?t:0]}class eJ{constructor(t,n={}){this.edgeIdCounter=new Map,this.nodeMap=rJ(t.nodes,n.node),this.edgeMap=iJ(t.edges||[],n.edge,this.getEdgeId.bind(this))}data(){return{nodes:this.nodeMap,edges:this.edgeMap}}replace(t){this.nodeMap=t.nodes,this.edgeMap=t.edges,this.clearCache()}nodes(){return Array.from(this.nodeMap.values())}node(t){return this.nodeMap.get(t)}nodeAt(t){this.indexNodeCache||this.buildNodeIndexCache();const n=this.indexNodeCache.get(t);return n?this.nodeMap.get(n):void 0}nodeIndexOf(t){var n;return this.nodeIndexCache||this.buildNodeIndexCache(),(n=this.nodeIndexCache.get(t))!==null&&n!==void 0?n:-1}firstNode(){return this.nodeMap.values().next().value}forEachNode(t){let n=0;this.nodeMap.forEach(r=>t(r,n++))}originalNode(t){const n=this.nodeMap.get(t);return n==null?void 0:n._original}nodeCount(){return this.nodeMap.size}edges(){return Array.from(this.edgeMap.values())}edge(t){return this.edgeMap.get(t)}firstEdge(){return this.edgeMap.values().next().value}forEachEdge(t){let n=0;this.edgeMap.forEach(r=>t(r,n++))}originalEdge(t){const n=this.edgeMap.get(t);return n==null?void 0:n._original}edgeCount(){return this.edgeMap.size}getEdgeId(t){if(t.id)return t.id;const n=`${t.source}-${t.target}`,r=this.edgeIdCounter.get(n)||0,i=r===0?n:`${n}-${r}`;return this.edgeIdCounter.set(n,r+1),i}degree(t,n="both"){this.degreeCache||this.buildDegreeCache();const r=this.degreeCache.get(t);return r?r[n]:0}neighbors(t,n="both"){if((!this.outAdjacencyCache||!this.inAdjacencyCache)&&this.buildAdjacencyCache(),n==="out")return Array.from(this.outAdjacencyCache.get(t)||[]);if(n==="in")return Array.from(this.inAdjacencyCache.get(t)||[]);if(this.bothAdjacencyCache)return Array.from(this.bothAdjacencyCache.get(t)||[]);const r=this.inAdjacencyCache.get(t),i=this.outAdjacencyCache.get(t);if(!r&&!i)return[];if(!r)return Array.from(i);if(!i)return Array.from(r);const o=new Set;return r.forEach(s=>o.add(s)),i.forEach(s=>o.add(s)),Array.from(o)}successors(t){return this.neighbors(t,"out")}predecessors(t){return this.neighbors(t,"in")}setNodeOrder(t){const n=new Map;for(const r of t)n.set(r.id,r);this.nodeMap=n,this.nodeIndexCache=void 0,this.indexNodeCache=void 0}clearCache(){this.degreeCache=void 0,this.inAdjacencyCache=void 0,this.outAdjacencyCache=void 0,this.bothAdjacencyCache=void 0,this.nodeIndexCache=void 0,this.indexNodeCache=void 0}buildDegreeCache(){this.degreeCache=new Map;for(const t of this.edges()){const{source:n,target:r}=t;if(t.source===t.target)continue;this.degreeCache.has(n)||this.degreeCache.set(n,{in:0,out:0,both:0});const i=this.degreeCache.get(t.source);i&&(i.out++,i.both++),this.degreeCache.has(r)||this.degreeCache.set(r,{in:0,out:0,both:0});const o=this.degreeCache.get(t.target);o&&(o.in++,o.both++)}}buildAdjacencyCache(){this.inAdjacencyCache=new Map,this.outAdjacencyCache=new Map;for(const t of this.edges())!this.nodeMap.has(t.source)||!this.nodeMap.has(t.target)||(this.outAdjacencyCache.has(t.source)||this.outAdjacencyCache.set(t.source,new Set),this.outAdjacencyCache.get(t.source).add(t.target),this.inAdjacencyCache.has(t.target)||this.inAdjacencyCache.set(t.target,new Set),this.inAdjacencyCache.get(t.target).add(t.source))}buildNodeIndexCache(){this.nodeIndexCache=new Map,this.indexNodeCache=new Map;let t=0;this.nodeMap.forEach((n,r)=>{this.nodeIndexCache.set(r,t),this.indexNodeCache.set(t,r),t++})}destroy(){this.clearCache(),this.nodeMap.clear(),this.edgeMap.clear(),this.edgeIdCounter.clear()}}const tJ=["id","x","y","z","vx","vy","vz","fx","fy","fz","parentId"],nJ=["id","source","target","points"];function rJ(e,t){if(!e)throw new Error("Data.nodes is required");const n=new Map;for(const r of e){const i={_original:r};for(const o of tJ){const s=r[o];hn(s)||(i[o]=s)}if(t){const o=t(r);for(const s in o){const a=o[s];hn(a)||(i[s]=a)}}if(hn(i.id))throw new Error("Node is missing id field");n.set(i.id,i)}return n}function iJ(e,t,n){const r=new Map;for(const i of e){const o={_original:i};for(const s of nJ){const a=i[s];hn(a)||(o[s]=a)}if(t){const s=t(i);for(const a in s){const l=s[a];hn(l)||(o[a]=l)}}if(hn(o.source)||hn(o.target))throw new Error("Edge is missing source or target field");hn(o.id)&&(o.id=n==null?void 0:n(i)),r.set(o.id,o)}return r}class oJ{constructor(t,n={}){this.graph=new eJ(t,n)}export(){return this.graph.data()}replace(t){this.graph.replace(t)}forEachNode(t){this.graph.forEachNode(t)}forEachEdge(t){this.graph.forEachEdge((n,r)=>{n.sourceNode=this.graph.node(n.source),n.targetNode=this.graph.node(n.target),t(n,r)})}destroy(){this.graph.destroy()}}const n6=Symbol("Comlink.proxy"),sJ=Symbol("Comlink.endpoint"),aJ=Symbol("Comlink.releaseProxy"),Cf=Symbol("Comlink.finalizer"),dl=Symbol("Comlink.thrown"),r6=e=>typeof e=="object"&&e!==null||typeof e=="function",lJ={canHandle:e=>r6(e)&&e[n6],serialize(e){const{port1:t,port2:n}=new MessageChannel;return o6(e,t),[n,[n]]},deserialize(e){return e.start(),a6(e)}},cJ={canHandle:e=>r6(e)&&dl in e,serialize({value:e}){let t;return e instanceof Error?t={isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:t={isError:!1,value:e},[t,[]]},deserialize(e){throw e.isError?Object.assign(new Error(e.value.message),e.value):e.value}},i6=new Map([["proxy",lJ],["throw",cJ]]);function uJ(e,t){for(const n of e)if(t===n||n==="*"||n instanceof RegExp&&n.test(t))return!0;return!1}function o6(e,t=globalThis,n=["*"]){t.addEventListener("message",function r(i){if(!i||!i.data)return;if(!uJ(n,i.origin)){console.warn(`Invalid origin '${i.origin}' for comlink proxy`);return}const{id:o,type:s,path:a}=Object.assign({path:[]},i.data),l=(i.data.argumentList||[]).map(Gr);let c;try{const u=a.slice(0,-1).reduce((f,d)=>f[d],e),h=a.reduce((f,d)=>f[d],e);switch(s){case"GET":c=h;break;case"SET":u[a.slice(-1)[0]]=Gr(i.data.value),c=!0;break;case"APPLY":c=h.apply(u,l);break;case"CONSTRUCT":{const f=new h(...l);c=mJ(f)}break;case"ENDPOINT":{const{port1:f,port2:d}=new MessageChannel;o6(e,d),c=gJ(f,[f])}break;case"RELEASE":c=void 0;break;default:return}}catch(u){c={value:u,[dl]:0}}Promise.resolve(c).catch(u=>({value:u,[dl]:0})).then(u=>{const[h,f]=yl(u);t.postMessage(Object.assign(Object.assign({},h),{id:o}),f),s==="RELEASE"&&(t.removeEventListener("message",r),s6(t),Cf in e&&typeof e[Cf]=="function"&&e[Cf]())}).catch(u=>{const[h,f]=yl({value:new TypeError("Unserializable return value"),[dl]:0});t.postMessage(Object.assign(Object.assign({},h),{id:o}),f)})}),t.start&&t.start()}function hJ(e){return e.constructor.name==="MessagePort"}function s6(e){hJ(e)&&e.close()}function a6(e,t){const n=new Map;return e.addEventListener("message",function(i){const{data:o}=i;if(!o||!o.id)return;const s=n.get(o.id);if(s)try{s(o)}finally{n.delete(o.id)}}),Pf(e,n,[],t)}function pl(e){if(e)throw new Error("Proxy has been released and is not useable")}function l6(e){return ki(e,new Map,{type:"RELEASE"}).then(()=>{s6(e)})}const gl=new WeakMap,ml="FinalizationRegistry"in globalThis&&new FinalizationRegistry(e=>{const t=(gl.get(e)||0)-1;gl.set(e,t),t===0&&l6(e)});function fJ(e,t){const n=(gl.get(t)||0)+1;gl.set(t,n),ml&&ml.register(e,t,e)}function dJ(e){ml&&ml.unregister(e)}function Pf(e,t,n=[],r=function(){}){let i=!1;const o=new Proxy(r,{get(s,a){if(pl(i),a===aJ)return()=>{dJ(o),l6(e),t.clear(),i=!0};if(a==="then"){if(n.length===0)return{then:()=>o};const l=ki(e,t,{type:"GET",path:n.map(c=>c.toString())}).then(Gr);return l.then.bind(l)}return Pf(e,t,[...n,a])},set(s,a,l){pl(i);const[c,u]=yl(l);return ki(e,t,{type:"SET",path:[...n,a].map(h=>h.toString()),value:c},u).then(Gr)},apply(s,a,l){pl(i);const c=n[n.length-1];if(c===sJ)return ki(e,t,{type:"ENDPOINT"}).then(Gr);if(c==="bind")return Pf(e,t,n.slice(0,-1));const[u,h]=c6(l);return ki(e,t,{type:"APPLY",path:n.map(f=>f.toString()),argumentList:u},h).then(Gr)},construct(s,a){pl(i);const[l,c]=c6(a);return ki(e,t,{type:"CONSTRUCT",path:n.map(u=>u.toString()),argumentList:l},c).then(Gr)}});return fJ(o,e),o}function pJ(e){return Array.prototype.concat.apply([],e)}function c6(e){const t=e.map(yl);return[t.map(n=>n[0]),pJ(t.map(n=>n[1]))]}const u6=new WeakMap;function gJ(e,t){return u6.set(e,t),e}function mJ(e){return Object.assign(e,{[n6]:!0})}function yl(e){for(const[t,n]of i6)if(n.canHandle(e)){const[r,i]=n.serialize(e);return[{type:"HANDLER",name:t,value:r},i]}return[{type:"RAW",value:e},u6.get(e)||[]]}function Gr(e){switch(e.type){case"HANDLER":return i6.get(e.name).deserialize(e.value);case"RAW":return e.value}}function ki(e,t,n,r){return new Promise(i=>{const o=yJ();t.set(o,i),e.start&&e.start(),e.postMessage(Object.assign({id:o},n),r)})}function yJ(){return new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-")}class vJ{constructor(){this.worker=null,this.workerApi=null}execute(t,n,r){return Yo(this,void 0,void 0,function*(){if(this.worker||(yield this.initWorker()),!this.workerApi)throw new Error("Worker API not initialized");return yield this.workerApi.execute(t,n,r)})}destroy(){this.workerApi&&this.workerApi.destroy(),this.worker&&(this.worker.terminate(),this.worker=null,this.workerApi=null)}initWorker(){return Yo(this,void 0,void 0,function*(){const t=this.resolveWorkerPath(),r=t.includes("/lib/")||t.endsWith(".mjs")?"module":"classic";this.worker=new Worker(t,{type:r}),this.workerApi=a6(this.worker)})}resolveWorkerPath(){if(typeof{url:typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:it&&it.tagName.toUpperCase()==="SCRIPT"&&it.src||new URL("infographic.min.js",document.baseURI).href}!="undefined"&&(typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:it&&it.tagName.toUpperCase()==="SCRIPT"&&it.src||new URL("infographic.min.js",document.baseURI).href)){const t=new URL(typeof document=="undefined"&&typeof location=="undefined"?require("url").pathToFileURL(__filename).href:typeof document=="undefined"?location.href:it&&it.tagName.toUpperCase()==="SCRIPT"&&it.src||new URL("infographic.min.js",document.baseURI).href),n=t.href.replace(/\/runtime\/[^/]+\.js$/,"/worker.js");return n!==t.href?n:t.href.replace(/\/[^/]+\.js$/,"/worker.js")}if(typeof document!="undefined"){const t=document.getElementsByTagName("script");for(let n=t.length-1;n>=0;n--){const r=t[n].src;if(r&&(r.includes("index.js")||r.includes("index.min.js")))return r.replace(/index(\.min)?\.js/,"worker.js")}}return"./worker.js"}}class bJ{constructor(t){this.supervisor=null,this.initialOptions=this.mergeOptions(this.getDefaultOptions(),t)}get options(){return this.runtimeOptions||this.initialOptions}mergeOptions(t,n){return Object.assign({},t,n||{})}execute(t,n){return Yo(this,void 0,void 0,function*(){this.runtimeOptions=this.mergeOptions(this.initialOptions,n);const{node:r,edge:i,enableWorker:o}=this.runtimeOptions;this.context=new oJ(t,{node:r,edge:i}),this.model=this.context.graph,o&&typeof Worker!="undefined"?yield this.layoutInWorker(t,this.runtimeOptions):yield this.layout(this.runtimeOptions)})}layoutInWorker(t,n){var r;return Yo(this,void 0,void 0,function*(){try{this.supervisor||(this.supervisor=new vJ);const i=yield this.supervisor.execute(this.id,t,n);(r=this.context)===null||r===void 0||r.replace(i)}catch(i){console.error("Layout in worker failed, fallback to main thread layout.",i),yield this.layout(n)}})}forEachNode(t){this.context.forEachNode(t)}forEachEdge(t){this.context.forEachEdge(t)}destroy(){var t;(t=this.context)===null||t===void 0||t.destroy(),this.model=null,this.context=null,this.supervisor&&(this.supervisor.destroy(),this.supervisor=null)}}function _J(e){return Array.isArray(e)}var wJ=(function(e){var t=typeof e;return e!==null&&t==="object"||t==="function"}),xJ=function(e){return typeof e=="object"&&e!==null},CJ={}.toString,h6=function(e,t){return CJ.call(e)==="[object "+t+"]"},PJ=function(e){if(!xJ(e)||!h6(e,"Object"))return!1;if(Object.getPrototypeOf(e)===null)return!0;for(var t=e;Object.getPrototypeOf(t)!==null;)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t},vl=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function OJ(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Of(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var Sf,f6;function SJ(){if(f6)return Sf;f6=1;function e(){this.__data__=[],this.size=0}return Sf=e,Sf}var $f,d6;function Li(){if(d6)return $f;d6=1;function e(t,n){return t===n||t!==t&&n!==n}return $f=e,$f}var Ef,p6;function bl(){if(p6)return Ef;p6=1;var e=Li();function t(n,r){for(var i=n.length;i--;)if(e(n[i][0],r))return i;return-1}return Ef=t,Ef}var Mf,g6;function $J(){if(g6)return Mf;g6=1;var e=bl(),t=Array.prototype,n=t.splice;function r(i){var o=this.__data__,s=e(o,i);if(s<0)return!1;var a=o.length-1;return s==a?o.pop():n.call(o,s,1),--this.size,!0}return Mf=r,Mf}var If,m6;function EJ(){if(m6)return If;m6=1;var e=bl();function t(n){var r=this.__data__,i=e(r,n);return i<0?void 0:r[i][1]}return If=t,If}var Af,y6;function MJ(){if(y6)return Af;y6=1;var e=bl();function t(n){return e(this.__data__,n)>-1}return Af=t,Af}var Tf,v6;function IJ(){if(v6)return Tf;v6=1;var e=bl();function t(n,r){var i=this.__data__,o=e(i,n);return o<0?(++this.size,i.push([n,r])):i[o][1]=r,this}return Tf=t,Tf}var Rf,b6;function _l(){if(b6)return Rf;b6=1;var e=SJ(),t=$J(),n=EJ(),r=MJ(),i=IJ();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var c=s[a];this.set(c[0],c[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,Rf=o,Rf}var kf,_6;function AJ(){if(_6)return kf;_6=1;var e=_l();function t(){this.__data__=new e,this.size=0}return kf=t,kf}var Lf,w6;function TJ(){if(w6)return Lf;w6=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return Lf=e,Lf}var Nf,x6;function RJ(){if(x6)return Nf;x6=1;function e(t){return this.__data__.get(t)}return Nf=e,Nf}var zf,C6;function kJ(){if(C6)return zf;C6=1;function e(t){return this.__data__.has(t)}return zf=e,zf}var Df,P6;function O6(){if(P6)return Df;P6=1;var e=typeof vl=="object"&&vl&&vl.Object===Object&&vl;return Df=e,Df}var qf,S6;function wn(){if(S6)return qf;S6=1;var e=O6(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return qf=n,qf}var Hf,$6;function Ni(){if($6)return Hf;$6=1;var e=wn(),t=e.Symbol;return Hf=t,Hf}var jf,E6;function LJ(){if(E6)return jf;E6=1;var e=Ni(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,i=e?e.toStringTag:void 0;function o(s){var a=n.call(s,i),l=s[i];try{s[i]=void 0;var c=!0}catch(h){}var u=r.call(s);return c&&(a?s[i]=l:delete s[i]),u}return jf=o,jf}var Ff,M6;function NJ(){if(M6)return Ff;M6=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return Ff=n,Ff}var Bf,I6;function Yr(){if(I6)return Bf;I6=1;var e=Ni(),t=LJ(),n=NJ(),r="[object Null]",i="[object Undefined]",o=e?e.toStringTag:void 0;function s(a){return a==null?a===void 0?i:r:o&&o in Object(a)?t(a):n(a)}return Bf=s,Bf}var Wf,A6;function fn(){if(A6)return Wf;A6=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return Wf=e,Wf}var Vf,T6;function Uo(){if(T6)return Vf;T6=1;var e=Yr(),t=fn(),n="[object AsyncFunction]",r="[object Function]",i="[object GeneratorFunction]",o="[object Proxy]";function s(a){if(!t(a))return!1;var l=e(a);return l==r||l==i||l==n||l==o}return Vf=s,Vf}var Gf,R6;function zJ(){if(R6)return Gf;R6=1;var e=wn(),t=e["__core-js_shared__"];return Gf=t,Gf}var Yf,k6;function DJ(){if(k6)return Yf;k6=1;var e=zJ(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return Yf=n,Yf}var Xf,L6;function N6(){if(L6)return Xf;L6=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch(i){}try{return r+""}catch(i){}}return""}return Xf=n,Xf}var Uf,z6;function qJ(){if(z6)return Uf;z6=1;var e=Uo(),t=DJ(),n=fn(),r=N6(),i=/[\\^$.*+?()[\]{}|]/g,o=/^\[object .+?Constructor\]$/,s=Function.prototype,a=Object.prototype,l=s.toString,c=a.hasOwnProperty,u=RegExp("^"+l.call(c).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function h(f){if(!n(f)||t(f))return!1;var d=e(f)?u:o;return d.test(r(f))}return Uf=h,Uf}var Kf,D6;function HJ(){if(D6)return Kf;D6=1;function e(t,n){return t==null?void 0:t[n]}return Kf=e,Kf}var Zf,q6;function Xr(){if(q6)return Zf;q6=1;var e=qJ(),t=HJ();function n(r,i){var o=t(r,i);return e(o)?o:void 0}return Zf=n,Zf}var Qf,H6;function Jf(){if(H6)return Qf;H6=1;var e=Xr(),t=wn(),n=e(t,"Map");return Qf=n,Qf}var ed,j6;function wl(){if(j6)return ed;j6=1;var e=Xr(),t=e(Object,"create");return ed=t,ed}var td,F6;function jJ(){if(F6)return td;F6=1;var e=wl();function t(){this.__data__=e?e(null):{},this.size=0}return td=t,td}var nd,B6;function FJ(){if(B6)return nd;B6=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return nd=e,nd}var rd,W6;function BJ(){if(W6)return rd;W6=1;var e=wl(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function i(o){var s=this.__data__;if(e){var a=s[o];return a===t?void 0:a}return r.call(s,o)?s[o]:void 0}return rd=i,rd}var id,V6;function WJ(){if(V6)return id;V6=1;var e=wl(),t=Object.prototype,n=t.hasOwnProperty;function r(i){var o=this.__data__;return e?o[i]!==void 0:n.call(o,i)}return id=r,id}var od,G6;function VJ(){if(G6)return od;G6=1;var e=wl(),t="__lodash_hash_undefined__";function n(r,i){var o=this.__data__;return this.size+=this.has(r)?0:1,o[r]=e&&i===void 0?t:i,this}return od=n,od}var sd,Y6;function GJ(){if(Y6)return sd;Y6=1;var e=jJ(),t=FJ(),n=BJ(),r=WJ(),i=VJ();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var c=s[a];this.set(c[0],c[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,sd=o,sd}var ad,X6;function YJ(){if(X6)return ad;X6=1;var e=GJ(),t=_l(),n=Jf();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return ad=r,ad}var ld,U6;function XJ(){if(U6)return ld;U6=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return ld=e,ld}var cd,K6;function xl(){if(K6)return cd;K6=1;var e=XJ();function t(n,r){var i=n.__data__;return e(r)?i[typeof r=="string"?"string":"hash"]:i.map}return cd=t,cd}var ud,Z6;function UJ(){if(Z6)return ud;Z6=1;var e=xl();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return ud=t,ud}var hd,Q6;function KJ(){if(Q6)return hd;Q6=1;var e=xl();function t(n){return e(this,n).get(n)}return hd=t,hd}var fd,J6;function ZJ(){if(J6)return fd;J6=1;var e=xl();function t(n){return e(this,n).has(n)}return fd=t,fd}var dd,e7;function QJ(){if(e7)return dd;e7=1;var e=xl();function t(n,r){var i=e(this,n),o=i.size;return i.set(n,r),this.size+=i.size==o?0:1,this}return dd=t,dd}var pd,t7;function gd(){if(t7)return pd;t7=1;var e=YJ(),t=UJ(),n=KJ(),r=ZJ(),i=QJ();function o(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var c=s[a];this.set(c[0],c[1])}}return o.prototype.clear=e,o.prototype.delete=t,o.prototype.get=n,o.prototype.has=r,o.prototype.set=i,pd=o,pd}var md,n7;function JJ(){if(n7)return md;n7=1;var e=_l(),t=Jf(),n=gd(),r=200;function i(o,s){var a=this.__data__;if(a instanceof e){var l=a.__data__;if(!t||l.length<r-1)return l.push([o,s]),this.size=++a.size,this;a=this.__data__=new n(l)}return a.set(o,s),this.size=a.size,this}return md=i,md}var yd,r7;function Cl(){if(r7)return yd;r7=1;var e=_l(),t=AJ(),n=TJ(),r=RJ(),i=kJ(),o=JJ();function s(a){var l=this.__data__=new e(a);this.size=l.size}return s.prototype.clear=t,s.prototype.delete=n,s.prototype.get=r,s.prototype.has=i,s.prototype.set=o,yd=s,yd}var vd,i7;function bd(){if(i7)return vd;i7=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i&&n(t[r],r,t)!==!1;);return t}return vd=e,vd}var _d,o7;function s7(){if(o7)return _d;o7=1;var e=Xr(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch(r){}})();return _d=t,_d}var wd,a7;function Pl(){if(a7)return wd;a7=1;var e=s7();function t(n,r,i){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:i,writable:!0}):n[r]=i}return wd=t,wd}var xd,l7;function Ol(){if(l7)return xd;l7=1;var e=Pl(),t=Li(),n=Object.prototype,r=n.hasOwnProperty;function i(o,s,a){var l=o[s];(!(r.call(o,s)&&t(l,a))||a===void 0&&!(s in o))&&e(o,s,a)}return xd=i,xd}var Cd,c7;function Ko(){if(c7)return Cd;c7=1;var e=Ol(),t=Pl();function n(r,i,o,s){var a=!o;o||(o={});for(var l=-1,c=i.length;++l<c;){var u=i[l],h=s?s(o[u],r[u],u,o,r):void 0;h===void 0&&(h=r[u]),a?t(o,u,h):e(o,u,h)}return o}return Cd=n,Cd}var Pd,u7;function eee(){if(u7)return Pd;u7=1;function e(t,n){for(var r=-1,i=Array(t);++r<t;)i[r]=n(r);return i}return Pd=e,Pd}var Od,h7;function Ln(){if(h7)return Od;h7=1;function e(t){return t!=null&&typeof t=="object"}return Od=e,Od}var Sd,f7;function tee(){if(f7)return Sd;f7=1;var e=Yr(),t=Ln(),n="[object Arguments]";function r(i){return t(i)&&e(i)==n}return Sd=r,Sd}var $d,d7;function Zo(){if(d7)return $d;d7=1;var e=tee(),t=Ln(),n=Object.prototype,r=n.hasOwnProperty,i=n.propertyIsEnumerable,o=e((function(){return arguments})())?e:function(s){return t(s)&&r.call(s,"callee")&&!i.call(s,"callee")};return $d=o,$d}var Ed,p7;function Rt(){if(p7)return Ed;p7=1;var e=Array.isArray;return Ed=e,Ed}var Qo={exports:{}},Md,g7;function nee(){if(g7)return Md;g7=1;function e(){return!1}return Md=e,Md}Qo.exports;var m7;function zi(){return m7||(m7=1,(function(e,t){var n=wn(),r=nee(),i=t&&!t.nodeType&&t,o=i&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s?n.Buffer:void 0,l=a?a.isBuffer:void 0,c=l||r;e.exports=c})(Qo,Qo.exports)),Qo.exports}var Id,y7;function Sl(){if(y7)return Id;y7=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,i){var o=typeof r;return i=i==null?e:i,!!i&&(o=="number"||o!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<i}return Id=n,Id}var Ad,v7;function Td(){if(v7)return Ad;v7=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return Ad=t,Ad}var Rd,b7;function ree(){if(b7)return Rd;b7=1;var e=Yr(),t=Td(),n=Ln(),r="[object Arguments]",i="[object Array]",o="[object Boolean]",s="[object Date]",a="[object Error]",l="[object Function]",c="[object Map]",u="[object Number]",h="[object Object]",f="[object RegExp]",d="[object Set]",p="[object String]",g="[object WeakMap]",m="[object ArrayBuffer]",v="[object DataView]",b="[object Float32Array]",_="[object Float64Array]",x="[object Int8Array]",w="[object Int16Array]",C="[object Int32Array]",P="[object Uint8Array]",O="[object Uint8ClampedArray]",$="[object Uint16Array]",S="[object Uint32Array]",M={};M[b]=M[_]=M[x]=M[w]=M[C]=M[P]=M[O]=M[$]=M[S]=!0,M[r]=M[i]=M[m]=M[o]=M[v]=M[s]=M[a]=M[l]=M[c]=M[u]=M[h]=M[f]=M[d]=M[p]=M[g]=!1;function I(E){return n(E)&&t(E.length)&&!!M[e(E)]}return Rd=I,Rd}var kd,_7;function $l(){if(_7)return kd;_7=1;function e(t){return function(n){return t(n)}}return kd=e,kd}var Jo={exports:{}};Jo.exports;var w7;function Ld(){return w7||(w7=1,(function(e,t){var n=O6(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o&&n.process,a=(function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch(c){}})();e.exports=a})(Jo,Jo.exports)),Jo.exports}var Nd,x7;function es(){if(x7)return Nd;x7=1;var e=ree(),t=$l(),n=Ld(),r=n&&n.isTypedArray,i=r?t(r):e;return Nd=i,Nd}var zd,C7;function P7(){if(C7)return zd;C7=1;var e=eee(),t=Zo(),n=Rt(),r=zi(),i=Sl(),o=es(),s=Object.prototype,a=s.hasOwnProperty;function l(c,u){var h=n(c),f=!h&&t(c),d=!h&&!f&&r(c),p=!h&&!f&&!d&&o(c),g=h||f||d||p,m=g?e(c.length,String):[],v=m.length;for(var b in c)(u||a.call(c,b))&&!(g&&(b=="length"||d&&(b=="offset"||b=="parent")||p&&(b=="buffer"||b=="byteLength"||b=="byteOffset")||i(b,v)))&&m.push(b);return m}return zd=l,zd}var Dd,O7;function El(){if(O7)return Dd;O7=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,i=typeof r=="function"&&r.prototype||e;return n===i}return Dd=t,Dd}var qd,S7;function $7(){if(S7)return qd;S7=1;function e(t,n){return function(r){return t(n(r))}}return qd=e,qd}var Hd,E7;function iee(){if(E7)return Hd;E7=1;var e=$7(),t=e(Object.keys,Object);return Hd=t,Hd}var jd,M7;function Fd(){if(M7)return jd;M7=1;var e=El(),t=iee(),n=Object.prototype,r=n.hasOwnProperty;function i(o){if(!e(o))return t(o);var s=[];for(var a in Object(o))r.call(o,a)&&a!="constructor"&&s.push(a);return s}return jd=i,jd}var Bd,I7;function Un(){if(I7)return Bd;I7=1;var e=Uo(),t=Td();function n(r){return r!=null&&t(r.length)&&!e(r)}return Bd=n,Bd}var Wd,A7;function mr(){if(A7)return Wd;A7=1;var e=P7(),t=Fd(),n=Un();function r(i){return n(i)?e(i):t(i)}return Wd=r,Wd}var Vd,T7;function oee(){if(T7)return Vd;T7=1;var e=Ko(),t=mr();function n(r,i){return r&&e(i,t(i),r)}return Vd=n,Vd}var Gd,R7;function see(){if(R7)return Gd;R7=1;function e(t){var n=[];if(t!=null)for(var r in Object(t))n.push(r);return n}return Gd=e,Gd}var Yd,k7;function aee(){if(k7)return Yd;k7=1;var e=fn(),t=El(),n=see(),r=Object.prototype,i=r.hasOwnProperty;function o(s){if(!e(s))return n(s);var a=t(s),l=[];for(var c in s)c=="constructor"&&(a||!i.call(s,c))||l.push(c);return l}return Yd=o,Yd}var Xd,L7;function Ur(){if(L7)return Xd;L7=1;var e=P7(),t=aee(),n=Un();function r(i){return n(i)?e(i,!0):t(i)}return Xd=r,Xd}var Ud,N7;function lee(){if(N7)return Ud;N7=1;var e=Ko(),t=Ur();function n(r,i){return r&&e(i,t(i),r)}return Ud=n,Ud}var ts={exports:{}};ts.exports;var z7;function D7(){return z7||(z7=1,(function(e,t){var n=wn(),r=t&&!t.nodeType&&t,i=r&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===r,s=o?n.Buffer:void 0,a=s?s.allocUnsafe:void 0;function l(c,u){if(u)return c.slice();var h=c.length,f=a?a(h):new c.constructor(h);return c.copy(f),f}e.exports=l})(ts,ts.exports)),ts.exports}var Kd,q7;function H7(){if(q7)return Kd;q7=1;function e(t,n){var r=-1,i=t.length;for(n||(n=Array(i));++r<i;)n[r]=t[r];return n}return Kd=e,Kd}var Zd,j7;function F7(){if(j7)return Zd;j7=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=0,s=[];++r<i;){var a=t[r];n(a,r,t)&&(s[o++]=a)}return s}return Zd=e,Zd}var Qd,B7;function W7(){if(B7)return Qd;B7=1;function e(){return[]}return Qd=e,Qd}var Jd,V7;function ep(){if(V7)return Jd;V7=1;var e=F7(),t=W7(),n=Object.prototype,r=n.propertyIsEnumerable,i=Object.getOwnPropertySymbols,o=i?function(s){return s==null?[]:(s=Object(s),e(i(s),function(a){return r.call(s,a)}))}:t;return Jd=o,Jd}var tp,G7;function cee(){if(G7)return tp;G7=1;var e=Ko(),t=ep();function n(r,i){return e(r,t(r),i)}return tp=n,tp}var np,Y7;function rp(){if(Y7)return np;Y7=1;function e(t,n){for(var r=-1,i=n.length,o=t.length;++r<i;)t[o+r]=n[r];return t}return np=e,np}var ip,X7;function Ml(){if(X7)return ip;X7=1;var e=$7(),t=e(Object.getPrototypeOf,Object);return ip=t,ip}var op,U7;function K7(){if(U7)return op;U7=1;var e=rp(),t=Ml(),n=ep(),r=W7(),i=Object.getOwnPropertySymbols,o=i?function(s){for(var a=[];s;)e(a,n(s)),s=t(s);return a}:r;return op=o,op}var sp,Z7;function uee(){if(Z7)return sp;Z7=1;var e=Ko(),t=K7();function n(r,i){return e(r,t(r),i)}return sp=n,sp}var ap,Q7;function J7(){if(Q7)return ap;Q7=1;var e=rp(),t=Rt();function n(r,i,o){var s=i(r);return t(r)?s:e(s,o(r))}return ap=n,ap}var lp,e9;function t9(){if(e9)return lp;e9=1;var e=J7(),t=ep(),n=mr();function r(i){return e(i,n,t)}return lp=r,lp}var cp,n9;function hee(){if(n9)return cp;n9=1;var e=J7(),t=K7(),n=Ur();function r(i){return e(i,n,t)}return cp=r,cp}var up,r9;function fee(){if(r9)return up;r9=1;var e=Xr(),t=wn(),n=e(t,"DataView");return up=n,up}var hp,i9;function dee(){if(i9)return hp;i9=1;var e=Xr(),t=wn(),n=e(t,"Promise");return hp=n,hp}var fp,o9;function s9(){if(o9)return fp;o9=1;var e=Xr(),t=wn(),n=e(t,"Set");return fp=n,fp}var dp,a9;function pee(){if(a9)return dp;a9=1;var e=Xr(),t=wn(),n=e(t,"WeakMap");return dp=n,dp}var pp,l9;function Di(){if(l9)return pp;l9=1;var e=fee(),t=Jf(),n=dee(),r=s9(),i=pee(),o=Yr(),s=N6(),a="[object Map]",l="[object Object]",c="[object Promise]",u="[object Set]",h="[object WeakMap]",f="[object DataView]",d=s(e),p=s(t),g=s(n),m=s(r),v=s(i),b=o;return(e&&b(new e(new ArrayBuffer(1)))!=f||t&&b(new t)!=a||n&&b(n.resolve())!=c||r&&b(new r)!=u||i&&b(new i)!=h)&&(b=function(_){var x=o(_),w=x==l?_.constructor:void 0,C=w?s(w):"";if(C)switch(C){case d:return f;case p:return a;case g:return c;case m:return u;case v:return h}return x}),pp=b,pp}var gp,c9;function gee(){if(c9)return gp;c9=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r){var i=r.length,o=new r.constructor(i);return i&&typeof r[0]=="string"&&t.call(r,"index")&&(o.index=r.index,o.input=r.input),o}return gp=n,gp}var mp,u9;function h9(){if(u9)return mp;u9=1;var e=wn(),t=e.Uint8Array;return mp=t,mp}var yp,f9;function vp(){if(f9)return yp;f9=1;var e=h9();function t(n){var r=new n.constructor(n.byteLength);return new e(r).set(new e(n)),r}return yp=t,yp}var bp,d9;function mee(){if(d9)return bp;d9=1;var e=vp();function t(n,r){var i=r?e(n.buffer):n.buffer;return new n.constructor(i,n.byteOffset,n.byteLength)}return bp=t,bp}var _p,p9;function yee(){if(p9)return _p;p9=1;var e=/\w*$/;function t(n){var r=new n.constructor(n.source,e.exec(n));return r.lastIndex=n.lastIndex,r}return _p=t,_p}var wp,g9;function vee(){if(g9)return wp;g9=1;var e=Ni(),t=e?e.prototype:void 0,n=t?t.valueOf:void 0;function r(i){return n?Object(n.call(i)):{}}return wp=r,wp}var xp,m9;function y9(){if(m9)return xp;m9=1;var e=vp();function t(n,r){var i=r?e(n.buffer):n.buffer;return new n.constructor(i,n.byteOffset,n.length)}return xp=t,xp}var Cp,v9;function bee(){if(v9)return Cp;v9=1;var e=vp(),t=mee(),n=yee(),r=vee(),i=y9(),o="[object Boolean]",s="[object Date]",a="[object Map]",l="[object Number]",c="[object RegExp]",u="[object Set]",h="[object String]",f="[object Symbol]",d="[object ArrayBuffer]",p="[object DataView]",g="[object Float32Array]",m="[object Float64Array]",v="[object Int8Array]",b="[object Int16Array]",_="[object Int32Array]",x="[object Uint8Array]",w="[object Uint8ClampedArray]",C="[object Uint16Array]",P="[object Uint32Array]";function O($,S,M){var I=$.constructor;switch(S){case d:return e($);case o:case s:return new I(+$);case p:return t($,M);case g:case m:case v:case b:case _:case x:case w:case C:case P:return i($,M);case a:return new I;case l:case h:return new I($);case c:return n($);case u:return new I;case f:return r($)}}return Cp=O,Cp}var Pp,b9;function _9(){if(b9)return Pp;b9=1;var e=fn(),t=Object.create,n=(function(){function r(){}return function(i){if(!e(i))return{};if(t)return t(i);r.prototype=i;var o=new r;return r.prototype=void 0,o}})();return Pp=n,Pp}var Op,w9;function x9(){if(w9)return Op;w9=1;var e=_9(),t=Ml(),n=El();function r(i){return typeof i.constructor=="function"&&!n(i)?e(t(i)):{}}return Op=r,Op}var Sp,C9;function _ee(){if(C9)return Sp;C9=1;var e=Di(),t=Ln(),n="[object Map]";function r(i){return t(i)&&e(i)==n}return Sp=r,Sp}var $p,P9;function wee(){if(P9)return $p;P9=1;var e=_ee(),t=$l(),n=Ld(),r=n&&n.isMap,i=r?t(r):e;return $p=i,$p}var Ep,O9;function xee(){if(O9)return Ep;O9=1;var e=Di(),t=Ln(),n="[object Set]";function r(i){return t(i)&&e(i)==n}return Ep=r,Ep}var Mp,S9;function Cee(){if(S9)return Mp;S9=1;var e=xee(),t=$l(),n=Ld(),r=n&&n.isSet,i=r?t(r):e;return Mp=i,Mp}var Ip,$9;function E9(){if($9)return Ip;$9=1;var e=Cl(),t=bd(),n=Ol(),r=oee(),i=lee(),o=D7(),s=H7(),a=cee(),l=uee(),c=t9(),u=hee(),h=Di(),f=gee(),d=bee(),p=x9(),g=Rt(),m=zi(),v=wee(),b=fn(),_=Cee(),x=mr(),w=Ur(),C=1,P=2,O=4,$="[object Arguments]",S="[object Array]",M="[object Boolean]",I="[object Date]",E="[object Error]",A="[object Function]",T="[object GeneratorFunction]",N="[object Map]",H="[object Number]",D="[object Object]",B="[object RegExp]",F="[object Set]",X="[object String]",G="[object Symbol]",L="[object WeakMap]",R="[object ArrayBuffer]",z="[object DataView]",q="[object Float32Array]",j="[object Float64Array]",V="[object Int8Array]",U="[object Int16Array]",K="[object Int32Array]",ne="[object Uint8Array]",J="[object Uint8ClampedArray]",se="[object Uint16Array]",Z="[object Uint32Array]",te={};te[$]=te[S]=te[R]=te[z]=te[M]=te[I]=te[q]=te[j]=te[V]=te[U]=te[K]=te[N]=te[H]=te[D]=te[B]=te[F]=te[X]=te[G]=te[ne]=te[J]=te[se]=te[Z]=!0,te[E]=te[A]=te[L]=!1;function ue(re,ee,oe,ie,le,pe){var he,ge=ee&C,fe=ee&P,xe=ee&O;if(oe&&(he=le?oe(re,ie,le,pe):oe(re)),he!==void 0)return he;if(!b(re))return re;var $e=g(re);if($e){if(he=f(re),!ge)return s(re,he)}else{var Ie=h(re),Pe=Ie==A||Ie==T;if(m(re))return o(re,ge);if(Ie==D||Ie==$||Pe&&!le){if(he=fe||Pe?{}:p(re),!ge)return fe?l(re,i(he,re)):a(re,r(he,re))}else{if(!te[Ie])return le?re:{};he=d(re,Ie,ge)}}pe||(pe=new e);var Le=pe.get(re);if(Le)return Le;pe.set(re,he),_(re)?re.forEach(function(ye){he.add(ue(ye,ee,oe,ye,re,pe))}):v(re)&&re.forEach(function(ye,we){he.set(we,ue(ye,ee,oe,we,re,pe))});var je=xe?fe?u:c:fe?w:x,Fe=$e?void 0:je(re);return t(Fe||re,function(ye,we){Fe&&(we=ye,ye=re[we]),n(he,we,ue(ye,ee,oe,we,re,pe))}),he}return Ip=ue,Ip}var Ap,M9;function Pee(){if(M9)return Ap;M9=1;var e=E9(),t=4;function n(r){return e(r,t)}return Ap=n,Ap}var Tp,I9;function Rp(){if(I9)return Tp;I9=1;function e(t){return function(){return t}}return Tp=e,Tp}var kp,A9;function Oee(){if(A9)return kp;A9=1;function e(t){return function(n,r,i){for(var o=-1,s=Object(n),a=i(n),l=a.length;l--;){var c=a[t?l:++o];if(r(s[c],c,s)===!1)break}return n}}return kp=e,kp}var Lp,T9;function Np(){if(T9)return Lp;T9=1;var e=Oee(),t=e();return Lp=t,Lp}var zp,R9;function Dp(){if(R9)return zp;R9=1;var e=Np(),t=mr();function n(r,i){return r&&e(r,i,t)}return zp=n,zp}var qp,k9;function See(){if(k9)return qp;k9=1;var e=Un();function t(n,r){return function(i,o){if(i==null)return i;if(!e(i))return n(i,o);for(var s=i.length,a=r?s:-1,l=Object(i);(r?a--:++a<s)&&o(l[a],a,l)!==!1;);return i}}return qp=t,qp}var Hp,L9;function Il(){if(L9)return Hp;L9=1;var e=Dp(),t=See(),n=t(e);return Hp=n,Hp}var jp,N9;function Kr(){if(N9)return jp;N9=1;function e(t){return t}return jp=e,jp}var Fp,z9;function D9(){if(z9)return Fp;z9=1;var e=Kr();function t(n){return typeof n=="function"?n:e}return Fp=t,Fp}var Bp,q9;function H9(){if(q9)return Bp;q9=1;var e=bd(),t=Il(),n=D9(),r=Rt();function i(o,s){var a=r(o)?e:t;return a(o,n(s))}return Bp=i,Bp}var Wp,j9;function F9(){return j9||(j9=1,Wp=H9()),Wp}var Vp,B9;function $ee(){if(B9)return Vp;B9=1;var e=Il();function t(n,r){var i=[];return e(n,function(o,s,a){r(o,s,a)&&i.push(o)}),i}return Vp=t,Vp}var Gp,W9;function Eee(){if(W9)return Gp;W9=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Gp=t,Gp}var Yp,V9;function Mee(){if(V9)return Yp;V9=1;function e(t){return this.__data__.has(t)}return Yp=e,Yp}var Xp,G9;function Y9(){if(G9)return Xp;G9=1;var e=gd(),t=Eee(),n=Mee();function r(i){var o=-1,s=i==null?0:i.length;for(this.__data__=new e;++o<s;)this.add(i[o])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Xp=r,Xp}var Up,X9;function Iee(){if(X9)return Up;X9=1;function e(t,n){for(var r=-1,i=t==null?0:t.length;++r<i;)if(n(t[r],r,t))return!0;return!1}return Up=e,Up}var Kp,U9;function K9(){if(U9)return Kp;U9=1;function e(t,n){return t.has(n)}return Kp=e,Kp}var Zp,Z9;function Q9(){if(Z9)return Zp;Z9=1;var e=Y9(),t=Iee(),n=K9(),r=1,i=2;function o(s,a,l,c,u,h){var f=l&r,d=s.length,p=a.length;if(d!=p&&!(f&&p>d))return!1;var g=h.get(s),m=h.get(a);if(g&&m)return g==a&&m==s;var v=-1,b=!0,_=l&i?new e:void 0;for(h.set(s,a),h.set(a,s);++v<d;){var x=s[v],w=a[v];if(c)var C=f?c(w,x,v,a,s,h):c(x,w,v,s,a,h);if(C!==void 0){if(C)continue;b=!1;break}if(_){if(!t(a,function(P,O){if(!n(_,O)&&(x===P||u(x,P,l,c,h)))return _.push(O)})){b=!1;break}}else if(!(x===w||u(x,w,l,c,h))){b=!1;break}}return h.delete(s),h.delete(a),b}return Zp=o,Zp}var Qp,J9;function Aee(){if(J9)return Qp;J9=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i,o){r[++n]=[o,i]}),r}return Qp=e,Qp}var Jp,e8;function e0(){if(e8)return Jp;e8=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(i){r[++n]=i}),r}return Jp=e,Jp}var t0,t8;function Tee(){if(t8)return t0;t8=1;var e=Ni(),t=h9(),n=Li(),r=Q9(),i=Aee(),o=e0(),s=1,a=2,l="[object Boolean]",c="[object Date]",u="[object Error]",h="[object Map]",f="[object Number]",d="[object RegExp]",p="[object Set]",g="[object String]",m="[object Symbol]",v="[object ArrayBuffer]",b="[object DataView]",_=e?e.prototype:void 0,x=_?_.valueOf:void 0;function w(C,P,O,$,S,M,I){switch(O){case b:if(C.byteLength!=P.byteLength||C.byteOffset!=P.byteOffset)return!1;C=C.buffer,P=P.buffer;case v:return!(C.byteLength!=P.byteLength||!M(new t(C),new t(P)));case l:case c:case f:return n(+C,+P);case u:return C.name==P.name&&C.message==P.message;case d:case g:return C==P+"";case h:var E=i;case p:var A=$&s;if(E||(E=o),C.size!=P.size&&!A)return!1;var T=I.get(C);if(T)return T==P;$|=a,I.set(C,P);var N=r(E(C),E(P),$,S,M,I);return I.delete(C),N;case m:if(x)return x.call(C)==x.call(P)}return!1}return t0=w,t0}var n0,n8;function Ree(){if(n8)return n0;n8=1;var e=t9(),t=1,n=Object.prototype,r=n.hasOwnProperty;function i(o,s,a,l,c,u){var h=a&t,f=e(o),d=f.length,p=e(s),g=p.length;if(d!=g&&!h)return!1;for(var m=d;m--;){var v=f[m];if(!(h?v in s:r.call(s,v)))return!1}var b=u.get(o),_=u.get(s);if(b&&_)return b==s&&_==o;var x=!0;u.set(o,s),u.set(s,o);for(var w=h;++m<d;){v=f[m];var C=o[v],P=s[v];if(l)var O=h?l(P,C,v,s,o,u):l(C,P,v,o,s,u);if(!(O===void 0?C===P||c(C,P,a,l,u):O)){x=!1;break}w||(w=v=="constructor")}if(x&&!w){var $=o.constructor,S=s.constructor;$!=S&&"constructor"in o&&"constructor"in s&&!(typeof $=="function"&&$ instanceof $&&typeof S=="function"&&S instanceof S)&&(x=!1)}return u.delete(o),u.delete(s),x}return n0=i,n0}var r0,r8;function kee(){if(r8)return r0;r8=1;var e=Cl(),t=Q9(),n=Tee(),r=Ree(),i=Di(),o=Rt(),s=zi(),a=es(),l=1,c="[object Arguments]",u="[object Array]",h="[object Object]",f=Object.prototype,d=f.hasOwnProperty;function p(g,m,v,b,_,x){var w=o(g),C=o(m),P=w?u:i(g),O=C?u:i(m);P=P==c?h:P,O=O==c?h:O;var $=P==h,S=O==h,M=P==O;if(M&&s(g)){if(!s(m))return!1;w=!0,$=!1}if(M&&!$)return x||(x=new e),w||a(g)?t(g,m,v,b,_,x):n(g,m,P,v,b,_,x);if(!(v&l)){var I=$&&d.call(g,"__wrapped__"),E=S&&d.call(m,"__wrapped__");if(I||E){var A=I?g.value():g,T=E?m.value():m;return x||(x=new e),_(A,T,v,b,x)}}return M?(x||(x=new e),r(g,m,v,b,_,x)):!1}return r0=p,r0}var i0,i8;function o8(){if(i8)return i0;i8=1;var e=kee(),t=Ln();function n(r,i,o,s,a){return r===i?!0:r==null||i==null||!t(r)&&!t(i)?r!==r&&i!==i:e(r,i,o,s,n,a)}return i0=n,i0}var o0,s8;function Lee(){if(s8)return o0;s8=1;var e=Cl(),t=o8(),n=1,r=2;function i(o,s,a,l){var c=a.length,u=c,h=!l;if(o==null)return!u;for(o=Object(o);c--;){var f=a[c];if(h&&f[2]?f[1]!==o[f[0]]:!(f[0]in o))return!1}for(;++c<u;){f=a[c];var d=f[0],p=o[d],g=f[1];if(h&&f[2]){if(p===void 0&&!(d in o))return!1}else{var m=new e;if(l)var v=l(p,g,d,o,s,m);if(!(v===void 0?t(g,p,n|r,l,m):v))return!1}}return!0}return o0=i,o0}var s0,a8;function l8(){if(a8)return s0;a8=1;var e=fn();function t(n){return n===n&&!e(n)}return s0=t,s0}var a0,c8;function Nee(){if(c8)return a0;c8=1;var e=l8(),t=mr();function n(r){for(var i=t(r),o=i.length;o--;){var s=i[o],a=r[s];i[o]=[s,a,e(a)]}return i}return a0=n,a0}var l0,u8;function h8(){if(u8)return l0;u8=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return l0=e,l0}var c0,f8;function zee(){if(f8)return c0;f8=1;var e=Lee(),t=Nee(),n=h8();function r(i){var o=t(i);return o.length==1&&o[0][2]?n(o[0][0],o[0][1]):function(s){return s===i||e(s,i,o)}}return c0=r,c0}var u0,d8;function qi(){if(d8)return u0;d8=1;var e=Yr(),t=Ln(),n="[object Symbol]";function r(i){return typeof i=="symbol"||t(i)&&e(i)==n}return u0=r,u0}var h0,p8;function f0(){if(p8)return h0;p8=1;var e=Rt(),t=qi(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function i(o,s){if(e(o))return!1;var a=typeof o;return a=="number"||a=="symbol"||a=="boolean"||o==null||t(o)?!0:r.test(o)||!n.test(o)||s!=null&&o in Object(s)}return h0=i,h0}var d0,g8;function Dee(){if(g8)return d0;g8=1;var e=gd(),t="Expected a function";function n(r,i){if(typeof r!="function"||i!=null&&typeof i!="function")throw new TypeError(t);var o=function(){var s=arguments,a=i?i.apply(this,s):s[0],l=o.cache;if(l.has(a))return l.get(a);var c=r.apply(this,s);return o.cache=l.set(a,c)||l,c};return o.cache=new(n.Cache||e),o}return n.Cache=e,d0=n,d0}var p0,m8;function qee(){if(m8)return p0;m8=1;var e=Dee(),t=500;function n(r){var i=e(r,function(s){return o.size===t&&o.clear(),s}),o=i.cache;return i}return p0=n,p0}var g0,y8;function Hee(){if(y8)return g0;y8=1;var e=qee(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(i){var o=[];return i.charCodeAt(0)===46&&o.push(""),i.replace(t,function(s,a,l,c){o.push(l?c.replace(n,"$1"):a||s)}),o});return g0=r,g0}var m0,v8;function Al(){if(v8)return m0;v8=1;function e(t,n){for(var r=-1,i=t==null?0:t.length,o=Array(i);++r<i;)o[r]=n(t[r],r,t);return o}return m0=e,m0}var y0,b8;function jee(){if(b8)return y0;b8=1;var e=Ni(),t=Al(),n=Rt(),r=qi(),i=e?e.prototype:void 0,o=i?i.toString:void 0;function s(a){if(typeof a=="string")return a;if(n(a))return t(a,s)+"";if(r(a))return o?o.call(a):"";var l=a+"";return l=="0"&&1/a==-1/0?"-0":l}return y0=s,y0}var v0,_8;function w8(){if(_8)return v0;_8=1;var e=jee();function t(n){return n==null?"":e(n)}return v0=t,v0}var b0,x8;function Tl(){if(x8)return b0;x8=1;var e=Rt(),t=f0(),n=Hee(),r=w8();function i(o,s){return e(o)?o:t(o,s)?[o]:n(r(o))}return b0=i,b0}var _0,C8;function ns(){if(C8)return _0;C8=1;var e=qi();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return _0=t,_0}var w0,P8;function Rl(){if(P8)return w0;P8=1;var e=Tl(),t=ns();function n(r,i){i=e(i,r);for(var o=0,s=i.length;r!=null&&o<s;)r=r[t(i[o++])];return o&&o==s?r:void 0}return w0=n,w0}var x0,O8;function Fee(){if(O8)return x0;O8=1;var e=Rl();function t(n,r,i){var o=n==null?void 0:e(n,r);return o===void 0?i:o}return x0=t,x0}var C0,S8;function Bee(){if(S8)return C0;S8=1;function e(t,n){return t!=null&&n in Object(t)}return C0=e,C0}var P0,$8;function E8(){if($8)return P0;$8=1;var e=Tl(),t=Zo(),n=Rt(),r=Sl(),i=Td(),o=ns();function s(a,l,c){l=e(l,a);for(var u=-1,h=l.length,f=!1;++u<h;){var d=o(l[u]);if(!(f=a!=null&&c(a,d)))break;a=a[d]}return f||++u!=h?f:(h=a==null?0:a.length,!!h&&i(h)&&r(d,h)&&(n(a)||t(a)))}return P0=s,P0}var O0,M8;function I8(){if(M8)return O0;M8=1;var e=Bee(),t=E8();function n(r,i){return r!=null&&t(r,i,e)}return O0=n,O0}var S0,A8;function Wee(){if(A8)return S0;A8=1;var e=o8(),t=Fee(),n=I8(),r=f0(),i=l8(),o=h8(),s=ns(),a=1,l=2;function c(u,h){return r(u)&&i(h)?o(s(u),h):function(f){var d=t(f,u);return d===void 0&&d===h?n(f,u):e(h,d,a|l)}}return S0=c,S0}var $0,T8;function R8(){if(T8)return $0;T8=1;function e(t){return function(n){return n==null?void 0:n[t]}}return $0=e,$0}var E0,k8;function Vee(){if(k8)return E0;k8=1;var e=Rl();function t(n){return function(r){return e(r,n)}}return E0=t,E0}var M0,L8;function Gee(){if(L8)return M0;L8=1;var e=R8(),t=Vee(),n=f0(),r=ns();function i(o){return n(o)?e(r(o)):t(o)}return M0=i,M0}var I0,N8;function Kn(){if(N8)return I0;N8=1;var e=zee(),t=Wee(),n=Kr(),r=Rt(),i=Gee();function o(s){return typeof s=="function"?s:s==null?n:typeof s=="object"?r(s)?t(s[0],s[1]):e(s):i(s)}return I0=o,I0}var A0,z8;function D8(){if(z8)return A0;z8=1;var e=F7(),t=$ee(),n=Kn(),r=Rt();function i(o,s){var a=r(o)?e:t;return a(o,n(s,3))}return A0=i,A0}var T0,q8;function Yee(){if(q8)return T0;q8=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r,i){return r!=null&&t.call(r,i)}return T0=n,T0}var R0,H8;function j8(){if(H8)return R0;H8=1;var e=Yee(),t=E8();function n(r,i){return r!=null&&t(r,i,e)}return R0=n,R0}var k0,F8;function Xee(){if(F8)return k0;F8=1;var e=Fd(),t=Di(),n=Zo(),r=Rt(),i=Un(),o=zi(),s=El(),a=es(),l="[object Map]",c="[object Set]",u=Object.prototype,h=u.hasOwnProperty;function f(d){if(d==null)return!0;if(i(d)&&(r(d)||typeof d=="string"||typeof d.splice=="function"||o(d)||a(d)||n(d)))return!d.length;var p=t(d);if(p==l||p==c)return!d.size;if(s(d))return!e(d).length;for(var g in d)if(h.call(d,g))return!1;return!0}return k0=f,k0}var L0,B8;function W8(){if(B8)return L0;B8=1;function e(t){return t===void 0}return L0=e,L0}var N0,V8;function G8(){if(V8)return N0;V8=1;var e=Il(),t=Un();function n(r,i){var o=-1,s=t(r)?Array(r.length):[];return e(r,function(a,l,c){s[++o]=i(a,l,c)}),s}return N0=n,N0}var z0,Y8;function X8(){if(Y8)return z0;Y8=1;var e=Al(),t=Kn(),n=G8(),r=Rt();function i(o,s){var a=r(o)?e:n;return a(o,t(s,3))}return z0=i,z0}var D0,U8;function Uee(){if(U8)return D0;U8=1;function e(t,n,r,i){var o=-1,s=t==null?0:t.length;for(i&&s&&(r=t[++o]);++o<s;)r=n(r,t[o],o,t);return r}return D0=e,D0}var q0,K8;function Kee(){if(K8)return q0;K8=1;function e(t,n,r,i,o){return o(t,function(s,a,l){r=i?(i=!1,s):n(r,s,a,l)}),r}return q0=e,q0}var H0,Z8;function Q8(){if(Z8)return H0;Z8=1;var e=Uee(),t=Il(),n=Kn(),r=Kee(),i=Rt();function o(s,a,l){var c=i(s)?e:r,u=arguments.length<3;return c(s,n(a,4),l,u,t)}return H0=o,H0}var j0,J8;function Zee(){if(J8)return j0;J8=1;var e=Yr(),t=Rt(),n=Ln(),r="[object String]";function i(o){return typeof o=="string"||!t(o)&&n(o)&&e(o)==r}return j0=i,j0}var F0,eC;function Qee(){if(eC)return F0;eC=1;var e=R8(),t=e("length");return F0=t,F0}var B0,tC;function Jee(){if(tC)return B0;tC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="\\u200d",a=RegExp("["+s+e+i+o+"]");function l(c){return a.test(c)}return B0=l,B0}var W0,nC;function ete(){if(nC)return W0;nC=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",i=t+n+r,o="\\ufe0e\\ufe0f",s="["+e+"]",a="["+i+"]",l="\\ud83c[\\udffb-\\udfff]",c="(?:"+a+"|"+l+")",u="[^"+e+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",d="\\u200d",p=c+"?",g="["+o+"]?",m="(?:"+d+"(?:"+[u,h,f].join("|")+")"+g+p+")*",v=g+p+m,b="(?:"+[u+a+"?",a,h,f,s].join("|")+")",_=RegExp(l+"(?="+l+")|"+b+v,"g");function x(w){for(var C=_.lastIndex=0;_.test(w);)++C;return C}return W0=x,W0}var V0,rC;function tte(){if(rC)return V0;rC=1;var e=Qee(),t=Jee(),n=ete();function r(i){return t(i)?n(i):e(i)}return V0=r,V0}var G0,iC;function nte(){if(iC)return G0;iC=1;var e=Fd(),t=Di(),n=Un(),r=Zee(),i=tte(),o="[object Map]",s="[object Set]";function a(l){if(l==null)return 0;if(n(l))return r(l)?i(l):l.length;var c=t(l);return c==o||c==s?l.size:e(l).length}return G0=a,G0}var Y0,oC;function rte(){if(oC)return Y0;oC=1;var e=bd(),t=_9(),n=Dp(),r=Kn(),i=Ml(),o=Rt(),s=zi(),a=Uo(),l=fn(),c=es();function u(h,f,d){var p=o(h),g=p||s(h)||c(h);if(f=r(f,4),d==null){var m=h&&h.constructor;g?d=p?new m:[]:l(h)?d=a(m)?t(i(h)):{}:d={}}return(g?e:n)(h,function(v,b,_){return f(d,v,b,_)}),d}return Y0=u,Y0}var X0,sC;function ite(){if(sC)return X0;sC=1;var e=Ni(),t=Zo(),n=Rt(),r=e?e.isConcatSpreadable:void 0;function i(o){return n(o)||t(o)||!!(r&&o&&o[r])}return X0=i,X0}var U0,aC;function K0(){if(aC)return U0;aC=1;var e=rp(),t=ite();function n(r,i,o,s,a){var l=-1,c=r.length;for(o||(o=t),a||(a=[]);++l<c;){var u=r[l];i>0&&o(u)?i>1?n(u,i-1,o,s,a):e(a,u):s||(a[a.length]=u)}return a}return U0=n,U0}var Z0,lC;function ote(){if(lC)return Z0;lC=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return Z0=e,Z0}var Q0,cC;function uC(){if(cC)return Q0;cC=1;var e=ote(),t=Math.max;function n(r,i,o){return i=t(i===void 0?r.length-1:i,0),function(){for(var s=arguments,a=-1,l=t(s.length-i,0),c=Array(l);++a<l;)c[a]=s[i+a];a=-1;for(var u=Array(i+1);++a<i;)u[a]=s[a];return u[i]=o(c),e(r,this,u)}}return Q0=n,Q0}var J0,hC;function ste(){if(hC)return J0;hC=1;var e=Rp(),t=s7(),n=Kr(),r=t?function(i,o){return t(i,"toString",{configurable:!0,enumerable:!1,value:e(o),writable:!0})}:n;return J0=r,J0}var eg,fC;function ate(){if(fC)return eg;fC=1;var e=800,t=16,n=Date.now;function r(i){var o=0,s=0;return function(){var a=n(),l=t-(a-s);if(s=a,l>0){if(++o>=e)return arguments[0]}else o=0;return i.apply(void 0,arguments)}}return eg=r,eg}var tg,dC;function pC(){if(dC)return tg;dC=1;var e=ste(),t=ate(),n=t(e);return tg=n,tg}var ng,gC;function kl(){if(gC)return ng;gC=1;var e=Kr(),t=uC(),n=pC();function r(i,o){return n(t(i,o,e),i+"")}return ng=r,ng}var rg,mC;function yC(){if(mC)return rg;mC=1;function e(t,n,r,i){for(var o=t.length,s=r+(i?1:-1);i?s--:++s<o;)if(n(t[s],s,t))return s;return-1}return rg=e,rg}var ig,vC;function lte(){if(vC)return ig;vC=1;function e(t){return t!==t}return ig=e,ig}var og,bC;function cte(){if(bC)return og;bC=1;function e(t,n,r){for(var i=r-1,o=t.length;++i<o;)if(t[i]===n)return i;return-1}return og=e,og}var sg,_C;function ute(){if(_C)return sg;_C=1;var e=yC(),t=lte(),n=cte();function r(i,o,s){return o===o?n(i,o,s):e(i,t,s)}return sg=r,sg}var ag,wC;function hte(){if(wC)return ag;wC=1;var e=ute();function t(n,r){var i=n==null?0:n.length;return!!i&&e(n,r,0)>-1}return ag=t,ag}var lg,xC;function fte(){if(xC)return lg;xC=1;function e(t,n,r){for(var i=-1,o=t==null?0:t.length;++i<o;)if(r(n,t[i]))return!0;return!1}return lg=e,lg}var cg,CC;function dte(){if(CC)return cg;CC=1;function e(){}return cg=e,cg}var ug,PC;function pte(){if(PC)return ug;PC=1;var e=s9(),t=dte(),n=e0(),r=1/0,i=e&&1/n(new e([,-0]))[1]==r?function(o){return new e(o)}:t;return ug=i,ug}var hg,OC;function gte(){if(OC)return hg;OC=1;var e=Y9(),t=hte(),n=fte(),r=K9(),i=pte(),o=e0(),s=200;function a(l,c,u){var h=-1,f=t,d=l.length,p=!0,g=[],m=g;if(u)p=!1,f=n;else if(d>=s){var v=c?null:i(l);if(v)return o(v);p=!1,f=r,m=new e}else m=c?[]:g;e:for(;++h<d;){var b=l[h],_=c?c(b):b;if(b=u||b!==0?b:0,p&&_===_){for(var x=m.length;x--;)if(m[x]===_)continue e;c&&m.push(_),g.push(b)}else f(m,_,u)||(m!==g&&m.push(_),g.push(b))}return g}return hg=a,hg}var fg,SC;function $C(){if(SC)return fg;SC=1;var e=Un(),t=Ln();function n(r){return t(r)&&e(r)}return fg=n,fg}var dg,EC;function mte(){if(EC)return dg;EC=1;var e=K0(),t=kl(),n=gte(),r=$C(),i=t(function(o){return n(e(o,1,r,!0))});return dg=i,dg}var pg,MC;function yte(){if(MC)return pg;MC=1;var e=Al();function t(n,r){return e(r,function(i){return n[i]})}return pg=t,pg}var gg,IC;function AC(){if(IC)return gg;IC=1;var e=yte(),t=mr();function n(r){return r==null?[]:e(r,t(r))}return gg=n,gg}var mg,TC;function dn(){if(TC)return mg;TC=1;var e;if(typeof Of=="function")try{e={clone:Pee(),constant:Rp(),each:F9(),filter:D8(),has:j8(),isArray:Rt(),isEmpty:Xee(),isFunction:Uo(),isUndefined:W8(),keys:mr(),map:X8(),reduce:Q8(),size:nte(),transform:rte(),union:mte(),values:AC()}}catch(t){}return e||(e=window._),mg=e,mg}var yg,RC;function vg(){if(RC)return yg;RC=1;var e=dn();yg=i;var t="\0",n="\0",r="";function i(u){this._isDirected=e.has(u,"directed")?u.directed:!0,this._isMultigraph=e.has(u,"multigraph")?u.multigraph:!1,this._isCompound=e.has(u,"compound")?u.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[n]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}i.prototype._nodeCount=0,i.prototype._edgeCount=0,i.prototype.isDirected=function(){return this._isDirected},i.prototype.isMultigraph=function(){return this._isMultigraph},i.prototype.isCompound=function(){return this._isCompound},i.prototype.setGraph=function(u){return this._label=u,this},i.prototype.graph=function(){return this._label},i.prototype.setDefaultNodeLabel=function(u){return e.isFunction(u)||(u=e.constant(u)),this._defaultNodeLabelFn=u,this},i.prototype.nodeCount=function(){return this._nodeCount},i.prototype.nodes=function(){return e.keys(this._nodes)},i.prototype.sources=function(){var u=this;return e.filter(this.nodes(),function(h){return e.isEmpty(u._in[h])})},i.prototype.sinks=function(){var u=this;return e.filter(this.nodes(),function(h){return e.isEmpty(u._out[h])})},i.prototype.setNodes=function(u,h){var f=arguments,d=this;return e.each(u,function(p){f.length>1?d.setNode(p,h):d.setNode(p)}),this},i.prototype.setNode=function(u,h){return e.has(this._nodes,u)?(arguments.length>1&&(this._nodes[u]=h),this):(this._nodes[u]=arguments.length>1?h:this._defaultNodeLabelFn(u),this._isCompound&&(this._parent[u]=n,this._children[u]={},this._children[n][u]=!0),this._in[u]={},this._preds[u]={},this._out[u]={},this._sucs[u]={},++this._nodeCount,this)},i.prototype.node=function(u){return this._nodes[u]},i.prototype.hasNode=function(u){return e.has(this._nodes,u)},i.prototype.removeNode=function(u){var h=this;if(e.has(this._nodes,u)){var f=function(d){h.removeEdge(h._edgeObjs[d])};delete this._nodes[u],this._isCompound&&(this._removeFromParentsChildList(u),delete this._parent[u],e.each(this.children(u),function(d){h.setParent(d)}),delete this._children[u]),e.each(e.keys(this._in[u]),f),delete this._in[u],delete this._preds[u],e.each(e.keys(this._out[u]),f),delete this._out[u],delete this._sucs[u],--this._nodeCount}return this},i.prototype.setParent=function(u,h){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(h))h=n;else{h+="";for(var f=h;!e.isUndefined(f);f=this.parent(f))if(f===u)throw new Error("Setting "+h+" as parent of "+u+" would create a cycle");this.setNode(h)}return this.setNode(u),this._removeFromParentsChildList(u),this._parent[u]=h,this._children[h][u]=!0,this},i.prototype._removeFromParentsChildList=function(u){delete this._children[this._parent[u]][u]},i.prototype.parent=function(u){if(this._isCompound){var h=this._parent[u];if(h!==n)return h}},i.prototype.children=function(u){if(e.isUndefined(u)&&(u=n),this._isCompound){var h=this._children[u];if(h)return e.keys(h)}else{if(u===n)return this.nodes();if(this.hasNode(u))return[]}},i.prototype.predecessors=function(u){var h=this._preds[u];if(h)return e.keys(h)},i.prototype.successors=function(u){var h=this._sucs[u];if(h)return e.keys(h)},i.prototype.neighbors=function(u){var h=this.predecessors(u);if(h)return e.union(h,this.successors(u))},i.prototype.isLeaf=function(u){var h;return this.isDirected()?h=this.successors(u):h=this.neighbors(u),h.length===0},i.prototype.filterNodes=function(u){var h=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});h.setGraph(this.graph());var f=this;e.each(this._nodes,function(g,m){u(m)&&h.setNode(m,g)}),e.each(this._edgeObjs,function(g){h.hasNode(g.v)&&h.hasNode(g.w)&&h.setEdge(g,f.edge(g))});var d={};function p(g){var m=f.parent(g);return m===void 0||h.hasNode(m)?(d[g]=m,m):m in d?d[m]:p(m)}return this._isCompound&&e.each(h.nodes(),function(g){h.setParent(g,p(g))}),h},i.prototype.setDefaultEdgeLabel=function(u){return e.isFunction(u)||(u=e.constant(u)),this._defaultEdgeLabelFn=u,this},i.prototype.edgeCount=function(){return this._edgeCount},i.prototype.edges=function(){return e.values(this._edgeObjs)},i.prototype.setPath=function(u,h){var f=this,d=arguments;return e.reduce(u,function(p,g){return d.length>1?f.setEdge(p,g,h):f.setEdge(p,g),g}),this},i.prototype.setEdge=function(){var u,h,f,d,p=!1,g=arguments[0];typeof g=="object"&&g!==null&&"v"in g?(u=g.v,h=g.w,f=g.name,arguments.length===2&&(d=arguments[1],p=!0)):(u=g,h=arguments[1],f=arguments[3],arguments.length>2&&(d=arguments[2],p=!0)),u=""+u,h=""+h,e.isUndefined(f)||(f=""+f);var m=a(this._isDirected,u,h,f);if(e.has(this._edgeLabels,m))return p&&(this._edgeLabels[m]=d),this;if(!e.isUndefined(f)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(u),this.setNode(h),this._edgeLabels[m]=p?d:this._defaultEdgeLabelFn(u,h,f);var v=l(this._isDirected,u,h,f);return u=v.v,h=v.w,Object.freeze(v),this._edgeObjs[m]=v,o(this._preds[h],u),o(this._sucs[u],h),this._in[h][m]=v,this._out[u][m]=v,this._edgeCount++,this},i.prototype.edge=function(u,h,f){var d=arguments.length===1?c(this._isDirected,arguments[0]):a(this._isDirected,u,h,f);return this._edgeLabels[d]},i.prototype.hasEdge=function(u,h,f){var d=arguments.length===1?c(this._isDirected,arguments[0]):a(this._isDirected,u,h,f);return e.has(this._edgeLabels,d)},i.prototype.removeEdge=function(u,h,f){var d=arguments.length===1?c(this._isDirected,arguments[0]):a(this._isDirected,u,h,f),p=this._edgeObjs[d];return p&&(u=p.v,h=p.w,delete this._edgeLabels[d],delete this._edgeObjs[d],s(this._preds[h],u),s(this._sucs[u],h),delete this._in[h][d],delete this._out[u][d],this._edgeCount--),this},i.prototype.inEdges=function(u,h){var f=this._in[u];if(f){var d=e.values(f);return h?e.filter(d,function(p){return p.v===h}):d}},i.prototype.outEdges=function(u,h){var f=this._out[u];if(f){var d=e.values(f);return h?e.filter(d,function(p){return p.w===h}):d}},i.prototype.nodeEdges=function(u,h){var f=this.inEdges(u,h);if(f)return f.concat(this.outEdges(u,h))};function o(u,h){u[h]?u[h]++:u[h]=1}function s(u,h){--u[h]||delete u[h]}function a(u,h,f,d){var p=""+h,g=""+f;if(!u&&p>g){var m=p;p=g,g=m}return p+r+g+r+(e.isUndefined(d)?t:d)}function l(u,h,f,d){var p=""+h,g=""+f;if(!u&&p>g){var m=p;p=g,g=m}var v={v:p,w:g};return d&&(v.name=d),v}function c(u,h){return a(u,h.v,h.w,h.name)}return yg}var bg,kC;function vte(){return kC||(kC=1,bg="2.1.8"),bg}var _g,LC;function bte(){return LC||(LC=1,_g={Graph:vg(),version:vte()}),_g}var wg,NC;function _te(){if(NC)return wg;NC=1;var e=dn(),t=vg();wg={write:n,read:o};function n(s){var a={options:{directed:s.isDirected(),multigraph:s.isMultigraph(),compound:s.isCompound()},nodes:r(s),edges:i(s)};return e.isUndefined(s.graph())||(a.value=e.clone(s.graph())),a}function r(s){return e.map(s.nodes(),function(a){var l=s.node(a),c=s.parent(a),u={v:a};return e.isUndefined(l)||(u.value=l),e.isUndefined(c)||(u.parent=c),u})}function i(s){return e.map(s.edges(),function(a){var l=s.edge(a),c={v:a.v,w:a.w};return e.isUndefined(a.name)||(c.name=a.name),e.isUndefined(l)||(c.value=l),c})}function o(s){var a=new t(s.options).setGraph(s.value);return e.each(s.nodes,function(l){a.setNode(l.v,l.value),l.parent&&a.setParent(l.v,l.parent)}),e.each(s.edges,function(l){a.setEdge({v:l.v,w:l.w,name:l.name},l.value)}),a}return wg}var xg,zC;function wte(){if(zC)return xg;zC=1;var e=dn();xg=t;function t(n){var r={},i=[],o;function s(a){e.has(r,a)||(r[a]=!0,o.push(a),e.each(n.successors(a),s),e.each(n.predecessors(a),s))}return e.each(n.nodes(),function(a){o=[],s(a),o.length&&i.push(o)}),i}return xg}var Cg,DC;function qC(){if(DC)return Cg;DC=1;var e=dn();Cg=t;function t(){this._arr=[],this._keyIndices={}}return t.prototype.size=function(){return this._arr.length},t.prototype.keys=function(){return this._arr.map(function(n){return n.key})},t.prototype.has=function(n){return e.has(this._keyIndices,n)},t.prototype.priority=function(n){var r=this._keyIndices[n];if(r!==void 0)return this._arr[r].priority},t.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},t.prototype.add=function(n,r){var i=this._keyIndices;if(n=String(n),!e.has(i,n)){var o=this._arr,s=o.length;return i[n]=s,o.push({key:n,priority:r}),this._decrease(s),!0}return!1},t.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var n=this._arr.pop();return delete this._keyIndices[n.key],this._heapify(0),n.key},t.prototype.decrease=function(n,r){var i=this._keyIndices[n];if(r>this._arr[i].priority)throw new Error("New priority is greater than current priority. Key: "+n+" Old: "+this._arr[i].priority+" New: "+r);this._arr[i].priority=r,this._decrease(i)},t.prototype._heapify=function(n){var r=this._arr,i=2*n,o=i+1,s=n;i<r.length&&(s=r[i].priority<r[s].priority?i:s,o<r.length&&(s=r[o].priority<r[s].priority?o:s),s!==n&&(this._swap(n,s),this._heapify(s)))},t.prototype._decrease=function(n){for(var r=this._arr,i=r[n].priority,o;n!==0&&(o=n>>1,!(r[o].priority<i));)this._swap(n,o),n=o},t.prototype._swap=function(n,r){var i=this._arr,o=this._keyIndices,s=i[n],a=i[r];i[n]=a,i[r]=s,o[a.key]=n,o[s.key]=r},Cg}var Pg,HC;function jC(){if(HC)return Pg;HC=1;var e=dn(),t=qC();Pg=r;var n=e.constant(1);function r(o,s,a,l){return i(o,String(s),a||n,l||function(c){return o.outEdges(c)})}function i(o,s,a,l){var c={},u=new t,h,f,d=function(p){var g=p.v!==h?p.v:p.w,m=c[g],v=a(p),b=f.distance+v;if(v<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+p+" Weight: "+v);b<m.distance&&(m.distance=b,m.predecessor=h,u.decrease(g,b))};for(o.nodes().forEach(function(p){var g=p===s?0:Number.POSITIVE_INFINITY;c[p]={distance:g},u.add(p,g)});u.size()>0&&(h=u.removeMin(),f=c[h],f.distance!==Number.POSITIVE_INFINITY);)l(h).forEach(d);return c}return Pg}var Og,FC;function xte(){if(FC)return Og;FC=1;var e=jC(),t=dn();Og=n;function n(r,i,o){return t.transform(r.nodes(),function(s,a){s[a]=e(r,a,i,o)},{})}return Og}var Sg,BC;function WC(){if(BC)return Sg;BC=1;var e=dn();Sg=t;function t(n){var r=0,i=[],o={},s=[];function a(l){var c=o[l]={onStack:!0,lowlink:r,index:r++};if(i.push(l),n.successors(l).forEach(function(f){e.has(o,f)?o[f].onStack&&(c.lowlink=Math.min(c.lowlink,o[f].index)):(a(f),c.lowlink=Math.min(c.lowlink,o[f].lowlink))}),c.lowlink===c.index){var u=[],h;do h=i.pop(),o[h].onStack=!1,u.push(h);while(l!==h);s.push(u)}}return n.nodes().forEach(function(l){e.has(o,l)||a(l)}),s}return Sg}var $g,VC;function Cte(){if(VC)return $g;VC=1;var e=dn(),t=WC();$g=n;function n(r){return e.filter(t(r),function(i){return i.length>1||i.length===1&&r.hasEdge(i[0],i[0])})}return $g}var Eg,GC;function Pte(){if(GC)return Eg;GC=1;var e=dn();Eg=n;var t=e.constant(1);function n(i,o,s){return r(i,o||t,s||function(a){return i.outEdges(a)})}function r(i,o,s){var a={},l=i.nodes();return l.forEach(function(c){a[c]={},a[c][c]={distance:0},l.forEach(function(u){c!==u&&(a[c][u]={distance:Number.POSITIVE_INFINITY})}),s(c).forEach(function(u){var h=u.v===c?u.w:u.v,f=o(u);a[c][h]={distance:f,predecessor:c}})}),l.forEach(function(c){var u=a[c];l.forEach(function(h){var f=a[h];l.forEach(function(d){var p=f[c],g=u[d],m=f[d],v=p.distance+g.distance;v<m.distance&&(m.distance=v,m.predecessor=g.predecessor)})})}),a}return Eg}var Mg,YC;function XC(){if(YC)return Mg;YC=1;var e=dn();Mg=t,t.CycleException=n;function t(r){var i={},o={},s=[];function a(l){if(e.has(o,l))throw new n;e.has(i,l)||(o[l]=!0,i[l]=!0,e.each(r.predecessors(l),a),delete o[l],s.push(l))}if(e.each(r.sinks(),a),e.size(i)!==r.nodeCount())throw new n;return s}function n(){}return n.prototype=new Error,Mg}var Ig,UC;function Ote(){if(UC)return Ig;UC=1;var e=XC();Ig=t;function t(n){try{e(n)}catch(r){if(r instanceof e.CycleException)return!1;throw r}return!0}return Ig}var Ag,KC;function ZC(){if(KC)return Ag;KC=1;var e=dn();Ag=t;function t(r,i,o){e.isArray(i)||(i=[i]);var s=(r.isDirected()?r.successors:r.neighbors).bind(r),a=[],l={};return e.each(i,function(c){if(!r.hasNode(c))throw new Error("Graph does not have node: "+c);n(r,c,o==="post",l,s,a)}),a}function n(r,i,o,s,a,l){e.has(s,i)||(s[i]=!0,o||l.push(i),e.each(a(i),function(c){n(r,c,o,s,a,l)}),o&&l.push(i))}return Ag}var Tg,QC;function Ste(){if(QC)return Tg;QC=1;var e=ZC();Tg=t;function t(n,r){return e(n,r,"post")}return Tg}var Rg,JC;function $te(){if(JC)return Rg;JC=1;var e=ZC();Rg=t;function t(n,r){return e(n,r,"pre")}return Rg}var kg,eP;function Ete(){if(eP)return kg;eP=1;var e=dn(),t=vg(),n=qC();kg=r;function r(i,o){var s=new t,a={},l=new n,c;function u(f){var d=f.v===c?f.w:f.v,p=l.priority(d);if(p!==void 0){var g=o(f);g<p&&(a[d]=c,l.decrease(d,g))}}if(i.nodeCount()===0)return s;e.each(i.nodes(),function(f){l.add(f,Number.POSITIVE_INFINITY),s.setNode(f)}),l.decrease(i.nodes()[0],0);for(var h=!1;l.size()>0;){if(c=l.removeMin(),e.has(a,c))s.setEdge(c,a[c]);else{if(h)throw new Error("Input graph is not connected: "+i);h=!0}i.nodeEdges(c).forEach(u)}return s}return kg}var Lg,tP;function Mte(){return tP||(tP=1,Lg={components:wte(),dijkstra:jC(),dijkstraAll:xte(),findCycles:Cte(),floydWarshall:Pte(),isAcyclic:Ote(),postorder:Ste(),preorder:$te(),prim:Ete(),tarjan:WC(),topsort:XC()}),Lg}var Ng,nP;function Ite(){if(nP)return Ng;nP=1;var e=bte();return Ng={Graph:e.Graph,json:_te(),alg:Mte(),version:e.version},Ng}var zg,rP;function xn(){if(rP)return zg;rP=1;var e;if(typeof Of=="function")try{e=Ite()}catch(t){}return e||(e=window.graphlib),zg=e,zg}var Dg,iP;function Ate(){if(iP)return Dg;iP=1;var e=E9(),t=1,n=4;function r(i){return e(i,t|n)}return Dg=r,Dg}var qg,oP;function Ll(){if(oP)return qg;oP=1;var e=Li(),t=Un(),n=Sl(),r=fn();function i(o,s,a){if(!r(a))return!1;var l=typeof s;return(l=="number"?t(a)&&n(s,a.length):l=="string"&&s in a)?e(a[s],o):!1}return qg=i,qg}var Hg,sP;function Tte(){if(sP)return Hg;sP=1;var e=kl(),t=Li(),n=Ll(),r=Ur(),i=Object.prototype,o=i.hasOwnProperty,s=e(function(a,l){a=Object(a);var c=-1,u=l.length,h=u>2?l[2]:void 0;for(h&&n(l[0],l[1],h)&&(u=1);++c<u;)for(var f=l[c],d=r(f),p=-1,g=d.length;++p<g;){var m=d[p],v=a[m];(v===void 0||t(v,i[m])&&!o.call(a,m))&&(a[m]=f[m])}return a});return Hg=s,Hg}var jg,aP;function Rte(){if(aP)return jg;aP=1;var e=Kn(),t=Un(),n=mr();function r(i){return function(o,s,a){var l=Object(o);if(!t(o)){var c=e(s,3);o=n(o),s=function(h){return c(l[h],h,l)}}var u=i(o,s,a);return u>-1?l[c?o[u]:u]:void 0}}return jg=r,jg}var Fg,lP;function kte(){if(lP)return Fg;lP=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return Fg=t,Fg}var Bg,cP;function Lte(){if(cP)return Bg;cP=1;var e=kte(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return Bg=n,Bg}var Wg,uP;function Nte(){if(uP)return Wg;uP=1;var e=Lte(),t=fn(),n=qi(),r=NaN,i=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,s=/^0o[0-7]+$/i,a=parseInt;function l(c){if(typeof c=="number")return c;if(n(c))return r;if(t(c)){var u=typeof c.valueOf=="function"?c.valueOf():c;c=t(u)?u+"":u}if(typeof c!="string")return c===0?c:+c;c=e(c);var h=o.test(c);return h||s.test(c)?a(c.slice(2),h?2:8):i.test(c)?r:+c}return Wg=l,Wg}var Vg,hP;function fP(){if(hP)return Vg;hP=1;var e=Nte(),t=1/0,n=17976931348623157e292;function r(i){if(!i)return i===0?i:0;if(i=e(i),i===t||i===-t){var o=i<0?-1:1;return o*n}return i===i?i:0}return Vg=r,Vg}var Gg,dP;function zte(){if(dP)return Gg;dP=1;var e=fP();function t(n){var r=e(n),i=r%1;return r===r?i?r-i:r:0}return Gg=t,Gg}var Yg,pP;function Dte(){if(pP)return Yg;pP=1;var e=yC(),t=Kn(),n=zte(),r=Math.max;function i(o,s,a){var l=o==null?0:o.length;if(!l)return-1;var c=a==null?0:n(a);return c<0&&(c=r(l+c,0)),e(o,t(s,3),c)}return Yg=i,Yg}var Xg,gP;function qte(){if(gP)return Xg;gP=1;var e=Rte(),t=Dte(),n=e(t);return Xg=n,Xg}var Ug,mP;function yP(){if(mP)return Ug;mP=1;var e=K0();function t(n){var r=n==null?0:n.length;return r?e(n,1):[]}return Ug=t,Ug}var Kg,vP;function Hte(){if(vP)return Kg;vP=1;var e=Np(),t=D9(),n=Ur();function r(i,o){return i==null?i:e(i,t(o),n)}return Kg=r,Kg}var Zg,bP;function jte(){if(bP)return Zg;bP=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return Zg=e,Zg}var Qg,_P;function Fte(){if(_P)return Qg;_P=1;var e=Pl(),t=Dp(),n=Kn();function r(i,o){var s={};return o=n(o,3),t(i,function(a,l,c){e(s,l,o(a,l,c))}),s}return Qg=r,Qg}var Jg,wP;function e1(){if(wP)return Jg;wP=1;var e=qi();function t(n,r,i){for(var o=-1,s=n.length;++o<s;){var a=n[o],l=r(a);if(l!=null&&(c===void 0?l===l&&!e(l):i(l,c)))var c=l,u=a}return u}return Jg=t,Jg}var t1,xP;function Bte(){if(xP)return t1;xP=1;function e(t,n){return t>n}return t1=e,t1}var n1,CP;function Wte(){if(CP)return n1;CP=1;var e=e1(),t=Bte(),n=Kr();function r(i){return i&&i.length?e(i,n,t):void 0}return n1=r,n1}var r1,PP;function OP(){if(PP)return r1;PP=1;var e=Pl(),t=Li();function n(r,i,o){(o!==void 0&&!t(r[i],o)||o===void 0&&!(i in r))&&e(r,i,o)}return r1=n,r1}var i1,SP;function Vte(){if(SP)return i1;SP=1;var e=Yr(),t=Ml(),n=Ln(),r="[object Object]",i=Function.prototype,o=Object.prototype,s=i.toString,a=o.hasOwnProperty,l=s.call(Object);function c(u){if(!n(u)||e(u)!=r)return!1;var h=t(u);if(h===null)return!0;var f=a.call(h,"constructor")&&h.constructor;return typeof f=="function"&&f instanceof f&&s.call(f)==l}return i1=c,i1}var o1,$P;function EP(){if($P)return o1;$P=1;function e(t,n){if(!(n==="constructor"&&typeof t[n]=="function")&&n!="__proto__")return t[n]}return o1=e,o1}var s1,MP;function Gte(){if(MP)return s1;MP=1;var e=Ko(),t=Ur();function n(r){return e(r,t(r))}return s1=n,s1}var a1,IP;function Yte(){if(IP)return a1;IP=1;var e=OP(),t=D7(),n=y9(),r=H7(),i=x9(),o=Zo(),s=Rt(),a=$C(),l=zi(),c=Uo(),u=fn(),h=Vte(),f=es(),d=EP(),p=Gte();function g(m,v,b,_,x,w,C){var P=d(m,b),O=d(v,b),$=C.get(O);if($){e(m,b,$);return}var S=w?w(P,O,b+"",m,v,C):void 0,M=S===void 0;if(M){var I=s(O),E=!I&&l(O),A=!I&&!E&&f(O);S=O,I||E||A?s(P)?S=P:a(P)?S=r(P):E?(M=!1,S=t(O,!0)):A?(M=!1,S=n(O,!0)):S=[]:h(O)||o(O)?(S=P,o(P)?S=p(P):(!u(P)||c(P))&&(S=i(O))):M=!1}M&&(C.set(O,S),x(S,O,_,w,C),C.delete(O)),e(m,b,S)}return a1=g,a1}var l1,AP;function Xte(){if(AP)return l1;AP=1;var e=Cl(),t=OP(),n=Np(),r=Yte(),i=fn(),o=Ur(),s=EP();function a(l,c,u,h,f){l!==c&&n(c,function(d,p){if(f||(f=new e),i(d))r(l,c,p,u,a,h,f);else{var g=h?h(s(l,p),d,p+"",l,c,f):void 0;g===void 0&&(g=d),t(l,p,g)}},o)}return l1=a,l1}var c1,TP;function Ute(){if(TP)return c1;TP=1;var e=kl(),t=Ll();function n(r){return e(function(i,o){var s=-1,a=o.length,l=a>1?o[a-1]:void 0,c=a>2?o[2]:void 0;for(l=r.length>3&&typeof l=="function"?(a--,l):void 0,c&&t(o[0],o[1],c)&&(l=a<3?void 0:l,a=1),i=Object(i);++s<a;){var u=o[s];u&&r(i,u,s,l)}return i})}return c1=n,c1}var u1,RP;function Kte(){if(RP)return u1;RP=1;var e=Xte(),t=Ute(),n=t(function(r,i,o){e(r,i,o)});return u1=n,u1}var h1,kP;function LP(){if(kP)return h1;kP=1;function e(t,n){return t<n}return h1=e,h1}var f1,NP;function Zte(){if(NP)return f1;NP=1;var e=e1(),t=LP(),n=Kr();function r(i){return i&&i.length?e(i,n,t):void 0}return f1=r,f1}var d1,zP;function Qte(){if(zP)return d1;zP=1;var e=e1(),t=Kn(),n=LP();function r(i,o){return i&&i.length?e(i,t(o,2),n):void 0}return d1=r,d1}var p1,DP;function Jte(){if(DP)return p1;DP=1;var e=wn(),t=function(){return e.Date.now()};return p1=t,p1}var g1,qP;function ene(){if(qP)return g1;qP=1;var e=Ol(),t=Tl(),n=Sl(),r=fn(),i=ns();function o(s,a,l,c){if(!r(s))return s;a=t(a,s);for(var u=-1,h=a.length,f=h-1,d=s;d!=null&&++u<h;){var p=i(a[u]),g=l;if(p==="__proto__"||p==="constructor"||p==="prototype")return s;if(u!=f){var m=d[p];g=c?c(m,p,d):void 0,g===void 0&&(g=r(m)?m:n(a[u+1])?[]:{})}e(d,p,g),d=d[p]}return s}return g1=o,g1}var m1,HP;function tne(){if(HP)return m1;HP=1;var e=Rl(),t=ene(),n=Tl();function r(i,o,s){for(var a=-1,l=o.length,c={};++a<l;){var u=o[a],h=e(i,u);s(h,u)&&t(c,n(u,i),h)}return c}return m1=r,m1}var y1,jP;function nne(){if(jP)return y1;jP=1;var e=tne(),t=I8();function n(r,i){return e(r,i,function(o,s){return t(r,s)})}return y1=n,y1}var v1,FP;function rne(){if(FP)return v1;FP=1;var e=yP(),t=uC(),n=pC();function r(i){return n(t(i,void 0,e),i+"")}return v1=r,v1}var b1,BP;function ine(){if(BP)return b1;BP=1;var e=nne(),t=rne(),n=t(function(r,i){return r==null?{}:e(r,i)});return b1=n,b1}var _1,WP;function one(){if(WP)return _1;WP=1;var e=Math.ceil,t=Math.max;function n(r,i,o,s){for(var a=-1,l=t(e((i-r)/(o||1)),0),c=Array(l);l--;)c[s?l:++a]=r,r+=o;return c}return _1=n,_1}var w1,VP;function sne(){if(VP)return w1;VP=1;var e=one(),t=Ll(),n=fP();function r(i){return function(o,s,a){return a&&typeof a!="number"&&t(o,s,a)&&(s=a=void 0),o=n(o),s===void 0?(s=o,o=0):s=n(s),a=a===void 0?o<s?1:-1:n(a),e(o,s,a,i)}}return w1=r,w1}var x1,GP;function ane(){if(GP)return x1;GP=1;var e=sne(),t=e();return x1=t,x1}var C1,YP;function lne(){if(YP)return C1;YP=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return C1=e,C1}var P1,XP;function cne(){if(XP)return P1;XP=1;var e=qi();function t(n,r){if(n!==r){var i=n!==void 0,o=n===null,s=n===n,a=e(n),l=r!==void 0,c=r===null,u=r===r,h=e(r);if(!c&&!h&&!a&&n>r||a&&l&&u&&!c&&!h||o&&l&&u||!i&&u||!s)return 1;if(!o&&!a&&!h&&n<r||h&&i&&s&&!o&&!a||c&&i&&s||!l&&s||!u)return-1}return 0}return P1=t,P1}var O1,UP;function une(){if(UP)return O1;UP=1;var e=cne();function t(n,r,i){for(var o=-1,s=n.criteria,a=r.criteria,l=s.length,c=i.length;++o<l;){var u=e(s[o],a[o]);if(u){if(o>=c)return u;var h=i[o];return u*(h=="desc"?-1:1)}}return n.index-r.index}return O1=t,O1}var S1,KP;function hne(){if(KP)return S1;KP=1;var e=Al(),t=Rl(),n=Kn(),r=G8(),i=lne(),o=$l(),s=une(),a=Kr(),l=Rt();function c(u,h,f){h.length?h=e(h,function(g){return l(g)?function(m){return t(m,g.length===1?g[0]:g)}:g}):h=[a];var d=-1;h=e(h,o(n));var p=r(u,function(g,m,v){var b=e(h,function(_){return _(g)});return{criteria:b,index:++d,value:g}});return i(p,function(g,m){return s(g,m,f)})}return S1=c,S1}var $1,ZP;function fne(){if(ZP)return $1;ZP=1;var e=K0(),t=hne(),n=kl(),r=Ll(),i=n(function(o,s){if(o==null)return[];var a=s.length;return a>1&&r(o,s[0],s[1])?s=[]:a>2&&r(s[0],s[1],s[2])&&(s=[s[0]]),t(o,e(s,1),[])});return $1=i,$1}var E1,QP;function dne(){if(QP)return E1;QP=1;var e=w8(),t=0;function n(r){var i=++t;return e(r)+i}return E1=n,E1}var M1,JP;function pne(){if(JP)return M1;JP=1;function e(t,n,r){for(var i=-1,o=t.length,s=n.length,a={};++i<o;){var l=i<s?n[i]:void 0;r(a,t[i],l)}return a}return M1=e,M1}var I1,eO;function gne(){if(eO)return I1;eO=1;var e=Ol(),t=pne();function n(r,i){return t(r||[],i||[],e)}return I1=n,I1}var A1,tO;function wt(){if(tO)return A1;tO=1;var e;if(typeof Of=="function")try{e={cloneDeep:Ate(),constant:Rp(),defaults:Tte(),each:F9(),filter:D8(),find:qte(),flatten:yP(),forEach:H9(),forIn:Hte(),has:j8(),isUndefined:W8(),last:jte(),map:X8(),mapValues:Fte(),max:Wte(),merge:Kte(),min:Zte(),minBy:Qte(),now:Jte(),pick:ine(),range:ane(),reduce:Q8(),sortBy:fne(),uniqueId:dne(),values:AC(),zipObject:gne()}}catch(t){}return e||(e=window._),A1=e,A1}var T1,nO;function mne(){if(nO)return T1;nO=1,T1=e;function e(){var r={};r._next=r._prev=r,this._sentinel=r}e.prototype.dequeue=function(){var r=this._sentinel,i=r._prev;if(i!==r)return t(i),i},e.prototype.enqueue=function(r){var i=this._sentinel;r._prev&&r._next&&t(r),r._next=i._next,i._next._prev=r,i._next=r,r._prev=i},e.prototype.toString=function(){for(var r=[],i=this._sentinel,o=i._prev;o!==i;)r.push(JSON.stringify(o,n)),o=o._prev;return"["+r.join(", ")+"]"};function t(r){r._prev._next=r._next,r._next._prev=r._prev,delete r._next,delete r._prev}function n(r,i){if(r!=="_next"&&r!=="_prev")return i}return T1}var R1,rO;function yne(){if(rO)return R1;rO=1;var e=wt(),t=xn().Graph,n=mne();R1=i;var r=e.constant(1);function i(c,u){if(c.nodeCount()<=1)return[];var h=a(c,u||r),f=o(h.graph,h.buckets,h.zeroIdx);return e.flatten(e.map(f,function(d){return c.outEdges(d.v,d.w)}),!0)}function o(c,u,h){for(var f=[],d=u[u.length-1],p=u[0],g;c.nodeCount();){for(;g=p.dequeue();)s(c,u,h,g);for(;g=d.dequeue();)s(c,u,h,g);if(c.nodeCount()){for(var m=u.length-2;m>0;--m)if(g=u[m].dequeue(),g){f=f.concat(s(c,u,h,g,!0));break}}}return f}function s(c,u,h,f,d){var p=d?[]:void 0;return e.forEach(c.inEdges(f.v),function(g){var m=c.edge(g),v=c.node(g.v);d&&p.push({v:g.v,w:g.w}),v.out-=m,l(u,h,v)}),e.forEach(c.outEdges(f.v),function(g){var m=c.edge(g),v=g.w,b=c.node(v);b.in-=m,l(u,h,b)}),c.removeNode(f.v),p}function a(c,u){var h=new t,f=0,d=0;e.forEach(c.nodes(),function(m){h.setNode(m,{v:m,in:0,out:0})}),e.forEach(c.edges(),function(m){var v=h.edge(m.v,m.w)||0,b=u(m),_=v+b;h.setEdge(m.v,m.w,_),d=Math.max(d,h.node(m.v).out+=b),f=Math.max(f,h.node(m.w).in+=b)});var p=e.range(d+f+3).map(function(){return new n}),g=f+1;return e.forEach(h.nodes(),function(m){l(p,g,h.node(m))}),{graph:h,buckets:p,zeroIdx:g}}function l(c,u,h){h.out?h.in?c[h.out-h.in+u].enqueue(h):c[c.length-1].enqueue(h):c[0].enqueue(h)}return R1}var k1,iO;function vne(){if(iO)return k1;iO=1;var e=wt(),t=yne();k1={run:n,undo:i};function n(o){var s=o.graph().acyclicer==="greedy"?t(o,a(o)):r(o);e.forEach(s,function(l){var c=o.edge(l);o.removeEdge(l),c.forwardName=l.name,c.reversed=!0,o.setEdge(l.w,l.v,c,e.uniqueId("rev"))});function a(l){return function(c){return l.edge(c).weight}}}function r(o){var s=[],a={},l={};function c(u){e.has(l,u)||(l[u]=!0,a[u]=!0,e.forEach(o.outEdges(u),function(h){e.has(a,h.w)?s.push(h):c(h.w)}),delete a[u])}return e.forEach(o.nodes(),c),s}function i(o){e.forEach(o.edges(),function(s){var a=o.edge(s);if(a.reversed){o.removeEdge(s);var l=a.forwardName;delete a.reversed,delete a.forwardName,o.setEdge(s.w,s.v,a,l)}})}return k1}var L1,oO;function on(){if(oO)return L1;oO=1;var e=wt(),t=xn().Graph;L1={addDummyNode:n,simplify:r,asNonCompoundGraph:i,successorWeights:o,predecessorWeights:s,intersectRect:a,buildLayerMatrix:l,normalizeRanks:c,removeEmptyRanks:u,addBorderNode:h,maxRank:f,partition:d,time:p,notime:g};function n(m,v,b,_){var x;do x=e.uniqueId(_);while(m.hasNode(x));return b.dummy=v,m.setNode(x,b),x}function r(m){var v=new t().setGraph(m.graph());return e.forEach(m.nodes(),function(b){v.setNode(b,m.node(b))}),e.forEach(m.edges(),function(b){var _=v.edge(b.v,b.w)||{weight:0,minlen:1},x=m.edge(b);v.setEdge(b.v,b.w,{weight:_.weight+x.weight,minlen:Math.max(_.minlen,x.minlen)})}),v}function i(m){var v=new t({multigraph:m.isMultigraph()}).setGraph(m.graph());return e.forEach(m.nodes(),function(b){m.children(b).length||v.setNode(b,m.node(b))}),e.forEach(m.edges(),function(b){v.setEdge(b,m.edge(b))}),v}function o(m){var v=e.map(m.nodes(),function(b){var _={};return e.forEach(m.outEdges(b),function(x){_[x.w]=(_[x.w]||0)+m.edge(x).weight}),_});return e.zipObject(m.nodes(),v)}function s(m){var v=e.map(m.nodes(),function(b){var _={};return e.forEach(m.inEdges(b),function(x){_[x.v]=(_[x.v]||0)+m.edge(x).weight}),_});return e.zipObject(m.nodes(),v)}function a(m,v){var b=m.x,_=m.y,x=v.x-b,w=v.y-_,C=m.width/2,P=m.height/2;if(!x&&!w)throw new Error("Not possible to find intersection inside of the rectangle");var O,$;return Math.abs(w)*C>Math.abs(x)*P?(w<0&&(P=-P),O=P*x/w,$=P):(x<0&&(C=-C),O=C,$=C*w/x),{x:b+O,y:_+$}}function l(m){var v=e.map(e.range(f(m)+1),function(){return[]});return e.forEach(m.nodes(),function(b){var _=m.node(b),x=_.rank;e.isUndefined(x)||(v[x][_.order]=b)}),v}function c(m){var v=e.min(e.map(m.nodes(),function(b){return m.node(b).rank}));e.forEach(m.nodes(),function(b){var _=m.node(b);e.has(_,"rank")&&(_.rank-=v)})}function u(m){var v=e.min(e.map(m.nodes(),function(w){return m.node(w).rank})),b=[];e.forEach(m.nodes(),function(w){var C=m.node(w).rank-v;b[C]||(b[C]=[]),b[C].push(w)});var _=0,x=m.graph().nodeRankFactor;e.forEach(b,function(w,C){e.isUndefined(w)&&C%x!==0?--_:_&&e.forEach(w,function(P){m.node(P).rank+=_})})}function h(m,v,b,_){var x={width:0,height:0};return arguments.length>=4&&(x.rank=b,x.order=_),n(m,"border",x,v)}function f(m){return e.max(e.map(m.nodes(),function(v){var b=m.node(v).rank;if(!e.isUndefined(b))return b}))}function d(m,v){var b={lhs:[],rhs:[]};return e.forEach(m,function(_){v(_)?b.lhs.push(_):b.rhs.push(_)}),b}function p(m,v){var b=e.now();try{return v()}finally{console.log(m+" time: "+(e.now()-b)+"ms")}}function g(m,v){return v()}return L1}var N1,sO;function bne(){if(sO)return N1;sO=1;var e=wt(),t=on();N1={run:n,undo:i};function n(o){o.graph().dummyChains=[],e.forEach(o.edges(),function(s){r(o,s)})}function r(o,s){var a=s.v,l=o.node(a).rank,c=s.w,u=o.node(c).rank,h=s.name,f=o.edge(s),d=f.labelRank;if(u!==l+1){o.removeEdge(s);var p,g,m;for(m=0,++l;l<u;++m,++l)f.points=[],g={width:0,height:0,edgeLabel:f,edgeObj:s,rank:l},p=t.addDummyNode(o,"edge",g,"_d"),l===d&&(g.width=f.width,g.height=f.height,g.dummy="edge-label",g.labelpos=f.labelpos),o.setEdge(a,p,{weight:f.weight},h),m===0&&o.graph().dummyChains.push(p),a=p;o.setEdge(a,c,{weight:f.weight},h)}}function i(o){e.forEach(o.graph().dummyChains,function(s){var a=o.node(s),l=a.edgeLabel,c;for(o.setEdge(a.edgeObj,l);a.dummy;)c=o.successors(s)[0],o.removeNode(s),l.points.push({x:a.x,y:a.y}),a.dummy==="edge-label"&&(l.x=a.x,l.y=a.y,l.width=a.width,l.height=a.height),s=c,a=o.node(s)})}return N1}var z1,aO;function Nl(){if(aO)return z1;aO=1;var e=wt();z1={longestPath:t,slack:n};function t(r){var i={};function o(s){var a=r.node(s);if(e.has(i,s))return a.rank;i[s]=!0;var l=e.min(e.map(r.outEdges(s),function(c){return o(c.w)-r.edge(c).minlen}));return(l===Number.POSITIVE_INFINITY||l===void 0||l===null)&&(l=0),a.rank=l}e.forEach(r.sources(),o)}function n(r,i){return r.node(i.w).rank-r.node(i.v).rank-r.edge(i).minlen}return z1}var D1,lO;function cO(){if(lO)return D1;lO=1;var e=wt(),t=xn().Graph,n=Nl().slack;D1=r;function r(a){var l=new t({directed:!1}),c=a.nodes()[0],u=a.nodeCount();l.setNode(c,{});for(var h,f;i(l,a)<u;)h=o(l,a),f=l.hasNode(h.v)?n(a,h):-n(a,h),s(l,a,f);return l}function i(a,l){function c(u){e.forEach(l.nodeEdges(u),function(h){var f=h.v,d=u===f?h.w:f;!a.hasNode(d)&&!n(l,h)&&(a.setNode(d,{}),a.setEdge(u,d,{}),c(d))})}return e.forEach(a.nodes(),c),a.nodeCount()}function o(a,l){return e.minBy(l.edges(),function(c){if(a.hasNode(c.v)!==a.hasNode(c.w))return n(l,c)})}function s(a,l,c){e.forEach(a.nodes(),function(u){l.node(u).rank+=c})}return D1}var q1,uO;function _ne(){if(uO)return q1;uO=1;var e=wt(),t=cO(),n=Nl().slack,r=Nl().longestPath,i=xn().alg.preorder,o=xn().alg.postorder,s=on().simplify;q1=a,a.initLowLimValues=h,a.initCutValues=l,a.calcCutValue=u,a.leaveEdge=d,a.enterEdge=p,a.exchangeEdges=g;function a(_){_=s(_),r(_);var x=t(_);h(x),l(x,_);for(var w,C;w=d(x);)C=p(x,_,w),g(x,_,w,C)}function l(_,x){var w=o(_,_.nodes());w=w.slice(0,w.length-1),e.forEach(w,function(C){c(_,x,C)})}function c(_,x,w){var C=_.node(w),P=C.parent;_.edge(w,P).cutvalue=u(_,x,w)}function u(_,x,w){var C=_.node(w),P=C.parent,O=!0,$=x.edge(w,P),S=0;return $||(O=!1,$=x.edge(P,w)),S=$.weight,e.forEach(x.nodeEdges(w),function(M){var I=M.v===w,E=I?M.w:M.v;if(E!==P){var A=I===O,T=x.edge(M).weight;if(S+=A?T:-T,v(_,w,E)){var N=_.edge(w,E).cutvalue;S+=A?-N:N}}}),S}function h(_,x){arguments.length<2&&(x=_.nodes()[0]),f(_,{},1,x)}function f(_,x,w,C,P){var O=w,$=_.node(C);return x[C]=!0,e.forEach(_.neighbors(C),function(S){e.has(x,S)||(w=f(_,x,w,S,C))}),$.low=O,$.lim=w++,P?$.parent=P:delete $.parent,w}function d(_){return e.find(_.edges(),function(x){return _.edge(x).cutvalue<0})}function p(_,x,w){var C=w.v,P=w.w;x.hasEdge(C,P)||(C=w.w,P=w.v);var O=_.node(C),$=_.node(P),S=O,M=!1;O.lim>$.lim&&(S=$,M=!0);var I=e.filter(x.edges(),function(E){return M===b(_,_.node(E.v),S)&&M!==b(_,_.node(E.w),S)});return e.minBy(I,function(E){return n(x,E)})}function g(_,x,w,C){var P=w.v,O=w.w;_.removeEdge(P,O),_.setEdge(C.v,C.w,{}),h(_),l(_,x),m(_,x)}function m(_,x){var w=e.find(_.nodes(),function(P){return!x.node(P).parent}),C=i(_,w);C=C.slice(1),e.forEach(C,function(P){var O=_.node(P).parent,$=x.edge(P,O),S=!1;$||($=x.edge(O,P),S=!0),x.node(P).rank=x.node(O).rank+(S?$.minlen:-$.minlen)})}function v(_,x,w){return _.hasEdge(x,w)}function b(_,x,w){return w.low<=x.lim&&x.lim<=w.lim}return q1}var H1,hO;function wne(){if(hO)return H1;hO=1;var e=Nl(),t=e.longestPath,n=cO(),r=_ne();H1=i;function i(l){switch(l.graph().ranker){case"network-simplex":a(l);break;case"tight-tree":s(l);break;case"longest-path":o(l);break;default:a(l)}}var o=t;function s(l){t(l),n(l)}function a(l){r(l)}return H1}var j1,fO;function xne(){if(fO)return j1;fO=1;var e=wt();j1=t;function t(i){var o=r(i);e.forEach(i.graph().dummyChains,function(s){for(var a=i.node(s),l=a.edgeObj,c=n(i,o,l.v,l.w),u=c.path,h=c.lca,f=0,d=u[f],p=!0;s!==l.w;){if(a=i.node(s),p){for(;(d=u[f])!==h&&i.node(d).maxRank<a.rank;)f++;d===h&&(p=!1)}if(!p){for(;f<u.length-1&&i.node(d=u[f+1]).minRank<=a.rank;)f++;d=u[f]}i.setParent(s,d),s=i.successors(s)[0]}})}function n(i,o,s,a){var l=[],c=[],u=Math.min(o[s].low,o[a].low),h=Math.max(o[s].lim,o[a].lim),f,d;f=s;do f=i.parent(f),l.push(f);while(f&&(o[f].low>u||h>o[f].lim));for(d=f,f=a;(f=i.parent(f))!==d;)c.push(f);return{path:l.concat(c.reverse()),lca:d}}function r(i){var o={},s=0;function a(l){var c=s;e.forEach(i.children(l),a),o[l]={low:c,lim:s++}}return e.forEach(i.children(),a),o}return j1}var F1,dO;function Cne(){if(dO)return F1;dO=1;var e=wt(),t=on();F1={run:n,cleanup:s};function n(a){var l=t.addDummyNode(a,"root",{},"_root"),c=i(a),u=e.max(e.values(c))-1,h=2*u+1;a.graph().nestingRoot=l,e.forEach(a.edges(),function(d){a.edge(d).minlen*=h});var f=o(a)+1;e.forEach(a.children(),function(d){r(a,l,h,f,u,c,d)}),a.graph().nodeRankFactor=h}function r(a,l,c,u,h,f,d){var p=a.children(d);if(!p.length){d!==l&&a.setEdge(l,d,{weight:0,minlen:c});return}var g=t.addBorderNode(a,"_bt"),m=t.addBorderNode(a,"_bb"),v=a.node(d);a.setParent(g,d),v.borderTop=g,a.setParent(m,d),v.borderBottom=m,e.forEach(p,function(b){r(a,l,c,u,h,f,b);var _=a.node(b),x=_.borderTop?_.borderTop:b,w=_.borderBottom?_.borderBottom:b,C=_.borderTop?u:2*u,P=x!==w?1:h-f[d]+1;a.setEdge(g,x,{weight:C,minlen:P,nestingEdge:!0}),a.setEdge(w,m,{weight:C,minlen:P,nestingEdge:!0})}),a.parent(d)||a.setEdge(l,g,{weight:0,minlen:h+f[d]})}function i(a){var l={};function c(u,h){var f=a.children(u);f&&f.length&&e.forEach(f,function(d){c(d,h+1)}),l[u]=h}return e.forEach(a.children(),function(u){c(u,1)}),l}function o(a){return e.reduce(a.edges(),function(l,c){return l+a.edge(c).weight},0)}function s(a){var l=a.graph();a.removeNode(l.nestingRoot),delete l.nestingRoot,e.forEach(a.edges(),function(c){var u=a.edge(c);u.nestingEdge&&a.removeEdge(c)})}return F1}var B1,pO;function Pne(){if(pO)return B1;pO=1;var e=wt(),t=on();B1=n;function n(i){function o(s){var a=i.children(s),l=i.node(s);if(a.length&&e.forEach(a,o),e.has(l,"minRank")){l.borderLeft=[],l.borderRight=[];for(var c=l.minRank,u=l.maxRank+1;c<u;++c)r(i,"borderLeft","_bl",s,l,c),r(i,"borderRight","_br",s,l,c)}}e.forEach(i.children(),o)}function r(i,o,s,a,l,c){var u={width:0,height:0,rank:c,borderType:o},h=l[o][c-1],f=t.addDummyNode(i,"border",u,s);l[o][c]=f,i.setParent(f,a),h&&i.setEdge(h,f,{weight:1})}return B1}var W1,gO;function One(){if(gO)return W1;gO=1;var e=wt();W1={adjust:t,undo:n};function t(c){var u=c.graph().rankdir.toLowerCase();(u==="lr"||u==="rl")&&r(c)}function n(c){var u=c.graph().rankdir.toLowerCase();(u==="bt"||u==="rl")&&o(c),(u==="lr"||u==="rl")&&(a(c),r(c))}function r(c){e.forEach(c.nodes(),function(u){i(c.node(u))}),e.forEach(c.edges(),function(u){i(c.edge(u))})}function i(c){var u=c.width;c.width=c.height,c.height=u}function o(c){e.forEach(c.nodes(),function(u){s(c.node(u))}),e.forEach(c.edges(),function(u){var h=c.edge(u);e.forEach(h.points,s),e.has(h,"y")&&s(h)})}function s(c){c.y=-c.y}function a(c){e.forEach(c.nodes(),function(u){l(c.node(u))}),e.forEach(c.edges(),function(u){var h=c.edge(u);e.forEach(h.points,l),e.has(h,"x")&&l(h)})}function l(c){var u=c.x;c.x=c.y,c.y=u}return W1}var V1,mO;function Sne(){if(mO)return V1;mO=1;var e=wt();V1=t;function t(n){var r={},i=e.filter(n.nodes(),function(c){return!n.children(c).length}),o=e.max(e.map(i,function(c){return n.node(c).rank})),s=e.map(e.range(o+1),function(){return[]});function a(c){if(!e.has(r,c)){r[c]=!0;var u=n.node(c);s[u.rank].push(c),e.forEach(n.successors(c),a)}}var l=e.sortBy(i,function(c){return n.node(c).rank});return e.forEach(l,a),s}return V1}var G1,yO;function $ne(){if(yO)return G1;yO=1;var e=wt();G1=t;function t(r,i){for(var o=0,s=1;s<i.length;++s)o+=n(r,i[s-1],i[s]);return o}function n(r,i,o){for(var s=e.zipObject(o,e.map(o,function(f,d){return d})),a=e.flatten(e.map(i,function(f){return e.sortBy(e.map(r.outEdges(f),function(d){return{pos:s[d.w],weight:r.edge(d).weight}}),"pos")}),!0),l=1;l<o.length;)l<<=1;var c=2*l-1;l-=1;var u=e.map(new Array(c),function(){return 0}),h=0;return e.forEach(a.forEach(function(f){var d=f.pos+l;u[d]+=f.weight;for(var p=0;d>0;)d%2&&(p+=u[d+1]),d=d-1>>1,u[d]+=f.weight;h+=f.weight*p})),h}return G1}var Y1,vO;function Ene(){if(vO)return Y1;vO=1;var e=wt();Y1=t;function t(n,r){return e.map(r,function(i){var o=n.inEdges(i);if(o.length){var s=e.reduce(o,function(a,l){var c=n.edge(l),u=n.node(l.v);return{sum:a.sum+c.weight*u.order,weight:a.weight+c.weight}},{sum:0,weight:0});return{v:i,barycenter:s.sum/s.weight,weight:s.weight}}else return{v:i}})}return Y1}var X1,bO;function Mne(){if(bO)return X1;bO=1;var e=wt();X1=t;function t(i,o){var s={};e.forEach(i,function(l,c){var u=s[l.v]={indegree:0,in:[],out:[],vs:[l.v],i:c};e.isUndefined(l.barycenter)||(u.barycenter=l.barycenter,u.weight=l.weight)}),e.forEach(o.edges(),function(l){var c=s[l.v],u=s[l.w];!e.isUndefined(c)&&!e.isUndefined(u)&&(u.indegree++,c.out.push(s[l.w]))});var a=e.filter(s,function(l){return!l.indegree});return n(a)}function n(i){var o=[];function s(c){return function(u){u.merged||(e.isUndefined(u.barycenter)||e.isUndefined(c.barycenter)||u.barycenter>=c.barycenter)&&r(c,u)}}function a(c){return function(u){u.in.push(c),--u.indegree===0&&i.push(u)}}for(;i.length;){var l=i.pop();o.push(l),e.forEach(l.in.reverse(),s(l)),e.forEach(l.out,a(l))}return e.map(e.filter(o,function(c){return!c.merged}),function(c){return e.pick(c,["vs","i","barycenter","weight"])})}function r(i,o){var s=0,a=0;i.weight&&(s+=i.barycenter*i.weight,a+=i.weight),o.weight&&(s+=o.barycenter*o.weight,a+=o.weight),i.vs=o.vs.concat(i.vs),i.barycenter=s/a,i.weight=a,i.i=Math.min(o.i,i.i),o.merged=!0}return X1}var U1,_O;function Ine(){if(_O)return U1;_O=1;var e=wt(),t=on();U1=n;function n(o,s){var a=t.partition(o,function(g){return e.has(g,"barycenter")}),l=a.lhs,c=e.sortBy(a.rhs,function(g){return-g.i}),u=[],h=0,f=0,d=0;l.sort(i(!!s)),d=r(u,c,d),e.forEach(l,function(g){d+=g.vs.length,u.push(g.vs),h+=g.barycenter*g.weight,f+=g.weight,d=r(u,c,d)});var p={vs:e.flatten(u,!0)};return f&&(p.barycenter=h/f,p.weight=f),p}function r(o,s,a){for(var l;s.length&&(l=e.last(s)).i<=a;)s.pop(),o.push(l.vs),a++;return a}function i(o){return function(s,a){return s.barycenter<a.barycenter?-1:s.barycenter>a.barycenter?1:o?a.i-s.i:s.i-a.i}}return U1}var K1,wO;function Ane(){if(wO)return K1;wO=1;var e=wt(),t=Ene(),n=Mne(),r=Ine();K1=i;function i(a,l,c,u){var h=a.children(l),f=a.node(l),d=f?f.borderLeft:void 0,p=f?f.borderRight:void 0,g={};d&&(h=e.filter(h,function(w){return w!==d&&w!==p}));var m=t(a,h);e.forEach(m,function(w){if(a.children(w.v).length){var C=i(a,w.v,c,u);g[w.v]=C,e.has(C,"barycenter")&&s(w,C)}});var v=n(m,c);o(v,g);var b=r(v,u);if(d&&(b.vs=e.flatten([d,b.vs,p],!0),a.predecessors(d).length)){var _=a.node(a.predecessors(d)[0]),x=a.node(a.predecessors(p)[0]);e.has(b,"barycenter")||(b.barycenter=0,b.weight=0),b.barycenter=(b.barycenter*b.weight+_.order+x.order)/(b.weight+2),b.weight+=2}return b}function o(a,l){e.forEach(a,function(c){c.vs=e.flatten(c.vs.map(function(u){return l[u]?l[u].vs:u}),!0)})}function s(a,l){e.isUndefined(a.barycenter)?(a.barycenter=l.barycenter,a.weight=l.weight):(a.barycenter=(a.barycenter*a.weight+l.barycenter*l.weight)/(a.weight+l.weight),a.weight+=l.weight)}return K1}var Z1,xO;function Tne(){if(xO)return Z1;xO=1;var e=wt(),t=xn().Graph;Z1=n;function n(i,o,s){var a=r(i),l=new t({compound:!0}).setGraph({root:a}).setDefaultNodeLabel(function(c){return i.node(c)});return e.forEach(i.nodes(),function(c){var u=i.node(c),h=i.parent(c);(u.rank===o||u.minRank<=o&&o<=u.maxRank)&&(l.setNode(c),l.setParent(c,h||a),e.forEach(i[s](c),function(f){var d=f.v===c?f.w:f.v,p=l.edge(d,c),g=e.isUndefined(p)?0:p.weight;l.setEdge(d,c,{weight:i.edge(f).weight+g})}),e.has(u,"minRank")&&l.setNode(c,{borderLeft:u.borderLeft[o],borderRight:u.borderRight[o]}))}),l}function r(i){for(var o;i.hasNode(o=e.uniqueId("_root")););return o}return Z1}var Q1,CO;function Rne(){if(CO)return Q1;CO=1;var e=wt();Q1=t;function t(n,r,i){var o={},s;e.forEach(i,function(a){for(var l=n.parent(a),c,u;l;){if(c=n.parent(l),c?(u=o[c],o[c]=l):(u=s,s=l),u&&u!==l){r.setEdge(u,l);return}l=c}})}return Q1}var J1,PO;function kne(){if(PO)return J1;PO=1;var e=wt(),t=Sne(),n=$ne(),r=Ane(),i=Tne(),o=Rne(),s=xn().Graph,a=on();J1=l;function l(f){var d=a.maxRank(f),p=c(f,e.range(1,d+1),"inEdges"),g=c(f,e.range(d-1,-1,-1),"outEdges"),m=t(f);h(f,m);for(var v=Number.POSITIVE_INFINITY,b,_=0,x=0;x<4;++_,++x){u(_%2?p:g,_%4>=2),m=a.buildLayerMatrix(f);var w=n(f,m);w<v&&(x=0,b=e.cloneDeep(m),v=w)}h(f,b)}function c(f,d,p){return e.map(d,function(g){return i(f,g,p)})}function u(f,d){var p=new s;e.forEach(f,function(g){var m=g.graph().root,v=r(g,m,p,d);e.forEach(v.vs,function(b,_){g.node(b).order=_}),o(g,p,v.vs)})}function h(f,d){e.forEach(d,function(p){e.forEach(p,function(g,m){f.node(g).order=m})})}return J1}var em,OO;function Lne(){if(OO)return em;OO=1;var e=wt(),t=xn().Graph,n=on();em={positionX:p,findType1Conflicts:r,findType2Conflicts:i,addConflict:s,hasConflict:a,verticalAlignment:l,horizontalCompaction:c,alignCoordinates:f,findSmallestWidthAlignment:h,balance:d};function r(v,b){var _={};function x(w,C){var P=0,O=0,$=w.length,S=e.last(C);return e.forEach(C,function(M,I){var E=o(v,M),A=E?v.node(E).order:$;(E||M===S)&&(e.forEach(C.slice(O,I+1),function(T){e.forEach(v.predecessors(T),function(N){var H=v.node(N),D=H.order;(D<P||A<D)&&!(H.dummy&&v.node(T).dummy)&&s(_,N,T)})}),O=I+1,P=A)}),C}return e.reduce(b,x),_}function i(v,b){var _={};function x(C,P,O,$,S){var M;e.forEach(e.range(P,O),function(I){M=C[I],v.node(M).dummy&&e.forEach(v.predecessors(M),function(E){var A=v.node(E);A.dummy&&(A.order<$||A.order>S)&&s(_,E,M)})})}function w(C,P){var O=-1,$,S=0;return e.forEach(P,function(M,I){if(v.node(M).dummy==="border"){var E=v.predecessors(M);E.length&&($=v.node(E[0]).order,x(P,S,I,O,$),S=I,O=$)}x(P,S,P.length,$,C.length)}),P}return e.reduce(b,w),_}function o(v,b){if(v.node(b).dummy)return e.find(v.predecessors(b),function(_){return v.node(_).dummy})}function s(v,b,_){if(b>_){var x=b;b=_,_=x}var w=v[b];w||(v[b]=w={}),w[_]=!0}function a(v,b,_){if(b>_){var x=b;b=_,_=x}return e.has(v[b],_)}function l(v,b,_,x){var w={},C={},P={};return e.forEach(b,function(O){e.forEach(O,function($,S){w[$]=$,C[$]=$,P[$]=S})}),e.forEach(b,function(O){var $=-1;e.forEach(O,function(S){var M=x(S);if(M.length){M=e.sortBy(M,function(N){return P[N]});for(var I=(M.length-1)/2,E=Math.floor(I),A=Math.ceil(I);E<=A;++E){var T=M[E];C[S]===S&&$<P[T]&&!a(_,S,T)&&(C[T]=S,C[S]=w[S]=w[T],$=P[T])}}})}),{root:w,align:C}}function c(v,b,_,x,w){var C={},P=u(v,b,_,w),O=w?"borderLeft":"borderRight";function $(I,E){for(var A=P.nodes(),T=A.pop(),N={};T;)N[T]?I(T):(N[T]=!0,A.push(T),A=A.concat(E(T))),T=A.pop()}function S(I){C[I]=P.inEdges(I).reduce(function(E,A){return Math.max(E,C[A.v]+P.edge(A))},0)}function M(I){var E=P.outEdges(I).reduce(function(T,N){return Math.min(T,C[N.w]-P.edge(N))},Number.POSITIVE_INFINITY),A=v.node(I);E!==Number.POSITIVE_INFINITY&&A.borderType!==O&&(C[I]=Math.max(C[I],E))}return $(S,P.predecessors.bind(P)),$(M,P.successors.bind(P)),e.forEach(x,function(I){C[I]=C[_[I]]}),C}function u(v,b,_,x){var w=new t,C=v.graph(),P=g(C.nodesep,C.edgesep,x);return e.forEach(b,function(O){var $;e.forEach(O,function(S){var M=_[S];if(w.setNode(M),$){var I=_[$],E=w.edge(I,M);w.setEdge(I,M,Math.max(P(v,S,$),E||0))}$=S})}),w}function h(v,b){return e.minBy(e.values(b),function(_){var x=Number.NEGATIVE_INFINITY,w=Number.POSITIVE_INFINITY;return e.forIn(_,function(C,P){var O=m(v,P)/2;x=Math.max(C+O,x),w=Math.min(C-O,w)}),x-w})}function f(v,b){var _=e.values(b),x=e.min(_),w=e.max(_);e.forEach(["u","d"],function(C){e.forEach(["l","r"],function(P){var O=C+P,$=v[O],S;if($!==b){var M=e.values($);S=P==="l"?x-e.min(M):w-e.max(M),S&&(v[O]=e.mapValues($,function(I){return I+S}))}})})}function d(v,b){return e.mapValues(v.ul,function(_,x){if(b)return v[b.toLowerCase()][x];var w=e.sortBy(e.map(v,x));return(w[1]+w[2])/2})}function p(v){var b=n.buildLayerMatrix(v),_=e.merge(r(v,b),i(v,b)),x={},w;e.forEach(["u","d"],function(P){w=P==="u"?b:e.values(b).reverse(),e.forEach(["l","r"],function(O){O==="r"&&(w=e.map(w,function(I){return e.values(I).reverse()}));var $=(P==="u"?v.predecessors:v.successors).bind(v),S=l(v,w,_,$),M=c(v,w,S.root,S.align,O==="r");O==="r"&&(M=e.mapValues(M,function(I){return-I})),x[P+O]=M})});var C=h(v,x);return f(x,C),d(x,v.graph().align)}function g(v,b,_){return function(x,w,C){var P=x.node(w),O=x.node(C),$=0,S;if($+=P.width/2,e.has(P,"labelpos"))switch(P.labelpos.toLowerCase()){case"l":S=-P.width/2;break;case"r":S=P.width/2;break}if(S&&($+=_?S:-S),S=0,$+=(P.dummy?b:v)/2,$+=(O.dummy?b:v)/2,$+=O.width/2,e.has(O,"labelpos"))switch(O.labelpos.toLowerCase()){case"l":S=O.width/2;break;case"r":S=-O.width/2;break}return S&&($+=_?S:-S),S=0,$}}function m(v,b){return v.node(b).width}return em}var tm,SO;function Nne(){if(SO)return tm;SO=1;var e=wt(),t=on(),n=Lne().positionX;tm=r;function r(o){o=t.asNonCompoundGraph(o),i(o),e.forEach(n(o),function(s,a){o.node(a).x=s})}function i(o){var s=t.buildLayerMatrix(o),a=o.graph().ranksep,l=0;e.forEach(s,function(c){var u=e.max(e.map(c,function(h){return o.node(h).height}));e.forEach(c,function(h){o.node(h).y=l+u/2}),l+=u+a})}return tm}var nm,$O;function zne(){if($O)return nm;$O=1;var e=wt(),t=vne(),n=bne(),r=wne(),i=on().normalizeRanks,o=xne(),s=on().removeEmptyRanks,a=Cne(),l=Pne(),c=One(),u=kne(),h=Nne(),f=on(),d=xn().Graph;nm=p;function p(R,z){var q=z&&z.debugTiming?f.time:f.notime;q("layout",function(){var j=q(" buildLayoutGraph",function(){return $(R)});q(" runLayout",function(){g(j,q)}),q(" updateInputGraph",function(){m(R,j)})})}function g(R,z){z(" makeSpaceForEdgeLabels",function(){S(R)}),z(" removeSelfEdges",function(){B(R)}),z(" acyclic",function(){t.run(R)}),z(" nestingGraph.run",function(){a.run(R)}),z(" rank",function(){r(f.asNonCompoundGraph(R))}),z(" injectEdgeLabelProxies",function(){M(R)}),z(" removeEmptyRanks",function(){s(R)}),z(" nestingGraph.cleanup",function(){a.cleanup(R)}),z(" normalizeRanks",function(){i(R)}),z(" assignRankMinMax",function(){I(R)}),z(" removeEdgeLabelProxies",function(){E(R)}),z(" normalize.run",function(){n.run(R)}),z(" parentDummyChains",function(){o(R)}),z(" addBorderSegments",function(){l(R)}),z(" order",function(){u(R)}),z(" insertSelfEdges",function(){F(R)}),z(" adjustCoordinateSystem",function(){c.adjust(R)}),z(" position",function(){h(R)}),z(" positionSelfEdges",function(){X(R)}),z(" removeBorderNodes",function(){D(R)}),z(" normalize.undo",function(){n.undo(R)}),z(" fixupEdgeLabelCoords",function(){N(R)}),z(" undoCoordinateSystem",function(){c.undo(R)}),z(" translateGraph",function(){A(R)}),z(" assignNodeIntersects",function(){T(R)}),z(" reversePoints",function(){H(R)}),z(" acyclic.undo",function(){t.undo(R)})}function m(R,z){e.forEach(R.nodes(),function(q){var j=R.node(q),V=z.node(q);j&&(j.x=V.x,j.y=V.y,z.children(q).length&&(j.width=V.width,j.height=V.height))}),e.forEach(R.edges(),function(q){var j=R.edge(q),V=z.edge(q);j.points=V.points,e.has(V,"x")&&(j.x=V.x,j.y=V.y)}),R.graph().width=z.graph().width,R.graph().height=z.graph().height}var v=["nodesep","edgesep","ranksep","marginx","marginy"],b={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},_=["acyclicer","ranker","rankdir","align"],x=["width","height"],w={width:0,height:0},C=["minlen","weight","width","height","labeloffset"],P={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},O=["labelpos"];function $(R){var z=new d({multigraph:!0,compound:!0}),q=L(R.graph());return z.setGraph(e.merge({},b,G(q,v),e.pick(q,_))),e.forEach(R.nodes(),function(j){var V=L(R.node(j));z.setNode(j,e.defaults(G(V,x),w)),z.setParent(j,R.parent(j))}),e.forEach(R.edges(),function(j){var V=L(R.edge(j));z.setEdge(j,e.merge({},P,G(V,C),e.pick(V,O)))}),z}function S(R){var z=R.graph();z.ranksep/=2,e.forEach(R.edges(),function(q){var j=R.edge(q);j.minlen*=2,j.labelpos.toLowerCase()!=="c"&&(z.rankdir==="TB"||z.rankdir==="BT"?j.width+=j.labeloffset:j.height+=j.labeloffset)})}function M(R){e.forEach(R.edges(),function(z){var q=R.edge(z);if(q.width&&q.height){var j=R.node(z.v),V=R.node(z.w),U={rank:(V.rank-j.rank)/2+j.rank,e:z};f.addDummyNode(R,"edge-proxy",U,"_ep")}})}function I(R){var z=0;e.forEach(R.nodes(),function(q){var j=R.node(q);j.borderTop&&(j.minRank=R.node(j.borderTop).rank,j.maxRank=R.node(j.borderBottom).rank,z=e.max(z,j.maxRank))}),R.graph().maxRank=z}function E(R){e.forEach(R.nodes(),function(z){var q=R.node(z);q.dummy==="edge-proxy"&&(R.edge(q.e).labelRank=q.rank,R.removeNode(z))})}function A(R){var z=Number.POSITIVE_INFINITY,q=0,j=Number.POSITIVE_INFINITY,V=0,U=R.graph(),K=U.marginx||0,ne=U.marginy||0;function J(se){var Z=se.x,te=se.y,ue=se.width,re=se.height;z=Math.min(z,Z-ue/2),q=Math.max(q,Z+ue/2),j=Math.min(j,te-re/2),V=Math.max(V,te+re/2)}e.forEach(R.nodes(),function(se){J(R.node(se))}),e.forEach(R.edges(),function(se){var Z=R.edge(se);e.has(Z,"x")&&J(Z)}),z-=K,j-=ne,e.forEach(R.nodes(),function(se){var Z=R.node(se);Z.x-=z,Z.y-=j}),e.forEach(R.edges(),function(se){var Z=R.edge(se);e.forEach(Z.points,function(te){te.x-=z,te.y-=j}),e.has(Z,"x")&&(Z.x-=z),e.has(Z,"y")&&(Z.y-=j)}),U.width=q-z+K,U.height=V-j+ne}function T(R){e.forEach(R.edges(),function(z){var q=R.edge(z),j=R.node(z.v),V=R.node(z.w),U,K;q.points?(U=q.points[0],K=q.points[q.points.length-1]):(q.points=[],U=V,K=j),q.points.unshift(f.intersectRect(j,U)),q.points.push(f.intersectRect(V,K))})}function N(R){e.forEach(R.edges(),function(z){var q=R.edge(z);if(e.has(q,"x"))switch((q.labelpos==="l"||q.labelpos==="r")&&(q.width-=q.labeloffset),q.labelpos){case"l":q.x-=q.width/2+q.labeloffset;break;case"r":q.x+=q.width/2+q.labeloffset;break}})}function H(R){e.forEach(R.edges(),function(z){var q=R.edge(z);q.reversed&&q.points.reverse()})}function D(R){e.forEach(R.nodes(),function(z){if(R.children(z).length){var q=R.node(z),j=R.node(q.borderTop),V=R.node(q.borderBottom),U=R.node(e.last(q.borderLeft)),K=R.node(e.last(q.borderRight));q.width=Math.abs(K.x-U.x),q.height=Math.abs(V.y-j.y),q.x=U.x+q.width/2,q.y=j.y+q.height/2}}),e.forEach(R.nodes(),function(z){R.node(z).dummy==="border"&&R.removeNode(z)})}function B(R){e.forEach(R.edges(),function(z){if(z.v===z.w){var q=R.node(z.v);q.selfEdges||(q.selfEdges=[]),q.selfEdges.push({e:z,label:R.edge(z)}),R.removeEdge(z)}})}function F(R){var z=f.buildLayerMatrix(R);e.forEach(z,function(q){var j=0;e.forEach(q,function(V,U){var K=R.node(V);K.order=U+j,e.forEach(K.selfEdges,function(ne){f.addDummyNode(R,"selfedge",{width:ne.label.width,height:ne.label.height,rank:K.rank,order:U+ ++j,e:ne.e,label:ne.label},"_se")}),delete K.selfEdges})})}function X(R){e.forEach(R.nodes(),function(z){var q=R.node(z);if(q.dummy==="selfedge"){var j=R.node(q.e.v),V=j.x+j.width/2,U=j.y,K=q.x-V,ne=j.height/2;R.setEdge(q.e,q.label),R.removeNode(z),q.label.points=[{x:V+2*K/3,y:U-ne},{x:V+5*K/6,y:U-ne},{x:V+K,y:U},{x:V+5*K/6,y:U+ne},{x:V+2*K/3,y:U+ne}],q.label.x=q.x,q.label.y=q.y}})}function G(R,z){return e.mapValues(e.pick(R,z),Number)}function L(R){var z={};return e.forEach(R,function(q,j){z[j.toLowerCase()]=q}),z}return nm}var rm,EO;function Dne(){if(EO)return rm;EO=1;var e=wt(),t=on(),n=xn().Graph;rm={debugOrdering:r};function r(i){var o=t.buildLayerMatrix(i),s=new n({compound:!0,multigraph:!0}).setGraph({});return e.forEach(i.nodes(),function(a){s.setNode(a,{label:a}),s.setParent(a,"layer"+i.node(a).rank)}),e.forEach(i.edges(),function(a){s.setEdge(a.v,a.w,{},a.name)}),e.forEach(o,function(a,l){var c="layer"+l;s.setNode(c,{rank:"same"}),e.reduce(a,function(u,h){return s.setEdge(u,h,{style:"invis"}),h})}),s}return rm}var im,MO;function qne(){return MO||(MO=1,im="0.8.5"),im}var om,IO;function Hne(){return IO||(IO=1,om={graphlib:xn(),layout:zne(),debug:Dne(),util:{time:on().time,notime:on().notime},version:qne()}),om}var AO=Hne(),jne=OJ(AO),Fne=function(e){return h6(e,"Boolean")};function Bne(e,t){if(e){var n;if(_J(e))for(var r=0,i=e.length;r<i&&(n=t(e[r],r),n!==!1);r++);else if(wJ(e)){for(var o in e)if(e.hasOwnProperty(o)&&(n=t(e[o],o),n===!1))break}}}var Wne=Object.prototype.hasOwnProperty,Vne=(function(e,t){if(e===null||!PJ(e))return{};var n={};return Bne(t,function(r){Wne.call(e,r)&&(n[r]=e[r])}),n});class Gne extends bJ{constructor(){super(...arguments),this.id="dagre",this.isCompoundGraph=null,this.config={graphAttributes:["rankdir","align","nodesep","edgesep","ranksep","marginx","marginy","acyclicer","ranker"],nodeAttributes:["width","height"],edgeAttributes:["minlen","weight","width","height","labelpos","labeloffset"]}}getDefaultOptions(){return{directed:!0,multigraph:!0,rankdir:"TB",align:void 0,nodesep:50,edgesep:10,ranksep:50,marginx:0,marginy:0,acyclicer:void 0,ranker:"network-simplex",nodeSize:[0,0],edgeMinLen:1,edgeWeight:1,edgeLabelSize:[0,0],edgeLabelPos:"r",edgeLabelOffset:10}}layout(){return Yo(this,void 0,void 0,function*(){const t=new AO.graphlib.Graph({directed:!!this.options.directed,multigraph:!!this.options.multigraph,compound:this.isCompound()});t.setGraph(Vne(this.options,this.config.graphAttributes)),t.setDefaultEdgeLabel(()=>({}));const n=t6(this.options.nodeSize,0);this.model.forEachNode(d=>{const p=d._original,[g,m]=Q5(n(p)),v={width:g,height:m};if(t.setNode(String(d.id),v),this.isCompound()){if(hn(d.parentId))return;t.setParent(String(d.id),String(d.parentId))}});const{edgeLabelSize:r,edgeLabelOffset:i,edgeLabelPos:o,edgeMinLen:s,edgeWeight:a}=this.options,l=t6(r,0,"edge"),c=xf(i,10,"edge"),u=typeof o=="string"?()=>o:wf(o,["edge"]),h=xf(s,1,"edge"),f=xf(a,1,"edge");this.model.forEachEdge(d=>{const p=d._original,[g,m]=Q5(l(p)),v={width:g,height:m,labelpos:u(p),labeloffset:c(p),minlen:h(p),weight:f(p)};t.setEdge(String(d.source),String(d.target),v,String(d.id))}),jne.layout(t),this.model.forEachNode(d=>{const p=t.node(String(d.id));p&&(d.x=p.x,d.y=p.y,d.size=[p.width,p.height])}),this.model.forEachEdge(d=>{const p=t.edge(String(d.source),String(d.target),String(d.id));if(!p)return;const{width:g,height:m,weight:v,minlen:b,labelpos:_,labeloffset:x,points:w}=p;d.labelSize=[g,m],d.weight=v,d.minLen=b,d.labelPos=_,d.labelOffset=x,d.points=w.map(JQ)})})}isCompound(){return this.isCompoundGraph!==null?this.isCompoundGraph:Fne(this.options.compound)?this.isCompoundGraph=this.options.compound:(this.isCompoundGraph=this.model.nodes().some(t=>!hn(t.parentId)),this.isCompoundGraph)}}var Yne=Object.defineProperty,Xne=Object.defineProperties,Une=Object.getOwnPropertyDescriptors,TO=Object.getOwnPropertySymbols,Kne=Object.prototype.hasOwnProperty,Zne=Object.prototype.propertyIsEnumerable,RO=(e,t,n)=>t in e?Yne(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,kO=(e,t)=>{for(var n in t||(t={}))Kne.call(t,n)&&RO(e,n,t[n]);if(TO)for(var n of TO(t))Zne.call(t,n)&&RO(e,n,t[n]);return e},LO=(e,t)=>Xne(e,Une(t));const Qne=50,Jne=70,ere=10,tre=2,nre=30,rre=(e,t)=>{var n,r;const i=new Map;e.forEach(a=>i.set(a,[]));for(const a of t){if(a.source===a.target)return!0;(n=i.get(a.source))==null||n.push({target:a.target,edgeId:a.id}),(r=i.get(a.target))==null||r.push({target:a.source,edgeId:a.id})}const o=new Set,s=(a,l)=>{o.add(a);const c=i.get(a)||[];for(const{target:u,edgeId:h}of c)if(h!==l&&(o.has(u)||s(u,h)))return!0;return!1};for(const a of e)if(!o.has(a)&&s(a,null))return!0;return!1},NO=e=>{var t,n;const{Title:r,Item:i,data:o,rankdir:s="TB",nodesep:a=Qne,ranksep:l=Jne,edgesep:c=ere,edgeWidth:u=tre,showConnections:h=!0,edgeColorMode:f="gradient",edgeStyle:d="solid",edgeDashPattern:p="5,5",edgeCornerRadius:g=12,edgeRouting:m="orth",showArrow:v=!0,arrowType:b="triangle",padding:_=nre,edgeAnimation:x="none",edgeAnimationSpeed:w=1,options:C}=e,{title:P,desc:O,items:$=[],relations:S=[]}=o,M=r?y(r,{title:P,desc:O}):null;if(!i||$.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[M,y(Y,{children:y(Q,{indexes:[0],x:0,y:0})})]});const I=new Map,E=new Map,A=new Map,T=new Map,N=new Set,H=new Map;let D=0;const B=$.map((Z,te)=>{var ue,re;const ee=Z,oe=String((ue=ee.id)!=null?ue:te),ie=[te];let le;const pe=String((re=ee.group)!=null?re:"");if(pe){let fe=H.get(pe);fe==null&&(fe=D,H.set(pe,fe),D+=1),le=He(C,[fe])}else le=He(C,ie);const he=le?Et({colorPrimary:le},C):void 0;le&&A.set(oe,le);const ge=ae(y(i,{indexes:ie,data:o,datum:ee,positionH:"center",positionV:"middle",themeColors:he}));return E.set(oe,ge),I.set(oe,{id:oe,indexes:ie,datum:ee,themeColors:he}),T.set(te,oe),N.add(oe),{id:oe,parentId:ee.parentId}}),F=Z=>{if(Z==null)return null;const te=String(Z);if(N.has(te))return te;const ue=Number(Z);if(!Number.isNaN(ue)){const re=T.get(ue);if(re)return re}return null},X=S.map((Z,te)=>{const ue=F(Z.from),re=F(Z.to);return!ue||!re?null:{id:Z.id?String(Z.id):`edge-${te}`,source:ue,target:re,relation:Z}}).filter(Boolean),L=rre(Array.from(N),X)?"dagre":m,R=new Gne({rankdir:s,nodesep:a,ranksep:l,edgesep:c,controlPoints:!0,nodeSize:Z=>{var te;const ue=String((te=Z.id)!=null?te:""),re=E.get(ue);return re?[re.width,re.height]:[0,0]}});R.execute({nodes:B,edges:X});const z=[];if(R.forEachNode(Z=>{var te,ue,re,ee;const oe=String(Z.id),ie=I.get(oe);if(!ie)return;const le=E.get(oe),pe=(te=le==null?void 0:le.width)!=null?te:0,he=(ue=le==null?void 0:le.height)!=null?ue:0,ge=((re=Z.x)!=null?re:0)-pe/2,fe=((ee=Z.y)!=null?ee:0)-he/2;z.push(LO(kO({},ie),{x:ge,y:fe,width:pe,height:he,centerX:ge+pe/2,centerY:fe+he/2}))}),z.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[M,y(Y,{children:y(Q,{indexes:[0],x:0,y:0})})]});const q=Math.min(...z.map(Z=>Z.x)),j=Math.min(...z.map(Z=>Z.y)),V=_-q,U=_-j,K=new Map,ne=[];z.forEach(Z=>{const te=Z.x+V,ue=Z.y+U,re=s==="LR"?"normal":s==="RL"?"flipped":"center",ee=s==="TB"?"normal":s==="BT"?"flipped":"middle";ne.push(y(i,{indexes:Z.indexes,datum:Z.datum,data:o,x:te,y:ue,positionH:re,positionV:ee,themeColors:Z.themeColors})),K.set(Z.id,LO(kO({},Z),{x:te,y:ue,centerX:te+Z.width/2,centerY:ue+Z.height/2}))});const J=[],se=[];if(h){const Z=Ot(C),te=Et(C.themeConfig,C),ue=(t=te==null?void 0:te.colorBg)!=null?t:"#ffffff",re=(n=te==null?void 0:te.colorText)!=null?n:Z,ee=Math.max(10,u*4),oe=s==="TB"||s==="BT",ie=x==="ant-line",le=ie?p:"",he=ie?le:!ie&&d==="dashed"?p:"",ge=ie?le.split(",").reduce((ye,we)=>ye+parseFloat(we.trim()||"0"),0):0,fe=ie&&ge>0?`${ge/(w*10)}s`:"1s",xe=g,$e=(ye,we,Ae)=>ye.map(([Ee,ce],me)=>`${me===0?"M":"L"} ${Ee+we} ${ce+Ae}`).join(" "),Ie=(ye,we,Ae,Ee)=>{if(ye.length<2)return"";const ce=(Se,Be,Qe)=>Math.min(Qe,Math.max(Be,Se)),me=([Se,Be])=>({x:Se+Ae,y:Be+Ee}),Oe=[],Ye=me(ye[0]);if(Oe.push(`M ${Ye.x} ${Ye.y}`),ye.length===2){const Se=me(ye[1]);return Oe.push(`L ${Se.x} ${Se.y}`),Oe.join(" ")}for(let Se=1;Se<ye.length-1;Se+=1){const Be=ye[Se-1],Qe=ye[Se],Je=ye[Se+1],Xe=Qe[0]-Be[0],pt=Qe[1]-Be[1],et=Je[0]-Qe[0],Wt=Je[1]-Qe[1],Gt=Math.hypot(Xe,pt),Ue=Math.hypot(et,Wt);if(Gt===0||Ue===0){const si=me(Qe);Oe.push(`L ${si.x} ${si.y}`);continue}const $t=ce(we,0,Math.min(Gt,Ue)/2);if($t===0){const si=me(Qe);Oe.push(`L ${si.x} ${si.y}`);continue}const Nt=Xe/Gt,Qt=pt/Gt,qn=et/Ue,ii=Wt/Ue,oi=me([Qe[0]-Nt*$t,Qe[1]-Qt*$t]),Hn=me([Qe[0]+qn*$t,Qe[1]+ii*$t]);Oe.push(`L ${oi.x} ${oi.y}`);const wc=me(Qe);Oe.push(`Q ${wc.x} ${wc.y} ${Hn.x} ${Hn.y}`)}const rt=me(ye[ye.length-1]);return Oe.push(`L ${rt.x} ${rt.y}`),Oe.join(" ")},Pe=(ye,we,Ae,Ee,ce)=>{const me=Math.cos(Ae),Oe=Math.sin(Ae),Ye=-Oe,rt=me,Se=ee,Be=ee*.55;if(Ee==="arrow"){const Je=ye-me*Se+Ye*Be,Xe=we-Oe*Se+rt*Be,pt=ye-me*Se-Ye*Be,et=we-Oe*Se-rt*Be;return[y(Ce,{d:`M ${Je} ${Xe} L ${ye} ${we} L ${pt} ${et}`,stroke:ce,strokeWidth:Math.max(1.5,u),strokeLinecap:"round",strokeLinejoin:"round",fill:"none"})]}if(Ee==="diamond"){const Je=Se*1.25,Xe=Be*.75,pt=ye-me*Je*.5,et=we-Oe*Je*.5,Wt=[{x:ye,y:we},{x:pt+Ye*Xe,y:et+rt*Xe},{x:ye-me*Je,y:we-Oe*Je},{x:pt-Ye*Xe,y:et-rt*Xe}];return[y(Yt,{points:Wt,fill:ce,stroke:ce,strokeWidth:Math.max(1,u*.8)})]}const Qe=[{x:ye,y:we},{x:ye-me*Se+Ye*Be,y:we-Oe*Se+rt*Be},{x:ye-me*Se-Ye*Be,y:we-Oe*Se-rt*Be}];return[y(Yt,{points:Qe,fill:ce,stroke:ce,strokeWidth:Math.max(1,u*.8)})]},Le=ye=>{if(ye.length===0)return null;if(ye.length===1)return ye[0];let we=0;const Ae=[];for(let ce=0;ce<ye.length-1;ce+=1){const me=ye[ce],Oe=ye[ce+1],Ye=Math.hypot(Oe[0]-me[0],Oe[1]-me[1]);Ae.push({length:Ye,start:me,end:Oe}),we+=Ye}if(we===0)return ye[0];let Ee=we/2;for(let ce=0;ce<Ae.length;ce+=1){const me=Ae[ce];if(Ee<=me.length||ce===Ae.length-1){const Oe=me.length===0?0:Math.max(0,Math.min(1,Ee/me.length));return[me.start[0]+(me.end[0]-me.start[0])*Oe,me.start[1]+(me.end[1]-me.start[1])*Oe]}Ee-=me.length}return ye[Math.floor(ye.length/2)]},je=(ye,we)=>{const Ae=K.get(ye),Ee=K.get(we);return!Ae||!Ee?null:s==="TB"?{start:[Ae.centerX,Ae.y+Ae.height],end:[Ee.centerX,Ee.y]}:s==="BT"?{start:[Ae.centerX,Ae.y],end:[Ee.centerX,Ee.y+Ee.height]}:s==="LR"?{start:[Ae.x+Ae.width,Ae.centerY],end:[Ee.x,Ee.centerY]}:{start:[Ae.x,Ae.centerY],end:[Ee.x+Ee.width,Ee.centerY]}},Fe=(ye,we)=>{const Ae=je(ye,we);if(!Ae)return null;const{start:Ee,end:ce}=Ae;if(oe){const Oe=Ee[1]+(ce[1]-Ee[1])/2;return{start:Ee,end:ce,points:[Ee,[Ee[0],Oe],[ce[0],Oe],ce]}}const me=Ee[0]+(ce[0]-Ee[0])/2;return{start:Ee,end:ce,points:[Ee,[me,Ee[1]],[me,ce[1]],ce]}};R.forEachEdge(ye=>{var we,Ae,Ee,ce,me,Oe,Ye,rt,Se;const Be=xt=>Array.isArray(xt)?xt.map(gt=>gt&&Array.isArray(gt)&>.length>=2?[Number(gt[0]),Number(gt[1])]:null).filter(gt=>!!gt&&Number.isFinite(gt[0])&&Number.isFinite(gt[1])):[],Qe=()=>{const xt=K.get(String(ye.source)),gt=K.get(String(ye.target));return!xt||!gt?[]:[[xt.centerX-V,xt.centerY-U],[gt.centerX-V,gt.centerY-U]]},Je=L==="orth",Xe=Je?Fe(String(ye.source),String(ye.target)):null,pt=Je?[]:Be(ye.points),et=Je?(we=Xe==null?void 0:Xe.points)!=null?we:[]:pt.length?pt:Qe();if(!et.length)return;const Wt=Je?0:V,Gt=Je?0:U,Ue=Je&&(Ae=Xe==null?void 0:Xe.start)!=null?Ae:et[0],$t=Je&&(Ee=Xe==null?void 0:Xe.end)!=null?Ee:et[et.length-1],Nt=(ce=ye._original)==null?void 0:ce.relation,Qt=(me=A.get(String(ye.source)))!=null?me:Z,qn=(Oe=A.get(String(ye.target)))!=null?Oe:Z,ii=`edge-gradient-${String(Qt)}-${String(qn)}`.replace(/[^a-zA-Z0-9_-]/g,""),oi=f==="gradient"?`url(#${ii})`:Z;let Hn="";if(xe>0?Hn=Ie(et,xe,Wt,Gt):Hn=$e(et,Wt,Gt),!Hn)return;const wc=y(Ce,{d:Hn,stroke:oi,strokeWidth:u,strokeDasharray:he,fill:"none","data-element-type":"shape",children:ie&&y("animate",{attributeName:"stroke-dashoffset",from:String(ge),to:"0",dur:fe,repeatCount:"indefinite"})});if(se.push(wc),f==="gradient"){const xt=Ue,gt=$t;J.push(k("linearGradient",{id:ii,gradientUnits:"userSpaceOnUse",x1:xt[0]+Wt,y1:xt[1]+Gt,x2:gt[0]+Wt,y2:gt[1]+Gt,children:[y("stop",{offset:"0%",stopColor:Qt}),y("stop",{offset:"100%",stopColor:qn})]}))}if(Nt!=null&&Nt.label){let xt=null;const gt=Le(et);if(gt&&(xt=[gt[0]+Wt,gt[1]+Gt]),xt){const Yi=String(Nt.label),_r=ae(y(Ne,{fontSize:14,fontWeight:"normal",children:Yi})),fs=xt[0]-_r.width/2,Jae=xt[1]-_r.height/2;se.push(y(Ne,{x:fs,y:Jae,width:_r.width,height:_r.height,fontSize:14,fontWeight:"normal",alignHorizontal:"center",alignVertical:"middle",fill:re,backgroundColor:ue,children:Yi}))}}const si=(Ye=Nt==null?void 0:Nt.showArrow)!=null?Ye:v,hy=(rt=Nt==null?void 0:Nt.direction)!=null?rt:"forward",QE=(Se=Nt==null?void 0:Nt.arrowType)!=null?Se:b,JE=et.length-1;if(si&&et.length>1){if(hy==="forward"||hy==="both"){const xt=et[JE],gt=et[JE-1],Yi=Math.atan2(xt[1]-gt[1],xt[0]-gt[0]),_r=f==="gradient"?qn:Z,fs=Pe(xt[0]+Wt,xt[1]+Gt,Yi,QE,_r);se.push(...fs)}if(hy==="both"){const xt=et[0],gt=et[1],Yi=Math.atan2(xt[1]-gt[1],xt[0]-gt[0]),_r=f==="gradient"?Qt:Z,fs=Pe(xt[0]+Wt,xt[1]+Gt,Yi,QE,_r);se.push(...fs)}}})}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[M,k(Y,{children:[y(Ke,{children:J}),y(Y,{width:0,height:0,children:se}),y(ze,{children:ne}),y(qe,{})]})]})};We("relation-dagre-flow",{component:NO,composites:["title","item"]});const zO=e=>{const{Title:t,Item:n,data:r,spacing:i=120,showConnections:o=!0,options:s}=e,{title:a,desc:l,items:c=[]}=r,u=t?y(t,{title:a,desc:l}):null;if(c.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,y(Y,{children:y(ze,{})})]});const h=ae(y(n,{indexes:[0],data:r,datum:c[0],positionH:"center"}));function f(){const P=c.map((S,M)=>({id:M,data:S,isCenter:M===0,_originalIndex:[M]})),O=c.slice(1).map((S,M)=>({source:0,target:M+1})),$=SX(P).force("link",vX(O).id(S=>S.id).distance(i)).force("charge",$X().strength(-50)).force("center",ZY(0,0)).force("collision",mX().radius(Math.max(h.width,h.height)/2+10));for(let S=0;S<300;++S)$.tick();return{nodes:P,links:O}}const{nodes:d,links:p}=f(),g=Math.min(...d.map(P=>{var O;return(O=P.x)!=null?O:0})),m=Math.min(...d.map(P=>{var O;return(O=P.y)!=null?O:0})),v=Math.max(0,-g+h.width/2),b=Math.max(0,-m+h.height/2),_=(P,O)=>({positionH:P<-50?"flipped":P>50?"normal":"center",positionV:O<-50?"flipped":O>50?"normal":"middle"}),x=d.map(P=>{if(P.x==null||P.y==null)return null;const O=P.x+v-h.width/2,$=P.y+b-h.height/2,{positionH:S,positionV:M}=_(P.x,P.y);return y(n,{indexes:P._originalIndex,datum:P.data,data:r,x:O,y:$,positionH:S,positionV:M},P.id)}).filter(Boolean),w=new Map(d.map(P=>[P.id,P])),C=o?p.map(P=>{const O=typeof P.source=="object"?P.source:w.get(P.source),$=typeof P.target=="object"?P.target:w.get(P.target);if(!O||!$||O.x==null||O.y==null||$.x==null||$.y==null)return null;const S=`M ${O.x+v} ${O.y+b} L ${$.x+v} ${$.y+b}`;return y(Ce,{d:S,stroke:Ot(s),strokeWidth:2,strokeOpacity:.6})}).filter(Boolean):[];return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,k(Y,{children:[y(Y,{children:C}),y(ze,{children:x})]})]})};We("relation-network",{component:zO,composites:["title","item"]});var ire=Object.defineProperty,ore=Object.defineProperties,sre=Object.getOwnPropertyDescriptors,zl=Object.getOwnPropertySymbols,DO=Object.prototype.hasOwnProperty,qO=Object.prototype.propertyIsEnumerable,HO=(e,t,n)=>t in e?ire(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,are=(e,t)=>{for(var n in t||(t={}))DO.call(t,n)&&HO(e,n,t[n]);if(zl)for(var n of zl(t))qO.call(t,n)&&HO(e,n,t[n]);return e},lre=(e,t)=>ore(e,sre(t)),cre=(e,t)=>{var n={};for(var r in e)DO.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&zl)for(var r of zl(e))t.indexOf(r)<0&&qO.call(e,r)&&(n[r]=e[r]);return n};const sm=e=>{var t=e,{width:n=25,height:r=25,colorPrimary:i="#6699FF",rotation:o=0}=t,s=cre(t,["width","height","colorPrimary","rotation"]);const a=`gradient-arrow-stroke-${i.replace("#","")}`,l=`gradient-arrow-fill-${i.replace("#","")}`,c=Math.round(n*.515),u=Math.round(r*.275),h=Math.round(r*.875),f=[{x:0,y:u},{x:c,y:u},{x:c,y:r*.075},{x:n,y:r*.575},{x:c,y:r*1.075},{x:c,y:h},{x:0,y:h}],d=n/2,p=r/2,g=`rotate(${o} ${d} ${p})`;return k(tt,{children:[y(Yt,lre(are({},s),{width:n,height:r,points:f,fill:`url(#${l})`,stroke:`url(#${a})`,transform:g,"data-element-type":"shape"})),k(Ke,{children:[k("linearGradient",{id:l,x1:"100%",y1:"0%",x2:"0%",y2:"0%",children:[y("stop",{offset:"0%","stop-color":i,"stop-opacity":"0.36"}),y("stop",{offset:"100%","stop-color":i,"stop-opacity":"0"})]}),k("linearGradient",{id:a,x1:"100%",y1:"0%",x2:"0%",y2:"0%",children:[y("stop",{offset:"0%","stop-color":i}),y("stop",{offset:"58%","stop-color":i,"stop-opacity":"0"})]})]})]})},ure=({text:e,x:t=0,y:n=0,fontSize:r=56,fontWeight:i="bold",fill:o="#FFFFFF",textAnchor:s="middle",dominantBaseline:a="middle",shadowOffsetX:l=2,shadowOffsetY:c=4,midShadowOffsetX:u=1,midShadowOffsetY:h=2,deepShadowOpacity:f=.3,midShadowOpacity:d=.5})=>k(Y,{children:[y("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,fillOpacity:f,textAnchor:s,dominantBaseline:a,transform:`translate(${l}, ${c})`,children:e}),y("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,fillOpacity:d,textAnchor:s,dominantBaseline:a,transform:`translate(${u}, ${h})`,children:e}),y("text",{x:t,y:n,fontSize:r,fontWeight:i,fill:o,textAnchor:s,dominantBaseline:a,children:e})]});var hre=Object.defineProperty,fre=Object.defineProperties,dre=Object.getOwnPropertyDescriptors,Dl=Object.getOwnPropertySymbols,jO=Object.prototype.hasOwnProperty,FO=Object.prototype.propertyIsEnumerable,BO=(e,t,n)=>t in e?hre(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pre=(e,t)=>{for(var n in t||(t={}))jO.call(t,n)&&BO(e,n,t[n]);if(Dl)for(var n of Dl(t))FO.call(t,n)&&BO(e,n,t[n]);return e},gre=(e,t)=>fre(e,dre(t)),mre=(e,t)=>{var n={};for(var r in e)jO.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Dl)for(var r of Dl(e))t.indexOf(r)<0&&FO.call(e,r)&&(n[r]=e[r]);return n};const yre=e=>{var t=e,{width:n=25,height:r=25,colorPrimary:i="#6699FF",rotation:o=0,strokeWidth:s=4}=t,a=mre(t,["width","height","colorPrimary","rotation","strokeWidth"]);const l=[{x:n/2,y:0},{x:n,y:r},{x:0,y:r}],c=n/2,u=r/2,h=`rotate(${o} ${c} ${u})`;return y(Yt,gre(pre({},a),{width:n,height:r,points:l,fill:i,stroke:i,strokeWidth:s,strokeLinecap:"round",strokeLinejoin:"round",transform:h}))},vre=-118,WO=118,VO=240,bre=180,_re=40,wre="M238.9 69.7a6 6 0 0 1-.1 1v.2l-.2.3v.3l-.1.3a6.2 6.2 0 0 1-.3.6l-.1.3-.2.3-.2.4-.3.5-.1.1a10.9 10.9 0 0 1-.8 1v.1l-.5.5h-.1l-.4.4-.3.3-.3.2-.3.3-.4.2a13 13 0 0 1-.7.5l-.4.3-.5.3-97.5 56.7-.7.4h-.2l-.6.4h-.1l-.8.4h-.2l-.6.4h-.2l-.8.3h-.2l-.5.3-.5.1-.5.1-.5.2h-.5a33.7 33.7 0 0 1-3.2.7h-.2l-1 .2h-1.6l-.7.1h-4.7l-.8-.1h-.2a38.2 38.2 0 0 1-2-.4h-.4l-.7-.2h-.4l-.7-.2-.4-.1a27.3 27.3 0 0 1-2.2-.7h-.2a44.2 44.2 0 0 1-.9-.3l-.5-.3-.4-.1-.5-.2-.3-.2-.5-.2-.3-.2-.8-.4L6.5 78C2.2 75.6 0 72.4 0 69v41.7c0 3.2 2.1 6.5 6.4 9l98.1 56.6a23.2 23.2 0 0 0 1 .6l.6.3.3.1.5.2.4.2.3.1h.2l.2.2a21.4 21.4 0 0 0 1.9.6l.3.1h.2l.7.2a77.6 77.6 0 0 1 1.1.3h.3l.7.2h.4a42.5 42.5 0 0 0 1 .2l1 .2h1.1l.4.1h2.1l.7.1h1.5a22 22 0 0 0 1.8-.2h.4l1.1-.1h.2l1.2-.2h.1l.3-.1.6-.1a12.5 12.5 0 0 0 1-.3h.5l.5-.2a29 29 0 0 0 1-.3h.2l.3-.2h.2a27 27 0 0 0 1.6-.7h.2l.8-.4a19.4 19.4 0 0 0 1.6-.9l97.5-56.7.3-.1.2-.2.4-.2.4-.3.3-.2.3-.3.4-.2.3-.3.3-.3h.1l.3-.3.5-.6h.1l.3-.5h.1v-.1l.4-.4v-.1l.4-.5v-.1l.1-.2.1-.2.2-.3.1-.3.1-.3.1-.1a6.9 6.9 0 0 0 .2-.8l.1-.3v-.4l.1-.3v-1l.2-41.4v.4Z",xre="M232.5 60.4c8.5 4.9 8.5 12.8.1 17.7l-97.5 56.7c-8.4 4.9-22 4.9-30.5 0L6.5 78C-2 73-2 65.3 6.4 60.4l97.5-56.7c8.4-5 22-5 30.5 0l98.1 56.7Z",Cre="M119.1 0A31 31 0 0 0 104 3.7L6.4 60.4C-2 65.3-2 73.2 6.4 78l98.2 56.7c4.2 2.4 9.8 3.7 15.3 3.7a31 31 0 0 0 15.2-3.7L232.6 78c8.4-5 8.4-12.8 0-17.7L134.3 3.7A31.2 31.2 0 0 0 119.1 0Zm0 2.5c5.4 0 10.3 1.2 14 3.3l98.2 56.7c3.3 2 5.1 4.3 5.1 6.8 0 2.4-1.8 4.7-5 6.6l-97.5 56.7a28.3 28.3 0 0 1-14 3.4c-5.3 0-10.3-1.2-14-3.4L7.7 76c-3.3-1.9-5-4.3-5-6.7 0-2.4 1.7-4.8 5-6.7L105 5.8a29 29 0 0 1 14-3.3Z",GO=k("filter",{id:"sequence-ascending-stairs-3d-shadow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[y("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),y("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),y("feOffset",{dx:"0",dy:"4"}),y("feGaussianBlur",{stdDeviation:"6"}),y("feComposite",{in2:"hardAlpha",operator:"out"}),y("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"}),y("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow"}),y("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow",result:"shape"})]}),YO=e=>{const{Title:t,Item:n,data:r,options:i,cubeWidth:o=VO}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null;if(l.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[y(Ke,{children:GO}),c,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const u=ae(y(Q,{indexes:[0]})),h=[],f=[],d=[],p=o/VO,g=bre*p;return l.forEach((m,v)=>{const b=[v],_=He(i,b),x=v*(o+vre),w=(l.length-1-v)*WO,C=`cube-gradient-bottom-${v}`,P=`cube-gradient-top-${v}`,O=`cube-gradient-stroke-${v}`;d.push(k(Y,{x,y:w,id:`cube-${v}`,width:o,height:g,filter:"url(#sequence-ascending-stairs-3d-shadow-filter)",children:[k(Ke,{children:[k("linearGradient",{id:C,x1:"0",y1:"124.5",x2:"238.9",y2:"124.5",gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0",stopColor:_,stopOpacity:"0.8"}),y("stop",{offset:"1",stopColor:_,stopOpacity:"0.4"})]}),k("linearGradient",{id:P,x1:"119.5",y1:"0",x2:"119.5",y2:"138.5",gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0",stopColor:_,stopOpacity:"0.9"}),y("stop",{offset:"1",stopColor:_,stopOpacity:"0.5"})]}),k("linearGradient",{id:O,x1:"119.5",y1:"0",x2:"119.5",y2:"138.5",gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0",stopColor:_}),y("stop",{offset:"1",stopColor:_,stopOpacity:"0.7"})]})]}),k(Pt,{transform:`scale(${p})`,children:[y(Ce,{d:wre,fill:`url(#${C})`}),y(Ce,{d:xre,fill:`url(#${P})`}),y(Ce,{d:Cre,fill:`url(#${O})`})]}),y(ure,{text:v+1,x:115,y:65,fontSize:56})]}));const $=x+o+_re,S=w+g/2;if(f.push(y(n,{indexes:b,datum:m,data:r,x:$,y:S,positionH:"normal"})),h.push(y(nt,{indexes:b,x:x+o-u.width/2,y:w-u.height/2})),v===0&&h.push(y(Q,{indexes:[0],x:x-30-u.width/2,y:w+g/2-u.height/2})),v<l.length-1){const M=(l.length-1-(v+1))*WO,I=x+o-u.width/2,E=(w+g/2+M+g/2)/2-u.height/2;h.push(y(Q,{indexes:[v+1],x:I,y:E}))}else h.push(y(Q,{indexes:[l.length],x:x+o+30-u.width/2,y:w+g/2-u.height/2}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[y(Ke,{children:GO}),c,k(Y,{x:0,y:0,children:[y(Y,{children:d}),y(ze,{children:f}),y(qe,{children:h})]})]})};We("sequence-ascending-stairs-3d",{component:YO,composites:["title","item"]});const XO=e=>{const{Title:t,Item:n,data:r,hGap:i=0,vGap:o=0}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=ae(y(n,{indexes:[0],data:r,datum:l[0]})),h=[],f=[],d=l.length,p=u.width+i,g=u.height/2+o,m=u.width/2,b=0+(d-1)*g;return l.forEach((_,x)=>{const w=m+x*p,C=b-x*g,P=[x];h.push(y(n,{indexes:P,datum:_,data:r,x:w,y:C})),f.push(y(nt,{indexes:P,x:w+u.width-30,y:C+u.height/2+10})),f.push(y(Q,{indexes:P,x:w+u.width+i/2,y:C-30}))}),k(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(ze,{children:h}),y(qe,{children:f})]})]})};We("sequence-ascending-steps",{component:XO,composites:["title","item"]});const Pre=20,UO=5,KO=e=>{const{Title:t,Item:n,data:r,options:i,radius:o=150,arrowSize:s=4,strokeWidth:a=10}=e,{title:l,desc:c,items:u=[]}=r,h=ae(y(Q,{indexes:[0]})),f=Ot(i);if(!n)return k(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[t?y(t,{title:l,desc:c}):null,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const d=u.length;if(d===0)return k(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[t?y(t,{title:l,desc:c}):null,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const p=ae(y(n,{indexes:[0],data:r,datum:u[0]})),g=0,m=0,v=2*Math.PI/d,b=[];let _=1/0,x=1/0,w=-1/0,C=-1/0;for(let N=0;N<d;N++){const H=N*v-Math.PI/2,D=g+o*Math.cos(H),B=m+o*Math.sin(H);b.push({x:D,y:B}),_=Math.min(_,D),x=Math.min(x,B),w=Math.max(w,D),C=Math.max(C,B)}const P=[];for(let N=0;N<d;N++){const H=b[N],D=b[(N+1)%d],B=Math.sqrt(Math.pow(D.x-H.x,2)+Math.pow(D.y-H.y,2)),F=Math.min(B*.5,100),X=(H.x+D.x)/2,G=(H.y+D.y)/2;_=Math.min(_,X-F/2),x=Math.min(x,G-F/2),w=Math.max(w,X+F/2),C=Math.max(C,G+F/2);const L=Math.atan2(G-m,X-g),R=L<0?L+2*Math.PI:L;let z,q;const j=R*180/Math.PI,V=F/2+Pre,U=X+Math.cos(L)*V,K=G+Math.sin(L)*V;j>=337.5||j<22.5?(z=U,q=K-p.height/2):j>=22.5&&j<67.5?(z=U,q=K):j>=67.5&&j<112.5?(z=U-p.width/2,q=K):j>=112.5&&j<157.5?(z=U-p.width,q=K):j>=157.5&&j<202.5?(z=U-p.width,q=K-p.height/2):j>=202.5&&j<247.5?(z=U-p.width,q=K-p.height):j>=247.5&&j<292.5?(z=U-p.width/2,q=K-p.height):(z=U,q=K-p.height),P.push({lineLength:B,circleBigW:F,midX:X,midY:G,itemX:z,itemY:q}),_=Math.min(_,z),x=Math.min(x,q),w=Math.max(w,z+p.width+h.width+5),C=Math.max(C,q+p.height)}const O=Math.max(0,-_),$=Math.max(0,-x),S=t?y(t,{title:l,desc:c}):null,M=[],I=[],E=[],A=[],T=b.map(N=>({x:N.x+O,y:N.y+$}));for(let N=0;N<d;N++){const H=T[N],D=T[(N+1)%d],B=(N+1)%d,F=[N],{lineLength:X,circleBigW:G,midX:L,midY:R}=P[N],z=Math.max(G-20,20),q=Math.max(z*.4,16),j=He(i,F)||f,V=D.x-H.x,U=D.y-H.y,K=X,ne=V/K,J=U/K,se=UO*2+s,Z=Math.min(UO,(K-se)/2),te=Math.max(0,H.x+ne*Z),ue=Math.max(0,H.y+J*Z),re=Math.max(0,D.x-ne*Z),ee=Math.max(0,D.y-J*Z),ie=TU().x(Pe=>Math.max(0,Pe.x)).y(Pe=>Math.max(0,Pe.y)).curve(o4)([{x:te,y:ue},{x:re,y:ee}])||"",pe=`fork-arrow-${j.replace(/[^a-zA-Z0-9]/g,"")}-${N}`,he=`
|
|
114
|
+
M ${-s*.6} ${-s*.4}
|
|
115
115
|
L 0 0
|
|
116
|
-
L ${-
|
|
117
|
-
`;
|
|
116
|
+
L ${-s*.6} ${s*.4}
|
|
117
|
+
`;A.push(y("marker",{id:pe,viewBox:`${-s} ${-s*.6} ${s*1.2} ${s*1.2}`,refX:-s*.08,refY:0,markerWidth:s,markerHeight:s,orient:"auto",markerUnits:"strokeWidth",children:y("path",{d:he,fill:"none",stroke:j,strokeLinecap:"round",strokeLinejoin:"round","data-element-type":"shape"})})),E.push(y(Ce,{d:ie,stroke:j,strokeWidth:a,fill:"none",markerEnd:`url(#${pe})`,strokeLinecap:"round","data-element-type":"shape"}));const ge=L+O,fe=R+$,xe=Et({colorPrimary:j},i);E.push(y(Ze,{x:Math.max(0,ge-G/2),y:Math.max(0,fe-G/2),width:G,height:G,fill:xe.colorPrimaryBg,"data-element-type":"shape"})),E.push(y(Ze,{x:Math.max(0,ge-z/2),y:Math.max(0,fe-z/2),width:z,height:z,fill:"#ffffff"})),E.push(y(Ft,{x:Math.max(0,ge-q/2),y:Math.max(0,fe-q/2),size:q,indexes:F,fill:j}));const $e=Math.max(0,ge-h.width/2),Ie=Math.max(0,fe-h.height/2);M.push(y(Q,{indexes:[B],x:$e,y:Ie}))}for(let N=0;N<d;N++){const H=[N],D=u[N],{itemX:B,itemY:F}=P[N],X=Math.max(0,B+O),G=Math.max(0,F+$);I.push(y(n,{indexes:H,datum:D,data:r,x:X,y:G}));const L=Math.max(0,X+p.width+5),R=Math.max(0,G+p.height/2-h.height/2);M.push(y(nt,{indexes:H,x:L,y:R}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[S,k(Y,{x:0,y:0,children:[y(Ke,{children:A}),y(Y,{children:E}),y(ze,{children:I}),y(qe,{children:M})]})]})};We("sequence-circle-arrows",{component:KO,composites:["title","item"]});const Ore=100,Sre=50,$re=6,Ere="40",ZO=e=>{const{Title:t,Item:n,data:r,options:i,outerRadius:o=180,innerRadius:s=120,itemDistance:a=310,gapAngle:l=5,iconRadius:c=34,iconBgRadius:u=38,iconSize:h=36}=e,{title:f,desc:d,items:p=[]}=r,g=t?y(t,{title:f,desc:d}):null,m=Math.max(a+Ore,o+Sre),v=Math.min(a,o),b=ae(y(Q,{indexes:[0]}));if(p.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[g,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:m-20,y:v-20})})})]});const _=[],x=[],w=[],C=[],P=ae(y(n,{indexes:[0],data:r,datum:p[0]})),S=(360-p.length*l)/p.length,M=(F,X,G,L,R,z)=>{const q=R*Math.PI/180,j=z*Math.PI/180,V=F+G*Math.cos(q),U=X+G*Math.sin(q),K=F+L*Math.cos(q),ne=X+L*Math.sin(q),J=F+L*Math.cos(j),se=X+L*Math.sin(j),Z=F+G*Math.cos(j),te=X+G*Math.sin(j),ue=z-R<=180?"0":"1";return[`M ${V} ${U}`,`L ${K} ${ne}`,`A ${L} ${L} 0 ${ue} 1 ${J} ${se}`,`L ${Z} ${te}`,`A ${G} ${G} 0 ${ue} 0 ${V} ${U}`,"Z"].join(" ")},I=({centerX:F,outerRadius:X,angleRad:G,btnBounds:L})=>{const R=F+(X+20)*Math.cos(G)-L.width/2,z=v+(X+20)*Math.sin(G)-L.height/2;return{x:R,y:z}},E=$re,A=(s+o)/2,T=E/A*(180/Math.PI);p.forEach((F,X)=>{const G=[X],L=X*(S+l)+270,R=L+S,z=(L+R)/2,q=z*Math.PI/180,j=He(i,G),V=j+Ere,U=M(m,v,s,o,L,R);w.push(y(Ce,{d:U,fill:V,width:o*2,height:o*2,"data-element-type":"shape"}));const K=M(m,v,s+E,o-E,L+T,R-T);w.push(y(Ce,{d:K,fill:j,width:o*2,height:o*2,"data-element-type":"shape"}));const ne=(s+o)/2,J=m+ne*Math.cos(q),se=v+ne*Math.sin(q);C.push(y(Ze,{x:J-u,y:se-u,width:u*2,height:u*2,fill:"#ffffff","data-element-type":"shape"})),C.push(y(Ze,{x:J-c,y:se-c,width:c*2,height:c*2,fill:j,"data-element-type":"shape"})),F.icon&&C.push(y(Ft,{x:J-h/2,y:se-h/2,indexes:G,size:h,fill:"#fff"}));const Z=(z%360+360)%360,te=Z>=270||Z<=90,ue=Z>=75&&Z<=105;let re,ee="normal",oe="normal";ue?(re=Z,oe="normal",ee="center"):te?(Z>=270?re=-60+(Z-270)/90*60:re=Z/90*60,ee="normal"):(re=120+(Z-90)/180*120,ee="flipped");const ie=re*Math.PI/180,le=m+a*Math.cos(ie)-P.width/2;let pe=v+a*Math.sin(ie)-P.height/2;ue&&(pe=v+o+P.height/2),x.push(y(n,{indexes:G,datum:F,data:r,x:le,y:pe,positionH:ee,positionV:oe}));const he=a+40,ge=m+he*Math.cos(ie)-b.width/2,fe=v+he*Math.sin(ie)-b.height/2;_.push(y(nt,{indexes:G,x:ge,y:fe}));const $e=(L+S+l/2)*Math.PI/180,{x:Ie,y:Pe}=I({centerX:m,outerRadius:o,angleRad:$e,btnBounds:b});_.push(y(Q,{indexes:[X+1],x:Ie,y:Pe}))});const H=(270-l/2)*Math.PI/180,{x:D,y:B}=I({centerX:m,outerRadius:o,angleRad:H,btnBounds:b});return _.unshift(y(Q,{indexes:[0],x:D,y:B})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:70,children:[g,k(Y,{children:[y(Y,{children:w}),y(Y,{children:C}),y(ze,{children:x}),y(qe,{children:_})]})]})};We("sequence-circular",{component:ZO,composites:["title","item"]});const QO=e=>{const{Title:t,Item:n,data:r,gap:i=0,rowGap:o=0,itemsPerRow:s=3,circleStrokeWidth:a=18,options:l}=e,{title:c,desc:u,items:h=[]}=r,f=t?y(t,{title:c,desc:u}):null,d=Ot(l),p=ae(y(Q,{indexes:[0]})),g=ae(y(n,{indexes:[0],data:r,datum:h[0],positionH:"center"})),m=[],v=[],b=[],_=(o+g.height)/2,x=_;if(h.forEach((w,C)=>{const P=Math.floor(C/s),O=C%s,$=P%2===1,M=($?s-1-O:O)*(g.width+i)+x,I=P*(g.height+o),E=[C];if(v.push(y(n,{indexes:E,datum:w,data:r,x:M,y:I,positionH:"center",positionV:C%2===1?"flipped":"normal"})),m.push(y(nt,{indexes:E,x:M+(g.width-p.width)/2,y:I+g.height+10})),C===0&&m.push(y(Q,{indexes:E,x:M+(g.width-p.width)/2,y:I-p.height-10})),C<h.length-1){const A=Math.floor((C+1)/s);if(P===A)m.push(y(Q,{indexes:[C+1],x:M+(g.width-p.width)/2,y:I-p.height-10}));else{const N=I+g.height/2,H=I+g.height+o+g.height/2;let D,B,F;$?(D=M,F=0,B=`M ${D} ${N} A ${_} ${_} 0 0 ${F} ${D} ${H}`):(D=M+g.width,F=1,B=`M ${D} ${N} A ${_} ${_} 0 0 ${F} ${D} ${H}`);const X=H-N,G=He(l,E),L=He(l,[C+1]),R=`gradient-arc-${C}`;b.push(k(tt,{children:[y(Ke,{children:k("linearGradient",{id:R,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:G||d}),y("stop",{offset:"100%",stopColor:L||d})]})}),y(Ce,{d:B,stroke:`url(#${R})`,strokeWidth:a,fill:"none",width:x,height:X,"data-element-type":"shape"})]}));const z=$?D-_-p.width/2:D+_-p.width/2,q=I+g.height+o/2-p.height/2;m.push(y(Q,{indexes:[C+1],x:z,y:q}))}}}),h.length>0){const w=h.length-1,C=Math.floor(w/s),P=w%s,S=(C%2===1?s-1-P:P)*(g.width+i),M=C*(g.height+o);m.push(y(Q,{indexes:[h.length],x:S+(g.width-p.width)/2,y:M+g.height+p.height+20}))}if(h.length/s>2){const w=(o+g.height)/2,C=He(l,[0]);b.push(y(ke,{x:0,y:g.height/2-a/2,width:w,height:a,fill:C||d,"data-element-type":"shape"}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,k(Y,{width:s*g.width+(s-1)*i+_*2,height:Math.ceil(h.length/s)*(g.height+o),children:[y(Y,{children:b}),y(ze,{children:v}),y(qe,{children:m})]})]})};We("sequence-color-snake-steps",{component:QO,composites:["title","item"]});const ql=(e,t)=>e===0?0:e===1?t/2:t/2+(e-1)*(t/2*3),Hl=(e,t,n)=>{if(e)return 0;const o=t===0?2:n;return n*2+o},Mre=(e,t,n,r,i,o,s,a)=>{const l=Math.max(6,o*.15),c=r+(e-1)*i,u=e*l,h=100,d=c+u+h+50,p=d-h;let g=0,m=0,v=0,b=0;if(e>0){let x=1/0,w=-1/0;for(let A=0;A<e;A++){const T=A%2===0,N=Math.floor(A/2),H=ql(N,n),B=0+Hl(T,N,n)+H;x=Math.min(x,B-n),w=Math.max(w,B+n)}const C=(x+w)/2,P=0;g=0,b=g+t.width+a+s+n,v=b-P+C;const M=g+t.width/2,I=v-M;m=v+I-t.width/2}return{canvasHeight:d,startY:p,leftItemAlignedX:g,rightItemAlignedX:m,cylinderAreaStartX:b}},Ire=(e,t,n,r,i,o,s)=>{const a=e%2===0,l=Math.floor(e/2),c=ql(l,t),u=Hl(a,l,t),h=s+u+c,f=o-e*i,d=n+e*r,p=f-d;return{x:h,y:p,height:d,bottomY:f,topY:p}},Are=(e,t,n,r,i,o,s,a,l)=>{const c=e%2===0,u=t.topY+t.height*.05;let h,f;c?(h=i,f=h+n.width+l):(h=o,f=h-l);let d;s==="top"?d=u:s==="bottom"?d=u-n.height:d=u-n.height/2,d+=a;const p=c?t.x-r:t.x+r,g=c?p-l:p+l;return{itemPos:{x:h,y:d},lineStartX:g,lineEndX:f,lineY:u}},Tre=(e,t)=>{const n=be(t),r=[];return r.push(k("linearGradient",{id:`cylinderGradient${e}`,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:n.toRgbString(),stopOpacity:.7}),y("stop",{offset:"40%",stopColor:n.clone().lighten(5).toRgbString(),stopOpacity:.65}),y("stop",{offset:"70%",stopColor:n.clone().lighten(15).toRgbString(),stopOpacity:.6}),y("stop",{offset:"100%",stopColor:n.clone().lighten(20).toRgbString(),stopOpacity:.55})]})),r.push(k("linearGradient",{id:`topGradient${e}`,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:n.clone().lighten(15).toRgbString(),stopOpacity:1}),y("stop",{offset:"100%",stopColor:"#fafafa",stopOpacity:1})]})),r.push(k("linearGradient",{id:`bottomGradient${e}`,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:n.clone().darken(8).toRgbString(),stopOpacity:.75}),y("stop",{offset:"50%",stopColor:n.clone().darken(5).toRgbString(),stopOpacity:.7}),y("stop",{offset:"100%",stopColor:n.clone().darken(12).toRgbString(),stopOpacity:.65})]})),r.push(k("linearGradient",{id:`numberGradient${e}`,x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:n.clone().darken(0).toRgbString(),stopOpacity:.9}),y("stop",{offset:"50%",stopColor:n.clone().lighten(5).toRgbString(),stopOpacity:.85}),y("stop",{offset:"100%",stopColor:n.clone().lighten(10).toRgbString(),stopOpacity:.8})]})),r.push(k("linearGradient",{id:`glowGradient${e}`,x1:"0%",y1:"100%",x2:"0%",y2:"0%",children:[y("stop",{offset:"0%",stopColor:"#FFFFFF",stopOpacity:.2}),y("stop",{offset:"90%",stopColor:"#FFFFFF",stopOpacity:0})]})),r},Rre=(e,t,n,r)=>{const{x:i,topY:o,bottomY:s}=t,a=[];a.push(y("ellipse",{id:`cylinder-bottom-${e}`,cx:i,cy:s,rx:n,ry:r,fill:`url(#bottomGradient${e})`,opacity:.7})),a.push(y(Ce,{id:`cylinder-body-${e}`,d:`
|
|
118
118
|
M ${i-n} ${o}
|
|
119
119
|
A ${n} ${r} 0 0 0 ${i} ${o+r}
|
|
120
120
|
A ${n} ${r} 0 0 0 ${i+n} ${o}
|
|
121
|
-
L ${i+n} ${
|
|
122
|
-
A ${n} ${r} 0 0 1 ${i} ${
|
|
123
|
-
A ${n} ${r} 0 0 1 ${i-n} ${
|
|
121
|
+
L ${i+n} ${s}
|
|
122
|
+
A ${n} ${r} 0 0 1 ${i} ${s+r}
|
|
123
|
+
A ${n} ${r} 0 0 1 ${i-n} ${s}
|
|
124
124
|
Z
|
|
125
|
-
`,fill:`url(#cylinderGradient${e})`,stroke:"none"})),
|
|
126
|
-
M ${u} ${
|
|
127
|
-
L ${h} ${
|
|
128
|
-
L ${
|
|
129
|
-
L ${
|
|
125
|
+
`,fill:`url(#cylinderGradient${e})`,stroke:"none"})),a.push(y(ke,{id:`cylinder-glow-${e}`,x:i-n,y:o-r*3,width:n*2,height:r*3,fill:`url(#glowGradient${e})`})),a.push(y("ellipse",{id:`cylinder-top-${e}`,cx:i,cy:o,rx:n,ry:r,fill:`url(#topGradient${e})`}));const l=i-10,c=o-15,f=`translate(${l}, ${c}) matrix(1, 0, ${-.6}, ${.6}, 0, 0)`;return a.push(y(Ne,{id:`cylinder-number-${e}`,width:50,height:50,fontFamily:"Arial Black, sans-serif",fontSize:32,fontWeight:900,fill:`url(#numberGradient${e})`,alignHorizontal:"center",alignVertical:"middle",transform:f,children:e+1})),a},kre=(e,t,n,r,i)=>{const s=[];return s.push(y("circle",{id:`decoration-dot-start-${e}`,cx:t,cy:r,r:2,fill:i})),s.push(y("line",{id:`decoration-line-${e}`,x1:t,y1:r,x2:n,y2:r,stroke:i,strokeWidth:1,opacity:.8})),s.push(y("circle",{id:`decoration-dot-end-${e}`,cx:n,cy:r,r:2,fill:i,opacity:.9})),s},Lre=(e,t,n,r,i)=>{if(e===0)return null;const o=[];for(let x=0;x<e;x++){const w=x%2===0,C=Math.floor(x/2),P=ql(C,t),O=Hl(w,C,t),$=n+O+P,S=r-x*i;o.push({x:$,y:S})}const s=o[0],a=o[o.length-1],l=6,c=e>5?e*16:100,u=s.x-t-c,h=s.x+t+c,f=s.y+l+c/6,d=a.x-t-c,p=a.x+t+c,g=a.y+l-c/6,m=`
|
|
126
|
+
M ${u} ${f}
|
|
127
|
+
L ${h} ${f}
|
|
128
|
+
L ${p} ${g}
|
|
129
|
+
L ${d} ${g}
|
|
130
130
|
Z
|
|
131
131
|
`,v=`
|
|
132
|
-
M ${h} ${
|
|
133
|
-
L ${h} ${
|
|
134
|
-
L ${
|
|
135
|
-
L ${
|
|
132
|
+
M ${h} ${f}
|
|
133
|
+
L ${h} ${f+l}
|
|
134
|
+
L ${p} ${g+l}
|
|
135
|
+
L ${p} ${g}
|
|
136
136
|
Z
|
|
137
137
|
`,b=`
|
|
138
|
-
M ${u} ${
|
|
139
|
-
L ${h} ${
|
|
140
|
-
L ${h} ${
|
|
141
|
-
L ${u} ${
|
|
138
|
+
M ${u} ${f}
|
|
139
|
+
L ${h} ${f}
|
|
140
|
+
L ${h} ${f+l}
|
|
141
|
+
L ${u} ${f+l}
|
|
142
142
|
Z
|
|
143
|
-
`;return L(Y,{children:[p(Ke,{children:L(tt,{children:[L("linearGradient",{id:"basePlateTopGradient",x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:"#fafafa",stopOpacity:1}),p("stop",{offset:"50%",stopColor:"#ffffff",stopOpacity:.98}),p("stop",{offset:"100%",stopColor:"#ececec",stopOpacity:.95})]}),L("linearGradient",{id:"basePlateFrontGradient",x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:"#e0e0e0",stopOpacity:.95}),p("stop",{offset:"50%",stopColor:"#d2d2d2",stopOpacity:.93}),p("stop",{offset:"100%",stopColor:"#c5c5c5",stopOpacity:.9})]}),L("linearGradient",{id:"basePlateSideGradient",x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[p("stop",{offset:"0%",stopColor:"#b8b8b8",stopOpacity:.92}),p("stop",{offset:"50%",stopColor:"#c0c0c0",stopOpacity:.88}),p("stop",{offset:"100%",stopColor:"#adadad",stopOpacity:.85})]})]})}),p(Pe,{id:"base-plate-front",d:b,fill:"url(#basePlateFrontGradient)",stroke:"#c5c5c5",strokeWidth:.3,opacity:.92}),p(Pe,{id:"base-plate-side",d:v,fill:"url(#basePlateSideGradient)",stroke:"#aaaaaa",strokeWidth:.3,opacity:.88}),p(Pe,{id:"base-plate-top",d:m,fill:"url(#basePlateTopGradient)",stroke:"#e5e5e5",strokeWidth:.5,opacity:.93})]})},iC=e=>{const{Title:t,Item:n,data:r,options:i,cylinderRx:o=28,cylinderRy:a=18,baseHeight:s=120,heightIncrement:c=40,depthSpacing:l=60,itemVerticalAlign:u="top",itemVerticalOffset:h=-12,firstDecorationWidth:d=90}=e,{title:f,desc:g,items:y=[]}=r,m=t?p(t,{title:f,desc:g}):null,v=se(p(n,{indexes:[0],data:r,datum:y[0],positionH:"center"})),b=se(p(Q,{indexes:[0]})),_=wt(i),x=10,w=Math.max(6,l*.15),P=ene(y.length,v,o,s,c,l,d,x),{startY:$,leftItemAlignedX:C,rightItemAlignedX:M,cylinderAreaStartX:S}=P,E=[],A=[];y.forEach((H,k)=>{const I=qe(i,[k])||_;E.push(...rne(k,I));const R=tne(k,o,s,c,w,$,S),N=ine(k,R,o,a),{itemPos:q,lineStartX:G,lineEndX:U,lineY:K}=nne(k,R,v,o,C,M,u,h,x),oe=one(k,G,U,K,I);N.push(...oe);const te=p(n,{indexes:[k],datum:H,data:r,x:q.x,y:q.y,positionH:k%2===0?"flipped":"normal"}),ae=[p(nt,{indexes:[k],x:q.x+v.width/2-b.width/2,y:q.y+v.height+10}),p(Q,{indexes:[k],x:q.x+v.width/2-b.width/2,y:q.y-b.height-10})];A[k]={cylinderNodes:N,itemNode:te,btnNodes:ae,itemX:q.x,itemY:q.y}});let O=1/0,T=1/0,F=-1/0,z=-1/0;A.forEach(H=>{const{itemX:k,itemY:I}=H;O=Math.min(O,k),T=Math.min(T,I),F=Math.max(F,k+v.width),z=Math.max(z,I+v.height)});const j=F-O,D=z-T,W=[p(Ke,{children:E})],B=[],X=ane(y.length,o,S,$,w);X&&W.push(X);for(let H=y.length-1;H>=0;H--){const k=A[H];k&&(W.push(L(Y,{children:[p(Y,{children:k.cylinderNodes}),k.itemNode]})),B.push(...k.btnNodes))}if(y.length>0){const H=y.length%2===0,k=Math.floor(y.length/2),I=Ic(k,o),R=Ac(H,k,o),N=S+R+I,q=$-y.length*w;B.push(p(Q,{indexes:[y.length],x:N,y:q-100}))}return L(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[m,L(Y,{width:j,height:D,children:[p(Ne,{children:W}),p(He,{children:B})]})]})};We("sequence-cylinders-3d",{component:iC,composites:["title","item"]});const ot={WIDTH:160,HEIGHT:260,ARROW_HEIGHT:148,ARROW_WIDTH:100,LINE_X:100,RECT_X:0,RECT_Y:80,RECT_WIDTH:100,RECT_HEIGHT:130},Tn={SIZE:8,MAX_COUNT:40,MIN_COUNT:5,ARROW_RATIO:.6,MIN_ARROW_COUNT:3};function sne(e,t,n){return(e+t*7+n*13)%100}function cne(e){const t=Math.ceil(Math.sqrt(e*1.5)),n=Math.ceil(e/t);return{cols:t,rows:n}}function lne(e,t,n,r,i,o,a,s){const c=Math.max(i,Math.min(e+n,o)),l=Math.max(a,Math.min(t+r,s));return{x:c,y:l}}function oC({count:e,rectX:t,rectY:n,rectWidth:r,rectHeight:i,seed:o}){const a=[],s=Tn.SIZE/2,{cols:c,rows:l}=cne(e),u=(r-s*2)/(c+1),h=(i-s*2)/(l+1);let d=0;for(let f=0;f<l&&d<e;f++)for(let g=0;g<c&&d<e;g++){const y=sne(o,f,g),m=y%16-8,v=y*3%12-6,b=f%2===1?u/2:0,_=t+s+(g+1)*u+b,x=n+s+(f+1)*h,{x:w,y:P}=lne(_,x,m,v,t+s,t+r-s,n+s,n+i-s);a.push({x:w,y:P,colorIndex:d}),d++}return a}function une(e,t){if(t<=1)return Tn.MAX_COUNT;const n=e/(t-1),r=Tn.MAX_COUNT-Tn.MIN_COUNT;return Math.round(Tn.MAX_COUNT-r*n)}function hne(){const a={topLeft:{x:40,y:25},topRight:{x:160,y:75},bottomLeft:{x:40,y:205},bottomRight:{x:160,y:255}},s=[];for(let c=0;c<=12;c++){const l=c/12,u={x:a.topLeft.x+(a.bottomLeft.x-a.topLeft.x)*l,y:a.topLeft.y+(a.bottomLeft.y-a.topLeft.y)*l},h={x:a.topRight.x+(a.bottomRight.x-a.topRight.x)*l,y:a.topRight.y+(a.bottomRight.y-a.topRight.y)*l};s.push(`M${u.x} ${u.y}L${h.x} ${h.y}`);const d={x:a.topLeft.x+(a.topRight.x-a.topLeft.x)*l,y:a.topLeft.y+(a.topRight.y-a.topLeft.y)*l},f={x:a.bottomLeft.x+(a.bottomRight.x-a.bottomLeft.x)*l,y:a.bottomLeft.y+(a.bottomRight.y-a.bottomLeft.y)*l};s.push(`M${d.x} ${d.y}L${f.x} ${f.y}`)}return s.join("")}function aC(e,t){return e.map(n=>{const r=qe(t,[n.colorIndex]);return p(Pe,{d:"M4 0L8 4L4 8L0 4Z",fill:r,x:n.x,y:n.y,width:Tn.SIZE,height:Tn.SIZE,"data-element-type":"shape"})})}function dne(e,t,n,r,i){return L(Y,{x:t,y:0,width:ot.WIDTH,height:ot.HEIGHT,children:[L(xt,{children:[p(Pe,{d:hne(),stroke:"#D9D9D9",strokeWidth:2}),p(Pe,{d:`M${ot.LINE_X} 25V260`,stroke:"#BFBFBF",strokeWidth:2,strokeLinecap:"round"}),p(Re,{x:ot.RECT_X,y:ot.RECT_Y,width:ot.RECT_WIDTH,height:ot.RECT_HEIGHT,fill:"#FFCB0E",fillOpacity:.2})]}),p(tt,{children:aC(r,i)}),p(ze,{x:ot.LINE_X-25,y:0,width:50,height:20,fontSize:20,fontWeight:"bold",alignHorizontal:"center",alignVertical:"top",fill:n,children:String(e+1).padStart(2,"0")})]})}function fne(e,t){const n=ot.RECT_Y+ot.RECT_HEIGHT/2-ot.ARROW_HEIGHT/2,r=Math.max(Math.round(Tn.MIN_COUNT*Tn.ARROW_RATIO),Tn.MIN_ARROW_COUNT),i=oC({count:r,rectX:0,rectY:14,rectWidth:57,rectHeight:120,seed:999});return L(Y,{x:e+ot.WIDTH,y:n,children:[p(Pe,{d:"M0 13.9679H57.1429V0L100 74L57.1429 148V134.032H0V13.9679Z",width:ot.ARROW_WIDTH,height:ot.ARROW_HEIGHT,fill:"#FFCB0E",fillOpacity:.2,"data-element-type":"shape"}),p(tt,{children:aC(i,t)})]})}const sC=e=>{const{Title:t,Item:n,data:r,gap:i=20,options:o}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=se(p(Q,{indexes:[0]})),h=se(p(n,{indexes:[0],data:r,datum:c[0],width:ot.WIDTH,positionH:"center"})),d=[],f=[],g=[],y=ot.HEIGHT+i,m=y+h.height+10;if(c.forEach((v,b)=>{const _=b*ot.WIDTH,x=[b],w=qe(o,x),P=une(b,c.length),$=oC({count:P,rectX:ot.RECT_X,rectY:ot.RECT_Y,rectWidth:ot.RECT_WIDTH,rectHeight:ot.RECT_HEIGHT,seed:b*100});d.push(dne(b,_,w,$,o)),b===c.length-1&&d.push(fne(_,o)),f.push(p(n,{indexes:x,datum:v,data:r,width:ot.WIDTH,x:_+ot.LINE_X-ot.WIDTH/2,y,positionH:"center"})),g.push(p(nt,{indexes:x,x:_+ot.LINE_X-u.width/2,y:m})),b<c.length-1&&g.push(p(Q,{indexes:[b+1],x:_+ot.WIDTH-u.width/2,y:m}))}),c.length>0){g.unshift(p(Q,{indexes:[0],x:-u.width/2,y:m}));const v=(c.length-1)*ot.WIDTH;g.push(p(Q,{indexes:[c.length],x:v+ot.WIDTH-u.width/2,y:m}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{width:ot.WIDTH*c.length+ot.ARROW_WIDTH,height:ot.HEIGHT+i+h.height,children:[p(Y,{children:d}),p(Ne,{children:f}),p(He,{children:g})]})]})};We("sequence-filter-mesh",{component:sC,composites:["title","item"]});const Tc=e=>Math.round(e*1e10)/1e10,B1=(e,t)=>Tc(Math.sqrt((t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y))),kc=Math.PI,pne=kc*2,gne=(e,t)=>{const n=t-e;return n>kc&&n<pne||n<0&&n>-kc?-1:1},mne=(e,t,n,r,i,o)=>{const a=Math.atan2(e.y-t.y,e.x-t.x),s=Math.atan2(n.y-t.y,n.x-t.x),c=Math.acos((r*r+o*o-i*i)/(2*r*o)),l=1/Math.tan(c/2),u=gne(a,s),h=a+u*c/2;return{prev:a,next:s,main:c,vel:l,dir:u,bis:h}},W1=Math.PI,cC=(e,t,n)=>e.reduce((r,i)=>{const{x:o,y:a,angle:{prev:s,next:c},arc:{x:l,y:u,radius:h}}=i,d=i.angle.dir*-1,f=s+d*W1/2,g=(d*W1+c-s)%W1,y=n-1,m=g/y,v=[];if(!m)return r.concat({x:o,y:a});for(let b=0;b<=y;b++)v.push({x:l+Math.cos(f+m*b)*h,y:u+Math.sin(f+m*b)*h});return r.concat(v)},[]),lC=(e,t=0)=>{const n=e.length,r=[],i=[],o=[];e.forEach((c,l)=>{const u=e[(l-1+n)%n],h=e[(l+1)%n],d=B1(u,c),f=B1(u,h),g=B1(c,h),y=mne(u,c,h,d,f,g);y.main===0&&(y.main=Number.EPSILON,y.vel=Number.MAX_SAFE_INTEGER),y.main===kc&&(y.vel=0);const m={x:c.x,y:c.y,angle:y,offset:0,arc:{radius:t,hit:t,lim:Math.min(g/y.vel,d/y.vel,c.r||0)},in:{length:d,rest:d},out:{length:g,rest:g},locked:!1,id:l,get prev(){return r[(l-1+n)%n]},get next(){return r[(l+1)%n]}};isNaN(y.main)&&(y.main=0,y.bis=y.prev||y.next,o.push(m)),typeof c.r=="number"&&(c.r===0?o.push(m):i.push(m)),r.push(m)}),o.forEach(c=>{c.angle.vel=0,c.arc.radius=0,G1(c)}),r.forEach(c=>{c.arc.hit=Math.min(c.out.rest/(c.angle.vel+c.next.angle.vel),c.in.rest/(c.angle.vel+c.prev.angle.vel))});let a=Rc(i);for(;a;)yne(a),a=Rc(i);for(a=Rc(r);a;)vne(a,t),a=Rc(r);const s=r.map(c=>{const l=c.arc.radius/Math.sin(c.angle.main/2);return{id:c.id,x:c.x,y:c.y,angle:{main:Tc(c.angle.main),prev:c.angle.prev,next:c.angle.next,bis:c.angle.bis,dir:c.angle.dir},offset:Tc(c.offset),arc:{radius:Tc(c.arc.radius),x:c.x+(Math.cos(c.angle.bis)*l||0),y:c.y+(Math.sin(c.angle.bis)*l||0)},in:{length:c.in.length,x:c.x+Math.cos(c.angle.prev)*c.offset,y:c.y+Math.sin(c.angle.prev)*c.offset},out:{length:c.out.length,x:c.x+Math.cos(c.angle.next)*c.offset,y:c.y+Math.sin(c.angle.next)*c.offset},get prev(){return s[(c.id-1+n)%n]},get next(){return s[(c.id+1)%n]}}});return s},yne=e=>{const{prev:t,next:n}=e;t.locked&&!n.locked?e.arc.radius=Math.min(Math.max((e.out.length-n.arc.lim*n.angle.vel)/e.angle.vel,e.out.length/(e.angle.vel+n.angle.vel)),e.in.rest/e.angle.vel,e.arc.lim):n.locked&&!t.locked?e.arc.radius=Math.min(Math.max((e.in.length-t.arc.lim*t.angle.vel)/e.angle.vel,e.in.length/(e.angle.vel+t.angle.vel)),e.out.rest/e.angle.vel,e.arc.lim):n.locked&&t.locked?e.arc.radius=Math.min(e.in.rest/e.angle.vel,e.out.rest/e.angle.vel,e.arc.lim):e.arc.radius=Math.min(Math.max((e.in.length-t.arc.lim*t.angle.vel)/e.angle.vel,e.in.length/(e.angle.vel+t.angle.vel)),Math.max((e.out.length-n.arc.lim*n.angle.vel)/e.angle.vel,e.out.length/(e.angle.vel+n.angle.vel)),e.arc.lim),G1(e)},vne=(e,t)=>{if(t>e.arc.hit){const{prev:n,next:r}=e;n.locked&&!r.locked?e.arc.radius=Math.max(Math.min(e.in.rest/e.angle.vel,e.out.length/(e.angle.vel+r.angle.vel),e.arc.radius),0):r.locked&&!n.locked?e.arc.radius=Math.max(Math.min(e.out.rest/e.angle.vel,e.in.length/(e.angle.vel+n.angle.vel),e.arc.radius),0):r.locked&&n.locked?e.arc.radius=Math.max(Math.min(e.in.rest/e.angle.vel,e.out.rest/e.angle.vel,e.arc.radius),0):e.arc.radius=e.arc.hit}G1(e)},G1=e=>{const{prev:t,next:n}=e;e.offset=e.arc.radius*e.angle.vel,t.out.rest-=e.offset,e.in.rest-=e.offset,e.out.rest-=e.offset,n.in.rest-=e.offset,e.locked=!0,t.arc.hit=Math.min(t.in.length/(t.angle.vel+t.prev.angle.vel),t.in.rest/t.angle.vel,t.out.rest/t.angle.vel),n.arc.hit=Math.min(n.out.length/(n.angle.vel+n.next.angle.vel),n.out.rest/n.angle.vel,n.in.rest/n.angle.vel)},Rc=e=>e.reduce((t,n)=>n.locked?t:t?n.arc.hit<t.arc.hit?n:t:n,null),bne=6,V1=32,_ne=1.25,Y1=25,uC=15,hC=e=>{const{Title:t,Item:n,data:r,gap:i=10,width:o=700,funnelWidth:a,itemHeight:s=60,minBottomRatio:c=.25,options:l}=e,{title:u,desc:h,items:d=[]}=r,f=t?p(t,{title:u,desc:h}):null;if(d.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:f});const g=Ct(l.themeConfig),y=a!=null?a:o*.55,m=o-y,v=s*_ne,b=d.length*v+(d.length-1)*i,_=y*c,x=d.map((P,$)=>{const C=[$],M=qe(l,[$])||g.colorPrimary,{points:S,topWidth:E}=xne(y,_,v,i,b,$),A=lC(S,bne),O=cC(A,"AMOUNT",10),T=y/2,F=$*(v+i),z=T+E/2,j=z-Y1,D=m+Y1-10,W=(v-s)/2,B=F+W,X=z+uC,H=D-Y1-uC,k=B,I=T-V1/2,R=F+v/2-V1/2,N=`${M.replace("#","")}-funnel-${$}`;return{background:p(Re,{x:j,y:B,width:D,height:s,ry:"8",fill:be(M).setAlpha(.1).toRgbString(),"data-element-type":"shape"}),funnel:[p(Ke,{children:L("linearGradient",{id:N,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p("stop",{offset:"0%",stopColor:be(M).lighten(10).toString()}),p("stop",{offset:"100%",stopColor:M})]})}),p(Wt,{points:O,fill:`url(#${N})`,y:F,"data-element-type":"shape",style:{filter:"drop-shadow(0px 2px 3px rgba(0,0,0,0.15))"}})],icon:p(Ht,{indexes:C,x:I,y:R,size:V1,fill:"#fff"}),item:p(n,{indexes:C,datum:P,data:r,x:X,y:k,width:H,height:s,positionV:"middle"}),btnRemove:p(nt,{indexes:C,x:j+D,y:B})}}),w=p(Q,{indexes:[d.length],x:o/2,y:b+10});return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,L(Y,{width:o,height:b+40,children:[p(Y,{children:x.map(P=>P.background)}),p(Y,{children:x.flatMap(P=>P.funnel)}),p(Y,{children:x.map(P=>P.icon)}),p(Ne,{children:x.map(P=>P.item)}),L(He,{children:[x.map(P=>P.btnRemove),w]})]})]})};function xne(e,t,n,r,i,o){const a=e/2,s=o*(n+r),c=s+n,l=e-t,u=e-l*(s/i),h=e-l*(c/i),d={x:a-u/2,y:0},f={x:a+u/2,y:0},g={x:a+h/2,y:n},y={x:a-h/2,y:n};return{points:[d,f,g,y],topWidth:u,bottomWidth:h}}We("sequence-funnel",{component:hC,composites:["title","item"]});const dC=e=>{const{Title:t,Item:n,data:r,gap:i=30,cardPadding:o=10,options:a}=e,{title:s,desc:c,items:l=[]}=r,u=t?p(t,{title:s,desc:c}):null,h=wt(a),d=Ct({colorPrimary:h},a),f=se(p(Q,{indexes:[0]})),g=se(p(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),y=[],m=[],v=[],b=g.width+o*2,_=g.height+o*2+30,x=8,w=6,P=Math.max(f.height+20,40),$=40;if(l.forEach((C,M)=>{const S=M%2===0,E=M*(b+i);let A;S?M%4===2?A=P:A=P+$:A=P+$+60;const O=[M],T=qe(a,O)||h;if(S){const D=T===h?d.colorPrimaryBg||"#E8F3FF":`${T}20`,W=p(Re,{x:E,y:A,width:b,height:_,fill:D,rx:20,ry:20});v.push(W)}m.push(p(n,{indexes:O,datum:C,data:r,x:E+o,y:A+o,positionH:"center",positionV:"normal"}));const F=l.length*x+(l.length-1)*w,z=E+(b-F)/2,j=A+g.height+20;for(let D=0;D<l.length;D++){const W=z+D*(x+w),B=D===M;v.push(p(Ze,{x:W,y:j,width:x,height:x,fill:B?T:"transparent",stroke:T,strokeWidth:2}))}y.push(p(nt,{indexes:O,x:E+(b-f.width)/2,y:A+_+10})),M===0?y.push(p(Q,{indexes:O,x:E+(b-f.width)/2,y:A-f.height-10})):y.push(p(Q,{indexes:O,x:E-i/2-f.width/2,y:P-f.height-10}))}),l.length>0){const C=[],S=i/2,E=6,A=P+$,O=0-S,T=A+_/2;C.push(`M ${O} ${T-E}`),l.forEach((N,q)=>{const G=q%2===0,U=q*(b+i);let K;G?q%4===2?K=P:K=P+$:K=P+$+60;const oe=U-S,te=U+b+S,ae=K-S,Z=K+_+S,ee=K+_/2;G?(C.push(`L ${oe} ${ae+35}`),C.push(`Q ${oe} ${ae} ${oe+35} ${ae}`),C.push(`L ${te-35} ${ae}`),C.push(`Q ${te} ${ae} ${te} ${ae+35}`),C.push(`L ${te} ${ee-E}`)):(C.push(`L ${oe} ${ee}`),C.push(`L ${oe} ${Z-35}`),C.push(`Q ${oe} ${Z} ${oe+35} ${Z}`),C.push(`L ${te-35} ${Z}`),C.push(`Q ${te} ${Z} ${te} ${Z-35}`),C.push(`L ${te} ${ee+E}`))});const F=l.length-1,z=F%2===0,j=F*(b+i);let D;z?F%4===2?D=P:D=P+$:D=P+$+60;const W=j+b+S,B=D+_/2,X=C.join(" "),H="gradient-zigzag-path",k=qe(a,[0])||h,I=qe(a,[l.length-1])||h,R=l.map((N,q)=>{const G=q/(l.length-1)*100,U=qe(a,[q])||h;return p("stop",{offset:`${G}%`,stopColor:U})});v.unshift(L(tt,{children:[p(Ke,{children:p("linearGradient",{id:H,x1:O,y1:T,x2:W,y2:B,gradientUnits:"userSpaceOnUse",children:R})}),p(Pe,{d:X,stroke:`url(#${H})`,strokeWidth:2,fill:"none",width:(l.length-1)*(b+i)+b+S*2,height:_+120})]})),v.unshift(p(Ze,{x:O-E,y:T-E,width:E*2,height:E*2,fill:"transparent",stroke:k,strokeWidth:2})),v.unshift(p(Ze,{x:W-E,y:B-E,width:E*2,height:E*2,fill:"transparent",stroke:I,strokeWidth:2}))}if(l.length>0){const M=(l.length-1)*(b+i);y.push(p(Q,{indexes:[l.length],x:M+b+(i-f.width)/2,y:P-f.height-10}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,L(Y,{children:[p(xt,{children:v}),p(Ne,{children:m}),p(He,{children:y})]})]})};We("sequence-horizontal-zigzag",{component:dC,composites:["title","item"]});var wne=Object.defineProperty,Pne=Object.defineProperties,$ne=Object.getOwnPropertyDescriptors,fC=Object.getOwnPropertySymbols,Cne=Object.prototype.hasOwnProperty,One=Object.prototype.propertyIsEnumerable,pC=(e,t,n)=>t in e?wne(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Lc=(e,t)=>{for(var n in t||(t={}))Cne.call(t,n)&&pC(e,n,t[n]);if(fC)for(var n of fC(t))One.call(t,n)&&pC(e,n,t[n]);return e},zc=(e,t)=>Pne(e,$ne(t));function Sne(e){const{width:t,height:n,colorPrimary:r}=e,i=r,o=be.mix(r,"#000",20).toHexString(),a=be.mix(r,"#fff",50).toHexString(),s=be.mix(a,"#000",15).toHexString();function c($,C){const S=[{position:.25,offset:.1},{position:.45,offset:-.02},{position:.6,offset:.04},{position:.75,offset:-.1}],E={x:0,y:C},A={x:$,y:C},O={x:$/2,y:0},T={x:$/2,y:C},F=C*.35,z=F/C,j={x:O.x*(1-z)+E.x*z,y:F},D={x:O.x,y:F},W={x:O.x*(1-z)+A.x*z,y:F},B=S.map(k=>{const I=j.x+(W.x-j.x)*k.position,R=F,N=C*k.offset;return{x:I,y:R+N,position:k.position,offset:k.offset}});B.sort((k,I)=>k.position-I.position);const X=B.filter(k=>k.x<=D.x),H=B.filter(k=>k.x>D.x);return{leftBottom:E,rightBottom:A,peak:O,centerBottom:T,snowLineY:F,leftEdge:j,centerSnow:D,rightEdge:W,leftRipples:X,rightRipples:H}}const{leftRipples:l,rightRipples:u,leftBottom:h,rightBottom:d,peak:f,centerBottom:g,leftEdge:y,centerSnow:m,rightEdge:v}=c(t,n),b=[f,y,...l,m],_=[f,m,...u,v],x=[y,...l,m,g,h],w=[m,...u,v,d,g],P=$=>$.map(C=>`${C.x},${C.y}`).join(" ");return L(xt,zc(Lc({},e),{children:[p("polygon",{points:P(b),fill:a}),p("polygon",{points:P(_),fill:s}),p("polygon",{points:P(x),fill:i}),p("polygon",{points:P(w),fill:o})]}))}function Mne(e){const n={tiny:27,small:48,medium:54,large:72}[e]||54,r="#17C76F",i="#139B57",o="#737373",a=n*.7,s=n-a,c=a*.8,l=c,u=l/6,h=(l-u)/2,d=a;return L(xt,{width:l,height:n,children:[p("ellipse",{cx:c/2,cy:a/2,rx:c/2,ry:a/2,fill:r,clipPath:"inset(0 50% 0 0)"}),p("ellipse",{cx:c/2,cy:a/2,rx:c/2,ry:a/2,fill:i,clipPath:"inset(0 0 0 50%)"}),p("rect",{x:h,y:d,width:u,height:s,fill:o})]})}function Ene(e){const{width:t,height:n}=e,r=t/2,i=n/2,o=Math.min(t,n)*.28,a=Math.min(t,n)*.14,s=Math.min(t,n)*.07,c=0,l=i-s/2,u=s*.4,h=8,d=Array.from({length:h},(f,g)=>{const y=360/h*g;return p("rect",{x:c,y:l,width:a,height:s,rx:u,ry:u,fill:"#FFCB0E",transform:`rotate(${y}, ${r}, ${i})`})});return L(xt,zc(Lc({},e),{children:[p("circle",{cx:r,cy:i,r:o,fill:"#FFCB0E"}),...d]}))}function Ine(e){return e.type==="single"?p(xt,zc(Lc({},e),{width:54,height:36,children:p("path",{d:"M10.2635 13.3806C11.0019 9.99045 12.7381 6.91002 15.2405 4.55004C17.743 2.19007 20.8929 0.662716 24.2701 0.171643C27.6473 -0.31943 31.0914 0.24912 34.143 1.80148C37.1946 3.35385 39.7087 5.81625 41.3501 8.86031C44.8835 9.0468 48.1994 10.6544 50.5684 13.3294C52.9373 16.0044 54.1653 19.5277 53.9821 23.1242C53.7989 26.7207 52.2195 30.0959 49.5914 32.5071C46.9634 34.9184 43.5019 36.1683 39.9684 35.9818H11.1517C4.93436 35.9818 0 30.9593 0 24.6309C0.0598447 21.8016 1.13799 19.093 3.02989 17.0192C4.9218 14.9454 7.49584 13.6506 10.2635 13.3806Z",fill:"#70CAF8"})})):L(xt,zc(Lc({},e),{width:73,height:40,children:[p("path",{d:"M61.6461 14.9716C60.8681 11.1875 58.9581 7.73823 56.1763 5.09315C53.3944 2.44806 49.8758 0.735682 46.0992 0.189041C42.3226 -0.357601 38.4714 0.288046 35.0699 2.03812C31.6683 3.7882 28.8815 6.5577 27.0889 9.96971C23.161 10.1687 19.4719 11.9405 16.8333 14.8953C14.1947 17.8502 12.8227 21.746 13.0191 25.7258C13.2155 29.7055 14.9642 33.4433 17.8806 36.1167C20.7969 38.7901 24.642 40.1802 28.5699 39.9812H60.6588C67.5702 39.9812 73.0006 34.4791 73.0006 27.4764C73.0006 20.9739 67.8664 15.4718 61.6461 14.9716Z",fill:"#70CAF8"}),p("path",{d:"M21.9691 6.47136e-09C25.9369 6.47136e-09 29.5264 1.62125 32.0003 4.21094C30.0604 5.7917 28.4423 7.75571 27.2581 10C23.3149 10.1989 19.6111 11.9702 16.9622 14.9238C14.3136 17.8774 12.936 21.772 13.1331 25.75C13.2057 27.2131 13.4902 28.6432 13.9652 30H10.7689C7.96116 29.8907 5.29664 28.7203 3.30402 26.7217C1.31144 24.7231 0.135825 22.0419 0.0110544 19.21C-0.113702 16.378 0.821178 13.6017 2.63019 11.4326C4.43921 9.26356 6.99065 7.8602 9.77766 7.5C11.9582 3.00012 16.6168 8.76701e-05 21.9691 6.47136e-09Z",fill:"#5BA2C6"})]}))}const gC=e=>{const{Title:t,Item:n,data:r,gap:i=20,minHeight:o=100,maxHeight:a=200,minWidth:s=260,maxWidth:c=300,options:l}=e,{title:u,desc:h,items:d=[]}=r,f=t?p(t,{title:u,desc:h}):null,g=[],y=[],m=[],v=[],b=d.length,_=Ct(l.themeConfig),x=60,w={single:{width:54,height:36},double:{width:73,height:40}},P=[],$=[];let C=0,M=0;d.forEach((B,X)=>{const H=b>1?X/(b-1):0,I=(o+(a-o)*H)*1.6,R=Math.max(s,Math.min(c,I));P.push(R);const N=M;$.push(N),M+=R/2,X===b-1&&(C=N+R)});const S=$[0],E=$[b-1]+P[b-1],A=E-S,O=b>1?(A-i*(b-1))/b:A,T=se(p(n,{indexes:[0],data:r,datum:d[0],width:O})),F=32,z=a+i,j=z+F+10;d.forEach((B,X)=>{const H=[X],k=o+(a-o)*(b>1?X/(b-1):0),I=P[X],R=$[X],N=a-k,q=qe(l,[X])||_.colorPrimary;m.push(p(Sne,{colorPrimary:q,x:R,y:N,width:I,height:k}));const G=S+X*(O+i);v.push(p(ze,{x:G,y:z,width:O,height:F,fontSize:16,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:q,backgroundColor:q,backgroundOpacity:.5,backgroundRadius:4,children:String(X+1).padStart(2,"0")})),g.push(p(n,{indexes:H,datum:B,data:r,x:G,y:j,width:O}))});const D=se(p(Q,{indexes:[0]})),W=j+T.height+10;if(d.forEach((B,X)=>{const H=[X],k=S+X*(O+i);y.push(p(nt,{indexes:H,x:k+O/2-D.width/2,y:W})),X<d.length-1&&y.push(p(Q,{indexes:[X+1],x:k+O+i/2-D.width/2,y:W}))}),b>0){const B=S;y.unshift(p(Q,{indexes:[0],x:B-i/2-D.width/2,y:W}));const X=S+(b-1)*(O+i);y.push(p(Q,{indexes:[b],x:X+O+i/2-D.width/2,y:W})),m.push(p(Ene,{x:C-x-20,y:-35,width:x,height:x}));const H=["tiny","small","medium","large"],k={tiny:27,small:48,medium:54,large:72},I={tiny:14.85,small:26.4,medium:29.7,large:39.6},R=[],N=(G,U,K=5)=>R.some(oe=>!(G+U+K<oe.x||G>oe.x+oe.width+K));d.forEach((G,U)=>{const K=$[U],oe=P[U],ae=U===b-1?3:U===0?1:2;for(let Z=0;Z<ae;Z++){const ee=U*100+Z*37,ue=ee*17%H.length,ne=H[ue],J=k[ne],ie=I[ne];let re=0,ce=0,pe=!1;for(;re<20&&!pe;){const he=(ee*13+re*19)%100/100,ge=K+oe*.15,de=K+oe*.85-ie;ce=ge+(de-ge)*he,N(ce,ie)||(pe=!0),re++}if(pe){R.push({x:ce,width:ie});const he=a-J;m.push(p(Y,{x:ce,y:he,children:Mne(ne)}))}}});const q=Math.max(1,Math.floor(b/1.5));for(let G=0;G<q;G++){const U=G*11+b*5+1,K=U%2===0?"single":"double",oe=w[K],te=E-S-oe.width,ae=S+U*7%100/100*te,Z=U*13%40;m.push(p(Ine,{type:K,x:ae,y:Z,width:oe.width,height:oe.height}))}}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,L(Y,{children:[p(Y,{children:m}),p(Y,{children:v}),p(Ne,{children:g}),p(He,{children:y})]})]})};We("sequence-mountain",{component:gC,composites:["title","item"]});const mC=e=>{const{Title:t,Item:n,data:r,gap:i=10,width:o=700,pyramidWidth:a,itemHeight:s=60,options:c}=e,{title:l,desc:u,items:h=[]}=r,d=t?p(t,{title:l,desc:u}):null;if(h.length===0)return p(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:d});const f=5,g=Ct(c.themeConfig),y=30,m=[],v=[],b=[],_=[],x=a!=null?a:o*.6,w=o-x,P=s*1.2,$=h.length*P+(h.length-1)*i;return h.forEach((C,M)=>{const S=[M],E=M===0,A=qe(c,[M])||g.colorPrimary,{points:O,topWidth:T,bottomWidth:F}=Ane(x,P,i,h.length,M),z=lC(O,f),j=cC(z,"AMOUNT",10),D=x/2,W=M*(P+i),B=(P-s)/2,X=W+B,H=D+T/2,k=D+F/2,R=H-f,N=w+f,q=s,G=R+N,U=D-y/2,K=W+P/2-y/2+(E?8:0),oe=k,te=G-k,ae=X;b.push(p(Re,{x:R,y:X,width:N,height:q,ry:"10",fill:g.colorPrimaryBg,"data-element-type":"shape"}));const Z=`${A}-pyramid-${M}`;v.push(p(Ke,{children:L("linearGradient",{id:Z,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[p("stop",{offset:"0","stop-color":A}),p("stop",{offset:"100%","stop-color":be.mix(A,"#fff",40).toHexString()})]})}),p(Wt,{points:j,fill:`url(#${Z})`,y:W,"data-element-type":"shape"})),_.push(p(Ht,{indexes:S,x:U,y:K,size:y,fill:"#fff"})),m.push(p(n,{indexes:S,datum:C,data:r,x:oe,y:ae,width:te,height:s,positionV:"middle"}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,L(Y,{width:o,height:$,children:[p(Y,{children:b}),p(Y,{children:v}),p(Y,{children:_}),p(Ne,{children:m}),p(He,{})]})]})};function Ane(e,t,n,r,i){const o=e/2,a=r*t+(r-1)*n,s=i*(t+n),c=s+t,l=s/a*e,u=c/a*e;let h;if(i===0){const d={x:o,y:0},f={x:o+u/2,y:t},g={x:o-u/2,y:t};h=[d,f,g]}else{const d={x:o+l/2,y:0},f={x:o+u/2,y:t},g={x:o-u/2,y:t},y={x:o-l/2,y:0};h=[d,f,g,y]}return{points:h,topWidth:l,bottomWidth:u}}We("sequence-pyramid",{component:mC,composites:["title","item"]});const Uo={iconSize:50,roadWidth:24,outerRadius:60,rowWidth:400,spacing:30,colorDefault:"#666666"},yC=(e,t)=>`M ${e} ${t}`,yt=(e,t)=>`L ${e} ${t}`,Ri=(e,t,n,r)=>`A ${e} ${e} 0 0 ${t} ${n} ${r}`,Tne=(e,{roadWidth:t,innerRadius:n,outerRadius:r})=>{const i=(t+n*2)*e;return{y1:i,y2:i+t,y3:i+t+n,y4:i+t+n*2,y5:i+r*2}};function kne({i:e,direction:t,x:n,y:r,color:i,data:o,itemBounds:a,item:s,Item:c,flipped:l}){const{iconSize:u}=Uo,h=t==="left",d=h?n.x4-u/2:n.x3-u/2,f=r.y3-u/2,g=h?n.x6+Uo.spacing:n.x1-Uo.spacing-a.width,y=r.y3-a.height/2,m=h?l?"flipped":"normal":l?"normal":"flipped";return{icon:p(kr,{indexes:[e],x:d,y:f,size:u,fill:i}),label:p(ze,{width:40,x:h?d-50:d+u+10,y:f+u/2-15,fontSize:30,fill:i,alignHorizontal:h?"right":"left",children:String(e+1).padStart(2,"0")}),item:p(c,{indexes:[e],data:o,datum:s,x:g,y,positionH:m})}}function Rne({direction:e,x:t,y:n,color:r,elements:i}){const o=e==="left";i.push(p(Fte,{x:o?t.x6+10:t.x1-20,y:n.y3-5,width:10,height:8,rotation:o?90:-90,colorPrimary:r,"data-element-type":"shape"}))}const vC=e=>{const{Title:t,Item:n,data:r,spacing:i=Uo.spacing,options:o,flipped:a=!1}=e,{title:s,desc:c,items:l=[]}=r,u=t?p(t,{title:s,desc:c}):null,h=se(p(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),{roadWidth:d,outerRadius:f,rowWidth:g,colorDefault:y}=Uo,m=d/2,v=f-d,b=(h.width+i)*2+g,_=h.width+i,x=_+f,w=_+g-f,$=w+v+d,C=_+g/2,M=[],S=[],E=[],A=[],O=[],T=[],F=[];for(let D=0;D<l.length;D++){const W=qe(o,[D])||y,B=D%2===0?"right":"left",X=D===0,H=D===l.length-1,k=Tne(D,{roadWidth:d,innerRadius:v,outerRadius:f});if(B==="right"){const q=X?[$,k.y1]:[w,k.y1],G=[x,k.y1],U=[x,k.y5],K=X?[$,k.y2]:[w,k.y2],oe=[x,k.y2];if(M.push(X?yC($,k.y1+m):yt(w,k.y1+m),yt(x,k.y1+m),Ri(f-m,0,x,k.y4+m)),S.push(X?yC(...q):yt(...q),yt(...G),Ri(f,0,...U)),E.push(yt(...K),yt(...oe),Ri(v,1,...oe)),H){const te=d/2;S.push(yt(C,k.y5),yt(C,k.y5+te),yt(C+d,k.y5-te),yt(C,k.y4-te),yt(C,k.y4),yt(x,k.y4)),M.push(yt(C,k.y4+m))}}else{const q=[x,k.y2],G=[w,k.y2],U=[w,k.y4],K=[x,k.y1],oe=[w,k.y1];if(M.push(yt(w,k.y1+m),Ri(f-m,1,w,k.y4+m)),S.push(yt(...q),yt(...G),Ri(v,1,...U)),E.push(yt(...K),yt(...oe),Ri(f,0,...oe)),H){const te=d/2;S.push(yt(C,k.y4),yt(C,k.y4-te),yt(C-d,k.y4+te),yt(C,k.y5+te),yt(C,k.y5),yt(w,k.y5)),M.push(yt(C,k.y4+m))}}Rne({direction:B,x:{x1:_,x6:$},y:k,color:W,elements:F});const{icon:I,label:R,item:N}=kne({i:D,direction:B,x:{x1:_,x3:x,x4:w,x6:$},y:k,color:W,data:r,itemBounds:h,item:l[D],Item:n,flipped:a});A.push(I),O.push(R),T.push(N)}const z=[...S,...E.reverse(),"Z"],j=l.length*(d+v*2)+d*1.5;return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,L(Y,{width:b,height:h.height<=f*2?j:j+h.height-f*2,children:[p(Pe,{width:g,height:j,d:z.join(" "),fill:y,stroke:y,strokeWidth:"4",strokeLinecap:"round",strokeLinejoin:"round","data-element-type":"shape"}),p(Pe,{d:M.join(" "),stroke:"white",fill:"none",strokeWidth:"3",strokeDasharray:"8 8",strokeLinecap:"round",strokeLinejoin:"round","data-element-type":"shape"}),L(tt,{children:[A,O,T,F]})]})]})};We("sequence-roadmap-vertical",{component:vC,composites:["title","item"]});const bC=e=>{const{Title:t,Item:n,data:r,gap:i=40,itemsPerRow:o=3,rowGap:a=80,options:s}=e,{title:c,desc:l,items:u=[]}=r,h=t?p(t,{title:c,desc:l}):null,d=wt(s),f=se(p(Q,{indexes:[0]})),g=se(p(n,{indexes:[0],data:r,datum:u[0],positionH:"center"})),y=[],m=[],v=[],b=25,_=25;if(u.forEach((x,w)=>{const P=Math.floor(w/o),$=w%o,C=P%2===1,S=(C?o-1-$:$)*(g.width+i),E=P*(g.height+a),A=[w];if(m.push(p(n,{indexes:A,datum:x,data:r,x:S,y:E,positionH:"center"})),y.push(p(nt,{indexes:A,x:S+(g.width-f.width)/2,y:E+g.height+10})),w===0&&y.push(p(Q,{indexes:A,x:S+(g.width-f.width)/2,y:E-f.height-10})),w<u.length-1){const O=Math.floor((w+1)/o),T=(w+1)%o,j=(O%2===1?o-1-T:T)*(g.width+i);if(P===O){const W=C,B=W?j+g.width+(i-b)/2:S+g.width+(i-b)/2,X=E+g.height/2-_/2;v.push(p(F1,{x:B,y:X,width:b,height:_,colorPrimary:d,rotation:W?180:0})),y.push(p(Q,{indexes:[w+1],x:B+(b-f.width)/2,y:E-f.height-10}))}else{const W=S+g.width/2-b/2,B=E+g.height+(a-_)/2;v.push(p(F1,{x:W,y:B,width:b,height:_,colorPrimary:d,rotation:90})),y.push(p(Q,{indexes:[w+1],x:W+(b-f.width)/2,y:B+(_-f.height)/2}))}}}),u.length>0){const x=u.length-1,w=Math.floor(x/o),P=x%o,M=(w%2===1?o-1-P:P)*(g.width+i),S=w*(g.height+a);y.push(p(Q,{indexes:[u.length],x:M+(g.width-f.width)/2,y:S+g.height+f.height+20}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[h,L(Y,{children:[p(Y,{children:v}),p(Ne,{children:m}),p(He,{children:y})]})]})};We("sequence-snake-steps",{component:bC,composites:["title","item"]});const _C=e=>{const{Title:t,Item:n,data:r,options:i,gap:o=16,perspectiveFactor:a=.2,width:s=720}=e,{title:c,desc:l,items:u=[]}=r,h=t,d=h?p(h,{title:c,desc:l}):null;if(u.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const f=wt(i),g=se(p(Q,{indexes:[0]})),y=se(p(n,{indexes:[0],data:r,datum:u[0]||{},positionH:"center"})),m=12,v=Math.min(s*.1,100),b=Math.min(s*.45,Math.max(80,s-y.width-m-v)),_=Math.max(24,b*a*.35),x=56,w=x*.7,P=u.length>1?(x-w)/(u.length-1):0,$=Math.max(g.height+_+20,_+28),C=b/2,M=b+v+m,S=u.map((ue,ne)=>x-P*ne),E=u.map((ue,ne)=>Math.max(_*(1-ne*.05),_*.7)),A=[],O=[],T=u.length-1;A[T]=$,O[T]=0;for(let ue=T-1;ue>=0;ue-=1)O[ue]=O[ue+1]+E[ue]+o,A[ue]=A[ue+1]+E[ue]+S[ue+1]+o;const F=O[0]||E[0]||_,z=b*(.55+a*.1),j=b-z,D=u.map((ue,ne)=>{const J=F===0?1:O[ne]/F;return z+j*J}),W=D.map(ue=>{const ne=C+ue/2;return Math.max(0,M-m-ne)}),B=[],X=[],H=[],k=[],I=[],R=0,N=(A[0]||$)+(S[0]||x),q=N-R,G=35,K=(D[T]||z)*.8,oe=K*.65,te=(D[0]||b)*.9;I.push(p(Wt,{points:[{x:C,y:R},{x:C+K/2,y:R+G},{x:C+oe/2,y:R+G},{x:C+te/2,y:N},{x:C-te/2,y:N},{x:C-oe/2,y:R+G},{x:C-K/2,y:R+G}],fill:"rgba(0,0,0,0.12)",width:te,height:q,"data-element-type":"shape"}));let ae=A[T]+S[T]/2;u.forEach((ue,ne)=>{const J=[ne],ie=D[ne],re=E[ne],ce=C-ie/2,pe=S[ne],he=A[ne],ge=he-re,de=he+pe/2,we=qe(i,J)||f;B.push(p(Re,{x:ce,y:he,width:ie,height:pe,fill:we,"data-element-type":"shape"}),p(Wt,{points:[{x:ce,y:he},{x:ce+ie,y:he},{x:ce+ie-re/2,y:ge},{x:ce+re/2,y:ge}],fill:we,opacity:"0.3",width:ie,height:re,"data-element-type":"shape"}),p(ze,{x:ce,y:he,width:ie,height:pe,fontSize:pe/2,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:"#ffffff",children:String(ne+1).padStart(2,"0")}));const Se=ce+ie,Ie=de,$e=W[ne],Le=Se+$e;k.push(p(Pe,{d:`M ${Se} ${Ie} L ${Le} ${Ie}`,stroke:we,strokeWidth:2,fill:"none",width:$e,height:2,"data-element-type":"shape"}),p(Pe,{d:`M ${Le} ${Ie} L ${Le} ${Ie}`,stroke:we,strokeWidth:6,strokeLinecap:"round",width:1,height:1,"data-element-type":"shape"}));const je=de-y.height/2;X.push(p(n,{indexes:J,datum:ue,data:r,x:M,y:je,positionV:"middle"})),H.push(p(nt,{indexes:J,x:M+y.width+10,y:je+y.height/2-g.height/2})),ne===0?H.push(p(Q,{indexes:[0],x:M+(y.width-g.width)/2,y:je-g.height-12})):H.push(p(Q,{indexes:J,x:M+(y.width-g.width)/2,y:(ae+de)/2-g.height/2})),ae=de});const ee=ae-y.height/2;return H.push(p(Q,{indexes:[u.length],x:M+(y.width-g.width)/2,y:ee+y.height+12})),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,L(Y,{children:[p(Y,{children:I}),p(Y,{children:B}),p(Y,{children:k}),p(Ne,{children:X}),p(He,{children:H})]})]})};We("sequence-stairs-front",{component:_C,composites:["title","item"]});const xC=e=>{const{Title:t,Item:n,data:r,gap:i=40,options:o}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=wt(o),h=se(p(Q,{indexes:[0]})),d=se(p(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),f=[],g=[],y=[],m=25,v=25,b=Math.max(h.height+20,30);if(c.forEach((_,x)=>{const w=x*(d.width+i),P=[x];if(g.push(p(n,{indexes:P,datum:_,data:r,x:w,y:b,positionH:"center"})),f.push(p(nt,{indexes:P,x:w+(d.width-h.width)/2,y:b+d.height+10})),x===0?f.push(p(Q,{indexes:P,x:w+(d.width-h.width)/2,y:b-h.height-10})):f.push(p(Q,{indexes:P,x:w-i/2-h.width/2,y:b-h.height-10})),x<c.length-1){const $=w+d.width+(i-m)/2,C=b+d.height/2-v/2;y.push(p(F1,{x:$,y:C,width:m,height:v,colorPrimary:u}))}}),c.length>0){const _=(c.length-1)*(d.width+i);f.push(p(Q,{indexes:[c.length],x:_+d.width+(i-h.width)/2,y:b-h.height-10}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(Y,{children:y}),p(Ne,{children:g}),p(He,{children:f})]})]})};We("sequence-steps",{component:xC,composites:["title","item"]});const wC=e=>{const{Title:t,Item:n,data:r,gap:i=10,options:o}=e,{title:a,desc:s,items:c=[]}=r,l=t?p(t,{title:a,desc:s}):null,u=wt(o),h=e3(o),d=se(p(Q,{indexes:[0]})),f=se(p(n,{indexes:[0],data:r,datum:c[0],positionH:"normal"})),g=[],y=[],m=[],v=10,b=v+70+10,_=b+30,x=6;if(c.length>1){const w=f.height/2+x,P=(c.length-1)*(f.height+i)+f.height/2-x,$=`M ${b} ${w} L ${b} ${P}`,C="gradient-timeline-line",M=P-w,S=c.map((E,A)=>{const T=(A*(f.height+i)+f.height/2-w)/M*100,F=qe(o,[A]);return p("stop",{offset:`${T}%`,stopColor:F||u})});m.push(L(tt,{children:[p(Ke,{children:p("linearGradient",{id:C,x1:b,y1:w,x2:b,y2:P,gradientUnits:"userSpaceOnUse",children:S})}),p(Pe,{d:$,stroke:`url(#${C})`,strokeWidth:2,width:1,height:P-w})]}))}if(c.forEach((w,P)=>{const $=P*(f.height+i),C=$+f.height/2,M=[P];m.push(p(ze,{x:v,y:C,width:70,fontSize:18,fontWeight:"bold",alignHorizontal:"left",alignVertical:"middle",fill:h[P%h.length],children:`STEP ${P+1}`})),y.push(p(n,{indexes:M,datum:w,data:r,x:_,y:$,positionH:"normal"})),m.push(p(Ze,{x:b-x,y:C-x,width:x*2,height:x*2,fill:h[P%h.length]})),g.push(p(nt,{indexes:M,x:_-d.width-10,y:$+(f.height-d.height)/2})),P===0?g.push(p(Q,{indexes:M,x:_+(f.width-d.width)/2,y:$-d.height-10})):g.push(p(Q,{indexes:M,x:_+(f.width-d.width)/2,y:$-i/2-d.height/2}))}),c.length>0){const w=(c.length-1)*(f.height+i);g.push(p(Q,{indexes:[c.length],x:_+(f.width-d.width)/2,y:w+f.height+10}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[l,L(Y,{children:[p(xt,{children:m}),p(Ne,{children:y}),p(He,{children:g})]})]})};We("sequence-timeline",{component:wC,composites:["title","item"]});const X1=120,U1=108,Nc=30,Lne="M4.49144e-05 34.4898C4.49144e-05 37.8786 0.848973 41.152 2.43571 44.2444C4.23516 47.7642 6.98514 51.0472 10.517 54.0009C21.331 63.047 39.4615 68.9814 59.9991 68.9814C80.5385 68.9814 98.6672 63.047 109.483 54.0009C113.013 51.0472 115.765 47.7642 117.564 44.2444C119.149 41.152 120 37.8786 120 34.4898C120 15.4407 93.1364 0 59.9991 0C26.8635 0 4.49144e-05 15.4407 4.49144e-05 34.4898Z",zne="M4.49145e-05 34.4898V53.9991C4.49145e-05 57.3879 0.848973 60.6613 2.43571 63.7556C9.75425 78.0545 32.7562 88.4907 59.999 88.4907C87.2438 88.4907 110.246 78.0545 117.564 63.7556C119.149 60.6613 120 57.3879 120 53.9991V34.4898C120 37.8786 119.149 41.152 117.564 44.2444C115.765 47.7642 113.013 51.0472 109.483 54.0009C98.6672 63.047 80.5385 68.9814 59.999 68.9814C39.4615 68.9814 21.3309 63.047 10.5169 54.0009C6.98509 51.0472 4.23516 47.7642 2.43567 44.2444C0.848928 41.152 4.49145e-05 37.8786 4.49145e-05 34.4898Z",Nne="M0 53.9991V73.5102C0 92.5593 26.8634 108 59.999 108C93.1363 108 120 92.5593 120 73.5102V53.9991C120 57.3879 119.149 60.6613 117.564 63.7556C110.246 78.0545 87.2438 88.4907 59.999 88.4907C32.7562 88.4907 9.75425 78.0545 2.43571 63.7556C0.848973 60.6613 0 57.3879 0 53.9991Z",PC=L("filter",{id:"sequence-zigzag-pucks-3d-shadow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[p("feOffset",{dx:"-7",dy:"7",in:"SourceAlpha",result:"offset"}),p("feGaussianBlur",{stdDeviation:"7.5",in:"offset",result:"blurred"}),p("feColorMatrix",{in:"blurred",type:"matrix",values:`0 0 0 0 0
|
|
143
|
+
`;return k(Y,{children:[y(Ke,{children:k(tt,{children:[k("linearGradient",{id:"basePlateTopGradient",x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:"#fafafa",stopOpacity:1}),y("stop",{offset:"50%",stopColor:"#ffffff",stopOpacity:.98}),y("stop",{offset:"100%",stopColor:"#ececec",stopOpacity:.95})]}),k("linearGradient",{id:"basePlateFrontGradient",x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:"#e0e0e0",stopOpacity:.95}),y("stop",{offset:"50%",stopColor:"#d2d2d2",stopOpacity:.93}),y("stop",{offset:"100%",stopColor:"#c5c5c5",stopOpacity:.9})]}),k("linearGradient",{id:"basePlateSideGradient",x1:"0%",y1:"0%",x2:"100%",y2:"100%",children:[y("stop",{offset:"0%",stopColor:"#b8b8b8",stopOpacity:.92}),y("stop",{offset:"50%",stopColor:"#c0c0c0",stopOpacity:.88}),y("stop",{offset:"100%",stopColor:"#adadad",stopOpacity:.85})]})]})}),y(Ce,{id:"base-plate-front",d:b,fill:"url(#basePlateFrontGradient)",stroke:"#c5c5c5",strokeWidth:.3,opacity:.92}),y(Ce,{id:"base-plate-side",d:v,fill:"url(#basePlateSideGradient)",stroke:"#aaaaaa",strokeWidth:.3,opacity:.88}),y(Ce,{id:"base-plate-top",d:m,fill:"url(#basePlateTopGradient)",stroke:"#e5e5e5",strokeWidth:.5,opacity:.93})]})},JO=e=>{const{Title:t,Item:n,data:r,options:i,cylinderRx:o=28,cylinderRy:s=18,baseHeight:a=120,heightIncrement:l=40,depthSpacing:c=60,itemVerticalAlign:u="top",itemVerticalOffset:h=-12,firstDecorationWidth:f=90}=e,{title:d,desc:p,items:g=[]}=r,m=t?y(t,{title:d,desc:p}):null,v=ae(y(n,{indexes:[0],data:r,datum:g[0],positionH:"center"})),b=ae(y(Q,{indexes:[0]})),_=Ot(i),x=10,w=Math.max(6,c*.15),C=Mre(g.length,v,o,a,l,c,f,x),{startY:P,leftItemAlignedX:O,rightItemAlignedX:$,cylinderAreaStartX:S}=C,M=[],I=[];g.forEach((G,L)=>{const R=He(i,[L])||_;M.push(...Tre(L,R));const z=Ire(L,o,a,l,w,P,S),q=Rre(L,z,o,s),{itemPos:j,lineStartX:V,lineEndX:U,lineY:K}=Are(L,z,v,o,O,$,u,h,x),ne=kre(L,V,U,K,R);q.push(...ne);const J=y(n,{indexes:[L],datum:G,data:r,x:j.x,y:j.y,positionH:L%2===0?"flipped":"normal"}),se=[y(nt,{indexes:[L],x:j.x+v.width/2-b.width/2,y:j.y+v.height+10}),y(Q,{indexes:[L],x:j.x+v.width/2-b.width/2,y:j.y-b.height-10})];I[L]={cylinderNodes:q,itemNode:J,btnNodes:se,itemX:j.x,itemY:j.y}});let E=1/0,A=1/0,T=-1/0,N=-1/0;I.forEach(G=>{const{itemX:L,itemY:R}=G;E=Math.min(E,L),A=Math.min(A,R),T=Math.max(T,L+v.width),N=Math.max(N,R+v.height)});const H=T-E,D=N-A,B=[y(Ke,{children:M})],F=[],X=Lre(g.length,o,S,P,w);X&&B.push(X);for(let G=g.length-1;G>=0;G--){const L=I[G];L&&(B.push(k(Y,{children:[y(Y,{children:L.cylinderNodes}),L.itemNode]})),F.push(...L.btnNodes))}if(g.length>0){const G=g.length%2===0,L=Math.floor(g.length/2),R=ql(L,o),z=Hl(G,L,o),q=S+z+R,j=P-g.length*w;F.push(y(Q,{indexes:[g.length],x:q,y:j-100}))}return k(ve,{flexDirection:"column",justifyContent:"center",alignItems:"center",children:[m,k(Y,{width:H,height:D,children:[y(ze,{children:B}),y(qe,{children:F})]})]})};We("sequence-cylinders-3d",{component:JO,composites:["title","item"]});const st={WIDTH:160,HEIGHT:260,ARROW_HEIGHT:148,ARROW_WIDTH:100,LINE_X:100,RECT_X:0,RECT_Y:80,RECT_WIDTH:100,RECT_HEIGHT:130},Nn={SIZE:8,MAX_COUNT:40,MIN_COUNT:5,ARROW_RATIO:.6,MIN_ARROW_COUNT:3};function Nre(e,t,n){return(e+t*7+n*13)%100}function zre(e){const t=Math.ceil(Math.sqrt(e*1.5)),n=Math.ceil(e/t);return{cols:t,rows:n}}function Dre(e,t,n,r,i,o,s,a){const l=Math.max(i,Math.min(e+n,o)),c=Math.max(s,Math.min(t+r,a));return{x:l,y:c}}function eS({count:e,rectX:t,rectY:n,rectWidth:r,rectHeight:i,seed:o}){const s=[],a=Nn.SIZE/2,{cols:l,rows:c}=zre(e),u=(r-a*2)/(l+1),h=(i-a*2)/(c+1);let f=0;for(let d=0;d<c&&f<e;d++)for(let p=0;p<l&&f<e;p++){const g=Nre(o,d,p),m=g%16-8,v=g*3%12-6,b=d%2===1?u/2:0,_=t+a+(p+1)*u+b,x=n+a+(d+1)*h,{x:w,y:C}=Dre(_,x,m,v,t+a,t+r-a,n+a,n+i-a);s.push({x:w,y:C,colorIndex:f}),f++}return s}function qre(e,t){if(t<=1)return Nn.MAX_COUNT;const n=e/(t-1),r=Nn.MAX_COUNT-Nn.MIN_COUNT;return Math.round(Nn.MAX_COUNT-r*n)}function Hre(){const s={topLeft:{x:40,y:25},topRight:{x:160,y:75},bottomLeft:{x:40,y:205},bottomRight:{x:160,y:255}},a=[];for(let l=0;l<=12;l++){const c=l/12,u={x:s.topLeft.x+(s.bottomLeft.x-s.topLeft.x)*c,y:s.topLeft.y+(s.bottomLeft.y-s.topLeft.y)*c},h={x:s.topRight.x+(s.bottomRight.x-s.topRight.x)*c,y:s.topRight.y+(s.bottomRight.y-s.topRight.y)*c};a.push(`M${u.x} ${u.y}L${h.x} ${h.y}`);const f={x:s.topLeft.x+(s.topRight.x-s.topLeft.x)*c,y:s.topLeft.y+(s.topRight.y-s.topLeft.y)*c},d={x:s.bottomLeft.x+(s.bottomRight.x-s.bottomLeft.x)*c,y:s.bottomLeft.y+(s.bottomRight.y-s.bottomLeft.y)*c};a.push(`M${f.x} ${f.y}L${d.x} ${d.y}`)}return a.join("")}function tS(e,t){return e.map(n=>{const r=He(t,[n.colorIndex]);return y(Ce,{d:"M4 0L8 4L4 8L0 4Z",fill:r,x:n.x,y:n.y,width:Nn.SIZE,height:Nn.SIZE,"data-element-type":"shape"})})}function jre(e,t,n,r,i){return k(Y,{x:t,y:0,width:st.WIDTH,height:st.HEIGHT,children:[k(Pt,{children:[y(Ce,{d:Hre(),stroke:"#D9D9D9",strokeWidth:2}),y(Ce,{d:`M${st.LINE_X} 25V260`,stroke:"#BFBFBF",strokeWidth:2,strokeLinecap:"round"}),y(ke,{x:st.RECT_X,y:st.RECT_Y,width:st.RECT_WIDTH,height:st.RECT_HEIGHT,fill:"#FFCB0E",fillOpacity:.2})]}),y(tt,{children:tS(r,i)}),y(Ne,{x:st.LINE_X-25,y:0,width:50,height:20,fontSize:20,fontWeight:"bold",alignHorizontal:"center",alignVertical:"top",fill:n,children:String(e+1).padStart(2,"0")})]})}function Fre(e,t){const n=st.RECT_Y+st.RECT_HEIGHT/2-st.ARROW_HEIGHT/2,r=Math.max(Math.round(Nn.MIN_COUNT*Nn.ARROW_RATIO),Nn.MIN_ARROW_COUNT),i=eS({count:r,rectX:0,rectY:14,rectWidth:57,rectHeight:120,seed:999});return k(Y,{x:e+st.WIDTH,y:n,children:[y(Ce,{d:"M0 13.9679H57.1429V0L100 74L57.1429 148V134.032H0V13.9679Z",width:st.ARROW_WIDTH,height:st.ARROW_HEIGHT,fill:"#FFCB0E",fillOpacity:.2,"data-element-type":"shape"}),y(tt,{children:tS(i,t)})]})}const nS=e=>{const{Title:t,Item:n,data:r,gap:i=20,options:o}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=ae(y(Q,{indexes:[0]})),h=ae(y(n,{indexes:[0],data:r,datum:l[0],width:st.WIDTH,positionH:"center"})),f=[],d=[],p=[],g=st.HEIGHT+i,m=g+h.height+10;if(l.forEach((v,b)=>{const _=b*st.WIDTH,x=[b],w=He(o,x),C=qre(b,l.length),P=eS({count:C,rectX:st.RECT_X,rectY:st.RECT_Y,rectWidth:st.RECT_WIDTH,rectHeight:st.RECT_HEIGHT,seed:b*100});f.push(jre(b,_,w,P,o)),b===l.length-1&&f.push(Fre(_,o)),d.push(y(n,{indexes:x,datum:v,data:r,width:st.WIDTH,x:_+st.LINE_X-st.WIDTH/2,y:g,positionH:"center"})),p.push(y(nt,{indexes:x,x:_+st.LINE_X-u.width/2,y:m})),b<l.length-1&&p.push(y(Q,{indexes:[b+1],x:_+st.WIDTH-u.width/2,y:m}))}),l.length>0){p.unshift(y(Q,{indexes:[0],x:-u.width/2,y:m}));const v=(l.length-1)*st.WIDTH;p.push(y(Q,{indexes:[l.length],x:v+st.WIDTH-u.width/2,y:m}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{width:st.WIDTH*l.length+st.ARROW_WIDTH,height:st.HEIGHT+i+h.height,children:[y(Y,{children:f}),y(ze,{children:d}),y(qe,{children:p})]})]})};We("sequence-filter-mesh",{component:nS,composites:["title","item"]});const jl=e=>Math.round(e*1e10)/1e10,am=(e,t)=>jl(Math.sqrt((t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y))),Fl=Math.PI,Bre=Fl*2,Wre=(e,t)=>{const n=t-e;return n>Fl&&n<Bre||n<0&&n>-Fl?-1:1},Vre=(e,t,n,r,i,o)=>{const s=Math.atan2(e.y-t.y,e.x-t.x),a=Math.atan2(n.y-t.y,n.x-t.x),l=Math.acos((r*r+o*o-i*i)/(2*r*o)),c=1/Math.tan(l/2),u=Wre(s,a),h=s+u*l/2;return{prev:s,next:a,main:l,vel:c,dir:u,bis:h}},lm=Math.PI,rS=(e,t,n)=>e.reduce((r,i)=>{const{x:o,y:s,angle:{prev:a,next:l},arc:{x:c,y:u,radius:h}}=i,f=i.angle.dir*-1,d=a+f*lm/2,p=(f*lm+l-a)%lm,g=n-1,m=p/g,v=[];if(!m)return r.concat({x:o,y:s});for(let b=0;b<=g;b++)v.push({x:c+Math.cos(d+m*b)*h,y:u+Math.sin(d+m*b)*h});return r.concat(v)},[]),iS=(e,t=0)=>{const n=e.length,r=[],i=[],o=[];e.forEach((l,c)=>{const u=e[(c-1+n)%n],h=e[(c+1)%n],f=am(u,l),d=am(u,h),p=am(l,h),g=Vre(u,l,h,f,d,p);g.main===0&&(g.main=Number.EPSILON,g.vel=Number.MAX_SAFE_INTEGER),g.main===Fl&&(g.vel=0);const m={x:l.x,y:l.y,angle:g,offset:0,arc:{radius:t,hit:t,lim:Math.min(p/g.vel,f/g.vel,l.r||0)},in:{length:f,rest:f},out:{length:p,rest:p},locked:!1,id:c,get prev(){return r[(c-1+n)%n]},get next(){return r[(c+1)%n]}};isNaN(g.main)&&(g.main=0,g.bis=g.prev||g.next,o.push(m)),typeof l.r=="number"&&(l.r===0?o.push(m):i.push(m)),r.push(m)}),o.forEach(l=>{l.angle.vel=0,l.arc.radius=0,cm(l)}),r.forEach(l=>{l.arc.hit=Math.min(l.out.rest/(l.angle.vel+l.next.angle.vel),l.in.rest/(l.angle.vel+l.prev.angle.vel))});let s=Bl(i);for(;s;)Gre(s),s=Bl(i);for(s=Bl(r);s;)Yre(s,t),s=Bl(r);const a=r.map(l=>{const c=l.arc.radius/Math.sin(l.angle.main/2);return{id:l.id,x:l.x,y:l.y,angle:{main:jl(l.angle.main),prev:l.angle.prev,next:l.angle.next,bis:l.angle.bis,dir:l.angle.dir},offset:jl(l.offset),arc:{radius:jl(l.arc.radius),x:l.x+(Math.cos(l.angle.bis)*c||0),y:l.y+(Math.sin(l.angle.bis)*c||0)},in:{length:l.in.length,x:l.x+Math.cos(l.angle.prev)*l.offset,y:l.y+Math.sin(l.angle.prev)*l.offset},out:{length:l.out.length,x:l.x+Math.cos(l.angle.next)*l.offset,y:l.y+Math.sin(l.angle.next)*l.offset},get prev(){return a[(l.id-1+n)%n]},get next(){return a[(l.id+1)%n]}}});return a},Gre=e=>{const{prev:t,next:n}=e;t.locked&&!n.locked?e.arc.radius=Math.min(Math.max((e.out.length-n.arc.lim*n.angle.vel)/e.angle.vel,e.out.length/(e.angle.vel+n.angle.vel)),e.in.rest/e.angle.vel,e.arc.lim):n.locked&&!t.locked?e.arc.radius=Math.min(Math.max((e.in.length-t.arc.lim*t.angle.vel)/e.angle.vel,e.in.length/(e.angle.vel+t.angle.vel)),e.out.rest/e.angle.vel,e.arc.lim):n.locked&&t.locked?e.arc.radius=Math.min(e.in.rest/e.angle.vel,e.out.rest/e.angle.vel,e.arc.lim):e.arc.radius=Math.min(Math.max((e.in.length-t.arc.lim*t.angle.vel)/e.angle.vel,e.in.length/(e.angle.vel+t.angle.vel)),Math.max((e.out.length-n.arc.lim*n.angle.vel)/e.angle.vel,e.out.length/(e.angle.vel+n.angle.vel)),e.arc.lim),cm(e)},Yre=(e,t)=>{if(t>e.arc.hit){const{prev:n,next:r}=e;n.locked&&!r.locked?e.arc.radius=Math.max(Math.min(e.in.rest/e.angle.vel,e.out.length/(e.angle.vel+r.angle.vel),e.arc.radius),0):r.locked&&!n.locked?e.arc.radius=Math.max(Math.min(e.out.rest/e.angle.vel,e.in.length/(e.angle.vel+n.angle.vel),e.arc.radius),0):r.locked&&n.locked?e.arc.radius=Math.max(Math.min(e.in.rest/e.angle.vel,e.out.rest/e.angle.vel,e.arc.radius),0):e.arc.radius=e.arc.hit}cm(e)},cm=e=>{const{prev:t,next:n}=e;e.offset=e.arc.radius*e.angle.vel,t.out.rest-=e.offset,e.in.rest-=e.offset,e.out.rest-=e.offset,n.in.rest-=e.offset,e.locked=!0,t.arc.hit=Math.min(t.in.length/(t.angle.vel+t.prev.angle.vel),t.in.rest/t.angle.vel,t.out.rest/t.angle.vel),n.arc.hit=Math.min(n.out.length/(n.angle.vel+n.next.angle.vel),n.out.rest/n.angle.vel,n.in.rest/n.angle.vel)},Bl=e=>e.reduce((t,n)=>n.locked?t:t?n.arc.hit<t.arc.hit?n:t:n,null),Xre=6,um=32,Ure=1.25,hm=25,oS=15,sS=e=>{const{Title:t,Item:n,data:r,gap:i=10,width:o=700,funnelWidth:s,itemHeight:a=60,minBottomRatio:l=.25,options:c}=e,{title:u,desc:h,items:f=[]}=r,d=t?y(t,{title:u,desc:h}):null;if(f.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:d});const p=Et(c.themeConfig),g=s!=null?s:o*.55,m=o-g,v=a*Ure,b=f.length*v+(f.length-1)*i,_=g*l,x=f.map((C,P)=>{const O=[P],$=He(c,[P])||p.colorPrimary,{points:S,topWidth:M}=Kre(g,_,v,i,b,P),I=iS(S,Xre),E=rS(I,"AMOUNT",10),A=g/2,T=P*(v+i),N=A+M/2,H=N-hm,D=m+hm-10,B=(v-a)/2,F=T+B,X=N+oS,G=D-hm-oS,L=F,R=A-um/2,z=T+v/2-um/2,q=`${$.replace("#","")}-funnel-${P}`;return{background:y(ke,{x:H,y:F,width:D,height:a,ry:"8",fill:be($).setAlpha(.1).toRgbString(),"data-element-type":"shape"}),funnel:[y(Ke,{children:k("linearGradient",{id:q,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[y("stop",{offset:"0%",stopColor:be($).lighten(10).toString()}),y("stop",{offset:"100%",stopColor:$})]})}),y(Yt,{points:E,fill:`url(#${q})`,y:T,"data-element-type":"shape",style:{filter:"drop-shadow(0px 2px 3px rgba(0,0,0,0.15))"}})],icon:y(Ft,{indexes:O,x:R,y:z,size:um,fill:"#fff"}),item:y(n,{indexes:O,datum:C,data:r,x:X,y:L,width:G,height:a,positionV:"middle"}),btnRemove:y(nt,{indexes:O,x:H+D,y:F})}}),w=y(Q,{indexes:[f.length],x:o/2,y:b+10});return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,k(Y,{width:o,height:b+40,children:[y(Y,{children:x.map(C=>C.background)}),y(Y,{children:x.flatMap(C=>C.funnel)}),y(Y,{children:x.map(C=>C.icon)}),y(ze,{children:x.map(C=>C.item)}),k(qe,{children:[x.map(C=>C.btnRemove),w]})]})]})};function Kre(e,t,n,r,i,o){const s=e/2,a=o*(n+r),l=a+n,c=e-t,u=e-c*(a/i),h=e-c*(l/i),f={x:s-u/2,y:0},d={x:s+u/2,y:0},p={x:s+h/2,y:n},g={x:s-h/2,y:n};return{points:[f,d,p,g],topWidth:u,bottomWidth:h}}We("sequence-funnel",{component:sS,composites:["title","item"]});const aS=e=>{const{Title:t,Item:n,data:r,gap:i=30,cardPadding:o=10,options:s}=e,{title:a,desc:l,items:c=[]}=r,u=t?y(t,{title:a,desc:l}):null,h=Ot(s),f=Et({colorPrimary:h},s),d=ae(y(Q,{indexes:[0]})),p=ae(y(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),g=[],m=[],v=[],b=p.width+o*2,_=p.height+o*2+30,x=8,w=6,C=Math.max(d.height+20,40),P=40;if(c.forEach((O,$)=>{const S=$%2===0,M=$*(b+i);let I;S?$%4===2?I=C:I=C+P:I=C+P+60;const E=[$],A=He(s,E)||h;if(S){const D=A===h?f.colorPrimaryBg||"#E8F3FF":`${A}20`,B=y(ke,{x:M,y:I,width:b,height:_,fill:D,rx:20,ry:20});v.push(B)}m.push(y(n,{indexes:E,datum:O,data:r,x:M+o,y:I+o,positionH:"center",positionV:"normal"}));const T=c.length*x+(c.length-1)*w,N=M+(b-T)/2,H=I+p.height+20;for(let D=0;D<c.length;D++){const B=N+D*(x+w),F=D===$;v.push(y(Ze,{x:B,y:H,width:x,height:x,fill:F?A:"transparent",stroke:A,strokeWidth:2}))}g.push(y(nt,{indexes:E,x:M+(b-d.width)/2,y:I+_+10})),$===0?g.push(y(Q,{indexes:E,x:M+(b-d.width)/2,y:I-d.height-10})):g.push(y(Q,{indexes:E,x:M-i/2-d.width/2,y:C-d.height-10}))}),c.length>0){const O=[],S=i/2,M=6,I=C+P,E=0-S,A=I+_/2;O.push(`M ${E} ${A-M}`),c.forEach((q,j)=>{const V=j%2===0,U=j*(b+i);let K;V?j%4===2?K=C:K=C+P:K=C+P+60;const ne=U-S,J=U+b+S,se=K-S,Z=K+_+S,te=K+_/2;V?(O.push(`L ${ne} ${se+35}`),O.push(`Q ${ne} ${se} ${ne+35} ${se}`),O.push(`L ${J-35} ${se}`),O.push(`Q ${J} ${se} ${J} ${se+35}`),O.push(`L ${J} ${te-M}`)):(O.push(`L ${ne} ${te}`),O.push(`L ${ne} ${Z-35}`),O.push(`Q ${ne} ${Z} ${ne+35} ${Z}`),O.push(`L ${J-35} ${Z}`),O.push(`Q ${J} ${Z} ${J} ${Z-35}`),O.push(`L ${J} ${te+M}`))});const T=c.length-1,N=T%2===0,H=T*(b+i);let D;N?T%4===2?D=C:D=C+P:D=C+P+60;const B=H+b+S,F=D+_/2,X=O.join(" "),G="gradient-zigzag-path",L=He(s,[0])||h,R=He(s,[c.length-1])||h,z=c.map((q,j)=>{const V=j/(c.length-1)*100,U=He(s,[j])||h;return y("stop",{offset:`${V}%`,stopColor:U})});v.unshift(k(tt,{children:[y(Ke,{children:y("linearGradient",{id:G,x1:E,y1:A,x2:B,y2:F,gradientUnits:"userSpaceOnUse",children:z})}),y(Ce,{d:X,stroke:`url(#${G})`,strokeWidth:2,fill:"none",width:(c.length-1)*(b+i)+b+S*2,height:_+120})]})),v.unshift(y(Ze,{x:E-M,y:A-M,width:M*2,height:M*2,fill:"transparent",stroke:L,strokeWidth:2})),v.unshift(y(Ze,{x:B-M,y:F-M,width:M*2,height:M*2,fill:"transparent",stroke:R,strokeWidth:2}))}if(c.length>0){const $=(c.length-1)*(b+i);g.push(y(Q,{indexes:[c.length],x:$+b+(i-d.width)/2,y:C-d.height-10}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,k(Y,{children:[y(Pt,{children:v}),y(ze,{children:m}),y(qe,{children:g})]})]})};We("sequence-horizontal-zigzag",{component:aS,composites:["title","item"]});var Zre=Object.defineProperty,Qre=Object.defineProperties,Jre=Object.getOwnPropertyDescriptors,lS=Object.getOwnPropertySymbols,eie=Object.prototype.hasOwnProperty,tie=Object.prototype.propertyIsEnumerable,cS=(e,t,n)=>t in e?Zre(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Wl=(e,t)=>{for(var n in t||(t={}))eie.call(t,n)&&cS(e,n,t[n]);if(lS)for(var n of lS(t))tie.call(t,n)&&cS(e,n,t[n]);return e},Vl=(e,t)=>Qre(e,Jre(t));function nie(e){const{width:t,height:n,colorPrimary:r}=e,i=r,o=be.mix(r,"#000",20).toHexString(),s=be.mix(r,"#fff",50).toHexString(),a=be.mix(s,"#000",15).toHexString();function l(P,O){const S=[{position:.25,offset:.1},{position:.45,offset:-.02},{position:.6,offset:.04},{position:.75,offset:-.1}],M={x:0,y:O},I={x:P,y:O},E={x:P/2,y:0},A={x:P/2,y:O},T=O*.35,N=T/O,H={x:E.x*(1-N)+M.x*N,y:T},D={x:E.x,y:T},B={x:E.x*(1-N)+I.x*N,y:T},F=S.map(L=>{const R=H.x+(B.x-H.x)*L.position,z=T,q=O*L.offset;return{x:R,y:z+q,position:L.position,offset:L.offset}});F.sort((L,R)=>L.position-R.position);const X=F.filter(L=>L.x<=D.x),G=F.filter(L=>L.x>D.x);return{leftBottom:M,rightBottom:I,peak:E,centerBottom:A,snowLineY:T,leftEdge:H,centerSnow:D,rightEdge:B,leftRipples:X,rightRipples:G}}const{leftRipples:c,rightRipples:u,leftBottom:h,rightBottom:f,peak:d,centerBottom:p,leftEdge:g,centerSnow:m,rightEdge:v}=l(t,n),b=[d,g,...c,m],_=[d,m,...u,v],x=[g,...c,m,p,h],w=[m,...u,v,f,p],C=P=>P.map(O=>`${O.x},${O.y}`).join(" ");return k(Pt,Vl(Wl({},e),{children:[y("polygon",{points:C(b),fill:s}),y("polygon",{points:C(_),fill:a}),y("polygon",{points:C(x),fill:i}),y("polygon",{points:C(w),fill:o})]}))}function rie(e){const n={tiny:27,small:48,medium:54,large:72}[e]||54,r="#17C76F",i="#139B57",o="#737373",s=n*.7,a=n-s,l=s*.8,c=l,u=c/6,h=(c-u)/2,f=s;return k(Pt,{width:c,height:n,children:[y("ellipse",{cx:l/2,cy:s/2,rx:l/2,ry:s/2,fill:r,clipPath:"inset(0 50% 0 0)"}),y("ellipse",{cx:l/2,cy:s/2,rx:l/2,ry:s/2,fill:i,clipPath:"inset(0 0 0 50%)"}),y("rect",{x:h,y:f,width:u,height:a,fill:o})]})}function iie(e){const{width:t,height:n}=e,r=t/2,i=n/2,o=Math.min(t,n)*.28,s=Math.min(t,n)*.14,a=Math.min(t,n)*.07,l=0,c=i-a/2,u=a*.4,h=8,f=Array.from({length:h},(d,p)=>{const g=360/h*p;return y("rect",{x:l,y:c,width:s,height:a,rx:u,ry:u,fill:"#FFCB0E",transform:`rotate(${g}, ${r}, ${i})`})});return k(Pt,Vl(Wl({},e),{children:[y("circle",{cx:r,cy:i,r:o,fill:"#FFCB0E"}),...f]}))}function oie(e){return e.type==="single"?y(Pt,Vl(Wl({},e),{width:54,height:36,children:y("path",{d:"M10.2635 13.3806C11.0019 9.99045 12.7381 6.91002 15.2405 4.55004C17.743 2.19007 20.8929 0.662716 24.2701 0.171643C27.6473 -0.31943 31.0914 0.24912 34.143 1.80148C37.1946 3.35385 39.7087 5.81625 41.3501 8.86031C44.8835 9.0468 48.1994 10.6544 50.5684 13.3294C52.9373 16.0044 54.1653 19.5277 53.9821 23.1242C53.7989 26.7207 52.2195 30.0959 49.5914 32.5071C46.9634 34.9184 43.5019 36.1683 39.9684 35.9818H11.1517C4.93436 35.9818 0 30.9593 0 24.6309C0.0598447 21.8016 1.13799 19.093 3.02989 17.0192C4.9218 14.9454 7.49584 13.6506 10.2635 13.3806Z",fill:"#70CAF8"})})):k(Pt,Vl(Wl({},e),{width:73,height:40,children:[y("path",{d:"M61.6461 14.9716C60.8681 11.1875 58.9581 7.73823 56.1763 5.09315C53.3944 2.44806 49.8758 0.735682 46.0992 0.189041C42.3226 -0.357601 38.4714 0.288046 35.0699 2.03812C31.6683 3.7882 28.8815 6.5577 27.0889 9.96971C23.161 10.1687 19.4719 11.9405 16.8333 14.8953C14.1947 17.8502 12.8227 21.746 13.0191 25.7258C13.2155 29.7055 14.9642 33.4433 17.8806 36.1167C20.7969 38.7901 24.642 40.1802 28.5699 39.9812H60.6588C67.5702 39.9812 73.0006 34.4791 73.0006 27.4764C73.0006 20.9739 67.8664 15.4718 61.6461 14.9716Z",fill:"#70CAF8"}),y("path",{d:"M21.9691 6.47136e-09C25.9369 6.47136e-09 29.5264 1.62125 32.0003 4.21094C30.0604 5.7917 28.4423 7.75571 27.2581 10C23.3149 10.1989 19.6111 11.9702 16.9622 14.9238C14.3136 17.8774 12.936 21.772 13.1331 25.75C13.2057 27.2131 13.4902 28.6432 13.9652 30H10.7689C7.96116 29.8907 5.29664 28.7203 3.30402 26.7217C1.31144 24.7231 0.135825 22.0419 0.0110544 19.21C-0.113702 16.378 0.821178 13.6017 2.63019 11.4326C4.43921 9.26356 6.99065 7.8602 9.77766 7.5C11.9582 3.00012 16.6168 8.76701e-05 21.9691 6.47136e-09Z",fill:"#5BA2C6"})]}))}const uS=e=>{const{Title:t,Item:n,data:r,gap:i=20,minHeight:o=100,maxHeight:s=200,minWidth:a=260,maxWidth:l=300,options:c}=e,{title:u,desc:h,items:f=[]}=r,d=t?y(t,{title:u,desc:h}):null,p=[],g=[],m=[],v=[],b=f.length,_=Et(c.themeConfig),x=60,w={single:{width:54,height:36},double:{width:73,height:40}},C=[],P=[];let O=0,$=0;f.forEach((F,X)=>{const G=b>1?X/(b-1):0,R=(o+(s-o)*G)*1.6,z=Math.max(a,Math.min(l,R));C.push(z);const q=$;P.push(q),$+=z/2,X===b-1&&(O=q+z)});const S=P[0],M=P[b-1]+C[b-1],I=M-S,E=b>1?(I-i*(b-1))/b:I,A=ae(y(n,{indexes:[0],data:r,datum:f[0],width:E})),T=32,N=s+i,H=N+T+10;f.forEach((F,X)=>{const G=[X],L=o+(s-o)*(b>1?X/(b-1):0),R=C[X],z=P[X],q=s-L,j=He(c,[X])||_.colorPrimary;m.push(y(nie,{colorPrimary:j,x:z,y:q,width:R,height:L}));const V=S+X*(E+i);v.push(y(Ne,{x:V,y:N,width:E,height:T,fontSize:16,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:j,backgroundColor:j,backgroundOpacity:.5,backgroundRadius:4,children:String(X+1).padStart(2,"0")})),p.push(y(n,{indexes:G,datum:F,data:r,x:V,y:H,width:E}))});const D=ae(y(Q,{indexes:[0]})),B=H+A.height+10;if(f.forEach((F,X)=>{const G=[X],L=S+X*(E+i);g.push(y(nt,{indexes:G,x:L+E/2-D.width/2,y:B})),X<f.length-1&&g.push(y(Q,{indexes:[X+1],x:L+E+i/2-D.width/2,y:B}))}),b>0){const F=S;g.unshift(y(Q,{indexes:[0],x:F-i/2-D.width/2,y:B}));const X=S+(b-1)*(E+i);g.push(y(Q,{indexes:[b],x:X+E+i/2-D.width/2,y:B})),m.push(y(iie,{x:O-x-20,y:-35,width:x,height:x}));const G=["tiny","small","medium","large"],L={tiny:27,small:48,medium:54,large:72},R={tiny:14.85,small:26.4,medium:29.7,large:39.6},z=[],q=(V,U,K=5)=>z.some(ne=>!(V+U+K<ne.x||V>ne.x+ne.width+K));f.forEach((V,U)=>{const K=P[U],ne=C[U],se=U===b-1?3:U===0?1:2;for(let Z=0;Z<se;Z++){const te=U*100+Z*37,ue=te*17%G.length,re=G[ue],ee=L[re],oe=R[re];let ie=0,le=0,pe=!1;for(;ie<20&&!pe;){const he=(te*13+ie*19)%100/100,ge=K+ne*.15,fe=K+ne*.85-oe;le=ge+(fe-ge)*he,q(le,oe)||(pe=!0),ie++}if(pe){z.push({x:le,width:oe});const he=s-ee;m.push(y(Y,{x:le,y:he,children:rie(re)}))}}});const j=Math.max(1,Math.floor(b/1.5));for(let V=0;V<j;V++){const U=V*11+b*5+1,K=U%2===0?"single":"double",ne=w[K],J=M-S-ne.width,se=S+U*7%100/100*J,Z=U*13%40;m.push(y(oie,{type:K,x:se,y:Z,width:ne.width,height:ne.height}))}}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[d,k(Y,{children:[y(Y,{children:m}),y(Y,{children:v}),y(ze,{children:p}),y(qe,{children:g})]})]})};We("sequence-mountain",{component:uS,composites:["title","item"]});const hS=e=>{const{Title:t,Item:n,data:r,gap:i=10,width:o=700,pyramidWidth:s,itemHeight:a=60,options:l}=e,{title:c,desc:u,items:h=[]}=r,f=t?y(t,{title:c,desc:u}):null;if(h.length===0)return y(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:f});const d=5,p=Et(l.themeConfig),g=30,m=[],v=[],b=[],_=[],x=s!=null?s:o*.6,w=o-x,C=a*1.2,P=h.length*C+(h.length-1)*i;return h.forEach((O,$)=>{const S=[$],M=$===0,I=He(l,[$])||p.colorPrimary,{points:E,topWidth:A,bottomWidth:T}=sie(x,C,i,h.length,$),N=iS(E,d),H=rS(N,"AMOUNT",10),D=x/2,B=$*(C+i),F=(C-a)/2,X=B+F,G=D+A/2,L=D+T/2,z=G-d,q=w+d,j=a,V=z+q,U=D-g/2,K=B+C/2-g/2+(M?8:0),ne=L,J=V-L,se=X;b.push(y(ke,{x:z,y:X,width:q,height:j,ry:"10",fill:p.colorPrimaryBg,"data-element-type":"shape"}));const Z=`${I}-pyramid-${$}`;v.push(y(Ke,{children:k("linearGradient",{id:Z,x1:"0%",y1:"0%",x2:"0%",y2:"100%",children:[y("stop",{offset:"0","stop-color":I}),y("stop",{offset:"100%","stop-color":be.mix(I,"#fff",40).toHexString()})]})}),y(Yt,{points:H,fill:`url(#${Z})`,y:B,"data-element-type":"shape"})),_.push(y(Ft,{indexes:S,x:U,y:K,size:g,fill:"#fff"})),m.push(y(n,{indexes:S,datum:O,data:r,x:ne,y:se,width:J,height:a,positionV:"middle"}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,k(Y,{width:o,height:P,children:[y(Y,{children:b}),y(Y,{children:v}),y(Y,{children:_}),y(ze,{children:m}),y(qe,{})]})]})};function sie(e,t,n,r,i){const o=e/2,s=r*t+(r-1)*n,a=i*(t+n),l=a+t,c=a/s*e,u=l/s*e;let h;if(i===0){const f={x:o,y:0},d={x:o+u/2,y:t},p={x:o-u/2,y:t};h=[f,d,p]}else{const f={x:o+c/2,y:0},d={x:o+u/2,y:t},p={x:o-u/2,y:t},g={x:o-c/2,y:0};h=[f,d,p,g]}return{points:h,topWidth:c,bottomWidth:u}}We("sequence-pyramid",{component:hS,composites:["title","item"]});const rs={iconSize:50,roadWidth:24,outerRadius:60,rowWidth:400,spacing:30,colorDefault:"#666666"},fS=(e,t)=>`M ${e} ${t}`,vt=(e,t)=>`L ${e} ${t}`,Hi=(e,t,n,r)=>`A ${e} ${e} 0 0 ${t} ${n} ${r}`,aie=(e,{roadWidth:t,innerRadius:n,outerRadius:r})=>{const i=(t+n*2)*e;return{y1:i,y2:i+t,y3:i+t+n,y4:i+t+n*2,y5:i+r*2}};function lie({i:e,direction:t,x:n,y:r,color:i,data:o,itemBounds:s,item:a,Item:l,flipped:c}){const{iconSize:u}=rs,h=t==="left",f=h?n.x4-u/2:n.x3-u/2,d=r.y3-u/2,p=h?n.x6+rs.spacing:n.x1-rs.spacing-s.width,g=r.y3-s.height/2,m=h?c?"flipped":"normal":c?"normal":"flipped";return{icon:y(zr,{indexes:[e],x:f,y:d,size:u,fill:i}),label:y(Ne,{width:40,x:h?f-50:f+u+10,y:d+u/2-15,fontSize:30,fill:i,alignHorizontal:h?"right":"left",children:String(e+1).padStart(2,"0")}),item:y(l,{indexes:[e],data:o,datum:a,x:p,y:g,positionH:m})}}function cie({direction:e,x:t,y:n,color:r,elements:i}){const o=e==="left";i.push(y(yre,{x:o?t.x6+10:t.x1-20,y:n.y3-5,width:10,height:8,rotation:o?90:-90,colorPrimary:r,"data-element-type":"shape"}))}const dS=e=>{const{Title:t,Item:n,data:r,spacing:i=rs.spacing,options:o,flipped:s=!1}=e,{title:a,desc:l,items:c=[]}=r,u=t?y(t,{title:a,desc:l}):null,h=ae(y(n,{indexes:[0],data:r,datum:c[0],positionH:"center"})),{roadWidth:f,outerRadius:d,rowWidth:p,colorDefault:g}=rs,m=f/2,v=d-f,b=(h.width+i)*2+p,_=h.width+i,x=_+d,w=_+p-d,P=w+v+f,O=_+p/2,$=[],S=[],M=[],I=[],E=[],A=[],T=[];for(let D=0;D<c.length;D++){const B=He(o,[D])||g,F=D%2===0?"right":"left",X=D===0,G=D===c.length-1,L=aie(D,{roadWidth:f,innerRadius:v,outerRadius:d});if(F==="right"){const j=X?[P,L.y1]:[w,L.y1],V=[x,L.y1],U=[x,L.y5],K=X?[P,L.y2]:[w,L.y2],ne=[x,L.y2];if($.push(X?fS(P,L.y1+m):vt(w,L.y1+m),vt(x,L.y1+m),Hi(d-m,0,x,L.y4+m)),S.push(X?fS(...j):vt(...j),vt(...V),Hi(d,0,...U)),M.push(vt(...K),vt(...ne),Hi(v,1,...ne)),G){const J=f/2;S.push(vt(O,L.y5),vt(O,L.y5+J),vt(O+f,L.y5-J),vt(O,L.y4-J),vt(O,L.y4),vt(x,L.y4)),$.push(vt(O,L.y4+m))}}else{const j=[x,L.y2],V=[w,L.y2],U=[w,L.y4],K=[x,L.y1],ne=[w,L.y1];if($.push(vt(w,L.y1+m),Hi(d-m,1,w,L.y4+m)),S.push(vt(...j),vt(...V),Hi(v,1,...U)),M.push(vt(...K),vt(...ne),Hi(d,0,...ne)),G){const J=f/2;S.push(vt(O,L.y4),vt(O,L.y4-J),vt(O-f,L.y4+J),vt(O,L.y5+J),vt(O,L.y5),vt(w,L.y5)),$.push(vt(O,L.y4+m))}}cie({direction:F,x:{x1:_,x6:P},y:L,color:B,elements:T});const{icon:R,label:z,item:q}=lie({i:D,direction:F,x:{x1:_,x3:x,x4:w,x6:P},y:L,color:B,data:r,itemBounds:h,item:c[D],Item:n,flipped:s});I.push(R),E.push(z),A.push(q)}const N=[...S,...M.reverse(),"Z"],H=c.length*(f+v*2)+f*1.5;return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[u,k(Y,{width:b,height:h.height<=d*2?H:H+h.height-d*2,children:[y(Ce,{width:p,height:H,d:N.join(" "),fill:g,stroke:g,strokeWidth:"4",strokeLinecap:"round",strokeLinejoin:"round","data-element-type":"shape"}),y(Ce,{d:$.join(" "),stroke:"white",fill:"none",strokeWidth:"3",strokeDasharray:"8 8",strokeLinecap:"round",strokeLinejoin:"round","data-element-type":"shape"}),k(tt,{children:[I,E,A,T]})]})]})};We("sequence-roadmap-vertical",{component:dS,composites:["title","item"]});const pS=e=>{const{Title:t,Item:n,data:r,gap:i=40,itemsPerRow:o=3,rowGap:s=80,options:a}=e,{title:l,desc:c,items:u=[]}=r,h=t?y(t,{title:l,desc:c}):null,f=Ot(a),d=ae(y(Q,{indexes:[0]})),p=ae(y(n,{indexes:[0],data:r,datum:u[0],positionH:"center"})),g=[],m=[],v=[],b=25,_=25;if(u.forEach((x,w)=>{const C=Math.floor(w/o),P=w%o,O=C%2===1,S=(O?o-1-P:P)*(p.width+i),M=C*(p.height+s),I=[w];if(m.push(y(n,{indexes:I,datum:x,data:r,x:S,y:M,positionH:"center"})),g.push(y(nt,{indexes:I,x:S+(p.width-d.width)/2,y:M+p.height+10})),w===0&&g.push(y(Q,{indexes:I,x:S+(p.width-d.width)/2,y:M-d.height-10})),w<u.length-1){const E=Math.floor((w+1)/o),A=(w+1)%o,H=(E%2===1?o-1-A:A)*(p.width+i);if(C===E){const B=O,F=B?H+p.width+(i-b)/2:S+p.width+(i-b)/2,X=M+p.height/2-_/2;v.push(y(sm,{x:F,y:X,width:b,height:_,colorPrimary:f,rotation:B?180:0})),g.push(y(Q,{indexes:[w+1],x:F+(b-d.width)/2,y:M-d.height-10}))}else{const B=S+p.width/2-b/2,F=M+p.height+(s-_)/2;v.push(y(sm,{x:B,y:F,width:b,height:_,colorPrimary:f,rotation:90})),g.push(y(Q,{indexes:[w+1],x:B+(b-d.width)/2,y:F+(_-d.height)/2}))}}}),u.length>0){const x=u.length-1,w=Math.floor(x/o),C=x%o,$=(w%2===1?o-1-C:C)*(p.width+i),S=w*(p.height+s);g.push(y(Q,{indexes:[u.length],x:$+(p.width-d.width)/2,y:S+p.height+d.height+20}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[h,k(Y,{children:[y(Y,{children:v}),y(ze,{children:m}),y(qe,{children:g})]})]})};We("sequence-snake-steps",{component:pS,composites:["title","item"]});const gS=e=>{const{Title:t,Item:n,data:r,options:i,gap:o=16,perspectiveFactor:s=.2,width:a=720}=e,{title:l,desc:c,items:u=[]}=r,h=t,f=h?y(h,{title:l,desc:c}):null;if(u.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const d=Ot(i),p=ae(y(Q,{indexes:[0]})),g=ae(y(n,{indexes:[0],data:r,datum:u[0]||{},positionH:"center"})),m=12,v=Math.min(a*.1,100),b=Math.min(a*.45,Math.max(80,a-g.width-m-v)),_=Math.max(24,b*s*.35),x=56,w=x*.7,C=u.length>1?(x-w)/(u.length-1):0,P=Math.max(p.height+_+20,_+28),O=b/2,$=b+v+m,S=u.map((ue,re)=>x-C*re),M=u.map((ue,re)=>Math.max(_*(1-re*.05),_*.7)),I=[],E=[],A=u.length-1;I[A]=P,E[A]=0;for(let ue=A-1;ue>=0;ue-=1)E[ue]=E[ue+1]+M[ue]+o,I[ue]=I[ue+1]+M[ue]+S[ue+1]+o;const T=E[0]||M[0]||_,N=b*(.55+s*.1),H=b-N,D=u.map((ue,re)=>{const ee=T===0?1:E[re]/T;return N+H*ee}),B=D.map(ue=>{const re=O+ue/2;return Math.max(0,$-m-re)}),F=[],X=[],G=[],L=[],R=[],z=0,q=(I[0]||P)+(S[0]||x),j=q-z,V=35,K=(D[A]||N)*.8,ne=K*.65,J=(D[0]||b)*.9;R.push(y(Yt,{points:[{x:O,y:z},{x:O+K/2,y:z+V},{x:O+ne/2,y:z+V},{x:O+J/2,y:q},{x:O-J/2,y:q},{x:O-ne/2,y:z+V},{x:O-K/2,y:z+V}],fill:"rgba(0,0,0,0.12)",width:J,height:j,"data-element-type":"shape"}));let se=I[A]+S[A]/2;u.forEach((ue,re)=>{const ee=[re],oe=D[re],ie=M[re],le=O-oe/2,pe=S[re],he=I[re],ge=he-ie,fe=he+pe/2,xe=He(i,ee)||d;F.push(y(ke,{x:le,y:he,width:oe,height:pe,fill:xe,"data-element-type":"shape"}),y(Yt,{points:[{x:le,y:he},{x:le+oe,y:he},{x:le+oe-ie/2,y:ge},{x:le+ie/2,y:ge}],fill:xe,opacity:"0.3",width:oe,height:ie,"data-element-type":"shape"}),y(Ne,{x:le,y:he,width:oe,height:pe,fontSize:pe/2,fontWeight:"bold",alignHorizontal:"center",alignVertical:"middle",fill:"#ffffff",children:String(re+1).padStart(2,"0")}));const $e=le+oe,Ie=fe,Pe=B[re],Le=$e+Pe;L.push(y(Ce,{d:`M ${$e} ${Ie} L ${Le} ${Ie}`,stroke:xe,strokeWidth:2,fill:"none",width:Pe,height:2,"data-element-type":"shape"}),y(Ce,{d:`M ${Le} ${Ie} L ${Le} ${Ie}`,stroke:xe,strokeWidth:6,strokeLinecap:"round",width:1,height:1,"data-element-type":"shape"}));const je=fe-g.height/2;X.push(y(n,{indexes:ee,datum:ue,data:r,x:$,y:je,positionV:"middle"})),G.push(y(nt,{indexes:ee,x:$+g.width+10,y:je+g.height/2-p.height/2})),re===0?G.push(y(Q,{indexes:[0],x:$+(g.width-p.width)/2,y:je-p.height-12})):G.push(y(Q,{indexes:ee,x:$+(g.width-p.width)/2,y:(se+fe)/2-p.height/2})),se=fe});const te=se-g.height/2;return G.push(y(Q,{indexes:[u.length],x:$+(g.width-p.width)/2,y:te+g.height+12})),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[f,k(Y,{children:[y(Y,{children:R}),y(Y,{children:F}),y(Y,{children:L}),y(ze,{children:X}),y(qe,{children:G})]})]})};We("sequence-stairs-front",{component:gS,composites:["title","item"]});const mS=e=>{const{Title:t,Item:n,data:r,gap:i=40,options:o}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=Ot(o),h=ae(y(Q,{indexes:[0]})),f=ae(y(n,{indexes:[0],data:r,datum:l[0],positionH:"center"})),d=[],p=[],g=[],m=25,v=25,b=Math.max(h.height+20,30);if(l.forEach((_,x)=>{const w=x*(f.width+i),C=[x];if(p.push(y(n,{indexes:C,datum:_,data:r,x:w,y:b,positionH:"center"})),d.push(y(nt,{indexes:C,x:w+(f.width-h.width)/2,y:b+f.height+10})),x===0?d.push(y(Q,{indexes:C,x:w+(f.width-h.width)/2,y:b-h.height-10})):d.push(y(Q,{indexes:C,x:w-i/2-h.width/2,y:b-h.height-10})),x<l.length-1){const P=w+f.width+(i-m)/2,O=b+f.height/2-v/2;g.push(y(sm,{x:P,y:O,width:m,height:v,colorPrimary:u}))}}),l.length>0){const _=(l.length-1)*(f.width+i);d.push(y(Q,{indexes:[l.length],x:_+f.width+(i-h.width)/2,y:b-h.height-10}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(Y,{children:g}),y(ze,{children:p}),y(qe,{children:d})]})]})};We("sequence-steps",{component:mS,composites:["title","item"]});const yS=e=>{const{Title:t,Item:n,data:r,gap:i=10,options:o}=e,{title:s,desc:a,items:l=[]}=r,c=t?y(t,{title:s,desc:a}):null,u=Ot(o),h=Uw(o),f=ae(y(Q,{indexes:[0]})),d=ae(y(n,{indexes:[0],data:r,datum:l[0],positionH:"normal"})),p=[],g=[],m=[],v=10,b=v+70+10,_=b+30,x=6;if(l.length>1){const w=d.height/2+x,C=(l.length-1)*(d.height+i)+d.height/2-x,P=`M ${b} ${w} L ${b} ${C}`,O="gradient-timeline-line",$=C-w,S=l.map((M,I)=>{const A=(I*(d.height+i)+d.height/2-w)/$*100,T=He(o,[I]);return y("stop",{offset:`${A}%`,stopColor:T||u})});m.push(k(tt,{children:[y(Ke,{children:y("linearGradient",{id:O,x1:b,y1:w,x2:b,y2:C,gradientUnits:"userSpaceOnUse",children:S})}),y(Ce,{d:P,stroke:`url(#${O})`,strokeWidth:2,width:1,height:C-w})]}))}if(l.forEach((w,C)=>{const P=C*(d.height+i),O=P+d.height/2,$=[C];m.push(y(Ne,{x:v,y:O,width:70,fontSize:18,fontWeight:"bold",alignHorizontal:"left",alignVertical:"middle",fill:h[C%h.length],children:`STEP ${C+1}`})),g.push(y(n,{indexes:$,datum:w,data:r,x:_,y:P,positionH:"normal"})),m.push(y(Ze,{x:b-x,y:O-x,width:x*2,height:x*2,fill:h[C%h.length]})),p.push(y(nt,{indexes:$,x:_-f.width-10,y:P+(d.height-f.height)/2})),C===0?p.push(y(Q,{indexes:$,x:_+(d.width-f.width)/2,y:P-f.height-10})):p.push(y(Q,{indexes:$,x:_+(d.width-f.width)/2,y:P-i/2-f.height/2}))}),l.length>0){const w=(l.length-1)*(d.height+i);p.push(y(Q,{indexes:[l.length],x:_+(d.width-f.width)/2,y:w+d.height+10}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[c,k(Y,{children:[y(Pt,{children:m}),y(ze,{children:g}),y(qe,{children:p})]})]})};We("sequence-timeline",{component:yS,composites:["title","item"]});const fm=120,dm=108,Gl=30,uie="M4.49144e-05 34.4898C4.49144e-05 37.8786 0.848973 41.152 2.43571 44.2444C4.23516 47.7642 6.98514 51.0472 10.517 54.0009C21.331 63.047 39.4615 68.9814 59.9991 68.9814C80.5385 68.9814 98.6672 63.047 109.483 54.0009C113.013 51.0472 115.765 47.7642 117.564 44.2444C119.149 41.152 120 37.8786 120 34.4898C120 15.4407 93.1364 0 59.9991 0C26.8635 0 4.49144e-05 15.4407 4.49144e-05 34.4898Z",hie="M4.49145e-05 34.4898V53.9991C4.49145e-05 57.3879 0.848973 60.6613 2.43571 63.7556C9.75425 78.0545 32.7562 88.4907 59.999 88.4907C87.2438 88.4907 110.246 78.0545 117.564 63.7556C119.149 60.6613 120 57.3879 120 53.9991V34.4898C120 37.8786 119.149 41.152 117.564 44.2444C115.765 47.7642 113.013 51.0472 109.483 54.0009C98.6672 63.047 80.5385 68.9814 59.999 68.9814C39.4615 68.9814 21.3309 63.047 10.5169 54.0009C6.98509 51.0472 4.23516 47.7642 2.43567 44.2444C0.848928 41.152 4.49145e-05 37.8786 4.49145e-05 34.4898Z",fie="M0 53.9991V73.5102C0 92.5593 26.8634 108 59.999 108C93.1363 108 120 92.5593 120 73.5102V53.9991C120 57.3879 119.149 60.6613 117.564 63.7556C110.246 78.0545 87.2438 88.4907 59.999 88.4907C32.7562 88.4907 9.75425 78.0545 2.43571 63.7556C0.848973 60.6613 0 57.3879 0 53.9991Z",vS=k("filter",{id:"sequence-zigzag-pucks-3d-shadow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[y("feOffset",{dx:"-7",dy:"7",in:"SourceAlpha",result:"offset"}),y("feGaussianBlur",{stdDeviation:"7.5",in:"offset",result:"blurred"}),y("feColorMatrix",{in:"blurred",type:"matrix",values:`0 0 0 0 0
|
|
144
144
|
0 0 0 0 0
|
|
145
145
|
0 0 0 0 0
|
|
146
|
-
0 0 0 0.3 0`,result:"shadow"}),p("feBlend",{mode:"normal",in:"SourceGraphic",in2:"shadow"})]}),$C=e=>{const{Title:t,Item:n,data:r,options:i,gap:o=80}=e,a=X1,s=U1,{title:c,desc:l,items:u=[]}=r,h=t?p(t,{title:c,desc:l}):null,d=wt(i);if(u.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[p(Ke,{children:PC}),h,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const f=se(p(n,{indexes:[0],data:r,datum:u[0],positionH:"center"})),g=se(p(Q,{indexes:[0]})),y=[],m=[],v=[];let b=-1/0;const _=f.height+Nc+s;return u.forEach((x,w)=>{const P=[w],$=qe(i,P),C=w%2===0,M=w*(a+o),S=C?0:f.height+Nc,E=`puck-gradient-middle-${w}`,A=`puck-gradient-bottom-${w}`;v.push(L(Y,{x:M,y:S,id:`puck-${w}`,width:a,height:s,filter:"url(#sequence-zigzag-pucks-3d-shadow-filter)",children:[L(Ke,{children:[L("linearGradient",{id:E,x1:"115",y1:"55.9991",x2:"15.0002",y2:"55.9991",gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0",stopColor:$||d}),p("stop",{offset:"1",stopColor:$||d,stopOpacity:"0.6"})]}),L("linearGradient",{id:A,x1:"115",y1:"72.1803",x2:"15.0002",y2:"72.1803",gradientUnits:"userSpaceOnUse",children:[p("stop",{offset:"0",stopColor:"#F4F4FB"}),p("stop",{offset:"1",stopColor:"#8E8C90"})]})]}),L(xt,{width:X1,height:U1,children:[p(Pe,{d:Lne,fill:$||d}),p(Pe,{d:zne,fill:`url(#${E})`}),p(Pe,{d:Nne,fill:`url(#${A})`}),p("rect",{fill:"transparent",y:U1,width:X1,height:20})]}),p("text",{x:65,y:40,width:50,height:50,fontSize:40,fontWeight:"bold",fill:"#FFFFFF",textAnchor:"middle",dominantBaseline:"middle",transform:"rotate(-15 65 40) scale(1, 0.8)",children:w+1})]}));const O=M+(a-f.width)/2,T=C?S+s+Nc:S-Nc-f.height;if(b=Math.max(b,T+f.height),m.push(p(n,{indexes:P,datum:x,data:r,x:O,y:T,positionH:"center"})),y.push(p(nt,{indexes:P,x:O+f.width-g.width/2,y:T+f.height-g.height/2})),w===0&&y.push(p(Q,{indexes:[0],x:M+a/2-g.width/2-(o+a)/2,y:S+s/2-g.height/2})),w<u.length-1){const z=(w+1)%2===0?0:_,j=M+a+o/2-g.width/2,D=(S+s/2+z+s/2)/2-g.height/2;y.push(p(Q,{indexes:[w+1],x:j,y:D}))}else y.push(p(Q,{indexes:[u.length],x:M+a+o/2-g.width/2,y:S+s/2-g.height/2}))}),L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[p(Ke,{children:PC}),h,L(Y,{x:0,y:0,children:[p(Y,{children:v}),p(Ne,{children:m}),p(He,{children:y})]})]})};We("sequence-zigzag-pucks-3d",{component:$C,composites:["title","item"]});const Dne=240,Hne=130,qne=105,Yr=12,jne=120,CC=50,Fne=.6,Bne="M132.821 50.6599L87.6795 76.8925C78.0629 82.4807 62.4238 82.4807 52.7445 76.8925L7.30824 50.6599C2.43719 47.8482 0.00459679 44.1562 0.0152907 40.472L3.17695e-05 45.6925C-0.0101404 49.378 2.42245 53.0686 7.29298 55.8803L52.7289 82.1129C62.4094 87.7011 78.0485 87.7011 87.6652 82.1129L132.806 55.8803C137.583 53.1038 139.975 49.4705 139.986 45.832L140 40.6116C139.989 44.2501 137.598 47.8834 132.821 50.6599Z",OC="M132.707 30.4224C142.386 36.0119 142.437 45.0704 132.821 50.6599L87.6795 76.8925C78.0629 82.4807 62.4238 82.4807 52.7445 76.8925L7.30825 50.6599C-2.37126 45.0717 -2.42225 36.0132 7.19414 30.4237L52.335 4.19115C61.9517 -1.39705 77.5908 -1.39705 87.2713 4.19115L132.707 30.4224Z",SC=70+Yr/2,MC=40+Yr/2,EC=p("filter",{id:"sequence-zigzag-glow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",children:p("feGaussianBlur",{in:"SourceGraphic",stdDeviation:"15",result:"blur"})}),IC=e=>{var t;const{Title:n,Item:r,data:i,options:o,dx:a=Dne,dy:s=Hne,iconSize:c=30}=e,{title:l,desc:u,items:h=[]}=i,d=n?p(n,{title:l,desc:u}):null,f=wt(o);if(h.length===0)return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[p(Ke,{children:EC}),d,p(Y,{children:p(He,{children:p(Q,{indexes:[0],x:0,y:0})})})]});const g=se(p(r,{indexes:[0],data:i,datum:h[0]})),y=se(p(Q,{indexes:[0]})),m=[],v=[],b=[],_=[],x=[];let w=0,P=0,$="",C=1/0,M=-1/0,S=1/0,E=1/0;const A=[];h.forEach((F,z)=>{const j=w,D=P;A.push({x:j,y:D}),C=Math.min(C,D);const W=j-SC,B=D-MC;S=Math.min(S,W),E=Math.min(E,B);const X=z%2===0;z<h.length-1&&(w+=a,P=X?P+s:P-s)});const O=Math.max(0,-S),T=Math.max(0,-E);if(w=0,P=0,h.forEach((F,z)=>{const j=[z],D=A[z],W=D.x+O,B=D.y+T,X=qe(o,j),H=Math.max(0,W-SC),k=Math.max(0,B-MC),I=10,R=CC+10,{colorPrimaryBg:N}=Ct({colorPrimary:X});if(_.push(L(xt,{x:H,y:k,width:140,height:110,children:[p(Ze,{x:I,y:R,width:jne,height:CC,fill:X||f,filter:"url(#sequence-zigzag-glow-filter)",opacity:Fne}),p(Pe,{d:Bne,fill:X||f}),p(Pe,{d:OC,fill:"#fff"}),p(Pe,{d:OC,fill:N||N})]})),F.icon){const U=Math.max(0,W-c/2-Yr/2),K=Math.max(0,B-c/2-Yr/2);x.push(p(Ht,{x:U,y:K,size:c,indexes:j,fill:X}))}const q=W-g.width/2-Yr/2,G=Math.max(0,B+qne-Yr/2);if(M=Math.max(M,G+g.height),z===0?$=`M ${W} ${B}`:$+=` L ${W} ${B}`,v.push(p(r,{indexes:j,datum:F,data:i,x:q,y:G})),m.push(p(nt,{indexes:j,x:Math.max(0,q+g.width-y.width/2),y:Math.max(0,G+g.height-y.height/2)})),z<h.length-1){const U=A[z+1],K=U.x+O,oe=U.y+T,te=Math.max(0,W+(K-W)/2-y.width/2),ae=Math.max(0,B+(oe-B)/2-y.height/2);m.push(p(Q,{indexes:[z+1],x:te,y:ae}))}else m.push(p(Q,{indexes:[h.length],x:Math.max(0,q+g.width+a/4),y:Math.max(0,G+g.height/2-y.height/2)}))}),$){const F=(((t=A[A.length-1])==null?void 0:t.x)||0)+O;b.push(p(Pe,{d:$,stroke:"#f3f2f1",strokeWidth:Yr,fill:"none",width:F,height:M-Math.min(C+T,0)}))}return L(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[p(Ke,{children:EC}),d,L(Y,{x:0,y:0,children:[p(Y,{children:[...b,..._,...x]}),p(Ne,{children:v}),p(He,{children:m})]})]})};We("sequence-zigzag-steps",{component:IC,composites:["title","item"]});class fr{init(t){Object.assign(this,t)}}class AC{constructor(t,n={}){this.clickTimer=null,this.singleClickCallback=null,this.doubleClickCallback=null,this.pointerId=null,this.startX=0,this.startY=0,this.skipClick=!1,this.dragged=!1,this.handlePointerDown=i=>{this.pointerId=i.pointerId,this.startX=i.clientX,this.startY=i.clientY,this.dragged=!1,this.skipClick=!1,window.addEventListener("pointermove",this.handlePointerMove,{passive:!0}),window.addEventListener("pointerup",this.handlePointerUp,{passive:!0}),window.addEventListener("pointercancel",this.handlePointerUp,{passive:!0})},this.handlePointerMove=i=>{if(this.pointerId===null||i.pointerId!==this.pointerId)return;const o=i.clientX-this.startX,a=i.clientY-this.startY;Math.hypot(o,a)>this.dragThreshold&&(this.skipClick=!0,this.dragged=!0)},this.handlePointerUp=i=>{this.pointerId!==null&&i.pointerId===this.pointerId&&(this.pointerId=null,window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp),this.dragged||(this.skipClick=!1),this.dragged=!1)};var r;this.element=t,this.delay=n.delay||300,this.dragThreshold=(r=n.dragThreshold)!=null?r:4,this.init()}init(){this.element.addEventListener("click",this.handleClick.bind(this)),this.element.addEventListener("dblclick",this.handleDoubleClick.bind(this)),this.element.addEventListener("pointerdown",this.handlePointerDown)}handleClick(t){if(this.skipClick){this.skipClick=!1;return}this.clickTimer&&clearTimeout(this.clickTimer),this.clickTimer=window.setTimeout(()=>{var n;(n=this.singleClickCallback)==null||n.call(this,t)},this.delay)}handleDoubleClick(t){var n;if(this.skipClick){this.skipClick=!1;return}this.clickTimer&&clearTimeout(this.clickTimer),(n=this.doubleClickCallback)==null||n.call(this,t)}onClick(t){return this.singleClickCallback=t,this}onDoubleClick(t){return this.doubleClickCallback=t,this}destroy(){this.clickTimer&&clearTimeout(this.clickTimer),this.element.removeEventListener("click",this.handleClick),this.element.removeEventListener("dblclick",this.handleDoubleClick),this.element.removeEventListener("pointerdown",this.handlePointerDown),window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}}function Wne(e){var t;return((t=e.getScreenCTM())==null?void 0:t.inverse())||new DOMMatrix}function Xr(e,t,n){return new DOMPoint(t,n).matrixTransform(Wne(e))}function Yn(e,t){const n=t.getBoundingClientRect(),i=[{x:n.x,y:n.y},{x:n.x+n.width,y:n.y},{x:n.x,y:n.y+n.height},{x:n.x+n.width,y:n.y+n.height}].map(l=>Xr(e,l.x,l.y)),o=Math.min(...i.map(l=>l.x)),a=Math.max(...i.map(l=>l.x)),s=Math.min(...i.map(l=>l.y)),c=Math.max(...i.map(l=>l.y));return new DOMRect(o,s,a-o,c-s)}function TC(e,t){if(t.length===0)return e.data;const n=no(e,t);return n.children||(n.children=[]),n.children}function Gne(e,t="data.items"){return e.reduce((n,r,i)=>i===0?`${n}[${r}]`:`${n}.children[${r}]`,t)}function kC(e){var t,n;return((n=(t=Vne(e))==null?void 0:t.dataset.indexes)==null?void 0:n.split(",").map(Number))||[]}function Vne(e){return cr(e)?ss(e):e}function Dc(e){if(!e)return null;const t=[Yne];let n=e;for(const r of t){const i=r(n);if(i){n=i;break}}return RC(n)}function RC(e){if(!e)return null;const t=[Xne,Une];for(const n of t){const r=n(e);if(r)return r}return MD(e)||Fn(e)||cr(e)?e:null}const Yne=e=>{var t;const n=r=>r?ID(r)||AD(r):!1;return n(e)?e.parentElement:n(e.parentElement)?(t=e.parentElement)==null?void 0:t.parentElement:null},Xne=e=>TD(e)&&Tb(e.parentElement)?e.parentElement:null,Une=e=>{const t=e.parentElement;return Ab(t)?t:ju(e)?e:null};class LC{constructor(){this.extensions=new Map}register(t,n,r){if(!(r!=null&&r.override)&&this.extensions.has(t))throw new Error(`Extension "${t}" already registered`);this.extensions.set(t,n)}get(t){return this.extensions.get(t)}has(t){return this.extensions.has(t)}getAll(){return this.extensions}forEach(t){this.extensions.forEach((n,r)=>{t(n,r)})}[Symbol.iterator](){return this.extensions.entries()}unregister(t){return this.extensions.delete(t)}destroy(){this.extensions.forEach(t=>{t&&typeof t.dispose=="function"&&t.dispose()}),this.extensions.clear()}}const Kne=e=>{if(!e||!(e instanceof HTMLElement))return!1;if(e.isContentEditable)return!0;const t=e.tagName.toLowerCase();return t==="input"||t==="textarea"||t==="select"},Zne=e=>{const t=e.toLowerCase().split("+").map(r=>r.trim()).filter(Boolean),n={key:""};if(t.forEach(r=>{r==="shift"?n.shift=!0:r==="alt"||r==="option"?n.alt=!0:r==="ctrl"||r==="control"?n.ctrl=!0:r==="meta"||r==="cmd"||r==="command"?n.meta=!0:r==="mod"?n.mod=!0:n.key=r}),!n.key)throw new Error(`Invalid hotkey combo: "${e}"`);return n},Qne=(e,t)=>{var n;if(e.key.toLowerCase()!==t.key)return!1;const i=(n=t.mod)!=null?n:!1,o=e.metaKey,a=e.ctrlKey,s=o||a,c=(l,u)=>l===void 0?!u:l===u;return i&&!s?!1:i?!(!c(t.shift,e.shiftKey)||!c(t.alt,e.altKey)||t.meta!==void 0&&!c(t.meta,o)||t.ctrl!==void 0&&!c(t.ctrl,a)):!(!c(t.meta,o)||!c(t.ctrl,a)||!c(t.shift,e.shiftKey)||!c(t.alt,e.altKey))};class Jne{constructor(t={}){this.bindings=[],this.handleKeydown=i=>{if(i instanceof KeyboardEvent&&!i.defaultPrevented&&!Kne(i.target)&&!(this.filter&&!this.filter(i))){for(const o of this.bindings)if(o.combos.some(a=>Qne(i,a))){o.handler(i);break}}};const{target:n=document,filter:r}=t;this.target=n,this.filter=r,this.target.addEventListener("keydown",this.handleKeydown)}bind(t,n){const i={combos:(Array.isArray(t)?t:[t]).map(o=>Zne(o)),handler:n};return this.bindings.push(i),()=>this.unbind(i)}destroy(){this.target.removeEventListener("keydown",this.handleKeydown),this.bindings=[]}unbind(t){this.bindings=this.bindings.filter(n=>n!==t)}}var ere=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class zC extends fr{constructor(){super(...arguments),this.name="brush-select",this.shiftKey=!1,this.dragging=!1,this.dragThreshold=4,this.handleStart=t=>{this.interaction.isActive()&&t.button===0&&(this.isTextSelectionTarget(t.target)||this.hasElementAtStart(t.target)||this.interaction.executeExclusiveInteraction(this,()=>ere(this,null,function*(){return new Promise(n=>{this.completeInteraction=n;const r=this.editor.getDocument();this.startPoint=Xr(r,t.clientX,t.clientY),this.pointerId=t.pointerId,this.shiftKey=t.shiftKey,this.dragging=!1,window.addEventListener("pointermove",this.handleMove),window.addEventListener("pointerup",this.handleEnd)})})))},this.handleMove=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;const n=this.editor.getDocument(),r=Xr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if(!this.dragging){if(Math.hypot(i,o)<this.dragThreshold)return;this.dragging=!0,this.ensureBrush(),this.updateBrush(this.startPoint,r)}t.preventDefault(),t.stopPropagation(),this.updateBrush(this.startPoint,r)},this.handleEnd=t=>{var n,r;if(t.pointerId!==this.pointerId||!this.startPoint)return;window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd);let i=null;if(this.dragging){t.preventDefault(),t.stopPropagation();const c=this.editor.getDocument(),l=Xr(c,t.clientX,t.clientY);i=this.updateBrush(this.startPoint,l),this.clearBrush()}this.pointerId=void 0,this.startPoint=void 0,this.dragging=!1;const o=this.shiftKey;if(this.shiftKey=!1,!i){(n=this.completeInteraction)==null||n.call(this),this.completeInteraction=void 0;return}const a=this.collectSelection(i);if((r=this.completeInteraction)==null||r.call(this),this.completeInteraction=void 0,a.length===0){o||this.interaction.clearSelection();return}const s=o?"add":"replace";this.interaction.select(a,s)}}init(t){super.init(t),this.editor.getDocument().addEventListener("pointerdown",this.handleStart)}destroy(){this.clearBrush(),this.editor.getDocument().removeEventListener("pointerdown",this.handleStart),window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd)}ensureBrush(){return this.brush?this.brush:(this.brush=this.interaction.appendTransientElement(Ee("rect",{fill:"rgba(51, 132, 245, 0.08)",stroke:"#3384F5","stroke-dasharray":"4 2","stroke-width":1,"pointer-events":"none"})),this.brush)}updateBrush(t,n){if(!this.brush)return null;const r=Math.min(t.x,n.x),i=Math.min(t.y,n.y),o=Math.abs(t.x-n.x),a=Math.abs(t.y-n.y);return lt(this.brush,{x:r,y:i,width:o,height:a}),{x:r,y:i,width:o,height:a}}clearBrush(){var t;(t=this.brush)==null||t.remove(),this.brush=void 0}collectSelection(t){const n=this.editor.getDocument(),r=Array.from(n.querySelectorAll("[data-element-type]")),i=(a,s)=>{const c=a.x+a.width,l=a.y+a.height,u=s.x+s.width,h=s.y+s.height;return!(c<s.x||u<a.x||l<s.y||h<a.y)},o=new Set;return r.reduce((a,s)=>{const c=RC(s);if(!c||o.has(c))return a;const l=Yn(n,c),u={x:l.x,y:l.y,width:l.width,height:l.height};return i(t,u)&&(a.push(c),o.add(c)),a},[])}hasElementAtStart(t){var n;return t instanceof Element?Dc(t)?!0:!!((n=t.closest)!=null&&n.call(t,"[data-element-type]")):!1}isTextSelectionTarget(t){if(!(t instanceof HTMLElement))return!1;if(t.isContentEditable)return!0;const n=t.tagName.toLowerCase();return n==="input"||n==="textarea"}}var tre=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class NC extends fr{constructor(){super(...arguments),this.name="click-select",this.shiftKey=!1,this.onShiftKeyDown=t=>{t.key==="Shift"&&(this.shiftKey=!0)},this.onShiftKeyUp=t=>{t.key==="Shift"&&(this.shiftKey=!1)},this.onEscKeyDown=t=>{t.key==="Escape"&&this.interaction.clearSelection()}}init(t){super.init(t);const{editor:n,interaction:r}=this;this.clickHandler=new AC(n.getDocument(),{delay:0});const i=o=>{r.isActive()&&r.executeExclusiveInteraction(this,()=>tre(this,null,function*(){const a=Dc(o.target);kb(a)||(this.shiftKey?a&&(r.isSelected(a)?r.select([a],"remove"):r.select([a],"add")):a?r.select([a],"replace"):r.clearSelection())}))};this.clickHandler.onClick(i),document.addEventListener("keydown",this.onShiftKeyDown),document.addEventListener("keyup",this.onShiftKeyUp),document.addEventListener("keydown",this.onEscKeyDown)}destroy(){var t;(t=this.clickHandler)==null||t.destroy(),document.removeEventListener("keydown",this.onShiftKeyDown),document.removeEventListener("keyup",this.onShiftKeyUp),document.removeEventListener("keydown",this.onEscKeyDown)}}var DC=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class nre{constructor(t){this.commands=t}apply(t){return DC(this,null,function*(){for(const n of this.commands)yield n.apply(t)})}undo(t){return DC(this,null,function*(){for(let n=this.commands.length-1;n>=0;n--)yield this.commands[n].undo(t)})}serialize(){return{type:"batch",commands:this.commands.map(t=>t.serialize())}}}var rre=Object.defineProperty,ire=Object.defineProperties,ore=Object.getOwnPropertyDescriptors,HC=Object.getOwnPropertySymbols,are=Object.prototype.hasOwnProperty,sre=Object.prototype.propertyIsEnumerable,qC=(e,t,n)=>t in e?rre(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ko=(e,t)=>{for(var n in t||(t={}))are.call(t,n)&&qC(e,n,t[n]);if(HC)for(var n of HC(t))sre.call(t,n)&&qC(e,n,t[n]);return e},jC=(e,t)=>ire(e,ore(t)),FC=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class kn{constructor(t,n,r){this.element=t,this.modified=n;const i=cre(t,n);this.original=lre(i,r)}apply(t){return FC(this,null,function*(){BC(this.element,this.modified),t.updateElement(this.element,this.modified)})}undo(t){return FC(this,null,function*(){this.original&&(BC(this.element,this.original),t.updateElement(this.element,this.original))})}serialize(){return{type:"update-element",elementId:this.element.id,modified:this.modified,original:this.original}}}function BC(e,t){Fn(e)?Ib(e,t):cr(e)?UD(e,void 0,t.attributes):t.attributes&<(e,t.attributes)}function cre(e,t){const n=Object.keys(t.attributes||{}),r=sn(e,n,!1),i=a=>{a&&n.forEach(s=>{s in a&&(r[s]=a[s])})},o=jC(Ko({},t),{attributes:r});if(Fn(e)){const{attributes:a}=qu(e);i(a)}else if(cr(e)){if(!ss(e))return;i(Gu(e))}return o}function lre(e,t){if(!e)return t;if(!t)return e;const n=Ko(Ko({},e.attributes||{}),t.attributes||{});return jC(Ko(Ko({},e),t),{attributes:Object.keys(n).length?n:void 0})}var ure=Object.defineProperty,WC=Object.getOwnPropertySymbols,hre=Object.prototype.hasOwnProperty,dre=Object.prototype.propertyIsEnumerable,GC=(e,t,n)=>t in e?ure(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,VC=(e,t)=>{for(var n in t||(t={}))hre.call(t,n)&&GC(e,n,t[n]);if(WC)for(var n of WC(t))dre.call(t,n)&&GC(e,n,t[n]);return e},YC=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class fre{constructor(t,n){this.options=t,this.original=n}apply(t){return YC(this,null,function*(){const n=t.getOptions();this.original||(this.original=n),t.updateOptions(VC(VC({},n),this.options))})}undo(t){return YC(this,null,function*(){this.original&&t.updateOptions(this.original)})}serialize(){return{type:"update-options",options:this.options,original:this.original}}}var XC=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class pre{constructor(t,n,r){this.element=t,this.originalText=r!=null?r:is(t),this.modifiedText=n}apply(t){return XC(this,null,function*(){this.originalText!==this.modifiedText&&(Hu(this.element,this.modifiedText),UC(t,this.element,this.modifiedText))})}undo(t){return XC(this,null,function*(){this.originalText!==this.modifiedText&&(Hu(this.element,this.originalText),UC(t,this.element,this.originalText))})}serialize(){return{type:"update-text",elementId:this.element.id,original:this.originalText,modified:this.modifiedText}}}function UC(e,t,n){const r=Fu(t);if(r.startsWith("item-")){const i=r.replace("item-",""),o=kC(t);e.updateItemDatum(o,{[i]:n})}else e.updateData(r,n)}var gre=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class KC extends fr{constructor(){super(...arguments),this.name="dblclick-edit-text"}init(t){super.init(t);const{editor:n,commander:r,interaction:i}=t;this.clickHandler=new AC(n.getDocument()).onDoubleClick(o=>{i.isActive()&&i.executeExclusiveInteraction(this,()=>gre(this,null,function*(){const a=Dc(o.target);if(a&&Fn(a)){i.select([a],"replace");const s=is(a),c=yield new Promise(l=>{const u=this.listenSelectionChange(a);yre(a,{cursorPosition:{clientX:o.clientX,clientY:o.clientY},onBlur:l,onCancel:l}),this.detachSelectionListener=u});r.execute(new pre(a,c,s))}}))})}destroy(){var t,n;(t=this.clickHandler)==null||t.destroy(),(n=this.detachSelectionListener)==null||n.call(this)}listenSelectionChange(t){const n=({next:r})=>{var i;if(!r.includes(t)){(i=this.detachSelectionListener)==null||i.call(this),this.detachSelectionListener=void 0;const o=Ir(t);o&&o.blur()}};return this.emitter.on("selection:change",n),()=>this.emitter.off("selection:change",n)}}const mre="infographic-inline-text-editor-style",Hc="infographic-inline-text-editor";function yre(e,t){const n=Ir(e);n&&(bre(),new vre(n,t).start())}class vre{constructor(t,n){this.entity=t,this.options=n,this.handlePaste=r=>{r.clipboardData&&(r.preventDefault(),this.insertPlainText(r.clipboardData.getData("text/plain")))},this.handleKeydown=r=>{r.key==="Enter"&&!r.shiftKey&&(r.preventDefault(),this.insertPlainText(`
|
|
147
|
-
`))},this.handleInput=()=>{var r,i;this.normalizeSpanContent(),(i=(r=this.options)==null?void 0:r.onInput)==null||i.call(r,this.getText())},this.handleBlur=()=>{var r,i;this.entity.removeAttribute("contenteditable"),this.entity.classList.remove(
|
|
148
|
-
.${
|
|
146
|
+
0 0 0 0.3 0`,result:"shadow"}),y("feBlend",{mode:"normal",in:"SourceGraphic",in2:"shadow"})]}),bS=e=>{const{Title:t,Item:n,data:r,options:i,gap:o=80}=e,s=fm,a=dm,{title:l,desc:c,items:u=[]}=r,h=t?y(t,{title:l,desc:c}):null,f=Ot(i);if(u.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[y(Ke,{children:vS}),h,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const d=ae(y(n,{indexes:[0],data:r,datum:u[0],positionH:"center"})),p=ae(y(Q,{indexes:[0]})),g=[],m=[],v=[];let b=-1/0;const _=d.height+Gl+a;return u.forEach((x,w)=>{const C=[w],P=He(i,C),O=w%2===0,$=w*(s+o),S=O?0:d.height+Gl,M=`puck-gradient-middle-${w}`,I=`puck-gradient-bottom-${w}`;v.push(k(Y,{x:$,y:S,id:`puck-${w}`,width:s,height:a,filter:"url(#sequence-zigzag-pucks-3d-shadow-filter)",children:[k(Ke,{children:[k("linearGradient",{id:M,x1:"115",y1:"55.9991",x2:"15.0002",y2:"55.9991",gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0",stopColor:P||f}),y("stop",{offset:"1",stopColor:P||f,stopOpacity:"0.6"})]}),k("linearGradient",{id:I,x1:"115",y1:"72.1803",x2:"15.0002",y2:"72.1803",gradientUnits:"userSpaceOnUse",children:[y("stop",{offset:"0",stopColor:"#F4F4FB"}),y("stop",{offset:"1",stopColor:"#8E8C90"})]})]}),k(Pt,{width:fm,height:dm,children:[y(Ce,{d:uie,fill:P||f}),y(Ce,{d:hie,fill:`url(#${M})`}),y(Ce,{d:fie,fill:`url(#${I})`}),y("rect",{fill:"transparent",y:dm,width:fm,height:20})]}),y("text",{x:65,y:40,width:50,height:50,fontSize:40,fontWeight:"bold",fill:"#FFFFFF",textAnchor:"middle",dominantBaseline:"middle",transform:"rotate(-15 65 40) scale(1, 0.8)",children:w+1})]}));const E=$+(s-d.width)/2,A=O?S+a+Gl:S-Gl-d.height;if(b=Math.max(b,A+d.height),m.push(y(n,{indexes:C,datum:x,data:r,x:E,y:A,positionH:"center"})),g.push(y(nt,{indexes:C,x:E+d.width-p.width/2,y:A+d.height-p.height/2})),w===0&&g.push(y(Q,{indexes:[0],x:$+s/2-p.width/2-(o+s)/2,y:S+a/2-p.height/2})),w<u.length-1){const N=(w+1)%2===0?0:_,H=$+s+o/2-p.width/2,D=(S+a/2+N+a/2)/2-p.height/2;g.push(y(Q,{indexes:[w+1],x:H,y:D}))}else g.push(y(Q,{indexes:[u.length],x:$+s+o/2-p.width/2,y:S+a/2-p.height/2}))}),k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[y(Ke,{children:vS}),h,k(Y,{x:0,y:0,children:[y(Y,{children:v}),y(ze,{children:m}),y(qe,{children:g})]})]})};We("sequence-zigzag-pucks-3d",{component:bS,composites:["title","item"]});const die=240,pie=130,gie=105,Zr=12,mie=120,_S=50,yie=.6,vie="M132.821 50.6599L87.6795 76.8925C78.0629 82.4807 62.4238 82.4807 52.7445 76.8925L7.30824 50.6599C2.43719 47.8482 0.00459679 44.1562 0.0152907 40.472L3.17695e-05 45.6925C-0.0101404 49.378 2.42245 53.0686 7.29298 55.8803L52.7289 82.1129C62.4094 87.7011 78.0485 87.7011 87.6652 82.1129L132.806 55.8803C137.583 53.1038 139.975 49.4705 139.986 45.832L140 40.6116C139.989 44.2501 137.598 47.8834 132.821 50.6599Z",wS="M132.707 30.4224C142.386 36.0119 142.437 45.0704 132.821 50.6599L87.6795 76.8925C78.0629 82.4807 62.4238 82.4807 52.7445 76.8925L7.30825 50.6599C-2.37126 45.0717 -2.42225 36.0132 7.19414 30.4237L52.335 4.19115C61.9517 -1.39705 77.5908 -1.39705 87.2713 4.19115L132.707 30.4224Z",xS=70+Zr/2,CS=40+Zr/2,PS=y("filter",{id:"sequence-zigzag-glow-filter",x:"-50%",y:"-50%",width:"200%",height:"200%",children:y("feGaussianBlur",{in:"SourceGraphic",stdDeviation:"15",result:"blur"})}),OS=e=>{var t;const{Title:n,Item:r,data:i,options:o,dx:s=die,dy:a=pie,iconSize:l=30}=e,{title:c,desc:u,items:h=[]}=i,f=n?y(n,{title:c,desc:u}):null,d=Ot(o);if(h.length===0)return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",children:[y(Ke,{children:PS}),f,y(Y,{children:y(qe,{children:y(Q,{indexes:[0],x:0,y:0})})})]});const p=ae(y(r,{indexes:[0],data:i,datum:h[0]})),g=ae(y(Q,{indexes:[0]})),m=[],v=[],b=[],_=[],x=[];let w=0,C=0,P="",O=1/0,$=-1/0,S=1/0,M=1/0;const I=[];h.forEach((T,N)=>{const H=w,D=C;I.push({x:H,y:D}),O=Math.min(O,D);const B=H-xS,F=D-CS;S=Math.min(S,B),M=Math.min(M,F);const X=N%2===0;N<h.length-1&&(w+=s,C=X?C+a:C-a)});const E=Math.max(0,-S),A=Math.max(0,-M);if(w=0,C=0,h.forEach((T,N)=>{const H=[N],D=I[N],B=D.x+E,F=D.y+A,X=He(o,H),G=Math.max(0,B-xS),L=Math.max(0,F-CS),R=10,z=_S+10,{colorPrimaryBg:q}=Et({colorPrimary:X});if(_.push(k(Pt,{x:G,y:L,width:140,height:110,children:[y(Ze,{x:R,y:z,width:mie,height:_S,fill:X||d,filter:"url(#sequence-zigzag-glow-filter)",opacity:yie}),y(Ce,{d:vie,fill:X||d}),y(Ce,{d:wS,fill:"#fff"}),y(Ce,{d:wS,fill:q||q})]})),T.icon){const U=Math.max(0,B-l/2-Zr/2),K=Math.max(0,F-l/2-Zr/2);x.push(y(Ft,{x:U,y:K,size:l,indexes:H,fill:X}))}const j=B-p.width/2-Zr/2,V=Math.max(0,F+gie-Zr/2);if($=Math.max($,V+p.height),N===0?P=`M ${B} ${F}`:P+=` L ${B} ${F}`,v.push(y(r,{indexes:H,datum:T,data:i,x:j,y:V})),m.push(y(nt,{indexes:H,x:Math.max(0,j+p.width-g.width/2),y:Math.max(0,V+p.height-g.height/2)})),N<h.length-1){const U=I[N+1],K=U.x+E,ne=U.y+A,J=Math.max(0,B+(K-B)/2-g.width/2),se=Math.max(0,F+(ne-F)/2-g.height/2);m.push(y(Q,{indexes:[N+1],x:J,y:se}))}else m.push(y(Q,{indexes:[h.length],x:Math.max(0,j+p.width+s/4),y:Math.max(0,V+p.height/2-g.height/2)}))}),P){const T=(((t=I[I.length-1])==null?void 0:t.x)||0)+E;b.push(y(Ce,{d:P,stroke:"#f3f2f1",strokeWidth:Zr,fill:"none",width:T,height:$-Math.min(O+A,0)}))}return k(ve,{id:"infographic-container",flexDirection:"column",justifyContent:"center",alignItems:"center",gap:30,children:[y(Ke,{children:PS}),f,k(Y,{x:0,y:0,children:[y(Y,{children:[...b,..._,...x]}),y(ze,{children:v}),y(qe,{children:m})]})]})};We("sequence-zigzag-steps",{component:OS,composites:["title","item"]});class yr{init(t){Object.assign(this,t)}}class SS{constructor(t,n={}){this.clickTimer=null,this.singleClickCallback=null,this.doubleClickCallback=null,this.pointerId=null,this.startX=0,this.startY=0,this.skipClick=!1,this.dragged=!1,this.handlePointerDown=i=>{this.pointerId=i.pointerId,this.startX=i.clientX,this.startY=i.clientY,this.dragged=!1,this.skipClick=!1,window.addEventListener("pointermove",this.handlePointerMove,{passive:!0}),window.addEventListener("pointerup",this.handlePointerUp,{passive:!0}),window.addEventListener("pointercancel",this.handlePointerUp,{passive:!0})},this.handlePointerMove=i=>{if(this.pointerId===null||i.pointerId!==this.pointerId)return;const o=i.clientX-this.startX,s=i.clientY-this.startY;Math.hypot(o,s)>this.dragThreshold&&(this.skipClick=!0,this.dragged=!0)},this.handlePointerUp=i=>{this.pointerId!==null&&i.pointerId===this.pointerId&&(this.pointerId=null,window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp),this.dragged||(this.skipClick=!1),this.dragged=!1)};var r;this.element=t,this.delay=n.delay||300,this.dragThreshold=(r=n.dragThreshold)!=null?r:4,this.init()}init(){this.element.addEventListener("click",this.handleClick.bind(this)),this.element.addEventListener("dblclick",this.handleDoubleClick.bind(this)),this.element.addEventListener("pointerdown",this.handlePointerDown)}handleClick(t){if(this.skipClick){this.skipClick=!1;return}this.clickTimer&&clearTimeout(this.clickTimer),this.clickTimer=window.setTimeout(()=>{var n;(n=this.singleClickCallback)==null||n.call(this,t)},this.delay)}handleDoubleClick(t){var n;if(this.skipClick){this.skipClick=!1;return}this.clickTimer&&clearTimeout(this.clickTimer),(n=this.doubleClickCallback)==null||n.call(this,t)}onClick(t){return this.singleClickCallback=t,this}onDoubleClick(t){return this.doubleClickCallback=t,this}destroy(){this.clickTimer&&clearTimeout(this.clickTimer),this.element.removeEventListener("click",this.handleClick),this.element.removeEventListener("dblclick",this.handleDoubleClick),this.element.removeEventListener("pointerdown",this.handlePointerDown),window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}}function bie(e){var t;return((t=e.getScreenCTM())==null?void 0:t.inverse())||new DOMMatrix}function Qr(e,t,n){return new DOMPoint(t,n).matrixTransform(bie(e))}function Zn(e,t){const n=t.getBoundingClientRect(),i=[{x:n.x,y:n.y},{x:n.x+n.width,y:n.y},{x:n.x,y:n.y+n.height},{x:n.x+n.width,y:n.y+n.height}].map(c=>Qr(e,c.x,c.y)),o=Math.min(...i.map(c=>c.x)),s=Math.max(...i.map(c=>c.x)),a=Math.min(...i.map(c=>c.y)),l=Math.max(...i.map(c=>c.y));return new DOMRect(o,a,s-o,l-a)}function $S(e,t){if(t.length===0)return e.data;const n=uo(e,t);return n.children||(n.children=[]),n.children}function _ie(e,t="data.items"){return e.reduce((n,r,i)=>i===0?`${n}[${r}]`:`${n}.children[${r}]`,t)}function ES(e){var t,n;return((n=(t=wie(e))==null?void 0:t.dataset.indexes)==null?void 0:n.split(",").map(Number))||[]}function wie(e){return fr(e)?ma(e):e}function Yl(e){if(!e)return null;const t=[xie];let n=e;for(const r of t){const i=r(n);if(i){n=i;break}}return MS(n)}function MS(e){if(!e)return null;const t=[Cie,Pie];for(const n of t){const r=n(e);if(r)return r}return rH(e)||Gn(e)||fr(e)?e:null}const xie=e=>{var t;const n=r=>r?oH(r)||sH(r):!1;return n(e)?e.parentElement:n(e.parentElement)?(t=e.parentElement)==null?void 0:t.parentElement:null},Cie=e=>aH(e)&&$_(e.parentElement)?e.parentElement:null,Pie=e=>{const t=e.parentElement;return S_(t)?t:oh(e)?e:null};class IS{constructor(){this.extensions=new Map}register(t,n,r){if(!(r!=null&&r.override)&&this.extensions.has(t))throw new Error(`Extension "${t}" already registered`);this.extensions.set(t,n)}get(t){return this.extensions.get(t)}has(t){return this.extensions.has(t)}getAll(){return this.extensions}forEach(t){this.extensions.forEach((n,r)=>{t(n,r)})}[Symbol.iterator](){return this.extensions.entries()}unregister(t){return this.extensions.delete(t)}destroy(){this.extensions.forEach(t=>{t&&typeof t.dispose=="function"&&t.dispose()}),this.extensions.clear()}}const Oie=e=>{if(!e||!(e instanceof HTMLElement))return!1;if(e.isContentEditable)return!0;const t=e.tagName.toLowerCase();return t==="input"||t==="textarea"||t==="select"},Sie=e=>{const t=e.toLowerCase().split("+").map(r=>r.trim()).filter(Boolean),n={key:""};if(t.forEach(r=>{r==="shift"?n.shift=!0:r==="alt"||r==="option"?n.alt=!0:r==="ctrl"||r==="control"?n.ctrl=!0:r==="meta"||r==="cmd"||r==="command"?n.meta=!0:r==="mod"?n.mod=!0:n.key=r}),!n.key)throw new Error(`Invalid hotkey combo: "${e}"`);return n},$ie=(e,t)=>{var n;if(e.key.toLowerCase()!==t.key)return!1;const i=(n=t.mod)!=null?n:!1,o=e.metaKey,s=e.ctrlKey,a=o||s,l=(c,u)=>c===void 0?!u:c===u;return i&&!a?!1:i?!(!l(t.shift,e.shiftKey)||!l(t.alt,e.altKey)||t.meta!==void 0&&!l(t.meta,o)||t.ctrl!==void 0&&!l(t.ctrl,s)):!(!l(t.meta,o)||!l(t.ctrl,s)||!l(t.shift,e.shiftKey)||!l(t.alt,e.altKey))};class Eie{constructor(t={}){this.bindings=[],this.handleKeydown=i=>{if(i instanceof KeyboardEvent&&!i.defaultPrevented&&!Oie(i.target)&&!(this.filter&&!this.filter(i))){for(const o of this.bindings)if(o.combos.some(s=>$ie(i,s))){o.handler(i);break}}};const{target:n=document,filter:r}=t;this.target=n,this.filter=r,this.target.addEventListener("keydown",this.handleKeydown)}bind(t,n){const i={combos:(Array.isArray(t)?t:[t]).map(o=>Sie(o)),handler:n};return this.bindings.push(i),()=>this.unbind(i)}destroy(){this.target.removeEventListener("keydown",this.handleKeydown),this.bindings=[]}unbind(t){this.bindings=this.bindings.filter(n=>n!==t)}}var Mie=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class AS extends yr{constructor(){super(...arguments),this.name="brush-select",this.shiftKey=!1,this.dragging=!1,this.dragThreshold=4,this.handleStart=t=>{this.interaction.isActive()&&t.button===0&&(this.isTextSelectionTarget(t.target)||this.hasElementAtStart(t.target)||this.interaction.executeExclusiveInteraction(this,()=>Mie(this,null,function*(){return new Promise(n=>{this.completeInteraction=n;const r=this.editor.getDocument();this.startPoint=Qr(r,t.clientX,t.clientY),this.pointerId=t.pointerId,this.shiftKey=t.shiftKey,this.dragging=!1,window.addEventListener("pointermove",this.handleMove),window.addEventListener("pointerup",this.handleEnd)})})))},this.handleMove=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;const n=this.editor.getDocument(),r=Qr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if(!this.dragging){if(Math.hypot(i,o)<this.dragThreshold)return;this.dragging=!0,this.ensureBrush(),this.updateBrush(this.startPoint,r)}t.preventDefault(),t.stopPropagation(),this.updateBrush(this.startPoint,r)},this.handleEnd=t=>{var n,r;if(t.pointerId!==this.pointerId||!this.startPoint)return;window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd);let i=null;if(this.dragging){t.preventDefault(),t.stopPropagation();const l=this.editor.getDocument(),c=Qr(l,t.clientX,t.clientY);i=this.updateBrush(this.startPoint,c),this.clearBrush()}this.pointerId=void 0,this.startPoint=void 0,this.dragging=!1;const o=this.shiftKey;if(this.shiftKey=!1,!i){(n=this.completeInteraction)==null||n.call(this),this.completeInteraction=void 0;return}const s=this.collectSelection(i);if((r=this.completeInteraction)==null||r.call(this),this.completeInteraction=void 0,s.length===0){o||this.interaction.clearSelection();return}const a=o?"add":"replace";this.interaction.select(s,a)}}init(t){super.init(t),this.editor.getDocument().addEventListener("pointerdown",this.handleStart)}destroy(){this.clearBrush(),this.editor.getDocument().removeEventListener("pointerdown",this.handleStart),window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd)}ensureBrush(){return this.brush?this.brush:(this.brush=this.interaction.appendTransientElement(Me("rect",{fill:"rgba(51, 132, 245, 0.08)",stroke:"#3384F5","stroke-dasharray":"4 2","stroke-width":1,"pointer-events":"none"})),this.brush)}updateBrush(t,n){if(!this.brush)return null;const r=Math.min(t.x,n.x),i=Math.min(t.y,n.y),o=Math.abs(t.x-n.x),s=Math.abs(t.y-n.y);return ut(this.brush,{x:r,y:i,width:o,height:s}),{x:r,y:i,width:o,height:s}}clearBrush(){var t;(t=this.brush)==null||t.remove(),this.brush=void 0}collectSelection(t){const n=this.editor.getDocument(),r=Array.from(n.querySelectorAll("[data-element-type]")),i=(s,a)=>{const l=s.x+s.width,c=s.y+s.height,u=a.x+a.width,h=a.y+a.height;return!(l<a.x||u<s.x||c<a.y||h<s.y)},o=new Set;return r.reduce((s,a)=>{const l=MS(a);if(!l||o.has(l))return s;const c=Zn(n,l),u={x:c.x,y:c.y,width:c.width,height:c.height};return i(t,u)&&(s.push(l),o.add(l)),s},[])}hasElementAtStart(t){var n;return t instanceof Element?Yl(t)?!0:!!((n=t.closest)!=null&&n.call(t,"[data-element-type]")):!1}isTextSelectionTarget(t){if(!(t instanceof HTMLElement))return!1;if(t.isContentEditable)return!0;const n=t.tagName.toLowerCase();return n==="input"||n==="textarea"}}var Iie=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class TS extends yr{constructor(){super(...arguments),this.name="click-select",this.shiftKey=!1,this.onShiftKeyDown=t=>{t.key==="Shift"&&(this.shiftKey=!0)},this.onShiftKeyUp=t=>{t.key==="Shift"&&(this.shiftKey=!1)},this.onEscKeyDown=t=>{t.key==="Escape"&&this.interaction.clearSelection()}}init(t){super.init(t);const{editor:n,interaction:r}=this;this.clickHandler=new SS(n.getDocument(),{delay:0});const i=o=>{r.isActive()&&r.executeExclusiveInteraction(this,()=>Iie(this,null,function*(){const s=Yl(o.target);E_(s)||(this.shiftKey?s&&(r.isSelected(s)?r.select([s],"remove"):r.select([s],"add")):s?r.select([s],"replace"):r.clearSelection())}))};this.clickHandler.onClick(i),document.addEventListener("keydown",this.onShiftKeyDown),document.addEventListener("keyup",this.onShiftKeyUp),document.addEventListener("keydown",this.onEscKeyDown)}destroy(){var t;(t=this.clickHandler)==null||t.destroy(),document.removeEventListener("keydown",this.onShiftKeyDown),document.removeEventListener("keyup",this.onShiftKeyUp),document.removeEventListener("keydown",this.onEscKeyDown)}}var RS=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class Aie{constructor(t){this.commands=t}apply(t){return RS(this,null,function*(){for(const n of this.commands)yield n.apply(t)})}undo(t){return RS(this,null,function*(){for(let n=this.commands.length-1;n>=0;n--)yield this.commands[n].undo(t)})}serialize(){return{type:"batch",commands:this.commands.map(t=>t.serialize())}}}var Tie=Object.defineProperty,Rie=Object.defineProperties,kie=Object.getOwnPropertyDescriptors,kS=Object.getOwnPropertySymbols,Lie=Object.prototype.hasOwnProperty,Nie=Object.prototype.propertyIsEnumerable,LS=(e,t,n)=>t in e?Tie(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,is=(e,t)=>{for(var n in t||(t={}))Lie.call(t,n)&&LS(e,n,t[n]);if(kS)for(var n of kS(t))Nie.call(t,n)&&LS(e,n,t[n]);return e},NS=(e,t)=>Rie(e,kie(t)),zS=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class zn{constructor(t,n,r){this.element=t,this.modified=n;const i=zie(t,n);this.original=Die(i,r)}apply(t){return zS(this,null,function*(){DS(this.element,this.modified),t.updateElement(this.element,this.modified)})}undo(t){return zS(this,null,function*(){this.original&&(DS(this.element,this.original),t.updateElement(this.element,this.original))})}serialize(){return{type:"update-element",elementId:this.element.id,modified:this.modified,original:this.original}}}function DS(e,t){Gn(e)?O_(e,t):fr(e)?PH(e,void 0,t.attributes):t.attributes&&ut(e,t.attributes)}function zie(e,t){const n=Object.keys(t.attributes||{}),r=cn(e,n,!1),i=s=>{s&&n.forEach(a=>{a in s&&(r[a]=s[a])})},o=NS(is({},t),{attributes:r});if(Gn(e)){const{attributes:s}=ih(e);i(s)}else if(fr(e)){if(!ma(e))return;i(ch(e))}return o}function Die(e,t){if(!e)return t;if(!t)return e;const n=is(is({},e.attributes||{}),t.attributes||{});return NS(is(is({},e),t),{attributes:Object.keys(n).length?n:void 0})}var qie=Object.defineProperty,qS=Object.getOwnPropertySymbols,Hie=Object.prototype.hasOwnProperty,jie=Object.prototype.propertyIsEnumerable,HS=(e,t,n)=>t in e?qie(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,jS=(e,t)=>{for(var n in t||(t={}))Hie.call(t,n)&&HS(e,n,t[n]);if(qS)for(var n of qS(t))jie.call(t,n)&&HS(e,n,t[n]);return e},FS=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class Fie{constructor(t,n){this.options=t,this.original=n}apply(t){return FS(this,null,function*(){const n=t.getOptions();this.original||(this.original=n),t.updateOptions(jS(jS({},n),this.options))})}undo(t){return FS(this,null,function*(){this.original&&t.updateOptions(this.original)})}serialize(){return{type:"update-options",options:this.options,original:this.original}}}var BS=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class Bie{constructor(t,n,r){this.element=t,this.originalText=r!=null?r:da(t),this.modifiedText=n}apply(t){return BS(this,null,function*(){this.originalText!==this.modifiedText&&(rh(this.element,this.modifiedText),WS(t,this.element,this.modifiedText))})}undo(t){return BS(this,null,function*(){this.originalText!==this.modifiedText&&(rh(this.element,this.originalText),WS(t,this.element,this.originalText))})}serialize(){return{type:"update-text",elementId:this.element.id,original:this.originalText,modified:this.modifiedText}}}function WS(e,t,n){const r=sh(t);if(r.startsWith("item-")){const i=r.replace("item-",""),o=ES(t);e.updateItemDatum(o,{[i]:n})}else e.updateData(r,n)}var Wie=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class VS extends yr{constructor(){super(...arguments),this.name="dblclick-edit-text"}init(t){super.init(t);const{editor:n,commander:r,interaction:i}=t;this.clickHandler=new SS(n.getDocument()).onDoubleClick(o=>{i.isActive()&&i.executeExclusiveInteraction(this,()=>Wie(this,null,function*(){const s=Yl(o.target);if(s&&Gn(s)){i.select([s],"replace");const a=da(s),l=yield new Promise(c=>{const u=this.listenSelectionChange(s);Gie(s,{cursorPosition:{clientX:o.clientX,clientY:o.clientY},onBlur:c,onCancel:c}),this.detachSelectionListener=u});r.execute(new Bie(s,l,a))}}))})}destroy(){var t,n;(t=this.clickHandler)==null||t.destroy(),(n=this.detachSelectionListener)==null||n.call(this)}listenSelectionChange(t){const n=({next:r})=>{var i;if(!r.includes(t)){(i=this.detachSelectionListener)==null||i.call(this),this.detachSelectionListener=void 0;const o=kr(t);o&&o.blur()}};return this.emitter.on("selection:change",n),()=>this.emitter.off("selection:change",n)}}const Vie="infographic-inline-text-editor-style",Xl="infographic-inline-text-editor";function Gie(e,t){const n=kr(e);n&&(Xie(),new Yie(n,t).start())}class Yie{constructor(t,n){this.entity=t,this.options=n,this.handlePaste=r=>{r.clipboardData&&(r.preventDefault(),this.insertPlainText(r.clipboardData.getData("text/plain")))},this.handleKeydown=r=>{r.key==="Enter"&&!r.shiftKey&&(r.preventDefault(),this.insertPlainText(`
|
|
147
|
+
`))},this.handleInput=()=>{var r,i;this.normalizeSpanContent(),(i=(r=this.options)==null?void 0:r.onInput)==null||i.call(r,this.getText())},this.handleBlur=()=>{var r,i;this.entity.removeAttribute("contenteditable"),this.entity.classList.remove(Xl),this.normalizeSpanContent(),(i=(r=this.options)==null?void 0:r.onBlur)==null||i.call(r,this.getText()),this.detachListeners()}}start(){this.entity.setAttribute("contenteditable","true"),this.entity.classList.add(Xl),this.entity.focus(),this.placeCaretAtClickPosition(),this.attachListeners()}attachListeners(){this.entity.addEventListener("paste",this.handlePaste),this.entity.addEventListener("keydown",this.handleKeydown),this.entity.addEventListener("input",this.handleInput),this.entity.addEventListener("blur",this.handleBlur,{once:!0})}detachListeners(){this.entity.removeEventListener("paste",this.handlePaste),this.entity.removeEventListener("keydown",this.handleKeydown),this.entity.removeEventListener("input",this.handleInput)}insertPlainText(t){var n,r;const i=window.getSelection();if(!i)return;i.rangeCount||this.placeCaretAtEnd();const o=i.rangeCount?i.getRangeAt(0):document.createRange();o.deleteContents();const s=document.createTextNode(t);o.insertNode(s),o.setStartAfter(s),o.setEndAfter(s),i.removeAllRanges(),i.addRange(o),this.normalizeSpanContent(),(r=(n=this.options)==null?void 0:n.onInput)==null||r.call(n,this.getText())}normalizeSpanContent(){var t;if(this.entity.childNodes.length===1&&((t=this.entity.firstChild)==null?void 0:t.nodeType)===Node.TEXT_NODE)return;const n=this.getText();this.entity.textContent=n}placeCaretAtClickPosition(){const t=window.getSelection();if(!t)return;const n=this.getRangeFromPoint();if(n){t.removeAllRanges(),t.addRange(n);return}this.placeCaretAtEnd()}getRangeFromPoint(){var t,n;const{cursorPosition:r}=this.options||{};if(!r)return null;const{clientX:i,clientY:o}=r,s=document,a=(n=(t=s.caretRangeFromPoint)==null?void 0:t.call(s,i,o))!=null?n:(()=>{var l;const c=(l=s.caretPositionFromPoint)==null?void 0:l.call(s,i,o);if(!c)return null;const u=document.createRange();return u.setStart(c.offsetNode,c.offset),u.collapse(!0),u})();return!a||!this.entity.contains(a.startContainer)?null:a}placeCaretAtEnd(){const t=window.getSelection();if(!t)return;const n=document.createRange();n.selectNodeContents(this.entity),n.collapse(!1),t.removeAllRanges(),t.addRange(n)}getText(){return this.entity.textContent||""}}function Xie(){An(Vie,`
|
|
148
|
+
.${Xl} {
|
|
149
149
|
margin: 0;
|
|
150
150
|
padding: 0;
|
|
151
151
|
box-sizing: border-box;
|
|
@@ -153,11 +153,11 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
153
153
|
outline: none;
|
|
154
154
|
cursor: text;
|
|
155
155
|
}
|
|
156
|
-
.${
|
|
156
|
+
.${Xl}::selection {
|
|
157
157
|
background-color: #b3d4fc;
|
|
158
158
|
}
|
|
159
|
-
`)}var _re=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class ZC extends fr{constructor(){super(...arguments),this.name="drag-element",this.selectionForDrag=[],this.willReplaceSelection=!1,this.exclusiveStarted=!1,this.dragItems=[],this.dragging=!1,this.dragThreshold=4,this.handleStart=t=>{if(!this.interaction.isActive()||t.pointerType==="mouse"&&t.button!==0)return;const n=Dc(t.target);if(!n||kb(n))return;const r=this.editor.getDocument();this.pointerId=t.pointerId,this.startPoint=Xr(r,t.clientX,t.clientY),this.dragging=!1,this.startTarget=n;const i=this.interaction.isSelected(n);this.selectionForDrag=i?this.interaction.getSelection():[n],this.willReplaceSelection=!i,this.exclusiveStarted=!1,this.startBounds=this.getSelectionBounds(this.selectionForDrag),this.guideCandidates=this.collectGuideCandidates(this.selectionForDrag),window.addEventListener("pointermove",this.handleMove),window.addEventListener("pointerup",this.handleEnd),window.addEventListener("pointercancel",this.handleEnd)},this.handleMove=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;const n=this.editor.getDocument(),r=Xr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if(!this.dragging){if(Math.hypot(i,o)<this.dragThreshold)return;if(!this.startDrag()){this.reset();return}this.dragging=!0}const s=t.altKey?{dx:i,dy:o}:this.getSnappedDelta(i,o);t.preventDefault(),t.stopPropagation(),this.updateGuides(s),this.applyTranslation(s.dx,s.dy),this.emitGeometryChange()},this.handleEnd=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;this.detachPointerListeners();const n=this.editor.getDocument(),r=Xr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if((this.dragging||Math.hypot(i,o)>=this.dragThreshold)&&this.dragItems.length&&this.exclusiveStarted){t.preventDefault(),t.stopPropagation();const s=t.altKey?{dx:i,dy:o}:this.getSnappedDelta(i,o);this.updateGuides(s),this.applyTranslation(s.dx,s.dy),this.commitTranslation(s.dx,s.dy),this.emitGeometryChange()}this.reset()}}init(t){super.init(t),this.editor.getDocument().addEventListener("pointerdown",this.handleStart)}destroy(){this.detachPointerListeners(),this.editor.getDocument().removeEventListener("pointerdown",this.handleStart)}startDrag(){if(this.exclusiveStarted)return!0;if(!this.startTarget||(this.willReplaceSelection&&this.interaction.select([this.startTarget],"replace"),this.dragItems=this.selectionForDrag.filter(n=>Fn(n)).map(n=>this.createDragItem(n)).filter(Boolean),this.dragItems.length===0))return!1;let t=!1;return this.interaction.executeExclusiveInteraction(this,()=>_re(this,null,function*(){return new Promise(n=>{this.completeInteraction=n,t=!0})})),this.exclusiveStarted=t,t}applyTranslation(t,n){this.dragItems.forEach(r=>{if(r.mode==="attr"){const i=r.startX+t,o=r.startY+n,a={x:i,y:o};r.hasDataX&&(a["data-x"]=i),r.hasDataY&&(a["data-y"]=o),lt(r.element,a)}else{const i=this.composeTransform(r.startX+t,r.startY+n,r.restTransform);lt(r.element,{transform:i})}})}commitTranslation(t,n){if(Math.abs(t)<1e-6&&Math.abs(n)<1e-6)return;const r=this.dragItems.map(i=>{if(i.mode==="attr"){const s=i.startX+t,c=i.startY+n,l={x:s,y:c},u={};return i.hasX?u.x=i.startX:u.x=null,i.hasY?u.y=i.startY:u.y=null,i.hasDataX&&(l["data-x"]=s,u["data-x"]=i.startX),i.hasDataY&&(l["data-y"]=c,u["data-y"]=i.startY),new kn(i.element,{attributes:l},{attributes:u})}const o=this.composeTransform(i.startX+t,i.startY+n,i.restTransform),a=i.originalTransform!==void 0?i.originalTransform:null;return new kn(i.element,{attributes:{transform:o}},{attributes:{transform:a}})});r.length&&this.commander.executeBatch(r)}createDragItem(t){const n=this.getTransformInfo(t);if(n)return{element:t,mode:"transform",startX:n.x,startY:n.y,hasX:!1,hasY:!1,hasDataX:!1,hasDataY:!1,restTransform:n.rest,originalTransform:n.original};const{x:r,y:i,hasX:o,hasY:a,hasDataX:s,hasDataY:c}=this.getAttrInfo(t);return{element:t,mode:"attr",startX:r,startY:i,hasX:o,hasY:a,hasDataX:s,hasDataY:c}}getAttrInfo(t){const n=this.editor.getDocument(),{x:r,y:i}=Yn(n,t),o=sn(t,["x","y","data-x","data-y"],!1),a=o.x!==null&&o.x!==void 0,s=o.y!==null&&o.y!==void 0,c=o["data-x"]!==null&&o["data-x"]!==void 0,l=o["data-y"]!==null&&o["data-y"]!==void 0,u=(v,b)=>{const _=v!=null?Number(v):NaN;return Number.isFinite(_)?_:b},h=u(o.x,NaN),d=u(o.y,NaN),f=u(o["data-x"],NaN),g=u(o["data-y"],NaN),y=Number.isFinite(h)?h:Number.isFinite(f)?f:r,m=Number.isFinite(d)?d:Number.isFinite(g)?g:i;return{x:y,y:m,hasX:a,hasY:s,hasDataX:c,hasDataY:l}}getTransformInfo(t){const n=t.getAttribute("transform");if(n===null)return null;const r=n.match(/translate\(\s*([-\d.]+)(?:[ ,]\s*([-\d.]+))?\s*\)/i);if(!r)return{x:0,y:0,rest:n,original:n};const i=Number(r[1])||0,o=r[2]!==void 0&&Number(r[2])||0,a=n.replace(r[0],"").trim();return{x:i,y:o,rest:a,original:n}}composeTransform(t,n,r){const i=`translate(${t}, ${n})`;return r&&r.length?`${i} ${r}`:i}emitGeometryChange(){var t;const n=(t=this.dragItems[0])==null?void 0:t.element;if(!n)return;const r=Yn(this.editor.getDocument(),n);this.emitter.emit("selection:geometrychange",{type:"selection:geometrychange",target:n,rect:r})}detachPointerListeners(){window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd),window.removeEventListener("pointercancel",this.handleEnd)}reset(){var t;this.detachPointerListeners(),this.clearGuides(),this.pointerId=void 0,this.startPoint=void 0,this.dragItems=[],this.startTarget=void 0,this.selectionForDrag=[],this.willReplaceSelection=!1,this.exclusiveStarted=!1,this.dragging=!1,this.startBounds=void 0,this.guideCandidates=void 0,(t=this.completeInteraction)==null||t.call(this),this.completeInteraction=void 0}getSelectionBounds(t){if(!t.length)return;const n=this.editor.getDocument(),r=t.map(i=>Yn(n,i));return yi(r)}collectGuideCandidates(t){const n=this.editor.getDocument(),r=new Set(t),i=Array.from(n.querySelectorAll("[data-element-type]")).filter(s=>!r.has(s)),o=[],a=[];return i.forEach(s=>{const{x:c,y:l,width:u,height:h}=Yn(n,s);o.push(c,c+u/2,c+u),a.push(l,l+h/2,l+h)}),{vertical:o,horizontal:a}}getSnappedDelta(t,n){if(!this.startBounds||!this.guideCandidates)return{dx:t,dy:n};const r={x:this.startBounds.x+t,y:this.startBounds.y+n,width:this.startBounds.width,height:this.startBounds.height},i=this.getSnapOffset([r.x,r.x+r.width/2,r.x+r.width],this.guideCandidates.vertical),o=this.getSnapOffset([r.y,r.y+r.height/2,r.y+r.height],this.guideCandidates.horizontal);return{dx:t+((i==null?void 0:i.offset)||0),dy:n+((o==null?void 0:o.offset)||0),snapX:i,snapY:o}}getSnapOffset(t,n,r=5){let i=null;return t.forEach(o=>{n.forEach(a=>{const s=a-o;Math.abs(s)<=r&&(!i||Math.abs(s)<Math.abs(i.offset))&&(i={offset:s,at:a})})}),i||void 0}ensureGuideLine(t){const n=t==="vertical"?this.guideVertical:this.guideHorizontal;if(n)return n;const r=this.interaction.appendTransientElement(Ee("line",{stroke:"#FF7A45","stroke-width":1,"stroke-dasharray":"4 4","pointer-events":"none",visibility:"hidden"}));return t==="vertical"?this.guideVertical=r:this.guideHorizontal=r,r}updateGuides(t){const n=this.editor.getDocument(),{width:r,height:i}=n.viewBox.baseVal;if(t.snapX){const o=this.ensureGuideLine("vertical");lt(o,{x1:t.snapX.at,y1:0,x2:t.snapX.at,y2:i,visibility:"visible"})}else this.guideVertical&&this.guideVertical.setAttribute("visibility","hidden");if(t.snapY){const o=this.ensureGuideLine("horizontal");lt(o,{x1:0,y1:t.snapY.at,x2:r,y2:t.snapY.at,visibility:"visible"})}else this.guideHorizontal&&this.guideHorizontal.setAttribute("visibility","hidden")}clearGuides(){var t,n;(t=this.guideVertical)==null||t.remove(),(n=this.guideHorizontal)==null||n.remove(),this.guideVertical=void 0,this.guideHorizontal=void 0}}var QC=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class JC extends fr{constructor(){super(...arguments),this.name="hotkey-history",this.handleUndo=t=>QC(this,null,function*(){t.preventDefault(),yield this.commander.undo()}),this.handleRedo=t=>QC(this,null,function*(){t.preventDefault(),yield this.commander.redo()})}init(t){super.init(t),this.hotkey=new Jne({filter:()=>this.interaction.isActive()}),this.hotkey.bind("mod+z",this.handleUndo),this.hotkey.bind(["mod+shift+z","mod+y"],this.handleRedo)}destroy(){var t;(t=this.hotkey)==null||t.destroy()}}var xre=Object.defineProperty,wre=Object.defineProperties,Pre=Object.getOwnPropertyDescriptors,eO=Object.getOwnPropertySymbols,$re=Object.prototype.hasOwnProperty,Cre=Object.prototype.propertyIsEnumerable,tO=(e,t,n)=>t in e?xre(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ore=(e,t)=>{for(var n in t||(t={}))$re.call(t,n)&&tO(e,n,t[n]);if(eO)for(var n of eO(t))Cre.call(t,n)&&tO(e,n,t[n]);return e},Sre=(e,t)=>wre(e,Pre(t));class nO extends fr{constructor(){super(...arguments),this.name="select-highlight",this.highlightMasks=[],this.handleSelectionChanged=({next:t})=>{this.highlightSelection(t)},this.handleGeometryChanged=({target:t})=>{this.interaction.isSelected(t)&&this.highlightSelection(this.interaction.getSelection())},this.handleHistoryChanged=()=>{this.highlightSelection(this.interaction.getSelection())}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChanged),n.on("selection:geometrychange",this.handleGeometryChanged),n.on("history:change",this.handleHistoryChanged),this.highlightSelection(this.interaction.getSelection())}destroy(){this.clearMasks();const{emitter:t}=this;t.off("selection:change",this.handleSelectionChanged),t.off("selection:geometrychange",this.handleGeometryChanged),t.off("history:change",this.handleHistoryChanged)}highlightSelection(t){if(t.length===1&&Fn(t[0])){this.clearMasks();return}this.drawElementMasks(t),this.drawCombinedBoundsMask(t)}drawElementMasks(t){let n=0;for(;n<t.length;n++){const{x:r,y:i,width:o,height:a}=Yn(this.editor.getDocument(),t[n]),s={x:r,y:i,width:o,height:a,fill:"none",stroke:"#3384F5","stroke-width":1,"pointer-events":"none"},c=this.highlightMasks[n];c?lt(c,s):this.highlightMasks[n]=this.interaction.appendTransientElement(Ee("rect",s))}for(;n<this.highlightMasks.length;n++)this.highlightMasks[n].remove();this.highlightMasks=this.highlightMasks.slice(0,t.length)}drawCombinedBoundsMask(t){var n;if(t.length<2){(n=this.combinedBoundsMask)==null||n.remove(),this.combinedBoundsMask=void 0;return}const r=yi(t.map(o=>Yn(this.editor.getDocument(),o))),i=Sre(Ore({},r),{fill:"none",stroke:"#3384F5","stroke-width":2,"pointer-events":"none"});this.combinedBoundsMask?lt(this.combinedBoundsMask,i):this.combinedBoundsMask=this.interaction.appendTransientElement(Ee("rect",i))}clearMasks(){var t;this.highlightMasks.forEach(n=>n.remove()),this.highlightMasks=[],(t=this.combinedBoundsMask)==null||t.remove(),this.combinedBoundsMask=void 0}}const rO=1,Mre=-5e3,Ere=5e3;class iO extends fr{constructor(){super(...arguments),this.name="zoom-wheel",this.wheelListener=t=>{var n;if(!this.interaction.isActive()||!t.ctrlKey&&!t.metaKey)return;t.preventDefault();const r=t.deltaY>0?1.1:.9,o=(n=this.state.getOptions().padding)!=null?n:0,a=Ar(o),c=this.editor.getDocument().getBBox(),l=a.map(v=>Vk((v===0?1:v)*r,Mre,Ere)),[u,h,d,f]=l,g=c.width+f+h,y=c.height+u+d;if(g<=rO||y<=rO)return;const m=new fre({padding:l});this.commander.execute(m)}}init(t){super.init(t),document.addEventListener("wheel",this.wheelListener,{passive:!1})}destroy(){document.removeEventListener("wheel",this.wheelListener)}}class K1{init(t){Object.assign(this,t)}}const Ur=({icon:e,onClick:t,activate:n=!1})=>{Are();const r=document.createElement("button");r.type="button",r.classList.add(Zo),n&&r.setAttribute("data-activate","true"),t&&r.addEventListener("click",t);const i=e();return r.appendChild(i),Object.assign(r,{setActivate:(a=>{a?r.setAttribute("data-activate","true"):r.removeAttribute("data-activate")}).bind(r),activate:n})},Zo="infographic-edit-bar-icon-btn",Ire="infographic-edit-bar-icon-btn-style";function Are(){Sn(Ire,`
|
|
160
|
-
.${
|
|
159
|
+
`)}var Uie=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class GS extends yr{constructor(){super(...arguments),this.name="drag-element",this.selectionForDrag=[],this.willReplaceSelection=!1,this.exclusiveStarted=!1,this.dragItems=[],this.dragging=!1,this.dragThreshold=4,this.handleStart=t=>{if(!this.interaction.isActive()||t.pointerType==="mouse"&&t.button!==0)return;const n=Yl(t.target);if(!n||E_(n))return;const r=this.editor.getDocument();this.pointerId=t.pointerId,this.startPoint=Qr(r,t.clientX,t.clientY),this.dragging=!1,this.startTarget=n;const i=this.interaction.isSelected(n);this.selectionForDrag=i?this.interaction.getSelection():[n],this.willReplaceSelection=!i,this.exclusiveStarted=!1,this.startBounds=this.getSelectionBounds(this.selectionForDrag),this.guideCandidates=this.collectGuideCandidates(this.selectionForDrag),window.addEventListener("pointermove",this.handleMove),window.addEventListener("pointerup",this.handleEnd),window.addEventListener("pointercancel",this.handleEnd)},this.handleMove=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;const n=this.editor.getDocument(),r=Qr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if(!this.dragging){if(Math.hypot(i,o)<this.dragThreshold)return;if(!this.startDrag()){this.reset();return}this.dragging=!0}const a=t.altKey?{dx:i,dy:o}:this.getSnappedDelta(i,o);t.preventDefault(),t.stopPropagation(),this.updateGuides(a),this.applyTranslation(a.dx,a.dy),this.emitGeometryChange()},this.handleEnd=t=>{if(t.pointerId!==this.pointerId||!this.startPoint)return;this.detachPointerListeners();const n=this.editor.getDocument(),r=Qr(n,t.clientX,t.clientY),i=r.x-this.startPoint.x,o=r.y-this.startPoint.y;if((this.dragging||Math.hypot(i,o)>=this.dragThreshold)&&this.dragItems.length&&this.exclusiveStarted){t.preventDefault(),t.stopPropagation();const a=t.altKey?{dx:i,dy:o}:this.getSnappedDelta(i,o);this.updateGuides(a),this.applyTranslation(a.dx,a.dy),this.commitTranslation(a.dx,a.dy),this.emitGeometryChange()}this.reset()}}init(t){super.init(t),this.editor.getDocument().addEventListener("pointerdown",this.handleStart)}destroy(){this.detachPointerListeners(),this.editor.getDocument().removeEventListener("pointerdown",this.handleStart)}startDrag(){if(this.exclusiveStarted)return!0;if(!this.startTarget||(this.willReplaceSelection&&this.interaction.select([this.startTarget],"replace"),this.dragItems=this.selectionForDrag.filter(n=>Gn(n)).map(n=>this.createDragItem(n)).filter(Boolean),this.dragItems.length===0))return!1;let t=!1;return this.interaction.executeExclusiveInteraction(this,()=>Uie(this,null,function*(){return new Promise(n=>{this.completeInteraction=n,t=!0})})),this.exclusiveStarted=t,t}applyTranslation(t,n){this.dragItems.forEach(r=>{if(r.mode==="attr"){const i=r.startX+t,o=r.startY+n,s={x:i,y:o};r.hasDataX&&(s["data-x"]=i),r.hasDataY&&(s["data-y"]=o),ut(r.element,s)}else{const i=this.composeTransform(r.startX+t,r.startY+n,r.restTransform);ut(r.element,{transform:i})}})}commitTranslation(t,n){if(Math.abs(t)<1e-6&&Math.abs(n)<1e-6)return;const r=this.dragItems.map(i=>{if(i.mode==="attr"){const a=i.startX+t,l=i.startY+n,c={x:a,y:l},u={};return i.hasX?u.x=i.startX:u.x=null,i.hasY?u.y=i.startY:u.y=null,i.hasDataX&&(c["data-x"]=a,u["data-x"]=i.startX),i.hasDataY&&(c["data-y"]=l,u["data-y"]=i.startY),new zn(i.element,{attributes:c},{attributes:u})}const o=this.composeTransform(i.startX+t,i.startY+n,i.restTransform),s=i.originalTransform!==void 0?i.originalTransform:null;return new zn(i.element,{attributes:{transform:o}},{attributes:{transform:s}})});r.length&&this.commander.executeBatch(r)}createDragItem(t){const n=this.getTransformInfo(t);if(n)return{element:t,mode:"transform",startX:n.x,startY:n.y,hasX:!1,hasY:!1,hasDataX:!1,hasDataY:!1,restTransform:n.rest,originalTransform:n.original};const{x:r,y:i,hasX:o,hasY:s,hasDataX:a,hasDataY:l}=this.getAttrInfo(t);return{element:t,mode:"attr",startX:r,startY:i,hasX:o,hasY:s,hasDataX:a,hasDataY:l}}getAttrInfo(t){const n=this.editor.getDocument(),{x:r,y:i}=Zn(n,t),o=cn(t,["x","y","data-x","data-y"],!1),s=o.x!==null&&o.x!==void 0,a=o.y!==null&&o.y!==void 0,l=o["data-x"]!==null&&o["data-x"]!==void 0,c=o["data-y"]!==null&&o["data-y"]!==void 0,u=(v,b)=>{const _=v!=null?Number(v):NaN;return Number.isFinite(_)?_:b},h=u(o.x,NaN),f=u(o.y,NaN),d=u(o["data-x"],NaN),p=u(o["data-y"],NaN),g=Number.isFinite(h)?h:Number.isFinite(d)?d:r,m=Number.isFinite(f)?f:Number.isFinite(p)?p:i;return{x:g,y:m,hasX:s,hasY:a,hasDataX:l,hasDataY:c}}getTransformInfo(t){const n=t.getAttribute("transform");if(n===null)return null;const r=n.match(/translate\(\s*([-\d.]+)(?:[ ,]\s*([-\d.]+))?\s*\)/i);if(!r)return{x:0,y:0,rest:n,original:n};const i=Number(r[1])||0,o=r[2]!==void 0&&Number(r[2])||0,s=n.replace(r[0],"").trim();return{x:i,y:o,rest:s,original:n}}composeTransform(t,n,r){const i=`translate(${t}, ${n})`;return r&&r.length?`${i} ${r}`:i}emitGeometryChange(){var t;const n=(t=this.dragItems[0])==null?void 0:t.element;if(!n)return;const r=Zn(this.editor.getDocument(),n);this.emitter.emit("selection:geometrychange",{type:"selection:geometrychange",target:n,rect:r})}detachPointerListeners(){window.removeEventListener("pointermove",this.handleMove),window.removeEventListener("pointerup",this.handleEnd),window.removeEventListener("pointercancel",this.handleEnd)}reset(){var t;this.detachPointerListeners(),this.clearGuides(),this.pointerId=void 0,this.startPoint=void 0,this.dragItems=[],this.startTarget=void 0,this.selectionForDrag=[],this.willReplaceSelection=!1,this.exclusiveStarted=!1,this.dragging=!1,this.startBounds=void 0,this.guideCandidates=void 0,(t=this.completeInteraction)==null||t.call(this),this.completeInteraction=void 0}getSelectionBounds(t){if(!t.length)return;const n=this.editor.getDocument(),r=t.map(i=>Zn(n,i));return Ci(r)}collectGuideCandidates(t){const n=this.editor.getDocument(),r=new Set(t),i=Array.from(n.querySelectorAll("[data-element-type]")).filter(a=>!r.has(a)),o=[],s=[];return i.forEach(a=>{const{x:l,y:c,width:u,height:h}=Zn(n,a);o.push(l,l+u/2,l+u),s.push(c,c+h/2,c+h)}),{vertical:o,horizontal:s}}getSnappedDelta(t,n){if(!this.startBounds||!this.guideCandidates)return{dx:t,dy:n};const r={x:this.startBounds.x+t,y:this.startBounds.y+n,width:this.startBounds.width,height:this.startBounds.height},i=this.getSnapOffset([r.x,r.x+r.width/2,r.x+r.width],this.guideCandidates.vertical),o=this.getSnapOffset([r.y,r.y+r.height/2,r.y+r.height],this.guideCandidates.horizontal);return{dx:t+((i==null?void 0:i.offset)||0),dy:n+((o==null?void 0:o.offset)||0),snapX:i,snapY:o}}getSnapOffset(t,n,r=5){let i=null;return t.forEach(o=>{n.forEach(s=>{const a=s-o;Math.abs(a)<=r&&(!i||Math.abs(a)<Math.abs(i.offset))&&(i={offset:a,at:s})})}),i||void 0}ensureGuideLine(t){const n=t==="vertical"?this.guideVertical:this.guideHorizontal;if(n)return n;const r=this.interaction.appendTransientElement(Me("line",{stroke:"#FF7A45","stroke-width":1,"stroke-dasharray":"4 4","pointer-events":"none",visibility:"hidden"}));return t==="vertical"?this.guideVertical=r:this.guideHorizontal=r,r}updateGuides(t){const n=this.editor.getDocument(),{width:r,height:i}=n.viewBox.baseVal;if(t.snapX){const o=this.ensureGuideLine("vertical");ut(o,{x1:t.snapX.at,y1:0,x2:t.snapX.at,y2:i,visibility:"visible"})}else this.guideVertical&&this.guideVertical.setAttribute("visibility","hidden");if(t.snapY){const o=this.ensureGuideLine("horizontal");ut(o,{x1:0,y1:t.snapY.at,x2:r,y2:t.snapY.at,visibility:"visible"})}else this.guideHorizontal&&this.guideHorizontal.setAttribute("visibility","hidden")}clearGuides(){var t,n;(t=this.guideVertical)==null||t.remove(),(n=this.guideHorizontal)==null||n.remove(),this.guideVertical=void 0,this.guideHorizontal=void 0}}var YS=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class XS extends yr{constructor(){super(...arguments),this.name="hotkey-history",this.handleUndo=t=>YS(this,null,function*(){t.preventDefault(),yield this.commander.undo()}),this.handleRedo=t=>YS(this,null,function*(){t.preventDefault(),yield this.commander.redo()})}init(t){super.init(t),this.hotkey=new Eie({filter:()=>this.interaction.isActive()}),this.hotkey.bind("mod+z",this.handleUndo),this.hotkey.bind(["mod+shift+z","mod+y"],this.handleRedo)}destroy(){var t;(t=this.hotkey)==null||t.destroy()}}var Kie=Object.defineProperty,Zie=Object.defineProperties,Qie=Object.getOwnPropertyDescriptors,US=Object.getOwnPropertySymbols,Jie=Object.prototype.hasOwnProperty,eoe=Object.prototype.propertyIsEnumerable,KS=(e,t,n)=>t in e?Kie(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,toe=(e,t)=>{for(var n in t||(t={}))Jie.call(t,n)&&KS(e,n,t[n]);if(US)for(var n of US(t))eoe.call(t,n)&&KS(e,n,t[n]);return e},noe=(e,t)=>Zie(e,Qie(t));class ZS extends yr{constructor(){super(...arguments),this.name="select-highlight",this.highlightMasks=[],this.handleSelectionChanged=({next:t})=>{this.highlightSelection(t)},this.handleGeometryChanged=({target:t})=>{this.interaction.isSelected(t)&&this.highlightSelection(this.interaction.getSelection())},this.handleHistoryChanged=()=>{this.highlightSelection(this.interaction.getSelection())}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChanged),n.on("selection:geometrychange",this.handleGeometryChanged),n.on("history:change",this.handleHistoryChanged),this.highlightSelection(this.interaction.getSelection())}destroy(){this.clearMasks();const{emitter:t}=this;t.off("selection:change",this.handleSelectionChanged),t.off("selection:geometrychange",this.handleGeometryChanged),t.off("history:change",this.handleHistoryChanged)}highlightSelection(t){if(t.length===1&&Gn(t[0])){this.clearMasks();return}this.drawElementMasks(t),this.drawCombinedBoundsMask(t)}drawElementMasks(t){let n=0;for(;n<t.length;n++){const{x:r,y:i,width:o,height:s}=Zn(this.editor.getDocument(),t[n]),a={x:r,y:i,width:o,height:s,fill:"none",stroke:"#3384F5","stroke-width":1,"pointer-events":"none"},l=this.highlightMasks[n];l?ut(l,a):this.highlightMasks[n]=this.interaction.appendTransientElement(Me("rect",a))}for(;n<this.highlightMasks.length;n++)this.highlightMasks[n].remove();this.highlightMasks=this.highlightMasks.slice(0,t.length)}drawCombinedBoundsMask(t){var n;if(t.length<2){(n=this.combinedBoundsMask)==null||n.remove(),this.combinedBoundsMask=void 0;return}const r=Ci(t.map(o=>Zn(this.editor.getDocument(),o))),i=noe(toe({},r),{fill:"none",stroke:"#3384F5","stroke-width":2,"pointer-events":"none"});this.combinedBoundsMask?ut(this.combinedBoundsMask,i):this.combinedBoundsMask=this.interaction.appendTransientElement(Me("rect",i))}clearMasks(){var t;this.highlightMasks.forEach(n=>n.remove()),this.highlightMasks=[],(t=this.combinedBoundsMask)==null||t.remove(),this.combinedBoundsMask=void 0}}const QS=1,roe=-5e3,ioe=5e3;class JS extends yr{constructor(){super(...arguments),this.name="zoom-wheel",this.wheelListener=t=>{var n;if(!this.interaction.isActive()||!t.ctrlKey&&!t.metaKey)return;t.preventDefault();const r=t.deltaY>0?1.1:.9,o=(n=this.state.getOptions().padding)!=null?n:0,s=Lr(o),l=this.editor.getDocument().getBBox(),c=s.map(v=>wL((v===0?1:v)*r,roe,ioe)),[u,h,f,d]=c,p=l.width+d+h,g=l.height+u+f;if(p<=QS||g<=QS)return;const m=new Fie({padding:c});this.commander.execute(m)}}init(t){super.init(t),document.addEventListener("wheel",this.wheelListener,{passive:!1})}destroy(){document.removeEventListener("wheel",this.wheelListener)}}class pm{init(t){Object.assign(this,t)}}const Jr=({icon:e,onClick:t,activate:n=!1})=>{soe();const r=document.createElement("button");r.type="button",r.classList.add(os),n&&r.setAttribute("data-activate","true"),t&&r.addEventListener("click",t);const i=e();return r.appendChild(i),Object.assign(r,{setActivate:(s=>{s?r.setAttribute("data-activate","true"):r.removeAttribute("data-activate")}).bind(r),activate:n})},os="infographic-edit-bar-icon-btn",ooe="infographic-edit-bar-icon-btn-style";function soe(){An(ooe,`
|
|
160
|
+
.${os} {
|
|
161
161
|
padding: 0;
|
|
162
162
|
display: flex;
|
|
163
163
|
align-items: center;
|
|
@@ -172,28 +172,28 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
172
172
|
cursor: pointer;
|
|
173
173
|
transition: color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
|
|
174
174
|
}
|
|
175
|
-
.${
|
|
175
|
+
.${os}:hover {
|
|
176
176
|
background-color: #f5f5f5;
|
|
177
177
|
}
|
|
178
|
-
.${
|
|
178
|
+
.${os}:active {
|
|
179
179
|
background-color: #d9d9d9;
|
|
180
180
|
}
|
|
181
|
-
.${
|
|
181
|
+
.${os}[data-activate="true"] {
|
|
182
182
|
background-color: #d9d9d9;
|
|
183
183
|
}
|
|
184
|
-
`)}const
|
|
185
|
-
.${
|
|
184
|
+
`)}const Dn="infographic-color-picker",e$=`${Dn}__swatches`,Ul=`${Dn}__swatch`,t$=`${Dn}__controls`,Kl=`${Dn}__input`,n$=`${Dn}__format`,ei=`${Dn}__format-switch`,gm=`${Dn}__format-switch-knob`,Zl=`${Dn}__format-switch-label`,aoe="infographic-color-picker-style",loe="#1f1f1f",coe=["#000000","#1f1f1f","#434343","#595959","#8c8c8c","#bfbfbf","#d9d9d9","#f0f0f0","#ffffff","#1677ff","#2f54eb","#91caff","#13c2c2","#36cfc9","#52c41a","#73d13d","#fadb14","#ffd666","#fa8c16","#fa541c","#f5222d","#ff7875","#eb2f96","#ffadd2","#722ed1","#9254de","rgba(0, 0, 0, 0.65)","rgba(255, 255, 255, 0.85)"];function r$(e){var t,n,r;if(typeof document=="undefined")throw new Error("ColorPicker can only be used in the browser.");doe();const i=document.createElement("div");i.classList.add(Dn);const o=document.createElement("div");o.classList.add(e$),i.appendChild(o);const s=document.createElement("div");s.classList.add(t$),i.appendChild(s);const a=document.createElement("input");a.type="text",a.spellcheck=!1,a.classList.add(Kl),s.appendChild(a);const l=document.createElement("div");l.classList.add(n$),s.appendChild(l);const c=document.createElement("button");c.type="button",c.classList.add(ei),c.appendChild(a$("HEXA"));const u=document.createElement("span");u.classList.add(gm),c.appendChild(u),c.appendChild(a$("RGBA")),l.appendChild(c);let h="hexa",f=(n=(t=ss(e.value))!=null?t:ss(loe))!=null?n:{r:31,g:31,b:31,a:1};const d=[];return((r=e.swatches)!=null&&r.length?e.swatches:coe).forEach(C=>{const P=ss(C);if(!P)return;const O=document.createElement("button");O.type="button",O.classList.add(Ul),O.style.setProperty("--swatch-color",Ql(P,"rgba")),O.dataset.colorKey=o$(P),O.addEventListener("click",()=>{b(P)}),o.appendChild(O),d.push(O)}),c.addEventListener("click",()=>v(h==="hexa"?"rgba":"hexa")),a.addEventListener("change",m),a.addEventListener("keydown",C=>{C.key==="Enter"&&m()}),_(),Object.assign(i,{setValue:C=>{const P=ss(C);if(!P){a.setAttribute("data-invalid","true");return}a.removeAttribute("data-invalid"),b(P,!1)},destroy:()=>{i.remove()}});function m(){const C=ss(a.value);if(!C){a.setAttribute("data-invalid","true");return}a.removeAttribute("data-invalid"),b(C)}function v(C,P){var O;h!==C&&(h=C,_(),(O=e.onChange)==null||O.call(e,Ql(f,h)))}function b(C,P=!0){var O;if(hoe(f,C)){_();return}f=C,_(),P&&((O=e.onChange)==null||O.call(e,Ql(f,h)))}function _(){a.value=Ql(f,h),x(),w()}function x(){const C=o$(f);d.forEach(P=>{P.dataset.colorKey===C?P.setAttribute("data-active","true"):P.removeAttribute("data-active")})}function w(){h==="rgba"?c.setAttribute("data-format","rgba"):c.setAttribute("data-format","hexa")}}function ss(e){var t;if(!e)return;const n=En(e);if(!n||typeof n.r!="number")return;const r=n;return{r:mm(r.r),g:mm(r.g),b:mm(r.b),a:s$((t=r.alpha)!=null?t:1)}}function Ql(e,t){return t==="rgba"?uoe(e):i$(e)}function i$(e){const t=Jl(e.r),n=Jl(e.g),r=Jl(e.b),i=e.a<1?Jl(Math.round(e.a*255)):"";return`#${t}${n}${r}${i}`}function uoe(e){const t=foe(e.a);return`rgba(${e.r}, ${e.g}, ${e.b}, ${t})`}function o$(e){return i$(e).toLowerCase()}function hoe(e,t){return e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a}function s$(e){return Number.isNaN(e)?0:Math.min(1,Math.max(0,e))}function mm(e){if(Number.isNaN(e))return 0;const t=e<=1?e*255:e;return Math.round(Math.min(255,Math.max(0,t)))}function Jl(e){return e.toString(16).padStart(2,"0")}function foe(e){const t=Math.round(s$(e)*100)/100;return t===1?"1":t===0?"0":t.toString()}function a$(e){const t=document.createElement("span");return t.textContent=e,t.classList.add(Zl),t}function doe(){An(aoe,`
|
|
185
|
+
.${Dn} {
|
|
186
186
|
width: 240px;
|
|
187
187
|
padding: 10px;
|
|
188
188
|
box-sizing: border-box;
|
|
189
189
|
}
|
|
190
|
-
.${
|
|
190
|
+
.${e$} {
|
|
191
191
|
display: grid;
|
|
192
192
|
grid-template-columns: repeat(auto-fit, 26px);
|
|
193
193
|
gap: 6px;
|
|
194
194
|
margin-bottom: 10px;
|
|
195
195
|
}
|
|
196
|
-
.${
|
|
196
|
+
.${Ul} {
|
|
197
197
|
width: 24px;
|
|
198
198
|
height: 24px;
|
|
199
199
|
border-radius: 50%;
|
|
@@ -204,19 +204,19 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
204
204
|
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
|
|
205
205
|
transition: transform 0.15s ease, box-shadow 0.15s ease;
|
|
206
206
|
}
|
|
207
|
-
.${
|
|
207
|
+
.${Ul}[data-active="true"] {
|
|
208
208
|
box-shadow: 0 0 0 2px #1677ff;
|
|
209
209
|
transform: translateY(-1px);
|
|
210
210
|
}
|
|
211
|
-
.${
|
|
211
|
+
.${Ul}:hover {
|
|
212
212
|
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.18);
|
|
213
213
|
}
|
|
214
|
-
.${
|
|
214
|
+
.${t$} {
|
|
215
215
|
display: flex;
|
|
216
216
|
align-items: center;
|
|
217
217
|
gap: 6px;
|
|
218
218
|
}
|
|
219
|
-
.${
|
|
219
|
+
.${Kl} {
|
|
220
220
|
flex: 1;
|
|
221
221
|
min-width: 0;
|
|
222
222
|
height: 30px;
|
|
@@ -232,19 +232,19 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
232
232
|
outline: none;
|
|
233
233
|
transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
|
|
234
234
|
}
|
|
235
|
-
.${
|
|
235
|
+
.${Kl}:focus {
|
|
236
236
|
border-color: #1677ff;
|
|
237
237
|
background: #ffffff;
|
|
238
238
|
box-shadow: 0 0 0 2px rgba(22, 119, 255, 0.12);
|
|
239
239
|
}
|
|
240
|
-
.${
|
|
240
|
+
.${Kl}[data-invalid="true"] {
|
|
241
241
|
border-color: #ff4d4f;
|
|
242
242
|
box-shadow: 0 0 0 2px rgba(255, 77, 79, 0.12);
|
|
243
243
|
}
|
|
244
|
-
.${
|
|
244
|
+
.${n$} {
|
|
245
245
|
display: inline-flex;
|
|
246
246
|
}
|
|
247
|
-
.${
|
|
247
|
+
.${ei} {
|
|
248
248
|
position: relative;
|
|
249
249
|
display: grid;
|
|
250
250
|
grid-template-columns: 1fr 1fr;
|
|
@@ -259,15 +259,15 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
259
259
|
overflow: hidden;
|
|
260
260
|
transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
|
|
261
261
|
}
|
|
262
|
-
.${
|
|
262
|
+
.${ei}:hover {
|
|
263
263
|
background: #ededed;
|
|
264
264
|
}
|
|
265
|
-
.${
|
|
265
|
+
.${ei}:focus-visible {
|
|
266
266
|
outline: none;
|
|
267
267
|
border-color: #1677ff;
|
|
268
268
|
box-shadow: 0 0 0 2px rgba(22, 119, 255, 0.12);
|
|
269
269
|
}
|
|
270
|
-
.${
|
|
270
|
+
.${gm} {
|
|
271
271
|
position: absolute;
|
|
272
272
|
inset: 0;
|
|
273
273
|
width: 50%;
|
|
@@ -276,10 +276,10 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
276
276
|
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
|
|
277
277
|
transition: transform 0.2s ease;
|
|
278
278
|
}
|
|
279
|
-
.${
|
|
279
|
+
.${ei}[data-format="rgba"] .${gm} {
|
|
280
280
|
transform: translateX(100%);
|
|
281
281
|
}
|
|
282
|
-
.${
|
|
282
|
+
.${Zl} {
|
|
283
283
|
position: relative;
|
|
284
284
|
z-index: 1;
|
|
285
285
|
text-align: center;
|
|
@@ -287,19 +287,19 @@ ${o(l)}}`}return i.push("type InfographicType = {"),n.includes("title")&&(i.push
|
|
|
287
287
|
color: #434343;
|
|
288
288
|
user-select: none;
|
|
289
289
|
}
|
|
290
|
-
.${
|
|
291
|
-
.${
|
|
290
|
+
.${ei}[data-format="hexa"] .${Zl}:first-child,
|
|
291
|
+
.${ei}[data-format="rgba"] .${Zl}:last-child {
|
|
292
292
|
color: #ffffff;
|
|
293
293
|
}
|
|
294
|
-
`)}const
|
|
294
|
+
`)}const qt=(e,{viewBox:t="0 0 1024 1024",size:n="1.5em"}={})=>({fill:r="currentColor"}={})=>{const i=`<svg xmlns="http://www.w3.org/2000/svg" viewBox="${t}" width="${n}" height="${n}" fill="${r}">
|
|
295
295
|
${e.trim()}
|
|
296
|
-
</svg>`;return document.createRange().createContextualFragment(i).firstElementChild},
|
|
297
|
-
<path d="M661.333 272.411c17.673 0 32 14.327 32 32V902c0 17.673-14.327 32-32 32H362.667c-17.673 0-32-14.327-32-32V304.411c0-17.673 14.327-32 32-32z m-32 63.999H394.666V870h234.667V336.41zM896 101.671c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768z" />`),alignRight:
|
|
298
|
-
.${
|
|
296
|
+
</svg>`;return document.createRange().createContextualFragment(i).firstElementChild},Qn={fontFamily:qt('<path d="M236.992 938.688H145.088L469.312 128h85.376l324.224 810.688h-91.904l-102.4-256H339.392l-102.4 256z m136.512-341.376h276.992L512 251.072l-138.496 346.24z"></path>',{size:"1.2em"}),fontSize:qt('<path d="M479.829333 640H202.837333l-85.333333 213.333333H25.6L298.666667 170.666667h85.333333l273.066667 682.666666h-91.904l-85.333334-213.333333z m-34.133333-85.333333L341.333333 293.76 236.970667 554.666667h208.725333zM896 534.826667V512h85.333333v341.333333h-85.333333v-22.826666a170.666667 170.666667 0 1 1 0-295.68zM810.666667 768a85.333333 85.333333 0 1 0 0-170.666667 85.333333 85.333333 0 0 0 0 170.666667z"></path>',{size:"1.2em"}),align:qt('<path d="M832 96c53.02 0 96 42.98 96 96v640c0 53.02-42.98 96-96 96H192c-53.02 0-96-42.98-96-96V192c0-53.02 42.98-96 96-96z m0 64H192c-17.673 0-32 14.327-32 32v640c0 17.673 14.327 32 32 32h640c17.673 0 32-14.327 32-32V192c0-17.673-14.327-32-32-32zM725.333 672c17.673 0 32 14.327 32 32 0 17.496-14.041 31.713-31.47 31.996l-0.53 0.004H298.667c-17.673 0-32-14.327-32-32 0-17.496 14.041-31.713 31.47-31.996l0.53-0.004h426.666z m0-192c17.673 0 32 14.327 32 32 0 17.496-14.041 31.713-31.47 31.996l-0.53 0.004H298.667c-17.673 0-32-14.327-32-32 0-17.496 14.041-31.713 31.47-31.996l0.53-0.004h426.666z m0-192c17.673 0 32 14.327 32 32 0 17.496-14.041 31.713-31.47 31.996l-0.53 0.004H298.667c-17.673 0-32-14.327-32-32 0-17.496 14.041-31.713 31.47-31.996l0.53-0.004h426.666z"></path>'),alignTop:qt('<path d="M896 859.329c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H128c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h768z m0-121.533c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768zM512.45 91.003L512 91a32.632 32.632 0 0 1 1.653 0.042l0.134 0.008c3.447 0.189 6.75 0.924 9.82 2.12l0.198 0.078a16.118 16.118 0 0 1 0.485 0.197l0.11 0.046a31.82 31.82 0 0 1 8.546 5.315l0.12 0.105a31.066 31.066 0 0 1 1.189 1.095l0.08 0.078 0.235 0.23 0.062 0.063 128 128.055c12.494 12.5 12.49 32.761-0.01 45.255-12.374 12.37-32.356 12.489-44.877 0.362l-0.377-0.372L544 200.28v413.598c0 17.673-14.327 32-32 32-17.496 0-31.713-14.042-31.996-31.471l-0.004-0.53V200.278l-73.368 73.4c-12.369 12.375-32.35 12.503-44.877 0.381l-0.378-0.37c-12.374-12.37-12.502-32.352-0.38-44.878l0.37-0.378 128-128.055 0.181-0.178a31.875 31.875 0 0 1 9.5-6.47l0.105-0.046c0.116-0.051 0.233-0.101 0.35-0.15 0.054-0.024 0.11-0.047 0.165-0.07a28.198 28.198 0 0 1 0.536-0.219l0.157-0.061a31.816 31.816 0 0 1 9.356-2.103l0.113-0.007c0.147-0.01 0.294-0.02 0.442-0.027l0.028-0.001 0.39-0.019 0.144-0.005a23.911 23.911 0 0 1 0.712-0.018c0.3-0.004 0.602-0.004 0.904 0z"></path>'),alignRight:qt('<path d="M896 800.339c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H298.667c-17.673 0-32-14.327-32-32 0-17.497 14.041-31.713 31.47-31.996l0.53-0.004H896z m0-213.226c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h768z m0-213.226c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H298.667c-17.673 0-32-14.327-32-32 0-17.496 14.041-31.713 31.47-31.996l0.53-0.004H896z m0-213.226c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768z"></path>'),alignBottom:qt('<path d="M896 859.329c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H128c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h768z m0-121.533c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768zM490.505 637.584l-0.127-0.117a32.174 32.174 0 0 1-0.633-0.596l-0.098-0.096-0.217-0.213-0.062-0.063-128-128.055c-12.494-12.499-12.49-32.76 0.01-45.254 12.374-12.37 32.356-12.489 44.877-0.362l0.377 0.371L480 536.598V123c0-17.673 14.327-32 32-32 17.496 0 31.713 14.042 31.996 31.47l0.004 0.53v413.597l73.368-73.398c12.494-12.5 32.755-12.503 45.255-0.01 12.374 12.37 12.502 32.352 0.38 44.878l-0.37 0.377-128 128.055c-0.121 0.12-0.238 0.236-0.356 0.35l0.355-0.35a31.922 31.922 0 0 1-9.68 6.649l-0.09 0.039a29.917 29.917 0 0 1-1.241 0.514 31.816 31.816 0 0 1-9.338 2.095l-0.113 0.008c-0.147 0.01-0.294 0.019-0.442 0.027h-0.028c-0.13 0.008-0.26 0.014-0.39 0.02l-0.144 0.005a23.92 23.92 0 0 1-0.796 0.019 33.927 33.927 0 0 1-0.37 0.002h-0.13l-0.236-0.002 0.366 0.002a32.633 32.633 0 0 1-1.153-0.02l-0.129-0.006a31.108 31.108 0 0 1-0.876-0.046l-0.105-0.008a31.811 31.811 0 0 1-8.926-1.931l-0.089-0.034a21.022 21.022 0 0 1-0.362-0.138l-0.098-0.04a22.132 22.132 0 0 1-0.746-0.304l-0.219-0.093-0.209-0.092a31.812 31.812 0 0 1-8.034-5.094l-0.12-0.105-0.173-0.153-0.151-0.136-0.105-0.093z"></path>'),alignLeft:qt('<path d="M725.333 800.339c17.673 0 32 14.327 32 32 0 17.496-14.041 31.713-31.47 31.995l-0.53 0.005H128c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h597.333zM896 587.113c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h768zM725.333 373.887c17.673 0 32 14.327 32 32 0 17.496-14.041 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h597.333zM896 160.661c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768z"></path>'),alignCenter:qt('<path d="M768 800.339c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H256c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h512z m128-213.226c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h768zM768 373.887c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H256c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h512z m128-213.226c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768z"></path>'),alignMiddle:qt('<path d="M534.246 617.448l0.377 0.371 128 127.952c12.5 12.494 12.503 32.755 0.009 45.255-12.37 12.374-32.352 12.501-44.878 0.38l-0.377-0.372-73.38-73.352V939c0 17.673-14.326 32-32 32-17.496 0-31.712-14.042-31.995-31.47l-0.004-0.53-0.001-221.314-73.374 73.348c-12.374 12.37-32.356 12.49-44.878 0.363l-0.377-0.371c-12.37-12.375-12.49-32.356-0.362-44.878l0.37-0.377 128-127.952c12.372-12.366 32.347-12.49 44.87-0.37zM896 480.508c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768zM511.998 54c17.496 0 31.713 14.042 31.996 31.47l0.004 0.53-0.001 221.314 73.38-73.349c12.499-12.494 32.76-12.49 45.255 0.009 12.37 12.374 12.49 32.356 0.362 44.878l-0.37 0.377-128 127.951c-12.372 12.366-32.347 12.49-44.87 0.371l-0.377-0.37-128-127.952c-12.5-12.495-12.503-32.756-0.009-45.255 12.37-12.374 32.352-12.502 44.878-0.38l0.377 0.371 73.374 73.346V86c0-17.673 14.328-32 32-32z"></path>')},Jn={align:qt('<path d="M555.188 715.059c17.673 0 32 14.327 32 32V875c0 17.673-14.327 32-32 32H171c-17.673 0-32-14.327-32-32V747.059c0-17.673 14.327-32 32-32z m-32.001 63.999H203V843h320.187v-63.942zM854 416.529c17.673 0 32 14.327 32 32v127.942c0 17.673-14.327 32-32 32H171c-17.673 0-32-14.327-32-32V448.529c0-17.673 14.327-32 32-32z m-32 64H203v63.941h619v-63.941zM683.25 118c17.673 0 32 14.327 32 32v127.941c0 17.673-14.327 32-32 32H171c-17.673 0-32-14.327-32-32V150c0-17.673 14.327-32 32-32z m-32 64H203v63.941h448.25V182z"></path>'),alignTop:qt(`
|
|
297
|
+
<path d="M661.333 272.411c17.673 0 32 14.327 32 32V902c0 17.673-14.327 32-32 32H362.667c-17.673 0-32-14.327-32-32V304.411c0-17.673 14.327-32 32-32z m-32 63.999H394.666V870h234.667V336.41zM896 101.671c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768z" />`),alignRight:qt('<path d="M891.329 96c17.496 0 31.713 14.042 31.995 31.47l0.005 0.53v768c0 17.673-14.327 32-32 32-17.497 0-31.713-14.042-31.996-31.47l-0.004-0.53V128c0-17.673 14.327-32 32-32z m-170.74 234.667c17.673 0 32 14.327 32 32v298.666c0 17.673-14.327 32-32 32H123c-17.673 0-32-14.327-32-32V362.667c0-17.673 14.327-32 32-32z m-32 63.999H155v234.667h533.589V394.666z" />'),alignBottom:qt('<path d="M896 859.329c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H128c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h768zM661.333 91c17.673 0 32 14.327 32 32v597.589c0 17.673-14.327 32-32 32H362.667c-17.673 0-32-14.327-32-32V123c0-17.673 14.327-32 32-32z m-32 64H394.666v533.589h234.667V155z" />'),alignLeft:qt('<path d="M133.671 96c17.497 0 31.713 14.042 31.996 31.47l0.004 0.53v768c0 17.673-14.327 32-32 32-17.496 0-31.713-14.042-31.995-31.47l-0.005-0.53V128c0-17.673 14.327-32 32-32zM902 330.667c17.673 0 32 14.327 32 32v298.666c0 17.673-14.327 32-32 32H304.411c-17.673 0-32-14.327-32-32V362.667c0-17.673 14.327-32 32-32z m-32.001 63.999H336.41v234.667h533.589V394.666z" />'),alignH:qt('<path d="M512.5 96c17.496 0 31.713 14.042 31.996 31.47l0.004 0.53v202.666H875c17.496 0 31.713 14.042 31.996 31.471l0.004 0.53v298.666c0 17.673-14.327 32-32 32H544.5V896c0 17.673-14.327 32-32 32-17.496 0-31.713-14.042-31.996-31.47l-0.004-0.53V693.333H150c-17.496 0-31.713-14.041-31.996-31.47l-0.004-0.53V362.667c0-17.673 14.327-32 32-32l330.5-0.001V128c0-17.673 14.327-32 32-32z m-32 298.666H182v234.667h298.5V394.666z m362.5 0H544.5v234.667H843V394.666z" />'),alignV:qt('<path d="M661.333 118c17.673 0 32 14.327 32 32v330.5H896c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.996l-0.53 0.004H693.333V875c0 17.496-14.041 31.713-31.47 31.996l-0.53 0.004H362.667c-17.673 0-32-14.327-32-32l-0.001-330.5H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.996l0.53-0.004h202.666V150c0-17.496 14.042-31.713 31.471-31.996l0.53-0.004z m-32.001 426.5H394.665l0.001 298.5h234.667l-0.001-298.5z m0.001-362.5H394.666l-0.001 298.5h234.667l0.001-298.5z" />'),distributeH:qt('<path d="M853.333 96c17.497 0 31.713 14.042 31.996 31.47l0.004 0.53v768c0 17.673-14.327 32-32 32-17.496 0-31.713-14.042-31.995-31.47l-0.005-0.53V128c0-17.673 14.327-32 32-32z m-682.666 0c17.496 0 31.713 14.042 31.995 31.47l0.005 0.53v768c0 17.673-14.327 32-32 32-17.497 0-31.713-14.042-31.996-31.47l-0.004-0.53V128c0-17.673 14.327-32 32-32zM640 181.333c17.673 0 32 14.327 32 32v597.334c0 17.673-14.327 32-32 32H384c-17.673 0-32-14.327-32-32V213.333c0-17.673 14.327-32 32-32z m-32 64H416v533.333h192V245.333z" />'),distributeV:qt('<path d="M896 821.333c17.673 0 32 14.327 32 32 0 17.497-14.042 31.713-31.47 31.996l-0.53 0.004H128c-17.673 0-32-14.327-32-32 0-17.496 14.042-31.713 31.47-31.995l0.53-0.005h768zM810.667 352c17.673 0 32 14.327 32 32v256c0 17.673-14.327 32-32 32H213.333c-17.673 0-32-14.327-32-32V384c0-17.673 14.327-32 32-32z m-32 64H245.334v192h533.333V416zM896 138.667c17.673 0 32 14.327 32 32 0 17.496-14.042 31.713-31.47 31.995l-0.53 0.005H128c-17.673 0-32-14.327-32-32 0-17.497 14.042-31.713 31.47-31.996l0.53-0.004h768z" />')},ec="infographic-edit-popover",It=`${ec}__content`,Cn=`${ec}__arrow`,poe="infographic-edit-popover-style";function ji(e){var t,n,r,i,o,s,a,l;goe();const c=(t=e.placement)!=null?t:"top",u=(n=e.closeOnOutsideClick)!=null?n:!0,h=Array.isArray(e.trigger)?e.trigger:[e.trigger||"hover"],f=(r=e.mouseEnterDelay)!=null?r:50,d=(i=e.mouseLeaveDelay)!=null?i:150,p=(o=e.offset)!=null?o:8,g=8,m=7,v=typeof e.padding=="number"?`${e.padding}px`:(s=e.padding)!=null?s:"4px",b=document.createElement("div");b.classList.add(ec);const _=(a=e.target)!=null?a:document.createElement("div");b.appendChild(_);const x=()=>{const j=typeof e.getContainer=="function"?e.getContainer():e.getContainer;return j!=null?j:document.body},w=document.createElement("div");w.classList.add(It),xo(w,Oc),w.dataset.placement=Array.isArray(c)?c[0]:c,w.setAttribute("data-open",String(!!e.open)),w.style.setProperty("--popover-gap",`${p}px`),w.style.setProperty("--popover-arrow-size",`${g}px`),w.style.setProperty("--popover-arrow-inner-size",`${m}px`);const C=x(),P=C!==b,O=document.createElement("div");O.classList.add(Cn),w.appendChild(O);const $=document.createElement("div");$.classList.add(`${It}-body`),$.style.padding=v,w.appendChild($),C.appendChild(w);let S=!!e.open,M=Array.isArray(c)?c:[c],I=(l=M[0])!=null?l:"top";const E=()=>{var j;const V=_.getBoundingClientRect(),U=w.getBoundingClientRect(),K=window.scrollX||document.documentElement.scrollLeft,ne=window.scrollY||document.documentElement.scrollTop,J=document.documentElement.clientWidth,se=document.documentElement.clientHeight;let Z=0,te=0;const ue=ie=>{switch(ie){case"top":return{left:K+V.left+V.width/2-U.width/2,top:ne+V.top-U.height-p};case"bottom":return{left:K+V.left+V.width/2-U.width/2,top:ne+V.bottom+p};case"left":return{left:K+V.left-U.width-p,top:ne+V.top+V.height/2-U.height/2};default:return{left:K+V.right+p,top:ne+V.top+V.height/2-U.height/2}}},re=(ie,le)=>ie>=K&&le>=ne&&ie+U.width<=K+J&&le+U.height<=ne+se;let ee=(j=M[0])!=null?j:"top",oe=ue(ee);for(const ie of M){const le=ue(ie);if(oe=le,re(le.left,le.top)){ee=ie;break}}I=ee,w.dataset.placement=I,P&&({left:Z,top:te}=oe,w.style.left=`${Z}px`,w.style.top=`${te}px`,w.style.right="auto",w.style.bottom="auto",w.style.transform="translate(0, 0)")};P&&(w.style.position="absolute",window.addEventListener("resize",E),window.addEventListener("scroll",E,!0));const A=j=>{let V=j;typeof V=="function"&&(V=V()),$.innerHTML="",V instanceof HTMLElement?$.appendChild(V):$.textContent=V!=null?V:"",E()},T=j=>{var V;M=Array.isArray(j)?j:[j],I=(V=M[0])!=null?V:"top",E()},N=j=>{S=j,w.setAttribute("data-open",String(S)),S&&E(),S&&u?document.addEventListener("click",D,!0):document.removeEventListener("click",D,!0)},H=()=>N(!S),D=j=>{const V=j.target;!b.contains(V)&&(!P||!w.contains(V))&&N(!1)};let B,F;const X=h.includes("hover"),G=h.includes("click"),L=()=>{B!==void 0&&(clearTimeout(B),B=void 0),F!==void 0&&(clearTimeout(F),F=void 0)},R=()=>{X&&(L(),B=window.setTimeout(()=>N(!0),f))},z=()=>{X&&(L(),F=window.setTimeout(()=>N(!1),d))};return G&&_.addEventListener("click",H),X&&(b.addEventListener("mouseenter",R),b.addEventListener("mouseleave",z),w.addEventListener("mouseenter",R),w.addEventListener("mouseleave",z)),A(e.content),T(c),N(S),Object.assign(b,{setOpen:N,toggle:H,setContent:A,setPlacement:T,destroy:()=>{document.removeEventListener("click",D,!0),G&&_.removeEventListener("click",H),X&&(b.removeEventListener("mouseenter",R),b.removeEventListener("mouseleave",z),w.removeEventListener("mouseenter",R),w.removeEventListener("mouseleave",z),L()),P&&(window.removeEventListener("resize",E),window.removeEventListener("scroll",E,!0),w.remove()),b.remove()}})}function goe(){An(poe,`
|
|
298
|
+
.${ec} {
|
|
299
299
|
position: relative;
|
|
300
300
|
display: inline-flex;
|
|
301
301
|
}
|
|
302
|
-
.${
|
|
302
|
+
.${It} {
|
|
303
303
|
position: absolute;
|
|
304
304
|
z-index: 1200;
|
|
305
305
|
padding: 0;
|
|
@@ -315,34 +315,34 @@ ${e.trim()}
|
|
|
315
315
|
pointer-events: none;
|
|
316
316
|
transition: opacity 120ms ease, transform 120ms ease, visibility 120ms ease;
|
|
317
317
|
}
|
|
318
|
-
.${
|
|
318
|
+
.${It}-body {
|
|
319
319
|
padding: 4px;
|
|
320
320
|
color: #000000d9;
|
|
321
321
|
font-size: 12px;
|
|
322
322
|
line-height: 1.5;
|
|
323
323
|
}
|
|
324
|
-
.${
|
|
324
|
+
.${It}[data-open="true"] {
|
|
325
325
|
opacity: 1;
|
|
326
326
|
visibility: visible;
|
|
327
327
|
pointer-events: auto;
|
|
328
328
|
}
|
|
329
|
-
.${
|
|
329
|
+
.${Cn} {
|
|
330
330
|
position: absolute;
|
|
331
331
|
width: 0;
|
|
332
332
|
height: 0;
|
|
333
333
|
}
|
|
334
|
-
.${
|
|
334
|
+
.${Cn}::after {
|
|
335
335
|
content: '';
|
|
336
336
|
position: absolute;
|
|
337
337
|
width: 0;
|
|
338
338
|
height: 0;
|
|
339
339
|
}
|
|
340
|
-
.${
|
|
340
|
+
.${It}[data-placement="top"] {
|
|
341
341
|
left: 50%;
|
|
342
342
|
bottom: calc(100% + var(--popover-gap));
|
|
343
343
|
transform: translate(-50%, calc(-1 * var(--popover-gap) / 2));
|
|
344
344
|
}
|
|
345
|
-
.${
|
|
345
|
+
.${It}[data-placement="top"] .${Cn} {
|
|
346
346
|
left: 50%;
|
|
347
347
|
bottom: calc(-1 * var(--popover-arrow-size));
|
|
348
348
|
transform: translateX(-50%);
|
|
@@ -350,7 +350,7 @@ ${e.trim()}
|
|
|
350
350
|
border-right: var(--popover-arrow-size) solid transparent;
|
|
351
351
|
border-top: var(--popover-arrow-size) solid rgba(239, 240, 240, 0.9);
|
|
352
352
|
}
|
|
353
|
-
.${
|
|
353
|
+
.${It}[data-placement="top"] .${Cn}::after {
|
|
354
354
|
left: 50%;
|
|
355
355
|
bottom: 1px;
|
|
356
356
|
transform: translateX(-50%);
|
|
@@ -358,15 +358,15 @@ ${e.trim()}
|
|
|
358
358
|
border-right: var(--popover-arrow-inner-size) solid transparent;
|
|
359
359
|
border-top: var(--popover-arrow-inner-size) solid #fff;
|
|
360
360
|
}
|
|
361
|
-
.${
|
|
361
|
+
.${It}[data-placement="top"][data-open="true"] {
|
|
362
362
|
transform: translate(-50%, 0);
|
|
363
363
|
}
|
|
364
|
-
.${
|
|
364
|
+
.${It}[data-placement="bottom"] {
|
|
365
365
|
left: 50%;
|
|
366
366
|
top: calc(100% + var(--popover-gap));
|
|
367
367
|
transform: translate(-50%, calc(var(--popover-gap) / 2));
|
|
368
368
|
}
|
|
369
|
-
.${
|
|
369
|
+
.${It}[data-placement="bottom"] .${Cn} {
|
|
370
370
|
left: 50%;
|
|
371
371
|
top: calc(-1 * var(--popover-arrow-size) + 2px);
|
|
372
372
|
transform: translateX(-50%);
|
|
@@ -374,7 +374,7 @@ ${e.trim()}
|
|
|
374
374
|
border-right: var(--popover-arrow-size) solid transparent;
|
|
375
375
|
border-bottom: var(--popover-arrow-size) solid rgba(239, 240, 240, 0.9);
|
|
376
376
|
}
|
|
377
|
-
.${
|
|
377
|
+
.${It}[data-placement="bottom"] .${Cn}::after {
|
|
378
378
|
left: 50%;
|
|
379
379
|
top: 1px;
|
|
380
380
|
transform: translateX(-50%);
|
|
@@ -382,15 +382,15 @@ ${e.trim()}
|
|
|
382
382
|
border-right: var(--popover-arrow-inner-size) solid transparent;
|
|
383
383
|
border-bottom: var(--popover-arrow-inner-size) solid #fff;
|
|
384
384
|
}
|
|
385
|
-
.${
|
|
385
|
+
.${It}[data-placement="bottom"][data-open="true"] {
|
|
386
386
|
transform: translate(-50%, 0);
|
|
387
387
|
}
|
|
388
|
-
.${
|
|
388
|
+
.${It}[data-placement="left"] {
|
|
389
389
|
right: calc(100% + var(--popover-gap));
|
|
390
390
|
top: 50%;
|
|
391
391
|
transform: translate(calc(-1 * var(--popover-gap) / 2), -50%);
|
|
392
392
|
}
|
|
393
|
-
.${
|
|
393
|
+
.${It}[data-placement="left"] .${Cn} {
|
|
394
394
|
right: calc(-1 * var(--popover-arrow-size) + 1px);
|
|
395
395
|
top: 50%;
|
|
396
396
|
transform: translateY(-50%);
|
|
@@ -399,7 +399,7 @@ ${e.trim()}
|
|
|
399
399
|
border-left: var(--popover-arrow-size) solid rgba(239, 240, 240, 0.9);
|
|
400
400
|
border-right: 0;
|
|
401
401
|
}
|
|
402
|
-
.${
|
|
402
|
+
.${It}[data-placement="left"] .${Cn}::after {
|
|
403
403
|
right: 1px;
|
|
404
404
|
top: 50%;
|
|
405
405
|
transform: translateY(-50%);
|
|
@@ -408,15 +408,15 @@ ${e.trim()}
|
|
|
408
408
|
border-left: var(--popover-arrow-inner-size) solid #fff;
|
|
409
409
|
border-right: 0;
|
|
410
410
|
}
|
|
411
|
-
.${
|
|
411
|
+
.${It}[data-placement="left"][data-open="true"] {
|
|
412
412
|
transform: translate(0, -50%);
|
|
413
413
|
}
|
|
414
|
-
.${
|
|
414
|
+
.${It}[data-placement="right"] {
|
|
415
415
|
left: calc(100% + var(--popover-gap));
|
|
416
416
|
top: 50%;
|
|
417
417
|
transform: translate(calc(var(--popover-gap) / 2), -50%);
|
|
418
418
|
}
|
|
419
|
-
.${
|
|
419
|
+
.${It}[data-placement="right"] .${Cn} {
|
|
420
420
|
left: calc(-1 * var(--popover-arrow-size) + 1px);
|
|
421
421
|
top: 50%;
|
|
422
422
|
transform: translateY(-50%);
|
|
@@ -425,7 +425,7 @@ ${e.trim()}
|
|
|
425
425
|
border-right: var(--popover-arrow-size) solid rgba(239, 240, 240, 0.9);
|
|
426
426
|
border-left: 0;
|
|
427
427
|
}
|
|
428
|
-
.${
|
|
428
|
+
.${It}[data-placement="right"] .${Cn}::after {
|
|
429
429
|
left: 1px;
|
|
430
430
|
top: 50%;
|
|
431
431
|
transform: translateY(-50%);
|
|
@@ -433,28 +433,28 @@ ${e.trim()}
|
|
|
433
433
|
border-bottom: var(--popover-arrow-inner-size) solid transparent;
|
|
434
434
|
border-right: var(--popover-arrow-inner-size) solid #fff;
|
|
435
435
|
}
|
|
436
|
-
.${
|
|
436
|
+
.${It}[data-placement="right"][data-open="true"] {
|
|
437
437
|
transform: translate(0, -50%);
|
|
438
438
|
}
|
|
439
|
-
`)}const
|
|
440
|
-
.${
|
|
439
|
+
`)}const ym="infographic-align-grid",l$=`${ym}--compact`,moe="infographic-align-grid-style",yoe=`
|
|
440
|
+
.${ym} {
|
|
441
441
|
display: grid;
|
|
442
442
|
grid-template-columns: repeat(4, 32px);
|
|
443
443
|
grid-auto-rows: 32px;
|
|
444
444
|
gap: 2px;
|
|
445
445
|
}
|
|
446
|
-
.${
|
|
446
|
+
.${l$} {
|
|
447
447
|
grid-template-columns: repeat(3, 32px);
|
|
448
448
|
}
|
|
449
|
-
`,
|
|
450
|
-
.${
|
|
449
|
+
`,c$=[{icon:Jn.alignLeft,action:"LEFT"},{icon:Jn.alignH,action:"H_CENTER"},{icon:Jn.alignRight,action:"RIGHT"},{icon:Jn.distributeH,action:"H_DISTRIBUTE"},{icon:Jn.alignTop,action:"TOP"},{icon:Jn.alignV,action:"V_CENTER"},{icon:Jn.alignBottom,action:"BOTTOM"},{icon:Jn.distributeV,action:"V_DISTRIBUTE"}],voe=(e,t,n,r)=>{var i;An(moe,yoe);const o=(i=r==null?void 0:r.enableDistribution)!=null?i:!0,s=boe(a=>_oe(e,a,n),o);return ji({target:Jr({icon:Jn.align}),content:s,placement:"top",offset:12})};function boe(e,t){const n=document.createElement("div");return n.classList.add(ym),t||n.classList.add(l$),(t?c$:c$.filter(({action:i})=>i!=="H_DISTRIBUTE"&&i!=="V_DISTRIBUTE")).forEach(({icon:i,action:o})=>{const s=Jr({icon:i,onClick:()=>e(o)});n.appendChild(s)}),n}function _oe(e,t,n){if(!e.length)return;const r=e[0].ownerSVGElement;if(!r)return;const i=e.map(u=>Coe(u,r)).filter(Boolean);if(!i.length)return;const o=i.filter(u=>u.movable);if(!o.length)return;const s=i.filter(u=>!u.movable),a=s.length?s:i,l=Ci(a.map(u=>u.bounds)),c=[];switch(t){case"LEFT":{const u=l.x;o.forEach(h=>{const f=u-h.bounds.x;vr(c,h,f,0)});break}case"H_CENTER":{const u=l.x+l.width/2;o.forEach(h=>{const f=u-(h.bounds.x+h.bounds.width/2);vr(c,h,f,0)});break}case"RIGHT":{const u=l.x+l.width;o.forEach(h=>{const f=u-(h.bounds.x+h.bounds.width);vr(c,h,f,0)});break}case"TOP":{const u=l.y;o.forEach(h=>{const f=u-h.bounds.y;vr(c,h,0,f)});break}case"V_CENTER":{const u=l.y+l.height/2;o.forEach(h=>{const f=u-(h.bounds.y+h.bounds.height/2);vr(c,h,0,f)});break}case"BOTTOM":{const u=l.y+l.height;o.forEach(h=>{const f=u-(h.bounds.y+h.bounds.height);vr(c,h,0,f)});break}case"H_DISTRIBUTE":{woe(i,c);break}case"V_DISTRIBUTE":{xoe(i,c);break}}c.length&&n.executeBatch(c)}function woe(e,t){if(e.length<=2)return;const n=[...e].sort((i,o)=>i.bounds.x-o.bounds.x||i.bounds.y-o.bounds.y),r=u$(n);for(let i=0;i<r.length-1;i++){const o=r[i],s=r[i+1],a=n[o],l=n[s],c=n.slice(o+1,s);if(!c.length)continue;const u=l.bounds.x-(a.bounds.x+a.bounds.width),h=c.reduce((p,g)=>p+g.bounds.width,0),f=(u-h)/(c.length+1);let d=a.bounds.x+a.bounds.width+f;c.forEach(p=>{const g=d-p.bounds.x;vr(t,p,g,0),d+=p.bounds.width+f})}}function xoe(e,t){if(e.length<=2)return;const n=[...e].sort((i,o)=>i.bounds.y-o.bounds.y||i.bounds.x-o.bounds.x),r=u$(n);for(let i=0;i<r.length-1;i++){const o=r[i],s=r[i+1],a=n[o],l=n[s],c=n.slice(o+1,s);if(!c.length)continue;const u=l.bounds.y-(a.bounds.y+a.bounds.height),h=c.reduce((p,g)=>p+g.bounds.height,0),f=(u-h)/(c.length+1);let d=a.bounds.y+a.bounds.height+f;c.forEach(p=>{const g=d-p.bounds.y;vr(t,p,0,g),d+=p.bounds.height+f})}}function u$(e){const t=new Set;return t.add(0),t.add(e.length-1),e.forEach((n,r)=>{n.movable||t.add(r)}),Array.from(t).sort((n,r)=>n-r)}function vr(e,t,n,r){const i=Poe(t,n,r);i&&e.push(i)}function Coe(e,t){const n=Zn(t,e),r=!fr(e),i=Soe(e);if(i)return{element:e,bounds:n,mode:"transform",startX:i.x,startY:i.y,hasX:!1,hasY:!1,hasDataX:!1,hasDataY:!1,restTransform:i.rest,originalTransform:i.original,movable:r};const{x:o,y:s,hasX:a,hasY:l,hasDataX:c,hasDataY:u}=Ooe(e,n);return{element:e,bounds:n,mode:"attr",startX:o,startY:s,hasX:a,hasY:l,hasDataX:c,hasDataY:u,movable:r}}function Poe(e,t,n){if(!e.movable||Math.abs(t)<1e-6&&Math.abs(n)<1e-6)return null;if(e.mode==="attr"){const o=e.startX+t,s=e.startY+n,a={x:o,y:s},l={};return l.x=e.hasX?e.startX:null,l.y=e.hasY?e.startY:null,e.hasDataX&&(a["data-x"]=o,l["data-x"]=e.startX),e.hasDataY&&(a["data-y"]=s,l["data-y"]=e.startY),new zn(e.element,{attributes:a},{attributes:l})}const r=$oe(e.startX+t,e.startY+n,e.restTransform),i=e.originalTransform!==void 0?e.originalTransform:null;return new zn(e.element,{attributes:{transform:r}},{attributes:{transform:i}})}function Ooe(e,t){const n=cn(e,["x","y","data-x","data-y"],!1),r=n.x!==null&&n.x!==void 0,i=n.y!==null&&n.y!==void 0,o=n["data-x"]!==null&&n["data-x"]!==void 0,s=n["data-y"]!==null&&n["data-y"]!==void 0,a=(p,g)=>{const m=p!=null?Number(p):NaN;return Number.isFinite(m)?m:g},l=a(n.x,NaN),c=a(n.y,NaN),u=a(n["data-x"],NaN),h=a(n["data-y"],NaN),f=Number.isFinite(l)?l:Number.isFinite(u)?u:t.x,d=Number.isFinite(c)?c:Number.isFinite(h)?h:t.y;return{x:f,y:d,hasX:r,hasY:i,hasDataX:o,hasDataY:s}}function Soe(e){var t;const n=e.getAttribute("transform");if(n===null)return null;const r=n.match(/translate\(\s*([-\d.]+)(?:[ ,]\s*([-\d.]+))?\s*\)/i);if(!r)return{x:0,y:0,rest:{before:n.trim(),after:""},original:n};const i=Number(r[1])||0,o=r[2]!==void 0&&Number(r[2])||0,s=(t=r.index)!=null?t:0,a=n.slice(0,s).trim(),l=n.slice(s+r[0].length).trim();return{x:i,y:o,rest:{before:a,after:l},original:n}}function $oe(e,t,n){const r=`translate(${e}, ${t})`;return[n==null?void 0:n.before,r,n==null?void 0:n.after].filter(o=>o&&o.length).join(" ")}var Eoe=Object.defineProperty,h$=Object.getOwnPropertySymbols,Moe=Object.prototype.hasOwnProperty,Ioe=Object.prototype.propertyIsEnumerable,f$=(e,t,n)=>t in e?Eoe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Aoe=(e,t)=>{for(var n in t||(t={}))Moe.call(t,n)&&f$(e,n,t[n]);if(h$)for(var n of h$(t))Ioe.call(t,n)&&f$(e,n,t[n]);return e};const d$="infographic-font-align-grid",Toe="infographic-font-align-grid-style",Roe=[{icon:Qn.alignLeft,align:"LEFT"},{icon:Qn.alignCenter,align:"CENTER"},{icon:Qn.alignRight,align:"RIGHT"}],koe=[{icon:Qn.alignTop,align:"TOP"},{icon:Qn.alignMiddle,align:"MIDDLE"},{icon:Qn.alignBottom,align:"BOTTOM"}],Loe=`
|
|
450
|
+
.${d$} {
|
|
451
451
|
display: grid;
|
|
452
452
|
grid-template-columns: repeat(3, 32px);
|
|
453
453
|
grid-auto-rows: 32px;
|
|
454
454
|
gap: 2px;
|
|
455
455
|
}
|
|
456
|
-
`,
|
|
457
|
-
.${
|
|
456
|
+
`,p$=(e,t,n)=>{An(Toe,Loe);const r={horizontal:t["data-horizontal-align"],vertical:t["data-vertical-align"]},i=Jr({icon:Qn.align}),o=Noe(r,s=>{const a={};s.horizontal&&(a["data-horizontal-align"]=s.horizontal),s.vertical&&(a["data-vertical-align"]=s.vertical),Object.keys(a).length&&n.executeBatch(e.map(l=>new zn(l,{attributes:a})))});return ji({target:i,content:o,placement:"top",offset:12})};function Noe(e,t){const n=document.createElement("div");n.classList.add(d$);const r={},i=()=>{Object.entries(r).forEach(([s,a])=>{const l=s===e.horizontal||s===e.vertical;a.setActivate(l)})},o=(s,a)=>{s.forEach(({icon:l,align:c})=>{const u=Jr({icon:l,onClick:()=>{e[a]!==c&&(Object.assign(e,{[a]:c}),i(),t(Aoe({},e)))},activate:c===e[a]});r[c]=u,n.appendChild(u)})};return o(Roe,"horizontal"),o(koe,"vertical"),n}const tc="infographic-font-color-btn",zoe="infographic-font-color-style",vm="#1f1f1f",g$=(e,t,n)=>{qoe();const r=Doe(t.fill),i=t.fill===void 0&&e.length>1,o=document.createElement("button");o.type="button",o.classList.add(tc),m$(o,r!=null?r:vm,i);const s=r$({value:r!=null?r:vm,onChange:a=>{m$(o,a,!1),n.executeBatch(e.map(l=>new zn(l,{attributes:{fill:a}})))}});return ji({target:o,content:s,placement:["top","bottom"],offset:12,trigger:"hover",closeOnOutsideClick:!0,open:!1,padding:0})};function Doe(e){if(e)return Pr(e)?e:void 0}function m$(e,t,n){e.style.setProperty("--infographic-font-color",t),n?e.setAttribute("data-mixed","true"):e.removeAttribute("data-mixed")}function qoe(){An(zoe,`
|
|
457
|
+
.${tc} {
|
|
458
458
|
position: relative;
|
|
459
459
|
width: 32px;
|
|
460
460
|
height: 32px;
|
|
@@ -464,15 +464,15 @@ ${e.trim()}
|
|
|
464
464
|
cursor: pointer;
|
|
465
465
|
transition: box-shadow 0.2s ease, border-color 0.2s ease;
|
|
466
466
|
}
|
|
467
|
-
.${
|
|
467
|
+
.${tc}::after {
|
|
468
468
|
content: '';
|
|
469
469
|
position: absolute;
|
|
470
470
|
inset: 6px;
|
|
471
471
|
border-radius: 50%;
|
|
472
|
-
background: var(--infographic-font-color, ${
|
|
472
|
+
background: var(--infographic-font-color, ${vm});
|
|
473
473
|
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
|
|
474
474
|
}
|
|
475
|
-
.${
|
|
475
|
+
.${tc}[data-mixed="true"]::after {
|
|
476
476
|
background: repeating-linear-gradient(
|
|
477
477
|
45deg,
|
|
478
478
|
#d9d9d9 0,
|
|
@@ -481,8 +481,8 @@ ${e.trim()}
|
|
|
481
481
|
#f5f5f5 12px
|
|
482
482
|
);
|
|
483
483
|
}
|
|
484
|
-
`)}const
|
|
485
|
-
.${
|
|
484
|
+
`)}const bm="infographic-font-family-list",nc=`${bm}__option`,Hoe="infographic-font-family-list-style",joe="默认",y$=(e,t,n)=>{Boe();const r=Nu(),i=v$(t["font-family"]),o=r.map(u=>({label:u.name||u.fontFamily,value:u.fontFamily}));o.some(u=>v$(u.value)===i)||o.unshift({label:joe,value:i});let s=i;const a=Foe(o,s,u=>{s!==u&&(s=u,n.executeBatch(e.map(h=>new zn(h,{attributes:{"font-family":gi(u)}}))))}),l=Jr({icon:Qn.fontFamily});return ji({target:l,content:a,placement:["top","bottom"],offset:12,trigger:"hover",closeOnOutsideClick:!0,open:!1,padding:0})};function Foe(e,t,n){const r=document.createElement("div");r.classList.add(bm);const i={},o=s=>{Object.entries(i).forEach(([a,l])=>{a===s?l.setAttribute("data-activate","true"):l.removeAttribute("data-activate")})};return e.forEach(({label:s,value:a})=>{const l=document.createElement("button");l.type="button",l.classList.add(nc),l.textContent=s,l.style.fontFamily=a,a===t&&l.setAttribute("data-activate","true"),l.addEventListener("click",()=>{t!==a&&(t=a,o(t),n(a))}),i[a]=l,r.appendChild(l)}),r}function v$(e){return e?Array.isArray(e)?Ar(e.join(", ")):Ar(String(e)):""}function Boe(){An(Hoe,`
|
|
485
|
+
.${bm} {
|
|
486
486
|
display: flex;
|
|
487
487
|
flex-direction: column;
|
|
488
488
|
gap: 2px;
|
|
@@ -491,7 +491,7 @@ ${e.trim()}
|
|
|
491
491
|
max-height: 220px;
|
|
492
492
|
overflow-y: auto;
|
|
493
493
|
}
|
|
494
|
-
.${
|
|
494
|
+
.${nc} {
|
|
495
495
|
width: 100%;
|
|
496
496
|
text-align: left;
|
|
497
497
|
padding: 6px 10px;
|
|
@@ -503,22 +503,22 @@ ${e.trim()}
|
|
|
503
503
|
color: #000000d9;
|
|
504
504
|
transition: background-color 0.2s ease, color 0.2s ease;
|
|
505
505
|
}
|
|
506
|
-
.${
|
|
506
|
+
.${nc}:hover {
|
|
507
507
|
background: #f5f5f5;
|
|
508
508
|
}
|
|
509
|
-
.${
|
|
509
|
+
.${nc}[data-activate="true"] {
|
|
510
510
|
background: #e6f4ff;
|
|
511
511
|
color: #0958d9;
|
|
512
512
|
}
|
|
513
|
-
`)}const
|
|
514
|
-
.${$
|
|
513
|
+
`)}const b$="infographic-font-size-grid",Woe="infographic-font-size-grid-style",Voe=[{label:"XS",value:12},{label:"S",value:14},{label:"M",value:16},{label:"L",value:20},{label:"XL",value:24}],Goe=`
|
|
514
|
+
.${b$} {
|
|
515
515
|
display: grid;
|
|
516
516
|
grid-template-columns: repeat(5, 32px);
|
|
517
517
|
grid-auto-rows: 32px;
|
|
518
518
|
gap: 2px;
|
|
519
519
|
}
|
|
520
|
-
`,
|
|
521
|
-
.${
|
|
520
|
+
`,_$=(e,t,n)=>{An(Woe,Goe);const r=Jr({icon:Qn.fontSize}),i=Uoe(t["font-size"]),o=Yoe(i,s=>{n.executeBatch(e.map(a=>new zn(a,{attributes:{"font-size":s}})))});return ji({target:r,content:o,placement:"top",offset:12})};function Yoe(e,t){const n=document.createElement("div");n.classList.add(b$);let r=e;const i={},o=()=>{Object.entries(i).forEach(([s,a])=>{const l=Number(s)===r;a.setActivate(l)})};return Voe.forEach(({label:s,value:a})=>{const l=Jr({icon:Xoe(s),onClick:()=>{r!==a&&(r=a,o(),t(a))},activate:a===r});i[String(a)]=l,n.appendChild(l)}),n}function Xoe(e){return()=>{const t="1.2em",n=document.createElement("span");return n.textContent=e,n.style.display="inline-flex",n.style.alignItems="center",n.style.justifyContent="center",n.style.width=t,n.style.height=t,n.style.fontSize="12px",n}}function Uoe(e){if(typeof e=="number")return e;if(typeof e=="string"){const n=parseFloat(e);return Number.isFinite(n)?n:12}return 12}const rc="infographic-icon-color-btn",Koe="infographic-icon-color-style",_m="#1f1f1f",w$=(e,t,n)=>{Qoe();const r=Zoe(t.fill),i=t.fill===void 0&&e.length>1,o=document.createElement("button");o.type="button",o.classList.add(rc),x$(o,r!=null?r:_m,i);const s=r$({value:r!=null?r:_m,onChange:a=>{x$(o,a,!1),n.executeBatch(e.map(l=>new zn(l,{attributes:{fill:a}})))}});return ji({target:o,content:s,placement:["top","bottom"],offset:12,trigger:"hover",closeOnOutsideClick:!0,open:!1,padding:0})};function Zoe(e){if(e)return Pr(e)?e:void 0}function x$(e,t,n){e.style.setProperty("--infographic-icon-color",t),n?e.setAttribute("data-mixed","true"):e.removeAttribute("data-mixed")}function Qoe(){An(Koe,`
|
|
521
|
+
.${rc} {
|
|
522
522
|
position: relative;
|
|
523
523
|
width: 32px;
|
|
524
524
|
height: 32px;
|
|
@@ -528,15 +528,15 @@ ${e.trim()}
|
|
|
528
528
|
cursor: pointer;
|
|
529
529
|
transition: box-shadow 0.2s ease, border-color 0.2s ease;
|
|
530
530
|
}
|
|
531
|
-
.${
|
|
531
|
+
.${rc}::after {
|
|
532
532
|
content: '';
|
|
533
533
|
position: absolute;
|
|
534
534
|
inset: 6px;
|
|
535
535
|
border-radius: 50%;
|
|
536
|
-
background: var(--infographic-icon-color, ${
|
|
536
|
+
background: var(--infographic-icon-color, ${_m});
|
|
537
537
|
box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
|
|
538
538
|
}
|
|
539
|
-
.${
|
|
539
|
+
.${rc}[data-mixed="true"]::after {
|
|
540
540
|
background: repeating-linear-gradient(
|
|
541
541
|
45deg,
|
|
542
542
|
#d9d9d9 0,
|
|
@@ -545,16 +545,45 @@ ${e.trim()}
|
|
|
545
545
|
#f5f5f5 12px
|
|
546
546
|
);
|
|
547
547
|
}
|
|
548
|
-
`)}var $ie=Object.defineProperty,MO=Object.getOwnPropertySymbols,Cie=Object.prototype.hasOwnProperty,Oie=Object.prototype.propertyIsEnumerable,EO=(e,t,n)=>t in e?$ie(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Sie=(e,t)=>{for(var n in t||(t={}))Cie.call(t,n)&&EO(e,n,t[n]);if(MO)for(var n of MO(t))Oie.call(t,n)&&EO(e,n,t[n]);return e};class IO extends K1{constructor(t){super(),this.options=t,this.name="edit-bar",this.selection=[],this.handleSelectionChanged=({next:n})=>{if(this.selection=n,n.length===0){this.container&&AO(this.container);return}const r=this.getOrCreateEditBar(),i=this.getEditItems(n);if(i.length===0){AO(r);return}Mie(r,i),this.placeEditBar(r,n),rm(r)},this.handleGeometryChanged=({target:n})=>{!this.selection.includes(n)||!this.container||(this.placeEditBar(this.container,this.selection),rm(this.container))},this.handleHistoryChanged=()=>{!this.container||this.selection.length===0||(this.placeEditBar(this.container,this.selection),rm(this.container))}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChanged),n.on("selection:geometrychange",this.handleGeometryChanged),n.on("history:change",this.handleHistoryChanged)}destroy(){var t;const{emitter:n}=this;n.off("selection:change",this.handleSelectionChanged),n.off("selection:geometrychange",this.handleGeometryChanged),n.off("history:change",this.handleHistoryChanged),(t=this.container)==null||t.remove()}getEditItems(t){let n=!1,r=!1,i=!1;for(const o of t)if(Fn(o)?n=!0:cr(o)?r=!0:kD(o)&&(i=!0),n&&r&&i)break;return n&&!r&&!i?t.length===1?this.getTextEditItems(t[0]):this.getTextCollectionEditItems(t):!n&&r&&!i?t.length===1?this.getIconEditItems(t):this.getIconCollectionEditItems(t):!n&&!r&&i?t.length===1?this.getGeometryEditItems(t):this.getGeometryCollectionEditItems(t):this.getElementCollectionEditItems(t)}getOrCreateEditBar(){if(this.container)return this.container;const{style:t,className:n}=this.options||{},r=document.createElement("div");Object.assign(r.style,Sie({visibility:"hidden",position:"absolute",left:"0",top:"0",display:"flex",flexFlow:"row",justifyContent:"center",alignItems:"center",height:"40px",minWidth:"40px",minHeight:"40px",borderRadius:"8px",padding:"0 4px",backgroundColor:"#fff",border:"1px solid rgba(239, 240, 240, 0.9)",zIndex:"9999",boxShadow:"rgba(0, 0, 0, 0.08) 0px 1px 2px -2px, rgba(0, 0, 0, 0.04) 0px 2px 6px, rgba(0, 0, 0, 0.02) 0px 4px 8px 1px"},t)),n&&r.classList.add(n),po(r,sl),this.container=r;const{getContainer:i}=this.options||{},o=typeof i=="function"?i():i,a=o!=null?o:document.body;return a==null||a.appendChild(r),r}getTextEditItems(t){const{attributes:n={}}=qu(t);return[_O,CO,bO,wO].map(r=>r([t],n,this.commander))}getTextCollectionEditItems(t){const n=jm(t.map(o=>qu(o).attributes||{})),r=[_O,CO,bO,wO].map(o=>o(t,n,this.commander)),i=this.getElementCollectionEditItems(t);return[...r,...i]}getIconEditItems(t){const n=Gu(t[0]);return[OO].map(r=>r(t,n,this.commander))}getIconCollectionEditItems(t){const n=jm(t.map(r=>Gu(r)));return[OO].map(r=>r(t,n,this.commander))}getGeometryEditItems(t){return[]}getGeometryCollectionEditItems(t){return[...this.getElementCollectionEditItems(t)]}getElementCollectionEditItems(t){return t.length<=1?[]:[Bre(t,{},this.commander,{enableDistribution:t.length>2})]}placeEditBar(t,n){var r;if(n.length===0)return;const i=yi(n.map(_=>_.getBoundingClientRect())),o=(r=t.offsetParent)!=null?r:document.documentElement,a=document.documentElement.clientHeight,s=document.documentElement.clientWidth,c=t.getBoundingClientRect(),l=8,u={x:i.x+i.width/2,y:i.y},h={y:i.y+i.height},d=(_,x,w)=>Math.min(Math.max(_,x),w),f=u.y-l,g=a-h.y-l,y=f>=c.height||f>=g;if(o===document.body||o===document.documentElement){const _=window.scrollX||document.documentElement.scrollLeft,x=window.scrollY||document.documentElement.scrollTop;let w=_+u.x-c.width/2;w=d(w,_,_+Math.max(s-c.width,0));let P=y?x+u.y-c.height-l:x+h.y+l;P=d(P,x,x+Math.max(a-c.height,0)),t.style.left=`${w}px`,t.style.top=`${P}px`;return}const m=o.getBoundingClientRect();let v=u.x-m.left-c.width/2;v=d(v,0,Math.max(m.width-c.width,0));let b=y?u.y-m.top-c.height-l:h.y-m.top+l;b=d(b,0,Math.max(m.height-c.height,0)),t.style.left=`${v}px`,t.style.top=`${b}px`}}function rm(e){e.style.visibility="visible"}function AO(e){e.style.visibility="hidden"}function Mie(e,t){e.innerHTML="",t.forEach(n=>{e.appendChild(n)})}var Eie=Object.defineProperty,TO=Object.getOwnPropertySymbols,Iie=Object.prototype.hasOwnProperty,Aie=Object.prototype.propertyIsEnumerable,kO=(e,t,n)=>t in e?Eie(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tie=(e,t)=>{for(var n in t||(t={}))Iie.call(t,n)&&kO(e,n,t[n]);if(TO)for(var n of TO(t))Aie.call(t,n)&&kO(e,n,t[n]);return e};const Jo=class xn extends K1{constructor(){super(...arguments),this.name="resize-element",this.target=null,this.handles=[],this.activeHandle=null,this.activePointerId=null,this.handleSelectionChange=({next:t})=>{const n=t.length===1?t[0]:null;n&&Fn(n)?(this.target=n,this.updateHandles()):(this.target=null,this.hideHandles(),this.cancelDrag())},this.handleDeactivate=()=>{this.target=null,this.hideHandles(),this.cancelDrag()},this.handleGeometryChange=({target:t})=>{if(!this.target||t!==this.target)return;const n=this.getViewportRect(this.target);this.lastViewportRect=n,this.updateHandles(n)},this.handleHistoryChange=()=>{if(!this.target)return;const t=this.getViewportRect(this.target);this.lastViewportRect=t,this.updateHandles(t)},this.handlePointerMove=t=>{if(!this.target||!this.startPointer||!this.startRect||!this.activeHandle||this.activePointerId!==null&&t.pointerId!==this.activePointerId)return;const n=this.clientToElement(this.target,t.clientX,t.clientY),r=n.x-this.startPointer.x,i=n.y-this.startPointer.y,o=this.clampRect(this.applyDelta(this.startRect,r,i,this.activeHandle),this.activeHandle);this.lastRect=o,this.applyRect(this.target,o),this.lastViewportRect=this.getViewportRect(this.target),this.updateHandles(this.lastViewportRect),this.emitSelectionGeometryChange()},this.handlePointerUp=t=>{if(this.activePointerId!==null&&t.pointerId!==this.activePointerId)return;const n=this.lastRect,r=this.startAttrs,i=n&&this.startRect&&this.hasRectChanged(this.startRect,n);if(this.cancelDrag(),i&&this.target&&n&&r)this.commander.execute(new kn(this.target,{attributes:n},{attributes:r})),this.lastViewportRect=this.getViewportRect(this.target),this.updateHandles(this.lastViewportRect),this.emitSelectionGeometryChange();else if(this.target){const o=this.lastViewportRect||this.getViewportRect(this.target);this.updateHandles(o)}}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChange),n.on("selection:geometrychange",this.handleGeometryChange),n.on("history:change",this.handleHistoryChange),n.on("deactivated",this.handleDeactivate)}destroy(){this.cancelDrag(),this.removeContainer();const{emitter:t}=this;t.off("selection:change",this.handleSelectionChange),t.off("selection:geometrychange",this.handleGeometryChange),t.off("history:change",this.handleHistoryChange),t.off("deactivated",this.handleDeactivate)}ensureContainer(){if(this.container)return this.container;const t=Ee("g",{"pointer-events":"none"});this.overlay=Ee("rect",{fill:"rgba(51, 132, 245, 0.06)",stroke:"none","pointer-events":"none"});const n=Ee("rect",{fill:"none",stroke:"#3384F5","stroke-width":1,"stroke-dasharray":"4 2","pointer-events":"none"});t.appendChild(this.overlay),t.appendChild(n),this.outline=n;const r=xn.HANDLE_POSITIONS,i={"top-left":"nwse-resize",top:"ns-resize","top-right":"nesw-resize",right:"ew-resize","bottom-right":"nwse-resize",bottom:"ns-resize","bottom-left":"nesw-resize",left:"ew-resize"};return r.forEach((o,a)=>{const c=o==="top"||o==="right"||o==="bottom"||o==="left"?Ee("line",{stroke:"transparent","stroke-width":xn.LINE_STROKE_WIDTH}):Ee("circle",{r:xn.HANDLE_SIZE/2,fill:"#3384F5",stroke:"#fff","stroke-width":1.5});c.style.cursor=i[o],c.style.pointerEvents="all",c.addEventListener("pointerdown",l=>this.handlePointerDown(l,o)),c.addEventListener("click",l=>{l.stopPropagation(),l.preventDefault()}),t.appendChild(c),this.handles[a]=c}),this.editor.getDocument().appendChild(t),this.container=t,t}updateHandles(t){if(!this.target){this.hideHandles();return}const n=t||this.getViewportRect(this.target)||this.lastViewportRect||null;if(!n){this.hideHandles();return}this.lastViewportRect=n;const r=this.ensureContainer();r.style.display="block",this.outline.style.display="block",lt(this.outline,n),this.overlay&&(this.overlay.style.display="block",lt(this.overlay,n));const i=this.getHandlePoints(n);this.handles.forEach((o,a)=>{const[s,c]=i[a];if(o.tagName==="circle")lt(o,{cx:s,cy:c});else{const l=xn.HANDLE_POSITIONS[a],u=this.getHandleLine(n,l);lt(o,u)}o.style.display="block"})}hideHandles(){this.container&&(this.container.style.display="none"),this.outline&&(this.outline.style.display="none"),this.overlay&&(this.overlay.style.display="none"),this.handles.forEach(t=>t.style.display="none")}removeContainer(){var t;(t=this.container)==null||t.remove(),this.container=void 0,this.outline=void 0,this.overlay=void 0,this.handles=[]}handlePointerDown(t,n){if(!this.target||t.button!==0&&t.pointerType==="mouse")return;t.stopPropagation(),t.preventDefault();const r=this.clientToElement(this.target,t.clientX,t.clientY);this.activeHandle=n,this.activePointerId=t.pointerId,this.startPointer=r;const i=this.getCurrentAttributes(this.target);this.startRect=i,this.startAttrs=Tie({},i),this.lastRect=i,this.lastViewportRect=this.getViewportRect(this.target),window.addEventListener("pointermove",this.handlePointerMove),window.addEventListener("pointerup",this.handlePointerUp),window.addEventListener("pointercancel",this.handlePointerUp)}cancelDrag(){this.activeHandle=null,this.activePointerId=null,this.startPointer=void 0,this.startRect=void 0,this.startAttrs=void 0,this.lastRect=void 0,this.lastViewportRect=void 0,window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}applyRect(t,n){lt(t,{x:n.x,y:n.y,width:n.width,height:n.height})}getViewportRect(t){const{x:n,y:r,width:i,height:o}=Yn(this.editor.getDocument(),t);return{x:n,y:r,width:i,height:o}}clientToElement(t,n,r){var i,o;const a=((i=t.getScreenCTM())==null?void 0:i.inverse())||((o=this.editor.getDocument().getScreenCTM())==null?void 0:o.inverse())||new DOMMatrix;return new DOMPoint(n,r).matrixTransform(a)}getCurrentAttributes(t){const n=sn(t,["x","y","width","height"],!1),r=this.getViewportRect(t),i=(o,a)=>{const s=o!==null?Number(o):NaN;return Number.isFinite(s)?s:a};return{x:i(n.x,r.x),y:i(n.y,r.y),width:i(n.width,r.width),height:i(n.height,r.height)}}getHandlePoints(t){const{x:n,y:r,width:i,height:o}=t,a=n+i/2,s=r+o/2;return[[n,r],[a,r],[n+i,r],[n+i,s],[n+i,r+o],[a,r+o],[n,r+o],[n,s]]}applyDelta(t,n,r,i){let{x:o,y:a,width:s,height:c}=t;switch(i){case"top-left":o+=n,a+=r,s-=n,c-=r;break;case"top":a+=r,c-=r;break;case"top-right":a+=r,s+=n,c-=r;break;case"right":s+=n;break;case"bottom-right":s+=n,c+=r;break;case"bottom":c+=r;break;case"bottom-left":o+=n,s-=n,c+=r;break;case"left":o+=n,s-=n;break}return{x:o,y:a,width:s,height:c}}clampRect(t,n){let{x:r,y:i,width:o,height:a}=t;if(o<xn.MIN_SIZE){const s=xn.MIN_SIZE-o;(n==="top-left"||n==="bottom-left"||n==="left")&&(r-=s),o=xn.MIN_SIZE}if(a<xn.MIN_SIZE){const s=xn.MIN_SIZE-a;(n==="top-left"||n==="top-right"||n==="top")&&(i-=s),a=xn.MIN_SIZE}return{x:r,y:i,width:o,height:a}}hasRectChanged(t,n){return Math.abs(t.x-n.x)>.5||Math.abs(t.y-n.y)>.5||Math.abs(t.width-n.width)>.5||Math.abs(t.height-n.height)>.5}emitSelectionGeometryChange(){this.target&&this.lastViewportRect&&this.emitter.emit("selection:geometrychange",{type:"selection:geometrychange",target:this.target,rect:this.lastViewportRect})}getHandleLine(t,n){const{x:r,y:i,width:o,height:a}=t;switch(n){case"top":return{x1:r,y1:i,x2:r+o,y2:i};case"right":return{x1:r+o,y1:i,x2:r+o,y2:i+a};case"bottom":return{x1:r,y1:i+a,x2:r+o,y2:i+a};default:return{x1:r,y1:i,x2:r,y2:i+a}}}};Jo.HANDLE_SIZE=10,Jo.LINE_STROKE_WIDTH=8,Jo.MIN_SIZE=1,Jo.HANDLE_POSITIONS=["top-left","top","top-right","right","bottom-right","bottom","bottom-left","left"];let RO=Jo;function LO(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var im,zO;function kie(){if(zO)return im;zO=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g;im=function(r,i){i=i||{};var o=1,a=1;function s(H){var k=H.match(/\n/g);k&&(o+=k.length);var I=H.lastIndexOf(`
|
|
549
|
-
|
|
548
|
+
`)}var Joe=Object.defineProperty,C$=Object.getOwnPropertySymbols,ese=Object.prototype.hasOwnProperty,tse=Object.prototype.propertyIsEnumerable,P$=(e,t,n)=>t in e?Joe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nse=(e,t)=>{for(var n in t||(t={}))ese.call(t,n)&&P$(e,n,t[n]);if(C$)for(var n of C$(t))tse.call(t,n)&&P$(e,n,t[n]);return e};class O$ extends pm{constructor(t){super(),this.options=t,this.name="edit-bar",this.selection=[],this.handleSelectionChanged=({next:n})=>{if(this.selection=n,n.length===0){this.container&&S$(this.container);return}const r=this.getOrCreateEditBar(),i=this.getEditItems(n);if(i.length===0){S$(r);return}rse(r,i),this.placeEditBar(r,n),wm(r)},this.handleGeometryChanged=({target:n})=>{!this.selection.includes(n)||!this.container||(this.placeEditBar(this.container,this.selection),wm(this.container))},this.handleHistoryChanged=()=>{!this.container||this.selection.length===0||(this.placeEditBar(this.container,this.selection),wm(this.container))}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChanged),n.on("selection:geometrychange",this.handleGeometryChanged),n.on("history:change",this.handleHistoryChanged)}destroy(){var t;const{emitter:n}=this;n.off("selection:change",this.handleSelectionChanged),n.off("selection:geometrychange",this.handleGeometryChanged),n.off("history:change",this.handleHistoryChanged),(t=this.container)==null||t.remove()}getEditItems(t){let n=!1,r=!1,i=!1;for(const o of t)if(Gn(o)?n=!0:fr(o)?r=!0:lH(o)&&(i=!0),n&&r&&i)break;return n&&!r&&!i?t.length===1?this.getTextEditItems(t[0]):this.getTextCollectionEditItems(t):!n&&r&&!i?t.length===1?this.getIconEditItems(t):this.getIconCollectionEditItems(t):!n&&!r&&i?t.length===1?this.getGeometryEditItems(t):this.getGeometryCollectionEditItems(t):this.getElementCollectionEditItems(t)}getOrCreateEditBar(){if(this.container)return this.container;const{style:t,className:n}=this.options||{},r=document.createElement("div");Object.assign(r.style,nse({visibility:"hidden",position:"absolute",left:"0",top:"0",display:"flex",flexFlow:"row",justifyContent:"center",alignItems:"center",height:"40px",minWidth:"40px",minHeight:"40px",borderRadius:"8px",padding:"0 4px",backgroundColor:"#fff",border:"1px solid rgba(239, 240, 240, 0.9)",zIndex:"9999",boxShadow:"rgba(0, 0, 0, 0.08) 0px 1px 2px -2px, rgba(0, 0, 0, 0.04) 0px 2px 6px, rgba(0, 0, 0, 0.02) 0px 4px 8px 1px"},t)),n&&r.classList.add(n),xo(r,Oc),this.container=r;const{getContainer:i}=this.options||{},o=typeof i=="function"?i():i,s=o!=null?o:document.body;return s==null||s.appendChild(r),r}getTextEditItems(t){const{attributes:n={}}=ih(t);return[g$,_$,p$,y$].map(r=>r([t],n,this.commander))}getTextCollectionEditItems(t){const n=Ny(t.map(o=>ih(o).attributes||{})),r=[g$,_$,p$,y$].map(o=>o(t,n,this.commander)),i=this.getElementCollectionEditItems(t);return[...r,...i]}getIconEditItems(t){const n=ch(t[0]);return[w$].map(r=>r(t,n,this.commander))}getIconCollectionEditItems(t){const n=Ny(t.map(r=>ch(r)));return[w$].map(r=>r(t,n,this.commander))}getGeometryEditItems(t){return[]}getGeometryCollectionEditItems(t){return[...this.getElementCollectionEditItems(t)]}getElementCollectionEditItems(t){return t.length<=1?[]:[voe(t,{},this.commander,{enableDistribution:t.length>2})]}placeEditBar(t,n){var r;if(n.length===0)return;const i=Ci(n.map(_=>_.getBoundingClientRect())),o=(r=t.offsetParent)!=null?r:document.documentElement,s=document.documentElement.clientHeight,a=document.documentElement.clientWidth,l=t.getBoundingClientRect(),c=8,u={x:i.x+i.width/2,y:i.y},h={y:i.y+i.height},f=(_,x,w)=>Math.min(Math.max(_,x),w),d=u.y-c,p=s-h.y-c,g=d>=l.height||d>=p;if(o===document.body||o===document.documentElement){const _=window.scrollX||document.documentElement.scrollLeft,x=window.scrollY||document.documentElement.scrollTop;let w=_+u.x-l.width/2;w=f(w,_,_+Math.max(a-l.width,0));let C=g?x+u.y-l.height-c:x+h.y+c;C=f(C,x,x+Math.max(s-l.height,0)),t.style.left=`${w}px`,t.style.top=`${C}px`;return}const m=o.getBoundingClientRect();let v=u.x-m.left-l.width/2;v=f(v,0,Math.max(m.width-l.width,0));let b=g?u.y-m.top-l.height-c:h.y-m.top+c;b=f(b,0,Math.max(m.height-l.height,0)),t.style.left=`${v}px`,t.style.top=`${b}px`}}function wm(e){e.style.visibility="visible"}function S$(e){e.style.visibility="hidden"}function rse(e,t){e.innerHTML="",t.forEach(n=>{e.appendChild(n)})}var ise=Object.defineProperty,$$=Object.getOwnPropertySymbols,ose=Object.prototype.hasOwnProperty,sse=Object.prototype.propertyIsEnumerable,E$=(e,t,n)=>t in e?ise(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ase=(e,t)=>{for(var n in t||(t={}))ose.call(t,n)&&E$(e,n,t[n]);if($$)for(var n of $$(t))sse.call(t,n)&&E$(e,n,t[n]);return e};const as=class On extends pm{constructor(){super(...arguments),this.name="resize-element",this.target=null,this.handles=[],this.activeHandle=null,this.activePointerId=null,this.handleSelectionChange=({next:t})=>{const n=t.length===1?t[0]:null;n&&Gn(n)?(this.target=n,this.updateHandles()):(this.target=null,this.hideHandles(),this.cancelDrag())},this.handleDeactivate=()=>{this.target=null,this.hideHandles(),this.cancelDrag()},this.handleGeometryChange=({target:t})=>{if(!this.target||t!==this.target)return;const n=this.getViewportRect(this.target);this.lastViewportRect=n,this.updateHandles(n)},this.handleHistoryChange=()=>{if(!this.target)return;const t=this.getViewportRect(this.target);this.lastViewportRect=t,this.updateHandles(t)},this.handlePointerMove=t=>{if(!this.target||!this.startPointer||!this.startRect||!this.activeHandle||this.activePointerId!==null&&t.pointerId!==this.activePointerId)return;const n=this.clientToElement(this.target,t.clientX,t.clientY),r=n.x-this.startPointer.x,i=n.y-this.startPointer.y,o=this.clampRect(this.applyDelta(this.startRect,r,i,this.activeHandle),this.activeHandle);this.lastRect=o,this.applyRect(this.target,o),this.lastViewportRect=this.getViewportRect(this.target),this.updateHandles(this.lastViewportRect),this.emitSelectionGeometryChange()},this.handlePointerUp=t=>{if(this.activePointerId!==null&&t.pointerId!==this.activePointerId)return;const n=this.lastRect,r=this.startAttrs,i=n&&this.startRect&&this.hasRectChanged(this.startRect,n);if(this.cancelDrag(),i&&this.target&&n&&r)this.commander.execute(new zn(this.target,{attributes:n},{attributes:r})),this.lastViewportRect=this.getViewportRect(this.target),this.updateHandles(this.lastViewportRect),this.emitSelectionGeometryChange();else if(this.target){const o=this.lastViewportRect||this.getViewportRect(this.target);this.updateHandles(o)}}}init(t){super.init(t);const{emitter:n}=t;n.on("selection:change",this.handleSelectionChange),n.on("selection:geometrychange",this.handleGeometryChange),n.on("history:change",this.handleHistoryChange),n.on("deactivated",this.handleDeactivate)}destroy(){this.cancelDrag(),this.removeContainer();const{emitter:t}=this;t.off("selection:change",this.handleSelectionChange),t.off("selection:geometrychange",this.handleGeometryChange),t.off("history:change",this.handleHistoryChange),t.off("deactivated",this.handleDeactivate)}ensureContainer(){if(this.container)return this.container;const t=Me("g",{"pointer-events":"none"});this.overlay=Me("rect",{fill:"rgba(51, 132, 245, 0.06)",stroke:"none","pointer-events":"none"});const n=Me("rect",{fill:"none",stroke:"#3384F5","stroke-width":1,"stroke-dasharray":"4 2","pointer-events":"none"});t.appendChild(this.overlay),t.appendChild(n),this.outline=n;const r=On.HANDLE_POSITIONS,i={"top-left":"nwse-resize",top:"ns-resize","top-right":"nesw-resize",right:"ew-resize","bottom-right":"nwse-resize",bottom:"ns-resize","bottom-left":"nesw-resize",left:"ew-resize"};return r.forEach((o,s)=>{const l=o==="top"||o==="right"||o==="bottom"||o==="left"?Me("line",{stroke:"transparent","stroke-width":On.LINE_STROKE_WIDTH}):Me("circle",{r:On.HANDLE_SIZE/2,fill:"#3384F5",stroke:"#fff","stroke-width":1.5});l.style.cursor=i[o],l.style.pointerEvents="all",l.addEventListener("pointerdown",c=>this.handlePointerDown(c,o)),l.addEventListener("click",c=>{c.stopPropagation(),c.preventDefault()}),t.appendChild(l),this.handles[s]=l}),this.editor.getDocument().appendChild(t),this.container=t,t}updateHandles(t){if(!this.target){this.hideHandles();return}const n=t||this.getViewportRect(this.target)||this.lastViewportRect||null;if(!n){this.hideHandles();return}this.lastViewportRect=n;const r=this.ensureContainer();r.style.display="block",this.outline.style.display="block",ut(this.outline,n),this.overlay&&(this.overlay.style.display="block",ut(this.overlay,n));const i=this.getHandlePoints(n);this.handles.forEach((o,s)=>{const[a,l]=i[s];if(o.tagName==="circle")ut(o,{cx:a,cy:l});else{const c=On.HANDLE_POSITIONS[s],u=this.getHandleLine(n,c);ut(o,u)}o.style.display="block"})}hideHandles(){this.container&&(this.container.style.display="none"),this.outline&&(this.outline.style.display="none"),this.overlay&&(this.overlay.style.display="none"),this.handles.forEach(t=>t.style.display="none")}removeContainer(){var t;(t=this.container)==null||t.remove(),this.container=void 0,this.outline=void 0,this.overlay=void 0,this.handles=[]}handlePointerDown(t,n){if(!this.target||t.button!==0&&t.pointerType==="mouse")return;t.stopPropagation(),t.preventDefault();const r=this.clientToElement(this.target,t.clientX,t.clientY);this.activeHandle=n,this.activePointerId=t.pointerId,this.startPointer=r;const i=this.getCurrentAttributes(this.target);this.startRect=i,this.startAttrs=ase({},i),this.lastRect=i,this.lastViewportRect=this.getViewportRect(this.target),window.addEventListener("pointermove",this.handlePointerMove),window.addEventListener("pointerup",this.handlePointerUp),window.addEventListener("pointercancel",this.handlePointerUp)}cancelDrag(){this.activeHandle=null,this.activePointerId=null,this.startPointer=void 0,this.startRect=void 0,this.startAttrs=void 0,this.lastRect=void 0,this.lastViewportRect=void 0,window.removeEventListener("pointermove",this.handlePointerMove),window.removeEventListener("pointerup",this.handlePointerUp),window.removeEventListener("pointercancel",this.handlePointerUp)}applyRect(t,n){ut(t,{x:n.x,y:n.y,width:n.width,height:n.height})}getViewportRect(t){const{x:n,y:r,width:i,height:o}=Zn(this.editor.getDocument(),t);return{x:n,y:r,width:i,height:o}}clientToElement(t,n,r){var i,o;const s=((i=t.getScreenCTM())==null?void 0:i.inverse())||((o=this.editor.getDocument().getScreenCTM())==null?void 0:o.inverse())||new DOMMatrix;return new DOMPoint(n,r).matrixTransform(s)}getCurrentAttributes(t){const n=cn(t,["x","y","width","height"],!1),r=this.getViewportRect(t),i=(o,s)=>{const a=o!==null?Number(o):NaN;return Number.isFinite(a)?a:s};return{x:i(n.x,r.x),y:i(n.y,r.y),width:i(n.width,r.width),height:i(n.height,r.height)}}getHandlePoints(t){const{x:n,y:r,width:i,height:o}=t,s=n+i/2,a=r+o/2;return[[n,r],[s,r],[n+i,r],[n+i,a],[n+i,r+o],[s,r+o],[n,r+o],[n,a]]}applyDelta(t,n,r,i){let{x:o,y:s,width:a,height:l}=t;switch(i){case"top-left":o+=n,s+=r,a-=n,l-=r;break;case"top":s+=r,l-=r;break;case"top-right":s+=r,a+=n,l-=r;break;case"right":a+=n;break;case"bottom-right":a+=n,l+=r;break;case"bottom":l+=r;break;case"bottom-left":o+=n,a-=n,l+=r;break;case"left":o+=n,a-=n;break}return{x:o,y:s,width:a,height:l}}clampRect(t,n){let{x:r,y:i,width:o,height:s}=t;if(o<On.MIN_SIZE){const a=On.MIN_SIZE-o;(n==="top-left"||n==="bottom-left"||n==="left")&&(r-=a),o=On.MIN_SIZE}if(s<On.MIN_SIZE){const a=On.MIN_SIZE-s;(n==="top-left"||n==="top-right"||n==="top")&&(i-=a),s=On.MIN_SIZE}return{x:r,y:i,width:o,height:s}}hasRectChanged(t,n){return Math.abs(t.x-n.x)>.5||Math.abs(t.y-n.y)>.5||Math.abs(t.width-n.width)>.5||Math.abs(t.height-n.height)>.5}emitSelectionGeometryChange(){this.target&&this.lastViewportRect&&this.emitter.emit("selection:geometrychange",{type:"selection:geometrychange",target:this.target,rect:this.lastViewportRect})}getHandleLine(t,n){const{x:r,y:i,width:o,height:s}=t;switch(n){case"top":return{x1:r,y1:i,x2:r+o,y2:i};case"right":return{x1:r+o,y1:i,x2:r+o,y2:i+s};case"bottom":return{x1:r,y1:i+s,x2:r+o,y2:i+s};default:return{x1:r,y1:i,x2:r,y2:i+s}}}};as.HANDLE_SIZE=10,as.LINE_STROKE_WIDTH=8,as.MIN_SIZE=1,as.HANDLE_POSITIONS=["top-left","top","top-right","right","bottom-right","bottom","bottom-left","left"];let M$=as;function I$(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function lse(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var n=function r(){var i=!1;try{i=this instanceof r}catch(o){}return i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var ic={exports:{}},A$;function cse(){if(A$)return ic.exports;A$=1;var e=String,t=function(){return{isColorSupported:!1,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e,blackBright:e,redBright:e,greenBright:e,yellowBright:e,blueBright:e,magentaBright:e,cyanBright:e,whiteBright:e,bgBlackBright:e,bgRedBright:e,bgGreenBright:e,bgYellowBright:e,bgBlueBright:e,bgMagentaBright:e,bgCyanBright:e,bgWhiteBright:e}};return ic.exports=t(),ic.exports.createColors=t,ic.exports}const Pn=lse(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var xm,T$;function Cm(){if(T$)return xm;T$=1;let e=cse(),t=Pn;class n extends Error{constructor(i,o,s,a,l,c){super(i),this.name="CssSyntaxError",this.reason=i,l&&(this.file=l),a&&(this.source=a),c&&(this.plugin=c),typeof o!="undefined"&&typeof s!="undefined"&&(typeof o=="number"?(this.line=o,this.column=s):(this.line=o.line,this.column=o.column,this.endLine=s.line,this.endColumn=s.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,n)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(i){if(!this.source)return"";let o=this.source;i==null&&(i=e.isColorSupported);let s=d=>d,a=d=>d,l=d=>d;if(i){let{bold:d,gray:p,red:g}=e.createColors(!0);a=m=>d(g(m)),s=m=>p(m),t&&(l=m=>t(m))}let c=o.split(/\r?\n/),u=Math.max(this.line-3,0),h=Math.min(this.line+2,c.length),f=String(h).length;return c.slice(u,h).map((d,p)=>{let g=u+1+p,m=" "+(" "+g).slice(-f)+" | ";if(g===this.line){if(d.length>160){let b=20,_=Math.max(0,this.column-b),x=Math.max(this.column+b,this.endColumn+b),w=d.slice(_,x),C=s(m.replace(/\d/g," "))+d.slice(0,Math.min(this.column-1,b-1)).replace(/[^\t]/g," ");return a(">")+s(m)+l(w)+`
|
|
549
|
+
`+C+a("^")}let v=s(m.replace(/\d/g," "))+d.slice(0,this.column-1).replace(/[^\t]/g," ");return a(">")+s(m)+l(d)+`
|
|
550
|
+
`+v+a("^")}return" "+s(m)+l(d)}).join(`
|
|
551
|
+
`)}toString(){let i=this.showSourceCode();return i&&(i=`
|
|
552
|
+
|
|
553
|
+
`+i+`
|
|
554
|
+
`),this.name+": "+this.message+i}}return xm=n,n.default=n,xm}var Pm,R$;function k$(){if(R$)return Pm;R$=1;const e={after:`
|
|
555
|
+
`,beforeClose:`
|
|
556
|
+
`,beforeComment:`
|
|
557
|
+
`,beforeDecl:`
|
|
558
|
+
`,beforeOpen:" ",beforeRule:`
|
|
559
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function t(r){return r[0].toUpperCase()+r.slice(1)}class n{constructor(i){this.builder=i}atrule(i,o){let s="@"+i.name,a=i.params?this.rawValue(i,"params"):"";if(typeof i.raws.afterName!="undefined"?s+=i.raws.afterName:a&&(s+=" "),i.nodes)this.block(i,s+a);else{let l=(i.raws.between||"")+(o?";":"");this.builder(s+a+l,i)}}beforeAfter(i,o){let s;i.type==="decl"?s=this.raw(i,null,"beforeDecl"):i.type==="comment"?s=this.raw(i,null,"beforeComment"):o==="before"?s=this.raw(i,null,"beforeRule"):s=this.raw(i,null,"beforeClose");let a=i.parent,l=0;for(;a&&a.type!=="root";)l+=1,a=a.parent;if(s.includes(`
|
|
560
|
+
`)){let c=this.raw(i,null,"indent");if(c.length)for(let u=0;u<l;u++)s+=c}return s}block(i,o){let s=this.raw(i,"between","beforeOpen");this.builder(o+s+"{",i,"start");let a;i.nodes&&i.nodes.length?(this.body(i),a=this.raw(i,"after")):a=this.raw(i,"after","emptyBody"),a&&this.builder(a),this.builder("}",i,"end")}body(i){let o=i.nodes.length-1;for(;o>0&&i.nodes[o].type==="comment";)o-=1;let s=this.raw(i,"semicolon");for(let a=0;a<i.nodes.length;a++){let l=i.nodes[a],c=this.raw(l,"before");c&&this.builder(c),this.stringify(l,o!==a||s)}}comment(i){let o=this.raw(i,"left","commentLeft"),s=this.raw(i,"right","commentRight");this.builder("/*"+o+i.text+s+"*/",i)}decl(i,o){let s=this.raw(i,"between","colon"),a=i.prop+s+this.rawValue(i,"value");i.important&&(a+=i.raws.important||" !important"),o&&(a+=";"),this.builder(a,i)}document(i){this.body(i)}raw(i,o,s){let a;if(s||(s=o),o&&(a=i.raws[o],typeof a!="undefined"))return a;let l=i.parent;if(s==="before"&&(!l||l.type==="root"&&l.first===i||l&&l.type==="document"))return"";if(!l)return e[s];let c=i.root();if(c.rawCache||(c.rawCache={}),typeof c.rawCache[s]!="undefined")return c.rawCache[s];if(s==="before"||s==="after")return this.beforeAfter(i,s);{let u="raw"+t(s);this[u]?a=this[u](c,i):c.walk(h=>{if(a=h.raws[o],typeof a!="undefined")return!1})}return typeof a=="undefined"&&(a=e[s]),c.rawCache[s]=a,a}rawBeforeClose(i){let o;return i.walk(s=>{if(s.nodes&&s.nodes.length>0&&typeof s.raws.after!="undefined")return o=s.raws.after,o.includes(`
|
|
561
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),o&&(o=o.replace(/\S/g,"")),o}rawBeforeComment(i,o){let s;return i.walkComments(a=>{if(typeof a.raws.before!="undefined")return s=a.raws.before,s.includes(`
|
|
562
|
+
`)&&(s=s.replace(/[^\n]+$/,"")),!1}),typeof s=="undefined"?s=this.raw(o,null,"beforeDecl"):s&&(s=s.replace(/\S/g,"")),s}rawBeforeDecl(i,o){let s;return i.walkDecls(a=>{if(typeof a.raws.before!="undefined")return s=a.raws.before,s.includes(`
|
|
563
|
+
`)&&(s=s.replace(/[^\n]+$/,"")),!1}),typeof s=="undefined"?s=this.raw(o,null,"beforeRule"):s&&(s=s.replace(/\S/g,"")),s}rawBeforeOpen(i){let o;return i.walk(s=>{if(s.type!=="decl"&&(o=s.raws.between,typeof o!="undefined"))return!1}),o}rawBeforeRule(i){let o;return i.walk(s=>{if(s.nodes&&(s.parent!==i||i.first!==s)&&typeof s.raws.before!="undefined")return o=s.raws.before,o.includes(`
|
|
564
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),o&&(o=o.replace(/\S/g,"")),o}rawColon(i){let o;return i.walkDecls(s=>{if(typeof s.raws.between!="undefined")return o=s.raws.between.replace(/[^\s:]/g,""),!1}),o}rawEmptyBody(i){let o;return i.walk(s=>{if(s.nodes&&s.nodes.length===0&&(o=s.raws.after,typeof o!="undefined"))return!1}),o}rawIndent(i){if(i.raws.indent)return i.raws.indent;let o;return i.walk(s=>{let a=s.parent;if(a&&a!==i&&a.parent&&a.parent===i&&typeof s.raws.before!="undefined"){let l=s.raws.before.split(`
|
|
565
|
+
`);return o=l[l.length-1],o=o.replace(/\S/g,""),!1}}),o}rawSemicolon(i){let o;return i.walk(s=>{if(s.nodes&&s.nodes.length&&s.last.type==="decl"&&(o=s.raws.semicolon,typeof o!="undefined"))return!1}),o}rawValue(i,o){let s=i[o],a=i.raws[o];return a&&a.value===s?a.raw:s}root(i){this.body(i),i.raws.after&&this.builder(i.raws.after)}rule(i){this.block(i,this.rawValue(i,"selector")),i.raws.ownSemicolon&&this.builder(i.raws.ownSemicolon,i,"end")}stringify(i,o){if(!this[i.type])throw new Error("Unknown AST node type "+i.type+". Maybe you need to change PostCSS stringifier.");this[i.type](i,o)}}return Pm=n,n.default=n,Pm}var Om,L$;function oc(){if(L$)return Om;L$=1;let e=k$();function t(n,r){new e(r).stringify(n)}return Om=t,t.default=t,Om}var sc={},N$;function Sm(){return N$||(N$=1,sc.isClean=Symbol("isClean"),sc.my=Symbol("my")),sc}var $m,z$;function ac(){if(z$)return $m;z$=1;let e=Cm(),t=k$(),n=oc(),{isClean:r,my:i}=Sm();function o(l,c){let u=new l.constructor;for(let h in l){if(!Object.prototype.hasOwnProperty.call(l,h)||h==="proxyCache")continue;let f=l[h],d=typeof f;h==="parent"&&d==="object"?c&&(u[h]=c):h==="source"?u[h]=f:Array.isArray(f)?u[h]=f.map(p=>o(p,u)):(d==="object"&&f!==null&&(f=o(f)),u[h]=f)}return u}function s(l,c){if(c&&typeof c.offset!="undefined")return c.offset;let u=1,h=1,f=0;for(let d=0;d<l.length;d++){if(h===c.line&&u===c.column){f=d;break}l[d]===`
|
|
566
|
+
`?(u=1,h+=1):u+=1}return f}class a{get proxyOf(){return this}constructor(c={}){this.raws={},this[r]=!1,this[i]=!0;for(let u in c)if(u==="nodes"){this.nodes=[];for(let h of c[u])typeof h.clone=="function"?this.append(h.clone()):this.append(h)}else this[u]=c[u]}addToError(c){if(c.postcssNode=this,c.stack&&this.source&&/\n\s{4}at /.test(c.stack)){let u=this.source;c.stack=c.stack.replace(/\n\s{4}at /,`$&${u.input.from}:${u.start.line}:${u.start.column}$&`)}return c}after(c){return this.parent.insertAfter(this,c),this}assign(c={}){for(let u in c)this[u]=c[u];return this}before(c){return this.parent.insertBefore(this,c),this}cleanRaws(c){delete this.raws.before,delete this.raws.after,c||delete this.raws.between}clone(c={}){let u=o(this);for(let h in c)u[h]=c[h];return u}cloneAfter(c={}){let u=this.clone(c);return this.parent.insertAfter(this,u),u}cloneBefore(c={}){let u=this.clone(c);return this.parent.insertBefore(this,u),u}error(c,u={}){if(this.source){let{end:h,start:f}=this.rangeBy(u);return this.source.input.error(c,{column:f.column,line:f.line},{column:h.column,line:h.line},u)}return new e(c)}getProxyProcessor(){return{get(c,u){return u==="proxyOf"?c:u==="root"?()=>c.root().toProxy():c[u]},set(c,u,h){return c[u]===h||(c[u]=h,(u==="prop"||u==="value"||u==="name"||u==="params"||u==="important"||u==="text")&&c.markDirty()),!0}}}markClean(){this[r]=!0}markDirty(){if(this[r]){this[r]=!1;let c=this;for(;c=c.parent;)c[r]=!1}}next(){if(!this.parent)return;let c=this.parent.index(this);return this.parent.nodes[c+1]}positionBy(c={}){let u=this.source.start;if(c.index)u=this.positionInside(c.index);else if(c.word){let h="document"in this.source.input?this.source.input.document:this.source.input.css,d=h.slice(s(h,this.source.start),s(h,this.source.end)).indexOf(c.word);d!==-1&&(u=this.positionInside(d))}return u}positionInside(c){let u=this.source.start.column,h=this.source.start.line,f="document"in this.source.input?this.source.input.document:this.source.input.css,d=s(f,this.source.start),p=d+c;for(let g=d;g<p;g++)f[g]===`
|
|
567
|
+
`?(u=1,h+=1):u+=1;return{column:u,line:h,offset:p}}prev(){if(!this.parent)return;let c=this.parent.index(this);return this.parent.nodes[c-1]}rangeBy(c={}){let u="document"in this.source.input?this.source.input.document:this.source.input.css,h={column:this.source.start.column,line:this.source.start.line,offset:s(u,this.source.start)},f=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:s(u,this.source.end)+1}:{column:h.column+1,line:h.line,offset:h.offset+1};if(c.word){let p=u.slice(s(u,this.source.start),s(u,this.source.end)).indexOf(c.word);p!==-1&&(h=this.positionInside(p),f=this.positionInside(p+c.word.length))}else c.start?h={column:c.start.column,line:c.start.line,offset:s(u,c.start)}:c.index&&(h=this.positionInside(c.index)),c.end?f={column:c.end.column,line:c.end.line,offset:s(u,c.end)}:typeof c.endIndex=="number"?f=this.positionInside(c.endIndex):c.index&&(f=this.positionInside(c.index+1));return(f.line<h.line||f.line===h.line&&f.column<=h.column)&&(f={column:h.column+1,line:h.line,offset:h.offset+1}),{end:f,start:h}}raw(c,u){return new t().raw(this,c,u)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...c){if(this.parent){let u=this,h=!1;for(let f of c)f===this?h=!0:h?(this.parent.insertAfter(u,f),u=f):this.parent.insertBefore(u,f);h||this.remove()}return this}root(){let c=this;for(;c.parent&&c.parent.type!=="document";)c=c.parent;return c}toJSON(c,u){let h={},f=u==null;u=u||new Map;let d=0;for(let p in this){if(!Object.prototype.hasOwnProperty.call(this,p)||p==="parent"||p==="proxyCache")continue;let g=this[p];if(Array.isArray(g))h[p]=g.map(m=>typeof m=="object"&&m.toJSON?m.toJSON(null,u):m);else if(typeof g=="object"&&g.toJSON)h[p]=g.toJSON(null,u);else if(p==="source"){if(g==null)continue;let m=u.get(g.input);m==null&&(m=d,u.set(g.input,d),d++),h[p]={end:g.end,inputId:m,start:g.start}}else h[p]=g}return f&&(h.inputs=[...u.keys()].map(p=>p.toJSON())),h}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(c=n){c.stringify&&(c=c.stringify);let u="";return c(this,h=>{u+=h}),u}warn(c,u,h={}){let f={node:this};for(let d in h)f[d]=h[d];return c.warn(u,f)}}return $m=a,a.default=a,$m}var Em,D$;function lc(){if(D$)return Em;D$=1;let e=ac();class t extends e{constructor(r){super(r),this.type="comment"}}return Em=t,t.default=t,Em}var Mm,q$;function cc(){if(q$)return Mm;q$=1;let e=ac();class t extends e{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(r){r&&typeof r.value!="undefined"&&typeof r.value!="string"&&(r=zt(ht({},r),{value:String(r.value)})),super(r),this.type="decl"}}return Mm=t,t.default=t,Mm}var Im,H$;function ti(){if(H$)return Im;H$=1;let e=lc(),t=cc(),n=ac(),{isClean:r,my:i}=Sm(),o,s,a,l;function c(f){return f.map(d=>(d.nodes&&(d.nodes=c(d.nodes)),delete d.source,d))}function u(f){if(f[r]=!1,f.proxyOf.nodes)for(let d of f.proxyOf.nodes)u(d)}class h extends n{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...d){for(let p of d){let g=this.normalize(p,this.last);for(let m of g)this.proxyOf.nodes.push(m)}return this.markDirty(),this}cleanRaws(d){if(super.cleanRaws(d),this.nodes)for(let p of this.nodes)p.cleanRaws(d)}each(d){if(!this.proxyOf.nodes)return;let p=this.getIterator(),g,m;for(;this.indexes[p]<this.proxyOf.nodes.length&&(g=this.indexes[p],m=d(this.proxyOf.nodes[g],g),m!==!1);)this.indexes[p]+=1;return delete this.indexes[p],m}every(d){return this.nodes.every(d)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let d=this.lastEach;return this.indexes[d]=0,d}getProxyProcessor(){return{get(d,p){return p==="proxyOf"?d:d[p]?p==="each"||typeof p=="string"&&p.startsWith("walk")?(...g)=>d[p](...g.map(m=>typeof m=="function"?(v,b)=>m(v.toProxy(),b):m)):p==="every"||p==="some"?g=>d[p]((m,...v)=>g(m.toProxy(),...v)):p==="root"?()=>d.root().toProxy():p==="nodes"?d.nodes.map(g=>g.toProxy()):p==="first"||p==="last"?d[p].toProxy():d[p]:d[p]},set(d,p,g){return d[p]===g||(d[p]=g,(p==="name"||p==="params"||p==="selector")&&d.markDirty()),!0}}}index(d){return typeof d=="number"?d:(d.proxyOf&&(d=d.proxyOf),this.proxyOf.nodes.indexOf(d))}insertAfter(d,p){let g=this.index(d),m=this.normalize(p,this.proxyOf.nodes[g]).reverse();g=this.index(d);for(let b of m)this.proxyOf.nodes.splice(g+1,0,b);let v;for(let b in this.indexes)v=this.indexes[b],g<v&&(this.indexes[b]=v+m.length);return this.markDirty(),this}insertBefore(d,p){let g=this.index(d),m=g===0?"prepend":!1,v=this.normalize(p,this.proxyOf.nodes[g],m).reverse();g=this.index(d);for(let _ of v)this.proxyOf.nodes.splice(g,0,_);let b;for(let _ in this.indexes)b=this.indexes[_],g<=b&&(this.indexes[_]=b+v.length);return this.markDirty(),this}normalize(d,p){if(typeof d=="string")d=c(s(d).nodes);else if(typeof d=="undefined")d=[];else if(Array.isArray(d)){d=d.slice(0);for(let m of d)m.parent&&m.parent.removeChild(m,"ignore")}else if(d.type==="root"&&this.type!=="document"){d=d.nodes.slice(0);for(let m of d)m.parent&&m.parent.removeChild(m,"ignore")}else if(d.type)d=[d];else if(d.prop){if(typeof d.value=="undefined")throw new Error("Value field is missed in node creation");typeof d.value!="string"&&(d.value=String(d.value)),d=[new t(d)]}else if(d.selector||d.selectors)d=[new l(d)];else if(d.name)d=[new o(d)];else if(d.text)d=[new e(d)];else throw new Error("Unknown node type in node creation");return d.map(m=>(m[i]||h.rebuild(m),m=m.proxyOf,m.parent&&m.parent.removeChild(m),m[r]&&u(m),m.raws||(m.raws={}),typeof m.raws.before=="undefined"&&p&&typeof p.raws.before!="undefined"&&(m.raws.before=p.raws.before.replace(/\S/g,"")),m.parent=this.proxyOf,m))}prepend(...d){d=d.reverse();for(let p of d){let g=this.normalize(p,this.first,"prepend").reverse();for(let m of g)this.proxyOf.nodes.unshift(m);for(let m in this.indexes)this.indexes[m]=this.indexes[m]+g.length}return this.markDirty(),this}push(d){return d.parent=this,this.proxyOf.nodes.push(d),this}removeAll(){for(let d of this.proxyOf.nodes)d.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(d){d=this.index(d),this.proxyOf.nodes[d].parent=void 0,this.proxyOf.nodes.splice(d,1);let p;for(let g in this.indexes)p=this.indexes[g],p>=d&&(this.indexes[g]=p-1);return this.markDirty(),this}replaceValues(d,p,g){return g||(g=p,p={}),this.walkDecls(m=>{p.props&&!p.props.includes(m.prop)||p.fast&&!m.value.includes(p.fast)||(m.value=m.value.replace(d,g))}),this.markDirty(),this}some(d){return this.nodes.some(d)}walk(d){return this.each((p,g)=>{let m;try{m=d(p,g)}catch(v){throw p.addToError(v)}return m!==!1&&p.walk&&(m=p.walk(d)),m})}walkAtRules(d,p){return p?d instanceof RegExp?this.walk((g,m)=>{if(g.type==="atrule"&&d.test(g.name))return p(g,m)}):this.walk((g,m)=>{if(g.type==="atrule"&&g.name===d)return p(g,m)}):(p=d,this.walk((g,m)=>{if(g.type==="atrule")return p(g,m)}))}walkComments(d){return this.walk((p,g)=>{if(p.type==="comment")return d(p,g)})}walkDecls(d,p){return p?d instanceof RegExp?this.walk((g,m)=>{if(g.type==="decl"&&d.test(g.prop))return p(g,m)}):this.walk((g,m)=>{if(g.type==="decl"&&g.prop===d)return p(g,m)}):(p=d,this.walk((g,m)=>{if(g.type==="decl")return p(g,m)}))}walkRules(d,p){return p?d instanceof RegExp?this.walk((g,m)=>{if(g.type==="rule"&&d.test(g.selector))return p(g,m)}):this.walk((g,m)=>{if(g.type==="rule"&&g.selector===d)return p(g,m)}):(p=d,this.walk((g,m)=>{if(g.type==="rule")return p(g,m)}))}}return h.registerParse=f=>{s=f},h.registerRule=f=>{l=f},h.registerAtRule=f=>{o=f},h.registerRoot=f=>{a=f},Im=h,h.default=h,h.rebuild=f=>{f.type==="atrule"?Object.setPrototypeOf(f,o.prototype):f.type==="rule"?Object.setPrototypeOf(f,l.prototype):f.type==="decl"?Object.setPrototypeOf(f,t.prototype):f.type==="comment"?Object.setPrototypeOf(f,e.prototype):f.type==="root"&&Object.setPrototypeOf(f,a.prototype),f[i]=!0,f.nodes&&f.nodes.forEach(d=>{h.rebuild(d)})},Im}var Am,j$;function Tm(){if(j$)return Am;j$=1;let e=ti();class t extends e{constructor(r){super(r),this.type="atrule"}append(...r){return this.proxyOf.nodes||(this.nodes=[]),super.append(...r)}prepend(...r){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...r)}}return Am=t,t.default=t,e.registerAtRule(t),Am}var Rm,F$;function km(){if(F$)return Rm;F$=1;let e=ti(),t,n;class r extends e{constructor(o){super(ht({type:"document"},o)),this.nodes||(this.nodes=[])}toResult(o={}){return new t(new n,this,o).stringify()}}return r.registerLazyResult=i=>{t=i},r.registerProcessor=i=>{n=i},Rm=r,r.default=r,Rm}var Lm,B$;function use(){if(B$)return Lm;B$=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return Lm={nanoid:(r=21)=>{let i="",o=r|0;for(;o--;)i+=e[Math.random()*64|0];return i},customAlphabet:(r,i=21)=>(o=i)=>{let s="",a=o|0;for(;a--;)s+=r[Math.random()*r.length|0];return s}},Lm}var Nm,W$;function V$(){if(W$)return Nm;W$=1;let{existsSync:e,readFileSync:t}=Pn,{dirname:n,join:r}=Pn,{SourceMapConsumer:i,SourceMapGenerator:o}=Pn;function s(l){return Buffer?Buffer.from(l,"base64").toString():window.atob(l)}class a{constructor(c,u){if(u.map===!1)return;this.loadAnnotation(c),this.inline=this.startWith(this.annotation,"data:");let h=u.map?u.map.prev:void 0,f=this.loadMap(u.from,h);!this.mapFile&&u.from&&(this.mapFile=u.from),this.mapFile&&(this.root=n(this.mapFile)),f&&(this.text=f)}consumer(){return this.consumerCache||(this.consumerCache=new i(this.text)),this.consumerCache}decodeInline(c){let u=/^data:application\/json;charset=utf-?8;base64,/,h=/^data:application\/json;base64,/,f=/^data:application\/json;charset=utf-?8,/,d=/^data:application\/json,/,p=c.match(f)||c.match(d);if(p)return decodeURIComponent(c.substr(p[0].length));let g=c.match(u)||c.match(h);if(g)return s(c.substr(g[0].length));let m=c.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(c){return c.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(c){return typeof c!="object"?!1:typeof c.mappings=="string"||typeof c._mappings=="string"||Array.isArray(c.sections)}loadAnnotation(c){let u=c.match(/\/\*\s*# sourceMappingURL=/g);if(!u)return;let h=c.lastIndexOf(u.pop()),f=c.indexOf("*/",h);h>-1&&f>-1&&(this.annotation=this.getAnnotationURL(c.substring(h,f)))}loadFile(c){if(this.root=n(c),e(c))return this.mapFile=c,t(c,"utf-8").toString().trim()}loadMap(c,u){if(u===!1)return!1;if(u){if(typeof u=="string")return u;if(typeof u=="function"){let h=u(c);if(h){let f=this.loadFile(h);if(!f)throw new Error("Unable to load previous source map: "+h.toString());return f}}else{if(u instanceof i)return o.fromSourceMap(u).toString();if(u instanceof o)return u.toString();if(this.isMap(u))return JSON.stringify(u);throw new Error("Unsupported previous source map format: "+u.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let h=this.annotation;return c&&(h=r(n(c),h)),this.loadFile(h)}}}startWith(c,u){return c?c.substr(0,u.length)===u:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Nm=a,a.default=a,Nm}var zm,G$;function uc(){if(G$)return zm;G$=1;let{nanoid:e}=use(),{isAbsolute:t,resolve:n}=Pn,{SourceMapConsumer:r,SourceMapGenerator:i}=Pn,{fileURLToPath:o,pathToFileURL:s}=Pn,a=Cm(),l=V$(),c=Pn,u=Symbol("lineToIndexCache"),h=!!(r&&i),f=!!(n&&t);function d(g){if(g[u])return g[u];let m=g.css.split(`
|
|
568
|
+
`),v=new Array(m.length),b=0;for(let _=0,x=m.length;_<x;_++)v[_]=b,b+=m[_].length+1;return g[u]=v,v}class p{get from(){return this.file||this.id}constructor(m,v={}){if(m===null||typeof m=="undefined"||typeof m=="object"&&!m.toString)throw new Error(`PostCSS received ${m} instead of CSS string`);if(this.css=m.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,v.document&&(this.document=v.document.toString()),v.from&&(!f||/^\w+:\/\//.test(v.from)||t(v.from)?this.file=v.from:this.file=n(v.from)),f&&h){let b=new l(this.css,v);if(b.text){this.map=b;let _=b.consumer().file;!this.file&&_&&(this.file=this.mapResolve(_))}}this.file||(this.id="<input css "+e(6)+">"),this.map&&(this.map.file=this.from)}error(m,v,b,_={}){let x,w,C,P,O;if(v&&typeof v=="object"){let S=v,M=b;if(typeof S.offset=="number"){P=S.offset;let I=this.fromOffset(P);v=I.line,b=I.col}else v=S.line,b=S.column,P=this.fromLineAndColumn(v,b);if(typeof M.offset=="number"){C=M.offset;let I=this.fromOffset(C);w=I.line,x=I.col}else w=M.line,x=M.column,C=this.fromLineAndColumn(M.line,M.column)}else if(b)P=this.fromLineAndColumn(v,b);else{P=v;let S=this.fromOffset(P);v=S.line,b=S.col}let $=this.origin(v,b,w,x);return $?O=new a(m,$.endLine===void 0?$.line:{column:$.column,line:$.line},$.endLine===void 0?$.column:{column:$.endColumn,line:$.endLine},$.source,$.file,_.plugin):O=new a(m,w===void 0?v:{column:b,line:v},w===void 0?b:{column:x,line:w},this.css,this.file,_.plugin),O.input={column:b,endColumn:x,endLine:w,endOffset:C,line:v,offset:P,source:this.css},this.file&&(s&&(O.input.url=s(this.file).toString()),O.input.file=this.file),O}fromLineAndColumn(m,v){return d(this)[m-1]+v-1}fromOffset(m){let v=d(this),b=v[v.length-1],_=0;if(m>=b)_=v.length-1;else{let x=v.length-2,w;for(;_<x;)if(w=_+(x-_>>1),m<v[w])x=w-1;else if(m>=v[w+1])_=w+1;else{_=w;break}}return{col:m-v[_]+1,line:_+1}}mapResolve(m){return/^\w+:\/\//.test(m)?m:n(this.map.consumer().sourceRoot||this.map.root||".",m)}origin(m,v,b,_){if(!this.map)return!1;let x=this.map.consumer(),w=x.originalPositionFor({column:v,line:m});if(!w.source)return!1;let C;typeof b=="number"&&(C=x.originalPositionFor({column:_,line:b}));let P;t(w.source)?P=s(w.source):P=new URL(w.source,this.map.consumer().sourceRoot||s(this.map.mapFile));let O={column:w.column,endColumn:C&&C.column,endLine:C&&C.line,line:w.line,url:P.toString()};if(P.protocol==="file:")if(o)O.file=o(P);else throw new Error("file: protocol is not available in this PostCSS build");let $=x.sourceContentFor(w.source);return $&&(O.source=$),O}toJSON(){let m={};for(let v of["hasBOM","css","file","id"])this[v]!=null&&(m[v]=this[v]);return this.map&&(m.map=ht({},this.map),m.map.consumerCache&&(m.map.consumerCache=void 0)),m}}return zm=p,p.default=p,c&&c.registerInput&&c.registerInput(p),zm}var Dm,Y$;function ls(){if(Y$)return Dm;Y$=1;let e=ti(),t,n;class r extends e{constructor(o){super(o),this.type="root",this.nodes||(this.nodes=[])}normalize(o,s,a){let l=super.normalize(o);if(s){if(a==="prepend")this.nodes.length>1?s.raws.before=this.nodes[1].raws.before:delete s.raws.before;else if(this.first!==s)for(let c of l)c.raws.before=s.raws.before}return l}removeChild(o,s){let a=this.index(o);return!s&&a===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[a].raws.before),super.removeChild(o)}toResult(o={}){return new t(new n,this,o).stringify()}}return r.registerLazyResult=i=>{t=i},r.registerProcessor=i=>{n=i},Dm=r,r.default=r,e.registerRoot(r),Dm}var qm,X$;function U$(){if(X$)return qm;X$=1;let e={comma(t){return e.split(t,[","],!0)},space(t){let n=[" ",`
|
|
569
|
+
`," "];return e.split(t,n)},split(t,n,r){let i=[],o="",s=!1,a=0,l=!1,c="",u=!1;for(let h of t)u?u=!1:h==="\\"?u=!0:l?h===c&&(l=!1):h==='"'||h==="'"?(l=!0,c=h):h==="("?a+=1:h===")"?a>0&&(a-=1):a===0&&n.includes(h)&&(s=!0),s?(o!==""&&i.push(o.trim()),o="",s=!1):o+=h;return(r||o!=="")&&i.push(o.trim()),i}};return qm=e,e.default=e,qm}var Hm,K$;function jm(){if(K$)return Hm;K$=1;let e=ti(),t=U$();class n extends e{get selectors(){return t.comma(this.selector)}set selectors(i){let o=this.selector?this.selector.match(/,\s*/):null,s=o?o[0]:","+this.raw("between","beforeOpen");this.selector=i.join(s)}constructor(i){super(i),this.type="rule",this.nodes||(this.nodes=[])}}return Hm=n,n.default=n,e.registerRule(n),Hm}var Fm,Z$;function hse(){if(Z$)return Fm;Z$=1;let e=Tm(),t=lc(),n=cc(),r=uc(),i=V$(),o=ls(),s=jm();function a(l,c){if(Array.isArray(l))return l.map(p=>a(p));let f=l,{inputs:u}=f,h=fy(f,["inputs"]);if(u){c=[];for(let p of u){let g=zt(ht({},p),{__proto__:r.prototype});g.map&&(g.map=zt(ht({},g.map),{__proto__:i.prototype})),c.push(g)}}if(h.nodes&&(h.nodes=l.nodes.map(p=>a(p,c))),h.source){let d=h.source,{inputId:p}=d,g=fy(d,["inputId"]);h.source=g,p!=null&&(h.source.input=c[p])}if(h.type==="root")return new o(h);if(h.type==="decl")return new n(h);if(h.type==="rule")return new s(h);if(h.type==="comment")return new t(h);if(h.type==="atrule")return new e(h);throw new Error("Unknown node type: "+l.type)}return Fm=a,a.default=a,Fm}var Bm,Q$;function J$(){if(Q$)return Bm;Q$=1;let{dirname:e,relative:t,resolve:n,sep:r}=Pn,{SourceMapConsumer:i,SourceMapGenerator:o}=Pn,{pathToFileURL:s}=Pn,a=uc(),l=!!(i&&o),c=!!(e&&n&&t&&r);class u{constructor(f,d,p,g){this.stringify=f,this.mapOpts=p.map||{},this.root=d,this.opts=p,this.css=g,this.originalCSS=g,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let f;this.isInline()?f="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?f=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?f=this.mapOpts.annotation(this.opts.to,this.root):f=this.outputFile()+".map";let d=`
|
|
570
|
+
`;this.css.includes(`\r
|
|
571
|
+
`)&&(d=`\r
|
|
572
|
+
`),this.css+=d+"/*# sourceMappingURL="+f+" */"}applyPrevMaps(){for(let f of this.previous()){let d=this.toUrl(this.path(f.file)),p=f.root||e(f.file),g;this.mapOpts.sourcesContent===!1?(g=new i(f.text),g.sourcesContent&&(g.sourcesContent=null)):g=f.consumer(),this.map.applySourceMap(g,d,this.toUrl(this.path(p)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let f;for(let d=this.root.nodes.length-1;d>=0;d--)f=this.root.nodes[d],f.type==="comment"&&f.text.startsWith("# sourceMappingURL=")&&this.root.removeChild(d)}else this.css&&(this.css=this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),c&&l&&this.isMap())return this.generateMap();{let f="";return this.stringify(this.root,d=>{f+=d}),[f]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let f=this.previous()[0].consumer();f.file=this.outputFile(),this.map=o.fromSourceMap(f,{ignoreInvalidMapping:!0})}else this.map=new o({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new o({file:this.outputFile(),ignoreInvalidMapping:!0});let f=1,d=1,p="<no source>",g={generated:{column:0,line:0},original:{column:0,line:0},source:""},m,v;this.stringify(this.root,(b,_,x)=>{if(this.css+=b,_&&x!=="end"&&(g.generated.line=f,g.generated.column=d-1,_.source&&_.source.start?(g.source=this.sourcePath(_),g.original.line=_.source.start.line,g.original.column=_.source.start.column-1,this.map.addMapping(g)):(g.source=p,g.original.line=1,g.original.column=0,this.map.addMapping(g))),v=b.match(/\n/g),v?(f+=v.length,m=b.lastIndexOf(`
|
|
573
|
+
`),d=b.length-m):d+=b.length,_&&x!=="start"){let w=_.parent||{raws:{}};(!(_.type==="decl"||_.type==="atrule"&&!_.nodes)||_!==w.last||w.raws.semicolon)&&(_.source&&_.source.end?(g.source=this.sourcePath(_),g.original.line=_.source.end.line,g.original.column=_.source.end.column-1,g.generated.line=f,g.generated.column=d-2,this.map.addMapping(g)):(g.source=p,g.original.line=1,g.original.column=0,g.generated.line=f,g.generated.column=d-1,this.map.addMapping(g)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(f=>f.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let f=this.mapOpts.annotation;return typeof f!="undefined"&&f!==!0?!1:this.previous().length?this.previous().some(d=>d.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(f=>f.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(f){if(this.mapOpts.absolute||f.charCodeAt(0)===60||/^\w+:\/\//.test(f))return f;let d=this.memoizedPaths.get(f);if(d)return d;let p=this.opts.to?e(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=e(n(p,this.mapOpts.annotation)));let g=t(p,f);return this.memoizedPaths.set(f,g),g}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(f=>{if(f.source&&f.source.input.map){let d=f.source.input.map;this.previousMaps.includes(d)||this.previousMaps.push(d)}});else{let f=new a(this.originalCSS,this.opts);f.map&&this.previousMaps.push(f.map)}return this.previousMaps}setSourcesContent(){let f={};if(this.root)this.root.walk(d=>{if(d.source){let p=d.source.input.from;if(p&&!f[p]){f[p]=!0;let g=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(g,d.source.input.css)}}});else if(this.css){let d=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(d,this.css)}}sourcePath(f){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(f.source.input.from):this.toUrl(this.path(f.source.input.from))}toBase64(f){return Buffer?Buffer.from(f).toString("base64"):window.btoa(unescape(encodeURIComponent(f)))}toFileUrl(f){let d=this.memoizedFileURLs.get(f);if(d)return d;if(s){let p=s(f).toString();return this.memoizedFileURLs.set(f,p),p}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(f){let d=this.memoizedURLs.get(f);if(d)return d;r==="\\"&&(f=f.replace(/\\/g,"/"));let p=encodeURI(f).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(f,p),p}}return Bm=u,Bm}var Wm,eE;function fse(){if(eE)return Wm;eE=1;const e=39,t=34,n=92,r=47,i=10,o=32,s=12,a=9,l=13,c=91,u=93,h=40,f=41,d=123,p=125,g=59,m=42,v=58,b=64,_=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,C=/[\da-f]/i;return Wm=function(O,$={}){let S=O.css.valueOf(),M=$.ignoreErrors,I,E,A,T,N,H,D,B,F,X,G=S.length,L=0,R=[],z=[];function q(){return L}function j(ne){throw O.error("Unclosed "+ne,L)}function V(){return z.length===0&&L>=G}function U(ne){if(z.length)return z.pop();if(L>=G)return;let J=ne?ne.ignoreUnclosed:!1;switch(I=S.charCodeAt(L),I){case i:case o:case a:case l:case s:{T=L;do T+=1,I=S.charCodeAt(T);while(I===o||I===i||I===a||I===l||I===s);H=["space",S.slice(L,T)],L=T-1;break}case c:case u:case d:case p:case v:case g:case f:{let se=String.fromCharCode(I);H=[se,se,L];break}case h:{if(X=R.length?R.pop()[1]:"",F=S.charCodeAt(L+1),X==="url"&&F!==e&&F!==t&&F!==o&&F!==i&&F!==a&&F!==s&&F!==l){T=L;do{if(D=!1,T=S.indexOf(")",T+1),T===-1)if(M||J){T=L;break}else j("bracket");for(B=T;S.charCodeAt(B-1)===n;)B-=1,D=!D}while(D);H=["brackets",S.slice(L,T+1),L,T],L=T}else T=S.indexOf(")",L+1),E=S.slice(L,T+1),T===-1||w.test(E)?H=["(","(",L]:(H=["brackets",E,L,T],L=T);break}case e:case t:{N=I===e?"'":'"',T=L;do{if(D=!1,T=S.indexOf(N,T+1),T===-1)if(M||J){T=L+1;break}else j("string");for(B=T;S.charCodeAt(B-1)===n;)B-=1,D=!D}while(D);H=["string",S.slice(L,T+1),L,T],L=T;break}case b:{_.lastIndex=L+1,_.test(S),_.lastIndex===0?T=S.length-1:T=_.lastIndex-2,H=["at-word",S.slice(L,T+1),L,T],L=T;break}case n:{for(T=L,A=!0;S.charCodeAt(T+1)===n;)T+=1,A=!A;if(I=S.charCodeAt(T+1),A&&I!==r&&I!==o&&I!==i&&I!==a&&I!==l&&I!==s&&(T+=1,C.test(S.charAt(T)))){for(;C.test(S.charAt(T+1));)T+=1;S.charCodeAt(T+1)===o&&(T+=1)}H=["word",S.slice(L,T+1),L,T],L=T;break}default:{I===r&&S.charCodeAt(L+1)===m?(T=S.indexOf("*/",L+2)+1,T===0&&(M||J?T=S.length:j("comment")),H=["comment",S.slice(L,T+1),L,T],L=T):(x.lastIndex=L+1,x.test(S),x.lastIndex===0?T=S.length-1:T=x.lastIndex-2,H=["word",S.slice(L,T+1),L,T],R.push(H),L=T);break}}return L++,H}function K(ne){z.push(ne)}return{back:K,endOfFile:V,nextToken:U,position:q}},Wm}var Vm,tE;function dse(){if(tE)return Vm;tE=1;let e=Tm(),t=lc(),n=cc(),r=ls(),i=jm(),o=fse();const s={empty:!0,space:!0};function a(c){for(let u=c.length-1;u>=0;u--){let h=c[u],f=h[3]||h[2];if(f)return f}}class l{constructor(u){this.input=u,this.root=new r,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:u,start:{column:1,line:1,offset:0}}}atrule(u){let h=new e;h.name=u[1].slice(1),h.name===""&&this.unnamedAtrule(h,u),this.init(h,u[2]);let f,d,p,g=!1,m=!1,v=[],b=[];for(;!this.tokenizer.endOfFile();){if(u=this.tokenizer.nextToken(),f=u[0],f==="("||f==="["?b.push(f==="("?")":"]"):f==="{"&&b.length>0?b.push("}"):f===b[b.length-1]&&b.pop(),b.length===0)if(f===";"){h.source.end=this.getPosition(u[2]),h.source.end.offset++,this.semicolon=!0;break}else if(f==="{"){m=!0;break}else if(f==="}"){if(v.length>0){for(p=v.length-1,d=v[p];d&&d[0]==="space";)d=v[--p];d&&(h.source.end=this.getPosition(d[3]||d[2]),h.source.end.offset++)}this.end(u);break}else v.push(u);else v.push(u);if(this.tokenizer.endOfFile()){g=!0;break}}h.raws.between=this.spacesAndCommentsFromEnd(v),v.length?(h.raws.afterName=this.spacesAndCommentsFromStart(v),this.raw(h,"params",v),g&&(u=v[v.length-1],h.source.end=this.getPosition(u[3]||u[2]),h.source.end.offset++,this.spaces=h.raws.between,h.raws.between="")):(h.raws.afterName="",h.params=""),m&&(h.nodes=[],this.current=h)}checkMissedSemicolon(u){let h=this.colon(u);if(h===!1)return;let f=0,d;for(let p=h-1;p>=0&&(d=u[p],!(d[0]!=="space"&&(f+=1,f===2)));p--);throw this.input.error("Missed semicolon",d[0]==="word"?d[3]+1:d[2])}colon(u){let h=0,f,d,p;for(let[g,m]of u.entries()){if(d=m,p=d[0],p==="("&&(h+=1),p===")"&&(h-=1),h===0&&p===":")if(!f)this.doubleColon(d);else{if(f[0]==="word"&&f[1]==="progid")continue;return g}f=d}return!1}comment(u){let h=new t;this.init(h,u[2]),h.source.end=this.getPosition(u[3]||u[2]),h.source.end.offset++;let f=u[1].slice(2,-2);if(/^\s*$/.test(f))h.text="",h.raws.left=f,h.raws.right="";else{let d=f.match(/^(\s*)([^]*\S)(\s*)$/);h.text=d[2],h.raws.left=d[1],h.raws.right=d[3]}}createTokenizer(){this.tokenizer=o(this.input)}decl(u,h){let f=new n;this.init(f,u[0][2]);let d=u[u.length-1];for(d[0]===";"&&(this.semicolon=!0,u.pop()),f.source.end=this.getPosition(d[3]||d[2]||a(u)),f.source.end.offset++;u[0][0]!=="word";)u.length===1&&this.unknownWord(u),f.raws.before+=u.shift()[1];for(f.source.start=this.getPosition(u[0][2]),f.prop="";u.length;){let b=u[0][0];if(b===":"||b==="space"||b==="comment")break;f.prop+=u.shift()[1]}f.raws.between="";let p;for(;u.length;)if(p=u.shift(),p[0]===":"){f.raws.between+=p[1];break}else p[0]==="word"&&/\w/.test(p[1])&&this.unknownWord([p]),f.raws.between+=p[1];(f.prop[0]==="_"||f.prop[0]==="*")&&(f.raws.before+=f.prop[0],f.prop=f.prop.slice(1));let g=[],m;for(;u.length&&(m=u[0][0],!(m!=="space"&&m!=="comment"));)g.push(u.shift());this.precheckMissedSemicolon(u);for(let b=u.length-1;b>=0;b--){if(p=u[b],p[1].toLowerCase()==="!important"){f.important=!0;let _=this.stringFrom(u,b);_=this.spacesFromEnd(u)+_,_!==" !important"&&(f.raws.important=_);break}else if(p[1].toLowerCase()==="important"){let _=u.slice(0),x="";for(let w=b;w>0;w--){let C=_[w][0];if(x.trim().startsWith("!")&&C!=="space")break;x=_.pop()[1]+x}x.trim().startsWith("!")&&(f.important=!0,f.raws.important=x,u=_)}if(p[0]!=="space"&&p[0]!=="comment")break}u.some(b=>b[0]!=="space"&&b[0]!=="comment")&&(f.raws.between+=g.map(b=>b[1]).join(""),g=[]),this.raw(f,"value",g.concat(u),h),f.value.includes(":")&&!h&&this.checkMissedSemicolon(u)}doubleColon(u){throw this.input.error("Double colon",{offset:u[2]},{offset:u[2]+u[1].length})}emptyRule(u){let h=new i;this.init(h,u[2]),h.selector="",h.raws.between="",this.current=h}end(u){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(u[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(u)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(u){if(this.spaces+=u[1],this.current.nodes){let h=this.current.nodes[this.current.nodes.length-1];h&&h.type==="rule"&&!h.raws.ownSemicolon&&(h.raws.ownSemicolon=this.spaces,this.spaces="",h.source.end=this.getPosition(u[2]),h.source.end.offset+=h.raws.ownSemicolon.length)}}getPosition(u){let h=this.input.fromOffset(u);return{column:h.col,line:h.line,offset:u}}init(u,h){this.current.push(u),u.source={input:this.input,start:this.getPosition(h)},u.raws.before=this.spaces,this.spaces="",u.type!=="comment"&&(this.semicolon=!1)}other(u){let h=!1,f=null,d=!1,p=null,g=[],m=u[1].startsWith("--"),v=[],b=u;for(;b;){if(f=b[0],v.push(b),f==="("||f==="[")p||(p=b),g.push(f==="("?")":"]");else if(m&&d&&f==="{")p||(p=b),g.push("}");else if(g.length===0)if(f===";")if(d){this.decl(v,m);return}else break;else if(f==="{"){this.rule(v);return}else if(f==="}"){this.tokenizer.back(v.pop()),h=!0;break}else f===":"&&(d=!0);else f===g[g.length-1]&&(g.pop(),g.length===0&&(p=null));b=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(h=!0),g.length>0&&this.unclosedBracket(p),h&&d){if(!m)for(;v.length&&(b=v[v.length-1][0],!(b!=="space"&&b!=="comment"));)this.tokenizer.back(v.pop());this.decl(v,m)}else this.unknownWord(v)}parse(){let u;for(;!this.tokenizer.endOfFile();)switch(u=this.tokenizer.nextToken(),u[0]){case"space":this.spaces+=u[1];break;case";":this.freeSemicolon(u);break;case"}":this.end(u);break;case"comment":this.comment(u);break;case"at-word":this.atrule(u);break;case"{":this.emptyRule(u);break;default:this.other(u);break}this.endFile()}precheckMissedSemicolon(){}raw(u,h,f,d){let p,g,m=f.length,v="",b=!0,_,x;for(let w=0;w<m;w+=1)p=f[w],g=p[0],g==="space"&&w===m-1&&!d?b=!1:g==="comment"?(x=f[w-1]?f[w-1][0]:"empty",_=f[w+1]?f[w+1][0]:"empty",!s[x]&&!s[_]?v.slice(-1)===","?b=!1:v+=p[1]:b=!1):v+=p[1];if(!b){let w=f.reduce((C,P)=>C+P[1],"");u.raws[h]={raw:w,value:v}}u[h]=v}rule(u){u.pop();let h=new i;this.init(h,u[0][2]),h.raws.between=this.spacesAndCommentsFromEnd(u),this.raw(h,"selector",u),this.current=h}spacesAndCommentsFromEnd(u){let h,f="";for(;u.length&&(h=u[u.length-1][0],!(h!=="space"&&h!=="comment"));)f=u.pop()[1]+f;return f}spacesAndCommentsFromStart(u){let h,f="";for(;u.length&&(h=u[0][0],!(h!=="space"&&h!=="comment"));)f+=u.shift()[1];return f}spacesFromEnd(u){let h,f="";for(;u.length&&(h=u[u.length-1][0],h==="space");)f=u.pop()[1]+f;return f}stringFrom(u,h){let f="";for(let d=h;d<u.length;d++)f+=u[d][1];return u.splice(h,u.length-h),f}unclosedBlock(){let u=this.current.source.start;throw this.input.error("Unclosed block",u.line,u.column)}unclosedBracket(u){throw this.input.error("Unclosed bracket",{offset:u[2]},{offset:u[2]+1})}unexpectedClose(u){throw this.input.error("Unexpected }",{offset:u[2]},{offset:u[2]+1})}unknownWord(u){throw this.input.error("Unknown word "+u[0][1],{offset:u[0][2]},{offset:u[0][2]+u[0][1].length})}unnamedAtrule(u,h){throw this.input.error("At-rule without name",{offset:h[2]},{offset:h[2]+h[1].length})}}return Vm=l,Vm}var Gm,nE;function Ym(){if(nE)return Gm;nE=1;let e=ti(),t=uc(),n=dse();function r(i,o){let s=new t(i,o),a=new n(s);try{a.parse()}catch(l){throw process.env.NODE_ENV!=="production"&&l.name==="CssSyntaxError"&&o&&o.from&&(/\.scss$/i.test(o.from)?l.message+=`
|
|
574
|
+
You tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser`:/\.sass/i.test(o.from)?l.message+=`
|
|
575
|
+
You tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser`:/\.less$/i.test(o.from)&&(l.message+=`
|
|
576
|
+
You tried to parse Less with the standard CSS parser; try again with the postcss-less parser`)),l}return a.root}return Gm=r,r.default=r,e.registerParse(r),Gm}var Xm,rE;function iE(){if(rE)return Xm;rE=1;class e{constructor(n,r={}){if(this.type="warning",this.text=n,r.node&&r.node.source){let i=r.node.rangeBy(r);this.line=i.start.line,this.column=i.start.column,this.endLine=i.end.line,this.endColumn=i.end.column}for(let i in r)this[i]=r[i]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Xm=e,e.default=e,Xm}var Um,oE;function Km(){if(oE)return Um;oE=1;let e=iE();class t{get content(){return this.css}constructor(r,i,o){this.processor=r,this.messages=[],this.root=i,this.opts=o,this.css="",this.map=void 0}toString(){return this.css}warn(r,i={}){i.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(i.plugin=this.lastPlugin.postcssPlugin);let o=new e(r,i);return this.messages.push(o),o}warnings(){return this.messages.filter(r=>r.type==="warning")}}return Um=t,t.default=t,Um}var Zm,sE;function aE(){if(sE)return Zm;sE=1;let e={};return Zm=function(n){e[n]||(e[n]=!0,typeof console!="undefined"&&console.warn&&console.warn(n))},Zm}var Qm,lE;function cE(){if(lE)return Qm;lE=1;let e=ti(),t=km(),n=J$(),r=Ym(),i=Km(),o=ls(),s=oc(),{isClean:a,my:l}=Sm(),c=aE();const u={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},h={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},f={Once:!0,postcssPlugin:!0,prepare:!0},d=0;function p(x){return typeof x=="object"&&typeof x.then=="function"}function g(x){let w=!1,C=u[x.type];return x.type==="decl"?w=x.prop.toLowerCase():x.type==="atrule"&&(w=x.name.toLowerCase()),w&&x.append?[C,C+"-"+w,d,C+"Exit",C+"Exit-"+w]:w?[C,C+"-"+w,C+"Exit",C+"Exit-"+w]:x.append?[C,d,C+"Exit"]:[C,C+"Exit"]}function m(x){let w;return x.type==="document"?w=["Document",d,"DocumentExit"]:x.type==="root"?w=["Root",d,"RootExit"]:w=g(x),{eventIndex:0,events:w,iterator:0,node:x,visitorIndex:0,visitors:[]}}function v(x){return x[a]=!1,x.nodes&&x.nodes.forEach(w=>v(w)),x}let b={};class _{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(w,C,P){this.stringified=!1,this.processed=!1;let O;if(typeof C=="object"&&C!==null&&(C.type==="root"||C.type==="document"))O=v(C);else if(C instanceof _||C instanceof i)O=v(C.root),C.map&&(typeof P.map=="undefined"&&(P.map={}),P.map.inline||(P.map.inline=!1),P.map.prev=C.map);else{let $=r;P.syntax&&($=P.syntax.parse),P.parser&&($=P.parser),$.parse&&($=$.parse);try{O=$(C,P)}catch(S){this.processed=!0,this.error=S}O&&!O[l]&&e.rebuild(O)}this.result=new i(w,O,P),this.helpers=zt(ht({},b),{postcss:b,result:this.result}),this.plugins=this.processor.plugins.map($=>typeof $=="object"&&$.prepare?ht(ht({},$),$.prepare(this.result)):$)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,C){let P=this.result.lastPlugin;try{if(C&&C.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin)w.plugin=P.postcssPlugin,w.setMessage();else if(P.postcssVersion&&process.env.NODE_ENV!=="production"){let O=P.postcssPlugin,$=P.postcssVersion,S=this.result.processor.version,M=$.split("."),I=S.split(".");(M[0]!==I[0]||parseInt(M[1])>parseInt(I[1]))&&console.error("Unknown error from PostCSS plugin. Your current PostCSS version is "+S+", but "+O+" uses "+$+". Perhaps this is the source of the error below.")}}catch(O){console&&console.error&&console.error(O)}return w}prepareVisitors(){this.listeners={};let w=(C,P,O)=>{this.listeners[P]||(this.listeners[P]=[]),this.listeners[P].push([C,O])};for(let C of this.plugins)if(typeof C=="object")for(let P in C){if(!h[P]&&/^[A-Z]/.test(P))throw new Error(`Unknown event ${P} in ${C.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!f[P])if(typeof C[P]=="object")for(let O in C[P])O==="*"?w(C,P,C[P][O]):w(C,P+"-"+O.toLowerCase(),C[P][O]);else typeof C[P]=="function"&&w(C,P,C[P])}this.hasListener=Object.keys(this.listeners).length>0}runAsync(){return rM(this,null,function*(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let C=this.plugins[w],P=this.runOnRoot(C);if(p(P))try{yield P}catch(O){throw this.handleError(O)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[a];){w[a]=!0;let C=[m(w)];for(;C.length>0;){let P=this.visitTick(C);if(p(P))try{yield P}catch(O){let $=C[C.length-1].node;throw this.handleError(O,$)}}}if(this.listeners.OnceExit)for(let[C,P]of this.listeners.OnceExit){this.result.lastPlugin=C;try{if(w.type==="document"){let O=w.nodes.map($=>P($,this.helpers));yield Promise.all(O)}else yield P(w,this.helpers)}catch(O){throw this.handleError(O)}}}return this.processed=!0,this.stringify()})}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let C=this.result.root.nodes.map(P=>w.Once(P,this.helpers));return p(C[0])?Promise.all(C):C}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(C){throw this.handleError(C)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let w=this.result.opts,C=s;w.syntax&&(C=w.syntax.stringify),w.stringifier&&(C=w.stringifier),C.stringify&&(C=C.stringify);let O=new n(C,this.result.root,this.result.opts).generate();return this.result.css=O[0],this.result.map=O[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let w of this.plugins){let C=this.runOnRoot(w);if(p(C))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[a];)w[a]=!0,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let C of w.nodes)this.visitSync(this.listeners.OnceExit,C);else this.visitSync(this.listeners.OnceExit,w)}return this.result}then(w,C){return process.env.NODE_ENV!=="production"&&("from"in this.opts||c("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(w,C)}toString(){return this.css}visitSync(w,C){for(let[P,O]of w){this.result.lastPlugin=P;let $;try{$=O(C,this.helpers)}catch(S){throw this.handleError(S,C.proxyOf)}if(C.type!=="root"&&C.type!=="document"&&!C.parent)return!0;if(p($))throw this.getAsyncError()}}visitTick(w){let C=w[w.length-1],{node:P,visitors:O}=C;if(P.type!=="root"&&P.type!=="document"&&!P.parent){w.pop();return}if(O.length>0&&C.visitorIndex<O.length){let[S,M]=O[C.visitorIndex];C.visitorIndex+=1,C.visitorIndex===O.length&&(C.visitors=[],C.visitorIndex=0),this.result.lastPlugin=S;try{return M(P.toProxy(),this.helpers)}catch(I){throw this.handleError(I,P)}}if(C.iterator!==0){let S=C.iterator,M;for(;M=P.nodes[P.indexes[S]];)if(P.indexes[S]+=1,!M[a]){M[a]=!0,w.push(m(M));return}C.iterator=0,delete P.indexes[S]}let $=C.events;for(;C.eventIndex<$.length;){let S=$[C.eventIndex];if(C.eventIndex+=1,S===d){P.nodes&&P.nodes.length&&(P[a]=!0,C.iterator=P.getIterator());return}else if(this.listeners[S]){C.visitors=this.listeners[S];return}}w.pop()}walkSync(w){w[a]=!0;let C=g(w);for(let P of C)if(P===d)w.nodes&&w.each(O=>{O[a]||this.walkSync(O)});else{let O=this.listeners[P];if(O&&this.visitSync(O,w.toProxy()))return}}warnings(){return this.sync().warnings()}}return _.registerPostcss=x=>{b=x},Qm=_,_.default=_,o.registerLazyResult(_),t.registerLazyResult(_),Qm}var Jm,uE;function pse(){if(uE)return Jm;uE=1;let e=J$(),t=Ym();const n=Km();let r=oc(),i=aE();class o{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let a,l=t;try{a=l(this._css,this._opts)}catch(c){this.error=c}if(this.error)throw this.error;return this._root=a,a}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(a,l,c){l=l.toString(),this.stringified=!1,this._processor=a,this._css=l,this._opts=c,this._map=void 0;let u,h=r;this.result=new n(this._processor,u,this._opts),this.result.css=l;let f=this;Object.defineProperty(this.result,"root",{get(){return f.root}});let d=new e(h,u,this._opts,l);if(d.isMap()){let[p,g]=d.generate();p&&(this.result.css=p),g&&(this.result.map=g)}else d.clearAnnotation(),this.result.css=d.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(a){return this.async().catch(a)}finally(a){return this.async().then(a,a)}sync(){if(this.error)throw this.error;return this.result}then(a,l){return process.env.NODE_ENV!=="production"&&("from"in this._opts||i("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(a,l)}toString(){return this._css}warnings(){return[]}}return Jm=o,o.default=o,Jm}var ey,hE;function gse(){if(hE)return ey;hE=1;let e=km(),t=cE(),n=pse(),r=ls();class i{constructor(s=[]){this.version="8.5.6",this.plugins=this.normalize(s)}normalize(s){let a=[];for(let l of s)if(l.postcss===!0?l=l():l.postcss&&(l=l.postcss),typeof l=="object"&&Array.isArray(l.plugins))a=a.concat(l.plugins);else if(typeof l=="object"&&l.postcssPlugin)a.push(l);else if(typeof l=="function")a.push(l);else if(typeof l=="object"&&(l.parse||l.stringify)){if(process.env.NODE_ENV!=="production")throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.")}else throw new Error(l+" is not a PostCSS plugin");return a}process(s,a={}){return!this.plugins.length&&!a.parser&&!a.stringifier&&!a.syntax?new n(this,s,a):new t(this,s,a)}use(s){return this.plugins=this.plugins.concat(this.normalize([s])),this}}return ey=i,i.default=i,r.registerProcessor(i),e.registerProcessor(i),ey}var ty,fE;function mse(){if(fE)return ty;fE=1;let e=Tm(),t=lc(),n=ti(),r=Cm(),i=cc(),o=km(),s=hse(),a=uc(),l=cE(),c=U$(),u=ac(),h=Ym(),f=gse(),d=Km(),p=ls(),g=jm(),m=oc(),v=iE();function b(..._){return _.length===1&&Array.isArray(_[0])&&(_=_[0]),new f(_)}return b.plugin=function(x,w){let C=!1;function P(...$){console&&console.warn&&!C&&(C=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
577
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(x+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
578
|
+
https://www.w3ctech.com/topic/2226`));let S=w(...$);return S.postcssPlugin=x,S.postcssVersion=new f().version,S}let O;return Object.defineProperty(P,"postcss",{get(){return O||(O=P()),O}}),P.process=function($,S,M){return b([P(M)]).process($,S)},P},b.stringify=m,b.parse=h,b.fromJSON=s,b.list=c,b.comment=_=>new t(_),b.atRule=_=>new e(_),b.decl=_=>new i(_),b.rule=_=>new g(_),b.root=_=>new p(_),b.document=_=>new o(_),b.CssSyntaxError=r,b.Declaration=i,b.Container=n,b.Processor=f,b.Document=o,b.Comment=t,b.Warning=v,b.AtRule=e,b.Result=d,b.Input=a,b.Rule=g,b.Root=p,b.Node=u,l.registerPostcss(b),ty=b,b.default=b,ty}var yse=mse();const bt=I$(yse);bt.stringify,bt.fromJSON,bt.plugin,bt.parse,bt.list,bt.document,bt.comment,bt.atRule,bt.rule,bt.decl,bt.root,bt.CssSyntaxError,bt.Declaration,bt.Container,bt.Processor,bt.Document,bt.Comment,bt.Warning,bt.AtRule,bt.Result,bt.Input,bt.Rule,bt.Root,bt.Node;var Fi=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function vse(e,t=!0){return Fi(this,null,function*(){const n=bse(e);if(n.size===0)return;const r=[];yield Promise.all(Array.from(n).map(i=>Fi(null,null,function*(){const o=wse(i);if(!o.length)return;const s=yield _se(i);if(!s.length)return;const a=yield Promise.all(s.map(l=>Fi(null,null,function*(){const c=xse(l),u=c["unicode-range"].replace(/\s/g,"");if(!o.find(g=>g.unicodeRange&&g.unicodeRange.replace(/\s/g,"")===u))return null;const f=wz(c["font-family"],fb(c["font-weight"]));if(!f)return null;const d=c.src.match(/url\(["']?(.*?\.woff2)[^"']*["']?\)/);if(!(d!=null&&d[1]))return null;const p=hh(f,d[1]);if(t){const g=yield Pse(p);c.src=`url(${g}) format('woff2')`}else c.src=`url(${p}) format('woff2')`;return c})));r.push(...a.filter(Boolean)||[])}))),r.length>0&&Cse(e,r)})}function bse(e){const t=new Set,n=i=>{i&&Ir(i).forEach(o=>{const s=gi(o);s&&t.add(s)})};n(e.getAttribute("font-family"));const r=e.querySelectorAll("foreignObject span");for(const i of r)n(i.style.fontFamily);return t}function _se(e){return Fi(this,null,function*(){const t=wb(e),n=[];return yield Promise.allSettled(t.map(r=>Fi(null,null,function*(){const i=yield ga(r).then(o=>o.text()).catch(()=>(console.error(`Failed to fetch font CSS: ${r}`),null));if(i)try{bt.parse(i).walkAtRules("font-face",s=>{const a={};s.walkDecls(l=>{a[l.prop]=l.value}),n.push(a)})}catch(o){console.error(`Failed to parse CSS: ${r}`,o)}}))),n})}function wse(e){const t=[],n=Ir(e).map(r=>gi(r));return document.fonts.forEach(r=>{n.includes(gi(r.family))&&r.status==="loaded"&&t.push(r)}),t}function xse(e){var t,n,r,i,o,s;return{"font-family":(t=e["font-family"])!=null?t:"",src:(n=e.src)!=null?n:"","font-style":(r=e["font-style"])!=null?r:"normal","font-display":(i=e["font-display"])!=null?i:"swap","font-weight":(o=e["font-weight"])!=null?o:"400","unicode-range":(s=e["unicode-range"])!=null?s:"U+0-FFFF"}}function Cse(e,t){const n=[],r=new Set;for(const s of t){const a=[s["font-family"],s["font-weight"],s["font-style"],s["unicode-range"],s.src].join("|");r.has(a)||(r.add(a),n.push(s))}if(n.length===0)return;const i=Me("style",{type:"text/css"});i.innerHTML=n.map(s=>`
|
|
550
579
|
@font-face {
|
|
551
|
-
font-family: ${
|
|
552
|
-
src: ${
|
|
553
|
-
font-style: ${
|
|
554
|
-
font-weight: ${
|
|
555
|
-
font-display: ${
|
|
556
|
-
unicode-range: ${
|
|
580
|
+
font-family: ${s["font-family"]};
|
|
581
|
+
src: ${s.src};
|
|
582
|
+
font-style: ${s["font-style"]};
|
|
583
|
+
font-weight: ${s["font-weight"]};
|
|
584
|
+
font-display: ${s["font-display"]};
|
|
585
|
+
unicode-range: ${s["unicode-range"]};
|
|
557
586
|
}
|
|
558
587
|
`.trim()).join(`
|
|
559
|
-
`);const o=e.querySelector("defs");o&&o.parentNode?o.parentNode.insertBefore(i,o.nextSibling):e.insertBefore(i,e.firstChild)}function Bie(e){return zi(this,null,function*(){const t=yield as(e);if(!t.ok)throw new Error(`Failed to load font: ${e}`);const n=yield t.blob();return yield new Promise((i,o)=>{const a=new FileReader;a.onloadend=()=>{i(a.result)},a.onerror=o,a.readAsDataURL(n)})})}var om=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});function Wie(e){return om(this,arguments,function*(t,n={}){const r=yield am(t,n),i=new XMLSerializer().serializeToString(r);return"data:image/svg+xml;charset=utf-8,"+encodeURIComponent(i)})}function am(e){return om(this,arguments,function*(t,n={}){const{embedResources:r=!0,removeIds:i=!1}=n,o=t.cloneNode(!0),{width:a,height:s}=Xu(t);return lt(o,{width:a,height:s}),i?(Yie(o),roe(o)):yield Gie(o),yield zie(o,r),coe(o),o})}function Gie(e){return om(this,null,function*(){const t=e.querySelectorAll("use"),n=Vie(e);t.forEach(r=>{const i=r.getAttribute("href");if(!i)return;if(!e.querySelector(i)){const a=document.querySelector(i);a&&n.appendChild(a.cloneNode(!0))}})})}const NO="icon-defs";function Vie(e){const t=mi(e,NO);if(t)return t;const n=Ee("defs");return po(n,NO),e.prepend(n),n}function Yie(e){const t=Array.from(e.querySelectorAll("use"));t.length&&t.forEach(n=>{const r=Xie(n);if(!r||!r.startsWith("#"))return;const i=Uie(e,r);if(!i||i===n)return;const o=Kie(n,i);o&&n.replaceWith(o)})}function Xie(e){var t;return(t=e.getAttribute("href"))!=null?t:e.getAttribute("xlink:href")}function Uie(e,t){const n=e.querySelector(t);return n||document.querySelector(t)}function Kie(e,t){const n=t.tagName.toLowerCase();return n==="symbol"?Zie(e,t):n==="svg"?Qie(e,t):Jie(e,t)}function Zie(e,t){const n=t.cloneNode(!0),r=Ee("svg");for(Uc(r,n,new Set(["id"])),Uc(r,e,new Set(["href","xlink:href"]));n.firstChild;)r.appendChild(n.firstChild);return r}function Qie(e,t){const n=t.cloneNode(!0);return n.removeAttribute("id"),Uc(n,e,new Set(["href","xlink:href"])),n}function Jie(e,t){const n=t.cloneNode(!0);n.removeAttribute("id");const r=Ee("g");Uc(r,e,new Set(["href","xlink:href","x","y","width","height","transform"]));const i=eoe(e);return i&&r.setAttribute("transform",i),r.appendChild(n),r}function eoe(e){var t;const n=e.getAttribute("x"),r=e.getAttribute("y"),i=n||r?`translate(${n!=null?n:0} ${r!=null?r:0})`:"",o=(t=e.getAttribute("transform"))!=null?t:"";return i&&o?`${i} ${o}`:i||o||null}function Uc(e,t,n=new Set){Array.from(t.attributes).forEach(r=>{if(!n.has(r.name)){if(r.name==="style"){toe(e,r.value);return}if(r.name==="class"){noe(e,r.value);return}e.setAttribute(r.name,r.value)}})}function toe(e,t){const n=e.getAttribute("style");if(!n){e.setAttribute("style",t);return}const r=n.trim().endsWith(";")?"":";";e.setAttribute("style",`${n}${r}${t}`)}function noe(e,t){const n=e.getAttribute("class");if(!n){e.setAttribute("class",t);return}e.setAttribute("class",`${n} ${t}`.trim())}const DO=/url\(\s*['"]?#([^'")\s]+)['"]?\s*\)/g;function roe(e){const t=ioe(e);if(t.size===0){qO(e);return}const n=ooe(e,t);n&&(gi(e,r=>{if(r.tagName.toLowerCase()==="defs")return!1;Array.from(r.attributes).forEach(o=>{const a=o.value;if(!a.includes("url("))return;const s=a.replace(DO,(c,l)=>{const u=encodeURIComponent(l);return`url("${n}#${u}")`});s!==a&&r.setAttribute(o.name,s)})}),qO(e))}function ioe(e){const t=new Set;return gi(e,n=>{if(n.tagName.toLowerCase()==="defs")return!1;HO(n,r=>t.add(r))}),t}function HO(e,t){for(const n of Array.from(e.attributes)){const r=n.value;if(r.includes("url("))for(const i of r.matchAll(DO))i[1]&&t(i[1]);(n.name==="href"||n.name==="xlink:href")&&r[0]==="#"&&t(r.slice(1))}}function ooe(e,t){if(t.size===0)return null;const n=aoe(e,t);if(n.size===0)return null;const r=Ee("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"}),i=Ee("defs");if(n.forEach(a=>{i.appendChild(a.cloneNode(!0))}),!i.children.length)return null;r.appendChild(i);const o=new XMLSerializer().serializeToString(r);return"data:image/svg+xml;charset=utf-8,"+encodeURIComponent(o)}function aoe(e,t){const n=new Map,r=Array.from(t),i=new Set(r),o=new Set,a=s=>{o.has(s)||i.has(s)||(r.push(s),i.add(s))};for(;r.length;){const s=r.shift();if(o.has(s))continue;o.add(s);const c=`#${soe(s)}`,l=e.querySelector(c);l&&(n.set(s,l),gi(l,u=>{HO(u,a)}))}return n}function soe(e){return globalThis.CSS&&typeof globalThis.CSS.escape=="function"?globalThis.CSS.escape(e):e.replace(/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g,"\\$1")}function qO(e){Array.from(e.querySelectorAll("defs")).forEach(n=>n.remove())}function coe(e){loe(e),uoe(e),hoe(e),doe(e)}function loe(e){const t=mi(e,Ve.BtnsGroup);t==null||t.remove();const n=mi(e,"btn-icon-defs");n==null||n.remove()}function uoe(e){const t=e.querySelector("[data-element-type=transient-container]");t==null||t.remove()}function hoe(e){e.querySelectorAll("g").forEach(n=>{n.removeAttribute("x"),n.removeAttribute("y"),n.removeAttribute("width"),n.removeAttribute("height")})}function doe(e){gi(e,t=>{for(const n in t.dataset)delete t.dataset[n]})}var foe=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});function poe(e){return foe(this,arguments,function*(t,n={}){var r;const{dpr:i=(r=globalThis.devicePixelRatio)!=null?r:2}=n,o=yield am(t),{width:a,height:s}=Xu(o);return new Promise((c,l)=>{try{const u=document.createElement("canvas");u.width=a*i,u.height=s*i;const h=u.getContext("2d");if(!h){l(new Error("Failed to get canvas context"));return}h.scale(i,i),h.imageSmoothingEnabled=!0,h.imageSmoothingQuality="high",o.setAttribute("width",String(a)),o.setAttribute("height",String(s));const d=new XMLSerializer().serializeToString(o),f="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(d),g=new Image;g.onload=function(){h.clearRect(0,0,a,s),h.drawImage(g,0,0,a,s);const y=u.toDataURL("image/png");c(y)},g.onerror=function(y){l(new Error("Image load failed: "+y))},g.src=f}catch(u){l(u)}})})}var sm={exports:{}},jO;function goe(){return jO||(jO=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(c,l,u){this.fn=c,this.context=l,this.once=u||!1}function o(c,l,u,h,d){if(typeof u!="function")throw new TypeError("The listener must be a function");var f=new i(u,h||c,d),g=n?n+l:l;return c._events[g]?c._events[g].fn?c._events[g]=[c._events[g],f]:c._events[g].push(f):(c._events[g]=f,c._eventsCount++),c}function a(c,l){--c._eventsCount===0?c._events=new r:delete c._events[l]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var l=[],u,h;if(this._eventsCount===0)return l;for(h in u=this._events)t.call(u,h)&&l.push(n?h.slice(1):h);return Object.getOwnPropertySymbols?l.concat(Object.getOwnPropertySymbols(u)):l},s.prototype.listeners=function(l){var u=n?n+l:l,h=this._events[u];if(!h)return[];if(h.fn)return[h.fn];for(var d=0,f=h.length,g=new Array(f);d<f;d++)g[d]=h[d].fn;return g},s.prototype.listenerCount=function(l){var u=n?n+l:l,h=this._events[u];return h?h.fn?1:h.length:0},s.prototype.emit=function(l,u,h,d,f,g){var y=n?n+l:l;if(!this._events[y])return!1;var m=this._events[y],v=arguments.length,b,_;if(m.fn){switch(m.once&&this.removeListener(l,m.fn,void 0,!0),v){case 1:return m.fn.call(m.context),!0;case 2:return m.fn.call(m.context,u),!0;case 3:return m.fn.call(m.context,u,h),!0;case 4:return m.fn.call(m.context,u,h,d),!0;case 5:return m.fn.call(m.context,u,h,d,f),!0;case 6:return m.fn.call(m.context,u,h,d,f,g),!0}for(_=1,b=new Array(v-1);_<v;_++)b[_-1]=arguments[_];m.fn.apply(m.context,b)}else{var x=m.length,w;for(_=0;_<x;_++)switch(m[_].once&&this.removeListener(l,m[_].fn,void 0,!0),v){case 1:m[_].fn.call(m[_].context);break;case 2:m[_].fn.call(m[_].context,u);break;case 3:m[_].fn.call(m[_].context,u,h);break;case 4:m[_].fn.call(m[_].context,u,h,d);break;default:if(!b)for(w=1,b=new Array(v-1);w<v;w++)b[w-1]=arguments[w];m[_].fn.apply(m[_].context,b)}}return!0},s.prototype.on=function(l,u,h){return o(this,l,u,h,!1)},s.prototype.once=function(l,u,h){return o(this,l,u,h,!0)},s.prototype.removeListener=function(l,u,h,d){var f=n?n+l:l;if(!this._events[f])return this;if(!u)return a(this,f),this;var g=this._events[f];if(g.fn)g.fn===u&&(!d||g.once)&&(!h||g.context===h)&&a(this,f);else{for(var y=0,m=[],v=g.length;y<v;y++)(g[y].fn!==u||d&&!g[y].once||h&&g[y].context!==h)&&m.push(g[y]);m.length?this._events[f]=m.length===1?m[0]:m:a(this,f)}return this},s.prototype.removeAllListeners=function(l){var u;return l?(u=n?n+l:l,this._events[u]&&a(this,u)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(sm)),sm.exports}var moe=goe();const yoe=LO(moe);var Kc=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class voe{constructor(){this.undoStack=[],this.redoStack=[]}init(t){Object.assign(this,t)}execute(t){return Kc(this,null,function*(){yield t.apply(this.state),this.undoStack.push(t),this.redoStack=[],this.emitHistoryChange("execute")})}executeBatch(t){return Kc(this,null,function*(){if(t.length===0)return;const n=new nre(t);yield this.execute(n)})}undo(){return Kc(this,null,function*(){const t=this.undoStack.pop();t&&(yield t.undo(this.state),this.redoStack.push(t),this.emitHistoryChange("undo"))})}redo(){return Kc(this,null,function*(){const t=this.redoStack.pop();t&&(yield t.apply(this.state),this.undoStack.push(t),this.emitHistoryChange("redo"))})}serialize(){return this.undoStack.map(t=>t.serialize())}clear(){this.undoStack=[],this.redoStack=[]}canUndo(){return this.undoStack.length>0}canRedo(){return this.redoStack.length>0}getHistorySize(){return this.undoStack.length}destroy(){this.clear()}emitHistoryChange(t){var n;(n=this.emitter)==null||n.emit("history:change",{type:"history:change",action:t})}}var FO=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class boe{constructor(){this.extensions=new LC,this.interactions=[],this.active=!1,this.running=null,this.concurrentInteractions=new Set,this.selection=new Set,this.handleClick=t=>{const n=this.editor.getDocument(),r=t.target;if(!r){this.deactivate();return}n.contains(r)||RD(r)?this.activate():this.deactivate()}}init(t){Object.assign(this,t),document.addEventListener("click",this.handleClick),this.interactions.forEach(n=>{this.extensions.register(n.name,n),n.init({emitter:this.emitter,editor:this.editor,commander:this.commander,state:this.state,interaction:this}),this.emitter.emit("interaction:registered",n)})}isActive(){return this.active}select(t,n){const r=this.getSelection(),i=[],o=[];if(n==="replace"){const c=new Set(t);r.forEach(l=>{c.has(l)||o.push(l)}),t.forEach(l=>{this.selection.has(l)||i.push(l)}),this.selection=c}else n==="add"?t.forEach(c=>{this.selection.has(c)||(this.selection.add(c),i.push(c))}):n==="remove"?t.forEach(c=>{this.selection.delete(c)&&o.push(c)}):n==="toggle"&&t.forEach(c=>{this.selection.has(c)?(this.selection.delete(c),o.push(c)):(this.selection.add(c),i.push(c))});const a=this.getSelection(),s={type:"selection:change",previous:r,next:a,added:i,removed:o,mode:n};this.emitter.emit("selection:change",s)}getSelection(){return[...this.selection]}isSelected(t){return this.selection.has(t)}clearSelection(){const t=this.getSelection();this.selection.clear();const n={type:"selection:change",previous:t,next:[],added:[],removed:t,mode:"replace"};this.emitter.emit("selection:change",n)}activate(){this.active=!0,this.emitter.emit("activated")}deactivate(){this.active=!1,this.running=null,this.clearSelection(),this.emitter.emit("deactivated")}executeExclusiveInteraction(t,n){return FO(this,null,function*(){if(!(!this.active||this.running)){this.running=t;try{this.emitter.emit("interaction:started",t),yield n(),this.emitter.emit("interaction:ended",t)}catch(r){console.error(`Error occurred during exclusive interaction "${t.name}":`,r),this.emitter.emit("interaction:error",t,r)}finally{this.running=null}}})}executeConcurrentInteraction(t,n){return FO(this,null,function*(){if(this.active){this.concurrentInteractions.add(t);try{this.emitter.emit("interaction:started",t),yield n(),this.emitter.emit("interaction:ended",t)}catch(r){console.error(`Error occurred during concurrent interaction "${t.name}":`,r),this.emitter.emit("interaction:error",t,r)}finally{this.concurrentInteractions.delete(t)}}})}getOrCreateTransientContainer(){const t="transient-container",n=this.editor.getDocument(),r=mi(n,t);if(r&&r.isConnected)return r;const i=Ee("g");return po(i,t),n.appendChild(i),i}appendTransientElement(t){return this.getOrCreateTransientContainer().appendChild(t),t}destroy(){this.extensions.forEach(t=>{t.destroy(),this.emitter.emit("interaction:destroyed",t)}),this.extensions.destroy(),this.active=!1,this.running=null,this.clearSelection(),document.removeEventListener("click",this.handleClick),this.getOrCreateTransientContainer().remove()}}class _oe{constructor(){this.extensions=new LC}init(t,n=[]){Object.assign(this,t),n.forEach(r=>{this.registerPlugin(r)})}getPlugin(t){return this.extensions.get(t)}getPlugins(){return this.extensions.getAll()}registerPlugin(t){this.extensions.register(t.name,t);const n={emitter:this.emitter,editor:this.editor,commander:this.commander,plugin:this,state:this.state};t.init(n),this.emitter.emit("plugin:registered",t)}unregisterPlugin(t){const n=this.extensions.get(t);n&&(n.destroy(),this.extensions.unregister(t),this.emitter.emit("plugin:unregistered",n))}destroy(){this.extensions.getAll().forEach(t=>{this.unregisterPlugin(t.name),this.emitter.emit("plugin:destroyed",t)}),this.extensions.destroy()}}var xoe=Object.defineProperty,BO=Object.getOwnPropertySymbols,woe=Object.prototype.hasOwnProperty,Poe=Object.prototype.propertyIsEnumerable,WO=(e,t,n)=>t in e?xoe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,GO=(e,t)=>{for(var n in t||(t={}))woe.call(t,n)&&WO(e,n,t[n]);if(BO)for(var n of BO(t))Poe.call(t,n)&&WO(e,n,t[n]);return e};class $oe{init(t){Object.assign(this,t)}addItemDatum(t,n){const r=t.slice(0,-1),i=t[t.length-1],o=Array.isArray(n)?n:[n];TC(this.options.data,r).splice(i,0,...o),this.emitter.emit("options:data:item:add",{indexes:t,datum:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"add",path:"data.items",indexes:t,value:o}]})}updateItemDatum(t,n){const r=no(this.options.data,t);Object.assign(r,n),this.emitter.emit("options:data:item:update",{indexes:t,datum:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:"data.items",indexes:t,value:n}]})}removeItemDatum(t,n=1){const r=t.slice(0,-1),i=t[t.length-1],a=TC(this.options.data,r).splice(i,n);this.emitter.emit("options:data:item:remove",{indexes:t,datum:a}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"remove",path:"data.items",indexes:t,value:a}]})}updateData(t,n){this.options.data[t]=n,this.emitter.emit("options:data:update",{key:t,value:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:`data.${t}`,value:n}]})}updateElement(t,n){this.updateBuiltInElement(t,n)}updateOptions(t){this.options=GO(GO({},this.options),t),this.options.padding!==void 0&&Fb(this.editor.getDocument(),Ar(this.options.padding)),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:"",value:t}]})}getOptions(){return this.options}updateBuiltInElement(t,n){var r,i;const{data:o}=this.options,{attributes:a={}}=n,s=Fu(t),c=cr(t)||Ve.ItemLabel===s||Ve.ItemDesc===s||Ve.ItemValue===s||Ve.ItemIllus===s,l=c?kC(t):void 0;if(c){const u=no(o,l),h=s.replace("item-","");u.attributes||(u.attributes={}),(r=u.attributes)[h]||(r[h]={}),Object.assign(u.attributes[h],a)}else(Ve.Title===s||Ve.Desc===s||Ve.Illus===s)&&(o.attributes||(o.attributes={}),(i=o.attributes)[s]||(i[s]={}),Object.assign(o.attributes[s],a));this.emitter.emit("options:element:update",{element:t,props:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",role:s,indexes:l,path:c?`${Gne(l)}.attributes.${s.replace("item-","")}`:`data.attributes.${s}`,value:n}]})}destroy(){}}class Coe{constructor(t,n,r){if(this.emitter=t,this.document=n,this.options=r,!n.isConnected)throw new Error("The provided document is not connected to the DOM.");n.style.userSelect="none";const i=new voe,o=new $oe,a=new _oe,s=new boe;i.init({state:o,emitter:t}),o.init({emitter:t,editor:this,commander:i,options:r}),a.init({emitter:t,editor:this,commander:i,state:o},r.plugins),s.init({emitter:t,editor:this,commander:i,state:o,interactions:r.interactions}),this.commander=i,this.state=o,this.plugin=a,this.interaction=s}getDocument(){return this.document}destroy(){this.document.style.userSelect="",this.interaction.destroy(),this.plugin.destroy(),this.commander.destroy(),this.state.destroy()}}var Ooe=Object.defineProperty,Soe=Object.defineProperties,Moe=Object.getOwnPropertyDescriptors,Zc=Object.getOwnPropertySymbols,VO=Object.prototype.hasOwnProperty,YO=Object.prototype.propertyIsEnumerable,XO=(e,t,n)=>t in e?Ooe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,cn=(e,t)=>{for(var n in t||(t={}))VO.call(t,n)&&XO(e,n,t[n]);if(Zc)for(var n of Zc(t))YO.call(t,n)&&XO(e,n,t[n]);return e},Ni=(e,t)=>Soe(e,Moe(t)),Di=(e,t)=>{var n={};for(var r in e)VO.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Zc)for(var r of Zc(e))t.indexOf(r)<0&&YO.call(e,r)&&(n[r]=e[r]);return n};function Eoe(e){const t=e,{container:n="#container",padding:r=0,template:i,design:o,theme:a,themeConfig:s,data:c}=t,l=Di(t,["container","padding","template","design","theme","themeConfig","data"]),u=typeof n=="string"?document.querySelector(n)||document.createElement("div"):n,h=i?mm(i):void 0,d=pv({},h==null?void 0:h.themeConfig,s),f=a||s||h!=null&&h.themeConfig?Roe(a,d):void 0,g={container:u,padding:Ar(r)};if(h){const m=h,{design:v}=m,b=Di(m,["design"]);Object.assign(g,b)}Object.assign(g,l);const y=Ioe(c,e.template);if(y&&(g.data=y),i&&(g.template=i),h!=null&&h.design||o){const m=Ni(cn({},f?Ni(cn({},e),{themeConfig:f}):e),{data:y||c}),v=Aoe(cn(cn({},h==null?void 0:h.design),o),m);gv(v)&&(g.design=v)}return a&&(g.theme=a),f&&(g.themeConfig=f),g}function Ioe(e,t){if(!e)return;if(Array.isArray(e.items)&&e.items.length)return e;const{lists:n,sequences:r,compares:i,nodes:o,values:a,root:s}=e,c=()=>{if(!t)return null;const h={list:n,sequence:r,compare:i,relation:o,chart:a,hierarchy:s?[s]:[]},d=t.split("-")[0],f=h[d];return f!=null&&f.length?f:null},l=()=>{var h;return n!=null&&n.length?n:r!=null&&r.length?r:i!=null&&i.length?i:o!=null&&o.length?o:a!=null&&a.length?a:s?[s]:(h=e.items)!=null&&h.length?e.items:[]};let u=c()||l();return u===r&&e.order==="desc"&&(u=[...u].reverse()),Ni(cn({},e),{items:u})}function cm(e){if(typeof e=="string")return{type:e};if(!("type"in e))throw new Error("Type is required");return e}function Aoe(e,t){const{structure:n,title:r,item:i,items:o}=e||{},a=UO(i||(o==null?void 0:o[0]),t);return{structure:Toe(n),title:koe(r,t),item:a,items:o?o.map(s=>UO(s,t)):[a]}}function Toe(e){if(!e)return null;const t=cm(e),{type:n}=t,r=Di(t,["type"]),i=Yw(n);if(!i)return null;const{component:o}=i;return Ni(cn({},i),{component:a=>o(cn(cn({},a),r))})}function koe(e,t){if(!e)return{component:null};const n=cm(e),{type:r}=n,i=Di(n,["type"]),{themeConfig:o}=t,a=(o==null?void 0:o.colorBg)||"#fff",s=KO(a,a);return{component:c=>U_(cn(Ni(cn({},c),{themeColors:s}),i))}}function UO(e,t){if(!e)return null;const n=cm(e),{type:r}=n,i=Di(n,["type"]),o=i3(r);if(!o)return null;const{component:a,options:s}=o;return Ni(cn({},o),{component:c=>{var l;const{indexes:u}=c,{data:h,themeConfig:d}=t,f=(d==null?void 0:d.colorBg)||"#fff",g=c,{themeColors:y=KO(za(d==null?void 0:d.palette,u,(l=h==null?void 0:h.items)==null?void 0:l.length)||(d==null?void 0:d.colorPrimary)||"#FF356A",f)}=g,m=Di(g,["themeColors"]);return a(cn(cn({themeColors:y},m),i))},options:s})}function Roe(e,t={}){var n;const r=e?K_(e)||{}:{},i=pv({},r,t);return i.palette=t.palette||r.palette,i.stylize=(n=t.stylize)!=null?n:r.stylize,i.colorPrimary||(i.colorPrimary="#FF356A"),i.palette||(i.palette=[i.colorPrimary]),i}function KO(e,t="#fff"){return J_({colorPrimary:e,isDarkMode:Gy(t),colorBg:t})}function Loe(e){return e===" "||e===" "}function zoe(e){let t=0,n=0;for(;n<e.length;){const r=e[n];if(r===" "){t+=1,n+=1;continue}if(r===" "){t+=2,n+=1;continue}break}return{indent:t,content:e.slice(n)}}function Noe(e){return e.trimEnd()}function Doe(e){return/[<>=o.x-]{2,}/.test(e)}function ZO(e){const t=e.trim();if(!t)return null;const n=t.match(/^([^:\s=]+)\s*[:=]\s*(.*)$/);if(n)return{key:n[1],value:n[2].trim()};const r=t.match(/^([^\s]+)\s+(.*)$/);return r?{key:r[1],value:r[2].trim()}:{key:t,value:void 0}}function Qc(e,t){return{kind:"object",line:e,value:t,entries:{}}}function QO(e){return{kind:"array",line:e,items:[]}}function Hoe(e){const t=[],n=Qc(0),r=[{indent:-1,node:n,parent:null,key:null}];return e.split(/\r?\n/).forEach((o,a)=>{const s=a+1;if(!o.trim())return;const{indent:c,content:l}=zoe(o),u=Noe(l);if(!u.trim())return;for(;r.length>1&&c<=r[r.length-1].indent;)r.pop();const h=r[r.length-1];let d=h.node;const f=u.trim();if(f.startsWith("-")&&(f.length===1||Loe(f[1]))){if(d.kind!=="array")if(d.kind==="object"&&Object.keys(d.entries).length===0&&d.value===void 0&&h.parent&&h.key){const b=QO(d.line);if(h.parent.kind==="object")h.parent.entries[h.key]=b;else if(h.parent.kind==="array"){const _=h.parent.items.indexOf(d);_>=0&&(h.parent.items[_]=b)}h.node=b,d=b}else{t.push({path:"",line:s,code:"bad_list",message:"List item is not under an array container.",raw:f});return}const m=f.slice(1).trim(),v=Qc(s,m||void 0);d.items.push(v),r.push({indent:c,node:v,parent:d});return}if(h.key==="relations"&&!f.startsWith("-")&&Doe(f)){if(d.kind!=="array")if(d.kind==="object"&&Object.keys(d.entries).length===0&&d.value===void 0&&h.parent&&h.key){const v=QO(d.line);if(h.parent.kind==="object")h.parent.entries[h.key]=v;else if(h.parent.kind==="array"){const b=h.parent.items.indexOf(d);b>=0&&(h.parent.items[b]=v)}h.node=v,d=v}else{t.push({path:"",line:s,code:"bad_list",message:"List item is not under an array container.",raw:f});return}const m=Qc(s,f);d.items.push(m),r.push({indent:c,node:m,parent:d});return}const g=ZO(f);if(!g){t.push({path:"",line:s,code:"bad_syntax",message:"Invalid syntax line.",raw:f});return}if(d.kind!=="object"){t.push({path:"",line:s,code:"bad_syntax",message:"Key-value pair is not under an object container.",raw:f});return}const y=Qc(s,g.value);d.entries[g.key]=y,r.push({indent:c,node:y,parent:d,key:g.key})}),{ast:n,errors:t}}function JO(e){return ZO(e)}function Jc(e,t){return{kind:"value",line:t,value:e}}const qoe=/^(#[0-9a-f]{8}|#[0-9a-f]{6}|#[0-9a-f]{4}|#[0-9a-f]{3})/i,joe=/^((?:rgb|rgba|hsl|hsla)\([^)]*\))/i;function Zr(e){const t=e.trim();return t==="true"?!0:t==="false"?!1:/^-?\d+(\.\d+)?$/.test(t)?parseFloat(t):t}function Qr(e){if(e.kind==="value"||e.kind==="object")return e.value}function Nt(e,t,n,r,i,o){e.push({path:n,line:t.line,code:r,message:i,raw:o})}function eS(e,t="any"){let n=e.trim();if(n.startsWith("[")&&n.endsWith("]")&&(n=n.slice(1,-1).trim()),!n)return[];let r;t==="comma"?r=n.split(","):t==="space"?r=n.split(/\s+/):r=n.split(/[,\s]+/);const i=[];for(const o of r){const a=o.trim();if(a){if(a==="#"||a==="//")break;i.push(a)}}return i}function Foe(e){let t=e.trim();const n=t.search(/\s+#(?![0-9a-f])/i);n>=0&&(t=t.slice(0,n).trimEnd());const r=t.indexOf("//");return r>=0&&(t=t.slice(0,r).trimEnd()),t}function lm(e){const t=Foe(e);if(!t)return;const n=t.match(qoe);if(n&&n[0].length===t.length)return t;const r=t.match(joe);if(r&&r[1].length===t.length||be(t).isValid())return t}function tS(e,t,n,r={}){const i=Qr(e);if(i===void 0){Nt(n,e,t,"schema_mismatch","Expected color value.");return}const o=lm(i);if(!o){r.soft||Nt(n,e,t,"invalid_value","Invalid color value.",i);return}return o}function Boe(e,t){return t.length>1||e.startsWith("[")&&e.endsWith("]")?!0:lm(e)!==void 0}function um(e){if(e.kind==="array")return e.items.map(r=>um(r));if(e.kind==="value"||!(Object.keys(e.entries).length>0)&&e.value!==void 0)return Zr(e.value);const n={};return e.value!==void 0&&(n.value=Zr(e.value)),Object.entries(e.entries).forEach(([r,i])=>{n[r]=um(i)}),n}function Woe(e,t,n,r){let i,o=null;for(const a of t.variants){const s=[],c=rn(e,a,n,s);(o===null||s.length<o.length)&&(o=s,i=c)}return o&&r.push(...o),i}function rn(e,t,n,r){switch(t.kind){case"union":return Woe(e,t,n,r);case"string":{const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected string value.");return}return i}case"number":{const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected number value.");return}const a=i.trim().match(/^(-?\d+(\.\d+)?)(?:\s*(#|\/\/).*)?$/);if(!a){Nt(r,e,n,"invalid_value","Invalid number value.",i);return}return parseFloat(a[1])}case"boolean":{const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected boolean value.");return}if(i!=="true"&&i!=="false"){Nt(r,e,n,"invalid_value","Invalid boolean value.",i);return}return i==="true"}case"enum":{const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected enum value.");return}if(!t.values.includes(i)){Nt(r,e,n,"invalid_value","Invalid enum value.",i);return}return i}case"array":{if(e.kind==="array")return e.items.map((s,c)=>rn(s,t.item,`${n}[${c}]`,r)).filter(s=>s!==void 0);if(e.kind==="object"&&Object.keys(e.entries).length>0){Nt(r,e,n,"schema_mismatch","Expected array value.");return}const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected array value.");return}const o=i.trim();return o.startsWith("[")&&!o.endsWith("]")?void 0:eS(i,t.split).map((s,c)=>rn(Jc(s,e.line),t.item,`${n}[${c}]`,r)).filter(s=>s!==void 0)}case"palette":{if(e.kind==="array"){const c=rn(e,{kind:"array",item:{kind:"color"},split:"any"},n,r);return Array.isArray(c)&&c.length>0?c:void 0}if(e.kind==="object"&&Object.keys(e.entries).length>0){Nt(r,e,n,"schema_mismatch","Expected palette value.");return}const i=Qr(e);if(i===void 0){Nt(r,e,n,"schema_mismatch","Expected palette value.");return}const o=i.trim();if(o.startsWith("[")&&!o.endsWith("]"))return;const a=lm(o);if(a)return[a];const s=eS(i,"any");if(Boe(o,s)){const c=s.map((l,u)=>tS(Jc(l,e.line),`${n}[${u}]`,r)).filter(l=>l!==void 0);return c.length>0?c:void 0}return i}case"color":return tS(e,n,r,{soft:t.soft});case"object":{if(e.kind==="array"){Nt(r,e,n,"schema_mismatch","Expected object value.");return}const i={};if(e.kind==="value"){if(t.shorthandKey)return i[t.shorthandKey]=e.value,i;const o=JO(e.value);if((o==null?void 0:o.value)!==void 0){if(t.fields[o.key]){const a=rn(Jc(o.value,e.line),t.fields[o.key],`${n}.${o.key}`,r);return a!==void 0&&(i[o.key]=a),i}return t.allowUnknown?(i[o.key]=Zr(o.value),i):(Nt(r,e,`${n}.${o.key}`,"unknown_key","Unknown key in object.",o.key),i)}if(t.allowUnknown)return i.value=Zr(e.value),i;Nt(r,e,n,"invalid_value","Expected object value.");return}if(e.value!==void 0)if(t.shorthandKey&&i[t.shorthandKey]===void 0)i[t.shorthandKey]=e.value;else{const o=JO(e.value);if((o==null?void 0:o.value)!==void 0)if(t.fields[o.key]){const a=rn(Jc(o.value,e.line),t.fields[o.key],`${n}.${o.key}`,r);a!==void 0&&i[o.key]===void 0&&(i[o.key]=a)}else t.allowUnknown?i[o.key]=Zr(o.value):Nt(r,e,`${n}.${o.key}`,"unknown_key","Unknown key in object.",o.key);else t.allowUnknown&&(i.value=Zr(e.value))}return Object.entries(e.entries).forEach(([o,a])=>{const s=t.fields[o];if(!s){if(t.allowUnknown){i[o]=um(a);return}Nt(r,a,`${n}.${o}`,"unknown_key","Unknown key in object.",o);return}const c=rn(a,s,`${n}.${o}`,r);c!==void 0&&(i[o]=c)}),i}default:return}}const kt=()=>({kind:"string"}),gr=()=>({kind:"number"}),ea=e=>({kind:"enum",values:e}),Hi=(e={})=>({kind:"color",soft:e.soft}),Kn=(e,t="any")=>({kind:"array",item:e,split:t}),qt=(e,t={})=>({kind:"object",fields:e,allowUnknown:t.allowUnknown,shorthandKey:t.shorthandKey}),ta=(...e)=>({kind:"union",variants:e}),Goe=()=>({kind:"palette"}),na=()=>qt({},{allowUnknown:!0}),nS={fill:Hi({soft:!0}),stroke:Hi({soft:!0})},qi=qt(nS,{allowUnknown:!0}),hm=qt(nS,{allowUnknown:!0}),Zn=qt({},{allowUnknown:!0});Zn.fields={id:kt(),label:kt(),value:ta(gr(),kt()),desc:kt(),icon:ta(kt(),na()),illus:ta(kt(),na()),attributes:na(),group:kt(),category:kt(),children:Kn(Zn)};const rS=qt({id:kt(),from:kt(),to:kt(),label:kt(),direction:ea(["forward","both","none"]),showArrow:ea(["true","false"]),arrowType:ea(["arrow","triangle","diamond"])},{allowUnknown:!0}),iS=qt({type:kt(),colorBg:Hi(),colorPrimary:Hi(),palette:Goe(),title:qi,desc:qi,shape:hm,base:qt({global:qt({},{allowUnknown:!0}),shape:hm,text:qi}),item:qt({icon:qt({},{allowUnknown:!0}),label:qi,desc:qi,value:qi,shape:hm}),stylize:qt({type:ea(["rough","pattern"]),roughness:gr(),bowing:gr(),fillWeight:gr(),hachureGap:gr(),pattern:kt(),backgroundColor:Hi(),foregroundColor:Hi(),scale:gr()},{shorthandKey:"type"}),elements:qt({},{allowUnknown:!0})},{shorthandKey:"type"}),el=qt({},{allowUnknown:!0,shorthandKey:"type"}),oS=qt({structure:el,item:el,items:Kn(el),title:el}),aS=qt({title:kt(),desc:kt(),items:Kn(Zn),lists:Kn(Zn),sequences:Kn(Zn),root:Zn,compares:Kn(Zn),nodes:Kn(Zn),relations:Kn(rS),values:Kn(Zn),order:ea(["asc","desc"]),illus:na(),attributes:na()}),sS=qt({type:kt()},{shorthandKey:"type"}),cS=qt({template:sS,design:oS,data:aS,theme:iS,width:ta(gr(),kt()),height:ta(gr(),kt())}),lS=/[<>=o.x-]{2,}/,tl=/[<>=o.x-]{2,}/g;function nl(e){let t=e.trim();if(!t)return"";const n=t[0],r=t[t.length-1];return(n==='"'&&r==='"'||n==="'"&&r==="'")&&(t=t.slice(1,-1)),t=t.replace(/\\(["'])/g,"$1").replace(/("|&#quot;|#quot;)/g,'"').replace(/('|'|#apos;)/g,"'"),t.trim()}function Voe(e){const t=e.trim().replace(/^[-=.ox]+/,"").trim();return nl(t)}function rl(e,t){let n=t;for(;n<e.length&&/\s/.test(e[n]);)n+=1;return n}function uS(e,t){let n=rl(e,t);if(n>=e.length)return null;const r=n;for(;n<e.length;){const a=e[n];if(/\s/.test(a)||a==="["||a==="("||a==="@"||a==="|"||a==="<"||a===">"||a==="-"&&(e[n+1]==="-"||e[n+1]===">"||e[n+1]==="<"))break;n+=1}if(n===r)return null;const i=e.slice(r,n).trim();if(!i)return null;if(e.startsWith("@{",n)){const a=e.indexOf("}",n+2);a!==-1&&(n=a+1)}n=rl(e,n);let o;if(e[n]==="["){const a=e.indexOf("]",n+1);a!==-1&&(o=nl(e.slice(n+1,a)),n=a+1)}else if(e[n]==="("){const a=e.indexOf(")",n+1);if(a!==-1){let s=e.slice(n+1,a).trim();s.startsWith("[")&&s.endsWith("]")&&(s=s.slice(1,-1).trim()),o=nl(s),n=a+1}}return{node:{id:i,label:o},nextIndex:n}}function Yoe(e,t){tl.lastIndex=t;const n=tl.exec(e);if(!n)return null;const r=n[0],i=n.index,o=i+r.length;let s=Voe(e.slice(t,i))||void 0,c=r,l=o;if(l=rl(e,l),e[l]==="|"){const v=e.indexOf("|",l+1);if(v!==-1){s=nl(e.slice(l+1,v))||s,l=v+1;const _=rl(e,l);tl.lastIndex=_;const x=tl.exec(e);x&&x.index===_?(c+=x[0],l=x.index+x[0].length):l=_}}const u=c.includes("<"),h=c.includes(">"),d=c.match(/[xo]/gi)||[],f=/^[xo]/i.test(c),g=/[xo]$/i.test(c);let y="none",m=!1;return u&&h||u&&g||h&&f||f&&g?y="both":(u||h||d.length>0)&&(y="forward",m=u&&!h),{label:s,direction:y,reverse:m,nextIndex:l}}function Xoe(e){const t=[],n=[],r=new Map;let i=0;const o=uS(e,i);if(!o)return{relations:t,nodes:n};let a=o.node;for(r.has(a.id)||(r.set(a.id,a),n.push(a)),i=o.nextIndex;i<e.length;){const s=Yoe(e,i);if(!s)break;i=s.nextIndex;const c=uS(e,i);if(!c)break;i=c.nextIndex;let l=a.id,u=c.node.id;const h=s.direction;s.reverse&&(l=c.node.id,u=a.id);const d={from:l,to:u};s.label&&(d.label=s.label),h==="both"&&(d.direction="both"),h==="none"&&(d.direction="none"),t.push(d),r.has(a.id)||(r.set(a.id,a),n.push(a)),r.has(c.node.id)||(r.set(c.node.id,c.node),n.push(c.node)),a=c.node}return{relations:t,nodes:n}}function Uoe(e,t,n,r){if(!n)return;const i=e.get(n);if(i){!i.label&&r&&(i.label=r);return}const o={id:n,label:r||n};e.set(n,o),t.push(o)}function Koe(e,t,n){const r=rn(e,rS,t,n);return!r||typeof r!="object"||typeof r.from!="string"||typeof r.to!="string"?null:r}function Zoe(e,t,n){const r=[],i=[],o=new Map,a=s=>{if(!lS.test(s))return;const c=Xoe(s);c.nodes.forEach(l=>{Uoe(o,i,l.id,l.label)}),r.push(...c.relations)};return e.kind==="array"?e.items.forEach((s,c)=>{if(s.kind==="object"&&s.value&&Object.keys(s.entries).length===0&&lS.test(s.value)){a(s.value);return}const l=Koe(s,`${n}[${c}]`,t);l&&r.push(l)}):e.kind==="object"&&e.value&&a(e.value),{relations:r,items:i}}var Qoe=Object.defineProperty,Joe=Object.defineProperties,eae=Object.getOwnPropertyDescriptors,il=Object.getOwnPropertySymbols,hS=Object.prototype.hasOwnProperty,dS=Object.prototype.propertyIsEnumerable,fS=(e,t,n)=>t in e?Qoe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,pS=(e,t)=>{for(var n in t||(t={}))hS.call(t,n)&&fS(e,n,t[n]);if(il)for(var n of il(t))dS.call(t,n)&&fS(e,n,t[n]);return e},tae=(e,t)=>Joe(e,eae(t)),gS=(e,t)=>{var n={};for(var r in e)hS.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&il)for(var r of il(e))t.indexOf(r)<0&&dS.call(e,r)&&(n[r]=e[r]);return n};function nae(e){var t;const n=new Set,r=[];for(let i=e.length-1;i>=0;i-=1){const o=e[i],a=(t=o.id)!=null?t:o.label;if(!a){r.push(o);continue}n.has(a)||(n.add(a),o.id||(o.id=a),r.push(o))}return r.reverse()}function rae(e,t){if(!e)return;const n=rn(e,sS,"template",t);if(n){if(typeof n=="string")return n;if(typeof n=="object"&&typeof n.type=="string")return n.type}}function mS(e){var t;const{ast:n,errors:r}=Hoe(e),i=[],o={},a=pS({},n.entries),s=n.entries.infographic;let c;s&&s.kind==="object"&&(s.value&&(c=s.value),Object.entries(s.entries).forEach(([v,b])=>{v in a||(a[v]=b)}));const l=new Set(["infographic","template","design","data","theme","width","height"]);Object.keys(a).forEach(v=>{l.has(v)||r.push({path:v,line:a[v].line,code:"unknown_key",message:"Unknown top-level key.",raw:v})});const u=a.template,h=rae(u,r);h&&(o.template=h),!o.template&&c&&(o.template=c);const d=a.design;if(d){const v=rn(d,oS,"design",r);v&&(o.design=v)}const f=a.data;if(f){let v,b=f;if(f.kind==="object"){const x=f.entries,{relations:w}=x,P=gS(x,["relations"]);v=w,b=tae(pS({},f),{entries:P})}const _=rn(b,aS,"data",r);if(_&&(o.data=_),v){const x=Zoe(v,r,"data.relations");if(x.relations.length>0||x.items.length>0){const w=(t=o.data)!=null?t:{},P=Array.isArray(w.items)?w.items:[],$=nae(P),C=new Map;$.forEach(M=>{M.id&&C.set(M.id,M)}),x.items.forEach(M=>{const S=C.get(M.id);S?!S.label&&M.label&&(S.label=M.label):($.push(M),C.set(M.id,M))}),w.items=$,w.relations=x.relations,o.data=w}}}const g=a.theme;if(g){const v=rn(g,iS,"theme",r);if(v&&typeof v=="object"){const b=v,{type:_}=b,x=gS(b,["type"]);typeof _=="string"&&_&&(o.theme=_),Object.keys(x).length>0&&(o.themeConfig=x)}}const y=a.width;if(y){const v=rn(y,cS.fields.width,"width",r);v!==void 0&&(o.width=v)}const m=a.height;if(m){const v=rn(m,cS.fields.height,"height",r);v!==void 0&&(o.height=v)}return{options:o,errors:r,warnings:i,ast:n}}const iae=()=>[new IO,new RO],oae=()=>[new KC,new zC,new NC,new ZC,new JC,new iO,new nO],aae={padding:20,theme:"light",themeConfig:{palette:"antv"},get plugins(){return iae()},get interactions(){return oae()}};var sae=Object.defineProperty,yS=Object.getOwnPropertySymbols,cae=Object.prototype.hasOwnProperty,lae=Object.prototype.propertyIsEnumerable,vS=(e,t,n)=>t in e?sae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Qn=(e,t)=>{for(var n in t||(t={}))cae.call(t,n)&&vS(e,n,t[n]);if(yS)for(var n of yS(t))lae.call(t,n)&&vS(e,n,t[n]);return e};function dm(e,t){const n=Qn(Qn({},e),t);return(e.design||t.design)&&(n.design=Qn(Qn({},e.design),t.design)),(e.themeConfig||t.themeConfig)&&(n.themeConfig=Qn(Qn({},e.themeConfig),t.themeConfig)),(e.svg||t.svg)&&(n.svg=Qn(Qn({},e.svg),t.svg)),n}function fm(e){const t=Qn({},e);return t.data&&(t.data=dv(t.data)),t.elements&&(t.elements=dv(t.elements)),t}function bS(e){const{design:t,data:n}=e;return!(!t||!gv(t)||!n||!Array.isArray(n.items)||n.items.length<1)}var uae=Object.defineProperty,_S=Object.getOwnPropertySymbols,hae=Object.prototype.hasOwnProperty,dae=Object.prototype.propertyIsEnumerable,xS=(e,t,n)=>t in e?uae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,fae=(e,t)=>{for(var n in t||(t={}))hae.call(t,n)&&xS(e,n,t[n]);if(_S)for(var n of _S(t))dae.call(t,n)&&xS(e,n,t[n]);return e},pae=(e,t,n)=>new Promise((r,i)=>{var o=c=>{try{s(n.next(c))}catch(l){i(l)}},a=c=>{try{s(n.throw(c))}catch(l){i(l)}},s=c=>c.done?r(c.value):Promise.resolve(c.value).then(o,a);s((n=n.apply(e,t)).next())});class gae{constructor(t){this.rendered=!1,this.emitter=new yoe,this.node=null,this.initialOptions={},this.setOptions(t,"replace",!0)}getOptions(){return this.options}setOptions(t,n="replace",r=!1){const{options:i,errors:o,warnings:a}=mae(t);r&&(this.initialOptions=i);const s=dm(n==="replace"?fm(this.initialOptions||{}):this.options||fm(this.initialOptions||{}),i);this.options=s,this.parsedOptions=Eoe(dm(aae,this.options)),a.length&&this.emitter.emit("warning",a),o.length&&this.emitter.emit("error",o)}render(t){t?this.setOptions(t,"replace"):!this.options&&this.initialOptions&&this.setOptions(this.initialOptions,"replace"),this.performRender()}update(t){this.setOptions(t,"merge"),this.performRender()}performRender(){var t;const n=this.parsedOptions;if(!bS(n)){this.emitter.emit("error",new Error("Incomplete options"));return}const{container:r}=this.parsedOptions,i=this.compose(n),o=new QN(n,i);this.node=o.render(),r==null||r.replaceChildren(this.node),(t=this.editor)==null||t.destroy(),this.editor=void 0,this.options.editable&&(this.editor=new Coe(this.emitter,this.node,n)),this.rendered=!0,this.emitter.emit("rendered",{node:this.node,options:this.options});const a=this.node;return a&&qL(a).then(()=>{this.node===a&&this.emitter.emit("loaded",{node:a,options:this.options})}),!0}compose(t){const{design:n,data:r}=t,{title:i,item:o,items:a,structure:s}=n,{component:c,props:l}=s,u=i.component,h=o.component,d=a.map(y=>y.component),f=a_(p(c,fae({data:r,Title:u,Item:h,Items:d,options:t},l))),g=pi(f);if(!g)throw new Error("Failed to parse SVG template");return g}getTypes(){const t=this.parsedOptions;if(!bS(t)){this.emitter.emit("error",new Error("Incomplete options"));return}const n=t.design,r=n.structure.composites||[],i=n.items.map(o=>o.composites||[]);return HD({structure:r,items:i})}toDataURL(t){return pae(this,null,function*(){if(!this.node)throw new Error("Infographic is not rendered yet.");return(t==null?void 0:t.type)==="svg"?yield Wie(this.node,t):yield poe(this.node,t)})}on(t,n){this.emitter.on(t,n)}off(t,n){this.emitter.off(t,n)}destroy(){var t,n;(t=this.editor)==null||t.destroy(),(n=this.node)==null||n.remove(),this.node=null,this.rendered=!1,this.emitter.emit("destroyed"),this.emitter.removeAllListeners()}}function mae(e){if(typeof e=="string"){const{options:t,errors:n,warnings:r}=mS(e);return{options:t,errors:n,warnings:r}}return{options:fm(e),errors:[],warnings:[]}}const yae="0.2.10";V.AlignLayout=vi,V.BadgeCard=s3,V.BrushSelect=zC,V.BtnAdd=Q,V.BtnRemove=nt,V.BtnsGroup=He,V.CandyCardLite=u3,V.CapsuleItem=v3,V.ChartBar=Xw,V.ChartColumn=Uw,V.ChartLine=Jw,V.ChartPie=e4,V.ChartWordCloud=a4,V.CircleNode=x3,V.CircularProgress=$3,V.ClickSelect=NC,V.CompactCard=M3,V.CompareBinaryHorizontal=m4,V.CompareHierarchyLeftRight=_4,V.CompareHierarchyRow=x4,V.DblClickEditText=KC,V.Defs=Ke,V.DoneList=A3,V.DragElement=ZC,V.EditBar=IO,V.Ellipse=Ze,V.FlexLayout=ve,V.Fragment=go,V.Gap=mt,V.Group=Y,V.HierarchyMindmap=T4,V.HierarchyStructure=R4,V.HierarchyTree=D4,V.HorizontalIconArrow=R3,V.HorizontalIconLine=H3,V.HotkeyHistory=JC,V.IconBadge=F3,V.Illus=y_,V.IndexedCard=G3,V.Infographic=gae,V.Interaction=fr,V.ItemDesc=ut,V.ItemIcon=Ht,V.ItemIconCircle=kr,V.ItemLabel=Ge,V.ItemValue=xo,V.ItemsGroup=Ne,V.LCornerCard=X3,V.LabelText=ax,V.LetterCard=Z3,V.LinedText=ex,V.ListColumn=H4,V.ListGrid=q4,V.ListPyramid=j4,V.ListRow=F4,V.ListSector=G4,V.ListWaterfall=V4,V.ListZigzagDown=Z4,V.ListZigzagUp=Q4,V.Path=Pe,V.PillBadge=rx,V.Plugin=K1,V.Polygon=Wt,V.ProgressCard=fw,V.Quadrant=w4,V.QuarterCircular=mw,V.QuarterSimpleCard=bw,V.Rect=Re,V.RelationCircle=J4,V.RelationDagreFlow=j$,V.RelationNetwork=F$,V.ResizeElement=RO,V.RibbonCard=ww,V.RoundedRectNode=Cw,V.SelectHighlight=nO,V.SequenceAscendingStairs3d=Q$,V.SequenceAscendingSteps=J$,V.SequenceCircleArrows=tC,V.SequenceCircular=nC,V.SequenceColorSnakeSteps=rC,V.SequenceFilterMesh=sC,V.SequenceFunnel=hC,V.SequenceHorizontalZigzag=dC,V.SequenceMountain=gC,V.SequencePyramid=mC,V.SequenceRoadmapVertical=vC,V.SequenceSnakeSteps=bC,V.SequenceStairsFront=_C,V.SequenceSteps=xC,V.SequenceTimeline=wC,V.SequenceZigzagPucks3d=$C,V.SequenceZigzagSteps=IC,V.ShapesGroup=xt,V.SimpleCircleNode=Mw,V.SimpleHorizontalArrow=Aw,V.SimpleIllusItem=Rw,V.SimpleItem=Nw,V.SimpleVerticalArrow=qw,V.Text=ze,V.Title=U_,V.UnderlineText=Bw,V.VERSION=yae,V.VerticalIconArrow=Vw,V.ZoomWheel=iO,V.cloneElement=lr,V.createFragment=iH,V.createLayout=eh,V.exportToSVG=am,V.getCombinedBounds=yi,V.getElementBounds=se,V.getElementsBounds=Tr,V.getFont=yu,V.getFonts=vu,V.getItem=i3,V.getItemProps=st,V.getItems=Iq,V.getPalette=Mv,V.getPaletteColor=za,V.getPalettes=ZL,V.getStructure=Yw,V.getStructures=HU,V.getTemplate=mm,V.getTemplates=SS,V.getTheme=K_,V.getThemeColors=Ct,V.getThemes=fq,V.jsx=ls,V.jsxDEV=aH,V.jsxs=oH,V.loadSVGResource=di,V.parseSVG=pi,V.parseSyntax=mS,V.registerFont=Cv,V.registerItem=ct,V.registerPalette=xu,V.registerPattern=cb,V.registerResourceLoader=gz,V.registerStructure=We,V.registerTemplate=gm,V.registerTheme=ih,V.renderSVG=a_,V.sequenceCylinders3d=iC,V.setDefaultFont=GL,V.setFontExtendFactor=iD,Object.defineProperty(V,Symbol.toStringTag,{value:"Module"})}));
|
|
588
|
+
`);const o=e.querySelector("defs");o&&o.parentNode?o.parentNode.insertBefore(i,o.nextSibling):e.insertBefore(i,e.firstChild)}function Pse(e){return Fi(this,null,function*(){const t=yield ga(e);if(!t.ok)throw new Error(`Failed to load font: ${e}`);const n=yield t.blob();return yield new Promise((i,o)=>{const s=new FileReader;s.onloadend=()=>{i(s.result)},s.onerror=o,s.readAsDataURL(n)})})}var ny=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function Ose(e){return ny(this,arguments,function*(t,n={}){const r=yield ry(t,n),i=new XMLSerializer().serializeToString(r);return"data:image/svg+xml;charset=utf-8,"+encodeURIComponent(i)})}function ry(e){return ny(this,arguments,function*(t,n={}){const{embedResources:r=!0,removeIds:i=!1}=n,o=t.cloneNode(!0),{width:s,height:a}=fh(t);return ut(o,{width:s,height:a}),i?(Ese(o),Dse(o)):yield Sse(o),yield vse(o,r),Bse(o),o})}function Sse(e){return ny(this,null,function*(){const t=e.querySelectorAll("use"),n=$se(e);t.forEach(r=>{const i=r.getAttribute("href");if(!i)return;if(!e.querySelector(i)){const s=document.querySelector(i);s&&n.appendChild(s.cloneNode(!0))}})})}const dE="icon-defs";function $se(e){const t=xi(e,dE);if(t)return t;const n=Me("defs");return xo(n,dE),e.prepend(n),n}function Ese(e){const t=Array.from(e.querySelectorAll("use"));t.length&&t.forEach(n=>{const r=Mse(n);if(!r||!r.startsWith("#"))return;const i=Ise(e,r);if(!i||i===n)return;const o=Ase(n,i);o&&n.replaceWith(o)})}function Mse(e){var t;return(t=e.getAttribute("href"))!=null?t:e.getAttribute("xlink:href")}function Ise(e,t){const n=e.querySelector(t);return n||document.querySelector(t)}function Ase(e,t){const n=t.tagName.toLowerCase();return n==="symbol"?Tse(e,t):n==="svg"?Rse(e,t):kse(e,t)}function Tse(e,t){const n=t.cloneNode(!0),r=Me("svg");for(hc(r,n,new Set(["id"])),hc(r,e,new Set(["href","xlink:href"]));n.firstChild;)r.appendChild(n.firstChild);return r}function Rse(e,t){const n=t.cloneNode(!0);return n.removeAttribute("id"),hc(n,e,new Set(["href","xlink:href"])),n}function kse(e,t){const n=t.cloneNode(!0);n.removeAttribute("id");const r=Me("g");hc(r,e,new Set(["href","xlink:href","x","y","width","height","transform"]));const i=Lse(e);return i&&r.setAttribute("transform",i),r.appendChild(n),r}function Lse(e){var t;const n=e.getAttribute("x"),r=e.getAttribute("y"),i=n||r?`translate(${n!=null?n:0} ${r!=null?r:0})`:"",o=(t=e.getAttribute("transform"))!=null?t:"";return i&&o?`${i} ${o}`:i||o||null}function hc(e,t,n=new Set){Array.from(t.attributes).forEach(r=>{if(!n.has(r.name)){if(r.name==="style"){Nse(e,r.value);return}if(r.name==="class"){zse(e,r.value);return}e.setAttribute(r.name,r.value)}})}function Nse(e,t){const n=e.getAttribute("style");if(!n){e.setAttribute("style",t);return}const r=n.trim().endsWith(";")?"":";";e.setAttribute("style",`${n}${r}${t}`)}function zse(e,t){const n=e.getAttribute("class");if(!n){e.setAttribute("class",t);return}e.setAttribute("class",`${n} ${t}`.trim())}const pE=/url\(\s*['"]?#([^'")\s]+)['"]?\s*\)/g;function Dse(e){const t=qse(e);if(t.size===0){mE(e);return}const n=Hse(e,t);n&&(wi(e,r=>{if(r.tagName.toLowerCase()==="defs")return!1;Array.from(r.attributes).forEach(o=>{const s=o.value;if(!s.includes("url("))return;const a=s.replace(pE,(l,c)=>{const u=encodeURIComponent(c);return`url("${n}#${u}")`});a!==s&&r.setAttribute(o.name,a)})}),mE(e))}function qse(e){const t=new Set;return wi(e,n=>{if(n.tagName.toLowerCase()==="defs")return!1;gE(n,r=>t.add(r))}),t}function gE(e,t){for(const n of Array.from(e.attributes)){const r=n.value;if(r.includes("url("))for(const i of r.matchAll(pE))i[1]&&t(i[1]);(n.name==="href"||n.name==="xlink:href")&&r[0]==="#"&&t(r.slice(1))}}function Hse(e,t){if(t.size===0)return null;const n=jse(e,t);if(n.size===0)return null;const r=Me("svg",{xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink"}),i=Me("defs");if(n.forEach(s=>{i.appendChild(s.cloneNode(!0))}),!i.children.length)return null;r.appendChild(i);const o=new XMLSerializer().serializeToString(r);return"data:image/svg+xml;charset=utf-8,"+encodeURIComponent(o)}function jse(e,t){const n=new Map,r=Array.from(t),i=new Set(r),o=new Set,s=a=>{o.has(a)||i.has(a)||(r.push(a),i.add(a))};for(;r.length;){const a=r.shift();if(o.has(a))continue;o.add(a);const l=`#${Fse(a)}`,c=e.querySelector(l);c&&(n.set(a,c),wi(c,u=>{gE(u,s)}))}return n}function Fse(e){return globalThis.CSS&&typeof globalThis.CSS.escape=="function"?globalThis.CSS.escape(e):e.replace(/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g,"\\$1")}function mE(e){Array.from(e.querySelectorAll("defs")).forEach(n=>n.remove())}function Bse(e){Wse(e),Vse(e),Gse(e),Yse(e)}function Wse(e){const t=xi(e,Ge.BtnsGroup);t==null||t.remove();const n=xi(e,"btn-icon-defs");n==null||n.remove()}function Vse(e){const t=e.querySelector("[data-element-type=transient-container]");t==null||t.remove()}function Gse(e){e.querySelectorAll("g").forEach(n=>{n.removeAttribute("x"),n.removeAttribute("y"),n.removeAttribute("width"),n.removeAttribute("height")})}function Yse(e){wi(e,t=>{for(const n in t.dataset)delete t.dataset[n]})}var Xse=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});function Use(e){return Xse(this,arguments,function*(t,n={}){var r;const{dpr:i=(r=globalThis.devicePixelRatio)!=null?r:2}=n,o=yield ry(t),{width:s,height:a}=fh(o);return new Promise((l,c)=>{try{const u=document.createElement("canvas");u.width=s*i,u.height=a*i;const h=u.getContext("2d");if(!h){c(new Error("Failed to get canvas context"));return}h.scale(i,i),h.imageSmoothingEnabled=!0,h.imageSmoothingQuality="high",o.setAttribute("width",String(s)),o.setAttribute("height",String(a));const f=new XMLSerializer().serializeToString(o),d="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(f),p=new Image;p.onload=function(){h.clearRect(0,0,s,a),h.drawImage(p,0,0,s,a);const g=u.toDataURL("image/png");l(g)},p.onerror=function(g){c(new Error("Image load failed: "+g))},p.src=d}catch(u){c(u)}})})}var iy={exports:{}},yE;function Kse(){return yE||(yE=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(l,c,u){this.fn=l,this.context=c,this.once=u||!1}function o(l,c,u,h,f){if(typeof u!="function")throw new TypeError("The listener must be a function");var d=new i(u,h||l,f),p=n?n+c:c;return l._events[p]?l._events[p].fn?l._events[p]=[l._events[p],d]:l._events[p].push(d):(l._events[p]=d,l._eventsCount++),l}function s(l,c){--l._eventsCount===0?l._events=new r:delete l._events[c]}function a(){this._events=new r,this._eventsCount=0}a.prototype.eventNames=function(){var c=[],u,h;if(this._eventsCount===0)return c;for(h in u=this._events)t.call(u,h)&&c.push(n?h.slice(1):h);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(u)):c},a.prototype.listeners=function(c){var u=n?n+c:c,h=this._events[u];if(!h)return[];if(h.fn)return[h.fn];for(var f=0,d=h.length,p=new Array(d);f<d;f++)p[f]=h[f].fn;return p},a.prototype.listenerCount=function(c){var u=n?n+c:c,h=this._events[u];return h?h.fn?1:h.length:0},a.prototype.emit=function(c,u,h,f,d,p){var g=n?n+c:c;if(!this._events[g])return!1;var m=this._events[g],v=arguments.length,b,_;if(m.fn){switch(m.once&&this.removeListener(c,m.fn,void 0,!0),v){case 1:return m.fn.call(m.context),!0;case 2:return m.fn.call(m.context,u),!0;case 3:return m.fn.call(m.context,u,h),!0;case 4:return m.fn.call(m.context,u,h,f),!0;case 5:return m.fn.call(m.context,u,h,f,d),!0;case 6:return m.fn.call(m.context,u,h,f,d,p),!0}for(_=1,b=new Array(v-1);_<v;_++)b[_-1]=arguments[_];m.fn.apply(m.context,b)}else{var x=m.length,w;for(_=0;_<x;_++)switch(m[_].once&&this.removeListener(c,m[_].fn,void 0,!0),v){case 1:m[_].fn.call(m[_].context);break;case 2:m[_].fn.call(m[_].context,u);break;case 3:m[_].fn.call(m[_].context,u,h);break;case 4:m[_].fn.call(m[_].context,u,h,f);break;default:if(!b)for(w=1,b=new Array(v-1);w<v;w++)b[w-1]=arguments[w];m[_].fn.apply(m[_].context,b)}}return!0},a.prototype.on=function(c,u,h){return o(this,c,u,h,!1)},a.prototype.once=function(c,u,h){return o(this,c,u,h,!0)},a.prototype.removeListener=function(c,u,h,f){var d=n?n+c:c;if(!this._events[d])return this;if(!u)return s(this,d),this;var p=this._events[d];if(p.fn)p.fn===u&&(!f||p.once)&&(!h||p.context===h)&&s(this,d);else{for(var g=0,m=[],v=p.length;g<v;g++)(p[g].fn!==u||f&&!p[g].once||h&&p[g].context!==h)&&m.push(p[g]);m.length?this._events[d]=m.length===1?m[0]:m:s(this,d)}return this},a.prototype.removeAllListeners=function(c){var u;return c?(u=n?n+c:c,this._events[u]&&s(this,u)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,e.exports=a})(iy)),iy.exports}var Zse=Kse();const Qse=I$(Zse);var fc=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class Jse{constructor(){this.undoStack=[],this.redoStack=[]}init(t){Object.assign(this,t)}execute(t){return fc(this,null,function*(){yield t.apply(this.state),this.undoStack.push(t),this.redoStack=[],this.emitHistoryChange("execute")})}executeBatch(t){return fc(this,null,function*(){if(t.length===0)return;const n=new Aie(t);yield this.execute(n)})}undo(){return fc(this,null,function*(){const t=this.undoStack.pop();t&&(yield t.undo(this.state),this.redoStack.push(t),this.emitHistoryChange("undo"))})}redo(){return fc(this,null,function*(){const t=this.redoStack.pop();t&&(yield t.apply(this.state),this.undoStack.push(t),this.emitHistoryChange("redo"))})}serialize(){return this.undoStack.map(t=>t.serialize())}clear(){this.undoStack=[],this.redoStack=[]}canUndo(){return this.undoStack.length>0}canRedo(){return this.redoStack.length>0}getHistorySize(){return this.undoStack.length}destroy(){this.clear()}emitHistoryChange(t){var n;(n=this.emitter)==null||n.emit("history:change",{type:"history:change",action:t})}}var vE=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class eae{constructor(){this.extensions=new IS,this.interactions=[],this.active=!1,this.running=null,this.concurrentInteractions=new Set,this.selection=new Set,this.handleClick=t=>{const n=this.editor.getDocument(),r=t.target;if(!r){this.deactivate();return}n.contains(r)||cH(r)?this.activate():this.deactivate()}}init(t){Object.assign(this,t),document.addEventListener("click",this.handleClick),this.interactions.forEach(n=>{this.extensions.register(n.name,n),n.init({emitter:this.emitter,editor:this.editor,commander:this.commander,state:this.state,interaction:this}),this.emitter.emit("interaction:registered",n)})}isActive(){return this.active}select(t,n){const r=this.getSelection(),i=[],o=[];if(n==="replace"){const l=new Set(t);r.forEach(c=>{l.has(c)||o.push(c)}),t.forEach(c=>{this.selection.has(c)||i.push(c)}),this.selection=l}else n==="add"?t.forEach(l=>{this.selection.has(l)||(this.selection.add(l),i.push(l))}):n==="remove"?t.forEach(l=>{this.selection.delete(l)&&o.push(l)}):n==="toggle"&&t.forEach(l=>{this.selection.has(l)?(this.selection.delete(l),o.push(l)):(this.selection.add(l),i.push(l))});const s=this.getSelection(),a={type:"selection:change",previous:r,next:s,added:i,removed:o,mode:n};this.emitter.emit("selection:change",a)}getSelection(){return[...this.selection]}isSelected(t){return this.selection.has(t)}clearSelection(){const t=this.getSelection();this.selection.clear();const n={type:"selection:change",previous:t,next:[],added:[],removed:t,mode:"replace"};this.emitter.emit("selection:change",n)}activate(){this.active=!0,this.emitter.emit("activated")}deactivate(){this.active=!1,this.running=null,this.clearSelection(),this.emitter.emit("deactivated")}executeExclusiveInteraction(t,n){return vE(this,null,function*(){if(!(!this.active||this.running)){this.running=t;try{this.emitter.emit("interaction:started",t),yield n(),this.emitter.emit("interaction:ended",t)}catch(r){console.error(`Error occurred during exclusive interaction "${t.name}":`,r),this.emitter.emit("interaction:error",t,r)}finally{this.running=null}}})}executeConcurrentInteraction(t,n){return vE(this,null,function*(){if(this.active){this.concurrentInteractions.add(t);try{this.emitter.emit("interaction:started",t),yield n(),this.emitter.emit("interaction:ended",t)}catch(r){console.error(`Error occurred during concurrent interaction "${t.name}":`,r),this.emitter.emit("interaction:error",t,r)}finally{this.concurrentInteractions.delete(t)}}})}getOrCreateTransientContainer(){const t="transient-container",n=this.editor.getDocument(),r=xi(n,t);if(r&&r.isConnected)return r;const i=Me("g");return xo(i,t),n.appendChild(i),i}appendTransientElement(t){return this.getOrCreateTransientContainer().appendChild(t),t}destroy(){this.extensions.forEach(t=>{t.destroy(),this.emitter.emit("interaction:destroyed",t)}),this.extensions.destroy(),this.active=!1,this.running=null,this.clearSelection(),document.removeEventListener("click",this.handleClick),this.getOrCreateTransientContainer().remove()}}class tae{constructor(){this.extensions=new IS}init(t,n=[]){Object.assign(this,t),n.forEach(r=>{this.registerPlugin(r)})}getPlugin(t){return this.extensions.get(t)}getPlugins(){return this.extensions.getAll()}registerPlugin(t){this.extensions.register(t.name,t);const n={emitter:this.emitter,editor:this.editor,commander:this.commander,plugin:this,state:this.state};t.init(n),this.emitter.emit("plugin:registered",t)}unregisterPlugin(t){const n=this.extensions.get(t);n&&(n.destroy(),this.extensions.unregister(t),this.emitter.emit("plugin:unregistered",n))}destroy(){this.extensions.getAll().forEach(t=>{this.unregisterPlugin(t.name),this.emitter.emit("plugin:destroyed",t)}),this.extensions.destroy()}}var nae=Object.defineProperty,bE=Object.getOwnPropertySymbols,rae=Object.prototype.hasOwnProperty,iae=Object.prototype.propertyIsEnumerable,_E=(e,t,n)=>t in e?nae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wE=(e,t)=>{for(var n in t||(t={}))rae.call(t,n)&&_E(e,n,t[n]);if(bE)for(var n of bE(t))iae.call(t,n)&&_E(e,n,t[n]);return e};class oae{init(t){Object.assign(this,t)}addItemDatum(t,n){const r=t.slice(0,-1),i=t[t.length-1],o=Array.isArray(n)?n:[n];$S(this.options.data,r).splice(i,0,...o),this.emitter.emit("options:data:item:add",{indexes:t,datum:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"add",path:"data.items",indexes:t,value:o}]})}updateItemDatum(t,n){const r=uo(this.options.data,t);Object.assign(r,n),this.emitter.emit("options:data:item:update",{indexes:t,datum:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:"data.items",indexes:t,value:n}]})}removeItemDatum(t,n=1){const r=t.slice(0,-1),i=t[t.length-1],s=$S(this.options.data,r).splice(i,n);this.emitter.emit("options:data:item:remove",{indexes:t,datum:s}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"remove",path:"data.items",indexes:t,value:s}]})}updateData(t,n){this.options.data[t]=n,this.emitter.emit("options:data:update",{key:t,value:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:`data.${t}`,value:n}]})}updateElement(t,n){this.updateBuiltInElement(t,n)}updateOptions(t){this.options=wE(wE({},this.options),t),this.options.padding!==void 0&&z_(this.editor.getDocument(),Lr(this.options.padding)),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",path:"",value:t}]})}getOptions(){return this.options}updateBuiltInElement(t,n){var r,i;const{data:o}=this.options,{attributes:s={}}=n,a=sh(t),l=fr(t)||Ge.ItemLabel===a||Ge.ItemDesc===a||Ge.ItemValue===a||Ge.ItemIllus===a,c=l?ES(t):void 0;if(l){const u=uo(o,c),h=a.replace("item-","");u.attributes||(u.attributes={}),(r=u.attributes)[h]||(r[h]={}),Object.assign(u.attributes[h],s)}else(Ge.Title===a||Ge.Desc===a||Ge.Illus===a)&&(o.attributes||(o.attributes={}),(i=o.attributes)[a]||(i[a]={}),Object.assign(o.attributes[a],s));this.emitter.emit("options:element:update",{element:t,props:n}),this.emitter.emit("options:change",{type:"options:change",changes:[{op:"update",role:a,indexes:c,path:l?`${_ie(c)}.attributes.${a.replace("item-","")}`:`data.attributes.${a}`,value:n}]})}destroy(){}}class sae{constructor(t,n,r){if(this.emitter=t,this.document=n,this.options=r,!n.isConnected)throw new Error("The provided document is not connected to the DOM.");n.style.userSelect="none";const i=new Jse,o=new oae,s=new tae,a=new eae;i.init({state:o,emitter:t}),o.init({emitter:t,editor:this,commander:i,options:r}),s.init({emitter:t,editor:this,commander:i,state:o},r.plugins),a.init({emitter:t,editor:this,commander:i,state:o,interactions:r.interactions}),this.commander=i,this.state=o,this.plugin=s,this.interaction=a}getDocument(){return this.document}destroy(){this.document.style.userSelect="",this.interaction.destroy(),this.plugin.destroy(),this.commander.destroy(),this.state.destroy()}}var aae=Object.defineProperty,lae=Object.defineProperties,cae=Object.getOwnPropertyDescriptors,dc=Object.getOwnPropertySymbols,xE=Object.prototype.hasOwnProperty,CE=Object.prototype.propertyIsEnumerable,PE=(e,t,n)=>t in e?aae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,un=(e,t)=>{for(var n in t||(t={}))xE.call(t,n)&&PE(e,n,t[n]);if(dc)for(var n of dc(t))CE.call(t,n)&&PE(e,n,t[n]);return e},Bi=(e,t)=>lae(e,cae(t)),Wi=(e,t)=>{var n={};for(var r in e)xE.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dc)for(var r of dc(e))t.indexOf(r)<0&&CE.call(e,r)&&(n[r]=e[r]);return n};function uae(e){const t=e,{container:n="#container",padding:r=0,template:i,design:o,theme:s,themeConfig:a,data:l}=t,c=Wi(t,["container","padding","template","design","theme","themeConfig","data"]),u=typeof n=="string"?document.querySelector(n)||document.createElement("div"):n,h=i?Xi(i):void 0,f=cb({},h==null?void 0:h.themeConfig,a),d=s||a||h!=null&&h.themeConfig?gae(s,f):void 0,p={container:u,padding:Lr(r)};if(h){const m=h,{design:v}=m,b=Wi(m,["design"]);Object.assign(p,b)}Object.assign(p,c);const g=hae(l,e.template);if(g&&(p.data=g),i&&(p.template=i),h!=null&&h.design||o){const m=Bi(un({},d?Bi(un({},e),{themeConfig:d}):e),{data:g||l}),v=fae(un(un({},h==null?void 0:h.design),o),m);ub(v)&&(p.design=v)}return s&&(p.theme=s),d&&(p.themeConfig=d),p}function hae(e,t){if(!e)return;if(Array.isArray(e.items)&&e.items.length)return e;const{lists:n,sequences:r,compares:i,nodes:o,values:s,root:a}=e,l=()=>{if(!t)return null;const h={list:n,sequence:r,compare:i,relation:o,chart:s,hierarchy:a?[a]:[]},f=t.split("-")[0],d=h[f];return d!=null&&d.length?d:null},c=()=>{var h;return n!=null&&n.length?n:r!=null&&r.length?r:i!=null&&i.length?i:o!=null&&o.length?o:s!=null&&s.length?s:a?[a]:(h=e.items)!=null&&h.length?e.items:[]};let u=l()||c();return u===r&&e.order==="desc"&&(u=[...u].reverse()),Bi(un({},e),{items:u})}function oy(e){if(typeof e=="string")return{type:e};if(!("type"in e))throw new Error("Type is required");return e}function fae(e,t){const{structure:n,title:r,item:i,items:o}=e||{},s=OE(i||(o==null?void 0:o[0]),t);return{structure:dae(n),title:pae(r,t),item:s,items:o?o.map(a=>OE(a,t)):[s]}}function dae(e){if(!e)return null;const t=oy(e),{type:n}=t,r=Wi(t,["type"]),i=F4(n);if(!i)return null;const{component:o}=i;return Bi(un({},i),{component:s=>o(un(un({},s),r))})}function pae(e,t){if(!e)return{component:null};const n=oy(e),{type:r}=n,i=Wi(n,["type"]),{themeConfig:o}=t,s=(o==null?void 0:o.colorBg)||"#fff",a=SE(s,s);return{component:l=>Ww(un(Bi(un({},l),{themeColors:a}),i))}}function OE(e,t){if(!e)return null;const n=oy(e),{type:r}=n,i=Wi(n,["type"]),o=Jw(r);if(!o)return null;const{component:s,options:a}=o;return Bi(un({},o),{component:l=>{var c;const{indexes:u}=l,{data:h,themeConfig:f}=t,d=(f==null?void 0:f.colorBg)||"#fff",p=l,{themeColors:g=SE(Vs(f==null?void 0:f.palette,u,(c=h==null?void 0:h.items)==null?void 0:c.length)||(f==null?void 0:f.colorPrimary)||"#FF356A",d)}=p,m=Wi(p,["themeColors"]);return s(un(un({themeColors:g},m),i))},options:a})}function gae(e,t={}){var n;const r=e?Vw(e)||{}:{},i=cb({},r,t);return i.palette=t.palette||r.palette,i.stylize=(n=t.stylize)!=null?n:r.stylize,i.colorPrimary||(i.colorPrimary="#FF356A"),i.palette||(i.palette=[i.colorPrimary]),i}function SE(e,t="#fff"){return Xw({colorPrimary:e,isDarkMode:H2(t),colorBg:t})}function mae(e){return e===" "||e===" "}function yae(e){let t=0,n=0;for(;n<e.length;){const r=e[n];if(r===" "){t+=1,n+=1;continue}if(r===" "){t+=2,n+=1;continue}break}return{indent:t,content:e.slice(n)}}function vae(e){return e.trimEnd()}function bae(e){return/[<>=o.x-]{2,}/.test(e)}function $E(e){const t=e.trim();if(!t)return null;const n=t.match(/^([^:\s=]+)\s*[:=]\s*(.*)$/);if(n)return{key:n[1],value:n[2].trim()};const r=t.match(/^([^\s]+)\s+(.*)$/);return r?{key:r[1],value:r[2].trim()}:{key:t,value:void 0}}function pc(e,t){return{kind:"object",line:e,value:t,entries:{}}}function EE(e){return{kind:"array",line:e,items:[]}}function _ae(e){const t=[],n=pc(0),r=[{indent:-1,node:n,parent:null,key:null}];return e.split(/\r?\n/).forEach((o,s)=>{const a=s+1;if(!o.trim())return;const{indent:l,content:c}=yae(o),u=vae(c);if(!u.trim())return;for(;r.length>1&&l<=r[r.length-1].indent;)r.pop();const h=r[r.length-1];let f=h.node;const d=u.trim();if(d.startsWith("-")&&(d.length===1||mae(d[1]))){if(f.kind!=="array")if(f.kind==="object"&&Object.keys(f.entries).length===0&&f.value===void 0&&h.parent&&h.key){const b=EE(f.line);if(h.parent.kind==="object")h.parent.entries[h.key]=b;else if(h.parent.kind==="array"){const _=h.parent.items.indexOf(f);_>=0&&(h.parent.items[_]=b)}h.node=b,f=b}else{t.push({path:"",line:a,code:"bad_list",message:"List item is not under an array container.",raw:d});return}const m=d.slice(1).trim(),v=pc(a,m||void 0);f.items.push(v),r.push({indent:l,node:v,parent:f});return}if(h.key==="relations"&&!d.startsWith("-")&&bae(d)){if(f.kind!=="array")if(f.kind==="object"&&Object.keys(f.entries).length===0&&f.value===void 0&&h.parent&&h.key){const v=EE(f.line);if(h.parent.kind==="object")h.parent.entries[h.key]=v;else if(h.parent.kind==="array"){const b=h.parent.items.indexOf(f);b>=0&&(h.parent.items[b]=v)}h.node=v,f=v}else{t.push({path:"",line:a,code:"bad_list",message:"List item is not under an array container.",raw:d});return}const m=pc(a,d);f.items.push(m),r.push({indent:l,node:m,parent:f});return}const p=$E(d);if(!p){t.push({path:"",line:a,code:"bad_syntax",message:"Invalid syntax line.",raw:d});return}if(f.kind!=="object"){t.push({path:"",line:a,code:"bad_syntax",message:"Key-value pair is not under an object container.",raw:d});return}const g=pc(a,p.value);f.entries[p.key]=g,r.push({indent:l,node:g,parent:f,key:p.key})}),{ast:n,errors:t}}function ME(e){return $E(e)}function gc(e,t){return{kind:"value",line:t,value:e}}const wae=/^(#[0-9a-f]{8}|#[0-9a-f]{6}|#[0-9a-f]{4}|#[0-9a-f]{3})/i,xae=/^((?:rgb|rgba|hsl|hsla)\([^)]*\))/i;function ni(e){const t=e.trim();return t==="true"?!0:t==="false"?!1:/^-?\d+(\.\d+)?$/.test(t)?parseFloat(t):t}function ri(e){if(e.kind==="value"||e.kind==="object")return e.value}function Ht(e,t,n,r,i,o){e.push({path:n,line:t.line,code:r,message:i,raw:o})}function IE(e,t="any"){let n=e.trim();if(n.startsWith("[")&&n.endsWith("]")&&(n=n.slice(1,-1).trim()),!n)return[];let r;t==="comma"?r=n.split(","):t==="space"?r=n.split(/\s+/):r=n.split(/[,\s]+/);const i=[];for(const o of r){const s=o.trim();if(s){if(s==="#"||s==="//")break;i.push(s)}}return i}function Cae(e){let t=e.trim();const n=t.search(/\s+#(?![0-9a-f])/i);n>=0&&(t=t.slice(0,n).trimEnd());const r=t.indexOf("//");return r>=0&&(t=t.slice(0,r).trimEnd()),t}function sy(e){const t=Cae(e);if(!t)return;const n=t.match(wae);if(n&&n[0].length===t.length)return t;const r=t.match(xae);if(r&&r[1].length===t.length||be(t).isValid())return t}function AE(e,t,n,r={}){const i=ri(e);if(i===void 0){Ht(n,e,t,"schema_mismatch","Expected color value.");return}const o=sy(i);if(!o){r.soft||Ht(n,e,t,"invalid_value","Invalid color value.",i);return}return o}function Pae(e,t){return t.length>1||e.startsWith("[")&&e.endsWith("]")?!0:sy(e)!==void 0}function ay(e){if(e.kind==="array")return e.items.map(r=>ay(r));if(e.kind==="value"||!(Object.keys(e.entries).length>0)&&e.value!==void 0)return ni(e.value);const n={};return e.value!==void 0&&(n.value=ni(e.value)),Object.entries(e.entries).forEach(([r,i])=>{n[r]=ay(i)}),n}function Oae(e,t,n,r){let i,o=null;for(const s of t.variants){const a=[],l=sn(e,s,n,a);(o===null||a.length<o.length)&&(o=a,i=l)}return o&&r.push(...o),i}function sn(e,t,n,r){switch(t.kind){case"union":return Oae(e,t,n,r);case"string":{const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected string value.");return}return i}case"number":{const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected number value.");return}const s=i.trim().match(/^(-?\d+(\.\d+)?)(?:\s*(#|\/\/).*)?$/);if(!s){Ht(r,e,n,"invalid_value","Invalid number value.",i);return}return parseFloat(s[1])}case"boolean":{const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected boolean value.");return}if(i!=="true"&&i!=="false"){Ht(r,e,n,"invalid_value","Invalid boolean value.",i);return}return i==="true"}case"enum":{const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected enum value.");return}if(!t.values.includes(i)){Ht(r,e,n,"invalid_value","Invalid enum value.",i);return}return i}case"array":{if(e.kind==="array")return e.items.map((a,l)=>sn(a,t.item,`${n}[${l}]`,r)).filter(a=>a!==void 0);if(e.kind==="object"&&Object.keys(e.entries).length>0){Ht(r,e,n,"schema_mismatch","Expected array value.");return}const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected array value.");return}const o=i.trim();return o.startsWith("[")&&!o.endsWith("]")?void 0:IE(i,t.split).map((a,l)=>sn(gc(a,e.line),t.item,`${n}[${l}]`,r)).filter(a=>a!==void 0)}case"palette":{if(e.kind==="array"){const l=sn(e,{kind:"array",item:{kind:"color"},split:"any"},n,r);return Array.isArray(l)&&l.length>0?l:void 0}if(e.kind==="object"&&Object.keys(e.entries).length>0){Ht(r,e,n,"schema_mismatch","Expected palette value.");return}const i=ri(e);if(i===void 0){Ht(r,e,n,"schema_mismatch","Expected palette value.");return}const o=i.trim();if(o.startsWith("[")&&!o.endsWith("]"))return;const s=sy(o);if(s)return[s];const a=IE(i,"any");if(Pae(o,a)){const l=a.map((c,u)=>AE(gc(c,e.line),`${n}[${u}]`,r)).filter(c=>c!==void 0);return l.length>0?l:void 0}return i}case"color":return AE(e,n,r,{soft:t.soft});case"object":{if(e.kind==="array"){Ht(r,e,n,"schema_mismatch","Expected object value.");return}const i={};if(e.kind==="value"){if(t.shorthandKey)return i[t.shorthandKey]=e.value,i;const o=ME(e.value);if((o==null?void 0:o.value)!==void 0){if(t.fields[o.key]){const s=sn(gc(o.value,e.line),t.fields[o.key],`${n}.${o.key}`,r);return s!==void 0&&(i[o.key]=s),i}return t.allowUnknown?(i[o.key]=ni(o.value),i):(Ht(r,e,`${n}.${o.key}`,"unknown_key","Unknown key in object.",o.key),i)}if(t.allowUnknown)return i.value=ni(e.value),i;Ht(r,e,n,"invalid_value","Expected object value.");return}if(e.value!==void 0)if(t.shorthandKey&&i[t.shorthandKey]===void 0)i[t.shorthandKey]=e.value;else{const o=ME(e.value);if((o==null?void 0:o.value)!==void 0)if(t.fields[o.key]){const s=sn(gc(o.value,e.line),t.fields[o.key],`${n}.${o.key}`,r);s!==void 0&&i[o.key]===void 0&&(i[o.key]=s)}else t.allowUnknown?i[o.key]=ni(o.value):Ht(r,e,`${n}.${o.key}`,"unknown_key","Unknown key in object.",o.key);else t.allowUnknown&&(i.value=ni(e.value))}return Object.entries(e.entries).forEach(([o,s])=>{const a=t.fields[o];if(!a){if(t.allowUnknown){i[o]=ay(s);return}Ht(r,s,`${n}.${o}`,"unknown_key","Unknown key in object.",o);return}const l=sn(s,a,`${n}.${o}`,r);l!==void 0&&(i[o]=l)}),i}default:return}}const Lt=()=>({kind:"string"}),br=()=>({kind:"number"}),cs=e=>({kind:"enum",values:e}),Vi=(e={})=>({kind:"color",soft:e.soft}),er=(e,t="any")=>({kind:"array",item:e,split:t}),Bt=(e,t={})=>({kind:"object",fields:e,allowUnknown:t.allowUnknown,shorthandKey:t.shorthandKey}),us=(...e)=>({kind:"union",variants:e}),Sae=()=>({kind:"palette"}),hs=()=>Bt({},{allowUnknown:!0}),TE={fill:Vi({soft:!0}),stroke:Vi({soft:!0})},Gi=Bt(TE,{allowUnknown:!0}),ly=Bt(TE,{allowUnknown:!0}),tr=Bt({},{allowUnknown:!0});tr.fields={id:Lt(),label:Lt(),value:us(br(),Lt()),desc:Lt(),icon:us(Lt(),hs()),illus:us(Lt(),hs()),attributes:hs(),group:Lt(),category:Lt(),children:er(tr)};const RE=Bt({id:Lt(),from:Lt(),to:Lt(),label:Lt(),direction:cs(["forward","both","none"]),showArrow:cs(["true","false"]),arrowType:cs(["arrow","triangle","diamond"])},{allowUnknown:!0}),kE=Bt({type:Lt(),colorBg:Vi(),colorPrimary:Vi(),palette:Sae(),title:Gi,desc:Gi,shape:ly,base:Bt({global:Bt({},{allowUnknown:!0}),shape:ly,text:Gi}),item:Bt({icon:Bt({},{allowUnknown:!0}),label:Gi,desc:Gi,value:Gi,shape:ly}),stylize:Bt({type:cs(["rough","pattern"]),roughness:br(),bowing:br(),fillWeight:br(),hachureGap:br(),pattern:Lt(),backgroundColor:Vi(),foregroundColor:Vi(),scale:br()},{shorthandKey:"type"}),elements:Bt({},{allowUnknown:!0})},{shorthandKey:"type"}),mc=Bt({},{allowUnknown:!0,shorthandKey:"type"}),LE=Bt({structure:mc,item:mc,items:er(mc),title:mc}),NE=Bt({title:Lt(),desc:Lt(),items:er(tr),lists:er(tr),sequences:er(tr),root:tr,compares:er(tr),nodes:er(tr),relations:er(RE),values:er(tr),order:cs(["asc","desc"]),illus:hs(),attributes:hs()}),zE=Bt({type:Lt()},{shorthandKey:"type"}),DE=Bt({template:zE,design:LE,data:NE,theme:kE,width:us(br(),Lt()),height:us(br(),Lt())}),qE=/[<>=o.x-]{2,}/,yc=/[<>=o.x-]{2,}/g;function vc(e){let t=e.trim();if(!t)return"";const n=t[0],r=t[t.length-1];return(n==='"'&&r==='"'||n==="'"&&r==="'")&&(t=t.slice(1,-1)),t=t.replace(/\\(["'])/g,"$1").replace(/("|&#quot;|#quot;)/g,'"').replace(/('|'|#apos;)/g,"'"),t.trim()}function $ae(e){const t=e.trim().replace(/^[-=.ox]+/,"").trim();return vc(t)}function bc(e,t){let n=t;for(;n<e.length&&/\s/.test(e[n]);)n+=1;return n}function HE(e,t){let n=bc(e,t);if(n>=e.length)return null;const r=n;for(;n<e.length;){const s=e[n];if(/\s/.test(s)||s==="["||s==="("||s==="@"||s==="|"||s==="<"||s===">"||s==="-"&&(e[n+1]==="-"||e[n+1]===">"||e[n+1]==="<"))break;n+=1}if(n===r)return null;const i=e.slice(r,n).trim();if(!i)return null;if(e.startsWith("@{",n)){const s=e.indexOf("}",n+2);s!==-1&&(n=s+1)}n=bc(e,n);let o;if(e[n]==="["){const s=e.indexOf("]",n+1);s!==-1&&(o=vc(e.slice(n+1,s)),n=s+1)}else if(e[n]==="("){const s=e.indexOf(")",n+1);if(s!==-1){let a=e.slice(n+1,s).trim();a.startsWith("[")&&a.endsWith("]")&&(a=a.slice(1,-1).trim()),o=vc(a),n=s+1}}return{node:{id:i,label:o},nextIndex:n}}function Eae(e,t){yc.lastIndex=t;const n=yc.exec(e);if(!n)return null;const r=n[0],i=n.index,o=i+r.length;let a=$ae(e.slice(t,i))||void 0,l=r,c=o;if(c=bc(e,c),e[c]==="|"){const v=e.indexOf("|",c+1);if(v!==-1){a=vc(e.slice(c+1,v))||a,c=v+1;const _=bc(e,c);yc.lastIndex=_;const x=yc.exec(e);x&&x.index===_?(l+=x[0],c=x.index+x[0].length):c=_}}const u=l.includes("<"),h=l.includes(">"),f=l.match(/[xo]/gi)||[],d=/^[xo]/i.test(l),p=/[xo]$/i.test(l);let g="none",m=!1;return u&&h||u&&p||h&&d||d&&p?g="both":(u||h||f.length>0)&&(g="forward",m=u&&!h),{label:a,direction:g,reverse:m,nextIndex:c}}function Mae(e){const t=[],n=[],r=new Map;let i=0;const o=HE(e,i);if(!o)return{relations:t,nodes:n};let s=o.node;for(r.has(s.id)||(r.set(s.id,s),n.push(s)),i=o.nextIndex;i<e.length;){const a=Eae(e,i);if(!a)break;i=a.nextIndex;const l=HE(e,i);if(!l)break;i=l.nextIndex;let c=s.id,u=l.node.id;const h=a.direction;a.reverse&&(c=l.node.id,u=s.id);const f={from:c,to:u};a.label&&(f.label=a.label),h==="both"&&(f.direction="both"),h==="none"&&(f.direction="none"),t.push(f),r.has(s.id)||(r.set(s.id,s),n.push(s)),r.has(l.node.id)||(r.set(l.node.id,l.node),n.push(l.node)),s=l.node}return{relations:t,nodes:n}}function Iae(e,t,n,r){if(!n)return;const i=e.get(n);if(i){!i.label&&r&&(i.label=r);return}const o={id:n,label:r||n};e.set(n,o),t.push(o)}function Aae(e,t,n){const r=sn(e,RE,t,n);return!r||typeof r!="object"||typeof r.from!="string"||typeof r.to!="string"?null:r}function Tae(e,t,n){const r=[],i=[],o=new Map,s=a=>{if(!qE.test(a))return;const l=Mae(a);l.nodes.forEach(c=>{Iae(o,i,c.id,c.label)}),r.push(...l.relations)};return e.kind==="array"?e.items.forEach((a,l)=>{if(a.kind==="object"&&a.value&&Object.keys(a.entries).length===0&&qE.test(a.value)){s(a.value);return}const c=Aae(a,`${n}[${l}]`,t);c&&r.push(c)}):e.kind==="object"&&e.value&&s(e.value),{relations:r,items:i}}var Rae=Object.defineProperty,kae=Object.defineProperties,Lae=Object.getOwnPropertyDescriptors,_c=Object.getOwnPropertySymbols,jE=Object.prototype.hasOwnProperty,FE=Object.prototype.propertyIsEnumerable,BE=(e,t,n)=>t in e?Rae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WE=(e,t)=>{for(var n in t||(t={}))jE.call(t,n)&&BE(e,n,t[n]);if(_c)for(var n of _c(t))FE.call(t,n)&&BE(e,n,t[n]);return e},Nae=(e,t)=>kae(e,Lae(t)),VE=(e,t)=>{var n={};for(var r in e)jE.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&_c)for(var r of _c(e))t.indexOf(r)<0&&FE.call(e,r)&&(n[r]=e[r]);return n};function zae(e){var t;const n=new Set,r=[];for(let i=e.length-1;i>=0;i-=1){const o=e[i],s=(t=o.id)!=null?t:o.label;if(!s){r.push(o);continue}n.has(s)||(n.add(s),o.id||(o.id=s),r.push(o))}return r.reverse()}function Dae(e,t){if(!e)return;const n=sn(e,zE,"template",t);if(n){if(typeof n=="string")return n;if(typeof n=="object"&&typeof n.type=="string")return n.type}}function GE(e){var t;const{ast:n,errors:r}=_ae(e),i=[],o={},s=WE({},n.entries),a=n.entries.infographic;let l;a&&a.kind==="object"&&(a.value&&(l=a.value),Object.entries(a.entries).forEach(([v,b])=>{v in s||(s[v]=b)}));const c=new Set(["infographic","template","design","data","theme","width","height"]);Object.keys(s).forEach(v=>{c.has(v)||r.push({path:v,line:s[v].line,code:"unknown_key",message:"Unknown top-level key.",raw:v})});const u=s.template,h=Dae(u,r);h&&(o.template=h),!o.template&&l&&(o.template=l);const f=s.design;if(f){const v=sn(f,LE,"design",r);v&&(o.design=v)}const d=s.data;if(d){let v,b=d;if(d.kind==="object"){const x=d.entries,{relations:w}=x,C=VE(x,["relations"]);v=w,b=Nae(WE({},d),{entries:C})}const _=sn(b,NE,"data",r);if(_&&(o.data=_),v){const x=Tae(v,r,"data.relations");if(x.relations.length>0||x.items.length>0){const w=(t=o.data)!=null?t:{},C=Array.isArray(w.items)?w.items:[],P=zae(C),O=new Map;P.forEach($=>{$.id&&O.set($.id,$)}),x.items.forEach($=>{const S=O.get($.id);S?!S.label&&$.label&&(S.label=$.label):(P.push($),O.set($.id,$))}),w.items=P,w.relations=x.relations,o.data=w}}}const p=s.theme;if(p){const v=sn(p,kE,"theme",r);if(v&&typeof v=="object"){const b=v,{type:_}=b,x=VE(b,["type"]);typeof _=="string"&&_&&(o.theme=_),Object.keys(x).length>0&&(o.themeConfig=x)}}const g=s.width;if(g){const v=sn(g,DE.fields.width,"width",r);v!==void 0&&(o.width=v)}const m=s.height;if(m){const v=sn(m,DE.fields.height,"height",r);v!==void 0&&(o.height=v)}return{options:o,errors:r,warnings:i,ast:n}}const qae=()=>[new O$,new M$],Hae=()=>[new VS,new AS,new TS,new GS,new XS,new JS,new ZS],jae={padding:20,theme:"light",themeConfig:{palette:"antv"},get plugins(){return qae()},get interactions(){return Hae()}};var Fae=Object.defineProperty,YE=Object.getOwnPropertySymbols,Bae=Object.prototype.hasOwnProperty,Wae=Object.prototype.propertyIsEnumerable,XE=(e,t,n)=>t in e?Fae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,nr=(e,t)=>{for(var n in t||(t={}))Bae.call(t,n)&&XE(e,n,t[n]);if(YE)for(var n of YE(t))Wae.call(t,n)&&XE(e,n,t[n]);return e};function cy(e,t){const n=nr(nr({},e),t);return(e.design||t.design)&&(n.design=nr(nr({},e.design),t.design)),(e.themeConfig||t.themeConfig)&&(n.themeConfig=nr(nr({},e.themeConfig),t.themeConfig)),(e.svg||t.svg)&&(n.svg=nr(nr({},e.svg),t.svg)),n}function uy(e){const t=nr({},e);return t.data&&(t.data=ab(t.data)),t.elements&&(t.elements=ab(t.elements)),t}function UE(e){const{design:t,data:n}=e;return!(!t||!ub(t)||!n||!Array.isArray(n.items)||n.items.length<1)}var Vae=Object.defineProperty,KE=Object.getOwnPropertySymbols,Gae=Object.prototype.hasOwnProperty,Yae=Object.prototype.propertyIsEnumerable,ZE=(e,t,n)=>t in e?Vae(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Xae=(e,t)=>{for(var n in t||(t={}))Gae.call(t,n)&&ZE(e,n,t[n]);if(KE)for(var n of KE(t))Yae.call(t,n)&&ZE(e,n,t[n]);return e},Uae=(e,t,n)=>new Promise((r,i)=>{var o=l=>{try{a(n.next(l))}catch(c){i(c)}},s=l=>{try{a(n.throw(l))}catch(c){i(c)}},a=l=>l.done?r(l.value):Promise.resolve(l.value).then(o,s);a((n=n.apply(e,t)).next())});class Kae{constructor(t){this.rendered=!1,this.emitter=new Qse,this.node=null,this.initialOptions={},this.setOptions(t,"replace",!0)}getOptions(){return this.options}setOptions(t,n="replace",r=!1){const{options:i,errors:o,warnings:s}=Zae(t);r&&(this.initialOptions=i);const a=cy(n==="replace"?uy(this.initialOptions||{}):this.options||uy(this.initialOptions||{}),i);this.options=a,this.parsedOptions=uae(cy(jae,this.options)),s.length&&this.emitter.emit("warning",s),o.length&&this.emitter.emit("error",o)}render(t){t?this.setOptions(t,"replace"):!this.options&&this.initialOptions&&this.setOptions(this.initialOptions,"replace"),this.performRender()}update(t){this.setOptions(t,"merge"),this.performRender()}performRender(){var t;const n=this.parsedOptions;if(!UE(n)){this.emitter.emit("error",new Error("Incomplete options"));return}const{container:r}=this.parsedOptions,i=this.compose(n),o=new $q(n,i);this.node=o.render(),r==null||r.replaceChildren(this.node),(t=this.editor)==null||t.destroy(),this.editor=void 0,this.options.editable&&(this.editor=new sae(this.emitter,this.node,n)),this.rendered=!0,this.emitter.emit("rendered",{node:this.node,options:this.options});const s=this.node;return s&&gz(s).then(()=>{this.node===s&&this.emitter.emit("loaded",{node:s,options:this.options})}),!0}compose(t){const{design:n,data:r}=t,{title:i,item:o,items:s,structure:a}=n,{component:l,props:c}=a,u=i.component,h=o.component,f=s.map(g=>g.component),d=tw(y(l,Xae({data:r,Title:u,Item:h,Items:f,options:t},c))),p=_i(d);if(!p)throw new Error("Failed to parse SVG template");return p}getTypes(){const t=this.parsedOptions;if(!UE(t)){this.emitter.emit("error",new Error("Incomplete options"));return}const n=t.design,r=n.structure.composites||[],i=n.items.map(o=>o.composites||[]);return pH({structure:r,items:i})}toDataURL(t){return Uae(this,null,function*(){if(!this.node)throw new Error("Infographic is not rendered yet.");return(t==null?void 0:t.type)==="svg"?yield Ose(this.node,t):yield Use(this.node,t)})}on(t,n){this.emitter.on(t,n)}off(t,n){this.emitter.off(t,n)}destroy(){var t,n;(t=this.editor)==null||t.destroy(),(n=this.node)==null||n.remove(),this.node=null,this.rendered=!1,this.emitter.emit("destroyed"),this.emitter.removeAllListeners()}}function Zae(e){if(typeof e=="string"){const{options:t,errors:n,warnings:r}=GE(e);return{options:t,errors:n,warnings:r}}return{options:uy(e),errors:[],warnings:[]}}const Qae="0.2.11";W.AlignLayout=Pi,W.BadgeCard=n3,W.BrushSelect=AS,W.BtnAdd=Q,W.BtnRemove=nt,W.BtnsGroup=qe,W.CandyCardLite=o3,W.CapsuleItem=d3,W.ChartBar=B4,W.ChartColumn=W4,W.ChartLine=X4,W.ChartPie=U4,W.ChartWordCloud=t5,W.CircleNode=m3,W.CircularProgress=b3,W.ClickSelect=TS,W.CompactCard=C3,W.CompareBinaryHorizontal=h5,W.CompareHierarchyLeftRight=g5,W.CompareHierarchyRow=m5,W.DblClickEditText=VS,W.Defs=Ke,W.DoneList=S3,W.DragElement=GS,W.EditBar=O$,W.Ellipse=Ze,W.FlexLayout=ve,W.Fragment=Co,W.Gap=yt,W.Group=Y,W.HierarchyMindmap=$5,W.HierarchyStructure=M5,W.HierarchyTree=R5,W.HorizontalIconArrow=M3,W.HorizontalIconLine=k3,W.HotkeyHistory=XS,W.IconBadge=z3,W.Illus=fw,W.IndexedCard=H3,W.Infographic=Kae,W.Interaction=yr,W.ItemDesc=ft,W.ItemIcon=Ft,W.ItemIconCircle=zr,W.ItemLabel=Ve,W.ItemValue=Mo,W.ItemsGroup=ze,W.LCornerCard=B3,W.LabelText=tx,W.LetterCard=G3,W.LinedText=U3,W.ListColumn=k5,W.ListGrid=L5,W.ListPyramid=N5,W.ListRow=z5,W.ListSector=H5,W.ListWaterfall=j5,W.ListZigzagDown=G5,W.ListZigzagUp=Y5,W.Path=Ce,W.PillBadge=Q3,W.Plugin=pm,W.Polygon=Yt,W.ProgressCard=l4,W.Quadrant=y5,W.QuarterCircular=h4,W.QuarterSimpleCard=p4,W.Rect=ke,W.RelationCircle=X5,W.RelationDagreFlow=NO,W.RelationNetwork=zO,W.ResizeElement=M$,W.RibbonCard=y4,W.RoundedRectNode=_4,W.SelectHighlight=ZS,W.SequenceAscendingStairs3d=YO,W.SequenceAscendingSteps=XO,W.SequenceCircleArrows=KO,W.SequenceCircular=ZO,W.SequenceColorSnakeSteps=QO,W.SequenceFilterMesh=nS,W.SequenceFunnel=sS,W.SequenceHorizontalZigzag=aS,W.SequenceMountain=uS,W.SequencePyramid=hS,W.SequenceRoadmapVertical=dS,W.SequenceSnakeSteps=pS,W.SequenceStairsFront=gS,W.SequenceSteps=mS,W.SequenceTimeline=yS,W.SequenceZigzagPucks3d=bS,W.SequenceZigzagSteps=OS,W.ShapesGroup=Pt,W.SimpleCircleNode=C4,W.SimpleHorizontalArrow=S4,W.SimpleIllusItem=M4,W.SimpleItem=T4,W.SimpleVerticalArrow=L4,W.Text=Ne,W.Title=Ww,W.UnderlineText=D4,W.VERSION=Qae,W.VerticalIconArrow=j4,W.ZoomWheel=JS,W.cloneElement=dr,W.createFragment=RH,W.createLayout=vh,W.exportToSVG=ry,W.getCombinedBounds=Ci,W.getElementBounds=ae,W.getElementsBounds=Nr,W.getFont=Lu,W.getFonts=Nu,W.getItem=Jw,W.getItemProps=lt,W.getItems=oF,W.getPalette=Cb,W.getPaletteColor=Vs,W.getPalettes=Sz,W.getStructure=F4,W.getStructures=pZ,W.getTemplate=Xi,W.getTemplates=Cc,W.getTheme=Vw,W.getThemeColors=Et,W.getThemes=Fj,W.jsx=va,W.jsxDEV=LH,W.jsxs=kH,W.loadSVGResource=vi,W.parseSVG=_i,W.parseSyntax=GE,W.registerFont=_b,W.registerItem=ct,W.registerPalette=qu,W.registerPattern=r_,W.registerResourceLoader=Wz,W.registerStructure=We,W.registerTemplate=Jt,W.registerTheme=xh,W.renderSVG=tw,W.sequenceCylinders3d=JO,W.setDefaultFont=_z,W.setFontExtendFactor=Rq,Object.defineProperty(W,Symbol.toStringTag,{value:"Module"})}));
|
|
560
589
|
//# sourceMappingURL=infographic.min.js.map
|