@helpai/elements 0.14.0 → 0.14.1

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/web-component.mjs CHANGED
@@ -109,7 +109,6 @@ var STRINGS_EN = {
109
109
  // ── Forms + human-in-the-loop (forms / ask-input / approval) ────
110
110
  formSubmit: "Submit",
111
111
  formSkip: "Skip for now",
112
- formDismiss: "Dismiss",
113
112
  formRequired: "This field is required",
114
113
  formInvalidEmail: "Enter a valid email address",
115
114
  formInvalidTel: "Enter a valid phone number",
@@ -215,7 +214,6 @@ var STRINGS_FR = {
215
214
  // ── Forms + human-in-the-loop (forms / ask-input / approval) ────
216
215
  formSubmit: "Envoyer",
217
216
  formSkip: "Ignorer pour l'instant",
218
- formDismiss: "Fermer",
219
217
  formRequired: "Ce champ est obligatoire",
220
218
  formInvalidEmail: "Saisissez une adresse e-mail valide",
221
219
  formInvalidTel: "Saisissez un num\xE9ro de t\xE9l\xE9phone valide",
@@ -609,7 +607,6 @@ function resolveModules(overrides) {
609
607
  const byId = Object.fromEntries(list.map((m) => [m.id, m]));
610
608
  return { list, byId };
611
609
  }
612
- var BLOCKABLE_KINDS = /* @__PURE__ */ new Set(["pre-chat", "after-messages"]);
613
610
  function resolveForms(overrides) {
614
611
  var _a;
615
612
  if (!overrides?.length) return DEFAULT_FORMS;
@@ -621,7 +618,6 @@ function resolveForms(overrides) {
621
618
  const triggers = (Array.isArray(def.on) ? def.on : [def.on]).map(parseTrigger).filter((t) => t !== null);
622
619
  if (fields.length === 0 || triggers.length === 0) continue;
623
620
  seen.add(def.id);
624
- const blockable = triggers.some((t) => BLOCKABLE_KINDS.has(t.kind));
625
621
  list.push({
626
622
  id: def.id,
627
623
  triggers,
@@ -631,7 +627,6 @@ function resolveForms(overrides) {
631
627
  description: def.description,
632
628
  submitLabel: def.submitLabel,
633
629
  skippable: def.skippable ?? false,
634
- blocking: (def.blocking ?? false) && blockable,
635
630
  frequency: def.frequency ?? "once",
636
631
  mirrorToContext: def.mirrorToContext ?? true
637
632
  });
@@ -967,7 +962,7 @@ var tokens_default = ':host{--__P__-accent: __BRAND_ACCENT__;--__P__-accent-text
967
962
  var reset_default = '*,*:before,*:after{box-sizing:border-box;margin:0;padding:0;border:0}button{font:inherit;color:inherit;background:none;cursor:pointer;-webkit-appearance:none;appearance:none;line-height:1}button:focus-visible,[tabindex]:focus-visible,textarea:focus-visible,input:focus-visible{outline:2px solid var(--__P__-accent);outline-offset:2px}textarea,input{font:inherit;color:inherit;background:none;border:0;outline:0;resize:none}a{color:var(--__P__-accent);text-decoration:underline;text-underline-offset:2px}img,svg{display:block;max-width:100%}ul,ol{list-style:none}.__P__-app{display:block;width:100%;height:100%;font-family:var(--__P__-font);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-feature-settings:"cv11","ss01","ss03"}.__P__-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}\n';
968
963
 
969
964
  // src/styles/panel.css
970
- var panel_default = '.__P__-anchor{right:16px;bottom:16px}:host([data-position="bottom-left"]) .__P__-anchor,:host([data-position="top-left"]) .__P__-anchor{right:auto;left:16px}:host([data-position="top-right"]) .__P__-anchor,:host([data-position="top-left"]) .__P__-anchor{bottom:auto;top:16px}.__P__-anchor{position:fixed;display:flex;flex-direction:column;align-items:flex-end;gap:var(--__P__-space-3);pointer-events:none}.__P__-anchor{--__P__-fab-size: 56px}.__P__-anchor[data-launcher-size=sm]{--__P__-fab-size: 44px}.__P__-anchor[data-launcher-size=md]{--__P__-fab-size: 56px}.__P__-anchor[data-launcher-size=lg]{--__P__-fab-size: 68px}.__P__-anchor>*{pointer-events:auto}.__P__-fab[data-size=sm]{--__P__-fab-size: 44px;font-size:var(--__P__-text-sm)}.__P__-fab[data-size=md]{--__P__-fab-size: 56px;font-size:14px}.__P__-fab[data-size=lg]{--__P__-fab-size: 68px;font-size:var(--__P__-text-base)}.__P__-fab{display:inline-flex;align-items:center;justify-content:center;gap:var(--__P__-space-2);color:var(--__P__-accent-text);background:var(--__P__-accent);box-shadow:var(--__P__-shadow-fab);font-weight:600;line-height:1;transform-origin:bottom right;animation:__P__-fab-in var(--__P__-dur-base) var(--__P__-ease) both;transition:transform var(--__P__-dur-base) var(--__P__-ease),opacity var(--__P__-dur-base) var(--__P__-ease),box-shadow var(--__P__-dur-base) var(--__P__-ease)}.__P__-fab:hover{transform:translateY(-2px)}.__P__-fab:active{transform:translateY(0)}.__P__-fab:focus-visible{outline:2px solid var(--__P__-on-accent);outline-offset:3px}.__P__-fab svg{width:24px;height:24px;flex-shrink:0}@keyframes __P__-fab-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:none}}.__P__-fab[data-leaving]{position:absolute;right:0;bottom:0;animation:__P__-fab-out var(--__P__-dur-quick) var(--__P__-ease) forwards;pointer-events:none}:host([data-position^="top-"]) .__P__-fab[data-leaving]{bottom:auto;top:0}:host([data-position$="-left"]) .__P__-fab[data-leaving]{right:auto;left:0}@keyframes __P__-fab-out{0%{opacity:1;transform:none}to{opacity:0;transform:scale(.85)}}.__P__-fab[data-variant=circle]{width:var(--__P__-fab-size);height:var(--__P__-fab-size);border-radius:999px}.__P__-fab[data-variant=circle] .__P__-fab-label{display:none}.__P__-fab[data-variant=pill]{height:var(--__P__-fab-size);padding:0 18px 0 16px;border-radius:999px}.__P__-fab[data-variant=bar]{height:var(--__P__-fab-size);padding:0 22px;border-radius:var(--__P__-radius)}.__P__-fab[data-variant=minimal]{height:var(--__P__-fab-size);padding:0 var(--__P__-space-4);border-radius:999px;background:transparent;color:var(--__P__-accent);box-shadow:none;border:1px solid currentColor}.__P__-fab[data-variant=minimal]:hover{background:color-mix(in srgb,var(--__P__-accent) 12%,transparent)}.__P__-callout{--__P__-callout-fab-h: var(--__P__-fab-size, 56px);--__P__-callout-gap: clamp(12px, calc(var(--__P__-callout-fab-h) * .25), 22px);--__P__-callout-nudge-direction: -1;position:absolute;display:inline-flex;align-items:center;gap:var(--__P__-space-2);padding:10px 14px;background:var(--__P__-fg);color:var(--__P__-bg);border-radius:999px;font-size:var(--__P__-text-sm);font-weight:600;line-height:1.2;box-shadow:0 10px 30px -8px #00000059;pointer-events:auto;animation:__P__-callout-in var(--__P__-dur-slow) var(--__P__-ease);z-index:1;max-width:240px;white-space:nowrap}.__P__-callout[data-position=left]{right:calc(100% + var(--__P__-callout-gap));bottom:calc(var(--__P__-callout-fab-h) / 2);transform:translateY(50%)}.__P__-callout[data-position=right]{left:calc(100% + var(--__P__-callout-gap));bottom:calc(var(--__P__-callout-fab-h) / 2);transform:translateY(50%);--__P__-callout-nudge-direction: 1}.__P__-callout[data-position=top]{bottom:calc(100% + var(--__P__-callout-gap));right:0;max-width:min(280px,calc(100vw - 32px))}.__P__-callout[data-position=bottom]{top:calc(100% + var(--__P__-callout-gap));right:0;max-width:min(280px,calc(100vw - 32px))}:host([data-position$="-left"]) .__P__-callout[data-position=top],:host([data-position$="-left"]) .__P__-callout[data-position=bottom]{right:auto;left:0}.__P__-callout[data-shape=bubble]{border-radius:var(--__P__-radius-md);white-space:normal;width:max-content;max-width:min(280px,calc(100vw - 32px))}.__P__-callout[data-shape=callout]{padding:12px 18px;font-size:14px;background:var(--__P__-accent);color:var(--__P__-accent-text)}.__P__-callout:after{content:"";position:absolute;width:12px;height:12px;background:inherit;border-radius:2px;transform:rotate(45deg)}.__P__-callout[data-position=left]:after{right:-5px;top:50%;margin-top:-6px}.__P__-callout[data-position=right]:after{left:-5px;top:50%;margin-top:-6px}.__P__-callout[data-position=top]:after{bottom:-5px;right:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}.__P__-callout[data-position=bottom]:after{top:-5px;right:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}:host([data-position$="-left"]) .__P__-callout[data-position=top]:after,:host([data-position$="-left"]) .__P__-callout[data-position=bottom]:after{right:auto;left:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}.__P__-callout[data-animated]{animation:__P__-callout-in var(--__P__-dur-slow) var(--__P__-ease),__P__-callout-nudge 1.6s var(--__P__-ease-in-out) var(--__P__-dur-slow) infinite}@keyframes __P__-callout-in{0%{opacity:0}to{opacity:1}}@keyframes __P__-callout-nudge{0%,to{margin-left:0;margin-right:0}50%{margin-left:calc(6px * var(--__P__-callout-nudge-direction));margin-right:calc(-6px * var(--__P__-callout-nudge-direction))}}@media(prefers-reduced-motion:reduce){.__P__-callout[data-animated]{animation:__P__-callout-in 1ms var(--__P__-ease)}.__P__-icon-btn[data-recording=true],.__P__-typing span{animation:none}}.__P__-callout-close{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;border-radius:999px;color:inherit;opacity:.7;cursor:pointer}.__P__-callout-close:hover{opacity:1;background:#ffffff26}.__P__-callout-close svg{width:12px;height:12px}.__P__-panel{width:var(--__P__-panel-w);height:var(--__P__-panel-h);max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);background:var(--__P__-bg);color:var(--__P__-fg);border-radius:var(--__P__-radius-lg);box-shadow:var(--__P__-shadow-panel);display:flex;flex-direction:column;overflow:hidden;transform-origin:bottom right;animation:__P__-panel-in var(--__P__-dur-slow) var(--__P__-ease);border:1px solid var(--__P__-border)}:host([data-mode="open"]) .__P__-panel{width:var(--__P__-widget-w, var(--__P__-panel-w));height:var(--__P__-widget-h, var(--__P__-panel-h));min-width:var(--__P__-resize-min-w, auto);min-height:var(--__P__-resize-min-h, auto);max-width:var(--__P__-resize-max-w, calc(100vw - 32px) );max-height:var(--__P__-resize-max-h, calc(100dvh - 32px) )}@keyframes __P__-panel-in{0%{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:none}}:host([data-mode="expanded"]) .__P__-panel{width:var(--__P__-expanded-w, 640px);height:var(--__P__-expanded-h, 820px);max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px)}:host([data-mode="fullscreen"]){z-index:var(--__P__-z-panel)!important}:host([data-mode="fullscreen"]) .__P__-anchor{inset:0;align-items:stretch;padding:0}:host([data-mode="fullscreen"]) .__P__-panel{width:100vw;height:100dvh;max-width:none;max-height:none;border-radius:0;border:0}:host([data-mode="fullscreen"]) .__P__-fab{display:none}:host([data-mode="inline"]) .__P__-anchor,:host([data-mode="standalone"]) .__P__-anchor{position:static;inset:auto;padding:0;align-items:stretch;width:100%;height:100%;min-height:0}:host([data-mode="inline"]) .__P__-panel,:host([data-mode="standalone"]) .__P__-panel{width:100%;height:100%;min-width:0;min-height:0;max-width:none;max-height:none;animation:none}:host([data-mode="inline"]) .__P__-fab,:host([data-mode="standalone"]) .__P__-fab{display:none}:host([data-mode="inline"]){min-height:320px}:host([data-mode="inline"]) .__P__-panel{border-radius:var(--__P__-radius)}:host([data-mode="standalone"]) .__P__-panel{border-radius:0;border:0;box-shadow:none}:host([data-mode="modal"]){position:fixed!important;inset:0!important;z-index:var(--__P__-z-panel)!important;display:block!important;width:100vw;height:100dvh;background:var(--__P__-modal-backdrop, var(--__P__-backdrop));animation:__P__-backdrop-in var(--__P__-dur-base) var(--__P__-ease) both;--__P__-panel-w: min(960px, 92vw);--__P__-panel-h: min(720px, 88dvh)}:host([data-mode="modal"]) .__P__-anchor{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;padding:var(--__P__-space-6);pointer-events:none}:host([data-mode="modal"]) .__P__-panel{pointer-events:auto;width:var(--__P__-widget-w, var(--__P__-panel-w));height:var(--__P__-widget-h, var(--__P__-panel-h));max-width:calc(100vw - 48px);max-height:calc(100dvh - 48px);min-width:0;min-height:0;border-radius:var(--__P__-radius);box-shadow:var(--__P__-shadow-panel);animation:__P__-modal-in var(--__P__-dur-base) var(--__P__-ease);translate:var(--__P__-modal-dx, 0px) var(--__P__-modal-dy, 0px)}:host([data-mode="modal"]) .__P__-header,:host([data-mode="modal"]) .__P__-back-header,:host([data-mode="modal"]) .__P__-home-hero{cursor:grab;touch-action:none}:host([data-mode="modal"]) .__P__-panel[data-dragging]{cursor:grabbing;user-select:none}:host([data-mode="modal"]) .__P__-panel[data-dragging] *{cursor:grabbing}:host([data-mode="modal"]) .__P__-fab{display:none}@keyframes __P__-backdrop-in{0%{background:#0000}to{background:var(--__P__-modal-backdrop, var(--__P__-backdrop))}}@keyframes __P__-modal-in{0%{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}:host([data-mode="drawer"]){--__P__-panel-w: min(440px, calc(100vw - 32px) );--__P__-panel-h: 100dvh}:host([data-mode="drawer"]) .__P__-anchor{position:fixed;--__P__-inset-x: var(--__P__-panel-inset, 12px);--__P__-inset-y: var(--__P__-panel-inset, 3dvh);top:var(--__P__-inset-y);bottom:auto;right:var(--__P__-inset-x);left:auto;width:min(var(--__P__-widget-w, var(--__P__-panel-w)),calc(100vw - var(--__P__-inset-x) * 2));height:min(var(--__P__-widget-h, var(--__P__-panel-h)),calc(100dvh - var(--__P__-inset-y) * 2));padding:0;display:block;pointer-events:auto}:host([data-mode="drawer"][data-position$="-left"]) .__P__-anchor{right:auto;left:var(--__P__-inset-x)}:host([data-mode="drawer"][data-position^="bottom-"]) .__P__-anchor{top:auto;bottom:var(--__P__-inset-y)}:host([data-mode="drawer"]) .__P__-panel{width:100%;height:100%;max-width:none;max-height:none;min-width:0;min-height:0;border-radius:var(--__P__-radius, 12px);border:1px solid var(--__P__-border);box-shadow:-8px 16px 32px -12px #00000038;animation:__P__-drawer-in var(--__P__-dur-base) var(--__P__-ease)}:host([data-mode="drawer"][data-position$="-left"]) .__P__-panel{box-shadow:8px 16px 32px -12px #00000038;animation:__P__-drawer-in-left var(--__P__-dur-base) var(--__P__-ease)}.__P__-fab[data-edge-tab]{display:inline-flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--__P__-space-2);position:fixed;top:50%;height:140px;width:auto;min-width:0;padding:10px 8px;writing-mode:vertical-rl;text-orientation:mixed;transform:translateY(-50%);transform-origin:center;animation:__P__-edge-tab-in var(--__P__-dur-base) var(--__P__-ease) both}.__P__-fab[data-edge-tab] svg{writing-mode:horizontal-tb}.__P__-fab[data-edge-tab]:hover{transform:translateY(-50%) scale(1.03)}.__P__-fab[data-edge-tab]:active{transform:translateY(-50%) scale(.97)}:host([data-position$="-right"]) .__P__-fab[data-edge-tab]{right:0;left:auto;border-radius:12px 0 0 12px;box-shadow:-6px 0 18px -8px #0000004d}:host([data-position$="-left"]) .__P__-fab[data-edge-tab]{left:0;right:auto;border-radius:0 12px 12px 0;box-shadow:6px 0 18px -8px #0000004d}.__P__-fab[data-edge-tab][data-leaving]{position:fixed;top:50%;bottom:auto;animation:__P__-edge-tab-out var(--__P__-dur-quick) var(--__P__-ease) forwards}@keyframes __P__-edge-tab-in{0%{opacity:0;transform:translateY(-50%) scale(.9)}to{opacity:1;transform:translateY(-50%) scale(1)}}@keyframes __P__-edge-tab-out{0%{opacity:1;transform:translateY(-50%) scale(1)}to{opacity:0;transform:translateY(-50%) scale(.85)}}@keyframes __P__-drawer-in{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes __P__-drawer-in-left{0%{transform:translate(-100%)}to{transform:translate(0)}}@media(prefers-reduced-motion:reduce){:host([data-mode="drawer"]) .__P__-panel,.__P__-fab[data-edge-tab]{animation:none}}.__P__-header{display:flex;align-items:center;gap:var(--__P__-space-2);padding:10px 12px;border-bottom:1px solid var(--__P__-border);background:var(--__P__-bg)}.__P__-header h1{font-size:14px;font-weight:600;flex:1;letter-spacing:-.01em}.__P__-header-actions{margin-left:auto;display:flex;align-items:center;gap:var(--__P__-space-1);flex-shrink:0}.__P__-agent{flex:1;display:inline-flex;align-items:center;gap:10px;min-width:0}.__P__-agent-avatar{position:relative;width:32px;height:32px;border-radius:999px;background:var(--__P__-bg-elevated);color:var(--__P__-fg-muted);display:inline-flex;align-items:center;justify-content:center;font-weight:700;font-size:var(--__P__-text-xs);overflow:hidden;flex-shrink:0}.__P__-agent-avatar img{width:100%;height:100%;object-fit:cover}.__P__-agent-avatar:after{content:"";position:absolute;right:-1px;bottom:-1px;width:10px;height:10px;border-radius:999px;border:2px solid var(--__P__-bg);background:var(--__P__-neutral)}.__P__-agent-avatar[data-status=online]:after{background:var(--__P__-success)}.__P__-agent-avatar[data-status=away]:after{background:var(--__P__-warning)}.__P__-agent-avatar[data-status=offline]:after{background:var(--__P__-neutral)}.__P__-agent-meta{display:flex;flex-direction:column;line-height:1.15;min-width:0}.__P__-agent-meta strong{font-size:14px;font-weight:600;letter-spacing:-.01em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-agent-meta span{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-suggestions{display:flex;flex-wrap:nowrap;gap:var(--__P__-space-2);padding:6px 14px 10px;overflow-x:auto;overflow-y:hidden;scroll-behavior:smooth;scroll-snap-type:x proximity;scrollbar-width:none;-ms-overflow-style:none;min-width:0}.__P__-suggestions::-webkit-scrollbar{display:none}.__P__-suggestions:before,.__P__-suggestions:after{content:"";flex:1 1 0;min-width:0}.__P__-suggestion{flex:0 0 auto;scroll-snap-align:center;padding:7px 14px;border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);color:var(--__P__-fg);font-size:var(--__P__-text-sm);font-weight:500;white-space:nowrap;transition:background var(--__P__-dur-quick) var(--__P__-ease),border-color var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease)}.__P__-suggestion:hover{border-color:var(--__P__-accent);color:var(--__P__-accent);transform:translateY(-1px)}.__P__-suggestion:focus-visible{outline:2px solid var(--__P__-accent);outline-offset:2px;border-color:var(--__P__-accent)}.__P__-suggestion:active{transform:translateY(0)}.__P__-icon-btn{width:32px;height:32px;border-radius:999px;display:inline-flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted);transition:background var(--__P__-dur-quick) var(--__P__-ease),color var(--__P__-dur-quick) var(--__P__-ease)}.__P__-icon-btn:hover{background:var(--__P__-bg-elevated);color:var(--__P__-fg)}.__P__-icon-btn:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-icon-btn:active{background:var(--__P__-border)}.__P__-icon-btn:disabled{opacity:.45;cursor:not-allowed}.__P__-icon-btn:before{content:"";position:absolute;inset:-6px}.__P__-icon-btn{position:relative}.__P__-icon-btn svg{width:18px;height:18px}.__P__-icon-btn[data-recording=true]{color:var(--__P__-accent);background:color-mix(in srgb,var(--__P__-accent) 12%,transparent);animation:__P__-pulse 1.2s var(--__P__-ease) infinite}@keyframes __P__-pulse{0%,to{box-shadow:0 0 color-mix(in srgb,var(--__P__-accent) 40%,transparent)}50%{box-shadow:0 0 0 6px color-mix(in srgb,var(--__P__-accent) 0%,transparent)}}.__P__-list-wrap{position:relative;flex:1;min-height:0;display:flex;flex-direction:column}.__P__-jump{position:absolute;right:14px;bottom:14px;z-index:2;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:999px;border:1px solid var(--__P__-border);background:var(--__P__-bg-elevated);color:var(--__P__-fg);box-shadow:var(--__P__-shadow-panel);cursor:pointer;opacity:.85;transition:opacity var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease);animation:__P__-bubble-in var(--__P__-dur-base) var(--__P__-ease)}.__P__-jump:hover{opacity:1}.__P__-jump:active{transform:translateY(1px)}.__P__-jump svg{width:18px;height:18px}.__P__-list{flex:1;min-height:0;overflow-y:auto;padding:var(--__P__-space-4);padding-bottom:var(--__P__-space-8);display:flex;flex-direction:column;gap:14px;scrollbar-width:thin;scrollbar-color:var(--__P__-border-strong) transparent;scrollbar-gutter:stable}.__P__-list::-webkit-scrollbar{width:8px}.__P__-list::-webkit-scrollbar-thumb{background:var(--__P__-border-strong);border-radius:8px}.__P__-date-divider{position:sticky;top:var(--__P__-space-2);z-index:2;display:flex;justify-content:center;margin:var(--__P__-space-1) 0;pointer-events:none}.__P__-date-pill{padding:3px 10px;border-radius:999px;font-size:11px;font-weight:600;color:var(--__P__-fg-muted);background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);box-shadow:var(--__P__-shadow-card);opacity:0;pointer-events:none;transition:opacity var(--__P__-dur-base) var(--__P__-ease)}.__P__-list[data-scrolling=true] .__P__-date-pill{opacity:1;pointer-events:auto}@media(prefers-reduced-motion:reduce){.__P__-date-pill{transition:none}}.__P__-bubble-row{display:flex}.__P__-bubble-row[data-role=user]{justify-content:flex-end}.__P__-bubble-row[data-role=assistant]{justify-content:flex-start}.__P__-bubble{max-width:100%;padding:var(--__P__-space-3) var(--__P__-space-4);border-radius:var(--__P__-radius);line-height:1.6;font-size:14px;word-wrap:break-word;overflow-wrap:anywhere;box-shadow:0 1px 2px #0000000a,0 1px 8px -4px #0000000f;animation:__P__-bubble-in var(--__P__-dur-base) var(--__P__-ease)}.__P__-bubble ::selection{background:color-mix(in srgb,var(--__P__-accent) 30%,transparent)}.__P__-bubble-row[data-role=user] .__P__-bubble ::selection{background:#fff6;color:var(--__P__-bubble-user-text)}@keyframes __P__-bubble-in{0%{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}.__P__-bubble-row[data-role=user] .__P__-bubble{background:var(--__P__-bubble-user);color:var(--__P__-bubble-user-text);border-bottom-right-radius:5px}.__P__-bubble-row[data-role=assistant] .__P__-bubble{background:var(--__P__-bubble-assistant);color:var(--__P__-bubble-assistant-text);border-bottom-left-radius:5px}.__P__-bubble-col{display:flex;flex-direction:column;max-width:85%;min-width:0}.__P__-bubble-row[data-role=user] .__P__-bubble-col{align-items:flex-end}.__P__-bubble-row[data-role=assistant] .__P__-bubble-col{align-items:flex-start}.__P__-bubble-time{margin-top:3px;padding:0 4px;font-size:11px;line-height:1;color:var(--__P__-fg-muted);user-select:none}.__P__-md>*:first-child{margin-top:0}.__P__-md>*:last-child{margin-bottom:0}.__P__-md p{margin:10px 0}.__P__-md h1,.__P__-md h2,.__P__-md h3,.__P__-md h4,.__P__-md h5,.__P__-md h6{margin:18px 0 8px;line-height:1.3;letter-spacing:-.01em;font-weight:700}.__P__-md h1{font-size:1.4em}.__P__-md h2{font-size:1.22em}.__P__-md h3{font-size:1.08em}.__P__-md h4,.__P__-md h5,.__P__-md h6{font-size:1em}.__P__-md>h1:first-child,.__P__-md>h2:first-child,.__P__-md>h3:first-child,.__P__-md>h4:first-child,.__P__-md>h5:first-child,.__P__-md>h6:first-child{margin-top:0}.__P__-md ul,.__P__-md ol{padding-left:1.5em;margin:10px 0}.__P__-md ul{list-style:disc}.__P__-md ol{list-style:decimal}.__P__-md li{margin:6px 0;padding-left:2px}.__P__-md li::marker{color:var(--__P__-fg-muted)}.__P__-md li>p{margin:6px 0}.__P__-md li>ul,.__P__-md li>ol{margin:6px 0}.__P__-md strong,.__P__-md b{font-weight:650;letter-spacing:-.005em}.__P__-md em,.__P__-md i{font-style:italic}.__P__-md code{font-family:var(--__P__-font-mono);font-size:.86em;padding:1px 6px;border-radius:5px;background:color-mix(in srgb,var(--__P__-accent) 10%,transparent);color:var(--__P__-fg);border:1px solid color-mix(in srgb,var(--__P__-accent) 16%,transparent)}.__P__-md pre{font-family:var(--__P__-font-mono);font-size:12.5px;padding:12px 14px;border-radius:var(--__P__-radius-sm);background:#7f7f7f1f;overflow-x:auto;margin:var(--__P__-space-3) 0;line-height:1.5}.__P__-md pre code{padding:0;background:none}.__P__-md a{color:inherit;text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:2px}.__P__-md a:hover{text-decoration-thickness:2px}.__P__-md blockquote{margin:14px 0;padding:6px 14px;border-left:3px solid color-mix(in srgb,var(--__P__-accent) 50%,transparent);background:color-mix(in srgb,var(--__P__-accent) 5%,transparent);border-radius:0 var(--__P__-radius-sm) var(--__P__-radius-sm) 0;color:var(--__P__-fg-muted)}.__P__-md blockquote>:first-child{margin-top:0}.__P__-md blockquote>:last-child{margin-bottom:0}.__P__-md hr{border:0;height:1px;background:color-mix(in srgb,currentColor 18%,transparent);margin:var(--__P__-space-4) 0}.__P__-md table{border-collapse:collapse;margin:var(--__P__-space-3) 0;font-size:.95em;display:block;overflow-x:auto;max-width:100%;font-variant-numeric:tabular-nums}.__P__-md th,.__P__-md td{padding:6px 10px;border-bottom:1px solid color-mix(in srgb,currentColor 12%,transparent);text-align:left}.__P__-md th{font-weight:700;background:color-mix(in srgb,currentColor 6%,transparent)}.__P__-md h1+ul,.__P__-md h1+ol,.__P__-md h2+ul,.__P__-md h2+ol,.__P__-md h3+ul,.__P__-md h3+ol,.__P__-md h4+ul,.__P__-md h4+ol{margin-top:var(--__P__-space-1)}.__P__-loading{display:inline-flex;align-items:center;gap:var(--__P__-space-2);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm)}.__P__-loading-spinner{width:14px;height:14px;border-radius:999px;border:2px solid currentColor;border-top-color:transparent;animation:__P__-spin .8s linear infinite}@keyframes __P__-spin{to{transform:rotate(1turn)}}.__P__-typing{display:inline-flex;gap:var(--__P__-space-1);padding:var(--__P__-space-1) 0}.__P__-typing span{width:5px;height:5px;border-radius:999px;background:currentColor;opacity:.4;animation:__P__-blink 1.2s var(--__P__-ease) infinite}.__P__-typing span:nth-child(2){animation-delay:.2s}.__P__-typing span:nth-child(3){animation-delay:.4s}@keyframes __P__-blink{0%,80%,to{opacity:.3;transform:translateY(0)}40%{opacity:1;transform:translateY(-2px)}}.__P__-reasoning{margin:var(--__P__-space-1) 0 var(--__P__-space-2);padding-left:var(--__P__-space-3);border-left:2px solid var(--__P__-border-strong)}.__P__-reasoning-summary{display:inline-flex;align-items:center;gap:var(--__P__-space-1);cursor:pointer;list-style:none;user-select:none;color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600}.__P__-reasoning-summary::-webkit-details-marker{display:none}.__P__-reasoning-summary:before{content:"";width:5px;height:5px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(-45deg);opacity:.7;transition:transform var(--__P__-dur-quick) var(--__P__-ease)}.__P__-reasoning[open] .__P__-reasoning-summary:before{transform:rotate(45deg)}.__P__-reasoning[data-active=true] .__P__-reasoning-label{animation:__P__-reasoning-pulse 1.4s var(--__P__-ease) infinite}@keyframes __P__-reasoning-pulse{0%,to{opacity:.5}50%{opacity:1}}@media(prefers-reduced-motion:reduce){.__P__-reasoning[data-active=true] .__P__-reasoning-label{animation:none}}.__P__-reasoning-body{margin-top:var(--__P__-space-1);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm)}.__P__-reasoning-body>:first-child{margin-top:0}.__P__-reasoning-body>:last-child{margin-bottom:0}.__P__-tool-chip{display:inline-flex;align-items:center;gap:6px;padding:var(--__P__-space-1) var(--__P__-space-2);margin-top:6px;border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs)}.__P__-composer{border-top:1px solid var(--__P__-border);padding:10px 12px;background:var(--__P__-bg);display:flex;flex-direction:column;gap:var(--__P__-space-2)}.__P__-composer-row{display:flex;align-items:flex-end;gap:6px}.__P__-textarea{flex:1;height:40px;max-height:160px;padding:10px 12px;border-radius:var(--__P__-radius);background:var(--__P__-bg-elevated);border:1px solid transparent;font-size:14px;line-height:1.4;transition:height var(--__P__-dur-quick) var(--__P__-ease),border-color var(--__P__-dur-quick) var(--__P__-ease),box-shadow var(--__P__-dur-quick) var(--__P__-ease)}.__P__-textarea:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:1px;border-color:var(--__P__-focus)}@media(pointer:coarse){.__P__-textarea,.__P__-home-search-input{font-size:16px}.__P__-textarea{height:44px}}.__P__-send{width:40px;height:40px;display:inline-flex;align-items:center;justify-content:center;border:1px solid transparent;transition:opacity var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease),background var(--__P__-dur-quick) var(--__P__-ease)}.__P__-send[data-shape=circle]{border-radius:999px}.__P__-send[data-shape=square]{border-radius:var(--__P__-radius-sm)}.__P__-send[data-shape=pill]{width:auto;padding:0 18px;border-radius:999px}.__P__-send[data-variant=filled]{background:var(--__P__-accent);color:var(--__P__-accent-text)}.__P__-send[data-variant=outline]{background:transparent;color:var(--__P__-accent);border-color:var(--__P__-accent)}.__P__-send[data-variant=outline]:not(:disabled):hover{background:color-mix(in srgb,var(--__P__-accent) 10%,transparent)}.__P__-send[data-variant=ghost]{background:transparent;color:var(--__P__-accent)}.__P__-send[data-variant=ghost]:not(:disabled):hover{background:color-mix(in srgb,var(--__P__-accent) 8%,transparent)}.__P__-send:disabled{opacity:.4;cursor:not-allowed}.__P__-send:not(:disabled):hover{transform:translateY(-1px)}.__P__-send:not(:disabled):active{transform:translateY(0)}.__P__-send:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-send svg{width:18px;height:18px}.__P__-composer-actions{display:flex;gap:var(--__P__-space-1);flex-wrap:wrap}.__P__-attachments{display:flex;flex-wrap:wrap;gap:6px}.__P__-attachment-chip{display:inline-flex;align-items:center;gap:6px;padding:var(--__P__-space-1) var(--__P__-space-2) var(--__P__-space-1) var(--__P__-space-1);border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);font-size:var(--__P__-text-xs);max-width:200px}.__P__-attachment-thumb{width:24px;height:24px;border-radius:999px;object-fit:cover;background:var(--__P__-border)}.__P__-attachment-name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.__P__-attachment-remove{width:18px;height:18px;border-radius:999px;display:inline-flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted)}.__P__-attachment-remove:hover{background:var(--__P__-border);color:var(--__P__-fg)}.__P__-dropzone{position:absolute;inset:8px;border:2px dashed var(--__P__-accent);border-radius:var(--__P__-radius);background:color-mix(in srgb,var(--__P__-accent) 8%,transparent);display:flex;align-items:center;justify-content:center;font-weight:600;color:var(--__P__-accent);pointer-events:none;z-index:10;animation:__P__-fade-in var(--__P__-dur-quick) var(--__P__-ease)}@keyframes __P__-fade-in{0%{opacity:0}to{opacity:1}}.__P__-error{margin-top:var(--__P__-space-1);padding:8px 10px;border-radius:var(--__P__-radius-sm);background:var(--__P__-danger-bg);color:var(--__P__-danger-text);font-size:var(--__P__-text-sm);display:flex;align-items:center;gap:var(--__P__-space-2)}.__P__-error button{color:inherit;text-decoration:underline;font-size:var(--__P__-text-sm)}.__P__-history{flex:1;overflow-y:auto;padding:var(--__P__-space-2) var(--__P__-space-1) var(--__P__-space-3)}.__P__-history-footer{flex:none;padding:var(--__P__-space-2) var(--__P__-space-3) var(--__P__-space-3);border-top:1px solid var(--__P__-border);background:var(--__P__-surface)}.__P__-history-new{width:100%;display:flex;align-items:center;justify-content:center;gap:var(--__P__-space-2);padding:var(--__P__-space-2) var(--__P__-space-3);border:none;border-radius:var(--__P__-radius-md);background:var(--__P__-accent);color:var(--__P__-on-accent);cursor:pointer;font-size:var(--__P__-text-sm);font-weight:600;transition:filter var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-history-new svg{width:16px;height:16px}.__P__-history-new:hover{filter:brightness(1.08)}.__P__-history-new:active{transform:translateY(1px)}.__P__-history-new:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-history-empty{flex:1;display:flex;align-items:center;justify-content:center;padding:40px 16px;color:var(--__P__-fg-muted);font-size:14px;text-align:center}.__P__-history-group{display:flex;flex-direction:column;padding:0 var(--__P__-space-2)}.__P__-history-heading{font-size:var(--__P__-text-xs);font-weight:600;color:var(--__P__-fg-muted);padding:12px 8px 6px;text-transform:uppercase;letter-spacing:.04em}.__P__-history-item{all:unset;display:flex;flex-direction:column;gap:3px;padding:10px 12px;border-radius:var(--__P__-radius-md);cursor:pointer;transition:background var(--__P__-dur-base) var(--__P__-ease)}.__P__-history-item:hover{background:var(--__P__-bg-elevated)}.__P__-history-item:focus-visible{background:var(--__P__-bg-elevated);outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-history-title{font-size:14px;font-weight:500;color:var(--__P__-fg);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-history-preview{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-history-item[data-closed=true] .__P__-history-title:after{content:"\\2022";margin-left:var(--__P__-space-2);opacity:.5}.__P__-list-loading{margin:auto;padding:var(--__P__-space-6) var(--__P__-space-4);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);text-align:center}.__P__-readonly-banner{display:flex;flex-direction:column;align-items:center;gap:10px;padding:14px 12px;margin:0 var(--__P__-space-3) var(--__P__-space-3);border-radius:var(--__P__-radius-md);background:var(--__P__-bg-elevated);color:var(--__P__-fg-muted);text-align:center;font-size:var(--__P__-text-sm)}.__P__-readonly-label{line-height:1.4}.__P__-readonly-cta{appearance:none;border:0;cursor:pointer;padding:var(--__P__-space-2) var(--__P__-space-4);border-radius:999px;background:var(--__P__-accent);color:var(--__P__-accent-text, #fff);font:inherit;font-weight:600;font-size:var(--__P__-text-sm);transition:filter var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-readonly-cta:hover,.__P__-readonly-cta:focus-visible{filter:brightness(1.1)}.__P__-readonly-cta:focus-visible{outline:2px solid var(--__P__-accent);outline-offset:2px}.__P__-composer-footer{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:10px 16px;margin:0 var(--__P__-space-3);border-top:1px solid var(--__P__-border);text-align:center;font-size:11px;line-height:1.4;color:var(--__P__-fg-muted)}.__P__-disclaimer{max-width:320px;margin:0 auto;opacity:.9;letter-spacing:.01em}.__P__-poweredby{display:inline-flex;align-items:center;justify-content:center;gap:6px;color:inherit;text-decoration:none;opacity:.7;transition:opacity var(--__P__-dur-base) var(--__P__-ease);font-size:11px;letter-spacing:.02em}.__P__-poweredby:hover{opacity:1}.__P__-poweredby-logo{height:12px;width:auto;display:inline-block;vertical-align:middle}.__P__-poweredby-bar{flex:none;display:flex;align-items:center;justify-content:center;padding:6px 16px;border-top:1px solid var(--__P__-border);background:var(--__P__-bg-elevated)}.__P__-menu-wrap{position:relative;display:inline-flex}.__P__-menu{position:absolute;top:100%;right:0;margin-top:6px;min-width:200px;padding:6px;background:var(--__P__-bg);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);box-shadow:var(--__P__-shadow-panel);z-index:10;display:flex;flex-direction:column;gap:2px;animation:__P__-menu-in var(--__P__-dur-base) var(--__P__-ease)}@media(prefers-reduced-motion:reduce){.__P__-menu{animation:none}}@keyframes __P__-menu-in{0%{opacity:0;transform:translateY(-4px) scale(.98);transform-origin:top right}to{opacity:1;transform:none}}.__P__-menu-item{all:unset;display:flex;align-items:center;gap:10px;padding:8px 10px;font-size:var(--__P__-text-sm);color:var(--__P__-fg);border-radius:var(--__P__-radius-sm);cursor:pointer;user-select:none}.__P__-menu-item:hover{background:var(--__P__-bg-elevated)}.__P__-menu-item:focus-visible{background:var(--__P__-bg-elevated);outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-menu-item[disabled]{opacity:.45;cursor:not-allowed}.__P__-menu-icon{display:inline-flex;width:16px;height:16px;color:var(--__P__-fg-muted)}.__P__-menu-icon svg{width:16px;height:16px}.__P__-menu-label{flex:1}.__P__-menu-check{display:inline-flex;color:var(--__P__-accent)}.__P__-menu-check svg{width:14px;height:14px}.__P__-resize-grip{position:absolute;width:18px;height:18px;display:flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted);opacity:.45;transition:opacity var(--__P__-dur-base) var(--__P__-ease);z-index:2;touch-action:none;user-select:none}.__P__-resize-grip:hover,.__P__-resize-grip:focus-visible{opacity:1}.__P__-resize-grip svg{width:10px;height:10px}.__P__-resize-grip--bottom-left{bottom:2px;left:2px;cursor:nesw-resize;transform:scaleX(-1)}.__P__-resize-grip--bottom-right{bottom:2px;right:2px;cursor:nwse-resize}.__P__-resize-grip--top-left{top:2px;left:2px;cursor:nwse-resize;transform:rotate(180deg)}.__P__-resize-grip--top-right{top:2px;right:2px;cursor:nesw-resize;transform:scaleY(-1)}:host(:not([data-mode="open"])) .__P__-resize-grip{display:none}.__P__-messenger{display:flex;flex-direction:column;overflow:hidden}.__P__-messenger-body{flex:1;min-height:0;display:flex;flex-direction:column;overflow:hidden}.__P__-module{display:flex;flex-direction:column;height:100%;min-height:0}.__P__-module-scroll{flex:1;min-height:0;overflow-y:auto;padding:var(--__P__-space-3);display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-home{background:radial-gradient(125% 65% at 88% 0%,color-mix(in srgb,#fff 16%,transparent),transparent 55%),linear-gradient(180deg,var(--__P__-accent) 0%,var(--__P__-accent) 22%,color-mix(in srgb,var(--__P__-accent) 28%,var(--__P__-surface)) 44%,var(--__P__-surface) 70%);border-radius:var(--__P__-radius-lg) var(--__P__-radius-lg) 0 0}.__P__-home-scroll{flex:1;min-height:0;overflow-y:auto;display:flex;flex-direction:column;background:transparent}.__P__-home-cards{display:flex;flex-direction:column;gap:var(--__P__-space-3);padding:4px 14px 16px}.__P__-module-pad{padding:var(--__P__-space-3) var(--__P__-space-3) 0}.__P__-module-empty{display:flex;flex-direction:column;align-items:center;gap:var(--__P__-space-3);padding:var(--__P__-space-8) var(--__P__-space-4);text-align:center;color:var(--__P__-fg-muted);font-size:var(--__P__-text-base)}.__P__-module-retry{padding:var(--__P__-space-2) var(--__P__-space-4);border:1px solid var(--__P__-border-strong);border-radius:var(--__P__-radius-sm);color:var(--__P__-fg);font-weight:600;cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out),border-color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-module-retry:hover{background:var(--__P__-hover);border-color:var(--__P__-accent)}.__P__-module-retry:active{background:var(--__P__-border)}.__P__-module-retry:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-help-list{flex:1;min-height:0;overflow-y:auto;padding-bottom:var(--__P__-space-3)}.__P__-help-group{display:flex;flex-direction:column}.__P__-help-section-title{position:sticky;top:0;z-index:1;margin:0;padding:var(--__P__-space-3) var(--__P__-space-5) var(--__P__-space-2);font-size:var(--__P__-text-xs);font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--__P__-fg-muted);background:var(--__P__-bg)}.__P__-help-card{margin:0 var(--__P__-space-3) var(--__P__-space-3);background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);overflow:hidden}.__P__-help-card .__P__-list-row{border-bottom:0;border-radius:0}.__P__-help-card .__P__-list-row+.__P__-list-row{border-top:1px solid var(--__P__-border)}.__P__-help-card .__P__-list-row:hover{background:var(--__P__-hover)}.__P__-module-cta{padding:var(--__P__-space-3);border-top:1px solid var(--__P__-border)}.__P__-tabbar{display:flex;border-top:1px solid var(--__P__-border);background:var(--__P__-bg-elevated);flex-shrink:0}.__P__-tab{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--__P__-space-1);min-height:48px;padding:var(--__P__-space-2) var(--__P__-space-1);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600;transition:color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-tab:hover{color:var(--__P__-fg)}.__P__-tab[aria-selected=true]{color:var(--__P__-accent)}.__P__-tab:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-tab:active{background:var(--__P__-hover)}.__P__-tab-icon{position:relative;display:inline-flex}.__P__-tab-icon svg{width:22px;height:22px}.__P__-tab-badge{position:absolute;top:-4px;left:calc(50% + 6px);min-width:16px;height:16px;padding:0 4px;display:inline-flex;align-items:center;justify-content:center;border-radius:999px;background:var(--__P__-accent);color:var(--__P__-on-accent);font-size:10px;font-weight:600;line-height:1}.__P__-home-hero{flex-shrink:0;padding:var(--__P__-space-5) var(--__P__-space-5) var(--__P__-space-3);color:var(--__P__-on-accent);--__P__-focus: var(--__P__-on-accent)}.__P__-home-hero-top{display:flex;align-items:center;justify-content:space-between;gap:var(--__P__-space-3);min-height:32px}.__P__-home-brand{font-size:14px;font-weight:600;letter-spacing:.01em;color:color-mix(in srgb,#fff 82%,transparent);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}.__P__-home-brand-spacer{flex:1}.__P__-home-hero-actions{display:flex;align-items:center;gap:var(--__P__-space-2);flex-shrink:0}.__P__-home-hero-actions .__P__-icon-btn{color:#fff}.__P__-home-greeting{margin:28px 0 0;font-family:var(--__P__-font-display);font-size:var(--__P__-text-2xl);font-weight:800;line-height:1.18;letter-spacing:-.01em;overflow-wrap:anywhere}.__P__-home-lead{margin:2px 0 0;font-family:var(--__P__-font-display);font-size:var(--__P__-text-2xl);font-weight:800;line-height:1.18;letter-spacing:-.01em;color:color-mix(in srgb,var(--__P__-on-accent) 88%,transparent);overflow-wrap:anywhere}.__P__-home-avatars{display:flex}.__P__-home-avatar{width:30px;height:30px;border-radius:999px;overflow:hidden;margin-left:-10px;border:2px solid color-mix(in srgb,#fff 92%,transparent);box-shadow:0 1px 3px #0000002e;background:var(--__P__-surface);display:inline-flex;align-items:center;justify-content:center;font-size:var(--__P__-text-xs);font-weight:700;color:var(--__P__-fg)}.__P__-home-avatar:first-child{margin-left:0}.__P__-home-avatar img{width:100%;height:100%;object-fit:cover}.__P__-home-content{background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);box-shadow:var(--__P__-shadow-card);overflow:hidden}.__P__-home-content-title{padding:var(--__P__-space-4) var(--__P__-space-4) var(--__P__-space-3);font-size:var(--__P__-text-sm);font-weight:700}.__P__-home-content-list{display:flex;flex-direction:column;padding:0 var(--__P__-space-2) var(--__P__-space-2)}.__P__-home-content-list .__P__-list-row+.__P__-list-row{border-top:1px solid var(--__P__-border)}.__P__-home-card{display:block;width:100%;text-align:left;background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);padding:var(--__P__-space-4);box-shadow:var(--__P__-shadow-card)}.__P__-home-card[data-interactive=true]{cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-home-card[data-interactive=true]:hover{background:var(--__P__-bg-elevated)}.__P__-home-card[data-interactive=true]:active{transform:translateY(1px)}.__P__-home-card[data-interactive=true]:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-home-recent-row{display:flex;align-items:center;gap:var(--__P__-space-3)}.__P__-home-recent-avatar{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;flex-shrink:0;border-radius:999px;background:color-mix(in oklch,var(--__P__-accent) 14%,transparent);color:var(--__P__-accent)}.__P__-home-recent-avatar svg{width:20px;height:20px}.__P__-home-recent-body{display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}.__P__-home-recent-title{font-weight:600;font-size:14px}.__P__-home-recent-preview{color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.__P__-home-recent-at{color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);flex-shrink:0}.__P__-home-recent-dot{width:8px;height:8px;border-radius:999px;background:var(--__P__-accent);flex-shrink:0}.__P__-home-recent-row[data-unread=true] .__P__-home-recent-title{font-weight:700}.__P__-home-status{display:flex;align-items:center;gap:var(--__P__-space-3)}.__P__-home-status-icon svg{width:22px;height:22px;color:var(--__P__-success)}.__P__-home-status[data-level=degraded] .__P__-home-status-icon svg{color:var(--__P__-warning)}.__P__-home-status[data-level=down] .__P__-home-status-icon svg{color:var(--__P__-danger)}.__P__-home-status-text{font-weight:600;font-size:14px}.__P__-home-search{display:flex;align-items:center;gap:var(--__P__-space-2);width:100%;padding:var(--__P__-space-3) var(--__P__-space-4);border-radius:var(--__P__-radius);border:1px solid var(--__P__-border);background:var(--__P__-surface);text-align:left}.__P__-home-search[data-input=true]{background:var(--__P__-bg-elevated)}.__P__-home-search:hover{border-color:var(--__P__-border-strong)}.__P__-home-search:focus-visible,.__P__-home-search:focus-within{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-home-search-text{flex:1;color:var(--__P__-fg-muted);font-size:14px}.__P__-home-search-input{flex:1;border:0;background:transparent;font-size:14px;color:var(--__P__-fg);outline:none}.__P__-home-search-icon svg{width:18px;height:18px;color:var(--__P__-accent)}.__P__-list-row{display:flex;align-items:center;gap:var(--__P__-space-3);width:100%;min-height:44px;text-align:left;padding:var(--__P__-space-3) var(--__P__-space-2);border-radius:var(--__P__-radius-sm)}.__P__-list-row:hover{background:var(--__P__-bg-elevated)}.__P__-list-row:active{background:var(--__P__-border)}.__P__-list-row:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-list-row-body{display:flex;flex-direction:column;min-width:0;flex:1}.__P__-list-row-title{font-weight:600;font-size:var(--__P__-text-md);line-height:1.35}.__P__-list-row-sub{color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);margin-top:var(--__P__-space-1);line-height:1.45;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.__P__-list-row-chevron svg{width:18px;height:18px;color:var(--__P__-accent);flex-shrink:0}.__P__-back-header{display:flex;align-items:center;gap:var(--__P__-space-2);padding:10px 12px;border-bottom:1px solid var(--__P__-border);flex-shrink:0}.__P__-back-title{flex:1;text-align:center;font-size:var(--__P__-text-md);font-weight:700;margin:0;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-back-spacer{width:32px;height:1px}.__P__-content{display:flex;flex-direction:column;gap:14px;width:100%;max-width:68ch;margin:0 auto}.__P__-content-hero{width:100%;border-radius:var(--__P__-radius)}.__P__-content-subtitle{color:var(--__P__-fg-muted);margin:0}.__P__-content-frame{flex:1;min-height:0;width:100%;border:0;background:#fff}.__P__-news-list{display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-news-card{display:block;width:100%;text-align:left;border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);overflow:hidden;background:var(--__P__-surface)}.__P__-news-card{transition:background var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-news-card:hover{background:var(--__P__-bg-elevated)}.__P__-news-card:active{transform:translateY(1px)}.__P__-news-card:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-news-hero{width:100%;display:block}.__P__-news-body{display:flex;flex-direction:column;gap:6px;padding:14px 16px}.__P__-news-tags{display:flex;gap:6px;flex-wrap:wrap}.__P__-news-tag{font-size:var(--__P__-text-xs);font-weight:600;color:var(--__P__-accent);background:color-mix(in srgb,var(--__P__-accent) 12%,transparent);padding:2px 8px;border-radius:999px}.__P__-news-title{font-weight:700;font-size:var(--__P__-text-md)}.__P__-news-summary{color:var(--__P__-fg-muted);font-size:14px;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.__P__-modules-empty{display:flex;align-items:center;justify-content:center;position:relative}.__P__-modules-empty-close{position:absolute;top:12px;right:12px}.__P__-modules-empty-text{color:var(--__P__-fg-muted);font-size:var(--__P__-text-base)}.__P__-form{display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-field{display:flex;flex-direction:column;gap:4px}.__P__-field-label{font-size:var(--__P__-text-sm);font-weight:600;color:var(--__P__-fg)}.__P__-field-req{color:var(--__P__-danger)}.__P__-field-input{width:100%;box-sizing:border-box;padding:var(--__P__-space-2) var(--__P__-space-3);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:var(--__P__-bg);color:var(--__P__-fg);font:inherit;font-size:var(--__P__-text-sm);resize:vertical;transition:border-color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-field-input:focus-visible{outline:none;border-color:var(--__P__-accent)}.__P__-field[data-invalid=true] .__P__-field-input{border-color:var(--__P__-danger)}.__P__-field-hint{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted)}.__P__-field-error{font-size:var(--__P__-text-xs);color:var(--__P__-danger)}.__P__-field-choices{display:flex;flex-direction:column;gap:6px}.__P__-choice{display:flex;align-items:flex-start;gap:8px;font-size:var(--__P__-text-sm);color:var(--__P__-fg);cursor:pointer}.__P__-choice input{margin-top:2px;accent-color:var(--__P__-accent)}.__P__-form-actions{display:flex;justify-content:flex-end;gap:var(--__P__-space-2);margin-top:2px}.__P__-form-submit,.__P__-tool-approve{padding:var(--__P__-space-2) var(--__P__-space-4);border:none;border-radius:var(--__P__-radius-md);background:var(--__P__-accent);color:var(--__P__-accent-text, #fff);font:inherit;font-weight:600;font-size:var(--__P__-text-sm);cursor:pointer;transition:filter var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-form-submit:hover:not(:disabled),.__P__-tool-approve:hover:not(:disabled){filter:brightness(1.06)}.__P__-form-submit:disabled{opacity:.6;cursor:default}.__P__-form-skip,.__P__-tool-reject{padding:var(--__P__-space-2) var(--__P__-space-4);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:transparent;color:var(--__P__-fg-muted);font:inherit;font-size:var(--__P__-text-sm);cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-form-skip:hover:not(:disabled),.__P__-tool-reject:hover:not(:disabled){background:var(--__P__-bg-elevated)}.__P__-form-gate{display:flex;flex-direction:column;gap:var(--__P__-space-2);padding:var(--__P__-space-3) var(--__P__-space-4) var(--__P__-space-4);border-top:1px solid var(--__P__-border);overflow-y:auto}.__P__-form-gate-title{margin:0;font-size:var(--__P__-text-base);font-weight:700;color:var(--__P__-fg)}.__P__-form-gate-desc{margin:0 0 var(--__P__-space-1);font-size:var(--__P__-text-sm);color:var(--__P__-fg-muted)}.__P__-form-card{display:flex;flex-direction:column;gap:var(--__P__-space-2);margin:var(--__P__-space-2) 0;padding:var(--__P__-space-3);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:var(--__P__-bg-elevated)}.__P__-form-card-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.__P__-form-card-title{font-size:var(--__P__-text-sm);font-weight:700;color:var(--__P__-fg)}.__P__-form-card-desc{margin:0;font-size:var(--__P__-text-sm);color:var(--__P__-fg-muted)}.__P__-tool-ask-input,.__P__-tool-approval{display:flex;flex-direction:column;gap:var(--__P__-space-2);margin-top:6px;padding:var(--__P__-space-3);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:var(--__P__-bg-elevated)}.__P__-tool-head{display:flex;align-items:center;flex-wrap:wrap;gap:8px}.__P__-tool-badge{padding:2px 8px;border-radius:999px;background:var(--__P__-warning, #f59e0b);color:#1a1206;font-size:var(--__P__-text-xs);font-weight:600}.__P__-tool-title{font-size:var(--__P__-text-sm);color:var(--__P__-fg)}.__P__-tool-question{margin:0;font-size:var(--__P__-text-sm);font-weight:600;color:var(--__P__-fg)}.__P__-tool-desc{margin:0;font-size:var(--__P__-text-sm);color:var(--__P__-fg-muted)}.__P__-tool-args{margin:0;padding:var(--__P__-space-2);max-height:160px;overflow:auto;border-radius:var(--__P__-radius-sm);background:var(--__P__-bg);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);white-space:pre-wrap;word-break:break-word}.__P__-tool-stale-note{margin:0;font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted)}.__P__-tool-decided{flex-direction:row;align-items:center;flex-wrap:wrap;gap:8px}.__P__-tool-decided-label{padding:2px 8px;border-radius:999px;background:var(--__P__-bg);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600}.__P__-tool-decided-label[data-approved=true]{color:var(--__P__-success, #16a34a);border-color:var(--__P__-success, #16a34a)}.__P__-tool-decided-label[data-approved=false]{color:var(--__P__-danger);border-color:var(--__P__-danger)}.__P__-tool-decided-value{font-size:var(--__P__-text-sm);color:var(--__P__-fg)}\n';
965
+ var panel_default = '.__P__-anchor{right:16px;bottom:16px}:host([data-position="bottom-left"]) .__P__-anchor,:host([data-position="top-left"]) .__P__-anchor{right:auto;left:16px}:host([data-position="top-right"]) .__P__-anchor,:host([data-position="top-left"]) .__P__-anchor{bottom:auto;top:16px}.__P__-anchor{position:fixed;display:flex;flex-direction:column;align-items:flex-end;gap:var(--__P__-space-3);pointer-events:none}.__P__-anchor{--__P__-fab-size: 56px}.__P__-anchor[data-launcher-size=sm]{--__P__-fab-size: 44px}.__P__-anchor[data-launcher-size=md]{--__P__-fab-size: 56px}.__P__-anchor[data-launcher-size=lg]{--__P__-fab-size: 68px}.__P__-anchor>*{pointer-events:auto}.__P__-fab[data-size=sm]{--__P__-fab-size: 44px;font-size:var(--__P__-text-sm)}.__P__-fab[data-size=md]{--__P__-fab-size: 56px;font-size:14px}.__P__-fab[data-size=lg]{--__P__-fab-size: 68px;font-size:var(--__P__-text-base)}.__P__-fab{display:inline-flex;align-items:center;justify-content:center;gap:var(--__P__-space-2);color:var(--__P__-accent-text);background:var(--__P__-accent);box-shadow:var(--__P__-shadow-fab);font-weight:600;line-height:1;transform-origin:bottom right;animation:__P__-fab-in var(--__P__-dur-base) var(--__P__-ease) both;transition:transform var(--__P__-dur-base) var(--__P__-ease),opacity var(--__P__-dur-base) var(--__P__-ease),box-shadow var(--__P__-dur-base) var(--__P__-ease)}.__P__-fab:hover{transform:translateY(-2px)}.__P__-fab:active{transform:translateY(0)}.__P__-fab:focus-visible{outline:2px solid var(--__P__-on-accent);outline-offset:3px}.__P__-fab svg{width:24px;height:24px;flex-shrink:0}@keyframes __P__-fab-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:none}}.__P__-fab[data-leaving]{position:absolute;right:0;bottom:0;animation:__P__-fab-out var(--__P__-dur-quick) var(--__P__-ease) forwards;pointer-events:none}:host([data-position^="top-"]) .__P__-fab[data-leaving]{bottom:auto;top:0}:host([data-position$="-left"]) .__P__-fab[data-leaving]{right:auto;left:0}@keyframes __P__-fab-out{0%{opacity:1;transform:none}to{opacity:0;transform:scale(.85)}}.__P__-fab[data-variant=circle]{width:var(--__P__-fab-size);height:var(--__P__-fab-size);border-radius:999px}.__P__-fab[data-variant=circle] .__P__-fab-label{display:none}.__P__-fab[data-variant=pill]{height:var(--__P__-fab-size);padding:0 18px 0 16px;border-radius:999px}.__P__-fab[data-variant=bar]{height:var(--__P__-fab-size);padding:0 22px;border-radius:var(--__P__-radius)}.__P__-fab[data-variant=minimal]{height:var(--__P__-fab-size);padding:0 var(--__P__-space-4);border-radius:999px;background:transparent;color:var(--__P__-accent);box-shadow:none;border:1px solid currentColor}.__P__-fab[data-variant=minimal]:hover{background:color-mix(in srgb,var(--__P__-accent) 12%,transparent)}.__P__-callout{--__P__-callout-fab-h: var(--__P__-fab-size, 56px);--__P__-callout-gap: clamp(12px, calc(var(--__P__-callout-fab-h) * .25), 22px);--__P__-callout-nudge-direction: -1;position:absolute;display:inline-flex;align-items:center;gap:var(--__P__-space-2);padding:10px 14px;background:var(--__P__-fg);color:var(--__P__-bg);border-radius:999px;font-size:var(--__P__-text-sm);font-weight:600;line-height:1.2;box-shadow:0 10px 30px -8px #00000059;pointer-events:auto;animation:__P__-callout-in var(--__P__-dur-slow) var(--__P__-ease);z-index:1;max-width:240px;white-space:nowrap}.__P__-callout[data-position=left]{right:calc(100% + var(--__P__-callout-gap));bottom:calc(var(--__P__-callout-fab-h) / 2);transform:translateY(50%)}.__P__-callout[data-position=right]{left:calc(100% + var(--__P__-callout-gap));bottom:calc(var(--__P__-callout-fab-h) / 2);transform:translateY(50%);--__P__-callout-nudge-direction: 1}.__P__-callout[data-position=top]{bottom:calc(100% + var(--__P__-callout-gap));right:0;max-width:min(280px,calc(100vw - 32px))}.__P__-callout[data-position=bottom]{top:calc(100% + var(--__P__-callout-gap));right:0;max-width:min(280px,calc(100vw - 32px))}:host([data-position$="-left"]) .__P__-callout[data-position=top],:host([data-position$="-left"]) .__P__-callout[data-position=bottom]{right:auto;left:0}.__P__-callout[data-shape=bubble]{border-radius:var(--__P__-radius-md);white-space:normal;width:max-content;max-width:min(280px,calc(100vw - 32px))}.__P__-callout[data-shape=callout]{padding:12px 18px;font-size:14px;background:var(--__P__-accent);color:var(--__P__-accent-text)}.__P__-callout:after{content:"";position:absolute;width:12px;height:12px;background:inherit;border-radius:2px;transform:rotate(45deg)}.__P__-callout[data-position=left]:after{right:-5px;top:50%;margin-top:-6px}.__P__-callout[data-position=right]:after{left:-5px;top:50%;margin-top:-6px}.__P__-callout[data-position=top]:after{bottom:-5px;right:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}.__P__-callout[data-position=bottom]:after{top:-5px;right:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}:host([data-position$="-left"]) .__P__-callout[data-position=top]:after,:host([data-position$="-left"]) .__P__-callout[data-position=bottom]:after{right:auto;left:calc(var(--__P__-fab-size, 56px) / 2 - 6px)}.__P__-callout[data-animated]{animation:__P__-callout-in var(--__P__-dur-slow) var(--__P__-ease),__P__-callout-nudge 1.6s var(--__P__-ease-in-out) var(--__P__-dur-slow) infinite}@keyframes __P__-callout-in{0%{opacity:0}to{opacity:1}}@keyframes __P__-callout-nudge{0%,to{margin-left:0;margin-right:0}50%{margin-left:calc(6px * var(--__P__-callout-nudge-direction));margin-right:calc(-6px * var(--__P__-callout-nudge-direction))}}@media(prefers-reduced-motion:reduce){.__P__-callout[data-animated]{animation:__P__-callout-in 1ms var(--__P__-ease)}.__P__-icon-btn[data-recording=true],.__P__-typing span{animation:none}}.__P__-callout-close{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;border-radius:999px;color:inherit;opacity:.7;cursor:pointer}.__P__-callout-close:hover{opacity:1;background:#ffffff26}.__P__-callout-close svg{width:12px;height:12px}.__P__-panel{width:var(--__P__-panel-w);height:var(--__P__-panel-h);max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);background:var(--__P__-bg);color:var(--__P__-fg);border-radius:var(--__P__-radius-lg);box-shadow:var(--__P__-shadow-panel);display:flex;flex-direction:column;overflow:hidden;transform-origin:bottom right;animation:__P__-panel-in var(--__P__-dur-slow) var(--__P__-ease);border:1px solid var(--__P__-border)}:host([data-mode="open"]) .__P__-panel{width:var(--__P__-widget-w, var(--__P__-panel-w));height:var(--__P__-widget-h, var(--__P__-panel-h));min-width:var(--__P__-resize-min-w, auto);min-height:var(--__P__-resize-min-h, auto);max-width:var(--__P__-resize-max-w, calc(100vw - 32px) );max-height:var(--__P__-resize-max-h, calc(100dvh - 32px) )}@keyframes __P__-panel-in{0%{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:none}}:host([data-mode="expanded"]) .__P__-panel{width:var(--__P__-expanded-w, 640px);height:var(--__P__-expanded-h, 820px);max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px)}:host([data-mode="fullscreen"]){z-index:var(--__P__-z-panel)!important}:host([data-mode="fullscreen"]) .__P__-anchor{inset:0;align-items:stretch;padding:0}:host([data-mode="fullscreen"]) .__P__-panel{width:100vw;height:100dvh;max-width:none;max-height:none;border-radius:0;border:0}:host([data-mode="fullscreen"]) .__P__-fab{display:none}:host([data-mode="inline"]) .__P__-anchor,:host([data-mode="standalone"]) .__P__-anchor{position:static;inset:auto;padding:0;align-items:stretch;width:100%;height:100%;min-height:0}:host([data-mode="inline"]) .__P__-panel,:host([data-mode="standalone"]) .__P__-panel{width:100%;height:100%;min-width:0;min-height:0;max-width:none;max-height:none;animation:none}:host([data-mode="inline"]) .__P__-fab,:host([data-mode="standalone"]) .__P__-fab{display:none}:host([data-mode="inline"]){min-height:320px}:host([data-mode="inline"]) .__P__-panel{border-radius:var(--__P__-radius)}:host([data-mode="standalone"]) .__P__-panel{border-radius:0;border:0;box-shadow:none}:host([data-mode="modal"]){position:fixed!important;inset:0!important;z-index:var(--__P__-z-panel)!important;display:block!important;width:100vw;height:100dvh;background:var(--__P__-modal-backdrop, var(--__P__-backdrop));animation:__P__-backdrop-in var(--__P__-dur-base) var(--__P__-ease) both;--__P__-panel-w: min(960px, 92vw);--__P__-panel-h: min(720px, 88dvh)}:host([data-mode="modal"]) .__P__-anchor{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;padding:var(--__P__-space-6);pointer-events:none}:host([data-mode="modal"]) .__P__-panel{pointer-events:auto;width:var(--__P__-widget-w, var(--__P__-panel-w));height:var(--__P__-widget-h, var(--__P__-panel-h));max-width:calc(100vw - 48px);max-height:calc(100dvh - 48px);min-width:0;min-height:0;border-radius:var(--__P__-radius);box-shadow:var(--__P__-shadow-panel);animation:__P__-modal-in var(--__P__-dur-base) var(--__P__-ease);translate:var(--__P__-modal-dx, 0px) var(--__P__-modal-dy, 0px)}:host([data-mode="modal"]) .__P__-header,:host([data-mode="modal"]) .__P__-back-header,:host([data-mode="modal"]) .__P__-home-hero{cursor:grab;touch-action:none}:host([data-mode="modal"]) .__P__-panel[data-dragging]{cursor:grabbing;user-select:none}:host([data-mode="modal"]) .__P__-panel[data-dragging] *{cursor:grabbing}:host([data-mode="modal"]) .__P__-fab{display:none}@keyframes __P__-backdrop-in{0%{background:#0000}to{background:var(--__P__-modal-backdrop, var(--__P__-backdrop))}}@keyframes __P__-modal-in{0%{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}:host([data-mode="drawer"]){--__P__-panel-w: min(440px, calc(100vw - 32px) );--__P__-panel-h: 100dvh}:host([data-mode="drawer"]) .__P__-anchor{position:fixed;--__P__-inset-x: var(--__P__-panel-inset, 12px);--__P__-inset-y: var(--__P__-panel-inset, 3dvh);top:var(--__P__-inset-y);bottom:auto;right:var(--__P__-inset-x);left:auto;width:min(var(--__P__-widget-w, var(--__P__-panel-w)),calc(100vw - var(--__P__-inset-x) * 2));height:min(var(--__P__-widget-h, var(--__P__-panel-h)),calc(100dvh - var(--__P__-inset-y) * 2));padding:0;display:block;pointer-events:auto}:host([data-mode="drawer"][data-position$="-left"]) .__P__-anchor{right:auto;left:var(--__P__-inset-x)}:host([data-mode="drawer"][data-position^="bottom-"]) .__P__-anchor{top:auto;bottom:var(--__P__-inset-y)}:host([data-mode="drawer"]) .__P__-panel{width:100%;height:100%;max-width:none;max-height:none;min-width:0;min-height:0;border-radius:var(--__P__-radius, 12px);border:1px solid var(--__P__-border);box-shadow:-8px 16px 32px -12px #00000038;animation:__P__-drawer-in var(--__P__-dur-base) var(--__P__-ease)}:host([data-mode="drawer"][data-position$="-left"]) .__P__-panel{box-shadow:8px 16px 32px -12px #00000038;animation:__P__-drawer-in-left var(--__P__-dur-base) var(--__P__-ease)}.__P__-fab[data-edge-tab]{display:inline-flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--__P__-space-2);position:fixed;top:50%;height:140px;width:auto;min-width:0;padding:10px 8px;writing-mode:vertical-rl;text-orientation:mixed;transform:translateY(-50%);transform-origin:center;animation:__P__-edge-tab-in var(--__P__-dur-base) var(--__P__-ease) both}.__P__-fab[data-edge-tab] svg{writing-mode:horizontal-tb}.__P__-fab[data-edge-tab]:hover{transform:translateY(-50%) scale(1.03)}.__P__-fab[data-edge-tab]:active{transform:translateY(-50%) scale(.97)}:host([data-position$="-right"]) .__P__-fab[data-edge-tab]{right:0;left:auto;border-radius:12px 0 0 12px;box-shadow:-6px 0 18px -8px #0000004d}:host([data-position$="-left"]) .__P__-fab[data-edge-tab]{left:0;right:auto;border-radius:0 12px 12px 0;box-shadow:6px 0 18px -8px #0000004d}.__P__-fab[data-edge-tab][data-leaving]{position:fixed;top:50%;bottom:auto;animation:__P__-edge-tab-out var(--__P__-dur-quick) var(--__P__-ease) forwards}@keyframes __P__-edge-tab-in{0%{opacity:0;transform:translateY(-50%) scale(.9)}to{opacity:1;transform:translateY(-50%) scale(1)}}@keyframes __P__-edge-tab-out{0%{opacity:1;transform:translateY(-50%) scale(1)}to{opacity:0;transform:translateY(-50%) scale(.85)}}@keyframes __P__-drawer-in{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes __P__-drawer-in-left{0%{transform:translate(-100%)}to{transform:translate(0)}}@media(prefers-reduced-motion:reduce){:host([data-mode="drawer"]) .__P__-panel,.__P__-fab[data-edge-tab]{animation:none}}.__P__-header{display:flex;align-items:center;gap:var(--__P__-space-2);padding:10px 12px;border-bottom:1px solid var(--__P__-border);background:var(--__P__-bg)}.__P__-header h1{font-size:14px;font-weight:600;flex:1;letter-spacing:-.01em}.__P__-header-actions{margin-left:auto;display:flex;align-items:center;gap:var(--__P__-space-1);flex-shrink:0}.__P__-agent{flex:1;display:inline-flex;align-items:center;gap:10px;min-width:0}.__P__-agent-avatar{position:relative;width:32px;height:32px;border-radius:999px;background:var(--__P__-bg-elevated);color:var(--__P__-fg-muted);display:inline-flex;align-items:center;justify-content:center;font-weight:700;font-size:var(--__P__-text-xs);overflow:hidden;flex-shrink:0}.__P__-agent-avatar img{width:100%;height:100%;object-fit:cover}.__P__-agent-avatar:after{content:"";position:absolute;right:-1px;bottom:-1px;width:10px;height:10px;border-radius:999px;border:2px solid var(--__P__-bg);background:var(--__P__-neutral)}.__P__-agent-avatar[data-status=online]:after{background:var(--__P__-success)}.__P__-agent-avatar[data-status=away]:after{background:var(--__P__-warning)}.__P__-agent-avatar[data-status=offline]:after{background:var(--__P__-neutral)}.__P__-agent-meta{display:flex;flex-direction:column;line-height:1.15;min-width:0}.__P__-agent-meta strong{font-size:14px;font-weight:600;letter-spacing:-.01em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-agent-meta span{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-suggestions{display:flex;flex-wrap:nowrap;gap:var(--__P__-space-2);padding:6px 14px 10px;overflow-x:auto;overflow-y:hidden;scroll-behavior:smooth;scroll-snap-type:x proximity;scrollbar-width:none;-ms-overflow-style:none;min-width:0}.__P__-suggestions::-webkit-scrollbar{display:none}.__P__-suggestions:before,.__P__-suggestions:after{content:"";flex:1 1 0;min-width:0}.__P__-suggestion{flex:0 0 auto;scroll-snap-align:center;padding:7px 14px;border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);color:var(--__P__-fg);font-size:var(--__P__-text-sm);font-weight:500;white-space:nowrap;transition:background var(--__P__-dur-quick) var(--__P__-ease),border-color var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease)}.__P__-suggestion:hover{border-color:var(--__P__-accent);color:var(--__P__-accent);transform:translateY(-1px)}.__P__-suggestion:focus-visible{outline:2px solid var(--__P__-accent);outline-offset:2px;border-color:var(--__P__-accent)}.__P__-suggestion:active{transform:translateY(0)}.__P__-icon-btn{width:32px;height:32px;border-radius:999px;display:inline-flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted);transition:background var(--__P__-dur-quick) var(--__P__-ease),color var(--__P__-dur-quick) var(--__P__-ease)}.__P__-icon-btn:hover{background:var(--__P__-bg-elevated);color:var(--__P__-fg)}.__P__-icon-btn:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-icon-btn:active{background:var(--__P__-border)}.__P__-icon-btn:disabled{opacity:.45;cursor:not-allowed}.__P__-icon-btn:before{content:"";position:absolute;inset:-6px}.__P__-icon-btn{position:relative}.__P__-icon-btn svg{width:18px;height:18px}.__P__-icon-btn[data-recording=true]{color:var(--__P__-accent);background:color-mix(in srgb,var(--__P__-accent) 12%,transparent);animation:__P__-pulse 1.2s var(--__P__-ease) infinite}@keyframes __P__-pulse{0%,to{box-shadow:0 0 color-mix(in srgb,var(--__P__-accent) 40%,transparent)}50%{box-shadow:0 0 0 6px color-mix(in srgb,var(--__P__-accent) 0%,transparent)}}.__P__-list-wrap{position:relative;flex:1;min-height:0;display:flex;flex-direction:column}.__P__-jump{position:absolute;right:14px;bottom:14px;z-index:2;display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:999px;border:1px solid var(--__P__-border);background:var(--__P__-bg-elevated);color:var(--__P__-fg);box-shadow:var(--__P__-shadow-panel);cursor:pointer;opacity:.85;transition:opacity var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease);animation:__P__-bubble-in var(--__P__-dur-base) var(--__P__-ease)}.__P__-jump:hover{opacity:1}.__P__-jump:active{transform:translateY(1px)}.__P__-jump svg{width:18px;height:18px}.__P__-list{flex:1;min-height:0;overflow-y:auto;padding:var(--__P__-space-4);padding-bottom:var(--__P__-space-8);display:flex;flex-direction:column;gap:14px;scrollbar-width:thin;scrollbar-color:var(--__P__-border-strong) transparent;scrollbar-gutter:stable}.__P__-list::-webkit-scrollbar{width:8px}.__P__-list::-webkit-scrollbar-thumb{background:var(--__P__-border-strong);border-radius:8px}.__P__-date-divider{position:sticky;top:var(--__P__-space-2);z-index:2;display:flex;justify-content:center;margin:var(--__P__-space-1) 0;pointer-events:none}.__P__-date-pill{padding:3px 10px;border-radius:999px;font-size:11px;font-weight:600;color:var(--__P__-fg-muted);background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);box-shadow:var(--__P__-shadow-card);opacity:0;pointer-events:none;transition:opacity var(--__P__-dur-base) var(--__P__-ease)}.__P__-list[data-scrolling=true] .__P__-date-pill{opacity:1;pointer-events:auto}@media(prefers-reduced-motion:reduce){.__P__-date-pill{transition:none}}.__P__-bubble-row{display:flex}.__P__-bubble-row[data-role=user]{justify-content:flex-end}.__P__-bubble-row[data-role=assistant]{justify-content:flex-start}.__P__-bubble{max-width:100%;padding:var(--__P__-space-3) var(--__P__-space-4);border-radius:var(--__P__-radius);line-height:1.6;font-size:14px;word-wrap:break-word;overflow-wrap:anywhere;box-shadow:0 1px 2px #0000000a,0 1px 8px -4px #0000000f;animation:__P__-bubble-in var(--__P__-dur-base) var(--__P__-ease)}.__P__-bubble ::selection{background:color-mix(in srgb,var(--__P__-accent) 30%,transparent)}.__P__-bubble-row[data-role=user] .__P__-bubble ::selection{background:#fff6;color:var(--__P__-bubble-user-text)}@keyframes __P__-bubble-in{0%{opacity:0;transform:translateY(4px)}to{opacity:1;transform:none}}.__P__-bubble-row[data-role=user] .__P__-bubble{background:var(--__P__-bubble-user);color:var(--__P__-bubble-user-text);border-bottom-right-radius:5px}.__P__-bubble-row[data-role=assistant] .__P__-bubble{background:var(--__P__-bubble-assistant);color:var(--__P__-bubble-assistant-text);border-bottom-left-radius:5px}.__P__-bubble-col{display:flex;flex-direction:column;max-width:85%;min-width:0}.__P__-bubble-row[data-role=user] .__P__-bubble-col{align-items:flex-end}.__P__-bubble-row[data-role=assistant] .__P__-bubble-col{align-items:flex-start}.__P__-bubble-time{margin-top:3px;padding:0 4px;font-size:11px;line-height:1;color:var(--__P__-fg-muted);user-select:none}.__P__-md>*:first-child{margin-top:0}.__P__-md>*:last-child{margin-bottom:0}.__P__-md p{margin:10px 0}.__P__-md h1,.__P__-md h2,.__P__-md h3,.__P__-md h4,.__P__-md h5,.__P__-md h6{margin:18px 0 8px;line-height:1.3;letter-spacing:-.01em;font-weight:700}.__P__-md h1{font-size:1.4em}.__P__-md h2{font-size:1.22em}.__P__-md h3{font-size:1.08em}.__P__-md h4,.__P__-md h5,.__P__-md h6{font-size:1em}.__P__-md>h1:first-child,.__P__-md>h2:first-child,.__P__-md>h3:first-child,.__P__-md>h4:first-child,.__P__-md>h5:first-child,.__P__-md>h6:first-child{margin-top:0}.__P__-md ul,.__P__-md ol{padding-left:1.5em;margin:10px 0}.__P__-md ul{list-style:disc}.__P__-md ol{list-style:decimal}.__P__-md li{margin:6px 0;padding-left:2px}.__P__-md li::marker{color:var(--__P__-fg-muted)}.__P__-md li>p{margin:6px 0}.__P__-md li>ul,.__P__-md li>ol{margin:6px 0}.__P__-md strong,.__P__-md b{font-weight:650;letter-spacing:-.005em}.__P__-md em,.__P__-md i{font-style:italic}.__P__-md code{font-family:var(--__P__-font-mono);font-size:.86em;padding:1px 6px;border-radius:5px;background:color-mix(in srgb,var(--__P__-accent) 10%,transparent);color:var(--__P__-fg);border:1px solid color-mix(in srgb,var(--__P__-accent) 16%,transparent)}.__P__-md pre{font-family:var(--__P__-font-mono);font-size:12.5px;padding:12px 14px;border-radius:var(--__P__-radius-sm);background:#7f7f7f1f;overflow-x:auto;margin:var(--__P__-space-3) 0;line-height:1.5}.__P__-md pre code{padding:0;background:none}.__P__-md a{color:inherit;text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:2px}.__P__-md a:hover{text-decoration-thickness:2px}.__P__-md blockquote{margin:14px 0;padding:6px 14px;border-left:3px solid color-mix(in srgb,var(--__P__-accent) 50%,transparent);background:color-mix(in srgb,var(--__P__-accent) 5%,transparent);border-radius:0 var(--__P__-radius-sm) var(--__P__-radius-sm) 0;color:var(--__P__-fg-muted)}.__P__-md blockquote>:first-child{margin-top:0}.__P__-md blockquote>:last-child{margin-bottom:0}.__P__-md hr{border:0;height:1px;background:color-mix(in srgb,currentColor 18%,transparent);margin:var(--__P__-space-4) 0}.__P__-md table{border-collapse:collapse;margin:var(--__P__-space-3) 0;font-size:.95em;display:block;overflow-x:auto;max-width:100%;font-variant-numeric:tabular-nums}.__P__-md th,.__P__-md td{padding:6px 10px;border-bottom:1px solid color-mix(in srgb,currentColor 12%,transparent);text-align:left}.__P__-md th{font-weight:700;background:color-mix(in srgb,currentColor 6%,transparent)}.__P__-md h1+ul,.__P__-md h1+ol,.__P__-md h2+ul,.__P__-md h2+ol,.__P__-md h3+ul,.__P__-md h3+ol,.__P__-md h4+ul,.__P__-md h4+ol{margin-top:var(--__P__-space-1)}.__P__-loading{display:inline-flex;align-items:center;gap:var(--__P__-space-2);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm)}.__P__-loading-spinner{width:14px;height:14px;border-radius:999px;border:2px solid currentColor;border-top-color:transparent;animation:__P__-spin .8s linear infinite}@keyframes __P__-spin{to{transform:rotate(1turn)}}.__P__-typing{display:inline-flex;gap:var(--__P__-space-1);padding:var(--__P__-space-1) 0}.__P__-typing span{width:5px;height:5px;border-radius:999px;background:currentColor;opacity:.4;animation:__P__-blink 1.2s var(--__P__-ease) infinite}.__P__-typing span:nth-child(2){animation-delay:.2s}.__P__-typing span:nth-child(3){animation-delay:.4s}@keyframes __P__-blink{0%,80%,to{opacity:.3;transform:translateY(0)}40%{opacity:1;transform:translateY(-2px)}}.__P__-reasoning{margin:var(--__P__-space-1) 0 var(--__P__-space-2);padding-left:var(--__P__-space-3);border-left:2px solid var(--__P__-border-strong)}.__P__-reasoning-summary{display:inline-flex;align-items:center;gap:var(--__P__-space-1);cursor:pointer;list-style:none;user-select:none;color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600}.__P__-reasoning-summary::-webkit-details-marker{display:none}.__P__-reasoning-summary:before{content:"";width:5px;height:5px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(-45deg);opacity:.7;transition:transform var(--__P__-dur-quick) var(--__P__-ease)}.__P__-reasoning[open] .__P__-reasoning-summary:before{transform:rotate(45deg)}.__P__-reasoning[data-active=true] .__P__-reasoning-label{animation:__P__-reasoning-pulse 1.4s var(--__P__-ease) infinite}@keyframes __P__-reasoning-pulse{0%,to{opacity:.5}50%{opacity:1}}@media(prefers-reduced-motion:reduce){.__P__-reasoning[data-active=true] .__P__-reasoning-label{animation:none}}.__P__-reasoning-body{margin-top:var(--__P__-space-1);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm)}.__P__-reasoning-body>:first-child{margin-top:0}.__P__-reasoning-body>:last-child{margin-bottom:0}.__P__-tool-chip{display:inline-flex;align-items:center;gap:6px;padding:var(--__P__-space-1) var(--__P__-space-2);margin-top:6px;border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs)}.__P__-composer{border-top:1px solid var(--__P__-border);padding:10px 12px;background:var(--__P__-bg);display:flex;flex-direction:column;gap:var(--__P__-space-2)}.__P__-composer-row{display:flex;align-items:flex-end;gap:6px}.__P__-textarea{flex:1;height:40px;max-height:160px;padding:10px 12px;border-radius:var(--__P__-radius);background:var(--__P__-bg-elevated);border:1px solid transparent;font-size:14px;line-height:1.4;transition:height var(--__P__-dur-quick) var(--__P__-ease),border-color var(--__P__-dur-quick) var(--__P__-ease),box-shadow var(--__P__-dur-quick) var(--__P__-ease)}.__P__-textarea:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:1px;border-color:var(--__P__-focus)}@media(pointer:coarse){.__P__-textarea,.__P__-home-search-input{font-size:16px}.__P__-textarea{height:44px}}.__P__-send{width:40px;height:40px;display:inline-flex;align-items:center;justify-content:center;border:1px solid transparent;transition:opacity var(--__P__-dur-quick) var(--__P__-ease),transform var(--__P__-dur-quick) var(--__P__-ease),background var(--__P__-dur-quick) var(--__P__-ease)}.__P__-send[data-shape=circle]{border-radius:999px}.__P__-send[data-shape=square]{border-radius:var(--__P__-radius-sm)}.__P__-send[data-shape=pill]{width:auto;padding:0 18px;border-radius:999px}.__P__-send[data-variant=filled]{background:var(--__P__-accent);color:var(--__P__-accent-text)}.__P__-send[data-variant=outline]{background:transparent;color:var(--__P__-accent);border-color:var(--__P__-accent)}.__P__-send[data-variant=outline]:not(:disabled):hover{background:color-mix(in srgb,var(--__P__-accent) 10%,transparent)}.__P__-send[data-variant=ghost]{background:transparent;color:var(--__P__-accent)}.__P__-send[data-variant=ghost]:not(:disabled):hover{background:color-mix(in srgb,var(--__P__-accent) 8%,transparent)}.__P__-send:disabled{opacity:.4;cursor:not-allowed}.__P__-send:not(:disabled):hover{transform:translateY(-1px)}.__P__-send:not(:disabled):active{transform:translateY(0)}.__P__-send:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-send svg{width:18px;height:18px}.__P__-composer-actions{display:flex;gap:var(--__P__-space-1);flex-wrap:wrap}.__P__-attachments{display:flex;flex-wrap:wrap;gap:6px}.__P__-attachment-chip{display:inline-flex;align-items:center;gap:6px;padding:var(--__P__-space-1) var(--__P__-space-2) var(--__P__-space-1) var(--__P__-space-1);border-radius:999px;background:var(--__P__-bg-elevated);border:1px solid var(--__P__-border);font-size:var(--__P__-text-xs);max-width:200px}.__P__-attachment-thumb{width:24px;height:24px;border-radius:999px;object-fit:cover;background:var(--__P__-border)}.__P__-attachment-name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.__P__-attachment-remove{width:18px;height:18px;border-radius:999px;display:inline-flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted)}.__P__-attachment-remove:hover{background:var(--__P__-border);color:var(--__P__-fg)}.__P__-dropzone{position:absolute;inset:8px;border:2px dashed var(--__P__-accent);border-radius:var(--__P__-radius);background:color-mix(in srgb,var(--__P__-accent) 8%,transparent);display:flex;align-items:center;justify-content:center;font-weight:600;color:var(--__P__-accent);pointer-events:none;z-index:10;animation:__P__-fade-in var(--__P__-dur-quick) var(--__P__-ease)}@keyframes __P__-fade-in{0%{opacity:0}to{opacity:1}}.__P__-error{margin-top:var(--__P__-space-1);padding:8px 10px;border-radius:var(--__P__-radius-sm);background:var(--__P__-danger-bg);color:var(--__P__-danger-text);font-size:var(--__P__-text-sm);display:flex;align-items:center;gap:var(--__P__-space-2)}.__P__-error button{color:inherit;text-decoration:underline;font-size:var(--__P__-text-sm)}.__P__-history{flex:1;overflow-y:auto;padding:var(--__P__-space-2) var(--__P__-space-1) var(--__P__-space-3)}.__P__-history-footer{flex:none;padding:var(--__P__-space-2) var(--__P__-space-3) var(--__P__-space-3);border-top:1px solid var(--__P__-border);background:var(--__P__-surface)}.__P__-history-new{width:100%;display:flex;align-items:center;justify-content:center;gap:var(--__P__-space-2);padding:var(--__P__-space-2) var(--__P__-space-3);border:none;border-radius:var(--__P__-radius-md);background:var(--__P__-accent);color:var(--__P__-on-accent);cursor:pointer;font-size:var(--__P__-text-sm);font-weight:600;transition:filter var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-history-new svg{width:16px;height:16px}.__P__-history-new:hover{filter:brightness(1.08)}.__P__-history-new:active{transform:translateY(1px)}.__P__-history-new:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-history-empty{flex:1;display:flex;align-items:center;justify-content:center;padding:40px 16px;color:var(--__P__-fg-muted);font-size:14px;text-align:center}.__P__-history-group{display:flex;flex-direction:column;padding:0 var(--__P__-space-2)}.__P__-history-heading{font-size:var(--__P__-text-xs);font-weight:600;color:var(--__P__-fg-muted);padding:12px 8px 6px;text-transform:uppercase;letter-spacing:.04em}.__P__-history-item{all:unset;display:flex;flex-direction:column;gap:3px;padding:10px 12px;border-radius:var(--__P__-radius-md);cursor:pointer;transition:background var(--__P__-dur-base) var(--__P__-ease)}.__P__-history-item:hover{background:var(--__P__-bg-elevated)}.__P__-history-item:focus-visible{background:var(--__P__-bg-elevated);outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-history-title{font-size:14px;font-weight:500;color:var(--__P__-fg);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-history-preview{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-history-item[data-closed=true] .__P__-history-title:after{content:"\\2022";margin-left:var(--__P__-space-2);opacity:.5}.__P__-list-loading{margin:auto;padding:var(--__P__-space-6) var(--__P__-space-4);color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);text-align:center}.__P__-readonly-banner{display:flex;flex-direction:column;align-items:center;gap:10px;padding:14px 12px;margin:0 var(--__P__-space-3) var(--__P__-space-3);border-radius:var(--__P__-radius-md);background:var(--__P__-bg-elevated);color:var(--__P__-fg-muted);text-align:center;font-size:var(--__P__-text-sm)}.__P__-readonly-label{line-height:1.4}.__P__-readonly-cta{appearance:none;border:0;cursor:pointer;padding:var(--__P__-space-2) var(--__P__-space-4);border-radius:999px;background:var(--__P__-accent);color:var(--__P__-accent-text, #fff);font:inherit;font-weight:600;font-size:var(--__P__-text-sm);transition:filter var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-readonly-cta:hover,.__P__-readonly-cta:focus-visible{filter:brightness(1.1)}.__P__-readonly-cta:focus-visible{outline:2px solid var(--__P__-accent);outline-offset:2px}.__P__-composer-footer{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:10px 16px;margin:0 var(--__P__-space-3);border-top:1px solid var(--__P__-border);text-align:center;font-size:11px;line-height:1.4;color:var(--__P__-fg-muted)}.__P__-disclaimer{max-width:320px;margin:0 auto;opacity:.9;letter-spacing:.01em}.__P__-poweredby{display:inline-flex;align-items:center;justify-content:center;gap:6px;color:inherit;text-decoration:none;opacity:.7;transition:opacity var(--__P__-dur-base) var(--__P__-ease);font-size:11px;letter-spacing:.02em}.__P__-poweredby:hover{opacity:1}.__P__-poweredby-logo{height:12px;width:auto;display:inline-block;vertical-align:middle}.__P__-poweredby-bar{flex:none;display:flex;align-items:center;justify-content:center;padding:6px 16px;border-top:1px solid var(--__P__-border);background:var(--__P__-bg-elevated)}.__P__-menu-wrap{position:relative;display:inline-flex}.__P__-menu{position:absolute;top:100%;right:0;margin-top:6px;min-width:200px;padding:6px;background:var(--__P__-bg);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);box-shadow:var(--__P__-shadow-panel);z-index:10;display:flex;flex-direction:column;gap:2px;animation:__P__-menu-in var(--__P__-dur-base) var(--__P__-ease)}@media(prefers-reduced-motion:reduce){.__P__-menu{animation:none}}@keyframes __P__-menu-in{0%{opacity:0;transform:translateY(-4px) scale(.98);transform-origin:top right}to{opacity:1;transform:none}}.__P__-menu-item{all:unset;display:flex;align-items:center;gap:10px;padding:8px 10px;font-size:var(--__P__-text-sm);color:var(--__P__-fg);border-radius:var(--__P__-radius-sm);cursor:pointer;user-select:none}.__P__-menu-item:hover{background:var(--__P__-bg-elevated)}.__P__-menu-item:focus-visible{background:var(--__P__-bg-elevated);outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-menu-item[disabled]{opacity:.45;cursor:not-allowed}.__P__-menu-icon{display:inline-flex;width:16px;height:16px;color:var(--__P__-fg-muted)}.__P__-menu-icon svg{width:16px;height:16px}.__P__-menu-label{flex:1}.__P__-menu-check{display:inline-flex;color:var(--__P__-accent)}.__P__-menu-check svg{width:14px;height:14px}.__P__-resize-grip{position:absolute;width:18px;height:18px;display:flex;align-items:center;justify-content:center;color:var(--__P__-fg-muted);opacity:.45;transition:opacity var(--__P__-dur-base) var(--__P__-ease);z-index:2;touch-action:none;user-select:none}.__P__-resize-grip:hover,.__P__-resize-grip:focus-visible{opacity:1}.__P__-resize-grip svg{width:10px;height:10px}.__P__-resize-grip--bottom-left{bottom:2px;left:2px;cursor:nesw-resize;transform:scaleX(-1)}.__P__-resize-grip--bottom-right{bottom:2px;right:2px;cursor:nwse-resize}.__P__-resize-grip--top-left{top:2px;left:2px;cursor:nwse-resize;transform:rotate(180deg)}.__P__-resize-grip--top-right{top:2px;right:2px;cursor:nesw-resize;transform:scaleY(-1)}:host(:not([data-mode="open"])) .__P__-resize-grip{display:none}.__P__-messenger{display:flex;flex-direction:column;overflow:hidden}.__P__-messenger-body{flex:1;min-height:0;display:flex;flex-direction:column;overflow:hidden}.__P__-module{display:flex;flex-direction:column;height:100%;min-height:0}.__P__-module-scroll{flex:1;min-height:0;overflow-y:auto;padding:var(--__P__-space-3);display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-home{background:radial-gradient(125% 65% at 88% 0%,color-mix(in srgb,#fff 16%,transparent),transparent 55%),linear-gradient(180deg,var(--__P__-accent) 0%,var(--__P__-accent) 22%,color-mix(in srgb,var(--__P__-accent) 28%,var(--__P__-surface)) 44%,var(--__P__-surface) 70%);border-radius:var(--__P__-radius-lg) var(--__P__-radius-lg) 0 0}.__P__-home-scroll{flex:1;min-height:0;overflow-y:auto;display:flex;flex-direction:column;background:transparent}.__P__-home-cards{display:flex;flex-direction:column;gap:var(--__P__-space-3);padding:4px 14px 16px}.__P__-module-pad{padding:var(--__P__-space-3) var(--__P__-space-3) 0}.__P__-module-empty{display:flex;flex-direction:column;align-items:center;gap:var(--__P__-space-3);padding:var(--__P__-space-8) var(--__P__-space-4);text-align:center;color:var(--__P__-fg-muted);font-size:var(--__P__-text-base)}.__P__-module-retry{padding:var(--__P__-space-2) var(--__P__-space-4);border:1px solid var(--__P__-border-strong);border-radius:var(--__P__-radius-sm);color:var(--__P__-fg);font-weight:600;cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out),border-color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-module-retry:hover{background:var(--__P__-hover);border-color:var(--__P__-accent)}.__P__-module-retry:active{background:var(--__P__-border)}.__P__-module-retry:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-help-list{flex:1;min-height:0;overflow-y:auto;padding-bottom:var(--__P__-space-3)}.__P__-help-group{display:flex;flex-direction:column}.__P__-help-section-title{position:sticky;top:0;z-index:1;margin:0;padding:var(--__P__-space-3) var(--__P__-space-5) var(--__P__-space-2);font-size:var(--__P__-text-xs);font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--__P__-fg-muted);background:var(--__P__-bg)}.__P__-help-card{margin:0 var(--__P__-space-3) var(--__P__-space-3);background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);overflow:hidden}.__P__-help-card .__P__-list-row{border-bottom:0;border-radius:0}.__P__-help-card .__P__-list-row+.__P__-list-row{border-top:1px solid var(--__P__-border)}.__P__-help-card .__P__-list-row:hover{background:var(--__P__-hover)}.__P__-module-cta{padding:var(--__P__-space-3);border-top:1px solid var(--__P__-border)}.__P__-tabbar{display:flex;border-top:1px solid var(--__P__-border);background:var(--__P__-bg-elevated);flex-shrink:0}.__P__-tab{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--__P__-space-1);min-height:48px;padding:var(--__P__-space-2) var(--__P__-space-1);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600;transition:color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-tab:hover{color:var(--__P__-fg)}.__P__-tab[aria-selected=true]{color:var(--__P__-accent)}.__P__-tab:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-tab:active{background:var(--__P__-hover)}.__P__-tab-icon{position:relative;display:inline-flex}.__P__-tab-icon svg{width:22px;height:22px}.__P__-tab-badge{position:absolute;top:-4px;left:calc(50% + 6px);min-width:16px;height:16px;padding:0 4px;display:inline-flex;align-items:center;justify-content:center;border-radius:999px;background:var(--__P__-accent);color:var(--__P__-on-accent);font-size:10px;font-weight:600;line-height:1}.__P__-home-hero{flex-shrink:0;padding:var(--__P__-space-5) var(--__P__-space-5) var(--__P__-space-3);color:var(--__P__-on-accent);--__P__-focus: var(--__P__-on-accent)}.__P__-home-hero-top{display:flex;align-items:center;justify-content:space-between;gap:var(--__P__-space-3);min-height:32px}.__P__-home-brand{font-size:14px;font-weight:600;letter-spacing:.01em;color:color-mix(in srgb,#fff 82%,transparent);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}.__P__-home-brand-spacer{flex:1}.__P__-home-hero-actions{display:flex;align-items:center;gap:var(--__P__-space-2);flex-shrink:0}.__P__-home-hero-actions .__P__-icon-btn{color:#fff}.__P__-home-greeting{margin:28px 0 0;font-family:var(--__P__-font-display);font-size:var(--__P__-text-2xl);font-weight:800;line-height:1.18;letter-spacing:-.01em;overflow-wrap:anywhere}.__P__-home-lead{margin:2px 0 0;font-family:var(--__P__-font-display);font-size:var(--__P__-text-2xl);font-weight:800;line-height:1.18;letter-spacing:-.01em;color:color-mix(in srgb,var(--__P__-on-accent) 88%,transparent);overflow-wrap:anywhere}.__P__-home-avatars{display:flex}.__P__-home-avatar{width:30px;height:30px;border-radius:999px;overflow:hidden;margin-left:-10px;border:2px solid color-mix(in srgb,#fff 92%,transparent);box-shadow:0 1px 3px #0000002e;background:var(--__P__-surface);display:inline-flex;align-items:center;justify-content:center;font-size:var(--__P__-text-xs);font-weight:700;color:var(--__P__-fg)}.__P__-home-avatar:first-child{margin-left:0}.__P__-home-avatar img{width:100%;height:100%;object-fit:cover}.__P__-home-content{background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);box-shadow:var(--__P__-shadow-card);overflow:hidden}.__P__-home-content-title{padding:var(--__P__-space-4) var(--__P__-space-4) var(--__P__-space-3);font-size:var(--__P__-text-sm);font-weight:700}.__P__-home-content-list{display:flex;flex-direction:column;padding:0 var(--__P__-space-2) var(--__P__-space-2)}.__P__-home-content-list .__P__-list-row+.__P__-list-row{border-top:1px solid var(--__P__-border)}.__P__-home-card{display:block;width:100%;text-align:left;background:var(--__P__-surface);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);padding:var(--__P__-space-4);box-shadow:var(--__P__-shadow-card)}.__P__-home-card[data-interactive=true]{cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-home-card[data-interactive=true]:hover{background:var(--__P__-bg-elevated)}.__P__-home-card[data-interactive=true]:active{transform:translateY(1px)}.__P__-home-card[data-interactive=true]:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-home-recent-row{display:flex;align-items:center;gap:var(--__P__-space-3)}.__P__-home-recent-avatar{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;flex-shrink:0;border-radius:999px;background:color-mix(in oklch,var(--__P__-accent) 14%,transparent);color:var(--__P__-accent)}.__P__-home-recent-avatar svg{width:20px;height:20px}.__P__-home-recent-body{display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}.__P__-home-recent-title{font-weight:600;font-size:14px}.__P__-home-recent-preview{color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.__P__-home-recent-at{color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);flex-shrink:0}.__P__-home-recent-dot{width:8px;height:8px;border-radius:999px;background:var(--__P__-accent);flex-shrink:0}.__P__-home-recent-row[data-unread=true] .__P__-home-recent-title{font-weight:700}.__P__-home-status{display:flex;align-items:center;gap:var(--__P__-space-3)}.__P__-home-status-icon svg{width:22px;height:22px;color:var(--__P__-success)}.__P__-home-status[data-level=degraded] .__P__-home-status-icon svg{color:var(--__P__-warning)}.__P__-home-status[data-level=down] .__P__-home-status-icon svg{color:var(--__P__-danger)}.__P__-home-status-text{font-weight:600;font-size:14px}.__P__-home-search{display:flex;align-items:center;gap:var(--__P__-space-2);width:100%;padding:var(--__P__-space-3) var(--__P__-space-4);border-radius:var(--__P__-radius);border:1px solid var(--__P__-border);background:var(--__P__-surface);text-align:left}.__P__-home-search[data-input=true]{background:var(--__P__-bg-elevated)}.__P__-home-search:hover{border-color:var(--__P__-border-strong)}.__P__-home-search:focus-visible,.__P__-home-search:focus-within{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-home-search-text{flex:1;color:var(--__P__-fg-muted);font-size:14px}.__P__-home-search-input{flex:1;border:0;background:transparent;font-size:14px;color:var(--__P__-fg);outline:none}.__P__-home-search-icon svg{width:18px;height:18px;color:var(--__P__-accent)}.__P__-list-row{display:flex;align-items:center;gap:var(--__P__-space-3);width:100%;min-height:44px;text-align:left;padding:var(--__P__-space-3) var(--__P__-space-2);border-radius:var(--__P__-radius-sm)}.__P__-list-row:hover{background:var(--__P__-bg-elevated)}.__P__-list-row:active{background:var(--__P__-border)}.__P__-list-row:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:-2px}.__P__-list-row-body{display:flex;flex-direction:column;min-width:0;flex:1}.__P__-list-row-title{font-weight:600;font-size:var(--__P__-text-md);line-height:1.35}.__P__-list-row-sub{color:var(--__P__-fg-muted);font-size:var(--__P__-text-sm);margin-top:var(--__P__-space-1);line-height:1.45;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.__P__-list-row-chevron svg{width:18px;height:18px;color:var(--__P__-accent);flex-shrink:0}.__P__-back-header{display:flex;align-items:center;gap:var(--__P__-space-2);padding:10px 12px;border-bottom:1px solid var(--__P__-border);flex-shrink:0}.__P__-back-title{flex:1;text-align:center;font-size:var(--__P__-text-md);font-weight:700;margin:0;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.__P__-back-spacer{width:32px;height:1px}.__P__-content{display:flex;flex-direction:column;gap:14px;width:100%;max-width:68ch;margin:0 auto}.__P__-content-hero{width:100%;border-radius:var(--__P__-radius)}.__P__-content-subtitle{color:var(--__P__-fg-muted);margin:0}.__P__-content-frame{flex:1;min-height:0;width:100%;border:0;background:#fff}.__P__-news-list{display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-news-card{display:block;width:100%;text-align:left;border:1px solid var(--__P__-border);border-radius:var(--__P__-radius);overflow:hidden;background:var(--__P__-surface)}.__P__-news-card{transition:background var(--__P__-dur-quick) var(--__P__-ease-out),transform var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-news-card:hover{background:var(--__P__-bg-elevated)}.__P__-news-card:active{transform:translateY(1px)}.__P__-news-card:focus-visible{outline:2px solid var(--__P__-focus);outline-offset:2px}.__P__-news-hero{width:100%;display:block}.__P__-news-body{display:flex;flex-direction:column;gap:6px;padding:14px 16px}.__P__-news-tags{display:flex;gap:6px;flex-wrap:wrap}.__P__-news-tag{font-size:var(--__P__-text-xs);font-weight:600;color:var(--__P__-accent);background:color-mix(in srgb,var(--__P__-accent) 12%,transparent);padding:2px 8px;border-radius:999px}.__P__-news-title{font-weight:700;font-size:var(--__P__-text-md)}.__P__-news-summary{color:var(--__P__-fg-muted);font-size:14px;display:-webkit-box;-webkit-line-clamp:2;line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.__P__-modules-empty{display:flex;align-items:center;justify-content:center;position:relative}.__P__-modules-empty-close{position:absolute;top:12px;right:12px}.__P__-modules-empty-text{color:var(--__P__-fg-muted);font-size:var(--__P__-text-base)}.__P__-form{display:flex;flex-direction:column;gap:var(--__P__-space-3)}.__P__-field{display:flex;flex-direction:column;gap:4px}.__P__-field-label{font-size:var(--__P__-text-sm);font-weight:600;color:var(--__P__-fg)}.__P__-field-req{color:var(--__P__-danger)}.__P__-field-input{width:100%;box-sizing:border-box;padding:var(--__P__-space-2) var(--__P__-space-3);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:var(--__P__-bg);color:var(--__P__-fg);font:inherit;font-size:var(--__P__-text-sm);resize:vertical;transition:border-color var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-field-input:focus-visible{outline:none;border-color:var(--__P__-accent)}.__P__-field[data-invalid=true] .__P__-field-input{border-color:var(--__P__-danger)}.__P__-field-hint{font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted)}.__P__-field-error{font-size:var(--__P__-text-xs);color:var(--__P__-danger)}.__P__-field-choices{display:flex;flex-direction:column;gap:6px}.__P__-choice{display:flex;align-items:flex-start;gap:8px;font-size:var(--__P__-text-sm);color:var(--__P__-fg);cursor:pointer}.__P__-choice input{margin-top:2px;accent-color:var(--__P__-accent)}.__P__-form-actions{display:flex;justify-content:flex-end;gap:var(--__P__-space-2);margin-top:2px}.__P__-form-submit,.__P__-tool-approve{padding:var(--__P__-space-2) var(--__P__-space-4);border:none;border-radius:var(--__P__-radius-md);background:var(--__P__-accent);color:var(--__P__-accent-text, #fff);font:inherit;font-weight:600;font-size:var(--__P__-text-sm);cursor:pointer;transition:filter var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-form-submit:hover:not(:disabled),.__P__-tool-approve:hover:not(:disabled){filter:brightness(1.06)}.__P__-form-submit:disabled{opacity:.6;cursor:default}.__P__-form-skip,.__P__-tool-reject{padding:var(--__P__-space-2) var(--__P__-space-4);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:transparent;color:var(--__P__-fg-muted);font:inherit;font-size:var(--__P__-text-sm);cursor:pointer;transition:background var(--__P__-dur-quick) var(--__P__-ease-out)}.__P__-form-skip:hover:not(:disabled),.__P__-tool-reject:hover:not(:disabled){background:var(--__P__-bg-elevated)}.__P__-form-gate{display:flex;flex-direction:column;gap:var(--__P__-space-2);padding:var(--__P__-space-3) var(--__P__-space-4) var(--__P__-space-4);border-top:1px solid var(--__P__-border);max-height:60%;overflow-y:auto}.__P__-form-gate-title{margin:0;font-size:var(--__P__-text-base);font-weight:700;color:var(--__P__-fg)}.__P__-form-gate-desc{margin:0 0 var(--__P__-space-1);font-size:var(--__P__-text-sm);color:var(--__P__-fg-muted)}.__P__-tool-ask-input,.__P__-tool-approval{display:flex;flex-direction:column;gap:var(--__P__-space-2);margin-top:6px;padding:var(--__P__-space-3);border:1px solid var(--__P__-border);border-radius:var(--__P__-radius-md);background:var(--__P__-bg-elevated)}.__P__-tool-head{display:flex;align-items:center;flex-wrap:wrap;gap:8px}.__P__-tool-badge{padding:2px 8px;border-radius:999px;background:var(--__P__-warning, #f59e0b);color:#1a1206;font-size:var(--__P__-text-xs);font-weight:600}.__P__-tool-title{font-size:var(--__P__-text-sm);color:var(--__P__-fg)}.__P__-tool-question{margin:0;font-size:var(--__P__-text-sm);font-weight:600;color:var(--__P__-fg)}.__P__-tool-desc{margin:0;font-size:var(--__P__-text-sm);color:var(--__P__-fg-muted)}.__P__-tool-args{margin:0;padding:var(--__P__-space-2);max-height:160px;overflow:auto;border-radius:var(--__P__-radius-sm);background:var(--__P__-bg);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);white-space:pre-wrap;word-break:break-word}.__P__-tool-stale-note{margin:0;font-size:var(--__P__-text-xs);color:var(--__P__-fg-muted)}.__P__-tool-decided{flex-direction:row;align-items:center;flex-wrap:wrap;gap:8px}.__P__-tool-decided-label{padding:2px 8px;border-radius:999px;background:var(--__P__-bg);border:1px solid var(--__P__-border);color:var(--__P__-fg-muted);font-size:var(--__P__-text-xs);font-weight:600}.__P__-tool-decided-label[data-approved=true]{color:var(--__P__-success, #16a34a);border-color:var(--__P__-success, #16a34a)}.__P__-tool-decided-label[data-approved=false]{color:var(--__P__-danger);border-color:var(--__P__-danger)}.__P__-tool-decided-value{font-size:var(--__P__-text-sm);color:var(--__P__-fg)}\n';
971
966
 
972
967
  // src/styles/standalone.css
973
968
  var standalone_default = ".__P__-standalone-page{margin:0;height:100vh;background:var(--__P__-bg, #fff);display:grid;place-items:stretch}\n";
@@ -1055,22 +1050,22 @@ function attachAdoptedSheet(shadow, doc) {
1055
1050
  }
1056
1051
  }
1057
1052
  function applyThemeOverrides(host, overrides) {
1058
- const p34 = BRAND.cssPrefix;
1059
- if (overrides.accent) host.style.setProperty(`--${p34}-accent`, overrides.accent);
1060
- if (overrides.accentText) host.style.setProperty(`--${p34}-accent-text`, overrides.accentText);
1061
- if (overrides.radius) host.style.setProperty(`--${p34}-radius`, overrides.radius);
1062
- if (overrides.fontFamily) host.style.setProperty(`--${p34}-font`, overrides.fontFamily);
1053
+ const p33 = BRAND.cssPrefix;
1054
+ if (overrides.accent) host.style.setProperty(`--${p33}-accent`, overrides.accent);
1055
+ if (overrides.accentText) host.style.setProperty(`--${p33}-accent-text`, overrides.accentText);
1056
+ if (overrides.radius) host.style.setProperty(`--${p33}-radius`, overrides.radius);
1057
+ if (overrides.fontFamily) host.style.setProperty(`--${p33}-font`, overrides.fontFamily);
1063
1058
  }
1064
1059
  function applyThemeMode(host, mode) {
1065
1060
  host.dataset.theme = mode;
1066
1061
  }
1067
1062
  function applySize(host, size) {
1068
- const p34 = BRAND.cssPrefix;
1069
- if (size.width !== void 0) host.style.setProperty(`--${p34}-panel-w`, size.width);
1070
- if (size.height !== void 0) host.style.setProperty(`--${p34}-panel-h`, size.height);
1071
- if (size.expanded?.width !== void 0) host.style.setProperty(`--${p34}-expanded-w`, size.expanded.width);
1072
- if (size.expanded?.height !== void 0) host.style.setProperty(`--${p34}-expanded-h`, size.expanded.height);
1073
- if (size.inset !== void 0) host.style.setProperty(`--${p34}-panel-inset`, size.inset);
1063
+ const p33 = BRAND.cssPrefix;
1064
+ if (size.width !== void 0) host.style.setProperty(`--${p33}-panel-w`, size.width);
1065
+ if (size.height !== void 0) host.style.setProperty(`--${p33}-panel-h`, size.height);
1066
+ if (size.expanded?.width !== void 0) host.style.setProperty(`--${p33}-expanded-w`, size.expanded.width);
1067
+ if (size.expanded?.height !== void 0) host.style.setProperty(`--${p33}-expanded-h`, size.expanded.height);
1068
+ if (size.inset !== void 0) host.style.setProperty(`--${p33}-panel-inset`, size.inset);
1074
1069
  }
1075
1070
  function applyPosition(host, pos) {
1076
1071
  host.dataset.position = pos;
@@ -1241,11 +1236,11 @@ function toBase64Url(json) {
1241
1236
  var nonEmpty = (ctx) => ctx && Object.keys(ctx).length > 0 ? ctx : void 0;
1242
1237
  function encodeContext(user, page) {
1243
1238
  const u = nonEmpty(user);
1244
- const p34 = nonEmpty(page);
1245
- if (!u && !p34) return void 0;
1239
+ const p33 = nonEmpty(page);
1240
+ if (!u && !p33) return void 0;
1246
1241
  const envelope = {};
1247
1242
  if (u) envelope.user = u;
1248
- if (p34) envelope.page = p34;
1243
+ if (p33) envelope.page = p33;
1249
1244
  return toBase64Url(JSON.stringify(envelope));
1250
1245
  }
1251
1246
 
@@ -1315,8 +1310,8 @@ function buildSendMessageRequest(params) {
1315
1310
  if (Object.keys(data).length > 0) body.data = data;
1316
1311
  return body;
1317
1312
  }
1318
- function isResolvedToolPart(p34) {
1319
- return p34.state === "output" || p34.state === "error" || p34.approval?.approved !== void 0;
1313
+ function isResolvedToolPart(p33) {
1314
+ return p33.state === "output" || p33.state === "error" || p33.approval?.approved !== void 0;
1320
1315
  }
1321
1316
  function normalizeToolRef(ref) {
1322
1317
  if (typeof ref === "string") return ref ? { code: ref } : null;
@@ -1324,24 +1319,24 @@ function normalizeToolRef(ref) {
1324
1319
  }
1325
1320
  function messageToWireParts(m) {
1326
1321
  const out = [];
1327
- for (const p34 of m.parts) {
1328
- if (p34.kind === "text" && p34.text) {
1329
- out.push({ text: p34.text, type: "text" });
1322
+ for (const p33 of m.parts) {
1323
+ if (p33.kind === "text" && p33.text) {
1324
+ out.push({ text: p33.text, type: "text" });
1330
1325
  }
1331
- if (p34.kind === "file" && p34.url) {
1332
- out.push({ mediaType: p34.mediaType, type: "file", url: p34.url });
1326
+ if (p33.kind === "file" && p33.url) {
1327
+ out.push({ mediaType: p33.mediaType, type: "file", url: p33.url });
1333
1328
  }
1334
- if (p34.kind === "tool" && isResolvedToolPart(p34)) {
1329
+ if (p33.kind === "tool" && isResolvedToolPart(p33)) {
1335
1330
  const part = {
1336
1331
  type: "tool",
1337
- toolCallId: p34.toolCallId,
1338
- toolName: p34.toolName,
1339
- state: p34.state
1332
+ toolCallId: p33.toolCallId,
1333
+ toolName: p33.toolName,
1334
+ state: p33.state
1340
1335
  };
1341
- if (p34.input !== void 0) part.input = p34.input;
1342
- if (p34.output !== void 0) part.output = p34.output;
1343
- if (p34.error !== void 0) part.errorText = p34.error;
1344
- if (p34.approval && p34.approval.approved !== void 0) part.approval = p34.approval;
1336
+ if (p33.input !== void 0) part.input = p33.input;
1337
+ if (p33.output !== void 0) part.output = p33.output;
1338
+ if (p33.error !== void 0) part.errorText = p33.error;
1339
+ if (p33.approval && p33.approval.approved !== void 0) part.approval = p33.approval;
1345
1340
  out.push(part);
1346
1341
  }
1347
1342
  }
@@ -1934,7 +1929,7 @@ function fromWireMessage(w) {
1934
1929
  };
1935
1930
  }
1936
1931
  return null;
1937
- }).filter((p34) => p34 !== null);
1932
+ }).filter((p33) => p33 !== null);
1938
1933
  return {
1939
1934
  id: w.id,
1940
1935
  role: w.role,
@@ -1964,43 +1959,43 @@ function assistantText(m) {
1964
1959
  }
1965
1960
  return out;
1966
1961
  }
1967
- function partToReactive(p34) {
1968
- if (p34.kind === "text" || p34.kind === "reasoning") {
1969
- return { kind: p34.kind, id: p34.id, textSig: signal(p34.text), doneSig: signal(p34.done) };
1962
+ function partToReactive(p33) {
1963
+ if (p33.kind === "text" || p33.kind === "reasoning") {
1964
+ return { kind: p33.kind, id: p33.id, textSig: signal(p33.text), doneSig: signal(p33.done) };
1970
1965
  }
1971
- if (p34.kind === "tool") {
1966
+ if (p33.kind === "tool") {
1972
1967
  return {
1973
1968
  kind: "tool",
1974
- toolCallId: p34.toolCallId,
1975
- toolName: p34.toolName,
1976
- inputPartialSig: signal(p34.inputPartial),
1977
- inputSig: signal(p34.input),
1978
- outputSig: signal(p34.output),
1979
- errorSig: signal(p34.error),
1980
- stateSig: signal(p34.state),
1981
- approvalSig: signal(p34.approval)
1969
+ toolCallId: p33.toolCallId,
1970
+ toolName: p33.toolName,
1971
+ inputPartialSig: signal(p33.inputPartial),
1972
+ inputSig: signal(p33.input),
1973
+ outputSig: signal(p33.output),
1974
+ errorSig: signal(p33.error),
1975
+ stateSig: signal(p33.state),
1976
+ approvalSig: signal(p33.approval)
1982
1977
  };
1983
1978
  }
1984
- return p34;
1979
+ return p33;
1985
1980
  }
1986
- function partFromReactive(p34) {
1987
- if (p34.kind === "text" || p34.kind === "reasoning") {
1988
- return { kind: p34.kind, id: p34.id, text: p34.textSig.value, done: p34.doneSig.value };
1981
+ function partFromReactive(p33) {
1982
+ if (p33.kind === "text" || p33.kind === "reasoning") {
1983
+ return { kind: p33.kind, id: p33.id, text: p33.textSig.value, done: p33.doneSig.value };
1989
1984
  }
1990
- if (p34.kind === "tool") {
1985
+ if (p33.kind === "tool") {
1991
1986
  return {
1992
1987
  kind: "tool",
1993
- toolCallId: p34.toolCallId,
1994
- toolName: p34.toolName,
1995
- inputPartial: p34.inputPartialSig.value,
1996
- input: p34.inputSig.value,
1997
- output: p34.outputSig.value,
1998
- error: p34.errorSig.value,
1999
- state: p34.stateSig.value,
2000
- approval: p34.approvalSig.value
1988
+ toolCallId: p33.toolCallId,
1989
+ toolName: p33.toolName,
1990
+ inputPartial: p33.inputPartialSig.value,
1991
+ input: p33.inputSig.value,
1992
+ output: p33.outputSig.value,
1993
+ error: p33.errorSig.value,
1994
+ state: p33.stateSig.value,
1995
+ approval: p33.approvalSig.value
2001
1996
  };
2002
1997
  }
2003
- return p34;
1998
+ return p33;
2004
1999
  }
2005
2000
 
2006
2001
  // src/stream/reducer.ts
@@ -2055,8 +2050,8 @@ var StreamReducer = class {
2055
2050
  ensureTextPart(m, "text", chunk.id);
2056
2051
  return;
2057
2052
  case "text-delta": {
2058
- const p34 = ensureTextPart(m, "text", chunk.id);
2059
- p34.textSig.value += chunk.delta;
2053
+ const p33 = ensureTextPart(m, "text", chunk.id);
2054
+ p33.textSig.value += chunk.delta;
2060
2055
  return;
2061
2056
  }
2062
2057
  case "text-end":
@@ -2066,8 +2061,8 @@ var StreamReducer = class {
2066
2061
  ensureTextPart(m, "reasoning", chunk.id).doneSig.value = false;
2067
2062
  return;
2068
2063
  case "reasoning-delta": {
2069
- const p34 = ensureTextPart(m, "reasoning", chunk.id);
2070
- p34.textSig.value += chunk.delta;
2064
+ const p33 = ensureTextPart(m, "reasoning", chunk.id);
2065
+ p33.textSig.value += chunk.delta;
2071
2066
  return;
2072
2067
  }
2073
2068
  case "reasoning-end":
@@ -2086,7 +2081,7 @@ var StreamReducer = class {
2086
2081
  return;
2087
2082
  case "source-url": {
2088
2083
  const parts = m.partsSig.value;
2089
- if (parts.some((p34) => p34.kind === "source" && p34.sourceId === chunk.sourceId)) return;
2084
+ if (parts.some((p33) => p33.kind === "source" && p33.sourceId === chunk.sourceId)) return;
2090
2085
  appendPart(m, { kind: "source", sourceId: chunk.sourceId, url: chunk.url, title: chunk.title });
2091
2086
  return;
2092
2087
  }
@@ -2110,14 +2105,14 @@ var StreamReducer = class {
2110
2105
  }
2111
2106
  };
2112
2107
  function ensureTextPart(m, kind, id) {
2113
- const existing = m.partsSig.value.find((p34) => p34.kind === kind && p34.id === id);
2108
+ const existing = m.partsSig.value.find((p33) => p33.kind === kind && p33.id === id);
2114
2109
  if (existing) return existing;
2115
2110
  const part = { kind, id, textSig: signal2(""), doneSig: signal2(false) };
2116
2111
  appendPart(m, part);
2117
2112
  return part;
2118
2113
  }
2119
2114
  function ensureToolPart(m, toolCallId, toolName) {
2120
- const existing = m.partsSig.value.find((p34) => p34.kind === "tool" && p34.toolCallId === toolCallId);
2115
+ const existing = m.partsSig.value.find((p33) => p33.kind === "tool" && p33.toolCallId === toolCallId);
2121
2116
  if (existing) return existing;
2122
2117
  const part = {
2123
2118
  kind: "tool",
@@ -2142,32 +2137,32 @@ function applyTool(m, chunk) {
2142
2137
  ensureToolPart(m, chunk.toolCallId, chunk.toolName);
2143
2138
  return;
2144
2139
  case "tool-input-delta": {
2145
- const p34 = ensureToolPart(m, chunk.toolCallId);
2146
- p34.inputPartialSig.value += chunk.delta;
2140
+ const p33 = ensureToolPart(m, chunk.toolCallId);
2141
+ p33.inputPartialSig.value += chunk.delta;
2147
2142
  return;
2148
2143
  }
2149
2144
  case "tool-input-available": {
2150
- const p34 = ensureToolPart(m, chunk.toolCallId, chunk.toolName);
2151
- p34.inputSig.value = chunk.input;
2152
- p34.stateSig.value = isAskUserInputTool(p34.toolName) ? "awaiting-input" : "awaiting";
2145
+ const p33 = ensureToolPart(m, chunk.toolCallId, chunk.toolName);
2146
+ p33.inputSig.value = chunk.input;
2147
+ p33.stateSig.value = isAskUserInputTool(p33.toolName) ? "awaiting-input" : "awaiting";
2153
2148
  return;
2154
2149
  }
2155
2150
  case "tool-approval-request": {
2156
- const p34 = ensureToolPart(m, chunk.toolCallId, chunk.toolName);
2157
- p34.approvalSig.value = { id: chunk.approvalId };
2158
- p34.stateSig.value = "awaiting-approval";
2151
+ const p33 = ensureToolPart(m, chunk.toolCallId, chunk.toolName);
2152
+ p33.approvalSig.value = { id: chunk.approvalId };
2153
+ p33.stateSig.value = "awaiting-approval";
2159
2154
  return;
2160
2155
  }
2161
2156
  case "tool-output-available": {
2162
- const p34 = ensureToolPart(m, chunk.toolCallId);
2163
- p34.outputSig.value = chunk.output;
2164
- p34.stateSig.value = "output";
2157
+ const p33 = ensureToolPart(m, chunk.toolCallId);
2158
+ p33.outputSig.value = chunk.output;
2159
+ p33.stateSig.value = "output";
2165
2160
  return;
2166
2161
  }
2167
2162
  case "tool-output-error": {
2168
- const p34 = ensureToolPart(m, chunk.toolCallId);
2169
- p34.errorSig.value = chunk.errorText;
2170
- p34.stateSig.value = "error";
2163
+ const p33 = ensureToolPart(m, chunk.toolCallId);
2164
+ p33.errorSig.value = chunk.errorText;
2165
+ p33.stateSig.value = "error";
2171
2166
  return;
2172
2167
  }
2173
2168
  default:
@@ -2833,16 +2828,12 @@ var TID = {
2833
2828
  /** News list item — suffix `-{id}`. */
2834
2829
  newsItem: `${p2}-news-item`,
2835
2830
  // ── Forms + human-in-the-loop (forms / ask-input / approval) ─────
2836
- /** Blocking form gate root (replaces the composer). */
2831
+ /** Form gate root (replaces the composer, locking the chat). */
2837
2832
  formGate: `${p2}-form-gate`,
2838
- /** Inline form card root (in the transcript). */
2839
- formCard: `${p2}-form-card`,
2840
2833
  /** Form submit button. */
2841
2834
  formSubmit: `${p2}-form-submit`,
2842
- /** Form skip button (blocking gate, when `skippable`). */
2835
+ /** Form skip button (shown only when `skippable`). */
2843
2836
  formSkip: `${p2}-form-skip`,
2844
- /** Inline form-card dismiss button. */
2845
- formDismiss: `${p2}-form-dismiss`,
2846
2837
  /** A single form field control — suffix `-{name}` at the JSX site. */
2847
2838
  formField: `${p2}-form-field`,
2848
2839
  /** Ask-input tool root (inline form in a message bubble). */
@@ -2969,24 +2960,24 @@ import { useCallback as useCallback2, useEffect as useEffect10, useRef as useRef
2969
2960
  import { useEffect as useEffect2, useRef } from "preact/hooks";
2970
2961
  import { jsx as jsx3 } from "preact/jsx-runtime";
2971
2962
  function ResizeGrip({ panelEl, resize, position, initialSize, onSizeChange, strings }) {
2972
- const p34 = BRAND.cssPrefix;
2963
+ const p33 = BRAND.cssPrefix;
2973
2964
  const dragRef = useRef(null);
2974
2965
  useEffect2(() => {
2975
2966
  if (!panelEl) return;
2976
2967
  const style = panelEl.style;
2977
- if (resize.minWidth) style.setProperty(`--${p34}-resize-min-w`, resize.minWidth);
2978
- if (resize.maxWidth) style.setProperty(`--${p34}-resize-max-w`, resize.maxWidth);
2979
- if (resize.minHeight) style.setProperty(`--${p34}-resize-min-h`, resize.minHeight);
2980
- if (resize.maxHeight) style.setProperty(`--${p34}-resize-max-h`, resize.maxHeight);
2968
+ if (resize.minWidth) style.setProperty(`--${p33}-resize-min-w`, resize.minWidth);
2969
+ if (resize.maxWidth) style.setProperty(`--${p33}-resize-max-w`, resize.maxWidth);
2970
+ if (resize.minHeight) style.setProperty(`--${p33}-resize-min-h`, resize.minHeight);
2971
+ if (resize.maxHeight) style.setProperty(`--${p33}-resize-max-h`, resize.maxHeight);
2981
2972
  if (initialSize) {
2982
- style.setProperty(`--${p34}-widget-w`, `${initialSize.width}px`);
2983
- style.setProperty(`--${p34}-widget-h`, `${initialSize.height}px`);
2973
+ style.setProperty(`--${p33}-widget-w`, `${initialSize.width}px`);
2974
+ style.setProperty(`--${p33}-widget-h`, `${initialSize.height}px`);
2984
2975
  }
2985
- }, [panelEl, resize.minWidth, resize.maxWidth, resize.minHeight, resize.maxHeight, p34, initialSize]);
2976
+ }, [panelEl, resize.minWidth, resize.maxWidth, resize.minHeight, resize.maxHeight, p33, initialSize]);
2986
2977
  if (!panelEl) return null;
2987
2978
  const isTop = position.startsWith("top-");
2988
2979
  const isRight = position.endsWith("-right");
2989
- const cornerClass = `${p34}-resize-grip ${p34}-resize-grip--${isTop ? "bottom" : "top"}-${isRight ? "left" : "right"}`;
2980
+ const cornerClass = `${p33}-resize-grip ${p33}-resize-grip--${isTop ? "bottom" : "top"}-${isRight ? "left" : "right"}`;
2990
2981
  const onPointerDown = (e) => {
2991
2982
  if (!panelEl) return;
2992
2983
  const target = e.currentTarget;
@@ -3010,8 +3001,8 @@ function ResizeGrip({ panelEl, resize, position, initialSize, onSizeChange, stri
3010
3001
  if (!d || e.pointerId !== d.pointerId || !panelEl) return;
3011
3002
  const dx = (e.clientX - d.startX) * d.dirX;
3012
3003
  const dy = (e.clientY - d.startY) * d.dirY;
3013
- panelEl.style.setProperty(`--${p34}-widget-w`, `${d.startW + dx}px`);
3014
- panelEl.style.setProperty(`--${p34}-widget-h`, `${d.startH + dy}px`);
3004
+ panelEl.style.setProperty(`--${p33}-widget-w`, `${d.startW + dx}px`);
3005
+ panelEl.style.setProperty(`--${p33}-widget-h`, `${d.startH + dy}px`);
3015
3006
  };
3016
3007
  const onPointerUp = (e) => {
3017
3008
  const d = dragRef.current;
@@ -3746,20 +3737,20 @@ function usePopoverMenu({ itemCount, initialFocusIndex }) {
3746
3737
  // src/ui/overflow-menu.tsx
3747
3738
  import { jsx as jsx8, jsxs as jsxs6 } from "preact/jsx-runtime";
3748
3739
  function OverflowMenu({ items, triggerLabel }) {
3749
- const p34 = BRAND.cssPrefix;
3740
+ const p33 = BRAND.cssPrefix;
3750
3741
  const menu = usePopoverMenu({ itemCount: items.length });
3751
3742
  const handleSelect = (item) => {
3752
3743
  if (item.disabled) return;
3753
3744
  item.onSelect();
3754
3745
  if (!item.keepOpen) menu.close();
3755
3746
  };
3756
- return /* @__PURE__ */ jsxs6("div", { class: `${p34}-menu-wrap`, children: [
3747
+ return /* @__PURE__ */ jsxs6("div", { class: `${p33}-menu-wrap`, children: [
3757
3748
  /* @__PURE__ */ jsx8(
3758
3749
  "button",
3759
3750
  {
3760
3751
  ref: menu.triggerRef,
3761
3752
  type: "button",
3762
- class: `${p34}-icon-btn`,
3753
+ class: `${p33}-icon-btn`,
3763
3754
  "aria-label": triggerLabel,
3764
3755
  "aria-haspopup": "menu",
3765
3756
  "aria-expanded": menu.open,
@@ -3773,7 +3764,7 @@ function OverflowMenu({ items, triggerLabel }) {
3773
3764
  "div",
3774
3765
  {
3775
3766
  ref: menu.menuRef,
3776
- class: `${p34}-menu`,
3767
+ class: `${p33}-menu`,
3777
3768
  role: "menu",
3778
3769
  "aria-label": triggerLabel,
3779
3770
  onKeyDown: menu.onMenuKey,
@@ -3783,15 +3774,15 @@ function OverflowMenu({ items, triggerLabel }) {
3783
3774
  {
3784
3775
  type: "button",
3785
3776
  role: "menuitem",
3786
- class: `${p34}-menu-item`,
3777
+ class: `${p33}-menu-item`,
3787
3778
  "aria-pressed": item.type === "switch" ? item.on : void 0,
3788
3779
  disabled: item.disabled,
3789
3780
  lang: item.lang,
3790
3781
  onClick: () => handleSelect(item),
3791
3782
  children: [
3792
- item.icon ? /* @__PURE__ */ jsx8("span", { class: `${p34}-menu-icon`, children: item.icon }) : null,
3793
- /* @__PURE__ */ jsx8("span", { class: `${p34}-menu-label`, children: item.label }),
3794
- item.type === "switch" && item.on ? /* @__PURE__ */ jsx8("span", { class: `${p34}-menu-check`, "aria-hidden": "true", children: /* @__PURE__ */ jsx8(CheckIcon, {}) }) : null
3783
+ item.icon ? /* @__PURE__ */ jsx8("span", { class: `${p33}-menu-icon`, children: item.icon }) : null,
3784
+ /* @__PURE__ */ jsx8("span", { class: `${p33}-menu-label`, children: item.label }),
3785
+ item.type === "switch" && item.on ? /* @__PURE__ */ jsx8("span", { class: `${p33}-menu-check`, "aria-hidden": "true", children: /* @__PURE__ */ jsx8(CheckIcon, {}) }) : null
3795
3786
  ]
3796
3787
  },
3797
3788
  item.id
@@ -4269,40 +4260,6 @@ function FormGate({ form, strings, onSubmit, onSkip }) {
4269
4260
  import { useEffect as useEffect8, useLayoutEffect, useRef as useRef5, useState as useState6 } from "preact/hooks";
4270
4261
  import { useComputed as useComputed5 } from "@preact/signals";
4271
4262
 
4272
- // src/ui/form/form-card.tsx
4273
- import { jsx as jsx12, jsxs as jsxs10 } from "preact/jsx-runtime";
4274
- var p12 = BRAND.cssPrefix;
4275
- function FormCard({ form, strings, onSubmit, onSkip }) {
4276
- return /* @__PURE__ */ jsxs10("div", { class: `${p12}-form-card`, "data-testid": TID.formCard, children: [
4277
- /* @__PURE__ */ jsxs10("div", { class: `${p12}-form-card-head`, children: [
4278
- form.title ? /* @__PURE__ */ jsx12("strong", { class: `${p12}-form-card-title`, children: form.title }) : /* @__PURE__ */ jsx12("span", {}),
4279
- /* @__PURE__ */ jsx12(
4280
- "button",
4281
- {
4282
- type: "button",
4283
- class: `${p12}-icon-btn`,
4284
- onClick: onSkip,
4285
- "aria-label": strings.formDismiss,
4286
- title: strings.formDismiss,
4287
- "data-testid": TID.formDismiss,
4288
- children: /* @__PURE__ */ jsx12(CloseIcon, {})
4289
- }
4290
- )
4291
- ] }),
4292
- form.description ? /* @__PURE__ */ jsx12("p", { class: `${p12}-form-card-desc`, children: form.description }) : null,
4293
- /* @__PURE__ */ jsx12(
4294
- DynamicForm,
4295
- {
4296
- fields: form.fields,
4297
- strings,
4298
- submitLabel: form.submitLabel ?? strings.formSubmit,
4299
- onSubmit,
4300
- submitTestId: TID.formSubmit
4301
- }
4302
- )
4303
- ] });
4304
- }
4305
-
4306
4263
  // src/ui/message-bubble.tsx
4307
4264
  import { useComputed as useComputed4 } from "@preact/signals";
4308
4265
 
@@ -4310,7 +4267,7 @@ import { useComputed as useComputed4 } from "@preact/signals";
4310
4267
  import { useEffect as useEffect7, useMemo, useRef as useRef4 } from "preact/hooks";
4311
4268
  import { effect, signal as signal4 } from "@preact/signals";
4312
4269
  import * as smd from "streaming-markdown";
4313
- import { jsx as jsx13 } from "preact/jsx-runtime";
4270
+ import { jsx as jsx12 } from "preact/jsx-runtime";
4314
4271
  function MarkdownView({ textSig, doneSig }) {
4315
4272
  const ref = useRef4(null);
4316
4273
  useEffect7(() => {
@@ -4360,12 +4317,12 @@ function MarkdownView({ textSig, doneSig }) {
4360
4317
  el.removeEventListener("click", onClick);
4361
4318
  };
4362
4319
  }, [textSig, doneSig]);
4363
- return /* @__PURE__ */ jsx13("div", { ref });
4320
+ return /* @__PURE__ */ jsx12("div", { ref });
4364
4321
  }
4365
4322
  function StaticMarkdown({ text }) {
4366
4323
  const textSig = useMemo(() => signal4(text), [text]);
4367
4324
  const doneSig = useMemo(() => signal4(true), []);
4368
- return /* @__PURE__ */ jsx13(MarkdownView, { textSig, doneSig });
4325
+ return /* @__PURE__ */ jsx12(MarkdownView, { textSig, doneSig });
4369
4326
  }
4370
4327
  function hardenLink(a) {
4371
4328
  const href = a.getAttribute("href") ?? "";
@@ -4379,8 +4336,8 @@ function hardenLink(a) {
4379
4336
 
4380
4337
  // src/ui/tool-approval.tsx
4381
4338
  import { useComputed as useComputed2, useSignal } from "@preact/signals";
4382
- import { Fragment, jsx as jsx14, jsxs as jsxs11 } from "preact/jsx-runtime";
4383
- var p13 = BRAND.cssPrefix;
4339
+ import { Fragment, jsx as jsx13, jsxs as jsxs10 } from "preact/jsx-runtime";
4340
+ var p12 = BRAND.cssPrefix;
4384
4341
  function ToolApproval({ part, strings, active, onDecision }) {
4385
4342
  const approval = useComputed2(() => part.approvalSig.value);
4386
4343
  const input = useComputed2(() => part.inputSig.value);
@@ -4388,24 +4345,24 @@ function ToolApproval({ part, strings, active, onDecision }) {
4388
4345
  const decided = approval.value?.approved !== void 0;
4389
4346
  if (decided) {
4390
4347
  const ap = approval.value;
4391
- return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-approval ${p13}-tool-decided`, "data-testid": TID.toolDecision, children: [
4392
- /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-decided-label`, "data-approved": ap?.approved ? "true" : "false", children: ap?.approved ? strings.approved : strings.rejected }),
4393
- /* @__PURE__ */ jsx14("strong", { class: `${p13}-tool-title`, children: part.toolName }),
4394
- ap?.reason ? /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-decided-value`, children: ap.reason }) : null
4348
+ return /* @__PURE__ */ jsxs10("div", { class: `${p12}-tool-approval ${p12}-tool-decided`, "data-testid": TID.toolDecision, children: [
4349
+ /* @__PURE__ */ jsx13("span", { class: `${p12}-tool-decided-label`, "data-approved": ap?.approved ? "true" : "false", children: ap?.approved ? strings.approved : strings.rejected }),
4350
+ /* @__PURE__ */ jsx13("strong", { class: `${p12}-tool-title`, children: part.toolName }),
4351
+ ap?.reason ? /* @__PURE__ */ jsx13("span", { class: `${p12}-tool-decided-value`, children: ap.reason }) : null
4395
4352
  ] });
4396
4353
  }
4397
4354
  const args = summarizeInput(input.value);
4398
- return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-approval`, "data-testid": TID.toolApproval, children: [
4399
- /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-head`, children: [
4400
- /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-badge`, children: strings.approvalRequired }),
4401
- /* @__PURE__ */ jsx14("strong", { class: `${p13}-tool-title`, children: part.toolName })
4355
+ return /* @__PURE__ */ jsxs10("div", { class: `${p12}-tool-approval`, "data-testid": TID.toolApproval, children: [
4356
+ /* @__PURE__ */ jsxs10("div", { class: `${p12}-tool-head`, children: [
4357
+ /* @__PURE__ */ jsx13("span", { class: `${p12}-tool-badge`, children: strings.approvalRequired }),
4358
+ /* @__PURE__ */ jsx13("strong", { class: `${p12}-tool-title`, children: part.toolName })
4402
4359
  ] }),
4403
- args ? /* @__PURE__ */ jsx14("pre", { class: `${p13}-tool-args`, children: args }) : null,
4404
- active ? /* @__PURE__ */ jsxs11(Fragment, { children: [
4405
- /* @__PURE__ */ jsx14(
4360
+ args ? /* @__PURE__ */ jsx13("pre", { class: `${p12}-tool-args`, children: args }) : null,
4361
+ active ? /* @__PURE__ */ jsxs10(Fragment, { children: [
4362
+ /* @__PURE__ */ jsx13(
4406
4363
  "input",
4407
4364
  {
4408
- class: `${p13}-field-input`,
4365
+ class: `${p12}-field-input`,
4409
4366
  value: reason.value,
4410
4367
  placeholder: strings.approvalReason,
4411
4368
  onInput: (e) => {
@@ -4413,29 +4370,29 @@ function ToolApproval({ part, strings, active, onDecision }) {
4413
4370
  }
4414
4371
  }
4415
4372
  ),
4416
- /* @__PURE__ */ jsxs11("div", { class: `${p13}-form-actions`, children: [
4417
- /* @__PURE__ */ jsx14(
4373
+ /* @__PURE__ */ jsxs10("div", { class: `${p12}-form-actions`, children: [
4374
+ /* @__PURE__ */ jsx13(
4418
4375
  "button",
4419
4376
  {
4420
4377
  type: "button",
4421
- class: `${p13}-tool-reject`,
4378
+ class: `${p12}-tool-reject`,
4422
4379
  onClick: () => onDecision(part.toolCallId, false, reason.value.trim() || void 0),
4423
4380
  "data-testid": TID.toolReject,
4424
4381
  children: strings.reject
4425
4382
  }
4426
4383
  ),
4427
- /* @__PURE__ */ jsx14(
4384
+ /* @__PURE__ */ jsx13(
4428
4385
  "button",
4429
4386
  {
4430
4387
  type: "button",
4431
- class: `${p13}-tool-approve`,
4388
+ class: `${p12}-tool-approve`,
4432
4389
  onClick: () => onDecision(part.toolCallId, true, reason.value.trim() || void 0),
4433
4390
  "data-testid": TID.toolApprove,
4434
4391
  children: strings.approve
4435
4392
  }
4436
4393
  )
4437
4394
  ] })
4438
- ] }) : /* @__PURE__ */ jsx14("p", { class: `${p13}-tool-stale-note`, children: strings.stepNoLongerActive })
4395
+ ] }) : /* @__PURE__ */ jsx13("p", { class: `${p12}-tool-stale-note`, children: strings.stepNoLongerActive })
4439
4396
  ] });
4440
4397
  }
4441
4398
  function summarizeInput(input) {
@@ -4506,49 +4463,49 @@ function num(v) {
4506
4463
  }
4507
4464
 
4508
4465
  // src/ui/tool-ask-input.tsx
4509
- import { jsx as jsx15, jsxs as jsxs12 } from "preact/jsx-runtime";
4510
- var p14 = BRAND.cssPrefix;
4466
+ import { jsx as jsx14, jsxs as jsxs11 } from "preact/jsx-runtime";
4467
+ var p13 = BRAND.cssPrefix;
4511
4468
  function ToolAskInput({ part, strings, active, onSubmit }) {
4512
4469
  const state = useComputed3(() => part.stateSig.value);
4513
4470
  const request = useComputed3(() => parseAskUserInput(part.inputSig.value));
4514
4471
  const decided = state.value === "output" || state.value === "error";
4515
4472
  if (decided) {
4516
- return /* @__PURE__ */ jsx15(DecidedSummary, { part, strings });
4473
+ return /* @__PURE__ */ jsx14(DecidedSummary, { part, strings });
4517
4474
  }
4518
4475
  if (!active) {
4519
- return /* @__PURE__ */ jsxs12("div", { class: `${p14}-tool-ask-input ${p14}-tool-stale`, "data-testid": TID.toolAskInput, children: [
4520
- /* @__PURE__ */ jsx15(Header, { strings, title: request.value.title ?? request.value.question }),
4521
- /* @__PURE__ */ jsx15("p", { class: `${p14}-tool-stale-note`, children: strings.stepNoLongerActive })
4476
+ return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-ask-input ${p13}-tool-stale`, "data-testid": TID.toolAskInput, children: [
4477
+ /* @__PURE__ */ jsx14(Header, { strings, title: request.value.title ?? request.value.question }),
4478
+ /* @__PURE__ */ jsx14("p", { class: `${p13}-tool-stale-note`, children: strings.stepNoLongerActive })
4522
4479
  ] });
4523
4480
  }
4524
4481
  const req = request.value;
4525
4482
  const isConfirmation = req.responseType === "confirmation";
4526
- return /* @__PURE__ */ jsxs12("div", { class: `${p14}-tool-ask-input`, "data-testid": TID.toolAskInput, children: [
4527
- /* @__PURE__ */ jsx15(Header, { strings, title: req.title }),
4528
- req.description ? /* @__PURE__ */ jsx15("p", { class: `${p14}-tool-desc`, children: req.description }) : null,
4529
- isConfirmation ? /* @__PURE__ */ jsx15("p", { class: `${p14}-tool-question`, children: req.question }) : null,
4530
- isConfirmation ? /* @__PURE__ */ jsxs12("div", { class: `${p14}-form-actions`, children: [
4531
- /* @__PURE__ */ jsx15(
4483
+ return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-ask-input`, "data-testid": TID.toolAskInput, children: [
4484
+ /* @__PURE__ */ jsx14(Header, { strings, title: req.title }),
4485
+ req.description ? /* @__PURE__ */ jsx14("p", { class: `${p13}-tool-desc`, children: req.description }) : null,
4486
+ isConfirmation ? /* @__PURE__ */ jsx14("p", { class: `${p13}-tool-question`, children: req.question }) : null,
4487
+ isConfirmation ? /* @__PURE__ */ jsxs11("div", { class: `${p13}-form-actions`, children: [
4488
+ /* @__PURE__ */ jsx14(
4532
4489
  "button",
4533
4490
  {
4534
4491
  type: "button",
4535
- class: `${p14}-form-skip`,
4492
+ class: `${p13}-form-skip`,
4536
4493
  onClick: () => onSubmit(part.toolCallId, { confirmed: false }),
4537
4494
  "data-testid": TID.toolInputSkip,
4538
4495
  children: strings.reject
4539
4496
  }
4540
4497
  ),
4541
- /* @__PURE__ */ jsx15(
4498
+ /* @__PURE__ */ jsx14(
4542
4499
  "button",
4543
4500
  {
4544
4501
  type: "button",
4545
- class: `${p14}-form-submit`,
4502
+ class: `${p13}-form-submit`,
4546
4503
  onClick: () => onSubmit(part.toolCallId, { confirmed: true }),
4547
4504
  "data-testid": TID.toolInputSubmit,
4548
4505
  children: strings.approve
4549
4506
  }
4550
4507
  )
4551
- ] }) : /* @__PURE__ */ jsx15(
4508
+ ] }) : /* @__PURE__ */ jsx14(
4552
4509
  DynamicForm,
4553
4510
  {
4554
4511
  fields: askInputToFields(req),
@@ -4564,17 +4521,17 @@ function ToolAskInput({ part, strings, active, onSubmit }) {
4564
4521
  ] });
4565
4522
  }
4566
4523
  function Header({ strings, title }) {
4567
- return /* @__PURE__ */ jsxs12("div", { class: `${p14}-tool-head`, children: [
4568
- /* @__PURE__ */ jsx15("span", { class: `${p14}-tool-badge`, children: strings.inputRequired }),
4569
- title ? /* @__PURE__ */ jsx15("strong", { class: `${p14}-tool-title`, children: title }) : null
4524
+ return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-head`, children: [
4525
+ /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-badge`, children: strings.inputRequired }),
4526
+ title ? /* @__PURE__ */ jsx14("strong", { class: `${p13}-tool-title`, children: title }) : null
4570
4527
  ] });
4571
4528
  }
4572
4529
  function DecidedSummary({ part, strings }) {
4573
4530
  const output = useComputed3(() => part.outputSig.value);
4574
4531
  const text = summarizeOutput(output.value) || strings.inputSubmitted;
4575
- return /* @__PURE__ */ jsxs12("div", { class: `${p14}-tool-ask-input ${p14}-tool-decided`, "data-testid": TID.toolDecision, children: [
4576
- /* @__PURE__ */ jsx15("span", { class: `${p14}-tool-decided-label`, children: strings.inputSubmitted }),
4577
- /* @__PURE__ */ jsx15("span", { class: `${p14}-tool-decided-value`, children: text })
4532
+ return /* @__PURE__ */ jsxs11("div", { class: `${p13}-tool-ask-input ${p13}-tool-decided`, "data-testid": TID.toolDecision, children: [
4533
+ /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-decided-label`, children: strings.inputSubmitted }),
4534
+ /* @__PURE__ */ jsx14("span", { class: `${p13}-tool-decided-value`, children: text })
4578
4535
  ] });
4579
4536
  }
4580
4537
  function summarizeOutput(output) {
@@ -4589,21 +4546,21 @@ function summarizeOutput(output) {
4589
4546
  }
4590
4547
 
4591
4548
  // src/ui/tool-chip.tsx
4592
- import { jsx as jsx16, jsxs as jsxs13 } from "preact/jsx-runtime";
4549
+ import { jsx as jsx15, jsxs as jsxs12 } from "preact/jsx-runtime";
4593
4550
  function ToolChip({ part, strings }) {
4594
- const p34 = BRAND.cssPrefix;
4595
- return /* @__PURE__ */ jsxs13("span", { class: `${p34}-tool-chip`, role: "status", children: [
4596
- /* @__PURE__ */ jsxs13("span", { children: [
4551
+ const p33 = BRAND.cssPrefix;
4552
+ return /* @__PURE__ */ jsxs12("span", { class: `${p33}-tool-chip`, role: "status", children: [
4553
+ /* @__PURE__ */ jsxs12("span", { children: [
4597
4554
  strings.usedTool,
4598
4555
  ":"
4599
4556
  ] }),
4600
- /* @__PURE__ */ jsx16("strong", { children: part.toolName })
4557
+ /* @__PURE__ */ jsx15("strong", { children: part.toolName })
4601
4558
  ] });
4602
4559
  }
4603
4560
 
4604
4561
  // src/ui/message-bubble.tsx
4605
- import { jsx as jsx17, jsxs as jsxs14 } from "preact/jsx-runtime";
4606
- var p15 = BRAND.cssPrefix;
4562
+ import { jsx as jsx16, jsxs as jsxs13 } from "preact/jsx-runtime";
4563
+ var p14 = BRAND.cssPrefix;
4607
4564
  function MessageBubble({
4608
4565
  message,
4609
4566
  strings,
@@ -4626,9 +4583,9 @@ function MessageBubble({
4626
4583
  const working = streaming && !hasAnswerText.value;
4627
4584
  const showStreamDots = streaming && !bufferedHold && !(reasoningVisible.value && working);
4628
4585
  const stamp = formatStamp(message.createdAt);
4629
- return /* @__PURE__ */ jsx17("div", { class: `${p15}-bubble-row`, "data-role": message.role, "data-testid": tid(TID.messageBubble, message.id), children: /* @__PURE__ */ jsxs14("div", { class: `${p15}-bubble-col`, children: [
4630
- /* @__PURE__ */ jsxs14("div", { class: `${p15}-bubble`, children: [
4631
- bufferedHold ? /* @__PURE__ */ jsx17(LoadingSpinner, { label: strings.loading }) : partList.map((part) => /* @__PURE__ */ jsx17(
4586
+ return /* @__PURE__ */ jsx16("div", { class: `${p14}-bubble-row`, "data-role": message.role, "data-testid": tid(TID.messageBubble, message.id), children: /* @__PURE__ */ jsxs13("div", { class: `${p14}-bubble-col`, children: [
4587
+ /* @__PURE__ */ jsxs13("div", { class: `${p14}-bubble`, children: [
4588
+ bufferedHold ? /* @__PURE__ */ jsx16(LoadingSpinner, { label: strings.loading }) : partList.map((part) => /* @__PURE__ */ jsx16(
4632
4589
  PartView,
4633
4590
  {
4634
4591
  part,
@@ -4641,10 +4598,10 @@ function MessageBubble({
4641
4598
  },
4642
4599
  partKey(part)
4643
4600
  )),
4644
- showStreamDots && /* @__PURE__ */ jsx17(TypingDots, {}),
4645
- message.status === "error" && message.errorText ? /* @__PURE__ */ jsx17("div", { class: `${p15}-error`, role: "alert", children: /* @__PURE__ */ jsx17("span", { children: message.errorText }) }) : null
4601
+ showStreamDots && /* @__PURE__ */ jsx16(TypingDots, {}),
4602
+ message.status === "error" && message.errorText ? /* @__PURE__ */ jsx16("div", { class: `${p14}-error`, role: "alert", children: /* @__PURE__ */ jsx16("span", { children: message.errorText }) }) : null
4646
4603
  ] }),
4647
- stamp ? /* @__PURE__ */ jsx17("time", { class: `${p15}-bubble-time`, dateTime: stamp.iso, title: stamp.full, children: stamp.short }) : null
4604
+ stamp ? /* @__PURE__ */ jsx16("time", { class: `${p14}-bubble-time`, dateTime: stamp.iso, title: stamp.full, children: stamp.short }) : null
4648
4605
  ] }) });
4649
4606
  }
4650
4607
  function formatStamp(createdAt) {
@@ -4671,11 +4628,11 @@ function PartView({
4671
4628
  }) {
4672
4629
  switch (part.kind) {
4673
4630
  case "text":
4674
- return /* @__PURE__ */ jsx17(MarkdownView, { textSig: part.textSig, doneSig: part.doneSig });
4631
+ return /* @__PURE__ */ jsx16(MarkdownView, { textSig: part.textSig, doneSig: part.doneSig });
4675
4632
  case "reasoning":
4676
- return showReasoning ? /* @__PURE__ */ jsx17(ReasoningView, { part, active, strings }) : null;
4633
+ return showReasoning ? /* @__PURE__ */ jsx16(ReasoningView, { part, active, strings }) : null;
4677
4634
  case "tool":
4678
- return /* @__PURE__ */ jsx17(
4635
+ return /* @__PURE__ */ jsx16(
4679
4636
  ToolPartView,
4680
4637
  {
4681
4638
  part,
@@ -4687,9 +4644,9 @@ function PartView({
4687
4644
  );
4688
4645
  case "file":
4689
4646
  if (part.mediaType.startsWith("image/")) {
4690
- return /* @__PURE__ */ jsx17("img", { src: part.url, alt: "", loading: "lazy" });
4647
+ return /* @__PURE__ */ jsx16("img", { src: part.url, alt: "", loading: "lazy" });
4691
4648
  }
4692
- return /* @__PURE__ */ jsx17("a", { href: part.url, target: "_blank", rel: "noreferrer noopener", children: part.url });
4649
+ return /* @__PURE__ */ jsx16("a", { href: part.url, target: "_blank", rel: "noreferrer noopener", children: part.url });
4693
4650
  case "source":
4694
4651
  return null;
4695
4652
  }
@@ -4705,22 +4662,22 @@ function ToolPartView({
4705
4662
  const hasApproval = useComputed4(() => part.approvalSig.value !== void 0);
4706
4663
  if (tool?.humanInLoop) {
4707
4664
  if (hasApproval.value || state.value === "awaiting-approval") {
4708
- return /* @__PURE__ */ jsx17(ToolApproval, { part, strings, active: interactive, onDecision: tool.onDecision });
4665
+ return /* @__PURE__ */ jsx16(ToolApproval, { part, strings, active: interactive, onDecision: tool.onDecision });
4709
4666
  }
4710
4667
  if (isAskUserInputTool(part.toolName) || state.value === "awaiting-input") {
4711
- return /* @__PURE__ */ jsx17(ToolAskInput, { part, strings, active: interactive, onSubmit: tool.onResult });
4668
+ return /* @__PURE__ */ jsx16(ToolAskInput, { part, strings, active: interactive, onSubmit: tool.onResult });
4712
4669
  }
4713
4670
  }
4714
- return showToolCalls ? /* @__PURE__ */ jsx17(ToolChip, { part, strings }) : null;
4671
+ return showToolCalls ? /* @__PURE__ */ jsx16(ToolChip, { part, strings }) : null;
4715
4672
  }
4716
4673
  function ReasoningView({
4717
4674
  part,
4718
4675
  active,
4719
4676
  strings
4720
4677
  }) {
4721
- return /* @__PURE__ */ jsxs14("details", { class: `${p15}-reasoning`, open: active, "data-active": active ? "true" : void 0, children: [
4722
- /* @__PURE__ */ jsx17("summary", { class: `${p15}-reasoning-summary`, children: /* @__PURE__ */ jsx17("span", { class: `${p15}-reasoning-label`, children: active ? strings.thinking : strings.thoughts }) }),
4723
- /* @__PURE__ */ jsx17("div", { class: `${p15}-reasoning-body`, children: /* @__PURE__ */ jsx17(MarkdownView, { textSig: part.textSig, doneSig: part.doneSig }) })
4678
+ return /* @__PURE__ */ jsxs13("details", { class: `${p14}-reasoning`, open: active, "data-active": active ? "true" : void 0, children: [
4679
+ /* @__PURE__ */ jsx16("summary", { class: `${p14}-reasoning-summary`, children: /* @__PURE__ */ jsx16("span", { class: `${p14}-reasoning-label`, children: active ? strings.thinking : strings.thoughts }) }),
4680
+ /* @__PURE__ */ jsx16("div", { class: `${p14}-reasoning-body`, children: /* @__PURE__ */ jsx16(MarkdownView, { textSig: part.textSig, doneSig: part.doneSig }) })
4724
4681
  ] });
4725
4682
  }
4726
4683
  function partKey(part) {
@@ -4737,22 +4694,22 @@ function partKey(part) {
4737
4694
  }
4738
4695
  }
4739
4696
  function TypingDots() {
4740
- return /* @__PURE__ */ jsxs14("span", { class: `${p15}-typing`, "aria-hidden": "true", children: [
4741
- /* @__PURE__ */ jsx17("span", {}),
4742
- /* @__PURE__ */ jsx17("span", {}),
4743
- /* @__PURE__ */ jsx17("span", {})
4697
+ return /* @__PURE__ */ jsxs13("span", { class: `${p14}-typing`, "aria-hidden": "true", children: [
4698
+ /* @__PURE__ */ jsx16("span", {}),
4699
+ /* @__PURE__ */ jsx16("span", {}),
4700
+ /* @__PURE__ */ jsx16("span", {})
4744
4701
  ] });
4745
4702
  }
4746
4703
  function LoadingSpinner({ label }) {
4747
- return /* @__PURE__ */ jsxs14("span", { class: `${p15}-loading`, role: "status", children: [
4748
- /* @__PURE__ */ jsx17("span", { class: `${p15}-loading-spinner`, "aria-hidden": "true" }),
4749
- /* @__PURE__ */ jsx17("span", { class: `${p15}-loading-label`, children: label })
4704
+ return /* @__PURE__ */ jsxs13("span", { class: `${p14}-loading`, role: "status", children: [
4705
+ /* @__PURE__ */ jsx16("span", { class: `${p14}-loading-spinner`, "aria-hidden": "true" }),
4706
+ /* @__PURE__ */ jsx16("span", { class: `${p14}-loading-label`, children: label })
4750
4707
  ] });
4751
4708
  }
4752
4709
 
4753
4710
  // src/ui/message-list.tsx
4754
- import { jsx as jsx18, jsxs as jsxs15 } from "preact/jsx-runtime";
4755
- var p16 = BRAND.cssPrefix;
4711
+ import { jsx as jsx17, jsxs as jsxs14 } from "preact/jsx-runtime";
4712
+ var p15 = BRAND.cssPrefix;
4756
4713
  var STICK_THRESHOLD = 120;
4757
4714
  var DIVIDER_IDLE_MS = 1200;
4758
4715
  function MessageList({
@@ -4763,10 +4720,7 @@ function MessageList({
4763
4720
  showToolCalls,
4764
4721
  loading,
4765
4722
  idle,
4766
- tool,
4767
- inlineForm,
4768
- onFormSubmit,
4769
- onFormSkip
4723
+ tool
4770
4724
  }) {
4771
4725
  const ref = useRef5(null);
4772
4726
  const messages = useComputed5(() => messagesSig.value);
@@ -4851,12 +4805,12 @@ function MessageList({
4851
4805
  const day = dayKey(m.createdAt);
4852
4806
  if (day && day !== prevDay) {
4853
4807
  rows.push(
4854
- /* @__PURE__ */ jsx18("div", { class: `${p16}-date-divider`, children: /* @__PURE__ */ jsx18("span", { class: `${p16}-date-pill`, title: fullDate(m.createdAt), children: dayLabel(m.createdAt, strings) }) }, `day:${day}`)
4808
+ /* @__PURE__ */ jsx17("div", { class: `${p15}-date-divider`, children: /* @__PURE__ */ jsx17("span", { class: `${p15}-date-pill`, title: fullDate(m.createdAt), children: dayLabel(m.createdAt, strings) }) }, `day:${day}`)
4855
4809
  );
4856
4810
  prevDay = day;
4857
4811
  }
4858
4812
  rows.push(
4859
- /* @__PURE__ */ jsx18(
4813
+ /* @__PURE__ */ jsx17(
4860
4814
  MessageBubble,
4861
4815
  {
4862
4816
  message: m,
@@ -4871,33 +4825,32 @@ function MessageList({
4871
4825
  )
4872
4826
  );
4873
4827
  }
4874
- return /* @__PURE__ */ jsxs15("div", { class: `${p16}-list-wrap`, children: [
4875
- /* @__PURE__ */ jsxs15(
4828
+ return /* @__PURE__ */ jsxs14("div", { class: `${p15}-list-wrap`, children: [
4829
+ /* @__PURE__ */ jsxs14(
4876
4830
  "div",
4877
4831
  {
4878
4832
  ref,
4879
- class: `${p16}-list`,
4833
+ class: `${p15}-list`,
4880
4834
  role: "log",
4881
4835
  "aria-live": "polite",
4882
4836
  "aria-relevant": "additions text",
4883
4837
  "data-scrolling": scrolling ? "true" : void 0,
4884
4838
  children: [
4885
- loading && messages.value.length === 0 ? /* @__PURE__ */ jsx18("div", { class: `${p16}-list-loading`, role: "status", children: strings.messagesLoading }) : null,
4886
- rows,
4887
- inlineForm && onFormSubmit && onFormSkip ? /* @__PURE__ */ jsx18(FormCard, { form: inlineForm, strings, onSubmit: onFormSubmit, onSkip: onFormSkip }) : null
4839
+ loading && messages.value.length === 0 ? /* @__PURE__ */ jsx17("div", { class: `${p15}-list-loading`, role: "status", children: strings.messagesLoading }) : null,
4840
+ rows
4888
4841
  ]
4889
4842
  }
4890
4843
  ),
4891
- showJump ? /* @__PURE__ */ jsx18(
4844
+ showJump ? /* @__PURE__ */ jsx17(
4892
4845
  "button",
4893
4846
  {
4894
4847
  type: "button",
4895
- class: `${p16}-jump`,
4848
+ class: `${p15}-jump`,
4896
4849
  onClick: jumpToBottom,
4897
4850
  "aria-label": strings.scrollToBottom,
4898
4851
  title: strings.scrollToBottom,
4899
4852
  "data-testid": TID.scrollToBottom,
4900
- children: /* @__PURE__ */ jsx18(ChevronDownIcon, {})
4853
+ children: /* @__PURE__ */ jsx17(ChevronDownIcon, {})
4901
4854
  }
4902
4855
  ) : null
4903
4856
  ] });
@@ -4956,7 +4909,7 @@ function startOfDay(ms) {
4956
4909
  }
4957
4910
 
4958
4911
  // src/ui/conversation-list.tsx
4959
- import { Fragment as Fragment2, jsx as jsx19, jsxs as jsxs16 } from "preact/jsx-runtime";
4912
+ import { Fragment as Fragment2, jsx as jsx18, jsxs as jsxs15 } from "preact/jsx-runtime";
4960
4913
  var log11 = logger.scope("history");
4961
4914
  var BUCKET_TO_STRING = {
4962
4915
  today: "dateToday",
@@ -4965,7 +4918,7 @@ var BUCKET_TO_STRING = {
4965
4918
  older: "dateOlder"
4966
4919
  };
4967
4920
  function ConversationList({ transport, strings, visitorId, onSelect, onNewChat }) {
4968
- const p34 = BRAND.cssPrefix;
4921
+ const p33 = BRAND.cssPrefix;
4969
4922
  const [state, setState] = useState7("loading");
4970
4923
  const [sessions, setChats] = useState7([]);
4971
4924
  useEffect9(() => {
@@ -4983,38 +4936,38 @@ function ConversationList({ transport, strings, visitorId, onSelect, onNewChat }
4983
4936
  cancelled = true;
4984
4937
  };
4985
4938
  }, [transport, visitorId]);
4986
- const newChatButton = onNewChat ? /* @__PURE__ */ jsx19("div", { class: `${p34}-history-footer`, children: /* @__PURE__ */ jsxs16("button", { type: "button", class: `${p34}-history-new`, onClick: onNewChat, "data-testid": TID.sidebarNewChat, children: [
4987
- /* @__PURE__ */ jsx19(PlusIcon, {}),
4939
+ const newChatButton = onNewChat ? /* @__PURE__ */ jsx18("div", { class: `${p33}-history-footer`, children: /* @__PURE__ */ jsxs15("button", { type: "button", class: `${p33}-history-new`, onClick: onNewChat, "data-testid": TID.sidebarNewChat, children: [
4940
+ /* @__PURE__ */ jsx18(PlusIcon, {}),
4988
4941
  strings.historyNewChat
4989
4942
  ] }) }) : null;
4990
4943
  if (state === "loading") {
4991
- return /* @__PURE__ */ jsxs16(Fragment2, { children: [
4992
- /* @__PURE__ */ jsx19("div", { class: `${p34}-history-empty`, children: strings.historyLoading }),
4944
+ return /* @__PURE__ */ jsxs15(Fragment2, { children: [
4945
+ /* @__PURE__ */ jsx18("div", { class: `${p33}-history-empty`, children: strings.historyLoading }),
4993
4946
  newChatButton
4994
4947
  ] });
4995
4948
  }
4996
4949
  if (state === "error" || sessions.length === 0) {
4997
- return /* @__PURE__ */ jsxs16(Fragment2, { children: [
4998
- /* @__PURE__ */ jsx19("div", { class: `${p34}-history-empty`, children: strings.historyEmpty }),
4950
+ return /* @__PURE__ */ jsxs15(Fragment2, { children: [
4951
+ /* @__PURE__ */ jsx18("div", { class: `${p33}-history-empty`, children: strings.historyEmpty }),
4999
4952
  newChatButton
5000
4953
  ] });
5001
4954
  }
5002
4955
  const groups = groupByBucket(Date.now(), sessions);
5003
- return /* @__PURE__ */ jsxs16(Fragment2, { children: [
5004
- /* @__PURE__ */ jsx19("div", { class: `${p34}-history`, role: "list", children: groups.map((group) => /* @__PURE__ */ jsxs16("div", { class: `${p34}-history-group`, children: [
5005
- /* @__PURE__ */ jsx19("div", { class: `${p34}-history-heading`, children: strings[BUCKET_TO_STRING[group.bucket]] }),
5006
- group.sessions.map((chat) => /* @__PURE__ */ jsxs16(
4956
+ return /* @__PURE__ */ jsxs15(Fragment2, { children: [
4957
+ /* @__PURE__ */ jsx18("div", { class: `${p33}-history`, role: "list", children: groups.map((group) => /* @__PURE__ */ jsxs15("div", { class: `${p33}-history-group`, children: [
4958
+ /* @__PURE__ */ jsx18("div", { class: `${p33}-history-heading`, children: strings[BUCKET_TO_STRING[group.bucket]] }),
4959
+ group.sessions.map((chat) => /* @__PURE__ */ jsxs15(
5007
4960
  "button",
5008
4961
  {
5009
4962
  type: "button",
5010
4963
  role: "listitem",
5011
- class: `${p34}-history-item`,
4964
+ class: `${p33}-history-item`,
5012
4965
  onClick: () => onSelect(chat),
5013
4966
  "data-closed": chat.canContinue ? void 0 : "true",
5014
4967
  "data-testid": tid(TID.historyItem, chat.sessionId),
5015
4968
  children: [
5016
- /* @__PURE__ */ jsx19("span", { class: `${p34}-history-title`, children: chat.title }),
5017
- chat.preview ? /* @__PURE__ */ jsx19("span", { class: `${p34}-history-preview`, children: chat.preview }) : null
4969
+ /* @__PURE__ */ jsx18("span", { class: `${p33}-history-title`, children: chat.title }),
4970
+ chat.preview ? /* @__PURE__ */ jsx18("span", { class: `${p33}-history-preview`, children: chat.preview }) : null
5018
4971
  ]
5019
4972
  },
5020
4973
  chat.sessionId
@@ -5025,21 +4978,21 @@ function ConversationList({ transport, strings, visitorId, onSelect, onNewChat }
5025
4978
  }
5026
4979
 
5027
4980
  // src/ui/chat-history-pane.tsx
5028
- import { jsx as jsx20 } from "preact/jsx-runtime";
4981
+ import { jsx as jsx19 } from "preact/jsx-runtime";
5029
4982
  function ChatHistoryPane(props2) {
5030
- return /* @__PURE__ */ jsx20(ConversationList, { ...props2 });
4983
+ return /* @__PURE__ */ jsx19(ConversationList, { ...props2 });
5031
4984
  }
5032
4985
 
5033
4986
  // src/ui/suggestions.tsx
5034
- import { jsx as jsx21 } from "preact/jsx-runtime";
5035
- var p17 = BRAND.cssPrefix;
4987
+ import { jsx as jsx20 } from "preact/jsx-runtime";
4988
+ var p16 = BRAND.cssPrefix;
5036
4989
  function Suggestions({ suggestions, onPick }) {
5037
4990
  if (suggestions.length === 0) return null;
5038
- return /* @__PURE__ */ jsx21("div", { class: `${p17}-suggestions`, role: "group", "aria-label": "Suggested replies", children: suggestions.map((s, i) => /* @__PURE__ */ jsx21(
4991
+ return /* @__PURE__ */ jsx20("div", { class: `${p16}-suggestions`, role: "group", "aria-label": "Suggested replies", children: suggestions.map((s, i) => /* @__PURE__ */ jsx20(
5039
4992
  "button",
5040
4993
  {
5041
4994
  type: "button",
5042
- class: `${p17}-suggestion`,
4995
+ class: `${p16}-suggestion`,
5043
4996
  onClick: () => onPick(s),
5044
4997
  "data-testid": tid(TID.suggestion, i),
5045
4998
  children: s.label
@@ -5049,8 +5002,8 @@ function Suggestions({ suggestions, onPick }) {
5049
5002
  }
5050
5003
 
5051
5004
  // src/ui/panel.tsx
5052
- import { Fragment as Fragment3, jsx as jsx22, jsxs as jsxs17 } from "preact/jsx-runtime";
5053
- var p18 = BRAND.cssPrefix;
5005
+ import { Fragment as Fragment3, jsx as jsx21, jsxs as jsxs16 } from "preact/jsx-runtime";
5006
+ var p17 = BRAND.cssPrefix;
5054
5007
  function Panel(props2) {
5055
5008
  const { options, onClose } = props2;
5056
5009
  const s = options.strings;
@@ -5074,18 +5027,18 @@ function Panel(props2) {
5074
5027
  }, []);
5075
5028
  const { visible: dragOver } = useFileDrop({ containerRef, onDrop: onDropItems });
5076
5029
  useDragMove(containerRef.current, options.mode === "modal");
5077
- return /* @__PURE__ */ jsxs17(
5030
+ return /* @__PURE__ */ jsxs16(
5078
5031
  "div",
5079
5032
  {
5080
5033
  ref: containerRef,
5081
- class: `${p18}-panel`,
5034
+ class: `${p17}-panel`,
5082
5035
  role: "dialog",
5083
5036
  "aria-modal": "false",
5084
5037
  "aria-label": s.panelTitle,
5085
5038
  style: { position: "relative" },
5086
5039
  "data-testid": TID.panel,
5087
5040
  children: [
5088
- /* @__PURE__ */ jsx22(
5041
+ /* @__PURE__ */ jsx21(
5089
5042
  PanelContent,
5090
5043
  {
5091
5044
  ...props2,
@@ -5094,7 +5047,7 @@ function Panel(props2) {
5094
5047
  composerAttachApiRef
5095
5048
  }
5096
5049
  ),
5097
- /* @__PURE__ */ jsx22(PoweredByBar, { poweredBy: props2.options.poweredBy })
5050
+ /* @__PURE__ */ jsx21(PoweredByBar, { poweredBy: props2.options.poweredBy })
5098
5051
  ]
5099
5052
  }
5100
5053
  );
@@ -5125,8 +5078,7 @@ function PanelContent(props2) {
5125
5078
  onSend,
5126
5079
  onStop,
5127
5080
  onSuggestion,
5128
- blockingForm,
5129
- inlineForm,
5081
+ activeForm,
5130
5082
  onFormSubmit,
5131
5083
  onFormSkip,
5132
5084
  tool,
@@ -5136,12 +5088,12 @@ function PanelContent(props2) {
5136
5088
  } = props2;
5137
5089
  const s = options.strings;
5138
5090
  let composerArea;
5139
- if (blockingForm) {
5140
- composerArea = /* @__PURE__ */ jsx22(FormGate, { form: blockingForm, strings: s, onSubmit: onFormSubmit, onSkip: onFormSkip });
5091
+ if (activeForm) {
5092
+ composerArea = /* @__PURE__ */ jsx21(FormGate, { form: activeForm, strings: s, onSubmit: onFormSubmit, onSkip: onFormSkip });
5141
5093
  } else if (canSend) {
5142
- composerArea = /* @__PURE__ */ jsxs17(Fragment3, { children: [
5143
- /* @__PURE__ */ jsx22(Suggestions, { suggestions, onPick: onSuggestion }),
5144
- /* @__PURE__ */ jsx22(
5094
+ composerArea = /* @__PURE__ */ jsxs16(Fragment3, { children: [
5095
+ /* @__PURE__ */ jsx21(Suggestions, { suggestions, onPick: onSuggestion }),
5096
+ /* @__PURE__ */ jsx21(
5145
5097
  Composer,
5146
5098
  {
5147
5099
  options,
@@ -5156,10 +5108,10 @@ function PanelContent(props2) {
5156
5108
  )
5157
5109
  ] });
5158
5110
  } else {
5159
- composerArea = /* @__PURE__ */ jsx22(ReadOnlyBanner, { label: s.chatClosed, ctaLabel: s.startNewConversation, onNewChat: onClear });
5111
+ composerArea = /* @__PURE__ */ jsx21(ReadOnlyBanner, { label: s.chatClosed, ctaLabel: s.startNewConversation, onNewChat: onClear });
5160
5112
  }
5161
- return /* @__PURE__ */ jsxs17(Fragment3, { children: [
5162
- view === "history" ? /* @__PURE__ */ jsx22(
5113
+ return /* @__PURE__ */ jsxs16(Fragment3, { children: [
5114
+ view === "history" ? /* @__PURE__ */ jsx21(
5163
5115
  HistoryHeader,
5164
5116
  {
5165
5117
  strings: s,
@@ -5167,22 +5119,22 @@ function PanelContent(props2) {
5167
5119
  onClose,
5168
5120
  showClose: canShowClose(options.mode, panelSize, options.actions)
5169
5121
  }
5170
- ) : /* @__PURE__ */ jsxs17("header", { class: `${p18}-header`, "data-testid": TID.panelHeader, children: [
5171
- onBack ? /* @__PURE__ */ jsx22(
5122
+ ) : /* @__PURE__ */ jsxs16("header", { class: `${p17}-header`, "data-testid": TID.panelHeader, children: [
5123
+ onBack ? /* @__PURE__ */ jsx21(
5172
5124
  "button",
5173
5125
  {
5174
5126
  type: "button",
5175
- class: `${p18}-icon-btn`,
5127
+ class: `${p17}-icon-btn`,
5176
5128
  onClick: onBack,
5177
5129
  "aria-label": s.moduleBack,
5178
5130
  title: s.moduleBack,
5179
- children: /* @__PURE__ */ jsx22(BackIcon, {})
5131
+ children: /* @__PURE__ */ jsx21(BackIcon, {})
5180
5132
  }
5181
5133
  ) : null,
5182
- agent ? /* @__PURE__ */ jsx22(AgentBadge, { agent }) : /* @__PURE__ */ jsx22("h1", { children: s.panelTitle }),
5183
- /* @__PURE__ */ jsx22(HeaderActions, { panelProps: props2, variant: "chat" })
5134
+ agent ? /* @__PURE__ */ jsx21(AgentBadge, { agent }) : /* @__PURE__ */ jsx21("h1", { children: s.panelTitle }),
5135
+ /* @__PURE__ */ jsx21(HeaderActions, { panelProps: props2, variant: "chat" })
5184
5136
  ] }),
5185
- view === "history" ? /* @__PURE__ */ jsx22(
5137
+ view === "history" ? /* @__PURE__ */ jsx21(
5186
5138
  ChatHistoryPane,
5187
5139
  {
5188
5140
  transport,
@@ -5191,9 +5143,9 @@ function PanelContent(props2) {
5191
5143
  onSelect: (chat) => onSelectHistoryChat(chat.sessionId),
5192
5144
  onNewChat
5193
5145
  }
5194
- ) : /* @__PURE__ */ jsxs17(Fragment3, { children: [
5195
- /* @__PURE__ */ jsx22(DropZone, { visible: dragOver, strings: s }),
5196
- /* @__PURE__ */ jsx22(
5146
+ ) : /* @__PURE__ */ jsxs16(Fragment3, { children: [
5147
+ /* @__PURE__ */ jsx21(DropZone, { visible: dragOver, strings: s }),
5148
+ /* @__PURE__ */ jsx21(
5197
5149
  MessageList,
5198
5150
  {
5199
5151
  messagesSig,
@@ -5203,16 +5155,13 @@ function PanelContent(props2) {
5203
5155
  showToolCalls: options.showToolCalls,
5204
5156
  loading: loadingMessages,
5205
5157
  idle: !isStreaming,
5206
- tool,
5207
- inlineForm,
5208
- onFormSubmit,
5209
- onFormSkip
5158
+ tool
5210
5159
  }
5211
5160
  ),
5212
5161
  composerArea,
5213
- /* @__PURE__ */ jsx22(ComposerFooter, { disclaimer: options.composerDisclaimer })
5162
+ /* @__PURE__ */ jsx21(ComposerFooter, { disclaimer: options.composerDisclaimer })
5214
5163
  ] }),
5215
- options.size.resize?.enabled ? /* @__PURE__ */ jsx22(
5164
+ options.size.resize?.enabled ? /* @__PURE__ */ jsx21(
5216
5165
  ResizeGrip,
5217
5166
  {
5218
5167
  panelEl: containerEl,
@@ -5231,55 +5180,55 @@ function HistoryHeader({
5231
5180
  onClose,
5232
5181
  showClose
5233
5182
  }) {
5234
- return /* @__PURE__ */ jsxs17("header", { class: `${p18}-header`, children: [
5235
- /* @__PURE__ */ jsx22(
5183
+ return /* @__PURE__ */ jsxs16("header", { class: `${p17}-header`, children: [
5184
+ /* @__PURE__ */ jsx21(
5236
5185
  "button",
5237
5186
  {
5238
5187
  type: "button",
5239
- class: `${p18}-icon-btn`,
5188
+ class: `${p17}-icon-btn`,
5240
5189
  onClick: onBack,
5241
5190
  "aria-label": strings.historyBack,
5242
5191
  title: strings.historyBack,
5243
- children: /* @__PURE__ */ jsx22(BackIcon, {})
5192
+ children: /* @__PURE__ */ jsx21(BackIcon, {})
5244
5193
  }
5245
5194
  ),
5246
- /* @__PURE__ */ jsx22("h1", { children: strings.historyTitle }),
5247
- showClose ? /* @__PURE__ */ jsx22(
5195
+ /* @__PURE__ */ jsx21("h1", { children: strings.historyTitle }),
5196
+ showClose ? /* @__PURE__ */ jsx21(
5248
5197
  "button",
5249
5198
  {
5250
5199
  type: "button",
5251
- class: `${p18}-icon-btn`,
5200
+ class: `${p17}-icon-btn`,
5252
5201
  onClick: onClose,
5253
5202
  "aria-label": strings.close,
5254
5203
  title: strings.close,
5255
- children: /* @__PURE__ */ jsx22(CloseIcon, {})
5204
+ children: /* @__PURE__ */ jsx21(CloseIcon, {})
5256
5205
  }
5257
5206
  ) : null
5258
5207
  ] });
5259
5208
  }
5260
5209
  function ReadOnlyBanner({ label, ctaLabel, onNewChat }) {
5261
- return /* @__PURE__ */ jsxs17("div", { class: `${p18}-readonly-banner`, role: "note", children: [
5262
- /* @__PURE__ */ jsx22("span", { class: `${p18}-readonly-label`, children: label }),
5263
- /* @__PURE__ */ jsx22("button", { type: "button", class: `${p18}-readonly-cta`, onClick: onNewChat, children: ctaLabel })
5210
+ return /* @__PURE__ */ jsxs16("div", { class: `${p17}-readonly-banner`, role: "note", children: [
5211
+ /* @__PURE__ */ jsx21("span", { class: `${p17}-readonly-label`, children: label }),
5212
+ /* @__PURE__ */ jsx21("button", { type: "button", class: `${p17}-readonly-cta`, onClick: onNewChat, children: ctaLabel })
5264
5213
  ] });
5265
5214
  }
5266
5215
  function ComposerFooter({ disclaimer }) {
5267
5216
  if (!disclaimer) return null;
5268
- return /* @__PURE__ */ jsx22("div", { class: `${p18}-composer-footer`, children: /* @__PURE__ */ jsx22("div", { class: `${p18}-disclaimer`, children: disclaimer }) });
5217
+ return /* @__PURE__ */ jsx21("div", { class: `${p17}-composer-footer`, children: /* @__PURE__ */ jsx21("div", { class: `${p17}-disclaimer`, children: disclaimer }) });
5269
5218
  }
5270
5219
  function PoweredByBar({ poweredBy }) {
5271
5220
  if (!poweredBy) return null;
5272
- return /* @__PURE__ */ jsx22("div", { class: `${p18}-poweredby-bar`, children: /* @__PURE__ */ jsx22(PoweredBy, { logoUrl: poweredBy.logoUrl, text: poweredBy.text, href: poweredBy.href }) });
5221
+ return /* @__PURE__ */ jsx21("div", { class: `${p17}-poweredby-bar`, children: /* @__PURE__ */ jsx21(PoweredBy, { logoUrl: poweredBy.logoUrl, text: poweredBy.text, href: poweredBy.href }) });
5273
5222
  }
5274
5223
  function PoweredBy({ logoUrl, text, href }) {
5275
- const inner = /* @__PURE__ */ jsxs17(Fragment3, { children: [
5276
- logoUrl ? /* @__PURE__ */ jsx22("img", { class: `${p18}-poweredby-logo`, src: logoUrl, alt: "", loading: "lazy" }) : null,
5277
- text ? /* @__PURE__ */ jsx22("span", { children: text }) : null
5224
+ const inner = /* @__PURE__ */ jsxs16(Fragment3, { children: [
5225
+ logoUrl ? /* @__PURE__ */ jsx21("img", { class: `${p17}-poweredby-logo`, src: logoUrl, alt: "", loading: "lazy" }) : null,
5226
+ text ? /* @__PURE__ */ jsx21("span", { children: text }) : null
5278
5227
  ] });
5279
5228
  if (href) {
5280
- return /* @__PURE__ */ jsx22("a", { class: `${p18}-poweredby`, href, target: "_blank", rel: "noopener noreferrer", children: inner });
5229
+ return /* @__PURE__ */ jsx21("a", { class: `${p17}-poweredby`, href, target: "_blank", rel: "noopener noreferrer", children: inner });
5281
5230
  }
5282
- return /* @__PURE__ */ jsx22("span", { class: `${p18}-poweredby`, children: inner });
5231
+ return /* @__PURE__ */ jsx21("span", { class: `${p17}-poweredby`, children: inner });
5283
5232
  }
5284
5233
 
5285
5234
  // src/ui/form/form-controller.ts
@@ -5354,34 +5303,34 @@ function whenPasses(form, d) {
5354
5303
  }
5355
5304
 
5356
5305
  // src/ui/sidebar.tsx
5357
- import { Fragment as Fragment4, jsx as jsx23, jsxs as jsxs18 } from "preact/jsx-runtime";
5306
+ import { Fragment as Fragment4, jsx as jsx22, jsxs as jsxs17 } from "preact/jsx-runtime";
5358
5307
  function Sidebar(props2) {
5359
- const p34 = BRAND.cssPrefix;
5308
+ const p33 = BRAND.cssPrefix;
5360
5309
  const { site, blocks, strings, collapsed } = props2;
5361
5310
  const navigation = blocks?.navigation ?? [];
5362
5311
  const linkCards = blocks?.linkCards ?? [];
5363
5312
  const toggleLabel = collapsed ? strings.expandSidebar : strings.collapseSidebar;
5364
- return /* @__PURE__ */ jsxs18("aside", { class: `${p34}-sidebar`, "data-collapsed": collapsed ? "true" : "false", "data-testid": TID.sidebar, children: [
5365
- /* @__PURE__ */ jsxs18("div", { class: `${p34}-sidebar-header`, children: [
5366
- /* @__PURE__ */ jsx23(SidebarBrand, { site }),
5367
- /* @__PURE__ */ jsx23(
5313
+ return /* @__PURE__ */ jsxs17("aside", { class: `${p33}-sidebar`, "data-collapsed": collapsed ? "true" : "false", "data-testid": TID.sidebar, children: [
5314
+ /* @__PURE__ */ jsxs17("div", { class: `${p33}-sidebar-header`, children: [
5315
+ /* @__PURE__ */ jsx22(SidebarBrand, { site }),
5316
+ /* @__PURE__ */ jsx22(
5368
5317
  "button",
5369
5318
  {
5370
5319
  type: "button",
5371
- class: `${p34}-sidebar-toggle`,
5320
+ class: `${p33}-sidebar-toggle`,
5372
5321
  "aria-label": toggleLabel,
5373
5322
  "aria-expanded": collapsed ? "false" : "true",
5374
5323
  title: toggleLabel,
5375
5324
  onClick: props2.onToggleCollapsed,
5376
5325
  "data-testid": TID.sidebarToggle,
5377
- children: /* @__PURE__ */ jsx23(SidebarToggleIcon, { collapsed })
5326
+ children: /* @__PURE__ */ jsx22(SidebarToggleIcon, { collapsed })
5378
5327
  }
5379
5328
  )
5380
5329
  ] }),
5381
- collapsed ? null : /* @__PURE__ */ jsxs18(Fragment4, { children: [
5382
- navigation.length > 0 ? /* @__PURE__ */ jsx23("nav", { class: `${p34}-sidebar-section`, "data-section": "navigation", children: /* @__PURE__ */ jsx23(SidebarNav, { items: navigation }) }) : null,
5383
- linkCards.length > 0 ? /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-section`, "data-section": "link-cards", children: /* @__PURE__ */ jsx23(SidebarCards, { items: linkCards }) }) : null,
5384
- props2.showConversations ? /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-conversations`, children: /* @__PURE__ */ jsx23(
5330
+ collapsed ? null : /* @__PURE__ */ jsxs17(Fragment4, { children: [
5331
+ navigation.length > 0 ? /* @__PURE__ */ jsx22("nav", { class: `${p33}-sidebar-section`, "data-section": "navigation", children: /* @__PURE__ */ jsx22(SidebarNav, { items: navigation }) }) : null,
5332
+ linkCards.length > 0 ? /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-section`, "data-section": "link-cards", children: /* @__PURE__ */ jsx22(SidebarCards, { items: linkCards }) }) : null,
5333
+ props2.showConversations ? /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-conversations`, children: /* @__PURE__ */ jsx22(
5385
5334
  ConversationList,
5386
5335
  {
5387
5336
  transport: props2.transport,
@@ -5395,18 +5344,18 @@ function Sidebar(props2) {
5395
5344
  ] });
5396
5345
  }
5397
5346
  function SidebarBrand({ site }) {
5398
- const p34 = BRAND.cssPrefix;
5347
+ const p33 = BRAND.cssPrefix;
5399
5348
  if (site?.logo?.url) {
5400
5349
  const alt = site.logo.alt ?? site.title ?? "Logo";
5401
- return /* @__PURE__ */ jsxs18("picture", { children: [
5402
- site.logoDark?.url ? /* @__PURE__ */ jsx23("source", { srcset: site.logoDark.url, media: "(prefers-color-scheme: dark)" }) : null,
5403
- /* @__PURE__ */ jsx23("img", { class: `${p34}-sidebar-logo`, src: site.logo.url, alt })
5350
+ return /* @__PURE__ */ jsxs17("picture", { children: [
5351
+ site.logoDark?.url ? /* @__PURE__ */ jsx22("source", { srcset: site.logoDark.url, media: "(prefers-color-scheme: dark)" }) : null,
5352
+ /* @__PURE__ */ jsx22("img", { class: `${p33}-sidebar-logo`, src: site.logo.url, alt })
5404
5353
  ] });
5405
5354
  }
5406
- return /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-title`, children: site?.title ?? BRAND.name });
5355
+ return /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-title`, children: site?.title ?? BRAND.name });
5407
5356
  }
5408
5357
  function SidebarToggleIcon({ collapsed }) {
5409
- return /* @__PURE__ */ jsx23(
5358
+ return /* @__PURE__ */ jsx22(
5410
5359
  "svg",
5411
5360
  {
5412
5361
  width: "16",
@@ -5416,38 +5365,38 @@ function SidebarToggleIcon({ collapsed }) {
5416
5365
  stroke: "currentColor",
5417
5366
  "stroke-width": "2",
5418
5367
  "aria-hidden": "true",
5419
- children: collapsed ? /* @__PURE__ */ jsx23("polyline", { points: "9 6 15 12 9 18" }) : /* @__PURE__ */ jsx23("polyline", { points: "15 6 9 12 15 18" })
5368
+ children: collapsed ? /* @__PURE__ */ jsx22("polyline", { points: "9 6 15 12 9 18" }) : /* @__PURE__ */ jsx22("polyline", { points: "15 6 9 12 15 18" })
5420
5369
  }
5421
5370
  );
5422
5371
  }
5423
5372
  function SidebarNav({ items }) {
5424
- const p34 = BRAND.cssPrefix;
5425
- return /* @__PURE__ */ jsx23("ul", { class: `${p34}-sidebar-nav`, children: items.map((item) => /* @__PURE__ */ jsx23("li", { children: /* @__PURE__ */ jsxs18(
5373
+ const p33 = BRAND.cssPrefix;
5374
+ return /* @__PURE__ */ jsx22("ul", { class: `${p33}-sidebar-nav`, children: items.map((item) => /* @__PURE__ */ jsx22("li", { children: /* @__PURE__ */ jsxs17(
5426
5375
  "a",
5427
5376
  {
5428
- class: `${p34}-sidebar-nav-item`,
5377
+ class: `${p33}-sidebar-nav-item`,
5429
5378
  href: item.href,
5430
5379
  target: item.href ? "_blank" : void 0,
5431
5380
  rel: item.href ? "noreferrer" : void 0,
5432
5381
  children: [
5433
- item.icon ? /* @__PURE__ */ jsx23("span", { class: `${p34}-sidebar-nav-icon`, "data-icon": item.icon }) : null,
5434
- /* @__PURE__ */ jsx23("span", { class: `${p34}-sidebar-nav-label`, children: item.label })
5382
+ item.icon ? /* @__PURE__ */ jsx22("span", { class: `${p33}-sidebar-nav-icon`, "data-icon": item.icon }) : null,
5383
+ /* @__PURE__ */ jsx22("span", { class: `${p33}-sidebar-nav-label`, children: item.label })
5435
5384
  ]
5436
5385
  }
5437
5386
  ) }, item.id ?? item.label)) });
5438
5387
  }
5439
5388
  function SidebarCards({ items }) {
5440
- const p34 = BRAND.cssPrefix;
5441
- return /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-cards`, children: items.map((item) => /* @__PURE__ */ jsxs18(
5389
+ const p33 = BRAND.cssPrefix;
5390
+ return /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-cards`, children: items.map((item) => /* @__PURE__ */ jsxs17(
5442
5391
  "a",
5443
5392
  {
5444
- class: `${p34}-sidebar-card`,
5393
+ class: `${p33}-sidebar-card`,
5445
5394
  href: item.href,
5446
5395
  target: item.href ? "_blank" : void 0,
5447
5396
  rel: item.href ? "noreferrer" : void 0,
5448
5397
  children: [
5449
- /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-card-label`, children: item.label }),
5450
- item.description ? /* @__PURE__ */ jsx23("div", { class: `${p34}-sidebar-card-desc`, children: item.description }) : null
5398
+ /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-card-label`, children: item.label }),
5399
+ item.description ? /* @__PURE__ */ jsx22("div", { class: `${p33}-sidebar-card-desc`, children: item.description }) : null
5451
5400
  ]
5452
5401
  },
5453
5402
  item.id ?? item.label
@@ -5455,11 +5404,11 @@ function SidebarCards({ items }) {
5455
5404
  }
5456
5405
 
5457
5406
  // src/ui/page-shell.tsx
5458
- import { jsx as jsx24, jsxs as jsxs19 } from "preact/jsx-runtime";
5459
- var p19 = BRAND.cssPrefix;
5407
+ import { jsx as jsx23, jsxs as jsxs18 } from "preact/jsx-runtime";
5408
+ var p18 = BRAND.cssPrefix;
5460
5409
  function PageShell(props2) {
5461
- return /* @__PURE__ */ jsxs19("main", { class: `${p19}-page-shell`, "data-sidebar-collapsed": props2.sidebarCollapsed ? "true" : "false", children: [
5462
- /* @__PURE__ */ jsx24(
5410
+ return /* @__PURE__ */ jsxs18("main", { class: `${p18}-page-shell`, "data-sidebar-collapsed": props2.sidebarCollapsed ? "true" : "false", children: [
5411
+ /* @__PURE__ */ jsx23(
5463
5412
  Sidebar,
5464
5413
  {
5465
5414
  site: props2.site,
@@ -5474,7 +5423,7 @@ function PageShell(props2) {
5474
5423
  onToggleCollapsed: props2.onToggleSidebarCollapsed
5475
5424
  }
5476
5425
  ),
5477
- /* @__PURE__ */ jsx24("section", { class: `${p19}-page-chat`, "aria-label": "Chat", children: props2.children })
5426
+ /* @__PURE__ */ jsx23("section", { class: `${p18}-page-chat`, "aria-label": "Chat", children: props2.children })
5478
5427
  ] });
5479
5428
  }
5480
5429
 
@@ -5524,80 +5473,80 @@ var chatLayout = {
5524
5473
  import { useEffect as useEffect11, useMemo as useMemo2, useState as useState8 } from "preact/hooks";
5525
5474
 
5526
5475
  // src/ui/back-header.tsx
5527
- import { jsx as jsx25, jsxs as jsxs20 } from "preact/jsx-runtime";
5528
- var p20 = BRAND.cssPrefix;
5476
+ import { jsx as jsx24, jsxs as jsxs19 } from "preact/jsx-runtime";
5477
+ var p19 = BRAND.cssPrefix;
5529
5478
  function TitleBar({ title, actions }) {
5530
- return /* @__PURE__ */ jsxs20("header", { class: `${p20}-back-header`, "data-variant": "title", children: [
5531
- /* @__PURE__ */ jsx25("span", { class: `${p20}-back-spacer`, "aria-hidden": "true" }),
5532
- /* @__PURE__ */ jsx25("h1", { class: `${p20}-back-title`, children: title }),
5533
- actions ?? /* @__PURE__ */ jsx25("span", { class: `${p20}-back-spacer`, "aria-hidden": "true" })
5479
+ return /* @__PURE__ */ jsxs19("header", { class: `${p19}-back-header`, "data-variant": "title", children: [
5480
+ /* @__PURE__ */ jsx24("span", { class: `${p19}-back-spacer`, "aria-hidden": "true" }),
5481
+ /* @__PURE__ */ jsx24("h1", { class: `${p19}-back-title`, children: title }),
5482
+ actions ?? /* @__PURE__ */ jsx24("span", { class: `${p19}-back-spacer`, "aria-hidden": "true" })
5534
5483
  ] });
5535
5484
  }
5536
5485
  function BackHeader({ title, backLabel, onBack, actions, testid }) {
5537
- return /* @__PURE__ */ jsxs20("header", { class: `${p20}-back-header`, "data-testid": testid, children: [
5538
- /* @__PURE__ */ jsx25("button", { type: "button", class: `${p20}-icon-btn`, onClick: onBack, "aria-label": backLabel, title: backLabel, children: /* @__PURE__ */ jsx25(BackIcon, {}) }),
5539
- /* @__PURE__ */ jsx25("h1", { class: `${p20}-back-title`, children: title }),
5540
- actions ?? /* @__PURE__ */ jsx25("span", { class: `${p20}-back-spacer`, "aria-hidden": "true" })
5486
+ return /* @__PURE__ */ jsxs19("header", { class: `${p19}-back-header`, "data-testid": testid, children: [
5487
+ /* @__PURE__ */ jsx24("button", { type: "button", class: `${p19}-icon-btn`, onClick: onBack, "aria-label": backLabel, title: backLabel, children: /* @__PURE__ */ jsx24(BackIcon, {}) }),
5488
+ /* @__PURE__ */ jsx24("h1", { class: `${p19}-back-title`, children: title }),
5489
+ actions ?? /* @__PURE__ */ jsx24("span", { class: `${p19}-back-spacer`, "aria-hidden": "true" })
5541
5490
  ] });
5542
5491
  }
5543
5492
 
5544
5493
  // src/ui/home-search.tsx
5545
- import { jsx as jsx26, jsxs as jsxs21 } from "preact/jsx-runtime";
5546
- var p21 = BRAND.cssPrefix;
5494
+ import { jsx as jsx25, jsxs as jsxs20 } from "preact/jsx-runtime";
5495
+ var p20 = BRAND.cssPrefix;
5547
5496
  function HomeSearchButton({ placeholder, onActivate }) {
5548
- return /* @__PURE__ */ jsxs21("button", { type: "button", class: `${p21}-home-search`, onClick: onActivate, "data-testid": TID.homeSearch, children: [
5549
- /* @__PURE__ */ jsx26("span", { class: `${p21}-home-search-text`, children: placeholder }),
5550
- /* @__PURE__ */ jsx26("span", { class: `${p21}-home-search-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx26(SearchIcon, {}) })
5497
+ return /* @__PURE__ */ jsxs20("button", { type: "button", class: `${p20}-home-search`, onClick: onActivate, "data-testid": TID.homeSearch, children: [
5498
+ /* @__PURE__ */ jsx25("span", { class: `${p20}-home-search-text`, children: placeholder }),
5499
+ /* @__PURE__ */ jsx25("span", { class: `${p20}-home-search-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx25(SearchIcon, {}) })
5551
5500
  ] });
5552
5501
  }
5553
5502
  function HelpSearchInput({ placeholder, value, onInput }) {
5554
- return /* @__PURE__ */ jsxs21("div", { class: `${p21}-home-search`, "data-input": "true", children: [
5555
- /* @__PURE__ */ jsx26(
5503
+ return /* @__PURE__ */ jsxs20("div", { class: `${p20}-home-search`, "data-input": "true", children: [
5504
+ /* @__PURE__ */ jsx25(
5556
5505
  "input",
5557
5506
  {
5558
5507
  type: "search",
5559
- class: `${p21}-home-search-input`,
5508
+ class: `${p20}-home-search-input`,
5560
5509
  placeholder,
5561
5510
  value,
5562
5511
  onInput: (e) => onInput(e.currentTarget.value),
5563
5512
  "data-testid": TID.helpSearch
5564
5513
  }
5565
5514
  ),
5566
- /* @__PURE__ */ jsx26("span", { class: `${p21}-home-search-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx26(SearchIcon, {}) })
5515
+ /* @__PURE__ */ jsx25("span", { class: `${p20}-home-search-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx25(SearchIcon, {}) })
5567
5516
  ] });
5568
5517
  }
5569
5518
 
5570
5519
  // src/ui/list-row.tsx
5571
- import { jsx as jsx27, jsxs as jsxs22 } from "preact/jsx-runtime";
5572
- var p22 = BRAND.cssPrefix;
5520
+ import { jsx as jsx26, jsxs as jsxs21 } from "preact/jsx-runtime";
5521
+ var p21 = BRAND.cssPrefix;
5573
5522
  function ListRow({ title, subtitle, onClick, testid }) {
5574
- return /* @__PURE__ */ jsxs22("button", { type: "button", class: `${p22}-list-row`, onClick, "data-testid": testid, children: [
5575
- /* @__PURE__ */ jsxs22("span", { class: `${p22}-list-row-body`, children: [
5576
- /* @__PURE__ */ jsx27("span", { class: `${p22}-list-row-title`, children: title }),
5577
- subtitle ? /* @__PURE__ */ jsx27("span", { class: `${p22}-list-row-sub`, children: subtitle }) : null
5523
+ return /* @__PURE__ */ jsxs21("button", { type: "button", class: `${p21}-list-row`, onClick, "data-testid": testid, children: [
5524
+ /* @__PURE__ */ jsxs21("span", { class: `${p21}-list-row-body`, children: [
5525
+ /* @__PURE__ */ jsx26("span", { class: `${p21}-list-row-title`, children: title }),
5526
+ subtitle ? /* @__PURE__ */ jsx26("span", { class: `${p21}-list-row-sub`, children: subtitle }) : null
5578
5527
  ] }),
5579
- /* @__PURE__ */ jsx27("span", { class: `${p22}-list-row-chevron`, "aria-hidden": "true", children: /* @__PURE__ */ jsx27(ChevronRightIcon, {}) })
5528
+ /* @__PURE__ */ jsx26("span", { class: `${p21}-list-row-chevron`, "aria-hidden": "true", children: /* @__PURE__ */ jsx26(ChevronRightIcon, {}) })
5580
5529
  ] });
5581
5530
  }
5582
5531
 
5583
5532
  // src/ui/module-state.tsx
5584
- import { jsx as jsx28, jsxs as jsxs23 } from "preact/jsx-runtime";
5585
- var p23 = BRAND.cssPrefix;
5533
+ import { jsx as jsx27, jsxs as jsxs22 } from "preact/jsx-runtime";
5534
+ var p22 = BRAND.cssPrefix;
5586
5535
  function ModuleState({
5587
5536
  tone = "info",
5588
5537
  message,
5589
5538
  onRetry,
5590
5539
  strings
5591
5540
  }) {
5592
- return /* @__PURE__ */ jsxs23("div", { class: `${p23}-module-empty`, role: tone === "error" ? "alert" : "status", "aria-live": "polite", children: [
5593
- /* @__PURE__ */ jsx28("span", { children: message }),
5594
- onRetry ? /* @__PURE__ */ jsx28("button", { type: "button", class: `${p23}-module-retry`, onClick: onRetry, children: strings.errorRetry }) : null
5541
+ return /* @__PURE__ */ jsxs22("div", { class: `${p22}-module-empty`, role: tone === "error" ? "alert" : "status", "aria-live": "polite", children: [
5542
+ /* @__PURE__ */ jsx27("span", { children: message }),
5543
+ onRetry ? /* @__PURE__ */ jsx27("button", { type: "button", class: `${p22}-module-retry`, onClick: onRetry, children: strings.errorRetry }) : null
5595
5544
  ] });
5596
5545
  }
5597
5546
 
5598
5547
  // src/ui/modules/help.tsx
5599
- import { jsx as jsx29, jsxs as jsxs24 } from "preact/jsx-runtime";
5600
- var p24 = BRAND.cssPrefix;
5548
+ import { jsx as jsx28, jsxs as jsxs23 } from "preact/jsx-runtime";
5549
+ var p23 = BRAND.cssPrefix;
5601
5550
  var log12 = logger.scope("help");
5602
5551
  var openArticle = (nav, a) => a.url ? nav.push({ kind: "iframe", url: a.url, title: a.title }) : nav.push({ kind: "content", id: a.id, title: a.title });
5603
5552
  function groupByCategory(items) {
@@ -5626,7 +5575,7 @@ function fuzzySearch(items, query) {
5626
5575
  return items.map((item) => ({ item, score: Math.max(fuzzyScore(q, item.title) * 2, fuzzyScore(q, item.description ?? "")) })).filter((r) => r.score > 0).toSorted((a, b) => b.score - a.score).map((r) => r.item);
5627
5576
  }
5628
5577
  function ArticleRow({ article, nav }) {
5629
- return /* @__PURE__ */ jsx29(
5578
+ return /* @__PURE__ */ jsx28(
5630
5579
  ListRow,
5631
5580
  {
5632
5581
  title: article.title,
@@ -5663,46 +5612,46 @@ function HelpRoot({ transport, strings, config, nav, panelProps }) {
5663
5612
  const results = useMemo2(() => fuzzySearch(items, query), [items, query]);
5664
5613
  function renderBody() {
5665
5614
  if (query.trim().length > 0) {
5666
- if (results.length === 0) return /* @__PURE__ */ jsx29(ModuleState, { message: strings.helpSearchEmpty, strings });
5667
- return /* @__PURE__ */ jsx29("div", { class: `${p24}-help-card`, children: results.map((a) => /* @__PURE__ */ jsx29(ArticleRow, { article: a, nav }, a.id)) });
5615
+ if (results.length === 0) return /* @__PURE__ */ jsx28(ModuleState, { message: strings.helpSearchEmpty, strings });
5616
+ return /* @__PURE__ */ jsx28("div", { class: `${p23}-help-card`, children: results.map((a) => /* @__PURE__ */ jsx28(ArticleRow, { article: a, nav }, a.id)) });
5668
5617
  }
5669
- if (state === "loading") return /* @__PURE__ */ jsx29(ModuleState, { message: strings.helpLoading, strings });
5618
+ if (state === "loading") return /* @__PURE__ */ jsx28(ModuleState, { message: strings.helpLoading, strings });
5670
5619
  if (state === "error") {
5671
- return /* @__PURE__ */ jsx29(ModuleState, { tone: "error", message: errorMsg, onRetry: () => setReloadKey((k) => k + 1), strings });
5620
+ return /* @__PURE__ */ jsx28(ModuleState, { tone: "error", message: errorMsg, onRetry: () => setReloadKey((k) => k + 1), strings });
5672
5621
  }
5673
- if (items.length === 0) return /* @__PURE__ */ jsx29(ModuleState, { message: strings.helpEmpty, strings });
5674
- return groupByCategory(items).map(([category, rows]) => /* @__PURE__ */ jsxs24("section", { class: `${p24}-help-group`, children: [
5675
- category ? /* @__PURE__ */ jsx29("h2", { class: `${p24}-help-section-title`, children: category }) : null,
5676
- /* @__PURE__ */ jsx29("div", { class: `${p24}-help-card`, children: rows.map((a) => /* @__PURE__ */ jsx29(ArticleRow, { article: a, nav }, a.id)) })
5622
+ if (items.length === 0) return /* @__PURE__ */ jsx28(ModuleState, { message: strings.helpEmpty, strings });
5623
+ return groupByCategory(items).map(([category, rows]) => /* @__PURE__ */ jsxs23("section", { class: `${p23}-help-group`, children: [
5624
+ category ? /* @__PURE__ */ jsx28("h2", { class: `${p23}-help-section-title`, children: category }) : null,
5625
+ /* @__PURE__ */ jsx28("div", { class: `${p23}-help-card`, children: rows.map((a) => /* @__PURE__ */ jsx28(ArticleRow, { article: a, nav }, a.id)) })
5677
5626
  ] }, category));
5678
5627
  }
5679
- return /* @__PURE__ */ jsxs24("div", { class: `${p24}-module`, children: [
5680
- /* @__PURE__ */ jsx29(TitleBar, { title: strings.helpTitle, actions: /* @__PURE__ */ jsx29(HeaderActions, { panelProps, variant: "plain" }) }),
5681
- /* @__PURE__ */ jsx29("div", { class: `${p24}-module-pad`, children: /* @__PURE__ */ jsx29(HelpSearchInput, { placeholder: strings.helpSearchPlaceholder, value: query, onInput: setQuery }) }),
5682
- /* @__PURE__ */ jsx29("div", { class: `${p24}-help-list`, children: renderBody() })
5628
+ return /* @__PURE__ */ jsxs23("div", { class: `${p23}-module`, children: [
5629
+ /* @__PURE__ */ jsx28(TitleBar, { title: strings.helpTitle, actions: /* @__PURE__ */ jsx28(HeaderActions, { panelProps, variant: "plain" }) }),
5630
+ /* @__PURE__ */ jsx28("div", { class: `${p23}-module-pad`, children: /* @__PURE__ */ jsx28(HelpSearchInput, { placeholder: strings.helpSearchPlaceholder, value: query, onInput: setQuery }) }),
5631
+ /* @__PURE__ */ jsx28("div", { class: `${p23}-help-list`, children: renderBody() })
5683
5632
  ] });
5684
5633
  }
5685
5634
  var helpLayout = {
5686
5635
  Icon: HelpIcon,
5687
- Root: (props2) => /* @__PURE__ */ jsx29(HelpRoot, { ...props2 })
5636
+ Root: (props2) => /* @__PURE__ */ jsx28(HelpRoot, { ...props2 })
5688
5637
  };
5689
5638
 
5690
5639
  // src/ui/modules/home.tsx
5691
5640
  import { useEffect as useEffect12, useState as useState9 } from "preact/hooks";
5692
5641
 
5693
5642
  // src/ui/home-card.tsx
5694
- import { jsx as jsx30 } from "preact/jsx-runtime";
5695
- var p25 = BRAND.cssPrefix;
5643
+ import { jsx as jsx29 } from "preact/jsx-runtime";
5644
+ var p24 = BRAND.cssPrefix;
5696
5645
  function HomeCard({ onClick, children, testid }) {
5697
5646
  if (onClick) {
5698
- return /* @__PURE__ */ jsx30("button", { type: "button", class: `${p25}-home-card`, "data-interactive": "true", onClick, "data-testid": testid, children });
5647
+ return /* @__PURE__ */ jsx29("button", { type: "button", class: `${p24}-home-card`, "data-interactive": "true", onClick, "data-testid": testid, children });
5699
5648
  }
5700
- return /* @__PURE__ */ jsx30("div", { class: `${p25}-home-card`, "data-testid": testid, children });
5649
+ return /* @__PURE__ */ jsx29("div", { class: `${p24}-home-card`, "data-testid": testid, children });
5701
5650
  }
5702
5651
 
5703
5652
  // src/ui/modules/home.tsx
5704
- import { Fragment as Fragment5, jsx as jsx31, jsxs as jsxs25 } from "preact/jsx-runtime";
5705
- var p26 = BRAND.cssPrefix;
5653
+ import { Fragment as Fragment5, jsx as jsx30, jsxs as jsxs24 } from "preact/jsx-runtime";
5654
+ var p25 = BRAND.cssPrefix;
5706
5655
  var log13 = logger.scope("home");
5707
5656
  function resolveGreeting(props2) {
5708
5657
  const name = props2.options.userContext?.name;
@@ -5739,49 +5688,49 @@ function HomeRoot(props2) {
5739
5688
  const avatars = config.userAvatars ?? [];
5740
5689
  const status = config.status;
5741
5690
  const contentTitle = config.contentBlockTitle ? moduleLabel(strings, config.contentBlockTitle) : strings.homeContentTitle;
5742
- return /* @__PURE__ */ jsx31("div", { class: `${p26}-module ${p26}-home`, "data-testid": TID.homeView, children: /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-scroll`, children: [
5743
- /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-hero`, children: [
5744
- /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-hero-top`, children: [
5745
- config.brandName ? /* @__PURE__ */ jsx31("span", { class: `${p26}-home-brand`, "data-testid": TID.homeBrand, children: config.brandName }) : /* @__PURE__ */ jsx31("span", { class: `${p26}-home-brand-spacer`, "aria-hidden": "true" }),
5746
- /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-hero-actions`, children: [
5747
- avatars.length > 0 ? /* @__PURE__ */ jsx31("div", { class: `${p26}-home-avatars`, children: avatars.map((a) => /* @__PURE__ */ jsx31("span", { class: `${p26}-home-avatar`, title: a.role ? `${a.name} \xB7 ${a.role}` : a.name, children: a.avatar ? /* @__PURE__ */ jsx31("img", { src: a.avatar, alt: "", loading: "lazy" }) : /* @__PURE__ */ jsx31("span", { children: initials(a.name) }) }, a.name)) }) : null,
5748
- /* @__PURE__ */ jsx31(HeaderActions, { panelProps, variant: "plain" })
5691
+ return /* @__PURE__ */ jsx30("div", { class: `${p25}-module ${p25}-home`, "data-testid": TID.homeView, children: /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-scroll`, children: [
5692
+ /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-hero`, children: [
5693
+ /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-hero-top`, children: [
5694
+ config.brandName ? /* @__PURE__ */ jsx30("span", { class: `${p25}-home-brand`, "data-testid": TID.homeBrand, children: config.brandName }) : /* @__PURE__ */ jsx30("span", { class: `${p25}-home-brand-spacer`, "aria-hidden": "true" }),
5695
+ /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-hero-actions`, children: [
5696
+ avatars.length > 0 ? /* @__PURE__ */ jsx30("div", { class: `${p25}-home-avatars`, children: avatars.map((a) => /* @__PURE__ */ jsx30("span", { class: `${p25}-home-avatar`, title: a.role ? `${a.name} \xB7 ${a.role}` : a.name, children: a.avatar ? /* @__PURE__ */ jsx30("img", { src: a.avatar, alt: "", loading: "lazy" }) : /* @__PURE__ */ jsx30("span", { children: initials(a.name) }) }, a.name)) }) : null,
5697
+ /* @__PURE__ */ jsx30(HeaderActions, { panelProps, variant: "plain" })
5749
5698
  ] })
5750
5699
  ] }),
5751
- config.showGreeting !== false ? /* @__PURE__ */ jsxs25(Fragment5, { children: [
5752
- /* @__PURE__ */ jsx31("h1", { class: `${p26}-home-greeting`, "data-testid": TID.homeGreeting, children: greeting.title }),
5753
- greeting.subtitle ? /* @__PURE__ */ jsx31("p", { class: `${p26}-home-lead`, children: greeting.subtitle }) : null
5700
+ config.showGreeting !== false ? /* @__PURE__ */ jsxs24(Fragment5, { children: [
5701
+ /* @__PURE__ */ jsx30("h1", { class: `${p25}-home-greeting`, "data-testid": TID.homeGreeting, children: greeting.title }),
5702
+ greeting.subtitle ? /* @__PURE__ */ jsx30("p", { class: `${p25}-home-lead`, children: greeting.subtitle }) : null
5754
5703
  ] }) : null
5755
5704
  ] }),
5756
- /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-cards`, children: [
5757
- config.showSearchBar !== false ? /* @__PURE__ */ jsx31(
5705
+ /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-cards`, children: [
5706
+ config.showSearchBar !== false ? /* @__PURE__ */ jsx30(
5758
5707
  HomeSearchButton,
5759
5708
  {
5760
5709
  placeholder: strings.homeSearchPlaceholder,
5761
5710
  onActivate: () => nav.switchToLayout("help")
5762
5711
  }
5763
5712
  ) : null,
5764
- recent ? /* @__PURE__ */ jsx31(HomeCard, { onClick: () => nav.selectSession(recent.sessionId), testid: TID.homeRecent, children: /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-recent-row`, "data-unread": (recent.unreadCount ?? 0) > 0 ? "true" : void 0, children: [
5765
- /* @__PURE__ */ jsx31("span", { class: `${p26}-home-recent-avatar`, "aria-hidden": "true", children: /* @__PURE__ */ jsx31(BubblesIcon, {}) }),
5766
- /* @__PURE__ */ jsxs25("span", { class: `${p26}-home-recent-body`, children: [
5767
- /* @__PURE__ */ jsx31("span", { class: `${p26}-home-recent-title`, children: recent.title }),
5768
- recent.preview ? /* @__PURE__ */ jsx31("span", { class: `${p26}-home-recent-preview`, children: recent.preview }) : null
5713
+ recent ? /* @__PURE__ */ jsx30(HomeCard, { onClick: () => nav.selectSession(recent.sessionId), testid: TID.homeRecent, children: /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-recent-row`, "data-unread": (recent.unreadCount ?? 0) > 0 ? "true" : void 0, children: [
5714
+ /* @__PURE__ */ jsx30("span", { class: `${p25}-home-recent-avatar`, "aria-hidden": "true", children: /* @__PURE__ */ jsx30(BubblesIcon, {}) }),
5715
+ /* @__PURE__ */ jsxs24("span", { class: `${p25}-home-recent-body`, children: [
5716
+ /* @__PURE__ */ jsx30("span", { class: `${p25}-home-recent-title`, children: recent.title }),
5717
+ recent.preview ? /* @__PURE__ */ jsx30("span", { class: `${p25}-home-recent-preview`, children: recent.preview }) : null
5769
5718
  ] }),
5770
- (recent.unreadCount ?? 0) > 0 ? /* @__PURE__ */ jsx31("span", { class: `${p26}-home-recent-dot`, "aria-label": "Unread" }) : null
5719
+ (recent.unreadCount ?? 0) > 0 ? /* @__PURE__ */ jsx30("span", { class: `${p25}-home-recent-dot`, "aria-label": "Unread" }) : null
5771
5720
  ] }) }) : null,
5772
- status ? /* @__PURE__ */ jsx31(
5721
+ status ? /* @__PURE__ */ jsx30(
5773
5722
  HomeCard,
5774
5723
  {
5775
5724
  onClick: status.url ? () => nav.push({ kind: "iframe", url: status.url, title: status.text }) : void 0,
5776
- children: /* @__PURE__ */ jsxs25("div", { class: `${p26}-home-status`, "data-level": status.level ?? "operational", children: [
5777
- /* @__PURE__ */ jsx31("span", { class: `${p26}-home-status-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx31(StatusOkIcon, {}) }),
5778
- /* @__PURE__ */ jsx31("span", { class: `${p26}-home-status-text`, children: status.text })
5725
+ children: /* @__PURE__ */ jsxs24("div", { class: `${p25}-home-status`, "data-level": status.level ?? "operational", children: [
5726
+ /* @__PURE__ */ jsx30("span", { class: `${p25}-home-status-icon`, "aria-hidden": "true", children: /* @__PURE__ */ jsx30(StatusOkIcon, {}) }),
5727
+ /* @__PURE__ */ jsx30("span", { class: `${p25}-home-status-text`, children: status.text })
5779
5728
  ] })
5780
5729
  }
5781
5730
  ) : null,
5782
- content.length > 0 ? /* @__PURE__ */ jsxs25("section", { class: `${p26}-home-content`, children: [
5783
- /* @__PURE__ */ jsx31("div", { class: `${p26}-home-content-title`, children: contentTitle }),
5784
- /* @__PURE__ */ jsx31("div", { class: `${p26}-home-content-list`, children: content.map((item) => /* @__PURE__ */ jsx31(
5731
+ content.length > 0 ? /* @__PURE__ */ jsxs24("section", { class: `${p25}-home-content`, children: [
5732
+ /* @__PURE__ */ jsx30("div", { class: `${p25}-home-content-title`, children: contentTitle }),
5733
+ /* @__PURE__ */ jsx30("div", { class: `${p25}-home-content-list`, children: content.map((item) => /* @__PURE__ */ jsx30(
5785
5734
  ListRow,
5786
5735
  {
5787
5736
  title: item.title,
@@ -5797,13 +5746,13 @@ function HomeRoot(props2) {
5797
5746
  }
5798
5747
  var homeLayout = {
5799
5748
  Icon: HomeIcon,
5800
- Root: (props2) => /* @__PURE__ */ jsx31(HomeRoot, { ...props2 })
5749
+ Root: (props2) => /* @__PURE__ */ jsx30(HomeRoot, { ...props2 })
5801
5750
  };
5802
5751
 
5803
5752
  // src/ui/modules/news.tsx
5804
5753
  import { useEffect as useEffect13, useState as useState10 } from "preact/hooks";
5805
- import { jsx as jsx32, jsxs as jsxs26 } from "preact/jsx-runtime";
5806
- var p27 = BRAND.cssPrefix;
5754
+ import { jsx as jsx31, jsxs as jsxs25 } from "preact/jsx-runtime";
5755
+ var p26 = BRAND.cssPrefix;
5807
5756
  var log14 = logger.scope("news");
5808
5757
  function NewsRoot({ transport, strings, config, nav, panelProps }) {
5809
5758
  const tags = config.contentTags;
@@ -5829,38 +5778,38 @@ function NewsRoot({ transport, strings, config, nav, panelProps }) {
5829
5778
  };
5830
5779
  }, [transport, tags, reloadKey]);
5831
5780
  function renderBody() {
5832
- if (state === "loading") return /* @__PURE__ */ jsx32(ModuleState, { message: strings.newsLoading, strings });
5781
+ if (state === "loading") return /* @__PURE__ */ jsx31(ModuleState, { message: strings.newsLoading, strings });
5833
5782
  if (state === "error") {
5834
- return /* @__PURE__ */ jsx32(ModuleState, { tone: "error", message: errorMsg, onRetry: () => setReloadKey((k) => k + 1), strings });
5783
+ return /* @__PURE__ */ jsx31(ModuleState, { tone: "error", message: errorMsg, onRetry: () => setReloadKey((k) => k + 1), strings });
5835
5784
  }
5836
- if (items.length === 0) return /* @__PURE__ */ jsx32(ModuleState, { message: strings.newsEmpty, strings });
5837
- return /* @__PURE__ */ jsx32("div", { class: `${p27}-news-list`, children: items.map((item) => /* @__PURE__ */ jsxs26(
5785
+ if (items.length === 0) return /* @__PURE__ */ jsx31(ModuleState, { message: strings.newsEmpty, strings });
5786
+ return /* @__PURE__ */ jsx31("div", { class: `${p26}-news-list`, children: items.map((item) => /* @__PURE__ */ jsxs25(
5838
5787
  "button",
5839
5788
  {
5840
5789
  type: "button",
5841
- class: `${p27}-news-card`,
5790
+ class: `${p26}-news-card`,
5842
5791
  onClick: () => nav.push({ kind: "content", id: item.id, title: item.title }),
5843
5792
  "data-testid": tid(TID.newsItem, item.id),
5844
5793
  children: [
5845
- item.image ? /* @__PURE__ */ jsx32("img", { class: `${p27}-news-hero`, src: item.image, alt: "", loading: "lazy" }) : null,
5846
- /* @__PURE__ */ jsxs26("span", { class: `${p27}-news-body`, children: [
5847
- item.tags && item.tags.length > 0 ? /* @__PURE__ */ jsx32("span", { class: `${p27}-news-tags`, children: item.tags.map((t) => /* @__PURE__ */ jsx32("span", { class: `${p27}-news-tag`, children: t }, t)) }) : null,
5848
- /* @__PURE__ */ jsx32("span", { class: `${p27}-news-title`, children: item.title }),
5849
- item.description ? /* @__PURE__ */ jsx32("span", { class: `${p27}-news-summary`, children: item.description }) : null
5794
+ item.image ? /* @__PURE__ */ jsx31("img", { class: `${p26}-news-hero`, src: item.image, alt: "", loading: "lazy" }) : null,
5795
+ /* @__PURE__ */ jsxs25("span", { class: `${p26}-news-body`, children: [
5796
+ item.tags && item.tags.length > 0 ? /* @__PURE__ */ jsx31("span", { class: `${p26}-news-tags`, children: item.tags.map((t) => /* @__PURE__ */ jsx31("span", { class: `${p26}-news-tag`, children: t }, t)) }) : null,
5797
+ /* @__PURE__ */ jsx31("span", { class: `${p26}-news-title`, children: item.title }),
5798
+ item.description ? /* @__PURE__ */ jsx31("span", { class: `${p26}-news-summary`, children: item.description }) : null
5850
5799
  ] })
5851
5800
  ]
5852
5801
  },
5853
5802
  item.id
5854
5803
  )) });
5855
5804
  }
5856
- return /* @__PURE__ */ jsxs26("div", { class: `${p27}-module`, children: [
5857
- /* @__PURE__ */ jsx32(TitleBar, { title: strings.newsTitle, actions: /* @__PURE__ */ jsx32(HeaderActions, { panelProps, variant: "plain" }) }),
5858
- /* @__PURE__ */ jsx32("div", { class: `${p27}-module-scroll`, children: renderBody() })
5805
+ return /* @__PURE__ */ jsxs25("div", { class: `${p26}-module`, children: [
5806
+ /* @__PURE__ */ jsx31(TitleBar, { title: strings.newsTitle, actions: /* @__PURE__ */ jsx31(HeaderActions, { panelProps, variant: "plain" }) }),
5807
+ /* @__PURE__ */ jsx31("div", { class: `${p26}-module-scroll`, children: renderBody() })
5859
5808
  ] });
5860
5809
  }
5861
5810
  var newsLayout = {
5862
5811
  Icon: NewsIcon,
5863
- Root: (props2) => /* @__PURE__ */ jsx32(NewsRoot, { ...props2 })
5812
+ Root: (props2) => /* @__PURE__ */ jsx31(NewsRoot, { ...props2 })
5864
5813
  };
5865
5814
 
5866
5815
  // src/ui/modules/registry.ts
@@ -5872,28 +5821,28 @@ var LAYOUTS = {
5872
5821
  };
5873
5822
 
5874
5823
  // src/ui/home-tab-bar.tsx
5875
- import { jsx as jsx33, jsxs as jsxs27 } from "preact/jsx-runtime";
5876
- var p28 = BRAND.cssPrefix;
5824
+ import { jsx as jsx32, jsxs as jsxs26 } from "preact/jsx-runtime";
5825
+ var p27 = BRAND.cssPrefix;
5877
5826
  function HomeTabBar({ modules, activeTab, strings, unreadCount, onSelect }) {
5878
- return /* @__PURE__ */ jsx33("nav", { class: `${p28}-tabbar`, role: "tablist", "aria-label": strings.panelTitle, children: modules.map((m) => {
5827
+ return /* @__PURE__ */ jsx32("nav", { class: `${p27}-tabbar`, role: "tablist", "aria-label": strings.panelTitle, children: modules.map((m) => {
5879
5828
  const Icon = LAYOUTS[m.layout].Icon;
5880
5829
  const selected = m.id === activeTab;
5881
5830
  const badge = m.layout === "chat" && unreadCount > 0 ? unreadCount > 9 ? "9+" : String(unreadCount) : null;
5882
- return /* @__PURE__ */ jsxs27(
5831
+ return /* @__PURE__ */ jsxs26(
5883
5832
  "button",
5884
5833
  {
5885
5834
  type: "button",
5886
5835
  role: "tab",
5887
5836
  "aria-selected": selected,
5888
- class: `${p28}-tab`,
5837
+ class: `${p27}-tab`,
5889
5838
  onClick: () => onSelect(m.id),
5890
5839
  "data-testid": tid(TID.tab, m.id),
5891
5840
  children: [
5892
- /* @__PURE__ */ jsxs27("span", { class: `${p28}-tab-icon`, "aria-hidden": "true", children: [
5893
- /* @__PURE__ */ jsx33(Icon, {}),
5894
- badge ? /* @__PURE__ */ jsx33("span", { class: `${p28}-tab-badge`, "data-testid": TID.tabBadge, children: badge }) : null
5841
+ /* @__PURE__ */ jsxs26("span", { class: `${p27}-tab-icon`, "aria-hidden": "true", children: [
5842
+ /* @__PURE__ */ jsx32(Icon, {}),
5843
+ badge ? /* @__PURE__ */ jsx32("span", { class: `${p27}-tab-badge`, "data-testid": TID.tabBadge, children: badge }) : null
5895
5844
  ] }),
5896
- /* @__PURE__ */ jsx33("span", { class: `${p28}-tab-label`, children: moduleLabel(strings, m.label) })
5845
+ /* @__PURE__ */ jsx32("span", { class: `${p27}-tab-label`, children: moduleLabel(strings, m.label) })
5897
5846
  ]
5898
5847
  },
5899
5848
  m.id
@@ -5902,12 +5851,12 @@ function HomeTabBar({ modules, activeTab, strings, unreadCount, onSelect }) {
5902
5851
  }
5903
5852
 
5904
5853
  // src/ui/iframe-view.tsx
5905
- import { jsx as jsx34, jsxs as jsxs28 } from "preact/jsx-runtime";
5906
- var p29 = BRAND.cssPrefix;
5854
+ import { jsx as jsx33, jsxs as jsxs27 } from "preact/jsx-runtime";
5855
+ var p28 = BRAND.cssPrefix;
5907
5856
  var SANDBOX = "allow-scripts allow-forms allow-popups allow-popups-to-escape-sandbox allow-downloads";
5908
5857
  function IframeView({ url, title, strings, onBack, actions }) {
5909
- return /* @__PURE__ */ jsxs28("div", { class: `${p29}-module`, children: [
5910
- /* @__PURE__ */ jsx34(
5858
+ return /* @__PURE__ */ jsxs27("div", { class: `${p28}-module`, children: [
5859
+ /* @__PURE__ */ jsx33(
5911
5860
  BackHeader,
5912
5861
  {
5913
5862
  title: title || strings.moduleBack,
@@ -5916,10 +5865,10 @@ function IframeView({ url, title, strings, onBack, actions }) {
5916
5865
  actions
5917
5866
  }
5918
5867
  ),
5919
- /* @__PURE__ */ jsx34(
5868
+ /* @__PURE__ */ jsx33(
5920
5869
  "iframe",
5921
5870
  {
5922
- class: `${p29}-content-frame`,
5871
+ class: `${p28}-content-frame`,
5923
5872
  src: url,
5924
5873
  title: title || "content",
5925
5874
  sandbox: SANDBOX,
@@ -5933,8 +5882,8 @@ function IframeView({ url, title, strings, onBack, actions }) {
5933
5882
 
5934
5883
  // src/ui/content-view.tsx
5935
5884
  import { useCallback as useCallback3, useEffect as useEffect14, useState as useState11 } from "preact/hooks";
5936
- import { jsx as jsx35, jsxs as jsxs29 } from "preact/jsx-runtime";
5937
- var p30 = BRAND.cssPrefix;
5885
+ import { jsx as jsx34, jsxs as jsxs28 } from "preact/jsx-runtime";
5886
+ var p29 = BRAND.cssPrefix;
5938
5887
  var log15 = logger.scope("content");
5939
5888
  function ContentView({ id, title, transport, strings, onBack, actions }) {
5940
5889
  const [item, setItem] = useState11(null);
@@ -5962,17 +5911,17 @@ function ContentView({ id, title, transport, strings, onBack, actions }) {
5962
5911
  };
5963
5912
  }, [transport, id, reloadKey]);
5964
5913
  function renderBody() {
5965
- if (failed) return /* @__PURE__ */ jsx35(ModuleState, { tone: "error", message: strings.errorGeneric, onRetry: retry, strings });
5966
- if (item === null) return /* @__PURE__ */ jsx35(ModuleState, { message: strings.contentLoading, strings });
5967
- return /* @__PURE__ */ jsxs29("article", { class: `${p30}-content`, "data-testid": TID.contentView, children: [
5968
- item.image ? /* @__PURE__ */ jsx35("img", { class: `${p30}-content-hero`, src: item.image, alt: "", loading: "lazy" }) : null,
5969
- item.description ? /* @__PURE__ */ jsx35("p", { class: `${p30}-content-subtitle`, children: item.description }) : null,
5970
- item.tags && item.tags.length > 0 ? /* @__PURE__ */ jsx35("span", { class: `${p30}-news-tags`, children: item.tags.map((t) => /* @__PURE__ */ jsx35("span", { class: `${p30}-news-tag`, children: t }, t)) }) : null,
5971
- /* @__PURE__ */ jsx35(StaticMarkdown, { text: item.content ?? "" })
5914
+ if (failed) return /* @__PURE__ */ jsx34(ModuleState, { tone: "error", message: strings.errorGeneric, onRetry: retry, strings });
5915
+ if (item === null) return /* @__PURE__ */ jsx34(ModuleState, { message: strings.contentLoading, strings });
5916
+ return /* @__PURE__ */ jsxs28("article", { class: `${p29}-content`, "data-testid": TID.contentView, children: [
5917
+ item.image ? /* @__PURE__ */ jsx34("img", { class: `${p29}-content-hero`, src: item.image, alt: "", loading: "lazy" }) : null,
5918
+ item.description ? /* @__PURE__ */ jsx34("p", { class: `${p29}-content-subtitle`, children: item.description }) : null,
5919
+ item.tags && item.tags.length > 0 ? /* @__PURE__ */ jsx34("span", { class: `${p29}-news-tags`, children: item.tags.map((t) => /* @__PURE__ */ jsx34("span", { class: `${p29}-news-tag`, children: t }, t)) }) : null,
5920
+ /* @__PURE__ */ jsx34(StaticMarkdown, { text: item.content ?? "" })
5972
5921
  ] });
5973
5922
  }
5974
- return /* @__PURE__ */ jsxs29("div", { class: `${p30}-module`, children: [
5975
- /* @__PURE__ */ jsx35(
5923
+ return /* @__PURE__ */ jsxs28("div", { class: `${p29}-module`, children: [
5924
+ /* @__PURE__ */ jsx34(
5976
5925
  BackHeader,
5977
5926
  {
5978
5927
  title: item?.title || title || strings.moduleBack,
@@ -5982,13 +5931,13 @@ function ContentView({ id, title, transport, strings, onBack, actions }) {
5982
5931
  testid: TID.backHeader
5983
5932
  }
5984
5933
  ),
5985
- /* @__PURE__ */ jsx35("div", { class: `${p30}-module-scroll`, "data-testid": TID.contentScroll, children: renderBody() })
5934
+ /* @__PURE__ */ jsx34("div", { class: `${p29}-module-scroll`, "data-testid": TID.contentScroll, children: renderBody() })
5986
5935
  ] });
5987
5936
  }
5988
5937
 
5989
5938
  // src/ui/messenger-home.tsx
5990
- import { jsx as jsx36, jsxs as jsxs30 } from "preact/jsx-runtime";
5991
- var p31 = BRAND.cssPrefix;
5939
+ import { jsx as jsx35, jsxs as jsxs29 } from "preact/jsx-runtime";
5940
+ var p30 = BRAND.cssPrefix;
5992
5941
  function MessengerHome({
5993
5942
  panelProps,
5994
5943
  enabledModules,
@@ -6056,12 +6005,12 @@ function MessengerHome({
6056
6005
  nav: moduleNav,
6057
6006
  panelProps
6058
6007
  });
6059
- const plainActions = /* @__PURE__ */ jsx36(HeaderActions, { panelProps, variant: "plain" });
6008
+ const plainActions = /* @__PURE__ */ jsx35(HeaderActions, { panelProps, variant: "plain" });
6060
6009
  let body;
6061
6010
  if (top?.kind === "iframe") {
6062
- body = /* @__PURE__ */ jsx36(IframeView, { url: top.url, title: top.title, strings, onBack: nav.pop, actions: plainActions });
6011
+ body = /* @__PURE__ */ jsx35(IframeView, { url: top.url, title: top.title, strings, onBack: nav.pop, actions: plainActions });
6063
6012
  } else if (top?.kind === "content") {
6064
- body = /* @__PURE__ */ jsx36(
6013
+ body = /* @__PURE__ */ jsx35(
6065
6014
  ContentView,
6066
6015
  {
6067
6016
  id: top.id,
@@ -6073,7 +6022,7 @@ function MessengerHome({
6073
6022
  }
6074
6023
  );
6075
6024
  } else if (activeModule?.layout === "chat") {
6076
- body = /* @__PURE__ */ jsx36(
6025
+ body = /* @__PURE__ */ jsx35(
6077
6026
  PanelContent,
6078
6027
  {
6079
6028
  ...panelProps,
@@ -6084,23 +6033,23 @@ function MessengerHome({
6084
6033
  );
6085
6034
  } else if (activeModule) {
6086
6035
  const Root = LAYOUTS[activeModule.layout].Root;
6087
- body = Root ? /* @__PURE__ */ jsx36(Root, { ...screenProps(activeModule) }, activeModule.id) : null;
6036
+ body = Root ? /* @__PURE__ */ jsx35(Root, { ...screenProps(activeModule) }, activeModule.id) : null;
6088
6037
  } else {
6089
6038
  body = null;
6090
6039
  }
6091
- return /* @__PURE__ */ jsxs30(
6040
+ return /* @__PURE__ */ jsxs29(
6092
6041
  "div",
6093
6042
  {
6094
6043
  ref: containerRef,
6095
- class: `${p31}-panel ${p31}-messenger`,
6044
+ class: `${p30}-panel ${p30}-messenger`,
6096
6045
  role: "dialog",
6097
6046
  "aria-modal": "false",
6098
6047
  "aria-label": strings.panelTitle,
6099
6048
  style: { position: "relative" },
6100
6049
  "data-testid": TID.messengerHome,
6101
6050
  children: [
6102
- /* @__PURE__ */ jsx36("div", { class: `${p31}-messenger-body`, children: body }),
6103
- showTabBar ? /* @__PURE__ */ jsx36(
6051
+ /* @__PURE__ */ jsx35("div", { class: `${p30}-messenger-body`, children: body }),
6052
+ showTabBar ? /* @__PURE__ */ jsx35(
6104
6053
  HomeTabBar,
6105
6054
  {
6106
6055
  modules: enabledModules,
@@ -6110,8 +6059,8 @@ function MessengerHome({
6110
6059
  onSelect: nav.switchTab
6111
6060
  }
6112
6061
  ) : null,
6113
- /* @__PURE__ */ jsx36(PoweredByBar, { poweredBy: options.poweredBy }),
6114
- options.size.resize?.enabled && !(activeModule?.layout === "chat" && !top) ? /* @__PURE__ */ jsx36(
6062
+ /* @__PURE__ */ jsx35(PoweredByBar, { poweredBy: options.poweredBy }),
6063
+ options.size.resize?.enabled && !(activeModule?.layout === "chat" && !top) ? /* @__PURE__ */ jsx35(
6115
6064
  ResizeGrip,
6116
6065
  {
6117
6066
  panelEl: containerRef.current,
@@ -6128,29 +6077,29 @@ function MessengerHome({
6128
6077
  }
6129
6078
 
6130
6079
  // src/ui/modules-empty.tsx
6131
- import { jsx as jsx37, jsxs as jsxs31 } from "preact/jsx-runtime";
6132
- var p32 = BRAND.cssPrefix;
6080
+ import { jsx as jsx36, jsxs as jsxs30 } from "preact/jsx-runtime";
6081
+ var p31 = BRAND.cssPrefix;
6133
6082
  function ModulesEmpty({ strings, onClose }) {
6134
- return /* @__PURE__ */ jsxs31(
6083
+ return /* @__PURE__ */ jsxs30(
6135
6084
  "div",
6136
6085
  {
6137
- class: `${p32}-panel ${p32}-modules-empty`,
6086
+ class: `${p31}-panel ${p31}-modules-empty`,
6138
6087
  role: "dialog",
6139
6088
  "aria-label": strings.panelTitle,
6140
6089
  "data-testid": TID.modulesEmpty,
6141
6090
  children: [
6142
- onClose ? /* @__PURE__ */ jsx37(
6091
+ onClose ? /* @__PURE__ */ jsx36(
6143
6092
  "button",
6144
6093
  {
6145
6094
  type: "button",
6146
- class: `${p32}-icon-btn ${p32}-modules-empty-close`,
6095
+ class: `${p31}-icon-btn ${p31}-modules-empty-close`,
6147
6096
  onClick: onClose,
6148
6097
  "aria-label": strings.close,
6149
6098
  title: strings.close,
6150
- children: /* @__PURE__ */ jsx37(CloseIcon, {})
6099
+ children: /* @__PURE__ */ jsx36(CloseIcon, {})
6151
6100
  }
6152
6101
  ) : null,
6153
- /* @__PURE__ */ jsx37("p", { class: `${p32}-modules-empty-text`, children: strings.modulesEmpty })
6102
+ /* @__PURE__ */ jsx36("p", { class: `${p31}-modules-empty-text`, children: strings.modulesEmpty })
6154
6103
  ]
6155
6104
  }
6156
6105
  );
@@ -6177,6 +6126,7 @@ function animateTypewriter(msg, text, charsPerSecond, abort) {
6177
6126
  part.textSig.value = text;
6178
6127
  part.doneSig.value = true;
6179
6128
  msg.status = "complete";
6129
+ msg.partsSig.value = [...msg.partsSig.value];
6180
6130
  resolve();
6181
6131
  };
6182
6132
  if (typeof requestAnimationFrame === "undefined") {
@@ -6221,9 +6171,9 @@ function useLauncherCallout({ callout, persistence }) {
6221
6171
  }
6222
6172
 
6223
6173
  // src/ui/app.tsx
6224
- import { jsx as jsx38, jsxs as jsxs32 } from "preact/jsx-runtime";
6174
+ import { jsx as jsx37, jsxs as jsxs31 } from "preact/jsx-runtime";
6225
6175
  var log16 = logger.scope("app");
6226
- var p33 = BRAND.cssPrefix;
6176
+ var p32 = BRAND.cssPrefix;
6227
6177
  function App({ options, hostElement, bus }) {
6228
6178
  const [persistence] = useState13(() => createPersistence(options.widgetId, options.storage));
6229
6179
  const [visitorId, setVisitorId] = useState13(() => persistence.getVisitorId());
@@ -6684,8 +6634,8 @@ function App({ options, hostElement, bus }) {
6684
6634
  if (!canSend) forms.fire("conversation-closed");
6685
6635
  }, [canSend, forms]);
6686
6636
  useEffect17(() => {
6687
- if (pageArea) forms.fire("page-area");
6688
- }, [pageArea, forms]);
6637
+ if (sessionReady && pageArea) forms.fire("page-area");
6638
+ }, [sessionReady, pageArea, forms]);
6689
6639
  const idleMs = useMemo3(() => {
6690
6640
  const secs = options.forms.list.flatMap((f) => f.triggers).filter((t) => t.kind === "idle").map((t) => Number(t.param));
6691
6641
  return secs.length ? Math.min(...secs) * 1e3 : 0;
@@ -6923,10 +6873,9 @@ function App({ options, hostElement, bus }) {
6923
6873
  bus.emit("suggestion", { text });
6924
6874
  void handleSend(text, []);
6925
6875
  },
6926
- // Active form: a blocking one replaces the composer (gate); a non-blocking
6927
- // one renders inline at the end of the transcript (card).
6928
- blockingForm: activeForm.value?.form.blocking ? activeForm.value.form : null,
6929
- inlineForm: activeForm.value && !activeForm.value.form.blocking ? activeForm.value.form : null,
6876
+ // Active form: replaces the composer as a gate and locks every chat action
6877
+ // until the visitor submits or (when skippable) skips.
6878
+ activeForm: activeForm.value?.form ?? null,
6930
6879
  onFormSubmit: forms.complete,
6931
6880
  onFormSkip: forms.skip,
6932
6881
  tool: toolInteraction
@@ -6941,12 +6890,12 @@ function App({ options, hostElement, bus }) {
6941
6890
  const renderSurface = (size) => {
6942
6891
  const closeable = isActionVisible("close", effectiveOptions.mode, size);
6943
6892
  if (enabledModules.length === 0) {
6944
- return /* @__PURE__ */ jsx38(ModulesEmpty, { strings: effectiveOptions.strings, onClose: closeable ? handleClose : void 0 });
6893
+ return /* @__PURE__ */ jsx37(ModulesEmpty, { strings: effectiveOptions.strings, onClose: closeable ? handleClose : void 0 });
6945
6894
  }
6946
6895
  if (enabledModules.length === 1 && enabledModules[0]?.layout === "chat") {
6947
- return /* @__PURE__ */ jsx38(Panel, { ...panelProps, panelSize: size });
6896
+ return /* @__PURE__ */ jsx37(Panel, { ...panelProps, panelSize: size });
6948
6897
  }
6949
- return /* @__PURE__ */ jsx38(
6898
+ return /* @__PURE__ */ jsx37(
6950
6899
  MessengerHome,
6951
6900
  {
6952
6901
  panelProps: { ...panelProps, panelSize: size, onClose: closeable ? handleClose : void 0 },
@@ -6964,7 +6913,7 @@ function App({ options, hostElement, bus }) {
6964
6913
  void handleSelectHistoryChat(chat.sessionId);
6965
6914
  };
6966
6915
  const messagesEnabled = enabledModules.some((m) => m.layout === "chat");
6967
- return /* @__PURE__ */ jsx38("div", { class: `${p33}-anchor`, children: /* @__PURE__ */ jsx38(
6916
+ return /* @__PURE__ */ jsx37("div", { class: `${p32}-anchor`, children: /* @__PURE__ */ jsx37(
6968
6917
  PageShell,
6969
6918
  {
6970
6919
  site: parsedSite,
@@ -6983,15 +6932,15 @@ function App({ options, hostElement, bus }) {
6983
6932
  }
6984
6933
  if (isInlineLike) {
6985
6934
  const inlineSize = options.mode === "standalone" ? "fullscreen" : panelSize;
6986
- return /* @__PURE__ */ jsx38("div", { class: `${p33}-anchor`, children: renderSurface(inlineSize) });
6935
+ return /* @__PURE__ */ jsx37("div", { class: `${p32}-anchor`, children: renderSurface(inlineSize) });
6987
6936
  }
6988
6937
  const drawerEdgeTab = options.mode === "drawer";
6989
6938
  const triggerOwnedByPage = options.mode === "modal";
6990
6939
  const launcherVisible = !triggerOwnedByPage && !options.launcher.hidden && (!isOpen || launcherLeaving);
6991
6940
  const calloutToRender = launcherVisible && !launcherLeaving && !calloutDismissed && !drawerEdgeTab ? effectiveOptions.launcher.callout : null;
6992
- return /* @__PURE__ */ jsxs32("div", { class: `${p33}-anchor`, "data-launcher-size": effectiveOptions.launcher.size, children: [
6941
+ return /* @__PURE__ */ jsxs31("div", { class: `${p32}-anchor`, "data-launcher-size": effectiveOptions.launcher.size, children: [
6993
6942
  isOpen ? renderSurface(panelSize) : null,
6994
- launcherVisible ? /* @__PURE__ */ jsx38(
6943
+ launcherVisible ? /* @__PURE__ */ jsx37(
6995
6944
  Launcher,
6996
6945
  {
6997
6946
  onToggle: handleOpen,
@@ -7001,7 +6950,7 @@ function App({ options, hostElement, bus }) {
7001
6950
  edgeTab: drawerEdgeTab
7002
6951
  }
7003
6952
  ) : null,
7004
- calloutToRender ? /* @__PURE__ */ jsx38(
6953
+ calloutToRender ? /* @__PURE__ */ jsx37(
7005
6954
  LauncherCallout,
7006
6955
  {
7007
6956
  callout: calloutToRender,