fix(studio): let the auto-join toggle show what it just saved - #175
Merged
Merged
Conversation
The toggle reads whether the workspace admits everyone from the workspace itself, but the callback it was given only refreshed the member list beside it. So a save landed on the server and the checkbox snapped straight back, which reads as a control that cannot be pressed rather than one whose answer arrived late. Admitting everyone also backfills the member list, so that one save leaves both stale, and the refresh belongs to the pair rather than to either caller. The box beside the label was also sitting high. Its nudge assumed the line box came from the small text inside the label, where a label carries the strut of whatever it inherits and a span cannot shrink it. Putting the size on the row makes the line the height the nudge already expected. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JXXoZwM5RfHUzW6vScoeqv
mroops0111
force-pushed
the
fix/auto-join-toggle
branch
from
September 15, 2026 07:49
6a1eea6 to
9d4fb47
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.
What
Two small defects on the Admit Anyone Who Signs In checkbox, in the workspace details sheet.
The toggle looked unpressable
It reads its own state from the workspace (
productManifest.autoJoinAs), but theonChangedcallback it was handed only invalidatedqueryKeys.workspaceMembers. The PATCH landed, the workspace query was never refetched, and the controlled checkbox re-rendered with the oldchecked={false}.To anyone using it, the click does nothing. The write had in fact succeeded every time.
invalidate()was written for its two original callers,MemberRowandAddMemberControl, which both edit the member list.AutoJoinControlwas later wired to the same callback but edits the workspace, so that edge was missing. Since turning this on also backfills existing users into the member list, one save genuinely leaves both queries stale, so the second invalidation belongs in the shared helper rather than in one caller'sonSuccess.The checkbox sat about 4px high
mt-0.5centres a 12px box on a 16px line, which is whattext-2xs(11px / 16px) gives. Buttext-2xswas on the twospans inside thelabel, not on the label, and a label carries the strut of whatever it inherits. With no size pinned anywhere above it the strut is the browser default plus preflight'sline-height: 1.5, so the first line box was 24px and the nudge under-shot by 4px.Moving the size onto the row makes the line the height the existing nudge already assumed. Same idiom as the two-line checkbox in
Build.tsx. Also addedshrink-0so the box cannot be squeezed next toflex-1text in a narrow sheet.Verification
@braidhq/studiotypecheck, lint, and 268 tests passdottedsign'sPRODUCT.mdcarriesautoJoinAs: guestNote
This is display-only. No change to the permission model, the route, or the manifest.
🤖 Generated with Claude Code
https://claude.ai/code/session_01JXXoZwM5RfHUzW6vScoeqv