@floless/app 0.140.0 → 0.141.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.
@@ -7,7 +7,7 @@ description: >-
7
7
  two-phase Drawing Filter process: first prepare and save the deterministic Filter, then read only the
8
8
  selected evidence into model-global members, registered plan views, observations, and revision history.
9
9
  metadata:
10
- version: 0.59.7
10
+ version: 0.59.9
11
11
  ---
12
12
 
13
13
  # Steel Takeoff — read drawings into `steel.model/v2`
@@ -91,8 +91,13 @@ Do not read members before the user saves the Drawing Filter.
91
91
  The drawings and completed page identification remain attached; never replace or split the set merely
92
92
  because a preparation worker exceeded one attempt window.
93
93
  Never build, rename, or replace server-owned Filter geometry yourself.
94
- 2. Stop and ask the user to review the Filter in **Drawing Filter** and press **Save filter** in the
95
- top-right corner.
94
+ 2. Stop and ask the user to open **Drawing Filter**. Explain that a steel read may need more than
95
+ steel lines: member/profile marks, grid labels, location or scale dimensions, and relevant
96
+ detail/section callouts may be needed too. Tell them that while the Drawing Filter is open they
97
+ can ask FloLess's **AI Chat** on the left about any layer or the selection, or tell it what to
98
+ change. When it proposes ticks, they appear as a card to review, apply with **Apply selection**,
99
+ and Undo; nothing changes before that, and it never presses **Save filter**. Ask the user to review the
100
+ bright selected drawing items and press **Save filter** in the top-right corner only when satisfied.
96
101
  3. Only after Save, fetch the request and its saved Filter again, pin its ETag, and read members from
97
102
  elements that the saved selection keeps.
98
103
 
