]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/shared/shared-main/buttons/button.component.scss
Refactor button components
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-main / buttons / button.component.scss
CommitLineData
8cbc40b2
C
1@use '_variables' as *;
2@use '_mixins' as *;
63c4db6d 3
faf7eab7
C
4@mixin responsive-label {
5 .action-button {
6 padding: 0 13px;
7 }
8
9 .button-label {
10 display: none;
11 }
db66f391
C
12
13 my-global-icon {
14 margin: 0 !important;
15 }
faf7eab7
C
16}
17
30814423
K
18:host {
19 outline: none;
b16e0cf2 20 display: inline-block;
30814423
K
21}
22
03652b31 23my-small-loader ::ng-deep .root {
b5f919ac
C
24 display: inline-block;
25 margin: 0 3px 0 0;
26 width: 20px;
27}
28
292c17b8 29a[class$=-button],
2b587cad
RK
30span[class$=-button] {
31 > span {
27bc9586 32 @include margin-left(5px);
2b587cad
RK
33 }
34}
35
cd83ea1b 36.action-button {
b16e0cf2 37 width: 100%; // useful for ellipsis, allow to define a max-width on host component
db129781 38
db66f391
C
39 &.has-icon {
40 @include button-with-icon(21px);
41 }
42
43 &.icon-only my-global-icon {
44 margin: 0 !important;
db129781 45 }
14aa8556 46}
61875048 47
db66f391
C
48.orange-button,
49.grey-button {
14aa8556 50 @include peertube-button;
14aa8556
C
51}
52
db66f391
C
53.orange-button-link,
54.grey-button-link {
14aa8556 55 @include peertube-button-link;
14aa8556
C
56}
57
db66f391
C
58.orange-button,
59.orange-button-link {
60 @include orange-button;
14aa8556
C
61}
62
db66f391 63.grey-button,
14aa8556 64.grey-button-link {
14aa8556 65 @include grey-button;
cd83ea1b 66}
b17e8d89 67
b16e0cf2
MK
68.button-label {
69 @include ellipsis;
70}
71
b17e8d89
C
72// In a table, try to minimize the space taken by this button
73@media screen and (max-width: 1400px) {
74 :host-context(td) {
faf7eab7
C
75 @include responsive-label;
76 }
77}
b17e8d89 78
faf7eab7
C
79@media screen and (max-width: $small-view) {
80 .responsive-label {
81 @include responsive-label;
b17e8d89
C
82 }
83}