Implemented cover photo upload and deletion
[GitHub/WoltLab/WCF.git] / wcfsetup / install / files / style / ui / userProfile.scss
1 .userProfileUser {
2 .contentHeaderIcon {
3 position: relative;
4
5 a {
6 display: block;
7 }
8 }
9
10 .contentHeaderIcon a {
11 display: block;
12 }
13
14 .contentHeaderDescription {
15 margin-top: 20px;
16 }
17
18 @include screen-sm-md {
19 .contentHeaderNavigation {
20 .button {
21 .invisible {
22 display: inline;
23 }
24 }
25 }
26 }
27
28 @include screen-sm-down {
29 display: flex;
30 flex-wrap: wrap;
31
32 .contentHeaderNavigation {
33 flex: 0 0 100%;
34 }
35 }
36
37 @include screen-sm {
38 .contentHeaderIcon {
39 display: block;
40 flex: 0 0 96px;
41 margin-right: 15px;
42
43 img {
44 width: 96px !important;
45 height: 96px !important;
46 }
47 }
48
49 .contentHeaderTitle {
50 flex: 0 0 calc(100% - 111px);
51 max-width: calc(100% - 11px);
52 }
53 }
54
55 @include screen-xs {
56 .contentHeaderIcon {
57 display: block;
58 flex: 0 0 48px;
59 margin-right: 10px;
60
61 img {
62 width: 48px !important;
63 height: 48px !important;
64 }
65 }
66
67 .contentHeaderTitle {
68 flex: 0 0 calc(100% - 58px);
69 max-width: calc(100% - 58px);
70 }
71
72 .contentHeaderNavigation {
73 .userProfileButtonContainer {
74 display: flex;
75
76 > li {
77 flex: 1 1 auto;
78 margin-top: 0 !important;
79
80 &:not(:last-child) {
81 margin-right: 1px;
82 }
83
84 .invisible {
85 display: none !important;
86 }
87 }
88 }
89 }
90 }
91
92 @include screen-md-up {
93 .contentHeaderIcon {
94 flex: 0 0 128px;
95 margin-right: 20px;
96 }
97 }
98 }
99
100 /* user profile cover photo */
101 .userProfileUserWithCoverPhoto {
102 padding-top: 165px;
103 position: relative;
104
105 .userProfileCoverPhoto {
106 background: no-repeat center;
107 background-size: cover;
108 border-radius: 3px;
109 height: 200px;
110 left: 0;
111 position: absolute;
112 right: 0;
113 top: 0;
114
115 &::after {
116 background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 70%, rgba(0, 0, 0, .5) 100%);
117 border-bottom-left-radius: 3px;
118 border-bottom-right-radius: 3px;
119 bottom: 0;
120 content: "";
121 display: block;
122 left: 0;
123 pointer-events: none;
124 position: absolute;
125 right: 0;
126 top: 0;
127 }
128
129 .userProfileManageCoverPhoto {
130 position: absolute;
131 right: 10px;
132 top: 10px;
133 }
134 }
135
136 .contentHeaderTitle {
137 /* avoid being covered by the photo */
138 z-index: 10;
139 }
140
141 .userProfileUsername {
142 color: #fff;
143 text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.6);
144 }
145
146 @include screen-md-up {
147 .contentHeaderIcon {
148 flex: 0 0 138px;
149 margin-top: -29px; /* 35px photo overlap - (128px height / 2) */
150 padding-left: 10px;
151 }
152
153 .contentHeaderDescription {
154 margin-top: 15px !important;
155 }
156
157 .contentHeaderNavigation {
158 padding-top: 45px;
159 }
160 }
161
162 @include screen-sm-up {
163 .contentHeaderIcon .badgeOnline {
164 left: 10px !important;
165 }
166
167 .userProfileUsername + .badge {
168 margin-left: 5px;
169 }
170 }
171
172 @include screen-sm {
173 padding-top: 170px;
174
175 .contentHeaderIcon {
176 margin-top: -18px; /* 30px photo overlap - (96px height / 2) */
177 padding-left: 5px;
178 }
179
180 .contentHeaderDescription {
181 margin-top: 10px !important;
182 }
183 }
184
185 @include screen-xs {
186 padding-top: 120px;
187
188 .userProfileCoverPhoto {
189 height: 150px;
190 }
191
192 .contentHeaderIcon {
193 margin-top: 6px; /* 30px photo overlap - (48px height / 2) */
194 padding-left: 5px;
195 }
196
197 .contentTitle {
198 margin-bottom: 35px;
199 position: relative;
200 }
201
202 .userProfileUsername {
203 display: block;
204 }
205
206 .userProfileUsername + .badge {
207 margin-left: 0;
208 position: absolute;
209 top: 35px !important;
210 }
211
212 .contentHeaderDescription {
213 margin-left: -58px;
214 }
215 }
216 }
217
218 .userTitleBadge {
219 max-width: 154px;
220 overflow: hidden;
221 text-overflow: ellipsis;
222 }
223
224 .userAvatarImage {
225 background-color: #fff;
226 border-radius: 50%;
227 }
228
229 .userAvatarList {
230 display: flex;
231 flex-wrap: wrap;
232 margin-bottom: -10px;
233
234 > li {
235 flex: 0 0 48px;
236 margin-bottom: 10px;
237 text-align: center;
238
239 &:not(:last-child) {
240 margin-right: -12px;
241 }
242
243 > a {
244 display: block;
245
246 > img {
247 border: 2px solid #fff;
248 }
249 }
250 }
251
252 &.small {
253 > li {
254 flex: 0 0 24px;
255
256 &:not(:last-child) {
257 margin-right: -6px;
258 }
259
260 > a {
261 > img {
262 border: 1px solid #fff;
263 }
264 }
265 }
266 }
267 }
268
269 .userList {
270 .box48 {
271 align-items: center;
272 }
273 }
274
275 .userProfilePreview {
276 position: relative;
277
278 .userInformation {
279 padding-bottom: 16px;
280 }
281
282 .buttonGroupNavigation {
283 position: absolute;
284 bottom: 0;
285 right: 0;
286 }
287 }
288
289 /* using `dl` + `.inlineDataList` to prevent styles applied to the
290 data list provided by the `userInformation` template */
291 .userProfilePreview dl.inlineDataList {
292 margin-top: 10px;
293
294 @include wcfFontSmall;
295 }
296
297 /* user notifications */
298 .userNotificationItemList > .notificationItem {
299 &.notificationUnconfirmed {
300 align-items: center;
301 display: flex;
302
303 > .box32 {
304 flex: 1 1 auto;
305 }
306
307 > .notificationItemMarkAsConfirmed {
308 flex: 0 0 auto;
309 }
310 }
311 }
312
313 .userProfilePreviewAvatar {
314 align-self: flex-start;
315 display: block;
316 position: relative;
317 }
318
319 .userProfilePreviewAvatar .badgeOnline,
320 .userProfileUser .contentHeaderIcon .badgeOnline {
321 left: 0;
322 pointer-events: none;
323 position: absolute;
324
325 @include screen-md-up {
326 bottom: 0;
327 }
328
329 @include screen-sm-down {
330 color: transparent;
331 padding: 0;
332 top: 0;
333 width: 0;
334
335 &::before {
336 background-color: inherit;
337 border: 1px solid rgba(255, 255, 255, 1);
338 border-radius: 50%;
339 content: "";
340 height: 16px;
341 left: 34px; /* 48px (avatar) - 16px (width) - 2px (border-left + border-right) */
342 position: absolute;
343 width: 16px;
344 }
345 }
346 }