feat(web): builtinTagTransformMap add input for x-input-ng#1932
feat(web): builtinTagTransformMap add input for x-input-ng#1932Sherry-hue merged 1 commit intolynx-family:mainfrom
Conversation
🦋 Changeset detectedLatest commit: 6fb1fc1 The changes in this PR will be included in the next version bump. This PR includes changesets to release 12 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
📝 WalkthroughWalkthroughAdds support for a new 'x-input-ng' tag alias that maps to 'x-input' across the web platform layers, with corresponding version bumps for three packages and a test case validating the bindinput behavior of the new tag variant. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related PRs
Suggested reviewers
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
.changeset/light-actors-wonder.md(1 hunks)packages/web-platform/web-core-server/src/createLynxView.ts(1 hunks)packages/web-platform/web-core/src/apis/LynxView.ts(1 hunks)packages/web-platform/web-tests/tests/react.spec.ts(1 hunks)packages/web-platform/web-tests/tests/react/basic-element-x-input-ng-bindinput/index.jsx(1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
.changeset/*.md
📄 CodeRabbit inference engine (AGENTS.md)
For contributions, generate and commit a Changeset describing your changes
Files:
.changeset/light-actors-wonder.md
🧠 Learnings (6)
📓 Common learnings
Learnt from: Sherry-hue
Repo: lynx-family/lynx-stack PR: 1820
File: packages/web-platform/web-tests/tests/react.spec.ts:834-856
Timestamp: 2025-10-11T06:16:12.517Z
Learning: In packages/web-platform/web-tests/tests/react.spec.ts, the tests `basic-bindmouse` and `basic-mts-bindtouchstart` are NOT duplicates despite having similar test structures. They test different event types: `basic-bindmouse` validates mouse events (mousedown, mouseup, mousemove) with mouse-specific properties (button, buttons, x, y, pageX, pageY, clientX, clientY), while `basic-mts-bindtouchstart` validates touch events (touchstart) with touch arrays (touches, targetTouches, changedTouches). The similar test structure is coincidental and follows testing conventions.
📚 Learning: 2025-09-12T09:43:04.847Z
Learnt from: gaoachao
Repo: lynx-family/lynx-stack PR: 1736
File: .changeset/spotty-experts-smoke.md:1-3
Timestamp: 2025-09-12T09:43:04.847Z
Learning: In the lynx-family/lynx-stack repository, private packages (marked with "private": true in package.json) like lynx-js/react-transform don't require meaningful changeset entries even when their public APIs change, since they are not published externally and only affect internal development.
Applied to files:
packages/web-platform/web-core-server/src/createLynxView.tspackages/web-platform/web-core/src/apis/LynxView.ts.changeset/light-actors-wonder.md
📚 Learning: 2025-07-16T06:26:22.230Z
Learnt from: PupilTong
Repo: lynx-family/lynx-stack PR: 1029
File: packages/web-platform/web-core-server/src/createLynxView.ts:0-0
Timestamp: 2025-07-16T06:26:22.230Z
Learning: In the lynx-stack SSR implementation, each createLynxView instance is used to render once and then discarded. There's no reuse of the same instance for multiple renders, so event arrays and other state don't need to be cleared between renders.
Applied to files:
packages/web-platform/web-core/src/apis/LynxView.ts
📚 Learning: 2025-10-11T06:16:12.517Z
Learnt from: Sherry-hue
Repo: lynx-family/lynx-stack PR: 1820
File: packages/web-platform/web-tests/tests/react.spec.ts:834-856
Timestamp: 2025-10-11T06:16:12.517Z
Learning: In packages/web-platform/web-tests/tests/react.spec.ts, the tests `basic-bindmouse` and `basic-mts-bindtouchstart` are NOT duplicates despite having similar test structures. They test different event types: `basic-bindmouse` validates mouse events (mousedown, mouseup, mousemove) with mouse-specific properties (button, buttons, x, y, pageX, pageY, clientX, clientY), while `basic-mts-bindtouchstart` validates touch events (touchstart) with touch arrays (touches, targetTouches, changedTouches). The similar test structure is coincidental and follows testing conventions.
Applied to files:
packages/web-platform/web-tests/tests/react/basic-element-x-input-ng-bindinput/index.jsxpackages/web-platform/web-tests/tests/react.spec.ts
📚 Learning: 2025-09-12T09:43:04.847Z
Learnt from: gaoachao
Repo: lynx-family/lynx-stack PR: 1736
File: .changeset/spotty-experts-smoke.md:1-3
Timestamp: 2025-09-12T09:43:04.847Z
Learning: In the lynx-family/lynx-stack repository, empty changeset files (containing only `---\n\n---`) are used for internal changes that modify src/** files but don't require meaningful release notes, such as private package changes or testing-only modifications. This satisfies CI requirements without generating user-facing release notes.
Applied to files:
.changeset/light-actors-wonder.md
📚 Learning: 2025-08-19T11:25:36.127Z
Learnt from: colinaaa
Repo: lynx-family/lynx-stack PR: 1558
File: .changeset/solid-squids-fall.md:2-2
Timestamp: 2025-08-19T11:25:36.127Z
Learning: In the lynx-family/lynx-stack repository, changesets should use the exact package name from package.json#name, not generic or unscoped names. Each package has its own specific scoped name (e.g., "lynx-js/react-transform" for packages/react/transform).
Applied to files:
.changeset/light-actors-wonder.md
🧬 Code graph analysis (1)
packages/web-platform/web-tests/tests/react.spec.ts (1)
packages/web-platform/web-tests/tests/react/basic-element-x-input-ng-bindinput/index.jsx (1)
result(8-8)
🔇 Additional comments (4)
packages/web-platform/web-core-server/src/createLynxView.ts (1)
85-85: LGTM! Tag alias mapping added correctly.The new 'x-input-ng' to 'x-input' mapping is properly placed and follows the existing pattern in the builtinTagTransformMap.
packages/web-platform/web-core/src/apis/LynxView.ts (1)
424-424: LGTM! Client-side tag mapping added correctly.The mapping mirrors the server-side implementation, ensuring consistent tag transformation across rendering contexts.
.changeset/light-actors-wonder.md (1)
1-7: LGTM! Changeset properly documents the feature addition.The changeset correctly specifies patch version bumps for the affected packages and provides a clear description of the new tag alias mapping.
packages/web-platform/web-tests/tests/react.spec.ts (1)
3027-3039: LGTM! Test case properly validates the new tag alias.The test follows the established pattern for input bindinput tests and appropriately validates that x-input-ng functions identically to x-input through the tag mapping. Based on learnings.
packages/web-platform/web-tests/tests/react/basic-element-x-input-ng-bindinput/index.jsx
Show resolved
Hide resolved
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
CodSpeed Performance ReportMerging #1932 will not alter performanceComparing Summary
Footnotes
|
Web Explorer#6201 Bundle Size — 366.77KiB (~+0.01%).6fb1fc1(current) vs a1e4e19 main#6193(baseline) Bundle metrics
Bundle size by type
Bundle analysis report Branch Sherry-hue:feat/web-builtin-xinp... Project dashboard Generated by RelativeCI Documentation Report issue |
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## @lynx-js/rspeedy@0.12.0 ### Minor Changes - Bump Rsbuild v1.6.7 with Rspack v1.6.4. ([#1905](#1905)) ### Patch Changes - Updated dependencies \[]: - @lynx-js/web-rsbuild-server-middleware@0.18.4 ## @lynx-js/devtool-mcp-server@0.4.1 ### Patch Changes - Export `registerTool` and `defineTool`. ([#1931](#1931)) - Fix failed to connect to client. ([#1931](#1931)) ## @lynx-js/react@0.114.5 ### Patch Changes - Reduce `__SetInlineStyles` element API call when attrs in spread not changed ([#1919](#1919)) ## @lynx-js/web-constants@0.18.4 ### Patch Changes - Updated dependencies \[]: - @lynx-js/web-worker-rpc@0.18.4 ## @lynx-js/web-core@0.18.4 ### Patch Changes - feat: builtinTagTransformMap add `'x-input-ng': 'x-input'` ([#1932](#1932)) - Updated dependencies \[]: - @lynx-js/web-constants@0.18.4 - @lynx-js/web-mainthread-apis@0.18.4 - @lynx-js/web-worker-rpc@0.18.4 - @lynx-js/web-worker-runtime@0.18.4 ## @lynx-js/web-core-server@0.18.4 ### Patch Changes - feat: builtinTagTransformMap add `'x-input-ng': 'x-input'` ([#1932](#1932)) - chore: minor bundle output change ([#1946](#1946)) the timing of loading wasm chunk has been changed ## @lynx-js/web-elements@0.8.11 ### Patch Changes - fix: when estimated-main-axis-size-px is not set, should use the height of list ([#1930](#1930)) - Updated dependencies \[]: - @lynx-js/web-elements-template@0.8.11 ## @lynx-js/web-explorer@0.0.13 ### Patch Changes - feat: builtinTagTransformMap add `'x-input-ng': 'x-input'` ([#1932](#1932)) ## @lynx-js/web-mainthread-apis@0.18.4 ### Patch Changes - Updated dependencies \[]: - @lynx-js/web-constants@0.18.4 ## @lynx-js/web-worker-runtime@0.18.4 ### Patch Changes - Updated dependencies \[]: - @lynx-js/web-constants@0.18.4 - @lynx-js/web-mainthread-apis@0.18.4 - @lynx-js/web-worker-rpc@0.18.4 ## create-rspeedy@0.12.0 ## upgrade-rspeedy@0.12.0 ## @lynx-js/web-elements-template@0.8.11 ## @lynx-js/web-rsbuild-server-middleware@0.18.4 ## @lynx-js/web-worker-rpc@0.18.4 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Summary by CodeRabbit
New Features
x-input-ngtag as an alternative tox-inputacross the platform.Tests
x-input-ngtag variant, including input binding and event validation scenarios.Checklist