Commit 5088d69
committed
Tabbed interface: Use flexbox for tab markers
Previously, in medium view and over, if any tab markers wrapped across multiple lines, "short" tab markers behaved strangely compared to "tall" ones.
Specifically:
* Short tab markers didn't use 100% height and looked bottom-aligned
* If the active tab used a short tab marker:
* The marker's thick top grey border wasn't top-aligned (vs tall tab markers)
* A thin grey border appeared above the marker
* The "linked area" of inactive short tab markers was misleading (looked as if marker links used 100% height, but didn't really):
* Caused by hover/focus effects (like background colours and cursor: pointer;) being set on li elements instead of a elements.
This resolves it by:
* Adding a second line to the third tab marker ("Example 3"/"Exemple 3") in the tabbed interface demo's first example
* Adjusting tab markers to use flexbox (to make short tab markers match the height/alignment of tall ones)
* Adjusting margins where necessary
* Tying hover/focus styles solely to links (not their parent elements)
* Removing irrelevant hover/focus styles (e.g. cursor properties, placeholder selector for a hidden element)
Notes:
* Flexbox changed carousel spacing slightly (for the better):
* Carousel style 1:
* Removed 10px space above the carousel
* Reduced spacing between the next and play/pause buttons from 10px to 5px
* Carousel style 2:
* Added 10px space between previous button and tab counter (matches space between counter and next button) (deliberate change)
* Fully-aligned play/pause button to the right (previously had extra space on the far right side)
* Added hover background colour to "show-thumbs" class' thumbnails (byproduct of hover/focus style changes)1 parent 5c0d9c5 commit 5088d69
3 files changed
Lines changed: 32 additions & 55 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | 144 | | |
150 | 145 | | |
151 | 146 | | |
| |||
208 | 203 | | |
209 | 204 | | |
210 | 205 | | |
211 | | - | |
| 206 | + | |
212 | 207 | | |
213 | 208 | | |
214 | 209 | | |
| |||
220 | 215 | | |
221 | 216 | | |
222 | 217 | | |
223 | | - | |
224 | | - | |
225 | | - | |
| 218 | + | |
226 | 219 | | |
227 | 220 | | |
228 | 221 | | |
| |||
239 | 232 | | |
240 | 233 | | |
241 | 234 | | |
242 | | - | |
243 | 235 | | |
244 | | - | |
245 | | - | |
246 | | - | |
247 | | - | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
248 | 241 | | |
249 | 242 | | |
250 | 243 | | |
251 | | - | |
252 | | - | |
253 | | - | |
254 | | - | |
255 | | - | |
256 | | - | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | 244 | | |
262 | 245 | | |
263 | 246 | | |
264 | 247 | | |
265 | 248 | | |
266 | 249 | | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
267 | 260 | | |
268 | 261 | | |
269 | 262 | | |
| |||
288 | 281 | | |
289 | 282 | | |
290 | 283 | | |
| 284 | + | |
291 | 285 | | |
292 | | - | |
293 | | - | |
294 | | - | |
295 | | - | |
296 | | - | |
| 286 | + | |
| 287 | + | |
297 | 288 | | |
298 | 289 | | |
299 | 290 | | |
| |||
348 | 339 | | |
349 | 340 | | |
350 | 341 | | |
351 | | - | |
352 | | - | |
353 | | - | |
354 | | - | |
355 | 342 | | |
356 | 343 | | |
357 | 344 | | |
358 | 345 | | |
359 | 346 | | |
360 | | - | |
361 | | - | |
362 | | - | |
363 | | - | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
373 | | - | |
374 | | - | |
375 | 347 | | |
376 | 348 | | |
377 | 349 | | |
| |||
444 | 416 | | |
445 | 417 | | |
446 | 418 | | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
447 | 423 | | |
448 | 424 | | |
449 | 425 | | |
| |||
470 | 446 | | |
471 | 447 | | |
472 | 448 | | |
473 | | - | |
| 449 | + | |
474 | 450 | | |
475 | 451 | | |
| 452 | + | |
476 | 453 | | |
477 | 454 | | |
478 | 455 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
| 59 | + | |
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| |||
0 commit comments