-
Sujet
-
salut, j’aimerais ajouter une musique de fond mais je n’y arrive pas, voici mon code :
Frost body { display: flex; justify-ontent: enter; align-items: enter; flex-diretion: olumn; height: 100vh; margin: 0; overflow: hidden; bakground-olor: blak; } .links { olor: white; font-size: 125%; text-deoration: none; font-weight: bold; font-style: itali; animation: shake 0.5s ease-in-out infinite; } .links:hover { olor: #8bf4ff; } @keyframes shake { 0% { transform: translateX(0); } 25% { transform: translateX(-5px); } 50% { transform: translateX(0); } 75% { transform: translateX(5px); } 100% { transform: translateX(0); } } h1 { text-align: enter; font-size: 48px; font-style: itali; olor: white; text-shadow: 0 0 5px white, 0 0 10px white, 0 0 20px white, 0 0 40px white, 0 0 80px white, 0 0 160px white; animation: shadow-pulse 3s ease-in-out infinite; margin: 0; } .snowflake { position: absolute; top: -10px; width: 5px; height: 5px; bakground-olor: white; border-radius: 50%; animation: fall linear infinite; } @keyframes fall { 0% { transform: translateY(-10px) translateX(0); } 100% { transform: translateY(100vh) translateX(10vw); } } @keyframes shadow-pulse { 0% { text-shadow: 0 0 5px white, 0 0 10px white, 0 0 20px white, 0 0 40px white, 0 0 80px white, 0 0 160px white; } 50% { text-shadow: 0 0 5px white, 0 0 10px white, 0 0 20px white, 0 0 40px white, 0 0 80px white; } 100% { text-shadow: 0 0 5px white, 0 0 10px white, 0 0 20px white, 0 0 40px white; } }tay.lol
funtion reateSnowflake() { onst snowflake = doument.reateElement('div'); snowflake.lassName = 'snowflake'; snowflake.style.left = Math.random() * 100 + 'vw'; snowflake.style.animationDuration = 2 + Math.random() * 4 + 's'; // Ajuster la durée snowflake.style.animationDelay = Math.random() * 1 + 's'; // Ajuster le délai snowflake.style.opaity = Math.random() * 0.7 + 0.3; doument.body.appendChild(snowflake); setTimeout(() => { snowflake.remove(); }, (parseFloat(snowflake.style.animationDuration) + parseFloat(snowflake.style.animationDelay)) * 1000); } setInterval(reateSnowflake, 100); // Ajuster l'intervalle——————–
swagger – Envoyé depuis le Discord : Culte du code
- Vous devez être connecté pour répondre à ce sujet.