update howtoplay, add some localstorage functionality
Build / Build-image (push) Successful in 1m30s

This commit is contained in:
2026-09-05 12:11:09 +02:00
parent c1fcb34ee5
commit cc892fdebf
3 changed files with 43 additions and 13 deletions
+34 -3
View File
@@ -23,7 +23,9 @@ import Wordle from '../components/Wordle.vue';
maxGuesses: 10,
correct: false,
no_tla: false,
wordle_open: [false, false, false]
wordle_open: [false, false, false],
wordle_dontshow: false,
wordle_hint: false,
};
},
@@ -42,6 +44,10 @@ import Wordle from '../components/Wordle.vue';
this.correct_words = response.data.tla_array;
}
});
if (localStorage.wordle_dontshow) {
this.wordle_dontshow = localStorage.wordle_dontshow;
}
},
methods: {
@@ -76,6 +82,10 @@ import Wordle from '../components/Wordle.vue';
},
onkeyup() {
this.words = this.guess.trim().split(/\s+/);
},
wordle_disable() {
this.wordle_dontshow = true;
localStorage.wordle_dontshow = true;
}
}
}
@@ -99,8 +109,7 @@ import Wordle from '../components/Wordle.vue';
<GuessWord @pressed_wordle="wordle_open[i-1] = true" :correctness="Number(guess[i+2])" :index="i-1">
{{ guess[i-1] }}
</GuessWord>
<Wordle v-model:open="wordle_open[i-1]" :correct="correct_words[i-1]"/>
<Wordle v-model:open="wordle_open[i-1]" :correct="correct_words[i-1]" :index="i"/>
</template>
</div>
</template>
@@ -158,6 +167,28 @@ import Wordle from '../components/Wordle.vue';
<h3>The context of todays TLA:</h3>
{{ context }}
</Modal>
<br>
<UForm @submit="wordle_disable" v-if="!wordle_dontshow">
<UAlert
title="Press the word if the starting letter is correct to launch a mini wordle!"
color="success"
style="text-align: left; margin-top: 10px;"
variant="subtle"
orientation="horizontal"
:actions="[
{
label: 'Don\'t show again',
color: 'warning',
type: 'submit',
variant: 'subtle'
}
]"
/>
</UForm>
</template>
<style>