docs(Checkbox): fix isChecked description (#202) - #229
Open
Kaustubh0505 wants to merge 1 commit into
Open
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR improves the Checkbox component documentation by clarifying the controlled isChecked prop and (per the description) adding a value prop explanation.
- Refines the
isCheckedprop comment to emphasize controlled usage. - (Intended) Adds documentation for the
valueprop.
Comments suppressed due to low confidence (2)
ui/elements/Form/Checkbox/types.ts:66
- [nitpick] The
@default falseannotation may be misleading for a controlled prop. Consider clarifying what happens whenisCheckedis omitted or remove the default ifisCheckedmust always be provided.
@default false
ui/elements/Form/Checkbox/types.ts:68
- The PR description mentions adding a
valueprop description, but that update isn't present here. Please add a clear comment for thevalueprop to explain its purpose and expected usage.
isChecked?: boolean;
Comment on lines
+61
to
+64
| * Controls the current checked state of the checkbox. | ||
| * | ||
| * This is a controlled prop. You must manage this value in the parent component, | ||
| * and update it based on user interaction via the `onChange` callback. |
Member
There was a problem hiding this comment.
need not be too verbose here
Suggested change
| * Controls the current checked state of the checkbox. | |
| * | |
| * This is a controlled prop. You must manage this value in the parent component, | |
| * and update it based on user interaction via the `onChange` callback. | |
| * Controls the current checked state of the checkbox. | |
| * |
Member
|
lets update PR title to mention only about isChecked prop description, as value prop description is unchanged :) |
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.
Fixed the isChecked prop description to clarify it controls the current checked state as a controlled prop.
Added description for the value prop explaining its role.
Improved documentation clarity for the Checkbox component props.
Fixes #202