Skip to content

Commit dd32947

Browse files
authored
fix: align workflow flow and add animation
2 parents 33746dc + 25d91f2 commit dd32947

2 files changed

Lines changed: 15 additions & 8 deletions

File tree

docs/src/app/home.css

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -110,14 +110,21 @@
110110
.hp-step-title { font-family: var(--hp-title); color: var(--hp-text); font-weight: 600; margin-bottom: 6px; font-size: 14px; }
111111
.hp-step-desc { color: var(--hp-text-dim); line-height: 1.5; }
112112
.hp-step-desc code { font-family: var(--hp-mono); font-size: 12px; color: var(--hp-accent); background: rgba(34, 197, 94, 0.08); padding: 1px 4px; border-radius: 3px; }
113-
.hp-workflow-flow { display: flex; align-items: center; justify-content: center; padding: 32px 0; }
113+
.hp-workflow-flow { display: flex; align-items: flex-start; justify-content: center; padding: 32px 0; }
114114
.hp-flow-step { display: flex; flex-direction: column; align-items: center; gap: 10px; }
115-
.hp-flow-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--hp-border-bright); border: 2px solid var(--hp-border-bright); display: block; }
116-
.hp-flow-dot.active { background: var(--hp-accent); border-color: var(--hp-accent); box-shadow: 0 0 8px rgba(34, 197, 94, 0.3); }
117-
.hp-flow-line { width: 48px; height: 2px; background: var(--hp-border-bright); margin-bottom: 22px; }
118-
.hp-flow-line.active { background: var(--hp-accent); }
115+
.hp-flow-dot { width: 12px; height: 12px; border-radius: 50%; background: var(--hp-border-bright); display: block; animation: flow-pulse 5s infinite; animation-delay: calc(var(--step-index) * 1s); }
116+
.hp-flow-line { width: 48px; height: 2px; background: var(--hp-border-bright); margin-top: 5px; animation: flow-line 5s infinite; animation-delay: calc(var(--line-index) * 1s + 0.5s); }
119117
.hp-flow-label { font-family: var(--hp-mono); font-size: 12px; color: var(--hp-text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
120118

119+
@keyframes flow-pulse {
120+
0%, 15% { background: var(--hp-accent); box-shadow: 0 0 8px rgba(168, 255, 83, 0.4); }
121+
30%, 100% { background: var(--hp-border-bright); box-shadow: none; }
122+
}
123+
@keyframes flow-line {
124+
0%, 10% { background: var(--hp-accent); }
125+
25%, 100% { background: var(--hp-border-bright); }
126+
}
127+
121128
/* SKILLS */
122129
.hp-skills { padding: 64px 0; }
123130
.hp-skills h2 { font-family: var(--hp-title); font-size: 28px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 12px; }

docs/src/app/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -206,11 +206,11 @@ export default function HomePage() {
206206
<div className="hp-workflow-flow">
207207
{['write', 'debug', 'fix', 'strip', 'merge'].map((label, i) => (
208208
<span key={label} style={{ display: 'contents' }}>
209-
<div className="hp-flow-step">
210-
<span className={`hp-flow-dot ${i < 3 ? 'active' : ''}`} />
209+
<div className="hp-flow-step" style={{ '--step-index': i } as React.CSSProperties}>
210+
<span className="hp-flow-dot" />
211211
<span className="hp-flow-label">{label}</span>
212212
</div>
213-
{i < 4 && <div className={`hp-flow-line ${i < 2 ? 'active' : ''}`} />}
213+
{i < 4 && <div className="hp-flow-line" style={{ '--line-index': i } as React.CSSProperties} />}
214214
</span>
215215
))}
216216
</div>

0 commit comments

Comments
 (0)