-
Notifications
You must be signed in to change notification settings - Fork 56
Updates to support new ToggleSwitch visual design #477
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
🦋 Changeset detectedLatest commit: 7d5f4ed The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Variables changed--- base/dist/scss/colors/_dark.scss 2023-02-10 19:19:57.307601458 +0000
+++ dist/scss/colors/_dark.scss 2023-02-10 19:18:45.194761215 +0000
@@ -261,4 +261,9 @@
--color-action-list-item-danger-hover-text: #ff7b72;
- --color-switch-track-bg: #010409;
- --color-switch-track-border: #6e7681;
+ --color-switch-track-bg: rgba(110,118,129,0.1);
+ --color-switch-track-hover-bg: hsla(215,8%,72%,0.1);
+ --color-switch-track-active-bg: rgba(110,118,129,0.4);
+ --color-switch-track-disabled-bg: #21262d;
+ --color-switch-track-fg: #8b949e;
+ --color-switch-track-disabled-fg: #010409;
+ --color-switch-track-border: rgba(0,0,0,0);
--color-switch-track-checked-bg: rgba(31,111,235,0.35);
@@ -266,6 +271,13 @@
--color-switch-track-checked-active-bg: rgba(31,111,235,0.65);
- --color-switch-track-checked-border: #58a6ff;
- --color-switch-knob-checked-bg: #1f6feb;
- --color-switch-knob-checked-disabled-bg: #484f58;
- --color-segmented-control-bg: #161b22;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #010409;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #0d1117;
+ --color-switch-knob-border: #606771;
+ --color-switch-knob-disabled-bg: #161b22;
+ --color-switch-knob-checked-bg: #0d1117;
+ --color-switch-knob-checked-disabled-bg: #161b22;
+ --color-switch-knob-checked-border: rgba(31,111,235,0.35);
+ --color-segmented-control-bg: rgba(110,118,129,0.1);
+ --color-segmented-control-button-bg: #0d1117;
--color-segmented-control-button-hover-bg: #30363d;
--- base/dist/scss/colors/_dark_colorblind.scss 2023-02-10 19:19:57.323601647 +0000
+++ dist/scss/colors/_dark_colorblind.scss 2023-02-10 19:18:45.214761450 +0000
@@ -261,4 +261,9 @@
--color-action-list-item-danger-hover-text: #ec8e2c;
- --color-switch-track-bg: #010409;
- --color-switch-track-border: #6e7681;
+ --color-switch-track-bg: rgba(110,118,129,0.1);
+ --color-switch-track-hover-bg: hsla(215,8%,72%,0.1);
+ --color-switch-track-active-bg: rgba(110,118,129,0.4);
+ --color-switch-track-disabled-bg: #21262d;
+ --color-switch-track-fg: #8b949e;
+ --color-switch-track-disabled-fg: #010409;
+ --color-switch-track-border: rgba(0,0,0,0);
--color-switch-track-checked-bg: rgba(31,111,235,0.35);
@@ -266,6 +271,13 @@
--color-switch-track-checked-active-bg: rgba(31,111,235,0.65);
- --color-switch-track-checked-border: #58a6ff;
- --color-switch-knob-checked-bg: #1f6feb;
- --color-switch-knob-checked-disabled-bg: #484f58;
- --color-segmented-control-bg: #161b22;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #010409;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #0d1117;
+ --color-switch-knob-border: #606771;
+ --color-switch-knob-disabled-bg: #161b22;
+ --color-switch-knob-checked-bg: #0d1117;
+ --color-switch-knob-checked-disabled-bg: #161b22;
+ --color-switch-knob-checked-border: rgba(31,111,235,0.35);
+ --color-segmented-control-bg: rgba(110,118,129,0.1);
+ --color-segmented-control-button-bg: #0d1117;
--color-segmented-control-button-hover-bg: #30363d;
--- base/dist/scss/colors/_dark_dimmed.scss 2023-02-10 19:19:57.315601552 +0000
+++ dist/scss/colors/_dark_dimmed.scss 2023-02-10 19:18:45.198761262 +0000
@@ -261,4 +261,9 @@
--color-action-list-item-danger-hover-text: #f47067;
- --color-switch-track-bg: #1c2128;
- --color-switch-track-border: #636e7b;
+ --color-switch-track-bg: rgba(99,110,123,0.1);
+ --color-switch-track-hover-bg: hsla(213,11%,69%,0.1);
+ --color-switch-track-active-bg: rgba(99,110,123,0.4);
+ --color-switch-track-disabled-bg: #373e47;
+ --color-switch-track-fg: #768390;
+ --color-switch-track-disabled-fg: #1c2128;
+ --color-switch-track-border: rgba(0,0,0,0);
--color-switch-track-checked-bg: rgba(49,109,202,0.35);
@@ -266,6 +271,13 @@
--color-switch-track-checked-active-bg: rgba(49,109,202,0.65);
- --color-switch-track-checked-border: #539bf5;
- --color-switch-knob-checked-bg: #316dca;
- --color-switch-knob-checked-disabled-bg: #545d68;
- --color-segmented-control-bg: #2d333b;
+ --color-switch-track-checked-fg: #cdd9e5;
+ --color-switch-track-checked-disabled-fg: #1c2128;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #22272e;
+ --color-switch-knob-border: #606771;
+ --color-switch-knob-disabled-bg: #2d333b;
+ --color-switch-knob-checked-bg: #22272e;
+ --color-switch-knob-checked-disabled-bg: #2d333b;
+ --color-switch-knob-checked-border: rgba(49,109,202,0.35);
+ --color-segmented-control-bg: rgba(99,110,123,0.1);
+ --color-segmented-control-button-bg: #22272e;
--color-segmented-control-button-hover-bg: #444c56;
--- base/dist/scss/colors/_dark_high_contrast.scss 2023-02-10 19:19:57.319601599 +0000
+++ dist/scss/colors/_dark_high_contrast.scss 2023-02-10 19:18:45.206761356 +0000
@@ -261,11 +261,23 @@
--color-action-list-item-danger-hover-text: #0a0c10;
- --color-switch-track-bg: #010409;
- --color-switch-track-border: #7a828e;
- --color-switch-track-checked-bg: rgba(64,158,255,0.35);
+ --color-switch-track-bg: #9ea7b3;
+ --color-switch-track-hover-bg: hsla(214,12%,61%,1);
+ --color-switch-track-active-bg: hsla(214,12%,58%,1);
+ --color-switch-track-disabled-bg: #272b33;
+ --color-switch-track-fg: #0a0c10;
+ --color-switch-track-disabled-fg: #010409;
+ --color-switch-track-border: rgba(0,0,0,0);
+ --color-switch-track-checked-bg: #409eff;
--color-switch-track-checked-hover-bg: rgba(64,158,255,0.5);
--color-switch-track-checked-active-bg: rgba(64,158,255,0.65);
- --color-switch-track-checked-border: #409eff;
- --color-switch-knob-checked-bg: #409eff;
- --color-switch-knob-checked-disabled-bg: #7a828e;
- --color-segmented-control-bg: #272b33;
+ --color-switch-track-checked-fg: #0a0c10;
+ --color-switch-track-checked-disabled-fg: #010409;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #0a0c10;
+ --color-switch-knob-border: #9ea7b3;
+ --color-switch-knob-disabled-bg: #272b33;
+ --color-switch-knob-checked-bg: #0a0c10;
+ --color-switch-knob-checked-disabled-bg: #272b33;
+ --color-switch-knob-checked-border: #409eff;
+ --color-segmented-control-bg: rgba(158,167,179,0.1);
+ --color-segmented-control-button-bg: #0a0c10;
--color-segmented-control-button-hover-bg: #525964;
--- base/dist/scss/colors/_dark_tritanopia.scss 2023-02-10 19:19:57.327601694 +0000
+++ dist/scss/colors/_dark_tritanopia.scss 2023-02-10 19:18:45.218761497 +0000
@@ -261,4 +261,9 @@
--color-action-list-item-danger-hover-text: #ff7b72;
- --color-switch-track-bg: #010409;
- --color-switch-track-border: #6e7681;
+ --color-switch-track-bg: rgba(110,118,129,0.1);
+ --color-switch-track-hover-bg: hsla(215,8%,72%,0.1);
+ --color-switch-track-active-bg: rgba(110,118,129,0.4);
+ --color-switch-track-disabled-bg: #21262d;
+ --color-switch-track-fg: #8b949e;
+ --color-switch-track-disabled-fg: #010409;
+ --color-switch-track-border: rgba(0,0,0,0);
--color-switch-track-checked-bg: rgba(31,111,235,0.35);
@@ -266,6 +271,13 @@
--color-switch-track-checked-active-bg: rgba(31,111,235,0.65);
- --color-switch-track-checked-border: #58a6ff;
- --color-switch-knob-checked-bg: #1f6feb;
- --color-switch-knob-checked-disabled-bg: #484f58;
- --color-segmented-control-bg: #161b22;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #010409;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #0d1117;
+ --color-switch-knob-border: #606771;
+ --color-switch-knob-disabled-bg: #161b22;
+ --color-switch-knob-checked-bg: #0d1117;
+ --color-switch-knob-checked-disabled-bg: #161b22;
+ --color-switch-knob-checked-border: rgba(31,111,235,0.35);
+ --color-segmented-control-bg: rgba(110,118,129,0.1);
+ --color-segmented-control-button-bg: #0d1117;
--color-segmented-control-button-hover-bg: #30363d;
--- base/dist/scss/colors/_light.scss 2023-02-10 19:19:57.275601080 +0000
+++ dist/scss/colors/_light.scss 2023-02-10 19:18:45.162760838 +0000
@@ -262,13 +262,25 @@
--color-switch-track-bg: #eaeef2;
- --color-switch-track-border: #afb8c1;
- --color-switch-track-checked-bg: #ddf4ff;
- --color-switch-track-checked-hover-bg: #b6e3ff;
- --color-switch-track-checked-active-bg: #80ccff;
- --color-switch-track-checked-border: #54aeff;
- --color-switch-knob-checked-bg: #0969da;
- --color-switch-knob-checked-disabled-bg: #6e7781;
+ --color-switch-track-hover-bg: hsla(210,24%,90%,1);
+ --color-switch-track-active-bg: hsla(210,24%,88%,1);
+ --color-switch-track-disabled-bg: #8c959f;
+ --color-switch-track-fg: #57606a;
+ --color-switch-track-disabled-fg: #ffffff;
+ --color-switch-track-border: rgba(0,0,0,0);
+ --color-switch-track-checked-bg: #0969da;
+ --color-switch-track-checked-hover-bg: #0860CA;
+ --color-switch-track-checked-active-bg: #0757BA;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #ffffff;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #ffffff;
+ --color-switch-knob-disabled-bg: #f6f8fa;
+ --color-switch-knob-border: #858F99;
+ --color-switch-knob-checked-bg: #ffffff;
+ --color-switch-knob-checked-disabled-bg: #f6f8fa;
+ --color-switch-knob-checked-border: #0969da;
--color-segmented-control-bg: #eaeef2;
+ --color-segmented-control-button-bg: #ffffff;
--color-segmented-control-button-hover-bg: rgba(175,184,193,0.2);
--color-segmented-control-button-active-bg: rgba(175,184,193,0.4);
- --color-segmented-control-button-selected-border: #6e7781;
+ --color-segmented-control-button-selected-border: #8c959f;
--color-tree-view-item-chevron-hover-bg: rgba(208,215,222,0.32);
--- base/dist/scss/colors/_light_colorblind.scss 2023-02-10 19:19:57.299601363 +0000
+++ dist/scss/colors/_light_colorblind.scss 2023-02-10 19:18:45.186761120 +0000
@@ -262,13 +262,25 @@
--color-switch-track-bg: #eaeef2;
- --color-switch-track-border: #afb8c1;
- --color-switch-track-checked-bg: #ddf4ff;
- --color-switch-track-checked-hover-bg: #b6e3ff;
- --color-switch-track-checked-active-bg: #80ccff;
- --color-switch-track-checked-border: #54aeff;
- --color-switch-knob-checked-bg: #0969da;
- --color-switch-knob-checked-disabled-bg: #6e7781;
+ --color-switch-track-hover-bg: hsla(210,24%,90%,1);
+ --color-switch-track-active-bg: hsla(210,24%,88%,1);
+ --color-switch-track-disabled-bg: #8c959f;
+ --color-switch-track-fg: #57606a;
+ --color-switch-track-disabled-fg: #ffffff;
+ --color-switch-track-border: rgba(0,0,0,0);
+ --color-switch-track-checked-bg: #0969da;
+ --color-switch-track-checked-hover-bg: #0860CA;
+ --color-switch-track-checked-active-bg: #0757BA;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #ffffff;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #ffffff;
+ --color-switch-knob-disabled-bg: #f6f8fa;
+ --color-switch-knob-border: #858F99;
+ --color-switch-knob-checked-bg: #ffffff;
+ --color-switch-knob-checked-disabled-bg: #f6f8fa;
+ --color-switch-knob-checked-border: #0969da;
--color-segmented-control-bg: #eaeef2;
+ --color-segmented-control-button-bg: #ffffff;
--color-segmented-control-button-hover-bg: rgba(175,184,193,0.2);
--color-segmented-control-button-active-bg: rgba(175,184,193,0.4);
- --color-segmented-control-button-selected-border: #6e7781;
+ --color-segmented-control-button-selected-border: #8c959f;
--color-tree-view-item-chevron-hover-bg: rgba(208,215,222,0.32);
--- base/dist/scss/colors/_light_high_contrast.scss 2023-02-10 19:19:57.287601222 +0000
+++ dist/scss/colors/_light_high_contrast.scss 2023-02-10 19:18:45.178761026 +0000
@@ -261,14 +261,26 @@
--color-action-list-item-danger-hover-text: #ffffff;
- --color-switch-track-bg: #ffffff;
- --color-switch-track-border: #20252c;
- --color-switch-track-checked-bg: #dff7ff;
- --color-switch-track-checked-hover-bg: #9cd7ff;
- --color-switch-track-checked-active-bg: #67b3fd;
- --color-switch-track-checked-border: #0349b4;
- --color-switch-knob-checked-bg: #0349b4;
- --color-switch-knob-checked-disabled-bg: #66707b;
+ --color-switch-track-bg: #66707b;
+ --color-switch-track-hover-bg: hsla(211,9%,47%,1);
+ --color-switch-track-active-bg: hsla(211,9%,49%,1);
+ --color-switch-track-disabled-bg: #88929d;
+ --color-switch-track-fg: #ffffff;
+ --color-switch-track-disabled-fg: #ffffff;
+ --color-switch-track-border: rgba(0,0,0,0);
+ --color-switch-track-checked-bg: #0349b4;
+ --color-switch-track-checked-hover-bg: #0860CA;
+ --color-switch-track-checked-active-bg: #0757BA;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #ffffff;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #ffffff;
+ --color-switch-knob-disabled-bg: #e7ecf0;
+ --color-switch-knob-border: #20252c;
+ --color-switch-knob-checked-bg: #ffffff;
+ --color-switch-knob-checked-disabled-bg: #e7ecf0;
+ --color-switch-knob-checked-border: #0349b4;
--color-segmented-control-bg: #e7ecf0;
+ --color-segmented-control-button-bg: #ffffff;
--color-segmented-control-button-hover-bg: rgba(172,182,192,0.2);
--color-segmented-control-button-active-bg: rgba(172,182,192,0.4);
- --color-segmented-control-button-selected-border: #66707b;
+ --color-segmented-control-button-selected-border: #88929d;
--color-tree-view-item-chevron-hover-bg: #ced5dc;
--- base/dist/scss/colors/_light_tritanopia.scss 2023-02-10 19:19:57.303601411 +0000
+++ dist/scss/colors/_light_tritanopia.scss 2023-02-10 19:18:45.190761167 +0000
@@ -262,13 +262,25 @@
--color-switch-track-bg: #eaeef2;
- --color-switch-track-border: #afb8c1;
- --color-switch-track-checked-bg: #ddf4ff;
- --color-switch-track-checked-hover-bg: #b6e3ff;
- --color-switch-track-checked-active-bg: #80ccff;
- --color-switch-track-checked-border: #54aeff;
- --color-switch-knob-checked-bg: #0969da;
- --color-switch-knob-checked-disabled-bg: #6e7781;
+ --color-switch-track-hover-bg: hsla(210,24%,90%,1);
+ --color-switch-track-active-bg: hsla(210,24%,88%,1);
+ --color-switch-track-disabled-bg: #8c959f;
+ --color-switch-track-fg: #57606a;
+ --color-switch-track-disabled-fg: #ffffff;
+ --color-switch-track-border: rgba(0,0,0,0);
+ --color-switch-track-checked-bg: #0969da;
+ --color-switch-track-checked-hover-bg: #0860CA;
+ --color-switch-track-checked-active-bg: #0757BA;
+ --color-switch-track-checked-fg: #ffffff;
+ --color-switch-track-checked-disabled-fg: #ffffff;
+ --color-switch-track-checked-border: rgba(0,0,0,0);
+ --color-switch-knob-bg: #ffffff;
+ --color-switch-knob-disabled-bg: #f6f8fa;
+ --color-switch-knob-border: #858F99;
+ --color-switch-knob-checked-bg: #ffffff;
+ --color-switch-knob-checked-disabled-bg: #f6f8fa;
+ --color-switch-knob-checked-border: #0969da;
--color-segmented-control-bg: #eaeef2;
+ --color-segmented-control-button-bg: #ffffff;
--color-segmented-control-button-hover-bg: rgba(175,184,193,0.2);
--color-segmented-control-button-active-bg: rgba(175,184,193,0.4);
- --color-segmented-control-button-selected-border: #6e7781;
+ --color-segmented-control-button-selected-border: #8c959f;
--color-tree-view-item-chevron-hover-bg: rgba(208,215,222,0.32); |
🟢 No design token changes found |
lukasoppermann
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
…imitives into mp/toggle-switch-style-updates
…rol color primitives
…per design feedback
langermank
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.
Looks good to me! Thanks for the helpful comments ❤️
…imitives into mp/toggle-switch-style-updates
Summary
switchTrackandswitchKnobresting background and border colors.switchTrack.activeBgswitchTrack.disabledBgswitchTrack.fgswitchTrack.disabledFgswitchTrack.checked.fgswitchTrack.checked.disabledFgswitchKnob.bgswitchKnob.borderswitchKnob.disabledBgswitchKnob.checked.disabledBorderWhat should reviewers focus on?
Does it look good in the React storybook preview deployment?
Steps to test:
Look at the preview Storybook deployment from the PR (link coming soon)
Contributor checklist:
Reviewer checklist: