2021-02-09 08:09:06 +00:00
|
|
|
/* switch box */
|
|
|
|
|
2023-02-14 08:19:41 +00:00
|
|
|
.switch {
|
2021-02-09 08:09:06 +00:00
|
|
|
--switch-size: 24px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.switch.small {
|
|
|
|
--switch-size: 12px;
|
|
|
|
}
|
|
|
|
|
|
|
|
.switch input {
|
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
|
2023-02-14 08:19:41 +00:00
|
|
|
.switch i {
|
2021-02-09 08:09:06 +00:00
|
|
|
display: inline-block;
|
|
|
|
vertical-align: middle;
|
|
|
|
cursor: pointer;
|
|
|
|
padding-right: var(--switch-size);
|
|
|
|
transition: all ease 0.2s;
|
|
|
|
-webkit-transition: all ease 0.2s;
|
|
|
|
-moz-transition: all ease 0.2s;
|
|
|
|
-o-transition: all ease 0.2s;
|
|
|
|
border-radius: var(--switch-size);
|
|
|
|
box-shadow: inset 0 0 1px 1px rgba(0, 0, 0, 0.5);
|
|
|
|
}
|
|
|
|
|
2023-02-14 08:19:41 +00:00
|
|
|
.switch i:before {
|
2021-02-09 08:09:06 +00:00
|
|
|
display: block;
|
|
|
|
content: '';
|
|
|
|
width: var(--switch-size);
|
|
|
|
height: var(--switch-size);
|
|
|
|
border-radius: var(--switch-size);
|
|
|
|
background: white;
|
|
|
|
box-shadow: 0 0 1px 1px rgba(0, 0, 0, 0.5);
|
|
|
|
}
|
|
|
|
|
2023-02-14 08:19:41 +00:00
|
|
|
.switch :checked + i {
|
2021-02-09 08:09:06 +00:00
|
|
|
padding-right: 0;
|
|
|
|
padding-left: var(--switch-size);
|
2023-09-04 15:20:36 +00:00
|
|
|
-webkit-box-shadow:
|
|
|
|
inset 0 0 1px rgba(0, 0, 0, 0.5),
|
|
|
|
inset 0 0 40px #337ab7;
|
|
|
|
-moz-box-shadow:
|
|
|
|
inset 0 0 1px rgba(0, 0, 0, 0.5),
|
|
|
|
inset 0 0 40px #337ab7;
|
|
|
|
box-shadow:
|
|
|
|
inset 0 0 1px rgba(0, 0, 0, 0.5),
|
|
|
|
inset 0 0 40px #337ab7;
|
2021-02-09 08:09:06 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.switch :disabled + i {
|
|
|
|
opacity: 0.5;
|
|
|
|
cursor: not-allowed;
|
|
|
|
}
|
2021-10-06 06:24:26 +00:00
|
|
|
|
|
|
|
.switch.limited {
|
|
|
|
pointer-events: none;
|
|
|
|
touch-action: none;
|
|
|
|
}
|
|
|
|
|
|
|
|
.switch.limited i {
|
|
|
|
opacity: 1;
|
|
|
|
cursor: not-allowed;
|
|
|
|
}
|
|
|
|
|
|
|
|
.switch.business i {
|
|
|
|
background-color: var(--BE-only);
|
2023-09-04 15:20:36 +00:00
|
|
|
box-shadow:
|
|
|
|
inset 0 0 1px rgb(0 0 0 / 50%),
|
|
|
|
inset 0 0 40px var(--BE-only);
|
2021-10-06 06:24:26 +00:00
|
|
|
}
|
2022-08-02 23:15:00 +00:00
|
|
|
|
|
|
|
.switch input[type='checkbox']:disabled + .slider {
|
|
|
|
cursor: not-allowed;
|
|
|
|
}
|