Initial commit

This commit is contained in:
sarahgarcin1 2026-01-05 19:33:15 +01:00
commit 388079e6bb
1108 changed files with 330121 additions and 0 deletions

0
site/accounts/index.html Normal file
View file

View file

@ -0,0 +1,4 @@
name: Add blank page
icon: page
wysiwyg: true
preview: box

View file

@ -0,0 +1,4 @@
name: Page Break
icon: box
wysiwyg: true
preview: box

View file

@ -0,0 +1,45 @@
name: Image pleine page
icon: image
wysiwyg: true
preview: image
fields:
location:
label: field.blocks.image.location
type: radio
columns: 2
default: "kirby"
required: true
options:
kirby: "{{ t('field.blocks.image.location.internal') }}"
web: "{{ t('field.blocks.image.location.external') }}"
image:
label: field.blocks.image.name
type: files
query: model.images
multiple: false
image:
back: black
uploads:
template: blocks/image
when:
location: kirby
src:
label: field.blocks.image.url
type: url
when:
location: web
alt:
label: field.blocks.image.alt
type: text
icon: title
caption:
label: field.blocks.image.caption
type: writer
icon: text
inline: true
fullwidth:
label: Image width fit page width
type: toggle
text:
- "off"
- "on"

View file

@ -0,0 +1,60 @@
name: field.blocks.image.name
icon: image
preview: image
fields:
location:
label: field.blocks.image.location
type: radio
columns: 2
default: "kirby"
options:
kirby: "{{ t('field.blocks.image.location.internal') }}"
web: "{{ t('field.blocks.image.location.external') }}"
image:
label: field.blocks.image.name
type: files
query: model.images
multiple: false
image:
back: black
uploads:
template: blocks/image
when:
location: kirby
src:
label: field.blocks.image.url
type: url
when:
location: web
alt:
label: field.blocks.image.alt
type: text
icon: title
caption:
label: field.blocks.image.caption
type: writer
icon: text
inline: true
link:
label: field.blocks.image.link
type: text
icon: url
width:
label: Largeur de l'image
type: select
width: 1/2
options:
16.666%: "16.666%"
20%: "20%"
25%: "25%"
33.333%: "33.333%"
50%: "50%"
66.666%: "66.666%"
100%: "100%"
position:
label: Position de l'image
type: select
width: 1/2
options:
auto: "Centrée"
0: "Alignée à gauche"

View file

@ -0,0 +1,25 @@
name: Interview
icon: question
wysiwyg: true
preview: text
fields:
alignment:
type: toggles
label: Alignement
options:
- value: justify
text: Justify
icon: text-justify
- value: left
text: Left
icon: text-left
- value: center
text: Center
icon: text-center
- value: right
text: Right
icon: text-right
text:
type: writer
nodes: true
placeholder: field.blocks.text.placeholder

View file

@ -0,0 +1,47 @@
name: Image en double page
icon: image
wysiwyg: true
preview: image
fields:
location:
label: field.blocks.image.location
type: radio
columns: 2
default: "kirby"
required: true
options:
kirby: "{{ t('field.blocks.image.location.internal') }}"
web: "{{ t('field.blocks.image.location.external') }}"
image:
label: field.blocks.image.name
type: files
query: model.images
multiple: false
image:
back: black
uploads:
template: blocks/image
when:
location: kirby
src:
label: field.blocks.image.url
type: url
when:
location: web
alt:
label: field.blocks.image.alt
type: text
icon: title
caption:
label: field.blocks.image.caption
type: writer
icon: text
inline: true
fullwidth:
label: Image width fit page width
type: toggle
text:
- "off"
- "on"

View file

@ -0,0 +1,9 @@
name: field.blocks.text.name
icon: text
wysiwyg: true
preview: text
fields:
text:
type: writer
nodes: true
placeholder: field.blocks.text.placeholder

View file

