Feature/TouristAttractionsAutoJs #1
14
js.js
14
js.js
@ -11,7 +11,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
const inputDescription = document.querySelector('.input-text__descricao');
|
||||
const form = document.querySelector('.form__tourist-attractions');
|
||||
|
||||
const ulList = document.querySelector('wrapper-ul__cards');
|
||||
const ulList = document.querySelector('.wrapper-ul__cards');
|
||||
|
||||
//Image Preview
|
||||
inputFile.addEventListener('change', (e) => {
|
||||
@ -75,23 +75,23 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
}else {
|
||||
alert('Preencha todos os campos')
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
|
||||
const renderListItems = () => {
|
||||
function renderListItems () {
|
||||
let spotStructure = '';
|
||||
|
||||
list.forEach((i) => {
|
||||
list.forEach(function (i) {
|
||||
spotStructure += `
|
||||
<li class="wrapper-cards__li">
|
||||
|
||||
<div class="cards">
|
||||
<div class="result-card__img">
|
||||
<img class="result-card__img" src="${i.image}" alt="Imagem Turismo" />
|
||||
</div>
|
||||
|
||||
<div class="result-card__text">
|
||||
<h2 class="result-card__title">${i.titulo}</h2>
|
||||
p class="result-card__description">${i.description}</p>
|
||||
<p> class="result-card__description">${i.description}</p>
|
||||
</div>
|
||||
|
||||
</li>
|
||||
@ -100,7 +100,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
|
||||
|
||||
|
||||
// ulList.innerHTML = spotStructure;
|
||||
ulList.innerHTML = spotStructure;
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user