-
Notifications
You must be signed in to change notification settings - Fork 184
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
[KOA-6248] Add optional label to nudger component #2967
Conversation
Visit https://backpack.github.io/storybook-prs/2967 to see this build running in a browser. |
Visit https://backpack.github.io/storybook-prs/2967 to see this build running in a browser. |
@@ -129,22 +127,25 @@ class App extends Component { | |||
|
|||
### BpkConfigurableNudger |
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.
Should we have 2 prop tables?
1 for one with label, one for without?
This way we can show the title is required etc.
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.
I'm afraid that'd make it look like there's 2 separate components (as that is the only time when we have more than 1 api table) and that's not the case here, but maybe can add a comment in the api table that title is required if you want to show a label?
Visit https://backpack.github.io/storybook-prs/2967 to see this build running in a browser. |
TL;DR
title
,subtitle
,icon
to add a label to the nudger component.BpkNudgerRow
component. This should not impact any projects in Skyscanner as it is a new component and we found no usages of it.Migrate to using the built-in nudger label
If you are using BpkNudger together with a label, consider passing the label content as props to inherit the accessible structure and styling of the component ✨
To migrate, remove the label component and instead pass the
title
andsubtitle
andicon
props accordingly.Checkout the README.md for more details on the props.
to
Remember to include the following changes:
README.md
(If you have created a new component)README.md