// $bg - Default:$input-prefix-bg || scale-color(#fff, $lightness: -5%) !default;
// $is-button - Toggle position settings if prefix is a button. Default:false
//
-@mixin prefix($bg:$input-prefix-bg,$is-button:false) {
+@mixin prefix($bg:$input-prefix-bg, $border:$input-prefix-border-color, $is-button:false) {
@if $bg {
$bg-lightness: lightness($bg);
background: $bg;
- border-color: scale-color($bg, $lightness: -11%);
border-#{$opposite-direction}: none;
// Control the font color based on background brightness
@else { color: $input-prefix-font-color-alt; }
}
+ @if $border {
+ border-color: $border;
+ }
+
@if $is-button {
padding-#{$default-float}: 0;
padding-#{$opposite-direction}: 0;
// We use this mixin to create postfix label styles
// $bg - Default:$input-prefix-bg || scale-color(#fff, $lightness: -5%) !default;
// $is-button - Toggle position settings if prefix is a button. Default: false
-@mixin postfix($bg:$input-prefix-bg, $is-button:false) {
+@mixin postfix($bg:$input-prefix-bg, $border:$input-prefix-border-color, $is-button:false) {
@if $bg {
$bg-lightness: lightness($bg);
background: $bg;
- border-color: scale-color($bg, $lightness: -16%);
border-#{$default-float}: none;
// Control the font color based on background brightness
@else { color: $input-prefix-font-color-alt; }
}
+ @if $border {
+ border-color: $border;
+ }
+
@if $is-button {
padding-#{$default-float}: 0;
padding-#{$opposite-direction}: 0;
.postfix { @include prefix-postfix-base; }
/* Adjust padding, alignment and radius if pre/post element is a button */
- .postfix.button { @include button-size(false,false,false); @include postfix(false,true); }
- .prefix.button { @include button-size(false,false,false); @include prefix(false,true); }
+ .postfix.button { @include button-size(false,false,false); @include postfix(false, false, true); }
+ .prefix.button { @include button-size(false,false,false); @include prefix(false, false, true); }
.prefix.button.radius { @include radius(0); @include side-radius(left, $button-radius); }
.postfix.button.radius { @include radius(0); @include side-radius(right, $button-radius); }