Install a delegated "dismiss from an action" click handler: any element inside
host carrying [attr] runs onDismiss on click, scoped to the nearest host
of host's own tag (so a control inside a nested same-tag element doesn't also
dismiss the outer one). A read-only light-DOM walk — no host / tree mutation —
that catches any activated control (native <button>, <a>, <a-button>,
<a-menu-item>) with keyboard activation for free. Shared by a-toast
(data-toast-dismiss) and a-banner (data-banner-dismiss), mirroring
a-dialog's data-dialog-close family; keep the one copy here so a future fix
(e.g. skipping [disabled] triggers) lands for every element at once.
Install a delegated "dismiss from an action" click handler: any element inside
hostcarrying[attr]runsonDismisson click, scoped to the nearest host ofhost's own tag (so a control inside a nested same-tag element doesn't also dismiss the outer one). A read-only light-DOM walk — no host / tree mutation — that catches any activated control (native<button>,<a>,<a-button>,<a-menu-item>) with keyboard activation for free. Shared bya-toast(data-toast-dismiss) anda-banner(data-banner-dismiss), mirroringa-dialog'sdata-dialog-closefamily; keep the one copy here so a future fix (e.g. skipping[disabled]triggers) lands for every element at once.