feat(sass): add support for contrast in color map for wp mode

BREAKING CHANGE:

Can now pass contrast to the colors map:

```
$colors-wp: (

  primary: (
    base: #327eff,
    contrast: yellow
  ),
  secondary: (
    base: #32db64,
    contrast: hotpink
  ),
  danger: #d91e18,
  light: #f4f4f4,
  dark: #222
) !default;
```

references #5445
This commit is contained in:
Brandy Carney
2016-03-22 18:07:59 -04:00
parent 9efa3ea3e6
commit 5f2e737904
17 changed files with 109 additions and 107 deletions

View File

@ -63,15 +63,15 @@ ion-segment {
// Windows Segment Button Mixin
// --------------------------------------------------
@mixin wp-segment-button($color-name, $color-value) {
@mixin wp-segment-button($color-name, $color-base) {
ion-segment[#{$color-name}] .segment-button {
color: $color-value;
color: $color-base;
&.activated,
&.segment-activated {
border-color: $color-value;
color: $color-value;
border-color: $color-base;
color: $color-base;
opacity: $segment-button-wp-opacity-activated;
}
}
@ -82,6 +82,6 @@ ion-segment {
// Windows Segment Color Generation
// --------------------------------------------------
@each $color-name, $color-value in $colors-wp {
@include wp-segment-button($color-name, $color-value);
@each $color-name, $color-base, $color-contrast in get-colors($colors-wp) {
@include wp-segment-button($color-name, $color-base);
}