fix qr dialog having no closing animation in old dashboard links page

main
TZGyn 1 year ago
parent da5c13a38f
commit 968e1568e2
Signed by: TZGyn
GPG Key ID: 122EAF77AE81FD4A

@ -332,48 +332,44 @@
{/if} {/if}
{/await} {/await}
{#if $page.state.linkQR} <Dialog.Root
<Dialog.Root open={!!$page.state.linkQR}
open onOpenChange={(open) => {
onOpenChange={(open) => { if (!open) {
if (!open) { history.back()
history.back() }
} }}>
}}> <Dialog.Content class="sm:max-w-[425px]">
<Dialog.Content class="sm:max-w-[425px]"> <Dialog.Header>
<Dialog.Header> <Dialog.Title>Shortener QR</Dialog.Title>
<Dialog.Title>Shortener QR</Dialog.Title> <Dialog.Description>
<Dialog.Description> Use this QR code to share the shortener.
Use this QR code to share the shortener. </Dialog.Description>
</Dialog.Description> </Dialog.Header>
</Dialog.Header> <ScrollArea class="max-h-[calc(100vh-200px)]">
<ScrollArea class="max-h-[calc(100vh-200px)]"> <LinkQRPage data={$page.state.linkQR} shallowRouting />
<LinkQRPage data={$page.state.linkQR} shallowRouting /> </ScrollArea>
</ScrollArea> </Dialog.Content>
</Dialog.Content> </Dialog.Root>
</Dialog.Root>
{/if}
{#if $page.state.projectLinkQR} <Dialog.Root
<Dialog.Root open={!!$page.state.projectLinkQR}
open onOpenChange={(open) => {
onOpenChange={(open) => { if (!open) {
if (!open) { history.back()
history.back() }
} }}>
}}> <Dialog.Content class="sm:max-w-[425px]">
<Dialog.Content class="sm:max-w-[425px]"> <Dialog.Header>
<Dialog.Header> <Dialog.Title>Shortener QR</Dialog.Title>
<Dialog.Title>Shortener QR</Dialog.Title> <Dialog.Description>
<Dialog.Description> Use this QR code to share the shortener.
Use this QR code to share the shortener. </Dialog.Description>
</Dialog.Description> </Dialog.Header>
</Dialog.Header> <ScrollArea class="max-h-[calc(100vh-200px)]">
<ScrollArea class="max-h-[calc(100vh-200px)]"> <ProjectLinkQRPage
<ProjectLinkQRPage data={$page.state.projectLinkQR}
data={$page.state.projectLinkQR} shallowRouting />
shallowRouting /> </ScrollArea>
</ScrollArea> </Dialog.Content>
</Dialog.Content> </Dialog.Root>
</Dialog.Root>
{/if}

Loading…
Cancel
Save