@floless/app 0.174.1 → 0.175.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/autostart.mjs +117 -10
  2. package/dist/floless-server.cjs +2 -2
  3. package/dist/pdf-engine/floless_pdf/__init__.py +7 -3
  4. package/dist/pdf-engine/floless_pdf/backend_pdfium.py +292 -13
  5. package/dist/pdf-engine/floless_pdf/backend_pymupdf.py +25 -3
  6. package/dist/pdf-engine/floless_pdf/images.py +4 -3
  7. package/dist/pdf-engine/floless_pdf/pages.py +136 -0
  8. package/dist/schemas/steel.model.v2.schema.json +44 -1
  9. package/dist/skills/floless-app-approval/SKILL.md +28 -3
  10. package/dist/skills/floless-app-knowledge/SKILL.md +3 -2
  11. package/dist/skills/floless-app-sketches/SKILL.md +71 -0
  12. package/dist/skills/floless-app-sketches/references/steel-plate.md +15 -0
  13. package/dist/skills/floless-app-steel-model/SKILL.md +11 -1
  14. package/dist/skills/floless-app-steel-model/references/elements.md +90 -23
  15. package/dist/skills/floless-app-steel-takeoff/SKILL.md +11 -6
  16. package/dist/web/agents.js +1 -1
  17. package/dist/web/app.css +120 -15
  18. package/dist/web/app.js +89 -38
  19. package/dist/web/aware-hold.js +10 -0
  20. package/dist/web/aware.js +405 -51
  21. package/dist/web/boot-watchdog.js +249 -0
  22. package/dist/web/card-details.js +88 -0
  23. package/dist/web/chat.css +29 -0
  24. package/dist/web/chat.js +430 -128
  25. package/dist/web/commands-connection-design.js +23 -0
  26. package/dist/web/commands-revit.js +3 -0
  27. package/dist/web/commands-shell.js +226 -10
  28. package/dist/web/commands-steel.js +93 -4
  29. package/dist/web/commands-tekla-parser.js +21 -1
  30. package/dist/web/connection-design-editor.html +71 -0
  31. package/dist/web/connection-design-editor.js +794 -61
  32. package/dist/web/connection-design-handles.js +9 -3
  33. package/dist/web/element-approval.js +74 -0
  34. package/dist/web/element-context.js +76 -6
  35. package/dist/web/element-geometry.js +8 -2
  36. package/dist/web/element-holds.js +68 -5
  37. package/dist/web/element-type-actions.js +22 -3
  38. package/dist/web/element-types.js +12 -5
  39. package/dist/web/element-words.js +15 -11
  40. package/dist/web/grid-place.js +51 -0
  41. package/dist/web/guide.js +2 -0
  42. package/dist/web/index.html +13 -16
  43. package/dist/web/instructor.js +5 -2
  44. package/dist/web/missed-routines.js +6 -1
  45. package/dist/web/model-change-findings.js +100 -30
  46. package/dist/web/model-change-review.js +411 -27
  47. package/dist/web/model-clash-check.css +100 -0
  48. package/dist/web/model-clash-check.js +681 -0
  49. package/dist/web/model-clip-box.js +204 -0
  50. package/dist/web/model-clip-list.js +153 -3
  51. package/dist/web/model-clip-session.js +3 -3
  52. package/dist/web/model-clip-three-overlay.js +135 -25
  53. package/dist/web/model-editor.css +2 -0
  54. package/dist/web/model-elements.js +273 -18
  55. package/dist/web/model-fit-checks.js +354 -0
  56. package/dist/web/model-spatial-panel.js +9 -3
  57. package/dist/web/model-spatial-tools.js +12 -3
  58. package/dist/web/model-tekla-selection.js +74 -0
  59. package/dist/web/model-view-query.js +70 -14
  60. package/dist/web/model-viewport-revit-adapter.js +8 -7
  61. package/dist/web/model-viewport-toolbar.js +8 -4
  62. package/dist/web/pages.js +78 -1
  63. package/dist/web/project-history.js +31 -1
  64. package/dist/web/revit-editor.css +34 -1
  65. package/dist/web/revit-editor.js +174 -55
  66. package/dist/web/run-history.js +8 -0
  67. package/dist/web/sketch-editor.js +141 -2
  68. package/dist/web/sketches.js +192 -6
  69. package/dist/web/start-place.js +46 -0
  70. package/dist/web/steel-3d-core.js +70 -0
  71. package/dist/web/steel-3d-view.js +288 -47
  72. package/dist/web/steel-change-review.css +28 -0
  73. package/dist/web/steel-custom-connection.js +6 -0
  74. package/dist/web/steel-editor.html +532 -33
  75. package/dist/web/steel-filter.html +8 -3
  76. package/dist/web/steel-model-checks.css +76 -0
  77. package/dist/web/steel-model-v2-commands.js +17 -0
  78. package/dist/web/steel-view-generation.js +6 -2
  79. package/dist/web/teams.js +259 -19
  80. package/dist/web/tekla-editor.html +1 -0
  81. package/dist/web/terminal-requests.js +6 -0
  82. package/dist/web/vendor/connection-engine.js +886 -91
  83. package/dist/web/workspaces.js +630 -48
  84. package/package.json +2 -1
  85. package/preferences-file.mjs +27 -0
