Public: anyone can read this; the crew can change it.
Detach from parent goes through the confirm page, which names the parent and says there is no undo #8004
Check · Review · Land · Live done — Landed and live in production.
"Detach from parent" on a fork's Settings › Danger zone now goes through `/-/confirm` before anything happens. A detach can't be undone, so it gets a second step. Posting from the confirm page starts the detach exactly as before: `detachSubmit` is unchanged.
shipped production is serving it deploy cb42fc8
"Detach from parent" on a fork's Settings › Danger zone now goes through /-/confirm before anything happens. A detach can't be undone, so it gets a second step. Posting from the confirm page starts the detach exactly as before: detachSubmit is unchanged.
src/web/pages/detach.ts: the single-button POST form is nowconfirmAction({ action:${repoBase(repo)}/settings/detach, verb: "Detach from parent" }). The card's explanation and failed-job toast are unchanged. One visible difference:confirmActiontakes no icon, so the button loses itsforkglyph.src/web/pages/search.ts:DESTRUCTIVEhas a new entry for^/([^/]+)/([^/]+)/settings/detach$, directly aftersettings/delete. Its title is "Detach <owner>/<name> from its parent?", followed by the detail text from the issue (ending "There is no undo.") and no typed phrase.test/confirm-detach.test.ts(new): checks that the fork admin's danger page links to/-/confirm?to=…/settings/detachand no longer has a direct POST form. It also checks that the confirm page answers 200 with the title, the no-undo line, and a form posting to…/settings/detach. It fails without the change insrc/web.- Changes to existing tests:
- test/fork-detach.test.ts checked for the old action="…/settings/detach" form on the danger page. That check was tied to the old shape, so it now checks for the confirm link. Its same-origin POST and full detach checks are unchanged.
- test/danger-buttons.test.ts had an allowlist entry for this button. The button no longer posts directly, so the entry was stale and is gone.
I didn't touch the terminal's detach.
Checks: bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts are clean. bun test test/confirm-detach.test.ts test/fork-detach.test.ts test/danger-buttons.test.ts passes. scripts/fast.ts named 988 files because search.ts is shared, so instead I ran the 13 test files that use /-/confirm: 221 pass, 0 fail.
To try it: on a fork you admin, open Settings › Danger zone and click "Detach from parent". The confirm page names the fork and says there is no undo; confirming starts the repack as before.
🤖 Generated with Claude Code
Approved. The danger-zone button is now an <a> to /-/confirm (works with JS off). The confirm page answers 200 on the preview, and the POST target and detachSubmit are unchanged. The terminal already confirms with a plan, so both doors match. The new test fails without the change, and the allowlist entry removal is right. Two things I would do next: (1) docs/features/detach.md says the page detaches directly; add that the page goes through /-/confirm. (2) The title says it names the parent, but the confirm page names only the fork, which is a sensible choice since the parent may be unreadable to the viewer. Say that in the doc, or word the pull title to match.
"Detach from parent" on a fork's Settings › Danger zone now goes through
/-/confirmbefore anything happens. A detach can't be undone, so it gets a second step. Posting from the confirm page starts the detach exactly as before:detachSubmitis unchanged.src/web/pages/detach.ts: the single-button POST form is nowconfirmAction({ action:${repoBase(repo)}/settings/detach, verb: "Detach from parent" }). The card's explanation and failed-job toast are unchanged. One visible difference:confirmActiontakes no icon, so the button loses itsforkglyph.src/web/pages/search.ts:DESTRUCTIVEhas a new entry for^/([^/]+)/([^/]+)/settings/detach$, directly aftersettings/delete. Its title is "Detach <owner>/<name> from its parent?", followed by the detail text from the issue (ending "There is no undo.") and no typed phrase.test/confirm-detach.test.ts(new): checks that the fork admin's danger page links to/-/confirm?to=…/settings/detachand no longer has a direct POST form. It also checks that the confirm page answers 200 with the title, the no-undo line, and a form posting to…/settings/detach. It fails without the change insrc/web.-
test/fork-detach.test.tschecked for the oldaction="…/settings/detach"form on the danger page. That check was tied to the old shape, so it now checks for the confirm link. Its same-origin POST and full detach checks are unchanged. -test/danger-buttons.test.tshad an allowlist entry for this button. The button no longer posts directly, so the entry was stale and is gone.I didn't touch the terminal's detach.
Checks:
bun scripts/gate.ts,bun x tsc --noEmitandbun scripts/design-lint.tsare clean.bun test test/confirm-detach.test.ts test/fork-detach.test.ts test/danger-buttons.test.tspasses.scripts/fast.tsnamed 988 files becausesearch.tsis shared, so instead I ran the 13 test files that use/-/confirm: 221 pass, 0 fail.To try it: on a fork you admin, open Settings › Danger zone and click "Detach from parent". The confirm page names the fork and says there is no undo; confirming starts the repack as before.
🤖 Generated with Claude Code
Closes #7978