diff --git a/src/components/@types/global.ts b/src/components/@types/global.ts index 97075269..0d9323ba 100644 --- a/src/components/@types/global.ts +++ b/src/components/@types/global.ts @@ -45,7 +45,7 @@ export interface ScrollerStep { */ foregroundProps?: object; /** - * Optional alt text for the background, read aloud after the foregroud text. You can add it to each step or just to the first step to describe the entire scroller graphic. + * Optional alt text for the background, read aloud after the foreground text. You can add it to each step or just to the first step to describe the entire scroller graphic. */ altText?: string; } diff --git a/src/components/Scroller/Background.svelte b/src/components/Scroller/Background.svelte index 0f568478..337a3c15 100644 --- a/src/components/Scroller/Background.svelte +++ b/src/components/Scroller/Background.svelte @@ -3,17 +3,12 @@ interface Props { index: number; - steps?: ScrollerStep[]; + steps: ScrollerStep[]; preload?: number; stackBackground?: boolean; } - let { - index, - steps = [], - preload = 1, - stackBackground = true, - }: Props = $props(); + let { index, steps, preload = 1, stackBackground = true }: Props = $props(); {#each steps as step, i} @@ -22,8 +17,8 @@ {#if preload === 0 || (i >= (stackBackground ? 0 : index - preload) && i <= index + preload)}
Likelihood of something happening
+0-25%
+50-75%
+75-100%
+25-50%
+The count is {count}
+The count is {count}
Click Me diff --git a/src/components/Scroller/demo/components/basic/Step.svelte b/src/components/Scroller/demo/components/basic/Step.svelte index 05b95243..d914ec8a 100644 --- a/src/components/Scroller/demo/components/basic/Step.svelte +++ b/src/components/Scroller/demo/components/basic/Step.svelte @@ -6,7 +6,7 @@ let { colour = 'lightblue' }: Props = $props(); - +