Skip to content
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

Style variables for switch control component missing #2913

Closed
NachoJusticia opened this issue Sep 7, 2018 · 0 comments
Closed

Style variables for switch control component missing #2913

NachoJusticia opened this issue Sep 7, 2018 · 0 comments

Comments

@NachoJusticia
Copy link
Contributor

Environment

  • Package version(s): 3.0.0-beta.1
  • Browser and OS versions: Google Chrome, MacOS High Sierra 10.13.3

Steps to reproduce

  1. Try to update switch component background colors just for dark theme using dark-switch-background-color variable in _controls.scss file.

Actual behavior

dark-switch-background-color variable is not being used among _controls.scss file, so nothing gets updated.

Expected behavior

  • Switch component updates its color just in dark theme.

Possible solution

Update this code (lane 378 of _controls.scss):

.#{$ns}-dark & {
      @include indicator-colors(
        "",
        $switch-background-color,
        $switch-background-color-hover,
        $switch-background-color-active,
        $switch-background-color-disabled
      );
      @include indicator-colors(
        ":checked",
        $switch-checked-background-color,
        $switch-checked-background-color-hover,
        $switch-checked-background-color-active,
        $switch-checked-background-color-disabled
      );
      ...

to

    .#{$ns}-dark & {
      @include indicator-colors(
        "",
        $dark-switch-background-color,
        $dark-switch-background-color-hover,
        $dark-switch-background-color-active,
        $dark-switch-background-color-disabled
      );
      @include indicator-colors(
        ":checked",
        $dark-switch-checked-background-color,
        $dark-switch-checked-background-color-hover,
        $dark-switch-checked-background-color-active,
        $dark-switch-checked-background-color-disabled
      );
      ... 

as I suggest in this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant