Skip to content

Commit

Permalink
Update x-follow-button for origami major change
Browse files Browse the repository at this point in the history
So that we can include it in projects that use other components that use
the latest changes.
  • Loading branch information
edds committed Dec 4, 2019
1 parent 04d7890 commit f7474c7
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 26 deletions.
6 changes: 3 additions & 3 deletions components/x-follow-button/bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
"private": true,
"main": "dist/FollowButton.es5.js",
"dependencies": {
"o-colors": "^4.4.1",
"o-icons": "^5.7.1",
"o-typography": "^5.7.4"
"o-colors": "^5.0.3",
"o-icons": "^6.0.0",
"o-typography": "^6.1.0"
}
}
5 changes: 4 additions & 1 deletion components/x-follow-button/src/styles/main.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
// TODO: update me to not need a system code
$system-code:'github:Financial-Times/x-dash' !default;

@import 'o-icons/main';
@import 'o-colors/main';
@import 'o-typography/main';

@import './mixins/lozenge/main.scss';

@import './components/FollowButton.scss';
@import './components/FollowButton.scss';
38 changes: 19 additions & 19 deletions components/x-follow-button/src/styles/mixins/lozenge/_themes.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,32 @@ $theme-map: null;

$myft-lozenge-themes: (
standard: (
background: oColorsGetPaletteColor('claret'),
text: oColorsGetPaletteColor('white'),
highlight: oColorsGetPaletteColor('claret-50'),
pressed-highlight: rgba(oColorsGetPaletteColor('black'), 0.05),
disabled: rgba(oColorsGetPaletteColor('black'), 0.5)
background: oColorsByName('claret'),
text: oColorsByName('white'),
highlight: oColorsByName('claret-50'),
pressed-highlight: rgba(oColorsByName('black'), 0.05),
disabled: rgba(oColorsByName('black'), 0.5)
),
inverse: (
background: oColorsGetPaletteColor('white'),
text: oColorsGetPaletteColor('claret'),
background: oColorsByName('white'),
text: oColorsByName('claret'),
highlight: rgba(white, 0.8),
pressed-highlight: rgba(white, 0.2),
disabled: rgba(oColorsGetPaletteColor('white'), 0.5)
disabled: rgba(oColorsByName('white'), 0.5)
),
opinion: (
background: oColorsGetPaletteColor('oxford-40'),
text: oColorsGetPaletteColor('white'),
highlight: oColorsGetPaletteColor('oxford-30'),
pressed-highlight: rgba(oColorsGetPaletteColor('oxford-40'), 0.2),
disabled: rgba(oColorsGetPaletteColor('black'), 0.5)
background: oColorsByName('oxford-40'),
text: oColorsByName('white'),
highlight: oColorsByName('oxford-30'),
pressed-highlight: rgba(oColorsByName('oxford-40'), 0.2),
disabled: rgba(oColorsByName('black'), 0.5)
),
monochrome: (
background: oColorsGetPaletteColor('white'),
text: oColorsGetPaletteColor('black'),
highlight: oColorsGetPaletteColor('white-80'),
pressed-highlight: rgba(oColorsGetPaletteColor('white'), 0.2),
disabled: rgba(oColorsGetPaletteColor('white'), 0.5)
background: oColorsByName('white'),
text: oColorsByName('black'),
highlight: oColorsByName('white-80'),
pressed-highlight: rgba(oColorsByName('white'), 0.2),
disabled: rgba(oColorsByName('white'), 0.5)
)
);

Expand All @@ -39,4 +39,4 @@ $myft-lozenge-themes: (
$theme-map: map-get($myft-lozenge-themes, $theme) !global;

@content;
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@mixin getIcon($name, $color) {
@include oIconsGetIcon($icon-name: $name, $container-width: 10, $color: $color, $iconset-version: 1);
@include oIconsContent($icon-name: $name, $size: 10, $color: $color, $iconset-version: 1);
content: '';
}

Expand Down Expand Up @@ -40,4 +40,4 @@
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@

@mixin myftLozenge($theme: standard, $with-toggle-icon: false) {
@include myftLozengeTheme($theme, $with-toggle-icon);
@include oTypographySansBold($scale: -1);
@include oTypographySans($scale: -1, $weight: 'semibold');

border-radius: 100px; // Number that will be larger than any possible height, so that works for all possible button sizes
box-sizing: content-box;
Expand Down

0 comments on commit f7474c7

Please sign in to comment.