signal-desktop/sticker-creator/elements/LabeledCheckbox.scss
2021-10-13 10:05:18 -07:00

60 lines
1 KiB
SCSS

// Copyright 2019-2021 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
@import '../../stylesheets/variables';
@import '../mixins';
.base {
display: flex;
flex-direction: row;
align-items: center;
padding: 2px;
// We'd really like to use focus-within-visible or :has(:focus-visible), to ensure that
// this doesn't show when using the mouse, but neither are ready yet!
&:focus-within {
outline: 2px solid -webkit-focus-ring-color;
}
}
.input {
position: absolute;
width: 0;
height: 0;
opacity: 0;
}
.checkbox {
width: 18px;
height: 18px;
border-radius: 2px;
display: flex;
justify-content: center;
align-items: center;
border: {
width: 2px;
style: solid;
}
@include light-theme() {
border-color: $color-gray-60;
}
@include dark-theme() {
border-color: $color-gray-25;
}
}
.checkbox-checked {
composes: checkbox;
border: none;
background-color: $color-ultramarine;
color: $color-white;
}
.label {
margin-left: 6px;
position: relative;
user-select: none;
}