|
1 | 1 | /* https://github.com/vuejs/vitepress/blob/main/src/client/theme-default/styles/vars.css */ |
2 | 2 | :root { |
3 | | - --vp-home-hero-name-color: #2C68C0; |
| 3 | + --vp-home-hero-name-color: #2c68c0; |
4 | 4 | --vp-home-hero-name-color: transparent; |
5 | | - --vp-home-hero-name-background: -webkit-linear-gradient(15deg, #2C68C0, #5DAC41); |
| 5 | + --vp-home-hero-name-background: -webkit-linear-gradient( |
| 6 | + 15deg, |
| 7 | + #2c68c0, |
| 8 | + #5dac41 |
| 9 | + ); |
6 | 10 |
|
7 | | - --vp-c-brand-1: #2C68C0; |
8 | | - --vp-c-brand-2: #5DAC41; |
| 11 | + --vp-c-brand-1: #2c68c0; |
| 12 | + --vp-c-brand-2: #5dac41; |
9 | 13 | } |
10 | 14 |
|
11 | 15 | .home-wrapper { |
|
15 | 19 | padding: 32px 48px 96px; |
16 | 20 | max-width: 1152px; |
17 | 21 | } |
| 22 | + |
| 23 | +.blog-hex-gallery { |
| 24 | + position: relative; |
| 25 | + height: calc(var(--max-blog-y) * var(--grid-width)); |
| 26 | + transition: transform 150ms ease-out; |
| 27 | + filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2)); |
| 28 | + width: calc(5 * var(--grid-width)); |
| 29 | + margin: 3rem auto; |
| 30 | + --grid-width: 90px; |
| 31 | +} |
| 32 | + |
| 33 | +@media (min-width: 640px) { |
| 34 | + .blog-hex-gallery { |
| 35 | + --grid-width: 100px; |
| 36 | + } |
| 37 | +} |
| 38 | + |
| 39 | +@media (min-width: 960px) { |
| 40 | + .blog-hex-gallery { |
| 41 | + --grid-width: 140px; |
| 42 | + } |
| 43 | +} |
| 44 | + |
| 45 | +.blog-item { |
| 46 | + position: relative; |
| 47 | + transition: filter 250ms ease-out; |
| 48 | + animation: fade-in 350ms cubic-bezier(0.215, 0.61, 0.355, 1) 0.1s backwards; |
| 49 | +} |
| 50 | + |
| 51 | +.blog-item:hover { |
| 52 | + filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4)); |
| 53 | + z-index: 3; |
| 54 | +} |
| 55 | + |
| 56 | +.blog-link { |
| 57 | + position: absolute; |
| 58 | + --transform: perspective(75em) |
| 59 | + translate(calc(var(--x) * 100%), calc(var(--y) * 86.67%)) scale(1.145); |
| 60 | + transform: var(--transform); |
| 61 | + transition: transform 250ms ease-out; |
| 62 | + clip-path: polygon( |
| 63 | + 50% 100%, |
| 64 | + 93.3% 75%, |
| 65 | + 93.3% 25%, |
| 66 | + 50% 0%, |
| 67 | + 6.7% 25%, |
| 68 | + 6.7% 75% |
| 69 | + ); |
| 70 | +} |
| 71 | + |
| 72 | +.blog-link:hover { |
| 73 | + transform: var(--transform) scale(1.1); |
| 74 | +} |
| 75 | + |
| 76 | +.blog-hex-gallery img { |
| 77 | + aspect-ratio: 1; |
| 78 | + object-fit: cover; |
| 79 | + width: var(--grid-width); |
| 80 | +} |
| 81 | + |
| 82 | +@keyframes fade-in { |
| 83 | + from { |
| 84 | + filter: blur(20px); |
| 85 | + opacity: 0; |
| 86 | + } |
| 87 | +} |
0 commit comments