2020-04-16 17:33:23 +08:00
|
|
|
/*
|
|
|
|
Copyright 2020 The Matrix.org Foundation C.I.C.
|
|
|
|
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
you may not use this file except in compliance with the License.
|
|
|
|
You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider {
|
2020-04-16 17:33:23 +08:00
|
|
|
position: relative;
|
|
|
|
margin: 0px;
|
2020-04-22 22:37:46 +08:00
|
|
|
flex-grow: 1;
|
2020-04-16 17:33:23 +08:00
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_dotContainer {
|
2020-04-16 17:33:23 +08:00
|
|
|
display: flex;
|
|
|
|
flex-direction: row;
|
|
|
|
justify-content: space-between;
|
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_bar {
|
2020-04-16 17:33:23 +08:00
|
|
|
display: flex;
|
|
|
|
box-sizing: border-box;
|
|
|
|
position: absolute;
|
2020-04-23 17:58:00 +08:00
|
|
|
height: 1em;
|
2020-04-16 17:33:23 +08:00
|
|
|
width: 100%;
|
2020-04-23 17:58:00 +08:00
|
|
|
padding: 0 0.5em; // half the width of a dot.
|
2020-04-16 17:33:23 +08:00
|
|
|
align-items: center;
|
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_bar > hr {
|
2020-04-16 17:33:23 +08:00
|
|
|
width: 100%;
|
2020-05-20 20:07:33 +08:00
|
|
|
height: 0.4em;
|
|
|
|
background-color: $slider-background-color;
|
|
|
|
border: 0;
|
2020-04-16 17:33:23 +08:00
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_selection {
|
2020-04-16 17:33:23 +08:00
|
|
|
display: flex;
|
|
|
|
align-items: center;
|
2020-04-23 17:58:00 +08:00
|
|
|
width: calc(100% - 1em); // 2 * half the width of a dot
|
|
|
|
height: 1em;
|
2020-04-16 17:33:23 +08:00
|
|
|
position: absolute;
|
2020-05-20 20:07:33 +08:00
|
|
|
pointer-events: none;
|
2020-04-16 17:33:23 +08:00
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_selectionDot {
|
2020-04-16 17:33:23 +08:00
|
|
|
position: absolute;
|
2021-10-20 20:41:27 +08:00
|
|
|
width: $slider-selection-dot-size;
|
|
|
|
height: $slider-selection-dot-size;
|
2021-11-08 19:50:53 +08:00
|
|
|
background-color: $accent-color;
|
2020-04-16 17:33:23 +08:00
|
|
|
border-radius: 50%;
|
|
|
|
z-index: 10;
|
|
|
|
}
|
|
|
|
|
2021-10-20 20:41:27 +08:00
|
|
|
.mx_Slider_selectionText {
|
|
|
|
color: $muted-fg-color;
|
|
|
|
font-size: $font-14px;
|
|
|
|
position: relative;
|
|
|
|
text-align: center;
|
|
|
|
top: 30px;
|
|
|
|
width: 100%;
|
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_selection > hr {
|
2020-04-16 17:33:23 +08:00
|
|
|
margin: 0;
|
2021-11-08 19:50:53 +08:00
|
|
|
border: 0.2em solid $accent-color;
|
2020-04-16 17:33:23 +08:00
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_dot {
|
2021-10-20 20:41:27 +08:00
|
|
|
height: $slider-dot-size;
|
|
|
|
width: $slider-dot-size;
|
2020-04-16 17:33:23 +08:00
|
|
|
border-radius: 50%;
|
2020-05-07 00:25:54 +08:00
|
|
|
background-color: $slider-background-color;
|
2020-04-16 17:33:23 +08:00
|
|
|
z-index: 0;
|
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_dotActive {
|
2021-11-08 19:50:53 +08:00
|
|
|
background-color: $accent-color;
|
2020-04-16 17:33:23 +08:00
|
|
|
}
|
|
|
|
|
2020-04-21 18:01:52 +08:00
|
|
|
.mx_Slider_dotValue {
|
2020-04-16 17:33:23 +08:00
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
align-items: center;
|
2020-05-07 00:25:54 +08:00
|
|
|
color: $slider-background-color;
|
2020-04-16 19:09:36 +08:00
|
|
|
}
|
2020-04-22 18:36:23 +08:00
|
|
|
|
|
|
|
// The following is a hack to center the labels without adding
|
|
|
|
// any width to the slider's dots.
|
|
|
|
.mx_Slider_labelContainer {
|
2020-04-23 17:58:00 +08:00
|
|
|
width: 1em;
|
2020-04-22 18:36:23 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
.mx_Slider_label {
|
|
|
|
position: relative;
|
|
|
|
width: fit-content;
|
|
|
|
left: -50%;
|
|
|
|
}
|