Jobs: the options sheet and the repeat sheet #175

Closed
opened 2026-08-23 19:46:05 +00:00 by nalum · 0 comments
Owner

Part of the jobs flow redesign. The design handoff (design_handoff_jobs_flow, held outside the repo) is the source; the facts it depends on are repeated here so this issue stands alone.

... opens a bottom sheet holding only what the rows cannot do: the repeat rule, Make it part of another job, a separator, and Delete. The header names the job and summarizes it, because the menu also opens from a card.

Make it part of another job is conditional, not merely consequential. SetParent refuses a candidate that carries a repeat rule, a deadline, list membership or children, each with a named reason (internal/services/item/setparent.go:58-86). So:

  • the entry pre-clears what it can and says so first;
  • it is absent when the job has sub-jobs of its own;
  • it is absent when the job repeats and the reader may not clear the rule. SetParent is open to a child (permissions.go:122), SetRepeat is not (:116);
  • the pre-clear is three writes — SetRepeat(nil), SetDeadline(""), SetParent. Capture the old values, restore them if the last one fails, and say so. Offline the three must go together or not at all, which the queue cannot express today (see the grouped-writes issue).

The repeat sheet. Five chips plus No, one per shape a job rule can hold: every day, every Tuesday, every fortnight on Tuesday, on the 9th monthly, 2nd Tuesday of the month. Below a divider, a sentence builder for everything else. Then the readback, which is the most important element: one next date and what completing early or late does (internal/domain/item.go:117). Completion also clones the whole checklist onto the successor (completeitem.go:272-305), so the readback names the returning sub-jobs too.

Do not offer weekdays, a multi-day strip, a yearly rule or an end date: ItemRepeat.weekday is a single int, EVERY_N_YEARS is events-only, and the rule has no end. RepeatEditor is shared with events, which legitimately keep both — gate by kind rather than deleting them.

The chip wording must match the label helper and conformance/repeat.json, which today pins Every 2 weeks on Tuesday, Monthly on day 2 and Monthly on the 2nd Tuesday. Chips, helper and fixture change together, both surfaces, one commit.


Two requirements added after #213 shipped

The job sheet went out to the family's cluster three times before it was right.
Seven visual defects, none caught by a suite: pickers that unfolded forms
instead of opening, three Save buttons on a commit-on-blur screen, (optional)
labels, a reward's name used as a field label, an unstyled add row, checkboxes
with a ghosted tick, and a create form with a browser spinner. Every one had to
be found by a person looking at a screen.

1. Screenshot goldens are part of this ticket

Record gallery (Playwright) and Roborazzi cases for every surface this ticket
builds or visibly changes, and treat them as a deliverable rather than a
follow-up. Three of #213's defects — the unstyled add row, the ghosted
checkboxes, the spinner in the create form — were pixel faults that a golden
would have caught before a deploy did.

#172 deferred its goldens on the reasoning that later tickets would re-record
them. That reasoning was sound then and is not now: the row grammar and the
pickers are settled, so an image recorded here stays valid.

Mechanics, from AGENTS.md: a new case rides in the same commit as the code
that adds it — a commit that adds a gallery or Roborazzi case without its image
is red on its own, because check / web runs npm run test:screens and
android / build runs verifyRoborazziDebug. A re-recorded existing case
goes in its own commit, so the reviewable diff stays code.

2. Check for leaked form styling before you finish

Every visual defect on #213 came from one place: the shipped app's form
fragments reused inside the new row grammar. They pass every test, because the
tests assert the pieces exist rather than that the screen reads right.

Before you call this done, grep the surfaces you touched and report what you
found and what you did about each:

  • a raw <input> / OutlinedTextField / BasicTextField outside the row and
    picker components — a form field dropped into a list of rows
  • type="number", which renders browser spinner arrows
  • btn, link-btn, btn-quiet or TextButton where a row or a quiet row
    verb belongs — underlined links reading as broken text
  • (optional) in any label — §8 names that pattern as the form admitting it
    should not have asked
  • any Save button on a surface that commits on blur, including Save changes and Save the points
  • a disabled-and-grey control where law 5 wants it absent
  • a record's title used as a field row's label — that column is for a
    field's name (Who, When, Worth), and a long title wraps in it

If your ticket is the first to land after this was written, add the check to
AGENTS.md beside the goldens rule, so it stops being a thing I remember to say.