@ -0,0 +1,39 @@
name: field.blocks.video.name
icon: video
preview: video
fields:
# url:
# label: field.blocks.video.url.label
# type: url
# placeholder: field.blocks.video.url.placeholder
location:
label: field.blocks.image.location
type: radio
columns: 2
default: "kirby"
options:
kirby: "{{ t('field.blocks.image.location.internal') }}"
web: "{{ t('field.blocks.image.location.external') }}"
video:
label: field.blocks.video.name
type: files
query: model.videos
multiple: false
video:
back: black
uploads:
template: blocks/video
when:
location: kirby
url:
label: field.blocks.video.url.label
type: url
placeholder: field.blocks.video.url.placeholder
when:
location: web
caption:
label: field.blocks.video.caption
type: writer
inline: true

View file

@ -0,0 +1,20 @@
title: Image
columns:
- width: 1/2
sections:
content:
type: fields
fields:
caption:
label: Légende
type: writer
size: small
- width: 1/2
sections:
meta:
type: fields
fields:
alt:
label: Texte alternatif
type: text

View file

@ -0,0 +1,46 @@
title: Chapitre
columns:
main:
width: 2/3
sections:
fields:
type: fields
fields:
chapeau:
label: Chapeau
type: writer
text:
label: Contenu
type: blocks
fieldsets:
text:
label: Texte
type: group
fieldsets:
- heading
- text
- list
- quote
- interview
media:
label: Media
type: group
fieldsets:
- gallery
- image
- fullpageimage
- spreadimage
others:
label: Autres
type: group
fieldsets:
- break
- blank
sidebar:
width: 1/3
sections:
files:
label: Images
type: files

View file

@ -0,0 +1,35 @@
title: Page
columns:
main:
width: 2/3
sections:
fields:
type: fields
fields:
text:
label: Texte
type: blocks
fieldsets:
text:
label: Texte
type: group
fieldsets:
- heading
- text
- list
- quote
media:
label: Medias
type: group
fieldsets:
- gallery
- image
- video
sidebar:
width: 1/3
sections:
files:
label: Fichiers
type: files

View file

@ -0,0 +1,21 @@
title: Page d'accueil
columns:
main:
width: 2/3
sections:
fields:
type: fields
fields:
bigImage:
label: Image à afficher sur la page d'accueil
type: files
multiple: false
sidebar:
width: 1/3
sections:
files:
label: Fichiers
type: files

View file

@ -0,0 +1,9 @@
title: Print
sections:
info:
type: info
label: Info
text: |
Cette page permet de générer la version print de la revue

83
site/blueprints/site.yml Normal file
View file

@ -0,0 +1,83 @@
title: Site
tabs:
content:
icon: text
label: Content
columns:
main:
width: 1/2
sections:
menu:
label: Chapitres
type: pages
templates:
- chapitre
secondary:
width: 1/2
sections:
pages:
type: pages
label: Autres pages
templates:
- home
- print
- error
settings:
label: Paramètres
icon: settings
columns:
main:
width: 2/3
sections:
content:
type: fields
fields:
logo:
label: Logo
type: files
multiple: false
width: 1/2
cover:
label: Image de couverture
type: files
multiple: false
width: 1/2
copyright:
label: Copyright
type: text
social:
label: Réseaux sociaux
type: structure
fields:
title:
label: Titre
type: text
icon:
label: Icône
type: text
help: Pour trouver votre icône, allez sur <a href="http://fontawesome.io/icons/" target="_blank">http://fontawesome.io/icons/</a>
link:
label: Lien
type: url
description:
label: Description
type: textarea
subject:
label: Sujet du site web
type: textarea
keywords:
label: Mots Clés
type: tags
author:
label: Auteur·ices
type: text
sidebar:
width: 1/3
sections:
files:
type: files

67
site/config/config.php Normal file
View file

