@elaraai/east-ui-components 1.0.12 → 1.0.13
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/dist/collections/schematic/index.d.ts +2 -0
- package/dist/collections/schematic/index.d.ts.map +1 -1
- package/dist/collections/schematic/paint.d.ts +83 -0
- package/dist/collections/schematic/paint.d.ts.map +1 -0
- package/dist/collections/schematic/theme.d.ts +9 -0
- package/dist/collections/schematic/theme.d.ts.map +1 -0
- package/dist/index.cjs +556 -112
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +556 -112
- package/dist/index.js.map +1 -1
- package/dist/theme/slot-recipes/schematic.d.ts +1 -1
- package/dist/theme/slot-recipes/schematic.d.ts.map +1 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -3011,6 +3011,9 @@ const schematicSlotRecipe = react.defineSlotRecipe({
|
|
|
3011
3011
|
"underlay",
|
|
3012
3012
|
"zone",
|
|
3013
3013
|
"zoneLabel",
|
|
3014
|
+
"zoneShapes",
|
|
3015
|
+
"zoneShapeLabel",
|
|
3016
|
+
"footprints",
|
|
3014
3017
|
"item",
|
|
3015
3018
|
"itemHead",
|
|
3016
3019
|
"itemIcon",
|
|
@@ -3140,6 +3143,91 @@ const schematicSlotRecipe = react.defineSlotRecipe({
|
|
|
3140
3143
|
paddingX: "{spacing.1}",
|
|
3141
3144
|
whiteSpace: "nowrap"
|
|
3142
3145
|
},
|
|
3146
|
+
/* Shaped zones (polyline / polygon) stroke in SVG so curves and
|
|
3147
|
+
* diagonals aren't confined to a div bounding box. Tone → token
|
|
3148
|
+
* mapping mirrors `underlay`; data only ever names a tone. These
|
|
3149
|
+
* are annotations like the rect zones — no pointer events. */
|
|
3150
|
+
zoneShapes: {
|
|
3151
|
+
position: "absolute",
|
|
3152
|
+
inset: "0",
|
|
3153
|
+
pointerEvents: "none",
|
|
3154
|
+
overflow: "visible",
|
|
3155
|
+
"& g[data-tone=brand]": { "--schematic-tone": "{colors.brand.600}" },
|
|
3156
|
+
"& g[data-tone=ink]": { "--schematic-tone": "{colors.fg}" },
|
|
3157
|
+
"& g[data-tone=muted]": { "--schematic-tone": "{colors.border.strong}" },
|
|
3158
|
+
"& g[data-tone=success]": { "--schematic-tone": "{colors.status.ok}" },
|
|
3159
|
+
"& g[data-tone=warning]": { "--schematic-tone": "{colors.status.warn}" },
|
|
3160
|
+
"& g[data-tone=danger]": { "--schematic-tone": "{colors.status.bad}" },
|
|
3161
|
+
"& path": {
|
|
3162
|
+
stroke: "var(--schematic-tone)",
|
|
3163
|
+
fill: "none",
|
|
3164
|
+
strokeLinejoin: "round"
|
|
3165
|
+
},
|
|
3166
|
+
/* Polygon outline echoes the dashed outline-rect zone. */
|
|
3167
|
+
"& path[data-shape=polygon]": {
|
|
3168
|
+
strokeWidth: "1px",
|
|
3169
|
+
strokeDasharray: "4 3"
|
|
3170
|
+
},
|
|
3171
|
+
/* Polyline is a run / road: a thin centre-line, or a soft band
|
|
3172
|
+
* when a world-space width is set inline. */
|
|
3173
|
+
"& path[data-shape=polyline]": {
|
|
3174
|
+
strokeWidth: "1.5px",
|
|
3175
|
+
strokeLinecap: "round",
|
|
3176
|
+
opacity: "0.55"
|
|
3177
|
+
}
|
|
3178
|
+
},
|
|
3179
|
+
/* Standalone eyebrow for a shaped zone — same look as `zoneLabel`
|
|
3180
|
+
* but positioned at the bbox top-left via inline coords. */
|
|
3181
|
+
zoneShapeLabel: {
|
|
3182
|
+
position: "absolute",
|
|
3183
|
+
transform: "translateY(-50%)",
|
|
3184
|
+
marginLeft: "{spacing.2}",
|
|
3185
|
+
fontFamily: "mono",
|
|
3186
|
+
fontSize: "9px",
|
|
3187
|
+
fontWeight: "600",
|
|
3188
|
+
letterSpacing: "0.14em",
|
|
3189
|
+
lineHeight: "normal",
|
|
3190
|
+
textTransform: "uppercase",
|
|
3191
|
+
color: "fg.muted",
|
|
3192
|
+
background: "bg.panel",
|
|
3193
|
+
paddingX: "{spacing.1}",
|
|
3194
|
+
whiteSpace: "nowrap",
|
|
3195
|
+
pointerEvents: "none"
|
|
3196
|
+
},
|
|
3197
|
+
/* Item footprints — the true shape body at close zoom (semantic
|
|
3198
|
+
* zoom). The path is clickable (selects the item); the card still
|
|
3199
|
+
* renders at the anchor, so no item info is lost. */
|
|
3200
|
+
footprints: {
|
|
3201
|
+
position: "absolute",
|
|
3202
|
+
inset: "0",
|
|
3203
|
+
pointerEvents: "none",
|
|
3204
|
+
overflow: "visible",
|
|
3205
|
+
"& g[data-tone=success]": { "--schematic-tone": "{colors.status.ok}" },
|
|
3206
|
+
"& g[data-tone=warning]": { "--schematic-tone": "{colors.status.warn}" },
|
|
3207
|
+
"& g[data-tone=danger]": { "--schematic-tone": "{colors.status.bad}" },
|
|
3208
|
+
"& g[data-tone=info]": { "--schematic-tone": "{colors.brand.500}" },
|
|
3209
|
+
"& g[data-tone=neutral]": { "--schematic-tone": "{colors.fg.muted}" },
|
|
3210
|
+
"& path": {
|
|
3211
|
+
stroke: "var(--schematic-tone)",
|
|
3212
|
+
strokeWidth: "1.5px",
|
|
3213
|
+
strokeLinejoin: "round",
|
|
3214
|
+
fill: "color-mix(in oklch, var(--schematic-tone) 12%, transparent)",
|
|
3215
|
+
cursor: "pointer",
|
|
3216
|
+
pointerEvents: "visiblePainted",
|
|
3217
|
+
transition: "fill {durations.fast}"
|
|
3218
|
+
},
|
|
3219
|
+
"& path[data-shape=polyline]": {
|
|
3220
|
+
fill: "none",
|
|
3221
|
+
strokeLinecap: "round"
|
|
3222
|
+
},
|
|
3223
|
+
"& g:hover path": {
|
|
3224
|
+
fill: "color-mix(in oklch, var(--schematic-tone) 20%, transparent)"
|
|
3225
|
+
},
|
|
3226
|
+
"& g[data-selected] path": {
|
|
3227
|
+
strokeWidth: "2.5px",
|
|
3228
|
+
fill: "color-mix(in oklch, var(--schematic-tone) 24%, transparent)"
|
|
3229
|
+
}
|
|
3230
|
+
},
|
|
3143
3231
|
/* LOD tiers — constant screen-size markers over scaled geometry.
|
|
3144
3232
|
* Items are the content layer: the darkest marks on the canvas at
|
|
3145
3233
|
* every tier. */
|
|
@@ -9439,7 +9527,7 @@ function transformForCss(_ref2) {
|
|
|
9439
9527
|
return val;
|
|
9440
9528
|
}
|
|
9441
9529
|
var baseStyles = ":root, :host {\n --fa-font-solid: normal 900 1em/1 'Font Awesome 7 Free';\n --fa-font-regular: normal 400 1em/1 'Font Awesome 7 Free';\n --fa-font-light: normal 300 1em/1 'Font Awesome 7 Pro';\n --fa-font-thin: normal 100 1em/1 'Font Awesome 7 Pro';\n --fa-font-duotone: normal 900 1em/1 'Font Awesome 7 Duotone';\n --fa-font-duotone-regular: normal 400 1em/1 'Font Awesome 7 Duotone';\n --fa-font-duotone-light: normal 300 1em/1 'Font Awesome 7 Duotone';\n --fa-font-duotone-thin: normal 100 1em/1 'Font Awesome 7 Duotone';\n --fa-font-brands: normal 400 1em/1 'Font Awesome 7 Brands';\n --fa-font-sharp-solid: normal 900 1em/1 'Font Awesome 7 Sharp';\n --fa-font-sharp-regular: normal 400 1em/1 'Font Awesome 7 Sharp';\n --fa-font-sharp-light: normal 300 1em/1 'Font Awesome 7 Sharp';\n --fa-font-sharp-thin: normal 100 1em/1 'Font Awesome 7 Sharp';\n --fa-font-sharp-duotone-solid: normal 900 1em/1 'Font Awesome 7 Sharp Duotone';\n --fa-font-sharp-duotone-regular: normal 400 1em/1 'Font Awesome 7 Sharp Duotone';\n --fa-font-sharp-duotone-light: normal 300 1em/1 'Font Awesome 7 Sharp Duotone';\n --fa-font-sharp-duotone-thin: normal 100 1em/1 'Font Awesome 7 Sharp Duotone';\n --fa-font-slab-regular: normal 400 1em/1 'Font Awesome 7 Slab';\n --fa-font-slab-press-regular: normal 400 1em/1 'Font Awesome 7 Slab Press';\n --fa-font-whiteboard-semibold: normal 600 1em/1 'Font Awesome 7 Whiteboard';\n --fa-font-thumbprint-light: normal 300 1em/1 'Font Awesome 7 Thumbprint';\n --fa-font-notdog-solid: normal 900 1em/1 'Font Awesome 7 Notdog';\n --fa-font-notdog-duo-solid: normal 900 1em/1 'Font Awesome 7 Notdog Duo';\n --fa-font-etch-solid: normal 900 1em/1 'Font Awesome 7 Etch';\n --fa-font-graphite-thin: normal 100 1em/1 'Font Awesome 7 Graphite';\n --fa-font-jelly-regular: normal 400 1em/1 'Font Awesome 7 Jelly';\n --fa-font-jelly-fill-regular: normal 400 1em/1 'Font Awesome 7 Jelly Fill';\n --fa-font-jelly-duo-regular: normal 400 1em/1 'Font Awesome 7 Jelly Duo';\n --fa-font-chisel-regular: normal 400 1em/1 'Font Awesome 7 Chisel';\n --fa-font-utility-semibold: normal 600 1em/1 'Font Awesome 7 Utility';\n --fa-font-utility-duo-semibold: normal 600 1em/1 'Font Awesome 7 Utility Duo';\n --fa-font-utility-fill-semibold: normal 600 1em/1 'Font Awesome 7 Utility Fill';\n}\n\n.svg-inline--fa {\n box-sizing: content-box;\n display: var(--fa-display, inline-block);\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.svg-inline--fa.fa-2xs {\n vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n vertical-align: -0.0714285714em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left,\n.svg-inline--fa .fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-pull-right,\n.svg-inline--fa .fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n.svg-inline--fa.fa-li {\n width: var(--fa-li-width, 2em);\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n inset-block-start: 0.25em; /* syncing vertical alignment with Web Font rendering */\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: var(--fa-width, 1.25em);\n}\n.fa-layers .svg-inline--fa {\n inset: 0;\n margin: auto;\n position: absolute;\n transform-origin: center center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: var(--fa-counter-background-color, #ff253a);\n border-radius: var(--fa-counter-border-radius, 1em);\n box-sizing: border-box;\n color: var(--fa-inverse, #fff);\n line-height: var(--fa-counter-line-height, 1);\n max-width: var(--fa-counter-max-width, 5em);\n min-width: var(--fa-counter-min-width, 1.5em);\n overflow: hidden;\n padding: var(--fa-counter-padding, 0.25em 0.5em);\n right: var(--fa-right, 0);\n text-overflow: ellipsis;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-counter-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: var(--fa-bottom, 0);\n right: var(--fa-right, 0);\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: var(--fa-bottom, 0);\n left: var(--fa-left, 0);\n right: auto;\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n top: var(--fa-top, 0);\n right: var(--fa-right, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: var(--fa-left, 0);\n right: auto;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top left;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-2xs {\n font-size: calc(10 / 16 * 1em); /* converts a 10px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 10 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 10 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-xs {\n font-size: calc(12 / 16 * 1em); /* converts a 12px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 12 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 12 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-sm {\n font-size: calc(14 / 16 * 1em); /* converts a 14px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 14 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 14 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-lg {\n font-size: calc(20 / 16 * 1em); /* converts a 20px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 20 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 20 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-xl {\n font-size: calc(24 / 16 * 1em); /* converts a 24px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 24 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 24 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-2xl {\n font-size: calc(32 / 16 * 1em); /* converts a 32px size into an em-based value that's relative to the scale's 16px base */\n line-height: calc(1 / 32 * 1em); /* sets the line-height of the icon back to that of it's parent */\n vertical-align: calc((6 / 32 - 0.375) * 1em); /* vertically centers the icon taking into account the surrounding text's descender */\n}\n\n.fa-width-auto {\n --fa-width: auto;\n}\n\n.fa-fw,\n.fa-width-fixed {\n --fa-width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-inline-start: var(--fa-li-margin, 2.5em);\n padding-inline-start: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n inset-inline-start: calc(-1 * var(--fa-li-width, 2em));\n position: absolute;\n text-align: center;\n width: var(--fa-li-width, 2em);\n line-height: inherit;\n}\n\n/* Heads Up: Bordered Icons will not be supported in the future!\n - This feature will be deprecated in the next major release of Font Awesome (v8)!\n - You may continue to use it in this version *v7), but it will not be supported in Font Awesome v8.\n*/\n/* Notes:\n* --@{v.$css-prefix}-border-width = 1/16 by default (to render as ~1px based on a 16px default font-size)\n* --@{v.$css-prefix}-border-padding =\n ** 3/16 for vertical padding (to give ~2px of vertical whitespace around an icon considering it's vertical alignment)\n ** 4/16 for horizontal padding (to give ~4px of horizontal whitespace around an icon)\n*/\n.fa-border {\n border-color: var(--fa-border-color, #eee);\n border-radius: var(--fa-border-radius, 0.1em);\n border-style: var(--fa-border-style, solid);\n border-width: var(--fa-border-width, 0.0625em);\n box-sizing: var(--fa-border-box-sizing, content-box);\n padding: var(--fa-border-padding, 0.1875em 0.25em);\n}\n\n.fa-pull-left,\n.fa-pull-start {\n float: inline-start;\n margin-inline-end: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right,\n.fa-pull-end {\n float: inline-end;\n margin-inline-start: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n animation-name: fa-beat;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n animation-name: fa-bounce;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n animation-name: fa-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n animation-name: fa-beat-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n animation-name: fa-flip;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n animation-name: fa-shake;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n animation-name: fa-spin;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 2s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n animation-name: fa-spin;\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n .fa-beat,\n .fa-bounce,\n .fa-fade,\n .fa-beat-fade,\n .fa-flip,\n .fa-pulse,\n .fa-shake,\n .fa-spin,\n .fa-spin-pulse {\n animation: none !important;\n transition: none !important;\n }\n}\n@keyframes fa-beat {\n 0%, 90% {\n transform: scale(1);\n }\n 45% {\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@keyframes fa-bounce {\n 0% {\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n transform: scale(1, 1) translateY(0);\n }\n}\n@keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@keyframes fa-flip {\n 50% {\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@keyframes fa-shake {\n 0% {\n transform: rotate(-15deg);\n }\n 4% {\n transform: rotate(15deg);\n }\n 8%, 24% {\n transform: rotate(-18deg);\n }\n 12%, 28% {\n transform: rotate(18deg);\n }\n 16% {\n transform: rotate(-22deg);\n }\n 20% {\n transform: rotate(22deg);\n }\n 32% {\n transform: rotate(-12deg);\n }\n 36% {\n transform: rotate(12deg);\n }\n 40%, 100% {\n transform: rotate(0deg);\n }\n}\n@keyframes fa-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n transform: rotate(var(--fa-rotate-angle, 0));\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.svg-inline--fa.fa-inverse {\n fill: var(--fa-inverse, #fff);\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n line-height: 2em;\n position: relative;\n vertical-align: middle;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: var(--fa-inverse, #fff);\n}\n\n.svg-inline--fa.fa-stack-1x {\n --fa-width: 1.25em;\n height: 1em;\n width: var(--fa-width);\n}\n.svg-inline--fa.fa-stack-2x {\n --fa-width: 2.5em;\n height: 2em;\n width: var(--fa-width);\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n inset: 0;\n margin: auto;\n position: absolute;\n z-index: var(--fa-stack-z-index, auto);\n}";
|
|
9442
|
-
function css() {
|
|
9530
|
+
function css$1() {
|
|
9443
9531
|
var dcp = DEFAULT_CSS_PREFIX;
|
|
9444
9532
|
var drc = DEFAULT_REPLACEMENT_CLASS;
|
|
9445
9533
|
var fp = config.cssPrefix;
|
|
@@ -9456,7 +9544,7 @@ function css() {
|
|
|
9456
9544
|
var _cssInserted = false;
|
|
9457
9545
|
function ensureCss() {
|
|
9458
9546
|
if (config.autoAddCss && !_cssInserted) {
|
|
9459
|
-
insertCss(css());
|
|
9547
|
+
insertCss(css$1());
|
|
9460
9548
|
_cssInserted = true;
|
|
9461
9549
|
}
|
|
9462
9550
|
}
|
|
@@ -9464,7 +9552,7 @@ var InjectCSS = {
|
|
|
9464
9552
|
mixout: function mixout() {
|
|
9465
9553
|
return {
|
|
9466
9554
|
dom: {
|
|
9467
|
-
css,
|
|
9555
|
+
css: css$1,
|
|
9468
9556
|
insertCss: ensureCss
|
|
9469
9557
|
}
|
|
9470
9558
|
};
|
|
@@ -61532,23 +61620,46 @@ function multiSelect(arr, left, right, n2, compare) {
|
|
|
61532
61620
|
stack.push(left, mid, mid, right);
|
|
61533
61621
|
}
|
|
61534
61622
|
}
|
|
61535
|
-
|
|
61536
|
-
|
|
61537
|
-
|
|
61538
|
-
|
|
61539
|
-
|
|
61540
|
-
|
|
61541
|
-
|
|
61542
|
-
|
|
61623
|
+
const css = (c2, a2 = 1) => a2 >= 1 ? `rgb(${c2[0]},${c2[1]},${c2[2]})` : `rgba(${c2[0]},${c2[1]},${c2[2]},${a2})`;
|
|
61624
|
+
function toneRGB(p2, tone, kind) {
|
|
61625
|
+
switch (tone) {
|
|
61626
|
+
case "brand":
|
|
61627
|
+
return p2.brand600;
|
|
61628
|
+
case "ink":
|
|
61629
|
+
return p2.fg;
|
|
61630
|
+
case "muted":
|
|
61631
|
+
return kind === "zone" ? p2.borderStrong : p2.fgMuted;
|
|
61632
|
+
case "success":
|
|
61633
|
+
return p2.statusOk;
|
|
61634
|
+
case "warning":
|
|
61635
|
+
return p2.statusWarn;
|
|
61636
|
+
case "danger":
|
|
61637
|
+
return p2.statusBad;
|
|
61638
|
+
default:
|
|
61639
|
+
return p2.fgMuted;
|
|
61640
|
+
}
|
|
61641
|
+
}
|
|
61642
|
+
function statusRGB(p2, status) {
|
|
61643
|
+
switch (status) {
|
|
61644
|
+
case "success":
|
|
61645
|
+
return p2.statusOk;
|
|
61646
|
+
case "warning":
|
|
61647
|
+
return p2.statusWarn;
|
|
61648
|
+
case "danger":
|
|
61649
|
+
return p2.statusBad;
|
|
61650
|
+
case "info":
|
|
61651
|
+
return p2.brand500;
|
|
61652
|
+
default:
|
|
61653
|
+
return p2.fgMuted;
|
|
61654
|
+
}
|
|
61655
|
+
}
|
|
61656
|
+
function statusTone$1(status) {
|
|
61543
61657
|
return status.type === "some" ? status.value.type : void 0;
|
|
61544
61658
|
}
|
|
61545
|
-
function
|
|
61546
|
-
|
|
61547
|
-
|
|
61548
|
-
|
|
61549
|
-
if (m2 * pow2 <= target) return m2 * pow2;
|
|
61550
|
-
}
|
|
61551
|
-
return pow2;
|
|
61659
|
+
function resolveTint(p2, color2, tone, fallback) {
|
|
61660
|
+
if (color2 !== void 0) return color2;
|
|
61661
|
+
if (tone !== void 0) return css(toneRGB(p2, tone, "link"));
|
|
61662
|
+
return css(fallback);
|
|
61552
61663
|
}
|
|
61553
61664
|
function orthogonalize(points) {
|
|
61554
61665
|
const out = [];
|
|
@@ -61561,26 +61672,354 @@ function orthogonalize(points) {
|
|
|
61561
61672
|
}
|
|
61562
61673
|
return out;
|
|
61563
61674
|
}
|
|
61564
|
-
function
|
|
61565
|
-
if (pts.length === 0) return
|
|
61566
|
-
|
|
61675
|
+
function traceRounded(ctx, pts, radius) {
|
|
61676
|
+
if (pts.length === 0) return;
|
|
61677
|
+
ctx.moveTo(pts[0].x, pts[0].y);
|
|
61567
61678
|
for (let i2 = 1; i2 < pts.length - 1; i2++) {
|
|
61568
61679
|
const p2 = pts[i2], a2 = pts[i2 - 1], b2 = pts[i2 + 1];
|
|
61569
61680
|
const inLen = Math.hypot(p2.x - a2.x, p2.y - a2.y);
|
|
61570
61681
|
const outLen = Math.hypot(b2.x - p2.x, b2.y - p2.y);
|
|
61571
61682
|
const r2 = Math.min(radius, inLen / 2, outLen / 2);
|
|
61572
61683
|
if (r2 < 0.5) {
|
|
61573
|
-
|
|
61684
|
+
ctx.lineTo(p2.x, p2.y);
|
|
61574
61685
|
continue;
|
|
61575
61686
|
}
|
|
61576
61687
|
const inU = { x: (p2.x - a2.x) / inLen, y: (p2.y - a2.y) / inLen };
|
|
61577
|
-
|
|
61578
|
-
|
|
61579
|
-
d2 += ` Q ${p2.x} ${p2.y} ${p2.x + outU.x * r2} ${p2.y + outU.y * r2}`;
|
|
61688
|
+
ctx.lineTo(p2.x - inU.x * r2, p2.y - inU.y * r2);
|
|
61689
|
+
ctx.quadraticCurveTo(p2.x, p2.y, p2.x + (b2.x - p2.x) / outLen * r2, p2.y + (b2.y - p2.y) / outLen * r2);
|
|
61580
61690
|
}
|
|
61581
61691
|
const last = pts[pts.length - 1];
|
|
61582
|
-
if (pts.length > 1)
|
|
61583
|
-
|
|
61692
|
+
if (pts.length > 1) ctx.lineTo(last.x, last.y);
|
|
61693
|
+
}
|
|
61694
|
+
function arcFromBulge(p1, p2, bulge) {
|
|
61695
|
+
const dx = p2.x - p1.x, dy = p2.y - p1.y;
|
|
61696
|
+
const chord = Math.hypot(dx, dy);
|
|
61697
|
+
if (Math.abs(bulge) < 1e-4 || chord < 1e-9) return null;
|
|
61698
|
+
const theta = 4 * Math.atan(bulge);
|
|
61699
|
+
const radius = Math.abs(chord / (2 * Math.sin(theta / 2)));
|
|
61700
|
+
const mx = (p1.x + p2.x) / 2, my = (p1.y + p2.y) / 2;
|
|
61701
|
+
const d2 = chord / 2 / Math.tan(theta / 2);
|
|
61702
|
+
const cx2 = mx - dy / chord * d2, cy = my + dx / chord * d2;
|
|
61703
|
+
return {
|
|
61704
|
+
cx: cx2,
|
|
61705
|
+
cy,
|
|
61706
|
+
radius,
|
|
61707
|
+
startAngle: Math.atan2(p1.y - cy, p1.x - cx2),
|
|
61708
|
+
endAngle: Math.atan2(p2.y - cy, p2.x - cx2),
|
|
61709
|
+
anticlockwise: theta < 0
|
|
61710
|
+
};
|
|
61711
|
+
}
|
|
61712
|
+
function traceBulge(ctx, p1, p2, bulge) {
|
|
61713
|
+
const arc = arcFromBulge(p1, p2, bulge);
|
|
61714
|
+
if (arc === null) {
|
|
61715
|
+
ctx.lineTo(p2.x, p2.y);
|
|
61716
|
+
return;
|
|
61717
|
+
}
|
|
61718
|
+
ctx.arc(arc.cx, arc.cy, arc.radius, arc.startAngle, arc.endAngle, arc.anticlockwise);
|
|
61719
|
+
}
|
|
61720
|
+
function traceVertices(ctx, pts, closed) {
|
|
61721
|
+
if (pts.length === 0) return;
|
|
61722
|
+
ctx.moveTo(pts[0].x, pts[0].y);
|
|
61723
|
+
for (let i2 = 1; i2 < pts.length; i2++) traceBulge(ctx, pts[i2 - 1], pts[i2], pts[i2 - 1].bulge);
|
|
61724
|
+
if (closed) {
|
|
61725
|
+
const last = pts[pts.length - 1];
|
|
61726
|
+
traceBulge(ctx, last, pts[0], last.bulge);
|
|
61727
|
+
ctx.closePath();
|
|
61728
|
+
}
|
|
61729
|
+
}
|
|
61730
|
+
function paintSchematic(input) {
|
|
61731
|
+
var _a2, _b, _c, _d;
|
|
61732
|
+
const { ctx, value, cam, width, height, visibleItems, tiers, selected, centers, palette: p2 } = input;
|
|
61733
|
+
const wx = (x2) => x2 * cam.ppu + cam.tx;
|
|
61734
|
+
const wy = (y2) => y2 * cam.ppu + cam.ty;
|
|
61735
|
+
const ppu = cam.ppu;
|
|
61736
|
+
ctx.clearRect(0, 0, width, height);
|
|
61737
|
+
ctx.lineJoin = "round";
|
|
61738
|
+
for (const zone of value.zones) {
|
|
61739
|
+
const pattern = zone.pattern;
|
|
61740
|
+
const patternTone = (pattern.value.tone.type === "some" ? pattern.value.tone.value.type : void 0) ?? "muted";
|
|
61741
|
+
const tint = resolveTint(p2, getSomeorUndefined(zone.color), (_a2 = getSomeorUndefined(zone.tone)) == null ? void 0 : _a2.type, toneRGB(p2, patternTone, "zone"));
|
|
61742
|
+
const zbg = getSomeorUndefined(zone.bg);
|
|
61743
|
+
const zFillAlpha = getSomeorUndefined(zone.fillOpacity) ?? 0.15;
|
|
61744
|
+
const zWeight = getSomeorUndefined(zone.weight);
|
|
61745
|
+
const geom = getSomeorUndefined(zone.geometry);
|
|
61746
|
+
const x2 = wx(zone.x), y2 = wy(zone.y), w2 = zone.width * ppu, h2 = zone.height * ppu;
|
|
61747
|
+
const fillShape = () => {
|
|
61748
|
+
if (zbg === void 0) return;
|
|
61749
|
+
ctx.save();
|
|
61750
|
+
ctx.globalAlpha = zFillAlpha;
|
|
61751
|
+
ctx.fillStyle = zbg;
|
|
61752
|
+
ctx.fill();
|
|
61753
|
+
ctx.restore();
|
|
61754
|
+
};
|
|
61755
|
+
if (geom !== void 0 && geom.type !== "rect") {
|
|
61756
|
+
if (geom.type === "circle") {
|
|
61757
|
+
ctx.beginPath();
|
|
61758
|
+
ctx.arc(x2 + w2 / 2, y2 + h2 / 2, geom.value.radius * ppu, 0, Math.PI * 2);
|
|
61759
|
+
fillShape();
|
|
61760
|
+
ctx.setLineDash([4, 3]);
|
|
61761
|
+
ctx.lineWidth = zWeight ?? 1;
|
|
61762
|
+
ctx.strokeStyle = tint;
|
|
61763
|
+
ctx.stroke();
|
|
61764
|
+
ctx.setLineDash([]);
|
|
61765
|
+
} else {
|
|
61766
|
+
const pts = geom.value.vertices.map((q) => ({ x: wx(q.x), y: wy(q.y), bulge: q.bulge }));
|
|
61767
|
+
if (pts.length > 0) {
|
|
61768
|
+
ctx.beginPath();
|
|
61769
|
+
if (geom.type === "polygon") {
|
|
61770
|
+
traceVertices(ctx, pts, true);
|
|
61771
|
+
fillShape();
|
|
61772
|
+
ctx.setLineDash([4, 3]);
|
|
61773
|
+
ctx.lineWidth = zWeight ?? 1;
|
|
61774
|
+
ctx.strokeStyle = tint;
|
|
61775
|
+
ctx.stroke();
|
|
61776
|
+
ctx.setLineDash([]);
|
|
61777
|
+
} else {
|
|
61778
|
+
traceVertices(ctx, pts, false);
|
|
61779
|
+
const band2 = geom.value.width.type === "some" ? geom.value.width.value * ppu : void 0;
|
|
61780
|
+
ctx.setLineDash([]);
|
|
61781
|
+
ctx.lineCap = "round";
|
|
61782
|
+
ctx.lineWidth = zWeight ?? band2 ?? 1.5;
|
|
61783
|
+
ctx.save();
|
|
61784
|
+
ctx.globalAlpha = 0.55;
|
|
61785
|
+
ctx.strokeStyle = tint;
|
|
61786
|
+
ctx.stroke();
|
|
61787
|
+
ctx.restore();
|
|
61788
|
+
ctx.lineCap = "butt";
|
|
61789
|
+
}
|
|
61790
|
+
}
|
|
61791
|
+
}
|
|
61792
|
+
} else if (pattern.type === "hatch") {
|
|
61793
|
+
const spacing = pattern.value.spacing.type === "some" ? pattern.value.spacing.value : 8;
|
|
61794
|
+
const angle = (pattern.value.angle.type === "some" ? pattern.value.angle.value : 45) * Math.PI / 180;
|
|
61795
|
+
ctx.save();
|
|
61796
|
+
ctx.beginPath();
|
|
61797
|
+
ctx.rect(x2, y2, w2, h2);
|
|
61798
|
+
ctx.clip();
|
|
61799
|
+
if (zbg !== void 0) {
|
|
61800
|
+
ctx.save();
|
|
61801
|
+
ctx.globalAlpha = zFillAlpha;
|
|
61802
|
+
ctx.fillStyle = zbg;
|
|
61803
|
+
ctx.fillRect(x2, y2, w2, h2);
|
|
61804
|
+
ctx.restore();
|
|
61805
|
+
}
|
|
61806
|
+
ctx.globalAlpha = 0.3;
|
|
61807
|
+
ctx.strokeStyle = tint;
|
|
61808
|
+
ctx.lineWidth = zWeight ?? 1;
|
|
61809
|
+
const dx = Math.cos(angle), dy = Math.sin(angle);
|
|
61810
|
+
const diag = Math.hypot(w2, h2);
|
|
61811
|
+
ctx.beginPath();
|
|
61812
|
+
for (let o2 = -diag; o2 < diag; o2 += spacing) {
|
|
61813
|
+
ctx.moveTo(x2 + o2, y2 - diag * dy);
|
|
61814
|
+
ctx.lineTo(x2 + o2 + dx * 2 * diag, y2 - diag * dy + dy * 2 * diag);
|
|
61815
|
+
}
|
|
61816
|
+
ctx.stroke();
|
|
61817
|
+
ctx.restore();
|
|
61818
|
+
} else {
|
|
61819
|
+
if (zbg !== void 0) {
|
|
61820
|
+
ctx.save();
|
|
61821
|
+
ctx.globalAlpha = zFillAlpha;
|
|
61822
|
+
ctx.fillStyle = zbg;
|
|
61823
|
+
ctx.fillRect(x2, y2, w2, h2);
|
|
61824
|
+
ctx.restore();
|
|
61825
|
+
}
|
|
61826
|
+
ctx.setLineDash([5, 4]);
|
|
61827
|
+
ctx.lineWidth = zWeight ?? 1;
|
|
61828
|
+
ctx.strokeStyle = tint;
|
|
61829
|
+
ctx.strokeRect(x2, y2, w2, h2);
|
|
61830
|
+
ctx.setLineDash([]);
|
|
61831
|
+
}
|
|
61832
|
+
if (w2 >= zone.label.length * 6.2 + 24) {
|
|
61833
|
+
ctx.font = '600 9px ui-monospace, "SF Mono", Menlo, monospace';
|
|
61834
|
+
const label = zone.label.toUpperCase();
|
|
61835
|
+
const tw = ctx.measureText(label).width;
|
|
61836
|
+
ctx.fillStyle = css(p2.bgPanel);
|
|
61837
|
+
ctx.fillRect(x2 + 6, y2 - 7, tw + 6, 12);
|
|
61838
|
+
ctx.fillStyle = css(p2.fgMuted);
|
|
61839
|
+
ctx.textBaseline = "middle";
|
|
61840
|
+
ctx.fillText(label, x2 + 9, y2);
|
|
61841
|
+
}
|
|
61842
|
+
}
|
|
61843
|
+
for (const link2 of value.links) {
|
|
61844
|
+
const from = centers.get(link2.from), to = centers.get(link2.to);
|
|
61845
|
+
if (!from || !to) continue;
|
|
61846
|
+
const anchors = [from, ...link2.via, to].map((q) => ({ x: wx(q.x), y: wy(q.y) }));
|
|
61847
|
+
const corner = link2.route.type === "orthogonal" ? link2.route.value.corner.type === "some" ? link2.route.value.corner.value : 8 : 0;
|
|
61848
|
+
const pts = link2.route.type === "orthogonal" ? orthogonalize(anchors) : anchors;
|
|
61849
|
+
const style = link2.style;
|
|
61850
|
+
const tone = (style.value.tone.type === "some" ? style.value.tone.value.type : void 0) ?? (style.type === "solid" ? "brand" : "muted");
|
|
61851
|
+
const weight = style.value.weight.type === "some" ? style.value.weight.value : style.type === "solid" ? 2.5 : 1.5;
|
|
61852
|
+
const color2 = toneRGB(p2, tone, "link");
|
|
61853
|
+
ctx.lineCap = "round";
|
|
61854
|
+
ctx.strokeStyle = css(color2);
|
|
61855
|
+
ctx.lineWidth = weight;
|
|
61856
|
+
ctx.setLineDash(style.type === "dashed" ? [6, 5] : []);
|
|
61857
|
+
ctx.beginPath();
|
|
61858
|
+
traceRounded(ctx, pts, corner);
|
|
61859
|
+
ctx.stroke();
|
|
61860
|
+
ctx.setLineDash([]);
|
|
61861
|
+
ctx.fillStyle = css(color2);
|
|
61862
|
+
for (const end3 of [anchors[0], anchors[anchors.length - 1]]) {
|
|
61863
|
+
ctx.beginPath();
|
|
61864
|
+
ctx.arc(end3.x, end3.y, weight + 1.5, 0, Math.PI * 2);
|
|
61865
|
+
ctx.fill();
|
|
61866
|
+
}
|
|
61867
|
+
ctx.lineCap = "butt";
|
|
61868
|
+
}
|
|
61869
|
+
for (const item of visibleItems) {
|
|
61870
|
+
const footprint = getSomeorUndefined(item.footprint);
|
|
61871
|
+
if (footprint === void 0 || footprint.type === "rect") continue;
|
|
61872
|
+
if ((tiers.get(item.key) ?? "dot") !== "card") continue;
|
|
61873
|
+
const isSel = selected === item.key;
|
|
61874
|
+
const tint = resolveTint(p2, getSomeorUndefined(item.color), (_b = getSomeorUndefined(item.tone)) == null ? void 0 : _b.type, statusRGB(p2, statusTone$1(item.status)));
|
|
61875
|
+
const ibg = getSomeorUndefined(item.bg);
|
|
61876
|
+
const fillAlpha = getSomeorUndefined(item.fillOpacity) ?? (isSel ? 0.24 : 0.12);
|
|
61877
|
+
const stroke = getSomeorUndefined(item.weight) ?? (isSel ? 2.5 : 1.5);
|
|
61878
|
+
const fillShape = () => {
|
|
61879
|
+
ctx.save();
|
|
61880
|
+
ctx.globalAlpha = fillAlpha;
|
|
61881
|
+
ctx.fillStyle = ibg ?? tint;
|
|
61882
|
+
ctx.fill();
|
|
61883
|
+
ctx.restore();
|
|
61884
|
+
};
|
|
61885
|
+
if (footprint.type === "circle") {
|
|
61886
|
+
ctx.beginPath();
|
|
61887
|
+
ctx.arc(wx(item.x), wy(item.y), footprint.value.radius * ppu, 0, Math.PI * 2);
|
|
61888
|
+
fillShape();
|
|
61889
|
+
ctx.lineWidth = stroke;
|
|
61890
|
+
ctx.strokeStyle = tint;
|
|
61891
|
+
ctx.stroke();
|
|
61892
|
+
continue;
|
|
61893
|
+
}
|
|
61894
|
+
const pts = footprint.value.vertices.map((q) => ({ x: wx(q.x), y: wy(q.y), bulge: q.bulge }));
|
|
61895
|
+
if (pts.length === 0) continue;
|
|
61896
|
+
ctx.beginPath();
|
|
61897
|
+
if (footprint.type === "polygon") {
|
|
61898
|
+
traceVertices(ctx, pts, true);
|
|
61899
|
+
fillShape();
|
|
61900
|
+
ctx.lineWidth = stroke;
|
|
61901
|
+
} else {
|
|
61902
|
+
traceVertices(ctx, pts, false);
|
|
61903
|
+
const band2 = footprint.value.width.type === "some" ? footprint.value.width.value * ppu : void 0;
|
|
61904
|
+
ctx.lineCap = "round";
|
|
61905
|
+
ctx.lineWidth = getSomeorUndefined(item.weight) ?? band2 ?? (isSel ? 2.5 : 1.5);
|
|
61906
|
+
}
|
|
61907
|
+
ctx.strokeStyle = tint;
|
|
61908
|
+
ctx.stroke();
|
|
61909
|
+
ctx.lineCap = "butt";
|
|
61910
|
+
}
|
|
61911
|
+
for (const item of visibleItems) {
|
|
61912
|
+
const tier = tiers.get(item.key) ?? "dot";
|
|
61913
|
+
if (tier === "card") continue;
|
|
61914
|
+
const tint = resolveTint(p2, getSomeorUndefined(item.color), (_c = getSomeorUndefined(item.tone)) == null ? void 0 : _c.type, statusRGB(p2, statusTone$1(item.status)));
|
|
61915
|
+
const isSel = selected === item.key;
|
|
61916
|
+
const x2 = wx(item.x), y2 = wy(item.y);
|
|
61917
|
+
if (tier === "dot") {
|
|
61918
|
+
ctx.beginPath();
|
|
61919
|
+
ctx.arc(x2, y2, 5, 0, Math.PI * 2);
|
|
61920
|
+
ctx.fillStyle = tint;
|
|
61921
|
+
ctx.fill();
|
|
61922
|
+
ctx.lineWidth = 1.5;
|
|
61923
|
+
ctx.strokeStyle = css(p2.white);
|
|
61924
|
+
ctx.stroke();
|
|
61925
|
+
if (isSel) {
|
|
61926
|
+
ctx.beginPath();
|
|
61927
|
+
ctx.arc(x2, y2, 7.5, 0, Math.PI * 2);
|
|
61928
|
+
ctx.lineWidth = 2;
|
|
61929
|
+
ctx.strokeStyle = css(p2.fg);
|
|
61930
|
+
ctx.stroke();
|
|
61931
|
+
}
|
|
61932
|
+
continue;
|
|
61933
|
+
}
|
|
61934
|
+
ctx.font = '600 10px ui-monospace, "SF Mono", Menlo, monospace';
|
|
61935
|
+
const tw = ctx.measureText(item.label).width;
|
|
61936
|
+
const padX = 6, dotW = 7, gap = 4, h2 = 16;
|
|
61937
|
+
const w2 = padX + dotW + gap + tw + padX;
|
|
61938
|
+
const left = x2 - w2 / 2, top = y2 - h2 / 2;
|
|
61939
|
+
ctx.beginPath();
|
|
61940
|
+
(_d = ctx.roundRect) == null ? void 0 : _d.call(ctx, left, top, w2, h2, h2 / 2);
|
|
61941
|
+
if (!ctx.roundRect) ctx.rect(left, top, w2, h2);
|
|
61942
|
+
ctx.fillStyle = css(p2.bgSurface);
|
|
61943
|
+
ctx.fill();
|
|
61944
|
+
ctx.lineWidth = 1;
|
|
61945
|
+
ctx.strokeStyle = isSel ? css(p2.fg) : css(p2.borderStrong);
|
|
61946
|
+
ctx.stroke();
|
|
61947
|
+
ctx.beginPath();
|
|
61948
|
+
ctx.arc(left + padX + dotW / 2, y2, dotW / 2, 0, Math.PI * 2);
|
|
61949
|
+
ctx.fillStyle = tint;
|
|
61950
|
+
ctx.fill();
|
|
61951
|
+
ctx.fillStyle = css(p2.fg);
|
|
61952
|
+
ctx.textBaseline = "middle";
|
|
61953
|
+
ctx.fillText(item.label, left + padX + dotW + gap, y2);
|
|
61954
|
+
}
|
|
61955
|
+
}
|
|
61956
|
+
const TOKENS = {
|
|
61957
|
+
brand600: "brand.600",
|
|
61958
|
+
brand500: "brand.500",
|
|
61959
|
+
fg: "fg",
|
|
61960
|
+
fgMuted: "fg.muted",
|
|
61961
|
+
fgSubtle: "fg.subtle",
|
|
61962
|
+
borderStrong: "border.strong",
|
|
61963
|
+
borderSubtle: "border.subtle",
|
|
61964
|
+
bgSurface: "bg.surface",
|
|
61965
|
+
bgPanel: "bg.panel",
|
|
61966
|
+
statusOk: "status.ok",
|
|
61967
|
+
statusWarn: "status.warn",
|
|
61968
|
+
statusBad: "status.bad",
|
|
61969
|
+
white: "white"
|
|
61970
|
+
};
|
|
61971
|
+
const KEYS = Object.keys(TOKENS);
|
|
61972
|
+
function parseRGB(s2) {
|
|
61973
|
+
const m2 = s2.match(/[\d.]+/g);
|
|
61974
|
+
if (m2 === null || m2.length < 3) return [0, 0, 0];
|
|
61975
|
+
return [Math.round(+m2[0]), Math.round(+m2[1]), Math.round(+m2[2])];
|
|
61976
|
+
}
|
|
61977
|
+
const SchematicPaletteProbe = React.memo(function SchematicPaletteProbe2({ onResolve }) {
|
|
61978
|
+
const ref = React.useRef(null);
|
|
61979
|
+
React.useLayoutEffect(() => {
|
|
61980
|
+
const read = () => {
|
|
61981
|
+
const el = ref.current;
|
|
61982
|
+
if (el === null) return;
|
|
61983
|
+
const kids = el.children;
|
|
61984
|
+
const palette = {};
|
|
61985
|
+
KEYS.forEach((k2, i2) => {
|
|
61986
|
+
const child = kids[i2];
|
|
61987
|
+
if (child !== void 0) palette[k2] = parseRGB(getComputedStyle(child).color);
|
|
61988
|
+
});
|
|
61989
|
+
onResolve(palette);
|
|
61990
|
+
};
|
|
61991
|
+
read();
|
|
61992
|
+
const obs = new MutationObserver(read);
|
|
61993
|
+
obs.observe(document.documentElement, { attributes: true, attributeFilter: ["class", "data-theme", "style"] });
|
|
61994
|
+
return () => obs.disconnect();
|
|
61995
|
+
}, [onResolve]);
|
|
61996
|
+
return /* @__PURE__ */ jsxRuntime.jsx(react.Box, { ref, "aria-hidden": "true", css: { position: "absolute", width: "0", height: "0", overflow: "hidden", pointerEvents: "none" }, children: KEYS.map((k2) => /* @__PURE__ */ jsxRuntime.jsx(react.Box, { color: TOKENS[k2] }, k2)) });
|
|
61997
|
+
});
|
|
61998
|
+
library$1.add(icons$2);
|
|
61999
|
+
const schematicEqual = east.equalFor(internal.Schematic.Types.Schematic);
|
|
62000
|
+
const IDENTITY = { zoom: 1, tx: 0, ty: 0 };
|
|
62001
|
+
const MAX_ZOOM = 40;
|
|
62002
|
+
const LOD_CARD_PPU = 30;
|
|
62003
|
+
const LOD_LABEL_PPU = 16;
|
|
62004
|
+
const MINIMAP_AUTO = 25;
|
|
62005
|
+
function statusTone(status) {
|
|
62006
|
+
return status.type === "some" ? status.value.type : void 0;
|
|
62007
|
+
}
|
|
62008
|
+
function niceScaleLength(ppu, targetPx) {
|
|
62009
|
+
const target = targetPx / ppu;
|
|
62010
|
+
const pow2 = Math.pow(10, Math.floor(Math.log10(target)));
|
|
62011
|
+
for (const m2 of [5, 2, 1]) {
|
|
62012
|
+
if (m2 * pow2 <= target) return m2 * pow2;
|
|
62013
|
+
}
|
|
62014
|
+
return pow2;
|
|
62015
|
+
}
|
|
62016
|
+
function pointInPolygon(x2, y2, pts) {
|
|
62017
|
+
let inside = false;
|
|
62018
|
+
for (let i2 = 0, j2 = pts.length - 1; i2 < pts.length; j2 = i2++) {
|
|
62019
|
+
const xi = pts[i2].x, yi = pts[i2].y, xj = pts[j2].x, yj = pts[j2].y;
|
|
62020
|
+
if (yi > y2 !== yj > y2 && x2 < (xj - xi) * (y2 - yi) / (yj - yi) + xi) inside = !inside;
|
|
62021
|
+
}
|
|
62022
|
+
return inside;
|
|
61584
62023
|
}
|
|
61585
62024
|
function buildNavTree(zones, items) {
|
|
61586
62025
|
const nodes = /* @__PURE__ */ new Map();
|
|
@@ -61671,13 +62110,16 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61671
62110
|
const showGrid = getSomeorUndefined(value.grid) ?? true;
|
|
61672
62111
|
const showNavigator = getSomeorUndefined(value.navigator) ?? value.zones.length > 0;
|
|
61673
62112
|
const showMinimap = getSomeorUndefined(value.minimap) ?? value.items.length >= MINIMAP_AUTO;
|
|
62113
|
+
const fixedHeight = getSomeorUndefined(value.height);
|
|
61674
62114
|
const [selected, setSelected] = React.useState(null);
|
|
61675
62115
|
const [view, setView] = React.useState(IDENTITY);
|
|
61676
62116
|
const [query, setQuery] = React.useState("");
|
|
61677
62117
|
const [openZone, setOpenZone] = React.useState(null);
|
|
61678
62118
|
const [navCollapsed, setNavCollapsed] = React.useState(false);
|
|
62119
|
+
const [palette, setPalette] = React.useState(null);
|
|
61679
62120
|
const navTreeRef = React.useRef(null);
|
|
61680
62121
|
const canvasRef = React.useRef(null);
|
|
62122
|
+
const drawRef = React.useRef(null);
|
|
61681
62123
|
const [size, setSize] = React.useState(null);
|
|
61682
62124
|
React.useLayoutEffect(() => {
|
|
61683
62125
|
const el = canvasRef.current;
|
|
@@ -61701,7 +62143,23 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61701
62143
|
const tree = new RBush();
|
|
61702
62144
|
tree.load(value.items.map((item) => {
|
|
61703
62145
|
const hw = (getSomeorUndefined(item.width) ?? 0) / 2 + 2.4;
|
|
61704
|
-
|
|
62146
|
+
let minX = item.x - hw, minY = item.y - 2, maxX = item.x + hw, maxY = item.y + 2;
|
|
62147
|
+
const fp = getSomeorUndefined(item.footprint);
|
|
62148
|
+
if (fp !== void 0 && fp.type === "circle") {
|
|
62149
|
+
const r2 = fp.value.radius;
|
|
62150
|
+
minX = Math.min(minX, item.x - r2);
|
|
62151
|
+
minY = Math.min(minY, item.y - r2);
|
|
62152
|
+
maxX = Math.max(maxX, item.x + r2);
|
|
62153
|
+
maxY = Math.max(maxY, item.y + r2);
|
|
62154
|
+
} else if (fp !== void 0 && fp.type !== "rect") {
|
|
62155
|
+
for (const v2 of fp.value.vertices) {
|
|
62156
|
+
minX = Math.min(minX, v2.x);
|
|
62157
|
+
minY = Math.min(minY, v2.y);
|
|
62158
|
+
maxX = Math.max(maxX, v2.x);
|
|
62159
|
+
maxY = Math.max(maxY, v2.y);
|
|
62160
|
+
}
|
|
62161
|
+
}
|
|
62162
|
+
return { minX, minY, maxX, maxY, item };
|
|
61705
62163
|
}));
|
|
61706
62164
|
return tree;
|
|
61707
62165
|
}, [value.items]);
|
|
@@ -61803,15 +62261,18 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61803
62261
|
return () => el.removeEventListener("wheel", onWheel);
|
|
61804
62262
|
}, []);
|
|
61805
62263
|
const panRef = React.useRef(null);
|
|
62264
|
+
const movedRef = React.useRef(false);
|
|
61806
62265
|
const onCanvasPointerDown = React.useCallback((e3) => {
|
|
61807
62266
|
if (e3.button !== 0) return;
|
|
61808
62267
|
if (e3.target.closest("button") !== null) return;
|
|
61809
62268
|
panRef.current = { x: e3.clientX, y: e3.clientY, tx: viewRef.current.tx, ty: viewRef.current.ty };
|
|
62269
|
+
movedRef.current = false;
|
|
61810
62270
|
e3.currentTarget.setPointerCapture(e3.pointerId);
|
|
61811
62271
|
}, []);
|
|
61812
62272
|
const onCanvasPointerMove = React.useCallback((e3) => {
|
|
61813
62273
|
const pan = panRef.current;
|
|
61814
62274
|
if (!pan) return;
|
|
62275
|
+
if (Math.abs(e3.clientX - pan.x) > 4 || Math.abs(e3.clientY - pan.y) > 4) movedRef.current = true;
|
|
61815
62276
|
setView((prev) => ({ ...prev, tx: pan.tx + e3.clientX - pan.x, ty: pan.ty + e3.clientY - pan.y }));
|
|
61816
62277
|
}, []);
|
|
61817
62278
|
const onCanvasPointerUp = React.useCallback(() => {
|
|
@@ -61866,6 +62327,61 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61866
62327
|
const lowerQuery = query.trim().toLowerCase();
|
|
61867
62328
|
const searchHits = React.useMemo(() => lowerQuery === "" ? [] : value.items.filter((i2) => i2.key.toLowerCase().includes(lowerQuery) || i2.label.toLowerCase().includes(lowerQuery)).slice(0, 12), [lowerQuery, value.items]);
|
|
61868
62329
|
const scaleLen = ppu > 0 ? niceScaleLength(ppu, 100) : 0;
|
|
62330
|
+
React.useEffect(() => {
|
|
62331
|
+
const canvas = drawRef.current;
|
|
62332
|
+
if (canvas === null || size === null || palette === null) return;
|
|
62333
|
+
const dpr = window.devicePixelRatio || 1;
|
|
62334
|
+
const bw = Math.round(size.w * dpr), bh = Math.round(size.h * dpr);
|
|
62335
|
+
if (canvas.width !== bw || canvas.height !== bh) {
|
|
62336
|
+
canvas.width = bw;
|
|
62337
|
+
canvas.height = bh;
|
|
62338
|
+
}
|
|
62339
|
+
const ctx = canvas.getContext("2d");
|
|
62340
|
+
if (ctx === null) return;
|
|
62341
|
+
ctx.setTransform(dpr, 0, 0, dpr, 0, 0);
|
|
62342
|
+
paintSchematic({
|
|
62343
|
+
ctx,
|
|
62344
|
+
value,
|
|
62345
|
+
cam: { ppu, tx: view.tx, ty: view.ty },
|
|
62346
|
+
width: size.w,
|
|
62347
|
+
height: size.h,
|
|
62348
|
+
visibleItems,
|
|
62349
|
+
tiers,
|
|
62350
|
+
selected,
|
|
62351
|
+
centers,
|
|
62352
|
+
palette
|
|
62353
|
+
});
|
|
62354
|
+
}, [value, view, ppu, size, visibleItems, tiers, selected, centers, palette]);
|
|
62355
|
+
const onCanvasClick = React.useCallback((e3) => {
|
|
62356
|
+
if (size === null || movedRef.current) return;
|
|
62357
|
+
const rect = e3.currentTarget.getBoundingClientRect();
|
|
62358
|
+
const sx = e3.clientX - rect.left, sy = e3.clientY - rect.top;
|
|
62359
|
+
const wxp = (sx - view.tx) / ppu, wyp = (sy - view.ty) / ppu;
|
|
62360
|
+
for (const box of index2.search({ minX: wxp, minY: wyp, maxX: wxp, maxY: wyp })) {
|
|
62361
|
+
const it = box.item;
|
|
62362
|
+
if ((tiers.get(it.key) ?? lod) !== "card") continue;
|
|
62363
|
+
const fp = getSomeorUndefined(it.footprint);
|
|
62364
|
+
if (fp === void 0 || fp.type === "rect") continue;
|
|
62365
|
+
const hit = fp.type === "circle" ? Math.hypot(wxp - it.x, wyp - it.y) <= fp.value.radius : pointInPolygon(wxp, wyp, fp.value.vertices);
|
|
62366
|
+
if (hit) {
|
|
62367
|
+
setSelected(it.key);
|
|
62368
|
+
if (onSelectFn) queueMicrotask(() => onSelectFn(it.key));
|
|
62369
|
+
return;
|
|
62370
|
+
}
|
|
62371
|
+
}
|
|
62372
|
+
let best = null, bestD = Infinity;
|
|
62373
|
+
for (const it of visibleItems) {
|
|
62374
|
+
const tier = tiers.get(it.key) ?? lod;
|
|
62375
|
+
if (tier === "card") continue;
|
|
62376
|
+
const d2 = Math.hypot(it.x * ppu + view.tx - sx, it.y * ppu + view.ty - sy);
|
|
62377
|
+
const reach = tier === "dot" ? 9 : 18;
|
|
62378
|
+
if (d2 < reach && d2 < bestD) {
|
|
62379
|
+
best = it;
|
|
62380
|
+
bestD = d2;
|
|
62381
|
+
}
|
|
62382
|
+
}
|
|
62383
|
+
if (best !== null) flyToItem(best);
|
|
62384
|
+
}, [size, view, ppu, index2, tiers, lod, visibleItems, onSelectFn, flyToItem]);
|
|
61869
62385
|
const toggleZone = React.useCallback((key) => {
|
|
61870
62386
|
setOpenZone((prev) => prev === key ? nav.parentOf.get(key) ?? null : key);
|
|
61871
62387
|
}, [nav.parentOf]);
|
|
@@ -61934,7 +62450,8 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61934
62450
|
))
|
|
61935
62451
|
] }, node2.zone.key);
|
|
61936
62452
|
};
|
|
61937
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { css: styles2.root, children: [
|
|
62453
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { css: styles2.root, ...fixedHeight !== void 0 ? { style: { height: fixedHeight, maxHeight: fixedHeight } } : {}, children: [
|
|
62454
|
+
/* @__PURE__ */ jsxRuntime.jsx(SchematicPaletteProbe, { onResolve: setPalette }),
|
|
61938
62455
|
showNavigator && navCollapsed && /* @__PURE__ */ jsxRuntime.jsx(react.Box, { css: styles2.navCollapsed, children: /* @__PURE__ */ jsxRuntime.jsx(react.Box, { as: "button", css: styles2.navToggle, "aria-label": "Expand index", title: "Show index", onClick: () => setNavCollapsed(false), children: /* @__PURE__ */ jsxRuntime.jsx(FontAwesomeIcon, { icon: faAnglesRight }) }) }),
|
|
61939
62456
|
showNavigator && !navCollapsed && /* @__PURE__ */ jsxRuntime.jsxs(react.Box, { css: styles2.nav, children: [
|
|
61940
62457
|
/* @__PURE__ */ jsxRuntime.jsxs(react.Box, { css: styles2.navHeader, children: [
|
|
@@ -61979,7 +62496,7 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
61979
62496
|
ref: canvasRef,
|
|
61980
62497
|
css: styles2.canvas,
|
|
61981
62498
|
"data-schematic-canvas": "",
|
|
61982
|
-
style: { aspectRatio: `${W2} / ${H}` },
|
|
62499
|
+
style: fixedHeight !== void 0 ? { minHeight: 0 } : { aspectRatio: `${W2} / ${H}` },
|
|
61983
62500
|
onPointerDown: onCanvasPointerDown,
|
|
61984
62501
|
onPointerMove: onCanvasPointerMove,
|
|
61985
62502
|
onPointerUp: onCanvasPointerUp,
|
|
@@ -62000,91 +62517,18 @@ const EastChakraSchematic = React.memo(function EastChakraSchematic2({ value })
|
|
|
62000
62517
|
);
|
|
62001
62518
|
})(),
|
|
62002
62519
|
size !== null && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
62003
|
-
|
|
62004
|
-
|
|
62005
|
-
|
|
62006
|
-
|
|
62007
|
-
|
|
62008
|
-
|
|
62009
|
-
}
|
|
62010
|
-
|
|
62011
|
-
react.Box,
|
|
62012
|
-
{
|
|
62013
|
-
css: styles2.zone,
|
|
62014
|
-
"data-pattern": pattern.type,
|
|
62015
|
-
"data-tone": tone,
|
|
62016
|
-
style: {
|
|
62017
|
-
left: wx(zone.x),
|
|
62018
|
-
top: wy(zone.y),
|
|
62019
|
-
width: zone.width * ppu,
|
|
62020
|
-
height: zone.height * ppu,
|
|
62021
|
-
...hatchVars
|
|
62022
|
-
},
|
|
62023
|
-
children: zone.width * ppu >= zone.label.length * 6.2 + 24 && /* @__PURE__ */ jsxRuntime.jsx(react.Box, { as: "span", css: styles2.zoneLabel, "data-pattern": pattern.type, children: zone.label })
|
|
62024
|
-
},
|
|
62025
|
-
zone.key
|
|
62026
|
-
);
|
|
62027
|
-
}),
|
|
62028
|
-
/* @__PURE__ */ jsxRuntime.jsx(react.Box, { as: "svg", css: styles2.underlay, ...{ viewBox: `0 0 ${size.w} ${size.h}`, width: size.w, height: size.h }, children: value.links.map((link2) => {
|
|
62029
|
-
const from = centers.get(link2.from);
|
|
62030
|
-
const to = centers.get(link2.to);
|
|
62031
|
-
if (!from || !to) return null;
|
|
62032
|
-
const anchors = [from, ...link2.via, to].map((p2) => ({ x: wx(p2.x), y: wy(p2.y) }));
|
|
62033
|
-
const corner = link2.route.type === "orthogonal" ? link2.route.value.corner.type === "some" ? link2.route.value.corner.value : 8 : 0;
|
|
62034
|
-
const pts = link2.route.type === "orthogonal" ? orthogonalize(anchors) : anchors;
|
|
62035
|
-
const style = link2.style;
|
|
62036
|
-
const tone = (style.value.tone.type === "some" ? style.value.tone.value.type : void 0) ?? (style.type === "solid" ? "brand" : "muted");
|
|
62037
|
-
const weight = style.value.weight.type === "some" ? style.value.weight.value : style.type === "solid" ? 2.5 : 1.5;
|
|
62038
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("g", { "data-tone": tone, children: [
|
|
62039
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
62040
|
-
"path",
|
|
62041
|
-
{
|
|
62042
|
-
d: roundedPath(pts, corner),
|
|
62043
|
-
fill: "none",
|
|
62044
|
-
"data-style": style.type,
|
|
62045
|
-
strokeWidth: weight,
|
|
62046
|
-
...style.type === "dashed" ? { strokeDasharray: "6 5" } : {}
|
|
62047
|
-
}
|
|
62048
|
-
),
|
|
62049
|
-
/* @__PURE__ */ jsxRuntime.jsx("circle", { cx: anchors[0].x, cy: anchors[0].y, r: weight + 1.5 }),
|
|
62050
|
-
/* @__PURE__ */ jsxRuntime.jsx("circle", { cx: anchors[anchors.length - 1].x, cy: anchors[anchors.length - 1].y, r: weight + 1.5 })
|
|
62051
|
-
] }, link2.key);
|
|
62052
|
-
}) }),
|
|
62520
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
62521
|
+
"canvas",
|
|
62522
|
+
{
|
|
62523
|
+
ref: drawRef,
|
|
62524
|
+
onClick: onCanvasClick,
|
|
62525
|
+
style: { position: "absolute", inset: 0, width: "100%", height: "100%" }
|
|
62526
|
+
}
|
|
62527
|
+
),
|
|
62053
62528
|
visibleItems.map((item) => {
|
|
62529
|
+
if ((tiers.get(item.key) ?? lod) !== "card") return null;
|
|
62054
62530
|
const tone = statusTone(item.status);
|
|
62055
62531
|
const isSelected = selected === item.key;
|
|
62056
|
-
const tier = tiers.get(item.key) ?? lod;
|
|
62057
|
-
if (tier === "dot") {
|
|
62058
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
62059
|
-
react.Box,
|
|
62060
|
-
{
|
|
62061
|
-
css: styles2.itemDot,
|
|
62062
|
-
"data-tone": tone ?? "neutral",
|
|
62063
|
-
...isSelected ? { "data-selected": "" } : {},
|
|
62064
|
-
style: { left: wx(item.x), top: wy(item.y) },
|
|
62065
|
-
onClick: () => flyToItem(item),
|
|
62066
|
-
onPointerDown: (e3) => e3.stopPropagation()
|
|
62067
|
-
},
|
|
62068
|
-
item.key
|
|
62069
|
-
);
|
|
62070
|
-
}
|
|
62071
|
-
if (tier === "label") {
|
|
62072
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
62073
|
-
react.Box,
|
|
62074
|
-
{
|
|
62075
|
-
css: styles2.itemPin,
|
|
62076
|
-
...isSelected ? { "data-selected": "" } : {},
|
|
62077
|
-
style: { left: wx(item.x), top: wy(item.y) },
|
|
62078
|
-
onClick: () => flyToItem(item),
|
|
62079
|
-
onPointerDown: (e3) => e3.stopPropagation(),
|
|
62080
|
-
children: [
|
|
62081
|
-
/* @__PURE__ */ jsxRuntime.jsx(react.Box, { as: "span", css: styles2.statusDot, "data-tone": tone ?? "neutral" }),
|
|
62082
|
-
item.label
|
|
62083
|
-
]
|
|
62084
|
-
},
|
|
62085
|
-
item.key
|
|
62086
|
-
);
|
|
62087
|
-
}
|
|
62088
62532
|
const sublabel = getSomeorUndefined(item.sublabel);
|
|
62089
62533
|
const icon3 = getSomeorUndefined(item.icon);
|
|
62090
62534
|
const meter = getSomeorUndefined(item.meter);
|