Commit b8f7e420 authored by Evan GISDAL's avatar Evan GISDAL

Corrections gulp et ajout fermeture popup

parent 34da9fb1
......@@ -21,11 +21,17 @@ async function artistSelected(evt) {
let aside = document.querySelector('aside');
aside.style.visiblity = 'visible';
aside.style.opacity = '1';
aside.style.transition = 'all 1s';
aside.style.transition = 'all 1s ease-out';
let body = document.querySelector('body');
aside.style.top = `${body.clientHeight/2 - aside.clientHeight/2}px`;
aside.style.left = `${body.clientWidth/2 - aside.clientWidth/2}px`;
aside.style.top = `${body.clientHeight / 2 - aside.clientHeight / 2}px`;
aside.style.left = `${body.clientWidth / 2 - aside.clientWidth / 2}px`;
console.log(aside);
let button = aside.querySelector('button');
console.log(button);
button.addEventListener('click', () => aside.style.opacity = '0');
}
else {
throw new Error('Mauvaise réponse du réseau');
......@@ -70,7 +76,7 @@ async function loadArtists(genre, _contenu) {
li.appendChild(a);
a.appendChild(h3);
a.setAttribute('href', '#');
a.setAttribute('id',element.id);
a.setAttribute('id', element.id);
h3.innerHTML = element.name;
img.setAttribute('src', element.photo);
img.setAttribute('alt', `picture of ${element.name}`);
......
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