An explicit confirmation with Minecraft ConfirmScreen artwork.
Preview
Usage
Control open and onOpenChange when confirmation changes application state. In the example, Yes increments the confirmation count and calls setOpen(false). AlertDialogAction is a plain Grasscn Button and does not close automatically.
Composition
Place Title and Description in Header, then Action and Cancel in Footer. Content creates its portal and full-screen overlay. AlertDialogCancel uses the primitive Close behavior; root scale defaults to 2.
Interaction and limits
Keep the warning specific and keep a cancel action available. The backdrop blur uses a local DOM snapshot and the original shader arithmetic; retained reference cases cover their recorded capture conditions. Arbitrary cross-origin imagery, video and vector underlays need separate evidence. This UI does not delete files itself.
See the upstream API for the underlying part and event contracts.
Installation
Component source
This is the component implementation. Its supporting styles, helpers and resources are also required. See complete manual installation.
"use client";
import { AlertDialog as Primitive } from "@base-ui/react/alert-dialog";
import * as React from "react";
import { Button } from "./button";
import { confirmationMenuBackground } from "./minecraft-confirmation-assets";
import { MinecraftConfirmationBlur } from "./minecraft-confirmation-blur";
import {
ConfirmationTextContext,
MinecraftConfirmationText,
confirmationButtonText,