Icon and Colour fields for managing commands
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
|
||||
.colour-field {
|
||||
&__option {
|
||||
@include animate(0.1s);
|
||||
display: inline-block;
|
||||
border-radius: 3px;
|
||||
background: colour(grey);
|
||||
@ -9,10 +10,17 @@
|
||||
margin: 2px 8px 2px 0;
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
border: 2px solid colour(grey);
|
||||
overflow: hidden;
|
||||
|
||||
&--selected {
|
||||
border-color: colour(turquoise);
|
||||
&:after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
&__icon {
|
||||
@ -20,6 +28,20 @@
|
||||
top: 3px;
|
||||
left: 3px;
|
||||
font-size: 20px;
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
&:after {
|
||||
background: rgba(255,255,255,0.15);
|
||||
}
|
||||
}
|
||||
|
||||
&:active,
|
||||
&:focus {
|
||||
&:after {
|
||||
background: rgba(0,0,0,0.15);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
52
src/scss/components/_icon-field.scss
Executable file
52
src/scss/components/_icon-field.scss
Executable file
@ -0,0 +1,52 @@
|
||||
|
||||
.icon-field {
|
||||
&__option {
|
||||
@include animate(0.1s);
|
||||
display: inline-block;
|
||||
border-radius: 3px;
|
||||
width: 30px;
|
||||
height: 30px;
|
||||
margin: 0 4px 4px 0;
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
overflow: hidden;
|
||||
|
||||
&--selected {
|
||||
&:after {
|
||||
background: colour(grey) !important;
|
||||
}
|
||||
}
|
||||
|
||||
&__icon {
|
||||
position: absolute;
|
||||
top: 6px;
|
||||
left: 6px;
|
||||
font-size: 18px;
|
||||
z-index: 3;
|
||||
}
|
||||
|
||||
&:after {
|
||||
content: '';
|
||||
display: block;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
&:after {
|
||||
background: rgba(255,255,255,0.15);
|
||||
}
|
||||
}
|
||||
|
||||
&:active,
|
||||
&:focus {
|
||||
&:after {
|
||||
background: rgba(255,255,255,0.3);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user