Repository navigation
fix(components): page:header reads the spec's variant 'danger' as destructive (objectui#12764) - #12798
Merged
objectstack-fleet[bot] merged 4 commits intoOct 16, 2026
Conversation
…tructive (objectui#12764) One predicate decides destructive for the header's primary pick, inline style, overflow band, separator and red row; it reads the spec's `danger` (and the host's `sys_delete` by name), not Shadcn's `destructive`. A danger action is never the filled primary, draws the destructive button inline, and is a red row below the separator in the overflow menu. Claude-Session: https://claude.ai/code/session_016x9qWsXaLgVtWMEpYeiNgo Co-authored-by: Claude <noreply@anthropic.com>
…in (objectui#12764) Claude-Session: https://claude.ai/code/session_016x9qWsXaLgVtWMEpYeiNgo Co-authored-by: Claude <noreply@anthropic.com>
…ader-danger-variant
… action list (objectui#12764) Claude-Session: https://claude.ai/code/session_016x9qWsXaLgVtWMEpYeiNgo Co-authored-by: Claude <noreply@anthropic.com>
Contributor
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
Contributor
Author
席位核对 · ACCEPT ·
|
objectstack-fleet
Bot
deleted the
claude/issue-12764-header-danger-variant
branch
October 16, 2026 21:40
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #12764
Clause-②: no
The record header reads the spec's
variant: 'danger'as destructive. Clause-② stays no: no prop, export or type member changes. The header reads its actions untyped, so no type union was widened, and an existing spec value now renders the way the spec defines it.What changed
page:header(packages/components/src/renderers/layout/containers.tsx) has ONE predicate,isDestructiveAction(variant === 'danger' || name === 'sys_delete'). It decides the overflow menu's destructive band, its separator, the red row, the inline style and the primary pick. Before this, the menu carried its own copy of the test.variant: 'primary'(objectui#12617's rule otherwise unchanged).destructivebutton (no new variant). Folded, it is a red row below the separator.variant: 'destructive'is no longer read. It is not a spec value (the enum is primary, secondary, danger, ghost, link: "danger = destructive"). The only header producer of it is the host'ssys_delete, which is matched by name, so the Delete row is unchanged.maxVisibleandcontent/docs/guide/slotted-pages.mdstate the rule.Tests
New
page-header-danger-12764.test.tsx(4 tests, the last a CONTROL forsys_deleteand non-destructive actions). Each new behaviour was proven red by ablation: predicate back todestructivegave 3 failed; primary candidates unfiltered gave 2 failed; inline variant back to default/outline gave 2 failed. The control passed in every leg, and every leg was restored to HEAD blob 5af5a743. The family run on head 275db44 (code unchanged at 92659d8) gave 26 files and 812 tests passed. Type-check, changeset presence and claims, line citations, test-path-roots, spec-symbols and eslint were all clean.Live reading
Published
@objectstack/*@18.0.0-next.2showcase, booted withe2e/live/ci/start-backend.sh. No showcase header action declaresdanger, soshowcase_submit_signoff(invoicerecord_header) was givenvariant: 'danger'in the throwaway copy only. On INV-1004, before the fix: Submit for Sign-off was the filled primary and Edit was outline. After: Edit is the primary and Submit for Sign-off is the red destructive button. Screenshots are on branchclaude/issue-12764-evidenceunderevidence/12764/.Acceptance notes
sys_deleteand plugin-detail DetailView'ssystemActions(the action:bar surface) still writevariant: 'destructive'. page:header now matches the Delete by name only. Not changed here: it is outside this card's surface.sys_deleteheader action withvariant: 'destructive'were not measured.Provenance: built by the cloud session
session_016x9qWsXaLgVtWMEpYeiNgo(claim6224242831) and opened by thedomain:uiseat 1 PM (session_011K9g23W67dy2zwnyzaoB6o) from that session's final message, because a cloud session cannot open a PR from its container. The seat replaced the dev's two footer lines with this paragraph and changed nothing else.Generated by Claude Code