Further cleanup and fixing Wallet and GoogleAuth to the new Composer interface
This commit is contained in:
23
src/lib/components/refactor/ComposerWallet.svelte
Normal file
23
src/lib/components/refactor/ComposerWallet.svelte
Normal file
@ -0,0 +1,23 @@
|
||||
<script>
|
||||
import { onMount } from 'svelte';
|
||||
import { connectWallet } from '$lib/services/wallet/wallet';
|
||||
import WalletConnect from '$lib/WalletConnect.svelte';
|
||||
import Send from '$lib/Send.svelte';
|
||||
|
||||
export let me;
|
||||
|
||||
onMount(async () => {
|
||||
$me.context.pkpWallet = await connectWallet($me.context.pkpPubKey, $me.context.rpcURL);
|
||||
});
|
||||
</script>
|
||||
|
||||
<div>
|
||||
<div class="mb-4 text-lg font-medium">
|
||||
PKP Wallet:
|
||||
{#if $me.context.pkpWallet}
|
||||
<span class="text-blue-600">{$me.context.pkpWallet.address}</span>
|
||||
{/if}
|
||||
</div>
|
||||
<Send pkpWallet={$me.context.pkpWallet} />
|
||||
<WalletConnect />
|
||||
</div>
|
Reference in New Issue
Block a user