package/dist/web/app.css CHANGED
@@ -2533,6 +2533,44 @@
2533
2533
  /* A waiting action must not light up under the pointer like a live one. Mirrors the chat
2534
2534
  Provider row's `.ai-chat-provider-switch:disabled` so the two sign-in surfaces read alike. */
2535
2535
  .int-action:disabled { cursor: default; color: var(--text-dim); border-color: var(--border); background: var(--surface); }
2536
+ /* The one choice a question recommends: the accent, from the baseline's own tokens, in both themes. */
2537
+ .int-action.primary { color: var(--accent-bright); border-color: var(--accent-dim); background: var(--accent-soft); }
2538
+ .int-action.primary:not(:disabled):hover { color: var(--text); border-color: var(--accent); background: var(--accent-soft); }
2539
+ .int-action:focus-visible, .int-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
2540
+ /* A small text action inside a line (Open to restart, Dismiss): a link look, a button underneath. */
2541
+ .int-link {
2542
+ font: inherit; font-size: 9px; padding: 0; border: 0; background: none; cursor: pointer;
2543
+ color: var(--accent-bright); text-decoration: underline; text-underline-offset: 2px; border-radius: 2px;
2544
+ }
2545
+ .int-link:hover { color: var(--accent); }
2546
+ /* #2470 R6.8 slice 4: a Microsoft 365 account's "Read Teams channel messages" switch (the shared .kb-toggle), the line
2547
+ under it, and what the last click did. Spans in the account grid's full width, so long names wrap, never overflow. */
2548
+ .int-chread { grid-column: 1 / -1; display: grid; gap: 3px; padding-top: 5px; border-top: 1px dashed var(--border); min-width: 0; }
2549
+ .int-chread-switch { display: inline-flex; align-items: center; gap: 7px; }
2550
+ .int-chread-switch .kb-toggle { flex-shrink: 0; }
2551
+ .int-chread-label { font-size: 10px; color: var(--text); }
2552
+ .int-chread-line { font-size: 9px; line-height: 1.4; color: var(--text-muted); overflow-wrap: anywhere; }
2553
+ .int-chread-line:empty, .int-chread-note:empty { display: none; }
2554
+ .int-chread-act { justify-self: start; }
2555
+ .int-chread-note { display: grid; gap: 4px; font-size: 9px; line-height: 1.4; color: var(--text-muted); overflow-wrap: anywhere; }
2556
+ .int-chread-saved { color: var(--ok); }
2557
+ .int-chread-error { color: var(--warn); }
2558
+ .int-chread-explain { padding: 5px 7px; border-left: 3px solid var(--accent-dim); border-radius: 0 4px 4px 0;
2559
+ background: color-mix(in srgb, var(--accent) 6%, var(--surface)); }
2560
+ .int-chread-choices { display: inline-flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
2561
+ .int-chread-stopped-head { color: var(--text); }
2562
+ .int-chread-stopped { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; max-height: 120px; overflow: auto;
2563
+ scrollbar-width: thin; scrollbar-color: var(--border-strong) transparent; }
2564
+ .int-chread-stopped::-webkit-scrollbar { width: 8px; }
2565
+ .int-chread-stopped::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 4px; }
2566
+ .int-chread-stopped::-webkit-scrollbar-track { background: transparent; }
2567
+ .int-chread-stopped li { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
2568
+ .int-chread-watcher { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
2569
+ .int-chread-dismiss { justify-self: start; }
2570
+ /* The Connect question and the sign-in choices, in the card's sign-in line. */
2571
+ .int-devicecode .int-chread-question { display: block; color: var(--text); }
2572
+ .int-devicecode .int-chread-choices { display: flex; margin-top: 6px; }
2573
+ .int-devicecode .int-chread-hint { display: block; font-size: 9px; color: var(--text-dim); margin-top: 4px; }
2536
2574
 
2537
2575
  /* ========== FOOTER ========== */
2538
2576
  footer {
@@ -3945,6 +3983,10 @@
3945
3983
  z-index: 50;
3946
3984
  display: none;
3947
3985
  animation: menu-in 0.16s ease-out;
3986
+ /* Short window or browser tab: the menu scrolls inside itself (themed by the global scrollbar rule) (#4091). */
3987
+ max-height: calc(100vh - var(--header-h) - 8px);
3988
+ overflow-y: auto;
3989
+ overscroll-behavior: contain;
3948
3990
  }
3949
3991
  .menu.show { display: block; }
3950
3992
  @keyframes menu-in {
@@ -4353,10 +4395,14 @@
4353
4395
  font-size: 12px;
4354
4396
  color: var(--text);
4355
4397
  }
4356
- /* The Start-on-startup row reuses .menu-theme (display:flex), which overrides its
4357
- `hidden` attribute, so it showed even when unsupported (dev/non-Windows). Restore
4358
- the hide with a class+attribute selector (higher specificity than .menu-theme). */
4359
- .menu-startup[hidden] { display: none; }
4398
+ /* The menu row and controls set display explicitly, so enforce their hidden states. */
4399
+ .menu-startup[hidden], .menu-startup .rtn-toggle[hidden] { display: none; }
4400
+ .menu-startup { display: grid; grid-template-columns: 1fr auto; row-gap: 4px; }
4401
+ .menu-startup:has(#startup-status:not([hidden])) .menu-label { cursor: default; }
4402
+ .startup-choices { grid-column: 1 / -1; justify-self: end; }
4403
+ .startup-choices[hidden] { display: none; }
4404
+ #startup-status { color: var(--text-muted); }
4405
+ #startup-status:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
4360
4406
  /* #2448: the AI note switch for every workflow's reports, with its plain hint under it (a hover tip is easy to miss). */
4361
4407
  .menu-ai-note[hidden], .menu-run-notify[hidden] { display: none; }
4362
4408
  .menu-ai-note-hint { margin: -4px 9px 6px; font-size: 11px; line-height: 1.4; color: var(--text-dim); }
@@ -4389,7 +4435,7 @@
4389
4435
  }
4390
4436
  /* #2399: "Suggestions" On / Quiet / Off in the ≡ menu: the Theme segmented look with text labels. Its own class, so
4391
4437
  the theme buttons' click handler never sees these. */
4392
- .suggest-btn, .client-btn {
4438
+ .suggest-btn, .client-btn, .startup-btn {
4393
4439
  background: transparent;
4394
4440
  border: none;
4395
4441
  min-width: 38px;
@@ -4401,12 +4447,13 @@
4401
4447
  border-radius: 3px;
4402
4448
  cursor: pointer;
4403
4449
  }
4404
- .suggest-btn:hover, .client-btn:hover { color: var(--text); }
4450
+ .suggest-btn:hover, .client-btn:hover, .startup-btn:hover:enabled { color: var(--text); }
4451
+ .startup-btn:disabled { opacity: .6; cursor: default; }
4405
4452
  .suggest-btn.active, .client-btn.active {
4406
4453
  background: var(--accent);
4407
4454
  color: white;
4408
4455
  }
4409
- .suggest-btn:focus-visible, .client-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
4456
+ .suggest-btn:focus-visible, .client-btn:focus-visible, .startup-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
4410
4457
  /* "Open FloLess in" / "Keep FloLess in the tray" reuse .menu-theme (display:flex), which overrides `hidden`. */
4411
4458
  .menu-client[hidden], .menu-tray[hidden] { display: none; }
4412
4459
  /* #3420: Hold AWARE updates. The "Keep vX held" choice appears under the hint only when AWARE changed while held. */
@@ -6462,6 +6509,27 @@ body.mode-workspaces #menu .menu-item[data-action="bake"] { display:none; }
6462
6509
  .sketches .sketches-input { flex:1; min-width:160px; color:var(--text); background:var(--surface-2); border:1px solid var(--border-strong); border-radius:5px; padding:6px 8px; font:inherit; font-size:12px; }
6463
6510
  .sketches .sketches-input:focus-visible { outline:2px solid var(--accent); outline-offset:1px; border-color:var(--accent-dim); }
6464
6511
  @media (prefers-reduced-motion: reduce) { .sketches button.sketches-switch .sketches-knob { transition:none; } }
6512
+ /* Sketches S1c (#3643): Show converted, the stale-reference choices, each shape's conversion state, the Conversions history. */
6513
+ .sketches .sketches-converted { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:8px 4px 2px; margin-top:6px; border-top:1px solid var(--border); font-size:11px; color:var(--text-muted); }
6514
+ .sketches .sketches-converted[hidden] { display:none; }
6515
+ .sketches .sketches-converted button.sketches-switch { margin-top:0; }
6516
+ .sketches .sketches-choices { flex-basis:100%; display:flex; flex-wrap:wrap; gap:6px; }
6517
+ .sketches .sketches-reference[data-verdict="unknown"] { border-left-color:var(--border-strong); background:var(--surface-2); }
6518
+ .sketches .sketches-convert-note { border-left:3px solid var(--warn); background:color-mix(in srgb, var(--warn) 7%, transparent); padding:9px 12px; border-radius:0 4px 4px 0; font-size:12px; display:flex; flex-wrap:wrap; gap:8px; align-items:center; }
6519
+ .sketches .sketches-convert-note[hidden] { display:none; }
6520
+ .sketches .sketches-shapes li.sketches-shape { display:flex; flex-wrap:wrap; align-items:baseline; gap:4px 8px; }
6521
+ .sketches .sketches-shape-line { min-width:0; }
6522
+ .sketches .sketches-shape-state { flex-basis:100%; font-size:11px; }
6523
+ .sketches details.sketches-conversions > summary { cursor:pointer; font-size:12px; font-weight:600; color:var(--text); list-style:none; display:flex; align-items:center; gap:6px; padding:2px 0; border-radius:4px; }
6524
+ .sketches details.sketches-conversions > summary::-webkit-details-marker { display:none; }
6525
+ .sketches details.sketches-conversions > summary::before { content:''; width:0; height:0; border-left:5px solid var(--text-muted); border-top:4px solid transparent; border-bottom:4px solid transparent; transition:transform .15s ease; }
6526
+ .sketches details.sketches-conversions[open] > summary::before { transform:rotate(90deg); }
6527
+ .sketches details.sketches-conversions > summary:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
6528
+ .sketches .sketches-conversion-list { max-height:40vh; overflow-y:auto; scrollbar-width:thin; scrollbar-color:var(--text-dim) transparent; }
6529
+ .sketches .sketches-conversion-list::-webkit-scrollbar { width:7px; }
6530
+ .sketches .sketches-conversion-list::-webkit-scrollbar-thumb { background:var(--text-dim); border-radius:7px; }
6531
+ .sketches .sketches-conversion-list::-webkit-scrollbar-track { background:transparent; }
6532
+ @media (prefers-reduced-motion: reduce) { .sketches details.sketches-conversions > summary::before { transition:none; } }
6465
6533
  .add-ons-empty-state { display:flex; flex-direction:column; align-items:flex-start; gap:10px; padding:18px 4px; max-width:520px; }
6466
6534
  .add-ons-empty-state h3 { font-size:15px; color:var(--text); }
6467
6535
  .add-ons-empty-state p { color:var(--text-muted); font-size:12px; line-height:1.5; }
@@ -7098,7 +7166,7 @@ body.mode-workspaces #menu .menu-item[data-action="bake"] { display:none; }
7098
7166
  .ws-source-inner { max-width:440px; text-align:center; }
7099
7167
  .ws-source-ico { font-size:34px; color:var(--accent); display:block; margin-bottom:12px; line-height:1; }
7100
7168
  .ws-source-title { font-size:14px; font-weight:600; color:var(--text); margin-bottom:6px; }
7101
- .ws-source-sub { font-size:12px; color:var(--text-dim); line-height:1.55; white-space:pre-line; }
7169
+ .ws-source-sub { font-size:12px; color:var(--text-dim); line-height:1.55; white-space:pre-line; overflow-wrap:anywhere; }
7102
7170
  /* A refusal can explain several findings and next steps. Keep the existing Source surface, but
7103
7171
  present its copy as readable prose in both themes instead of a narrow, centered caption. */
7104
7172
  /* The missing-catalogue question (#1836, data-asking) reads as the same left-aligned prose, but it
@@ -7652,6 +7720,41 @@ table.hist td.gate > .pill-group { min-width:78px; }
7652
7720
  border-radius:8px; background:var(--surface-2); font-size:12px; line-height:1.45; }
7653
7721
  .approval-version-card b { color:var(--text); font-weight:600; }
7654
7722
  .approval-version-card p { margin:3px 0 0; color:var(--text-muted); }
7723
+ /* #3680 part C: what approving does to each density the approval compares. A plain bordered panel like the version
7724
+ card above it (no accent rail: it reports, it does not lead); its list scrolls inside its own themed region. */
7725
+ .approval-density { margin:0 0 10px; padding:10px 12px; border:1px solid var(--border); border-radius:8px; background:var(--surface-2); font-size:12px; line-height:1.45; }
7726
+ .approval-density:focus, .approval-density [data-approval-density-refreshed]:focus { outline:none; }
7727
+ .approval-density:focus-visible, .approval-density [data-approval-density-refreshed]:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
7728
+ .approval-density-title { margin:0; color:var(--text); font-size:12.5px; font-weight:600; }
7729
+ .approval-density-lead { margin:3px 0 8px; color:var(--text-muted); }
7730
+ .approval-density-quiet { display:flex; align-items:center; gap:8px; margin:0; color:var(--text-muted); }
7731
+ .approval-density-quiet .rtn-spinner { width:11px; height:11px; border-width:2px; }
7732
+ .approval-density .approval-notice { margin:0 0 8px; }
7733
+ .approval-density > .approval-notice:last-child { margin-bottom:0; }
7734
+ /* The panel is --surface-2, which in the dark theme is the same colour as --border-strong, so this region's thumb uses
7735
+ --text-dim to stay visible in both themes. */
7736
+ .approval-density-scroll { max-height:min(40vh, 240px); overflow-y:auto; margin:0 -4px; padding:0 4px; border-radius:6px;
7737
+ scrollbar-width:thin; scrollbar-color:var(--text-dim) transparent; }
7738
+ .approval-density-scroll::-webkit-scrollbar { width:8px; }
7739
+ .approval-density-scroll::-webkit-scrollbar-thumb { background:var(--text-dim); border-radius:5px; }
7740
+ .approval-density-scroll::-webkit-scrollbar-track { background:transparent; }
7741
+ .approval-density-scroll:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
7742
+ .approval-density-list, .approval-density-dropped { margin:0; padding:0; list-style:none; }
7743
+ .approval-density-row { padding:7px 0; border-top:1px solid var(--border); }
7744
+ .approval-density-list > .approval-density-row:first-child { border-top:0; padding-top:2px; }
7745
+ .approval-density-head { display:flex; align-items:center; justify-content:space-between; gap:12px; }
7746
+ .approval-density-head b { color:var(--text); font-weight:600; }
7747
+ .approval-density-layers { display:flex; flex-wrap:wrap; gap:2px 14px; margin-top:2px; color:var(--text); font-family:var(--mono); font-size:11px; font-variant-numeric:tabular-nums; }
7748
+ .approval-density-row-id { color:var(--text-dim); }
7749
+ .approval-density-row p { margin:3px 0 0; color:var(--text-muted); }
7750
+ .approval-density-new { margin-top:6px; }
7751
+ .approval-density-new .approval-density-list { padding-left:12px; }
7752
+ .approval-density-sub { margin:10px 0 4px; color:var(--text-muted); font-size:11px; font-weight:600; }
7753
+ .approval-density-dropped li { padding:3px 0 0 12px; color:var(--text-muted); }
7754
+ .approval-risk.ok { color:var(--ok); border-color:color-mix(in srgb, var(--ok) 45%, var(--border)); }
7755
+ /* On the --surface-2 panel the plain pill's --border-strong edge disappears in the dark theme. */
7756
+ .approval-density .approval-risk.low { border-color:var(--text-dim); }
7757
+ .approval-empty-note { display:block; margin-top:6px; color:var(--text-dim); }
7655
7758
  /* Progress while saving, comparing, approving or checking: a short step list, the active step named,
7656
7759
  with elapsed time so slow work reads as progress and never as a hang. State is carried by the mark's
7657
7760
  SHAPE (tick, spinner, hollow ring) as well as its colour, and spoken by a hidden suffix. */
@@ -9421,6 +9524,8 @@ body:has(.ai-chat-viewer-backdrop.show) #instructor .ix-parts { display:block; f
9421
9524
  .pv-banner[hidden] { display:none; }
9422
9525
  .pv-banner-text { flex:1 1 360px; margin:0; font-size:12.5px; color:var(--text-muted); line-height:1.45; }
9423
9526
  .pv-banner-text strong { color:var(--text); font-weight:600; }
9527
+ /* #3927 §13.11.2: the note a changed Teams question carries, above the question it replaced. */
9528
+ .pv-banner-text .pv-banner-note { display:block; margin-bottom:4px; color:var(--text); }
9424
9529
  .pv-banner-path { color:var(--text-dim); }
9425
9530
  .pv-banner-actions { display:flex; gap:8px; flex-shrink:0; }
9426
9531
  .pv-banner-actions button { padding:5px 12px; }
@@ -10202,6 +10307,13 @@ input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer
10202
10307
  .teams-facts dt { color:var(--text-muted); }
10203
10308
  .teams-facts dd { margin:0; color:var(--text); overflow-wrap:anywhere; }
10204
10309
  .teams-callout { border-left:3px solid var(--warn); background:color-mix(in srgb, var(--warn) 7%, transparent); padding:9px 12px; border-radius:0 4px 4px 0; font-size:12px; color:var(--text); display:flex; flex-direction:column; gap:8px; }
10310
+ /* #3778: the one-time "this window answers Teams now" notice: the callout, in the success colour. */
10311
+ .teams-callout.ok { border-left-color:var(--ok); background:color-mix(in srgb, var(--ok) 7%, transparent); margin:0; }
10312
+ /* #3927: the Teams record warning: a change file named in full on hover (data-tip), never widening the dialog. */
10313
+ .teams-events-marker { display:flex; flex-direction:column; gap:6px; min-width:0; }
10314
+ .teams-events-file { font:12px/1.4 var(--mono); color:var(--text); min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
10315
+ .teams-events .teams-callout:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
10316
+ .teams-answer-here-said { margin:6px 0 0; }
10205
10317
  .teams-choice { border:1px solid var(--border); border-radius:6px; padding:8px 12px 10px; margin:0; display:flex; flex-direction:column; gap:6px; }
10206
10318
  .teams-choice legend { padding:0 4px; color:var(--text-dim); font:10px var(--mono); letter-spacing:.08em; text-transform:uppercase; }
10207
10319
  .teams-check { display:flex; align-items:flex-start; gap:8px; font-size:12px; color:var(--text); cursor:pointer; line-height:1.45; }
@@ -10326,13 +10438,6 @@ html.desktop .app > header {
10326
10438
  html.desktop .app > header :is(button, a, input, select, textarea, .mode-switch, .wf-combo, .wf-popover, .wf-forked-pill,
10327
10439
  .wf-update-pill, .ws-quick-chips, #run-state) { -webkit-app-region: no-drag; }
10328
10440
 
10329
- /* The ≡ menu runs off the bottom of a short window: it scrolls instead (themed by the global scrollbar rule above). */
10330
- html.desktop .menu {
10331
- max-height: calc(100vh - var(--header-h) - 8px);
10332
- overflow-y: auto;
10333
- overscroll-behavior: contain;
10334
- }
10335
-
10336
10441
  /* The one-time "Go fullscreen" nudge is for a browser tab; the window has its own maximise. ≡ → Enter full screen stays. */
10337
10442
  html.desktop .fullscreen-nudge { display: none; }
10338
10443
 
package/dist/web/app.js CHANGED
@@ -234,7 +234,7 @@ function wireAskGuide(btn) {
234
234
  if (!btn) return;
235
235
  btn.onclick = () => {
236
236
  if (window.flolessGuide?.open) { void window.flolessGuide.open({ returnFocus: btn }); return; }
237
- showToast('The Guide isn’t ready yet. Try again in a moment, or open it from ≡ → Guide.', 'warn');
237
+ showToast('The Guide is still loading. If it doesn’t open in a few seconds, reload FloLess (Ctrl+R).', 'warn');
238
238
  };
239
239
  }
240
240
  function wireOnboardingCopy() {
@@ -1661,17 +1661,48 @@ document.querySelectorAll('.theme-btn').forEach(b => {
1661
1661
  const $startupRow = document.getElementById('menu-startup');
1662
1662
  const $startupToggle = document.getElementById('startup-toggle');
1663
1663
 
1664
- async function refreshStartup() {
1664
+ const $startupStatus = document.getElementById('startup-status');
1665
+ const $startupChoices = document.getElementById('startup-choices');
1666
+ const $startupOn = document.getElementById('startup-on');
1667
+ const $startupOff = document.getElementById('startup-off');
1668
+ let startupRequest = 0;
1669
+ let startupChanging = false;
1670
+
1671
+ function paintStartupState(enabled, state) {
1672
+ if (!$startupToggle || !$startupStatus) return;
1673
+ const known = state !== 'unknown' && typeof enabled === 'boolean';
1674
+ $startupToggle.closest('label').hidden = !known;
1675
+ $startupToggle.disabled = startupChanging || !known;
1676
+ $startupStatus.hidden = known;
1677
+ $startupChoices.hidden = known;
1678
+ if (known) $startupToggle.checked = enabled;
1679
+ }
1680
+
1681
+ async function refreshStartup(retry = true) {
1682
+ if (startupChanging) return;
1683
+ const preserveUnknown = $startupRow?.hidden === false && $startupStatus?.hidden === false;
1684
+ const request = ++startupRequest;
1665
1685
  try {
1666
1686
  await globalThis.flolessStartupAdmission?.admit('/api/autostart');
1667
1687
  const r = await fetch('/api/autostart');
1668
- if (!r.ok) { if ($startupRow) $startupRow.hidden = true; showStartOnLoginLinks(false); return; }
1688
+ if (!r.ok) throw new Error('autostart-status-unavailable');
1669
1689
  const d = await r.json();
1670
- const supported = !!d.supported;
1690
+ if (request !== startupRequest) return;
1691
+ if (preserveUnknown && typeof d?.supported !== 'boolean') return;
1692
+ const supported = d.supported === true;
1671
1693
  if ($startupRow) $startupRow.hidden = !supported;
1672
- if (supported && $startupToggle) $startupToggle.checked = !!d.enabled;
1694
+ if (supported) paintStartupState(d.enabled, d.state);
1673
1695
  showStartOnLoginLinks(supported);
1674
- } catch { if ($startupRow) $startupRow.hidden = true; showStartOnLoginLinks(false); }
1696
+ if (retry && supported && d.enabled === null && $menu.classList.contains('show')) {
1697
+ setTimeout(() => {
1698
+ if (request === startupRequest && $menu.classList.contains('show')) void refreshStartup(false);
1699
+ }, 2700);
1700
+ }
1701
+ } catch {
1702
+ if (request !== startupRequest || preserveUnknown) return;
1703
+ if ($startupRow) $startupRow.hidden = true;
1704
+ showStartOnLoginLinks(false);
1705
+ }
1675
1706
  }
1676
1707
 
1677
1708
  // #2062: Routines run only while FloLess is running, so their dialogs point to this setting. The links follow the
@@ -1680,7 +1711,7 @@ function showStartOnLoginLinks(supported) {
1680
1711
  document.querySelectorAll('[data-start-on-login-link], [data-start-on-login-hint]').forEach((node) => { node.hidden = !supported; });
1681
1712
  }
1682
1713
 
1683
- /** #2062: close whatever dialog asked, open the ≡ menu and put focus on the start-on-login switch. */
1714
+ /** #2062: close whatever dialog asked, open the ≡ menu and put focus on the start-on-login setting. */
1684
1715
  async function revealStartOnLogin() {
1685
1716
  // Read the setting first: if it has gone (or can't be read), say so and leave Routines open.
1686
1717
  await refreshStartup();
@@ -1694,7 +1725,7 @@ async function revealStartOnLogin() {
1694
1725
  $startupRow.classList.remove('is-pointed');
1695
1726
  void $startupRow.offsetWidth; // re-arm the highlight on a repeat
1696
1727
  $startupRow.classList.add('is-pointed');
1697
- $startupToggle.focus({ preventScroll: false });
1728
+ ($startupStatus && !$startupStatus.hidden ? $startupStatus : $startupToggle).focus({ preventScroll: false });
1698
1729
  }
1699
1730
  document.addEventListener('click', (event) => {
1700
1731
  const link = event.target.closest?.('[data-start-on-login-link]');
@@ -1704,38 +1735,49 @@ document.addEventListener('click', (event) => {
1704
1735
  void revealStartOnLogin();
1705
1736
  }, true);
1706
1737
 
1707
- if ($startupToggle) {
1708
- $startupToggle.addEventListener('change', async () => {
1709
- const want = $startupToggle.checked;
1710
- $startupToggle.disabled = true;
1711
- try {
1712
- const r = await fetch('/api/autostart', {
1713
- method: 'PUT',
1714
- headers: { 'Content-Type': 'application/json' },
1715
- body: JSON.stringify({ enabled: want }),
1716
- });
1717
- const d = await r.json().catch(() => ({}));
1718
- if (!r.ok || !d.ok) {
1719
- // #3070: the server reads Windows back and says what is really true; show that, never the flip we guessed.
1720
- const failure = new Error('autostart-change-refused');
1721
- failure.enabled = typeof d.enabled === 'boolean' ? d.enabled : null;
1722
- // Plain words written by this route; `saved` marks them (any other failing body is not ours to show).
1723
- failure.userMessage = typeof d.saved === 'boolean' && typeof d.error === 'string' && d.error ? d.error : null;
1724
- throw failure;
1725
- }
1726
- $startupToggle.checked = !!d.enabled; // trust server truth (schtasks re-queried)
1727
- // Success is silent — the switch position IS the confirmation (matches Theme).
1728
- // UX review 2026-05-31: a preference write doesn't rise to a toast.
1729
- } catch (e) {
1730
- $startupToggle.checked = typeof e?.enabled === 'boolean' ? e.enabled : !want; // what Windows really has, else revert the optimistic flip
1731
- showToast(e?.userMessage
1732
- || 'We couldn’t save that startup setting. Try again. If it keeps happening, reopen FloLess.', 'err');
1733
- } finally {
1734
- $startupToggle.disabled = false;
1738
+ async function changeStartup(want) {
1739
+ if (startupChanging) return;
1740
+ startupChanging = true;
1741
+ startupRequest++;
1742
+ $startupToggle.disabled = $startupOn.disabled = $startupOff.disabled = true;
1743
+ let reread = false;
1744
+ try {
1745
+ const r = await fetch('/api/autostart', {
1746
+ method: 'PUT',
1747
+ headers: { 'Content-Type': 'application/json' },
1748
+ body: JSON.stringify({ enabled: want }),
1749
+ });
1750
+ const d = await r.json().catch(() => ({}));
1751
+ if (!r.ok || !d.ok) {
1752
+ const failure = new Error('autostart-change-refused');
1753
+ // Plain words written by this route; `saved` marks them (any other failing body is not ours to show).
1754
+ failure.userMessage = typeof d.saved === 'boolean' && typeof d.error === 'string' && d.error ? d.error : null;
1755
+ // A refusal this route wrote carries what Windows really has: show that (#3070), never a guess.
1756
+ failure.observed = typeof d.saved === 'boolean' && typeof d.enabled === 'boolean' ? d.enabled : null;
1757
+ failure.answered = true;
1758
+ throw failure;
1735
1759
  }
1736
- });
1760
+ paintStartupState(d.enabled, d.state);
1761
+ // Success is silent — the switch position IS the confirmation (matches Theme).
1762
+ // UX review 2026-05-31: a preference write doesn't rise to a toast.
1763
+ } catch (e) {
1764
+ if (typeof e?.observed === 'boolean') paintStartupState(e.observed, e.observed ? 'present' : 'absent');
1765
+ else { paintStartupState(null, 'unknown'); reread = true; } // no observed state in the answer: ask again, never repaint the old one
1766
+ showToast(e?.userMessage || (e?.answered
1767
+ ? 'We couldn’t save that startup setting. Try again. If it keeps happening, reopen FloLess.'
1768
+ : 'We couldn’t confirm the startup setting. Try again if the status stays unknown.'), 'err');
1769
+ } finally {
1770
+ startupChanging = false;
1771
+ $startupToggle.disabled = !$startupStatus.hidden;
1772
+ $startupOn.disabled = $startupOff.disabled = false;
1773
+ if (reread) void refreshStartup();
1774
+ }
1737
1775
  }
1738
1776
 
1777
+ $startupToggle?.addEventListener('change', () => changeStartup($startupToggle.checked));
1778
+ $startupOn?.addEventListener('click', () => changeStartup(true));
1779
+ $startupOff?.addEventListener('click', () => changeStartup(false));
1780
+
1739
1781
  // Initial read + a refresh each time the menu opens (state can change out-of-band,
1740
1782
  // e.g. the user disabling the task in Windows Settings).
1741
1783
  refreshStartup();
@@ -1871,6 +1913,15 @@ function authoredToastCopy(text) {
1871
1913
  return { [Symbol.for('floless.authored-toast-copy')]: String(text ?? '') };
1872
1914
  }
1873
1915
 
1916
+ function showStartPlaceToast(missing) {
1917
+ const message = missing === 'project'
1918
+ ? 'The project you had open is no longer here, so FloLess opened Workspaces.'
1919
+ : missing === 'workflow'
1920
+ ? 'The workflow you had open is no longer here, so FloLess opened Workspaces.'
1921
+ : 'Reopened where you left off.';
1922
+ showToast(message, 'info', { durationMs: 6000 });
1923
+ }
1924
+
1874
1925
  function showToast(msg, type, options) {
1875
1926
  const c = document.getElementById('toast-container');
1876
1927
  const t = document.createElement('div');
@@ -1898,7 +1949,7 @@ function showToast(msg, type, options) {
1898
1949
  // A toast carrying the only record of what happened may opt into persistence while
1899
1950
  // keeping its styling. warn/err and every persistent toast get an × so they can
1900
1951
  // always be closed.
1901
- const ms = options?.persistent ? 0 : ({ ok: 2500, info: 2500, warn: 5000, err: 0, progress: 0 }[type] ?? 2500);
1952
+ const ms = options?.persistent ? 0 : options?.durationMs ?? ({ ok: 2500, info: 2500, warn: 5000, err: 0, progress: 0 }[type] ?? 2500);
1902
1953
  if (type === 'warn' || type === 'err' || options?.persistent) {
1903
1954
  const x = document.createElement('button');
1904
1955
  x.className = 'toast-close';
@@ -150,6 +150,15 @@
150
150
  }
151
151
  }
152
152
 
153
+ /**
154
+ * Does the hold, not an upgrade, answer this update check? True while AWARE is held and the check offers nothing the
155
+ * hold allows, or AWARE changed while it was held. A bridge repair, a reinstall of an unreadable held AWARE and an
156
+ * interrupted update keep their own offer, in the order the footer pill shows them.
157
+ */
158
+ function ownsOffer(check) {
159
+ return !!(check && check.hold && !check.recoveryPending && (check.drifted || !check.updateAvailable));
160
+ }
161
+
153
162
  function wire() {
154
163
  var e = els();
155
164
  if (!e.toggle || !e.keep) return;
@@ -169,6 +178,7 @@
169
178
  window.flolessAwareHold = {
170
179
  refresh: function () { return refresh(false); },
171
180
  openInMenu: openInMenu,
181
+ ownsOffer: ownsOffer,
172
182
  getState: function () { return state; },
173
183
  };
174
184
  if (doc.readyState === 'loading') doc.addEventListener('DOMContentLoaded', wire);