Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 0 additions & 48 deletions apps/frontend/src/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -31,54 +31,6 @@
U+E000-F8FF, U+FE00-FE0F, U+FB00-FB06, U+FEFF, U+FFFD;
}

/* === Animations === */

/* SVG graph draw-in */
.graph-line {
stroke-dasharray: 1;
stroke-dashoffset: 1;
}

.in-view .graph-line {
animation: draw-line 1.2s ease forwards;
}

@keyframes draw-line {
to {
stroke-dashoffset: 0;
}
}

.graph-node {
transform-box: fill-box;
transform-origin: center;
transform: scale(0);
}

.in-view .graph-node {
animation: pop-in 0.4s ease forwards;
}

@keyframes pop-in {
to {
transform: scale(1);
}
}

.graph-fade {
opacity: 0;
}

.in-view .graph-fade {
animation: fade-in 0.5s ease forwards;
}

@keyframes fade-in {
to {
opacity: 1;
}
}

/* Custom utilities */

@utility page-container {
Expand Down
52 changes: 21 additions & 31 deletions apps/frontend/src/components/timeline/TimelineGraph.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -105,73 +105,63 @@
y1={nodeY(maxGridRow, pxPerMonth)}
x2={graphData.laneX(0)}
y2={nodeY(1, pxPerMonth)}
class="stroke-surface-600 graph-line"
class="stroke-surface-600"
stroke-width={LINE_WIDTH}
stroke-linecap="round"
pathLength="1"
style="animation-delay: 200ms;"
/>

<!-- Branch paths (fork curve + vertical + merge curve combined) -->
{#each branchPaths as bp, i}
{#each branchPaths as bp}
<path
d={bp.d}
fill="none"
stroke={bp.color}
stroke-width={LINE_WIDTH}
stroke-linecap="round"
class="graph-line"
pathLength="1"
style="animation-delay: {300 + i * 100}ms;"
/>
{/each}

<!-- Leader lines -->
{#each graphData.leaderLines as leader, i}
{#each graphData.leaderLines as leader}
<polyline
points={leader.points.map((p) => `${p.x},${p.y}`).join(" ")}
fill="none"
stroke={leader.color}
stroke-width={1}
stroke-dasharray="4 3"
class="graph-fade"
style="animation-delay: {600 + i * 50}ms;"
/>
{/each}

<!-- Commit nodes -->
{#each graphData.nodes as node, i}
{#each graphData.nodes as node}
{@const ny = nodeY(node.row, pxPerMonth)}
<circle
cx={graphData.laneX(node.lane)}
cy={ny}
r={NODE_RADIUS}
fill={node.color}
class="stroke-surface-950 stroke-3 graph-node"
style="animation-delay: {600 + i * 50}ms;"
class="stroke-surface-950 stroke-3"
/>
{/each}

<!-- Trunk labels (year markers + life labels) -->
{#each trunkLabels as label, i}
{#each trunkLabels as label}
{@const mx = graphData.laneX(0)}
<g class="graph-fade" style="animation-delay: {800 + i * 50}ms;">
<rect
x={mx - 16}
y={label.y - 8}
width="32"
height="16"
rx="3"
class="fill-surface-950"
/>
<text
x={mx}
y={label.y + 4}
text-anchor="middle"
class="fill-surface-500 font-semibold tracking-[0.05em]"
style="font-size: 0.5625rem;">{label.text}</text
>
</g>
<rect
x={mx - 16}
y={label.y - 8}
width="32"
height="16"
rx="3"
class="fill-surface-950"
/>
<text
x={mx}
y={label.y + 4}
text-anchor="middle"
class="fill-surface-500 font-semibold tracking-[0.05em]"
style="font-size: 0.5625rem;">{label.text}</text
>
{/each}
</svg>
</div>
4 changes: 2 additions & 2 deletions apps/frontend/src/routes/history/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import Timeline from "$components/Timeline.svelte";
import TitleText from "$components/TitleText.svelte";
import { timelineEntries } from "$data/metadata";
import { inview } from "$lib/actions/inview";

import SEO from "$lib/seo/components/SEO.svelte";
import { SITE_URL } from "$lib/config";
import type { PageData } from "./$types";
Expand All @@ -20,7 +20,7 @@

<div class="page-container">
<TitleText path="history" subtitle="My timeline so far" />
<section class="flex flex-col gap-4 items-center w-full" use:inview>
<section class="flex flex-col gap-4 items-center w-full">
<Timeline entries={timelineEntries} />
</section>
</div>
Loading