-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(CodeSnippet): set min number of rows #8181
feat(CodeSnippet): set min number of rows #8181
Conversation
set default min to 100% apply the approprate minHeight collapsed or expanded as needed add props to component and story... - minCollapsedNumberOfRows and minExpandedNumberOfRows
Deploy preview for carbon-elements ready! Built with commit 4d4f45d |
Deploy preview for carbon-components-react ready! Built without sensitive environment variables with commit 4d4f45d https://deploy-preview-8181--carbon-components-react.netlify.app |
use minExpanded when clearing expandedCode minExpanded could be < maxCollapsed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍 ✅
…en-collapsed-and/or-expanded
DCO Assistant Lite bot: Thanks for your submission! We ask that you sign our Developer Certificate of Origin before we can accept your contribution. You can sign the DCO by adding a comment below using this text: I have read the DCO document and I hereby sign the DCO. Bill Guigue seems not to be a GitHub user. You need a GitHub account to be able to sign the DCO. If you have already a GitHub account, please add the email address used for this commit to your account. |
feat(CodeSnippet): set min number of rows
Closes #
#8056
set default min to 100%
apply the appropriate minHeight collapsed or expanded as needed
add props to component and story... minCollapsedNumberOfRows and minExpandedNumberOfRows
use minExpanded when clearing expandedCode... minExpandedNumberOfRows could be < maxCollapsedNumberOfRows
Testing / Reviewing
Testing via Storybook pages may be troublesome as you can't manipulate the contents of the CodeSnippet
to see the reactions when there are fewer rows of data than the min settings.
Also note: the code does not have any 'adjusting' checks if the client passes odd settings.
ie: it makes no since to set minExpandedNumberOfRows > maxExpandedNumberOfRows so there is no 'adjusting' code.
As these are client set - not settable/changeable by the user - I don't think 'adjusting' checks are needed.