-
Notifications
You must be signed in to change notification settings - Fork 1
Make cafe pass a single-line marquee #14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -372,53 +372,76 @@ h2 { | |
| } | ||
|
|
||
| .hero-pass { | ||
| display: flex; | ||
| position: relative; | ||
| display: grid; | ||
| align-items: center; | ||
| gap: 0.75rem; | ||
| grid-template-columns: auto minmax(0, 1fr); | ||
| gap: 0.82rem; | ||
| width: min(100%, 52rem); | ||
| min-width: 0; | ||
| overflow-x: auto; | ||
| min-inline-size: 0; | ||
| overflow: hidden; | ||
| padding: 0.78rem 0.85rem; | ||
| border: 1px solid rgba(152, 225, 255, 0.2); | ||
| border-radius: var(--radius-lg); | ||
| background: rgba(9, 10, 30, 0.36); | ||
| box-shadow: inset 0 0 24px rgba(152, 225, 255, 0.05); | ||
| scrollbar-width: none; | ||
| } | ||
|
|
||
| .hero-pass::-webkit-scrollbar { | ||
| display: none; | ||
| .hero-pass::after { | ||
| position: absolute; | ||
| top: 0; | ||
| right: 0; | ||
| bottom: 0; | ||
| width: 3rem; | ||
| pointer-events: none; | ||
| content: ""; | ||
| background: linear-gradient(90deg, transparent, rgba(9, 10, 30, 0.88)); | ||
| } | ||
|
|
||
| .pass-label { | ||
| flex: 0 0 auto; | ||
| color: var(--accent-secondary); | ||
| font-family: "Space Grotesk", system-ui, sans-serif; | ||
| font-size: 0.78rem; | ||
| font-weight: 800; | ||
| line-height: 1; | ||
| white-space: nowrap; | ||
| } | ||
|
|
||
| .pass-marquee { | ||
| min-inline-size: 0; | ||
| overflow: hidden; | ||
| } | ||
|
|
||
| .hero-pass ol { | ||
| display: flex; | ||
| flex-wrap: nowrap; | ||
| align-items: center; | ||
| gap: 0.5rem; | ||
| width: max-content; | ||
| min-width: max-content; | ||
| margin: 0; | ||
| padding: 0; | ||
| animation: pass-marquee 22s linear infinite; | ||
| list-style: none; | ||
| will-change: transform; | ||
| } | ||
|
|
||
| .hero-pass:hover ol { | ||
| animation-play-state: paused; | ||
| } | ||
|
|
||
| .hero-pass li { | ||
| position: relative; | ||
| display: inline-flex; | ||
| gap: 0.45rem; | ||
| flex: 0 0 auto; | ||
| align-items: center; | ||
| gap: 0.42rem; | ||
| color: var(--text-secondary); | ||
| white-space: nowrap; | ||
| } | ||
|
|
||
| .hero-pass li:not(:last-child)::after { | ||
| width: 1.35rem; | ||
| width: 1.45rem; | ||
| height: 1px; | ||
| margin-left: 0.15rem; | ||
| content: ""; | ||
|
Comment on lines
415
to
447
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Visual Jump in Marquee LoopThere is a subtle but noticeable visual jump/jitter when the marquee animation loops (resets from
Combined, this causes a visual jump of nearly Solution
.hero-pass ol {
display: flex;
flex-wrap: nowrap;
align-items: center;
width: max-content;
min-width: max-content;
margin: 0;
padding: 0;
animation: pass-marquee 22s linear infinite;
list-style: none;
will-change: transform;
}
.hero-pass:hover ol {
animation-play-state: paused;
}
.hero-pass li {
position: relative;
display: inline-flex;
flex: 0 0 auto;
align-items: center;
gap: 0.42rem;
margin-right: 0.5rem;
color: var(--text-secondary);
white-space: nowrap;
}
.hero-pass li::after {
width: 1.45rem;
height: 1px;
margin-left: 0.15rem;
content: ""; |
||
|
|
@@ -442,6 +465,7 @@ h2 { | |
| .hero-pass li strong { | ||
| color: var(--text-primary); | ||
| font-size: 0.82rem; | ||
| line-height: 1.22; | ||
| white-space: nowrap; | ||
| } | ||
|
|
||
|
|
@@ -1054,8 +1078,16 @@ textarea:focus { | |
| } | ||
|
|
||
| .sponsor-carousel { | ||
| scrollbar-width: none; | ||
| min-width: 0; | ||
| border: 1px solid rgba(255, 255, 255, 0.13); | ||
| border-radius: var(--radius-md); | ||
| background: | ||
| linear-gradient(180deg, rgba(255, 255, 255, 0.13), rgba(232, 238, 255, 0.06)), | ||
| rgba(8, 8, 29, 0.18); | ||
| box-shadow: | ||
| inset 0 1px 0 rgba(255, 255, 255, 0.12), | ||
| inset 0 -18px 32px rgba(8, 8, 29, 0.14); | ||
| scrollbar-width: none; | ||
| } | ||
|
|
||
| .sponsor-carousel::-webkit-scrollbar { | ||
|
|
@@ -1128,11 +1160,21 @@ textarea:focus { | |
| border-radius: calc(var(--radius-sm) - 0.12rem); | ||
| } | ||
|
|
||
| .sponsor-card[data-sponsor="arize"], | ||
| .sponsor-card[data-sponsor="minds"] { | ||
| padding-block: 0.28rem; | ||
| background: | ||
| linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(231, 238, 255, 0.82)), | ||
| rgba(255, 255, 255, 0.86); | ||
| linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(235, 240, 255, 0.88)), | ||
| rgba(255, 255, 255, 0.92); | ||
| border-color: rgba(255, 255, 255, 0.42); | ||
| box-shadow: | ||
| inset 0 1px 0 rgba(255, 255, 255, 0.78), | ||
| inset 0 -16px 28px rgba(55, 67, 113, 0.08), | ||
| 0 10px 24px rgba(0, 0, 0, 0.18); | ||
| } | ||
|
|
||
| .sponsor-card[data-sponsor="arize"] img { | ||
| height: 2.8rem; | ||
| } | ||
|
|
||
| .sponsor-card[data-sponsor="minds"] img { | ||
|
|
@@ -1158,6 +1200,16 @@ textarea:focus { | |
| } | ||
| } | ||
|
|
||
| @keyframes pass-marquee { | ||
| from { | ||
| transform: translateX(0); | ||
| } | ||
|
|
||
| to { | ||
| transform: translateX(-50%); | ||
| } | ||
| } | ||
|
|
||
| @keyframes sponsor-mobile-cycle { | ||
| 0%, | ||
| 20% { | ||
|
|
@@ -1195,9 +1247,14 @@ textarea:focus { | |
| scroll-behavior: auto; | ||
| } | ||
|
|
||
| .hero-pass ol, | ||
| .sponsor-track { | ||
| animation: none; | ||
| } | ||
|
|
||
| .hero-pass ol { | ||
| transform: none; | ||
| } | ||
| } | ||
|
|
||
| @media (max-width: 860px) { | ||
|
|
@@ -1262,10 +1319,19 @@ textarea:focus { | |
| } | ||
|
|
||
| .hero-pass { | ||
| grid-template-columns: auto minmax(0, 1fr); | ||
| width: 100%; | ||
| padding: 0.56rem 0.65rem; | ||
| } | ||
|
|
||
| .hero-pass ol { | ||
| animation-duration: 18s; | ||
| } | ||
|
|
||
| .hero-pass li strong { | ||
| font-size: 0.76rem; | ||
| } | ||
|
|
||
| .guestbook-card, | ||
| .entries-card { | ||
| padding: 0.72rem; | ||
|
|
@@ -1377,6 +1443,10 @@ textarea:focus { | |
| height: 2.35rem; | ||
| } | ||
|
|
||
| .sponsor-card[data-sponsor="arize"] img { | ||
| height: 2.72rem; | ||
| } | ||
|
|
||
| .sponsor-card[data-sponsor="minds"] img { | ||
| height: 2.95rem; | ||
| } | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update the test assertion to match the updated CSS rule (
.hero-pass li::afterinstead of.hero-pass li:not(:last-child)::after) to support the seamless marquee loop fix.