-
Notifications
You must be signed in to change notification settings - Fork 376
feat(component): introduce the pf4 switch component #761
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
Conversation
|
I'm waiting for the switch component to be released in patternfly-core |
|
PatternFly-React preview: https://761-pr-patternfly-react-patternfly.surge.sh |
|
cc: @maryshak1996 |
0edb563 to
612fa78
Compare
|
@guillaumevincent on my end, it isn't showing the element (must not be available in core yet), so I'll check back to review visuals frequently to keep things moving :) |
|
This was a convo on slack but adding here to make sure everyone saw....
Once another proper commit is made to core, the switch should be available with that release. @dgutride will be adding stricter rules to help enforce proper commit messages and improve the releases. |
612fa78 to
b2e6c76
Compare
Pull Request Test Coverage Report for Build 3233
💛 - Coveralls |
b2e6c76 to
49f3e6b
Compare
8e0febe to
9970df0
Compare
|
I don't know why PatternFly-React preview is not updated, but this PR is ready for a review |
9970df0 to
acd291d
Compare
christiemolloy
left a comment
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.
@guillaumevincent This implementation is great! The CSS aligns with what we have in pf-next. Only thing, I see there is an "Uncontrolled Switch" in react but not in pf-next, was this intentional? I assume that these should be synonymous, but correct me if I'm wrong :)
packages/patternfly-4/react-core/src/components/Switch/Switch.js
Outdated
Show resolved
Hide resolved
packages/patternfly-4/react-core/src/components/Switch/Switch.js
Outdated
Show resolved
Hide resolved
packages/patternfly-4/react-core/src/components/Switch/Switch.js
Outdated
Show resolved
Hide resolved
packages/patternfly-4/react-core/src/components/Switch/Switch.js
Outdated
Show resolved
Hide resolved
acd291d to
bb29ceb
Compare
|
@christiemolloy I copy the Checkbox component here @jschuler I agree for the event props should be first |
|
@jschuler just for your information you can propose change directly in the PR |
|
@jgiardino I added a PR on pf-core |
|
That's fair @guillaumevincent . I will consult with Visuals and open a new issue if we decide that the Switch labeling should be updated in both places. I was going to mark this as "UX Approved" but looks like I don't have edit rights on this repo. @LHinson is that something you can enable? |
efa19e1 to
5778d7a
Compare
|
@mcarrano I fix the label in pf-next |
|
Yes, makes sense @guillaumevincent . |
|
@dlabaj @mcarrano @tlabaj patternfly/patternfly#877 merged. Is this one ready for merge? |
|
@rachael-phillips we had some discussion about the Switch component in the Accessibility meeting today and may be making some changes on the Core side. Opened a new issue here: patternfly/patternfly#914 We could merge this and create a new React issue or hold on this until core changes are made. |
|
We should let this in - @guillaumevincent - please make sure the build is passing and then it can be merged. |
|
Thanks so much, Matt and Dana!
…On Thu, Nov 8, 2018 at 1:59 PM mcarrano ***@***.***> wrote:
@rachael-phillips <https://github.com/rachael-phillips> we had some
discussion about the Switch component in the Accessibility meeting today
and may be making some changes on the Core side. Opened a new issue here:
patternfly/patternfly#914
<patternfly/patternfly#914> We could merge
this and create a new React issue or hold on this until core changes are
made.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#761 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AmaPXkbcaOUoPVeAMkilEtgFBY8CE7vDks5utH75gaJpZM4XcTyQ>
.
|
49b8d32 to
1d87c60
Compare
packages/patternfly-4/react-core/src/components/Switch/Switch.docs.js
Outdated
Show resolved
Hide resolved
1d87c60 to
7271d1e
Compare
tlabaj
left a comment
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
|
@jgiardino do you know the status of the switch component. Was @mceledonia going to make visual updates? In this react example the text is "on/off" should we keep this wording or switch to "label" like we have in core. |
|
If this is ready to merge then I'd vote to handle the visual updates (patternfly/patternfly#914) in a later PR since they haven't been implemented in core yet. Let's keep On/Off here. There's also an issue in core to handle toggling the label (patternfly/patternfly#915). I suggested we change the label to "On" and "Off" in that issue. So let's keep "On"/"Off" in this one, and core will match when that issue is done. |
|
@jgiardino Sounds good, looks like this is good to merge and there are some followup items in the 2 issues you referenced. |
fix #728