From 66b48ae5877893687bb3eb0d83bf61011bcb9952 Mon Sep 17 00:00:00 2001 From: eti Date: Wed, 5 Aug 2026 10:06:16 +0200 Subject: [PATCH] web/components: add ShimmerText Text with a highlight that sweeps across it, for pending states like "cloning" or "waiting for a runner". Ported from spelte.dev, but the js animation is gone (plain css keyframes now) and the colour comes from our semantic tokens instead of a tailwind palette. The highlight is mixed out of currentColor towards the page background, so it lightens in light mode and darkens in dark mode on its own. Nothing uses it yet. Signed-off-by: eti --- .../components/ui/ShimmerText.stories.svelte | 38 ++++++ web/src/lib/components/ui/ShimmerText.svelte | 110 ++++++++++++++++++ 2 files changed, 148 insertions(+) create mode 100644 web/src/lib/components/ui/ShimmerText.stories.svelte create mode 100644 web/src/lib/components/ui/ShimmerText.svelte diff --git a/web/src/lib/components/ui/ShimmerText.stories.svelte b/web/src/lib/components/ui/ShimmerText.stories.svelte new file mode 100644 index 00000000..3ad16240 --- /dev/null +++ b/web/src/lib/components/ui/ShimmerText.stories.svelte @@ -0,0 +1,38 @@ + + +Cloning repository +Waiting for a runner +Pipeline running +Taking a while + + + {#snippet template()} +
+ Resolving knots + Fetching objects + Building index +
+ {/snippet} +
diff --git a/web/src/lib/components/ui/ShimmerText.svelte b/web/src/lib/components/ui/ShimmerText.svelte new file mode 100644 index 00000000..307537c1 --- /dev/null +++ b/web/src/lib/components/ui/ShimmerText.svelte @@ -0,0 +1,110 @@ + + + + + + {@render children()} + + + -- 2.51.2