Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -760,7 +760,13 @@ door's first-tap prompt, shown once; features/lessons.js).
`{ type, index, pageIdx, lineId, before, moved }`, set by the context menu's Move
label row, cleared by the drop, Esc or a right-click; a handle whose line is gone or
on another page cancels itself at the next slide; one slide long, never persisted;
features/mark-context-menu.js).
features/mark-context-menu.js),
`state.placingGhost` + `placingGhostLast` + `placingGhostFromStamp` (the Ghost tool's copy
in hand, features/ghost.js: between a capture and its drop, and since STAMP-PICKUP,
2026-10-13, after a Stamp, which takes the ghost off the sheet and hands it back to the
cursor grabbed where its menu opened; `placingGhostFromStamp` is read by app.js's undo and
redo, which drop the copy in hand because the undo of the stamp puts the ghost back on the
sheet; Esc lets it go, any other tool orphans it in `clearToolStarts`; never persisted).
- `config.example.js` is the template; `config.js` is committed for production.

### Cloud state (when Supabase enabled)
Expand Down
26 changes: 23 additions & 3 deletions ARCHITECTURE.md

Large diffs are not rendered by default.

40 changes: 40 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,46 @@ expired recovery UX" work occupies that slot).

---

## docs: the hand-kept lists caught up to main at 655a023 (2026-10-13)

A read of AGENTS.md, ARCHITECTURE.md, RECONSTITUTE.md, SUPABASE_SETUP.md, FEATURES.md,
FEATURE-CATALOG.md, the Overseer guide and the BOARD-QUIET plan against the code after the seven
PRs since the pass at 5362f42 earlier today (#327 the measuring guide, #328 the BOARD-QUIET row,
#329 PEOPLE-TWINS, #330 REVIEW-BAR, #331 DROP-CARD-BUTTONS, #332 CLOUD-OFF-ICON, #333
STAMP-PICKUP). Each kept its CHANGELOG entry, its ARCHITECTURE rows and, for the board, the
guide; what drifted was the lists beside them, the product copy, and the lines LEAD-ROLE
(2026-10-02) had already left behind in the rows these PRs touched.

- **AGENTS.md.** The in-memory state list gains the ghost in hand (`state.placingGhost`,
`placingGhostLast`, `placingGhostFromStamp`), since STAMP-PICKUP made it a cross-file contract
that app.js's undo reads.
- **ARCHITECTURE.md.** The ghost.spec row said the ghost survives its own stamp for the next drop
and listed neither the STAMP-PICKUP test nor the drag test; the bid-board row named overseers
and admins where the sidebar button and the server have included leads since LEAD-ROLE, and
its spec list lacked this week's three board tests; the review-flow row gave
`setProjectReviewStatus` two arguments and a reviewer set without leads. The feature catalog
("Features Beyond Spec") had no bullet for the Ghost / Stamp tool (2026-08-20) or for the All
Bids board and the review handoff (2026-08-28); both written.
- **FEATURES.md and FEATURE-CATALOG.md.** A line and an entry for the All Bids board with the
review handoff (none of the four board PRs wrote one); a line and an entry for Ghost / Stamp,
which had none since it shipped; and the catalog's Lead role entry, which FEATURES.md had and
the catalog did not.
- **SUPABASE_SETUP.md.** The handoff bullet still had the overseer clicking Mark reviewed on the
card.
- **The Overseer guide.** "Only an overseer or admin can mark it reviewed" and the admins aside
under Granting the role, both from before leads; rebuilt. The board screenshot showed the old
badges (the CLOUD-OFF-ICON entry said so): the generator's callout box still pointed at the
removed `.bid-card-badge-warn`, now `.bid-card-cloud-off`, and `overseer-all-bids.png` is
rebuilt from it (the overlay now right-aligns a callout label whose box sits at the frame's
right edge, where "Cloud status" was clipped).
- **BOARD-QUIET.** The plan's Shipped list lacked CLOUD-OFF-ICON and its closing line still named
the Fully cloud badge as a redundancy to remove; the PUNCHLIST row names the fourth step.
- Code comments the rows copy: features/review-flow.js's and features/bid-board.js's headers
(leads), ghost.spec.js's old stamp test (the pure stamp leaves the ghost in its list). sw.js
restamped for the two shell files.
- Not touched: RECONSTITUTE.md (no shape changed; a ghost in hand is state, not a payload),
JOURNEY-MAP.md, the deck, the courses.

## feat(ghost): Stamp hands the ghost back to the cursor (STAMP-PICKUP, 2026-10-13)

Wendi: "i want the text and box to go away after using a ghost stamp." The box and the word
Expand Down
25 changes: 25 additions & 0 deletions FEATURE-CATALOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,14 @@ reflects all ten automatically. Every counter total surface shows the multiplied
number — sidebar badges, Choose tab, Summary, footer, legend, report all agree — and hovering a
sidebar/Summary badge shows the placed count.

