]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - client/src/sass/include/_miniature.scss
Add abuse message management in admin
[github/Chocobozzz/PeerTube.git] / client / src / sass / include / _miniature.scss
CommitLineData
830b4faf
C
1@import '_variables';
2@import '_mixins';
3
4@mixin miniature-name {
8fc02e47 5 @include ellipsis-multiline(1.1em, 2);
0c9945d9 6
830b4faf 7 transition: color 0.2s;
830b4faf 8 font-weight: $font-semibold;
e66883b3 9 color: pvar(--mainForegroundColor);
8fc02e47 10 margin-top: 10px;
830b4faf
C
11 margin-bottom: 5px;
12
13 &:hover {
14 text-decoration: none;
15 }
16
17 &.blur-filter {
18 filter: blur(3px);
19 padding-left: 4px;
20 }
21}
22
23$play-overlay-transition: 0.2s ease;
24$play-overlay-height: 26px;
25$play-overlay-width: 18px;
26
e2f01c47 27@mixin miniature-thumbnail {
830b4faf
C
28 @include disable-outline;
29
8fc02e47
C
30 display: flex;
31 flex-direction: column;
830b4faf
C
32 position: relative;
33 border-radius: 3px;
34 overflow: hidden;
e2f01c47
C
35 width: $video-thumbnail-width;
36 height: $video-thumbnail-height;
830b4faf
C
37 background-color: #ececec;
38 transition: filter $play-overlay-transition;
39
40 .play-overlay {
41 position: absolute;
42 right: 0;
43 bottom: 0;
44
c5a1ae50
C
45 width: inherit;
46 height: inherit;
830b4faf 47 opacity: 0;
41f8f620 48 background-color: rgba(0, 0, 0, 0.3);
830b4faf
C
49
50 &, .icon {
51 transition: all $play-overlay-transition;
52 }
53
54 .icon {
55 width: 0;
56 height: 0;
57
58 position: absolute;
59 left: 50%;
60 top: 50%;
61 transform: translate(-50%, -50%) scale(0.5);
62
63 border-top: ($play-overlay-height / 2) solid transparent;
64 border-bottom: ($play-overlay-height / 2) solid transparent;
65
66 border-left: $play-overlay-width solid rgba(255, 255, 255, 0.95);
67 }
68 }
69
70 &:hover {
71 text-decoration: none !important;
72
73 .play-overlay {
74 opacity: 1;
75
76 .icon {
77 transform: translate(-50%, -50%) scale(1);
78 }
79 }
80 }
81
82 &.focus-visible {
e66883b3 83 box-shadow: #{$focus-box-shadow-form} pvar(--mainColorLightest);
6a4c30de 84 outline: none;
830b4faf
C
85 }
86
87 img {
c5a1ae50
C
88 width: inherit;
89 height: inherit;
830b4faf
C
90
91 &.blur-filter {
1b8a8905 92 filter: blur(20px);
830b4faf
C
93 transform : scale(1.03);
94 }
95 }
96}
97
e2f01c47 98@mixin thumbnail-size-component ($width, $height) {
03652b31 99 ::ng-deep .video-thumbnail {
e2f01c47
C
100 width: $width;
101 height: $height;
102 }
103}
104
830b4faf
C
105@mixin static-thumbnail-overlay {
106 display: inline-block;
107 background-color: rgba(0, 0, 0, 0.7);
108 color: #fff;
109}
110
c8487f3f 111@mixin miniature-rows {
c8487f3f
C
112 &:first-child {
113 padding-top: 30px;
dc890263
C
114
115 .section-title {
116 border-top: none !important;
117 }
c8487f3f
C
118 }
119
c8487f3f
C
120 .section-title {
121 font-size: 24px;
122 font-weight: $font-semibold;
dc890263
C
123 padding-top: 15px;
124 margin-bottom: 15px;
bc01017b
C
125 display: flex;
126 justify-content: space-between;
c9e3565d
CC
127
128 &:not(h2) {
129 border-top: 1px solid $separator-border-color;
130 }
c8487f3f
C
131
132 a {
133 &:hover, &:focus:not(.focus-visible), &:active {
134 text-decoration: none;
135 outline: none;
136 }
137
e66883b3 138 color: pvar(--mainForegroundColor);
c8487f3f
C
139 }
140 }
141
142 &.channel {
143 .section-title {
144 a {
145 display: flex;
146 width: fit-content;
147 align-items: center;
148
149 img {
150 @include avatar(28px);
151
152 margin-right: 8px;
153 }
154 }
155
156 .followers {
e66883b3 157 color: pvar(--greyForegroundColor);
c8487f3f
C
158 font-weight: normal;
159 font-size: 14px;
160 margin-left: 10px;
161 position: relative;
162 top: 2px;
163 }
164 }
165 }
166
dc890263
C
167 .show-more {
168 position: relative;
169 top: -5px;
170 display: inline-block;
171 font-size: 16px;
172 text-transform: uppercase;
e66883b3 173 color: pvar(--greyForegroundColor);
dc890263
C
174 margin-bottom: 10px;
175 font-weight: $font-semibold;
25266908 176 text-decoration: none;
dc890263
C
177 }
178
c8487f3f
C
179 @media screen and (max-width: $mobile-view) {
180 max-height: initial;
181 overflow: initial;
182
c8487f3f
C
183 .section-title {
184 font-size: 17px;
cf78883c 185 margin-left: 10px;
c8487f3f
C
186 }
187 }
188}
189
cf78883c 190@mixin fluid-videos-miniature-layout {
d39db21a
RK
191 margin-left: $not-expanded-horizontal-margins !important;
192 margin-right: $not-expanded-horizontal-margins !important;
c8487f3f 193
cf78883c
C
194 @media screen and (max-width: $mobile-view) {
195 width: auto;
196 margin: 0 !important;
c8487f3f 197
cf78883c
C
198 .videos {
199 text-align: center;
c8487f3f 200
cf78883c
C
201 ::ng-deep .video-miniature {
202 padding-right: 0;
203 height: auto;
204 width: 100%;
205 margin-bottom: 25px;
c8487f3f 206
cf78883c
C
207 .video-miniature-information {
208 width: 100% !important;
209 text-align: left;
210
211 span {
212 width: 100%;
213 }
214 }
215
216 .video-thumbnail {
217 border-radius: 0;
218 }
219 }
e66883b3 220 }
cf78883c
C
221 }
222
223 @media screen and (min-width: #{breakpoint(fhd)}) {
224 margin-left: 6vw !important;
225 margin-right: 6vw !important;
226 }
c8487f3f 227
cf78883c
C
228 @media screen and (min-width: $mobile-view) {
229
230 .videos {
231 --miniature-min-width: #{$video-thumbnail-width - 15px};
232 --miniature-max-width: #{$video-thumbnail-width};
233
234 display: grid;
235 column-gap: 5px;
236 grid-template-columns: repeat(
237 auto-fill,
238 minmax(
239 var(--miniature-min-width),
240 1fr
241 )
242 );
243
244 @media screen and (min-width: #{breakpoint(fhd)}) {
245 column-gap: 1%;
246 --miniature-min-width: #{$video-thumbnail-width};
247 }
248
249 .video-wrapper {
250 margin: 0 auto;
251 width: 100%;
c8487f3f 252
cf78883c
C
253 my-video-miniature {
254 display: block;
255 min-width: var(--miniature-min-width);
256 max-width: var(--miniature-max-width);
257 }
e66883b3 258 }
c8487f3f
C
259 }
260 }
261}