Commit adfdc686 authored by Sebastien's avatar Sebastien

Added animated text under name

parent fe7fa556
......@@ -44,8 +44,13 @@
<header>
<div class="container">
<div class="title">
<h1>Jurdeczka Sébastien</h1>
<h2>Développeur Web</h2>
<p>
<h1>Jurdeczka Sébastien</h1>
</p>
<p>
<h2 class= "dev"></h2>
</p>
<a class="btn btn-primary" href="documents/CV-Jurdeczka.pdf" download="CV-Jurdeczka.pdf">Télécharger CV</a>
</div>
......@@ -161,6 +166,7 @@
<p class="m-0 text-center text-white">Copyright &copy; Jurdeczka Sébastien 2018</p>
</div>
</footer>
<script src="js/main.js"></script>
<script src="js/jquery.min.js"></script>
<script src="js/bootstrap.bundle.min.js"></script>
<script src="js/jquery.easing.min.js"></script>
......
var tableau = "Développeur Web";
var tabl = [];
var div = document.querySelector(".dev");
var texte = tableau.split('');
var txt = texte.length;
var ok ='';
var msg = txt - 1;
var i = 0;
function boucle(){
for(i = 0 ; i < txt ; i++){
console.log('ok');
texte[i] = ok + texte[i]
tabl.push(texte[i]);
ok = texte[i];
}
}
var bis = 0;
function change(){
div.innerHTML = tabl[bis];
bis ++;
if(bis == txt){
div.innerHTML = "";
var j = 0;
for(j = 0 ; j< tabl.length; j++){
div.innerHTML= tabl[j];
}
}
if(bis >= txt){
bis = msg;
}
}
console.log(tabl)
boucle();
setInterval("change()",150);
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment