mirror of
https://github.com/wu736139669/hapi.git
synced 2026-08-05 06:24:37 +00:00
* fix(web): add close button to dialog so modals are dismissable on mobile The shared DialogContent had no close affordance — desktop users could press Escape or click the overlay, but on mobile (no Escape key, dialog spans calc(100vw-24px) leaving almost no tappable overlay) there was no way to dismiss it. Add a DialogPrimitive.Close X button in the top-right, fixing every dialog that uses this component at once. * fix(web): reserve header space for dialog close button Address review feedback: the absolutely-positioned close button overlaps the top-right of every dialog. Long/breaking titles (e.g. DiffView's break-all filename) could wrap underneath the 32px tap target. Add pr-12 to DialogHeader rather than padding DialogContent globally, so the title row clears the button while body content (code blocks, diffs) keeps full width. * fix(web): localize dialog close button aria-label Use the existing button.close locale string instead of a hardcoded "Close" so screen-reader users get the label in their language (zh-CN: 关闭).