**Ghost / Stamp — a typical that rides the cursor**
*Problem:* A restroom group or a unit layout repeats across a floor at different spots, where a
multiply zone (one spot, many copies) does not fit, and counting each copy by hand is the same
twenty clicks again.
*Useful because:* Rubber-band the placed marks into a translucent copy, drop it where the next one
goes, and Stamp it down as real counted marks; the ghost itself never reaches a total, and after a
stamp it is back in hand for the next spot, so a four-restroom floor is one capture and four stamps.

---

## 3. Counting
Expand Down Expand Up @@ -463,6 +471,23 @@ what they were.
*Useful because:* One view shows which counters and line types you actually use across all your
projects, with one-click adds of the proven ones to your Artboard.

**All Bids board + bid review handoff**
*Problem:* The owner or the senior estimator who needs to see a bid has to ask for it to be shared,
and "it's done, go look" is a chat message nobody tracks.
*Useful because:* An overseer, lead or admin opens every bid in the company from one board (search,
an estimator filter, and a People · Twins · All switch where digital twins run, so the fleet's
backtests stay out of the way). The estimator marks a bid Ready for review from Project Settings;
it joins a pinned lane, oldest waiting first, and opening it shows a Reviewing bar with Request
changes…, Mark reviewed and Next ready, so a morning of reviews is one loop. Both sides see the
state on the bid.

**Lead role — takes over bids without the admin's keys**
*Problem:* The lead estimator who must free a stuck lock, reassign a bid or fix who has access
either waits for an admin or is made one, with the account and delete powers that brings.
*Useful because:* A lead sees every bid, checks out any, forces a live lock, manages a bid's
editors and viewers, marks it reviewed, and hands it to another estimator with one click; users,
passwords, deletes and the global reload stay with admins.

**Admin toolkit — users, projects, activity, force turn-in, global reload**
*Problem:* Team tools usually externalize administration to a separate console (or a support
ticket).
Expand Down
2 changes: 2 additions & 0 deletions FEATURES.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Compiled 2026-07-31 from the live app, ARCHITECTURE.md's feature catalog, and th
- **Synthetic scale bar** — A dashed reference bar drawn on the sheet lets you eyeball a preset scale against a known dimension at any time.
- **Scale zones** — A detail or isometric drawn at a different scale on the same sheet measures correctly without re-scaling the page. On a compressed/rescaled sheet, zone presets carry the same sheet-size correction as the page, so detail and plan agree.
- **Multiply zones** — Count one typical floor, wrap it in a ×10 zone, and the totals reflect all ten — no duplicate clicking. Every counter total surface shows the multiplied ("with repeats") number; hovering a sidebar or Summary badge shows how many marks are physically placed.
- **Ghost / Stamp (G)** — Rubber-band a typical (a restroom group, a unit) into a translucent copy that rides the cursor, drop it where the next one goes, and Stamp it down as real counted marks; the ghost itself never counts, and after a stamp it is back in hand for the next spot, so a four-restroom floor is one capture and four stamps.

## Counting

