🚧 Some progress with ClassQuizController

This commit is contained in:
Mawoka
2023-04-15 13:24:36 +02:00
parent ac18621672
commit 9d685e25df
17 changed files with 2061 additions and 1496 deletions
@@ -0,0 +1,22 @@
<script lang="ts">
let color_map = {
r: 'red',
g: 'green',
y: 'yellow',
b: 'blue'
};
export let code: string;
</script>
<div class="flex flex-row gap-2 mx-auto">
{#each code as c}
<div class="flex flex-col">
<p class="text-center">{c}</p>
<span
style="background-color: {color_map[
c.toLowerCase()
]}; width: 2rem; height: {c.toLowerCase() == c ? '2' : '4'}rem"
/>
</div>
{/each}
</div>