-
Notifications
You must be signed in to change notification settings - Fork 0
/
template-contact.php
62 lines (39 loc) · 1.8 KB
/
template-contact.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?php
/* Template Name: Contact */
$header = get_field( 'header' );
$content = get_field( 'content' );
$contact = get_field( 'contact' );
$button_classes = 'flex justify-center items-center p-10 bg-white text-center border rounded-full';
?>
<?php get_header(); ?>
<?php while ( have_posts() ) : ?>
<?php the_post(); ?>
<main class="flex flex-col flex-grow">
<?php set_query_var( 'title', $header['alt_title'] ?: get_the_title() ); ?>
<?php get_template_part( 'template-parts/blocks/header' ); ?>
<div class="flex flex-wrap flex-grow lg:px-20 text-53 leading-none tracking-tight font-oswald font-light uppercase">
<article class="w-full lg:w-2/3 p-20 lg:text-92">
<div class=""><?php the_content(); ?></div>
</article>
<aside class="flex flex-col w-full lg:w-1/3 p-20 border-t lg:border-t-0 lg:border-l">
<header class="flex -mx-10 pb-20 border-b lg:border-b-0">
<h2 class="w-full px-10" style="font: inherit;"><?php echo esc_html( $contact['email']['text'] ); ?></h2>
<div class="w-full px-10">
<div class="max-w-90 ml-auto">
<div class="relative h-0 text-28 tracking-normal font-medium" style="padding-bottom: 100%;">
<?php $email = "mailto:{$contact['email']['address']}"; ?>
<?php echo do_shortcode( '[button_link url="' . $email . '" class="invisible"]Here[/button_link]' ); ?>
<?php echo do_shortcode( '[button_link url="' . $email . '" class="absolute pin w-full h-full"]Here[/button_link]' ); ?>
</div>
</div>
</div>
</header>
<div class="flex justify-between lg:justify-start mt-auto pt-5">
<?php $social_links = $contact['social']['links']; ?>
<?php require locate_template( 'template-parts/blocks/social-links.php' ); ?>
</div>
</aside>
</div>
</main>
<?php endwhile; ?>
<?php get_footer(); ?>