add count and pie

This commit is contained in:
Vincent Liao
2022-03-22 00:36:43 +07:00
parent f11bc89dcc
commit e91c8f3a07
6 changed files with 78 additions and 1 deletions

20
src/lib/Count.svelte Normal file
View File

@@ -0,0 +1,20 @@
<script>
export let count1h;
export let count24h;
</script>
<div class="rounded-md shadow p-3 bg-white">
<span class="block text-center pb-3 text-sm text-neutral-400 font-mono"
>NOSTR NETWORK'S EVENT COUNT</span
>
<div class="flex">
<div class="flex-1 text-center">
<span class="text-2xl">{count1h}</span>
<span class="text-neutral-400">last 1h</span>
</div>
<div class="flex-1 text-center">
<span class="text-2xl">{count24h}</span>
<span class="text-neutral-400">last 24h</span>
</div>
</div>
</div>