1
0
Fork 0
mirror of https://github.com/seanmorley15/AdventureLog.git synced 2025-08-05 05:05:17 +02:00

Refactor adventure creation form

This commit is contained in:
Sean Morley 2024-03-31 17:01:58 +00:00
parent 2e26e3712d
commit 716276c375

View file

@ -10,6 +10,7 @@
import SucessToast from "$lib/components/SucessToast.svelte"; import SucessToast from "$lib/components/SucessToast.svelte";
import mapDrawing from "$lib/assets/adventure_map.svg" import mapDrawing from "$lib/assets/adventure_map.svg"
import EditModal from "$lib/components/EditModal.svelte"; import EditModal from "$lib/components/EditModal.svelte";
import { Input } from "postcss";
let newName = ''; let newName = '';
@ -96,9 +97,11 @@
</script> </script>
<div class="flex flex-row items-center justify-center gap-4"> <div class="flex flex-row items-center justify-center gap-4">
<input type="text" bind:value={newName} placeholder="Adventure Name" class="input input-bordered w-full max-w-xs" /> <form on:submit={createNewAdventure} class="flex gap-2">
<input type="text" bind:value={newLocation} placeholder="Adventure Location" class="input input-bordered w-full max-w-xs" /> <input type="text" bind:value={newName} placeholder="Adventure Name" class="input input-bordered w-full max-w-xs" />
<button class="btn" on:click={createNewAdventure}>Add Adventure</button> <input type="text" bind:value={newLocation} placeholder="Adventure Location" class="input input-bordered w-full max-w-xs" />
<input class="btn btn-primary" type="submit" value="Add Adventure">
</form>
</div> </div>
{#if isShowingToast} {#if isShowingToast}