]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/app/shared/shared-video-playlist/video-playlist-element-miniature.component.scss
Merge branch 'release/4.3.0' into develop
[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 }
bfbd9128
C
78 }
79
931d3430
C
80 .more,
81 my-edit-button {
27bc9586
C
82 @include margin-left(auto);
83
e2f01c47 84 justify-self: flex-end;
e2f01c47 85 cursor: pointer;
c5407d70 86 min-width: 24px;
bedf0e60 87 }
88
89 .more {
90 opacity: 0;
e2f01c47
C
91
92 &.show {
3143ae17 93 opacity: 1;
e2f01c47
C
94 }
95
96 .icon-more {
e66883b3 97 @include apply-svg-color(pvar(--greyForegroundColor));
e2f01c47
C
98
99 display: flex;
100
101 &::after {
931d3430 102 border: 0;
e2f01c47
C
103 }
104 }
da2516fd
C
105 }
106}
e2f01c47 107
5b0ec7cd
C
108.video-info-name {
109 @include ellipsis;
110
111 font-size: 18px;
112 font-weight: $font-semibold;
113 display: inline-block;
114}
115
116.video-info {
117 display: flex;
118 flex-direction: column;
119 align-self: flex-start;
120 min-width: 0;
121
122 .video-info-header {
123 display: flex;
124 align-items: baseline;
125
126 a {
127 width: auto;
128 padding-right: 5px;
129 }
130
131 .pt-badge {
132 @include margin-right(5px);
133 }
134 }
135
136 .video-info-account,
137 .video-info-timestamp {
138 color: pvar(--greyForegroundColor);
139 }
140}
141
142.video-info-account,
143.video-miniature-created-at-views {
144 font-size: 14px;
145}
146
da2516fd 147.dropdown-menu {
e2f01c47 148
da2516fd
C
149 .dropdown-item {
150 @include dropdown-with-icon-item;
e2f01c47 151
da2516fd
C
152 cursor: pointer;
153 }
e2f01c47 154
da2516fd 155 .timestamp-options {
27bc9586
C
156 @include padding-left(35px);
157
da2516fd 158 padding-top: 0;
da2516fd 159 margin-bottom: 15px;
e2f01c47 160
da2516fd
C
161 > div {
162 display: flex;
163 align-items: center;
164 margin-bottom: 5px;
165 }
166
167 my-peertube-checkbox {
27bc9586 168 @include margin-right(5px);
da2516fd
C
169 }
170
171 input {
172 @include peertube-button;
173 @include orange-button;
174
175 margin-top: 10px;
e2f01c47
C
176 }
177 }
178}
bedf0e60 179
180@mixin more-dropdown-control {
181 .video {
182 my-edit-button {
183 display: none;
184
185 + .more {
186 display: inline-flex;
187 }
188 }
189 }
190}
191
192@mixin edit-button-control {
193 .video {
194 my-edit-button {
195 display: none;
196 }
197
198 &.playing {
199 my-edit-button {
200 display: inline-flex;
201 height: max-content;
2d0d756e 202 margin: auto;
bedf0e60 203 }
204 }
205
206 my-edit-button + .more {
207 display: none;
208 }
209 }
210}
211
212@mixin edit-button-in-mobile-view {
213 .video {
214 my-edit-button {
215 ::ng-deep .action-button-edit {
216 padding: 0 13px;
217
218 .button-label {
219 display: none;
220 }
221 }
222 }
223 }
224}
225
226@media screen and (min-width: $small-view) {
227 :host-context(.expanded) {
228 @include more-dropdown-control();
229 }
230}
231
232@media screen and (max-width: $small-view) {
233 :host-context(.expanded) {
234 @include edit-button-control();
235 }
236}
237
238@media screen and (max-width: $mobile-view) {
239 :host-context(.expanded) {
240 @include edit-button-in-mobile-view();
241 }
242}
243
244@media screen and (min-width: #{$small-view + $menu-width}) {
245 :host-context(.main-col:not(.expanded)) {
246 @include more-dropdown-control();
247 }
248}
249
250@media screen and (max-width: #{$small-view + $menu-width}) {
251 :host-context(.main-col:not(.expanded)) {
252 @include edit-button-control();
253 }
254}
255
256@media screen and (max-width: #{$mobile-view + $menu-width}) {
257 :host-context(.main-col:not(.expanded)) {
258 @include edit-button-in-mobile-view();
259 }
260}