@ -0,0 +1,67 @@
<?php
/*
---------------------------------------
Kirby Configuration For Localhost
---------------------------------------
*/
return [
'debug' => true,
'languages' => false,
'smartypants' => [
'attr' => 1,
'doublequote.open' => '«&#8239;',
'doublequote.close' => '&#8239;»',
'doublequote.low' => '&#8222;',
'singlequote.open' => '&#8216;',
'singlequote.close' => '&#8217;',
'backtick.doublequote.open' => '&#8220;',
'backtick.doublequote.close' => '&#8221;',
'backtick.singlequote.open' => '&#8216;',
'backtick.singlequote.close' => '&#8217;',
'emdash' => '&#8212;',
'endash' => '&#8211;',
'ellipsis' => '&#8230;',
'space' => '(?: | |&#8239;|&#0*160;|&#x0*[aA]0;)',
'space.emdash' => ' ',
'space.endash' => ' ',
'space.colon' => '&#8239;',
'space.semicolon' => '&#8239;',
'space.marks' => '&#8239;',
'space.frenchquote' => '&#8239;',
'space.thousand' => '',
'space.unit' => ' ',
'guillemet.leftpointing' => '&#171;',
'guillemet.rightpointing' => '&#187;',
'geresh' => '&#1523;',
'gershayim' => '&#1524;',
'skip' => 'pre|code|kbd|script|style|math',
],
'routes' => [
[
'pattern' => 'sitemap.xml',
'action' => function() {
$pages = site()->pages()->index();
// fetch the pages to ignore from the config settings,
// if nothing is set, we ignore the error page
$ignore = kirby()->option('sitemap.ignore', ['error']);
$content = snippet('sitemap', compact('pages', 'ignore'), true);
// return response with correct header type
return new Kirby\Cms\Response($content, 'application/xml');
}
],
[
'pattern' => 'sitemap',
'action' => function() {
return go('sitemap.xml', 301);
}
],
]
];

View file

@ -0,0 +1,17 @@
<?php
Kirby::plugin('sarahgarcin/notes-tag', [
'tags' => [
'note' => [
'attr' => [
'note',
],
'html' => function($tag) {
$note = $tag->attr('note');
return '<span class="footnote">'.$note.'</span>';
}
]
]
]);

0
site/sessions/index.html Normal file
View file

View file

@ -0,0 +1,2 @@
<?php /** @var \Kirby\Cms\Block $block */ ?>
<div class="blank-page"></div>

View file

@ -0,0 +1,2 @@
<?php /** @var \Kirby\Cms\Block $block */ ?>
<div class="pagebreak"></div>

View file

@ -0,0 +1,27 @@
<?php
/** @var \Kirby\Cms\Block $block */
$alt = $block->alt();
$caption = $block->caption();
$src = null;
$fullWidth = $block->fullwidth()->toBool();
if ($block->location() == 'web') {
$src = $block->src()->esc();
} elseif ($image = $block->image()->toFile()) {
$alt = $alt->or($image->alt());
$src = $image->url();
}
?>
<?php if ($src): ?>
<div class="full-bleed-image full-page">
<figure class="<?= $fullWidth ? 'full-width' : '' ?>">
<img src="<?= $src ?>" alt="<?= $alt->esc() ?>">
<?php if ($caption->isNotEmpty()): ?>
<figcaption><?= $caption ?></figcaption>
<?php endif ?>
</figure>
</div>
<?php endif ?>

View file

@ -0,0 +1,22 @@
<?php
/** @var \Kirby\Cms\Block $block */
$caption = $block->caption();
$crop = $block->crop()->isTrue();
$ratio = $block->ratio()->or('auto');
?>
<figure<?= Html::attr(['data-ratio' => $ratio, 'data-crop' => $crop], null, ' ') ?>>
<ul>
<?php foreach ($block->images()->toFiles() as $image): ?>
<li>
<a href="<?= $image->url() ?>" class="glightbox" <?php if($caption->isNotEmpty()):?> data-glightbox="title: <?= $caption ?>"<?php endif?>>
<?= $image ?>
</a>
</li>
<?php endforeach ?>
</ul>
<?php if ($caption->isNotEmpty()): ?>
<figcaption>
<?= $caption ?>
</figcaption>
<?php endif ?>
</figure>

