From 1e261eb3eca7a1d86753bdf9cb3187a1de91116a Mon Sep 17 00:00:00 2001 From: Settel Date: Fri, 16 Sep 2022 22:41:08 +0200 Subject: [PATCH] feat: add animations to Playground elements --- client/src/components/Playground.vue | 13 ++++--------- client/src/components/SourceCard.vue | 9 +++++---- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/client/src/components/Playground.vue b/client/src/components/Playground.vue index ffeb887..afe6e79 100644 --- a/client/src/components/Playground.vue +++ b/client/src/components/Playground.vue @@ -72,16 +72,11 @@ const disabledMap = computed(() => { }) const showMap = ref({} as { [key: string]: boolean}) -window.setTimeout(() => { - for (const source of sources) { +sources.forEach((source, index) => { + window.setTimeout(() => { showMap.value[source.id] = true - } -}, 1000) -window.setTimeout(() => { - for (const source of sources) { - showMap.value[source.id] = false - } -}, 3000) + }, 1000 + index * 250) +})