mirror of
https://github.com/mdbootstrap/mdb-ui-kit.git
synced 2024-11-23 18:14:04 +03:00
sass button-variations now being replaced
This commit is contained in:
parent
7fc8f47437
commit
cfa603321e
14
Gruntfile.js
14
Gruntfile.js
|
@ -29,16 +29,10 @@ module.exports = function(grunt) {
|
||||||
},
|
},
|
||||||
|
|
||||||
// button variations mixin replacement(s)
|
// button variations mixin replacement(s)
|
||||||
//{ // http://rubular.com/r/r198CndVsf
|
{ // Multi-line replacement -https://regex101.com/r/qD9qB8/2
|
||||||
// pattern: /.generic-variations\(unquote\((.*)\).*\).*(\d+).*}\);/m,
|
pattern: /.generic-variations\(unquote\(("[^"]+")\), (\$[\s\S]+?(?!\r|\n)), {$\n[\s\S]+?(?!\r|\n)contrast[\s\S]+?(?!\r|\n)(\d+)[\s\S]+?(?!\r|\n)}\);$\n/mg,
|
||||||
// replacement: '@include button-variations(unquote($1), $btn-default, $2%);',
|
replacement: '@include button-variations(unquote($1), $2, $3%);\n',
|
||||||
// order: 200
|
order: 20
|
||||||
//}
|
|
||||||
// attempting multi-line replacement - https://github.com/duvillierA/grunt-less-to-sass/issues/6
|
|
||||||
{ // http://rubular.com/r/oL4O1x6Wda
|
|
||||||
pattern: /.generic-variations\(unquote\(("[^"]+")\), (\$.+?(?!\r|\n)), {$\n.+?(?!\r|\n)(\d+).+?(?!\r|\n)}\);$\n/m,
|
|
||||||
replacement: '@include button-variations(unquote($1), $2, $3%);',
|
|
||||||
order: 2
|
|
||||||
}
|
}
|
||||||
|
|
||||||
]
|
]
|
||||||
|
|
|
@ -24,17 +24,11 @@
|
||||||
@include background-variations(unquote(":not(.btn-link):not(.btn-flat)"), $btn-default);
|
@include background-variations(unquote(":not(.btn-link):not(.btn-flat)"), $btn-default);
|
||||||
|
|
||||||
// BTN hover effect
|
// BTN hover effect
|
||||||
.generic-variations(unquote(":hover:not(.btn-link):not(.btn-flat)"), $btn-default, {
|
@include button-variations(unquote(":hover:not(.btn-link):not(.btn-flat)"), $btn-default, 4%);
|
||||||
background-color: contrast($material-color, darken($material-color, 4%), lighten($material-color, 4%), $contrast-factor);
|
|
||||||
});
|
|
||||||
// BTN active effect
|
// BTN active effect
|
||||||
.generic-variations(unquote(":active:not(.btn-link):not(.btn-flat)"), $btn-default, {
|
@include button-variations(unquote(":active:not(.btn-link):not(.btn-flat)"), $btn-default, 6%);
|
||||||
background-color: contrast($material-color, darken($material-color, 6%), lighten($material-color, 6%), $contrast-factor);
|
|
||||||
});
|
|
||||||
// BTN .active effect
|
// BTN .active effect
|
||||||
.generic-variations(unquote(".active:not(.btn-link):not(.btn-flat)"), $btn-default, {
|
@include button-variations(unquote(".active:not(.btn-link):not(.btn-flat)"), $btn-default, 6%);
|
||||||
background-color: contrast($material-color, darken($material-color, 6%), lighten($material-color, 6%), $contrast-factor);
|
|
||||||
});
|
|
||||||
// BTN flat hover effect
|
// BTN flat hover effect
|
||||||
.generic-variations(unquote(".btn-flat:hover:not(.btn-link)"), $btn-default, {
|
.generic-variations(unquote(".btn-flat:hover:not(.btn-link)"), $btn-default, {
|
||||||
background-color: rgba($material-color, (20/100));
|
background-color: rgba($material-color, (20/100));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user