Public: anyone can read this; the crew can change it.
An app's page says in one line who can see it (only you, your members, anyone with the link, the public) and the same words reach the MCP #15665
Check · Review · Land · Live done — Landed and live in production.
An app's page now says in one line who can open the app, and the MCP repo read returns the same words in audience.appLine.
shipped production is serving it deploy 3fede26
6 earlier comments · 1 event
An app's page now says in one line who can open the app, and the MCP repo read returns the same words in audience.appLine.
One words function, appVisibilityWords in src/apps/visibility_words.ts, takes the app's access and the repository's visibility and gives one of four lines:
- only you: a private app on a person's repository. The line says "you" only to the owner; anyone else sees the owner's name.
- your members: a private app on an organization's repository.
- anyone with the link: a public app whose code is private.
- the public: a public app on a public repository.
Where it shows:
- App page: on its own line under the existing who-can-see-the-repository sentence (
src/web/chrome.ts,data-app-seen). It comes in the server's first paint and uses the samemuted smallstyle, so it is not a banner and nothing shifts. - MCP and API:
appLineOfinsrc/core/audience.tsbuilds the line, andaudienceForreturns it asaudience.appLine(nullfor a repository with no app).audienceForis the one call the MCPreporead andGET /api/v1/repos/:owner/:nameshare, so both carry the same string. No new tool: therepodoc string gains only the field name, andtest/mcp-size.test.tspasses.
Choices to look at:
- Repository sentence kept: I first had the app line replace it on the app page.
test/audience-surfaces.test.tsexpects that sentence and its Split badge (public code, private app) on the app's home, so I kept it and added the app line beneath it. - Members wording: "members" is the plain word for an organization's private app. Exactly who gets in (people who can change the repository, people it names) is still spelled out in the repository sentence above it.
test/visibility-words.test.ts has one test of the words per visibility, plus two end-to-end checks: the page head and the MCP read give the same line for a private app, and a repository with no app has no line and appLine: null. Gate, tsc --noEmit and design lint are clean. scripts/fast.ts named 2,543 files because chrome.ts is imported almost everywhere, so I ran 61 files by hand (the audience, here, studio-app, chrome and MCP-size tests): 548 pass, 0 fail.
To try it: open an app's page at /:owner/:name and read the line under the title; then call the MCP repo tool on the same repository and compare audience.appLine.
[{"go":"/trevato/lab","look":"the muted lines under the repository title","expect":"a second line saying who can open the app, e.g. 'Anyone with the link can open this app; its code stays private.' or 'Public: anyone can open this app and read its code.'"},{"go":"/trevato/lab","look":"the page as it loads","expect":"the line is there in the first paint; nothing moves","ask":"Does the line read as plain information rather than a banner?"}]
🤖 Generated with Claude Code
<!-- look-pages b855d5e244f8 --> Look pages for b855d5e, from the gate:
look pages (inferred): this pull changes src/web/chrome.ts; the forge pictures / (src/web/chrome.ts), /docs (src/web/chrome.ts), /explore (src/web/chrome.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
An app's page now says in one line who can open the app, and the MCP repo read returns the same words in audience.appLine.
One words function, appVisibilityWords in src/apps/visibility_words.ts, takes the app's access and the repository's visibility and gives one of four lines:
- only you: a private app on a person's repository. The line says "you" only to the owner; anyone else sees the owner's name.
- your members: a private app on an organization's repository.
- anyone with the link: a public app whose code is private.
- the public: a public app on a public repository.
Where it shows:
- App page: on its own line under the existing who-can-see-the-repository sentence (
src/web/chrome.ts,data-app-seen). It comes in the server's first paint and uses the samemuted smallstyle, so it is not a banner and nothing shifts. - MCP and API:
appLineOfinsrc/core/audience.tsbuilds the line, andaudienceForreturns it asaudience.appLine(nullfor a repository with no app).audienceForis the one call the MCPreporead andGET /api/v1/repos/:owner/:nameshare, so both carry the same string. No new tool: therepodoc string gains only the field name, andtest/mcp-size.test.tspasses.
Choices to look at:
- Repository sentence kept: I first had the app line replace it on the app page.
test/audience-surfaces.test.tsexpects that sentence and its Split badge (public code, private app) on the app's home, so I kept it and added the app line beneath it. - Members wording: "members" is the plain word for an organization's private app. Exactly who gets in (people who can change the repository, people it names) is still spelled out in the repository sentence above it.
- Not in the terminal: the terminal's about screen still shows only the repository sentence. Adding the app line there would make its card one line taller, so I left it out.
- Gate lines: the first check failed on three gate rules. The last commit answers them in its message:
Looks: /preview-admin/sample, aNo door:line (a line on an existing page and a field on an existing read, not a new feature), and aDirection:line naming #15632, ahead of #6534. Please check that these reasons are acceptable.
test/visibility-words.test.ts has one test of the words per visibility, plus two end-to-end checks: the page head and the MCP read give the same line for a private app, and a repository with no app has no line and appLine: null. Gate and tsc --noEmit are clean, and design lint passed on the first push. After the gate fix I re-ran test/visibility-words.test.ts, test/audience-surfaces.test.ts and test/mcp-size.test.ts: 19 pass, 0 fail. scripts/fast.ts named 2,543 files because chrome.ts is imported almost everywhere, so before the first push I ran 61 files by hand (the audience, here, studio-app, chrome and MCP-size tests): 548 pass, 0 fail.
To try it: open an app's page at /:owner/:name and read the line under the title; then call the MCP repo tool on the same repository and compare audience.appLine.
[{"go":"/trevato/lab","look":"the muted lines under the repository title","expect":"a second line saying who can open the app, e.g. 'Anyone with the link can open this app; its code stays private.' or 'Public: anyone can open this app and read its code.'"},{"go":"/trevato/lab","look":"the page as it loads","expect":"the line is there in the first paint; nothing moves","ask":"Does the line read as plain information rather than a banner?"}]
🤖 Generated with Claude Code
An app's page now says, under its title, who can open the app, in one of four sentences from src/apps/visibility_words.ts. The repository read returns the same sentence as audience.appLine. That covers GET/PATCH /api/v1/repos/:owner/:name and the MCP repo tool.
This push fixes the six red tests from the last check. They had two causes:
appLinewas in every audience. It had been added toaudienceFor, which also feeds the page manifest (here) and every other caller, so the outsider manifest went over its 1400-character ceiling and other JSON shapes changed.audienceForis back to its old shape. A newrepoAudienceForaddsappLine, and only the repository read uses it.- The line was a new paragraph. That added a block to the first view. It is now a
<span data-app-seen>inside the existing audience paragraph, rendered on the server, so nothing shifts. The wording still adds up to 12 words, sodocs/design/attention-budget.jsonraises the word budget for therepositoryandappviews from 116 to 126, with a note. Block budgets are unchanged.
Three tests changed because the markup and the API read changed on purpose; they were not wrong before:
test/audience-surfaces.test.ts: the paragraph pattern accepts the optional span, and the HTTP read is compared withrepoAudienceFor.test/visibility-line.test.ts: the HTTP read is compared withrepoAudienceFor.test/visibility-words.test.ts: it now matches the span and usesrepoAudienceFor.
Checks run:
- Type check,
scripts/gate.ts --fixanddesign-lintare clean. - The six files that failed pass, plus
test/visibility-words.test.ts. - The 45 test files that mention the audience pass: 448 tests.
scripts/fast.tsnamed 2779 files (about 234 minutes), too broad to run here. That run timed out and moved to the background. I could not stop it from this session, and its result is not part of this report. The forge's full check covers the rest.
Not done: the line is only on the app's page, not on the repository's other tabs or in the page manifest.
To try it: open a private app on your own repository at /:owner/:name. The audience line reads "… Only you can open this app, and anyone you add." GET /api/v1/repos/:owner/:name returns the same words as audience.appLine, or null when the repository has no app.
[
{"go": "/preview-admin/sample", "look": "the muted line under the title", "expect": "the audience sentence, then on the same line who can open the app (e.g. \"Public: anyone can open this app and read its code.\")"},
{"go": "/api/v1/repos/preview-admin/sample", "look": "audience.appLine", "expect": "the same sentence the page shows"},
{"go": "/preview-admin/sample/issues", "look": "the line under the title", "expect": "the audience sentence only, no app line", "ask": "Is one line enough, or should the app sentence also be on the repository's other tabs?"}
]
🤖 Generated with Claude Code
Changes needed, in one round:
- Both doors: the terminal (src/tui/) does not show who can open the app, and there is no docs/features/<name>.md how-to. The pull says it left the terminal out; a person can read this on the page, so the terminal must show it too, gated as the page is.
- Principle 1 (nothing explains itself twice): the line repeats what the repository sentence beside it already says (e.g. 'Public: anyone can open this app and read its code' after 'Public: anyone...'). Fold the app part into one sentence, or show it only when it differs from the repository sentence, and drop the attention-budget raise.
- Tests: only the 'you' case is checked end to end on the page and the MCP. Add the link, members and public cases on the page, and the owner-vs-other viewer case.
- Direction: this is a feature while the pipeline items (#6534, #6611, #5276 ...) are open; keep it small. First fix: the terminal screen plus docs/features page.
Who can open an app is now part of the repository's one audience sentence. The app is mentioned only where it reaches further than the code: private code behind a public app reads "Private: only you; anyone with the link can open its app." In every other case the existing sentence already says who can open it, so nothing is added. That one sentence (audienceOf in src/core/audience.ts) is what the page head, the terminal's About card (I), the API and the MCP all print, so the terminal now shows it too. This round, following review:
- Page: the separate
data-app-seenspan is gone andsrc/web/chrome.tsmatches main again. The attention-budget raise is dropped. - Wording:
src/apps/visibility_words.tsnow says exactly who gets into a private app: whoever can change the repository and the people the app names. The owner reads "you"; anyone else reads the owner's name. - API and MCP:
GET /api/v1/repos/:owner/:nameand therepotool still returnaudience.appLine(nullwhen there is no app), for clients that read only that field. - Docs: new how-to page
docs/features/app-seen-by.md. - Tests:
test/visibility-words.test.tschecks the link, members, public and you cases end to end on the page, the About card and the MCP. It also checks that the owner reads "you" while another viewer reads "olive".
bun x tsc --noEmit, bun scripts/gate.ts --fix and bun scripts/design-lint.ts pass, as do the tests covering this: audience, visibility line, the terminal About card, and the feature-docs and budget tests. scripts/fast.ts found the change too broad to name its tests, so I picked these by hand; the full suite runs on the forge's check. The gate still reports "this pull changes src/web/chrome.ts" because of the earlier commits, but the net diff no longer touches that file. It also noted that repoAudienceFor is close to audienceFor. I left them as two functions so only the repository read carries appLine.
I left out the org case's wording beyond "whoever can change acme's repository": membership of an organization alone does not open its private app.
[
{"go": "/preview-admin/sample", "look": "the muted line under the repository title", "expect": "one sentence about who can see it, with no second sentence about the app after it"},
{"go": "a private repository you own whose app is public, at /:owner/:name and /:owner/:name/app", "look": "the line under the title", "expect": "Private: only you; anyone with the link can open its app."},
{"go": "the same repository in the terminal, About card (I)", "look": "the line under the description", "expect": "the same sentence as the page", "ask": "Does the clause read as part of the sentence, not as a second message?"}
]
🤖 Generated with Claude Code
Earlier asks are met: the separate data-app-seen span and the attention-budget raise are gone, chrome.ts is back to main, the wording names exactly who gets into a private app, the terminal About card prints the same sentence as the page, the how-to is in docs/features/app-seen-by.md and README is untouched. appLine sits behind the repo read, so it leaks nothing the read does not already gate. Each visibility has a test of the words, and the page, About card and MCP are tested end to end. Non-blocking: repoAudienceFor duplicates audienceFor; a spread over audienceFor would do. Non-blocking: box 1 is met through the audience sentence, which says the app only where it reaches further than the code. The standalone four-way line is on the API and MCP only.
An app's page now says in one line who can open the app, and the MCP
reporead returns the same words inaudience.appLine.One words function,
appVisibilityWordsinsrc/apps/visibility_words.ts, takes the app's access and the repository's visibility and gives one of four lines:Where it shows:
src/web/chrome.ts,data-app-seen). It comes in the server's first paint and uses the samemuted smallstyle, so it is not a banner and nothing shifts.appLineOfinsrc/core/audience.tsbuilds the line, andaudienceForreturns it asaudience.appLine(nullfor a repository with no app).audienceForis the one call the MCPreporead andGET /api/v1/repos/:owner/:nameshare, so both carry the same string. No new tool: therepodoc string gains only the field name, andtest/mcp-size.test.tspasses.Choices to look at:
test/audience-surfaces.test.tsexpects that sentence and its Split badge (public code, private app) on the app's home, so I kept it and added the app line beneath it.test/visibility-words.test.tshas one test of the words per visibility, plus two end-to-end checks: the page head and the MCP read give the same line for a private app, and a repository with no app has no line andappLine: null. Gate,tsc --noEmitand design lint are clean.scripts/fast.tsnamed 2,543 files becausechrome.tsis imported almost everywhere, so I ran 61 files by hand (the audience, here, studio-app, chrome and MCP-size tests): 548 pass, 0 fail.To try it: open an app's page at
/:owner/:nameand read the line under the title; then call the MCPrepotool on the same repository and compareaudience.appLine.🤖 Generated with Claude Code
Closes #15632