|
23 | 23 |
|
24 | 24 | .event-popup__arrow { |
25 | 25 | position: absolute; |
26 | | - width: 0; |
27 | | - height: 0; |
28 | | - border-left: 8px solid transparent; |
29 | | - border-right: 8px solid transparent; |
30 | | - border-bottom: 10px solid var(--bg-color-alt, #fff); |
31 | | - top: -10px; |
| 26 | + width: 24px; |
| 27 | + height: 16px; |
| 28 | + left: calc(50% - 12px); |
| 29 | + top: -8px; |
| 30 | + pointer-events: none; |
32 | 31 | transform-origin: center; |
33 | | - filter: drop-shadow(0 10px 18px rgba(16, 24, 40, 0.08)); |
34 | | - transform: translateY(8px); |
35 | 32 | opacity: 0; |
| 33 | + |
| 34 | + &::before { |
| 35 | + content: ""; |
| 36 | + position: absolute; |
| 37 | + left: 0; |
| 38 | + top: 0; |
| 39 | + width: 0; |
| 40 | + height: 0; |
| 41 | + border-left: 12px solid transparent; |
| 42 | + border-right: 12px solid transparent; |
| 43 | + border-bottom: 12px solid rgba(0, 0, 0, 0.06); /* border/outline color */ |
| 44 | + filter: drop-shadow(0 8px 16px rgba(16, 24, 40, 0.06)); |
| 45 | + } |
| 46 | + |
| 47 | + &::after { |
| 48 | + content: ""; |
| 49 | + position: absolute; |
| 50 | + left: 1px; |
| 51 | + top: 1px; |
| 52 | + width: 0; |
| 53 | + height: 0; |
| 54 | + border-left: 11px solid transparent; |
| 55 | + border-right: 11px solid transparent; |
| 56 | + border-bottom: 11px solid var(--bg-color-alt, #fff); /* match popup */ |
| 57 | + } |
| 58 | + |
| 59 | + transform: translateY(8px); |
| 60 | + transition: |
| 61 | + transform 220ms cubic-bezier(0.16, 1, 0.3, 1), |
| 62 | + opacity 180ms ease !important; |
| 63 | + } |
| 64 | + |
| 65 | + &.is-mounted .event-popup__arrow { |
| 66 | + opacity: 1; |
| 67 | + transform: translateY(0); |
36 | 68 | transition: |
37 | 69 | transform 220ms cubic-bezier(0.16, 1, 0.3, 1), |
38 | 70 | opacity 180ms ease !important; |
|
49 | 81 | &.event-popup--above { |
50 | 82 | .event-popup__arrow { |
51 | 83 | top: auto; |
52 | | - bottom: -10px; |
53 | | - border-bottom: 0; |
54 | | - border-top: 10px solid var(--bg-color-alt, #fff); |
| 84 | + bottom: -8px; |
| 85 | + &::before { |
| 86 | + border-bottom: 0; |
| 87 | + border-top: 12px solid rgba(0, 0, 0, 0.06); |
| 88 | + } |
| 89 | + &::after { |
| 90 | + border-bottom: 0; |
| 91 | + border-top: 11px solid var(--bg-color-alt, #fff); |
| 92 | + } |
55 | 93 | transform-origin: bottom center; |
56 | 94 | } |
57 | 95 | } |
|
0 commit comments