The dialog is not yours. `alert()` renders browser chrome: your theme does not reach it, your fonts do not reach it, and neither does your dark mode. It is the one surface in the product the design system cannot touch, which makes it the one surface that announces the app was assembled rather than designed. Toast is a component, so it inherits everything — the quebi surface, the status ramps, the radii, the motion — and so is AlertDialog.
It blocks the main thread, and that is a behavioural difference, not an aesthetic one. While an `alert()` is open nothing renders, no timer fires, no fetch settles and no route transition completes; on iOS Safari the user can tick a box that suppresses every later dialog on the origin, at which point `confirm()` returns false forever and the code silently stops asking. A Toast is transient and non-blocking, and an AlertDialog is a focus-trapped dialog inside the tree, where the rest of the app keeps running behind it.
It cannot be tested and it cannot be prerendered. `alert` and `confirm` are not defined on the server, so the same call that works in the browser throws during a prerender; in happy-dom they are stubs that return undefined, so a test of the flow behind a `confirm()` either hangs on a decision nobody makes or takes a branch the user never would. A Toast is a rendered node with an aria-live region — `findByRole('status')` — and a confirmation is a dialog with a button you can press and a promise you can await.
Both replacements now name themselves, which is why this rule fails rather than warns. `toast` is not exported; the queue is reached through `useToast()` under a `<ToastProvider>`. `confirm()` is reached through `useConfirm()` under a `<ConfirmProvider>` — and because it returns `Promise<boolean>`, the handler that asked the question keeps its shape and gains one `await`, rather than being split in two around a Modal's button. Each replacement is one import plus a provider mounted once at the root; the declarative shape, `<AlertDialog>` with `isOpen` and `onConfirm`, is still there for the cases that want it. Nothing left here is a refactor of the call site, so nothing left here is a judgement call.