@aiquants/markdown-explorer 0.36.0 → 0.37.0
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/CHANGELOG.md +72 -0
- package/README.md +74 -11
- package/dist/{EditSurface-BCFJRyIM.js → EditSurface-BQgwRUrR.js} +250 -245
- package/dist/EditSurface-Xvk5wZu7.cjs +6 -0
- package/dist/ExplorerSplit-C_3FChSt.cjs +2 -0
- package/dist/ExplorerSplit-C_kaEnyM.js +1619 -0
- package/dist/{MultiLayout-Bo9LAXiY.cjs → MultiLayout-BZNj1GYo.cjs} +1 -1
- package/dist/{MultiLayout-Dy5TIC2t.js → MultiLayout-DROxkTdD.js} +22 -22
- package/dist/{NativeScrollBar-Bj-LKej0.cjs → NativeScrollBar-BDF9A1sc.cjs} +1 -1
- package/dist/{NativeScrollBar-DpZMYhmf.js → NativeScrollBar-DvdOpwIW.js} +2 -2
- package/dist/{TreeLayout-DsSKW_Qj.js → TreeLayout-Cc-ykewY.js} +2 -2
- package/dist/{TreeLayout-T8sc_wg7.cjs → TreeLayout-D_DYV64_.cjs} +1 -1
- package/dist/client/MarkdownExplorer.d.cts +4 -5
- package/dist/client/MarkdownExplorer.d.ts +4 -5
- package/dist/client/hostContract.d.cts +1 -8
- package/dist/client/hostContract.d.ts +1 -8
- package/dist/core/labels.d.cts +0 -9
- package/dist/core/labels.d.ts +0 -9
- package/dist/explorerCore-DivWkFQF.cjs +1 -0
- package/dist/{explorerCore-B3RGmMG6.js → explorerCore-EkU0mwdW.js} +310 -308
- package/dist/index-BmOU3xcK.cjs +18 -0
- package/dist/{index-D0l_BJqb.js → index-dtjghDWY.js} +2451 -2434
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +54 -55
- package/dist/{merge-Dckw7r9T.cjs → merge-BCFCL1cF.cjs} +1 -1
- package/dist/{merge-BwcqBd4c.js → merge-DC_h-t31.js} +1 -1
- package/dist/server/anonymous.d.cts +2 -2
- package/dist/server/anonymous.d.ts +2 -2
- package/dist/server/ports.d.cts +5 -2
- package/dist/server/ports.d.ts +5 -2
- package/dist/server.cjs +1 -1
- package/dist/server.d.cts +1 -1
- package/dist/server.d.ts +1 -1
- package/dist/server.js +12 -12
- package/dist/serverCore.cjs +1 -1
- package/dist/serverCore.d.cts +1 -1
- package/dist/serverCore.d.ts +1 -1
- package/dist/serverCore.js +1 -1
- package/dist/styles/markdown-explorer.css +1 -1
- package/dist/{tapScrollCircle-smKLgRa2.js → tapScrollCircle-CqMZzWjo.js} +1 -1
- package/dist/{tapScrollCircle-DyLInGck.cjs → tapScrollCircle-DVNlszeF.cjs} +1 -1
- package/docs/behavior/dom-hooks.md +8 -1
- package/docs/behavior/hosting.md +1 -1
- package/docs/behavior/localization.md +2 -2
- package/docs/behavior/security.md +1 -1
- package/docs/behavior/url-contract.md +2 -2
- package/package.json +6 -4
- package/dist/EditSurface-B70iRFkG.cjs +0 -6
- package/dist/ExplorerSplit-BNrHrIus.cjs +0 -2
- package/dist/ExplorerSplit-Bgccz2nm.js +0 -1589
- package/dist/explorerCore-CUkyKtm8.cjs +0 -1
- package/dist/index-lpL7GltU.cjs +0 -18
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */
|
|
2
2
|
/*! @aiquants/markdown-explorer — component styles, layered in `components`. The layer order is pinned first (theme, base, components, utilities, as Tailwind CSS declares it), so a Tailwind host's preflight in `base` cannot override the explorer when this sheet is the first to name a layer. */
|
|
3
|
-
@layer theme,base;@layer components{.aqmx-root{color-scheme:light;--aqmx-space-1:.0625rem;--aqmx-space-2:.125rem;--aqmx-space-3:.1875rem;--aqmx-space-4:.3125rem;--aqmx-space-5:.5rem;--aqmx-space-6:.8125rem;--aqmx-space-7:1.3125rem;--aqmx-space-8:2.125rem;--aqmx-space-9:3.4375rem;--aqmx-control:2.75rem;--aqmx-focus-ring-width:var(--aqmx-space-2);--aqmx-focus-ring-offset:var(--aqmx-space-2);--aqmx-icon:1rem;--aqmx-radius-s:.3125rem;--aqmx-radius-m:.5rem;--aqmx-radius-l:.8125rem;--aqmx-duration-1:89ms;--aqmx-duration-2:.144s;--aqmx-duration-3:.233s;--aqmx-duration-4:.377s;--aqmx-delay-progress:.233s;--aqmx-ease:cubic-bezier(.2, 0, 0, 1);--aqmx-font-size-body:.8125rem;--aqmx-font-size-title:1rem;--aqmx-font-size-display:1.3125rem;--aqmx-line-height-compact:1.382;--aqmx-line-height-prose:1.618;--aqmx-column-measure:40ch;--aqmx-tap-circle-gutter-size:54px;--aqmx-scroll-bar-overlay-size:0px;--aqmx-scroll-bar-slot-size:8px;--aqmx-split-handle-size:24px;--aqmx-surface:#fff;--aqmx-surface-raised:#f8fafc;--aqmx-surface-sunken:#f1f5f9;--aqmx-border:#cbd5e1;--aqmx-border-strong:#94a3b8;--aqmx-text:#0f172a;--aqmx-text-muted:#3d4a5c;--aqmx-accent:#1d3fa6;--aqmx-accent-surface:#dbeafe;--aqmx-tree-line:#64748b;--aqmx-tree-row-tint:#f1f1f2;--aqmx-tree-row-accent-tint:#dce6fc;--aqmx-focus:#2563eb;--aqmx-info-surface:#eff6ff;--aqmx-info-border:#93c5fd;--aqmx-info-text:#1e3a8a;--aqmx-warning-surface:#fffbeb;--aqmx-warning-border:#fcd34d;--aqmx-warning-text:#78350f;--aqmx-danger-surface:#fef2f2;--aqmx-danger-border:#fca5a5;--aqmx-danger-text:#7f1d1d;--aqmx-syntax-heading:#172554;--aqmx-syntax-link:#1e3a8a;--aqmx-syntax-url:#5b21b6;--aqmx-syntax-code:#7c2d12;--aqmx-syntax-quote:#334155;--aqmx-syntax-mark:#3d4a5c;--aqmx-editor-gutter:#334155;--aqmx-editor-selection:#2563eb36;--aqmx-editor-active-line:#0f172a0d;--aqmx-conflict-ours-tint:#16a34a21;--aqmx-conflict-theirs-tint:#2563eb21;--aqmx-conflict-marker-tint:#d9770636;--aqmx-shadow:0 .0625rem .1875rem #0f172a21, 0 .3125rem .8125rem #0f172a14}.aqmx-root[data-aqmx-theme=dark]{color-scheme:dark;--aqmx-surface:#0f172a;--aqmx-surface-raised:#1e293b;--aqmx-surface-sunken:#020617;--aqmx-border:#334155;--aqmx-border-strong:#64748b;--aqmx-text:#e2e8f0;--aqmx-text-muted:#aab6c8;--aqmx-accent:#bfdbfe;--aqmx-accent-surface:#1e3a8a;--aqmx-tree-line:#94a3b8;--aqmx-tree-row-tint:#1c2436;--aqmx-tree-row-accent-tint:#19387f;--aqmx-focus:#60a5fa;--aqmx-info-surface:#172554;--aqmx-info-border:#1d4ed8;--aqmx-info-text:#bfdbfe;--aqmx-warning-surface:#422006;--aqmx-warning-border:#a16207;--aqmx-warning-text:#fde68a;--aqmx-danger-surface:#450a0a;--aqmx-danger-border:#b91c1c;--aqmx-danger-text:#fecaca;--aqmx-syntax-heading:#bfdbfe;--aqmx-syntax-link:#c7d2fe;--aqmx-syntax-url:#ddd6fe;--aqmx-syntax-code:#fdba74;--aqmx-syntax-quote:#cbd5e1;--aqmx-syntax-mark:#cbd5e1;--aqmx-editor-gutter:#cbd5e1;--aqmx-editor-selection:#3b82f657;--aqmx-editor-active-line:#e2e8f00d;--aqmx-conflict-ours-tint:#22c55e36;--aqmx-conflict-theirs-tint:#3b82f636;--aqmx-conflict-marker-tint:#f59e0b36;--aqmx-shadow:0 .0625rem .1875rem #0000008c, 0 .3125rem .8125rem #00000057}@media (pointer:coarse){.aqmx-root{--aqmx-font-size-body:1rem;--aqmx-tap-circle-gutter-size:0px;--aqmx-scroll-bar-overlay-size:8px;--aqmx-scroll-bar-slot-size:0px;--aqmx-split-handle-size:44px}}@media (forced-colors:active){.aqmx-root.aqmx-root[data-aqmx-theme]{--aqmx-tree-line:CanvasText}}@media (prefers-reduced-motion:reduce){.aqmx-root{--aqmx-duration-1:0s;--aqmx-duration-2:0s;--aqmx-duration-3:0s;--aqmx-duration-4:0s}}.aqmx-root{block-size:100%;min-block-size:0;inline-size:100%;min-inline-size:0;color:var(--aqmx-text);background:var(--aqmx-surface);font-size:var(--aqmx-font-size-body);line-height:var(--aqmx-line-height-compact);flex-direction:column;display:flex;position:relative}.aqmx-root *,.aqmx-root :before,.aqmx-root :after{box-sizing:border-box}.aqmx-icon-button{inline-size:var(--aqmx-control);block-size:var(--aqmx-control);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);cursor:pointer;transition:background-color var(--aqmx-duration-2) var(--aqmx-ease), color var(--aqmx-duration-2) var(--aqmx-ease);background:0 0;border:0;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.aqmx-icon-button:hover{color:var(--aqmx-text);background:var(--aqmx-surface-sunken)}.aqmx-icon-button[aria-pressed=true],.aqmx-icon-button:has(>input:checked),.aqmx-icon-button[aria-expanded=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface)}.aqmx-icon-button:disabled{opacity:.382;cursor:not-allowed}.aqmx-icon-button[aria-disabled=true]{cursor:not-allowed}.aqmx-icon-button[aria-disabled=true]:hover{color:var(--aqmx-text-muted);background:0 0}.aqmx-icon-button>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon)}.aqmx-icon-button[aria-disabled=true]>svg{opacity:.382}.aqmx-icon-button:has(>input[type=radio]){position:relative}.aqmx-icon-button>input[type=radio]{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.aqmx-root :focus-visible,.aqmx-icon-button:has(>input:focus-visible){outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:var(--aqmx-focus-ring-offset)}.aqmx-callout{gap:var(--aqmx-space-5);padding:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-info-border);border-radius:var(--aqmx-radius-l);color:var(--aqmx-info-text);background:var(--aqmx-info-surface);line-height:var(--aqmx-line-height-prose);display:grid}.aqmx-callout[data-aqmx-tone=warning]{border-color:var(--aqmx-warning-border);color:var(--aqmx-warning-text);background:var(--aqmx-warning-surface)}.aqmx-callout[data-aqmx-tone=danger]{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-callout-title{font-size:var(--aqmx-font-size-title);font-weight:600;line-height:var(--aqmx-line-height-compact);margin:0}.aqmx-callout-body{margin:0}.aqmx-callout-actions{gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-callout-action{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid currentColor;border-radius:var(--aqmx-radius-m);color:inherit;font:inherit;cursor:pointer;background:0 0;justify-self:start;align-items:center;font-weight:600;text-decoration:none;display:inline-flex}.aqmx-progress{z-index:2;block-size:var(--aqmx-space-3);pointer-events:none;position:absolute;inset-block-start:0;inset-inline:0;overflow:hidden}.aqmx-progress:before{content:"";background:var(--aqmx-accent);inline-size:38.1966%;animation:aqmx-progress calc(var(--aqmx-duration-4) * 3) var(--aqmx-ease) infinite;position:absolute;inset-block:0}@keyframes aqmx-progress{0%{inset-inline-start:-38.1966%}to{inset-inline-start:100%}}.aqmx-empty{place-content:center;justify-items:center;gap:var(--aqmx-space-6);block-size:100%;padding:var(--aqmx-space-8);color:var(--aqmx-text-muted);text-align:center;line-height:var(--aqmx-line-height-prose);display:grid}.aqmx-empty-title{color:var(--aqmx-text);font-size:var(--aqmx-font-size-title);margin:0;font-weight:600}.aqmx-skeleton{gap:var(--aqmx-space-6);padding:var(--aqmx-space-7);display:grid}.aqmx-skeleton>span{block-size:var(--aqmx-space-6);border-radius:var(--aqmx-radius-s);background:var(--aqmx-surface-sunken);animation:aqmx-pulse calc(var(--aqmx-duration-4) * 4) ease-in-out infinite;display:block}.aqmx-skeleton>span:nth-child(3n+1){inline-size:61.8034%}.aqmx-skeleton>span:nth-child(3n+2){inline-size:100%}.aqmx-skeleton>span:nth-child(3n){inline-size:85.4102%}@keyframes aqmx-pulse{50%{opacity:.618}}.aqmx-sr-only,.aqmx-document-refresh-bar[data-aqmx-sheet-bar] .aqmx-labelled-button>span{clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.aqmx-native-scroll-bar{display:flex}@media (pointer:coarse){.aqmx-native-scroll-bar{inline-size:0;position:relative}.aqmx-native-scroll-bar>[data-aqvs-scrollbar]{pointer-events:none;position:absolute;inset-block-start:0;inset-inline-end:0}}.aqmx-toast{z-index:60;max-inline-size:min(34rem, calc(100% - var(--aqmx-space-8)));padding:var(--aqmx-space-5) var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-warning-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-warning-text);background:var(--aqmx-warning-surface);box-shadow:var(--aqmx-shadow);position:absolute;inset-block-start:var(--aqmx-space-6);inset-inline-end:var(--aqmx-space-7)}@media (prefers-reduced-motion:reduce){.aqmx-progress:before,.aqmx-skeleton>span{animation:none}}@media (forced-colors:active){.aqmx-icon-button[aria-pressed=true],.aqmx-icon-button:has(>input:checked),.aqmx-icon-button[aria-expanded=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-icon-button[aria-disabled=true]{color:graytext}.aqmx-root :focus-visible,.aqmx-icon-button:has(>input:focus-visible){outline-color:highlight}.aqmx-progress:before{forced-color-adjust:none;background:highlight}.aqmx-skeleton>span{forced-color-adjust:none;background:graytext}}.aqmx-explorer{gap:var(--aqmx-space-5);block-size:100%;min-block-size:0;min-inline-size:0;padding:var(--aqmx-space-4);color:var(--aqmx-text);background:var(--aqmx-surface);flex-direction:column;display:flex;position:relative;overflow-y:auto}.aqmx-explorer-header{align-items:center;gap:var(--aqmx-space-4);min-block-size:var(--aqmx-control);flex-wrap:wrap;flex:none;display:flex}.aqmx-explorer-source{min-inline-size:min(100%,9rem);block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface-raised);font:inherit;text-overflow:ellipsis;cursor:pointer;flex:9rem}.aqmx-explorer-actions{justify-content:flex-end;align-items:center;gap:var(--aqmx-space-2);flex-wrap:wrap;flex:0 auto;min-inline-size:0;margin-inline-start:auto;display:flex}.aqmx-explorer-body{gap:var(--aqmx-space-5);flex-direction:column;flex:1 1 0;min-block-size:0;min-inline-size:0;display:flex;position:relative}.aqmx-labelled-button{gap:var(--aqmx-space-2);min-inline-size:var(--aqmx-control);inline-size:auto;padding-inline:var(--aqmx-space-3);white-space:nowrap;flex:0 auto;display:inline-flex}.aqmx-labelled-button>svg{flex:none}.aqmx-labelled-button>span{text-overflow:ellipsis;min-inline-size:0;overflow:hidden}.aqmx-explorer-refresh-failure,.aqmx-explorer-expand-all-stop{padding:var(--aqmx-space-4) var(--aqmx-space-5);border:var(--aqmx-space-1) solid;border-radius:var(--aqmx-radius-m);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;flex:none;margin:0}.aqmx-explorer-refresh-failure{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-explorer-expand-all-stop{border-color:var(--aqmx-info-border);color:var(--aqmx-info-text);background:var(--aqmx-info-surface)}.aqmx-explorer-actions>.aqmx-labelled-button[data-aqmx-busy=true]>svg{animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite}@keyframes aqmx-explorer-spin{to{rotate:1turn}}.aqmx-explorer-actions>.aqmx-icon-button[aria-busy=true]{cursor:progress}.aqmx-explorer-menu{z-index:50;gap:var(--aqmx-space-1);max-block-size:100%;inline-size:min(21rem,100%);padding:var(--aqmx-space-3);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);display:grid;position:absolute;inset-block-start:0;inset-inline-end:0;overflow-y:auto}.aqmx-explorer-menu-item{align-items:center;gap:var(--aqmx-space-5);inline-size:100%;min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border-radius:var(--aqmx-radius-s);color:var(--aqmx-text);font:inherit;text-align:start;cursor:pointer;transition:background-color var(--aqmx-duration-1) var(--aqmx-ease);background:0 0;border:0;display:flex}.aqmx-explorer-menu-item:hover,.aqmx-explorer-menu-item:focus-visible{background:var(--aqmx-surface-sunken)}.aqmx-explorer-menu-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);color:var(--aqmx-text-muted);flex:none}.aqmx-explorer-menu-name{text-overflow:ellipsis;white-space:nowrap;flex:auto;min-inline-size:0;overflow:hidden}.aqmx-explorer-menu-value{color:var(--aqmx-accent);font-variant-numeric:tabular-nums;flex:none;font-weight:600}.aqmx-explorer-notices{gap:var(--aqmx-space-5);flex:none;display:grid}.aqmx-explorer-tree-area{min-block-size:calc(var(--aqmx-control) * 3);flex-direction:column;flex:1 1 0;min-inline-size:0;display:flex;position:relative}.aqmx-explorer-tree{flex:1 1 0;min-block-size:0;position:relative}.aqmx-explorer-tree-view{block-size:100%}@media (pointer:coarse){.aqmx-explorer-tree [data-aqvs-scrollbar]:has(>[data-aqvs-scrollbar-arrow]){visibility:hidden}}.aqmx-explorer-tree-progress{z-index:1;align-items:center;gap:var(--aqmx-space-2) var(--aqmx-space-4);max-inline-size:calc(100% - var(--aqmx-space-5) * 3);padding:var(--aqmx-space-3) var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;pointer-events:none;animation:aqmx-appear var(--aqmx-duration-2) ease-out var(--aqmx-delay-progress) both;flex-wrap:wrap;margin:0;display:flex;position:absolute;inset-block-end:var(--aqmx-space-9);inset-inline-start:var(--aqmx-space-5)}.aqmx-explorer-tree-progress-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite;flex:none}@keyframes aqmx-appear{0%{opacity:0}}.aqmx-explorer-tree-probe{inline-size:0;block-size:var(--aqmx-control);visibility:hidden;pointer-events:none;color:var(--aqmx-tree-line);forced-color-adjust:none;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-explorer-loading{gap:var(--aqmx-space-5);padding:var(--aqmx-space-6) var(--aqmx-space-5);color:var(--aqmx-text-muted);display:grid}.aqmx-explorer-loading-text{margin:0}.aqmx-explorer-loading>.aqmx-skeleton{padding:0}.aqmx-explorer-tree-message{padding:var(--aqmx-space-5);overflow-y:auto}.aqmx-explorer-empty-icon{inline-size:var(--aqmx-space-8);block-size:var(--aqmx-space-8);color:var(--aqmx-border-strong)}.aqmx-explorer-empty-body{margin:0}.aqmx-explorer-tree [role=treeitem]{border-radius:var(--aqmx-radius-s);color:var(--aqmx-text);transition:background-color var(--aqmx-duration-1) var(--aqmx-ease)}.aqmx-explorer-tree [role=treeitem]:hover{color:var(--aqmx-text);background:var(--aqmx-tree-row-tint)}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]{color:var(--aqmx-text);background:var(--aqmx-tree-row-tint);box-shadow:inset var(--aqmx-space-2) 0 0 currentColor}.aqmx-explorer-tree [role=treeitem][data-entry-selected=true],.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]{color:var(--aqmx-accent);background:var(--aqmx-tree-row-accent-tint)}.aqmx-explorer-tree [role=treeitem]:focus-visible{outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]:focus-visible{box-shadow:inset calc(var(--aqmx-space-2) + var(--aqmx-focus-ring-width)) 0 0 currentColor}.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]{font-weight:600}.aqmx-explorer-tree [role=treeitem][data-aqmx-children=loading]{animation:aqmx-pulse calc(var(--aqmx-duration-4) * 4) ease-in-out infinite}.aqmx-explorer-tree [role=treeitem][data-aqmx-loop]{color:var(--aqmx-text-muted);font-style:italic}.aqmx-explorer-folder-failed{--aqmx-folder-name-floor:3em;align-items:center;min-inline-size:0;max-inline-size:100%;display:flex}.aqmx-explorer-folder-name{flex:10000 1 var(--aqmx-folder-name-floor);text-overflow:ellipsis;white-space:nowrap;min-inline-size:0;max-inline-size:max-content;overflow:hidden}.aqmx-explorer-folder-error{min-inline-size:0;color:var(--aqmx-danger-text);text-indent:var(--aqmx-space-4);text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;overflow:hidden}.aqmx-explorer-folder-retry{flex:1000000 0 calc(var(--aqmx-icon) + (var(--aqmx-space-3) + var(--aqmx-space-1)) * 2);min-inline-size:calc(var(--aqmx-icon) + (var(--aqmx-space-3) + var(--aqmx-space-1)) * 2);max-inline-size:max-content;min-block-size:var(--aqmx-control);padding:0 var(--aqmx-space-3);border:var(--aqmx-space-1) solid var(--aqmx-danger-border);border-radius:var(--aqmx-radius-s);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface);font:inherit;line-height:var(--aqmx-line-height-compact);cursor:pointer;justify-content:center;align-items:center;margin-inline-start:var(--aqmx-space-4);display:inline-flex;overflow:hidden}.aqmx-explorer-folder-retry:focus-visible{outline-offset:calc(-1 * (var(--aqmx-focus-ring-width) + var(--aqmx-space-1)))}.aqmx-explorer-folder-retry-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);flex:none}.aqmx-explorer-folder-retry-text{min-inline-size:0;text-indent:var(--aqmx-space-3);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.aqmx-explorer-tray{gap:var(--aqmx-space-4);min-block-size:calc(var(--aqmx-control) + (var(--aqmx-space-5) + var(--aqmx-space-1)) * 2);padding:var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);flex-direction:column;flex:0 auto;display:flex;overflow-y:auto}.aqmx-explorer-tray-header{justify-content:space-between;align-items:center;gap:var(--aqmx-space-5);flex:none;display:flex}.aqmx-explorer-tray-title{margin:0;font-weight:600}.aqmx-explorer-tray-button{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border-radius:var(--aqmx-radius-m);color:var(--aqmx-accent);font:inherit;cursor:pointer;background:0 0;border:0;flex:none;font-weight:600}.aqmx-explorer-tray-button:hover{background:var(--aqmx-surface-sunken)}.aqmx-explorer-tray-list{gap:var(--aqmx-space-1);min-block-size:var(--aqmx-control);max-block-size:calc(var(--aqmx-control) * 3);flex:0 auto;margin:0;padding:0;list-style:none;display:grid;overflow-y:auto}.aqmx-explorer-tray-item{align-items:center;gap:var(--aqmx-space-4);display:flex}.aqmx-explorer-tray-name{text-overflow:ellipsis;white-space:nowrap;flex:auto;min-inline-size:0;font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;overflow:hidden}.aqmx-explorer-tray-open{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border-radius:var(--aqmx-radius-m);color:var(--aqmx-surface);background:var(--aqmx-accent);font:inherit;cursor:pointer;border:0;flex:none;font-weight:600}@media (forced-colors:active){.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true],.aqmx-explorer-tree [role=treeitem][data-entry-selected=true],.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true],.aqmx-explorer-menu-item[aria-checked=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-explorer-menu-item[aria-checked=true] *,.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true] *,.aqmx-explorer-tree [role=treeitem][data-entry-selected=true] *,.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true] *{color:inherit!important}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]:focus-visible,.aqmx-explorer-tree [role=treeitem][data-entry-selected=true]:focus-visible,.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]:focus-visible{outline-color:highlighttext}.aqmx-explorer-tray-button,.aqmx-explorer-tray-open,.aqmx-explorer-tray-remove{border:var(--aqmx-space-1) solid ButtonText}}@media (prefers-reduced-motion:reduce){.aqmx-explorer-actions>.aqmx-labelled-button[data-aqmx-busy=true]>svg,.aqmx-explorer-tree-progress-icon,.aqmx-explorer-tree [role=treeitem][data-aqmx-children=loading]{animation:none}}.aqmx-document{contain:layout paint;--aqmd-toolbar-inset-block-start:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset));block-size:100%;min-block-size:0;inline-size:100%;min-inline-size:0;color:var(--aqmx-text);background:var(--aqmx-surface);flex-direction:column;display:flex;position:relative;overflow:hidden}.aqmx-document-viewer:has([data-aqmd-scroll-bar]){--aqmd-toolbar-inset-inline-end:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset) + var(--aqmx-scroll-bar-overlay-size))}.aqmx-document [data-theme]{background-color:#0000!important}.aqmx-document .markdown-body :is(sup,sub) a{outline-offset:var(--aqmx-focus-ring-offset)!important}.aqmx-document *{scroll-margin:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset))}.aqmx-document :is([data-aqmd-scroll-container],[data-aqmx-document-scroller]):focus-visible{outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-document[aria-busy=true]>:not(.aqmx-progress){opacity:.618;transition:opacity var(--aqmx-duration-3) var(--aqmx-ease)}.aqmx-document-viewer{flex:1 1 0;min-block-size:0;min-inline-size:0}.aqmx-document>.aqmx-document-viewer:is(:first-child,.aqmx-progress+*){--aqmd-toolbar-reserve-before-measure:1}.aqmx-document-notice{margin:var(--aqmx-space-6) var(--aqmx-space-7) 0;overflow-wrap:anywhere;flex:none}.aqmx-document-notices{flex-direction:column;flex:none;display:flex}.aqmx-document-notices:not(:empty){padding-block-end:var(--aqmx-space-6)}.aqmx-document-scroll-row{flex:1 1 0;min-block-size:0}.aqmx-document-failure{min-block-size:0;padding:var(--aqmx-space-7);flex:1 1 0;padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));overflow:auto}.aqmx-document-file{flex-direction:column;flex:1 1 0;min-block-size:0;min-inline-size:0;display:flex}.aqmx-document-spreadsheet-body{min-block-size:0;flex:1 1 0;padding-inline-end:var(--aqmx-tap-circle-gutter,0px);overflow:auto}.aqmx-document-spreadsheet-column{flex-direction:column;min-block-size:100%;display:flex}.aqmx-document-spreadsheet{min-inline-size:0;padding:var(--aqmx-space-6) var(--aqmx-space-7) var(--aqmx-space-7);flex:auto;grid-template:minmax(min-content,1fr)/minmax(0,1fr);display:grid}.aqmx-document-spreadsheet-stage{padding:var(--aqmx-space-7);background:var(--aqmx-surface-sunken);flex:auto;place-items:center;display:grid}.aqmx-document-notice+.aqmx-document-spreadsheet-stage{margin-block-start:var(--aqmx-space-6)}.aqmx-document-spreadsheet-failure{padding:var(--aqmx-space-7);flex:auto}.aqmx-document-spreadsheet>[data-aqmd-spreadsheet]{margin-block:0}.aqmx-sheet-tabs{gap:var(--aqmx-space-3);margin:var(--aqmx-space-6) var(--aqmx-space-7) 0;flex-wrap:wrap;flex:none;display:flex}.aqmx-sheet-tab{min-inline-size:var(--aqmx-control);min-block-size:var(--aqmx-control);max-inline-size:100%;padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);font:inherit;text-align:start;overflow-wrap:anywhere;cursor:pointer;background:0 0;align-items:center;display:inline-flex}.aqmx-sheet-tab:hover{color:var(--aqmx-text);background:var(--aqmx-surface-sunken)}.aqmx-sheet-tab[aria-selected=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface);border-color:currentColor;font-weight:600}.aqmx-document-spreadsheet-sheet{flex-direction:column;flex:auto;min-inline-size:0;display:flex}@media (forced-colors:active){.aqmx-sheet-tab[aria-selected=true]{forced-color-adjust:none;color:highlighttext;background:highlight}}.aqmx-document-toolbar{align-items:center;gap:var(--aqmx-space-3);padding:var(--aqmx-space-3) var(--aqmx-space-6);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex-wrap:wrap;flex:none;display:flex}.aqmx-document-file-icon{color:var(--aqmx-text-muted);flex:none;display:inline-flex}.aqmx-document-file-icon>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon)}.aqmx-document-title{text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;min-inline-size:0;font-weight:600;overflow:hidden}.aqmx-document-level{min-inline-size:var(--aqmx-space-9);color:var(--aqmx-text-muted);font-variant-numeric:tabular-nums;text-align:center;flex:none}.aqmx-document-canvas{touch-action:pan-x pan-y;min-block-size:0;padding:var(--aqmx-space-7);background-color:var(--aqmx-surface-sunken);background-image:radial-gradient(var(--aqmx-border) var(--aqmx-space-1), transparent var(--aqmx-space-1));background-size:var(--aqmx-space-6) var(--aqmx-space-6);flex:1 1 0;grid-template:minmax(0,1fr)/minmax(0,1fr);padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));display:grid;overflow:auto}.aqmx-document-image{margin:auto;display:block}.aqmx-document-image[data-aqmx-image-mode=fit]{object-fit:contain;max-block-size:100%;max-inline-size:100%}.aqmx-document-image[data-aqmx-image-mode=level]{max-block-size:none;max-inline-size:none}.aqmx-document-stage{min-block-size:0;padding:var(--aqmx-space-7);background:var(--aqmx-surface-sunken);flex:1 1 0;grid-template:minmax(0,1fr)/minmax(0,1fr);place-items:center;padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));display:grid;overflow:auto}.aqmx-document-file[data-aqmx-media-type=pdf] .aqmx-document-stage{place-items:stretch stretch;padding:0;padding-inline-end:var(--aqmx-tap-circle-gutter,0px)}.aqmx-document-video{border-radius:var(--aqmx-radius-l);background:var(--aqmx-surface-raised);max-block-size:100%;max-inline-size:100%;box-shadow:var(--aqmx-shadow)}.aqmx-document-audio{inline-size:min(100%, var(--aqmx-column-measure))}.aqmx-document-frame{background:var(--aqmx-surface);border:0;block-size:100%;inline-size:100%}.aqmx-document-inert-link{color:var(--aqmx-text-muted);cursor:not-allowed;text-decoration-style:dotted}.aqmx-document[data-aqmx-document-flow=content]{contain:layout;block-size:auto;overflow:visible}.aqmx-document[data-aqmx-document-flow=content]>*,.aqmx-document[data-aqmx-document-flow=content] .aqmx-document-file>*{flex:none}.aqmx-document[data-aqmx-document-flow=content] .aqmx-document-frame{aspect-ratio:1/1.41421;block-size:auto}.aqmx-document-refresh-bar{flex-direction:column;flex:none;display:flex;container:aqmx-document-bar/inline-size}.aqmx-document-refresh-row{justify-content:flex-end;align-items:center;gap:var(--aqmx-space-2);padding:var(--aqmx-space-4);display:flex}.aqmx-document-column>.aqmx-document-refresh-bar>.aqmx-document-refresh-row{padding-inline-end:calc(var(--aqmx-space-4) + var(--aqmx-page-bar-inset-inline-end,0px))}.aqmx-document-refresh-bar[data-aqmx-sheet-bar]{border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised)}.aqmx-document-refresh-bar[data-aqmx-sheet-bar=merged]>.aqmx-document-refresh-row{padding-inline-start:calc(var(--aqmx-space-4) * 2 + var(--aqmx-control))}.aqmx-document-refresh-failure{margin:0 var(--aqmx-space-3) var(--aqmx-space-2);padding:var(--aqmx-space-4) var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-danger-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere}.aqmx-document-refresh-row>.aqmx-icon-button[data-aqmx-busy=true]>svg{animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite}.aqmx-document-refresh-row>.aqmx-icon-button[aria-busy=true]{cursor:progress}@media (prefers-reduced-motion:reduce){.aqmx-document-refresh-row>.aqmx-icon-button[data-aqmx-busy=true]>svg{animation:none}}.aqmx-edit{background:var(--aqmx-surface);flex:1 1 0;grid-template-columns:minmax(0,1fr);grid-auto-rows:minmax(0,1fr);min-block-size:0;min-inline-size:0;display:grid;position:relative}.aqmx-edit[data-aqmx-edit-layout=content]{display:block}.aqmx-edit-editor,.aqmx-edit-preview{background:var(--aqmx-surface);min-block-size:0;min-inline-size:0}.aqmx-edit-editor{-webkit-user-select:text;user-select:text}.aqmx-edit-editor:has(.cm-content:focus-visible){outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-edit-preview{flex-direction:column;display:flex;overflow:hidden}.aqmx-edit-preview [data-aqmd-scroll-container]{overflow-anchor:none}.aqmx-edit[data-aqmx-edit-split=beside]{grid-template-columns:minmax(0, calc(var(--aqmx-edit-share) - var(--aqmx-edit-gutter) / 2)) var(--aqmx-edit-gutter) minmax(0, 1fr)}.aqmx-edit[data-aqmx-edit-split=stacked]{grid-template-rows:minmax(0, calc(var(--aqmx-edit-share) - var(--aqmx-edit-gutter) / 2)) var(--aqmx-edit-gutter) minmax(0, 1fr)}.aqmx-edit[data-aqmx-edit-split]>.aqmx-edit-editor{grid-area:1/1}.aqmx-edit[data-aqmx-edit-split=beside]>.aqmx-edit-preview{grid-area:1/3}.aqmx-edit[data-aqmx-edit-split=stacked]>.aqmx-edit-preview{grid-area:3/1}.aqmx-edit[data-aqmx-edit-split]:before{content:"";background:var(--aqmx-border)}.aqmx-edit[data-aqmx-edit-split=beside]:before{inline-size:var(--aqmx-space-1);grid-area:1/2;justify-self:center}.aqmx-edit[data-aqmx-edit-split=stacked]:before{block-size:var(--aqmx-space-1);grid-area:2/1;align-self:center}.aqmx-edit-split{pointer-events:none;position:absolute;inset:0}.aqmx-edit-split-handle{pointer-events:auto}.aqmx-edit-split-probe{inline-size:var(--aqmx-column-measure);visibility:hidden;block-size:0;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-edit:is([data-aqmx-edit-view=editor],[data-aqmx-edit-view=preview])>:is(.aqmx-edit-editor,.aqmx-edit-preview){grid-area:1/1}.aqmx-edit[data-aqmx-edit-view=editor]>.aqmx-edit-preview,.aqmx-edit[data-aqmx-edit-view=preview]>.aqmx-edit-editor{visibility:hidden}.aqmx-edit[data-aqmx-edit-layout=content]>.aqmx-edit-preview{display:block;overflow:visible}.aqmx-edit[data-aqmx-edit-layout=content]>[hidden]{display:none}.aqmx-edit-view{gap:var(--aqmx-space-2);flex:0 auto;min-inline-size:0;display:flex}@container aqmx-document-bar not (min-inline-size:calc(80ch + 24px)){.aqmx-edit-view>.aqmx-labelled-button>span{display:none}}@media (pointer:coarse){@container aqmx-document-bar not (min-inline-size:calc(80ch + 44px)){.aqmx-edit-view>.aqmx-labelled-button>span{display:none}}}.aqmx-edit-editor [data-aqmx-conflict-line=ours]{background-color:var(--aqmx-conflict-ours-tint)}.aqmx-edit-editor [data-aqmx-conflict-line=theirs]{background-color:var(--aqmx-conflict-theirs-tint)}.aqmx-edit-editor [data-aqmx-conflict-line=marker]{background-color:var(--aqmx-conflict-marker-tint)}.aqmx-edit-editor [data-aqmx-conflict-actions]{gap:var(--aqmx-space-3);padding:var(--aqmx-space-3) var(--aqmx-space-6);background-color:var(--aqmx-conflict-marker-tint);font-family:system-ui,sans-serif;font-size:var(--aqmx-font-size-body);line-height:var(--aqmx-line-height-compact);flex-wrap:wrap;display:flex}.aqmx-edit-editor [data-aqmx-conflict-choice]{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border-strong);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface);font:inherit;cursor:pointer;font-weight:600}.aqmx-edit-editor [data-aqmx-conflict-choice]:hover{background:var(--aqmx-surface-sunken)}.aqmx-multi-panel-frame .aqmx-document[data-aqmx-document-flow=content] .cm-panels-top{inset-block-start:var(--aqmx-multi-panel-pinned-block-size)!important}.aqmx-edit-message{min-block-size:0;padding:var(--aqmx-space-7);flex:1 1 0;overflow:auto}.aqmx-edit-grant-actions{gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-edit-status{min-inline-size:0;padding-inline:var(--aqmx-space-3);color:var(--aqmx-text-muted);text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;margin:0;overflow:hidden}.aqmx-edit-status[data-aqmx-save=conflicts]{color:var(--aqmx-warning-text)}.aqmx-edit-status[data-aqmx-save=failed]{color:var(--aqmx-danger-text)}.aqmx-document-refresh-bar>.aqmx-edit-grant{margin:0 var(--aqmx-space-3) var(--aqmx-space-2)}.aqmx-confirm{inset:var(--aqmx-dialog-top) auto auto var(--aqmx-dialog-left);margin:var(--aqmx-space-7);inline-size:min(34rem, calc(100vw - 2 * var(--aqmx-space-7)));border:var(--aqmx-space-1) solid var(--aqmx-border-strong);border-radius:var(--aqmx-radius-l);max-inline-size:none;color:var(--aqmx-text);background:var(--aqmx-surface);box-shadow:var(--aqmx-shadow);padding:0;position:fixed}.aqmx-confirm::backdrop{background:#0f172a61}.aqmx-confirm-panel{gap:var(--aqmx-space-6);padding:var(--aqmx-space-7);display:grid}.aqmx-confirm-title{font-size:var(--aqmx-font-size-title);font-weight:600;line-height:var(--aqmx-line-height-compact);margin:0}.aqmx-confirm-body{line-height:var(--aqmx-line-height-prose);overflow-wrap:anywhere;margin:0}.aqmx-confirm-actions{justify-content:flex-end;gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-confirm-actions>.aqmx-callout-action{justify-self:auto}.aqmx-confirm-actions>[data-aqmx-tone=danger]{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-confirm-actions>[aria-disabled=true]{opacity:.618;cursor:not-allowed}.aqmx-history{inline-size:min(55rem, calc(100vw - 2 * var(--aqmx-space-7)))}.aqmx-history-panel{max-block-size:calc(100vh - 2 * var(--aqmx-space-7));overflow:auto}.aqmx-history-note{color:var(--aqmx-text-muted);margin:0}.aqmx-history-list{gap:var(--aqmx-space-2);max-block-size:34vh;margin:0;padding:0;list-style:none;display:grid;overflow:auto}.aqmx-history-entry{align-items:center;gap:var(--aqmx-space-5);inline-size:100%;min-block-size:var(--aqmx-control);padding:var(--aqmx-space-3) var(--aqmx-space-5);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);font:inherit;text-align:start;cursor:pointer;background:0 0;border:0;flex-wrap:wrap;display:flex}.aqmx-history-entry:hover{background:var(--aqmx-surface-sunken)}.aqmx-history-entry[aria-pressed=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface)}.aqmx-history-mark{padding-inline:var(--aqmx-space-4);border:var(--aqmx-space-1) solid currentColor;border-radius:var(--aqmx-radius-s)}.aqmx-history-text{max-block-size:34vh;padding:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);overflow:auto}.aqmx-history-text>pre{white-space:pre-wrap;overflow-wrap:anywhere;margin:0;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace}.aqmx-multi-stage{--aqmx-multi-panel-body-floor:calc(3rem * var(--aqmx-line-height-prose));--aqdd-stage-padding-block:var(--aqmx-space-7);--aqdd-stage-padding-inline:var(--aqmx-space-6) calc(var(--aqmx-space-6) + var(--aqmx-multi-stage-bar-gutter));--aqdd-column-gap:var(--aqmx-space-6);--aqdd-panel-surface:var(--aqmx-surface);--aqdd-panel-border:var(--aqmx-border);--aqdd-panel-title-color:var(--aqmx-text);--aqdd-header-button-color:var(--aqmx-text-muted);--aqdd-header-button-hover-color:var(--aqmx-text);--aqdd-header-button-hover-surface:var(--aqmx-surface-sunken);--aqdd-custom-badge-color:var(--aqmx-warning-text);--aqdd-custom-badge-surface:var(--aqmx-warning-surface);--aqdd-restore-button-color:var(--aqmx-surface);--aqdd-restore-button-surface:var(--aqmx-accent);--aqdd-restore-button-hover-surface:var(--aqmx-info-text);--aqdd-drop-placeholder-color:var(--aqmx-accent);--aqdd-drop-placeholder-surface:var(--aqmx-surface);--aqdd-drop-placeholder-target-surface:var(--aqmx-accent-surface);--aqdd-maximize-top:var(--aqmx-maximize-top,0px);--aqdd-maximize-right:var(--aqmx-maximize-right,0px);--aqdd-maximize-bottom:var(--aqmx-maximize-bottom,0px);--aqdd-maximize-left:var(--aqmx-maximize-left,0px);background:var(--aqmx-surface-sunken);block-size:100%;min-block-size:0;min-inline-size:0;color:var(--aqmx-text);flex-direction:column;display:flex;position:relative}.aqmx-multi-stage:focus-visible{outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-multi-probe{inline-size:var(--aqmx-column-measure);visibility:hidden;pointer-events:none;block-size:0;font-size:1rem;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-multi-layout{flex:auto;min-block-size:0}.aqmx-multi-skeleton{grid-template-columns:repeat(auto-fit, minmax(min(100%, var(--aqmx-column-measure)), 1fr));align-content:start;gap:var(--aqmx-space-7);padding:var(--aqmx-space-7);display:grid;overflow:hidden}.aqmx-multi-skeleton-column{border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-l);background:var(--aqmx-surface)}.aqmx-multi-column{min-inline-size:0}.aqmx-multi-panel{outline:var(--aqmx-space-1) solid var(--aqmx-border-strong);outline-offset:0;color:var(--aqmx-text)}.aqmx-multi-panel[data-maximized]{outline-color:var(--aqmx-focus)}.aqmx-multi-panel-frame{content-visibility:auto;contain-intrinsic-block-size:auto var(--aqmx-space-9);min-block-size:100%}.aqmx-multi-panel-frame:focus-visible{outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-multi-panel-frame[data-aqmx-maximized=false]{-webkit-user-select:none;user-select:none}.aqmx-multi-panel-frame>.aqmx-document-refresh-bar{z-index:1;background:var(--aqmx-surface);position:sticky;inset-block-start:0}.aqmx-multi-panel-frame{--aqmx-multi-panel-pinned-block-size:0px}.aqmx-multi-panel-frame .aqmx-document[data-aqmx-document-flow=content] *{scroll-margin-block-start:calc(var(--aqmx-multi-panel-pinned-block-size) + var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset))}.aqmx-multi-panel-frame:has(>.aqmx-document[data-aqmx-document-flow=fill]){flex-direction:column;block-size:100%;display:flex}.aqmx-multi-panel-frame>.aqmx-document[data-aqmx-document-flow=fill]{flex:1 1 0;block-size:auto}.aqmx-multi-panel-frame .aqmx-document-toolbar>.aqmx-icon-button{flex-shrink:1;min-inline-size:0}.aqmx-multi-toast{animation:aqmx-multi-toast-in var(--aqmx-duration-3) var(--aqmx-ease)}.aqmx-multi-toast:popover-open{max-inline-size:min(34rem, calc(var(--aqmx-multi-toast-room) - var(--aqmx-space-8)));margin:0;position:fixed;inset:auto;inset-block-start:calc(var(--aqmx-multi-toast-block-start) + var(--aqmx-space-6));inset-inline-end:calc(var(--aqmx-multi-toast-inline-end) + var(--aqmx-space-7));overflow:visible}@keyframes aqmx-multi-toast-in{0%{opacity:0;translate:0 calc(var(--aqmx-space-5) * -1)}}@media (prefers-reduced-motion:reduce){.aqmx-multi-toast{animation:none}}@media (forced-colors:active){.aqmx-multi-stage:focus-visible,.aqmx-multi-stage :focus-visible,.aqmx-multi-panel[data-maximized]{outline-color:highlight}}.aqmx-split-frame{flex-direction:column;flex:auto;min-block-size:0;min-inline-size:0;display:flex;position:relative;container:aqmx-split-frame/inline-size}.aqmx-rem-probe{visibility:hidden;pointer-events:none;block-size:0;inline-size:1rem;position:absolute;inset-block-start:0;inset-inline-start:0}.aqmx-split-row{flex:auto;min-block-size:0;min-inline-size:0;display:flex}.aqmx-split{--aqmx-split-band:var(--aqmx-split-handle-size);flex:auto;min-block-size:0}.aqmx-split-frame:not([data-aqmx-explorer-mode=split]) .aqmx-split{--aqmx-split-band:0px}.aqmx-split-rail{padding:var(--aqmx-space-4);border-inline-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex-direction:column;flex:none;display:flex}.aqmx-split-explorer,.aqmx-split-content{background:var(--aqmx-surface);min-block-size:0}.aqmx-split-explorer{background:var(--aqmx-surface-raised)}.aqmx-split-explorer .aqmx-explorer{margin-inline-end:calc(var(--aqmx-split-band) / 2)}.aqmx-split-content{padding-inline-start:calc(var(--aqmx-split-band) / 2)}.aqmx-split-handle{background:var(--aqmx-surface-raised);transition:background-color var(--aqmx-duration-2) var(--aqmx-ease)}.aqmx-split-handle:hover,.aqmx-split-handle:focus-visible{background:var(--aqmx-surface-sunken)}.aqmx-sheet-bar{padding:var(--aqmx-space-4);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex:none;align-items:center;display:flex}.aqmx-sheet-bar[data-aqmx-sheet-bar-merged=true]{z-index:1;background:0 0;border-block-end:0;position:absolute;inset-block-start:0;inset-inline-start:0}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-split-explorer{min-inline-size:13rem!important}@container aqmx-split-frame not (min-width:34.0344rem){.aqmx-split-frame[data-aqmx-measured=false] :is(.aqmx-split-explorer,.aqmx-split-handle,.aqmx-split-rail){display:none!important}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-split{--aqmx-split-band:0px}.aqmx-split-frame[data-aqmx-measured=false]:not(:has(.aqmx-tree-document>.aqmx-document-refresh-bar)):before{content:"";block-size:var(--aqmx-space-9);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex:none}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar{border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised)}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar>.aqmx-document-refresh-row{padding-inline-start:calc(var(--aqmx-space-4) * 2 + var(--aqmx-control))}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar .aqmx-labelled-button>span{clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}}.aqmx-explorer-toggle,.aqmx-explorer-close{justify-content:center;align-items:center;gap:var(--aqmx-space-5);min-inline-size:var(--aqmx-control);min-block-size:var(--aqmx-control);padding:0 var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface);font:inherit;cursor:pointer;transition:background-color var(--aqmx-duration-2) var(--aqmx-ease);display:inline-flex}.aqmx-explorer-close{z-index:1;color:var(--aqmx-text-muted);background:var(--aqmx-surface);pointer-events:auto;border-color:#0000;padding:0;position:relative}.aqmx-explorer-toggle:hover,.aqmx-explorer-close:hover{background:var(--aqmx-surface-sunken)}.aqmx-explorer-toggle>svg,.aqmx-explorer-close>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);flex:none}.aqmx-sheet{inline-size:min(calc(100vw - var(--aqmx-space-9)), 21rem);border:0;border-inline-end:var(--aqmx-space-1) solid var(--aqmx-border);block-size:100dvh;max-block-size:none;max-inline-size:none;color:var(--aqmx-text);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);margin:0;padding:0;position:fixed;inset-block:0;inset-inline:0 auto}.aqmx-sheet::backdrop{background:#0f172a61}.aqmx-sheet-panel{flex-direction:column;block-size:100%;display:flex;position:relative}.aqmx-explorer-chrome{z-index:1;padding:var(--aqmx-space-4);pointer-events:none;justify-content:flex-end;align-items:flex-start;display:flex;position:absolute;inset-block-start:0;inset-inline:0}.aqmx-split-explorer .aqmx-explorer-chrome{inset-inline-end:calc(var(--aqmx-split-band) / 2)}:is(.aqmx-sheet,.aqmx-split-explorer) .aqmx-explorer-header>:first-child{min-block-size:var(--aqmx-control);margin-inline-end:calc(var(--aqmx-control) + var(--aqmx-space-4))}:is(.aqmx-sheet,.aqmx-split-explorer) .aqmx-explorer-source{flex-basis:100%;min-inline-size:0}.aqmx-sheet-notice-slot>.aqmx-toast{--aqmx-sheet-notice-band:calc(var(--aqmx-control) + var(--aqmx-space-4) * 2);--aqmx-sheet-notice-line:calc(var(--aqmx-line-height-compact) * 1em);--aqmx-sheet-notice-inset:calc((var(--aqmx-sheet-notice-band) - var(--aqmx-sheet-notice-line)) / 2);z-index:0;max-inline-size:none;padding-block:var(--aqmx-sheet-notice-inset) 0;padding-inline:var(--aqmx-space-6) var(--aqmx-space-4);border:0;border-block-end:var(--aqmx-space-1) solid var(--aqmx-warning-border);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;box-shadow:none;pointer-events:auto;border-radius:0;position:absolute;inset-block:0 auto;inset-inline:0}.aqmx-sheet-notice-slot>.aqmx-toast:before{content:"";float:inline-end;inline-size:calc(var(--aqmx-control) + var(--aqmx-space-4));block-size:calc(var(--aqmx-sheet-notice-band) - var(--aqmx-sheet-notice-inset) - var(--aqmx-space-1))}.aqmx-sheet-notice-slot>.aqmx-toast:after{content:"";block-size:calc(var(--aqmx-sheet-notice-inset) - var(--aqmx-space-1));display:block}.aqmx-sheet-body{isolation:isolate;flex-direction:column;flex:auto;min-block-size:0;display:flex;position:relative;overflow:hidden}.aqmx-document-column{flex-direction:column;min-block-size:0;display:flex}.aqmx-document-column>.aqmx-document{flex:1 1 0;block-size:auto;min-block-size:0}.aqmx-single{flex:auto;position:relative}.aqmx-tree-document{block-size:100%;inline-size:100%}.aqmx-tree-document[data-aqmx-maximized=true]{top:var(--aqmx-maximize-top,0px);right:var(--aqmx-maximize-right,0px);bottom:var(--aqmx-maximize-bottom,0px);left:var(--aqmx-maximize-left,0px);z-index:50;background:var(--aqmx-surface);block-size:auto;inline-size:auto;position:fixed}.aqmx-split-fallback,.aqmx-stage-fallback{background:var(--aqmx-surface-sunken);flex:auto;min-block-size:0}@media (forced-colors:active){.aqmx-explorer-toggle[aria-expanded=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-explorer-toggle:focus-visible,.aqmx-explorer-close:focus-visible{outline-color:highlight}.aqmx-split-handle:focus-visible{outline:var(--aqmx-focus-ring-width) solid Highlight!important;outline-offset:calc(-1 * var(--aqmx-focus-ring-width))!important}}@media (prefers-reduced-motion:reduce){.aqmx-split-handle,.aqmx-split-handle *{transition-duration:0s!important}}}@layer utilities;
|
|
3
|
+
@layer theme,base;@layer components{.aqmx-root{color-scheme:light;--aqmx-space-1:.0625rem;--aqmx-space-2:.125rem;--aqmx-space-3:.1875rem;--aqmx-space-4:.3125rem;--aqmx-space-5:.5rem;--aqmx-space-6:.8125rem;--aqmx-space-7:1.3125rem;--aqmx-space-8:2.125rem;--aqmx-space-9:3.4375rem;--aqmx-control:2.75rem;--aqmx-focus-ring-width:var(--aqmx-space-2);--aqmx-focus-ring-offset:var(--aqmx-space-2);--aqmx-icon:1rem;--aqmx-radius-s:.3125rem;--aqmx-radius-m:.5rem;--aqmx-radius-l:.8125rem;--aqmx-duration-1:89ms;--aqmx-duration-2:.144s;--aqmx-duration-3:.233s;--aqmx-duration-4:.377s;--aqmx-delay-progress:.233s;--aqmx-ease:cubic-bezier(.2, 0, 0, 1);--aqmx-font-size-body:.8125rem;--aqmx-font-size-title:1rem;--aqmx-font-size-display:1.3125rem;--aqmx-line-height-compact:1.382;--aqmx-line-height-prose:1.618;--aqmx-column-measure:40ch;--aqmx-tap-circle-gutter-size:54px;--aqmx-scroll-bar-overlay-size:0px;--aqmx-scroll-bar-slot-size:8px;--aqmx-split-handle-size:24px;--aqmx-surface:#fff;--aqmx-surface-raised:#f8fafc;--aqmx-surface-sunken:#f1f5f9;--aqmx-border:#cbd5e1;--aqmx-border-strong:#94a3b8;--aqmx-text:#0f172a;--aqmx-text-muted:#3d4a5c;--aqmx-accent:#1d3fa6;--aqmx-accent-surface:#dbeafe;--aqmx-tree-line:#64748b;--aqmx-tree-row-tint:#f1f1f2;--aqmx-tree-row-accent-tint:#dce6fc;--aqmx-focus:#2563eb;--aqmx-info-surface:#eff6ff;--aqmx-info-border:#93c5fd;--aqmx-info-text:#1e3a8a;--aqmx-warning-surface:#fffbeb;--aqmx-warning-border:#fcd34d;--aqmx-warning-text:#78350f;--aqmx-danger-surface:#fef2f2;--aqmx-danger-border:#fca5a5;--aqmx-danger-text:#7f1d1d;--aqmx-syntax-heading:#172554;--aqmx-syntax-link:#1e3a8a;--aqmx-syntax-url:#5b21b6;--aqmx-syntax-code:#7c2d12;--aqmx-syntax-quote:#334155;--aqmx-syntax-mark:#3d4a5c;--aqmx-editor-gutter:#334155;--aqmx-editor-selection:#2563eb36;--aqmx-editor-active-line:#0f172a0d;--aqmx-conflict-ours-tint:#16a34a21;--aqmx-conflict-theirs-tint:#2563eb21;--aqmx-conflict-marker-tint:#d9770636;--aqmx-shadow:0 .0625rem .1875rem #0f172a21, 0 .3125rem .8125rem #0f172a14}.aqmx-root[data-aqmx-theme=dark]{color-scheme:dark;--aqmx-surface:#0f172a;--aqmx-surface-raised:#1e293b;--aqmx-surface-sunken:#020617;--aqmx-border:#334155;--aqmx-border-strong:#64748b;--aqmx-text:#e2e8f0;--aqmx-text-muted:#aab6c8;--aqmx-accent:#bfdbfe;--aqmx-accent-surface:#1e3a8a;--aqmx-tree-line:#94a3b8;--aqmx-tree-row-tint:#1c2436;--aqmx-tree-row-accent-tint:#19387f;--aqmx-focus:#60a5fa;--aqmx-info-surface:#172554;--aqmx-info-border:#1d4ed8;--aqmx-info-text:#bfdbfe;--aqmx-warning-surface:#422006;--aqmx-warning-border:#a16207;--aqmx-warning-text:#fde68a;--aqmx-danger-surface:#450a0a;--aqmx-danger-border:#b91c1c;--aqmx-danger-text:#fecaca;--aqmx-syntax-heading:#bfdbfe;--aqmx-syntax-link:#c7d2fe;--aqmx-syntax-url:#ddd6fe;--aqmx-syntax-code:#fdba74;--aqmx-syntax-quote:#cbd5e1;--aqmx-syntax-mark:#cbd5e1;--aqmx-editor-gutter:#cbd5e1;--aqmx-editor-selection:#3b82f657;--aqmx-editor-active-line:#e2e8f00d;--aqmx-conflict-ours-tint:#22c55e36;--aqmx-conflict-theirs-tint:#3b82f636;--aqmx-conflict-marker-tint:#f59e0b36;--aqmx-shadow:0 .0625rem .1875rem #0000008c, 0 .3125rem .8125rem #00000057}@media (pointer:coarse){.aqmx-root{--aqmx-font-size-body:1rem;--aqmx-tap-circle-gutter-size:0px;--aqmx-scroll-bar-overlay-size:8px;--aqmx-scroll-bar-slot-size:0px;--aqmx-split-handle-size:44px}}@media (forced-colors:active){.aqmx-root.aqmx-root[data-aqmx-theme]{--aqmx-tree-line:CanvasText}}@media (prefers-reduced-motion:reduce){.aqmx-root{--aqmx-duration-1:0s;--aqmx-duration-2:0s;--aqmx-duration-3:0s;--aqmx-duration-4:0s}}.aqmx-root{block-size:100%;min-block-size:0;inline-size:100%;min-inline-size:0;color:var(--aqmx-text);background:var(--aqmx-surface);font-size:var(--aqmx-font-size-body);line-height:var(--aqmx-line-height-compact);flex-direction:column;display:flex;position:relative}.aqmx-root *,.aqmx-root :before,.aqmx-root :after{box-sizing:border-box}.aqmx-icon-button{inline-size:var(--aqmx-control);block-size:var(--aqmx-control);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);cursor:pointer;transition:background-color var(--aqmx-duration-2) var(--aqmx-ease), color var(--aqmx-duration-2) var(--aqmx-ease);background:0 0;border:0;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.aqmx-icon-button:hover{color:var(--aqmx-text);background:var(--aqmx-surface-sunken)}.aqmx-icon-button[aria-pressed=true],.aqmx-icon-button:has(>input:checked),.aqmx-icon-button[aria-expanded=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface)}.aqmx-icon-button:disabled{opacity:.382;cursor:not-allowed}.aqmx-icon-button[aria-disabled=true]{cursor:not-allowed}.aqmx-icon-button[aria-disabled=true]:hover{color:var(--aqmx-text-muted);background:0 0}.aqmx-icon-button>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon)}.aqmx-icon-button[aria-disabled=true]>svg{opacity:.382}.aqmx-icon-button:has(>input[type=radio]){position:relative}.aqmx-icon-button>input[type=radio]{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.aqmx-root :focus-visible,.aqmx-icon-button:has(>input:focus-visible){outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:var(--aqmx-focus-ring-offset)}.aqmx-callout{gap:var(--aqmx-space-5);padding:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-info-border);border-radius:var(--aqmx-radius-l);color:var(--aqmx-info-text);background:var(--aqmx-info-surface);line-height:var(--aqmx-line-height-prose);display:grid}.aqmx-callout[data-aqmx-tone=warning]{border-color:var(--aqmx-warning-border);color:var(--aqmx-warning-text);background:var(--aqmx-warning-surface)}.aqmx-callout[data-aqmx-tone=danger]{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-access-failure{flex:none;min-inline-size:0}.aqmx-callout-title{font-size:var(--aqmx-font-size-title);font-weight:600;line-height:var(--aqmx-line-height-compact);margin:0}.aqmx-callout-body{margin:0}.aqmx-callout-actions{gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-callout-action{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid currentColor;border-radius:var(--aqmx-radius-m);color:inherit;font:inherit;cursor:pointer;background:0 0;justify-self:start;align-items:center;font-weight:600;text-decoration:none;display:inline-flex}.aqmx-progress{z-index:2;block-size:var(--aqmx-space-3);pointer-events:none;position:absolute;inset-block-start:0;inset-inline:0;overflow:hidden}.aqmx-progress:before{content:"";background:var(--aqmx-accent);inline-size:38.1966%;animation:aqmx-progress calc(var(--aqmx-duration-4) * 3) var(--aqmx-ease) infinite;position:absolute;inset-block:0}@keyframes aqmx-progress{0%{inset-inline-start:-38.1966%}to{inset-inline-start:100%}}.aqmx-empty{place-content:center;justify-items:center;gap:var(--aqmx-space-6);block-size:100%;padding:var(--aqmx-space-8);color:var(--aqmx-text-muted);text-align:center;line-height:var(--aqmx-line-height-prose);display:grid}.aqmx-empty-title{color:var(--aqmx-text);font-size:var(--aqmx-font-size-title);margin:0;font-weight:600}.aqmx-skeleton{gap:var(--aqmx-space-6);padding:var(--aqmx-space-7);display:grid}.aqmx-skeleton>span{block-size:var(--aqmx-space-6);border-radius:var(--aqmx-radius-s);background:var(--aqmx-surface-sunken);animation:aqmx-pulse calc(var(--aqmx-duration-4) * 4) ease-in-out infinite;display:block}.aqmx-skeleton>span:nth-child(3n+1){inline-size:61.8034%}.aqmx-skeleton>span:nth-child(3n+2){inline-size:100%}.aqmx-skeleton>span:nth-child(3n){inline-size:85.4102%}@keyframes aqmx-pulse{50%{opacity:.618}}.aqmx-sr-only,.aqmx-document-refresh-bar[data-aqmx-sheet-bar] .aqmx-labelled-button>span{clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.aqmx-native-scroll-bar{display:flex}@media (pointer:coarse){.aqmx-native-scroll-bar{inline-size:0;position:relative}.aqmx-native-scroll-bar>[data-aqvs-scrollbar]{pointer-events:none;position:absolute;inset-block-start:0;inset-inline-end:0}}.aqmx-toast{z-index:60;max-inline-size:min(34rem, calc(100% - var(--aqmx-space-8)));padding:var(--aqmx-space-5) var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-warning-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-warning-text);background:var(--aqmx-warning-surface);box-shadow:var(--aqmx-shadow);position:absolute;inset-block-start:var(--aqmx-space-6);inset-inline-end:var(--aqmx-space-7)}@media (prefers-reduced-motion:reduce){.aqmx-progress:before,.aqmx-skeleton>span{animation:none}}@media (forced-colors:active){.aqmx-icon-button[aria-pressed=true],.aqmx-icon-button:has(>input:checked),.aqmx-icon-button[aria-expanded=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-icon-button[aria-disabled=true]{color:graytext}.aqmx-root :focus-visible,.aqmx-icon-button:has(>input:focus-visible){outline-color:highlight}.aqmx-progress:before{forced-color-adjust:none;background:highlight}.aqmx-skeleton>span{forced-color-adjust:none;background:graytext}}.aqmx-explorer{gap:var(--aqmx-space-5);block-size:100%;min-block-size:0;min-inline-size:0;padding:var(--aqmx-space-4);color:var(--aqmx-text);background:var(--aqmx-surface);flex-direction:column;display:flex;position:relative;overflow-y:auto}.aqmx-explorer-header{align-items:center;gap:var(--aqmx-space-4);min-block-size:var(--aqmx-control);flex-wrap:wrap;flex:none;display:flex}.aqmx-explorer-source{min-inline-size:min(100%,9rem);block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface-raised);font:inherit;text-overflow:ellipsis;cursor:pointer;flex:9rem}.aqmx-explorer-actions{justify-content:flex-end;align-items:center;gap:var(--aqmx-space-2);flex-wrap:wrap;flex:0 auto;min-inline-size:0;margin-inline-start:auto;display:flex}.aqmx-explorer-body{gap:var(--aqmx-space-5);flex-direction:column;flex:1 1 0;min-block-size:0;min-inline-size:0;display:flex;position:relative}.aqmx-labelled-button{gap:var(--aqmx-space-2);min-inline-size:var(--aqmx-control);inline-size:auto;padding-inline:var(--aqmx-space-3);white-space:nowrap;flex:0 auto;display:inline-flex}.aqmx-labelled-button>svg{flex:none}.aqmx-labelled-button>span{text-overflow:ellipsis;min-inline-size:0;overflow:hidden}.aqmx-explorer-refresh-failure,.aqmx-explorer-expand-all-stop{padding:var(--aqmx-space-4) var(--aqmx-space-5);border:var(--aqmx-space-1) solid;border-radius:var(--aqmx-radius-m);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;flex:none;margin:0}.aqmx-sheet-access-failures{gap:var(--aqmx-space-3);flex-direction:column;flex:none;max-block-size:38.1966%;min-inline-size:0;display:flex;overflow-y:auto}.aqmx-explorer-refresh-failure{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-explorer-expand-all-stop{border-color:var(--aqmx-info-border);color:var(--aqmx-info-text);background:var(--aqmx-info-surface)}.aqmx-explorer-actions>.aqmx-labelled-button[data-aqmx-busy=true]>svg{animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite}@keyframes aqmx-explorer-spin{to{rotate:1turn}}.aqmx-explorer-actions>.aqmx-icon-button[aria-busy=true]{cursor:progress}.aqmx-explorer-menu{z-index:50;gap:var(--aqmx-space-1);max-block-size:100%;inline-size:min(21rem,100%);padding:var(--aqmx-space-3);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);display:grid;position:absolute;inset-block-start:0;inset-inline-end:0;overflow-y:auto}.aqmx-explorer-menu-item{align-items:center;gap:var(--aqmx-space-5);inline-size:100%;min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border-radius:var(--aqmx-radius-s);color:var(--aqmx-text);font:inherit;text-align:start;cursor:pointer;transition:background-color var(--aqmx-duration-1) var(--aqmx-ease);background:0 0;border:0;display:flex}.aqmx-explorer-menu-item:hover,.aqmx-explorer-menu-item:focus-visible{background:var(--aqmx-surface-sunken)}.aqmx-explorer-menu-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);color:var(--aqmx-text-muted);flex:none}.aqmx-explorer-menu-name{text-overflow:ellipsis;white-space:nowrap;flex:auto;min-inline-size:0;overflow:hidden}.aqmx-explorer-menu-value{color:var(--aqmx-accent);font-variant-numeric:tabular-nums;flex:none;font-weight:600}.aqmx-explorer-notices{gap:var(--aqmx-space-5);flex:none;display:grid}.aqmx-explorer-tree-area{min-block-size:calc(var(--aqmx-control) * 3);flex-direction:column;flex:1 1 0;min-inline-size:0;display:flex;position:relative}.aqmx-explorer-tree{flex:1 1 0;min-block-size:0;position:relative}.aqmx-explorer-tree-view{block-size:100%}@media (pointer:coarse){.aqmx-explorer-tree [data-aqvs-scrollbar]:has(>[data-aqvs-scrollbar-arrow]){visibility:hidden}}.aqmx-explorer-tree-progress{z-index:1;align-items:center;gap:var(--aqmx-space-2) var(--aqmx-space-4);max-inline-size:calc(100% - var(--aqmx-space-5) * 3);padding:var(--aqmx-space-3) var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;pointer-events:none;animation:aqmx-appear var(--aqmx-duration-2) ease-out var(--aqmx-delay-progress) both;flex-wrap:wrap;margin:0;display:flex;position:absolute;inset-block-end:var(--aqmx-space-9);inset-inline-start:var(--aqmx-space-5)}.aqmx-explorer-tree-progress-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite;flex:none}@keyframes aqmx-appear{0%{opacity:0}}.aqmx-explorer-tree-probe{inline-size:0;block-size:var(--aqmx-control);visibility:hidden;pointer-events:none;color:var(--aqmx-tree-line);forced-color-adjust:none;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-explorer-loading{gap:var(--aqmx-space-5);padding:var(--aqmx-space-6) var(--aqmx-space-5);color:var(--aqmx-text-muted);display:grid}.aqmx-explorer-loading-text{margin:0}.aqmx-explorer-loading>.aqmx-skeleton{padding:0}.aqmx-explorer-tree-message{padding:var(--aqmx-space-5);overflow-y:auto}.aqmx-explorer-empty-icon{inline-size:var(--aqmx-space-8);block-size:var(--aqmx-space-8);color:var(--aqmx-border-strong)}.aqmx-explorer-empty-body{margin:0}.aqmx-explorer-tree [role=treeitem]{border-radius:var(--aqmx-radius-s);color:var(--aqmx-text);transition:background-color var(--aqmx-duration-1) var(--aqmx-ease)}.aqmx-explorer-tree [role=treeitem]:hover{color:var(--aqmx-text);background:var(--aqmx-tree-row-tint)}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]{color:var(--aqmx-text);background:var(--aqmx-tree-row-tint);box-shadow:inset var(--aqmx-space-2) 0 0 currentColor}.aqmx-explorer-tree [role=treeitem][data-entry-selected=true],.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]{color:var(--aqmx-accent);background:var(--aqmx-tree-row-accent-tint)}.aqmx-explorer-tree [role=treeitem]:focus-visible{outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]:focus-visible{box-shadow:inset calc(var(--aqmx-space-2) + var(--aqmx-focus-ring-width)) 0 0 currentColor}.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]{font-weight:600}.aqmx-explorer-tree [role=treeitem][data-aqmx-children=loading]{animation:aqmx-pulse calc(var(--aqmx-duration-4) * 4) ease-in-out infinite}.aqmx-explorer-tree [role=treeitem][data-aqmx-loop]{color:var(--aqmx-text-muted);font-style:italic}.aqmx-explorer-folder-failed{--aqmx-folder-name-floor:3em;align-items:center;min-inline-size:0;max-inline-size:100%;display:flex}.aqmx-explorer-folder-name{flex:10000 1 var(--aqmx-folder-name-floor);text-overflow:ellipsis;white-space:nowrap;min-inline-size:0;max-inline-size:max-content;overflow:hidden}.aqmx-explorer-folder-error{min-inline-size:0;color:var(--aqmx-danger-text);text-indent:var(--aqmx-space-4);text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;overflow:hidden}.aqmx-explorer-folder-retry{flex:1000000 0 calc(var(--aqmx-icon) + (var(--aqmx-space-3) + var(--aqmx-space-1)) * 2);min-inline-size:calc(var(--aqmx-icon) + (var(--aqmx-space-3) + var(--aqmx-space-1)) * 2);max-inline-size:max-content;min-block-size:var(--aqmx-control);padding:0 var(--aqmx-space-3);border:var(--aqmx-space-1) solid var(--aqmx-danger-border);border-radius:var(--aqmx-radius-s);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface);font:inherit;line-height:var(--aqmx-line-height-compact);cursor:pointer;justify-content:center;align-items:center;margin-inline-start:var(--aqmx-space-4);display:inline-flex;overflow:hidden}.aqmx-explorer-folder-retry:focus-visible{outline-offset:calc(-1 * (var(--aqmx-focus-ring-width) + var(--aqmx-space-1)))}.aqmx-explorer-folder-retry-icon{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);flex:none}.aqmx-explorer-folder-retry-text{min-inline-size:0;text-indent:var(--aqmx-space-3);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.aqmx-explorer-tray{gap:var(--aqmx-space-4);min-block-size:calc(var(--aqmx-control) + (var(--aqmx-space-5) + var(--aqmx-space-1)) * 2);padding:var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);flex-direction:column;flex:0 auto;display:flex;overflow-y:auto}.aqmx-explorer-tray-header{justify-content:space-between;align-items:center;gap:var(--aqmx-space-5);flex:none;display:flex}.aqmx-explorer-tray-title{margin:0;font-weight:600}.aqmx-explorer-tray-button{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-5);border-radius:var(--aqmx-radius-m);color:var(--aqmx-accent);font:inherit;cursor:pointer;background:0 0;border:0;flex:none;font-weight:600}.aqmx-explorer-tray-button:hover{background:var(--aqmx-surface-sunken)}.aqmx-explorer-tray-list{gap:var(--aqmx-space-1);min-block-size:var(--aqmx-control);max-block-size:calc(var(--aqmx-control) * 3);flex:0 auto;margin:0;padding:0;list-style:none;display:grid;overflow-y:auto}.aqmx-explorer-tray-item{align-items:center;gap:var(--aqmx-space-4);display:flex}.aqmx-explorer-tray-name{text-overflow:ellipsis;white-space:nowrap;flex:auto;min-inline-size:0;font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;overflow:hidden}.aqmx-explorer-tray-open{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border-radius:var(--aqmx-radius-m);color:var(--aqmx-surface);background:var(--aqmx-accent);font:inherit;cursor:pointer;border:0;flex:none;font-weight:600}@media (forced-colors:active){.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true],.aqmx-explorer-tree [role=treeitem][data-entry-selected=true],.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true],.aqmx-explorer-menu-item[aria-checked=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-explorer-menu-item[aria-checked=true] *,.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true] *,.aqmx-explorer-tree [role=treeitem][data-entry-selected=true] *,.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true] *{color:inherit!important}.aqmx-explorer-tree [role=treeitem][data-entry-item-selected=true]:focus-visible,.aqmx-explorer-tree [role=treeitem][data-entry-selected=true]:focus-visible,.aqmx-explorer-tree [role=treeitem][data-aqmx-open=true]:focus-visible{outline-color:highlighttext}.aqmx-explorer-tray-button,.aqmx-explorer-tray-open,.aqmx-explorer-tray-remove{border:var(--aqmx-space-1) solid ButtonText}}@media (prefers-reduced-motion:reduce){.aqmx-explorer-actions>.aqmx-labelled-button[data-aqmx-busy=true]>svg,.aqmx-explorer-tree-progress-icon,.aqmx-explorer-tree [role=treeitem][data-aqmx-children=loading]{animation:none}}.aqmx-document{contain:layout paint;--aqmd-toolbar-inset-block-start:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset));block-size:100%;min-block-size:0;inline-size:100%;min-inline-size:0;color:var(--aqmx-text);background:var(--aqmx-surface);flex-direction:column;display:flex;position:relative;overflow:hidden}.aqmx-document-viewer:has([data-aqmd-scroll-bar]){--aqmd-toolbar-inset-inline-end:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset) + var(--aqmx-scroll-bar-overlay-size))}.aqmx-document [data-theme]{background-color:#0000!important}.aqmx-document .markdown-body :is(sup,sub) a{outline-offset:var(--aqmx-focus-ring-offset)!important}.aqmx-document *{scroll-margin:calc(var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset))}.aqmx-document :is([data-aqmd-scroll-container],[data-aqmx-document-scroller]):focus-visible{outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-document[aria-busy=true]>:not(.aqmx-progress){opacity:.618;transition:opacity var(--aqmx-duration-3) var(--aqmx-ease)}.aqmx-document-viewer{flex:1 1 0;min-block-size:0;min-inline-size:0}.aqmx-document>.aqmx-document-viewer:is(:first-child,.aqmx-progress+*){--aqmd-toolbar-reserve-before-measure:1}.aqmx-document-notice{margin:var(--aqmx-space-6) var(--aqmx-space-7) 0;overflow-wrap:anywhere;flex:none}.aqmx-document-notices{flex-direction:column;flex:none;display:flex}.aqmx-document-notices:not(:empty){padding-block-end:var(--aqmx-space-6)}.aqmx-document-scroll-row{flex:1 1 0;min-block-size:0}.aqmx-document-failure{min-block-size:0;padding:var(--aqmx-space-7);flex:1 1 0;padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));overflow:auto}.aqmx-document-file{flex-direction:column;flex:1 1 0;min-block-size:0;min-inline-size:0;display:flex}.aqmx-document-spreadsheet-body{min-block-size:0;flex:1 1 0;padding-inline-end:var(--aqmx-tap-circle-gutter,0px);overflow:auto}.aqmx-document-spreadsheet-column{flex-direction:column;min-block-size:100%;display:flex}.aqmx-document-spreadsheet{min-inline-size:0;padding:var(--aqmx-space-6) var(--aqmx-space-7) var(--aqmx-space-7);flex:auto;grid-template:minmax(min-content,1fr)/minmax(0,1fr);display:grid}.aqmx-document-spreadsheet-stage{padding:var(--aqmx-space-7);background:var(--aqmx-surface-sunken);flex:auto;place-items:center;display:grid}.aqmx-document-notice+.aqmx-document-spreadsheet-stage{margin-block-start:var(--aqmx-space-6)}.aqmx-document-spreadsheet-failure{padding:var(--aqmx-space-7);flex:auto}.aqmx-document-spreadsheet>[data-aqmd-spreadsheet]{margin-block:0}.aqmx-sheet-tabs{gap:var(--aqmx-space-3);margin:var(--aqmx-space-6) var(--aqmx-space-7) 0;flex-wrap:wrap;flex:none;display:flex}.aqmx-sheet-tab{min-inline-size:var(--aqmx-control);min-block-size:var(--aqmx-control);max-inline-size:100%;padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text-muted);font:inherit;text-align:start;overflow-wrap:anywhere;cursor:pointer;background:0 0;align-items:center;display:inline-flex}.aqmx-sheet-tab:hover{color:var(--aqmx-text);background:var(--aqmx-surface-sunken)}.aqmx-sheet-tab[aria-selected=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface);border-color:currentColor;font-weight:600}.aqmx-document-spreadsheet-sheet{flex-direction:column;flex:auto;min-inline-size:0;display:flex}@media (forced-colors:active){.aqmx-sheet-tab[aria-selected=true]{forced-color-adjust:none;color:highlighttext;background:highlight}}.aqmx-document-toolbar{align-items:center;gap:var(--aqmx-space-3);padding:var(--aqmx-space-3) var(--aqmx-space-6);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex-wrap:wrap;flex:none;display:flex}.aqmx-document-file-icon{color:var(--aqmx-text-muted);flex:none;display:inline-flex}.aqmx-document-file-icon>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon)}.aqmx-document-title{text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;min-inline-size:0;font-weight:600;overflow:hidden}.aqmx-document-level{min-inline-size:var(--aqmx-space-9);color:var(--aqmx-text-muted);font-variant-numeric:tabular-nums;text-align:center;flex:none}.aqmx-document-canvas{touch-action:pan-x pan-y;min-block-size:0;padding:var(--aqmx-space-7);background-color:var(--aqmx-surface-sunken);background-image:radial-gradient(var(--aqmx-border) var(--aqmx-space-1), transparent var(--aqmx-space-1));background-size:var(--aqmx-space-6) var(--aqmx-space-6);flex:1 1 0;grid-template:minmax(0,1fr)/minmax(0,1fr);padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));display:grid;overflow:auto}.aqmx-document-image{margin:auto;display:block}.aqmx-document-image[data-aqmx-image-mode=fit]{object-fit:contain;max-block-size:100%;max-inline-size:100%}.aqmx-document-image[data-aqmx-image-mode=level]{max-block-size:none;max-inline-size:none}.aqmx-document-stage{min-block-size:0;padding:var(--aqmx-space-7);background:var(--aqmx-surface-sunken);flex:1 1 0;grid-template:minmax(0,1fr)/minmax(0,1fr);place-items:center;padding-inline-end:calc(var(--aqmx-space-7) + var(--aqmx-tap-circle-gutter,0px));display:grid;overflow:auto}.aqmx-document-file[data-aqmx-media-type=pdf] .aqmx-document-stage{place-items:stretch stretch;padding:0;padding-inline-end:var(--aqmx-tap-circle-gutter,0px)}.aqmx-document-video{border-radius:var(--aqmx-radius-l);background:var(--aqmx-surface-raised);max-block-size:100%;max-inline-size:100%;box-shadow:var(--aqmx-shadow)}.aqmx-document-audio{inline-size:min(100%, var(--aqmx-column-measure))}.aqmx-document-frame{background:var(--aqmx-surface);border:0;block-size:100%;inline-size:100%}.aqmx-document-inert-link{color:var(--aqmx-text-muted);cursor:not-allowed;text-decoration-style:dotted}.aqmx-document[data-aqmx-document-flow=content]{contain:layout;block-size:auto;overflow:visible}.aqmx-document[data-aqmx-document-flow=content]>*,.aqmx-document[data-aqmx-document-flow=content] .aqmx-document-file>*{flex:none}.aqmx-document[data-aqmx-document-flow=content] .aqmx-document-frame{aspect-ratio:1/1.41421;block-size:auto}.aqmx-document-refresh-bar{flex-direction:column;flex:none;display:flex;container:aqmx-document-bar/inline-size}.aqmx-document-refresh-row{justify-content:flex-end;align-items:center;gap:var(--aqmx-space-2);padding:var(--aqmx-space-4);display:flex}.aqmx-document-column>.aqmx-document-refresh-bar>.aqmx-document-refresh-row{padding-inline-end:calc(var(--aqmx-space-4) + var(--aqmx-page-bar-inset-inline-end,0px))}.aqmx-document-refresh-bar[data-aqmx-sheet-bar]{border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised)}.aqmx-document-refresh-bar[data-aqmx-sheet-bar=merged]>.aqmx-document-refresh-row{padding-inline-start:calc(var(--aqmx-space-4) * 2 + var(--aqmx-control))}.aqmx-document-refresh-failure{margin:0 var(--aqmx-space-3) var(--aqmx-space-2);padding:var(--aqmx-space-4) var(--aqmx-space-5);border:var(--aqmx-space-1) solid var(--aqmx-danger-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere}.aqmx-document-refresh-bar>.aqmx-access-failure{margin:0 var(--aqmx-space-3) var(--aqmx-space-2)}.aqmx-document-refresh-row>.aqmx-icon-button[data-aqmx-busy=true]>svg{animation:aqmx-explorer-spin calc(var(--aqmx-duration-4) * 3) linear infinite}.aqmx-document-refresh-row>.aqmx-icon-button[aria-busy=true]{cursor:progress}@media (prefers-reduced-motion:reduce){.aqmx-document-refresh-row>.aqmx-icon-button[data-aqmx-busy=true]>svg{animation:none}}.aqmx-edit{background:var(--aqmx-surface);flex:1 1 0;grid-template-columns:minmax(0,1fr);grid-auto-rows:minmax(0,1fr);min-block-size:0;min-inline-size:0;display:grid;position:relative}.aqmx-edit[data-aqmx-edit-layout=content]{display:block}.aqmx-edit-editor,.aqmx-edit-preview{background:var(--aqmx-surface);min-block-size:0;min-inline-size:0}.aqmx-edit-editor{-webkit-user-select:text;user-select:text}.aqmx-edit-editor:has(.cm-content:focus-visible){outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-edit-preview{flex-direction:column;display:flex;overflow:hidden}.aqmx-edit-preview [data-aqmd-scroll-container]{overflow-anchor:none}.aqmx-edit[data-aqmx-edit-split=beside]{grid-template-columns:minmax(0, calc(var(--aqmx-edit-share) - var(--aqmx-edit-gutter) / 2)) var(--aqmx-edit-gutter) minmax(0, 1fr)}.aqmx-edit[data-aqmx-edit-split=stacked]{grid-template-rows:minmax(0, calc(var(--aqmx-edit-share) - var(--aqmx-edit-gutter) / 2)) var(--aqmx-edit-gutter) minmax(0, 1fr)}.aqmx-edit[data-aqmx-edit-split]>.aqmx-edit-editor{grid-area:1/1}.aqmx-edit[data-aqmx-edit-split=beside]>.aqmx-edit-preview{grid-area:1/3}.aqmx-edit[data-aqmx-edit-split=stacked]>.aqmx-edit-preview{grid-area:3/1}.aqmx-edit[data-aqmx-edit-split]:before{content:"";background:var(--aqmx-border)}.aqmx-edit[data-aqmx-edit-split=beside]:before{inline-size:var(--aqmx-space-1);grid-area:1/2;justify-self:center}.aqmx-edit[data-aqmx-edit-split=stacked]:before{block-size:var(--aqmx-space-1);grid-area:2/1;align-self:center}.aqmx-edit-split{pointer-events:none;position:absolute;inset:0}.aqmx-edit-split-handle{pointer-events:auto}.aqmx-edit-split-probe{inline-size:var(--aqmx-column-measure);visibility:hidden;block-size:0;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-edit:is([data-aqmx-edit-view=editor],[data-aqmx-edit-view=preview])>:is(.aqmx-edit-editor,.aqmx-edit-preview){grid-area:1/1}.aqmx-edit[data-aqmx-edit-view=editor]>.aqmx-edit-preview,.aqmx-edit[data-aqmx-edit-view=preview]>.aqmx-edit-editor{visibility:hidden}.aqmx-edit[data-aqmx-edit-layout=content]>.aqmx-edit-preview{display:block;overflow:visible}.aqmx-edit[data-aqmx-edit-layout=content]>[hidden]{display:none}.aqmx-edit-view{gap:var(--aqmx-space-2);flex:0 auto;min-inline-size:0;display:flex}@container aqmx-document-bar not (min-inline-size:calc(80ch + 24px)){.aqmx-edit-view>.aqmx-labelled-button>span{display:none}}@media (pointer:coarse){@container aqmx-document-bar not (min-inline-size:calc(80ch + 44px)){.aqmx-edit-view>.aqmx-labelled-button>span{display:none}}}.aqmx-edit-editor [data-aqmx-conflict-line=ours]{background-color:var(--aqmx-conflict-ours-tint)}.aqmx-edit-editor [data-aqmx-conflict-line=theirs]{background-color:var(--aqmx-conflict-theirs-tint)}.aqmx-edit-editor [data-aqmx-conflict-line=marker]{background-color:var(--aqmx-conflict-marker-tint)}.aqmx-edit-editor [data-aqmx-conflict-actions]{gap:var(--aqmx-space-3);padding:var(--aqmx-space-3) var(--aqmx-space-6);background-color:var(--aqmx-conflict-marker-tint);font-family:system-ui,sans-serif;font-size:var(--aqmx-font-size-body);line-height:var(--aqmx-line-height-compact);flex-wrap:wrap;display:flex}.aqmx-edit-editor [data-aqmx-conflict-choice]{min-block-size:var(--aqmx-control);padding-inline:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border-strong);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface);font:inherit;cursor:pointer;font-weight:600}.aqmx-edit-editor [data-aqmx-conflict-choice]:hover{background:var(--aqmx-surface-sunken)}.aqmx-multi-panel-frame .aqmx-document[data-aqmx-document-flow=content] .cm-panels-top{inset-block-start:var(--aqmx-multi-panel-pinned-block-size)!important}.aqmx-edit-message{min-block-size:0;padding:var(--aqmx-space-7);flex:1 1 0;overflow:auto}.aqmx-edit-grant-actions{gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-edit-status{min-inline-size:0;padding-inline:var(--aqmx-space-3);color:var(--aqmx-text-muted);text-overflow:ellipsis;white-space:nowrap;flex:1 1 0;margin:0;overflow:hidden}.aqmx-edit-status[data-aqmx-save=conflicts]{color:var(--aqmx-warning-text)}.aqmx-edit-status[data-aqmx-save=failed]{color:var(--aqmx-danger-text)}.aqmx-document-refresh-bar>.aqmx-edit-grant{margin:0 var(--aqmx-space-3) var(--aqmx-space-2)}.aqmx-confirm{inset:var(--aqmx-dialog-top) auto auto var(--aqmx-dialog-left);margin:var(--aqmx-space-7);inline-size:min(34rem, calc(100vw - 2 * var(--aqmx-space-7)));border:var(--aqmx-space-1) solid var(--aqmx-border-strong);border-radius:var(--aqmx-radius-l);max-inline-size:none;color:var(--aqmx-text);background:var(--aqmx-surface);box-shadow:var(--aqmx-shadow);padding:0;position:fixed}.aqmx-confirm::backdrop{background:#0f172a61}.aqmx-confirm-panel{gap:var(--aqmx-space-6);padding:var(--aqmx-space-7);display:grid}.aqmx-confirm-title{font-size:var(--aqmx-font-size-title);font-weight:600;line-height:var(--aqmx-line-height-compact);margin:0}.aqmx-confirm-body{line-height:var(--aqmx-line-height-prose);overflow-wrap:anywhere;margin:0}.aqmx-confirm-actions{justify-content:flex-end;gap:var(--aqmx-space-5);flex-wrap:wrap;display:flex}.aqmx-confirm-actions>.aqmx-callout-action{justify-self:auto}.aqmx-confirm-actions>[data-aqmx-tone=danger]{border-color:var(--aqmx-danger-border);color:var(--aqmx-danger-text);background:var(--aqmx-danger-surface)}.aqmx-confirm-actions>[aria-disabled=true]{opacity:.618;cursor:not-allowed}.aqmx-history{inline-size:min(55rem, calc(100vw - 2 * var(--aqmx-space-7)))}.aqmx-history-panel{max-block-size:calc(100vh - 2 * var(--aqmx-space-7));overflow:auto}.aqmx-history-note{color:var(--aqmx-text-muted);margin:0}.aqmx-history-list{gap:var(--aqmx-space-2);max-block-size:34vh;margin:0;padding:0;list-style:none;display:grid;overflow:auto}.aqmx-history-entry{align-items:center;gap:var(--aqmx-space-5);inline-size:100%;min-block-size:var(--aqmx-control);padding:var(--aqmx-space-3) var(--aqmx-space-5);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);font:inherit;text-align:start;cursor:pointer;background:0 0;border:0;flex-wrap:wrap;display:flex}.aqmx-history-entry:hover{background:var(--aqmx-surface-sunken)}.aqmx-history-entry[aria-pressed=true]{color:var(--aqmx-accent);background:var(--aqmx-accent-surface)}.aqmx-history-mark{padding-inline:var(--aqmx-space-4);border:var(--aqmx-space-1) solid currentColor;border-radius:var(--aqmx-radius-s)}.aqmx-history-text{max-block-size:34vh;padding:var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);background:var(--aqmx-surface-raised);overflow:auto}.aqmx-history-text>pre{white-space:pre-wrap;overflow-wrap:anywhere;margin:0;font-family:ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace}.aqmx-multi-stage{--aqmx-multi-panel-body-floor:calc(3rem * var(--aqmx-line-height-prose));--aqdd-stage-padding-block:var(--aqmx-space-7);--aqdd-stage-padding-inline:var(--aqmx-space-6) calc(var(--aqmx-space-6) + var(--aqmx-multi-stage-bar-gutter));--aqdd-column-gap:var(--aqmx-space-6);--aqdd-panel-surface:var(--aqmx-surface);--aqdd-panel-border:var(--aqmx-border);--aqdd-panel-title-color:var(--aqmx-text);--aqdd-header-button-color:var(--aqmx-text-muted);--aqdd-header-button-hover-color:var(--aqmx-text);--aqdd-header-button-hover-surface:var(--aqmx-surface-sunken);--aqdd-custom-badge-color:var(--aqmx-warning-text);--aqdd-custom-badge-surface:var(--aqmx-warning-surface);--aqdd-restore-button-color:var(--aqmx-surface);--aqdd-restore-button-surface:var(--aqmx-accent);--aqdd-restore-button-hover-surface:var(--aqmx-info-text);--aqdd-drop-placeholder-color:var(--aqmx-accent);--aqdd-drop-placeholder-surface:var(--aqmx-surface);--aqdd-drop-placeholder-target-surface:var(--aqmx-accent-surface);--aqdd-maximize-top:var(--aqmx-maximize-top,0px);--aqdd-maximize-right:var(--aqmx-maximize-right,0px);--aqdd-maximize-bottom:var(--aqmx-maximize-bottom,0px);--aqdd-maximize-left:var(--aqmx-maximize-left,0px);background:var(--aqmx-surface-sunken);block-size:100%;min-block-size:0;min-inline-size:0;color:var(--aqmx-text);flex-direction:column;display:flex;position:relative}.aqmx-multi-stage:focus-visible{outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-multi-probe{inline-size:var(--aqmx-column-measure);visibility:hidden;pointer-events:none;block-size:0;font-size:1rem;position:absolute;inset-block-start:0;inset-inline-start:0;overflow:hidden}.aqmx-multi-layout{flex:auto;min-block-size:0}.aqmx-multi-skeleton{grid-template-columns:repeat(auto-fit, minmax(min(100%, var(--aqmx-column-measure)), 1fr));align-content:start;gap:var(--aqmx-space-7);padding:var(--aqmx-space-7);display:grid;overflow:hidden}.aqmx-multi-skeleton-column{border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-l);background:var(--aqmx-surface)}.aqmx-multi-column{min-inline-size:0}.aqmx-multi-panel{outline:var(--aqmx-space-1) solid var(--aqmx-border-strong);outline-offset:0;color:var(--aqmx-text)}.aqmx-multi-panel[data-maximized]{outline-color:var(--aqmx-focus)}.aqmx-multi-panel-frame{content-visibility:auto;contain-intrinsic-block-size:auto var(--aqmx-space-9);min-block-size:100%}.aqmx-multi-panel-frame:focus-visible{outline:var(--aqmx-focus-ring-width) solid var(--aqmx-focus);outline-offset:calc(-1 * var(--aqmx-focus-ring-width))}.aqmx-multi-panel-frame[data-aqmx-maximized=false]{-webkit-user-select:none;user-select:none}.aqmx-multi-panel-frame>.aqmx-document-refresh-bar{z-index:1;background:var(--aqmx-surface);position:sticky;inset-block-start:0}.aqmx-multi-panel-frame{--aqmx-multi-panel-pinned-block-size:0px}.aqmx-multi-panel-frame .aqmx-document[data-aqmx-document-flow=content] *{scroll-margin-block-start:calc(var(--aqmx-multi-panel-pinned-block-size) + var(--aqmx-focus-ring-width) + var(--aqmx-focus-ring-offset))}.aqmx-multi-panel-frame:has(>.aqmx-document[data-aqmx-document-flow=fill]){flex-direction:column;block-size:100%;display:flex}.aqmx-multi-panel-frame>.aqmx-document[data-aqmx-document-flow=fill]{flex:1 1 0;block-size:auto}.aqmx-multi-panel-frame .aqmx-document-toolbar>.aqmx-icon-button{flex-shrink:1;min-inline-size:0}.aqmx-multi-toast{animation:aqmx-multi-toast-in var(--aqmx-duration-3) var(--aqmx-ease)}.aqmx-multi-toast:popover-open{max-inline-size:min(34rem, calc(var(--aqmx-multi-toast-room) - var(--aqmx-space-8)));margin:0;position:fixed;inset:auto;inset-block-start:calc(var(--aqmx-multi-toast-block-start) + var(--aqmx-space-6));inset-inline-end:calc(var(--aqmx-multi-toast-inline-end) + var(--aqmx-space-7));overflow:visible}@keyframes aqmx-multi-toast-in{0%{opacity:0;translate:0 calc(var(--aqmx-space-5) * -1)}}@media (prefers-reduced-motion:reduce){.aqmx-multi-toast{animation:none}}@media (forced-colors:active){.aqmx-multi-stage:focus-visible,.aqmx-multi-stage :focus-visible,.aqmx-multi-panel[data-maximized]{outline-color:highlight}}.aqmx-split-frame{flex-direction:column;flex:auto;min-block-size:0;min-inline-size:0;display:flex;position:relative;container:aqmx-split-frame/inline-size}.aqmx-rem-probe{visibility:hidden;pointer-events:none;block-size:0;inline-size:1rem;position:absolute;inset-block-start:0;inset-inline-start:0}.aqmx-split-row{flex:auto;min-block-size:0;min-inline-size:0;display:flex}.aqmx-split{--aqmx-split-band:var(--aqmx-split-handle-size);flex:auto;min-block-size:0}.aqmx-split-frame:not([data-aqmx-explorer-mode=split]) .aqmx-split{--aqmx-split-band:0px}.aqmx-split-rail{padding:var(--aqmx-space-4);border-inline-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex-direction:column;flex:none;display:flex}.aqmx-split-explorer,.aqmx-split-content{background:var(--aqmx-surface);min-block-size:0}.aqmx-split-explorer{background:var(--aqmx-surface-raised)}.aqmx-split-explorer .aqmx-explorer{margin-inline-end:calc(var(--aqmx-split-band) / 2)}.aqmx-split-content{padding-inline-start:calc(var(--aqmx-split-band) / 2)}.aqmx-split-handle{background:var(--aqmx-surface-raised);transition:background-color var(--aqmx-duration-2) var(--aqmx-ease)}.aqmx-split-handle:hover,.aqmx-split-handle:focus-visible{background:var(--aqmx-surface-sunken)}.aqmx-sheet-bar{padding:var(--aqmx-space-4);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex:none;align-items:center;display:flex}.aqmx-sheet-bar[data-aqmx-sheet-bar-merged=true]{z-index:1;background:0 0;border-block-end:0;position:absolute;inset-block-start:0;inset-inline-start:0}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-split-explorer{min-inline-size:13rem!important}@container aqmx-split-frame not (min-width:34.0344rem){.aqmx-split-frame[data-aqmx-measured=false] :is(.aqmx-split-explorer,.aqmx-split-handle,.aqmx-split-rail){display:none!important}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-split{--aqmx-split-band:0px}.aqmx-split-frame[data-aqmx-measured=false]:not(:has(.aqmx-tree-document>.aqmx-document-refresh-bar)):before{content:"";block-size:var(--aqmx-space-9);border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised);flex:none}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar{border-block-end:var(--aqmx-space-1) solid var(--aqmx-border);background:var(--aqmx-surface-raised)}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar>.aqmx-document-refresh-row{padding-inline-start:calc(var(--aqmx-space-4) * 2 + var(--aqmx-control))}.aqmx-split-frame[data-aqmx-measured=false] .aqmx-tree-document>.aqmx-document-refresh-bar .aqmx-labelled-button>span{clip:rect(0, 0, 0, 0);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}}.aqmx-explorer-toggle,.aqmx-explorer-close{justify-content:center;align-items:center;gap:var(--aqmx-space-5);min-inline-size:var(--aqmx-control);min-block-size:var(--aqmx-control);padding:0 var(--aqmx-space-6);border:var(--aqmx-space-1) solid var(--aqmx-border);border-radius:var(--aqmx-radius-m);color:var(--aqmx-text);background:var(--aqmx-surface);font:inherit;cursor:pointer;transition:background-color var(--aqmx-duration-2) var(--aqmx-ease);display:inline-flex}.aqmx-explorer-close{z-index:1;color:var(--aqmx-text-muted);background:var(--aqmx-surface);pointer-events:auto;border-color:#0000;padding:0;position:relative}.aqmx-explorer-toggle:hover,.aqmx-explorer-close:hover{background:var(--aqmx-surface-sunken)}.aqmx-explorer-toggle>svg,.aqmx-explorer-close>svg{inline-size:var(--aqmx-icon);block-size:var(--aqmx-icon);flex:none}.aqmx-sheet{inline-size:min(calc(100vw - var(--aqmx-space-9)), 21rem);border:0;border-inline-end:var(--aqmx-space-1) solid var(--aqmx-border);block-size:100dvh;max-block-size:none;max-inline-size:none;color:var(--aqmx-text);background:var(--aqmx-surface-raised);box-shadow:var(--aqmx-shadow);margin:0;padding:0;position:fixed;inset-block:0;inset-inline:0 auto}.aqmx-sheet::backdrop{background:#0f172a61}.aqmx-sheet-panel{flex-direction:column;block-size:100%;display:flex;position:relative}.aqmx-explorer-chrome{z-index:1;padding:var(--aqmx-space-4);pointer-events:none;justify-content:flex-end;align-items:flex-start;display:flex;position:absolute;inset-block-start:0;inset-inline:0}.aqmx-split-explorer .aqmx-explorer-chrome{inset-inline-end:calc(var(--aqmx-split-band) / 2)}:is(.aqmx-sheet,.aqmx-split-explorer) .aqmx-explorer-header>:first-child{min-block-size:var(--aqmx-control);margin-inline-end:calc(var(--aqmx-control) + var(--aqmx-space-4))}:is(.aqmx-sheet,.aqmx-split-explorer) .aqmx-explorer-source{flex-basis:100%;min-inline-size:0}.aqmx-sheet-notice-slot>.aqmx-toast{--aqmx-sheet-notice-band:calc(var(--aqmx-control) + var(--aqmx-space-4) * 2);--aqmx-sheet-notice-line:calc(var(--aqmx-line-height-compact) * 1em);--aqmx-sheet-notice-inset:calc((var(--aqmx-sheet-notice-band) - var(--aqmx-sheet-notice-line)) / 2);z-index:0;max-inline-size:none;padding-block:var(--aqmx-sheet-notice-inset) 0;padding-inline:var(--aqmx-space-6) var(--aqmx-space-4);border:0;border-block-end:var(--aqmx-space-1) solid var(--aqmx-warning-border);line-height:var(--aqmx-line-height-compact);overflow-wrap:anywhere;box-shadow:none;pointer-events:auto;border-radius:0;position:absolute;inset-block:0 auto;inset-inline:0}.aqmx-sheet-notice-slot>.aqmx-toast:before{content:"";float:inline-end;inline-size:calc(var(--aqmx-control) + var(--aqmx-space-4));block-size:calc(var(--aqmx-sheet-notice-band) - var(--aqmx-sheet-notice-inset) - var(--aqmx-space-1))}.aqmx-sheet-notice-slot>.aqmx-toast:after{content:"";block-size:calc(var(--aqmx-sheet-notice-inset) - var(--aqmx-space-1));display:block}.aqmx-sheet-body{isolation:isolate;flex-direction:column;flex:auto;min-block-size:0;display:flex;position:relative;overflow:hidden}.aqmx-document-column{flex-direction:column;min-block-size:0;display:flex}.aqmx-document-column>.aqmx-document{flex:1 1 0;block-size:auto;min-block-size:0}.aqmx-single{flex:auto;position:relative}.aqmx-tree-document{block-size:100%;inline-size:100%}.aqmx-tree-document[data-aqmx-maximized=true]{top:var(--aqmx-maximize-top,0px);right:var(--aqmx-maximize-right,0px);bottom:var(--aqmx-maximize-bottom,0px);left:var(--aqmx-maximize-left,0px);z-index:50;background:var(--aqmx-surface);block-size:auto;inline-size:auto;position:fixed}.aqmx-split-fallback,.aqmx-stage-fallback{background:var(--aqmx-surface-sunken);flex:auto;min-block-size:0}@media (forced-colors:active){.aqmx-explorer-toggle[aria-expanded=true]{forced-color-adjust:none;color:highlighttext;background:highlight}.aqmx-explorer-toggle:focus-visible,.aqmx-explorer-close:focus-visible{outline-color:highlight}.aqmx-split-handle:focus-visible{outline:var(--aqmx-focus-ring-width) solid Highlight!important;outline-offset:calc(-1 * var(--aqmx-focus-ring-width))!important}}@media (prefers-reduced-motion:reduce){.aqmx-split-handle,.aqmx-split-handle *{transition-duration:0s!important}}}@layer utilities;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@aiquants/virtualscroll"),e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@aiquants/virtualscroll"),e=require("./index-BmOU3xcK.cjs"),C=Object.freeze({renderVisual:r.tapScrollCircleSampleVisual,...e.TAP_SCROLL_CIRCLE_SPEED_RANGE,size:e.TAP_SCROLL_CIRCLE_SIZE,offsetX:e.TAP_SCROLL_CIRCLE_OFFSET_X}),L=Object.freeze({...C,visibility:"scrolling"}),l=_=>_?L:C,t=Object.freeze({enabled:!1});exports.NO_TAP_SCROLL_CIRCLE=t;exports.TAP_SCROLL_CIRCLE=C;exports.TOUCH_TAP_SCROLL_CIRCLE=L;exports.tapScrollCircleFor=l;
|
|
@@ -22,6 +22,7 @@ Tests and host styling may rely on the `data-testid` values and `data-aqmx-*` at
|
|
|
22
22
|
| `data-testid="markdown-explorer-sheet"` | The explorer sheet (a modal `dialog`) | Has the `open` attribute while shown |
|
|
23
23
|
| `data-testid="markdown-explorer-sheet-close"` | Close button of the sheet | |
|
|
24
24
|
| `data-testid="markdown-explorer-sheet-announcer"` | The sheet's polite live region (`role="status"`), inside the dialog | Holds the announcements while the sheet is open (the modal dialog hides the root's region), with the same text as the root's region would; empty while the sheet is closed and when it opens |
|
|
25
|
+
| `data-testid="markdown-explorer-sheet-access-failures"` | The access failures of the content behind the open sheet, first in the explorer inside the sheet | Present only while the open sheet holds one. The content behind the modal sheet is inert and hidden from assistive technology, so each access failure met there is drawn here instead of in its place — its own element, with its hook and `data-aqmx-failure` — in the order they came, and goes back to its place, with the same occurrence, once the sheet closes (see [Access failures](../../README.md#access-failures)) |
|
|
25
26
|
| `data-testid="markdown-explorer-split-loading"` | Placeholder while the tree view's code loads | Carries `data-aqmx-content-pane` |
|
|
26
27
|
| `data-testid="markdown-explorer-single"` | Single view frame | Carries `data-aqmx-content-pane` |
|
|
27
28
|
| `data-aqmx-content-pane` | The content pane the explorer's dialogs are centered over | The document column of the tree view (the bar and the document region), the single view's frame, the multi view's stage, and a maximized panel's frame (`markdown-explorer-panel-frame`, inside the stage) while it is maximized; a view's loading placeholder while its code loads. The innermost element carrying it is the pane |
|
|
@@ -33,11 +34,13 @@ Tests and host styling may rely on the `data-testid` values and `data-aqmx-*` at
|
|
|
33
34
|
| `data-testid="markdown-explorer-edit-next-conflict"` / `-history` / `-save` | The editor's actions in the bar | Next conflict only while conflicts wait (it moves the focus to the conflict's first choice); History (`aria-haspopup="dialog"`) only when the host keeps revisions; Save carries `aria-keyshortcuts="Control+S Meta+S"`, `aria-busy` while it runs and `aria-disabled` until the draft changes (never `disabled`). A draft session, which never saves, has neither History nor Save |
|
|
34
35
|
| `data-testid="markdown-explorer-edit-view"` | The view switch in the bar, between Next conflict and History (`role="radiogroup"`, named `editView`; in a panel `editViewNamed`) | Its radios are `-view-editor`, `-view-split` (only where the pane has room for the preview beside the editor: a page view, a maximized panel) and `-view-preview`, each a native radio (`input type="radio"`, the three sharing a name unique to the switch) covering its icon button (a `label`, which draws the checked state and the focus ring), checked for the shown view, titled by its tooltip and named by `aria-label` (`editViewEditor`, `editViewSplit`, `editViewPreview`), with its words hidden where the bar is narrower than two reading columns and in a panel. As in any radio group, Tab stops at the checked radio and the arrow keys check the next or the previous one. The editor's and the preview's radios carry `aria-keyshortcuts="Control+E Meta+E"`: Ctrl+E (⌘E on Apple's platforms) switches between the editor and the preview from the editor, the preview or the switch |
|
|
35
36
|
| `data-testid="markdown-explorer-save-grant"` / `-open` / `-retry` | Notice below the bar's row when a save needs a grant, its action and Try again (which saves again) | |
|
|
37
|
+
| `data-testid="markdown-explorer-save-access-failure"` | The host's presenter's node for a save that met an access failure, below the bar's row | Carries `data-aqmx-failure` (`unauthorized` / `forbidden`). The place is `write`, and the node's retry saves again without asking `confirmUnversionedSaves` again. Meanwhile the status carries `data-aqmx-save="failed"` and names the unsaved draft alone (`draftUnsaved`), and the announcer says nothing of the failure |
|
|
36
38
|
| `data-testid="markdown-explorer-edit-close-confirm"` / `-cancel` / `-confirm` | The confirmation before an unsaved draft is closed (a modal `dialog`) | Centered over the content pane (`data-aqmx-content-pane`), as the other dialogs below. Opens with the focus on the way back (`unsavedStay`); Escape and the backdrop choose it too (Escape is consumed). `-confirm` (`unsavedDiscard`) closes the draft |
|
|
37
39
|
| `data-testid="markdown-explorer-unsaved-guard"` / `-cancel` / `-confirm` | The confirmation before a navigation drops unsaved drafts (a modal `dialog`, one per explorer) | As above; `-confirm` drops those drafts and goes on |
|
|
38
40
|
| `data-testid="markdown-explorer-history"` | The revisions dialog (a modal `dialog`, named `historyTitle`) | Holds `-history-loading`, `-history-failure` or `-history-empty`, else `-history-list` of `-history-entry` buttons (`aria-pressed` for the one shown), the picked revision's text `-history-text` (focusable, so the keyboard scrolls it) or `-history-revision-failure`, and `-history-close` and `-history-restore` (`aria-disabled` until a revision's text is shown) |
|
|
39
41
|
| `data-testid="markdown-explorer-document-refresh"` | The Refresh document button, in the bar | Reads that document alone again past the host's caches. The page views name it by its visible label (`refreshDocumentLabel`; tooltip `refreshDocument`); a panel's is icon-only, with `aria-label` and `title` set to `refreshDocumentNamed` (the panel title). Carries `aria-busy="true"` and `data-aqmx-busy="true"` while it runs, and `aria-disabled="true"` then and while the document loads (never `disabled`) |
|
|
40
42
|
| `data-testid="markdown-explorer-document-permalink"` | The Copy permalink button, in the bar after Refresh document | Drawn with `documentIds` in the configuration while the document is not edited, from the server's render on (see [URL contract](url-contract.md#document-ids)); `aria-disabled="true"` while the document loads or failed, when it ignores presses. The page views name it by its visible label (`copyPermalinkLabel`; tooltip `copyPermalink`); a panel's is icon-only, with `aria-label` and `title` set to `copyPermalinkNamed`. Carries `data-aqmx-copy-outcome`: `idle`, then `copied` or `failed` for 2 seconds after a press, while its `title` says what happened (its name never changes; the announcer speaks the outcome). |
|
|
43
|
+
| `data-testid="markdown-explorer-permalink-access-failure"` | The host's presenter's node for the latest Copy permalink press whose ID was refused by an access failure, in the bar below its button row | Carries `data-aqmx-failure` (`unauthorized` / `forbidden`). The place is `write`, with no retry (the reader presses again). The button keeps `data-aqmx-copy-outcome="idle"` and the announcer says nothing; the node goes at the next press and when the bar moves to another document (it does not come back on return), and while the document is edited, after which it is drawn again |
|
|
41
44
|
| `data-testid="markdown-explorer-document-maximize"` | The Maximize button that ends the tree view's document bar | Icon-only, with `aria-label` and `title` naming what a press does (`documentMaximize`, or `documentRestore` while the document is maximized) and no `aria-pressed`; the same element in every state. Absent in the single view and in a multi-view panel |
|
|
42
45
|
| `data-aqmx-maximized` | The tree view's document column (the bar and the document region, `data-aqmx-content-pane`) | `true` while the column covers the page — the document is maximized and has something to show, or its folder's README is being looked for — else `false` (a multi-view panel's frame carries the same attribute, see [Multi-panel view](#multi-panel-view)) |
|
|
43
46
|
| `data-testid="markdown-explorer-document-refresh-failure"` | Notice of a document refresh that failed, inside the bar below its button row | No live role (the announcer speaks the same text); carries `data-aqmx-failure` (the reason). The failure is the document's answer, or the reading of the part the document's content reads itself (a table file's table, a document shown as written) when that content showed a copy of it, which stays. Shown while the copy of the document it kept stays on screen: a newer answer that replaces or confirms that copy, a move to another document (it does not come back on return), a switch between the document rendered and as written and that control's next refresh take it down. It is the one notice of a failed refresh: no notice inside the document repeats it |
|
|
@@ -58,6 +61,7 @@ Tests and host styling may rely on the `data-testid` values and `data-aqmx-*` at
|
|
|
58
61
|
| `data-testid="markdown-explorer-view-switch"` | Link to the other view | Carries `data-aqmx-target` (`tree` / `multi`) |
|
|
59
62
|
| `data-testid="markdown-explorer-notice"` | One notice | Carries `data-aqmx-notice` (its id) and `data-aqmx-tone` (`info` / `warning` / `danger`) |
|
|
60
63
|
| `data-testid="markdown-explorer-expand-all-stop"` | Notice of an Expand all press that stopped at a limit, in the explorer's body just above the tree area (not a live region, not focusable) | Holds the stop sentence announced at the stop (`expandAllFolderLimit` / `expandAllDepthLimit`); shown until the next press, Collapse all, a pane with no rows (failed, empty or cleared) or unmount (a source or view switch). Carries `data-aqmx-stop` (`folder-limit` / `depth-limit`) |
|
|
64
|
+
| `data-testid="markdown-explorer-folder-access-failure"` | The host's presenter's node for the lazy folders whose children met an access failure, in the explorer's body above the tree area (before the Expand all stop notice) | Carries `data-aqmx-failure`, the reason of the first folder that stopped. One node for every folder that stopped, one after another, while any of them stays stopped (the folders one press of Expand all stops at once share it), with the place `read`; its retry loads every stopped folder again. The rows keep `data-aqmx-children="failed"` and their `markdown-explorer-folder-retry`; the announcer names none of the folders, and the end of an Expand all press counts them among the folders that could not be loaded |
|
|
61
65
|
| `data-testid="markdown-explorer-tree"` | Tree area | |
|
|
62
66
|
| `data-testid="markdown-explorer-tree-scroll"` | The tree's scroll pane (the virtual list's root) | |
|
|
63
67
|
| `data-testid="markdown-explorer-tree-loading"` | Tree placeholder while it loads | |
|
|
@@ -145,4 +149,7 @@ Everything around a panel's content is drawn by `@aiquants/drag-drop-panels` and
|
|
|
145
149
|
|
|
146
150
|
## Failures and tones
|
|
147
151
|
|
|
148
|
-
`data-aqmx-failure` takes the failure reasons: `unauthorized`, `forbidden`, `not-found`, `not-configured`, `invalid`, `too-large`, `unsupported` and `failed`. `data-aqmx-tone`
|
|
152
|
+
`data-aqmx-failure` takes the failure reasons: `unauthorized`, `forbidden`, `not-found`, `not-configured`, `invalid`, `too-large`, `unsupported` and `failed`. For the explorer's own reasons (all but `unauthorized` and `forbidden`) the element holds the explorer's callout: its `data-aqmx-tone` is `danger` for `failed` and `warning` for the other reasons, and it offers "Try again" (`retry`) only for `failed`, with no button for the other reasons, which retrying cannot change.
|
|
153
|
+
For an access failure (`unauthorized`, `forbidden`) the same element holds the node the host's `accessFailure` presenter returns instead, whatever its row says of the callout: no callout, tone, role or text of the explorer's, and nothing for its announcer to say.
|
|
154
|
+
This holds for every hook above that carries `data-aqmx-failure` (a host's `renderTreeFailure` view still replaces what the tree failure holds), and for the three only an access failure draws: `markdown-explorer-save-access-failure`, `markdown-explorer-permalink-access-failure` and `markdown-explorer-folder-access-failure`.
|
|
155
|
+
While the explorer's sheet is open, the content's access failures are drawn inside `markdown-explorer-sheet-access-failures` instead of in place (see [Access failures](../../README.md#access-failures)).
|
package/docs/behavior/hosting.md
CHANGED
|
@@ -51,7 +51,7 @@ export const explorer = createExplorerServer(
|
|
|
51
51
|
sources,
|
|
52
52
|
document: documentOf,
|
|
53
53
|
asset: assetOf,
|
|
54
|
-
signedOutPage: (
|
|
54
|
+
signedOutPage: (_args, headers) => new Response(null, { status: 401, headers }),
|
|
55
55
|
readSettings: keptSettings,
|
|
56
56
|
assetMaxRangeBytes: null,
|
|
57
57
|
},
|
|
@@ -47,8 +47,8 @@ This page is part of the host-facing contract of `@aiquants/markdown-explorer`;
|
|
|
47
47
|
`spreadsheetSheetLoading` is the screen-reader text while a sheet is read for the first time; a sheet without data shows `spreadsheetSheetEmpty`. Its notes are `spreadsheetUnshownSheets(count)` (sheets left out: hidden, or without a table), `spreadsheetUnlistedSheets(count)` (the number of sheets listed, when the workbook has more than the reader lists) and `spreadsheetWorkbookFirstSheet` (the first sheet's text shown instead of the workbook);
|
|
48
48
|
in place of the tabs or a sheet's table, `spreadsheetWorkbookEncrypted` (a password-protected workbook), `spreadsheetNotWorkbook` (bytes that are no workbook the explorer reads, a legacy `.xls` included) or `spreadsheetWorkbookTooLarge` (past `spreadsheets.maxWorkbookBytes` or the reader's limit for one part).
|
|
49
49
|
- `copyText` is the accessible name and tooltip of the icon-only Copy the text button in the header of a text read whole (a text file, or a Markdown document shown as written). A copy is announced with `copiedText`, or with `copyTextFailed` when the browser has no asynchronous clipboard, refuses the write or has a clipboard that throws; for 2 seconds the outcome's label is also the button's tooltip, while its name stays `copyText`.
|
|
50
|
-
-
|
|
51
|
-
|
|
50
|
+
- The catalogs hold no words for an access failure: a session that ended (`unauthorized`) and something the reader may not read or write (`forbidden`) are drawn by the host's `accessFailure` presenter, in the presenter's own words (for example `@aiquants/auth-core`'s, `resolveAccessFailureLabels(locale)`), so `labels` cannot reword them and a host that signs in to a named service says so there.
|
|
51
|
+
The one sentence the explorer gives the presenter is `documentIdForbidden`, what was denied when an ID URL answers `forbidden` (see [Access failures](../../README.md#access-failures)).
|
|
52
52
|
- Under `confirmUnversionedSaves`, a save that would write a change to a source that keeps no previous versions asks first: `unversionedSaveTitle`, `unversionedSaveBody` (the previous content cannot be restored), `unversionedSaveConfirm`, which saves, and `unsavedStay`, which goes back to editing.
|
|
53
53
|
- `switchToTree` and `switchToMulti` name their destination with the README's view names ("Open in the tree view" / "ツリービューで開く", "Open in the multi-panel view" / "マルチビューで開く"); no label names the single view, which no control inside the explorer opens.
|
|
54
54
|
|
|
@@ -113,7 +113,7 @@ In a tree or children listing, an entry with an empty name, or with a path the b
|
|
|
113
113
|
## Responses
|
|
114
114
|
|
|
115
115
|
- Every JSON data response of the explorer's own carries `Content-Type: application/json; charset=utf-8`, `Cache-Control: private, no-store`, `X-Content-Type-Options: nosniff`, `Content-Security-Policy: default-src 'none'; frame-ancestors 'none'; sandbox` and `Cross-Origin-Resource-Policy: same-origin`, and has a JSON body.
|
|
116
|
-
- The page loader's responses carry `Cache-Control: private, no-store` through the exported `headers`, to both the HTML document and the single-fetch data.
|
|
116
|
+
- The page loader's responses carry `Cache-Control: private, no-store` through the exported `headers`, to both the HTML document and the single-fetch data. A reader `authenticate` answers `forbidden` for is refused with `@aiquants/auth-core`'s `accessFailureResponse("forbidden")` and the authentication's headers: a 403 with `Cache-Control: no-store`, which the same `headers` carry to both while the page route has its own error boundary (the HTML document's `Content-Type` stays the entry's, and the single-fetch data's React Router's).
|
|
117
117
|
- The data route answers a React Router single-fetch request (`<dataPath>/<operation>.data`: its own URL path ends in `.data`, which React Router strips from the route's `url` argument and `params` but not from `request.url`) with a `not-found` failure (404) before authenticating or calling a source. React Router would run the route for it, read the whole response into memory and keep none of the headers above but `Set-Cookie`.
|
|
118
118
|
- Status codes: 200 for a tree, children, ancestors, reveal, document, text, refresh or editor (`edit`, `save`, `preview`, `revisions`, `revision`) answer (a refresh answers the reloaded tree, as a tree request does, failures included), 400 for a missing or malformed parameter or draft,
|
|
119
119
|
401 when the reader is signed out, 403 when the reader may not use the explorer (or a refresh, a document request marked as one's, a save, a preview or an ID's issue lacks its proof), 404 for an unknown operation or source for a children request to a source without `children()`, for an ancestors request to a source without `ancestors()`, for the editor's operations without `edit` ports and for the ID operations without `documentIds` ports, 405 (with `Allow`) for a wrong method, 413 for a draft longer than `editMaxBytes`.
|
|
@@ -85,12 +85,12 @@ With `documentIds: { slug }` in the configuration, a document can also be linked
|
|
|
85
85
|
`documentIdVectors()` of `@aiquants/markdown-explorer/testing` lists the answers `parseDocumentId` owes, for a host's registry and for an implementation of the rule in another language.
|
|
86
86
|
- **Writing and reading.** `explorerHref(config, { view: "document-id", id, opens?, overrides?, embed? })` writes an ID URL: `opens: "single"` writes `{views.single}` after the ID and is the only form that takes `embed`; `overrides` (`style`, `align`) are written as in a path URL. It throws a `TypeError` with a configuration without `documentIds`, and a `RangeError` for an ID that is not canonical, an `opens` other than `"single"`, embedding options without `opens: "single"`, or a value the resolver would ignore.
|
|
87
87
|
`resolveExplorerLocation` answers an ID URL with `{ kind: "document-id", id, opens, location }`: the canonical ID (`null` when the URL's ID is written wrong), how its document opens (`ExplorerDocumentIdOpening`: the tree view with the overrides, or the single view with the overrides and the embedding options), and the location drawn meanwhile and on a failure — the default source's tree without a document. The URL's `source`, `doc`, `markup` and `maximized` are not read: the ID decides the document.
|
|
88
|
-
- **The page loader.** It authenticates first (a signed-out reader gets `signedOutPage` before the registry is asked), resolves the ID as the `resolve-id` operation does, and answers a document the reader can open with a `302` to its path URL — the view the ID URL asked for, under the source that admits the document (written by omission when it is the default), with the ID URL's overrides and embedding parameters — carrying `Cache-Control: private, no-store` and the authentication's headers.
|
|
88
|
+
- **The page loader.** It authenticates first (a signed-out reader gets `signedOutPage`, and a reader `authenticate` answers `forbidden` for gets `@aiquants/auth-core`'s 403 refusal, before the registry is asked), resolves the ID as the `resolve-id` operation does, and answers a document the reader can open with a `302` to its path URL — the view the ID URL asked for, under the source that admits the document (written by omission when it is the default), with the ID URL's overrides and embedding parameters — carrying `Cache-Control: private, no-store` and the authentication's headers.
|
|
89
89
|
Never `301` or `308`: a browser keeps a permanent redirect, and the path an ID names changes when its document moves.
|
|
90
90
|
Otherwise it answers the page with the location above, `documentId: { id, failure }` in the page data (never naming the path) and the failure's status: `invalid` 400 for an ID written wrong (the registry is not asked), `not-found` 404 for an ID the registry does not know or a path where no document is, `forbidden` 403 for a path the deny rules refuse, no source's boundary admits or the reader may not read, `failed` 500. Every other page carries `documentId: null`.
|
|
91
91
|
The browser keeps a fragment across the `302` on a page load; a client-side navigation from another route loses it, as for any redirect above.
|
|
92
92
|
- **In the browser.** A navigation inside the explorer to an ID URL (a document's link, Back and Forward) runs no loader: the explorer shows the document's skeleton in the location above, asks the data route's `resolve-id` operation, and moves with a replacing navigation to the path URL it writes with `explorerHref`, keeping the current fragment, so Back returns to the page the reader came from. A change of URL cancels the resolution in flight.
|
|
93
|
-
A failure is drawn in the document's place (`data-testid="markdown-explorer-document-id-failure"`, its reason in `data-aqmx-failure`) under its own title, with words of its own for `invalid
|
|
93
|
+
A failure is drawn in the document's place (`data-testid="markdown-explorer-document-id-failure"`, its reason in `data-aqmx-failure`) under its own title, with words of its own for `invalid` and `not-found`, and with Try again for `failed` only; an access failure there is the host's presenter's node instead, `forbidden` with the sentence of what was denied `documentIdForbidden`; a failure the loader already answered for the same ID is drawn without asking again, and an answer that names a source the page does not know is drawn as `failed`.
|
|
94
94
|
- **Copy permalink.** The bar of a document that is not edited holds Copy permalink, from the server's render on; while the document loads or failed, the button is unavailable (`aria-disabled`) and ignores presses, so the bar's buttons keep their places whatever the document's state.
|
|
95
95
|
A press asks the data route's `issue-id` operation for the document's ID (issued on the first press, the same ID ever after) and copies its ID URL as an absolute URL with the router's basename, in the form of the current view: the single view's with its overrides and embedding parameters, the tree view's with its overrides, and a multi-view panel's as the tree view's without any.
|
|
96
96
|
The clipboard write starts inside the press, since Safari allows a write only during the reader's gesture: a `ClipboardItem` whose text the ID URL fulfils once the server answers. The outcome is announced and shown as the bar's other copies are, with the ID grouped, or with why nothing was copied: the failure's title when no ID could be issued, otherwise the browser's refusal — a browser without the asynchronous clipboard or without `ClipboardItem` included, never retried with `writeText()`, which would write outside the reader's gesture.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aiquants/markdown-explorer",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.37.0",
|
|
4
4
|
"description": "Markdown document explorer for React Router 8 (framework mode): a source tree with a single-document view and a multi-panel reading view, storage-agnostic server ports, golden-ratio layout and an en / ja UI.",
|
|
5
5
|
"sideEffects": [
|
|
6
6
|
"**/*.css"
|
|
@@ -102,6 +102,7 @@
|
|
|
102
102
|
"parse5": "^8.0.0"
|
|
103
103
|
},
|
|
104
104
|
"peerDependencies": {
|
|
105
|
+
"@aiquants/auth-core": "^0.8.0",
|
|
105
106
|
"@aiquants/directory-tree": "^6.1.1",
|
|
106
107
|
"@aiquants/drag-drop-panels": "^0.14.0",
|
|
107
108
|
"@aiquants/markdown": "^13.0.0",
|
|
@@ -113,12 +114,13 @@
|
|
|
113
114
|
"react-router": "^8.0.0"
|
|
114
115
|
},
|
|
115
116
|
"devDependencies": {
|
|
117
|
+
"@aiquants/auth-core": "0.8.0",
|
|
116
118
|
"@aiquants/directory-tree": "6.1.3",
|
|
117
119
|
"@aiquants/drag-drop-panels": "0.14.1",
|
|
118
|
-
"@aiquants/markdown": "13.
|
|
120
|
+
"@aiquants/markdown": "13.2.0",
|
|
119
121
|
"@aiquants/resize-panels": "2.3.0",
|
|
120
|
-
"@aiquants/spreadsheet": "0.20.
|
|
121
|
-
"@aiquants/virtualscroll": "3.
|
|
122
|
+
"@aiquants/spreadsheet": "0.20.1",
|
|
123
|
+
"@aiquants/virtualscroll": "3.26.0",
|
|
122
124
|
"@heroicons/react": "^2.2.0",
|
|
123
125
|
"@playwright/test": "^1.64.1",
|
|
124
126
|
"@tailwindcss/cli": "^4.1.18",
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const C=require("react/jsx-runtime"),m=require("react"),S=require("./index-lpL7GltU.cjs"),Z=require("@aiquants/markdown/code-blocks"),J=require("@codemirror/commands"),we=require("@codemirror/lang-markdown"),ie=require("@codemirror/language"),Ee=require("@codemirror/search"),K=require("@codemirror/state"),_=require("@codemirror/view"),D=require("@lezer/highlight"),Ge=require("@aiquants/markdown"),me=require("@aiquants/markdown/source-lines"),ne=require("./ownUrls-BTPGNhBt.cjs"),he=require("./sanitizePolicy-C-ehd0J_.cjs"),We=require("isomorphic-dompurify"),X=require("./location-DrOP6t1F.cjs"),Xe=require("./describeValue-Ccvhbt36.cjs"),ce=require("@aiquants/resize-panels"),be=require("./useSplitPersistence-BUa_KMsV.cjs"),Pe={history:J.historyField},$e=ie.HighlightStyle.define([{tag:[D.tags.heading1,D.tags.heading2,D.tags.heading3,D.tags.heading4,D.tags.heading5,D.tags.heading6,D.tags.heading],color:"var(--aqmx-syntax-heading)",fontWeight:"700"},{tag:D.tags.strong,fontWeight:"700"},{tag:D.tags.emphasis,fontStyle:"italic"},{tag:D.tags.strikethrough,textDecoration:"line-through"},{tag:D.tags.link,color:"var(--aqmx-syntax-link)",textDecoration:"underline"},{tag:D.tags.url,color:"var(--aqmx-syntax-url)"},{tag:D.tags.monospace,color:"var(--aqmx-syntax-code)"},{tag:D.tags.quote,color:"var(--aqmx-syntax-quote)"},{tag:[D.tags.processingInstruction,D.tags.contentSeparator,D.tags.labelName,D.tags.meta],color:"var(--aqmx-syntax-mark)"}]),Ke=_.EditorView.theme({"&":{height:"100%",color:"var(--aqmx-text)",backgroundColor:"var(--aqmx-surface)",fontSize:"var(--aqmx-font-size-title)"},"&.cm-focused":{outline:"none"},".cm-scroller":{fontFamily:'ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace',lineHeight:"var(--aqmx-line-height-prose)"},".cm-content":{caretColor:"var(--aqmx-text)",paddingBlock:"var(--aqmx-space-6)"},".cm-line":{paddingInline:"var(--aqmx-space-6)"},"&.cm-focused .cm-cursor":{borderLeftColor:"var(--aqmx-text)"},"&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection":{backgroundColor:"var(--aqmx-editor-selection)"},".cm-activeLine":{backgroundColor:"var(--aqmx-editor-active-line)"},".cm-gutters":{backgroundColor:"var(--aqmx-surface-raised)",color:"var(--aqmx-editor-gutter)",borderInlineEnd:"var(--aqmx-space-1) solid var(--aqmx-border)"},".cm-activeLineGutter":{backgroundColor:"var(--aqmx-editor-active-line)"},".cm-searchMatch":{outline:"var(--aqmx-space-1) solid var(--aqmx-border-strong)"},".cm-panels":{backgroundColor:"var(--aqmx-surface-raised)",color:"var(--aqmx-text)"}}),Ne="data-aqmx-conflict-actions",Ye=_.Decoration.line({attributes:{"data-aqmx-conflict-line":"marker"}}),Je=_.Decoration.line({attributes:{"data-aqmx-conflict-line":"ours"}}),Qe=_.Decoration.line({attributes:{"data-aqmx-conflict-line":"theirs"}});class Ze extends _.WidgetType{constructor(t,n){super(),this.index=t,this.labels=n}index;labels;eq(t){return t.index===this.index&&t.labels===this.labels}toDOM(t){const n=document.createElement("div");n.setAttribute(Ne,String(this.index));for(const[o,s]of[["ours",this.labels.useOurs],["theirs",this.labels.useTheirs],["both",this.labels.keepBoth]]){const r=document.createElement("button");r.type="button",r.textContent=s,r.setAttribute("data-aqmx-conflict-choice",o),r.addEventListener("mousedown",l=>l.preventDefault()),r.addEventListener("click",()=>{const l=se(t.state.doc)[this.index];l!==void 0&&(De(t,l,o),t.focus())}),n.append(r)}return n}ignoreEvent(){return!0}}const se=e=>S.findConflictsInLines(e.iterLines()),xe=(e,t)=>{const n=new K.RangeSetBuilder;return se(e).forEach((o,s)=>{const r=e.line(o.start);n.add(r.from,r.from,_.Decoration.widget({widget:new Ze(s,t),block:!0,side:-1}));for(let l=o.start;l<=o.end;l+=1){const i=e.line(l).from,f=l===o.start||l===o.separator||l===o.end?Ye:l<o.separator?Je:Qe;n.add(i,i,f)}}),n.finish()},et=e=>K.StateField.define({create:t=>xe(t.doc,e),update:(t,n)=>n.docChanged?xe(n.state.doc,e):t,provide:t=>_.EditorView.decorations.from(t)}),De=(e,t,n)=>{const{doc:o}=e.state,s=(E,c)=>{const w=[];for(let u=E;u<=c;u+=1)w.push(o.line(u).text);return w},r=s(t.start+1,t.separator-1),l=s(t.separator+1,t.end-1),i=n==="ours"?r:n==="theirs"?l:[...r,...l];let f=o.line(t.start).from,d=o.line(t.end).to;i.length===0&&(t.end<o.lines?d+=1:t.start>1&&(f-=1));const b=i.join(`
|
|
2
|
-
`);e.dispatch({changes:{from:f,to:d,insert:b},selection:K.EditorSelection.cursor(f),scrollIntoView:!0,userEvent:"input.resolve"})},Se="input.preview",tt=20,nt=_.ViewPlugin.fromClass(class{constructor(e){this.view=e,this.schedule()}view;cancel=null;update(e){e.docChanged&&this.schedule()}schedule(){if(this.cancel!==null||ie.syntaxTreeAvailable(this.view.state))return;const e=this.view.dom.ownerDocument.defaultView;if(e===null)return;const t=()=>{this.cancel=null,ie.ensureSyntaxTree(this.view.state,this.view.state.doc.length,tt),this.schedule()};if(typeof e.requestIdleCallback=="function"){const n=e.requestIdleCallback(t);this.cancel=()=>e.cancelIdleCallback(n)}else{const n=e.setTimeout(t,0);this.cancel=()=>e.clearTimeout(n)}}destroy(){this.cancel?.(),this.cancel=null}}),rt=/`{3,}|~{3,}/u,re=Object.freeze({kind:"absent"}),de=Object.freeze({kind:"unreadable"}),ot=(e,t,n)=>{const o=[];for(let f=t.parent;f!==null;f=f.parent)(f.name==="Blockquote"||f.name==="ListItem")&&o.unshift(f);const s=[],r=[],l=f=>{const d=r.indexOf(f);return d===-1?r.length:d};for(const f of o){const d=e.lineAt(f.from).number;if(f.name==="ListItem"){const b=Z.listItemWidthOn(e.line(d).text,s,l(d));if(b===null)return null;s.push({kind:"listItem",width:b})}else s.push({kind:"quote"});r.push(d)}const i=Z.openingFenceOn(n.text,s,l(n.number));return i===null?null:{containers:s,...i}},st=(e,t)=>{const{doc:n}=e;let o=n.lineAt(t).to;for(;;){const s=ie.ensureSyntaxTree(e,o,Number.POSITIVE_INFINITY);if(s===null)return null;const r=s.resolveInner(t,1),l=r.parent;if(r.name!=="CodeMark"||l===null||l.name!=="FencedCode"||l.from!==r.from)return null;if(l.to<o||o>=n.length)return l;o=Math.min(n.length,l.to+Math.max(l.to-t,1))}},ye=(e,t)=>{const{doc:n}=e;if(!Number.isInteger(t)||t<1||t>n.lines)return re;const o=n.line(t),s=rt.exec(o.text);if(s===null)return re;const r=st(e,o.from+s.index);if(r===null)return re;const l=r.getChild("CodeInfo");if(l===null)return re;const i=Z.fencedCodeLanguageOf(n.sliceString(l.from,l.to));if(i===null)return de;if(i!==Z.SPREADSHEETS_LANGUAGE)return re;const f=ot(n,r,o);if(f===null)return de;const[,...d]=r.getChildren("CodeMark"),b=d.at(-1),E=b===void 0?n.lineAt(r.to).number:n.lineAt(b.from).number-1,c=[];let w="";for(let u=t+1;u<=E;u+=1){const h=n.line(u).text,g=Z.readFencedLine(h,f);if(g===null)return de;c.push(h),w+=u<n.lines?`${g.content}
|
|
3
|
-
`:g.content}return{kind:"found",firstLine:t+1,lines:c,layout:f,body:w}},it=({parent:e,scroll:t,text:n,saved:o,labels:s,revisions:r,onChange:l,onGeometry:i,onSave:f})=>{let d=!1;const b=[_.EditorView.scrollHandler.of((u,h,g)=>(lt(u,h.head,g,t),!0)),_.lineNumbers(),_.highlightActiveLineGutter(),J.history(),_.drawSelection(),_.highlightActiveLine(),Ee.highlightSelectionMatches(),_.EditorView.lineWrapping,we.markdown({base:we.markdownLanguage}),nt,ie.syntaxHighlighting($e),et(s),_.keymap.of([{key:"Mod-s",preventDefault:!0,run:()=>(f(),!0)},...Ee.searchKeymap,...J.historyKeymap,...J.defaultKeymap]),_.EditorView.contentAttributes.of({"aria-label":s.editor,"aria-multiline":"true"}),_.EditorView.updateListener.of(u=>{for(const h of u.transactions)h.docChanged&&r.record(h.changes,h.newDoc);u.docChanged&&l(u.transactions.every(h=>!h.docChanged||h.isUserEvent(Se))),(u.docChanged||u.heightChanged||u.geometryChanged)&&i(u.docChanged&&!d)}),Ke],E=ut(o,b)??K.EditorState.create({doc:n,extensions:b}),c=new _.EditorView({state:E,parent:e});r.mount(c.state.doc);const w=u=>{d=!0;try{u()}finally{d=!1}};return{text:()=>c.state.doc.toString(),replaceText:u=>{const h=c.state.doc.toString();if(h===u)return;let g=0;const y=Math.min(h.length,u.length);for(;g<y&&h.charCodeAt(g)===u.charCodeAt(g);)g+=1;let p=0;for(;p<y-g&&h.charCodeAt(h.length-1-p)===u.charCodeAt(u.length-1-p);)p+=1;c.dispatch({changes:{from:g,to:h.length-p,insert:u.slice(g,u.length-p)},userEvent:"input.replace"})},replaceBody:(u,h,g,y)=>{const{doc:p}=c.state,T=r.lineOf(y,u);if(T===null)return"changed";const O=ye(c.state,T);if(O.kind==="absent")return"changed";if(O.kind==="unreadable")return"unwritable";if(O.body!==Z.fencedBodyAsRead(h,O.layout))return"changed";const L=Z.planFencedBodyEdit(O.lines,O.layout,g);if(L.kind!=="edit")return L.kind;if(L.from===L.to&&L.lines.length===0)return"written";const N=z=>{const H=O.firstLine+z;return H<=p.lines?p.line(H).from:p.length},M=N(L.from),B=`${M===p.length&&p.sliceString(p.length-1)!==`
|
|
4
|
-
`?`
|
|
5
|
-
`:""}${L.lines.map(z=>`${z}
|
|
6
|
-
`).join("")}`;return w(()=>c.dispatch({changes:{from:M,to:N(L.to),insert:B},userEvent:Se,annotations:J.isolateHistory.of("full")})),"written"},readBody:(u,h)=>{const g=r.lineOf(h,u);if(g===null)return null;const y=ye(c.state,g);return y.kind==="found"?y.body:null},undo:()=>w(()=>J.undo(c)),redo:()=>w(()=>J.redo(c)),reveal:({line:u,column:h},g)=>{const{doc:y}=c.state,p=y.line(Math.min(Math.max(u,1),y.lines)),T=Math.min(p.from+h,p.to);c.dispatch({selection:K.EditorSelection.cursor(T),effects:Te(c,T,g,t)})},showLine:u=>{const{doc:h}=c.state,g=h.line(Math.min(Math.max(u,1),h.lines)).from;c.dispatch({effects:Te(c,g,null,t)})},topLine:()=>{const u=t.scrollerOf(c.scrollDOM),h=S.visibleTopOf(u,c.contentDOM),g=S.frameTopOf(u)+u.clientHeight,{documentTop:y}=c,{doc:p}=c.state;let T=c.lineBlockAtHeight(Math.max(h-y,0));for(;p.lineAt(T.from).text.trim()===""&&T.to<p.length;){const N=c.lineBlockAt(T.to+1);if(y+N.top>=g)break;T=N}const O=c.coordsAtPos(T.from),L=O===null?y+T.top:O.top;return{line:c.state.doc.lineAt(T.from).number,clientTop:L,offset:L-h}},lineSpans:u=>{const h=c.scrollDOM,g=h.scrollTop+c.documentTop-S.visibleTopOf(h,c.contentDOM),{doc:y}=c.state,p=T=>y.line(Math.min(Math.max(T,1),y.lines)).from;return u.map(({first:T,last:O})=>({top:g+c.lineBlockAt(p(T)).top,bottom:g+c.lineBlockAt(p(O)).bottom}))},scrollElement:c.scrollDOM,focus:()=>c.focus(),conflicts:()=>se(c.state.doc),resolveAtCursor:u=>{const h=se(c.state.doc),g=c.state.doc.lineAt(c.state.selection.main.head).number,y=h.find(p=>p.end>=g);return y===void 0?!1:(De(c,y,u),!0)},nextConflict:()=>{const u=se(c.state.doc);if(u[0]===void 0)return!1;const g=c.state.doc.lineAt(c.state.selection.main.head).number,y=u.findIndex(L=>L.start>g),p=y<0?0:y,T=c.state.doc.line(u[p].start).from;c.dispatch({selection:K.EditorSelection.cursor(T),effects:_.EditorView.scrollIntoView(T,{y:"center"})});const O=c.contentDOM.querySelector(`[${Ne}="${String(p)}"] button`);return O instanceof HTMLElement?O.focus({preventScroll:!0}):c.focus(),!0},save:()=>c.state.toJSON(Pe),destroy:()=>c.destroy()}},Te=(e,t,n,o)=>{const s=o.scrollerOf(e.scrollDOM),r=(n===null?S.visibleTopOf(s,e.contentDOM):n)-S.frameTopOf(s);return _.EditorView.scrollIntoView(t,{y:"start",yMargin:r})},lt=(e,t,n,o)=>{const s=ct(e,t),r=o.scrollerOf(e.scrollDOM),l=S.frameTopOf(r),i=S.visibleTopOf(r,e.contentDOM),f=l+r.clientHeight;let d=0;switch(n.y){case"start":d=s.top-(l+n.yMargin);break;case"center":d=(s.top+s.bottom)/2-(i+f)/2;break;case"end":d=s.bottom-(f-n.yMargin);break;default:s.top<i+n.yMargin?d=s.top-(i+n.yMargin):s.bottom>f-n.yMargin&&(d=Math.min(s.bottom-(f-n.yMargin),s.top-(i+n.yMargin)))}if(d!==0&&(r.scrollTop+=d),n.y==="start")return;const b=at(e,t);b!==null&&o.reveal(b)},ct=(e,t)=>{const{node:n,offset:o}=e.domAtPos(t);if(n.nodeType===Node.TEXT_NODE){const l=n.ownerDocument?.createRange();if(l!==void 0){l.setStart(n,o),l.setEnd(n,o);const[i]=l.getClientRects();if(i!==void 0&&i.height>0)return{top:i.top,bottom:i.bottom}}}const s=e.lineBlockAt(t),r=e.documentTop+s.top;return{top:r,bottom:r+s.height}},at=(e,t)=>{const{node:n}=e.domAtPos(t);for(let o=n instanceof Element?n:n.parentElement;o!==null;o=o.parentElement)if(o.parentElement===e.contentDOM)return o;return null},ut=(e,t)=>{if(e==null)return null;try{return K.EditorState.fromJSON(e,{extensions:t},Pe)}catch{return null}},dt=610,ft=987,ke=Object.freeze({kind:"unavailable"}),mt="true",ht="false",pt=e=>e===mt?!0:e===ht?!1:null,gt=e=>{const t=new DOMParser().parseFromString(e,"text/html"),n=[];for(const o of t.querySelectorAll("img[data-asset-src], a[data-doc-path]")){const s=o.localName==="img",r=o.getAttribute(s?"data-asset-src":"data-doc-path");r!==null&&n.push({target:{kind:s?"asset":"doc",path:r},exists:pt(o.getAttribute(s?"data-asset-exists":"data-doc-exists"))})}return n},vt=({path:e,instant:t,preview:n,initial:o,onView:s})=>{const r=new AbortController,l={asset:new Map,doc:new Map};let i=o,f=null,d=!1,b=!1,E=null,c=null,w=[],u,h=!1,g,y=null;const p=v=>{v.parsed===i.parsed&&v.source===i.source&&v.failure===i.failure&&v.busy===i.busy&&v.tier===i.tier||(i=v,s(v))},T=(v,x)=>{d||(d=!0,console.error(`[markdown-explorer] ${v}`,...x===void 0?[]:[x]))},O=v=>{if(t!==null)for(const{target:x,exists:q}of t.marksOf(v))l[x.kind].set(x.path,q)},L=()=>{clearTimeout(g),g=void 0,y?.abort(),y=null},N=()=>{c=null,w=[],clearTimeout(u),u=void 0},M=(v,x)=>{p({...i,failure:v,busy:!1,tier:x})},U=()=>{clearTimeout(u),u=w.length===0?void 0:setTimeout(z,ft)},B=()=>{if(t===null||c===null)return;const v=c,x=[],q={asset:new Set,doc:new Set};let G;try{G=t.sanitize(v.html,F=>{const le=l[F.kind].get(F.path);return le===void 0&&!q[F.kind].has(F.path)&&(q[F.kind].add(F.path),x.push(F)),le??void 0})}catch(F){N(),F instanceof he.HtmlNestingLimitError?M(ne.failureOf("too-large"),"instant"):(T("the draft sanitizer failed",F),M(ne.failureOf("failed"),"instant"));return}w=x;const Y=i.parsed!==null&&i.parsed.htmlContent===G&&i.parsed.headings===v.headings?i.parsed:{htmlContent:G,headings:v.headings};p({parsed:Y,source:v.draft,failure:null,busy:!1,tier:"instant"}),U()},z=()=>{if(u=void 0,h||c===null||w.length===0)return;h=!0;const v=w;n(e,c.draft.text,r.signal).then(x=>{if(h=!1,!(r.signal.aborted||!("kind"in x))){x.kind==="preview"&&O(x.htmlContent);for(const q of v)l[q.kind].has(q.path)||l[q.kind].set(q.path,null);B()}})},H=v=>{L(),N(),p({...i,busy:!0,tier:"server"});const x=new AbortController;y=x,g=setTimeout(()=>{g=void 0,n(e,v.text,x.signal).then(q=>{if(!(x.signal.aborted||!("kind"in q))){if(y=null,q.kind==="failure"){M(q.failure,"server");return}O(q.htmlContent),p({parsed:{htmlContent:q.htmlContent,headings:q.headings},source:v,failure:null,busy:!1,tier:"server"})}})},dt)},a=async(v,x)=>{let q;try{q=await v.convert({path:e,text:x},r.signal)}catch(Y){return r.signal.aborted||T("the draft converter rejected a conversion, which its contract allows only once the signal aborted",Y),ke}const G=ne.draftAnswerViolation(q);return G===null?q:(T(`the draft converter answered outside its contract: ${G}`),ke)},I=(v,x)=>{switch(x.kind){case"preview":if(L(),x.headings.length>ne.EXPLORER_MAX_HEADINGS){N(),M(ne.failureOf("too-large"),"instant");return}c={draft:v,html:x.htmlContent,headings:x.headings.map(({text:q,depth:G,id:Y})=>({text:q,depth:G,id:Y}))},B();return;case"failure":L(),N(),M(ne.failureOf(x.failure.reason,x.failure.code),"instant");return;case"unavailable":H(v);return}},A=async v=>{b=!0;try{for(;E!==null&&!r.signal.aborted;){const x=E;E=null;const q=await a(v,x.text);if(r.signal.aborted)return;I(x,q)}}finally{b=!1}};return t!==null&&t.seed!==null&&O(t.seed),{update:v=>{if(!(r.signal.aborted||v.text===f?.text)){if(f=v,clearTimeout(u),u=void 0,t===null){H(v);return}E=v,b||A(t.converter)}},dispose:()=>{r.abort(),E=null,clearTimeout(u),u=void 0,L()}}},wt=e=>he.createHtmlSanitizer(We(window),e.iframeHosts,e.dataPath,he.MAX_HTML_NESTING_DEPTH,X.ownUrlsOf(e)),Et=(e,t)=>e.flatMap((n,o)=>{const s=t[o];return s===void 0?[]:[{editor:s.top,preview:n.top},{editor:s.bottom,preview:n.bottom}]}),Q=(e,t)=>{const n=e[t];if(n===void 0)throw new RangeError(`[markdown-explorer] a scroll map index must be in 0..${String(e.length-1)}; got ${Xe.describeValue(t)}`);return n},bt=e=>{const t=[];for(const o of e){let s=0,r=t.length;for(;s<r;){const l=s+r>>1;Q(t,l).pair.preview<=o.preview?s=l+1:r=l}t[s]={pair:o,before:s===0?void 0:Q(t,s-1)}}const n=[];for(let o=t.at(-1);o!==void 0;o=o.before)n.push(o.pair);return n.reverse()},xt=(e,t)=>{const n=Math.max(t.editorMax,0),o=Math.max(t.previewMax,0),s=n-t.editorViewport,r=o-t.previewViewport,l=e.filter(d=>d.editor>0&&d.editor<s&&d.preview>0&&d.preview<r).sort((d,b)=>d.editor-b.editor||d.preview-b.preview);let i={editor:0,preview:0};const f=[i];for(const d of bt(l))d.editor>i.editor&&d.preview>i.preview&&(f.push(d),i=d);return f.push({editor:n,preview:o}),{toPreview:d=>Le(f,"editor","preview",d),toEditor:d=>Le(f,"preview","editor",d)}},Le=(e,t,n,o)=>{const s=Q(e,0),r=Q(e,e.length-1);if(Number.isNaN(o)||o<=s[t])return s[n];if(o>=r[t])return r[n];let l=0,i=e.length-1;for(;i-l>1;){const b=l+i>>1;Q(e,b)[t]<=o?l=b:i=b}const f=Q(e,l),d=Q(e,i);return f[n]+(d[n]-f[n])*(o-f[t])/(d[t]-f[t])},St=610,Ie=89,Ae=.5,yt=({editor:e,preview:t,previewBlocks:n,editorSpans:o,requestFrame:s,cancelFrame:r,now:l})=>{let i="editor",f=0,d=null,b=null,E=!1,c=null,w=null;const u={editor:0,preview:0},h={editor:null,preview:null};let g=null,y=()=>{};const p=a=>{d!==null&&a!==d||(i=a,f=l()+St)},T=(a,I)=>{a!==i&&d===null&&l()>=f&&!O(a,I)&&(i=a),B()},O=(a,I)=>{const A=h[a];return l()<u[a]||A!==null&&Math.abs(I.position()-A)<Ae},L=e.onScroll(()=>T("editor",e)),N=e.onIntent(()=>p("editor")),M=()=>{const a=t();return a!==g&&(y(),g=a,y=a===null?()=>{}:U(a)),a},U=a=>{const I=a.onScroll(()=>T("preview",a)),A=a.onIntent(()=>p("preview"));return()=>{I(),A()}},B=()=>{!E&&b===null&&(b=s(z))},z=()=>{b=null;const a=M();a!==null&&(c??=n(),w??=xt(Et(c,o(c)),{editorMax:e.max(),previewMax:a.max(),editorViewport:e.viewport(),previewViewport:a.viewport()}),i==="editor"?H(a,"preview",w.toPreview(e.position())):H(e,"editor",w.toEditor(a.position())))},H=(a,I,A)=>{if(Math.abs(a.position()-A)<Ae){h[I]=a.position();return}u[I]=l()+Ie,h[I]=a.scrollTo(A)};return B(),{editorChanged:a=>{w=null,a&&p("editor"),B()},previewChanged:()=>{c=null,w=null,u.preview=l()+Ie,B()},showAlone:a=>{d=a,!(a===null||a===i)&&(i=a,f=0,B())},dispose:()=>{E=!0,b!==null&&r(b),b=null,L(),N(),y()}}},Oe=Object.freeze(["wheel","pointerdown","keydown","focusin"]),Ve=e=>({position:()=>e.scrollTop,max:()=>Math.max(e.scrollHeight-e.clientHeight,0),viewport:()=>e.clientHeight,scrollTo:t=>(e.scrollTo({top:t,behavior:"instant"}),e.scrollTop),onScroll:t=>(e.addEventListener("scroll",t,{passive:!0}),()=>e.removeEventListener("scroll",t)),onIntent:t=>{for(const n of Oe)e.addEventListener(n,t,{capture:!0,passive:!0});return()=>{for(const n of Oe)e.removeEventListener(n,t,{capture:!0})}}}),oe="[data-aqmd-scroll-container]",Tt="[data-aqmd-content]",kt=`[${me.SOURCE_LINES_ATTRIBUTE}]`,Lt=Object.freeze(["p1","p2","p3","p4","p5","p6","p7","p8"]),Be=(e,t)=>{const n=S.loadedOf(e.peek(t));return n!==null&&n.document.kind==="markdown"?{htmlContent:n.document.htmlContent,headings:n.document.headings}:null},It=(e,t,n,o)=>{if(t===void 0)return null;let s;try{s=wt(e)}catch(r){return console.error("[markdown-explorer] the draft sanitizer cannot run in this browser, so the server renders the preview",r),null}return{converter:t,sanitize:s,marksOf:gt,seed:Be(n,o)?.htmlContent??null}},At=e=>{const t=[];let n=null;for(const o of e.querySelectorAll(kt)){const s=me.parseSourceLines(o.getAttribute(me.SOURCE_LINES_ATTRIBUTE));if(s===null||o.getClientRects().length===0)continue;n??=e.scrollTop-S.visibleTopOf(e,o);const{top:r,bottom:l}=o.getBoundingClientRect();t.push({first:s.first,last:s.last,top:n+r,bottom:n+l})}return t},Ot=({path:e,readDraft:t,viewer:n,tables:o,concealed:s,onEditAt:r,onLayout:l,handleRef:i})=>{const{config:f,data:d,documents:b,draftConverter:E,labels:c}=S.useExplorer(),[w,u]=m.useState(()=>({parsed:Be(b,e),source:null,failure:null,busy:!0,tier:E===void 0?"server":"instant"})),h=m.useRef(null),g=m.useRef(null),y=m.useRef(w);m.useLayoutEffect(()=>{y.current=w});const p=m.useEffectEvent(()=>t());m.useEffect(()=>{const a=It(f,E,b,e),I=p(),A=vt({path:e,instant:a,preview:d.preview,initial:y.current,onView:v=>m.startTransition(()=>u(v))});return g.current=A,A.update(I),()=>{A.dispose(),g.current=null}},[f,d,b,E,e]);const T=m.useEffectEvent(()=>l());m.useLayoutEffect(()=>{w.parsed!==null&&T()},[w.parsed]);const O=w.parsed!==null;m.useLayoutEffect(()=>{const a=O?h.current?.querySelector(oe):null;if(!(a instanceof HTMLElement))return;a.tabIndex=0;const I=new ResizeObserver(()=>T());I.observe(a);const A=a.querySelector(Tt);return A!==null&&I.observe(A),()=>I.disconnect()},[O]);const L=m.useRef(null);m.useImperativeHandle(i,()=>({draft:a=>{g.current?.update(a)},scrollPort:()=>{const a=h.current?.querySelector(oe);return a instanceof HTMLElement?(L.current?.scroller!==a&&(L.current={scroller:a,port:Ve(a)}),L.current.port):null},blocks:()=>{const a=h.current?.querySelector(oe);return a instanceof HTMLElement?At(a):[]},focus:()=>{const a=h.current?.querySelector(oe);a instanceof HTMLElement&&a.focus({preventScroll:!0})},anchor:a=>{const I=h.current,A=I?.querySelector(oe);return I===null||!(A instanceof HTMLElement)?null:S.anchorOfView(I,a(A))},place:({line:a,clientTop:I},A)=>{const v=h.current,x=v===null?null:S.blockAtLine(v,a);x!==null&&(A(x).scrollTop+=S.lineTopIn(x,a)-I)}}),[]);const N=a=>{const I=h.current,{target:A}=a;if(r===void 0||I===null||!(A instanceof Element)||!S.isEditingDoubleClick(A))return;const v=S.anchorOfDoubleClick(A,I,I.ownerDocument.getSelection());v!==null&&r(v)},M=w.source===null?null:w.source.revision,U=m.useMemo(()=>M===null?void 0:{write:a=>o.write(M,a),read:a=>o.read(M,a),undo:o.undo,redo:o.redo,subscribe:o.subscribe},[o,M]),B=m.useMemo(()=>({...n.labels,spreadsheetReadOnly:c.previewTablePending}),[n.labels,c.previewTablePending]),z=m.useMemo(()=>({...n,labels:U===void 0?B:n.labels,showToc:!1,showStyle:!1,showAlign:!1,showMeasure:!1,showContentColors:!1,renderScrollBar:void 0,scrollBarGutter:void 0,scrollBarInlineSize:void 0,spreadsheetEditor:U}),[n,B,U]),H=m.useMemo(()=>w.parsed===null?null:C.jsx("div",{className:"aqmx-document-viewer",children:C.jsx(Ge.MarkdownViewer,{...z,parseResult:w.parsed,content:null})}),[z,w.parsed]);return C.jsxs("section",{ref:h,className:"aqmx-edit-preview","aria-label":c.previewRegion,"aria-busy":w.busy,inert:s!==null,hidden:s==="removed","data-aqmx-preview-tier":w.tier,"data-testid":"markdown-explorer-edit-preview",onDoubleClick:r===void 0?void 0:N,children:[w.failure===null?null:C.jsx("p",{className:"aqmx-callout aqmx-document-notice","data-aqmx-tone":"warning","data-testid":"markdown-explorer-edit-preview-failure",children:c.previewFailed(S.failureTitleOf(c,w.failure.reason))}),H??(w.failure===null?C.jsx("div",{className:"aqmx-skeleton","aria-hidden":"true","data-testid":"markdown-explorer-edit-preview-skeleton",children:Lt.map(a=>C.jsx("span",{},a))}):null),w.busy?C.jsx("p",{className:"aqmx-sr-only",children:c.previewUpdating}):null]})},Re="data-aqmx-edit-split",fe="--aqmx-edit-share",qe="--aqmx-edit-gutter",Rt="data-aqmx-edit-split-probe",qt="aqmx-edit-split",Ct="aqmx-edit-editor",Mt="aqmx-edit-preview",Ce={value:X.EDIT_SPLIT_MIN_PERCENT,unit:"percentage"},Me={value:X.EDIT_SPLIT_MAX_PERCENT,unit:"percentage"},_e=e=>{if(e.length!==2)return null;const[t=0,n=0]=e,o=t+n;return o>0?t/o*100:null},ae=e=>{const t=e.current?.parentElement;if(t==null)throw new Error("[markdown-explorer] the edit split is not mounted in its surface");return t},_t=(e,t,n)=>{const[o,s]=m.useState(null);return m.useLayoutEffect(()=>{const r=e.current,l=t.current;if(r===null||l===null)throw new Error("[markdown-explorer] the edit split is not mounted");const i={frame:r.getBoundingClientRect().width,measure:l.getBoundingClientRect().width},f=()=>{i.frame>0&&i.measure>0&&s(X.editSplitOrientation(i.frame,i.measure,n))};f();const d=new ResizeObserver(b=>{for(const E of b){const[c]=E.borderBoxSize;c!==void 0&&(E.target===r&&(i.frame=c.inlineSize),E.target===l&&(i.measure=c.inlineSize))}f()});return d.observe(r),d.observe(l),()=>d.disconnect()},[e,t,n]),o},Pt=({editorId:e})=>{const{edits:t,labels:n}=S.useExplorer(),o=m.useMemo(()=>be.toPanelGroupLabels(n),[n]),s=m.useRef(null),r=m.useRef(null),l=S.useCoarsePointer()?X.COARSE_TARGET_PIXELS:X.FINE_TARGET_PIXELS,i=_t(s,r,l),[f]=m.useState(()=>t.editorShare());m.useLayoutEffect(()=>{const E=ae(s);return E.style.setProperty(qe,`${String(l)}px`),()=>{E.style.removeProperty(qe)}},[l]),m.useLayoutEffect(()=>{const E=ae(s);return E.style.setProperty(fe,`${String(f)}%`),()=>{E.style.removeProperty(fe)}},[f]),m.useLayoutEffect(()=>{if(i===null)return;const E=ae(s);return E.setAttribute(Re,i),()=>E.removeAttribute(Re)},[i]);const d=be.useSplitPersistence(m.useCallback(E=>{const c=_e(E);c!==null&&t.setEditorShare(c)},[t])),b=m.useCallback((E,c)=>{const w=_e(E);w!==null&&ae(s).style.setProperty(fe,`${String(w)}%`),d.layoutChanged(E,c)},[d]);return C.jsxs("div",{ref:s,className:"aqmx-edit-split","data-testid":"markdown-explorer-edit-split",children:[C.jsx("span",{ref:r,className:"aqmx-edit-split-probe","aria-hidden":"true",[Rt]:""}),i===null?null:C.jsxs(ce.PanelGroup,{id:qt,direction:i==="beside"?"horizontal":"vertical",onLayout:b,labels:o,className:"aqmx-edit-split-group",children:[C.jsx(ce.Panel,{id:Ct,defaultSize:{value:f,unit:"percentage"},minSize:Ce,maxSize:Me,contentOverflow:"hidden"}),C.jsx(ce.PanelResizeHandle,{thickness:l,indicator:{visible:!0,thickness:X.SPLIT_HANDLE_PIXELS.gripThickness,length:X.SPLIT_HANDLE_PIXELS.gripLength,barThickness:X.SPLIT_HANDLE_PIXELS.barThickness,barLength:X.SPLIT_HANDLE_PIXELS.barLength},title:n.editViewSplitResize,"aria-label":n.editViewSplitResize,"aria-controls":e,onDragging:d.draggingChanged,className:"aqmx-split-handle aqmx-edit-split-handle"}),C.jsx(ce.Panel,{id:Mt,defaultSize:{value:100-f,unit:"percentage"},minSize:Ce,maxSize:Me,contentOverflow:"hidden"})]})]})},Nt=512,Dt=()=>{const e=[];let t=0,n=null;const o=s=>{if(n===null||!Number.isInteger(s)||s<t)return null;if(s===t+e.length)return n;const r=e[s-t];return r===void 0?null:r.before};return{revision:()=>t+e.length,mount:s=>{if(n!==null&&(n===s||n.eq(s))){n=s;return}const r=t+e.length;e.length=0,t=n===null?r:r+1,n=s},record:(s,r)=>{if(n===null)throw new Error("[markdown-explorer] a change of the editor's text was recorded before an editor mounted");e.push({before:n,changes:s}),n=r,e.length>Nt&&(e.shift(),t+=1)},lineOf:(s,r)=>{const l=o(s);if(l===null||n===null||!Number.isInteger(r)||r<1||r>l.lines)return null;let i=l.line(r).from;for(const f of e.slice(s-t)){const d=f.changes.mapPos(i,1,K.MapMode.TrackAfter);if(d===null)return null;i=d}return n.lineAt(i).number}}},He=144,Vt=e=>{if(typeof e!="object"||e===null)return!1;const{generation:t,topLine:n}=e;return"state"in e&&typeof t=="number"&&typeof n=="number"},Bt=e=>{e.stopPropagation()},Ht=e=>{const{path:t,name:n,session:o}=e,{edits:s,labels:r,announcer:l}=S.useExplorer(),{phase:i}=o,f=m.useCallback(()=>s.retry(t),[s,t]);switch(m.useEffect(()=>{i.kind==="failed"&&l.announce(r.documentFailed(n,S.failureTitleOf(r,i.failure.reason)))},[i,l,r,n]),i.kind){case"opening":return C.jsx(S.ContentSkeleton,{label:r.editLoading,testId:"markdown-explorer-edit-skeleton"});case"grant":return C.jsx("div",{className:"aqmx-edit-message",children:C.jsx(S.EditGrantNotice,{href:i.href,onRetry:f,testId:"markdown-explorer-edit-grant"})});case"failed":return C.jsx("div",{className:"aqmx-edit-message",children:C.jsx(S.FailureView,{failure:i.failure,alert:!1,onRetry:f,testId:"markdown-explorer-edit-failure"})});case"editing":return C.jsx(jt,{...e})}},jt=({path:e,name:t,session:n,layout:o,viewer:s,region:r,paneScroll:l})=>{const{edits:i,labels:f}=S.useExplorer(),d=m.useRef(null),b=m.useId(),E=m.useRef(null),[c]=m.useState(()=>new Set),[w]=m.useState(Dt),u=m.useRef(null),h=m.useRef(null),g=o==="fill",y=S.useSideBySide(),p=S.editViewOf(n,y,g),T=p!=="editor"||n.previewPrepared,O=T&&g,L=m.useRef({layout:o,region:r,paneScroll:l});m.useLayoutEffect(()=>{L.current={layout:o,region:r,paneScroll:l}});const N=m.useRef(n.generation);m.useLayoutEffect(()=>{N.current=n.generation});const M=m.useRef({view:p,previewMounted:T});m.useLayoutEffect(()=>{M.current={view:p,previewMounted:T}});const{requestSave:U,confirmation:B}=S.useSaveRequest(e),z=m.useRef(U);m.useLayoutEffect(()=>{z.current=U});const H=m.useRef(null),a=m.useRef(null),I=m.useRef(!1),A=m.useMemo(()=>({editor:f.editorLabel(t),useOurs:f.conflictUseOurs,useTheirs:f.conflictUseTheirs,keepBoth:f.conflictKeepBoth}),[f,t]),v=m.useCallback(k=>{const{region:R,paneScroll:V}=L.current,j=R();return j===null?k:V.scrollerOf(j,k)},[]);m.useLayoutEffect(()=>{const k=d.current,R=i.draft(e);if(k===null||R===null)return;const V=i.editorState.get(e),j=Vt(V)&&V.generation===N.current?V:null;let $=null,ee=null;const ue=()=>{$!==null&&clearTimeout($),$=null,ee!==null&&i.setDraft(e,ee.text())},W=it({parent:k,scroll:{scrollerOf:P=>{const{layout:te,region:Fe,paneScroll:Ue}=L.current,ve=Fe();return te==="fill"||ve===null?P:Ue.scrollerOf(ve,P)},reveal:P=>L.current.paneScroll.reveal(P)},text:R,saved:j===null?void 0:j.state,labels:A,revisions:w,onGeometry:P=>h.current?.editorChanged(P),onChange:P=>{if($??=setTimeout(ue,He),!P)for(const te of[...c])te();M.current.previewMounted&&ee!==null&&u.current?.draft({text:ee.text(),revision:w.revision()})},onSave:()=>z.current()});ee=W,E.current=W;const pe=()=>{const P=W.topLine();return{line:P.line,clientTop:P.clientTop}},ge=()=>u.current?.anchor(v)??null,ze=i.bindEditor(e,{flush:ue,adopt:P=>W.replaceText(P),returnPoint:()=>{const P=M.current.view==="preview"&&L.current.layout==="content"?ge():null;return P===null?pe():{line:P.lines.first,clientTop:P.clientTop}},nextConflict:()=>M.current.view!=="preview"?W.nextConflict():W.conflicts().length===0?!1:(I.current=!0,i.setView(e,"editor"),!0),beforeView:P=>{if(L.current.layout==="fill")return;if(P==="preview"){H.current={to:"preview",point:pe()};return}const te=ge();H.current=te===null?null:{to:"editor",anchor:te}}});return j!==null&&W.showLine(j.topLine),()=>{ue(),i.editorState.set(e,{state:W.save(),generation:N.current,topLine:W.topLine().line}),ze(),W.destroy(),ee=null,E.current=null}},[i,e,A,v,c,w]);const{request:x}=n;m.useLayoutEffect(()=>{const k=E.current,R=i.draft(e);k===null||R===null||x===null||(x.anchor!==null&&k.reveal(S.positionInSource(R,x.anchor),x.anchor.clientTop),k.focus(),i.consumeRequest(e))},[i,e,x,A]),m.useLayoutEffect(()=>{p!=="editor"&&!n.previewPrepared&&i.preparePreview(e)},[i,e,p,n.previewPrepared]),m.useLayoutEffect(()=>{const k=H.current,R=a.current,V=I.current;H.current=null,a.current=null,I.current=!1;const j=E.current;if(k?.to==="preview")u.current?.place(k.point,v);else if(k?.to==="editor"&&j!==null){const $=i.draft(e);$!==null&&j.reveal(S.positionInSource($,k.anchor),k.anchor.clientTop)}V?j?.nextConflict():R==="editor"?j?.focus():R==="preview"&&u.current?.focus()},[i,e,p,v]);const q=m.useMemo(()=>{const k=()=>{const R=E.current;if(R===null)throw new Error("[markdown-explorer] a table of the preview wrote back while no editor was mounted");return R};return{write:(R,{fenceLine:V,expected:j,text:$})=>k().replaceBody(V,j,$,R),read:(R,V)=>k().readBody(V,R),undo:()=>k().undo(),redo:()=>k().redo(),subscribe:R=>(c.add(R),()=>{c.delete(R)})}},[c]),G=m.useCallback(()=>{const k=E.current;if(k===null)throw new Error("[markdown-explorer] the preview read the draft before the editor was mounted");return{text:k.text(),revision:w.revision()}},[w]);m.useLayoutEffect(()=>{const k=E.current;if(!O||k===null)return;const R=yt({editor:Ve(k.scrollElement),preview:()=>u.current?.scrollPort()??null,previewBlocks:()=>u.current?.blocks()??[],editorSpans:V=>k.lineSpans(V),requestFrame:V=>requestAnimationFrame(V),cancelFrame:V=>cancelAnimationFrame(V),now:()=>performance.now()});return R.showAlone(S.paneShownAlone(M.current.view)),h.current=R,()=>{R.dispose(),h.current=null}},[O,i,e,A]),m.useLayoutEffect(()=>{h.current?.showAlone(S.paneShownAlone(p))},[p]);const Y=m.useCallback(()=>h.current?.previewChanged(),[]),F=m.useCallback(k=>i.start(e,k),[i,e]),le=k=>{if(S.isInFullscreenBlock(k.target))return;if(k.key==="Escape"){S.consumeKey(k);return}if(!S.isEditViewShortcut(k.nativeEvent,S.isApplePlatform(navigator.platform)))return;S.consumeKey(k);const R=S.toggledEditView(p);a.current=R,S.chooseEditView(i,e,R,g)},je=C.jsxs("div",{className:"aqmx-edit","data-aqmx-edit-layout":o,"data-aqmx-edit-view":p,"data-testid":"markdown-explorer-edit",onKeyDown:le,onDoubleClick:Bt,children:[C.jsx("div",{ref:d,id:b,className:"aqmx-edit-editor","data-testid":"markdown-explorer-editor",inert:p==="preview",hidden:p==="preview"&&!g,...S.ALLOW_KEY_REPEAT}),p==="split"?C.jsx(Pt,{editorId:b}):null,T?C.jsx(Ot,{path:e,readDraft:G,viewer:s,tables:q,concealed:p!=="editor"?null:g?"overlay":"removed",onEditAt:p==="preview"?F:void 0,onLayout:Y,handleRef:u}):null]});return C.jsxs(C.Fragment,{children:[je,B]})};exports.DRAFT_WRITE_INTERVAL_MS=He;exports.default=Ht;
|