Repository navigation
feat(patchy): onboarding sets up the company look, and the personal default style retires - #582
allisonmahmood wants to merge 45 commits into
Conversation
Tier 0's content policy had no font-src, so default-src 'none' blocked every font, even a data: one. Allow data: fonts in the policy the hosted shell and the local runtime share; remote fonts stay blocked. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Inter's Latin subset (OFL) as a data: @font-face, read by the policy tests, the repo bundle check and pnpm seed:dev. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
One pure module, @patchy/core/look, that the CLI and the instance both run: the 15 tokens declared once each as opaque #RRGGBB, no !important, everything inside @layer look, WCAG contrast for text on both grounds and accent-fg on accent, data: URLs only, and the two size caps from the limits registry. The four prototype looks, contrast-fixed, are its fixtures. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
A company owns numbered look revisions, each with its author, time, note and three files, and a nullable pointer to the current one. GET /api/look is for any active member; POST /api/look/publish and /api/look/restore are admin-only and refuse members with the active admins' names. Publishing reruns the core look checks and serializes per company; restore moves the pointer only. Both report business events after commit. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
patchy look prints the company's current revision and history, with the files' contents under --json. look publish checks a look folder with the core look checks before sending it; look restore takes a revision number or none. A member's refusal relays the admins to ask in the failure document. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…t map Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…d commits Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Duolingo's lip, press and uppercase labels and Patchy's hover shadow and press move from plain elements into LOOK.md recipes; element styles keep to colours, fonts, borders, radius and spacing, as the verdict on #547 asks. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
A token counts only in a :root rule directly inside @layer look, and @Property may not register one. Escaped names, string addresses in image-set() and src(), NUL characters, and a logo with script, handlers or foreignObject are refused. A leading @charset and the @layer look; statement are accepted. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…n_unavailable Looks.Revision and Current become plain interfaces; nothing decodes them. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…mary Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…s colour only Refusing every @Property closes an escaped prelude registering a token; a look never needs one. The Linear fixture's plain button hover drops its brightness filter for a colour mix. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The specimen is one fixed page that ships in the CLI, styled only by a look. look preview writes it as a self-contained file in the state dir, for a candidate folder, the company's look, or both with --compare, and lists every failure look publish would report without refusing to render. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The state dir is created 0700 and the page goes through a sibling temp file and a rename, as State's other files do, so a link at look-preview.html is replaced instead of truncating its target. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
… has them - hover and focus stand-ins replace each pseudo-class in place with :is(), inside :not() and :is() too, so negations and :focus:not(:focus-visible) behave as the real state would - the specimen's own CSS follows the look unlayered, so its amount column and error spacing aren't overridden by the look's element styles - badges keep text on the verified ground and carry status in the border - no <form>, so the single-look page publishes as a tier 0 page - compare frames are border-box, ending a 1px overflow; a browser test renders a compare page Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
… as a page Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Generation writes it for a company with no look, so it has to be in the server image; core's fixtures folder is not. The fixture helper reads it from its new home. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…sion Every generation now carries patchy/_generated/look.css, the logo when the current revision has one, and the patchy-look project skill: the style order plus the revision's brief. With no company look it writes the Patchy look as Patchy's default, with no logo and a null stamp. index.json records the revision as `look`, in the shape `patchy look --json` uses. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Tier 1 and 2 starters import patchy/_generated/look.css from src/main.tsx; the tier 0 starter links it from index.html, and the single-file build inlines it, embedded fonts included. AGENTS.md points at the patchy-look skill. Tests cover the starter page building in a look with an embedded font at tiers 0 and 1, and refresh swapping look files while page source stays untouched. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The CLI README, product doc, generate route, Publishing glossary (Managed files, Project skill, Patchy look), skill distribution and context map say how a repo gets the company look and what index.json's look records. patchy-loop points agents at the patchy-look skill before styling, which also reaches repos made before the scaffold imported the look. The image build checks the Patchy look ships. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Sequential replaces let a note containing <!-- look-brief --> take the brief and leave the real marker unfilled. One pass over the template never searches filled text. The generated README no longer calls the Patchy look the company's. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The success and warning badges and the selected tab hard-coded colours left from the 13-token prototype, so a page lifting them kept Patchy's colours after the company published its own look. They now tint --look-success, --look-warning and --look-accent. The provenance line no longer names paths a patch repo doesn't have. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…mand The scan now covers every HTML, CSS and script file outside dependencies, builds, dot folders and generated files, so a root stylesheet that imports the look counts, and it skips comment lines, so a commented-out import doesn't. Revisions compare by number and time, since numbers restart per company. The checks are advisory: a failed look read at publish becomes a warning and the publish goes ahead, before the build; a refresh without /api/me names "The company". Notices are remembered only once activation succeeds, so a rolled back refresh announces nothing, and publish remembers its warning when found. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
… say Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…e admins A static page settles its style with `patchy look --json`, but a company with no look got `current: null` and nothing to style by. The read now carries the Patchy look's `look.css` and `LOOK.md` as `patchyLook` while `current` is null, and `admins`, so a member's agent can say who changes the look without attempting a change. The Patchy look moves from the SDK into Companies beside the look it stands in for; `Looks` reads it once and generation uses the same copy. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The company look replaces the personal default style, so nothing reads or writes `style.md` and `status --json` drops `hasDefaultStyle`. Nobody has a setup yet, so there is no migration. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…tand-in and admins Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…yle retires Onboarding's style question becomes the company look: after login, an admin whose company has no look is asked "You're at acme.com. Want your tools to look like Acme?", from their email domain unless it is webmail; the agent captures the site, shows the specimen and publishes revision 1. A member is asked nothing, and someone joining a company with a look is told their tools use it. The portal's setup line runs this step too, since it is the first moment an agent meets a company's creator. Static pages and the welcome page settle their style with `patchy look --json` in the spec's order; the welcome page's own CSS uses only the look's tokens. Changing the look takes an explicit request: a member hears who the admins are and can show a draft's specimen as a page; an admin's change shows the comparison first. `style-file.md` becomes the capture reference, and the old plan-doc style goes now that the Patchy look is reachable. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
|
Review round 1 (stack orchestration for #547): one Claude Opus 5.5 reviewer and three GPT-6.1 Sol reviewers (wire + CLI + retirement; the global skill as a fresh agent reads it; an independent fresh-agent probe of two acceptance scenarios against a dev instance), read-only against Agreed sound: the look read's new shape ( Sent to the builder: the welcome page must follow the same four-level style order as every static page, and its badges must not tint a ground the checks didn't verify; the skill should tell agents to save For landing: the look read's shape changed between #577 and this PR, so the six PRs land back to back and deploy once. Posted by Claude Fable 5.1 (orchestrator) in Claude Code, running in T3 Code. |
…rough Path patchyLook's schema is look.css and LOOK.md alone, so the API docs stop offering a logo the Patchy look never has, and Looks locates the shipped folder with Path.fromFileUrl instead of a node:url opt-out. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…s read into a file The welcome page settles its style by the same four-level order as any static page, so a request or the published page's own style wins on a redo. Its badges carry status in text and border on bg or surface, the grounds the look checks verify. Agents write patchy look --json to a file and copy look.css and the logo by script, since embedded fonts can make the read half a megabyte, and the skill says what to do when the read fails. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The Patchy look never carries a logo, so its header recipe and logo section show the company's name instead of Patchy's mark. Its avoid list narrows grids of cards to dashboards tiled with them, as its layout section already says. The Patchy look's glossary entry moves to Companies, which ships it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
|
Review round 2: the orchestrator read the fix commits ( Verdict from the orchestrator: ready to merge after #581. The six PRs land bottom-up (#576 → #577 → #578 → #579 → #581 → #582) and deploy once, since the look read's wire shape changed between #577 and this PR. Posted by Claude Fable 5.1 (orchestrator) in Claude Code, running in T3 Code. |
New patch repos start unstyled: the company look (#565) exists, but nothing carries it into a repo, so every agent invents a style or rebuilds Patchy's by hand. Generation now carries the look as managed files, so init, refresh and dev start all write it: - `patchy/_generated/look.css`, plus `patchy/_generated/logo.svg` when the current revision has one. - The `patchy-look` project skill: a release-bound template (`packages/sdk/skills/patchy-look/SKILL.md`) with the style order, the token meanings and how to use the logo, filled with which look this is and the revision's `LOOK.md`. - `index.json` gains `look`: the revision the files came from, in the shape `patchy look --json` uses (`{ revision, author: { id, name }, createdAt, note }`), or `null`. #568 builds its notices on this. With no company look, generation writes the Patchy look as Patchy's default: no logo, a `null` stamp, and the skill says the company has none yet. The Patchy look's files moved from core's fixtures to `packages/sdk/looks/patchy/` so they ship in the server image; the image build checks they're there, and the logo stays behind. (Later in the stack, #582 moves them again to `packages/companies/looks/patchy/`, so the look API can hand the same files to static pages.) The starters use it: tier 1 and 2 `src/main.tsx` import `look.css`, and tier 0's `index.html` links it. The single-file build inlines it, embedded fonts included, so the first `patchy dev` page is in the company's look at every tier. `AGENTS.md` gets one line pointing at the skill, and `patchy-loop` points there too, which reaches repos made before this change. Closes #567 Built by Claude Opus 5.5 in Claude Code, running in T3 Code. --------- Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
58f360a to
b449d5d
Compare
|
Closed in favour of #598: after the stack rebase onto Posted by Claude Fable 5.1 (orchestrator) in Claude Code, running in T3 Code. |
…efault style retires (#598) Onboarding still captured a personal `style.md` that only one person's static pages ever read, and a static page in a company with no look had no way to reach the Patchy look. This moves onboarding and the global skill to the company look and retires the personal default style. **Onboarding.** Right after login, the agent runs `patchy look --json` and `whoami`: - An admin whose company has no look gets a guess from their email domain ("You're at acme.com. Want your tools to look like Acme?"). A webmail address gets no guess: the agent asks for a site once, or moves on. On yes, it captures the site on the person's machine, shows the specimen with `patchy look preview`, sums the look up in one line and publishes revision 1. - A member is asked nothing. Someone joining a company with a look is told their tools will use it. - The portal's setup line (`Set up Patchy using …/llms.txt`) runs this step too, because that login is the first time an agent meets a company's creator. **The global skill.** - Static pages, the welcome page included, settle their style in the spec's order: what the person asked for, the page's own style, the company look, the Patchy look. - Agents write `patchy look --json` to a file and copy `look.css` and the logo by script, because embedded fonts can make the read half a megabyte. When the read fails, they fix the login or retry, and write a plain page rather than invent a look. - The welcome page's CSS now uses only the look's tokens, so it takes whichever look applies. Its badges carry status in text and border on bg or surface, the grounds the look checks verify. - The look changes only on an explicit request. A member is told who the admins are and can publish a draft's specimen as a page to show them. An admin sees `look preview --compare` before `look publish`. - `style-file.md` becomes `look-capture.md`, built from the prototype's capture draft and its four capture notes. `patchy-plan-style.md` goes, because the Patchy look replaces it. **The wire.** `GET /api/look` (and `patchy look --json`) now carries `patchyLook`: the Patchy look's `look.css` and `LOOK.md` while `current` is null, and null otherwise. It also carries `admins`, so a member's agent can name the admins without attempting a change. The Patchy look moves from `packages/sdk/looks/patchy/` to `packages/companies/looks/patchy/`. `Looks` reads it once, and both generation and the look API use that one copy. Its brief now heads pages with the company's name, since the stand-in never carries Patchy's logo. **Retired.** `status --json` drops `hasDefaultStyle`, and nothing reads or writes `style.md`. There is no migration, since nobody has a setup yet. **Tried with fresh agents** (Claude Code in `/tmp` with only the rewritten skill, against `pnpm dev up team` plus two companies made through create-or-join): - An admin at a real company domain was asked the guess question. The agent captured the site from the product's own CSS in about three minutes, showed the specimen and published revision 1. It then published the welcome page in that look, logo included. - A Gmail admin got no guess, skipped, and got the welcome page in the Patchy look. - A member of a company with a look was asked nothing and told their tools use it. - A member asking for a darker green was told only Ada can change it, and published the draft's specimen as `acme/look-draft`. - An admin asking the same got `look preview --compare` and published revision 2 only after approving. - The creator's real path, on a machine with nothing installed: given only the portal's setup line, the agent ran the installer, relayed the login, then asked the guess question. `llms.txt` needed no change. After the capture, the person said "that's our marketing website, not our product". The agent didn't argue or publish; it found the app behind a login, asked for product material, re-captured from the help centre's app screenshots and the sign-in screen, and published revision 1 once approved. It then handed back to "ask for your first tool" without a welcome page. - Ambiguous domains: `eng.<domain>` was fetched and guessed as the bare domain. A domain that now redirects to another company's site was named as such, and the agent asked for the right site instead of guessing. Closes #569 Built by Claude Opus 5.5 in Claude Code, running in T3 Code. Replaces #582, whose GitHub record stopped tracking the branch after it was rebased onto `main` for landing; the commits are identical. Review rounds and the orchestrator's verdicts are on #582. --------- Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
Release 8 of What's new, written for the deploy of the company look stack (#547, first build). It covers everything merged after release 7's `through`. - **New: Your tools can look like your company** — #577, #579 - **New: Preview a look before you publish it** — #578 - **New: Setting up Patchy sets up your look** — #598 (the rebased replacement for #582) - **Improved: Patches hear when the look changes** — #581 - **Improved: Static pages can use embedded fonts** — #576 - Behind the scenes: the personal style file retires (#598) Written by Claude Fable 5.1 in Claude Code, running in T3 Code. Co-authored-by: Claude Fable 5.1 <[email protected]>
Onboarding still captured a personal
style.mdthat only one person's static pages ever read, and a static page in a company with no look had no way to reach the Patchy look. This moves onboarding and the global skill to the company look and retires the personal default style.Onboarding. Right after login, the agent runs
patchy look --jsonandwhoami:patchy look preview, sums the look up in one line and publishes revision 1.Set up Patchy using …/llms.txt) runs this step too, because that login is the first time an agent meets a company's creator.The global skill.
patchy look --jsonto a file and copylook.cssand the logo by script, because embedded fonts can make the read half a megabyte. When the read fails, they fix the login or retry, and write a plain page rather than invent a look.look preview --comparebeforelook publish.style-file.mdbecomeslook-capture.md, built from the prototype's capture draft and its four capture notes.patchy-plan-style.mdgoes, because the Patchy look replaces it.The wire.
GET /api/look(andpatchy look --json) now carriespatchyLook: the Patchy look'slook.cssandLOOK.mdwhilecurrentis null, and null otherwise. It also carriesadmins, so a member's agent can name the admins without attempting a change. The Patchy look moves frompackages/sdk/looks/patchy/topackages/companies/looks/patchy/.Looksreads it once, and both generation and the look API use that one copy. Its brief now heads pages with the company's name, since the stand-in never carries Patchy's logo.Retired.
status --jsondropshasDefaultStyle, and nothing reads or writesstyle.md. There is no migration, since nobody has a setup yet.Tried with fresh agents (Claude Code in
/tmpwith only the rewritten skill, againstpnpm dev up teamplus two companies made through create-or-join):acme/look-draft.look preview --compareand published revision 2 only after approving.llms.txtneeded no change. After the capture, the person said "that's our marketing website, not our product". The agent didn't argue or publish; it found the app behind a login, asked for product material, re-captured from the help centre's app screenshots and the sign-in screen, and published revision 1 once approved. It then handed back to "ask for your first tool" without a welcome page.eng.<domain>was fetched and guessed as the bare domain. A domain that now redirects to another company's site was named as such, and the agent asked for the right site instead of guessing.Closes #569
Built by Claude Opus 5.5 in Claude Code, running in T3 Code.