regen
This commit is contained in:
parent
b84a93fead
commit
cb2b02e747
@ -240,7 +240,6 @@
|
||||
.then(response => response.json())
|
||||
.then(json => {
|
||||
noms = json
|
||||
|
||||
regen()
|
||||
})
|
||||
|
||||
@ -252,11 +251,11 @@
|
||||
|
||||
function regen() {
|
||||
if (sigleInput.value.length) {
|
||||
let listNoms = Array.from(sigleInput.value).map((lettre, position) => trouveMot(lettre, position))
|
||||
let suggestion= Array.from(sigleInput.value).map((lettre, position) => trouveMot(lettre, position)).join(" ")
|
||||
alertDiv.innerHTML = `
|
||||
<div class="fr-alert fr-alert--info">
|
||||
<p>Suggestion :</p>
|
||||
<h3 class="fr-alert__title" id="nomDiv">${listNoms.join(" ")}</h3>
|
||||
<h3 class="fr-alert__title" id="nomDiv">${suggestion}</h3>
|
||||
<button class="fr-btn--close fr-btn" title="Masquer le message" onclick="const alert = this.parentNode; alert.parentNode.removeChild(alert)">
|
||||
Masquer le message
|
||||
</button>
|
||||
|
Loading…
x
Reference in New Issue
Block a user