ptits fix
This commit is contained in:
parent
4d0795d2de
commit
54f7a5285f
3 changed files with 6 additions and 36 deletions
32
css/gift.css
32
css/gift.css
|
|
@ -1,32 +0,0 @@
|
|||
.gift {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
background-color: red;
|
||||
border-radius: 10px;
|
||||
position: absolute;
|
||||
animation: moveGift 5s infinite linear;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
@keyframes moveGift {
|
||||
0% {
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
25% {
|
||||
top: 0;
|
||||
left: calc(100% - 50px);
|
||||
}
|
||||
50% {
|
||||
top: calc(100% - 50px);
|
||||
left: calc(100% - 50px);
|
||||
}
|
||||
75% {
|
||||
top: calc(100% - 50px);
|
||||
left: 0;
|
||||
}
|
||||
100% {
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
}
|
||||
|
|
@ -78,6 +78,7 @@
|
|||
position: absolute;
|
||||
left:0%;
|
||||
top: 0%;
|
||||
max-width: 100vw;
|
||||
}
|
||||
|
||||
#close_rick{
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ async function remplirMagasinTechnologies(){
|
|||
|
||||
const table= document.getElementById("table_magasin_technologies_body")
|
||||
|
||||
let data = await fetch("../bdd/arbre.json")
|
||||
let data = await fetch("./bdd/arbre.json")
|
||||
data = await data.json()
|
||||
|
||||
|
||||
|
|
@ -103,7 +103,7 @@ async function remplirMagasinCollegues(){
|
|||
|
||||
const table= document.getElementById("table_magasin_collegues_body")
|
||||
|
||||
let data = await fetch("../bdd/arbre.json")
|
||||
let data = await fetch("./bdd/arbre.json")
|
||||
data = await data.json()
|
||||
|
||||
|
||||
|
|
@ -404,13 +404,14 @@ function cadeauClickCallback(){
|
|||
}
|
||||
}
|
||||
|
||||
// enlève le cadeau
|
||||
div_cadeau.style.display = "none";
|
||||
|
||||
|
||||
// génère un nouveau timer pour le prochain cadeau à afficher !
|
||||
setTimeout(genererCadeau, Math.random() * 10000 + 20000); // Premier affichage aléatoire entre 20 et 30 secondes
|
||||
|
||||
})
|
||||
// enlève le cadeau avant que le callback soit executé pour ne pas voir le cadeau sur l'alert
|
||||
div_cadeau.style.display = "none";
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue