fix(dashboard): fix crash when changing pages with an open card

This commit is contained in:
Jake/Rads 2022-06-24 07:56:16 +02:00
parent b4b7525fc0
commit 3c4de5996c

View File

@ -155,7 +155,7 @@
{#if !listLoading && !err} {#if !listLoading && !err}
{#if settings && settings.accessibility ? (!settings.accessibility.expandedcards && !settings.accessibility.pagelinks) : true} {#if settings && settings.accessibility ? (!settings.accessibility.expandedcards && !settings.accessibility.pagelinks) : true}
<Accordion class="my-3" stayOpen> <Accordion class="my-3" stayOpen>
{#each slicedList as item, index} {#each slicedList as item, index (item.id)}
<AccordionItem> <AccordionItem>
<CardsHeader {item} slot="header"> <CardsHeader {item} slot="header">
<div slot="icon"> <div slot="icon">
@ -179,7 +179,7 @@
{/each} {/each}
</Accordion> </Accordion>
{:else if settings.accessibility.expandedcards} {:else if settings.accessibility.expandedcards}
{#each slicedList as item, index} {#each slicedList as item, index (item.id)}
<Card class="mb-3"> <Card class="mb-3">
<CardHeader> <CardHeader>
<CardsHeader {item} slot="header"> <CardsHeader {item} slot="header">
@ -207,7 +207,7 @@
{/each} {/each}
{:else} {:else}
<div class="my-3"> <div class="my-3">
{#each slicedList as item, index} {#each slicedList as item, index (item.id)}
<Card> <Card>
<Link class="accordion-button collapsed" style="text-decoration: none;" to={getItemLink(item)}> <Link class="accordion-button collapsed" style="text-decoration: none;" to={getItemLink(item)}>
<CardsHeader {item} slot="header"> <CardsHeader {item} slot="header">