Initial commit: gustavoo portfolio project
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page about section.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_about_text = (string) gustavoo_portfolio_get_setting( 'about_text' );
|
||||
$gustavoo_about_secondary_text = (string) gustavoo_portfolio_get_setting( 'about_secondary_text' );
|
||||
?>
|
||||
|
||||
<section id="sobre" class="section section--about" aria-labelledby="about-title">
|
||||
<div class="site-shell about-layout">
|
||||
<header class="section__header about-layout__header">
|
||||
<p class="eyebrow"><?php echo esc_html( gustavoo_portfolio_get_setting( 'about_eyebrow' ) ); ?></p>
|
||||
<h2 id="about-title" class="section__title"><?php echo esc_html( gustavoo_portfolio_get_setting( 'about_title' ) ); ?></h2>
|
||||
</header>
|
||||
|
||||
<div class="about-layout__content">
|
||||
<div class="prose prose--lead">
|
||||
<?php echo wp_kses_post( wpautop( esc_html( $gustavoo_about_text ) ) ); ?>
|
||||
<?php echo wp_kses_post( wpautop( esc_html( $gustavoo_about_secondary_text ) ) ); ?>
|
||||
</div>
|
||||
|
||||
<dl class="about-facts" aria-label="<?php esc_attr_e( 'Diferenciais profissionais', 'gustavoo-portfolio' ); ?>">
|
||||
<div class="about-fact">
|
||||
<dt><?php esc_html_e( 'Escopo', 'gustavoo-portfolio' ); ?></dt>
|
||||
<dd><?php esc_html_e( 'Da regra de negócio à infraestrutura', 'gustavoo-portfolio' ); ?></dd>
|
||||
</div>
|
||||
<div class="about-fact">
|
||||
<dt><?php esc_html_e( 'Entrega', 'gustavoo-portfolio' ); ?></dt>
|
||||
<dd><?php esc_html_e( 'Código limpo, documentado e sustentável', 'gustavoo-portfolio' ); ?></dd>
|
||||
</div>
|
||||
<div class="about-fact">
|
||||
<dt><?php esc_html_e( 'Visão', 'gustavoo-portfolio' ); ?></dt>
|
||||
<dd><?php esc_html_e( 'Tecnologia alinhada ao crescimento', 'gustavoo-portfolio' ); ?></dd>
|
||||
</div>
|
||||
</dl>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page contact section.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_contact_form_id = absint( gustavoo_portfolio_get_setting( 'contact_form_id' ) );
|
||||
$gustavoo_email = sanitize_email( (string) gustavoo_portfolio_get_setting( 'email' ) );
|
||||
$gustavoo_privacy_url = get_privacy_policy_url();
|
||||
?>
|
||||
|
||||
<section id="contato" class="section section--contact" aria-labelledby="contact-title">
|
||||
<div class="site-shell contact-panel">
|
||||
<div class="contact-panel__content">
|
||||
<p class="eyebrow"><?php echo esc_html( gustavoo_portfolio_get_setting( 'contact_eyebrow' ) ); ?></p>
|
||||
<h2 id="contact-title" class="section__title"><?php echo esc_html( gustavoo_portfolio_get_setting( 'contact_heading' ) ); ?></h2>
|
||||
<p class="contact-panel__description"><?php echo esc_html( gustavoo_portfolio_get_setting( 'contact_text' ) ); ?></p>
|
||||
|
||||
<?php if ( $gustavoo_email ) : ?>
|
||||
<ul class="contact-list">
|
||||
<?php if ( $gustavoo_email ) : ?>
|
||||
<li><span><?php esc_html_e( 'E-mail', 'gustavoo-portfolio' ); ?></span><a href="<?php echo esc_url( 'mailto:' . $gustavoo_email ); ?>"><?php echo esc_html( antispambot( $gustavoo_email ) ); ?></a></li>
|
||||
<?php endif; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php gustavoo_portfolio_social_links( 'social-links social-links--contact' ); ?>
|
||||
</div>
|
||||
|
||||
<div class="contact-panel__form">
|
||||
<?php gustavoo_portfolio_the_fluent_form( $gustavoo_contact_form_id, 'contact' ); ?>
|
||||
<?php if ( $gustavoo_privacy_url ) : ?>
|
||||
<p class="form-privacy">
|
||||
<?php
|
||||
printf(
|
||||
/* translators: %s: privacy policy URL. */
|
||||
wp_kses_post( __( 'Ao enviar, você concorda com o tratamento dos dados conforme a <a href="%s">Política de Privacidade</a>.', 'gustavoo-portfolio' ) ),
|
||||
esc_url( $gustavoo_privacy_url )
|
||||
);
|
||||
?>
|
||||
</p>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,54 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page hero.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_hero_eyebrow = (string) gustavoo_portfolio_get_setting( 'hero_eyebrow' );
|
||||
$gustavoo_hero_title = (string) gustavoo_portfolio_get_setting( 'hero_title' );
|
||||
$gustavoo_hero_description = (string) gustavoo_portfolio_get_setting( 'hero_description' );
|
||||
$gustavoo_hero_primary_label = (string) gustavoo_portfolio_get_setting( 'hero_primary_label' );
|
||||
$gustavoo_hero_primary_url = (string) gustavoo_portfolio_get_setting( 'hero_primary_url' );
|
||||
$gustavoo_hero_secondary_label = (string) gustavoo_portfolio_get_setting( 'hero_secondary_label' );
|
||||
$gustavoo_hero_secondary_url = (string) gustavoo_portfolio_get_setting( 'hero_secondary_url' );
|
||||
$gustavoo_hero_sources = gustavoo_portfolio_get_picture_sources( 'hero-art' );
|
||||
?>
|
||||
|
||||
<section class="hero-stage" aria-labelledby="hero-title">
|
||||
<div class="site-shell hero">
|
||||
<div class="hero__content">
|
||||
<?php if ( $gustavoo_hero_eyebrow ) : ?>
|
||||
<p class="eyebrow hero__eyebrow"><?php echo esc_html( $gustavoo_hero_eyebrow ); ?></p>
|
||||
<?php endif; ?>
|
||||
|
||||
<h1 id="hero-title" class="hero__title"><?php echo esc_html( $gustavoo_hero_title ); ?></h1>
|
||||
<p class="hero__description"><?php echo esc_html( $gustavoo_hero_description ); ?></p>
|
||||
|
||||
<div class="hero__actions">
|
||||
<?php if ( $gustavoo_hero_primary_label && $gustavoo_hero_primary_url ) : ?>
|
||||
<a class="button button--primary" href="<?php echo esc_url( $gustavoo_hero_primary_url ); ?>">
|
||||
<?php echo esc_html( $gustavoo_hero_primary_label ); ?> <span aria-hidden="true">→</span>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $gustavoo_hero_secondary_label && $gustavoo_hero_secondary_url ) : ?>
|
||||
<a class="button button--secondary" href="<?php echo esc_url( $gustavoo_hero_secondary_url ); ?>">
|
||||
<?php echo esc_html( $gustavoo_hero_secondary_label ); ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="hero__visual" aria-hidden="true">
|
||||
<div class="hero__visual-glow"></div>
|
||||
<picture>
|
||||
<?php if ( $gustavoo_hero_sources['webp'] ) : ?>
|
||||
<source srcset="<?php echo esc_url( $gustavoo_hero_sources['webp'] ); ?>" type="image/webp">
|
||||
<?php endif; ?>
|
||||
<img class="hero__image" src="<?php echo esc_url( $gustavoo_hero_sources['fallback'] ); ?>" width="1234" height="1280" alt="" loading="eager" decoding="async" fetchpriority="high">
|
||||
</picture>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page latest posts.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_blog_limit = max( 1, min( 12, absint( gustavoo_portfolio_get_setting( 'blog_limit', 4 ) ) ) );
|
||||
$gustavoo_posts = new WP_Query(
|
||||
array(
|
||||
'post_type' => 'post',
|
||||
'post_status' => 'publish',
|
||||
'posts_per_page' => $gustavoo_blog_limit,
|
||||
'ignore_sticky_posts' => true,
|
||||
'no_found_rows' => true,
|
||||
)
|
||||
);
|
||||
?>
|
||||
|
||||
<section id="blog" class="section section--posts" aria-labelledby="latest-posts-title">
|
||||
<div class="site-shell">
|
||||
<header class="section__header section__header--split">
|
||||
<div>
|
||||
<p class="eyebrow"><?php echo esc_html( gustavoo_portfolio_get_setting( 'blog_eyebrow' ) ); ?></p>
|
||||
<h2 id="latest-posts-title" class="section__title"><?php echo esc_html( gustavoo_portfolio_get_setting( 'blog_title' ) ); ?></h2>
|
||||
</div>
|
||||
<p class="section__description"><?php echo esc_html( gustavoo_portfolio_get_setting( 'blog_text' ) ); ?></p>
|
||||
</header>
|
||||
|
||||
<?php if ( $gustavoo_posts->have_posts() ) : ?>
|
||||
<div class="posts-grid posts-grid--featured">
|
||||
<?php
|
||||
while ( $gustavoo_posts->have_posts() ) {
|
||||
$gustavoo_posts->the_post();
|
||||
get_template_part( 'template-parts/global/post-card' );
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
|
||||
<p class="section__action"><a class="button button--secondary" href="<?php echo esc_url( gustavoo_portfolio_get_blog_url() ); ?>"><?php esc_html_e( 'Explorar todos os artigos', 'gustavoo-portfolio' ); ?> <span aria-hidden="true">→</span></a></p>
|
||||
<?php else : ?>
|
||||
<div class="section__empty"><p><?php esc_html_e( 'O primeiro artigo está a caminho.', 'gustavoo-portfolio' ); ?></p></div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php wp_reset_postdata(); ?>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,49 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page project grid.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_project_limit = max( 1, min( 24, absint( gustavoo_portfolio_get_setting( 'projects_limit', 6 ) ) ) );
|
||||
$gustavoo_projects = gustavoo_portfolio_get_home_projects( $gustavoo_project_limit );
|
||||
$gustavoo_archive_url = esc_url_raw( (string) gustavoo_portfolio_get_setting( 'projects_archive_url' ) );
|
||||
?>
|
||||
|
||||
<section id="projetos" class="section section--projects" aria-labelledby="projects-title">
|
||||
<div class="site-shell">
|
||||
<header class="section__header section__header--split">
|
||||
<div>
|
||||
<p class="eyebrow"><?php echo esc_html( gustavoo_portfolio_get_setting( 'projects_eyebrow' ) ); ?></p>
|
||||
<h2 id="projects-title" class="section__title"><?php echo esc_html( gustavoo_portfolio_get_setting( 'projects_title' ) ); ?></h2>
|
||||
</div>
|
||||
<p class="section__description"><?php echo esc_html( gustavoo_portfolio_get_setting( 'projects_text' ) ); ?></p>
|
||||
</header>
|
||||
|
||||
<?php if ( $gustavoo_projects ) : ?>
|
||||
<div class="projects-grid">
|
||||
<?php
|
||||
global $post;
|
||||
|
||||
foreach ( $gustavoo_projects as $post ) {
|
||||
setup_postdata( $post );
|
||||
get_template_part( 'template-parts/global/project-card' );
|
||||
}
|
||||
|
||||
wp_reset_postdata();
|
||||
?>
|
||||
</div>
|
||||
<?php else : ?>
|
||||
<div class="section__empty">
|
||||
<p><?php esc_html_e( 'Novos projetos serão publicados aqui em breve.', 'gustavoo-portfolio' ); ?></p>
|
||||
<?php if ( current_user_can( 'edit_posts' ) && post_type_exists( 'gso_project' ) ) : ?>
|
||||
<a class="text-link" href="<?php echo esc_url( admin_url( 'post-new.php?post_type=gso_project' ) ); ?>"><?php esc_html_e( 'Adicionar o primeiro projeto', 'gustavoo-portfolio' ); ?> <span aria-hidden="true">→</span></a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ( $gustavoo_archive_url ) : ?>
|
||||
<p class="section__action"><a class="button button--secondary" href="<?php echo esc_url( $gustavoo_archive_url ); ?>"><?php esc_html_e( 'Ver todos os projetos', 'gustavoo-portfolio' ); ?> <span aria-hidden="true">→</span></a></p>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</section>
|
||||
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
/**
|
||||
* Front-page services section.
|
||||
*
|
||||
* @package Gustavo_Portfolio
|
||||
*/
|
||||
|
||||
$gustavoo_services = gustavoo_portfolio_get_services();
|
||||
?>
|
||||
|
||||
<section id="servicos" class="section section--services" aria-labelledby="services-title">
|
||||
<div class="site-shell">
|
||||
<header class="section__header section__header--split">
|
||||
<div>
|
||||
<p class="eyebrow"><?php echo esc_html( gustavoo_portfolio_get_setting( 'services_eyebrow' ) ); ?></p>
|
||||
<h2 id="services-title" class="section__title"><?php echo esc_html( gustavoo_portfolio_get_setting( 'services_title' ) ); ?></h2>
|
||||
</div>
|
||||
<p class="section__description"><?php echo esc_html( gustavoo_portfolio_get_setting( 'services_description' ) ); ?></p>
|
||||
</header>
|
||||
|
||||
<div class="services-grid">
|
||||
<?php foreach ( $gustavoo_services as $gustavoo_service ) : ?>
|
||||
<article class="service-card">
|
||||
<p class="service-card__number" aria-hidden="true"><?php echo esc_html( $gustavoo_service['number'] ?? '' ); ?></p>
|
||||
<h3 class="service-card__title"><?php echo esc_html( $gustavoo_service['title'] ?? '' ); ?></h3>
|
||||
<p class="service-card__description"><?php echo esc_html( $gustavoo_service['description'] ?? '' ); ?></p>
|
||||
</article>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
Reference in New Issue
Block a user