@@ -0,0 +1,168 @@
1
+ /* ──────────────────────────────────────────────────────────────────────────
2
+ Account menu — the avatar at the far right of the header.
3
+
4
+ The same menu floless.io shows under its avatar: the signed-in name and email, then Profile and
5
+ Settings (opened on floless.io in a new browser tab, like the sign-in screen's "Manage
6
+ subscription" link), then Sign Out. Who is signed in comes from GET /api/license/me — display
7
+ only, and only while the licence is valid; when nobody is, the avatar stays hidden.
8
+
9
+ Sign Out asks the leave guard first (web/leave-guard.js), because reloading onto the sign-in
10
+ screen would lose unsaved work exactly like stopping the app would.
11
+ ────────────────────────────────────────────────────────────────────────── */
12
+ (function () {
13
+ 'use strict';
14
+
15
+ var $btn = document.getElementById('account-btn');
16
+ var $menu = document.getElementById('account-menu');
17
+ if (!$btn || !$menu) return;
18
+ var $initials = document.getElementById('account-initials');
19
+ var $name = document.getElementById('account-name');
20
+ var $email = document.getElementById('account-email');
21
+ var $profile = document.getElementById('account-profile');
22
+ var $settings = document.getElementById('account-settings');
23
+ var $signOut = document.getElementById('account-sign-out');
24
+
25
+ /** floless.io's getUserInitials: first + last initial of the full name, else the email's first letter. */
26
+ function initialsFor(fullName, email) {
27
+ var names = String(fullName || '').trim().split(/\s+/).filter(Boolean);
28
+ if (names.length >= 2) return (names[0][0] + names[names.length - 1][0]).toUpperCase();
29
+ if (names.length === 1) return names[0][0].toUpperCase();
30
+ var e = String(email || '').trim();
31
+ return e ? e[0].toUpperCase() : '?';
32
+ }
33
+
34
+ function showInitials() {
35
+ var img = $btn.querySelector('img');
36
+ if (img) img.remove();
37
+ $initials.hidden = false;
38
+ }
39
+
40
+ function render(me) {
41
+ if (!me || !me.signedIn) { $btn.hidden = true; close(false); return; }
42
+ var who = me.fullName || me.email || '';
43
+ $initials.textContent = initialsFor(me.fullName, me.email);
44
+ $name.textContent = me.fullName || '';
45
+ $name.hidden = !me.fullName;
46
+ $email.textContent = me.email || '';
47
+ $email.hidden = !me.email;
48
+ $email.dataset.tip = me.email || '';
49
+ $btn.setAttribute('aria-label', who ? 'Account menu — signed in as ' + who : 'Account menu');
50
+ $btn.dataset.tip = who ? 'Signed in as ' + who : 'Your account';
51
+ if (me.profileUrl) $profile.href = me.profileUrl;
52
+ if (me.settingsUrl) $settings.href = me.settingsUrl;
53
+ var old = $btn.querySelector('img');
54
+ if (old) old.remove();
55
+ $initials.hidden = false;
56
+ if (me.avatarUrl && /^https:\/\//.test(me.avatarUrl)) {
57
+ var img = document.createElement('img');
58
+ img.alt = '';
59
+ img.referrerPolicy = 'no-referrer';
60
+ img.decoding = 'async';
61
+ // Initials stay until the photo has actually loaded; a broken photo falls back to them.
62
+ img.addEventListener('load', function () { $initials.hidden = true; img.hidden = false; });
63
+ img.addEventListener('error', showInitials);
64
+ img.hidden = true;
65
+ img.src = me.avatarUrl;
66
+ $btn.appendChild(img);
67
+ }
68
+ $btn.hidden = false;
69
+ }
70
+
71
+ async function load() {
72
+ try {
73
+ var r = await fetch('/api/license/me', { cache: 'no-store' });
74
+ render(r.ok ? await r.json() : null);
75
+ } catch (_) { /* offline: keep whatever was shown; the next load tries again */ }
76
+ }
77
+
78
+ /* ── open / close / keyboard ───────────────────────────────────────────── */
79
+
80
+ function items() { return Array.from($menu.querySelectorAll('.menu-item')).filter(function (i) { return !i.hidden; }); }
81
+
82
+ function open() {
83
+ if (typeof window.toggleMenu === 'function') window.toggleMenu(false); // one menu at a time
84
+ $menu.classList.add('show');
85
+ $btn.classList.add('open');
86
+ $btn.setAttribute('aria-expanded', 'true');
87
+ }
88
+ function close(returnFocus) {
89
+ if (!$menu.classList.contains('show')) return;
90
+ $menu.classList.remove('show');
91
+ $btn.classList.remove('open');
92
+ $btn.setAttribute('aria-expanded', 'false');
93
+ if (returnFocus) $btn.focus();
94
+ }
95
+
96
+ $btn.addEventListener('click', function (e) {
97
+ e.stopPropagation();
98
+ if ($menu.classList.contains('show')) close(false); else open();
99
+ });
100
+ // Opening from the keyboard lands on the first item, as a menu button should.
101
+ $btn.addEventListener('keydown', function (e) {
102
+ if (e.key === 'ArrowDown' || e.key === 'Enter' || e.key === ' ') {
103
+ e.preventDefault();
104
+ open();
105
+ var list = items();
106
+ if (list[0]) list[0].focus();
107
+ }
108
+ });
109
+ $menu.addEventListener('keydown', function (e) {
110
+ var list = items();
111
+ var at = list.indexOf(document.activeElement);
112
+ if (e.key === 'Escape') { e.preventDefault(); e.stopPropagation(); close(true); }
113
+ else if (e.key === 'ArrowDown') { e.preventDefault(); (list[(at + 1) % list.length] || list[0]).focus(); }
114
+ else if (e.key === 'ArrowUp') { e.preventDefault(); (list[(at - 1 + list.length) % list.length] || list[list.length - 1]).focus(); }
115
+ else if (e.key === 'Home') { e.preventDefault(); list[0].focus(); }
116
+ else if (e.key === 'End') { e.preventDefault(); list[list.length - 1].focus(); }
117
+ else if (e.key === 'Tab') close(false);
118
+ });
119
+ // Esc closes it wherever focus is (a mouse-opened menu leaves focus on the avatar, not inside).
120
+ document.addEventListener('keydown', function (e) {
121
+ if (e.key !== 'Escape' || !$menu.classList.contains('show') || $menu.contains(document.activeElement)) return;
122
+ e.preventDefault();
123
+ e.stopPropagation();
124
+ close(true);
125
+ }, true);
126
+ document.addEventListener('click', function (e) {
127
+ if ($menu.classList.contains('show') && !$menu.contains(e.target) && e.target !== $btn && !$btn.contains(e.target)) close(false);
128
+ });
129
+ // The ≡ menu and this one never stand open together.
130
+ var $hamburger = document.getElementById('menu-btn');
131
+ if ($hamburger) $hamburger.addEventListener('click', function () { close(false); });
132
+
133
+ $profile.addEventListener('click', function () { close(false); });
134
+ $settings.addEventListener('click', function () { close(false); });
135
+
136
+ var signingOut = false;
137
+ $signOut.addEventListener('click', async function () {
138
+ close(false);
139
+ if (signingOut) return;
140
+ var guard = window.flolessLeaveGuard;
141
+ signingOut = true;
142
+ // The sign-out request runs INSIDE the question (commit), which stays open and busy until the
143
+ // server answers — nothing can be edited in between, and a refusal is explained right there.
144
+ var go = guard ? await guard.confirm({ action: 'signout', returnFocus: $btn, commit: requestLogout }) : (await requestLogout()).ok;
145
+ if (!go) { signingOut = false; return; }
146
+ location.reload(); // lands on the sign-in screen
147
+ });
148
+ async function requestLogout() {
149
+ try {
150
+ var r = await fetch('/api/license/logout', { method: 'POST' });
151
+ if (r.ok) return { ok: true };
152
+ } catch (_) { /* unreachable server: ask below, which fails the same way */ }
153
+ // A refused sign-out can still have signed you out (the server clears the session even when a
154
+ // later clean-up step fails), so ask who is signed in rather than claiming you still are.
155
+ var who = null;
156
+ try {
157
+ var me = await fetch('/api/license/me', { cache: 'no-store' });
158
+ if (me.ok) who = await me.json();
159
+ } catch (_) { /* could not tell — say so below */ }
160
+ if (who && who.signedIn === false) return { ok: true };
161
+ if (who && who.signedIn === true) return { ok: false }; // the dialog's own "you are still signed in"
162
+ // Neither answer arrived: do not claim either way.
163
+ return { ok: false, message: 'FloLess could not tell whether you were signed out. Reload this tab to check; if you are still signed in, try Sign Out again.' };
164
+ }
165
+
166
+ window.flolessAccountMenu = { load: load, initialsFor: initialsFor };
167
+ load();
168
+ })();
package/dist/web/app.css CHANGED
@@ -537,6 +537,21 @@
537
537
  .left-pane-empty[hidden] { display: none; }
