Add layout and footer components, update adventureService, and create log page

This commit is contained in:
Sean Morley
2024-03-29 22:44:32 +00:00
parent 2f180a204b
commit 90036c5c14
5 changed files with 144 additions and 103 deletions

View File

@@ -34,8 +34,8 @@ export function getAdventures(): Adventure[] {
return adventures;
}
export function removeAdventure(event: { detail: string; }) {
adventures = adventures.filter(adventure => adventure.name !== event.detail);
export function removeAdventure(event: { detail: number; }) {
adventures = adventures.filter(adventure => adventure.id !== event.detail);
if (isBrowser) {
localStorage.setItem('adventures', JSON.stringify(adventures));
}