@floless/app 0.159.0 → 0.161.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 (43) hide show
  1. package/dist/floless-server.cjs +76823 -65608
  2. package/dist/schemas/steel.model.v2.schema.json +24 -0
  3. package/dist/skills/floless-app-onboarding/SKILL.md +4 -3
  4. package/dist/skills/floless-app-onboarding/references/floless-surfaces.md +1 -2
  5. package/dist/skills/floless-app-rfi/SKILL.md +44 -3
  6. package/dist/skills/floless-app-steel-model/SKILL.md +2 -2
  7. package/dist/skills/floless-app-steel-takeoff/SKILL.md +417 -261
  8. package/dist/templates/steel-model.flo +6 -2
  9. package/dist/templates/viewer-3d-demo.flo +8 -2
  10. package/dist/web/app.css +342 -160
  11. package/dist/web/app.js +17 -51
  12. package/dist/web/aware.js +656 -574
  13. package/dist/web/chat-question-card.js +27 -1
  14. package/dist/web/chat.css +185 -30
  15. package/dist/web/chat.js +2099 -255
  16. package/dist/web/commands-drawing-check.js +1 -0
  17. package/dist/web/commands-filter.js +11 -0
  18. package/dist/web/commands-shell.js +1118 -134
  19. package/dist/web/commands-steel.js +41 -38
  20. package/dist/web/drawing-check-editor.js +76 -3
  21. package/dist/web/guide.js +8 -0
  22. package/dist/web/index.html +68 -42
  23. package/dist/web/instructor.js +17 -6
  24. package/dist/web/pages.js +158 -30
  25. package/dist/web/panels.js +19 -1
  26. package/dist/web/project-history.js +349 -0
  27. package/dist/web/project-reconciliation.js +1 -0
  28. package/dist/web/project-rfis.js +954 -0
  29. package/dist/web/project-workflows.js +236 -4
  30. package/dist/web/run-history.js +198 -0
  31. package/dist/web/run-page-view.js +12 -2
  32. package/dist/web/startup-admission.js +53 -7
  33. package/dist/web/steel-3d-core.js +144 -7
  34. package/dist/web/steel-3d-view.js +61 -5
  35. package/dist/web/steel-editor.html +510 -128
  36. package/dist/web/steel-filter.html +139 -0
  37. package/dist/web/steel-model-v2-commands.js +3 -3
  38. package/dist/web/steel-model-v2-projection.js +139 -4
  39. package/dist/web/steel-plan-transform.js +78 -0
  40. package/dist/web/tool-updates.js +5 -0
  41. package/dist/web/workspaces.js +1438 -159
  42. package/launch.mjs +36 -5
  43. package/package.json +7 -4
@@ -2113,6 +2113,7 @@
2113
2113
  def('steel.profile-colours', { label: 'Profile colours', actsOn: 'Opens the key of section colours for the whole model, and lets you change any of them', group: 'In the 3D toolbar', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'It only changes how members are DRAWN — no geometry, no sections, nothing that reaches the lock.' });