View file

@ -0,0 +1,39 @@
<?php
/** @var \Kirby\Cms\Block $block */
$alt = $block->alt();
$caption = $block->caption();
$crop = $block->crop()->toBool();
$link = $block->link();
$ratio = $block->ratio()->or('auto');
$src = null;
if ($block->location() == 'web') {
$src = $block->src()->esc();
} elseif ($image = $block->image()->toFile()) {
$alt = $alt->or($image->alt());
$src = $image->url();
}
?>
<?php if ($src): ?>
<figure
data-crop="<?= $crop ? 'true' : 'false' ?>"
data-ratio="<?= $ratio ?>"
style="--ratio: <?= $ratio ?>;"
>
<?php if ($link->isNotEmpty()): ?>
<a href="<?= Str::esc($link->toUrl()) ?>">
<img src="<?= $src ?>" alt="<?= $alt->esc() ?>">
</a>
<?php else: ?>
<img src="<?= $src ?>" alt="<?= $alt->esc() ?>">
<?php endif ?>
<?php if ($caption->isNotEmpty()): ?>
<figcaption>
<?= $caption->kt() ?>
</figcaption>
<?php endif ?>
</figure>
<?php endif ?>

View file

@ -0,0 +1,4 @@
<?php /** @var \Kirby\Cms\Block $block */ ?>
<div class="interview-block alignment-<?= $block->alignment()?>">
<?= $block->text()->kt();?>
</div>

View file

@ -0,0 +1,27 @@
<?php
/** @var \Kirby\Cms\Block $block */
$alt = $block->alt();
$caption = $block->caption();
$src = null;
$fullWidth = $block->fullwidth()->toBool();
if ($block->location() == 'web') {
$src = $block->src()->esc();
} elseif ($image = $block->image()->toFile()) {
$alt = $alt->or($image->alt());
$src = $image->url();
}
?>
<?php if ($src): ?>
<div class="spread-image">
<figure class="<?= $fullWidth ? 'full-width' : '' ?>">
<img src="<?= $src ?>" alt="<?= $alt->esc() ?>">
<?php if ($caption->isNotEmpty()): ?>
<figcaption><?= $caption ?></figcaption>
<?php endif ?>
</figure>
</div>
<?php endif ?>

View file

@ -0,0 +1,3 @@
<?php /** @var \Kirby\Cms\Block $block */ ?>
<?= $block->text()->kt()->smartypants();?>

View file

@ -0,0 +1,30 @@
<?php
use Kirby\Cms\Html;
/** @var \Kirby\Cms\Block $block */
$caption = $block->caption();
$url = null;
$class = null;
if ($block->location() == 'web') {
$url = $block->url()->esc();
$class = "video-from-web";
} elseif ($video = $block->video()->toFile()) {
$url = $video->url();
$class = "video-from-local";
}
?>
<?php if ($video = Html::video($url)): ?>
<figure class="<?= $class ?>">
<?php if ($block->location() == 'web'):?>
<?= $video ?>
<?php else:?>
<video src="<?= $url ?>" controls></video>
<?php endif;?>
<?php if ($caption->isNotEmpty()): ?>
<figcaption><?= $caption ?></figcaption>
<?php endif ?>
</figure>
<?php endif ?>

3
site/snippets/footer.php Normal file
View file

@ -0,0 +1,3 @@
</body>
</html>

78
site/snippets/head.php Normal file
View file

