Created
June 22, 2020 13:52
-
-
Save vineeshtp/d54439bf3fc0300deedb36edecdbdacf to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<style> | |
#location-name { | |
background:#003344; | |
align-self: center; | |
width: 540px; | |
max-height: 100px; | |
color: #FFFFFF; | |
-webkit-text-stroke-color: #000000; | |
font-size: 42px; | |
line-height: 50px; | |
overflow: hidden; | |
text-overflow: ellipsis; | |
-webkit-line-clamp: 2; | |
-webkit-box-orient: vertical; | |
animation: fade-in 2s; | |
} | |
@keyframes fade-in { | |
0%{ | |
color:black; | |
} | |
30%{ | |
color:blue; | |
} | |
80%{ | |
color:green | |
} | |
from { opacity: 0; } | |
to { opacity: 1; } | |
} | |
@keyframes fade-out { | |
from { opacity: 1; } | |
to { opacity: 0; } | |
} | |
</style> | |
</head> | |
<body> | |
<h1>The animation-timing-function Property</h1> | |
<div id="location-name-container"> | |
<div id="location-name">Hello</div> | |
</div> | |
<script> | |
setInterval(myFunction, 3000) | |
var a = 1 | |
function myFunction(){ | |
document.getElementById('location-name').innerHTML = "Hello"+a | |
a++ | |
} | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment