2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-06-14 18:42:30 +03:00

add custom file vars, fix up custom select var

This commit is contained in:
Mark Otto
2016-01-17 15:21:16 -08:00
parent 6b318ef176
commit 5c12d5e469
2 changed files with 42 additions and 23 deletions
+23 -23
View File
@@ -185,19 +185,19 @@
position: relative;
display: inline-block;
max-width: 100%;
height: 2.5rem;
height: $custom-file-height;
cursor: pointer;
}
.custom-file-input {
min-width: 14rem;
min-width: $custom-file-width;
max-width: 100%;
margin: 0;
filter: alpha(opacity = 0);
opacity: 0;
&:focus ~ .custom-file-control {
@include box-shadow(0 0 0 .075rem #fff, 0 0 0 .2rem #0074d9);
@include box-shadow($custom-file-focus-box-shadow);
}
}
@@ -207,34 +207,34 @@
right: 0;
left: 0;
z-index: 5;
height: 2.5rem;
padding: .5rem 1rem;
line-height: 1.5;
color: #555;
height: $custom-file-height;
padding: $custom-file-padding-x $custom-file-padding-y;
line-height: $custom-file-line-height;
color: $custom-file-color;
user-select: none;
background-color: #fff;
border: $input-btn-border-width solid #ddd;
border-radius: .25rem;
@include box-shadow(inset 0 .2rem .4rem rgba(0,0,0,.05));
background-color: $custom-file-bg;
border: $custom-file-border-width solid $custom-file-border-color;
@include border-radius($custom-file-border-radius)
@include box-shadow($custom-file-box-shadow);
&::after {
content: "Choose file...";
content: $custom-file-placeholder;
}
&::before {
position: absolute;
top: -.075rem;
right: -.075rem;
bottom: -.075rem;
top: -$custom-file-border-width;
right: -$custom-file-border-width;
bottom: -$custom-file-border-width;
z-index: 6;
display: block;
height: 2.5rem;
padding: .5rem 1rem;
line-height: 1.5;
color: #555;
content: "Browse";
background-color: #eee;
border: $input-btn-border-width solid #ddd;
border-radius: 0 .25rem .25rem 0;
height: $custom-file-height;
padding: $custom-file-padding-x $custom-file-padding-y;
line-height: $custom-file-line-height;
color: $custom-file-button-color;
content: $custom-file-button-label;
background-color: $custom-file-button-bg;
border: $custom-file-border-width solid $custom-file-border-color;
@include border-radius(0 $custom-file-border-radius $custom-file-border-radius 0);
}
}