@ -0,0 +1,78 @@
<!DOCTYPE html>
<html lang="fr">
<head>
<!-- Meta Tag -->
<meta charset="utf-8" />
<meta name="robots" content="index,follow">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<meta name="description" content="<?= $site->description()->html() ?>">
<meta name="keywords" content="<?= $site->keywords()->html() ?>">
<meta name="author" content="<?= $site->author()->html() ?>">
<meta name='subject' content="<?= $site->subject()->html() ?>">
<!-- Title -->
<title><?= $site->title()->esc() ?> | <?= $page->title()->esc() ?></title>
<!-- Stylesheets -->
<?= css([
'assets/css/reset.css',
'assets/fonts/stylesheet.css',
'assets/css/variables.css',
'assets/css/main.css',
'@auto'
]) ?>
<?php if($page->intendedTemplate() == "print"):?>
<?= css("assets/pagedjs/interface-header.css")?>
<?= css("assets/pagedjs/interface.css")?>
<?php else: ?>
<?= css([
'assets/css/libs/flexboxgrid.css',
'assets/css/libs/glightbox.min.css',
'assets/css/web.css',
'assets/css/responsive.css',
'@auto'
]) ?>
<?php endif;?>
<?php if($page->intendedTemplate() == "print"):?>
<?= js([
"assets/pagedjs/paged.js",
"assets/pagedjs/interface.js",
"assets/pagedjs/reload-in-place.js",
"assets/js/plugins/csstree.js",
"assets/js/plugins/smartquote.js",
"assets/js/plugins/fix-justif.js",
"assets/js/plugins/fullpage.js",
"assets/js/plugins/full-page.js",
"assets/js/plugins/margin-notes.js",
"assets/js/plugins/toc.js",
'@auto'
]) ?>
<?php else:?>
<?= js([
'assets/js/glightbox.min.js',
'assets/js/main.js',
'@auto'
]) ?>
<?php endif;?>
<!-- Social Networks -->
<meta property="og:title" content="<?= $site->title()->html() ?> | <?= $page->title()->html() ?>">
<meta property="og:description" content="<?= $site->description()->html() ?>">
<?php if ($cover = $site->cover()->toFile()): ?>
<meta property="og:image" content="<?= $cover->url()?>">
<?php endif ?>
<meta name='og:type' content='<?= $site->subject()->html() ?>'>
<meta name='og:url' content='<?= $site->url() ?>'>
<meta name='og:site_name' content='<?= $site->title()->html() ?>'>
</head>
<body
data-login="<?php e($kirby->user(),'true', 'false') ?>"
data-template="<?= $page->template() ?>"
data-intended-template="<?= $page->intendedTemplate() ?>">

5
site/snippets/header.php Normal file
View file

@ -0,0 +1,5 @@
<header role="banner" class="row">
<?php snippet('logo')?>
<?php snippet('nav')?>
</header>

23
site/snippets/item.php Normal file
View file

@ -0,0 +1,23 @@
<li class="col-xs-12 col-sm-6 col-md-4 col-xl-3">
<a href="<?= $projet->url()?>" title="<?= $projet->title()?>">
<?php if($image = $projet->cover()->toFile()):?>
<div class="projets__projet__cover">
<picture>
<source
srcset="<?= $image->thumb(['width' => 680, 'height' => 680, 'crop' => true, 'format' => 'webp'])->url() ?>"
sizes="<?= $sizes ?>"
type="image/webp"
>
<img
loading="lazy"
alt="<?= $image->alt() ?>"
src="<?= $image->thumb(['width' => 680, 'height' => 680, 'crop' => true, 'format' => 'webp'])->url() ?>"
srcset="<?= $image->srcset() ?>"
sizes="<?= $sizes ?>"
>
</picture>
</div>
<?php endif;?>
<p><?= $projet->title()?></p>
</a>
</li>

13
site/snippets/logo.php Normal file
View file

@ -0,0 +1,13 @@
<div class="site__logo col-xs-6 col-sm-3 col-md-4 col-lg-5 col-xl-6 row">
<?php if($logo = $site->logo()->toFile()):?>
<a href="<?= $site->url() ?>" title="<?= $site->title()?>">
<figure>
<?= $logo?>
</figure>
</a>
<?php endif;?>
<h1 class="header__title">
<a href="<?= $site->url() ?>" title="<?= $site->title()?>">
<?= $site->title()->html()?>
</a></h1>
</div>

