From 1d7ac4d5a2180a6f0e36149a1f83f690c4c961cf Mon Sep 17 00:00:00 2001 From: mehbark Date: Tue, 11 Jul 2023 12:43:32 -0400 Subject: [PATCH] actually random take skeleton? --- ...people_who_eat_croissants_are_dangerous.tsx | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/html/hot_people_who_eat_croissants_are_dangerous.tsx b/html/hot_people_who_eat_croissants_are_dangerous.tsx index 7dd8b68..4a7d6b1 100644 --- a/html/hot_people_who_eat_croissants_are_dangerous.tsx +++ b/html/hot_people_who_eat_croissants_are_dangerous.tsx @@ -38,14 +38,26 @@ const Wheel: Component = ({ items }, _) => ( ); +function slices(arr: T[]): T[][] { + return arr.map((_, i) => arr.slice(0, i)); +} + +const MultiWheel: Component = ({ items }, _) => ( +
+ {slices(items).map(items => ( + + ))} +
+); + // i'll probably just hardcode the delays... lame but w/e // nope // it would be possible to have it so the final text is actually properyly selectable maybe but eh const Take: Component = ({ subjects, objects, adjectives }, _) => (
-
who eat
{" "} -
are
{" "} - +
who eat
{" "} +
are
{" "} +
);