2114
2114
  def('steel.structure-stats', { label: 'Structure numbers', actsOn: 'Expands the members and weight for the active plan sheet, or for the whole model while the 3D view is active', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The header states the total; opening it shows what the total is made of, and changes nothing.' });
2115
2115
  def('steel.quality-stats', { label: 'Quality numbers', actsOn: 'Expands what is unresolved on this sheet — RFI, duplicates, member ends and read confidence', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The header states how many issues there are; opening it says which kinds, and changes nothing.' });
2116
+ def('steel.quick-model-chip', { label: 'Quick model label', actsOn: 'Says that the model, as last saved, was built by the AI deciding where it would have asked you', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A Quick model is fine for a tender or an estimate but is not precise. The label describes the model as last saved; "Possibly Quick" means FloLess could not read which AI decisions it rests on.' });
2116
2117
  def('steel.confidence-report', { label: 'Open confidence report', actsOn: 'Opens the recorded drawing-confidence review', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Shows current field-level read evidence without changing the model.' });
2117
2118
 
2118
2119
  /* Ask AI */
@@ -2328,14 +2329,16 @@
2328
2329
  // #1090 — the ONE RFI list. It replaces `steel.questions-list`, whose panel listed gaps derived from
2329
2330
  // the model and could act on none of them, and `steel.question-select`, whose row could frame its
2330
2331
  // subjects but not file, answer or close anything.
2331
- def('steel.rfi-list', { label: 'RFIs', actsOn: 'Lists every RFI on this project — questions FloLess could not answer from the drawings, and members whose size it cannot price', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Reading the list changes nothing in the model. It covers the whole project rather than the open sheet, so a question raised on another drawing is still here — the count shows even at zero, because zero is a real answer.' });
2332
- def('steel.rfi-scope', { label: 'Show', actsOn: 'Narrows the RFI list to {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A filter changes what is listed, never what is recorded. “This sheet only” is offered only while a plan sheet is open, because otherwise there is no sheet for it to mean.' });
2333
- def('steel.rfi-status-filter', { label: 'Status', actsOn: 'Filters the RFI list to {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Open means anything still waiting on somebody — raised, sent or answered. Closed ones stay listed so a settled question can be looked up later.' });
2334
- def('steel.rfi-copy', { label: 'Copy whole RFI', actsOn: 'Copies {instance} as text, ready to paste into an email', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'This copies the same complete question FloLess sends through Gmail. If the clipboard cannot be reached, the text is shown instead so you can copy it by hand.' });
2335
- def('steel.rfi-quick-refile', { label: 'Try filing again', actsOn: 'Files the questions {instance} keeps that the AI could not file yet', anyInstance: 'a Quick model version', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A Quick model keeps the questions the AI could not settle with the version it published. When the RFI file could not take them, this files them, marked as the AI’s. Anything already filed is not filed twice, and nothing is sent to anyone.' });
2336
- def('steel.rfi-group-toggle', { label: 'Show occurrences', actsOn: 'Expands or collapses the ordered occurrences in {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A grouped question remains one RFI. Expanding it reveals each occurrence’s own status, drawing destination and scoped actions without creating duplicate rows.' });
2337
- def('steel.rfi-group-elsewhere', { label: 'Show elsewhere in this RFI', actsOn: 'Reveals occurrences from {instance} that are not on the current sheet', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The sheet filter keeps a grouped RFI indivisible. Matching occurrences stay first; this disclosure reveals the rest without pretending they belong to the current sheet.' });
2338
- def('steel.rfi-technical', { label: 'Technical details', actsOn: 'Shows the stored technical identity for {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The internal gap key is useful for diagnosis but is not a user-facing action selector, so it stays behind this disclosure.' });
2332
+ def('steel.rfi-list', { label: 'RFIs', actsOn: 'Opens this project’s RFIs step: every question FloLess could not answer from the drawings, and members whose size it cannot price', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Reading the list changes nothing in the model. It covers the whole project rather than the open sheet, so a question raised on another drawing is still here — the count shows even at zero, because zero is a real answer.' });
2333
+ def('steel.back-to-rfis', { label: 'Back to RFIs', actsOn: 'Returns to the RFIs step, on the RFI you left it from', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Shown after Locate or a size fix took you from an RFI to the model, so the round trip ends where it started.' });
2334
+ def('steel.back-to-model', { label: 'Back to model', actsOn: 'Shows the model again in place of the RFI list', group: 'In the steel editor opened on its own', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Only when this editor is open on its own (outside a project’s steps); in a project the Model and RFIs steps switch between the two.' });
2335
+ def('steel.rfi-scope', { label: 'Show', actsOn: 'Narrows the RFI list to {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A filter changes what is listed, never what is recorded. “This sheet only” is offered only while a plan sheet is open, because otherwise there is no sheet for it to mean.' });
2336
+ def('steel.rfi-status-filter', { label: 'Status', actsOn: 'Filters the RFI list to {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Open means anything still waiting on somebody — raised, sent or answered. Closed ones stay listed so a settled question can be looked up later.' });
2337
+ def('steel.rfi-copy', { label: 'Copy whole RFI', actsOn: 'Copies {instance} as text, ready to paste into an email', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'This copies the same complete question FloLess sends through Gmail. If the clipboard cannot be reached, the text is shown instead so you can copy it by hand.' });
2338
+ def('steel.rfi-quick-refile', { label: 'Try filing again', actsOn: 'Files the questions {instance} keeps that the AI could not file yet', anyInstance: 'a Quick model version', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A Quick model keeps the questions the AI could not settle with the version it published. When the RFI file could not take them, this files them, marked as the AI’s. Anything already filed is not filed twice, and nothing is sent to anyone.' });
2339
+ def('steel.rfi-group-toggle', { label: 'Show occurrences', actsOn: 'Expands or collapses the ordered occurrences in {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A grouped question remains one RFI. Expanding it reveals each occurrence’s own status, drawing destination and scoped actions without creating duplicate rows.' });
2340
+ def('steel.rfi-group-elsewhere', { label: 'Show elsewhere in this RFI', actsOn: 'Reveals occurrences from {instance} that are not on the current sheet', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The sheet filter keeps a grouped RFI indivisible. Matching occurrences stay first; this disclosure reveals the rest without pretending they belong to the current sheet.' });
2341
+ def('steel.rfi-technical', { label: 'Technical details', actsOn: 'Shows the stored technical identity for {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The internal gap key is useful for diagnosis but is not a user-facing action selector, so it stays behind this disclosure.' });
2339
2342
  /* The bookkeeping action verbs (#1090 slice 5b-ii), plus the distinct connected-Gmail boundary.
2340
2343
  ONE id per gesture, with the ROW as the instance: `steel.rfi-send` is the same bookkeeping
2341
2344
  capability whether the subject is a filed record or a member being promoted. Connected delivery
@@ -2347,41 +2350,41 @@
2347
2350
  `escLabel` is the ONLY place the Escape rule is narrated, and it is true only because this slice
2348
2351
  added the form-open branch to the dialog's own keydown handler. `steel.rfi-apply` really is
2349
2352
  instant — it has no form. */
2350
- def('steel.rfi-send', { label: 'Mark sent', actsOn: 'Opens the form that records an email you sent outside FloLess for {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Say who received it', 'Choose Mark sent to record it'], escLabel: 'Esc closes the form — nothing is recorded', why: 'Available when this RFI has no unresolved Gmail attempt. This does not send an email. It records the recipient and date after you sent the RFI elsewhere. On an unfiled size question it also creates the durable RFI record.' });
2351
- def('steel.rfi-gmail-send', { label: 'Send with Gmail', actsOn: 'Opens the final Gmail confirmation for {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Check the recipient', 'Choose Send with Gmail'], escLabel: 'Esc closes the confirmation — nothing is sent', why: 'Opening this puts focus in To. FloLess sends the complete stored RFI through the Google account connected in Integrations only after the second click.' });
2352
- def('steel.rfi-gmail-submit', { label: 'Send with Gmail', actsOn: 'Sends {instance} through the connected Google account', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: ['destructive'], guidance: 'on-demand', why: 'This cannot be undone. Focus stays on this RFI while Gmail works, then returns to an available action on the same row. Acceptance does not prove inbox delivery.' });
2353
- def('steel.rfi-gmail-continue', { label: 'Continue recording this send', actsOn: 'Continues the exact prepared Gmail attempt for {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: ['destructive'], guidance: 'on-demand', why: 'This may finish the already-prepared Gmail delivery, so it is the same irreversible send, never a new attempt. Focus stays on this action while it runs, then returns to the same RFI.' });
2354
- def('steel.rfi-gmail-confirm-sent', { label: 'I found it in Sent', actsOn: 'Records that the exact Gmail attempt for {instance} is visible in the connected account’s Sent folder', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use this only after matching the RFI and attempt marker in the correct sender’s Sent folder. It records that check and returns focus to the same RFI; it does not send another message.' });
2355
- def('steel.rfi-answer', { label: 'Answer', actsOn: 'Opens the form that records the answer to {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Write what came back, or pick the section', 'Choose Answer to record it'], escLabel: 'Esc closes the form — nothing is recorded', why: 'A question about a size takes a section designation rather than a sentence, because FloLess has to compare it against the model later. Every other kind takes the words the engineer actually sent back.' });
2356
- def('steel.rfi-apply', { label: 'Mark applied', actsOn: 'Records that the model now carries the size answered on {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess records that the answer reached the steel; it does not write it for you. Set the size with the box on this row first — then this checks the model really carries it and stamps the receipt that lets the RFI close as resolved. Offered only once an answer exists and the model agrees.' });
2357
- def('steel.rfi-close', { label: 'Close', actsOn: 'Opens the form that closes {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Choose how it ended', 'Give a short reason', 'Choose Close to record it'], escLabel: 'Esc closes the form — the RFI stays open', why: 'A closed RFI stays on the project and stays readable; it leaves the Open filter, not the record. Only the endings this particular question can actually have are offered — a size question ends by the size reaching the model, never by accepting an answer on paper.' });
2358
- def('steel.rfi-reopen', { label: 'Reopen', actsOn: 'Opens the form that reopens {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Say why it is being reopened', 'Choose Reopen to record it'], escLabel: 'Esc closes the form — the RFI stays closed', why: 'Reopening starts a fresh round on the same question: the previous answer and closure stay in the history but stop being what the RFI currently says.' });
2359
- def('steel.rfi-disposition', { label: 'How it ended', actsOn: 'Marks {instance} once you record the form', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Nothing is written until you choose Close. Resolved is offered only for a size question whose answer is already in the model, so the ending you pick can always actually be recorded.' });
2360
- def('steel.rfi-submit', { label: 'Record it', actsOn: 'Commits {instance} to the project record', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Every bookkeeping change carries a one-time key, so pressing twice records the attempt once. This never sends through Gmail; that has its own clearly named confirmation.' });
2361
- def('steel.rfi-retry-same', { label: 'Try same attempt again', actsOn: 'Replays the preserved one-time request for {instance}', group: 'In the RFI dialog', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess first checked that the RFI still matches the version you acted on. This sends the exact same request bytes and one-time key, so the server can return the first result without applying the action twice.' });
2353
+ def('steel.rfi-send', { label: 'Mark sent', actsOn: 'Opens the form that records an email you sent outside FloLess for {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Say who received it', 'Choose Mark sent to record it'], escLabel: 'Esc closes the form — nothing is recorded', why: 'Available when this RFI has no unresolved Gmail attempt. This does not send an email. It records the recipient and date after you sent the RFI elsewhere. On an unfiled size question it also creates the durable RFI record.' });
2354
+ def('steel.rfi-gmail-send', { label: 'Send with Gmail', actsOn: 'Opens the final Gmail confirmation for {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Check the recipient', 'Choose Send with Gmail'], escLabel: 'Esc closes the confirmation — nothing is sent', why: 'Opening this puts focus in To. FloLess sends the complete stored RFI through the Google account connected in Integrations only after the second click.' });
2355
+ def('steel.rfi-gmail-submit', { label: 'Send with Gmail', actsOn: 'Sends {instance} through the connected Google account', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: ['destructive'], guidance: 'on-demand', why: 'This cannot be undone. Focus stays on this RFI while Gmail works, then returns to an available action on the same row. Acceptance does not prove inbox delivery.' });
2356
+ def('steel.rfi-gmail-continue', { label: 'Continue recording this send', actsOn: 'Continues the exact prepared Gmail attempt for {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: ['destructive'], guidance: 'on-demand', why: 'This may finish the already-prepared Gmail delivery, so it is the same irreversible send, never a new attempt. Focus stays on this action while it runs, then returns to the same RFI.' });
2357
+ def('steel.rfi-gmail-confirm-sent', { label: 'I found it in Sent', actsOn: 'Records that the exact Gmail attempt for {instance} is visible in the connected account’s Sent folder', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use this only after matching the RFI and attempt marker in the correct sender’s Sent folder. It records that check and returns focus to the same RFI; it does not send another message.' });
2358
+ def('steel.rfi-answer', { label: 'Answer', actsOn: 'Opens the form that records the answer to {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Write what came back, or pick the section', 'Choose Answer to record it'], escLabel: 'Esc closes the form — nothing is recorded', why: 'A question about a size takes a section designation rather than a sentence, because FloLess has to compare it against the model later. Every other kind takes the words the engineer actually sent back.' });
2359
+ def('steel.rfi-apply', { label: 'Mark applied', actsOn: 'Records that the model now carries the size answered on {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess records that the answer reached the steel; it does not write it for you. Set the size with the box on this row first — then this checks the model really carries it and stamps the receipt that lets the RFI close as resolved. Offered only once an answer exists and the model agrees.' });
2360
+ def('steel.rfi-close', { label: 'Close', actsOn: 'Opens the form that closes {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Choose how it ended', 'Give a short reason', 'Choose Close to record it'], escLabel: 'Esc closes the form — the RFI stays open', why: 'A closed RFI stays on the project and stays readable; it leaves the Open filter, not the record. Only the endings this particular question can actually have are offered — a size question ends by the size reaching the model, never by accepting an answer on paper.' });
2361
+ def('steel.rfi-reopen', { label: 'Reopen', actsOn: 'Opens the form that reopens {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'mode', risk: [], guidance: 'active-command', steps: ['Say why it is being reopened', 'Choose Reopen to record it'], escLabel: 'Esc closes the form — the RFI stays closed', why: 'Reopening starts a fresh round on the same question: the previous answer and closure stay in the history but stop being what the RFI currently says.' });
2362
+ def('steel.rfi-disposition', { label: 'How it ended', actsOn: 'Marks {instance} once you record the form', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Nothing is written until you choose Close. Resolved is offered only for a size question whose answer is already in the model, so the ending you pick can always actually be recorded.' });
2363
+ def('steel.rfi-submit', { label: 'Record it', actsOn: 'Commits {instance} to the project record', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Every bookkeeping change carries a one-time key, so pressing twice records the attempt once. This never sends through Gmail; that has its own clearly named confirmation.' });
2364
+ def('steel.rfi-retry-same', { label: 'Try same attempt again', actsOn: 'Replays the preserved one-time request for {instance}', group: 'In a steel project’s RFIs step', persistence: 'external', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess first checked that the RFI still matches the version you acted on. This sends the exact same request bytes and one-time key, so the server can return the first result without applying the action twice.' });
2362
2365
  // #2450: the Raise an RFI dialog, opened from the readiness card on one connection.
2363
2366
  def('steel.rfi-raise-question', { label: 'Show a question', actsOn: 'Opens or closes {instance} in the Raise an RFI dialog', group: 'In the Raise an RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess wrote each question from the model: a check outside its limit, one it could not measure, or a connection it could not build. Opening one shows its full words and what it is about; nothing is filed until you file it.' });
2364
2367
  def('steel.rfi-raise-open-record', { label: 'Open the RFI', actsOn: 'Opens {instance} in the RFI list', group: 'In the Raise an RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A question that already has an RFI is acted on there, so the same question is never filed twice.' });
2365
2368
  def('steel.rfi-raise-retry', { label: 'Try again', actsOn: 'Reads the questions for {instance} again', group: 'In the Raise an RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Reading the questions changes nothing. It is offered when FloLess could not read them the first time.' });
2366
2369
  def('steel.rfi-raise-use-saved', { label: 'Show the saved model’s questions', actsOn: 'Shows the questions for {instance} as the saved model raises them', group: 'In the Raise an RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Offered when your latest edits could not be saved. The questions then describe the saved model, not what you see, and the dialog says so.' });
2367
2370
  def('steel.rfi-raise-open-list', { label: 'Open the RFI list', actsOn: 'Opens the RFI list, where the questions that explain {instance} live', anyInstance: 'the connection', group: 'In the Raise an RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Some build issues come from a member FloLess cannot size or place yet. That member has its own question in the RFI list, and answering it is what fixes the connection.' });
2368
- def('steel.rfi-check-status', { label: 'Check RFI', actsOn: 'Reads {instance} again after FloLess stopped waiting for an action', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'This only checks the project record. It does not repeat the action. FloLess offers the same-attempt retry only when the current RFI still matches the revision you acted on.' });
2369
- def('steel.rfi-review-current', { label: 'Review current RFI', actsOn: 'Leaves the timed-out attempt and returns to the current state of {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess found that the RFI changed while checking. This clears the saved attempt without repeating it, so the current status and available actions become authoritative again.' });
2370
- def('steel.rfi-reload-model', { label: 'Reload to reconcile', actsOn: 'Reloads the model after the save for {instance} stopped responding', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess safely parked the exact model in this browser before saving. Reloading lets the editor compare that parked copy with the server without placing another write behind the request that is still unresolved.' });
2371
- def('steel.rfi-cancel', { label: 'Cancel', actsOn: 'Closes or discards {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Before submission, this only discards the typed text. After a timeout, “Discard saved form” clears the retained entries but cannot undo an action the project may already have recorded; check the current RFI first if that matters.' });
2372
- def('steel.rfi-open-drawing', { label: 'Open drawing or detail', actsOn: 'Shows the saved drawing location for {instance}; a checked bounded detail is highlighted, otherwise the whole referenced sheet opens', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Opens the saved source page in the drawing viewer. When the reader supplied a checked detail location, FloLess highlights that exact bounded area; otherwise it opens the whole referenced sheet and says exact detail highlighting is unavailable. Zoom or pan to inspect it. Escape returns to this RFI without discarding a written answer.' });
2373
- def('steel.rfi-locate-joint', { label: 'Locate connection', actsOn: 'Selects and frames the connection for {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Opens the 3D view and selects the actual connection. It changes your view and selection, never the steel. If the connection can no longer be drawn, the RFI stays open and explains why.' });
2374
- def('steel.rfi-locate-member', { label: 'Locate member', actsOn: 'Switches to and frames the member for {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Closes the RFI dialog, opens the first project view that draws this member, selects it, and frames the whole member. If the question names a start or end, that endpoint remains context for the question; this action does not isolate the endpoint. It changes only the view and selection.' });
2371
+ def('steel.rfi-check-status', { label: 'Check RFI', actsOn: 'Reads {instance} again after FloLess stopped waiting for an action', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'This only checks the project record. It does not repeat the action. FloLess offers the same-attempt retry only when the current RFI still matches the revision you acted on.' });
2372
+ def('steel.rfi-review-current', { label: 'Review current RFI', actsOn: 'Leaves the timed-out attempt and returns to the current state of {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess found that the RFI changed while checking. This clears the saved attempt without repeating it, so the current status and available actions become authoritative again.' });
2373
+ def('steel.rfi-reload-model', { label: 'Reload to reconcile', actsOn: 'Reloads the model after the save for {instance} stopped responding', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'FloLess safely parked the exact model in this browser before saving. Reloading lets the editor compare that parked copy with the server without placing another write behind the request that is still unresolved.' });
2374
+ def('steel.rfi-cancel', { label: 'Cancel', actsOn: 'Closes or discards {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Before submission, this only discards the typed text. After a timeout, “Discard saved form” clears the retained entries but cannot undo an action the project may already have recorded; check the current RFI first if that matters.' });
2375
+ def('steel.rfi-open-drawing', { label: 'Open drawing or detail', actsOn: 'Shows the saved drawing location for {instance}; a checked bounded detail is highlighted, otherwise the whole referenced sheet opens', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Opens the saved source page in the drawing viewer. When the reader supplied a checked detail location, FloLess highlights that exact bounded area; otherwise it opens the whole referenced sheet and says exact detail highlighting is unavailable. Zoom or pan to inspect it. Escape returns to this RFI without discarding a written answer.' });
2376
+ def('steel.rfi-locate-joint', { label: 'Locate connection', actsOn: 'Selects and frames the connection for {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Opens the 3D view and selects the actual connection. It changes your view and selection, never the steel. If the connection can no longer be drawn, the RFI stays open and explains why.' });
2377
+ def('steel.rfi-locate-member', { label: 'Locate member', actsOn: 'Shows the model and frames the member for {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Shows the model, opens the first project view that draws this member, selects it, and frames the whole member. If the question names a start or end, that endpoint remains context for the question; this action does not isolate the endpoint. It changes only the view and selection.' });
2375
2378
  /* The fields. Each carries its OWN id and the wrapper carries none: the narrator resolves the
2376
2379
  nearest `data-command-id` from whatever holds focus, so a field without one would be described by
2377
2380
  whichever ancestor did. The instance is verb-plus-row, because one id serves five forms. */
2378
- def('steel.rfi-field-to', { label: 'To', actsOn: 'Records who {instance} is addressed to', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A name or an address — whatever will make sense to you in three months. It is stored with the RFI and appears in the copied body.' });
2379
- def('steel.rfi-field-profile', { label: 'Size', actsOn: 'Records the section designation answering {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A size question needs a designation FloLess can look up rather than a sentence, so that it can later check the model really carries it. Pick from the list to be sure of the spelling.' });
2380
- def('steel.rfi-field-text', { label: 'What came back', actsOn: 'Records the words that answer {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Written down as the engineer put it. FloLess never acts on these words itself — it keeps them beside the question so the decision has a trace.' });
2381
- def('steel.rfi-field-note', { label: 'Reason', actsOn: 'Records why {instance} ended the way it did', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Every ending except a size reaching the model is somebody deciding something, and a decision with no reason is unreadable a month later. That is why it is asked for rather than optional.' });
2382
- def('steel.rfi-field-why', { label: 'Why', actsOn: 'Records why {instance} is being reopened', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The reason sits at the top of the new round, so whoever picks the question up knows what changed since it was closed.' });
2381
+ def('steel.rfi-field-to', { label: 'To', actsOn: 'Records who {instance} is addressed to', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A name or an address — whatever will make sense to you in three months. It is stored with the RFI and appears in the copied body.' });
2382
+ def('steel.rfi-field-profile', { label: 'Size', actsOn: 'Records the section designation answering {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A size question needs a designation FloLess can look up rather than a sentence, so that it can later check the model really carries it. Pick from the list to be sure of the spelling.' });
2383
+ def('steel.rfi-field-text', { label: 'What came back', actsOn: 'Records the words that answer {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Written down as the engineer put it. FloLess never acts on these words itself — it keeps them beside the question so the decision has a trace.' });
2384
+ def('steel.rfi-field-note', { label: 'Reason', actsOn: 'Records why {instance} ended the way it did', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Every ending except a size reaching the model is somebody deciding something, and a decision with no reason is unreadable a month later. That is why it is asked for rather than optional.' });
2385
+ def('steel.rfi-field-why', { label: 'Why', actsOn: 'Records why {instance} is being reopened', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'The reason sits at the top of the new round, so whoever picks the question up knows what changed since it was closed.' });
2383
2386
 
2384
- def('steel.rfi-retry', { label: 'Retry', actsOn: 'Reads the filed RFIs again', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Offered only when the record could not be read. Unresolved sizes are listed either way — those come from the model on screen, not from the record.' });
2387
+ def('steel.rfi-retry', { label: 'Retry', actsOn: 'Reads the filed RFIs again', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Offered only when the record could not be read. Unresolved sizes are listed either way — those come from the model on screen, not from the record.' });
2385
2388
  def('steel.review-list', { label: 'Connections needing review', actsOn: 'Lists the imported connections whose steel has moved since they were placed', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Listing them changes nothing in the model; picking one selects the steel it is watching.' });
2386
2389
  def('steel.untracked-list', { label: 'Connections not being watched', actsOn: 'Lists the imported connections that are not being watched for moved steel', group: 'In the steel editor header', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Every connection placed before this feature existed is untracked. It is not a fault.' });
2387
2390
  // #935 — the plan-registration refusal surfaces. Listing and reading change nothing in the model; the
@@ -2479,13 +2482,13 @@
2479
2482
  def('steel.detail-delete-keep', { label: 'Keep the picture', actsOn: 'Leaves {instance} and its placed copies as they are', group: 'In the Details dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand' });
2480
2483
  def('steel.connection-row-field', { label: 'Connection library field', actsOn: 'Sets the value for {instance}', group: 'In the Connections dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand' });
2481
2484
  def('steel.connection-row-delete', { label: 'Remove connection row', actsOn: 'Deletes the connection-library row for {instance}', group: 'In the Connections dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Used rows require confirmation. Placed geometry remains but loses its recipe reference.' });
2482
- def('steel.rfi-profile', { label: 'Set RFI profile', actsOn: 'Sets the live profile for {instance} so FloLess can price the member and check any filed size answer', group: 'In the RFI dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand' });
2483
- def('steel.rfi-profile-retry', { label: 'Retry profile check', actsOn: 'Saves the live profile again and rechecks {instance} against current RFI truth', group: 'In the RFI dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Offered only after saving or reading current RFI truth failed. The row stays paused until the saved model and the RFI record agree, so retrying cannot expose a stale Apply or Resolved action.' });
2485
+ def('steel.rfi-profile', { label: 'Set RFI profile', actsOn: 'Sets the live profile for {instance} so FloLess can price the member and check any filed size answer', group: 'In a steel project’s RFIs step', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand' });
2486
+ def('steel.rfi-profile-retry', { label: 'Retry profile check', actsOn: 'Saves the live profile again and rechecks {instance} against current RFI truth', group: 'In a steel project’s RFIs step', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Offered only after saving or reading current RFI truth failed. The row stays paused until the saved model and the RFI record agree, so retrying cannot expose a stale Apply or Resolved action.' });
2484
2487
  // #1723 — a height the drawing states, proposed instead of asked for. Every one of these is the same
2485
2488
  // edit as typing the elevation in Properties, so it clears the "not confirmed" mark on that end.
2486
- def('steel.rfi-use-height', { label: 'Use or confirm a height', actsOn: 'Sets {instance} as the top of steel for that member end', group: 'In the RFI dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use applies a height read off the drawing; Confirm keeps the height already drawn, offered only where the drawings back it. Nothing changes until you choose, and FloLess re-reads the questions first and refuses if the offer has changed.' });
2487
- def('steel.rfi-height', { label: 'Height', actsOn: 'Holds the height you type for {instance}', group: 'In the RFI dialog', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Nothing changes until Set height is pressed or Enter is typed.' });
2488
- def('steel.rfi-set-height', { label: 'Set height', actsOn: 'Sets the typed height as the top of steel for {instance}', group: 'In the RFI dialog', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use it when the proposed height is wrong or there is none. It is the same edit as typing the elevation in Properties.' });
2489
+ def('steel.rfi-use-height', { label: 'Use or confirm a height', actsOn: 'Sets {instance} as the top of steel for that member end', group: 'In a steel project’s RFIs step', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use applies a height read off the drawing; Confirm keeps the height already drawn, offered only where the drawings back it. Nothing changes until you choose, and FloLess re-reads the questions first and refuses if the offer has changed.' });
2490
+ def('steel.rfi-height', { label: 'Height', actsOn: 'Holds the height you type for {instance}', group: 'In a steel project’s RFIs step', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Nothing changes until Set height is pressed or Enter is typed.' });
2491
+ def('steel.rfi-set-height', { label: 'Set height', actsOn: 'Sets the typed height as the top of steel for {instance}', group: 'In a steel project’s RFIs step', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use it when the proposed height is wrong or there is none. It is the same edit as typing the elevation in Properties.' });
2489
2492
  def('steel.inspector-use-height', { label: 'Use or confirm a height', actsOn: 'Sets {instance} as the top of steel for that member end', group: 'In the Properties panel', persistence: 'working', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'Use applies a height read off the drawing; Confirm keeps the height already drawn, offered only where the drawings back it. Nothing changes until you choose, and FloLess re-reads the questions first and refuses if the offer has changed.' });
2490
2493
  def('steel.provisional-select', { label: 'Inspect source trace', actsOn: 'Selects the exact source-view trace for {instance} and opens its evidence inspector', group: 'On the steel canvas', persistence: 'none', interaction: 'instant', risk: [], guidance: 'on-demand', why: 'A source trace is evidence, not physical steel, so selecting it exposes the unresolved placement without enabling model edits.' });
2491
2494
  def('steel.provisional-review', { label: 'Review question', actsOn: 'Opens the unresolved placement question for source-only members on this view', group: 'On the steel canvas', persistence: 'none', interaction: 'dialog', risk: [], guidance: 'on-demand', why: 'The traced member stays outside the physical model until its drawing scale, registration, and endpoint readings establish one placement.' });
@@ -206,6 +206,35 @@ export function clearancesHtml(it, note = '') {
206
206
  <div class="row-actions"><button type="button" data-act="fill-clearances" data-standard="us" data-tip="${tip}" data-command-id="drawing-check.fill-clearances#us" data-command-instance-label="US practice (AISC)">US practice (AISC J3.3 standard holes)</button>
207
207
  <button type="button" data-act="fill-clearances" data-standard="en1090" data-tip="${tip}" data-command-id="drawing-check.fill-clearances#en1090" data-command-instance-label="EN 1090-2">EN 1090-2 (normal round holes)</button></div></div>`;
208
208
  }
209
+ /**
210
+ * Whether the main part's mark is the assembly mark (owner ruling 2026-10-25, #2756), under "Part list agrees with the
211
+ * title": normally yes (the row carrying the assembly mark), rarely no (the first row with a mark). Two checks use it.
212
+ * Read from a title-block field, the quantity comes with no assembly mark, so there is nothing to choose: said, not offered.
213
+ */
214
+ /** The R1 item R7 follows (server `mainRowItem`): the ticked one, else the first. The setting shows under it. */
215
+ export function mainRowItem(list) {
216
+ const r1s = (list || []).filter((x) => x.rule && x.rule.type === 'part-list-agrees');
217
+ return r1s.find((x) => x.enabled) || r1s[0];
218
+ }
219
+ export function mainPartHtml(it, { touched = false, note = '', locatedOn = false } = {}) {
220
+ // The chip sits outside the heading's text, so the group's name is the question alone.
221
+ const head = (chip) => `<p class="clear-head"><span id="main-part-h">Main part: is its mark the assembly mark?</span>${chip}</p>`;
222
+ const open = `<div class="clear-panel" role="group" aria-labelledby="main-part-h">`;
223
+ const m = it.rule.mainRow;
224
+ const fromField = !!it.rule.assemblyQty && it.rule.assemblyQty.from !== 'drawing-title';
225
+ if (fromField && m === 'first-marked-row') {
226
+ return `${open}${head('')}<div class="band ask-band" role="note"><span>This checklist reads the assembly quantity from a title-block field, where no assembly mark is read, so the main part is the first part-list row with a mark.</span></div></div>`;
227
+ }
228
+ // Any other setting there (a "yes" kept from before, or an older first-row one) is said, and No offered.
229
+ const stale = fromField ? `<div class="band ask-band" role="note"><span>This checklist reads the assembly quantity from a title-block field, where no assembly mark is read${m === 'mark-equals-assembly' ? ', so no part-list row can be matched to it' : ''}. Choose No to take the first part-list row with a mark.</span></div>` : '';
230
+ const opt = (v, on, words) => `<button type="button" role="radio" aria-checked="${on}" tabindex="${on || (m === 'first-row' && v === 'yes') ? 0 : -1}" data-main-row="${esc(v)}" data-command-id="drawing-check.main-part#${esc(v)}" data-command-instance-label="${esc(words)}">${esc(words)}</button>`;
231
+ const unticked = it.enabled ? '' : `<p class="note">${locatedOn ? 'This item is not ticked, so only “Every part is located” uses this setting.' : 'Neither check that uses this setting is ticked.'}</p>`;
232
+ return `${open}${head(` <span class="chip">${touched ? 'set by you' : 'proposed from the references'}</span>`)}
233
+ ${stale}<div class="seg" role="radiogroup" aria-labelledby="main-part-h">${opt('yes', m === 'mark-equals-assembly', 'Yes, same as the assembly mark')}${opt('no', m === 'first-marked-row', 'No, use the first marked row')}</div>
234
+ ${m === 'first-row' ? '<p class="note">Now the first part-list row is taken, whatever its mark. Choose one.</p>' : ''}
235
+ <p class="note">Normally the main part is the part-list row whose mark is the assembly mark in the drawing title. “Part list agrees with the title” and “Every part is located” both use it. Choose No only if this client lists the main part under a different mark.</p>
236
+ ${unticked}${note ? `<p class="note" role="status">${esc(note)}</p>` : ''}</div>`;
237
+ }
209
238
  export const KIND_WORDS = { standard: 'standard holes', oversize: 'oversize holes', 'short-slot': 'short slots', 'long-slot': 'long slots' };
210
239
  export const STANDARD_NAMES = { us: 'US practice (AISC J3.3, standard holes)', en1090: 'EN 1090-2 (normal round holes)' };
211
240
  function lenText(l) {
@@ -224,7 +253,7 @@ export function clientFieldHtml(client) {
224
253
  // ── keeping keyboard focus across a re-render (pure, exported for server/drawing-check-ui.test.ts) ─
225
254
 
226
255
  /** The attributes that name a control stably across re-renders, in the order they are tried. */
227
- const FOCUS_KEYS = ['data-tb-label', 'data-tb-required', 'data-tb-remove', 'data-typed-label', 'data-typed-use', 'data-type-label', 'data-item', 'data-tab', 'data-act', 'id'];
256
+ const FOCUS_KEYS = ['data-main-row', 'data-tb-label', 'data-tb-required', 'data-tb-remove', 'data-typed-label', 'data-typed-use', 'data-type-label', 'data-item', 'data-tab', 'data-act', 'id'];
228
257
  const attrEsc = (v) => String(v).replace(/["\\]/g, '\\$&');
229
258
  /**
230
259
  * A selector that finds "the same control" in freshly rendered markup, or null. A read-mode button is
@@ -643,7 +672,7 @@ function boot() {
643
672
 
644
673
  // ── loading ──
645
674
  async function loadDraft() {
646
- S.clearNote = ''; // a note about the last fill says nothing true about a draft read afresh
675
+ S.clearNote = ''; S.mainNote = ''; // a note about the last change says nothing true about a draft read afresh
647
676
  const res = await fetch(`/api/contract/${encodeURIComponent(APP)}?project=${encodeURIComponent(PROJECT)}&quietMissing=1`, { credentials: 'same-origin' });
648
677
  if (res.status === 204) { S.draft = null; S.etag = null; return; }
649
678
  if (res.status === 404) throw new Error('This profile could not be found. It may have been archived; open it again from Workspaces.');
@@ -1007,7 +1036,8 @@ function boot() {
1007
1036
  return `<label class="check-row"><input type="checkbox" data-item="${esc(it.id)}" data-command-id="drawing-check.tick-item#${esc(it.id)}" data-command-instance-label="${esc(it.label)}"${it.enabled ? ' checked' : ''}>
1008
1037
  <span class="lbl">${esc(it.label)}<span class="origin">${esc(origin)}</span></span>
1009
1038
  ${pct !== null ? `<span class="freq${pct < 50 ? ' rare' : ''}" data-tip="How often this held on the reference drawings"><span class="bar"><i style="width:${pct}%"></i></span>${pct}%</span>` : '<span></span>'}
1010
- <span class="kind">by code</span></label>${it.rule && it.rule.type === 'hole-bolt' ? clearancesHtml(it, S.clearNote) : ''}`;
1039
+ <span class="kind">by code</span></label>${it.rule && it.rule.type === 'hole-bolt' ? clearancesHtml(it, S.clearNote) : ''}${it.rule && it.rule.type === 'part-list-agrees' && mainRowItem(list) === it
1040
+ ? mainPartHtml(it, { touched: ((S.draft && S.draft.touched) || []).includes(`item:${it.id}.mainRow`), note: S.mainNote, locatedOn: list.some((x) => x.enabled && x.rule && x.rule.type === 'parts-located') }) : ''}`;
1011
1041
  }).join('');
1012
1042
  return `<div class="wrap"><h2>Checklist</h2>
1013
1043
  <p class="lede">Common doesn’t mean required. Tick only what this client needs.</p>
@@ -1072,6 +1102,37 @@ function boot() {
1072
1102
  } finally { itemsInFlight--; }
1073
1103
  });
1074
1104
  }
1105
+ // Whether the main part's mark is the assembly mark: one PUT on the checklist queue, as the clearance fill.
1106
+ // Each main part click is numbered: an answer settles the choice on the page unless a later click is on its way.
1107
+ let mainClicks = 0;
1108
+ function putMainPart(assemblyMark) {
1109
+ itemsInFlight++;
1110
+ const click = ++mainClicks;
1111
+ return itemsQueue(async () => {
1112
+ S.checklistError = ''; S.mainNote = '';
1113
+ try {
1114
+ const { body } = await call(`${base}/main-part`, jsonOpts('PUT', { assemblyMark }, S.etag ? { 'if-match': S.etag } : {}));
1115
+ S.etag = body.etag;
1116
+ S.mainNote = `Main part set to “${assemblyMark ? 'same as the assembly mark' : 'the first marked row'}”. The checklist has to be approved again.`;
1117
+ // The server marks the setting the person's; so does the page, for the "set by you" chip.
1118
+ const r1 = mainRowItem(body.items);
1119
+ if (r1) S.draft.touched = [...new Set([...(S.draft.touched || []), `item:${r1.id}.mainRow`])];
1120
+ if (itemsInFlight === 1) { S.draft.items = body.items; await loadReview(); render(); }
1121
+ else if (click === mainClicks) {
1122
+ // Not the last answer, but the last main part click: what was saved is shown, even if a reload after
1123
+ // another edit's refusal put back the old choice. Other items wait for the last answer (review r2).
1124
+ const mine = mainRowItem(S.draft.items);
1125
+ if (mine && r1 && mine.id === r1.id) { mine.rule.mainRow = r1.rule.mainRow; render(); }
1126
+ }
1127
+ // Otherwise a later click is still queued: its choice stays as shown.
1128
+ } catch (e) {
1129
+ if (e.status === 412 || e.status === 428) S.conflict = true;
1130
+ else S.checklistError = e.message;
1131
+ await loadDraft().catch(() => {});
1132
+ render();
1133
+ } finally { itemsInFlight--; }
1134
+ });
1135
+ }
1075
1136
  // Checklist edits go out ONE AT A TIME. Two quick ticks used to send the second PUT with the etag the
1076
1137
  // page held before the first answered, which the server rightly refused (412) — shown as "changed in
1077
1138
  // another window" and the tick reverted. Each queued PUT reads S.etag when it actually goes out.
@@ -2135,6 +2196,18 @@ function boot() {
2135
2196
  refocusIfLost(document, root, `[data-tb-read="${CSS.escape(t.dataset.tbRead)}"][aria-checked="true"]`);
2136
2197
  return;
2137
2198
  }
2199
+ if (t.dataset.mainRow) {
2200
+ const it = mainRowItem(items());
2201
+ const want = t.dataset.mainRow === 'yes', row = want ? 'mark-equals-assembly' : 'first-marked-row';
2202
+ // As a read mode: the choice shows at once; the answer (or a reload after a refusal) settles it.
2203
+ if (it && it.rule.mainRow !== row) {
2204
+ it.rule.mainRow = row; S.mainNote = ''; render();
2205
+ root.querySelector('[data-main-row][aria-checked="true"]')?.focus();
2206
+ await putMainPart(want);
2207
+ }
2208
+ refocusIfLost(document, root, '[data-main-row][aria-checked="true"]');
2209
+ return;
2210
+ }
2138
2211
  if (t.dataset.tbRemove) { await putTitleBlock({ remove: t.dataset.tbRemove }); return; }
2139
2212
  const act = t.dataset.act;
2140
2213
  if (act === 'add-field') { addFieldDialog(); return; }
package/dist/web/guide.js CHANGED
@@ -855,9 +855,12 @@
855
855
  const paintCard = () => {
856
856
  const focusBack = card.contains(document.activeElement);
857
857
  card.replaceChildren();
858
+ // #2678: AI Chat's one line for a hidden card says it still waits while the suggestion is open (set below), not after.
859
+ delete card.dataset.waits; delete card.dataset.waitsSays;
858
860
  const aside = setAsideFor(moveKey, move);
859
861
  if (aside) {
860
862
  moveKey = aside.key;
863
+ card.setAttribute('aria-label', `Not now: ${text.title}`);
861
864
  const line = el('div', 'ai-chat-connection-collapsed');
862
865
  const undo = el('button', '', 'Undo');
863
866
  undo.type = 'button';
@@ -891,11 +894,13 @@
891
894
  const tick = el('span', '', '✓ '); tick.setAttribute('aria-hidden', 'true');
892
895
  head.lastChild.append(tick, document.createTextNode(`${move.toolName} installed`));
893
896
  card.classList.add('is-connected');
897
+ card.dataset.waits = 'done'; // #2678: installed, so AI Chat folds it to one line by itself
894
898
  card.append(head, el('p', 'ai-chat-filter-note', 'Ready to use.'), status);
895
899
  if (focusBack) { card.tabIndex = -1; card.focus({ preventScroll: true }); }
896
900
  return;
897
901
  }
898
902
  card.classList.remove('is-connected');
903
+ card.dataset.waits = 'you';
899
904
  const head = el('div', 'ai-chat-filter-card-head');
900
905
  head.append(el('span', 'guide-move-eyebrow', 'Suggested'), el('strong', '', text.title));
901
906
  card.append(head);
@@ -1000,6 +1005,7 @@
1000
1005
  if (update?.state === 'building') {
1001
1006
  // The card stays in the Guide for days, so it says what happened, not that the AI is still working.
1002
1007
  card.setAttribute('aria-label', `Draft created: ${workflowName}`);
1008
+ card.dataset.waits = 'done'; // #2678: built in its own chat, so AI Chat folds this card by itself
1003
1009
  head.append(el('span', 'guide-move-eyebrow', 'Draft created'), el('strong', '', workflowName));
1004
1010
  card.append(head, el('p', 'ai-chat-filter-why', 'It is built in the workflow’s own chat. You can leave and come back.'));
1005
1011
  const open = button('Open workflow', 'shell.guide-move-open-workflow', 'Opens this workflow’s build conversation. If the AI never got its first message, this sends it again.', 'ai-chat-filter-apply');
@@ -1007,6 +1013,7 @@
1007
1013
  actions.append(open); first = open;
1008
1014
  card.append(actions, status);
1009
1015
  } else if (update?.state === 'failed') {
1016
+ card.dataset.waits = 'you'; card.dataset.waitsSays = 'Not started. Expand it to try again or open the draft.';
1010
1017
  card.setAttribute('aria-label', `Not started: ${workflowName}`);
1011
1018
  head.append(el('span', 'guide-move-eyebrow', 'Not started'), el('strong', '', `“${workflowName}” is saved as a draft, but its chat didn’t start`));
1012
1019
  card.append(head);
@@ -1030,6 +1037,7 @@
1030
1037
  actions.append(retry, open); first = retry;
1031
1038
  card.append(actions, status);
1032
1039
  } else {
1040
+ card.dataset.waits = 'you';
1033
1041
  card.setAttribute('aria-label', `Suggestion: ${text.title}`);
1034
1042
  head.append(el('span', 'guide-move-eyebrow', 'Suggested'), el('strong', '', text.title));
1035
1043
  card.append(head);
@@ -135,16 +135,11 @@
135
135
  <span class="ws-access-label">Project access</span><span class="ws-access-count" id="ws-access-count" hidden></span>
136
136
  </button>
137
137
  <span class="ctl-sep" aria-hidden="true"></span>
138
+ <!-- #2521 row 5: what the approved head and the working copy rest on, when either is a Quick model. -->
139
+ <span id="ws-quick" class="ws-quick-chips" hidden></span>
138
140
  <button data-command-id="shell.approve" id="ws-approve" type="button" class="primary"
139
141
  data-tip="Review every pending change before signing off.">Review &amp; approve</button>
140
142
  </div>
141
- <!-- Per-workflow onboarding beacon. Pulses "✨ Start here" while this workflow is
142
- new to the user (no first Run completed, not dismissed); calms to a quiet
143
- "❔ Guide" after — always clickable for re-reference. Hidden until an app loads. -->
144
- <button data-command-id="guide.open" id="guide-beacon" class="guide-beacon" type="button" hidden aria-haspopup="dialog" data-tip="New here? See what this workflow does and how to run it.">
145
- <span class="guide-beacon-ico" aria-hidden="true">✦</span>
146
- <span class="guide-beacon-label">Start here</span>
147
- </button>
148
143
  <span class="run-state" id="run-state" role="status" aria-live="polite" aria-atomic="true"></span>
149
144
  <!-- Restore + Customize: shown for a MAINTAINED (publisher:floless, non-forked) app. Restore
150
145
  appears only when its logic drifted (re-installs the official version); Customize (fork) is
@@ -293,8 +288,9 @@
293
288
  <!-- One toolbar under the message box: attach, the conversation's scope, access and units, then Send. -->
294
289
  <div class="ai-chat-scope-controls" id="chat-scope-controls" hidden>
295
290
  <button type="button" id="chat-scope-toggle" data-command-id="shell.chat-scope-open" aria-expanded="false" aria-controls="chat-scope-picker">Scope</button>
296
- <button type="button" id="chat-access-explanation" data-command-id="shell.chat-access-explanation#hidden" aria-expanded="false" aria-controls="chat-scope-disclosure" aria-label="Explain Read only access" data-tip="Show what this access level allows."><span class="sr-only">Access · </span><strong>Read only</strong><span class="ai-chat-access-chevron" aria-hidden="true">⌄</span></button>
297
- <span id="chat-scope-disclosure" aria-live="polite" hidden></span>
291
+ <!-- A quick switch, like the AI terminals' own: the four levels, each with its one-line note (web/chat.js). -->
292
+ <button type="button" id="chat-access-chip" data-command-id="shell.chat-access-open" aria-haspopup="menu" aria-expanded="false" aria-controls="chat-access-menu" aria-label="Access: Read only. Change access"><span class="sr-only">Access · </span><strong>Read only</strong><span class="ai-chat-access-chevron" aria-hidden="true">⌄</span></button>
293
+ <div class="ai-chat-access-menu" id="chat-access-menu" role="menu" aria-labelledby="chat-access-menu-head" hidden></div>
298
294
  <section class="ai-chat-picker ai-chat-scope-picker" id="chat-scope-picker" role="dialog" aria-label="Conversation scope" hidden></section>
299
295
  </div>
300
296
  <!-- #1890: once a workspace conversation's units are chosen, a units chip ("ft-in ⌄") with a two-item menu. -->
@@ -373,7 +369,7 @@
373
369
  <div class="canvas-drop-target" id="canvas-drop-target" aria-hidden="true">
374
370
  <div class="canvas-drop-icon" aria-hidden="true">⤓</div>
375
371
  <div class="canvas-drop-label">Drop a .flo file to import</div>
376
- <div class="canvas-drop-sub">The workflow installs and is added to your picker</div>
372
+ <div class="canvas-drop-sub">It opens as a draft — Compile it to add it to your picker</div>
377
373
  </div>
378
374
  <input data-command-id="menu.import" type="file" id="import-file" accept=".flo,.app,.flow,.aware" hidden>
379
375
  <div class="find-overlay" id="find-overlay">
@@ -450,7 +446,9 @@
450
446
  <button data-command-id="shell.workspace-step#history" type="button" data-step="history" role="tab" aria-selected="false">History</button>
451
447
  <button data-command-id="shell.workspace-step#pages" type="button" data-step="pages" role="tab" aria-selected="false">Pages</button>
452
448
  <button data-command-id="shell.workspace-step#workflows" type="button" data-step="workflows" role="tab" aria-selected="false" hidden>Workflows</button>
449
+ <button data-command-id="shell.workspace-step#rfis" type="button" data-step="rfis" role="tab" aria-selected="false" hidden>RFIs</button>
453
450
  <button data-command-id="shell.workspace-step#modules" type="button" data-step="modules" role="tab" aria-selected="false" hidden>Modules</button>
451
+ <button data-command-id="shell.workspace-step#journal" type="button" data-step="journal" role="tab" aria-selected="false" hidden>History</button>
454
452
  </div>
455
453
  <span class="ws-step-end">
456
454
  <!-- Shown only on the Drawings/Source step. It used to have a 42px band of its own labelled
@@ -515,9 +513,15 @@
515
513
  <!-- #2470 R6.2: Workflows = a SHELL-rendered pane: the workflows this project owns.
516
514
  project-workflows.js fills it on step-switch (flolessProjectWorkflows.render). -->
517
515
  <div class="ws-pages ws-workflows" id="ws-workflows" hidden></div>
516
+ <!-- #2470 R6.6: RFIs = a SHELL-rendered pane: a General project's questions for the engineer, client or architect.
517
+ project-rfis.js fills it on step-switch (flolessProjectRfis.render). -->
518
+ <div class="ws-pages ws-rfis" id="ws-rfis" hidden></div>
518
519
  <!-- #2470 R6.7: Modules = a SHELL-rendered pane: the module projects linked to a General project.
519
520
  project-modules.js fills it on step-switch (flolessProjectModules.render). -->
520
521
  <div class="ws-pages ws-modules" id="ws-modules" hidden></div>
522
+ <!-- #2470 R6.5: History = a SHELL-rendered pane: what happened in a General project (its journal).
523
+ project-history.js fills it on step-switch (flolessProjectHistory.render). -->
524
+ <div class="ws-pages ws-journal" id="ws-journal" hidden></div>
521
525
  <!-- Knowledge = a SHELL-rendered pane (not an iframe): the project's Knowledge Base.
522
526
  workspaces.js fills it on step-switch (renderKnowledge). Stage B ships the References
523
527
  column (drop / useAsKb / remove / Organize); the graph + note columns are Stage C/D.
@@ -802,6 +806,22 @@
802
806
  </div>
803
807
  </div>
804
808
 
809
+ <!-- #2521 row 7b: the confirm step after picking drawings for a Steel model project. The Model choice is painted
810
+ into #rb-choice by askRevisionBuild (web/workspaces.js), preset to the model's own mode; Queue read is the
811
+ person's consent. -->
812
+ <div class="modal-backdrop" id="revision-build-modal" role="dialog" aria-modal="true" aria-labelledby="rb-title" aria-describedby="rb-files rb-sub">
813
+ <div class="modal ac-dialog rb-dialog">
814
+ <div class="modal-title" id="rb-title" tabindex="-1">Read these drawings into the model</div>
815
+ <div class="rb-files" id="rb-files"></div>
816
+ <div class="modal-sub" id="rb-sub">FloLess queues one drawing read for your AI. Nothing changes in the model until you review it.</div>
817
+ <div id="rb-choice"></div>
818
+ <div class="modal-actions">
819
+ <button data-command-id="shell.dialog-cancel#reading drawings" id="rb-cancel">Cancel</button>
820
+ <button data-command-id="shell.revision-read-queue" id="rb-ok" class="primary">Queue read</button>
821
+ </div>
822
+ </div>
823
+ </div>
824
+
805
825
  <!-- AWARE runtime + installed-host-bridge upgrade. One dedicated surface is
806
826
  shared by the footer pill and Workspaces recovery actions. Progress comes
807
827
  from the server transaction; this UI never infers installer completion. -->
@@ -1259,7 +1279,7 @@
1259
1279
  </div>
1260
1280
  <div class="report-actions">
1261
1281
  <button data-command-id="shell.report-stop" id="report-stop" class="ghost report-stop" hidden data-tip="Stop this workflow run">■ Stop run</button>
1262
- <button data-command-id="shell.report-share" id="report-share" class="ghost" hidden data-tip="Share this report as a link anyone can view — hosted on floless.io">↗ Share</button>
1282
+ <button data-command-id="shell.report-share" id="report-share" class="ghost" hidden data-tip="Share this report as a link anyone can view, hosted on floless.io. When the run made a Page version, this shares the workflow’s Page, whose link keeps updating.">↗ Share</button>
1263
1283
  <button data-command-id="shell.report-download" id="report-download" class="ghost" hidden data-tip="Download the complete read-only model property report">↓ Download complete report</button>
1264
1284
  <button data-command-id="shell.report-watch" id="report-watch" type="button" class="ghost" hidden data-tip="Play the video this run rendered">▶ Watch video</button>
1265
1285
  <button data-command-id="shell.report-open-file" id="report-open-file" class="ghost" hidden data-tip="Open the saved file in its default app">⧉ Open file</button>
@@ -1391,6 +1411,29 @@
1391
1411
  </div>
1392
1412
  <div class="project-setup-note">The standard is fixed for this project. Display units can be changed later.</div>
1393
1413
  </fieldset>
1414
+ <!-- #2521 row 7a: how the first read builds the model. Shown only with Create project & start chat for a Steel
1415
+ model from drawings, the one path here that starts a read. Pressing Quick shows its terms in full: pressing it
1416
+ and creating is the person's consent, the same terms the chat card states (QUICK_MODEL_TERMS). -->
1417
+ <fieldset class="project-setup-field project-setup-standard project-setup-build" id="project-setup-build" hidden>
1418
+ <legend class="project-setup-label">Model</legend>
1419
+ <div class="project-setup-standard-options">
1420
+ <button type="button" data-build-mode="quick" data-command-id="shell.project-build-mode#Quick" aria-pressed="false"
1421
+ aria-describedby="project-setup-quick-terms">
1422
+ <span class="project-setup-standard-label">Quick model</span>
1423
+ <span>AI answers the drawing questions · faster · not precise</span>
1424
+ </button>
1425
+ <button type="button" data-build-mode="precise" data-command-id="shell.project-build-mode#Precise" aria-pressed="true">
1426
+ <span class="project-setup-standard-label">Precise model</span>
1427
+ <span>You answer them · hours · best evidence</span>
1428
+ </button>
1429
+ </div>
1430
+ <div class="project-setup-quick-terms" id="project-setup-quick-terms" role="group" aria-label="Quick model terms" aria-live="polite" hidden>
1431
+ <strong>Before you create a Quick model</strong>
1432
+ <p>The AI answers this read's drawing questions itself instead of asking you, and files an RFI, marked as its own, only for a question it cannot settle; nothing is sent to anyone. It records every decision it makes, so you can review them afterwards, and the model is labelled as a Quick model. The AI never approves anything: you still decide on the Drawing Filter and on the review.</p>
1433
+ <p id="project-setup-quick-create-only">Create project only starts no read, so it builds no Quick model. To build one later, ask for a Quick model in AI Chat.</p>
1434
+ </div>
1435
+ <div class="project-setup-note" id="project-setup-build-locked" hidden>This setup was already sent with this choice, so it continues with it. To choose differently, cancel and start a new project.</div>
1436
+ </fieldset>
1394
1437
  <!-- Which AI answers this project's conversation (#1605). The same Claude / Codex choice the
1395
1438
  AI Chat empty state asks, with each one's own sign-in underneath; it defaults to the AI
1396
1439
  FloLess would pick, so Create project & start chat stays one click. Hidden with that
@@ -1537,6 +1580,17 @@
1537
1580
 
1538
1581
  <!-- Save-on-switch confirmation — shown when switching workflows with unsaved
1539
1582
  input changes. Reuses the shared modal styling; no new backdrop look. -->
1583
+ <!-- New RFI (project-rfis.js, #2470 R6.6): the Project access sheet's chrome; its body is the form or the Cite picker. -->
1584
+ <div class="modal-backdrop pa-backdrop pm-backdrop pr-backdrop" id="project-rfi-sheet" role="dialog" aria-modal="true" aria-labelledby="pr-title" aria-describedby="pr-sub">
1585
+ <aside class="pa-sheet pr-sheet" tabindex="-1">
1586
+ <header class="pa-head">
1587
+ <div><h2 class="pa-title" id="pr-title">New RFI</h2><p class="pa-subtitle" id="pr-sub"></p></div>
1588
+ <button type="button" class="pa-close" id="pr-close" aria-label="Close" data-tip="Close" data-command-id="shell.project-rfi-sheet-close">✕</button>
1589
+ </header>
1590
+ <div class="pa-body" id="pr-body"></div>
1591
+ <footer class="pa-foot pr-foot" id="pr-foot"></footer>
1592
+ </aside>
1593
+ </div>
1540
1594
  <!-- Add a module / Link an existing project (project-modules.js, #2470 R6.7): the Project access sheet's chrome. -->
1541
1595
  <div class="modal-backdrop pa-backdrop pm-backdrop" id="project-modules-sheet" role="dialog" aria-modal="true" aria-labelledby="pm-title" aria-describedby="pm-sub">
1542
1596
  <aside class="pa-sheet pm-sheet" tabindex="-1">
@@ -1775,37 +1829,6 @@
1775
1829
  </div>
1776
1830
  </div>
1777
1831
 
1778
- <!-- Per-workflow onboarding "Start here" guide. Surfaces the workflow's plain-English
1779
- description + a live "Set inputs → Compile → Run" checklist (ticks from real state),
1780
- and relays a "walk me through it" ask to the terminal AI. A styled modal — never a
1781
- native dialog; body (#guide-body) is rendered per-open in aware.js. -->
1782
- <div class="modal-backdrop" id="guide-modal">
1783
- <div class="modal guide" role="dialog" aria-modal="true" aria-labelledby="guide-title" tabindex="-1">
1784
- <div class="guide-eyebrow" id="guide-eyebrow">✦ Start here</div>
1785
- <div class="modal-title" id="guide-title">Workflow</div>
1786
- <div class="modal-sub">What this workflow does, and how to go through it.</div>
1787
- <div id="guide-body"></div>
1788
- <div class="modal-actions">
1789
- <button data-command-id="shell.guide-dismiss" id="guide-got-it">Got it</button>
1790
- <button data-command-id="shell.guide-walk" id="guide-walk" class="primary">Walk me through it →</button>
1791
- </div>
1792
- </div>
1793
- </div>
1794
-
1795
- <!-- One-time first-open spotlight: dims the canvas and points at the "Start here"
1796
- beacon, then collapses into it. Shown once per workflow; Esc / click-away / either
1797
- button dismiss it. The beacon gets .spotlit so it sits above the dim. The bubble is
1798
- positioned next to the beacon at open time (aware.js). -->
1799
- <div id="guide-spotlight" class="guide-spotlight" hidden>
1800
- <div class="guide-spotlight-bubble" role="dialog" aria-modal="false" aria-label="New workflow tip" tabindex="-1">
1801
- <div class="guide-spotlight-text">New to this workflow? <strong>Start here</strong> — see what it does and how to run it.</div>
1802
- <div class="guide-spotlight-actions">
1803
- <button data-command-id="shell.guide-dismiss" type="button" id="guide-spotlight-got" class="ghost">Got it</button>
1804
- <button data-command-id="shell.guide-walk" type="button" id="guide-spotlight-show" class="primary">Show me</button>
1805
- </div>
1806
- </div>
1807
- </div>
1808
-
1809
1832
  <!-- Routines — scheduled .flo runs. The list; the add/edit form is its own modal. -->
1810
1833
  <div class="modal-backdrop" id="routines-modal">
1811
1834
  <div class="modal routines">
@@ -2130,8 +2153,11 @@
2130
2153
  <script src="agents.js"></script>
2131
2154
  <script src="project-access.js"></script>
2132
2155
  <script src="pages.js"></script>
2156
+ <script src="run-history.js"></script>
2133
2157
  <script src="project-workflows.js"></script>
2134
2158
  <script src="project-modules.js"></script>
2159
+ <script src="project-rfis.js"></script>
2160
+ <script src="project-history.js"></script>
2135
2161
  <script src="guide.js"></script>
2136
2162
  <script src="connections.js"></script>
2137
2163
  <script src="local-discovery.js"></script>