]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/shared/shared-video-playlist/video-playlist-element-miniature.component.scss
Move to sass module
[github/Chocobozzz/PeerTube.git] / client / src / app / shared / shared-video-playlist / video-playlist-element-miniature.component.scss
CommitLineData
8cbc40b2
C
1@use '_variables' as *;
2@use '_mixins' as *;
3@use '_miniature' as *;
e2f01c47 4
bfbd9128
C
5$thumbnail-width: 130px;
6$thumbnail-height: 72px;
7
72675ebe 8my-video-thumbnail {
bfbd9128
C
9 @include thumbnail-size-component($thumbnail-width, $thumbnail-height);
10}
72675ebe 11
bfbd9128
C
12.fake-thumbnail {
13 width: $thumbnail-width;
14 height: $thumbnail-height;
15 background-color: #ececec;
16}
17
18my-video-thumbnail,
19.fake-thumbnail {
27bc9586
C
20 @include margin-right(10px);
21
72675ebe 22 display: flex; // Avoids an issue with line-height that adds space below the element
72675ebe
C
23}
24
e2f01c47 25.video {
2d0d756e
C
26 display: grid;
27 grid-template-columns: 1fr auto;
e66883b3 28 background-color: pvar(--mainBackgroundColor);
e2f01c47
C
29 padding: 10px;
30 border-bottom: 1px solid $separator-border-color;
31
2d0d756e
C
32 .more {
33 display: flex;
34 }
35
e2f01c47
C
36 &:hover {
37 background-color: rgba(0, 0, 0, 0.05);
38
39 .more {
3143ae17 40 opacity: 1;
e2f01c47
C
41 }
42 }
43
70afd522 44 @media not all and (hover: hover) and (pointer: fine) {
45 .more {
46 opacity: 1 !important;
47 }
48 }
49
e2f01c47
C
50 &.playing {
51 background-color: rgba(0, 0, 0, 0.02);
52 }
53
54 a {
55 @include disable-default-a-behaviour;
56
e66883b3 57 color: pvar(--mainForegroundColor);
e2f01c47 58 display: flex;
3143ae17 59 min-width: 0;
e2f01c47
C
60 align-items: center;
61 cursor: pointer;
e2f01c47
C
62
63 .position {
27bc9586
C
64 @include margin-right(10px);
65
e2f01c47 66 font-weight: $font-semibold;
e66883b3 67 color: pvar(--greyForegroundColor);
bce47964 68 min-width: 25px;
e2f01c47
C
69
70 my-global-icon {
e66883b3 71 @include apply-svg-color(pvar(--greyForegroundColor));
e2f01c47
C
72
73 width: 17px;
74 position: relative;
75 left: -2px;
76 }
77 }
78
e2f01c47
C
79 .video-info {
80 display: flex;
81 flex-direction: column;
3143ae17 82 align-self: flex-start;
e2f01c47
C
83 min-width: 0;
84
85 a {
bce47964 86 width: auto;
e2f01c47
C
87 }
88
931d3430
C
89 .video-info-account,
90 .video-info-timestamp {
e66883b3 91 color: pvar(--greyForegroundColor);
e2f01c47
C
92 }
93 }
94 }
95
bfbd9128 96 .video-info-name {
931d3430
C
97 @include ellipsis;
98
bfbd9128
C
99 font-size: 18px;
100 font-weight: $font-semibold;
101 display: inline-block;
bfbd9128
C
102 }
103
931d3430
C
104 .more,
105 my-edit-button {
27bc9586
C
106 @include margin-left(auto);
107
e2f01c47 108 justify-self: flex-end;
e2f01c47 109 cursor: pointer;
c5407d70 110 min-width: 24px;
bedf0e60 111 }
112
113 .more {
114 opacity: 0;
e2f01c47
C
115
116 &.show {
3143ae17 117 opacity: 1;
e2f01c47
C
118 }
119
120 .icon-more {
e66883b3 121 @include apply-svg-color(pvar(--greyForegroundColor));
e2f01c47
C
122
123 display: flex;
124
125 &::after {
931d3430 126 border: 0;
e2f01c47
C
127 }
128 }
da2516fd
C
129 }
130}
e2f01c47 131
da2516fd 132.dropdown-menu {
e2f01c47 133
da2516fd
C
134 .dropdown-item {
135 @include dropdown-with-icon-item;
e2f01c47 136
da2516fd
C
137 cursor: pointer;
138 }
e2f01c47 139
da2516fd 140 .timestamp-options {
27bc9586
C
141 @include padding-left(35px);
142
da2516fd 143 padding-top: 0;
da2516fd 144 margin-bottom: 15px;
e2f01c47 145
da2516fd
C
146 > div {
147 display: flex;
148 align-items: center;
149 margin-bottom: 5px;
150 }
151
152 my-peertube-checkbox {
27bc9586 153 @include margin-right(5px);
da2516fd
C
154 }
155
156 input {
157 @include peertube-button;
158 @include orange-button;
159
160 margin-top: 10px;
e2f01c47
C
161 }
162 }
163}
bedf0e60 164
165@mixin more-dropdown-control {
166 .video {
167 my-edit-button {
168 display: none;
169
170 + .more {
171 display: inline-flex;
172 }
173 }
174 }
175}
176
177@mixin edit-button-control {
178 .video {
179 my-edit-button {
180 display: none;
181 }
182
183 &.playing {
184 my-edit-button {
185 display: inline-flex;
186 height: max-content;
2d0d756e 187 margin: auto;
bedf0e60 188 }
189 }
190
191 my-edit-button + .more {
192 display: none;
193 }
194 }
195}
196
197@mixin edit-button-in-mobile-view {
198 .video {
199 my-edit-button {
200 ::ng-deep .action-button-edit {
201 padding: 0 13px;
202
203 .button-label {
204 display: none;
205 }
206 }
207 }
208 }
209}
210
211@media screen and (min-width: $small-view) {
212 :host-context(.expanded) {
213 @include more-dropdown-control();
214 }
215}
216
217@media screen and (max-width: $small-view) {
218 :host-context(.expanded) {
219 @include edit-button-control();
220 }
221}
222
223@media screen and (max-width: $mobile-view) {
224 :host-context(.expanded) {
225 @include edit-button-in-mobile-view();
226 }
227}
228
229@media screen and (min-width: #{$small-view + $menu-width}) {
230 :host-context(.main-col:not(.expanded)) {
231 @include more-dropdown-control();
232 }
233}
234
235@media screen and (max-width: #{$small-view + $menu-width}) {
236 :host-context(.main-col:not(.expanded)) {
237 @include edit-button-control();
238 }
239}
240
241@media screen and (max-width: #{$mobile-view + $menu-width}) {
242 :host-context(.main-col:not(.expanded)) {
243 @include edit-button-in-mobile-view();
244 }
245}