@graphysdk/react-renderer 1.9.0-beta.1794569506652 → 1.9.0-beta.1794582331101
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/editable.cjs +1 -1
- package/dist/editable.d.ts +0 -3
- package/dist/editable.mjs +2061 -2066
- package/dist/history-chords-B_gzoztJ.cjs +2 -0
- package/dist/{history-chords-L-9s4-lq.js → history-chords-QvGzISXZ.js} +3510 -3508
- package/dist/history-chords.css +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +34 -20
- package/dist/index.mjs +339 -328
- package/package.json +4 -4
- package/dist/history-chords-CHDa7G9D.cjs +0 -2
package/dist/history-chords.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@property --graphy-text-scale{syntax:"<number>";inherits:true;initial-value:1}@property --graphy-font-size-xxs{syntax:"<length>";inherits:true;initial-value:10px}@property --graphy-font-size-xs{syntax:"<length>";inherits:true;initial-value:11px}@property --graphy-font-size-sm{syntax:"<length>";inherits:true;initial-value:12px}@property --graphy-font-size-md{syntax:"<length>";inherits:true;initial-value:14px}@property --graphy-font-size-lg{syntax:"<length>";inherits:true;initial-value:16px}@property --graphy-font-size-xl{syntax:"<length>";inherits:true;initial-value:20px}@property --graphy-font-size-editor-body{syntax:"<length>";inherits:true;initial-value:15px}@property --graphy-font-size-heading-sm{syntax:"<length>";inherits:true;initial-value:18px}@property --graphy-font-size-heading-md{syntax:"<length>";inherits:true;initial-value:22px}@property --graphy-font-size-heading-lg{syntax:"<length>";inherits:true;initial-value:28px}._1d8mpa10{overflow:visible}._8zqcis5{x:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);width:min(var(--_8zqcis1), var(--_8zqcis2))}._8zqcis6{y:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);height:min(var(--_8zqcis1), var(--_8zqcis2))}._8zqcis7{x:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);width:min(var(--_8zqcis1), var(--_8zqcis2));y:calc(var(--_8zqcis3) - var(--_8zqcis4) / 2);height:var(--_8zqcis4)}._8zqcis8{y:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);height:min(var(--_8zqcis1), var(--_8zqcis2));x:calc(var(--_8zqcis3) - var(--_8zqcis4) / 2);width:var(--_8zqcis4)}._16vokpr0{pointer-events:none;-webkit-user-select:none;user-select:none}._2qyyu60{flex-shrink:0;display:block;overflow:visible}.bow4tg0{box-sizing:border-box;color:var(--graphy-text-primary);font-size:calc(10px * var(--graphy-text-scale));position:relative;overflow:hidden}.bow4tg1{color:var(--graphy-text-primary);font-size:calc(10px * var(--graphy-text-scale));display:contents}.bow4tg2{background-color:var(--graphy-graph-background);position:absolute;top:0;bottom:0;left:0;right:0}.bow4tg2[data-graph-mode=edit]{-webkit-user-select:none;user-select:none}.bow4tg3{outline:none}.bow4tg4{background-image:linear-gradient(45deg, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 25%, transparent 25%, transparent 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent)), linear-gradient(45deg, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 25%, transparent 25%, transparent 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent));background-position:0 0,1em 1em;background-size:2em 2em}._1ii3bsb0{--graphy-transparent:transparent;--graphy-white:#fff;--graphy-black:#000;--graphy-gray-100:#fff;--graphy-gray-95:#fcfcfc;--graphy-gray-90:#fafafa;--graphy-gray-85:#f5f5f5;--graphy-gray-80:#f0f0f0;--graphy-gray-75:#e8e8e8;--graphy-gray-70:#e5e5e5;--graphy-gray-60:#ccc;--graphy-gray-50:#c4c4c4;--graphy-gray-0:#1d2129;--graphy-red-60:#e14b49;--graphy-red-50:#f93939;--graphy-amber-70:#ffba8c;--graphy-amber-50:#ffc849;--graphy-amber-40:#feae47;--graphy-amber-30:#e7a816;--graphy-green-60:#06b299;--graphy-green-50:#42cd69;--graphy-blue-80:#2e62ff;--graphy-blue-60:#3d70ff;--graphy-purple-50:#7b56ea;--graphy-purple-30:#e093fe;--graphy-gray-gradient-80:linear-gradient(to top, #f0f0f1, #f9f9ff);--graphy-text-primary:var(--graphy-black);--graphy-text-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-text-disabled:color-mix(in srgb, transparent, var(--graphy-text-primary) 50%);--graphy-icon-primary:currentColor;--graphy-icon-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-icon-sticker-background:var(--graphy-gray-100);--graphy-brand:var(--graphy-purple-50);--graphy-success:var(--graphy-green-50);--graphy-warning:var(--graphy-amber-50);--graphy-alert:var(--graphy-red-50);--graphy-border-100:var(--graphy-gray-0);--graphy-border-50:color-mix(in srgb, transparent, var(--graphy-gray-0) 50%);--graphy-border-10:color-mix(in srgb, transparent, var(--graphy-gray-0) 10%);--graphy-sunken-background:var(--graphy-gray-90);--graphy-default-background:var(--graphy-gray-100);--graphy-raised-background:var(--graphy-gray-85);--graphy-overlay-background:var(--graphy-gray-100);--graphy-overlay-border-gradient:var(--graphy-border-10);--graphy-elevation-xs:0 0 2px #0f0f181f, 0 2px 2px #0e0e3414;--graphy-elevation-sm:0 0 4px #0f0f181f, 0 4px 4px #0e0e3414;--graphy-elevation-md:0 0 8px #0f0f181f, 0 8px 8px #0e0e3414;--graphy-elevation-lg:0 0 16px #0f0f181f, 0 16px 16px #0e0e3414;--graphy-radii-xs:4px;--graphy-radii-sm:6px;--graphy-radii-md:8px;--graphy-radii-lg:12px;--graphy-space-xxs:2px;--graphy-space-xs:4px;--graphy-space-sm:6px;--graphy-space-md:8px;--graphy-space-lg:12px;--graphy-space-xl:16px;--graphy-z-index-toolbar:10;--graphy-z-index-toolbar-tooltip:20;--graphy-z-index-toolbar-popover:30;--graphy-z-index-editor-popover:950;--graphy-graph-background:var(--graphy-gray-100);--graphy-toolbar-background-color:var(--graphy-overlay-background);--graphy-toolbar-button-background-color:transparent;--graphy-toolbar-button-background-color-hovered:var(--graphy-gray-80);--graphy-toolbar-button-background-color-selected:var(--graphy-gray-60);--graphy-toolbar-separator-color:var(--graphy-gray-60);--graphy-editor-default-accent:#3b372f;--graphy-editor-default-surface:#fff;--graphy-editor-default-text:#3b372f;--graphy-editor-default-shadow:var(--graphy-elevation-md), 0 16px 40px #14120f24;--graphy-canvas-default:#000;--graphy-canvas-blue:#3b82f6;--graphy-canvas-cyan:#06b6d4;--graphy-canvas-green:#10b981;--graphy-canvas-yellow:#e5b400;--graphy-canvas-orange:#f97316;--graphy-canvas-red:#ef4444;--graphy-canvas-pink:#e845bf;--graphy-canvas-purple:#8b5cf6;--graphy-canvas-gray:#78716c;--graphy-canvas-inverse:#fff;--graphy-editor-control-height:32px;--graphy-text-scale:1;--graphy-font-family:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-family-heading:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-weight-regular:400;--graphy-font-weight-medium:500;--graphy-font-weight-semibold:600;--graphy-font-weight-bold:700;--graphy-font-weight-extra-bold:800;--graphy-font-size-xxs:1em;--graphy-font-size-xs:1.1em;--graphy-font-size-sm:1.2em;--graphy-font-size-md:1.4em;--graphy-font-size-lg:1.6em;--graphy-font-size-xl:2em;--graphy-font-line-height-xxs:1;--graphy-font-line-height-xs:1;--graphy-font-line-height-sm:1.3;--graphy-font-line-height-md:1.43;--graphy-font-line-height-lg:1;--graphy-font-line-height-xl:1;--graphy-font-size-editor-body:1.5em;--graphy-font-size-heading-sm:1.8em;--graphy-font-size-heading-md:2.2em;--graphy-font-size-heading-lg:2.8em;--graphy-font-line-height-editor-body:1.47;--graphy-font-line-height-heading-sm:1.25;--graphy-font-line-height-heading-md:1.41;--graphy-font-line-height-heading-lg:1.29;--graphy-font-uitooltip:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-uitooltip-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-button:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input-label:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-font-family);--graphy-font-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-select-description:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-color-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-group-title:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-item-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-item-label-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-error-boundary-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family);--graphy-font-error-boundary-message:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-cell:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-header-cell:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-link:var(--graphy-font-weight-regular) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-h1:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-lg)/var(--graphy-font-line-height-heading-lg) var(--graphy-font-family-heading);--graphy-font-text-editor-h2:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-md)/var(--graphy-font-line-height-heading-md) var(--graphy-font-family-heading);--graphy-font-text-editor-h3:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family-heading);--graphy-font-text-editor-h6:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-body:var(--graphy-font-weight-medium) var(--graphy-font-size-editor-body)/var(--graphy-font-line-height-editor-body) var(--graphy-font-family);--graphy-font-text-editor-link:var(--graphy-font-weight-regular) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-title:var(--graphy-font-weight-bold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-subtitle:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-editor-control-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-control-value:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-section-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-caption:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-editor-font-family,var(--graphy-font-family))}._1ii3bsb1{--graphy-transparent:transparent;--graphy-white:#fff;--graphy-black:#000;--graphy-gray-100:#000;--graphy-gray-95:#0d0d0d;--graphy-gray-90:#1a1a1a;--graphy-gray-85:#1f1f1f;--graphy-gray-80:#2a2a2a;--graphy-gray-75:#2e2e2e;--graphy-gray-70:#353535;--graphy-gray-60:#494949;--graphy-gray-50:#6f6f6f;--graphy-gray-0:#fff;--graphy-red-60:#cb3333;--graphy-red-50:#f93939;--graphy-amber-70:#f48135;--graphy-amber-50:#feae47;--graphy-amber-40:#ffc849;--graphy-amber-30:#ffd061;--graphy-green-60:#0ac600;--graphy-green-50:#42cd69;--graphy-blue-80:#2e62ff;--graphy-blue-60:#3d70ff;--graphy-purple-50:#7b56ea;--graphy-purple-30:#e093fe;--graphy-gray-gradient-80:linear-gradient(to top, #222429, #31353f);--graphy-text-primary:var(--graphy-gray-0);--graphy-text-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 80%);--graphy-text-disabled:color-mix(in srgb, transparent, var(--graphy-text-primary) 50%);--graphy-icon-primary:currentColor;--graphy-icon-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-icon-sticker-background:var(--graphy-gray-70);--graphy-border-100:var(--graphy-gray-0);--graphy-border-50:color-mix(in srgb, transparent, var(--graphy-gray-0) 50%);--graphy-border-10:color-mix(in srgb, transparent, var(--graphy-gray-0) 10%);--graphy-brand:var(--graphy-purple-50);--graphy-success:var(--graphy-green-50);--graphy-warning:var(--graphy-amber-50);--graphy-alert:var(--graphy-red-50);--graphy-sunken-background:var(--graphy-gray-100);--graphy-default-background:var(--graphy-gray-90);--graphy-raised-background:var(--graphy-gray-80);--graphy-overlay-background:var(--graphy-gray-90);--graphy-overlay-border-gradient:var(--graphy-gray-gradient-80);--graphy-elevation-xs:0 0 2px #0f0f181f, 0 2px 2px #0e0e3414;--graphy-elevation-sm:0 0 4px #0f0f181f, 0 4px 4px #0e0e3414;--graphy-elevation-md:0 0 8px #0f0f181f, 0 8px 8px #0e0e3414;--graphy-elevation-lg:0 0 16px #0f0f181f, 0 16px 16px #0e0e3414;--graphy-radii-xs:4px;--graphy-radii-sm:6px;--graphy-radii-md:8px;--graphy-radii-lg:12px;--graphy-space-xxs:2px;--graphy-space-xs:4px;--graphy-space-sm:6px;--graphy-space-md:8px;--graphy-space-lg:12px;--graphy-space-xl:16px;--graphy-z-index-toolbar:10;--graphy-z-index-toolbar-tooltip:20;--graphy-z-index-toolbar-popover:30;--graphy-z-index-editor-popover:950;--graphy-graph-background:var(--graphy-gray-90);--graphy-toolbar-background-color:var(--graphy-overlay-background);--graphy-toolbar-button-background-color:transparent;--graphy-toolbar-button-background-color-hovered:var(--graphy-gray-80);--graphy-toolbar-button-background-color-selected:var(--graphy-gray-60);--graphy-toolbar-separator-color:var(--graphy-gray-60);--graphy-editor-default-accent:#ece7df;--graphy-editor-default-surface:#26241f;--graphy-editor-default-text:#ece7df;--graphy-editor-default-shadow:var(--graphy-elevation-md), 0 16px 40px #00000073;--graphy-canvas-default:#fff;--graphy-canvas-blue:#60a5fa;--graphy-canvas-cyan:#22d3ee;--graphy-canvas-green:#34d399;--graphy-canvas-yellow:#ffc800;--graphy-canvas-orange:#fb923c;--graphy-canvas-red:#f87171;--graphy-canvas-pink:#f979d9;--graphy-canvas-purple:#a78bfa;--graphy-canvas-gray:#a8a29e;--graphy-canvas-inverse:#000;--graphy-editor-control-height:32px;--graphy-text-scale:1;--graphy-font-family:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-family-heading:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-weight-regular:400;--graphy-font-weight-medium:500;--graphy-font-weight-semibold:600;--graphy-font-weight-bold:700;--graphy-font-weight-extra-bold:800;--graphy-font-size-xxs:1em;--graphy-font-size-xs:1.1em;--graphy-font-size-sm:1.2em;--graphy-font-size-md:1.4em;--graphy-font-size-lg:1.6em;--graphy-font-size-xl:2em;--graphy-font-line-height-xxs:1;--graphy-font-line-height-xs:1;--graphy-font-line-height-sm:1.3;--graphy-font-line-height-md:1.43;--graphy-font-line-height-lg:1;--graphy-font-line-height-xl:1;--graphy-font-size-editor-body:1.5em;--graphy-font-size-heading-sm:1.8em;--graphy-font-size-heading-md:2.2em;--graphy-font-size-heading-lg:2.8em;--graphy-font-line-height-editor-body:1.47;--graphy-font-line-height-heading-sm:1.25;--graphy-font-line-height-heading-md:1.41;--graphy-font-line-height-heading-lg:1.29;--graphy-font-uitooltip:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-uitooltip-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-button:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input-label:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-font-family);--graphy-font-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-select-description:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-color-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-group-title:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-item-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-item-label-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-error-boundary-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family);--graphy-font-error-boundary-message:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-cell:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-header-cell:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-link:var(--graphy-font-weight-regular) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-h1:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-lg)/var(--graphy-font-line-height-heading-lg) var(--graphy-font-family-heading);--graphy-font-text-editor-h2:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-md)/var(--graphy-font-line-height-heading-md) var(--graphy-font-family-heading);--graphy-font-text-editor-h3:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family-heading);--graphy-font-text-editor-h6:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-body:var(--graphy-font-weight-medium) var(--graphy-font-size-editor-body)/var(--graphy-font-line-height-editor-body) var(--graphy-font-family);--graphy-font-text-editor-link:var(--graphy-font-weight-regular) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-title:var(--graphy-font-weight-bold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-subtitle:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-editor-control-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-control-value:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-section-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-caption:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-editor-font-family,var(--graphy-font-family))}._1cocly40{color:inherit;text-underline-offset:.15em;text-decoration:underline}._19519k80{flex-direction:column;gap:4px;min-width:120px;max-width:280px;display:flex}._19519k81{white-space:normal;overflow-wrap:anywhere}._19519k82{flex-direction:column;display:flex}._19519k83{flex-direction:row;align-items:center;gap:8px;display:flex}._19519k84{flex-shrink:0;display:block;overflow:visible}._19519k85{width:12px;height:12px}._19519k86{white-space:nowrap;text-overflow:ellipsis;min-width:0;overflow:hidden}._19519k87{font-variant-numeric:tabular-nums;white-space:nowrap;text-align:right}._19519k88{pointer-events:none;-webkit-user-select:none;user-select:none;z-index:1000;position:fixed;top:0;left:0}._84o2bh0{pointer-events:none;position:absolute}._4dlrid0{margin:0}._4dlrid0 :-webkit-any(h1,h2,h3,p){font:inherit;color:inherit;margin:0}._4dlrid0 :is(h1,h2,h3,p){font:inherit;color:inherit;margin:0}.xfz7dq0{position:absolute}.xfz7dq1{align-items:end;column-gap:var(--graphy-space-xs);color:var(--graphy-text-secondary);grid-template-columns:minmax(0,1fr) auto;display:grid}.xfz7dq2{min-width:0}.xfz7dq3{overflow-wrap:anywhere;text-decoration:underline}.xfz7dq3:hover{color:var(--graphy-text-primary)}.xfz7dq4{margin-right:var(--graphy-space-xs)}.xfz7dq5{overflow-wrap:anywhere}._15xngrw0{box-sizing:border-box;white-space:nowrap;color:#2a2a28;opacity:.62;background-color:#ffffff8c;border-radius:999px;flex-shrink:0;align-items:center;gap:4px;height:22px;padding-inline-start:9px;padding-inline-end:11px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,system-ui,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:11.5px;line-height:1;text-decoration:none;transition:opacity .12s,max-width .25s,padding .25s,gap .25s;display:inline-flex;box-shadow:0 1px 4px #00000017}._15xngrw0:hover{opacity:1}._15xngrw0:focus-visible{opacity:1}._15xngrw0:focus-visible{outline-offset:2px;outline:2px solid #2a2a28}._15xngrw0[data-background-tone=mid]{opacity:.8;background-color:#ffffffbf}._15xngrw0[data-background-tone=dark]{opacity:.85;color:#fff;box-shadow:none;background-color:#ffffff14}._15xngrw0[data-background-tone=dark]:focus-visible{outline:2px solid #fff}._15xngrw0[data-variant=mini]{justify-content:center;gap:0;width:22px;padding-inline-start:0;padding-inline-end:0}._15xngrw0[data-variant=mini]:hover{gap:4px;width:auto;padding-inline-start:9px;padding-inline-end:11px}._15xngrw0[data-variant=mini]:focus-visible{gap:4px;width:auto;padding-inline-start:9px;padding-inline-end:11px}._15xngrw1{flex-direction:row-reverse}._15xngrw2{flex-shrink:0;width:10.5px;height:14px;display:block}._15xngrw3{max-width:120px;font-weight:500;transition:max-width .25s,opacity .25s;display:inline-flex;overflow:hidden}._15xngrw0[data-variant=mini] ._15xngrw3{opacity:0;max-width:0}._15xngrw0[data-variant=mini]:hover ._15xngrw3{opacity:1;max-width:120px}._15xngrw0[data-variant=mini]:focus-visible ._15xngrw3{opacity:1;max-width:120px}._15xngrw4{place-self:end}._15xngrw5{position:absolute;top:50%;right:0;transform:translateY(-50%)}@media (prefers-reduced-motion:reduce){._15xngrw0,._15xngrw3{transition:none}}._1k4qtbg0{position:absolute}._1k4qtbg1{padding-right:110px}._1u9qprb0{pointer-events:none;justify-content:start;align-items:start;display:flex;position:absolute}._1u9qprb1{pointer-events:none;justify-content:center;align-items:center;display:flex;position:absolute}._9aen060{align-items:baseline;display:flex}._9aen061,._9aen062{align-items:center;display:flex}._9aen063{flex-direction:column;align-items:start;display:flex}.asohov0{flex-shrink:0}.asohov1{color:var(--graphy-icon-primary)}.asohov2{color:var(--graphy-icon-secondary)}.n7clvo0,.n7clvo1{white-space:nowrap}.n7clvo2{border-radius:50%;justify-content:center;align-items:center;width:12px;height:12px;display:flex}.n7clvo3{transform:rotate(180deg)}._1oj6yix0{pointer-events:none;height:100%;position:relative}._1oj6yix1{pointer-events:none;position:absolute;top:0;left:0;overflow:visible}._1oj6yix2{white-space:nowrap;position:absolute;transform:translateY(-50%)}._1oj6yix3{pointer-events:auto;cursor:pointer;margin-left:-3px;padding:3px}._6a636s0{pointer-events:none;position:absolute}._1isxsac0{white-space:nowrap;flex-shrink:0;display:flex}._1isxsac1{flex-direction:row;align-items:center}._1isxsac2{flex-direction:column;align-items:flex-start}._1isxsac3{margin-inline-start:auto}._1isxsac4,._1isxsac5{flex-direction:row;align-items:center;display:flex}._1isxsac6{text-overflow:ellipsis;overflow:hidden}._1or78v80{box-sizing:border-box;border-style:solid;border-width:1px;border-radius:9999px;flex-shrink:0;transition:inline-size .3s ease-out,block-size .3s ease-out;display:block}._1or78v81{flex-shrink:0;display:block;overflow:visible}@media (prefers-reduced-motion:reduce){._1or78v80{transition:none}}._1cecisi0{pointer-events:none;flex-wrap:nowrap;align-items:center;block-size:100%;inline-size:100%;display:flex}._1cecisi1{flex-direction:row}._1cecisi2{flex-direction:column}._1cecisi3{justify-content:flex-start}._1cecisi3._1cecisi1:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-end}._1cecisi3._1cecisi1:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-end}._1cecisi4{justify-content:center}._1cecisi5{justify-content:flex-end}._1cecisi5._1cecisi1:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-start}._1cecisi5._1cecisi1:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-start}._1cecisi6{justify-content:flex-end}._1cecisi7{align-items:flex-start}._1cecisi7:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-end}._1cecisi7:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-end}._1cecisi8{align-items:flex-end}._1cecisi8:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-start}._1cecisi8:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-start}._1cecisi9{white-space:nowrap;flex-shrink:0;align-items:center;display:flex}._1cecisia{pointer-events:auto;cursor:pointer}._1kjk02r1{pointer-events:auto;flex-shrink:0;align-items:center;display:inline-flex;position:relative}._1kjk02r2{pointer-events:none}._1kjk02r3{padding-inline-start:4px}._1kjk02r4{padding-inline-start:8px}._1kjk02r5{padding-block-start:4px}._1kjk02r6{padding-block-start:8px}._1kjk02r7{pointer-events:none;position:absolute}._1kjk02r8{top:0;bottom:0}._1kjk02r8:not(:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:4px;right:0}._1kjk02r8:not(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:4px;right:0}._1kjk02r8:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:4px}._1kjk02r8:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:4px}._1kjk02r9{top:0;bottom:0}._1kjk02r9:not(:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:8px;right:0}._1kjk02r9:not(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:8px;right:0}._1kjk02r9:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:8px}._1kjk02r9:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:8px}._1kjk02ra{top:4px;bottom:0;left:0;right:0}._1kjk02rb{top:8px;bottom:0;left:0;right:0}._1kjk02rc{white-space:nowrap;cursor:pointer;pointer-events:auto;-webkit-appearance:none;appearance:none;background:0 0;border:none;align-items:center;padding:0;display:inline-flex;position:relative}._1kjk02rc:focus-visible{outline:1px solid var(--_1kjk02r0)}._1kjk02rd{cursor:default;pointer-events:none}._1kjk02re{font-variant-numeric:tabular-nums}._1kjk02rf{pointer-events:auto;z-index:40;max-width:320px;max-height:240px;overflow-y:auto}._1kjk02rg{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}._1kjk02rh{white-space:nowrap;align-items:center;display:flex}._1kjk02ri,._1i8rg6j0{cursor:pointer}._1aj6s5s0{pointer-events:auto;font-family:var(--graphy-font-family);word-wrap:break-word;white-space:break-spaces;text-align:center;box-sizing:border-box;width:100%}._1aj6s5s0 p,._1aj6s5s0 h1,._1aj6s5s0 h2,._1aj6s5s0 h3{margin:0}._1aj6s5s1 .ProseMirror{outline:none;min-height:1em}._1aj6s5s1 .ProseMirror .is-empty:before{content:attr(data-placeholder);color:currentColor;opacity:.4;float:left;white-space:nowrap;text-overflow:ellipsis;pointer-events:none;width:100%;margin-right:-100%;overflow:hidden}.ph8bdc0{pointer-events:none}.ph8bdc1{flex-shrink:0;align-items:center;display:flex}.ph8bdc2{font-family:var(--graphy-font-family)}.ph8bdc3{box-sizing:border-box;white-space:nowrap;-webkit-user-select:none;user-select:none;flex-direction:row;align-items:center;gap:5px;width:100%;height:100%;display:flex}.ph8bdc4{pointer-events:auto}.ph8bdc5,._1agclyl0,._1agclyl1{pointer-events:none}._1agclyl2{pointer-events:none;font-variant-numeric:tabular-nums}.to1jkx2{stroke-linecap:round;overflow:visible}.to1jkx3{transition:opacity .15s ease-out,filter .15s ease-out}[data-hover-active=true] .to1jkx3{opacity:var(--to1jkx0,1);filter:var(--to1jkx1,none)}._17uhij30{position:absolute;top:0;left:0;overflow:visible}._17uhij30 text{direction:ltr;unicode-bidi:plaintext}._1vl0pke0{pointer-events:none;border-radius:inherit;position:absolute;top:0;bottom:0;left:0;right:0}._1vl0pke1{isolation:isolate}._1vl0pke2{z-index:-1;pointer-events:none;border-radius:inherit;position:absolute;top:0;bottom:0;left:0;right:0}
|
|
1
|
+
@property --graphy-text-scale{syntax:"<number>";inherits:true;initial-value:1}@property --graphy-font-size-xxs{syntax:"<length>";inherits:true;initial-value:10px}@property --graphy-font-size-xs{syntax:"<length>";inherits:true;initial-value:11px}@property --graphy-font-size-sm{syntax:"<length>";inherits:true;initial-value:12px}@property --graphy-font-size-md{syntax:"<length>";inherits:true;initial-value:14px}@property --graphy-font-size-lg{syntax:"<length>";inherits:true;initial-value:16px}@property --graphy-font-size-xl{syntax:"<length>";inherits:true;initial-value:20px}@property --graphy-font-size-editor-body{syntax:"<length>";inherits:true;initial-value:15px}@property --graphy-font-size-heading-sm{syntax:"<length>";inherits:true;initial-value:18px}@property --graphy-font-size-heading-md{syntax:"<length>";inherits:true;initial-value:22px}@property --graphy-font-size-heading-lg{syntax:"<length>";inherits:true;initial-value:28px}._1d8mpa10{overflow:visible}.w2i4n00{pointer-events:none;position:absolute}._8zqcis5{x:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);width:min(var(--_8zqcis1), var(--_8zqcis2))}._8zqcis6{y:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);height:min(var(--_8zqcis1), var(--_8zqcis2))}._8zqcis7{x:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);width:min(var(--_8zqcis1), var(--_8zqcis2));y:calc(var(--_8zqcis3) - var(--_8zqcis4) / 2);height:var(--_8zqcis4)}._8zqcis8{y:calc(var(--_8zqcis0) + (var(--_8zqcis1) - min(var(--_8zqcis1), var(--_8zqcis2))) / 2);height:min(var(--_8zqcis1), var(--_8zqcis2));x:calc(var(--_8zqcis3) - var(--_8zqcis4) / 2);width:var(--_8zqcis4)}._16vokpr0{pointer-events:none;-webkit-user-select:none;user-select:none}._2qyyu60{flex-shrink:0;display:block;overflow:visible}.bow4tg0{box-sizing:border-box;color:var(--graphy-text-primary);font-size:calc(10px * var(--graphy-text-scale));position:relative;overflow:hidden}.bow4tg1{color:var(--graphy-text-primary);font-size:calc(10px * var(--graphy-text-scale));display:contents}.bow4tg2{background-color:var(--graphy-graph-background);position:absolute;top:0;bottom:0;left:0;right:0}.bow4tg2[data-graph-mode=edit]{-webkit-user-select:none;user-select:none}.bow4tg3{outline:none}.bow4tg4{background-image:linear-gradient(45deg, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 25%, transparent 25%, transparent 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent)), linear-gradient(45deg, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 25%, transparent 25%, transparent 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent) 75%, color-mix(in srgb, var(--graphy-text-primary) 5%, transparent));background-position:0 0,1em 1em;background-size:2em 2em}._1ii3bsb0{--graphy-transparent:transparent;--graphy-white:#fff;--graphy-black:#000;--graphy-gray-100:#fff;--graphy-gray-95:#fcfcfc;--graphy-gray-90:#fafafa;--graphy-gray-85:#f5f5f5;--graphy-gray-80:#f0f0f0;--graphy-gray-75:#e8e8e8;--graphy-gray-70:#e5e5e5;--graphy-gray-60:#ccc;--graphy-gray-50:#c4c4c4;--graphy-gray-0:#1d2129;--graphy-red-60:#e14b49;--graphy-red-50:#f93939;--graphy-amber-70:#ffba8c;--graphy-amber-50:#ffc849;--graphy-amber-40:#feae47;--graphy-amber-30:#e7a816;--graphy-green-60:#06b299;--graphy-green-50:#42cd69;--graphy-blue-80:#2e62ff;--graphy-blue-60:#3d70ff;--graphy-purple-50:#7b56ea;--graphy-purple-30:#e093fe;--graphy-gray-gradient-80:linear-gradient(to top, #f0f0f1, #f9f9ff);--graphy-text-primary:var(--graphy-black);--graphy-text-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-text-disabled:color-mix(in srgb, transparent, var(--graphy-text-primary) 50%);--graphy-icon-primary:currentColor;--graphy-icon-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-icon-sticker-background:var(--graphy-gray-100);--graphy-brand:var(--graphy-purple-50);--graphy-success:var(--graphy-green-50);--graphy-warning:var(--graphy-amber-50);--graphy-alert:var(--graphy-red-50);--graphy-border-100:var(--graphy-gray-0);--graphy-border-50:color-mix(in srgb, transparent, var(--graphy-gray-0) 50%);--graphy-border-10:color-mix(in srgb, transparent, var(--graphy-gray-0) 10%);--graphy-sunken-background:var(--graphy-gray-90);--graphy-default-background:var(--graphy-gray-100);--graphy-raised-background:var(--graphy-gray-85);--graphy-overlay-background:var(--graphy-gray-100);--graphy-overlay-border-gradient:var(--graphy-border-10);--graphy-elevation-xs:0 0 2px #0f0f181f, 0 2px 2px #0e0e3414;--graphy-elevation-sm:0 0 4px #0f0f181f, 0 4px 4px #0e0e3414;--graphy-elevation-md:0 0 8px #0f0f181f, 0 8px 8px #0e0e3414;--graphy-elevation-lg:0 0 16px #0f0f181f, 0 16px 16px #0e0e3414;--graphy-radii-xs:4px;--graphy-radii-sm:6px;--graphy-radii-md:8px;--graphy-radii-lg:12px;--graphy-space-xxs:2px;--graphy-space-xs:4px;--graphy-space-sm:6px;--graphy-space-md:8px;--graphy-space-lg:12px;--graphy-space-xl:16px;--graphy-z-index-toolbar:10;--graphy-z-index-toolbar-tooltip:20;--graphy-z-index-toolbar-popover:30;--graphy-z-index-editor-popover:950;--graphy-graph-background:var(--graphy-gray-100);--graphy-toolbar-background-color:var(--graphy-overlay-background);--graphy-toolbar-button-background-color:transparent;--graphy-toolbar-button-background-color-hovered:var(--graphy-gray-80);--graphy-toolbar-button-background-color-selected:var(--graphy-gray-60);--graphy-toolbar-separator-color:var(--graphy-gray-60);--graphy-editor-default-accent:#3b372f;--graphy-editor-default-surface:#fff;--graphy-editor-default-text:#3b372f;--graphy-editor-default-shadow:var(--graphy-elevation-md), 0 16px 40px #14120f24;--graphy-canvas-default:#000;--graphy-canvas-blue:#3b82f6;--graphy-canvas-cyan:#06b6d4;--graphy-canvas-green:#10b981;--graphy-canvas-yellow:#e5b400;--graphy-canvas-orange:#f97316;--graphy-canvas-red:#ef4444;--graphy-canvas-pink:#e845bf;--graphy-canvas-purple:#8b5cf6;--graphy-canvas-gray:#78716c;--graphy-canvas-inverse:#fff;--graphy-editor-control-height:32px;--graphy-text-scale:1;--graphy-font-family:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-family-heading:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-weight-regular:400;--graphy-font-weight-medium:500;--graphy-font-weight-semibold:600;--graphy-font-weight-bold:700;--graphy-font-weight-extra-bold:800;--graphy-font-size-xxs:1em;--graphy-font-size-xs:1.1em;--graphy-font-size-sm:1.2em;--graphy-font-size-md:1.4em;--graphy-font-size-lg:1.6em;--graphy-font-size-xl:2em;--graphy-font-line-height-xxs:1;--graphy-font-line-height-xs:1;--graphy-font-line-height-sm:1.3;--graphy-font-line-height-md:1.43;--graphy-font-line-height-lg:1;--graphy-font-line-height-xl:1;--graphy-font-size-editor-body:1.5em;--graphy-font-size-heading-sm:1.8em;--graphy-font-size-heading-md:2.2em;--graphy-font-size-heading-lg:2.8em;--graphy-font-line-height-editor-body:1.47;--graphy-font-line-height-heading-sm:1.25;--graphy-font-line-height-heading-md:1.41;--graphy-font-line-height-heading-lg:1.29;--graphy-font-uitooltip:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-uitooltip-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-button:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input-label:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-font-family);--graphy-font-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-select-description:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-color-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-group-title:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-item-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-item-label-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-error-boundary-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family);--graphy-font-error-boundary-message:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-cell:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-header-cell:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-link:var(--graphy-font-weight-regular) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-h1:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-lg)/var(--graphy-font-line-height-heading-lg) var(--graphy-font-family-heading);--graphy-font-text-editor-h2:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-md)/var(--graphy-font-line-height-heading-md) var(--graphy-font-family-heading);--graphy-font-text-editor-h3:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family-heading);--graphy-font-text-editor-h6:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-body:var(--graphy-font-weight-medium) var(--graphy-font-size-editor-body)/var(--graphy-font-line-height-editor-body) var(--graphy-font-family);--graphy-font-text-editor-link:var(--graphy-font-weight-regular) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-title:var(--graphy-font-weight-bold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-subtitle:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-editor-control-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-control-value:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-section-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-caption:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-editor-font-family,var(--graphy-font-family))}._1ii3bsb1{--graphy-transparent:transparent;--graphy-white:#fff;--graphy-black:#000;--graphy-gray-100:#000;--graphy-gray-95:#0d0d0d;--graphy-gray-90:#1a1a1a;--graphy-gray-85:#1f1f1f;--graphy-gray-80:#2a2a2a;--graphy-gray-75:#2e2e2e;--graphy-gray-70:#353535;--graphy-gray-60:#494949;--graphy-gray-50:#6f6f6f;--graphy-gray-0:#fff;--graphy-red-60:#cb3333;--graphy-red-50:#f93939;--graphy-amber-70:#f48135;--graphy-amber-50:#feae47;--graphy-amber-40:#ffc849;--graphy-amber-30:#ffd061;--graphy-green-60:#0ac600;--graphy-green-50:#42cd69;--graphy-blue-80:#2e62ff;--graphy-blue-60:#3d70ff;--graphy-purple-50:#7b56ea;--graphy-purple-30:#e093fe;--graphy-gray-gradient-80:linear-gradient(to top, #222429, #31353f);--graphy-text-primary:var(--graphy-gray-0);--graphy-text-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 80%);--graphy-text-disabled:color-mix(in srgb, transparent, var(--graphy-text-primary) 50%);--graphy-icon-primary:currentColor;--graphy-icon-secondary:color-mix(in srgb, transparent, var(--graphy-text-primary) 60%);--graphy-icon-sticker-background:var(--graphy-gray-70);--graphy-border-100:var(--graphy-gray-0);--graphy-border-50:color-mix(in srgb, transparent, var(--graphy-gray-0) 50%);--graphy-border-10:color-mix(in srgb, transparent, var(--graphy-gray-0) 10%);--graphy-brand:var(--graphy-purple-50);--graphy-success:var(--graphy-green-50);--graphy-warning:var(--graphy-amber-50);--graphy-alert:var(--graphy-red-50);--graphy-sunken-background:var(--graphy-gray-100);--graphy-default-background:var(--graphy-gray-90);--graphy-raised-background:var(--graphy-gray-80);--graphy-overlay-background:var(--graphy-gray-90);--graphy-overlay-border-gradient:var(--graphy-gray-gradient-80);--graphy-elevation-xs:0 0 2px #0f0f181f, 0 2px 2px #0e0e3414;--graphy-elevation-sm:0 0 4px #0f0f181f, 0 4px 4px #0e0e3414;--graphy-elevation-md:0 0 8px #0f0f181f, 0 8px 8px #0e0e3414;--graphy-elevation-lg:0 0 16px #0f0f181f, 0 16px 16px #0e0e3414;--graphy-radii-xs:4px;--graphy-radii-sm:6px;--graphy-radii-md:8px;--graphy-radii-lg:12px;--graphy-space-xxs:2px;--graphy-space-xs:4px;--graphy-space-sm:6px;--graphy-space-md:8px;--graphy-space-lg:12px;--graphy-space-xl:16px;--graphy-z-index-toolbar:10;--graphy-z-index-toolbar-tooltip:20;--graphy-z-index-toolbar-popover:30;--graphy-z-index-editor-popover:950;--graphy-graph-background:var(--graphy-gray-90);--graphy-toolbar-background-color:var(--graphy-overlay-background);--graphy-toolbar-button-background-color:transparent;--graphy-toolbar-button-background-color-hovered:var(--graphy-gray-80);--graphy-toolbar-button-background-color-selected:var(--graphy-gray-60);--graphy-toolbar-separator-color:var(--graphy-gray-60);--graphy-editor-default-accent:#ece7df;--graphy-editor-default-surface:#26241f;--graphy-editor-default-text:#ece7df;--graphy-editor-default-shadow:var(--graphy-elevation-md), 0 16px 40px #00000073;--graphy-canvas-default:#fff;--graphy-canvas-blue:#60a5fa;--graphy-canvas-cyan:#22d3ee;--graphy-canvas-green:#34d399;--graphy-canvas-yellow:#ffc800;--graphy-canvas-orange:#fb923c;--graphy-canvas-red:#f87171;--graphy-canvas-pink:#f979d9;--graphy-canvas-purple:#a78bfa;--graphy-canvas-gray:#a8a29e;--graphy-canvas-inverse:#000;--graphy-editor-control-height:32px;--graphy-text-scale:1;--graphy-font-family:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-family-heading:"Stack Sans Text", "Inter", -apple-system, BlinkMacSystemFont, "Open Sans", "Segoe UI", "Roboto", "Oxygen-Sans", "Ubuntu", "Cantarell", "Helvetica Neue", "NotoSansArabic", "NotoSansJP", "NotoSansSC", "NotoSansKR", "NotoSerifKR", sans-serif, "Apple Color Emoji", "NotoColorEmoji";--graphy-font-weight-regular:400;--graphy-font-weight-medium:500;--graphy-font-weight-semibold:600;--graphy-font-weight-bold:700;--graphy-font-weight-extra-bold:800;--graphy-font-size-xxs:1em;--graphy-font-size-xs:1.1em;--graphy-font-size-sm:1.2em;--graphy-font-size-md:1.4em;--graphy-font-size-lg:1.6em;--graphy-font-size-xl:2em;--graphy-font-line-height-xxs:1;--graphy-font-line-height-xs:1;--graphy-font-line-height-sm:1.3;--graphy-font-line-height-md:1.43;--graphy-font-line-height-lg:1;--graphy-font-line-height-xl:1;--graphy-font-size-editor-body:1.5em;--graphy-font-size-heading-sm:1.8em;--graphy-font-size-heading-md:2.2em;--graphy-font-size-heading-lg:2.8em;--graphy-font-line-height-editor-body:1.47;--graphy-font-line-height-heading-sm:1.25;--graphy-font-line-height-heading-md:1.41;--graphy-font-line-height-heading-lg:1.29;--graphy-font-uitooltip:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-uitooltip-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-button:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-input-label:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-font-family);--graphy-font-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-select-description:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-color-select-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-group-title:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-menu-item-label:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-menu-item-label-secondary:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-error-boundary-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family);--graphy-font-error-boundary-message:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-cell:var(--graphy-font-weight-medium) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-table-header-cell:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-source-link:var(--graphy-font-weight-regular) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-h1:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-lg)/var(--graphy-font-line-height-heading-lg) var(--graphy-font-family-heading);--graphy-font-text-editor-h2:var(--graphy-font-weight-bold) var(--graphy-font-size-heading-md)/var(--graphy-font-line-height-heading-md) var(--graphy-font-family-heading);--graphy-font-text-editor-h3:var(--graphy-font-weight-semibold) var(--graphy-font-size-heading-sm)/var(--graphy-font-line-height-heading-sm) var(--graphy-font-family-heading);--graphy-font-text-editor-h6:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-text-editor-body:var(--graphy-font-weight-medium) var(--graphy-font-size-editor-body)/var(--graphy-font-line-height-editor-body) var(--graphy-font-family);--graphy-font-text-editor-link:var(--graphy-font-weight-regular) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-title:var(--graphy-font-weight-bold) var(--graphy-font-size-md)/var(--graphy-font-line-height-md) var(--graphy-font-family);--graphy-font-highlight-mode-subtitle:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-font-family);--graphy-font-editor-control-label:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-control-value:var(--graphy-font-weight-medium) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-section-title:var(--graphy-font-weight-semibold) var(--graphy-font-size-sm)/var(--graphy-font-line-height-sm) var(--graphy-editor-font-family,var(--graphy-font-family));--graphy-font-editor-caption:var(--graphy-font-weight-medium) var(--graphy-font-size-xxs)/var(--graphy-font-line-height-xxs) var(--graphy-editor-font-family,var(--graphy-font-family))}._1cocly40{color:inherit;text-underline-offset:.15em;text-decoration:underline}._19519k80{flex-direction:column;gap:4px;min-width:120px;max-width:280px;display:flex}._19519k81{white-space:normal;overflow-wrap:anywhere}._19519k82{flex-direction:column;display:flex}._19519k83{flex-direction:row;align-items:center;gap:8px;display:flex}._19519k84{flex-shrink:0;display:block;overflow:visible}._19519k85{width:12px;height:12px}._19519k86{white-space:nowrap;text-overflow:ellipsis;min-width:0;overflow:hidden}._19519k87{font-variant-numeric:tabular-nums;white-space:nowrap;text-align:right}._19519k88{pointer-events:none;-webkit-user-select:none;user-select:none;z-index:1000;position:fixed;top:0;left:0}._4dlrid0{margin:0}._4dlrid0 :-webkit-any(h1,h2,h3,p){font:inherit;color:inherit;margin:0}._4dlrid0 :is(h1,h2,h3,p){font:inherit;color:inherit;margin:0}.xfz7dq0{position:absolute}.xfz7dq1{align-items:end;column-gap:var(--graphy-space-xs);color:var(--graphy-text-secondary);grid-template-columns:minmax(0,1fr) auto;display:grid}.xfz7dq2{min-width:0}.xfz7dq3{overflow-wrap:anywhere;text-decoration:underline}.xfz7dq3:hover{color:var(--graphy-text-primary)}.xfz7dq4{margin-right:var(--graphy-space-xs)}.xfz7dq5{overflow-wrap:anywhere}._15xngrw0{box-sizing:border-box;white-space:nowrap;color:#2a2a28;opacity:.62;background-color:#ffffff8c;border-radius:999px;flex-shrink:0;align-items:center;gap:4px;height:22px;padding-inline-start:9px;padding-inline-end:11px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,system-ui,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:11.5px;line-height:1;text-decoration:none;transition:opacity .12s,max-width .25s,padding .25s,gap .25s;display:inline-flex;box-shadow:0 1px 4px #00000017}._15xngrw0:hover{opacity:1}._15xngrw0:focus-visible{opacity:1}._15xngrw0:focus-visible{outline-offset:2px;outline:2px solid #2a2a28}._15xngrw0[data-background-tone=mid]{opacity:.8;background-color:#ffffffbf}._15xngrw0[data-background-tone=dark]{opacity:.85;color:#fff;box-shadow:none;background-color:#ffffff14}._15xngrw0[data-background-tone=dark]:focus-visible{outline:2px solid #fff}._15xngrw0[data-variant=mini]{justify-content:center;gap:0;width:22px;padding-inline-start:0;padding-inline-end:0}._15xngrw0[data-variant=mini]:hover{gap:4px;width:auto;padding-inline-start:9px;padding-inline-end:11px}._15xngrw0[data-variant=mini]:focus-visible{gap:4px;width:auto;padding-inline-start:9px;padding-inline-end:11px}._15xngrw1{flex-direction:row-reverse}._15xngrw2{flex-shrink:0;width:10.5px;height:14px;display:block}._15xngrw3{max-width:120px;font-weight:500;transition:max-width .25s,opacity .25s;display:inline-flex;overflow:hidden}._15xngrw0[data-variant=mini] ._15xngrw3{opacity:0;max-width:0}._15xngrw0[data-variant=mini]:hover ._15xngrw3{opacity:1;max-width:120px}._15xngrw0[data-variant=mini]:focus-visible ._15xngrw3{opacity:1;max-width:120px}._15xngrw4{place-self:end}._15xngrw5{position:absolute;top:50%;right:0;transform:translateY(-50%)}@media (prefers-reduced-motion:reduce){._15xngrw0,._15xngrw3{transition:none}}._1k4qtbg0{position:absolute}._1k4qtbg1{padding-right:110px}._1u9qprb0{pointer-events:none;justify-content:start;align-items:start;display:flex;position:absolute}._1u9qprb1{pointer-events:none;justify-content:center;align-items:center;display:flex;position:absolute}._9aen060{align-items:baseline;display:flex}._9aen061,._9aen062{align-items:center;display:flex}._9aen063{flex-direction:column;align-items:start;display:flex}.asohov0{flex-shrink:0}.asohov1{color:var(--graphy-icon-primary)}.asohov2{color:var(--graphy-icon-secondary)}.n7clvo0,.n7clvo1{white-space:nowrap}.n7clvo2{border-radius:50%;justify-content:center;align-items:center;width:12px;height:12px;display:flex}.n7clvo3{transform:rotate(180deg)}._1oj6yix0{pointer-events:none;height:100%;position:relative}._1oj6yix1{pointer-events:none;position:absolute;top:0;left:0;overflow:visible}._1oj6yix2{white-space:nowrap;position:absolute;transform:translateY(-50%)}._1oj6yix3{pointer-events:auto;cursor:pointer;margin-left:-3px;padding:3px}._6a636s0{pointer-events:none;position:absolute}._1isxsac0{white-space:nowrap;flex-shrink:0;display:flex}._1isxsac1{flex-direction:row;align-items:center}._1isxsac2{flex-direction:column;align-items:flex-start}._1isxsac3{margin-inline-start:auto}._1isxsac4,._1isxsac5{flex-direction:row;align-items:center;display:flex}._1isxsac6{text-overflow:ellipsis;overflow:hidden}._1or78v80{box-sizing:border-box;border-style:solid;border-width:1px;border-radius:9999px;flex-shrink:0;transition:inline-size .3s ease-out,block-size .3s ease-out;display:block}._1or78v81{flex-shrink:0;display:block;overflow:visible}@media (prefers-reduced-motion:reduce){._1or78v80{transition:none}}._1cecisi0{pointer-events:none;flex-wrap:nowrap;align-items:center;block-size:100%;inline-size:100%;display:flex}._1cecisi1{flex-direction:row}._1cecisi2{flex-direction:column}._1cecisi3{justify-content:flex-start}._1cecisi3._1cecisi1:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-end}._1cecisi3._1cecisi1:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-end}._1cecisi4{justify-content:center}._1cecisi5{justify-content:flex-end}._1cecisi5._1cecisi1:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-start}._1cecisi5._1cecisi1:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){justify-content:flex-start}._1cecisi6{justify-content:flex-end}._1cecisi7{align-items:flex-start}._1cecisi7:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-end}._1cecisi7:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-end}._1cecisi8{align-items:flex-end}._1cecisi8:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-start}._1cecisi8:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){align-items:flex-start}._1cecisi9{white-space:nowrap;flex-shrink:0;align-items:center;display:flex}._1cecisia{pointer-events:auto;cursor:pointer}._1kjk02r1{pointer-events:auto;flex-shrink:0;align-items:center;display:inline-flex;position:relative}._1kjk02r2{pointer-events:none}._1kjk02r3{padding-inline-start:4px}._1kjk02r4{padding-inline-start:8px}._1kjk02r5{padding-block-start:4px}._1kjk02r6{padding-block-start:8px}._1kjk02r7{pointer-events:none;position:absolute}._1kjk02r8{top:0;bottom:0}._1kjk02r8:not(:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:4px;right:0}._1kjk02r8:not(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:4px;right:0}._1kjk02r8:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:4px}._1kjk02r8:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:4px}._1kjk02r9{top:0;bottom:0}._1kjk02r9:not(:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:8px;right:0}._1kjk02r9:not(:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi))){left:8px;right:0}._1kjk02r9:-webkit-any(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:8px}._1kjk02r9:is(:lang(ae),:lang(ar),:lang(arc),:lang(bcc),:lang(bqi),:lang(ckb),:lang(dv),:lang(fa),:lang(glk),:lang(he),:lang(ku),:lang(mzn),:lang(nqo),:lang(pnb),:lang(ps),:lang(sd),:lang(ug),:lang(ur),:lang(yi)){left:0;right:8px}._1kjk02ra{top:4px;bottom:0;left:0;right:0}._1kjk02rb{top:8px;bottom:0;left:0;right:0}._1kjk02rc{white-space:nowrap;cursor:pointer;pointer-events:auto;-webkit-appearance:none;appearance:none;background:0 0;border:none;align-items:center;padding:0;display:inline-flex;position:relative}._1kjk02rc:focus-visible{outline:1px solid var(--_1kjk02r0)}._1kjk02rd{cursor:default;pointer-events:none}._1kjk02re{font-variant-numeric:tabular-nums}._1kjk02rf{pointer-events:auto;z-index:40;max-width:320px;max-height:240px;overflow-y:auto}._1kjk02rg{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}._1kjk02rh{white-space:nowrap;align-items:center;display:flex}._1kjk02ri,._1i8rg6j0{cursor:pointer}._1aj6s5s0{pointer-events:auto;font-family:var(--graphy-font-family);word-wrap:break-word;white-space:break-spaces;text-align:center;box-sizing:border-box;width:100%}._1aj6s5s0 p,._1aj6s5s0 h1,._1aj6s5s0 h2,._1aj6s5s0 h3{margin:0}._1aj6s5s1 .ProseMirror{outline:none;min-height:1em}._1aj6s5s1 .ProseMirror .is-empty:before{content:attr(data-placeholder);color:currentColor;opacity:.4;float:left;white-space:nowrap;text-overflow:ellipsis;pointer-events:none;width:100%;margin-right:-100%;overflow:hidden}.ph8bdc0{pointer-events:none}.ph8bdc1{flex-shrink:0;align-items:center;display:flex}.ph8bdc2{font-family:var(--graphy-font-family)}.ph8bdc3{box-sizing:border-box;white-space:nowrap;-webkit-user-select:none;user-select:none;flex-direction:row;align-items:center;gap:5px;width:100%;height:100%;display:flex}.ph8bdc4{pointer-events:auto}.ph8bdc5,._1agclyl0,._1agclyl1{pointer-events:none}._1agclyl2{pointer-events:none;font-variant-numeric:tabular-nums}.to1jkx2{stroke-linecap:round;overflow:visible}.to1jkx3{transition:opacity .15s ease-out,filter .15s ease-out}[data-hover-active=true] .to1jkx3{opacity:var(--to1jkx0,1);filter:var(--to1jkx1,none)}._17uhij30{position:absolute;top:0;left:0;overflow:visible}._17uhij30 text{direction:ltr;unicode-bidi:plaintext}._1vl0pke0{pointer-events:none;border-radius:inherit;position:absolute;top:0;bottom:0;left:0;right:0}._1vl0pke1{isolation:isolate}._1vl0pke2{z-index:-1;pointer-events:none;border-radius:inherit;position:absolute;top:0;bottom:0;left:0;right:0}
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./index.css');const s=require("./history-chords-CHDa7G9D.cjs");let m=require("@graphysdk/viz-engine"),u=require("react"),i=require("react/jsx-runtime"),W=require("zustand"),U=require("motion/react"),Q=require("zustand/vanilla"),Y=require("clsx");Y=s.__toESM(Y,1);var Se="_1a5iqpb0",ye="_1a5iqpb1";var be="_1a5iqpb3",Ge="_1a5iqpb4",Te="_1a5iqpb5";var X=({errors:e})=>{const[t,...r]=e;return(0,i.jsxs)("div",{role:"alert",className:Se,children:[(0,i.jsx)("strong",{className:ye,children:"This chart could not be rendered."}),t&&(0,i.jsx)(Z,{diagnostic:t}),r.length>0&&(0,i.jsx)("ul",{className:"_1a5iqpb2",children:r.map((n,o)=>(0,i.jsx)("li",{children:(0,i.jsx)(Z,{diagnostic:n})},`${n.code}-${o}`))})]})},Z=({diagnostic:e})=>(0,i.jsxs)("div",{className:be,children:[(0,i.jsx)("span",{className:Ge,children:e.code}),(0,i.jsx)("p",{className:Te,children:e.message}),e.suggestion&&(0,i.jsx)("p",{className:"_1a5iqpb6",children:e.suggestion})]});function xe(e=[],t=[]){return e.length===t.length&&e.every((r,n)=>Object.is(r,t[n]))}var ae=class extends u.Component{constructor(...e){super(...e),this.state={caughtDiagnostic:null}}static getDerivedStateFromError(e){return{caughtDiagnostic:(0,m.buildDiagnostic)(e)}}componentDidCatch(e,t){const r=(0,m.buildDiagnostic)(e);s.logDiagnostics([r]),this.props.onError?.([r]),console.error("Chart render component stack:",t.componentStack)}componentDidUpdate(e){this.state.caughtDiagnostic&&!xe(e.resetKeys,this.props.resetKeys)&&this.setState({caughtDiagnostic:null})}render(){const{caughtDiagnostic:e}=this.state;if(e)return(0,i.jsx)(X,{errors:[e]});const{forcedErrors:t,children:r}=this.props;return t&&t.length>0?(0,i.jsx)(X,{errors:t}):r}},ce=e=>typeof e=="object"&&"geom"in e&&"render"in e,le=e=>{const t=(0,m.resolveDefinition)(e);return t instanceof m.Geom?t:null},ue=(e,t)=>{const r=e.filter(n=>Ee(n,t));return r.length===e.length?e:r},Ee=(e,t)=>e.kind==="annotation"?(0,m.findAnnotation)(t.annotations,e.id)!==null:e.kind==="observations"||e.kind==="layer"&&e.layerId!==void 0?(0,m.findLayerById)(t.layers,e.layerId)!==void 0:!0,ee=[],Re=()=>(0,Q.createStore)(e=>({selection:ee,setSelection:t=>e(r=>Pe(r.selection,t)?r:{selection:t}),clearSelection:()=>e(t=>t.selection.length===0?t:{selection:ee})})),Pe=(e,t)=>e===t?!0:e.length!==t.length?!1:e.every((r,n)=>{const o=t[n];return o!==void 0&&(0,m.areEditTargetsEqual)(r,o)}),Ce=5,Ie=e=>{if(!s.IS_DEV)return{emit:()=>{},subscribe:()=>je,getLastTrigger:()=>null,getLastCompile:()=>null,getCacheStats:()=>e.getCacheStats()};const t=new Set;let r=null;return{emit:n=>{const o=e.getLastCompile();if(o){r=n;for(const c of t)c(n,o)}},subscribe:n=>(t.add(n),()=>{t.delete(n)}),getLastTrigger:()=>r,getLastCompile:()=>e.getLastCompile(),getCacheStats:()=>e.getCacheStats()}},Ne=()=>(0,Q.createStore)(e=>({lastCompile:null,history:[],nextId:1,lastSnapshot:null,recordCompile:(t,r)=>e(n=>{if(n.lastSnapshot===r)return n;const o={id:n.nextId,label:De(t),stages:r.stages,stageDurationsMs:r.stageDurationsMs,durationMs:r.durationMs};return{lastCompile:o,history:we(n.history,o,Ce),nextId:n.nextId+1,lastSnapshot:r}})})),je=()=>{},De=e=>{switch(e.kind){case"init":return"init";case"spec":return"spec change";case"data":return"data change";case"command":return e.command.metadata.description}},we=(e,t,r)=>{const n=e.length>=r?e.length-(r-1):0;return[...e.slice(n),t]};function te(e){const t=e.filter(ce),r=new Set([...Object.keys(s.BUILT_IN_GEOM_RENDERERS),...t.map(d=>d.geom)]),n=[],o=new Set;for(const d of e){const h=le(d);h===null||r.has(h.type)||o.has(h.type)||(o.add(h.type),n.push({kind:"userInput",severity:"error",code:"MISSING_GEOM_RENDERER",message:`Custom geom '${h.type}' is registered but has no renderer.`,context:{requested:h.type,kind:"geom-renderer"},suggestion:`Add a render half for it: \`defineGeomRenderer(${h.type}Geom, { coord, render })\`, then include it in \`plugins\`.`}))}const c=new Map;for(const d of t){if("definition"in d)continue;const h=`${d.geom}|${d.coord}`,v=c.get(h);v?v.count+=1:c.set(h,{geom:d.geom,coord:d.coord,count:1})}const l=[];for(const{geom:d,coord:h,count:v}of c.values())v<2||l.push({kind:"userInput",severity:"warning",code:"DUPLICATE_REGISTERED_TYPE",message:`Multiple render-only overrides register ('${d}', '${h}') (${v} entries); the last in the array wins.`,context:{requested:`${d}@${h}`,kind:"geom-renderer"},suggestion:`Keep a single render-only override for ('${d}', '${h}').`});return l.push(...Oe(e)),{errors:n,warnings:l}}function Le(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n)t(l.geom,r.type)!==null||o.has(l.geom)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"MISSING_GEOM_RENDERER",message:`No renderer for geom '${l.geom}' under ${r.type} coords; the layer is not painted.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:`Register a renderer for ('${l.geom}', '${r.type}') via \`defineGeomRenderer\`.`}));return c}function _e(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind!=="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||d.hitTest||s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"MISSING_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares spatialKind 'renderHitTest' but its renderer provides no hit-test; the layer has no hover.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:`Add a \`hitTest\` factory (precomputed geometry) or a live render (\`{ fn, options: { live: true } }\`, live simulation) to the renderer for ('${l.geom}', '${r.type}').`}))}return c}function ke(e){const t=new Set,r=[];for(const n of e.layers){const o=n.identityKey;n.interactive!==!1&&(n.spatialKind!=="renderHitTest"||typeof o!="object"||t.has(n.geom)||n.data.hasVariable(o.variable)||(t.add(n.geom),r.push({kind:"userInput",severity:"warning",code:"RENDER_HIT_TEST_IDENTITY",message:`Geom '${n.geom}' keys its identity on '${o.variable}', a column its compile output does not emit; its hover lookup is empty.`,context:{requested:n.geom,kind:"geom-renderer"},suggestion:`Emit the '${o.variable}' column from the geom's \`compile()\`, or point \`identityKey\` at a column it does emit.`})))}return r}function qe(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind!=="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||!d.hitTest||!s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"CONFLICTING_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares both a \`hitTest\` factory and a live render; these are alternatives, so only the live render is used.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:"Keep one: a `hitTest` factory for precomputed geometry, OR a live render (`{ fn, options: { live: true } }`) for a live simulation."}))}return c}function He(e,t){const r=new Set,n=[];for(const o of e.layers)o.interactive!==!1&&(o.spatialKind!=="renderHitTest"||r.has(o.geom)||t.hasCapability(o.geom)||(r.add(o.geom),n.push({kind:"userInput",severity:"warning",code:"MISSING_ANCHOR_CAPABILITY",message:`Geom '${o.geom}' declares no \`resolveAnchorPosition\`; its observations cannot be annotated, so the editor overlay paints no creation trigger on them.`,context:{requested:o.geom,kind:"geom-renderer"},suggestion:"Implement `resolveAnchorPosition(observation, context)` on the geom, returning the normalised panel position an annotation on that observation belongs at."})));return n}function Me(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind==="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||!s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"LIVE_RENDER_REQUIRES_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares a live render but its layer's spatialKind is '${l.spatialKind}', not 'renderHitTest'; its push-path hover resolves to nothing.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:"Have the geom's manifest yield spatialKind 'renderHitTest' so the scene layer carries the `byKey` index the live render's `pushHover` resolves against."}))}return c}function Ae(e,t){let r;return e.layers.flatMap((n,o)=>s.isLiveRender(t(n.geom,e.coordSystem.type))?$e(n)?(r??=(0,m.createStyleResolver)().readers(e),(r.geom(n).get("overpaint",void 0,"hovered")?.length??0)===0?[]:[{kind:"userInput",severity:"warning",code:"INVALID_STYLE_RULE",message:`Style 'overpaint' in state 'hovered' is not supported on live geom '${n.geom}' (layer '${n.id}'); it is ignored.`,context:{param:"overpaint",layerIndex:o,requested:n.geom},suggestion:"Remove the hovered overpaint, or paint the hover treatment in the geom's live render."}]):[]:[])}var $e=e=>[e.styles.defaults,e.styles.overrides].some(t=>t.some(r=>r.state==="hovered"&&(r.declarations.overpaint?.length??0)>0));function Oe(e){const t=new Set,r=[];for(const n of e){const o=le(n);o===null||t.has(o.type)||o.dataLabelCoordTypes.length===0||o.getDataLabelPlacements!==void 0||(t.add(o.type),r.push({kind:"userInput",severity:"warning",code:"MISSING_DATA_LABEL_PLACEMENT",message:`Geom '${o.type}' declares \`dataLabelCoordTypes\` but implements no \`getDataLabelPlacements\`; its layers paint no data labels.`,context:{requested:o.type,kind:"geom-renderer"},suggestion:"Implement `getDataLabelPlacements(context)` on the geom, or drop `dataLabelCoordTypes` so the compiler warns the author off the flag."}))}return r}var Be=e=>(0,Q.createStore)(t=>({scene:e,setScene:r=>t(n=>n.scene===r?n:{scene:r})})),Fe=({spec:e,data:t,colorScheme:r,plugins:n,theme:o,resolveRenderer:c,anchorResolver:l,onSpecChange:d,onError:h,onWarnings:v})=>{const b=s.useLatestRef(d),N=s.useLatestRef(h),x=s.useLatestRef(v),[{session:f,compileBus:p,findGeom:G}]=(0,u.useState)(()=>{const a=(0,m.createCompiler)({plugins:n,theme:o});return{session:new m.GraphCompilationSession(a),compileBus:Ie(a),findGeom:g=>a.findGeom(g)}}),[S]=(0,u.useState)(()=>{const a=te(n??[]),g=te(o?.plugins??[]);return{errors:[...g.errors,...a.errors],warnings:[...g.warnings,...a.warnings]}}),q=(0,u.useRef)(null),[j]=(0,u.useState)(Ke),T=(0,u.useRef)(null),y=(0,u.useCallback)(a=>S.errors.length===0?a:[...S.errors,...a??[]],[S]),L=(0,u.useCallback)(a=>{if(!a.ok)return a.errors;if(T.current)T.current.getState().setScene(a.scene);else{const g=Be(a.scene);g.subscribe(j.notify),T.current=g,j.notify()}return null},[j]),[$,R]=(0,u.useState)(()=>{const a=f.compile({spec:e,data:t,colorScheme:r});return q.current=a,y(L(a))}),P=(0,u.useCallback)(a=>a.ok?[...a.warnings,...Le(a.scene,c),..._e(a.scene,c),...ke(a.scene),...qe(a.scene,c),...Me(a.scene,c),...Ae(a.scene,c),...He(a.scene,l)]:a.warnings,[c,l]),C=(0,u.useCallback)(a=>{a.length!==0&&(s.logDiagnostics(a),N.current?.(a))},[N]),I=(0,u.useCallback)(a=>{a.length!==0&&(s.logDiagnostics(a),x.current?.(a))},[x]);(0,u.useEffect)(()=>{const a=q.current;a&&(C([...S.errors,...a.ok?[]:a.errors]),I([...S.warnings,...P(a)]),a.ok&&p.emit({kind:"init"}))},[p,C,I,S,P]),(0,u.useEffect)(()=>{const a=f.update({spec:e,data:t,colorScheme:r});if(!a)return;a.committedSpec&&b.current?.(a.committedSpec);const g=L(a.result);R(y(g)),g&&C(g),I(P(a.result)),g||p.emit({kind:a.hasSpecChange?"spec":"data"})},[e,t,r,f,p,L,C,I,y,P,b]);const H=(0,u.useCallback)(a=>{R(g=>g===null?g:y(null)),I(P(a))},[y,I,P]),D=(0,u.useCallback)(a=>{a.scene&&T.current?.getState().setScene(a.scene),a.result&&H(a.result),a.command&&p.emit({kind:"command",command:a.command}),a.spec&&b.current?.(a.spec),a.errors&&C([...a.errors])},[H,p,b,C]),E=(0,u.useCallback)(a=>{for(const g of a)D(g);return a.some(g=>!!g.scene)},[D]),O=(0,u.useCallback)((a,g)=>{E(f.applyCommand(a,g))},[f,E]),B=(0,u.useCallback)(()=>{E(f.commit())},[f,E]),F=(0,u.useCallback)(()=>E(f.undo()),[f,E]),M=(0,u.useCallback)(()=>E(f.redo()),[f,E]),_=(0,u.useCallback)(a=>{const g=f.preview(a).find(ve=>ve.scene)?.scene;return g?(T.current?.getState().setScene(g),!0):!1},[f]),K=(0,u.useCallback)(()=>{const a=f.scene;a&&T.current?.getState().setScene(a)},[f]),w=(0,u.useMemo)(()=>({stack:f.history,undo:F,redo:M}),[f,F,M]),V=(0,u.useCallback)(()=>T.current?.getState().scene??null,[]);return{store:T.current,dispatch:O,commit:B,paintPreview:_,clearPreview:K,history:w,subscribe:j.subscribe,getScene:V,compileBus:p,compileErrors:$,findGeom:G}},Ke=()=>{const e=new Set;return{subscribe:t=>(e.add(t),()=>{e.delete(t)}),notify:()=>e.forEach(t=>t())}},ze=["cartesian","polar"],de=({data:e,spec:t,plugins:r=[],theme:n,glyphs:o,formattingLocale:c,handleRef:l,onSpecChange:d,onError:h,onWarnings:v,colorScheme:b="light",children:N})=>{const x=We(c,v),[f]=(0,u.useState)(()=>n),[p]=(0,u.useState)(()=>s.mergeGlyphs(n?.glyphs,o)),G=f?.colorScheme??b,[S]=(0,u.useState)(()=>s.createGeomRendererResolver([...f?.plugins??[],...r].filter(ce)));Ve(S,p);const q=(0,u.useId)(),[j]=(0,u.useState)(()=>(0,m.createAnchorResolver)(r)),[T]=(0,u.useState)(()=>(0,m.createDataLabelPlacementResolver)(r)),[y]=(0,u.useState)(()=>Re()),[L]=(0,u.useState)(()=>s.createTargetBoundaryStore()),$=(0,u.useMemo)(()=>(0,m.createStyleResolver)({colorScheme:G}),[G]),{store:R,dispatch:P,commit:C,paintPreview:I,clearPreview:H,history:D,subscribe:E,getScene:O,compileBus:B,compileErrors:F,findGeom:M}=Fe({spec:t,data:e,colorScheme:G,plugins:r,theme:f,resolveRenderer:S,anchorResolver:j,onSpecChange:d,onError:h,onWarnings:v});(0,u.useEffect)(()=>{if(R)return R.subscribe((w,V)=>{if(w.scene.spec===V.scene.spec)return;const{selection:a,setSelection:g}=y.getState();a.length!==0&&g(ue(a,w.scene.spec))})},[R,y]);const _=(0,u.useMemo)(()=>({dispatch:P,commit:C,paintPreview:I,clearPreview:H}),[P,C,I,H]);(0,u.useImperativeHandle)(l,()=>({commands:_,undo:D.undo,redo:D.redo,subscribe:E,getScene:O,formattingLocale:x,getSelection:()=>y.getState().selection,setSelection:w=>y.getState().setSelection(w),subscribeSelection:y.subscribe,canPlaceDataLabels:T.hasCapability,canFormatDataLabelsAsPercentages:T.hasPercentageFormat,getGlyphs:()=>p,getPointSymbols:w=>S("point",w)?.symbols}),[_,D,E,O,x,y,T,p,S]);const K=(0,u.useMemo)(()=>R?{chartId:q,store:R,selectionStore:y,targetBoundaryStore:L,commands:_,history:D,formattingLocale:x,compileBus:B,colorScheme:G,styleResolver:$,anchorResolver:j,findGeom:M}:null,[q,R,y,L,_,D,x,B,G,$,j,M]);return(0,i.jsx)(ae,{forcedErrors:F,onError:h,resetKeys:[t,e],children:K?(0,i.jsx)(s.GraphContext.Provider,{value:K,children:(0,i.jsx)(s.GeomRendererResolverProvider,{value:S,children:(0,i.jsx)(s.DataLabelPlacementResolverProvider,{value:T,children:(0,i.jsx)(s.GeomShapesProvider,{shapes:f?.shapes,children:(0,i.jsx)(s.GlyphRegistryProvider,{glyphs:p,children:N})})})})}):null})},Ue=(e,t)=>(e??[]).filter(r=>!(0,m.isGeometricSymbol)(r)&&!t.has(r)),Ve=(e,t)=>{(0,u.useEffect)(()=>{if(!s.IS_DEV)return;const r=new Set(t.map(({name:n})=>n));for(const n of ze)for(const o of Ue(e("point",n)?.symbols,r))console.warn(`[graphy] The ${n} point renderer lists "${o}", but no glyph has that name. The shape menu offers it, and SymbolFigure draws the first listed symbol in its place.`)},[e,t])},We=(e,t)=>{const r=s.useLatestRef(t);return(0,u.useEffect)(()=>{if(e===void 0||(0,m.findIntlLocale)(e)!==void 0)return;const n=[{severity:"warning",kind:"userInput",code:"INVALID_FORMATTING_LOCALE",message:`formattingLocale '${e}' is not a tag Intl can format in, so the chart formats in ${m.DEFAULT_LOCALE}.`}];s.logDiagnostics(n),r.current?.(n)},[e,r]),e===void 0?void 0:(0,m.canonicalizeLocale)(e)};function Ye({theme:e,glyphs:t,...r}={}){const n=(0,m.createSpecBuilder)(r);return{...n,GraphProvider:c=>(0,i.jsx)(de,{...c,plugins:n.plugins,theme:e,glyphs:t})}}var k=(e,t)=>{if(typeof e=="number")return Number.isFinite(e)?e:null;if(!e.endsWith("%"))return null;const r=Number.parseFloat(e);return Number.isFinite(r)?r/100*t:null},Xe=({x:e,y:t,width:r,height:n},o)=>{const c=k(e,o.width),l=k(t,o.height),d=k(r,o.width),h=k(n,o.height);return c===null||l===null||d===null||h===null?null:{x:c,y:l,width:d,height:h}},me=({animateTransitions:e,cx:t,cy:r,r:n,effects:o,...c})=>{const l=s.toGeomEffectsStyle(o);return e?(0,i.jsx)(U.motion.circle,{initial:!1,animate:{cx:t,cy:r,r:n},transition:s.DEFAULT_SPRING_TRANSITION,style:l,...c}):(0,i.jsx)("circle",{cx:t,cy:r,r:n,style:l,...c})},he=({animateTransitions:e,x1:t,y1:r,x2:n,y2:o,effects:c,...l})=>{const d=s.toGeomEffectsStyle(c);return e?(0,i.jsx)(U.motion.line,{initial:!1,animate:{x1:t,y1:r,x2:n,y2:o},transition:s.DEFAULT_SPRING_TRANSITION,style:d,...l}):(0,i.jsx)("line",{x1:t,y1:r,x2:n,y2:o,style:d,...l})},ge=({animateTransitions:e,x:t,y:r,width:n,height:o,rx:c,ry:l,effects:d,...h})=>{const v=s.toGeomEffectsStyle(d);return e?(0,i.jsx)(U.motion.rect,{initial:!1,animate:{attrX:t,attrY:r,width:n,height:o,...c!==void 0&&l!==void 0?{rx:c,ry:l}:{}},transition:s.DEFAULT_SPRING_TRANSITION,style:v,...h}):(0,i.jsx)("rect",{x:t,y:r,width:n,height:o,rx:c,ry:l,style:v,...h})},fe=({animateTransitions:e,d:t,source:r,effects:n,...o})=>{const c=s.toGeomEffectsStyle(n);return e?(0,i.jsx)(tt,{d:t,source:r,style:c,...o}):(0,i.jsx)("path",{d:t,style:c,...o})},Qe=e=>{const{Circle:t}=s.useGeomShapes(),{symbol:r,...n}=e;return r!==void 0&&r!=="circle"?(0,i.jsx)("g",{style:s.toGeomEffectsStyle(e.effects),"data-testid":e["data-testid"],children:(0,i.jsx)(s.PointSymbol,{symbol:r,cx:re(e.cx),cy:re(e.cy),size:e.r*2,fill:e.fill??"currentColor",fillOpacity:e.fillOpacity,opacity:e.opacity,stroke:e.stroke,strokeOpacity:e.strokeOpacity,strokeWidth:e.strokeWidth,motion:e.animateTransitions?{transition:s.DEFAULT_SPRING_TRANSITION,intro:!1,fadesIn:!1}:null})}):t===void 0?me(n):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...n})})},Je=e=>{const{Line:t}=s.useGeomShapes();return t===void 0?he(e):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...e})})},Ze=({cornerRadius:e,...t})=>{const{Rect:r}=s.useGeomShapes(),n=s.useGeomViewport()?.size??null,o=s.useGeomPixelsPerUnit(),c={...t,...rt(e,t,n,o)};return r===void 0?ge(c):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(r,{...c})})},et=e=>{const{Path:t}=s.useGeomShapes();return t===void 0?fe(e):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...e})})},re=e=>typeof e=="number"?`${e}px`:e,tt=({d:e,source:t,...r})=>{const n=s.useSvgPathMorph(e,s.DEFAULT_SPRING_TRANSITION,t);return(0,i.jsx)(U.motion.path,{d:n,...r})},rt=(e,t,r,n)=>{if(e===void 0)return{};const o=(0,m.foldGeomCornerRadii)(e);if(o===void 0)return{};const c=nt(t,r,n);if(c===null)return o==="full"?{}:se((0,m.resolveGeomCornerRadiusPx)({cornerRadius:o}),n);const l=Math.min((0,m.resolveGeomCornerRadiusPx)({cornerRadius:o,box:c}),Math.min(c.width,c.height)/2);return se(l,n)},nt=(e,t,r)=>{const n=ne(e.width,t?.width,r.x),o=ne(e.height,t?.height,r.y);return n===null||o===null?null:{width:n,height:o}},ne=(e,t,r)=>{if(typeof e=="number")return Number.isFinite(e)?Math.abs(e)*r:null;if(t===void 0)return null;const n=k(e,t);return n===null?null:Math.abs(n)},se=(e,t)=>t.x<=0||t.y<=0?{rx:0,ry:0}:{rx:e/t.x,ry:e/t.y},st=({symbol:e,size:t,fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l})=>{const d=s.useGlyphRegistry(),h=s.useGeomRendererResolver(),v=s.useSceneSelector(x=>x.coordSystem.type),b=ot(e,h("point",v)?.symbols??[],d),N={size:t,fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l};return(0,m.isGeometricSymbol)(b)?(0,i.jsx)("path",{d:(0,m.buildPointSymbolPath)(b,t),fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l,strokeLinejoin:"round"}):(0,i.jsx)(s.GlyphMark,{symbol:b,glyphs:d,...N})},ot=(e,t,r)=>(0,m.isImageSymbol)(e)||t.includes(e)||!(0,m.isGeometricSymbol)(e)&&r.has(e)?e:t[0]??"circle",it=({children:e,...t})=>{const r=s.useGeomViewport()?.size??null;return(0,i.jsx)("svg",{viewBox:"0 0 1 1",preserveAspectRatio:"none",width:"100%",height:"100%",pointerEvents:"none",...t,children:(0,i.jsx)(s.GeomViewportProvider,{size:r,space:"unit",children:e})})},at=({box:e,children:t})=>{const r=s.useGeomViewportSize(),n=r===null?null:r.width*(e.x1-e.x0),o=r===null?null:r.height*(e.y1-e.y0),c=(0,u.useMemo)(()=>n===null||o===null?null:{width:n,height:o},[n,o]);return(0,i.jsx)("svg",{x:(0,m.toPercent)(e.x0),y:(0,m.toPercent)(e.y0),width:(0,m.toPercent)(e.x1-e.x0),height:(0,m.toPercent)(e.y1-e.y0),overflow:"hidden",pointerEvents:"none",children:(0,i.jsx)(s.GeomViewportProvider,{size:c,children:t})})},ct="drqe3u0",lt="drqe3u1",ut="drqe3u2",dt="drqe3u3",A="drqe3u4",mt="drqe3u5",ht="drqe3u6",gt="drqe3u7",z="drqe3u8",ft="drqe3u9",pt="drqe3ua";var vt="drqe3uc",St="drqe3ud",yt="drqe3ue",bt="drqe3uf";var Gt="drqe3uh",Tt="drqe3ui",oe={enabled:"drqe3uk drqe3uj",disabled:"drqe3ul drqe3uj"},ie={ran:"drqe3un drqe3um",dim:"drqe3uo drqe3um"},pe={ran:"drqe3uq drqe3up",cached:"drqe3ur drqe3up",untouched:"drqe3us drqe3up"},xt=({width:e=440,style:t,className:r}={})=>{const{compileBus:n}=s.useGraphContext(),[o]=(0,u.useState)(()=>Ne()),[c,l]=(0,u.useState)(!1),[d,h]=(0,u.useState)(m.isCompilerCachingEnabled);(0,u.useEffect)(()=>{const{recordCompile:p}=o.getState(),G=n.getLastTrigger(),S=n.getLastCompile();return G&&S&&p(G,S),n.subscribe(p)},[o,n]);const v=(0,W.useStore)(o,p=>p.lastCompile),b=(0,W.useStore)(o,p=>p.history),N=n.getCacheStats(),x=v===null&&b.length===0,f=()=>{h(p=>{const G=!p;return(0,m.setCompilerCachingEnabled)(G),G})};return(0,i.jsxs)("div",{className:(0,Y.default)(pt,r),style:{width:e,...t},children:[(0,i.jsxs)("div",{className:ct,children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:lt,children:"compile cache"}),(0,i.jsx)("div",{className:yt,children:x?"production: stats disabled":v?`last: ${v.label} · ${J(v.durationMs)}`:"awaiting first compile…"})]}),(0,i.jsx)("button",{type:"button",onClick:()=>l(p=>!p),className:bt,children:c?"▾":"▴"})]}),!c&&(0,i.jsxs)("div",{className:"drqe3ub",children:[(0,i.jsxs)("button",{type:"button",onClick:f,className:d?oe.enabled:oe.disabled,"aria-pressed":d,children:["cache ",d?"enabled":"disabled"]}),(0,i.jsx)("span",{className:"drqe3ug",children:"next compile reflects this toggle"})]}),!c&&!x&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(Et,{delta:v?.stages,durations:v?.stageDurationsMs,cumulative:N}),(0,i.jsx)(Rt,{entries:b})]})]})},Et=({delta:e,durations:t,cumulative:r})=>(0,i.jsxs)("table",{className:ut,children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{className:Gt,children:[(0,i.jsx)("th",{className:dt,children:"stage"}),(0,i.jsx)("th",{className:A,children:"time"}),(0,i.jsx)("th",{className:A,children:"Δ miss"}),(0,i.jsx)("th",{className:A,children:"Δ hit"}),(0,i.jsx)("th",{className:A,children:"total miss"}),(0,i.jsx)("th",{className:A,children:"total hit"})]})}),(0,i.jsx)("tbody",{children:m.COMPILER_STAGE_KEYS.map(n=>{const o=e?.[n],c=Pt(o);return(0,i.jsxs)("tr",{className:vt,children:[(0,i.jsxs)("td",{className:mt,children:[(0,i.jsx)("span",{className:pe[c],"aria-hidden":!0})," ",n]}),(0,i.jsx)("td",{className:z,children:t===void 0||c==="untouched"?"—":J(t[n])}),(0,i.jsx)("td",{className:c==="ran"?ie.ran:ie.dim,children:o?.misses??0}),(0,i.jsx)("td",{className:z,children:o?.hits??0}),(0,i.jsx)("td",{className:z,children:r[n].misses}),(0,i.jsx)("td",{className:z,children:r[n].hits})]},n)})})]}),Rt=({entries:e})=>e.length===0?null:(0,i.jsxs)("div",{className:St,children:[(0,i.jsx)("div",{className:Tt,children:"recent compiles"}),e.map(t=>{const r=Ct(t.stages,c=>c.misses>0),n=m.COMPILER_STAGE_KEYS.length,o=r===0?"cached":"ran";return(0,i.jsxs)("div",{className:ht,children:[(0,i.jsx)("span",{className:pe[o],"aria-hidden":!0}),(0,i.jsx)("span",{className:gt,title:t.label,children:t.label}),(0,i.jsxs)("span",{className:ft,children:[r,"/",n," ran · ",J(t.durationMs)]})]},t.id)})]}),Pt=e=>!e||e.hits===0&&e.misses===0?"untouched":e.misses>0?"ran":"cached",Ct=(e,t)=>{let r=0;for(const n of m.COMPILER_STAGE_KEYS)t(e[n])&&(r+=1);return r},J=e=>e<.1?"<0.1ms":e>=10?`${e.toFixed(0)}ms`:`${e.toFixed(2)}ms`,It=()=>{const{history:e}=s.useGraphContext(),{stack:t,undo:r,redo:n}=e,o=(0,u.useCallback)(d=>t.subscribe(d),[t]),c=(0,u.useCallback)(()=>t.getSnapshot(),[t]),l=(0,u.useSyncExternalStore)(o,c,c);return(0,u.useMemo)(()=>({...l,undo:r,redo:n}),[l,r,n])},Nt=new Set(["button","checkbox","color","file","hidden","image","radio","range","reset","submit"]),jt=(e,t={})=>{const{target:r,enabled:n=!0}=t;(0,u.useEffect)(()=>{const o=Dt(r);if(!n||!o)return;const c=l=>{if(!wt(l)||l.defaultPrevented||Lt(l.target))return;const d=s.resolveHistoryStep(l);if(!d)return;const h=e.current;h&&(d==="undo"?h.undo():h.redo())&&l.preventDefault()};return o.addEventListener("keydown",c),()=>o.removeEventListener("keydown",c)},[e,r,n])},Dt=e=>e===void 0?window:e!==null&&"current"in e?e.current:e,wt=e=>"key"in e,Lt=e=>e instanceof HTMLInputElement?!Nt.has(e.type):e instanceof HTMLElement?e.isContentEditable||e.tagName==="TEXTAREA":!1,_t=()=>{const{targetBoundaryStore:e}=s.useGraphContext();return(0,W.useStore)(e,t=>t.boundary)};exports.CanvasTextMeasurer=s.CanvasTextMeasurer;exports.DefaultFooter=s.DefaultFooter;exports.DefaultGeomCircle=me;exports.DefaultGeomLine=he;exports.DefaultGeomPath=fe;exports.DefaultGeomRect=ge;exports.DefaultGrid=s.DefaultGrid;exports.DefaultHeader=s.DefaultHeader;exports.DefaultSwatch=s.DefaultSwatch;exports.DefaultTooltip=s.DefaultTooltip;exports.DevToolsPanel=xt;exports.GRAPH_MODES=s.GRAPH_MODES;exports.GeomCircle=Qe;exports.GeomLine=Je;exports.GeomOverpaint=s.GeomOverpaint;exports.GeomPanelSizeProvider=s.GeomPanelSizeProvider;exports.GeomPath=et;exports.GeomRect=Ze;exports.GraphErrorBoundary=ae;exports.GraphErrorPanel=X;exports.GraphProvider=de;exports.GraphRenderer=s.GraphRenderer;exports.GraphyBadge=s.GraphyBadge;exports.HoverProvider=s.HoverProvider;exports.IntlProvider=s.ChartIntlProvider;exports.IntroFade=s.IntroFade;exports.IntroWipeClip=s.IntroWipeClip;exports.SymbolFigure=st;exports.TextMeasurerProvider=s.TextMeasurerProvider;exports.ThemeProvider=s.ThemeProvider;exports.UnitBoxSvg=at;exports.UnitSpaceSvg=it;exports.buildDotsEditOutlineShapes=s.buildDotsEditOutlineShapes;exports.createGraphyKit=Ye;exports.darkTheme=s.darkTheme;exports.defineGeomRenderer=s.defineGeomRenderer;exports.defineGlyph=s.defineGlyph;exports.getBuiltInEditOutlineShapes=s.getBuiltInEditOutlineShapes;exports.lightTheme=s.lightTheme;exports.lightenCss=s.lightenCss;exports.pruneSelection=ue;exports.readPositionPixels=k;exports.readRectPixels=Xe;exports.resolveGraphyBadgeVariant=s.resolveGraphyBadgeVariant;exports.resolvePathStroke=s.resolvePathStroke;exports.scalePointToPanel=s.scalePointToPanel;exports.stampAxisEditTarget=s.stampAxisEditTarget;exports.stampGridEditTarget=s.stampGridEditTarget;exports.stampLegendEditTarget=s.stampLegendEditTarget;exports.useElementScreenRect=s.useElementScreenRect;exports.useFormattingLocale=s.useFormattingLocale;exports.useGeomHitTest=s.useGeomHitTest;exports.useGeomHover=s.useGeomHover;exports.useGeomPanelSize=s.useGeomPanelSize;exports.useGeomReaderTree=s.useGeomReaderTree;exports.useGeomStyleReader=s.useGeomStyleReader;exports.useGeomViewportSize=s.useGeomViewportSize;exports.useGraphCommands=s.useGraphCommands;exports.useGraphHandle=s.useGraphHandle;exports.useGraphHistory=It;exports.useGraphHistoryShortcuts=jt;exports.useGraphLocale=s.useGraphLocale;exports.useGraphSelection=s.useGraphSelection;exports.useGuidesTakePress=s.useGuidesTakePress;exports.useHandleScene=s.useHandleScene;exports.useHoverState=s.useHoverState;exports.usePaintDefs=s.usePaintDefs;exports.useResolvedStyle=s.useResolvedStyle;exports.useSceneSelector=s.useSceneSelector;exports.useStyleReaderTree=s.useStyleReaderTree;exports.useStyleResolver=s.useStyleResolver;exports.useTargetBoundary=_t;exports.useTextMeasurer=s.useTextMeasurer;exports.vars=s.vars;
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./index.css');const s=require("./history-chords-B_gzoztJ.cjs");let m=require("@graphysdk/viz-engine"),u=require("react"),i=require("react/jsx-runtime"),W=require("zustand"),U=require("motion/react"),Q=require("zustand/vanilla"),Y=require("clsx");Y=s.__toESM(Y,1);var Se="_1a5iqpb0",ye="_1a5iqpb1";var Ge="_1a5iqpb3",be="_1a5iqpb4",Te="_1a5iqpb5";var X=({errors:e})=>{const[t,...r]=e;return(0,i.jsxs)("div",{role:"alert",className:Se,children:[(0,i.jsx)("strong",{className:ye,children:"This chart could not be rendered."}),t&&(0,i.jsx)(Z,{diagnostic:t}),r.length>0&&(0,i.jsx)("ul",{className:"_1a5iqpb2",children:r.map((n,o)=>(0,i.jsx)("li",{children:(0,i.jsx)(Z,{diagnostic:n})},`${n.code}-${o}`))})]})},Z=({diagnostic:e})=>(0,i.jsxs)("div",{className:Ge,children:[(0,i.jsx)("span",{className:be,children:e.code}),(0,i.jsx)("p",{className:Te,children:e.message}),e.suggestion&&(0,i.jsx)("p",{className:"_1a5iqpb6",children:e.suggestion})]});function xe(e=[],t=[]){return e.length===t.length&&e.every((r,n)=>Object.is(r,t[n]))}var ae=class extends u.Component{constructor(...e){super(...e),this.state={caughtDiagnostic:null}}static getDerivedStateFromError(e){return{caughtDiagnostic:(0,m.buildDiagnostic)(e)}}componentDidCatch(e,t){const r=(0,m.buildDiagnostic)(e);s.logDiagnostics([r]),this.props.onError?.([r]),console.error("Chart render component stack:",t.componentStack)}componentDidUpdate(e){this.state.caughtDiagnostic&&!xe(e.resetKeys,this.props.resetKeys)&&this.setState({caughtDiagnostic:null})}render(){const{caughtDiagnostic:e}=this.state;if(e)return(0,i.jsx)(X,{errors:[e]});const{forcedErrors:t,children:r}=this.props;return t&&t.length>0?(0,i.jsx)(X,{errors:t}):r}},ce=e=>typeof e=="object"&&"geom"in e&&"render"in e,le=e=>{const t=(0,m.resolveDefinition)(e);return t instanceof m.Geom?t:null},ue=(e,t)=>{const r=e.filter(n=>Ee(n,t));return r.length===e.length?e:r},Ee=(e,t)=>e.kind==="annotation"?(0,m.findAnnotation)(t.annotations,e.id)!==null:e.kind==="observations"||e.kind==="layer"&&e.layerId!==void 0?(0,m.findLayerById)(t.layers,e.layerId)!==void 0:!0,ee=[],Re=()=>(0,Q.createStore)(e=>({selection:ee,setSelection:t=>e(r=>Pe(r.selection,t)?r:{selection:t}),clearSelection:()=>e(t=>t.selection.length===0?t:{selection:ee})})),Pe=(e,t)=>e===t?!0:e.length!==t.length?!1:e.every((r,n)=>{const o=t[n];return o!==void 0&&(0,m.areEditTargetsEqual)(r,o)}),Ce=5,Ie=e=>{if(!s.IS_DEV)return{emit:()=>{},subscribe:()=>je,getLastTrigger:()=>null,getLastCompile:()=>null,getCacheStats:()=>e.getCacheStats()};const t=new Set;let r=null;return{emit:n=>{const o=e.getLastCompile();if(o){r=n;for(const c of t)c(n,o)}},subscribe:n=>(t.add(n),()=>{t.delete(n)}),getLastTrigger:()=>r,getLastCompile:()=>e.getLastCompile(),getCacheStats:()=>e.getCacheStats()}},Ne=()=>(0,Q.createStore)(e=>({lastCompile:null,history:[],nextId:1,lastSnapshot:null,recordCompile:(t,r)=>e(n=>{if(n.lastSnapshot===r)return n;const o={id:n.nextId,label:De(t),stages:r.stages,stageDurationsMs:r.stageDurationsMs,durationMs:r.durationMs};return{lastCompile:o,history:we(n.history,o,Ce),nextId:n.nextId+1,lastSnapshot:r}})})),je=()=>{},De=e=>{switch(e.kind){case"init":return"init";case"spec":return"spec change";case"data":return"data change";case"command":return e.command.metadata.description}},we=(e,t,r)=>{const n=e.length>=r?e.length-(r-1):0;return[...e.slice(n),t]};function te(e){const t=e.filter(ce),r=new Set([...Object.keys(s.BUILT_IN_GEOM_RENDERERS),...t.map(d=>d.geom)]),n=[],o=new Set;for(const d of e){const h=le(d);h===null||r.has(h.type)||o.has(h.type)||(o.add(h.type),n.push({kind:"userInput",severity:"error",code:"MISSING_GEOM_RENDERER",message:`Custom geom '${h.type}' is registered but has no renderer.`,context:{requested:h.type,kind:"geom-renderer"},suggestion:`Add a render half for it: \`defineGeomRenderer(${h.type}Geom, { coord, render })\`, then include it in \`plugins\`.`}))}const c=new Map;for(const d of t){if("definition"in d)continue;const h=`${d.geom}|${d.coord}`,v=c.get(h);v?v.count+=1:c.set(h,{geom:d.geom,coord:d.coord,count:1})}const l=[];for(const{geom:d,coord:h,count:v}of c.values())v<2||l.push({kind:"userInput",severity:"warning",code:"DUPLICATE_REGISTERED_TYPE",message:`Multiple render-only overrides register ('${d}', '${h}') (${v} entries); the last in the array wins.`,context:{requested:`${d}@${h}`,kind:"geom-renderer"},suggestion:`Keep a single render-only override for ('${d}', '${h}').`});return l.push(...Oe(e)),{errors:n,warnings:l}}function Le(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n)t(l.geom,r.type)!==null||o.has(l.geom)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"MISSING_GEOM_RENDERER",message:`No renderer for geom '${l.geom}' under ${r.type} coords; the layer is not painted.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:`Register a renderer for ('${l.geom}', '${r.type}') via \`defineGeomRenderer\`.`}));return c}function _e(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind!=="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||d.hitTest||s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"MISSING_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares spatialKind 'renderHitTest' but its renderer provides no hit-test; the layer has no hover.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:`Add a \`hitTest\` factory (precomputed geometry) or a live render (\`{ fn, options: { live: true } }\`, live simulation) to the renderer for ('${l.geom}', '${r.type}').`}))}return c}function ke(e){const t=new Set,r=[];for(const n of e.layers){const o=n.identityKey;n.interactive!==!1&&(n.spatialKind!=="renderHitTest"||typeof o!="object"||t.has(n.geom)||n.data.hasVariable(o.variable)||(t.add(n.geom),r.push({kind:"userInput",severity:"warning",code:"RENDER_HIT_TEST_IDENTITY",message:`Geom '${n.geom}' keys its identity on '${o.variable}', a column its compile output does not emit; its hover lookup is empty.`,context:{requested:n.geom,kind:"geom-renderer"},suggestion:`Emit the '${o.variable}' column from the geom's \`compile()\`, or point \`identityKey\` at a column it does emit.`})))}return r}function qe(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind!=="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||!d.hitTest||!s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"CONFLICTING_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares both a \`hitTest\` factory and a live render; these are alternatives, so only the live render is used.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:"Keep one: a `hitTest` factory for precomputed geometry, OR a live render (`{ fn, options: { live: true } }`) for a live simulation."}))}return c}function He(e,t){const r=new Set,n=[];for(const o of e.layers)o.interactive!==!1&&(o.spatialKind!=="renderHitTest"||r.has(o.geom)||t.hasCapability(o.geom)||(r.add(o.geom),n.push({kind:"userInput",severity:"warning",code:"MISSING_ANCHOR_CAPABILITY",message:`Geom '${o.geom}' declares no \`resolveAnchorPosition\`; its observations cannot be annotated, so the editor overlay paints no creation trigger on them.`,context:{requested:o.geom,kind:"geom-renderer"},suggestion:"Implement `resolveAnchorPosition(observation, context)` on the geom, returning the normalised panel position an annotation on that observation belongs at."})));return n}function Me(e,t){const{coordSystem:r,layers:n}=e,o=new Set,c=[];for(const l of n){if(l.interactive===!1||l.spatialKind==="renderHitTest"||o.has(l.geom))continue;const d=t(l.geom,r.type);d===null||!s.isLiveRender(d)||(o.add(l.geom),c.push({kind:"userInput",severity:"warning",code:"LIVE_RENDER_REQUIRES_RENDER_HIT_TEST",message:`Geom '${l.geom}' declares a live render but its layer's spatialKind is '${l.spatialKind}', not 'renderHitTest'; its push-path hover resolves to nothing.`,context:{requested:l.geom,kind:"geom-renderer"},suggestion:"Have the geom's manifest yield spatialKind 'renderHitTest' so the scene layer carries the `byKey` index the live render's `pushHover` resolves against."}))}return c}function Ae(e,t){let r;return e.layers.flatMap((n,o)=>s.isLiveRender(t(n.geom,e.coordSystem.type))?$e(n)?(r??=(0,m.createStyleResolver)().readers(e),(r.geom(n).get("overpaint",void 0,"hovered")?.length??0)===0?[]:[{kind:"userInput",severity:"warning",code:"INVALID_STYLE_RULE",message:`Style 'overpaint' in state 'hovered' is not supported on live geom '${n.geom}' (layer '${n.id}'); it is ignored.`,context:{param:"overpaint",layerIndex:o,requested:n.geom},suggestion:"Remove the hovered overpaint, or paint the hover treatment in the geom's live render."}]):[]:[])}var $e=e=>[e.styles.defaults,e.styles.overrides].some(t=>t.some(r=>r.state==="hovered"&&(r.declarations.overpaint?.length??0)>0));function Oe(e){const t=new Set,r=[];for(const n of e){const o=le(n);o===null||t.has(o.type)||o.dataLabelCoordTypes.length===0||o.getDataLabelPlacements!==void 0||(t.add(o.type),r.push({kind:"userInput",severity:"warning",code:"MISSING_DATA_LABEL_PLACEMENT",message:`Geom '${o.type}' declares \`dataLabelCoordTypes\` but implements no \`getDataLabelPlacements\`; its layers paint no data labels.`,context:{requested:o.type,kind:"geom-renderer"},suggestion:"Implement `getDataLabelPlacements(context)` on the geom, or drop `dataLabelCoordTypes` so the compiler warns the author off the flag."}))}return r}var Be=e=>(0,Q.createStore)(t=>({scene:e,setScene:r=>t(n=>n.scene===r?n:{scene:r})})),Fe=({spec:e,data:t,colorScheme:r,plugins:n,theme:o,resolveRenderer:c,anchorResolver:l,onSpecChange:d,onError:h,onWarnings:v})=>{const G=s.useLatestRef(d),N=s.useLatestRef(h),x=s.useLatestRef(v),[{session:p,compileBus:f,findGeom:b}]=(0,u.useState)(()=>{const a=(0,m.createCompiler)({plugins:n,theme:o});return{session:new m.GraphCompilationSession(a),compileBus:Ie(a),findGeom:g=>a.findGeom(g)}}),[S]=(0,u.useState)(()=>{const a=te(n??[]),g=te(o?.plugins??[]);return{errors:[...g.errors,...a.errors],warnings:[...g.warnings,...a.warnings]}}),q=(0,u.useRef)(null),[j]=(0,u.useState)(Ke),T=(0,u.useRef)(null),y=(0,u.useCallback)(a=>S.errors.length===0?a:[...S.errors,...a??[]],[S]),L=(0,u.useCallback)(a=>{if(!a.ok)return a.errors;if(T.current)T.current.getState().setScene(a.scene);else{const g=Be(a.scene);g.subscribe(j.notify),T.current=g,j.notify()}return null},[j]),[$,R]=(0,u.useState)(()=>{const a=p.compile({spec:e,data:t,colorScheme:r});return q.current=a,y(L(a))}),P=(0,u.useCallback)(a=>a.ok?[...a.warnings,...Le(a.scene,c),..._e(a.scene,c),...ke(a.scene),...qe(a.scene,c),...Me(a.scene,c),...Ae(a.scene,c),...He(a.scene,l)]:a.warnings,[c,l]),C=(0,u.useCallback)(a=>{a.length!==0&&(s.logDiagnostics(a),N.current?.(a))},[N]),I=(0,u.useCallback)(a=>{a.length!==0&&(s.logDiagnostics(a),x.current?.(a))},[x]);(0,u.useEffect)(()=>{const a=q.current;a&&(C([...S.errors,...a.ok?[]:a.errors]),I([...S.warnings,...P(a)]),a.ok&&f.emit({kind:"init"}))},[f,C,I,S,P]),(0,u.useEffect)(()=>{const a=p.update({spec:e,data:t,colorScheme:r});if(!a)return;a.committedSpec&&G.current?.(a.committedSpec);const g=L(a.result);R(y(g)),g&&C(g),I(P(a.result)),g||f.emit({kind:a.hasSpecChange?"spec":"data"})},[e,t,r,p,f,L,C,I,y,P,G]);const H=(0,u.useCallback)(a=>{R(g=>g===null?g:y(null)),I(P(a))},[y,I,P]),D=(0,u.useCallback)(a=>{a.scene&&T.current?.getState().setScene(a.scene),a.result&&H(a.result),a.command&&f.emit({kind:"command",command:a.command}),a.spec&&G.current?.(a.spec),a.errors&&C([...a.errors])},[H,f,G,C]),E=(0,u.useCallback)(a=>{for(const g of a)D(g);return a.some(g=>!!g.scene)},[D]),O=(0,u.useCallback)((a,g)=>{E(p.applyCommand(a,g))},[p,E]),B=(0,u.useCallback)(()=>{E(p.commit())},[p,E]),F=(0,u.useCallback)(()=>E(p.undo()),[p,E]),M=(0,u.useCallback)(()=>E(p.redo()),[p,E]),_=(0,u.useCallback)(a=>{const g=p.preview(a).find(ve=>ve.scene)?.scene;return g?(T.current?.getState().setScene(g),!0):!1},[p]),K=(0,u.useCallback)(()=>{const a=p.scene;a&&T.current?.getState().setScene(a)},[p]),w=(0,u.useMemo)(()=>({stack:p.history,undo:F,redo:M}),[p,F,M]),V=(0,u.useCallback)(()=>T.current?.getState().scene??null,[]);return{store:T.current,dispatch:O,commit:B,paintPreview:_,clearPreview:K,history:w,subscribe:j.subscribe,getScene:V,compileBus:f,compileErrors:$,findGeom:b}},Ke=()=>{const e=new Set;return{subscribe:t=>(e.add(t),()=>{e.delete(t)}),notify:()=>e.forEach(t=>t())}},ze=["cartesian","polar"],de=({data:e,spec:t,plugins:r=[],theme:n,glyphs:o,formattingLocale:c,handleRef:l,onSpecChange:d,onError:h,onWarnings:v,colorScheme:G="light",children:N})=>{const x=We(c,v),[p]=(0,u.useState)(()=>n),[f]=(0,u.useState)(()=>s.mergeGlyphs(n?.glyphs,o)),b=p?.colorScheme??G,[S]=(0,u.useState)(()=>s.createGeomRendererResolver([...p?.plugins??[],...r].filter(ce)));Ve(S,f);const q=(0,u.useId)(),[j]=(0,u.useState)(()=>(0,m.createAnchorResolver)(r)),[T]=(0,u.useState)(()=>(0,m.createDataLabelPlacementResolver)(r)),[y]=(0,u.useState)(()=>Re()),[L]=(0,u.useState)(()=>s.createTargetBoundaryStore()),$=(0,u.useMemo)(()=>(0,m.createStyleResolver)({colorScheme:b}),[b]),{store:R,dispatch:P,commit:C,paintPreview:I,clearPreview:H,history:D,subscribe:E,getScene:O,compileBus:B,compileErrors:F,findGeom:M}=Fe({spec:t,data:e,colorScheme:b,plugins:r,theme:p,resolveRenderer:S,anchorResolver:j,onSpecChange:d,onError:h,onWarnings:v});(0,u.useEffect)(()=>{if(R)return R.subscribe((w,V)=>{if(w.scene.spec===V.scene.spec)return;const{selection:a,setSelection:g}=y.getState();a.length!==0&&g(ue(a,w.scene.spec))})},[R,y]);const _=(0,u.useMemo)(()=>({dispatch:P,commit:C,paintPreview:I,clearPreview:H}),[P,C,I,H]);(0,u.useImperativeHandle)(l,()=>({commands:_,undo:D.undo,redo:D.redo,subscribe:E,getScene:O,formattingLocale:x,getSelection:()=>y.getState().selection,setSelection:w=>y.getState().setSelection(w),subscribeSelection:y.subscribe,canPlaceDataLabels:T.hasCapability,canFormatDataLabelsAsPercentages:T.hasPercentageFormat,getGlyphs:()=>f,getPointSymbols:w=>S("point",w)?.symbols}),[_,D,E,O,x,y,T,f,S]);const K=(0,u.useMemo)(()=>R?{chartId:q,store:R,selectionStore:y,targetBoundaryStore:L,commands:_,history:D,formattingLocale:x,compileBus:B,colorScheme:b,styleResolver:$,anchorResolver:j,findGeom:M}:null,[q,R,y,L,_,D,x,B,b,$,j,M]);return(0,i.jsx)(ae,{forcedErrors:F,onError:h,resetKeys:[t,e],children:K?(0,i.jsx)(s.GraphContext.Provider,{value:K,children:(0,i.jsx)(s.GeomRendererResolverProvider,{value:S,children:(0,i.jsx)(s.DataLabelPlacementResolverProvider,{value:T,children:(0,i.jsx)(s.GeomShapesProvider,{shapes:p?.shapes,children:(0,i.jsx)(s.GlyphRegistryProvider,{glyphs:f,children:N})})})})}):null})},Ue=(e,t)=>(e??[]).filter(r=>!(0,m.isGeometricSymbol)(r)&&!t.has(r)),Ve=(e,t)=>{(0,u.useEffect)(()=>{if(!s.IS_DEV)return;const r=new Set(t.map(({name:n})=>n));for(const n of ze)for(const o of Ue(e("point",n)?.symbols,r))console.warn(`[graphy] The ${n} point renderer lists "${o}", but no glyph has that name. The shape menu offers it, and SymbolFigure draws the first listed symbol in its place.`)},[e,t])},We=(e,t)=>{const r=s.useLatestRef(t);return(0,u.useEffect)(()=>{if(e===void 0||(0,m.findIntlLocale)(e)!==void 0)return;const n=[{severity:"warning",kind:"userInput",code:"INVALID_FORMATTING_LOCALE",message:`formattingLocale '${e}' is not a tag Intl can format in, so the chart formats in ${m.DEFAULT_LOCALE}.`}];s.logDiagnostics(n),r.current?.(n)},[e,r]),e===void 0?void 0:(0,m.canonicalizeLocale)(e)};function Ye({theme:e,glyphs:t,...r}={}){const n=(0,m.createSpecBuilder)(r);return{...n,GraphProvider:c=>(0,i.jsx)(de,{...c,plugins:n.plugins,theme:e,glyphs:t})}}var k=(e,t)=>{if(typeof e=="number")return Number.isFinite(e)?e:null;if(!e.endsWith("%"))return null;const r=Number.parseFloat(e);return Number.isFinite(r)?r/100*t:null},Xe=({x:e,y:t,width:r,height:n},o)=>{const c=k(e,o.width),l=k(t,o.height),d=k(r,o.width),h=k(n,o.height);return c===null||l===null||d===null||h===null?null:{x:c,y:l,width:d,height:h}},me=({animateTransitions:e,cx:t,cy:r,r:n,effects:o,...c})=>{const l=s.toGeomEffectsStyle(o);return e?(0,i.jsx)(U.motion.circle,{initial:!1,animate:{cx:t,cy:r,r:n},transition:s.DEFAULT_SPRING_TRANSITION,style:l,...c}):(0,i.jsx)("circle",{cx:t,cy:r,r:n,style:l,...c})},he=({animateTransitions:e,x1:t,y1:r,x2:n,y2:o,effects:c,...l})=>{const d=s.toGeomEffectsStyle(c);return e?(0,i.jsx)(U.motion.line,{initial:!1,animate:{x1:t,y1:r,x2:n,y2:o},transition:s.DEFAULT_SPRING_TRANSITION,style:d,...l}):(0,i.jsx)("line",{x1:t,y1:r,x2:n,y2:o,style:d,...l})},ge=({animateTransitions:e,x:t,y:r,width:n,height:o,rx:c,ry:l,effects:d,...h})=>{const v=s.toGeomEffectsStyle(d);return e?(0,i.jsx)(U.motion.rect,{initial:!1,animate:{attrX:t,attrY:r,width:n,height:o,...c!==void 0&&l!==void 0?{rx:c,ry:l}:{}},transition:s.DEFAULT_SPRING_TRANSITION,style:v,...h}):(0,i.jsx)("rect",{x:t,y:r,width:n,height:o,rx:c,ry:l,style:v,...h})},pe=({animateTransitions:e,d:t,source:r,effects:n,...o})=>{const c=s.toGeomEffectsStyle(n);return e?(0,i.jsx)(tt,{d:t,source:r,style:c,...o}):(0,i.jsx)("path",{d:t,style:c,...o})},Qe=e=>{const{Circle:t}=s.useGeomShapes(),{animateTransitions:r}=s.useGraphAnimation(),{symbol:n,...o}=e,c={...o,animateTransitions:r};return n!==void 0&&n!=="circle"?(0,i.jsx)("g",{style:s.toGeomEffectsStyle(e.effects),"data-testid":e["data-testid"],children:(0,i.jsx)(s.PointSymbol,{symbol:n,cx:re(e.cx),cy:re(e.cy),size:e.r*2,fill:e.fill??"currentColor",fillOpacity:e.fillOpacity,opacity:e.opacity,stroke:e.stroke,strokeOpacity:e.strokeOpacity,strokeWidth:e.strokeWidth,motion:r?{transition:s.DEFAULT_SPRING_TRANSITION,intro:!1,fadesIn:!1}:null})}):t===void 0?me(c):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...c})})},Je=e=>{const{Line:t}=s.useGeomShapes(),{animateTransitions:r}=s.useGraphAnimation(),n={...e,animateTransitions:r};return t===void 0?he(n):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...n})})},Ze=({cornerRadius:e,...t})=>{const{Rect:r}=s.useGeomShapes(),n=s.useGeomViewport()?.size??null,o=s.useGeomPixelsPerUnit(),{animateTransitions:c}=s.useGraphAnimation(),l={...t,animateTransitions:c,...rt(e,t,n,o)};return r===void 0?ge(l):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(r,{...l})})},et=e=>{const{Path:t}=s.useGeomShapes(),{animateTransitions:r}=s.useGraphAnimation(),n={...e,animateTransitions:r};return t===void 0?pe(n):(0,i.jsx)(s.GeomShapesProvider,{children:(0,i.jsx)(t,{...n})})},re=e=>typeof e=="number"?`${e}px`:e,tt=({d:e,source:t,...r})=>{const n=s.useSvgPathMorph(e,s.DEFAULT_SPRING_TRANSITION,t);return(0,i.jsx)(U.motion.path,{d:n,...r})},rt=(e,t,r,n)=>{if(e===void 0)return{};const o=(0,m.foldGeomCornerRadii)(e);if(o===void 0)return{};const c=nt(t,r,n);if(c===null)return o==="full"?{}:se((0,m.resolveGeomCornerRadiusPx)({cornerRadius:o}),n);const l=Math.min((0,m.resolveGeomCornerRadiusPx)({cornerRadius:o,box:c}),Math.min(c.width,c.height)/2);return se(l,n)},nt=(e,t,r)=>{const n=ne(e.width,t?.width,r.x),o=ne(e.height,t?.height,r.y);return n===null||o===null?null:{width:n,height:o}},ne=(e,t,r)=>{if(typeof e=="number")return Number.isFinite(e)?Math.abs(e)*r:null;if(t===void 0)return null;const n=k(e,t);return n===null?null:Math.abs(n)},se=(e,t)=>t.x<=0||t.y<=0?{rx:0,ry:0}:{rx:e/t.x,ry:e/t.y},st=({symbol:e,size:t,fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l})=>{const d=s.useGlyphRegistry(),h=s.useGeomRendererResolver(),v=s.useSceneSelector(x=>x.coordSystem.type),G=ot(e,h("point",v)?.symbols??[],d),N={size:t,fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l};return(0,m.isGeometricSymbol)(G)?(0,i.jsx)("path",{d:(0,m.buildPointSymbolPath)(G,t),fill:r,fillOpacity:n,stroke:o,strokeOpacity:c,strokeWidth:l,strokeLinejoin:"round"}):(0,i.jsx)(s.GlyphMark,{symbol:G,glyphs:d,...N})},ot=(e,t,r)=>(0,m.isImageSymbol)(e)||t.includes(e)||!(0,m.isGeometricSymbol)(e)&&r.has(e)?e:t[0]??"circle",it=({children:e,...t})=>{const r=s.useGeomViewport()?.size??null;return(0,i.jsx)("svg",{viewBox:"0 0 1 1",preserveAspectRatio:"none",width:"100%",height:"100%",pointerEvents:"none",...t,children:(0,i.jsx)(s.GeomViewportProvider,{size:r,space:"unit",children:e})})},at=({box:e,children:t})=>{const r=s.useGeomViewportSize(),n=r===null?null:r.width*(e.x1-e.x0),o=r===null?null:r.height*(e.y1-e.y0),c=(0,u.useMemo)(()=>n===null||o===null?null:{width:n,height:o},[n,o]);return(0,i.jsx)("svg",{x:(0,m.toPercent)(e.x0),y:(0,m.toPercent)(e.y0),width:(0,m.toPercent)(e.x1-e.x0),height:(0,m.toPercent)(e.y1-e.y0),overflow:"hidden",pointerEvents:"none",children:(0,i.jsx)(s.GeomViewportProvider,{size:c,children:t})})},ct="drqe3u0",lt="drqe3u1",ut="drqe3u2",dt="drqe3u3",A="drqe3u4",mt="drqe3u5",ht="drqe3u6",gt="drqe3u7",z="drqe3u8",pt="drqe3u9",ft="drqe3ua";var vt="drqe3uc",St="drqe3ud",yt="drqe3ue",Gt="drqe3uf";var bt="drqe3uh",Tt="drqe3ui",oe={enabled:"drqe3uk drqe3uj",disabled:"drqe3ul drqe3uj"},ie={ran:"drqe3un drqe3um",dim:"drqe3uo drqe3um"},fe={ran:"drqe3uq drqe3up",cached:"drqe3ur drqe3up",untouched:"drqe3us drqe3up"},xt=({width:e=440,style:t,className:r}={})=>{const{compileBus:n}=s.useGraphContext(),[o]=(0,u.useState)(()=>Ne()),[c,l]=(0,u.useState)(!1),[d,h]=(0,u.useState)(m.isCompilerCachingEnabled);(0,u.useEffect)(()=>{const{recordCompile:f}=o.getState(),b=n.getLastTrigger(),S=n.getLastCompile();return b&&S&&f(b,S),n.subscribe(f)},[o,n]);const v=(0,W.useStore)(o,f=>f.lastCompile),G=(0,W.useStore)(o,f=>f.history),N=n.getCacheStats(),x=v===null&&G.length===0,p=()=>{h(f=>{const b=!f;return(0,m.setCompilerCachingEnabled)(b),b})};return(0,i.jsxs)("div",{className:(0,Y.default)(ft,r),style:{width:e,...t},children:[(0,i.jsxs)("div",{className:ct,children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("div",{className:lt,children:"compile cache"}),(0,i.jsx)("div",{className:yt,children:x?"production: stats disabled":v?`last: ${v.label} · ${J(v.durationMs)}`:"awaiting first compile…"})]}),(0,i.jsx)("button",{type:"button",onClick:()=>l(f=>!f),className:Gt,children:c?"▾":"▴"})]}),!c&&(0,i.jsxs)("div",{className:"drqe3ub",children:[(0,i.jsxs)("button",{type:"button",onClick:p,className:d?oe.enabled:oe.disabled,"aria-pressed":d,children:["cache ",d?"enabled":"disabled"]}),(0,i.jsx)("span",{className:"drqe3ug",children:"next compile reflects this toggle"})]}),!c&&!x&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(Et,{delta:v?.stages,durations:v?.stageDurationsMs,cumulative:N}),(0,i.jsx)(Rt,{entries:G})]})]})},Et=({delta:e,durations:t,cumulative:r})=>(0,i.jsxs)("table",{className:ut,children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{className:bt,children:[(0,i.jsx)("th",{className:dt,children:"stage"}),(0,i.jsx)("th",{className:A,children:"time"}),(0,i.jsx)("th",{className:A,children:"Δ miss"}),(0,i.jsx)("th",{className:A,children:"Δ hit"}),(0,i.jsx)("th",{className:A,children:"total miss"}),(0,i.jsx)("th",{className:A,children:"total hit"})]})}),(0,i.jsx)("tbody",{children:m.COMPILER_STAGE_KEYS.map(n=>{const o=e?.[n],c=Pt(o);return(0,i.jsxs)("tr",{className:vt,children:[(0,i.jsxs)("td",{className:mt,children:[(0,i.jsx)("span",{className:fe[c],"aria-hidden":!0})," ",n]}),(0,i.jsx)("td",{className:z,children:t===void 0||c==="untouched"?"—":J(t[n])}),(0,i.jsx)("td",{className:c==="ran"?ie.ran:ie.dim,children:o?.misses??0}),(0,i.jsx)("td",{className:z,children:o?.hits??0}),(0,i.jsx)("td",{className:z,children:r[n].misses}),(0,i.jsx)("td",{className:z,children:r[n].hits})]},n)})})]}),Rt=({entries:e})=>e.length===0?null:(0,i.jsxs)("div",{className:St,children:[(0,i.jsx)("div",{className:Tt,children:"recent compiles"}),e.map(t=>{const r=Ct(t.stages,c=>c.misses>0),n=m.COMPILER_STAGE_KEYS.length,o=r===0?"cached":"ran";return(0,i.jsxs)("div",{className:ht,children:[(0,i.jsx)("span",{className:fe[o],"aria-hidden":!0}),(0,i.jsx)("span",{className:gt,title:t.label,children:t.label}),(0,i.jsxs)("span",{className:pt,children:[r,"/",n," ran · ",J(t.durationMs)]})]},t.id)})]}),Pt=e=>!e||e.hits===0&&e.misses===0?"untouched":e.misses>0?"ran":"cached",Ct=(e,t)=>{let r=0;for(const n of m.COMPILER_STAGE_KEYS)t(e[n])&&(r+=1);return r},J=e=>e<.1?"<0.1ms":e>=10?`${e.toFixed(0)}ms`:`${e.toFixed(2)}ms`,It=()=>{const{history:e}=s.useGraphContext(),{stack:t,undo:r,redo:n}=e,o=(0,u.useCallback)(d=>t.subscribe(d),[t]),c=(0,u.useCallback)(()=>t.getSnapshot(),[t]),l=(0,u.useSyncExternalStore)(o,c,c);return(0,u.useMemo)(()=>({...l,undo:r,redo:n}),[l,r,n])},Nt=new Set(["button","checkbox","color","file","hidden","image","radio","range","reset","submit"]),jt=(e,t={})=>{const{target:r,enabled:n=!0}=t;(0,u.useEffect)(()=>{const o=Dt(r);if(!n||!o)return;const c=l=>{if(!wt(l)||l.defaultPrevented||Lt(l.target))return;const d=s.resolveHistoryStep(l);if(!d)return;const h=e.current;h&&(d==="undo"?h.undo():h.redo())&&l.preventDefault()};return o.addEventListener("keydown",c),()=>o.removeEventListener("keydown",c)},[e,r,n])},Dt=e=>e===void 0?window:e!==null&&"current"in e?e.current:e,wt=e=>"key"in e,Lt=e=>e instanceof HTMLInputElement?!Nt.has(e.type):e instanceof HTMLElement?e.isContentEditable||e.tagName==="TEXTAREA":!1,_t=()=>{const{targetBoundaryStore:e}=s.useGraphContext();return(0,W.useStore)(e,t=>t.boundary)};exports.CanvasTextMeasurer=s.CanvasTextMeasurer;exports.DefaultFooter=s.DefaultFooter;exports.DefaultGeomCircle=me;exports.DefaultGeomLine=he;exports.DefaultGeomPath=pe;exports.DefaultGeomRect=ge;exports.DefaultGrid=s.DefaultGrid;exports.DefaultHeader=s.DefaultHeader;exports.DefaultSwatch=s.DefaultSwatch;exports.DefaultTooltip=s.DefaultTooltip;exports.DevToolsPanel=xt;exports.GRAPH_MODES=s.GRAPH_MODES;exports.GeomCircle=Qe;exports.GeomLine=Je;exports.GeomOverpaint=s.GeomOverpaint;exports.GeomPanelSizeProvider=s.GeomPanelSizeProvider;exports.GeomPath=et;exports.GeomRect=Ze;exports.GraphErrorBoundary=ae;exports.GraphErrorPanel=X;exports.GraphProvider=de;exports.GraphRenderer=s.GraphRenderer;exports.GraphyBadge=s.GraphyBadge;exports.HoverProvider=s.HoverProvider;exports.IntlProvider=s.ChartIntlProvider;exports.IntroFade=s.IntroFade;exports.IntroWipeClip=s.IntroWipeClip;exports.SymbolFigure=st;exports.TextMeasurerProvider=s.TextMeasurerProvider;exports.ThemeProvider=s.ThemeProvider;exports.UnitBoxSvg=at;exports.UnitSpaceSvg=it;exports.buildDotsEditOutlineShapes=s.buildDotsEditOutlineShapes;exports.createGraphyKit=Ye;exports.darkTheme=s.darkTheme;exports.defineGeomRenderer=s.defineGeomRenderer;exports.defineGlyph=s.defineGlyph;exports.getBuiltInEditOutlineShapes=s.getBuiltInEditOutlineShapes;exports.lightTheme=s.lightTheme;exports.lightenCss=s.lightenCss;exports.pruneSelection=ue;exports.readPositionPixels=k;exports.readRectPixels=Xe;exports.resolveGraphyBadgeVariant=s.resolveGraphyBadgeVariant;exports.resolvePathStroke=s.resolvePathStroke;exports.scalePointToPanel=s.scalePointToPanel;exports.stampAxisEditTarget=s.stampAxisEditTarget;exports.stampGridEditTarget=s.stampGridEditTarget;exports.stampLegendEditTarget=s.stampLegendEditTarget;exports.useElementScreenRect=s.useElementScreenRect;exports.useFormattingLocale=s.useFormattingLocale;exports.useGeomHitTest=s.useGeomHitTest;exports.useGeomHover=s.useGeomHover;exports.useGeomPanelSize=s.useGeomPanelSize;exports.useGeomReaderTree=s.useGeomReaderTree;exports.useGeomStyleReader=s.useGeomStyleReader;exports.useGeomViewportSize=s.useGeomViewportSize;exports.useGraphAnimation=s.useGraphAnimation;exports.useGraphCommands=s.useGraphCommands;exports.useGraphHandle=s.useGraphHandle;exports.useGraphHistory=It;exports.useGraphHistoryShortcuts=jt;exports.useGraphLocale=s.useGraphLocale;exports.useGraphSelection=s.useGraphSelection;exports.useGuidesTakePress=s.useGuidesTakePress;exports.useHandleScene=s.useHandleScene;exports.useHoverState=s.useHoverState;exports.usePaintDefs=s.usePaintDefs;exports.useResolvedStyle=s.useResolvedStyle;exports.useSceneSelector=s.useSceneSelector;exports.useStyleReaderTree=s.useStyleReaderTree;exports.useStyleResolver=s.useStyleResolver;exports.useTargetBoundary=_t;exports.useTextMeasurer=s.useTextMeasurer;exports.vars=s.vars;
|
package/dist/index.d.ts
CHANGED
|
@@ -244,17 +244,17 @@ export declare const DefaultFooter: ({ ref, footerRect, mode, caption, showCapti
|
|
|
244
244
|
* at its position rather than traveling to it from an unset attribute at the panel's origin. An
|
|
245
245
|
* entrance is the layer's to play, through {@link IntroFade} or {@link IntroWipeClip}.
|
|
246
246
|
*/
|
|
247
|
-
export declare const DefaultGeomCircle: ({ animateTransitions, cx, cy, r, effects, ...paint }:
|
|
247
|
+
export declare const DefaultGeomCircle: ({ animateTransitions, cx, cy, r, effects, ...paint }: GeomCircleShapeProps) => JSX.Element;
|
|
248
248
|
|
|
249
249
|
/** A straight line whose endpoints spring to their new positions — {@link GeomCircle} for a segment. */
|
|
250
|
-
export declare const DefaultGeomLine: ({ animateTransitions, x1, y1, x2, y2, effects, ...paint }:
|
|
250
|
+
export declare const DefaultGeomLine: ({ animateTransitions, x1, y1, x2, y2, effects, ...paint }: GeomLineShapeProps) => JSX.Element;
|
|
251
251
|
|
|
252
252
|
/**
|
|
253
253
|
* A path whose shape morphs to its new one — {@link GeomCircle} for a free shape, such as a polygon between two
|
|
254
254
|
* bars. A path is drawn in pixels, so it takes the layer it is drawn from as `source`: a resize redraws it where
|
|
255
255
|
* the percentage marks already are, rather than morphing behind them.
|
|
256
256
|
*/
|
|
257
|
-
export declare const DefaultGeomPath: ({ animateTransitions, d, source, effects, ...paint }:
|
|
257
|
+
export declare const DefaultGeomPath: ({ animateTransitions, d, source, effects, ...paint }: GeomPathShapeProps) => JSX.Element;
|
|
258
258
|
|
|
259
259
|
/**
|
|
260
260
|
* A rect whose origin, size and corners spring to their new values — {@link GeomCircle} for a box. Motion reads `x`
|
|
@@ -657,8 +657,6 @@ export declare interface EditorSurfaceSlotProps {
|
|
|
657
657
|
panelRect: Rect;
|
|
658
658
|
/** The axes as the chart paints them, whose ticks a stamped tick index addresses. */
|
|
659
659
|
formattedAxes: readonly FormattedAxis[];
|
|
660
|
-
/** Whether the chart animates between states, so what the editor draws over its geoms can follow. */
|
|
661
|
-
animateTransitions: boolean;
|
|
662
660
|
}
|
|
663
661
|
|
|
664
662
|
/** Round marks of one size, which the outline grows from their edge. */
|
|
@@ -849,14 +847,15 @@ export declare interface GeomCircleProps {
|
|
|
849
847
|
strokeWidth?: number;
|
|
850
848
|
/** Shadow, blend mode and filters from `readGeomEffects`. The resting shadow is `'none'` when the layer casts it. */
|
|
851
849
|
effects?: GeomEffects;
|
|
852
|
-
/** Whether a change of center or radius springs to the new one. Snaps when false. */
|
|
853
|
-
animateTransitions: boolean;
|
|
854
850
|
/** A geom's own test hook, since the primitive owns the painted element. */
|
|
855
851
|
'data-testid'?: string;
|
|
856
852
|
/** Replaces the circle with a built-in shape, a registered glyph, or an inline image. */
|
|
857
853
|
symbol?: StylePointSymbol;
|
|
858
854
|
}
|
|
859
855
|
|
|
856
|
+
/** The circle a theme's `Circle` draws. */
|
|
857
|
+
export declare type GeomCircleShapeProps = GeomCircleProps & GeomShapeTransition;
|
|
858
|
+
|
|
860
859
|
/** A custom geom `getEditOutlineShapes` handler's input: the observations to outline as a layer, plus `sourceLayer`. */
|
|
861
860
|
export declare type GeomEditOutlineShapesRendererInput = EditOutlineShapesInput;
|
|
862
861
|
|
|
@@ -918,11 +917,12 @@ export declare interface GeomLineProps {
|
|
|
918
917
|
strokeLinecap?: 'butt' | 'round' | 'square';
|
|
919
918
|
/** Shadow, blend mode and filters from `readGeomEffects`. The resting shadow is `'none'` when the layer casts it. */
|
|
920
919
|
effects?: GeomEffects;
|
|
921
|
-
/** Whether a change of either endpoint springs to the new one. Snaps when false. */
|
|
922
|
-
animateTransitions: boolean;
|
|
923
920
|
'data-testid'?: string;
|
|
924
921
|
}
|
|
925
922
|
|
|
923
|
+
/** The line a theme's `Line` draws. */
|
|
924
|
+
export declare type GeomLineShapeProps = GeomLineProps & GeomShapeTransition;
|
|
925
|
+
|
|
926
926
|
/** A live geom's paint function — receives the guaranteed wiring on `input.live`. */
|
|
927
927
|
export declare type GeomLiveRenderFn<G extends GeomName | string = string, C extends CoordKind = CoordKind> = (input: GeomLiveRenderInput<G, C>) => ReactNode;
|
|
928
928
|
|
|
@@ -991,11 +991,12 @@ export declare interface GeomPathProps {
|
|
|
991
991
|
strokeDasharray?: string;
|
|
992
992
|
/** Shadow, blend mode and filters from `readGeomEffects`. The resting shadow is `'none'` when the layer casts it. */
|
|
993
993
|
effects?: GeomEffects;
|
|
994
|
-
/** Whether a change of shape morphs to the new one. Snaps when false. */
|
|
995
|
-
animateTransitions: boolean;
|
|
996
994
|
'data-testid'?: string;
|
|
997
995
|
}
|
|
998
996
|
|
|
997
|
+
/** The path a theme's `Path` draws. */
|
|
998
|
+
export declare type GeomPathShapeProps = GeomPathProps & GeomShapeTransition;
|
|
999
|
+
|
|
999
1000
|
export declare const GeomRect: ({ cornerRadius, ...props }: GeomRectProps) => JSX.Element;
|
|
1000
1001
|
|
|
1001
1002
|
export declare interface GeomRectProps {
|
|
@@ -1016,16 +1017,14 @@ export declare interface GeomRectProps {
|
|
|
1016
1017
|
cornerRadius?: GeomCornerRadius | GeomCornerRadii;
|
|
1017
1018
|
/** Shadow, blend mode and filters from `readGeomEffects`. The resting shadow is `'none'` when the layer casts it. */
|
|
1018
1019
|
effects?: GeomEffects;
|
|
1019
|
-
/** Whether a change of origin or size springs to the new one. Snaps when false. */
|
|
1020
|
-
animateTransitions: boolean;
|
|
1021
1020
|
'data-testid'?: string;
|
|
1022
1021
|
}
|
|
1023
1022
|
|
|
1024
1023
|
/** The rect a theme's `Rect` draws, its corner radius resolved to the user units it is placed in. */
|
|
1025
|
-
export declare type GeomRectShapeProps = Omit<GeomRectProps, 'cornerRadius'> & {
|
|
1024
|
+
export declare type GeomRectShapeProps = Omit<GeomRectProps, 'cornerRadius'> & GeomShapeTransition & {
|
|
1026
1025
|
/**
|
|
1027
|
-
* Corner radii in user units, clamped to half the rect's shorter side on screen when its size is known. They
|
|
1028
|
-
* inside a `UnitSpaceSvg`, whose units stretch to the panel, so the corner stays round.
|
|
1026
|
+
* Corner radii in user units, clamped to half the rect's shorter side on screen when its size is known. They
|
|
1027
|
+
* differ inside a `UnitSpaceSvg`, whose units stretch to the panel, so the corner stays round.
|
|
1029
1028
|
*/
|
|
1030
1029
|
rx?: number;
|
|
1031
1030
|
ry?: number;
|
|
@@ -1149,7 +1148,6 @@ export declare type GeomRenderFn<G extends GeomName | string = string, C extends
|
|
|
1149
1148
|
declare interface GeomRenderInput<G extends GeomName | string = string, C extends CoordKind = CoordKind> extends GeomRenderInputBase {
|
|
1150
1149
|
layer: SceneLayerOf<G>;
|
|
1151
1150
|
coordSystem: CoordSystemFor<C>;
|
|
1152
|
-
animateTransitions: boolean;
|
|
1153
1151
|
formattingLocale: FormattingLocale;
|
|
1154
1152
|
intro?: LayerIntroPlan | null;
|
|
1155
1153
|
}
|
|
@@ -1181,10 +1179,16 @@ export declare interface GeomRenderOptions {
|
|
|
1181
1179
|
* default. Wrap `DefaultGeomCircle` and its siblings to keep their transitions.
|
|
1182
1180
|
*/
|
|
1183
1181
|
export declare interface GeomShapes {
|
|
1184
|
-
Circle?: ComponentType<
|
|
1185
|
-
Line?: ComponentType<
|
|
1182
|
+
Circle?: ComponentType<GeomCircleShapeProps>;
|
|
1183
|
+
Line?: ComponentType<GeomLineShapeProps>;
|
|
1186
1184
|
Rect?: ComponentType<GeomRectShapeProps>;
|
|
1187
|
-
Path?: ComponentType<
|
|
1185
|
+
Path?: ComponentType<GeomPathShapeProps>;
|
|
1186
|
+
}
|
|
1187
|
+
|
|
1188
|
+
/** What a shape draws besides the props a geom passes, resolved by the primitive from the graph it paints in. */
|
|
1189
|
+
declare interface GeomShapeTransition {
|
|
1190
|
+
/** Whether a change of geometry springs to the new one. Snaps when false. */
|
|
1191
|
+
animateTransitions: boolean;
|
|
1188
1192
|
}
|
|
1189
1193
|
|
|
1190
1194
|
/**
|
|
@@ -1265,6 +1269,13 @@ export declare interface GraphAnimationProps {
|
|
|
1265
1269
|
maxAnimatedGeoms?: number;
|
|
1266
1270
|
}
|
|
1267
1271
|
|
|
1272
|
+
export declare interface GraphAnimationState {
|
|
1273
|
+
/** Whether geoms and guides animate from one scene to the next. */
|
|
1274
|
+
animateTransitions: boolean;
|
|
1275
|
+
/** Whether the intro waits for the panel to come into view, holding back the paint it plays over. */
|
|
1276
|
+
waitingForView: boolean;
|
|
1277
|
+
}
|
|
1278
|
+
|
|
1268
1279
|
/** Write access to the graph's spec: applying {@link Command}s and closing the runs they form. */
|
|
1269
1280
|
export declare interface GraphCommands {
|
|
1270
1281
|
/** Applies a command to the provider's live spec. */
|
|
@@ -2390,6 +2401,9 @@ export declare const useGeomStyleReader: <L extends SceneLayer>(layer: L) => Sty
|
|
|
2390
2401
|
*/
|
|
2391
2402
|
export declare const useGeomViewportSize: () => BoxSize | null;
|
|
2392
2403
|
|
|
2404
|
+
/** The graph's animation as its paint reads it. Outside a graph nothing animates and nothing waits. */
|
|
2405
|
+
export declare const useGraphAnimation: () => GraphAnimationState;
|
|
2406
|
+
|
|
2393
2407
|
/**
|
|
2394
2408
|
* Returns the graph's command controls.
|
|
2395
2409
|
*
|