CounterLabel, StateLabel: sync docs.json with deprecated props#8182
Open
siddharthkp wants to merge 1 commit into
Open
CounterLabel, StateLabel: sync docs.json with deprecated props#8182siddharthkp wants to merge 1 commit into
siddharthkp wants to merge 1 commit into
Conversation
Mark CounterLabel scheme and StateLabel variant as deprecated and document their replacements (variant, size)
|
siddharthkp
marked this pull request as ready for review
July 21, 2026 09:56
siddharthkp
enabled auto-merge
July 21, 2026 09:56
Contributor
There was a problem hiding this comment.
Pull request overview
Updates Primer React component metadata so generated documentation reflects source-level deprecations for CounterLabel and StateLabel.
Changes:
- Add
StateLabel.sizeto docs metadata and markStateLabel.variantas deprecated. - Add
CounterLabel.variantto docs metadata and markCounterLabel.schemeas deprecated.
Show a summary per file
| File | Description |
|---|---|
| packages/react/src/StateLabel/StateLabel.docs.json | Adds size prop metadata and marks variant as deprecated in docs. |
| packages/react/src/CounterLabel/CounterLabel.docs.json | Adds variant prop metadata and marks scheme as deprecated in docs. |
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 3
- Review effort level: Low
Comment on lines
+19
to
+24
| { | ||
| "name": "variant", | ||
| "type": "'primary' | 'secondary'", | ||
| "defaultValue": "", | ||
| "description": "Pass in 'primary' for a darker background and inverse text, or 'secondary' for a lighter background and primary text. Omitting the variant prop renders the default counter scheme" | ||
| }, |
Comment on lines
26
to
+30
| "name": "scheme", | ||
| "type": "'primary' | 'secondary'", | ||
| "defaultValue": "", | ||
| "description": "Pass in 'primary' for a darker background and inverse text, or 'secondary' for a lighter background and primary text. Omitting the scheme prop renders the default counter scheme" | ||
| "description": "Use `variant` instead.", | ||
| "deprecated": true |
| "type": "'small' | 'normal'", | ||
| "defaultValue": "'normal'" | ||
| "defaultValue": "'normal'", | ||
| "description": "Use `size` instead.", |
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.
docs.json for
CounterLabelandStateLabeldid not reflect deprecations that already exist in the source.Marked
CounterLabel.schemeandStateLabel.variantas deprecated for the docs.Rollout strategy