refactor(desktop): migrate workspace leave and ownership transfer onto the design system
Merged
CH
5d ago+95+95+01234567890123456789-106-106-012345678901234567890123456789
D22 of the design-system migration (Desktop stack, base feature/desktop-d21-workspace-linear-connections, #3400).
What
- Settings › Workspace's last section, the way out, is
@luke/ui'sSettingsSection(untitled, as before), itsLEAVEsearch anchor on a wrapperdiv, as Members, Invitations and Integrations do. - A member's or an admin's leave is a
SettingsRow: label "Leave ‹workspace›", the line for what goes as its description, and Leave as theDANGER_OUTLINEButton(replacingtoolbar-button bordered-button+data-danger), as Profile's Delete account is since D15. - The owner's leave is a
SettingsRowsaying a handover comes first, with Transfer ownership as the outlineButton; with no admin to hand it to, the row says to make one first and offers nothing. The owner of the account's own workspace still sees no leave at all. - The handover dialog's New owner is a
FormFieldover the barrel's fieldChip(+ChipName), replacing the window'sCompatChipwith a class and the hand-rolled.dialog-field. The label now names the chip (for→ the chip's id); itsaria-label"New owner: ‹name›" is unchanged. The chip's 220px floor is a container (.workspace-heir), not a class on the control. - Behaviour is unchanged: the leave and the transfer ask first through
ConfirmDialog, the leave names what stays and stops (the reader's automations by name where the service says whose), a refusal stays in the dialog, and Transfer sendsWORKSPACE_TRANSFERfor the admin chosen (the first unless another is).
Selectors
- Removed:
.dialog-field,.dialog-field-label,.workspace-heir .luke-chip-face > svg:last-child(the field look already puts the chevron at the end), and the page's privateRowCopy. .workspace-heiris now the chip's container (grid,min-width: 220px);.leave-consequencesmoved onto--luke-*tokens.- The
../chipimport is gone from this page (chip.tsxstays for its other callers).
Visible changes
- Leave / Transfer ownership use the shared button faces (weight 500), as Delete account and Connect do.
- The rows' label and description use the label (13/18, 500) and caption (12/16) roles, matching the sections above.
- The section's card is the shared section's.
- New owner's label is the label role (13/18, 500, text colour) rather than 12px/600 secondary.
- The consequences list is set in the body role (13/20, was 12.5px/1.5), the dialog body's size above it, in the muted ink.
- The dialog's parts now stand at the dialog's own 8px gap: the field and the consequences list lose the extra 12px above them.
- Below a 380px row, the button drops below the words, per the shared row contract.
Tests
workspace-page.test.ts: the three leave tests read a row's line through the file's existingrowWords/ROWShelpers (a newleaveLine) instead of the old row'ssmalland.settings-row. What they assert is unchanged. Everything else passes as is (53/53).- No new tests: no user-visible behaviour changed.
pnpm check:affectedexits 0.
Evidence
Captured on Linux with headless Chrome at 1280×840, animations held still. The real WorkspacePage was rendered in jsdom by a throwaway, uncommitted copy of the page's test, with synthetic workspaces. Its leave section and dialogs were placed in the built desktop stylesheet inside the SettingsPage frame. The small grey captions over each card label the case and are not part of the app.
| Light | Dark | |
|---|---|---|
| Rows: member/admin; owner with an admin; owner with none | ![]() | ![]() |
| Leave dialog (admin, one automation of theirs named) | ![]() | ![]() |
| Transfer ownership dialog | ![]() | ![]() |
Not verified on a Mac
- SF Pro rendering of the rows, the dialog and the chip
- Leaving or transferring against a live workspace, which only the tests cover
- The search-result ring landing on the leave section in the real window
🤖 Generated with Claude Code





