fleet/frontend/components/forms/fields/Dropdown/_styles.scss
RachelElysia 0834af5bb7
User Settings Page and User Management Page: SMTP config conditionally disables email update (#1309)
* Disable Email update field when SMTP is disabled
* Render tooltip, not-allowed cursor, greyed font for disabled UI
* Update integration tests accordingly
* Minor fixes to form styling
2021-07-06 12:22:51 -04:00

259 lines
4.7 KiB
SCSS

.dropdown {
&__label {
display: block;
font-size: $small;
font-weight: $regular;
color: $core-fleet-black;
margin-bottom: $pad-xsmall;
&--error {
font-weight: $bold;
}
}
&__select {
&--error {
&.Select {
.Select-control {
color: $core-vibrant-red;
border: 1px solid $core-vibrant-red;
box-sizing: border-box;
border-radius: 4px;
}
.Select-arrow {
border-top-color: $ui-error;
}
}
}
}
&__option {
display: flex;
flex-direction: column;
}
&__help-text {
margin-top: $pad-xsmall;
font-size: $xx-small;
white-space: normal;
color: $core-fleet-blue;
font-style: italic;
}
}
.Select {
.Select-control {
border: 1px solid $ui-fleet-blue-15;
background-color: $ui-light-grey;
border-radius: $border-radius;
height: 40px;
.Select-value {
font-size: $x-small;
border-radius: 4px;
background-color: $ui-off-white;
border: solid 1px $core-dark-blue-grey;
}
}
.Select-value {
font-size: $x-small;
border-radius: $border-radius;
background-color: $ui-off-white;
border: solid 1px $core-dark-blue-grey;
.Select-value-icon {
border: 0;
float: right;
position: relative;
line-height: 28px;
width: 20px;
padding: 0;
margin: 0 5px;
text-indent: -999em;
&::after {
transition: color 150ms ease-in-out;
content: url(../assets/images/icon-close-dark-blue-grey-16x16@2x.png);
transform: scale(0.5);
position: absolute;
top: -5px;
left: -5px;
visibility: visible;
font-size: $small;
color: $ui-gray;
text-indent: 0;
}
}
.Select-value-label {
font-size: $x-small;
color: $core-dark-blue-grey;
line-height: 28px;
}
}
&--single {
> .Select-control {
.Select-value {
line-height: 38px;
margin-top: 4px;
border: none;
}
}
}
.Select-arrow {
content: url("../assets/images/icon-chevron-black-16x16@2x.png");
height: 16px;
width: 16px;
margin-top: 8px;
margin-left: -4px;
border: none;
&:hover {
content: url("../assets/images/icon-chevron-blue-16x16@2x.png");
}
}
&.is-open {
.Select-arrow {
content: url("../assets/images/icon-collapse-black-16x16@2x.png");
height: 16px;
width: 16px;
margin-top: 14px;
margin-left: -3px;
border: none;
&:hover {
content: url("../assets/images/icon-collapse-blue-16x16@2x.png");
}
}
.Select-arrow-zone {
&:hover {
.Select-arrow {
border-top-color: transparent;
}
}
}
}
// .Select-arrow {
// border-top-color: $core-vibrant-blue;
// }
// &.is-focused {
// .Select-control {
// border: 1px solid $core-vibrant-blue;
// }
// &:not(.is-open) {
// .Select-control {
// box-shadow: none;
// }
// }
// }
&.has-value {
> .Select-control,
&.is-pseudo-focused > .Select-control {
.Select-value {
.Select-value-label {
color: $core-dark-blue-grey;
font-size: $x-small;
}
}
}
}
.Select-menu-outer {
margin-top: $pad-xsmall;
box-shadow: 0 4px 10px rgba(52, 59, 96, 0.15);
border-radius: $border-radius;
z-index: 6;
overflow: hidden;
border: 0;
}
.Select-noresults {
font-size: $x-small;
}
.Select-option {
color: $core-fleet-black;
font-size: $x-small;
margin: 6px 0;
padding: 6px $pad-medium;
display: block;
&.is-focused {
background-color: $ui-vibrant-blue-10;
.Select-icon {
color: $ui-vibrant-blue-10;
}
}
&.is-disabled {
color: $ui-gray;
.Select-icon {
visibility: hidden;
opacity: 0;
}
}
}
.Select-icon {
color: $ui-gray;
}
.Select-placeholder,
.Select-input {
color: $core-fleet-blue;
font-size: $small;
line-height: 40px;
padding: 0 12px;
box-sizing: border-box;
}
&.Select--multi {
.Select-control {
display: flex;
align-items: center;
height: auto;
min-height: 40px;
}
.Select-multi-value-wrapper {
flex-grow: 1;
padding: $pad-xsmall;
}
.Select-arrow-zone {
display: block;
}
.Select-option {
&.is-disabled {
color: $core-fleet-black;
cursor: default;
&.is-focused {
background-color: $ui-vibrant-blue-10;
color: $core-white;
}
}
}
.Select-value {
margin-top: 4px;
}
.Select-value-label {
padding: 0 0 0 10px;
}
}
}