Repository navigation
fix(explainer): localize automatic workflow branch labels - #1095
Merged
Merged
Conversation
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
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 |
Preserve author history and Apache-2.0, legacy MIT and third-party notices. Rebuild the distributable from combined source with the canonical Node 22 toolchain.
1 task
1 task done
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.
Problem and value
Refs #1082. On dev
82c7e0f, an English workflow shorthand branching from Build to Ship/Roll back generates分支 1in its lane name, node context, SVG title and accessible name. Automatic branch lanes now useBranch Nfor non-zh locales and retain分支 Nfor zh-prefixed/default pages, matching the Explainer reader fallback. Authored lanes and wrapped-band titles retain their text.Metadata may appear after the shorthand. The parser keeps its original compilation timing for quality, title, source anchors and automatic block IDs, then recompiles only workflow shorthand requiring non-Chinese labels with the final locale. Its spec locations retain the original directive span. Explicit native specs and referenced source files are unaffected; no translation framework or layout algorithm is added.
Attribution and AI assistance
Adapted the narrow branch-label correction and CLI/compiler regression ideas from @BlueboxC's 897cbbf0, which also contains unrelated fork fixes that are not imported here. Added coverage for late metadata, source locations, automatic IDs and original quality.
Impact and verification
The change is limited to generated shorthand lane text and its derived reader/accessibility context. Tests preserve authored labels, wrapped titles and all other native spec fields. The matched three-node en/zh-CN sample at 390px keeps the same SVG viewBox, geometry attributes and node/text bounds; this is a bounded comparison, not a universal claim that translated text can never affect measurements. Existing English toolbar overflow remains the separate #1076 behavior.
Base
82c7e0f; candidate323b3196:Branch 1and Chinese分支 1context, accessible name and SVG title on the same source input. Screenshots were inspected by the agent; personal human review remains separate.npm run test:generated: pass. Release/package gates: 36 pass, 2 platform skips.explainer/parse.mjsandexplainer/diagrams.mjsdiffer. Checked-in shorthand showcase sources are zh-CN and keep their output; no unrelated gallery or README proof refresh is included.Required final-head hosted CI and maintainer acceptance remain pending. No release, deployment or live installation is claimed.
Apache baseline integration (2026-10-25)
Normally merged exact dev
3f95f0349c8276db71509ca239461b6fe9d00f9finto the original author history; new head1e37c5e1c55a51736d7cbbf4761580b96121aba4. Source merged without conflict; only the binary ZIP conflicted and was rebuilt from combined source. Apache LICENSE, legacy LICENSE-MIT, NOTICE, third-party notices and the offline notice module match the exact base; the actual extracted package retains those bytes.New local focused check:
node --test test/explainer-parser.test.mjs test/explainer-diagrams.test.mjs test/explainer-cli.test.mjs.Full smoke through the actual extracted ZIP passed, including licensing and third-party notice contracts. Two official Node 22.23.3 / zlib
1.3.1-e00f703canonical builds are byte-identical, SHA-256100d09a173137b277f899ca2c6cc0d139a2f635e738dacd3307cf253d12f88ac.git diff --checkpasses; checkout committed clean. Earlier behavior evidence is reused only for unchanged responsibilities; Apache notices are an intentional added output detail. Prior hosted CI belongs to the stated prior heads. Final-head hosted CI remains pending; no green result, release or live installation is claimed.