Migrate the remaining inline confirmations to ConfirmationModal #213
Loading…
Reference in a new issue
No description provided.
Delete branch "migrate-inline-confirmations"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes task 221. One visual language for "are you sure?" rather than two. Presentation consolidation, not a redesign — every site keeps its own wording, destructive styling, disabled-while-in-flight states, focus behaviour and Escape semantics.
Migrated:
PlaceFormPaneldelete,GroupFormPaneldelete (its cascading place-count wording preserved — that text is load-bearing, not decoration), andPendingInvitationRow's decline.ConfirmationModalgrewBusy, disabling Confirm and Cancel while a mutation is in flight. ADR-0136's own Alternatives anticipated and deferred exactly this, so no new ADR was needed — the shared component grew rather than a second variant being forked.The decline site was structurally the hardest, not a markup swap. Nesting
ConfirmationModalinside a row that itself goesinertaround it would have made the confirmation inert too — the precise bug ADR-0136'sSuppressedByStackedOverlaysaga already found once in a real browser while every bUnit assertion passed. The confirmation and its state moved up toAccount, which is also the firstConfirmationModalstacked over ordinary page content rather than anotherModalOverlay-hosted panel, soAccount.razor's.page-contentnow carries its owninertbinding.Excluded, each with the reason recorded in code:
PlaceForm's move confirmation — stays a real<form>submit. A button in a separate stacked modal sits outside the form, reopening the second-entry-point problem ADR-0066 forbids. This is the honest exception the ticket allowed.GroupMemberRow(remove/promote/leave) — ADR-0065 deliberately chose inline for this list-scoped case, and ADR-0136 never names it among the sites task 221 converts. Converting it would silently reopen a decision nobody revisited.Accountdeletion — no such UI exists in the WebUI at all, only the API client method. The ticket assumed a confirm site that has never been built; nothing to migrate.GroupMembersPanel— surveyed, has no confirm-shaped markup of its own; all of it delegates toGroupMemberRow.Watched to fail, per site, as the ticket required — each mutation wired the destructive action to fire without confirmation:
PlaceFormPanel—PlaceFormPanel_DeleteButtonClicked_ShowsAConfirmationNamingThePermanenceRatherThanDeletingImmediatelyreddened on an unexpected DELETE.GroupFormPanel—GroupFormPanel_DeleteButtonClicked_NamesTheCascadingPlaceCountInTheConfirmationreddened the same way.Account—Account_DeclineCancelled_LeavesTheInvitationListedAndCallsNothingreddened, the confirmation vanishing before Cancel could be clicked because the decline had already happened.E2E: added
DeclineInvitationJourneyTests, the only genuinely new browser-only plumbing here, sinceAccountis the first non-panelConfirmationModalhost.PlaceFormPanel's stacked-confirmation mechanism is already covered byEditAndDeletePlaceJourneyTestsandDiscardConfirmationJourneyTestsand is centralised inModalOverlay, unchanged.GroupFormPanel's delete has no E2E coverage — a pre-existing gap, not deepened here, recorded rather than left silent. Run confirmed genuinely executing withPLACEMARK_RUN_E2E_TESTS=true, and caught a real locator bug in the new test on its first run.Suite totals re-derived, not carried over: Domain 39, Contracts 139, Architecture 148, WebUI 923 passed / 4 skipped, Infrastructure 360, Api 622, E2E 61/61. Coverage ratchet held from a Release build with the merged Cobertura report — WebUI 91.7% against a 91.6% baseline.
Verdict: mergeable
Checked against task 221 and ADR-0136:
GroupFormPanel.DeleteConfirmPrompt's place-count wording is untouched (read the getter directly — cascading-count logic identical). Test assertion changes are selector-only or expand to the synchronousmodal-overlay-panel-closingcheck patternPlaceFormPanel's discard tests already established for task 220 — none change what behaviour is under test.ConfirmationModalrenders as.page-content's sibling, before the div that goesinert, not nested inside it — the exact class of bug ADR-0136'sSuppressedByStackedOverlaysaga found is avoided here by construction.DeclineInvitationJourneyTestsis real browser coverage of exactly this new stacking shape, which is the right place to have spent the E2E budget on this PR.ConfirmationModal.Busy: read ADR-0136's Alternatives directly — it was explicitly proposed and rejected as premature, deferred by name to task 221 ("task 221 extends the component when a real caller needs it"). No ADR-0137 needed; the PR's claim holds.PlaceFormmove confirmation — ADR-0066's single-entry-point constraint is real.GroupMemberRow— ADR-0065's "Inline confirmation, not a modal" section genuinely justifies the list-scoped inline pattern on its own merits; nothing here reopens it.DeleteAccount/DeleteMeAsyncappears only inPlaceMarkApiClient.Users.cs; no.razorcaller exists.GroupMembersPanel— read the file; it has no confirm markup of its own, everything delegates toGroupMemberRowvia events.Account.razor/GroupFormPanel/PlaceFormPanelis consistent with the claimed shape.Non-blocking observations:
GroupFormPanel's delete has no E2E coverage, same as before this PR. Lower risk thanAccount's new stacking shape (it reusesPlaceFormPanel's already-covered mechanism verbatim), but giveninert/stacking defects here have twice only been found in a real browser, a follow-up ticket for it is reasonable rather than required.CI (run #892, SHA
d755c66— matches head) was stillrunningat review time; confirm it finished green (apart from the knownRememberViewportJourneyTestsflake onmain, task 277) before merging.