38
site/snippets/nav.php Normal file
View file

@ -0,0 +1,38 @@
<?php $items = $pages->listed();?>
<?php if($items->isNotEmpty()):?>
<nav class="col-xs-12 col-sm-9 col-md-8 col-lg-7 col-xl-6 row end-xs">
<div class="mobile__menu_btn">
<span></span>
<span></span>
<span></span>
</div>
<ul class='row between-xs col-xs-12 col-sm'>
<?php foreach($items as $item): ?>
<li <?php e($item->isOpen(), ' class="active"') ?>>
<a href="<?= $item->url() ?>"><?= $item->title()->html() ?>
</a>
</li>
<?php endforeach ?>
</ul>
<ul class="social-network end-xs row">
<?php $socials = $site->social()->toStructure();?>
<?php foreach($socials as $social): ?>
<li>
<a href="<?= $social->link()?>" title="<?= $social->title()?>" target="_blank">
<?= $social->icon()?>
</a>
</li>
<?php endforeach; ?>
</ul>
<ul class="languages end-xs row">
<?php foreach($kirby->languages() as $language): ?>
<li<?php e($kirby->language() == $language, ' class="active"') ?>>
<a href="<?= $page->url($language->code()) ?>" hreflang="<?php echo $language->code() ?>">
<?= html($language->code()) ?>
</a>
</li>
<?php endforeach ?>
</ul>
</nav>
<?php endif ?>

View file

@ -0,0 +1,15 @@
<?php snippet('head') ?>
<?php snippet('header') ?>
<main class="default__page" id="fade">
<div class="default__page__wrapper">
<h1><?= $page->title()->html()->smartypants()?></h1>
<?php foreach ($page->text()->toBlocks() as $block): ?>
<div id="<?= $block->id() ?>" class="block block-type-<?= $block->type() ?>">
<?= $block ?>
</div>
<?php endforeach ?>
</div>
</main>
<?php snippet('footer');?>

23
site/templates/home.php Normal file
View file

@ -0,0 +1,23 @@
<?php snippet('head') ?>
<?php snippet('header') ?>
<?php $sizes = "(min-width: 1200px) 25vw,
(min-width: 900px) 33vw,
(min-width: 600px) 50vw,
100vw";
?>
<main class="home" id="fade">
<section>
<?php foreach($site->index()->filterBy('intendedTemplate', 'chapitre') as $chapitre):?>
<article>
<h2><?= $chapitre->title()->html() ?></h2>
<?= $chapitre->text()->toBlocks() ?>
</article>
<?php endforeach;?>
</section>
</main>
<?php snippet('footer');?>

35
site/templates/print.php Normal file
View file

@ -0,0 +1,35 @@
<?php snippet('head') ?>
<?php $sizes = "(min-width: 1200px) 25vw,
(min-width: 900px) 33vw,
(min-width: 600px) 50vw,
100vw";
?>
<header id="interface-header" w3-include-html="assets/pagedjs/interface.html"></header>
<div id="render-book"></div>
<template id="book-content">
<section class="cover">
<h1><?= $site->title()->html()?></h1>
</section>
<section class="toc">
<h2>Sommaire</h2>
<article id="table-of-contents"></article>
</section>
<?php foreach($site->index()->filterBy('intendedTemplate', 'chapitre') as $chapitre):?>
<section class="chapter">
<h2><?= $chapitre->title()->html()->smartypants() ?></h2>
<?php foreach ($chapitre->text()->toBlocks() as $block): ?>
<div id="<?= $block->id() ?>" class="block block-type-<?= $block->type() ?>">
<?= $block ?>
</div>
<?php endforeach ?>
</section>
<?php endforeach;?>
</template>
<?php snippet('footer');?>