diff --git a/src/App.svelte b/src/App.svelte index 290459f..bfebefa 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -1,169 +1,36 @@ @@ -173,19 +40,20 @@ {:else}
- - + +
- - (openWindow = "")} /> - (openWindow = "")} /> {/if} { + handler={(/** @type {string} */ btn) => { openWindow = btn; }} {connected} /> + + + (openWindow = "")} /> + (openWindow = "")} /> (openWindow = "")} /> diff --git a/src/audio.js b/src/lib/audio.js similarity index 100% rename from src/audio.js rename to src/lib/audio.js diff --git a/src/lib/Chat.svelte b/src/lib/components/Chat.svelte similarity index 89% rename from src/lib/Chat.svelte rename to src/lib/components/Chat.svelte index 99553b9..a8fbe85 100644 --- a/src/lib/Chat.svelte +++ b/src/lib/components/Chat.svelte @@ -1,6 +1,5 @@
  • diff --git a/src/lib/Hints.svelte b/src/lib/components/Hints.svelte similarity index 56% rename from src/lib/Hints.svelte rename to src/lib/components/Hints.svelte index a548b4a..ff79712 100644 --- a/src/lib/Hints.svelte +++ b/src/lib/components/Hints.svelte @@ -1,11 +1,6 @@ @@ -14,36 +9,44 @@

    Hinted Items

    - {#each hints as [_a, hint_data]} - {@const i1_data = hint_data.ingredient_1} - {@const i2_data = hint_data.ingredient_2} - {@const prod_data = hint_data.product} -
    - {i1_data.alt} - -

    {i1_data.location}

    -

    from {i1_data.player}

    -

    {i1_data.name}

    -
    -
    - + -
    - {i2_data.alt} - -

    {i2_data.location}

    -

    from {i2_data.player}

    -

    {i2_data.name}

    -
    -
    - = -
    - {prod_data.alt} - -

    {prod_data.location}

    -

    from {prod_data.player}

    -

    {prod_data.name}

    -
    -
    + {#each apstore.hintedElements as [_a, recipes]} + {#each recipes as recipe} + {@const i1_data = + apstore.elementData[recipe.ingredient_1] ?? + defaultElementData(recipe.ingredient_1)} + {@const i2_data = + apstore.elementData[recipe.ingredient_2] ?? + defaultElementData(recipe.ingredient_2)} + {@const prod_data = + apstore.elementData[recipe.result] ?? defaultElementData(recipe.result)} + +
    + {i1_data.alt} + +

    {i1_data.location}

    +

    from {i1_data.player}

    +

    {i1_data.name}

    +
    +
    + + +
    + {i2_data.alt} + +

    {i2_data.location}

    +

    from {i2_data.player}

    +

    {i2_data.name}

    +
    +
    + = +
    + {prod_data.alt} + +

    {prod_data.location}

    +

    to {prod_data.player}

    +

    {prod_data.name}

    +
    +
    + {/each} {/each}
    diff --git a/src/lib/Login.svelte b/src/lib/components/Login.svelte similarity index 91% rename from src/lib/Login.svelte rename to src/lib/components/Login.svelte index cce5bb2..0e5cd26 100644 --- a/src/lib/Login.svelte +++ b/src/lib/components/Login.svelte @@ -1,10 +1,8 @@ + +
    + + diff --git a/src/lib/Settings.svelte b/src/lib/components/Settings.svelte similarity index 100% rename from src/lib/Settings.svelte rename to src/lib/components/Settings.svelte diff --git a/src/lib/Toast.svelte b/src/lib/components/Toast.svelte similarity index 83% rename from src/lib/Toast.svelte rename to src/lib/components/Toast.svelte index cc61447..4b79770 100644 --- a/src/lib/Toast.svelte +++ b/src/lib/components/Toast.svelte @@ -1,6 +1,6 @@