diff options
Diffstat (limited to 'client/src/sass')
-rw-r--r-- | client/src/sass/application.scss | 118 | ||||
-rw-r--r-- | client/src/sass/bootstrap.scss | 138 | ||||
-rw-r--r-- | client/src/sass/include/_miniature.scss | 97 | ||||
-rw-r--r-- | client/src/sass/include/_mixins.scss | 25 | ||||
-rw-r--r-- | client/src/sass/include/_variables.scss | 4 | ||||
-rw-r--r-- | client/src/sass/player/_player-variables.scss | 8 | ||||
-rw-r--r-- | client/src/sass/player/context-menu.scss | 4 | ||||
-rw-r--r-- | client/src/sass/player/peertube-skin.scss | 12 | ||||
-rw-r--r-- | client/src/sass/player/settings-menu.scss | 2 |
9 files changed, 269 insertions, 139 deletions
diff --git a/client/src/sass/application.scss b/client/src/sass/application.scss index d84766240..c64a8ebf8 100644 --- a/client/src/sass/application.scss +++ b/client/src/sass/application.scss | |||
@@ -12,6 +12,7 @@ $assets-path: '../assets/'; | |||
12 | @import './player/index'; | 12 | @import './player/index'; |
13 | @import './loading-bar'; | 13 | @import './loading-bar'; |
14 | 14 | ||
15 | @import './bootstrap'; | ||
15 | @import './primeng-custom'; | 16 | @import './primeng-custom'; |
16 | 17 | ||
17 | [hidden] { | 18 | [hidden] { |
@@ -181,128 +182,11 @@ label { | |||
181 | font-weight: bold; | 182 | font-weight: bold; |
182 | } | 183 | } |
183 | 184 | ||
184 | // Thanks https://gist.github.com/alexandrevicenzi/680147013e902a4eaa5d | ||
185 | .glyphicon-refresh-animate { | ||
186 | animation: spin .7s infinite linear; | ||
187 | } | ||
188 | |||
189 | @keyframes spin { | 185 | @keyframes spin { |
190 | from { transform: scale(1) rotate(0deg);} | 186 | from { transform: scale(1) rotate(0deg);} |
191 | to { transform: scale(1) rotate(360deg);} | 187 | to { transform: scale(1) rotate(360deg);} |
192 | } | 188 | } |
193 | 189 | ||
194 | // Bootstrap customizations | ||
195 | .dropdown-menu { | ||
196 | border-radius: 3px; | ||
197 | box-shadow: 0 3px 6px; | ||
198 | font-size: 15px; | ||
199 | |||
200 | .dropdown-item { | ||
201 | padding: 3px 15px; | ||
202 | |||
203 | &:active { | ||
204 | color: #000 !important; | ||
205 | } | ||
206 | } | ||
207 | |||
208 | button { | ||
209 | @include disable-default-a-behaviour; | ||
210 | } | ||
211 | |||
212 | a { | ||
213 | @include disable-default-a-behaviour; | ||
214 | color: #000 !important; | ||
215 | } | ||
216 | } | ||
217 | |||
218 | .modal { | ||
219 | .modal-content { | ||
220 | background-color: var(--mainBackgroundColor); | ||
221 | } | ||
222 | |||
223 | .modal-header { | ||
224 | border-bottom: none; | ||
225 | margin-bottom: 5px; | ||
226 | |||
227 | .modal-title { | ||
228 | font-size: 20px; | ||
229 | font-weight: $font-semibold; | ||
230 | } | ||
231 | |||
232 | my-global-icon { | ||
233 | @include icon(24px); | ||
234 | |||
235 | position: relative; | ||
236 | top: 3px; | ||
237 | float: right; | ||
238 | |||
239 | margin: 0; | ||
240 | padding: 0; | ||
241 | opacity: 1; | ||
242 | } | ||
243 | } | ||
244 | |||
245 | .inputs { | ||
246 | margin-bottom: 0; | ||
247 | text-align: right; | ||
248 | |||
249 | .action-button-cancel { | ||
250 | @include peertube-button; | ||
251 | @include grey-button; | ||
252 | |||
253 | display: inline-block; | ||
254 | margin-right: 10px; | ||
255 | } | ||
256 | |||
257 | .action-button-submit { | ||
258 | @include peertube-button; | ||
259 | @include orange-button; | ||
260 | } | ||
261 | } | ||
262 | } | ||
263 | |||
264 | // Nav customizations | ||
265 | .nav .nav-link { | ||
266 | display: flex !important; | ||
267 | align-items: center; | ||
268 | height: 30px !important; | ||
269 | padding: 10px 15px !important; | ||
270 | } | ||
271 | |||
272 | .nav.nav-pills { | ||
273 | font-size: 16px !important; | ||
274 | |||
275 | .nav-link.active { | ||
276 | font-weight: $font-semibold !important; | ||
277 | } | ||
278 | |||
279 | a { | ||
280 | @include disable-default-a-behaviour; | ||
281 | |||
282 | color: var(--mainForegroundColor); | ||
283 | } | ||
284 | } | ||
285 | |||
286 | ngb-tabset.bootstrap { | ||
287 | |||
288 | .nav-link { | ||
289 | &, & a { | ||
290 | @include disable-default-a-behaviour; | ||
291 | |||
292 | color: var(--mainForegroundColor) !important; | ||
293 | } | ||
294 | } | ||
295 | |||
296 | .nav-pills .nav-link.active { | ||
297 | color: #000 !important; | ||
298 | } | ||
299 | } | ||
300 | |||
301 | .nav-tabs .nav-link.active { | ||
302 | background-color: var(--mainBackgroundColor) !important; | ||
303 | border-bottom: none; | ||
304 | } | ||
305 | |||
306 | .orange-button { | 190 | .orange-button { |
307 | @include peertube-button; | 191 | @include peertube-button; |
308 | @include orange-button; | 192 | @include orange-button; |
diff --git a/client/src/sass/bootstrap.scss b/client/src/sass/bootstrap.scss new file mode 100644 index 000000000..12e73278a --- /dev/null +++ b/client/src/sass/bootstrap.scss | |||
@@ -0,0 +1,138 @@ | |||
1 | $icon-font-path: '~@neos21/bootstrap3-glyphicons/assets/fonts/'; | ||
2 | @import '_bootstrap'; | ||
3 | |||
4 | @import '_variables'; | ||
5 | @import '_mixins'; | ||
6 | |||
7 | // Thanks https://gist.github.com/alexandrevicenzi/680147013e902a4eaa5d | ||
8 | .glyphicon-refresh-animate { | ||
9 | animation: spin .7s infinite linear; | ||
10 | } | ||
11 | |||
12 | @keyframes spin { | ||
13 | from { transform: scale(1) rotate(0deg);} | ||
14 | to { transform: scale(1) rotate(360deg);} | ||
15 | } | ||
16 | |||
17 | .dropdown-menu { | ||
18 | border-radius: 3px; | ||
19 | box-shadow: 0 3px 6px; | ||
20 | font-size: 15px; | ||
21 | |||
22 | .dropdown-item { | ||
23 | padding: 3px 15px; | ||
24 | |||
25 | &:active { | ||
26 | color: #000 !important; | ||
27 | } | ||
28 | } | ||
29 | |||
30 | button { | ||
31 | @include disable-default-a-behaviour; | ||
32 | } | ||
33 | |||
34 | a { | ||
35 | @include disable-default-a-behaviour; | ||
36 | color: #000 !important; | ||
37 | } | ||
38 | } | ||
39 | |||
40 | .modal { | ||
41 | .modal-content { | ||
42 | background-color: var(--mainBackgroundColor); | ||
43 | } | ||
44 | |||
45 | .modal-header { | ||
46 | border-bottom: none; | ||
47 | margin-bottom: 5px; | ||
48 | |||
49 | .modal-title { | ||
50 | font-size: 20px; | ||
51 | font-weight: $font-semibold; | ||
52 | } | ||
53 | |||
54 | my-global-icon { | ||
55 | @include icon(24px); | ||
56 | |||
57 | position: relative; | ||
58 | top: 3px; | ||
59 | float: right; | ||
60 | |||
61 | margin: 0; | ||
62 | padding: 0; | ||
63 | opacity: 1; | ||
64 | } | ||
65 | } | ||
66 | |||
67 | .inputs { | ||
68 | margin-bottom: 0; | ||
69 | text-align: right; | ||
70 | |||
71 | .action-button-cancel { | ||
72 | @include peertube-button; | ||
73 | @include grey-button; | ||
74 | |||
75 | display: inline-block; | ||
76 | margin-right: 10px; | ||
77 | } | ||
78 | |||
79 | .action-button-submit { | ||
80 | @include peertube-button; | ||
81 | @include orange-button; | ||
82 | } | ||
83 | } | ||
84 | } | ||
85 | |||
86 | // Nav customizations | ||
87 | .nav .nav-link { | ||
88 | display: flex !important; | ||
89 | align-items: center; | ||
90 | height: 30px !important; | ||
91 | padding: 10px 15px !important; | ||
92 | } | ||
93 | |||
94 | .nav.nav-pills { | ||
95 | font-size: 16px !important; | ||
96 | |||
97 | .nav-link.active { | ||
98 | font-weight: $font-semibold !important; | ||
99 | } | ||
100 | |||
101 | a { | ||
102 | @include disable-default-a-behaviour; | ||
103 | |||
104 | color: var(--mainForegroundColor); | ||
105 | } | ||
106 | } | ||
107 | |||
108 | ngb-tabset.bootstrap { | ||
109 | |||
110 | .nav-link { | ||
111 | &, & a { | ||
112 | @include disable-default-a-behaviour; | ||
113 | |||
114 | color: var(--mainForegroundColor) !important; | ||
115 | } | ||
116 | } | ||
117 | |||
118 | .nav-pills .nav-link.active { | ||
119 | color: #000 !important; | ||
120 | } | ||
121 | } | ||
122 | |||
123 | .nav-tabs .nav-link.active { | ||
124 | background-color: var(--mainBackgroundColor) !important; | ||
125 | border-bottom: none; | ||
126 | } | ||
127 | |||
128 | .collapse-transition { | ||
129 | // Animation when we show/hide the filters | ||
130 | transition: max-height 0.3s; | ||
131 | display: block !important; | ||
132 | overflow: hidden !important; | ||
133 | max-height: 0; | ||
134 | |||
135 | &.show { | ||
136 | max-height: 1500px; | ||
137 | } | ||
138 | } | ||
diff --git a/client/src/sass/include/_miniature.scss b/client/src/sass/include/_miniature.scss index b62187fd2..0c2ee2d0d 100644 --- a/client/src/sass/include/_miniature.scss +++ b/client/src/sass/include/_miniature.scss | |||
@@ -138,3 +138,100 @@ $play-overlay-width: 18px; | |||
138 | } | 138 | } |
139 | } | 139 | } |
140 | } | 140 | } |
141 | |||
142 | @mixin miniature-rows { | ||
143 | max-height: 540px; // 2 rows max | ||
144 | overflow: hidden; | ||
145 | padding-top: 10px; | ||
146 | |||
147 | &:first-child { | ||
148 | padding-top: 30px; | ||
149 | } | ||
150 | |||
151 | my-video-miniature { | ||
152 | text-align: left; | ||
153 | } | ||
154 | |||
155 | .section-title { | ||
156 | font-size: 24px; | ||
157 | font-weight: $font-semibold; | ||
158 | margin-bottom: 30px; | ||
159 | display: flex; | ||
160 | justify-content: space-between; | ||
161 | |||
162 | a { | ||
163 | &:hover, &:focus:not(.focus-visible), &:active { | ||
164 | text-decoration: none; | ||
165 | outline: none; | ||
166 | } | ||
167 | |||
168 | color: var(--mainForegroundColor); | ||
169 | } | ||
170 | } | ||
171 | |||
172 | &.channel { | ||
173 | .section-title { | ||
174 | a { | ||
175 | display: flex; | ||
176 | width: fit-content; | ||
177 | align-items: center; | ||
178 | |||
179 | img { | ||
180 | @include avatar(28px); | ||
181 | |||
182 | margin-right: 8px; | ||
183 | } | ||
184 | } | ||
185 | |||
186 | .followers { | ||
187 | color: $grey-foreground-color; | ||
188 | font-weight: normal; | ||
189 | font-size: 14px; | ||
190 | margin-left: 10px; | ||
191 | position: relative; | ||
192 | top: 2px; | ||
193 | } | ||
194 | } | ||
195 | } | ||
196 | |||
197 | @media screen and (max-width: $mobile-view) { | ||
198 | max-height: initial; | ||
199 | overflow: initial; | ||
200 | |||
201 | @include video-miniature-small-screen; | ||
202 | |||
203 | .section-title { | ||
204 | font-size: 17px; | ||
205 | } | ||
206 | } | ||
207 | } | ||
208 | |||
209 | @mixin adapt-margin-content-width { | ||
210 | width: $video-miniature-width * 6; | ||
211 | margin: auto !important; | ||
212 | |||
213 | @media screen and (max-width: 1800px) { | ||
214 | width: $video-miniature-width * 5; | ||
215 | } | ||
216 | |||
217 | @media screen and (max-width: 1800px - $video-miniature-width) { | ||
218 | width: $video-miniature-width * 4; | ||
219 | } | ||
220 | |||
221 | @media screen and (max-width: 1800px - (2* $video-miniature-width)) { | ||
222 | width: $video-miniature-width * 3; | ||
223 | } | ||
224 | |||
225 | @media screen and (max-width: 1800px - (3* $video-miniature-width)) { | ||
226 | width: $video-miniature-width * 2; | ||
227 | } | ||
228 | |||
229 | @media screen and (max-width: 500px) { | ||
230 | width: auto; | ||
231 | margin: 0 !important; | ||
232 | |||
233 | .videos { | ||
234 | @include video-miniature-small-screen; | ||
235 | } | ||
236 | } | ||
237 | } | ||
diff --git a/client/src/sass/include/_mixins.scss b/client/src/sass/include/_mixins.scss index 262a8136f..f608e9299 100644 --- a/client/src/sass/include/_mixins.scss +++ b/client/src/sass/include/_mixins.scss | |||
@@ -235,6 +235,14 @@ | |||
235 | position: relative; | 235 | position: relative; |
236 | font-size: 15px; | 236 | font-size: 15px; |
237 | 237 | ||
238 | &.disabled { | ||
239 | background-color: #E5E5E5; | ||
240 | |||
241 | select { | ||
242 | cursor: default; | ||
243 | } | ||
244 | } | ||
245 | |||
238 | @media screen and (max-width: $width) { | 246 | @media screen and (max-width: $width) { |
239 | width: 100%; | 247 | width: 100%; |
240 | } | 248 | } |
@@ -282,16 +290,6 @@ | |||
282 | } | 290 | } |
283 | } | 291 | } |
284 | 292 | ||
285 | @mixin peertube-select-disabled-container ($width) { | ||
286 | @include peertube-select-container($width); | ||
287 | |||
288 | background-color: #E5E5E5; | ||
289 | |||
290 | select { | ||
291 | cursor: default; | ||
292 | } | ||
293 | } | ||
294 | |||
295 | // Thanks: https://codepen.io/triss90/pen/XNEdRe/ | 293 | // Thanks: https://codepen.io/triss90/pen/XNEdRe/ |
296 | @mixin peertube-radio-container { | 294 | @mixin peertube-radio-container { |
297 | input[type="radio"] { | 295 | input[type="radio"] { |
@@ -331,7 +329,12 @@ | |||
331 | } | 329 | } |
332 | 330 | ||
333 | @mixin peertube-checkbox ($border-width) { | 331 | @mixin peertube-checkbox ($border-width) { |
334 | display: none; | 332 | opacity: 0; |
333 | position: absolute; | ||
334 | |||
335 | &:focus + span { | ||
336 | outline: 1px solid #1e5180; | ||
337 | } | ||
335 | 338 | ||
336 | & + span { | 339 | & + span { |
337 | position: relative; | 340 | position: relative; |
diff --git a/client/src/sass/include/_variables.scss b/client/src/sass/include/_variables.scss index c7b205b11..aafeda257 100644 --- a/client/src/sass/include/_variables.scss +++ b/client/src/sass/include/_variables.scss | |||
@@ -71,7 +71,9 @@ $variables: ( | |||
71 | --menuForegroundColor: var(--menuForegroundColor), | 71 | --menuForegroundColor: var(--menuForegroundColor), |
72 | --submenuColor: var(--submenuColor), | 72 | --submenuColor: var(--submenuColor), |
73 | --inputColor: var(--inputColor), | 73 | --inputColor: var(--inputColor), |
74 | --inputPlaceholderColor: var(--inputPlaceholderColor) | 74 | --inputPlaceholderColor: var(--inputPlaceholderColor), |
75 | --embedForegroundColor: var(--embedForegroundColor), | ||
76 | --embedBigPlayBackgroundColor: var(--embedBigPlayBackgroundColor) | ||
75 | ); | 77 | ); |
76 | 78 | ||
77 | /*** theme helper ***/ | 79 | /*** theme helper ***/ |
diff --git a/client/src/sass/player/_player-variables.scss b/client/src/sass/player/_player-variables.scss index 110129790..4e9e8736c 100644 --- a/client/src/sass/player/_player-variables.scss +++ b/client/src/sass/player/_player-variables.scss | |||
@@ -10,4 +10,10 @@ $slider-bg-color: lighten($primary-background-color, 33%); | |||
10 | 10 | ||
11 | $progress-margin: 10px; | 11 | $progress-margin: 10px; |
12 | 12 | ||
13 | $assets-path: '../../assets/' !default; \ No newline at end of file | 13 | $assets-path: '../../assets/' !default; |
14 | |||
15 | body { | ||
16 | --embedForegroundColor: #{$primary-foreground-color}; | ||
17 | |||
18 | --embedBigPlayBackgroundColor: #{$primary-background-color}; | ||
19 | } | ||
diff --git a/client/src/sass/player/context-menu.scss b/client/src/sass/player/context-menu.scss index 71d6d1b1d..eeab0ccdf 100644 --- a/client/src/sass/player/context-menu.scss +++ b/client/src/sass/player/context-menu.scss | |||
@@ -14,7 +14,7 @@ $context-menu-width: 350px; | |||
14 | 14 | ||
15 | .vjs-menu-content { | 15 | .vjs-menu-content { |
16 | opacity: $primary-foreground-opacity; | 16 | opacity: $primary-foreground-opacity; |
17 | color: $primary-foreground-color; | 17 | color: var(--embedForegroundCsolor); |
18 | font-size: $font-size !important; | 18 | font-size: $font-size !important; |
19 | font-weight: $font-semibold; | 19 | font-weight: $font-semibold; |
20 | } | 20 | } |
@@ -30,4 +30,4 @@ $context-menu-width: 350px; | |||
30 | background-color: rgba(255, 255, 255, 0.2); | 30 | background-color: rgba(255, 255, 255, 0.2); |
31 | } | 31 | } |
32 | } | 32 | } |
33 | } \ No newline at end of file | 33 | } |
diff --git a/client/src/sass/player/peertube-skin.scss b/client/src/sass/player/peertube-skin.scss index e63a2875c..996024ade 100644 --- a/client/src/sass/player/peertube-skin.scss +++ b/client/src/sass/player/peertube-skin.scss | |||
@@ -10,9 +10,8 @@ | |||
10 | } | 10 | } |
11 | 11 | ||
12 | .video-js.vjs-peertube-skin { | 12 | .video-js.vjs-peertube-skin { |
13 | |||
14 | font-size: $font-size; | 13 | font-size: $font-size; |
15 | color: $primary-foreground-color; | 14 | color: var(--embedForegroundColor); |
16 | 15 | ||
17 | .vjs-dock-text { | 16 | .vjs-dock-text { |
18 | padding-right: 10px; | 17 | padding-right: 10px; |
@@ -114,7 +113,7 @@ | |||
114 | .vjs-control-bar, | 113 | .vjs-control-bar, |
115 | .vjs-big-play-button, | 114 | .vjs-big-play-button, |
116 | .vjs-settings-dialog { | 115 | .vjs-settings-dialog { |
117 | background-color: rgba($primary-background-color, 0.5); | 116 | background-color: var(--embedBigPlayBackgroundColor); |
118 | } | 117 | } |
119 | 118 | ||
120 | .vjs-poster { | 119 | .vjs-poster { |
@@ -139,7 +138,8 @@ | |||
139 | .vjs-theater-control, | 138 | .vjs-theater-control, |
140 | .vjs-settings | 139 | .vjs-settings |
141 | { | 140 | { |
142 | color: $primary-foreground-color !important; | 141 | color: var(--embedForegroundColor) !important; |
142 | |||
143 | opacity: $primary-foreground-opacity; | 143 | opacity: $primary-foreground-opacity; |
144 | transition: opacity .1s; | 144 | transition: opacity .1s; |
145 | 145 | ||
@@ -151,7 +151,7 @@ | |||
151 | .vjs-current-time, | 151 | .vjs-current-time, |
152 | .vjs-duration, | 152 | .vjs-duration, |
153 | .vjs-peertube { | 153 | .vjs-peertube { |
154 | color: $primary-foreground-color; | 154 | color: var(--embedForegroundColor); |
155 | opacity: $primary-foreground-opacity; | 155 | opacity: $primary-foreground-opacity; |
156 | } | 156 | } |
157 | 157 | ||
@@ -171,7 +171,7 @@ | |||
171 | transition: none; | 171 | transition: none; |
172 | 172 | ||
173 | .vjs-play-progress { | 173 | .vjs-play-progress { |
174 | background: $primary-foreground-color; | 174 | background: var(--embedForegroundColor); |
175 | 175 | ||
176 | // Not display the circle if the progress is not hovered | 176 | // Not display the circle if the progress is not hovered |
177 | &::before { | 177 | &::before { |
diff --git a/client/src/sass/player/settings-menu.scss b/client/src/sass/player/settings-menu.scss index 61965c85e..83407b445 100644 --- a/client/src/sass/player/settings-menu.scss +++ b/client/src/sass/player/settings-menu.scss | |||
@@ -38,7 +38,7 @@ $setting-transition-easing: ease-out; | |||
38 | position: absolute; | 38 | position: absolute; |
39 | right: .5em; | 39 | right: .5em; |
40 | bottom: 3.5em; | 40 | bottom: 3.5em; |
41 | color: $primary-foreground-color; | 41 | color: var(--embedForegroundColor); |
42 | opacity: $primary-foreground-opacity; | 42 | opacity: $primary-foreground-opacity; |
43 | margin: 0 auto; | 43 | margin: 0 auto; |
44 | font-size: $font-size !important; | 44 | font-size: $font-size !important; |