From 2807629891fa8f74e4f62178c9097a1edef79cb8 Mon Sep 17 00:00:00 2001 From: Jonathan Staab Date: Sat, 11 Mar 2023 13:51:58 -0600 Subject: [PATCH] Fix person popover on mobile --- ROADMAP.md | 1 - src/partials/ImageInput.svelte | 15 ++++++++++----- src/views/notes/Note.svelte | 2 +- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/ROADMAP.md b/ROADMAP.md index f0bbc5f5..aa20e63c 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -1,6 +1,5 @@ # Current -- [ ] Add warning for petnames not synced (or maybe check that in connect?) - [ ] Add cryptic symbol somewhere showing how many hours I've put in vs sats received with a link to a dev fund page somewhere - [ ] Show loading/success on zap invoice screen - [ ] Fix iOS/safari/firefox diff --git a/src/partials/ImageInput.svelte b/src/partials/ImageInput.svelte index 81dd281e..2d959217 100644 --- a/src/partials/ImageInput.svelte +++ b/src/partials/ImageInput.svelte @@ -21,12 +21,17 @@ $: { if (input) { listener = listenForFile(input, async inputFile => { - const opts = filter(identity, {maxWidth, maxHeight}) + if (inputFile) { + const opts = filter(identity, {maxWidth, maxHeight}) - file = blobToFile(await stripExifData(inputFile, opts)) - quote = await postJson(user.dufflepud("/upload/quote"), { - uploads: [{size: file.size}], - }) + file = blobToFile(await stripExifData(inputFile, opts)) + quote = await postJson(user.dufflepud("/upload/quote"), { + uploads: [{size: file.size}], + }) + } else { + file = null + quote = null + } }) } } diff --git a/src/views/notes/Note.svelte b/src/views/notes/Note.svelte index adf281d9..f6950257 100644 --- a/src/views/notes/Note.svelte +++ b/src/views/notes/Note.svelte @@ -348,7 +348,7 @@ + href={isMobile ? null : routes.person($person.pubkey)}> {displayPerson($person)} {#if $person.verified_as}