]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/sass/bootstrap.scss
Translated using Weblate (Russian)
[github/Chocobozzz/PeerTube.git] / client / src / sass / bootstrap.scss
CommitLineData
8cbc40b2
C
1@use '_variables' as *;
2@use '_mixins' as *;
3
4@import './_bootstrap-variables';
5
6@import '~bootstrap/scss/functions';
7@import '~bootstrap/scss/variables';
8cbc40b2 8@import '~bootstrap/scss/mixins';
4c8749cb
C
9@import '~bootstrap/scss/utilities';
10
8cbc40b2
C
11@import '~bootstrap/scss/root';
12@import '~bootstrap/scss/reboot';
13@import '~bootstrap/scss/type';
14@import '~bootstrap/scss/grid';
8cbc40b2
C
15@import '~bootstrap/scss/forms';
16@import '~bootstrap/scss/buttons';
17@import '~bootstrap/scss/dropdown';
18@import '~bootstrap/scss/button-group';
8cbc40b2
C
19@import '~bootstrap/scss/nav';
20@import '~bootstrap/scss/card';
4c8749cb 21@import '~bootstrap/scss/accordion';
8cbc40b2
C
22@import '~bootstrap/scss/alert';
23@import '~bootstrap/scss/close';
24@import '~bootstrap/scss/modal';
25@import '~bootstrap/scss/tooltip';
26@import '~bootstrap/scss/popover';
a14c1764 27@import '~bootstrap/scss/spinners';
4c8749cb
C
28
29@import '~bootstrap/scss/helpers';
30@import '~bootstrap/scss/utilities/api';
8cbc40b2 31
f409f0c3
RK
32.flex-auto {
33 flex: auto;
34}
35
d3217560 36.c-hand {
4c8749cb 37 cursor: pointer !important;
d3217560
RK
38}
39
5efa5df2
C
40// ---------------------------------------------------------------------------
41// Dropdown
42// ---------------------------------------------------------------------------
43
2f4c784a 44.dropdown-menu {
b788e691
C
45 color: pvar(--mainForegroundColor);
46 background-color: pvar(--mainBackgroundColor);
47
0d3a2982 48 .dropdown-header {
27bc9586 49 @include padding-left(1rem);
0d3a2982
RK
50 }
51
2f4c784a
C
52 .dropdown-item {
53 padding: 3px 15px;
54
24e7916c 55 &.active {
e66883b3
RK
56 color: pvar(--mainBackgroundColor) !important;
57 background-color: pvar(--mainHoverColor);
931d3430 58 opacity: 0.9;
2f4c784a 59 }
45c6bcf3 60
d3217560
RK
61 &::after {
62 display: none;
63 }
2f4c784a
C
64 }
65
2f4c784a
C
66 a {
67 @include disable-default-a-behaviour;
2f4c784a
C
68 }
69}
70
5efa5df2
C
71.dropdown-divider {
72 margin: 0.3rem 0;
73}
74
5b0ec7cd
C
75// ---------------------------------------------------------------------------
76// Alert
77// ---------------------------------------------------------------------------
78
79.alert {
80 p:last-child {
81 margin-bottom: 0;
82 }
83}
84
5efa5df2
C
85// ---------------------------------------------------------------------------
86// Modal
87// ---------------------------------------------------------------------------
88
165ee292 89@media screen and (min-width: #{breakpoint(md)}) {
931d3430 90 .modal::before {
3921166d 91 vertical-align: middle;
931d3430 92 content: ' ';
3921166d
RK
93 height: 100%;
94 }
95
96 .modal-dialog {
27bc9586 97 text-align: start;
2bc9bd08
RK
98
99 &:not(.modal-lg):not(.modal-xl) {
100 min-width: 500px;
101 width: 40vw;
102 max-width: 900px;
103 }
3921166d
RK
104 }
105}
106
2f4c784a 107.modal {
3921166d
RK
108 text-align: center;
109
2f4c784a 110 .modal-content {
e66883b3 111 background-color: pvar(--mainBackgroundColor);
681276a6 112 word-break: break-word;
2f4c784a
C
113 }
114
115 .modal-header {
931d3430 116 border-bottom: 0;
2f4c784a
C
117 margin-bottom: 5px;
118
119 .modal-title {
120 font-size: 20px;
121 font-weight: $font-semibold;
122 }
123
124 my-global-icon {
54e78847 125 @include icon(22px);
2f4c784a 126
931d3430 127 opacity: 0.5;
8319d6ae 128
5b0ec7cd
C
129 &:hover {
130 opacity: 0.8;
8319d6ae 131 }
2f4c784a
C
132 }
133 }
134
135 .inputs {
136 margin-bottom: 0;
27bc9586 137 text-align: end;
2f4c784a 138
26490335 139 > *:not(:first-child) {
27bc9586 140 @include margin-left(10px);
2f4c784a
C
141 }
142 }
143}
144
8110705d 145
146// On desktop browsers, make the content and header horizontally sticked to right not move when modal open and close
147.modal-open {
148 overflow-y: scroll !important; // Make sure vertical scroll bar is always visible on desktop browsers to get disabled scrollbar effect
17384fd8 149 width: 100vw; // Make sure the content fits all the available width
8110705d 150}
151
245b9d27
K
152// On touchscreen devices, simply overflow: hidden to avoid detached overlay on scroll
153@media (hover: none) and (pointer: coarse) {
931d3430
C
154 .modal-open,
155 .menu-open {
245b9d27
K
156 overflow: hidden !important;
157 }
158
159 // On touchscreen devices display content overlay when opened menu
160 .menu-open {
161 .main-col {
162 &::before {
931d3430 163 background-color: #000;
245b9d27
K
164 width: 100vw;
165 height: 100vh;
166 opacity: 0.75;
167 content: '';
168 display: block;
245b9d27
K
169 }
170 }
171 }
172}
173
5efa5df2
C
174// ---------------------------------------------------------------------------
175// Nav
176// ---------------------------------------------------------------------------
177
2f4c784a
C
178.nav .nav-link {
179 display: flex !important;
180 align-items: center;
181 height: 30px !important;
182 padding: 10px 15px !important;
183}
184
185.nav.nav-pills {
186 font-size: 16px !important;
ed5bb517 187 font-weight: $font-semibold !important;
2f4c784a 188
ed5bb517 189 .nav-link {
3d2078d6 190 opacity: 0.7 !important;
ed5bb517 191
931d3430
C
192 &.active,
193 &:hover,
194 &:active,
195 &:focus {
ed5bb517
K
196 opacity: 1 !important;
197 }
2f4c784a
C
198 }
199
200 a {
201 @include disable-default-a-behaviour;
202
e66883b3 203 color: pvar(--mainForegroundColor);
2f4c784a
C
204 }
205}
206
ed5bb517
K
207.nav-tabs .nav-link {
208 @include disable-default-a-behaviour;
2f4c784a 209
ed5bb517
K
210 color: pvar(--mainForegroundColor);
211 font-weight: $font-semibold;
931d3430 212 border: 0;
ed5bb517 213 border-bottom: 2px solid transparent;
3d2078d6 214 opacity: 0.7;
2f4c784a 215
758f0d19 216 &.active {
ed5bb517 217 color: pvar(--mainForegroundColor);
e66883b3 218 background-color: pvar(--mainBackgroundColor) !important;
ed5bb517 219 border-bottom-color: pvar(--mainColor);
758f0d19 220 }
ed5bb517 221
931d3430
C
222 &.active,
223 &:hover,
224 &:active,
225 &:focus {
ed5bb517 226 opacity: 1;
758f0d19 227 }
2f4c784a
C
228}
229
5efa5df2
C
230// ---------------------------------------------------------------------------
231// Card, collapse and accordion
232// ---------------------------------------------------------------------------
233
a4610bc6 234.card {
e66883b3 235 background-color: pvar(--mainBackgroundColor);
a4610bc6
JM
236 border-color: #dee2e6;
237}
238
2f4c784a
C
239.collapse-transition {
240 // Animation when we show/hide the filters
241 transition: max-height 0.3s;
242 display: block !important;
243 overflow: hidden !important;
244 max-height: 0;
245
246 &.show {
247 max-height: 1500px;
dd24f1bb 248 overflow: inherit !important;
2f4c784a
C
249 }
250}
bc584963 251
5efa5df2
C
252// ---------------------------------------------------------------------------
253// Buttons & form controls
254// ---------------------------------------------------------------------------
000eb0e4 255
5b0ec7cd
C
256.btn:not(.btn-sm) {
257 font-size: $button-font-size;
258 line-height: 1.2;
259}
260
947d0102
RK
261.btn-outline-secondary {
262 border-color: $input-border-color;
263
264 &:focus-within,
265 &:focus,
266 &:hover {
267 color: #fff;
268 background-color: #6c757d;
269 }
270}
271
a8454bb2 272.btn-group.select-button {
2accfdd8
C
273 font-weight: $font-semibold;
274
275 .active {
276 @include orange-button;
277 }
278
279 :not(.active) {
280 @include grey-button;
281 }
282
283 > * {
284 @include peertube-button-link;
285
286 box-shadow: none !important;
287
288 &:not(:first-child) {
289 border-top-left-radius: 0 !important;
290 border-bottom-left-radius: 0 !important;
291 }
292
293 &:not(:last-child) {
294 border-top-right-radius: 0 !important;
295 border-bottom-right-radius: 0 !important;
296 }
297 }
298}
299
a6d5ff76 300.form-control {
e66883b3
RK
301 color: pvar(--mainForegroundColor);
302 background-color: pvar(--inputBackgroundColor);
a6d5ff76 303 outline: none;
a6d5ff76 304}
947d0102 305
0d3a2982 306.input-group {
4c8749cb
C
307 > .btn,
308 > .input-group-text {
309 height: $button-height;
0d3a2982 310 }
931d3430 311
4c8749cb 312 > .input-group-text {
4c8749cb
C
313 line-height: normal;
314 opacity: 0.9;
0d3a2982
RK
315 }
316
4c8749cb
C
317 .input-group-text > .dropdown-toggle {
318 display: flex;
319 }
320
321 .last-in-group {
322 border-top-right-radius: 3px !important;
323 border-bottom-right-radius: 3px !important;
0d3a2982 324 }
947d0102 325}
25a42e29 326
4c8749cb 327.has-clear {
25a42e29 328 input {
27bc9586 329 @include padding-right(1.5rem !important);
25a42e29
RK
330 }
331
332 .form-control-clear {
333 color: rgba(0, 0, 0, 0.4);
25a42e29
RK
334 display: flex;
335 justify-content: center;
336 align-items: center;
25a42e29 337 height: 95%;
4f5d0459 338 font-size: 14px;
5b0ec7cd
C
339 position: absolute;
340 right: .5rem;
25a42e29
RK
341
342 &:hover {
343 color: rgba(0, 0, 0, 0.7);
344 cursor: pointer;
345 }
346 }
347
348 input:placeholder-shown + .form-control-clear {
349 display: none;
350 }
351}