Um novo país, geografia, clima e costumes. Apesar de todas as novidades com que os imigrantes lidavam ao chegar no Brasil, uma dor era comum e inevitável: a morte. Ter um lugar digno para enterrar os parentes era uma necessidade básica que, na Linha Catarina, em Teutônia, encontrou espaço em um monte, de forma quase…
Antigo cemitério de Linha Catarina em Teutônia será revitalizado pela comunidade
Espaço fica em Linha Catarina Fundos e foi abandonado depois que um novo cemitério foi feito / Crédito: Júlia Amaral
Mais Notícias
.fp-slider-wrap-all {
width: 100%;
position: relative;
display: none; /* Oculto até encontrar posts */
}
.fp-slider-all {
position: relative;
width: 100%;
height: 280px;
overflow: hidden;
border: 1px solid #E6E6E6;
border-radius: 15px;
}
.fp-slide-all {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
opacity: 0;
transition: opacity 0.8s ease;
background-size: cover;
background-position: center;
background-repeat: no-repeat;
border-radius: 15px;
}
.fp-slide-all.active {
opacity: 1;
}
(function() {
var base = 'https://folhapopular.info/wp-json/wp/v2';
function initSlider(containerId, posts) {
var container = document.getElementById(containerId);
var wrapper = document.getElementById('fp-slider-wrap-all');
if (!container) return;
container.innerHTML = '';
var slides = [];
var current = 0;
posts.forEach(function(p) {
var img = '';
if (
p._embedded &&
p._embedded['wp:featuredmedia'] &&
p._embedded['wp:featuredmedia'][0]
) {
img = p._embedded['wp:featuredmedia'][0].source_url;
}
if (!img) return;
var slide = document.createElement('div');
slide.className = 'fp-slide-all';
slide.style.backgroundImage = 'url(' + img + ')';
container.appendChild(slide);
slides.push(slide);
});
/* Se não houver slides, mantém oculto */
if (!slides.length) {
if (wrapper) wrapper.style.display = 'none';
return;
}
/* Exibe o slider somente se houver posts */
if (wrapper) wrapper.style.display = 'block';
slides[0].classList.add('active');
if (slides.length < 2) return;
setInterval(function() {
slides[current].classList.remove('active');
current = (current + 1) % slides.length;
slides[current].classList.add('active');
}, 4000);
}
function loadSlider(categoryId, containerId) {
fetch(base + '/posts?categories=' + categoryId + '&per_page=10&_embed=1')
.then(function(r) { return r.json(); })
.then(function(posts) {
/* Se não houver posts na categoria, oculta o bloco */
if (!posts || !posts.length) {
var wrapper = document.getElementById('fp-slider-wrap-all');
if (wrapper) wrapper.style.display = 'none';
return;
}
initSlider(containerId, posts);
})
.catch(function(e) {
console.log('Erro:', e);
var wrapper = document.getElementById('fp-slider-wrap-all');
if (wrapper) wrapper.style.display = 'none';
});
}
setTimeout(function() {
loadSlider(20860, 'fp-slider-all');
}, 2500);
})();

