feat(sidebar): per platform sidebar labels with auto cleanup#347
Draft
dobromirts wants to merge 2 commits into
Draft
feat(sidebar): per platform sidebar labels with auto cleanup#347dobromirts wants to merge 2 commits into
dobromirts wants to merge 2 commits into
Conversation
| run: node scripts/release-labels.mjs | ||
|
|
||
| - name: Open PR if toc files changed | ||
| uses: peter-evans/create-pull-request@v6 |
| const processed = processNodes(nodes, platform, currentVersion); | ||
| if (JSON.stringify(processed) === JSON.stringify(nodes)) return; | ||
| const out = JSON.stringify(processed, null, indent) + '\n'; | ||
| if (!DRY_RUN) writeFileSync(tocPath, out, 'utf8'); |
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.
Related to (#324
Summary
platformsfield to xplat toc.json for per-platform badge overridesThe same topic can show New on React, Updated on WebComponents, Preview on Blazor.
sincefield inside eachplatforms[P]entry to track when the label was introduced.Labels auto-expire after 2 minor package versions (e.g. added at
7.1.0→ cleared at7.3.0).scripts/release-labels.mjs, fetches live versions from npm (Angular, React, WC) andnuget.org (
IgniteUI.Blazor.Trial), clears expired labels, preserves original file indentation..github/workflows/clear-expired-sidebar-labels.yml- runs every Tuesday + manual dispatch,opens a PR when any labels are cleared. Silent when nothing has expired.
PLATFORM-LABELS.mdwith full usage guide including how to add a label step-by-step.TocItemtype insidebar.tsto documentplatformsandsince.Test plan
npm run dev:react/dev:webcomponents/dev:blazor- check sidebar labels forChat, Open-Source vs Premium, Cell Merging match the table in
PLATFORM-LABELS.mdnpm run release:labels:dry— confirm only the expired test items are flagged, nothing elseTODO (after approach is verified)
new/updated/previewentries in bothsrc/content/en/toc.jsonandsrc/content/jp/toc.jsonand add the correctsincevaluefor each platform, matching the package version at the time the label was originally introduced
sincevalues on the 3 test items (Chat, Open-Source vs Premium, Cell Merging)to the actual current release versions (
19.7.0/7.2.3/26.1.51)docs/angular/src/content/en/components/toc.json)should adopt the same
sinceexpiry pattern for single-platform labelsrelease-labels.mjs, confirm the GitHub Actions PRworkflow opens and the diff looks as expected before merging