Repository navigation
feat(teams): the acting team for a page - #2940
Merged
Merged
Conversation
🎩 PreviewA preview build has been created at: |
1 of 3 tasks
camielvs
force-pushed
the
cvs/acting-team
branch
2 times, most recently
from
October 23, 2026 23:50
36da936 to
8eb46cf
Compare
camielvs
force-pushed
the
cvs/acting-team
branch
from
October 26, 2026 21:56
8eb46cf to
3b2da63
Compare
camielvs
force-pushed
the
cvs/acting-team
branch
3 times, most recently
from
October 28, 2026 23:11
c51e09f to
3f5b7a1
Compare
camielvs
force-pushed
the
cvs/acting-team
branch
3 times, most recently
from
October 29, 2026 23:33
d3efee7 to
af71b7b
Compare
camielvs
commented
Oct 30, 2026
camielvs
force-pushed
the
cvs/acting-team
branch
2 times, most recently
from
October 30, 2026 20:35
6047c77 to
521d2d3
Compare
camielvs
marked this pull request as ready for review
October 30, 2026 21:23
camielvs
force-pushed
the
cvs/acting-team
branch
from
October 30, 2026 21:46
521d2d3 to
18fd6d1
Compare
maxy-shpfy
approved these changes
Oct 30, 2026
`useActingTeam()` resolves the team a page acts as, from the projects the page belongs to. The Secrets window and the secret pickers read it, so they show the secrets that runs submitted from that page will use. A page gets its project from one of two places: - Tangent's embedded editor and run view sit inside `RunSubmissionScopeProvider`, which files runs under the Tangent project. - The standalone editor carries the project in `?projectId=`, which `useRunProjectContext` reads. The hook takes the projects from both and lets `useTeamForProjects` decide, so a page that names projects on two teams resolves to `conflict` rather than picking one. It is a hook over cached queries rather than a new provider: every consumer already sits under the router and the scope provider, and the project, workspace and identity lookups are shared through the query cache. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…header Both project headers now show the workspace a project sits in and, when that workspace belongs to a team, your role in that team: Editor, Reader, No access, or Not a member. A project page otherwise gave no hint that its runs and secrets can belong to a team. The headers mark the workspace with the Shapes icon, and the workspace selector, used when starting a session or creating a project, now shows it on its button, though not on its options. In the session box the selector sits next to the AI model picker, and the icon tells the two apart at a glance. The team itself isn't named. The backend has no display name for a team, only its id, which is long and opaque in a header. The role is read from your memberships, not from whether a run would act as the team, which depends on each run's secrets and its Run as choice. The project page test that asserted the workspace is never named dates from when workspaces scoped nothing; teams changed that. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
camielvs
force-pushed
the
cvs/acting-team
branch
from
October 31, 2026 00:12
18fd6d1 to
2eb00db
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
useActingTeam()resolves the team a page acts as, from the projects the page belongs to. The secret pickers later in this stack read it, so they show the secrets that runs submitted from that page will use.A page gets its project from one of two places:
RunSubmissionScopeProvider, which files runs under the Tangent project.?projectId=, whichuseRunProjectContextreads.The hook takes the projects from both and lets
useTeamForProjectsdecide. A page that names projects on two teams resolves toconflictrather than picking one.It's a hook over cached queries, not a new provider. Every consumer already sits under the router and the scope provider, and the project, workspace and identity lookups are shared through the query cache.
Both project headers also show where you're working: the project's workspace and, when that workspace belongs to a team, your role in that team, as in "Search · Editor". The Tangent header shows it after the share button, and the project page shows it beside the pin.
GET /api/users/me. Until they load, only the workspace's name shows.The headers mark the workspace with the Shapes icon. The workspace selector, used when starting a session or creating a project, now shows it on its button too, though not on its options. In the session box the selector sits next to the AI model picker, and the icon tells the two apart at a glance.
The header doesn't say whether runs act as the team. That depends on each run's secrets and its Run as choice (#2943), so the header only states facts about the project and you. The project page tests asserted that the workspace is never named. That dated from when workspaces scoped nothing, so they now assert the label is shown.
Related Issue and Pull requests
useTeamForSubmission.Type of Change
Line Breakdown
Checklist
Screenshots (if applicable)
None yet.
Test Instructions
Additional Comments
None.
🤖 Generated with Claude Code