Uh oh!
There was an error while loading. Please reload this page.
fix(components): forward the declared onSuccess block on all four action surfaces - #6304
Merged
os-support-ai merged 2 commits intoAug 25, 2026
Merged
Conversation
…ction surfaces
`ActionSchema.onSuccess` (spec's closed strict `{ navigate, openIn }`) became
authorable with the @objectstack/spec 17.1.0 pin bump, and `ActionRunner` reads
it off the FORWARDED def at execute time (`handlePostExecution` ->
`readOnSuccessNavigation` -> `navigateOnSuccess`, hopping through the app's own
`navigationHandler`). The four declared action renderers never carried the key
in their forward whitelists, so the action succeeded and the declared
post-success navigation silently did not happen.
- forward `onSuccess` in `action-button`, `action-icon`, `action-group` and
`action-menu`, following the house whitelist pattern (explicit key, comment
stating why it is forwarded, cast as the sibling spec-owned keys are)
- delete the four matching `KNOWN_GAPS` entries in
`scripts/check-action-forward-parity.mjs` (ratcheted: a stale entry excusing
a forwarded key fails the gate)
- pin the hop end to end, one row per surface, in
`action-onSuccess-forward.test.tsx`
- append `onSuccess` to the two pinned key orders in
`action-forward-precedence.test.tsx`
`element:button` is untouched: `onSuccess` is not on spec's
`InlineActionSchema` pick list, so that surface never owed it.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011SfZeFWrhGLHmfq61xbz4qContributor
✅ 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
|
This was referenced Aug 25, 2026
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
|
os-support-ai
marked this pull request as ready for review
August 25, 2026 12:36
Uh oh!
There was an error while loading. Please reload this page.
os-support-ai
deleted the
claude/issue-5493-forward-onsuccess-action-surfaces
branch
August 25, 2026 12:55
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 freeto 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#5493
ActionSchema.onSuccess— spec's closed strict{ navigate, openIn }block — is authorable as of@objectstack/spec17.1.0 and is read off the forwarded def at execute time byActionRunner.handlePostExecution→readOnSuccessNavigation→navigateOnSuccess, which hops through the app's ownnavigationHandler. The four declared action renderers never carried the key in their forward whitelists, so the action succeeded, the toast said so, and the declared post-success navigation silently did not happen.What changed
packages/components/src/renderers/action/action-button.tsxonSuccess, house whitelist pattern (explicit key + comment stating why), cast as the sibling spec-owned keys are…/action-icon.tsx,…/action-group.tsx,…/action-menu.tsxscripts/check-action-forward-parity.mjsKNOWN_GAPS:onSuccessentries — only those entries, nothing else in that shared file…/__tests__/action-onSuccess-forward.test.tsx…/__tests__/action-forward-precedence.test.tsx'onSuccess'appended to the two pinned key orders.changeset/action-onsuccess-forward-5493.md@object-ui/components: patchelement:buttonis untouched and stays correct:onSuccessis not on spec'sInlineActionSchemapick list, so that surface never owed it. The gate derives that split rather than registering it, so no exemption was added.Verification
Everything below was run on
42fcf136a, the head of this branch.The assertion distinguishes the two worlds. Each row drives the real renderer through the real
ActionRunnerand asserts (a) theapihandler is handed a def whoseonSuccessis the authored block, and (b)onNavigatereceives/app/crm/contacts/rec_42— the${result.id}-interpolated url, a value only the declared string plus the handler's own payload can produce — withopenInexercised on both branches ('self'on three surfaces,'newTab'onaction:menu). Every row asserts the action executed first, so a zero-navigation reading cannot be a harness that did nothing.Red before, green after. Before the fix:
Tests 4 failed (4), each failing at theonSuccessdeep-equal withReceived: undefined— i.e. past the positive control. After:Test Files 13 passed,Tests 303 passedover the wholerenderers/action/__tests__directory plus the gate's own suite.Per-point ablation, four legs. Each leg deletes one surface's forward line, proves the mutation on disk in both directions (the removed text grep goes 1 → 0 and the file's hash leaves its HEAD blob), runs the pin, then restores with
git checkout HEAD -- <absolute path>undertrap … EXIT INT TERMand proves the restore the same way (hash back on the HEAD blob,git diff HEAD --statempty):action-button1 failed | 3 passed— the failing row isaction:buttonaction-icon1 failed | 3 passed—action:iconaction-group1 failed | 3 passed—action:groupaction-menu1 failed | 3 passed—action:menuNo rebuild is on the path and none is owed: the pin imports the renderers by relative path and
@object-ui/core/@object-ui/reactresolve through vitest'sresolve.aliastopackages/*/src, so nodist/sits between the mutation and the measurement. The legs going red is itself the evidence — a stale-distablation stays green.The gate ratchets both ways (measured, both restored):
exit 1, "action:button… does not forward 1 key the runtime reads:onSuccess".KNOWN_GAPSentry re-added →exit 1, "KNOWN_GAPSentryaction:button:onSuccessis no longer a gap — delete it".Gates run locally
Derived from each CI job's own step list, scoped to this diff:
check:action-forward-parity✅ action forward parity: 5 surfaces checked … 19 justified omissions, 7 known gaps(was 11)@object-ui/componentstype-checktsc --noEmit && tsc -p tsconfig.test.json→ exit 0;--listFilesshows both edited test files and all four renderers in the checked program (1858 files)Test Files 39 passed (39),Tests 823 passed (823)check:control-bytes✅ OK (scanned 5196 tracked text file(s))check:changeset-presence/no-major/fixed✅/✅ No changeset declares a major bump/✅check:spec-symbols,check:vi-mock-specifiers,check:entry-guard,lint:coverage,type-check:coverage,type-check:scriptsno-explicit-anywarning as theresultDialogline beside themDeclared narrowing: the vitest run is the 39 test files that can observe this change — every test in the repo naming
action:button|icon|group|menu|baror importingrenderers/action— not the fullpackages/componentssuite. The full-package run was started and killed at ~10 minutes under CPU contention while holding the shared verify lock; it is reported as unrun, not as green. The narrowing is sound because a test can only see this diff by rendering one of the four renderers, and the enumeration above is the measured population; CI runs the full sharded suite regardless.Generated by Claude Code