Skip to content

Commit

Permalink
Problem: Not clear when user is logged in
Browse files Browse the repository at this point in the history
  • Loading branch information
gsovereignty committed Apr 30, 2024
1 parent 5ead6e8 commit 49b1944
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 28 deletions.
41 changes: 16 additions & 25 deletions src/lib/components/Coracle.svelte
Original file line number Diff line number Diff line change
@@ -1,27 +1,18 @@
<script>
import { Circle2 } from "svelte-loading-spinners";
import { Circle2 } from 'svelte-loading-spinners';
</script>
<div class="flex flex-col items-center justify-center gap-4 py-20">
<div class="flex flex-row">
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="30" unit="px" /><Circle2 size="60" unit="px" /><Circle2
size="90"
unit="px"
/>
</div>
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="90" unit="px" /><Circle2 size="60" unit="px" /><Circle2
size="30"
unit="px"
/>
</div>
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="30" unit="px" /><Circle2 size="60" unit="px" /><Circle2
size="90"
unit="px"
/>
</div>
</div>
</div>

<div class="flex flex-col items-center justify-center gap-4 py-20 overflow-hidden">
<div class="flex flex-row">
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="30" unit="px" /><Circle2 size="60" unit="px" /><Circle2 size="90" unit="px" /><Circle2 size="120" unit="px" />
</div>
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="120" unit="px" /><Circle2 size="90" unit="px" /><Circle2 size="60" unit="px" /><Circle2 size="30" unit="px" />
</div>
<div class="flex flex-col items-center justify-center gap-4 py-20">
<Circle2 size="30" unit="px" /><Circle2 size="60" unit="px" /><Circle2 size="90" unit="px" /><Circle2 size="120" unit="px" />
</div>
</div>
<!-- <Circle2 size="800" unit="px" /> hodlbod's motto is "you can never have too many spinners", but I don't know about this last one, it might be too much-->
</div>
7 changes: 4 additions & 3 deletions src/lib/ndk/Login.svelte
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
<script lang="ts">
import Button from '@/components/Button.svelte';
import type NDK from '@nostr-dev-kit/ndk';
import { NDKNip07Signer, NDKNip46Signer, NDKPrivateKeySigner, NDKUser } from '@nostr-dev-kit/ndk';
import { onMount } from 'svelte';
import { UserAstronautSolid } from 'svelte-awesome-icons';
import { get } from 'svelte/store';
import { connect, currentUser, ndk } from './ndk';
import Button from '@/components/Button.svelte';
import { KeySolid, UserAstronautSolid } from 'svelte-awesome-icons';
import UserProfilePic from '@/components/UserProfilePic.svelte';
onMount(() => {
connect();
Expand Down Expand Up @@ -153,4 +154,4 @@
}
</script>

<Button onClick={()=>{loginNip07(true)}}><UserAstronautSolid /></Button>
<Button onClick={()=>{loginNip07(true)}}>{#if !$currentUser}<UserAstronautSolid class=" fill-violet-700 dark:fill-orange-500" />{:else}<UserProfilePic pubkey={$currentUser.pubkey} />{/if}</Button>

0 comments on commit 49b1944

Please sign in to comment.