Expand Down Expand Up @@ -108,6 +109,7 @@ Compiled 2026-07-31 from the live app, ARCHITECTURE.md's feature catalog, and th
- **Viewer scale sharing** — A view-link recipient can set a page scale and it shares back to the project, so field questions get answered without a round trip.
- **Artboard (cloud palette)** — Your counters, line types, modifiers, and Quick Key layout follow your account to any device — set up once, reuse every bid; loading mid-bid re-links your placed marks by name, nothing stops counting.
- **My Standards** — See which counters and line types you actually use across all your projects and add the standards to your Artboard in one click.
- **All Bids board + bid review handoff** — An overseer, lead or admin sees every bid in the company on one board, newest first, with search and an estimator filter (a company running digital twins gets a People · Twins · All switch, so the fleet's backtests stay out of the way). An estimator marks a bid Ready for review from Project Settings; it joins a pinned lane, oldest waiting first, and opening it shows a Reviewing bar with Request changes…, Mark reviewed and Next ready, so a morning of reviews is one loop, not forty trips to the board.
- **Lead role (takes over bids)** — A lead estimator sees every bid, checks out any, frees a stuck lock, manages who has access, and hands a bid to another estimator with one click, without the keys to accounts and deletes an admin holds.
- **Admin toolkit** — Create/manage users, transfer project ownership, force turn-in, audit per-user activity, and push a global reload — all inside the app.

Expand Down
2 changes: 1 addition & 1 deletion PUNCHLIST.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@ How agents add to this list: AGENTS.md, "Recording a to-do".
| TRADE-DEFAULT | A project that never named a trade: does the device's default trade count as the project's? The app answers three ways today, so Bid Check on such a project shows water rows and the IPC edition but no hanger, fitting or plumbing rows. Decide, then one resolver | decision | ⚑ call | — | [DECOMPOSITION_MAP.md](DECOMPOSITION_MAP.md#t06-one-trade-resolver) |
| ICON-STORE | Opening a project REPLACES the user's own icon store with its `customIconPaths` (annotation-model.js:509 and 444 into app.js:209, wholesale; a project with an empty list empties the store), and they ride the user's later saves. Since #268 they are inert, but should a project be able to add icons to a user's store at all? Decide, then build | decision | ⚑ call | — | |
| DEMO-TRACK | The demo track behind the test drive's "Try it" is built for all three trades (phases 1 to 3 landed 2026-10-02). Left: a tester's real tablet and phone walk with a stopwatch against the 60 s target | test | tester | — | [DEMO-TRACK.md](journeys/plans/DEMO-TRACK.md#open-after-phase-2) |
| BOARD-QUIET | All Bids for a lead: the board becomes a quiet list, actions on the hovered row, exceptions only, grouped by estimator once there are enough; PEOPLE-TWINS, REVIEW-BAR and DROP-CARD-BUTTONS shipped the first steps (the twin fleet off by default, the decision in the opened bid only, oldest waiting first) | build | agent | — | [BID-BOARD-QUIET.md](journeys/plans/BID-BOARD-QUIET.md#what-is-left) |
| BOARD-QUIET | All Bids for a lead: the board becomes a quiet list, actions on the hovered row, exceptions only, grouped by estimator once there are enough; PEOPLE-TWINS, REVIEW-BAR, DROP-CARD-BUTTONS and CLOUD-OFF-ICON shipped the first steps (the twin fleet off by default, the decision in the opened bid only, oldest waiting first, the cloud silent unless the PDF is missing) | build | agent | — | [BID-BOARD-QUIET.md](journeys/plans/BID-BOARD-QUIET.md#what-is-left) |
| DEEP-ZOOM | Zoom past 1200% for Wendi: a full-density overlay window for the marks at deep zoom, the ceiling to 5000% with the device and per-sheet guard rails, and a smaller full-page backdrop past 4×; measured safe to 30000% on main, the blur is the marks, not the sheet | build | agent | — | [DEEP-ZOOM.md](journeys/plans/DEEP-ZOOM.md#the-build) |
2 changes: 1 addition & 1 deletion SUPABASE_SETUP.md
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ on conflict (user_id) do update set is_admin = true;
- **Manage User** (admin only) — In User Settings, open Manage User to list all users with role, an owned-**Projects** count, and last sign-in / last active. Per-row actions: **Set password** (🔑, reset any user's password via `admin-set-password`), **Transfer projects** (⇄, move all of a user's projects to someone else via `admin-reassign-projects`), **Overseer toggle** (👁, grant/revoke the read-only see-every-bid role via `admin_set_overseer` — the icon is lit when active and the Role column reads `Overseer`), **View activity** (♥, opens the activity overview), and **Delete**. Delete opens a dialog offering to either delete the user's projects too or **reassign** them to another user first (`admin-delete-user` with `reassignToUserId`). Click a user's **Projects** count to see their project list (name + last-edited), or their stacked **dates** cell / heart icon to open the **Activity overview**. Reassign/transfer moves the project rows *and* their owner-scoped PDF storage objects, preserves inherited view links, and clears redundant shares. You cannot delete yourself.
- **All Users** (admin only) — In User Settings, view all users with role, project count, last sign-in / last active, and per-row **View activity**.
- **Overseer / Bid Board** — A user flagged `profiles.is_overseer` (Manage Users 👁 toggle, or SQL upsert like the admin one above) sees **every project, always read-only**: the **All Bids** board (sidebar button; auto-opens for pure overseers signing in with nothing to restore) lists every bid as cards (name, estimator, counts, last edited) with search + estimator filter, and clicking one opens it in the existing viewer mode. Load Project shows the same full list with the owner filter. No edit, checkout, share, delete, or admin surfaces — enforced server-side (dedicated read-only RLS policies; the checkout RPC refuses overseers). Test-harness accounts' projects are hidden from the board.
- **Bid review handoff** — An estimator marks a cloud bid **Ready for review** from Project Settings (status row + toggle; withdraw or re-request anytime). The Bid Board pins ready bids in a **Ready for review** lane where an overseer/admin clicks **Mark reviewed**; reviewed bids carry a quiet ✓ badge (Load Project rows badge both states too). All transitions go through `set_project_review_status` (server-guarded per role).
- **Bid review handoff** — An estimator marks a cloud bid **Ready for review** from Project Settings (status row + toggle; withdraw or re-request anytime). The Bid Board pins ready bids in a **Ready for review** lane, oldest waiting first; opening one as a reviewer (overseer, lead or admin) shows the review bar under the header with **Request changes…**, **Mark reviewed** and **Next ready** (REVIEW-BAR, 2026-10-13; the cards carry no decision since DROP-CARD-BUTTONS); reviewed bids carry a quiet ✓ badge (Load Project rows badge both states too). All transitions go through `set_project_review_status` (server-guarded per role).
- **My Activity** — In User Settings, any signed-in user can open **My Activity** to see their own activity overview (member-since, total events, counters/lines/exports, active days, rolling windows, and a day-grouped recent-activity feed). Backed by `user_activity_detail_for_admin` (self-or-admin guard).
- **Manage Projects** (admin only) — In Project Settings, open Manage Projects to list all projects across users and delete any project (removes project and stored PDF).
- **Share** — In Project Settings, open Share to add users by email (viewer or editor). Any project member can add users. Editors can check out to edit; one editor at a time. Turn in releases the lock. 30-minute inactivity expiry (lock extends on edits/saves). System admins can force turn-in any project.
Expand Down
10 changes: 5 additions & 5 deletions content/guides/reviewing-all-bids.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,9 @@ sign in, CountTooling brings you back to the bid you last had open; the board is
Project Settings row (or **Withdraw** a request that went up too early).

Who can do what is enforced by the server, not the buttons: only the bid's owner, an editor
on it, or an admin can mark it ready or withdraw; only an overseer or admin can mark it
reviewed. The same badges show up in **Load Project** rows, so estimators see the state of
their own bids wherever they look.
on it, a lead or an admin can mark it ready or withdraw; only an overseer, a lead or an admin
can mark it reviewed. The same badges show up in **Load Project** rows, so estimators see the
state of their own bids wherever they look.

## Granting the role (admins)

Expand All @@ -136,8 +136,8 @@ Users**, each row has an **eye toggle**:
**Role** column reads *Overseer*. Click it again to take the role away; the change applies
the next time they load the app.
- Overseer is **read-everything, write-nothing**. It doesn't grant any admin powers, no user
management, no deleting, no editing other people's projects. (Admins already see every
project and don't need the flag; they also get the All Bids board.)
management, no deleting, no editing other people's projects. (Admins and leads already see
every project and don't need the flag; they get the All Bids board too.)
- The role is a good fit for exactly the person who should *look but never touch*: reviews
stay safe because the server refuses an overseer every write, even if a bug or a
mis-click asked for one.
Expand Down
2 changes: 1 addition & 1 deletion features/bid-board.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
// into the same load path as the Load Project modal
// (App.loadCloudProjectRow, extracted from features/load-project.js), so a
// bid always opens in the existing read-only viewer mode -- the overseer has
// no checkout arm server-side. Admins can open the board too (same button);
// no checkout arm server-side. Admins and leads (LEAD-ROLE) open the board too (same button);
// it auto-opens only for pure overseers signing in with nothing else to
// restore. Cross-file deps read from App at call time: getSupabase,
// showModal, hideModal, escapeHtml, loadCloudProjectRow, showToast.
Expand Down
4 changes: 2 additions & 2 deletions features/review-flow.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
// row (review_status rides it), and hides when the open project is no
// longer the one it was shown for (App.refreshReviewBar, from updateUI).
// All transitions go through the set_project_review_status RPC, which
// enforces who can do what server-side ('ready'/clear: owner, editor share,
// or admin; 'reviewed': overseer or admin) — this file never gates harder
// enforces who can do what server-side ('ready'/clear: owner, editor share, admin or
// lead; 'reviewed' and 'changes': overseer, lead or admin, LEAD-ROLE) — this file never gates harder
// than the server, it only hides the row where it could never apply.

async function setProjectReviewStatus(projectId, status, note) {
Expand Down
4 changes: 2 additions & 2 deletions ghost.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,8 +190,8 @@ test.describe('Ghost tool (features/ghost.js)', () => {
expect(now.counters).toBe(4);
expect(now.lines).toBe(1);

// Re-enable runs and stamp again — the ghost survives its own stamp, so a
// typical can be walked across the sheet and dropped repeatedly.
// Re-enable runs and stamp again: the pure stamp leaves the ghost in its list (it is the
// menu's Stamp that hands it to the cursor, STAMP-PICKUP below), so it stamps repeatedly.
const res2 = await page.evaluate(() => {
const ann = window.App.getActiveAnnotations(window.state.pages[0]);
ann.ghosts[0].showLines = true;
Expand Down
Binary file modified guides/img/overseer-all-bids.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading