feat: add wordpress site variant

This commit is contained in:
bisco
2026-06-25 07:36:25 +02:00
parent cae9180bc6
commit c66dd7e511
46 changed files with 2091 additions and 136 deletions
@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 860 700" role="img" aria-labelledby="t"><title id="t">Ascolto e movimento</title><rect width="860" height="700" fill="#D8C7AE"/><circle cx="220" cy="220" r="88" fill="#FFF8EF"/><circle cx="638" cy="170" r="76" fill="#A4513B"/><path d="M62 700l101-378c83-24 151 26 202 151l-37 227z" fill="#515D53"/><path d="M487 700l75-408c81-21 151 47 207 202v206z" fill="#4A433A"/><path d="M304 420c122-83 232-112 331-86" fill="none" stroke="#B8674C" stroke-width="18" stroke-linecap="round"/></svg>

After

Width:  |  Height:  |  Size: 538 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 860 700" role="img" aria-labelledby="t"><title id="t">Dietro le quinte</title><rect width="860" height="700" fill="#4A433A"/><path d="M0 0h230v700H0zM630 0h230v700H630z" fill="#A4513B"/><ellipse cx="430" cy="720" rx="275" ry="346" fill="#D8C7AE"/><circle cx="430" cy="286" r="88" fill="#FFF8EF"/><path d="M290 700c24-192 71-298 140-318 82 25 129 131 140 318z" fill="#515D53"/></svg>

After

Width:  |  Height:  |  Size: 436 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 860 700" role="img" aria-labelledby="t"><title id="t">Una scena dello spettacolo finale</title><rect width="860" height="700" fill="#515D53"/><circle cx="430" cy="350" r="251" fill="#B8674C"/><path d="M0 560c234-153 497-163 860-41v181H0z" fill="#D8C7AE"/><path d="M157 560c33-136 90-212 171-228 92 26 151 104 177 236zM496 550c11-121 58-202 142-244 93 43 140 128 141 254z" fill="#4A433A"/><circle cx="326" cy="270" r="52" fill="#FFF8EF"/><circle cx="639" cy="251" r="52" fill="#A4513B"/></svg>

After

Width:  |  Height:  |  Size: 546 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 860 700" role="img" aria-labelledby="t"><title id="t">Il gruppo del laboratorio</title><rect width="860" height="700" fill="#FFF8EF"/><circle cx="430" cy="350" r="292" fill="#D8C7AE"/><circle cx="229" cy="250" r="58" fill="#A4513B"/><circle cx="430" cy="188" r="58" fill="#515D53"/><circle cx="631" cy="250" r="58" fill="#4A433A"/><path d="M111 615c15-171 54-259 117-265 73 4 116 93 130 265z" fill="#4A433A"/><path d="M313 615c13-203 52-304 117-305 75 2 115 104 120 305z" fill="#A4513B"/><path d="M514 615c17-171 56-259 117-265 73 4 116 93 130 265z" fill="#515D53"/></svg>

After

Width:  |  Height:  |  Size: 626 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 960 1120" role="img" aria-labelledby="t d"><title id="t">Il gruppo in scena</title><desc id="d">Composizione astratta ispirata al movimento teatrale</desc><rect width="960" height="1120" fill="#D8C7AE"/><path d="M0 780c208-186 425-245 651-178 133 40 236 107 309 201v317H0z" fill="#515D53"/><circle cx="278" cy="390" r="118" fill="#FFF8EF"/><circle cx="642" cy="320" r="102" fill="#A4513B"/><path d="M137 845c32-266 80-410 145-431 91 17 157 164 198 441z" fill="#4A433A"/><path d="M487 855c38-300 90-461 157-482 96 30 156 191 179 482z" fill="#B8674C"/><path d="M315 525c117 95 219 100 306 15" fill="none" stroke="#F3EBDD" stroke-width="22" stroke-linecap="round"/></svg>

After

Width:  |  Height:  |  Size: 722 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 960 760" role="img" aria-labelledby="t"><title id="t">Esercizio nello spazio</title><rect width="960" height="760" fill="#FFF8EF"/><circle cx="480" cy="380" r="310" fill="#D8C7AE"/><circle cx="306" cy="250" r="72" fill="#A4513B"/><circle cx="670" cy="230" r="68" fill="#515D53"/><path d="M120 700c48-245 111-373 189-384 91 11 155 139 194 384z" fill="#4A433A"/><path d="M480 700c45-258 108-389 190-393 94 20 157 151 188 393z" fill="#B8674C"/><path d="M380 405c108-77 208-86 301-28" fill="none" stroke="#FFF8EF" stroke-width="18" stroke-linecap="round"/></svg>

After

Width:  |  Height:  |  Size: 612 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 700 880" role="img" aria-labelledby="t"><title id="t">Le cose che restano</title><rect width="700" height="880" fill="#4A433A"/><circle cx="350" cy="350" r="245" fill="#D8C7AE"/><path d="M0 610c181-123 414-128 700-15v285H0z" fill="#515D53"/><path d="M214 682c25-186 70-286 136-301 75 21 122 122 140 301z" fill="#A4513B"/><text x="350" y="790" fill="#FFF8EF" text-anchor="middle" font-family="Georgia,serif" font-size="44">LE COSE CHE RESTANO</text></svg>

After

Width:  |  Height:  |  Size: 508 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 700 880" role="img" aria-labelledby="t"><title id="t">Fuori campo</title><rect width="700" height="880" fill="#D8C7AE"/><rect x="76" y="72" width="548" height="624" rx="274" fill="#A4513B"/><circle cx="350" cy="317" r="112" fill="#FFF8EF"/><path d="M145 696c35-223 105-344 205-363 116 24 184 145 205 363z" fill="#515D53"/><text x="350" y="790" fill="#1D1A17" text-anchor="middle" font-family="Georgia,serif" font-size="56">FUORI CAMPO</text></svg>

After

Width:  |  Height:  |  Size: 501 B

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 760 900" role="img" aria-labelledby="t"><title id="t">Ritratto del maestro Ernesto Estatico</title><rect width="760" height="900" fill="#515D53"/><circle cx="380" cy="285" r="142" fill="#D8C7AE"/><path d="M92 900c24-321 120-491 288-511 173 24 269 194 288 511z" fill="#4A433A"/><path d="M258 297c67 42 139 42 215 0" fill="none" stroke="#A4513B" stroke-width="15" stroke-linecap="round"/><circle cx="330" cy="260" r="10" fill="#1D1A17"/><circle cx="430" cy="260" r="10" fill="#1D1A17"/><path d="M0 760c213-78 466-77 760 3v137H0z" fill="#A4513B" opacity=".78"/></svg>

After

Width:  |  Height:  |  Size: 618 B

+22
View File
@@ -0,0 +1,22 @@
<?php
/** Site footer. */
$footer_text = azionelab_mod( 'footer_text' );
$privacy_url = get_privacy_policy_url();
?>
<footer class="site-footer">
<div class="container footer-inner">
<p><strong><?php bloginfo( 'name' ); ?></strong> · <?php echo esc_html( $footer_text ); ?></p>
<p>
<?php if ( $privacy_url ) : ?>
<a href="<?php echo esc_url( $privacy_url ); ?>">Privacy</a>
<?php else : ?>
Privacy — TODO
<?php endif; ?>
· Tema Azione!Lab
</p>
</div>
</footer>
<?php wp_footer(); ?>
</body>
</html>
+185
View File
@@ -0,0 +1,185 @@
<?php
/** Homepage single-page template. */
get_header();
$hero_image = get_theme_mod( 'hero_image' ) ?: azionelab_asset( 'hero.svg' );
$laboratory_image = get_theme_mod( 'laboratory_image' ) ?: azionelab_asset( 'laboratory.svg' );
$teacher_image = get_theme_mod( 'teacher_image' ) ?: azionelab_asset( 'teacher.svg' );
$features = array(
array( 'Per chi inizia', 'Non serve esperienza: serve curiosità, ascolto e voglia di mettersi in gioco.' ),
array( 'Per chi vuole crescere', 'Un tempo regolare per approfondire strumenti, consapevolezza e libertà espressiva.' ),
array( 'Per chi ama il gruppo', 'La scena nasce dalla fiducia: si crea insieme, rispettando tempi e sensibilità diverse.' ),
);
?>
<main id="contenuto">
<section class="hero section" id="inizio" aria-labelledby="hero-title">
<div class="container hero-grid">
<div class="hero-copy">
<p class="eyebrow">Laboratorio teatrale · corpo, voce, relazione</p>
<h1 id="hero-title"><?php echo esc_html( azionelab_mod( 'hero_title' ) ); ?></h1>
<p class="hero-subtitle"><?php echo esc_html( azionelab_mod( 'hero_subtitle' ) ); ?></p>
<div class="button-row">
<a class="button" href="#contatti"><?php echo esc_html( azionelab_mod( 'hero_primary_label' ) ); ?></a>
<a class="text-link" href="#galleria"><?php echo esc_html( azionelab_mod( 'hero_secondary_label' ) ); ?> <span aria-hidden="true">↓</span></a>
</div>
</div>
<figure class="hero-visual">
<img src="<?php echo esc_url( $hero_image ); ?>" alt="Il gruppo durante un esercizio teatrale" width="960" height="1120" fetchpriority="high">
<figcaption>Il gruppo è materia viva.</figcaption>
</figure>
</div>
</section>
<section class="manifesto section" aria-labelledby="manifesto-title">
<div class="container narrow">
<p class="eyebrow">Il nostro modo di lavorare</p>
<h2 id="manifesto-title"><?php echo esc_html( azionelab_mod( 'intro_title' ) ); ?></h2>
<div class="manifesto-text rich-text"><?php echo wp_kses_post( wpautop( azionelab_mod( 'intro_body' ) ) ); ?></div>
</div>
</section>
<section class="features section" aria-labelledby="features-title">
<div class="container">
<p class="eyebrow">Perché partecipare</p>
<h2 id="features-title">Un percorso aperto</h2>
<div class="feature-grid">
<?php foreach ( $features as $index => $feature ) : ?>
<article class="feature-card">
<p class="feature-index"><?php echo esc_html( sprintf( '%02d', $index + 1 ) ); ?></p>
<h3><?php echo esc_html( $feature[0] ); ?></h3>
<p><?php echo esc_html( $feature[1] ); ?></p>
</article>
<?php endforeach; ?>
</div>
</div>
</section>
<section class="section section-sand" id="laboratorio" aria-labelledby="laboratory-title">
<div class="container split-grid">
<div class="editorial-image"><img src="<?php echo esc_url( $laboratory_image ); ?>" alt="Esercizio di movimento nello spazio" width="960" height="760" loading="lazy"></div>
<div>
<p class="eyebrow">Pratica e ricerca</p>
<h2 id="laboratory-title"><?php echo esc_html( azionelab_mod( 'laboratory_title' ) ); ?></h2>
<div class="lead rich-text"><?php echo wp_kses_post( wpautop( azionelab_mod( 'laboratory_body' ) ) ); ?></div>
<ul class="practice-list" aria-label="Aree di lavoro"><li>Corpo</li><li>Voce</li><li>Improvvisazione</li><li>Ascolto</li><li>Presenza scenica</li></ul>
</div>
</div>
</section>
<section class="section" id="maestro" aria-labelledby="teacher-title">
<div class="container teacher-grid">
<div class="teacher-photo"><img src="<?php echo esc_url( $teacher_image ); ?>" alt="Ritratto di <?php echo esc_attr( azionelab_mod( 'teacher_name' ) ); ?>" width="760" height="900" loading="lazy"></div>
<div>
<p class="eyebrow">La guida del percorso</p>
<h2 id="teacher-title">Il maestro</h2>
<h3><?php echo esc_html( azionelab_mod( 'teacher_name' ) ); ?></h3>
<div class="lead rich-text"><?php echo wp_kses_post( wpautop( azionelab_mod( 'teacher_bio' ) ) ); ?></div>
<blockquote>“<?php echo esc_html( azionelab_mod( 'teacher_quote' ) ); ?>”</blockquote>
</div>
</div>
</section>
<section class="lessons section section-sand" id="lezioni" aria-labelledby="lessons-title">
<div class="container">
<div class="section-heading"><div><p class="eyebrow">Informazioni pratiche</p><h2 id="lessons-title">Le lezioni</h2></div><p>Un appuntamento settimanale per allenarsi con continuità, senza fretta.</p></div>
<div class="lesson-panel">
<dl class="lesson-details">
<div><dt>Quando</dt><dd><?php echo esc_html( azionelab_mod( 'lesson_schedule' ) ); ?></dd></div>
<div><dt>Dove</dt><dd><?php echo esc_html( azionelab_mod( 'lesson_location' ) ); ?></dd></div>
<div><dt>Per chi</dt><dd><?php echo esc_html( azionelab_mod( 'lesson_audience' ) ); ?></dd></div>
<div><dt>Cosa facciamo</dt><dd><?php echo wp_kses_post( azionelab_mod( 'lesson_description' ) ); ?></dd></div>
</dl>
<aside class="trial-card">
<p class="eyebrow">Puoi provare</p>
<h3><?php echo esc_html( azionelab_mod( 'trial_lesson' ) ); ?></h3>
<p><?php echo esc_html( azionelab_mod( 'lesson_notes' ) ); ?></p>
<a class="button" href="#contatti">Prenota un incontro</a>
</aside>
</div>
</div>
</section>
<section class="section" id="spettacoli" aria-labelledby="shows-title">
<div class="container">
<div class="section-heading"><div><p class="eyebrow">Spettacoli e progetti</p><h2 id="shows-title">La scena continua</h2></div><p>Esiti, attraversamenti e lavori corali nati durante il percorso.</p></div>
<div class="shows-grid">
<?php
$shows = new WP_Query(
array(
'post_type' => 'azl_show',
'posts_per_page' => 6,
'orderby' => array( 'menu_order' => 'ASC', 'date' => 'DESC' ),
)
);
if ( $shows->have_posts() ) :
$show_index = 0;
while ( $shows->have_posts() ) :
$shows->the_post();
$fallback = azionelab_asset( 0 === $show_index % 2 ? 'show-one.svg' : 'show-two.svg' );
$image = get_the_post_thumbnail_url( get_the_ID(), 'large' ) ?: $fallback;
$year = get_post_meta( get_the_ID(), 'azl_show_year', true );
$location = get_post_meta( get_the_ID(), 'azl_show_location', true );
?>
<article class="show-card">
<img src="<?php echo esc_url( $image ); ?>" alt="Locandina di <?php the_title_attribute(); ?>" width="700" height="880" loading="lazy">
<div class="show-copy"><p class="show-meta"><?php echo esc_html( trim( $year . ' · ' . $location, ' ·' ) ); ?></p><h3><?php the_title(); ?></h3><div><?php the_excerpt(); ?></div></div>
</article>
<?php
++$show_index;
endwhile;
wp_reset_postdata();
else :
?>
<p class="empty-state">I prossimi progetti saranno pubblicati presto.</p>
<?php endif; ?>
</div>
</div>
</section>
<section class="section section-sand" id="galleria" aria-labelledby="gallery-title">
<div class="container">
<div class="section-heading"><div><p class="eyebrow">Dentro il laboratorio</p><h2 id="gallery-title">Galleria</h2></div><p>Lezioni, backstage, spettacoli e il tempo condiviso dal gruppo.</p></div>
<div class="gallery-grid">
<?php
$gallery = new WP_Query(
array(
'post_type' => 'azl_gallery',
'posts_per_page' => 8,
'orderby' => array( 'menu_order' => 'ASC', 'date' => 'DESC' ),
)
);
if ( $gallery->have_posts() ) :
$gallery_index = 0;
while ( $gallery->have_posts() ) :
$gallery->the_post();
$fallback = azionelab_asset( 'gallery-' . ( ( $gallery_index % 4 ) + 1 ) . '.svg' );
$image = get_the_post_thumbnail_url( get_the_ID(), 'large' ) ?: $fallback;
$category = get_post_meta( get_the_ID(), 'azl_gallery_category', true );
?>
<figure class="gallery-item"><img src="<?php echo esc_url( $image ); ?>" alt="<?php the_title_attribute(); ?>" width="860" height="700" loading="lazy"><figcaption><?php echo esc_html( $category ? $category . ' · ' . get_the_title() : get_the_title() ); ?></figcaption></figure>
<?php
++$gallery_index;
endwhile;
wp_reset_postdata();
else :
?>
<p class="empty-state">La galleria sarà aggiornata presto.</p>
<?php endif; ?>
</div>
</div>
</section>
<section class="contacts section" id="contatti" aria-labelledby="contacts-title">
<div class="container contact-grid">
<div><p class="eyebrow">Parliamone</p><h2 id="contacts-title">Vieni a conoscerci</h2><p class="lead">Non serve esperienza: basta la curiosità di incontrare il teatro e il gruppo.</p><p><strong>Dove</strong><br><?php echo esc_html( azionelab_mod( 'contact_address' ) ); ?></p><div class="social-links"><a href="<?php echo esc_url( azionelab_mod( 'contact_instagram' ) ); ?>" rel="noopener noreferrer">Instagram</a><a href="<?php echo esc_url( azionelab_mod( 'contact_facebook' ) ); ?>" rel="noopener noreferrer">Facebook</a></div></div>
<div class="contact-actions">
<a class="contact-action" href="mailto:<?php echo esc_attr( sanitize_email( azionelab_mod( 'contact_email' ) ) ); ?>"><span>Scrivi una mail</span><strong><?php echo esc_html( azionelab_mod( 'contact_email' ) ); ?></strong></a>
<a class="contact-action" href="tel:<?php echo esc_attr( azionelab_phone_href( azionelab_mod( 'contact_phone' ) ) ); ?>"><span>Chiama</span><strong><?php echo esc_html( azionelab_mod( 'contact_phone' ) ); ?></strong></a>
<a class="contact-action" href="https://wa.me/<?php echo esc_attr( azionelab_whatsapp_href( azionelab_mod( 'contact_whatsapp' ) ) ); ?>" rel="noopener noreferrer"><span>WhatsApp</span><strong><?php echo esc_html( azionelab_mod( 'contact_whatsapp' ) ); ?></strong></a>
</div>
</div>
</section>
</main>
<?php
get_footer();
+161
View File
@@ -0,0 +1,161 @@
<?php
/**
* Azione!Lab theme setup and editable homepage fields.
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
function azionelab_defaults(): array {
return array(
'hero_title' => 'Il teatro diventa presenza.',
'hero_subtitle' => 'Un laboratorio dove corpo, voce, ascolto e relazione diventano scena.',
'hero_primary_label' => 'Vieni a conoscerci',
'hero_secondary_label'=> 'Guarda la galleria',
'intro_title' => 'Uno spazio per esserci davvero',
'intro_body' => 'Ogni incontro è uno spazio di pratica: si prova, si sbaglia, si ascolta, si ricomincia. Il gruppo diventa materia viva, la scena diventa occasione di scoperta.',
'laboratory_title' => 'Il laboratorio',
'laboratory_body' => 'Lavoriamo con il corpo, la voce e limprovvisazione per allenare ascolto e presenza scenica. Attraverso esercizi individuali e di gruppo, ogni persona trova un modo autentico di stare nello spazio e nella relazione.',
'teacher_name' => 'Ernesto Estatico',
'teacher_bio' => 'Attore, regista e formatore, accompagna gruppi di ogni esperienza con cura e concretezza. Da oltre quindici anni conduce percorsi dedicati alla ricerca dellautenticità scenica, intrecciando pedagogia teatrale, movimento e lavoro sulla voce.',
'teacher_quote' => 'Il teatro non è fingere: è imparare a essere presenti.',
'lesson_schedule' => 'Ogni martedì, dalle 20:00 alle 22:30',
'lesson_location' => "Spazio Teatro, Via dell'Epomeo 9999, Napoli",
'lesson_audience' => 'Adulti, con o senza esperienza',
'lesson_description' => 'Training fisico e vocale, improvvisazione, ascolto, costruzione del personaggio e lavoro di scena.',
'trial_lesson' => 'La prima lezione di prova è gratuita, su prenotazione.',
'lesson_notes' => 'Abiti comodi e calze antiscivolo consigliati.',
'contact_email' => 'ciao@azionelab.org',
'contact_phone' => '+39 333 123 4567',
'contact_whatsapp' => '+39 333 123 4567',
'contact_instagram' => 'https://instagram.com/',
'contact_facebook' => 'https://facebook.com/',
'contact_address' => "Via dell'Epomeo 9999, Napoli",
'footer_text' => 'Uno spazio aperto a chi desidera incontrare il teatro, insieme.',
);
}
function azionelab_mod( string $key ): string {
$defaults = azionelab_defaults();
return (string) get_theme_mod( $key, $defaults[ $key ] ?? '' );
}
function azionelab_asset( string $filename ): string {
return get_theme_file_uri( 'assets/images/' . $filename );
}
function azionelab_phone_href( string $number ): string {
return preg_replace( '/[^0-9+]/', '', $number ) ?: '';
}
function azionelab_whatsapp_href( string $number ): string {
return preg_replace( '/[^0-9]/', '', $number ) ?: '';
}
function azionelab_setup(): void {
load_theme_textdomain( 'azionelab', get_template_directory() . '/languages' );
add_theme_support( 'title-tag' );
add_theme_support( 'post-thumbnails' );
add_theme_support( 'responsive-embeds' );
add_theme_support(
'html5',
array( 'search-form', 'comment-form', 'comment-list', 'gallery', 'caption', 'style', 'script' )
);
}
add_action( 'after_setup_theme', 'azionelab_setup' );
function azionelab_assets(): void {
wp_enqueue_style( 'azionelab', get_stylesheet_uri(), array(), '1.0.0' );
}
add_action( 'wp_enqueue_scripts', 'azionelab_assets' );
function azionelab_customize_register( WP_Customize_Manager $customizer ): void {
$defaults = azionelab_defaults();
$sections = array(
'azionelab_hero' => array( 'Hero', 30 ),
'azionelab_intro' => array( 'Manifesto e laboratorio', 31 ),
'azionelab_teacher' => array( 'Il maestro', 32 ),
'azionelab_lessons' => array( 'Le lezioni', 33 ),
'azionelab_contacts' => array( 'Contatti e footer', 34 ),
);
foreach ( $sections as $id => $section ) {
$customizer->add_section(
$id,
array( 'title' => $section[0], 'priority' => $section[1] )
);
}
$fields = array(
'hero_title' => array( 'azionelab_hero', 'Titolo', 'text' ),
'hero_subtitle' => array( 'azionelab_hero', 'Sottotitolo', 'textarea' ),
'hero_image' => array( 'azionelab_hero', 'Immagine principale', 'image' ),
'hero_primary_label' => array( 'azionelab_hero', 'Etichetta CTA primaria', 'text' ),
'hero_secondary_label' => array( 'azionelab_hero', 'Etichetta CTA secondaria', 'text' ),
'intro_title' => array( 'azionelab_intro', 'Titolo manifesto', 'text' ),
'intro_body' => array( 'azionelab_intro', 'Testo manifesto', 'textarea_html' ),
'laboratory_title' => array( 'azionelab_intro', 'Titolo laboratorio', 'text' ),
'laboratory_body' => array( 'azionelab_intro', 'Descrizione laboratorio', 'textarea_html' ),
'laboratory_image' => array( 'azionelab_intro', 'Immagine laboratorio', 'image' ),
'teacher_name' => array( 'azionelab_teacher', 'Nome', 'text' ),
'teacher_bio' => array( 'azionelab_teacher', 'Biografia', 'textarea_html' ),
'teacher_quote' => array( 'azionelab_teacher', 'Citazione', 'textarea' ),
'teacher_image' => array( 'azionelab_teacher', 'Foto', 'image' ),
'lesson_schedule' => array( 'azionelab_lessons', 'Quando', 'text' ),
'lesson_location' => array( 'azionelab_lessons', 'Dove', 'text' ),
'lesson_audience' => array( 'azionelab_lessons', 'Per chi', 'text' ),
'lesson_description' => array( 'azionelab_lessons', 'Cosa si fa', 'textarea_html' ),
'trial_lesson' => array( 'azionelab_lessons', 'Lezione di prova', 'text' ),
'lesson_notes' => array( 'azionelab_lessons', 'Note', 'textarea' ),
'contact_email' => array( 'azionelab_contacts', 'Email', 'email' ),
'contact_phone' => array( 'azionelab_contacts', 'Telefono', 'text' ),
'contact_whatsapp' => array( 'azionelab_contacts', 'WhatsApp', 'text' ),
'contact_instagram' => array( 'azionelab_contacts', 'Instagram', 'url' ),
'contact_facebook' => array( 'azionelab_contacts', 'Facebook', 'url' ),
'contact_address' => array( 'azionelab_contacts', 'Indirizzo', 'text' ),
'footer_text' => array( 'azionelab_contacts', 'Testo footer', 'text' ),
);
foreach ( $fields as $id => $field ) {
$type = $field[2];
$sanitize_callback = 'sanitize_text_field';
if ( 'textarea' === $type ) {
$sanitize_callback = 'sanitize_textarea_field';
} elseif ( 'textarea_html' === $type ) {
$sanitize_callback = 'wp_kses_post';
} elseif ( 'email' === $type ) {
$sanitize_callback = 'sanitize_email';
} elseif ( 'url' === $type || 'image' === $type ) {
$sanitize_callback = 'esc_url_raw';
}
$customizer->add_setting(
$id,
array(
'default' => $defaults[ $id ] ?? '',
'sanitize_callback' => $sanitize_callback,
)
);
if ( 'image' === $type ) {
$customizer->add_control(
new WP_Customize_Image_Control(
$customizer,
$id,
array( 'label' => $field[1], 'section' => $field[0] )
)
);
} else {
$customizer->add_control(
$id,
array(
'label' => $field[1],
'section' => $field[0],
'type' => str_starts_with( $type, 'textarea' ) ? 'textarea' : $type,
)
);
}
}
}
add_action( 'customize_register', 'azionelab_customize_register' );
+42
View File
@@ -0,0 +1,42 @@
<?php
/** Site header. */
$site_name = get_bloginfo( 'name' ) ?: 'Azione!Lab';
?>
<!doctype html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#F3EBDD">
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<a class="skip-link" href="#contenuto"><?php esc_html_e( 'Vai al contenuto', 'azionelab' ); ?></a>
<header class="site-header">
<div class="container header-inner">
<a class="wordmark" href="#inizio" aria-label="<?php echo esc_attr( $site_name . ', torna allinizio' ); ?>">
<?php echo esc_html( $site_name ); ?>
</a>
<nav class="desktop-nav" aria-label="<?php esc_attr_e( 'Navigazione principale', 'azionelab' ); ?>">
<a href="#laboratorio">Il laboratorio</a>
<a href="#maestro">Il maestro</a>
<a href="#lezioni">Le lezioni</a>
<a href="#spettacoli">Progetti</a>
<a href="#galleria">Galleria</a>
</nav>
<a class="button button-small desktop-cta" href="#contatti">Vieni a conoscerci</a>
<details class="mobile-menu">
<summary><span class="menu-icon" aria-hidden="true"></span><span>Menu</span></summary>
<nav aria-label="<?php esc_attr_e( 'Navigazione mobile', 'azionelab' ); ?>">
<a href="#laboratorio">Il laboratorio</a>
<a href="#maestro">Il maestro</a>
<a href="#lezioni">Le lezioni</a>
<a href="#spettacoli">Progetti</a>
<a href="#galleria">Galleria</a>
<a class="button button-small" href="#contatti">Vieni a conoscerci</a>
</nav>
</details>
</div>
</header>
+21
View File
@@ -0,0 +1,21 @@
<?php
/** Fallback template. */
get_header();
?>
<main id="contenuto" class="section">
<div class="container narrow">
<?php if ( have_posts() ) : ?>
<?php while ( have_posts() ) : the_post(); ?>
<article <?php post_class(); ?>>
<h1><?php the_title(); ?></h1>
<div class="rich-text"><?php the_content(); ?></div>
</article>
<?php endwhile; ?>
<?php else : ?>
<p><?php esc_html_e( 'Nessun contenuto disponibile.', 'azionelab' ); ?></p>
<?php endif; ?>
</div>
</main>
<?php
get_footer();
+217
View File
@@ -0,0 +1,217 @@
/*
Theme Name: Azione!Lab
Theme URI: https://azionelab.org
Author: Azione!Lab
Description: Editorial single-page theme for the Azione!Lab theatre workshop.
Version: 1.0.0
Requires at least: 7.0
Requires PHP: 8.3
Text Domain: azionelab
*/
:root {
--color-bg: #f3ebdd;
--color-bg-light: #fff8ef;
--color-dark: #4a433a;
--color-dark-soft: #5a5046;
--color-dark-text: #1d1a17;
--color-primary: #a4513b;
--color-primary-soft: #b8674c;
--color-sage: #515d53;
--color-sand: #d8c7ae;
--color-muted: #7a7067;
--color-border: #e6d8c8;
--font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
--font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
--shadow: 0 24px 70px rgba(74, 67, 58, 0.14);
--radius: 1.25rem;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
margin: 0;
color: var(--color-dark-text);
background: var(--color-bg);
font-family: var(--font-sans);
font-size: 1rem;
line-height: 1.65;
overflow-x: hidden;
}
body::before {
position: fixed;
inset: 0;
z-index: -1;
content: "";
opacity: 0.28;
pointer-events: none;
background-image: radial-gradient(rgba(74, 67, 58, 0.1) 0.6px, transparent 0.6px);
background-size: 8px 8px;
}
img { display: block; width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 {
font-family: var(--font-serif);
font-weight: 500;
line-height: 0.98;
letter-spacing: -0.025em;
}
h1 { max-width: 10ch; margin-bottom: 1.5rem; font-size: clamp(3.4rem, 12vw, 7.8rem); }
h2 { margin-bottom: 1.5rem; font-size: clamp(2.7rem, 8vw, 5.25rem); }
h3 { margin-bottom: 0.75rem; font-size: clamp(1.65rem, 4vw, 2.35rem); }
.container { width: min(100% - 2rem, 76rem); margin-inline: auto; }
.narrow { width: min(100%, 48rem); }
.section { padding-block: clamp(4.5rem, 10vw, 8.5rem); }
.section-sand { background: rgba(216, 199, 174, 0.5); }
.eyebrow {
margin-bottom: 1rem;
color: var(--color-primary);
font-size: 0.76rem;
font-weight: 750;
letter-spacing: 0.15em;
text-transform: uppercase;
}
.lead { max-width: 42rem; color: var(--color-dark-soft); font-size: clamp(1.14rem, 2.5vw, 1.42rem); }
.rich-text > :last-child { margin-bottom: 0; }
.skip-link {
position: fixed;
top: 0.75rem;
left: 0.75rem;
z-index: 100;
padding: 0.65rem 1rem;
color: white;
background: var(--color-dark-text);
transform: translateY(-200%);
}
.skip-link:focus { transform: none; }
.site-header {
position: sticky;
top: 0;
z-index: 50;
border-bottom: 1px solid rgba(230, 216, 200, 0.8);
background: rgba(243, 235, 221, 0.93);
backdrop-filter: blur(14px);
}
.header-inner { display: flex; min-height: 4.7rem; align-items: center; justify-content: space-between; gap: 1rem; }
.wordmark { font-family: var(--font-serif); font-size: 1.65rem; font-weight: 700; text-decoration: none; }
.desktop-nav { display: none; gap: 1.6rem; font-size: 0.92rem; }
.desktop-nav a { text-decoration: none; }
.desktop-nav a:hover { color: var(--color-primary); }
.desktop-cta { display: none !important; }
.mobile-menu { position: relative; }
.mobile-menu summary { display: flex; cursor: pointer; align-items: center; gap: 0.6rem; font-weight: 700; list-style: none; }
.mobile-menu summary::-webkit-details-marker { display: none; }
.menu-icon, .menu-icon::before, .menu-icon::after { display: block; width: 1.35rem; height: 2px; background: currentColor; }
.menu-icon { position: relative; }
.menu-icon::before, .menu-icon::after { position: absolute; left: 0; content: ""; }
.menu-icon::before { top: -0.38rem; }
.menu-icon::after { top: 0.38rem; }
.mobile-menu nav {
position: absolute;
top: 2.35rem;
right: 0;
display: grid;
width: min(20rem, calc(100vw - 2rem));
padding: 1rem;
border: 1px solid var(--color-border);
border-radius: 1rem;
background: var(--color-bg-light);
box-shadow: var(--shadow);
}
.mobile-menu nav a { padding: 0.65rem; text-decoration: none; }
.button-row { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.4rem; }
.button {
display: inline-flex;
min-height: 3rem;
padding: 0.75rem 1.25rem;
border: 1px solid var(--color-primary);
border-radius: 999px;
align-items: center;
justify-content: center;
color: white;
background: var(--color-primary);
font-weight: 750;
text-decoration: none;
transition: transform 180ms ease, background 180ms ease;
}
.button:hover { background: var(--color-primary-soft); transform: translateY(-2px); }
.button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid var(--color-sage); outline-offset: 4px; }
.button-small { min-height: 2.5rem; padding: 0.55rem 1rem; font-size: 0.9rem; }
.text-link { color: var(--color-dark); font-weight: 750; text-underline-offset: 0.3em; }
.hero { padding-top: clamp(3rem, 8vw, 6.5rem); }
.hero-grid { display: grid; align-items: center; gap: 3rem; }
.hero-subtitle { max-width: 35rem; margin-bottom: 2rem; color: var(--color-dark-soft); font-size: clamp(1.15rem, 3vw, 1.45rem); }
.hero-visual { position: relative; margin: 0; }
.hero-visual img { aspect-ratio: 5 / 6; border-radius: 48% 48% 1.5rem 1.5rem; object-fit: cover; box-shadow: var(--shadow); }
.hero-visual figcaption { position: absolute; right: -0.25rem; bottom: 1.25rem; padding: 0.65rem 0.9rem; background: var(--color-bg-light); font-family: var(--font-serif); font-style: italic; }
.manifesto { position: relative; text-align: center; }
.manifesto::before { display: block; width: 4rem; height: 1px; margin: 0 auto 2rem; content: ""; background: var(--color-primary); }
.manifesto-text { font-family: var(--font-serif); font-size: clamp(1.55rem, 4vw, 2.6rem); line-height: 1.25; }
.features { padding-top: 0; }
.feature-grid { display: grid; gap: 1rem; }
.feature-card { min-height: 15rem; padding: 2rem; border: 1px solid var(--color-border); border-radius: var(--radius); background: rgba(255, 248, 239, 0.72); }
.feature-index { color: var(--color-primary); font-family: var(--font-serif); font-size: 1.2rem; }
.split-grid, .teacher-grid { display: grid; align-items: center; gap: 3rem; }
.editorial-image img, .teacher-photo img { aspect-ratio: 5 / 4; border-radius: var(--radius); object-fit: cover; box-shadow: var(--shadow); }
.teacher-photo img { aspect-ratio: 4 / 5; }
.practice-list { display: flex; margin: 2rem 0 0; padding: 0; flex-wrap: wrap; gap: 0.6rem; list-style: none; }
.practice-list li { padding: 0.45rem 0.8rem; border: 1px solid var(--color-sand); border-radius: 999px; background: var(--color-bg-light); }
blockquote { margin: 2rem 0 0; padding-left: 1.5rem; border-left: 3px solid var(--color-primary); font-family: var(--font-serif); font-size: clamp(1.5rem, 3vw, 2.25rem); font-style: italic; }
.section-heading { margin-bottom: 2.5rem; }
.lesson-panel { display: grid; overflow: hidden; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-bg-light); box-shadow: var(--shadow); }
.lesson-details { display: grid; margin: 0; padding: 2rem; gap: 1.5rem; }
.lesson-details div { padding-bottom: 1.2rem; border-bottom: 1px solid var(--color-border); }
.lesson-details div:last-child { border-bottom: 0; }
.lesson-details dt { margin-bottom: 0.25rem; color: var(--color-primary); font-weight: 750; }
.lesson-details dd { margin: 0; }
.trial-card { padding: 2rem; color: var(--color-bg-light); background: var(--color-sage); }
.trial-card .eyebrow { color: var(--color-sand); }
.shows-grid { display: grid; gap: 1.25rem; }
.show-card { overflow: hidden; border: 1px solid var(--color-border); border-radius: var(--radius); background: var(--color-bg-light); }
.show-card img { aspect-ratio: 4 / 5; object-fit: cover; }
.show-copy { padding: 1.4rem; }
.show-meta { color: var(--color-primary); font-size: 0.85rem; font-weight: 750; letter-spacing: 0.08em; text-transform: uppercase; }
.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
.gallery-item { position: relative; overflow: hidden; margin: 0; border-radius: 1rem; background: var(--color-sand); }
.gallery-item img { aspect-ratio: 1 / 1; object-fit: cover; transition: transform 300ms ease; }
.gallery-item:hover img { transform: scale(1.025); }
.gallery-item figcaption { position: absolute; right: 0.6rem; bottom: 0.6rem; left: 0.6rem; padding: 0.5rem 0.7rem; border-radius: 0.65rem; color: white; background: rgba(29, 26, 23, 0.76); font-size: 0.84rem; }
.empty-state { padding: 2rem; border: 1px dashed var(--color-muted); border-radius: var(--radius); color: var(--color-muted); text-align: center; }
.contacts { color: var(--color-bg-light); background: var(--color-dark); }
.contacts .eyebrow { color: var(--color-primary-soft); }
.contact-grid { display: grid; gap: 2.5rem; }
.contact-actions { display: grid; gap: 0.8rem; }
.contact-action { display: grid; padding: 1rem 1.1rem; border: 1px solid rgba(255,255,255,0.18); border-radius: 0.9rem; text-decoration: none; }
.contact-action span { color: var(--color-sand); font-size: 0.78rem; text-transform: uppercase; }
.social-links { display: flex; margin-top: 1.25rem; flex-wrap: wrap; gap: 1rem; }
.site-footer { padding-block: 2rem; color: var(--color-bg-light); background: var(--color-dark-text); }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.75rem 1.5rem; font-size: 0.85rem; }
.footer-inner p { margin: 0; }
@media (min-width: 44rem) {
.container { width: min(100% - 3rem, 76rem); }
.hero-grid, .split-grid, .teacher-grid { grid-template-columns: 1fr 0.82fr; gap: clamp(3rem, 7vw, 6rem); }
.split-grid { grid-template-columns: 0.95fr 1.05fr; }
.feature-grid { grid-template-columns: repeat(3, 1fr); }
.lesson-panel { grid-template-columns: 1.5fr 0.8fr; }
.lesson-details { grid-template-columns: repeat(2, 1fr); }
.shows-grid { grid-template-columns: repeat(2, 1fr); }
.gallery-grid { grid-template-columns: repeat(4, 1fr); }
.gallery-item:nth-child(3n + 1) { grid-column: span 2; }
.contact-grid { grid-template-columns: 1fr 0.9fr; }
}
@media (min-width: 64rem) {
.desktop-nav { display: flex; }
.desktop-cta { display: inline-flex !important; }
.mobile-menu { display: none; }
.shows-grid { grid-template-columns: repeat(3, 1fr); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 2rem; }
.section-heading > p { max-width: 31rem; }
}
@media (prefers-reduced-motion: reduce) {
html { scroll-behavior: auto; }
*, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}