fix: ModalContainer modals sometimes stay closed / fix autofill not working after 1 usage

This commit is contained in:
Xylight committed 2026-02-26 17:52:08 -08:00
1 parent 6a88a3baca
commit 38844827d0
4 files changed
+9 -4

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "photon-lemmy", "name": "photon-lemmy",
"version": "2.2.2", "version": "2.3.0",
"license": "AGPL-3.0-only", "license": "AGPL-3.0-only",
"devDependencies": { "devDependencies": {
"@dicebear/core": "^9.3.1", "@dicebear/core": "^9.3.1",
@@ -175,6 +175,7 @@
{#snippet autofillPostModal()} {#snippet autofillPostModal()}
<svelte:boundary> <svelte:boundary>
{#if form.url} {#if form.url}
{#key form.url}
{#await autofill(new URL(form.url))} {#await autofill(new URL(form.url))}
<div class="w-full h-48 grid place-items-center"> <div class="w-full h-48 grid place-items-center">
<TextLoader> <TextLoader>
@@ -209,6 +210,7 @@
<Switch class="mt-4" bind:checked={settings.forms.autosubmitAutofill}> <Switch class="mt-4" bind:checked={settings.forms.autosubmitAutofill}>
{$t('form.post.autosubmit')} {$t('form.post.autosubmit')}
</Switch> </Switch>
{/key}
{/if} {/if}
</svelte:boundary> </svelte:boundary>
{/snippet} {/snippet}
@@ -161,7 +161,6 @@
} }
.post-media-indicator { .post-media-indicator {
/*bg-linear-180 from-zinc-900/0 to-zinc-900/95 h-16 absolute bottom-0 w-full left-0 flex items-end p-2*/
position: absolute; position: absolute;
bottom: 0; bottom: 0;
left: 0; left: 0;
@@ -170,6 +169,8 @@
padding: calc(var(--spacing) * 2); padding: calc(var(--spacing) * 2);
height: calc(var(--spacing) * 16); height: calc(var(--spacing) * 16);
width: 100%; width: 100%;
border-bottom-left-radius: inherit;
border-bottom-right-radius: inherit;
background-image: linear-gradient( background-image: linear-gradient(
to bottom, to bottom,
@@ -4,7 +4,8 @@
import { shownModal } from './modal' import { shownModal } from './modal'
</script> </script>
{#if $shownModal} {#key $shownModal}
{#if $shownModal}
<Modal <Modal
title={$shownModal.title} title={$shownModal.title}
dismissable={$shownModal.dismissable} dismissable={$shownModal.dismissable}
@@ -39,4 +40,5 @@
</div> </div>
{/if} {/if}
</Modal> </Modal>
{/if} {/if}
{/key}