Edit website structure
This commit is contained in:
parent
2b79d762b3
commit
5921d2fafe
19 changed files with 104 additions and 110 deletions
|
@ -1,7 +1,7 @@
|
|||
title:
|
||||
en: Home
|
||||
fr: Accueil
|
||||
icon: home
|
||||
icon: list-bullet
|
||||
status:
|
||||
draft: true
|
||||
listed: true
|
||||
|
@ -17,5 +17,5 @@ options:
|
|||
delete: false
|
||||
duplicate: false
|
||||
tabs:
|
||||
content: tabs/home_content
|
||||
seo: tabs/home_seo
|
||||
content: tabs/exhibitions_content
|
||||
seo: tabs/exhibitions_seo
|
|
@ -1,7 +1,7 @@
|
|||
title:
|
||||
en: Gallery
|
||||
fr: Galerie
|
||||
icon: file-image
|
||||
icon: images
|
||||
status:
|
||||
draft: true
|
||||
listed: true
|
||||
|
|
|
@ -3,17 +3,6 @@ headline:
|
|||
fr: Expositions
|
||||
type: fields
|
||||
fields:
|
||||
featured_exhibition:
|
||||
label:
|
||||
en: Featured exhibition
|
||||
fr: Exposition mise en avant
|
||||
type: select
|
||||
options: query
|
||||
query:
|
||||
fetch: page.exhibitions.toStructure
|
||||
text: '{{ structureItem.url }}'
|
||||
value: '{{ structureItem.url }}'
|
||||
width: 1/2
|
||||
exhibitions:
|
||||
label:
|
||||
en: Exhibitions
|
|
@ -3,13 +3,14 @@ headline:
|
|||
fr: Pages
|
||||
type: pages
|
||||
templates:
|
||||
- home
|
||||
- about
|
||||
- exhibitions
|
||||
- gallery
|
||||
sortBy: title desc
|
||||
create: false
|
||||
layout: cardlets
|
||||
layout: cards
|
||||
size: small
|
||||
image:
|
||||
ratio: 1/1
|
||||
cover: true
|
||||
query: page.images.template('image').first
|
||||
back: white
|
||||
|
|
9
site/blueprints/tabs/exhibitions_content.yml
Normal file
9
site/blueprints/tabs/exhibitions_content.yml
Normal file
|
@ -0,0 +1,9 @@
|
|||
label:
|
||||
en: Content
|
||||
fr: Contenu
|
||||
icon: text
|
||||
sections:
|
||||
exhibitions: sections/exhibitions_content_exhibitions
|
||||
contact: sections/exhibitions_content_contact
|
||||
|
||||
|
|
@ -3,4 +3,4 @@ label:
|
|||
fr: Référencement
|
||||
icon: search
|
||||
sections:
|
||||
seo_basic_meta: sections/home_seo_metadata
|
||||
seo_basic_meta: sections/exhibitions_seo_metadata
|
|
@ -1,7 +0,0 @@
|
|||
label:
|
||||
en: Content
|
||||
fr: Contenu
|
||||
icon: text
|
||||
sections:
|
||||
exhibitions: sections/home_content_exhibitions
|
||||
|
|
@ -4,4 +4,3 @@ label:
|
|||
icon: home
|
||||
sections:
|
||||
pages: sections/site_content_pages
|
||||
contact: sections/site_content_contact
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
return [
|
||||
// Kirby configuration settings
|
||||
'home' => 'gallery',
|
||||
'panel' => [
|
||||
'language' => 'fr',
|
||||
'css' => 'assets/build/panel.css'
|
||||
|
|
|
@ -10,7 +10,13 @@ return function ($page) {
|
|||
$exhibition['title'] = str_replace(['http://', 'https://', 'www.'], '', $exhibition['url']);
|
||||
}
|
||||
|
||||
// Get contact fields content
|
||||
$email = $page->email();
|
||||
$instagram = $page->instagram();
|
||||
|
||||
return [
|
||||
'exhibitions' => $exhibitions
|
||||
'exhibitions' => $exhibitions,
|
||||
'email' => $email,
|
||||
'instagram' => $instagram
|
||||
];
|
||||
};
|
|
@ -38,54 +38,13 @@
|
|||
|
||||
{% block header %}
|
||||
<header>
|
||||
|
||||
<div class="header-bar">
|
||||
|
||||
<nav class="header-bar__nav" aria-label="Menu">
|
||||
{% if exhibitions is not empty %}
|
||||
<ul class="header-bar__nav-menu">
|
||||
{% for exhibition in exhibitions %}
|
||||
<li class="header-bar__nav-item">
|
||||
{% if exhibition.external_link == false %}
|
||||
<a href="{{ exhibition.url }}" target="iframe">{{ exhibition.title }}</a>
|
||||
{% elseif exhibition.external_link == true %}
|
||||
<a href="{{ exhibition.url }}" target="_blank">{{ exhibition.title }}</a>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</nav>
|
||||
<div class="header-bar__social">
|
||||
<a class="header-bar__gallery-button" href="#" target="_self" aria-label="Show {{ site.title }}'s image gallery">
|
||||
<svg aria-hidden="true" viewBox="0 0 48 48" fill="currentColor">
|
||||
<path d="M17.25 29.15H36.8l-6.35-8.55-5.15 6.75L21.9 23ZM10 38V4h34v34Zm3-3h28V7H13Zm-9 9V10h3v31h31v3Zm9-9V7v28Z"/>
|
||||
</svg>
|
||||
</a>
|
||||
<a class="header-bar__email-button" href="mailto:{{ site.email }}" target="_blank" aria-label="Write an email to {{ site.title }}">
|
||||
<svg aria-hidden="true" viewBox="0 0 48 48" fill="currentColor">
|
||||
<path d="M4 40V8h40v32Zm20-15.1L7 13.75V37h34V13.75Zm0-3L40.8 11H7.25ZM7 13.75V11v2.75Z"/>
|
||||
</svg>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div></div>
|
||||
</header>
|
||||
{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
{% endblock %}
|
||||
|
||||
{% block footer %}
|
||||
<footer>
|
||||
|
||||
<div class="footer-bar">
|
||||
</div>
|
||||
|
||||
</footer>
|
||||
{% endblock %}
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
|
47
site/templates/exhibitions.twig
Normal file
47
site/templates/exhibitions.twig
Normal file
|
@ -0,0 +1,47 @@
|
|||
{% extends "base.twig" %}
|
||||
|
||||
{% block header %}
|
||||
<header>
|
||||
|
||||
<div class="sidebar">
|
||||
<nav class="sidebar__nav" aria-label="Menu">
|
||||
{% if exhibitions is not empty %}
|
||||
<ul class="sidebar__nav-menu">
|
||||
{% for exhibition in exhibitions %}
|
||||
<li class="sidebar__nav-item">
|
||||
{% if exhibition.external_link == false %}
|
||||
<a href="{{ exhibition.url }}" target="iframe">{{ exhibition.title }}</a>
|
||||
{% elseif exhibition.external_link == true %}
|
||||
<a href="{{ exhibition.url }}" target="_blank">{{ exhibition.title }}</a>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</nav>
|
||||
<div class="sidebar__social">
|
||||
<a class="sidebar__gallery-button" href="#" target="_self" aria-label="Show {{ site.title }}'s image gallery">
|
||||
<svg aria-hidden="true" viewBox="0 0 48 48" fill="currentColor">
|
||||
<path d="M17.25 29.15H36.8l-6.35-8.55-5.15 6.75L21.9 23ZM10 38V4h34v34Zm3-3h28V7H13Zm-9 9V10h3v31h31v3Zm9-9V7v28Z"/>
|
||||
</svg>
|
||||
</a>
|
||||
<a class="sidebar__email-button" href="mailto:{{ email }}" target="_blank" aria-label="Write an email to {{ site.title }}">
|
||||
<svg aria-hidden="true" viewBox="0 0 48 48" fill="currentColor">
|
||||
<path d="M4 40V8h40v32Zm20-15.1L7 13.75V37h34V13.75Zm0-3L40.8 11H7.25ZM7 13.75V11v2.75Z"/>
|
||||
</svg>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</header>
|
||||
{% endblock %}
|
||||
|
||||
{% block main %}
|
||||
<main>
|
||||
|
||||
<section class="home-section">
|
||||
<iframe class="home-section__iframe" src="{{ page.featured_exhibition }}" name="iframe"></iframe>
|
||||
</section>
|
||||
|
||||
</main>
|
||||
{% endblock %}
|
1
site/templates/gallery.twig
Normal file
1
site/templates/gallery.twig
Normal file
|
@ -0,0 +1 @@
|
|||
{% extends "base.twig" %}
|
|
@ -1,11 +0,0 @@
|
|||
{% extends "base.twig" %}
|
||||
|
||||
{% block main %}
|
||||
<main>
|
||||
|
||||
<section class="home-section">
|
||||
<iframe class="home-section__iframe" src="{{ page.featured_exhibition }}" name="iframe"></iframe>
|
||||
</section>
|
||||
|
||||
</main>
|
||||
{% endblock %}
|
Loading…
Add table
Add a link
Reference in a new issue