1
0
Fork 0
mirror of https://github.com/seanmorley15/AdventureLog.git synced 2025-07-19 04:49:37 +02:00

fix: Pass collection prop to various card components in the collections page

This commit is contained in:
Sean Morley 2025-03-19 13:50:32 -04:00 committed by GitHub
commit dbd417ca87
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -859,6 +859,7 @@
on:edit={editAdventure} on:edit={editAdventure}
on:delete={deleteAdventure} on:delete={deleteAdventure}
{adventure} {adventure}
{collection}
/> />
{/each} {/each}
{/if} {/if}
@ -866,6 +867,7 @@
{#each dayTransportations as transportation} {#each dayTransportations as transportation}
<TransportationCard <TransportationCard
{transportation} {transportation}
{collection}
user={data?.user} user={data?.user}
on:delete={(event) => { on:delete={(event) => {
transportations = transportations.filter((t) => t.id != event.detail); transportations = transportations.filter((t) => t.id != event.detail);
@ -881,6 +883,7 @@
{#each dayNotes as note} {#each dayNotes as note}
<NoteCard <NoteCard
{note} {note}
{collection}
user={data.user || null} user={data.user || null}
on:edit={(event) => { on:edit={(event) => {
noteToEdit = event.detail; noteToEdit = event.detail;
@ -896,6 +899,7 @@
{#each dayLodging as hotel} {#each dayLodging as hotel}
<LodgingCard <LodgingCard
lodging={hotel} lodging={hotel}
{collection}
user={data?.user} user={data?.user}
on:delete={(event) => { on:delete={(event) => {
lodging = lodging.filter((t) => t.id != event.detail); lodging = lodging.filter((t) => t.id != event.detail);
@ -908,6 +912,7 @@
{#each dayChecklists as checklist} {#each dayChecklists as checklist}
<ChecklistCard <ChecklistCard
{checklist} {checklist}
{collection}
user={data.user || null} user={data.user || null}
on:delete={(event) => { on:delete={(event) => {
notes = notes.filter((n) => n.id != event.detail); notes = notes.filter((n) => n.id != event.detail);