section : add isTitled option
This commit is contained in:
parent
8a76ab6821
commit
74b9433124
2 changed files with 10 additions and 2 deletions
|
|
@ -6,6 +6,12 @@ tabs:
|
||||||
label: Constructeur
|
label: Constructeur
|
||||||
icon: dashboard
|
icon: dashboard
|
||||||
fields:
|
fields:
|
||||||
|
isTitled:
|
||||||
|
label: Titrée
|
||||||
|
type: toggle
|
||||||
|
default: true
|
||||||
|
help: Affiche le titre de la section.
|
||||||
|
width: 1/4
|
||||||
isIndexed:
|
isIndexed:
|
||||||
label: Indexée
|
label: Indexée
|
||||||
type: toggle
|
type: toggle
|
||||||
|
|
@ -15,7 +21,7 @@ tabs:
|
||||||
backgroundColor:
|
backgroundColor:
|
||||||
extends: fields/color
|
extends: fields/color
|
||||||
label: Couleur de fond
|
label: Couleur de fond
|
||||||
width: 3/4
|
width: 2/4
|
||||||
section:
|
section:
|
||||||
label: Section
|
label: Section
|
||||||
type: layout
|
type: layout
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,9 @@
|
||||||
|
|
||||||
<?php foreach($page->children() as $sectionPage): ?>
|
<?php foreach($page->children() as $sectionPage): ?>
|
||||||
<section id="<?= $sectionPage->slug() ?>" <?= e($sectionPage->backgroundColor()->isNotEmpty() == 'true', ' style="--color: ' . $sectionPage->backgroundColor() . ';"') ?>>
|
<section id="<?= $sectionPage->slug() ?>" <?= e($sectionPage->backgroundColor()->isNotEmpty() == 'true', ' style="--color: ' . $sectionPage->backgroundColor() . ';"') ?>>
|
||||||
<h2 class="h3"><?= $sectionPage->title() ?></h2>
|
<?php if ($sectionPage->isTitled() != 'false'): ?>
|
||||||
|
<h2 class="h3"><?= $sectionPage->title() ?></h2>
|
||||||
|
<?php endif ?>
|
||||||
<?php foreach ($sectionPage->section()->toLayouts() as $layout): ?>
|
<?php foreach ($sectionPage->section()->toLayouts() as $layout): ?>
|
||||||
<div
|
<div
|
||||||
class="section__row grid<?= e($layout->attrs()->imgHeight()->isNotEmpty() == 'true', ' fixed-img-height') ?>"
|
class="section__row grid<?= e($layout->attrs()->imgHeight()->isNotEmpty() == 'true', ' fixed-img-height') ?>"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue