Bulk Action Bar
Bulk Action Bar is a temporary command region for a collection with an active selection. It keeps the selected scope, eligibility, batch commands, and the way out of selection mode in one predictable place.
Production environments
Three environments are selected; only two have archive permission.
Usage
Keep the bar adjacent to the collection that owns the selection. Give the root a collection-specific accessible name, keep the exact selected count visible, and label each command with the number of eligible items when eligibility is partial. The host owns permission checks, confirmation, requests, optimistic updates, rollback, and retry.
The controller can be loaded with the complete runtime or as a split entry:
The integrated preview above is the canonical HTML, React, and Vue example. Its source disclosure keeps the install command, setup entry, and example file in one workspace; switch the tabs in the preview toolbar to copy the active file.
Contract
setPending(action, true, { message, allowClear }) disables the pending command and every contradictory command while retaining the original disabled states. allowClear defaults to true; set it to false when leaving selection mode would conflict with a host request. Clearing during pending does not cancel the request and preserves the pending region until the host completes it.
States and recovery
The live preview toolbar includes the state acceptance matrix. It verifies that empty hides the region, selected preserves the scope, loading disables contradictory commands, and disabled applies native disabled semantics to every command.
When five items are selected but only three are eligible, label the command “Retry 3”, not “Retry 5” followed by a silent server-side skip. Destructive commands still require Alert Dialog confirmation with the affected count.
Accessibility and ownership
The root region must be named for the collection it affects and must not move focus when it appears. Selection count, eligible count, progress, and outcome are expressed as text. The pending command keeps its label and exposes aria-busy="true" on the root; clear remains available only when allowClear permits it. After a rejected request, preserve the selection and focus context so the recovery command is still reachable. After a successful clear or completion, restore focus to the stable collection target instead of leaving focus on a hidden action.
React and Vue use the same controller events and methods. They do not create a framework-specific selection store or perform network work inside the adapter.
