]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/sass/primeng-custom.scss
Translated using Weblate (Spanish)
[github/Chocobozzz/PeerTube.git] / client / src / sass / primeng-custom.scss
CommitLineData
bbe0f064
C
1@import '_variables';
2@import '_mixins';
3
4@import '~primeng/resources/primeng.css';
276d9652 5@import '~primeng/resources/themes/nova-light/theme.css';
bbe0f064
C
6
7@mixin glyphicon-light {
8 font-family: 'Glyphicons Halflings';
9 text-decoration: none !important;
e66883b3 10 color: pvar(--mainForegroundColor) !important;
7738273b 11 font-display: swap;
bbe0f064
C
12}
13
bf64ed41
RK
14my-edit-button,
15my-delete-button,
16my-button {
17 height: max-content;
18}
19
2bc9bd08
RK
20// focus box-shadow for primeng
21.ui-inputtext:enabled:focus:not(.ui-state-error) {
e66883b3 22 box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest) !important;
2bc9bd08
RK
23}
24
bbe0f064
C
25// data table customizations
26p-table {
791645e6 27 .ui-table-caption {
276d9652 28 border: none !important;
e66883b3 29 background-color: pvar(--mainBackgroundColor) !important;
b014b6b9
C
30
31 .caption {
32 height: 40px;
25a42e29
RK
33 width: 100%;
34 display: inline-flex;
b014b6b9 35 align-items: center;
0d3a2982
RK
36
37 .input-group-text {
38 background-color: transparent;
39 }
b014b6b9 40 }
791645e6
C
41 }
42
276d9652 43 th {
e66883b3 44 background-color: pvar(--mainBackgroundColor) !important;
276d9652
C
45 outline: 0;
46 }
47
48 td, th {
49 font-family: $main-fonts;
50 font-size: 15px !important;
e66883b3 51 color: pvar(--mainForegroundColor) !important;
276d9652
C
52 }
53
bbe0f064 54 td {
bbe0f064 55 padding-left: 15px !important;
141b177d 56
566c125d 57 &:not(.action-cell):not(.expand-cell) {
141b177d
C
58 overflow: hidden !important;
59 text-overflow: ellipsis !important;
60 white-space: nowrap !important;
61 }
bbe0f064
C
62 }
63
64 tr {
276d9652 65 outline: 0;
e66883b3 66 background-color: pvar(--mainBackgroundColor) !important;
bbe0f064 67 height: 46px;
791645e6
C
68
69 &.ui-state-highlight {
e66883b3 70 background-color: pvar(--submenuColor) !important;
276d9652
C
71
72 td, td > a {
e66883b3 73 color: pvar(--mainForegroundColor) !important;
276d9652 74 }
791645e6 75 }
bbe0f064
C
76 }
77
78 .ui-table-tbody {
79 tr {
80 &:hover {
e66883b3 81 background-color: pvar(--submenuColor) !important;
bbe0f064
C
82 }
83
276d9652
C
84 td {
85 border: none !important;
86 }
87
bbe0f064
C
88 &:first-child td {
89 border-top: none !important;
90 }
91
92 &:last-child td {
93 border-bottom: none !important;
94 }
654a188f
RK
95
96 &:focus + tr > td,
97 &:focus > td {
98 box-shadow: none !important;
99 }
bbe0f064
C
100 }
101
102 .expander {
103 cursor: pointer;
104 position: relative;
105 top: 1px;
106 }
107 }
108
109 th {
110 border: none !important;
b9fcfb1d 111 border-bottom: 1px solid !important;
e66883b3 112 border-color: pvar(--submenuColor) !important;
bbe0f064
C
113 text-align: left !important;
114 padding: 5px 0 5px 15px !important;
115 font-weight: $font-semibold !important;
e66883b3 116 color: pvar(--mainForegroundColor) !important;
bbe0f064
C
117
118 &.ui-sortable-column:hover {
e66883b3 119 background-color: pvar(--submenuColor) !important;
b9fcfb1d 120 border: 1px solid !important;
e66883b3 121 border-color: pvar(--submenuColor) !important;
bbe0f064
C
122 border-width: 0 1px !important;
123
124 &:first-child {
125 border-width: 0 1px 0 0 !important;
126 }
127 }
128
129 &.ui-state-highlight {
e66883b3 130 background-color: pvar(--submenuColor) !important;
bbe0f064
C
131
132 .pi {
133 @extend .glyphicon;
134
276d9652
C
135 color: #000 !important;
136 font-size: 11px !important;
137 top: 0 !important;
bbe0f064 138
619443a3 139 &.pi-sort-amount-up-alt {
bbe0f064 140 @extend .glyphicon-triangle-top;
f2fab901 141
e66883b3 142 color: pvar(--mainForegroundColor) !important;
bbe0f064
C
143 }
144
619443a3 145 &.pi-sort-amount-down {
bbe0f064 146 @extend .glyphicon-triangle-bottom;
f2fab901 147
e66883b3 148 color: pvar(--mainForegroundColor) !important;
bbe0f064
C
149 }
150 }
151 }
152 }
153
154 .action-cell {
155 width: 250px !important;
156 padding: 0 !important;
157 text-align: center;
158
28e0e40d
C
159 .dropdown-root,
160 my-edit-button,
161 my-delete-button,
162 my-button {
2170f1db 163 display: inline-block !important;
165ee292 164 margin-left: 5px;
c5a1ae50 165
165ee292
K
166 :first-child {
167 margin-left: 0
168 }
bbe0f064
C
169 }
170 }
171
172 p-paginator {
173 .ui-paginator-bottom {
e66883b3 174 background-color: pvar(--mainBackgroundColor) !important;
bbe0f064 175 position: relative;
8b183196
RK
176 border: none;
177 border-top: 1px solid !important;
e66883b3 178 border-color: pvar(--submenuColor) !important;
bbe0f064
C
179 height: 40px;
180 display: flex;
181 justify-content: center;
182 align-items: center;
183
2bc9bd08
RK
184 .ui-dropdown {
185 position: absolute;
9b4241e3 186 top: 3px;
2bc9bd08 187 left: 0;
9b4241e3
RK
188
189 &.ui-state-focus {
e66883b3 190 box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest);
9b4241e3
RK
191 }
192
193 .ui-dropdown-label {
e66883b3 194 color: pvar(--inputPlaceholderColor);
9b4241e3 195 }
2bc9bd08
RK
196 }
197
198 .ui-paginator-current {
199 position: absolute;
200 right: 0;
e66883b3 201 color: pvar(--inputPlaceholderColor);
2bc9bd08
RK
202 }
203
30eac84e
C
204 .ui-paginator-first,
205 .ui-paginator-prev,
206 .ui-paginator-next,
207 .ui-paginator-last {
208 @include glyphicon-light;
209 padding: 5px 2px;
210 height: auto;
211 outline: none;
212 font-size: 13px;
213 top: -1px;
214
2bc9bd08
RK
215 &.focus-within,
216 &:focus {
e66883b3 217 box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest);
2bc9bd08
RK
218 }
219
30eac84e
C
220 &.ui-state-disabled:hover {
221 background-color: #fff !important;
222 }
223
224 &.ui-paginator-first {
225 @extend .glyphicon-step-backward;
226 }
227
228 &.ui-paginator-prev {
229 @extend .glyphicon-chevron-left;
230
231 margin-right: 10px;
232 }
233
234 &.ui-paginator-next {
235 @extend .glyphicon-chevron-right;
236
237 margin-left: 10px;
238 }
239
240 &.ui-paginator-last {
241 @extend .glyphicon-step-forward;
242 }
243 }
244
bbe0f064
C
245 .ui-paginator-pages {
246 height: auto !important;
247
2bc9bd08
RK
248 .ui-paginator-page {
249 &.focus-within,
250 &:focus {
e66883b3 251 box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest) !important;
165ee292 252 }
2bc9bd08
RK
253 }
254
bbe0f064 255 a {
e66883b3 256 color: pvar(--mainForegroundColor) !important;
bbe0f064 257 font-weight: $font-semibold !important;
276d9652 258 margin: 0 5px !important;
bbe0f064
C
259 outline: 0 !important;
260 border-radius: 3px !important;
261 padding: 5px 2px !important;
262 height: auto !important;
276d9652 263 line-height: initial !important;
bbe0f064
C
264
265 &.ui-state-active {
266 &, &:hover, &:active, &:focus {
267 color: #fff !important;
e66883b3 268 background-color: pvar(--mainColor) !important;
bbe0f064
C
269 }
270 }
271 }
272 }
273 }
274 }
275}
276
165ee292 277// overflow data table
c2a89b70 278@mixin overflow-datatable ($table-min-width, $horizontal-margins, $mobile-paginator: true) {
165ee292
K
279 p-table {
280 .ui-table-wrapper {
281 overflow-x: auto;
282 max-width: calc(100vw - #{$horizontal-margins * 2});
283
284 table {
285 min-width: $table-min-width;
286 }
287 }
288
c2a89b70
RK
289 @if $mobile-paginator {
290 p-paginator .ui-paginator-bottom {
165ee292 291 display: block;
619443a3 292
c2a89b70
RK
293 .ui-paginator-current {
294 position: relative;
295 display: block;
296 }
619443a3 297
c2a89b70
RK
298 a, .ui-paginator-pages {
299 vertical-align: middle;
300 }
165ee292
K
301 }
302 }
303 }
304}
305
bbe0f064
C
306// PrimeNG calendar tweaks
307p-calendar .ui-datepicker {
308 a {
309 @include disable-default-a-behaviour;
310 }
311
312 .ui-datepicker-header {
313
314 .ui-datepicker-year {
315 margin-left: 5px;
316 }
317
318 .ui-datepicker-next {
319 @extend .glyphicon-chevron-right;
320 @include glyphicon-light;
276d9652 321
aa879092 322 color: #000 !important;
276d9652
C
323 text-align: right;
324
325 .pi.pi-chevron-right {
326 display: none !important;
327 }
bbe0f064
C
328 }
329
330 .ui-datepicker-prev {
331 @extend .glyphicon-chevron-left;
332 @include glyphicon-light;
276d9652 333
aa879092 334 color: #000 !important;
276d9652
C
335 text-align: left;
336
337 .pi.pi-chevron-left {
338 display: none !important;
339 }
bbe0f064
C
340 }
341 }
342
343 .ui-timepicker {
344
345 .pi.pi-chevron-up {
346 @extend .glyphicon-chevron-up;
347 @include glyphicon-light;
aa879092
C
348
349 color: #000 !important;
bbe0f064
C
350 }
351
352 .pi.pi-chevron-down {
353 @extend .glyphicon-chevron-down;
354 @include glyphicon-light;
aa879092
C
355
356 color: #000 !important;
bbe0f064
C
357 }
358 }
791645e6
C
359}
360
46db9430
RK
361p-tablecheckbox:hover div .ui-chkbox-box {
362 box-shadow: 0 0 0 .1rem rgba(87, 85, 217, .2);
363}
364
17bb716b 365.ui-chkbox {
276d9652 366
17bb716b
C
367 &, .ui-chkbox-box {
368 width: 18px !important;
369 height: 18px !important;
791645e6
C
370 }
371
17bb716b
C
372 .ui-chkbox-box {
373 &.ui-state-active {
e66883b3
RK
374 border-color: pvar(--mainColor) !important;
375 background-color: pvar(--mainColor) !important;
791645e6
C
376 }
377
17bb716b
C
378 .ui-chkbox-icon {
379 position: relative;
380 overflow: visible !important;
381
382 &:after {
383 content: '';
384 position: absolute;
385 top: 1px;
386 left: 6px;
387 width: 5px;
388 height: 12px;
389 opacity: 0;
390 transform: rotate(45deg) scale(0);
e66883b3
RK
391 border-right: 2px solid pvar(--mainBackgroundColor);
392 border-bottom: 2px solid pvar(--mainBackgroundColor);
17bb716b
C
393 }
394
395 &.pi-check:after {
396 opacity: 1;
397 transform: rotate(45deg) scale(1);
398 }
791645e6
C
399 }
400 }
276d9652
C
401}
402
403p-inputswitch {
9b82d49d
RK
404 height: 26px;
405
276d9652 406 .ui-inputswitch-checked .ui-inputswitch-slider {
e66883b3 407 background-color: pvar(--mainColor) !important;
276d9652 408 }
d3217560
RK
409
410 &.small {
411 height: 20px;
412
413 .ui-inputswitch {
414 width: 2.5em !important;
415 height: 1.45em !important;
416
417 .ui-inputswitch-slider::before {
418 height: 1em !important;
419 width: 1em !important;
420 }
421 }
422
423 .ui-inputswitch-checked .ui-inputswitch-slider::before {
424 transform: translateX(1em) !important;
425 }
426 }
276d9652 427}
f8b2c1b4
C
428
429p-toast {
3195cd1c 430 .ui-toast {
36f2981f 431 z-index: z(notification) !important;
3195cd1c 432
21973012
RK
433 .ui-toast-close-icon {
434 font-family: "Glyphicons Halflings";
435 opacity: 0;
75264e37 436
21973012
RK
437 &:after {
438 content: "\e014";
439 }
75264e37
RK
440 }
441
21973012
RK
442 &:hover .ui-toast-close-icon {
443 opacity: .3;
75264e37
RK
444 }
445 }
446
f8b2c1b4
C
447 .ui-toast-message {
448 font-family: $main-fonts;
e66883b3
RK
449 background-color: pvar(--mainBackgroundColor) !important;
450 color: pvar(--mainForegroundColor) !important;
28c801b6
RK
451 border-radius: 5px;
452 box-sizing: border-box;
453 border: 1px solid #EBEEF5 !important;
454 box-shadow: 0 2px 12px 0 rgba(0, 0 , 0, .1);
455 overflow: hidden;
456
457 &.ui-toast-message-success .glyphicon {
458 color: #8BC34A !important;
f8b2c1b4
C
459 }
460
28c801b6
RK
461 &.ui-toast-message-error .glyphicon {
462 color: #F44336 !important;
f8b2c1b4
C
463 }
464
28c801b6
RK
465 &.ui-toast-message-warn .glyphicon {
466 color: #F1680D !important;
f8b2c1b4
C
467 }
468
28c801b6
RK
469 &.ui-toast-message-info .glyphicon {
470 color: #03A9F4 !important;
f8b2c1b4
C
471 }
472
4707f410
C
473 .notification-block {
474 display: flex;
2f1548fd
C
475 align-items: center;
476 padding: 5px;
f8b2c1b4 477
4707f410 478 .message {
6e7e63b8
C
479 flex-grow: 1;
480
4707f410
C
481 h3 {
482 font-size: 21px;
483 }
f8b2c1b4 484
4707f410
C
485 p {
486 font-size: 15px;
2f1548fd 487 margin-bottom: 0;
4707f410 488 }
f8b2c1b4 489 }
f8b2c1b4 490
4707f410
C
491 .glyphicon {
492 font-size: 32px;
4707f410
C
493 margin-right: 5px;
494 }
f8b2c1b4
C
495 }
496 }
497}
17bb716b
C
498
499.ui-widget {
500 font-family: $main-fonts !important;
501}