diff --git a/src/lib/atproto/UI/HandleInput.svelte b/src/lib/atproto/UI/HandleInput.svelte index e8b85a4..dc57bd1 100644 --- a/src/lib/atproto/UI/HandleInput.svelte +++ b/src/lib/atproto/UI/HandleInput.svelte @@ -38,8 +38,8 @@ (val) => { const profile = results.find((v) => v.handle === val); if (profile) onselected?.(profile); - - value = val; + // Only update if val has content - prevents Combobox from clearing on Enter + if (val) value = val; } } bind:open={ @@ -57,6 +57,9 @@ value = e.currentTarget.value; search(e.currentTarget.value); }} + onkeydown={(e) => { + if (e.key === 'Enter') e.currentTarget.form?.requestSubmit(); + }} class="focus-within:outline-accent-600 dark:focus-within:outline-accent-500 dark:placeholder:text-base-400 w-full touch-none rounded-full border-0 bg-white ring-0 outline-1 -outline-offset-1 outline-gray-300 focus-within:outline-2 focus-within:-outline-offset-2 dark:bg-white/5 dark:outline-white/10" placeholder="handle" id="" diff --git a/src/routes/(auth)/oauth/callback/+page.svelte b/src/routes/(auth)/oauth/callback/+page.svelte index 89ac157..097a332 100644 --- a/src/routes/(auth)/oauth/callback/+page.svelte +++ b/src/routes/(auth)/oauth/callback/+page.svelte @@ -12,7 +12,7 @@ goto('/' + getHandleOrDid(user.profile) + '/edit', {}); } - if(!user.isInitializing && !startedErrorTimer) { + if (!user.isInitializing && !startedErrorTimer) { startedErrorTimer = true; setTimeout(() => { @@ -30,7 +30,6 @@ >There was an error signing you in, please go back to the homepage and try again. - {/if}