Pagina de noticias

This commit is contained in:
2025-09-14 15:46:57 -03:00
parent 27b4a3df67
commit cf44b83ad0
6 changed files with 98 additions and 49 deletions

View File

@@ -218,6 +218,7 @@ function newstc_social_share() {
'twitter' => 'https://twitter.com/intent/tweet?text=' . $post_title . '&url=' . $post_url,
'linkedin' => 'https://www.linkedin.com/shareArticle?mini=true&url=' . $post_url . '&title=' . $post_title,
'whatsapp' => 'https://api.whatsapp.com/send?text=' . $post_title . ' ' . $post_url,
'instagram' => 'https://www.instagram.com', // O Instagram não tem URL de compartilhamento direto. Este link pode ser alterado para o perfil da empresa.
];
echo '<div class="post-share">';

BIN
images/terradorei.pdf Normal file

Binary file not shown.

BIN
images/terradorei_icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.2 KiB

BIN
images/terradorei_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

View File

@@ -12,8 +12,8 @@ get_header();
?>
<main id="primary" class="site-main">
<div class="container">
<div class="latest-news">
<div class="container" style="padding-top: var(--spacing-xl); padding-bottom: var(--spacing-xl);">
<div class="archive-header">
<h1 class="page-title">
<?php
if ( is_home() && ! is_front_page() ) :
@@ -23,56 +23,55 @@ get_header();
endif;
?>
</h1>
<?php if ( have_posts() ) : ?>
<div class="news-grid">
<?php
while ( have_posts() ) :
the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class('news-card'); ?>>
<div class="news-thumbnail">
<?php if (has_post_thumbnail()) : ?>
<a href="<?php the_permalink(); ?>">
<?php the_post_thumbnail('medium'); ?>
</a>
<?php endif; ?>
</div>
<div class="news-content">
<header class="news-header">
<h2 class="news-title"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
<?php newstc_post_meta(); ?>
</header>
<div class="news-excerpt">
<?php the_excerpt(); ?>
</div>
<footer class="news-footer">
<a href="<?php the_permalink(); ?>" class="btn btn-primary"><?php esc_html_e('Leia mais', 'newstc'); ?></a>
</footer>
</div>
</article>
<?php
endwhile;
?>
</div>
<?php
the_posts_pagination(
array(
'prev_text' => '<i class="fas fa-arrow-left"></i> ' . esc_html__( 'Anterior', 'newstc' ),
'next_text' => esc_html__( 'Próximo', 'newstc' ) . ' <i class="fas fa-arrow-right"></i>',
)
);
else :
?>
<p><?php esc_html_e('Nenhuma notícia encontrada.', 'newstc'); ?></p>
<?php
endif;
?>
</div>
<?php if ( have_posts() ) : ?>
<div class="news-grid" style="grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));">
<?php
while ( have_posts() ) :
the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class('news-card'); ?>>
<div class="news-thumbnail">
<?php if (has_post_thumbnail()) : ?>
<a href="<?php the_permalink(); ?>">
<?php the_post_thumbnail('newstc-card'); ?>
</a>
<?php endif; ?>
</div>
<div class="news-content">
<header class="news-header">
<h2 class="news-title"><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2>
<?php newstc_post_meta(); ?>
</header>
<div class="news-excerpt">
<?php the_excerpt(); ?>
</div>
<footer class="news-footer">
<a href="<?php the_permalink(); ?>" class="btn btn-primary"><?php esc_html_e('Leia mais', 'newstc'); ?></a>
</footer>
</div>
</article>
<?php
endwhile;
?>
</div>
<?php
the_posts_pagination(
array(
'prev_text' => '<i class="fas fa-arrow-left"></i> ' . esc_html__( 'Anterior', 'newstc' ),
'next_text' => esc_html__( 'Próximo', 'newstc' ) . ' <i class="fas fa-arrow-right"></i>',
)
);
else :
?>
<p><?php esc_html_e('Nenhuma notícia encontrada.', 'newstc'); ?></p>
<?php
endif;
?>
</div>
</main><!-- #main -->
<?php
get_sidebar();
get_footer();

View File

@@ -1055,9 +1055,11 @@ p {
.share-btn.facebook { background: #1877F2; }
.share-btn.twitter { background: #1DA1F2; }
.share-btn.linkedin { background: #0A66C2; }
.share-btn.instagram { background: #833AB4; } /* Cor roxa do Instagram */
.share-btn.whatsapp { background: #25D366; }
.share-btn.print-btn { background: var(--preto); }
/* Post Navigation */
.post-navigation-container {
max-width: 840px;
@@ -1115,6 +1117,53 @@ p {
color: var(--preto);
}
/*--------------------------------------------------------------
# Pagination
--------------------------------------------------------------*/
.navigation.pagination {
margin-top: var(--spacing-2xl);
font-family: var(--font-heading);
}
.nav-links {
display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap;
gap: var(--spacing-sm);
}
.nav-links .page-numbers {
display: inline-flex;
align-items: center;
justify-content: center;
min-width: 44px;
height: 44px;
padding: 0 var(--spacing-sm);
border: 1px solid var(--cinza);
border-radius: var(--borda-radius);
background-color: var(--branco);
color: var(--azul-principal);
font-weight: 600;
transition: var(--transicao);
box-shadow: var(--sombra);
}
.nav-links .page-numbers:hover {
background-color: var(--azul-principal);
color: var(--branco);
border-color: var(--azul-principal);
transform: translateY(-2px);
box-shadow: var(--sombra-hover);
}
.nav-links .page-numbers.current {
background-color: var(--azul-principal);
color: var(--branco);
border-color: var(--azul-principal);
cursor: default;
}
/* Responsividade */
@media (max-width: 1024px) {
:root {