Part of the jobs flow redesign. The design handoff (`design_handoff_jobs_flow`, held outside the repo) is the source; the facts it depends on are repeated here so this issue stands alone. `...` opens a bottom sheet holding only what the rows cannot do: the repeat rule, `Make it part of another job`, a separator, and Delete. The header names the job and summarizes it, because the menu also opens from a card. **`Make it part of another job` is conditional, not merely consequential.** `SetParent` refuses a candidate that carries a repeat rule, a deadline, list membership or children, each with a named reason (`internal/services/item/setparent.go:58-86`). So: - the entry pre-clears what it can and says so first; - it is absent when the job has sub-jobs of its own; - it is absent when the job repeats and the reader may not clear the rule. `SetParent` is open to a child (`permissions.go:122`), `SetRepeat` is not (`:116`); - the pre-clear is three writes — `SetRepeat(nil)`, `SetDeadline("")`, `SetParent`. Capture the old values, restore them if the last one fails, and say so. Offline the three must go together or not at all, which the queue cannot express today (see the grouped-writes issue). **The repeat sheet.** Five chips plus `No`, one per shape a job rule can hold: every day, every Tuesday, every fortnight on Tuesday, on the 9th monthly, 2nd Tuesday of the month. Below a divider, a sentence builder for everything else. Then the readback, which is the most important element: one next date and what completing early or late does (`internal/domain/item.go:117`). Completion also clones the whole checklist onto the successor (`completeitem.go:272-305`), so the readback names the returning sub-jobs too. Do not offer weekdays, a multi-day strip, a yearly rule or an end date: `ItemRepeat.weekday` is a single int, `EVERY_N_YEARS` is events-only, and the rule has no end. `RepeatEditor` is shared with events, which legitimately keep both — gate by kind rather than deleting them. The chip wording must match the label helper and `conformance/repeat.json`, which today pins *Every 2 weeks on Tuesday*, *Monthly on day 2* and *Monthly on the 2nd Tuesday*. Chips, helper and fixture change together, both surfaces, one commit. --- ## Two requirements added after #213 shipped The job sheet went out to the family's cluster three times before it was right. Seven visual defects, none caught by a suite: pickers that unfolded forms instead of opening, three Save buttons on a commit-on-blur screen, `(optional)` labels, a reward's name used as a field label, an unstyled add row, checkboxes with a ghosted tick, and a create form with a browser spinner. Every one had to be found by a person looking at a screen. ### 1. Screenshot goldens are part of this ticket Record gallery (Playwright) and Roborazzi cases for every surface this ticket builds or visibly changes, and treat them as a deliverable rather than a follow-up. Three of #213's defects — the unstyled add row, the ghosted checkboxes, the spinner in the create form — were pixel faults that a golden would have caught before a deploy did. `#172` deferred its goldens on the reasoning that later tickets would re-record them. That reasoning was sound then and is not now: the row grammar and the pickers are settled, so an image recorded here stays valid. Mechanics, from AGENTS.md: a **new** case rides in the same commit as the code that adds it — a commit that adds a gallery or Roborazzi case without its image is red on its own, because `check / web` runs `npm run test:screens` and `android / build` runs `verifyRoborazziDebug`. A **re-recorded existing** case goes in its own commit, so the reviewable diff stays code. ### 2. Check for leaked form styling before you finish Every visual defect on #213 came from one place: the shipped app's form fragments reused inside the new row grammar. They pass every test, because the tests assert the pieces exist rather than that the screen reads right. Before you call this done, grep the surfaces you touched and report what you found and what you did about each: - a raw `<input>` / `OutlinedTextField` / `BasicTextField` outside the row and picker components — a form field dropped into a list of rows - `type="number"`, which renders browser spinner arrows - `btn`, `link-btn`, `btn-quiet` or `TextButton` where a row or a quiet row verb belongs — underlined links reading as broken text - `(optional)` in any label — §8 names that pattern as the form admitting it should not have asked - **any Save button on a surface that commits on blur**, including `Save changes` and `Save the points` - a disabled-and-grey control where law 5 wants it absent - a record's title used as a field row's `label` — that column is for a field's name (`Who`, `When`, `Worth`), and a long title wraps in it If your ticket is the first to land after this was written, add the check to AGENTS.md beside the goldens rule, so it stops being a thing I remember to say.
nalum closed this issue 2026-08-26 18:34:16 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
eagraiclainne/app#175
No description provided.