538
538
  .left-pane-section { min-height: 74px; display: flex; flex-direction: column; overflow: hidden; background: var(--surface); }
539
539
  .left-pane-section[hidden] { display: none; }
540
+ /* A decision takes priority over the model index while both sections are open. The
541
+ saved split is untouched, so closing the tray restores the person's layout. */
542
+ .left-pane-stack:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-tray > .ai-chat-approval:not(.ai-chat-approval-scope)):has(> .left-pane-section[data-left-section="model"]:not([hidden])) > .left-pane-section[data-left-section="narrative"] {
543
+ flex: 0 0 calc(100% - 85px) !important;
544
+ }
545
+ .left-pane-stack:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-tray > .ai-chat-approval:not(.ai-chat-approval-scope)):has(> .left-pane-section[data-left-section="model"]:not([hidden])) > .left-pane-section[data-left-section="model"] {
546
+ flex: 0 0 74px !important;
547
+ }
548
+ /* A low saved Chat ratio can clip the single-line Revoke grant at any viewport height. */
549
+ .left-pane-stack:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-scope):not(:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-tray > .ai-chat-approval:not(.ai-chat-approval-scope))) > .left-pane-section[data-left-section="narrative"] {
550
+ min-height: 290px;
551
+ }
552
+ .left-pane-stack:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-scope):not(:has(.ai-chat-shell:not(.history-open) .ai-chat-approval-tray > .ai-chat-approval:not(.ai-chat-approval-scope))) > .left-pane-section[data-left-section="model"] {
553
+ flex-shrink: 1 !important;
554
+ }
540
555
  .left-pane-section.drag-over { box-shadow: inset 0 2px 0 var(--accent); }
541
556
  .left-section-heading {
542
557
  height: 40px; flex: 0 0 40px; display: flex; align-items: center; gap: 8px;
@@ -559,7 +574,8 @@
559
574
  position: relative; height: 11px; flex: 0 0 11px; cursor: ns-resize; touch-action: none; background: var(--surface);
560
575
  }
561
576
  .left-pane-split::after { content: ""; position: absolute; left: 0; right: 0; top: 5px; height: 1px; background: var(--border); }
562
- .left-pane-split:hover::after, .left-pane-split:focus-visible::after, .left-pane-split.dragging::after { height: 2px; background: var(--accent); }
577
+ .left-pane-split:not([aria-disabled="true"]):hover::after, .left-pane-split:not([aria-disabled="true"]):focus-visible::after, .left-pane-split.dragging::after { height: 2px; background: var(--accent); }
578
+ .left-pane-split[aria-disabled="true"] { cursor: default; }
563
579
  .left-pane-split:focus-visible { outline: none; }
564
580
  body.left-pane-height-resizing, body.left-pane-height-resizing * { cursor: ns-resize !important; user-select: none; }
565
581
  body.left-pane-height-resizing iframe { pointer-events: none; }
@@ -1811,24 +1827,31 @@
1811
1827
  #project-setup-folder-choose:focus-visible { border-color:var(--accent); outline:none;
1812
1828
  box-shadow:0 0 0 2px var(--accent-soft); }
1813
1829
  .project-setup-note { color:var(--text-dim); font-size:11px; line-height:1.45; }
1814
- .project-setup-standard-options { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
1815
- .project-setup-standard-options button { display:grid; gap:3px; min-width:0; padding:9px 10px;
1830
+ /* The AI Chat choice (#1605) is the same held one-of-two choice as the Standard, so it wears the
1831
+ same toggle; its sign-in line sits under the pair, as it does in the AI Chat empty state. */
1832
+ .project-setup-standard-options, .project-setup-provider-options, .project-setup-provider-accounts {
1833
+ display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
1834
+ .project-setup-standard-options button, .project-setup-provider-options button { display:grid; gap:3px; min-width:0; padding:9px 10px;
1816
1835
  text-align:left; border:1px solid var(--border-strong); background:var(--surface-2); color:var(--text-muted); }
1817
- .project-setup-standard-options button:hover { color:var(--text); border-color:var(--accent-dim); }
1818
- .project-setup-standard-options button[aria-pressed="true"] { color:var(--text); border-color:var(--accent);
1819
- background:var(--accent-soft); box-shadow:inset 2px 0 0 var(--accent); }
1836
+ .project-setup-standard-options button:hover, .project-setup-provider-options button:not([aria-disabled="true"]):hover {
1837
+ color:var(--text); border-color:var(--accent-dim); }
1838
+ .project-setup-standard-options button[aria-pressed="true"], .project-setup-provider-options button[aria-pressed="true"] {
1839
+ color:var(--text); border-color:var(--accent); background:var(--accent-soft); box-shadow:inset 2px 0 0 var(--accent); }
1840
+ .project-setup-provider-options button { font-weight:650; }
1841
+ /* aria-disabled, not disabled: a provider that is not installed stays focusable so its data-tip
1842
+ can say why it cannot be chosen. */
1843
+ .project-setup-provider-options button[aria-disabled="true"] { cursor:default; opacity:.45; }
1844
+ .project-setup-provider-accounts { margin-top:-2px; color:var(--text-dim); font:9.5px/1.4 var(--mono); }
1845
+ .project-setup-provider-accounts > span { min-width:0; overflow-wrap:anywhere; }
1820
1846
  .project-setup-standard-options button > span:last-child { color:var(--text-dim); font-size:10px; }
1821
1847
  .project-setup-standard-label { font-weight:650; }
1822
1848
  .project-setup-storage-note { margin-top:14px; padding:10px 11px; border-left:2px solid var(--accent-dim);
1823
1849
  background:color-mix(in srgb, var(--accent) 5%, transparent); color:var(--text-muted);
1824
1850
  font-size:11px; line-height:1.5; }
1825
- .project-setup-chat-meta { margin:10px 0 -4px; color:var(--text-dim); font:10px/1.4 var(--mono);
1826
- text-align:right; }
1827
- .project-setup-chat-meta[hidden] { display:none; }
1828
1851
  .project-setup-error { margin-top:12px; padding:8px 10px; border:1px solid color-mix(in srgb, var(--err) 45%, var(--border));
1829
1852
  border-radius:5px; background:color-mix(in srgb, var(--err) 8%, transparent); color:var(--err);
1830
1853
  font-size:11px; line-height:1.45; }
1831
- .project-setup-error[hidden], .project-setup-standard[hidden] { display:none; }
1854
+ .project-setup-error[hidden], .project-setup-standard[hidden], .project-setup-provider[hidden] { display:none; }
1832
1855
  #project-setup-modal[aria-busy="true"] .project-setup-dialog { cursor:wait; }
1833
1856
  @media (max-width:560px) {
1834
1857
  .project-setup-standard-options { grid-template-columns:1fr; }
@@ -2130,6 +2153,9 @@
2130
2153
  .int-account-reason { grid-column: 1 / -1; font-size: 9px; line-height: 1.35; color: var(--text-dim); }
2131
2154
  .int-account-empty { font-size: 9px; line-height: 1.4; color: var(--text-dim); }
2132
2155
  .int-load-failed { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; gap: 10px; }
2156
+ /* One clipped line for an OAuth row's endpoint list; offerClippedScopeLines() (aware.js) gives a
2157
+ line that actually overflows a data-tip + tab stop so it is never a dead end (#1524). A setup or
2158
+ status sentence the person must read wraps instead (.int-setup-detail). */
2133
2159
  .int-scopes {
2134
2160
  font-family: var(--mono);
2135
2161
  font-size: 10px;
@@ -2350,6 +2376,10 @@
2350
2376
  scrollport there. */
2351
2377
  scroll-margin-block: 8px;
2352
2378
  }
2379
+ /* A row holds focus when the control that had it is gone after a repaint (#1594) or a Stop.
2380
+ The shared ring sits 2px OUTSIDE its element, where the list's scrollport clips it to one edge;
2381
+ inside the row it reads whole. */
2382
+ .req-item:focus-visible { outline-offset: -2px; }
2353
2383
  .req-info { flex: 1; min-width: 0; }
2354
2384
  .req-head { font-size: 12px; color: var(--text-dim); display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
2355
2385
  .req-head code { font-family: var(--mono); color: var(--text-muted); }
@@ -2642,6 +2672,9 @@
2642
2672
  .req-run-output > summary::before { content: '▸ '; font-size: 9px; }
2643
2673
  .req-run-output[open] > summary::before { content: '▾ '; }
2644
2674
  .req-run-output > summary:hover { color: var(--text-muted); }
2675
+ /* The shared ring, as .req-technical's summary has it: without one Chrome draws its own white ring,
2676
+ and keyboard focus now stays on this summary while a running request repaints the list (#1594). */
2677
+ .req-run-output > summary:focus-visible { color: var(--text); outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }
2645
2678
  .req-run-output pre {
2646
2679
  margin: 6px 0 0; padding: 7px 9px; max-height: 120px; overflow: auto;
2647
2680
  background: var(--bg); border: 1px solid var(--border); border-radius: 4px;
@@ -2731,6 +2764,10 @@
2731
2764
  .int-rt-badge { font-size: 9px; text-transform: uppercase; letter-spacing: 0.1em; font-weight: 600;
2732
2765
  padding: 2px 8px; border-radius: 10px; background: var(--surface-3); color: var(--text-muted); }
2733
2766
  .int-rt.is-missing .int-rt-badge { color: var(--text-dim); }
2767
+ /* A setup that failed claims no readiness, so it may say so; every other state stays neutral. */
2768
+ .int-rt-badge.is-warn, .int-rt.is-missing .int-rt-badge.is-warn { color: var(--warn); }
2769
+ /* FloLess's own copy (#1622): a sentence, not a path — prose type that wraps instead of truncating. */
2770
+ .int-rt-copy { font-size: 10px; color: var(--text-dim); margin-top: 3px; line-height: 1.45; overflow-wrap: anywhere; }
2734
2771
  .int-rt-side { display: flex; align-items: center; gap: 7px; }
2735
2772
  .int-folder { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border);
2736
2773
  display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--text-muted); }
@@ -3345,6 +3382,75 @@
3345
3382
  background: var(--border);
3346
3383
  margin: 5px 4px;
3347
3384
  }
3385
+ /* "Stop FloLess" — the one ≡ row that ends something, so it reads as such at rest (--err is the
3386
+ palette's only red; no new colour). It always asks first, so this is a signal, not a trap. */
3387
+ .menu-item-danger, .menu-item-danger .menu-icon { color: var(--err); }
3388
+ .menu-item-danger:hover { background: color-mix(in srgb, var(--err) 10%, transparent); }
3389
+ /* Profile / Settings are links (they open floless.io), styled exactly as the button rows. */
3390
+ a.menu-item { text-decoration: none; }
3391
+ .menu-item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
3392
+
3393
+ /* ── Account menu (web/account-menu.js) — floless.io's avatar dropdown, in this skin ── */
3394
+ /* The header is space-between with two children; the avatar makes three, so the controls take the
3395
+ free space themselves and the avatar sits at the far right, as on floless.io. */
3396
+ header > .controls { margin-left: auto; }
3397
+ .account-btn {
3398
+ flex-shrink: 0;
3399
+ width: 28px; height: 28px; margin-left: 14px; padding: 0;
3400
+ border-radius: 50%;
3401
+ border: 1px solid var(--border-strong);
3402
+ background: var(--accent-soft);
3403
+ color: var(--accent-bright);
3404
+ display: inline-flex; align-items: center; justify-content: center;
3405
+ overflow: hidden; cursor: pointer;
3406
+ font: 600 11px/1 var(--ui); letter-spacing: 0.02em;
3407
+ }
3408
+ .account-btn:hover, .account-btn.open { border-color: var(--accent-dim); }
3409
+ .account-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
3410
+ .account-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }
3411
+ .account-menu { left: auto; right: 12px; width: 224px; }
3412
+ .account-id { padding: 6px 9px 5px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
3413
+ .account-name { font: 500 13px/1.35 var(--ui); color: var(--text); overflow-wrap: anywhere; }
3414
+ .account-email { font: 400 11px/1.35 var(--ui); color: var(--text-muted);
3415
+ white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
3416
+
3417
+ /* ── Leave guard (web/leave-guard.js) — the #confirm-modal look, plus the unsaved list ── */
3418
+ .modal.leave-guard { width: min(480px, calc(100vw - 32px)); }
3419
+ .leave-guard-unsaved {
3420
+ margin-top: 12px; max-height: 240px; overflow: auto; padding: 8px 12px;
3421
+ border: 1px solid var(--border-strong); border-radius: 5px; background: var(--surface-2);
3422
+ scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent;
3423
+ }
3424
+ .leave-guard-unsaved::-webkit-scrollbar { width: 9px; height: 9px; }
3425
+ .leave-guard-unsaved::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 5px; }
3426
+ .leave-guard-unsaved::-webkit-scrollbar-track { background: transparent; }
3427
+ .leave-guard-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
3428
+ .leave-guard-list li { font: 12.5px/1.45 var(--ui); color: var(--text-muted); padding-left: 12px; position: relative; }
3429
+ .leave-guard-list li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 5px; height: 5px;
3430
+ border-radius: 50%; background: var(--warn); }
3431
+ .leave-guard-list li strong { color: var(--text); font-weight: 600; }
3432
+ .leave-guard-list li.lg-failed::before { background: var(--err); }
3433
+ .leave-guard-list .lg-why { display: block; color: var(--err); font-size: 12px; margin-top: 2px; }
3434
+ .leave-guard-note { margin: 10px 0 0; font: 12.5px/1.45 var(--ui); color: var(--text); }
3435
+ .leave-guard-running { margin: 12px 0 0; padding: 6px 10px; border-left: 2px solid var(--warn);
3436
+ background: color-mix(in srgb, var(--warn) 8%, transparent); font: 12.5px/1.45 var(--ui); color: var(--text); }
3437
+
3438
+ /* ── "FloLess has stopped" — the terminal screen after Stop FloLess (the sign-in gate's recipe) ── */
3439
+ #app-stopped { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center;
3440
+ background: var(--bg); color: var(--text); font-family: var(--ui); padding: 16px; }
3441
+ #app-stopped .as-card { max-width: 420px; text-align: center; padding: 40px 36px; border-radius: 14px;
3442
+ background: var(--surface); border: 1px solid var(--border); box-shadow: 0 20px 60px rgba(0,0,0,.35); }
3443
+ #app-stopped .as-card:focus { outline: none; }
3444
+ #app-stopped .as-mark { color: var(--text-dim); width: 54px; height: 51px; margin: 0 auto 18px; }
3445
+ #app-stopped .as-mark svg { width: 100%; height: 100%; display: block; }
3446
+ #app-stopped .as-mark .mark-node { fill: var(--surface); }
3447
+ #app-stopped h1 { font-size: 20px; margin: 0 0 8px; font-weight: 600; }
3448
+ #app-stopped p { font-size: 14px; line-height: 1.5; color: var(--text-muted); margin: 0 0 22px; }
3449
+ #app-stopped .as-start { display: inline-block; font-size: 13px; font-weight: 600; color: var(--accent-bright);
3450
+ text-decoration: none; padding: 8px 16px; border: 1px solid var(--border-strong); border-radius: 8px; }
3451
+ #app-stopped .as-start:hover { border-color: var(--accent); }
3452
+ #app-stopped .as-start:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
3453
+ #app-stopped .as-status { min-height: 18px; margin: 14px 0 0; font-size: 12.5px; }
3348
3454
  /* Checkmarked menu items use the app's existing accent-active dialect
3349
3455
  (.code-wrap-btn.active, .tf-chip.active). The icon recolors to accent-bright and a trailing check
3350
3456
  confirms it — mirroring the trailing .menu-kbd slot the action items already reserve on the
@@ -5180,7 +5286,10 @@ body {
5180
5286
  .mode-switch button.active { background:var(--accent-soft); color:var(--accent-bright); }
5181
5287
  .mode-switch button[aria-busy="true"] { display:inline-flex; align-items:center; gap:6px; color:var(--text); cursor:wait; }
5182
5288
  .mode-switch button[aria-busy="true"] .rtn-spinner { width:10px; height:10px; border-width:2px; }
5183
- .mode-switch button[aria-disabled="true"] { pointer-events:none; }
5289
+ /* The pending tab deliberately keeps its pointer events (#1489): pointer-events:none would hide the
5290
+ cursor:wait above, because the pointer would fall through to the switch. setMode() already ignores a
5291
+ re-click while aria-busy="true". Its aria-disabled="true" is the blocked signal for screen readers
5292
+ and for Instructor, which narrates its data-blocked-reason. */
5184
5293
 
5185
5294
  /* Mode gating: Workflows chrome hides wholesale in Workspaces (hidden, never disabled).
5186
5295
  ≡ keeps only app-wide items; Dashboard is Workflows-scoped (spec §2).
package/dist/web/app.js CHANGED
@@ -1388,6 +1388,8 @@ function handleMenuAction(action) {
1388
1388
  case 'routines': openRoutines(); break;
1389
1389
  case 'report-issue': openReportIssue(); break;
1390
1390
  case 'fullscreen': toggleFullscreen(); break;
1391
+ // Asks first (unsaved work, a running workflow) — see web/leave-guard.js.
1392
+ case 'stop-app': if (window.flolessLeaveGuard) window.flolessLeaveGuard.stopApp(); break;
1391
1393
  }
1392
1394
  }
1393
1395