Compare commits
No commits in common. "a03e5b567a2d8f06f2f5d599035a06895085dc9d" and "86461c1a87e29c58fdeb70614c743f1c2be7f1e2" have entirely different histories.
a03e5b567a
...
86461c1a87
1
icones/site.webmanifest
Normal file
1
icones/site.webmanifest
Normal file
@ -0,0 +1 @@
|
|||||||
|
{"name":"","short_name":"","icons":[{"src":"/android-chrome-192x192.png","sizes":"192x192","type":"image/png"},{"src":"/android-chrome-512x512.png","sizes":"512x512","type":"image/png"}],"theme_color":"#ffffff","background_color":"#ffffff","display":"standalone"}
|
@ -11,7 +11,7 @@
|
|||||||
<link rel="apple-touch-icon" sizes="180x180" href="icones/apple-touch-icon.png">
|
<link rel="apple-touch-icon" sizes="180x180" href="icones/apple-touch-icon.png">
|
||||||
<link rel="icon" type="image/png" sizes="32x32" href="icones/favicon-32x32.png">
|
<link rel="icon" type="image/png" sizes="32x32" href="icones/favicon-32x32.png">
|
||||||
<link rel="icon" type="image/png" sizes="16x16" href="icones/favicon-16x16.png">
|
<link rel="icon" type="image/png" sizes="16x16" href="icones/favicon-16x16.png">
|
||||||
<link rel="manifest" href="site.webmanifest">
|
<link rel="manifest" href="icones/site.webmanifest">
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
18
script.js
18
script.js
@ -83,12 +83,9 @@ function nouvelEssai() {
|
|||||||
input.disabled = true
|
input.disabled = true
|
||||||
input.value = lettre
|
input.value = lettre
|
||||||
})
|
})
|
||||||
sonPerdu.onended = function() {
|
play(sonPerdu)
|
||||||
if (confirm(`Perdu ! Le mot à trouver était : ${motATrouver.toUpperCase()}.\nRéessayer ?`)) nouvellePartie()
|
if (confirm(`Perdu ! Le mot à trouver était : ${motATrouver.toUpperCase()}.\nRéessayer ?`)) nouvellePartie()
|
||||||
else nbEssais = 0
|
else nbEssais = 0
|
||||||
}
|
|
||||||
if (volumeOn) play(sonPerdu)
|
|
||||||
else sonPerdu.onended()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -126,10 +123,6 @@ function play(son) {
|
|||||||
son.play()
|
son.play()
|
||||||
}
|
}
|
||||||
|
|
||||||
sonMotTrouve.onended = function(event) {
|
|
||||||
if (confirm("Bien joué !\nUne nouvelle partie ?")) nouvellePartie()
|
|
||||||
}
|
|
||||||
|
|
||||||
function onsubmit(event) {
|
function onsubmit(event) {
|
||||||
if (this.checkValidity()) {
|
if (this.checkValidity()) {
|
||||||
if (motsAutorises.includes(Array.from(form.children).map((input) => input.value).join(""))) {
|
if (motsAutorises.includes(Array.from(form.children).map((input) => input.value).join(""))) {
|
||||||
@ -164,8 +157,8 @@ function onsubmit(event) {
|
|||||||
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
if (nbLettresBienPlacees == nbLettres) {
|
if (nbLettresBienPlacees == nbLettres) {
|
||||||
if (volumeOn) play(sonMotTrouve)
|
play(sonMotTrouve)
|
||||||
else sonMotTrouve.onended()
|
if (confirm("Bien joué !\nUne nouvelle partie ?")) nouvellePartie()
|
||||||
} else nouvelEssai()
|
} else nouvelEssai()
|
||||||
}, listeATrouver.length * periode)
|
}, listeATrouver.length * periode)
|
||||||
|
|
||||||
@ -179,4 +172,3 @@ function onsubmit(event) {
|
|||||||
this.reportValidity()
|
this.reportValidity()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "L🪷TUS",
|
|
||||||
"short_name": "L🪷TUS",
|
|
||||||
"description": "Devinez le mot",
|
|
||||||
"icons": [
|
|
||||||
{ "src": "icones/android-chrome-192x192.png", "sizes": "192x192", "type": "image/png" },
|
|
||||||
{ "src": "icones/android-chrome-512x512.png", "sizes": "512x512", "type": "image/png" }
|
|
||||||
],
|
|
||||||
"theme_color": "#f26c9a",
|
|
||||||
"background_color": "#ffffff",
|
|
||||||
"display": "standalone"
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user