fix(Form,Range): omit method on nested forms, emit a number for one thumb - #509
Merged
Conversation
…humb Ports two upstream fixes, contiguous in `v4`: `a494a97d` (nuxt/ui #6888) and `3d2de0ce` (nuxt/ui #6890). **`Form` — `method` on a nested form.** Our root element already renders as a `div` when nested (`:is="parentBus ? 'div' : 'form'"`), and `:name` was already conditional on the same flag — but `method="post"` was left unconditional, so a nested form emitted `<div method="post">`. Upstream's fix is the line we were missing: `:method="parentBus ? undefined : 'post'"`. **`Range` — a single thumb emitted an array, twice.** Upstream's `Slider` is this fork's `Range` (§1). `useForwardProps` was handed `emits`, so `SliderRoot`'s own `update:modelValue` was re-emitted alongside the one the component derives — `[[1], [1]]` in our own test, and an array rather than a number for a single thumb. Dropping the `emits` argument leaves the component's `defineModel` handling as the only emitter. Ported upstream's two new emits cases and the corrected expectation, adapted to `Range`. Mutation-checked rather than assumed: restoring the `emits` argument with the tests kept turns **all six** red across both projects. Verified with `CI=true`: `lint` · `typecheck` · `test` (7472 passed, 6 skipped, 318 files) · `docs:generate` (1264 routes). Ledger: cursor → `3d2de0ce`, two entries.
Advances the cursor past `ae243116` (nuxt/ui #6883) and adds the journals for this run's three commits. `ae243116` replaces upstream's hand-rolled agent-discovery surface with a `nuxt-agent-discovery` module, deleting its own `.well-known`, `raw/*`, `sitemap.*`, markdown-negotiation and error-handling implementation in the process — 33 files, +474/−1914. Skipped: it refactors infrastructure this fork deliberately does not have. `9ef3ee39`, the commit that built that surface, is recorded one entry earlier as a skip on maintainer decision, so a refactor of code we never took has nothing to apply to. Taking it would also delete working code written on purpose — the two `.well-known` routes it removes are the ones this fork **added** in #492, and our `raw/*` and `sitemap.*` routes are in use: `raw/**.md` is what the skills reference links to, and both sitemaps are prerendered into the static build. Adopting the module stays a live option, but that is a decision about our own architecture rather than a port. Ledger: cursor → `ae243116` (upstream HEAD), parity snapshot refreshed.
This was referenced Aug 29, 2026
IgorShevchik
pushed a commit
that referenced
this pull request
Aug 29, 2026
`a494a97d`, `3d2de0ce` and `ae243116` were written while their port was still open, so all three carried `pending-merge` in both `pr` and `b24ui_sha`. #509 squash-merged as `7203420b`; this points them at it. Bookkeeping only — no ledger entry is added, the cursor does not move, and no decision changes.
IgorShevchik
added a commit
that referenced
this pull request
Aug 29, 2026
…511) `a494a97d`, `3d2de0ce` and `ae243116` were written while their port was still open, so all three carried `pending-merge` in both `pr` and `b24ui_sha`. #509 squash-merged as `7203420b`; this points them at it. Bookkeeping only — no ledger entry is added, the cursor does not move, and no decision changes.
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.
Linked issue
Sync with
nuxt/ui@v4— three contiguous commits (§6 4b):a494a97d(nuxt/ui#6888) ·3d2de0ce(nuxt/ui#6890) ·ae243116(nuxt/ui#6883, skipped). After this the cursor is at upstream HEAD.Type of change
Description
a494a97d—methodon a nested formOur root element already renders as a
divwhen nested (:is="parentBus ? 'div' : 'form'"), because aforminside aformis invalid HTML, and:namewas already conditional on the same flag. Butmethod="post"was left unconditional, so a nested form emitted<div method="post">— a form attribute on an element that is not a form.Upstream's fix is exactly the line we were missing:
Applies verbatim — same pre-image, and nothing on the line involves
ui/b24ui.3d2de0ce— a single thumb emitted an array, twiceUpstream's
Slideris this fork'sRange(§1); third commit in that family after #431 and #466.Passing
emitstouseForwardPropsforwardedSliderRoot's ownupdate:modelValuestraight through, in addition to the one the component derives from itsdefineModel. Two consequences: the event fired twice, and the forwarded copy carried Reka's raw payload — an array — so a single-thumb Range emitted[71]where the caller passed and expects71.Our
Range.vue:74carried the identicalemitsargument, andRange.spec.tscarried the identical pre-image expectation —{ 'update:modelValue': [[1], [1]] }, the doubled emit written down as though it were correct.ae243116— skippedReplaces upstream's hand-rolled agent-discovery surface with a
nuxt-agent-discoverymodule, deleting its own.well-known,raw/*,sitemap.*, markdown-negotiation and error-handling implementation — 33 files, +474/−1914.It refactors infrastructure this fork deliberately does not have:
9ef3ee39, the commit that built that surface, is recorded one entry earlier as a skip on maintainer decision, so a refactor of code we never took has nothing to apply to. Taking it would also delete working code written on purpose — the two.well-knownroutes it removes are the ones this fork added in #492, and ourraw/*andsitemap.*routes are in use (raw/**.mdis what the skills reference links to; both sitemaps are prerendered into the static build).Adopting the module stays a live option, but that is a decision about our own architecture rather than a port.
Verification
Mutation-checked, not assumed. Upstream's two new emits cases plus the corrected expectation were ported and adapted to
Range; restoring theemitsargument with the tests kept turns all six red — the corrected case and both new ones, across thenuxtandvueprojects.The Form fix moves no snapshot:
Form.spec.tsdoes not render a nested form, so the attribute change is not witnessed by the suite. Stated rather than glossed over — it is correct by inspection of the template, not by a test that would have caught it.Gate with
CI=true:lint·typecheck·test(7472 passed, 6 skipped, 318 files) ·docs:generate(1264 routes).One thing found along the way, not fixed here:
pnpm buildcurrently fails onmainwith 12TS2883errors inruntime/plugins/{colors,platform,ui-version}.ts— verified by stashing this branch's changes and building cleanmain, which fails identically. CI does not runbuild(it runsdev:prepare,lint,typecheck,test:coverage,test:module), which is why it went unnoticed. Unrelated to this port and left alone rather than folded into a sync PR.Ledger: cursor →
ae243116, three entries with their.sync/log/journals, parity snapshot refreshed (zero package differences).Checklist
Generated by Claude Code