redesign hero blueprint

This commit is contained in:
isUnknown 2024-07-29 18:41:34 +02:00
parent ec89064d39
commit aa265db0d3
5 changed files with 84 additions and 18 deletions

16
assets/css/panel.css Normal file
View file

@ -0,0 +1,16 @@
:root {
--color-salmon: #ff4f4b;
}
.k-field-name-herotext .k-block-type-heading-input[data-level="h3"] .k-text {
color: var(--color-salmon);
}
.k-field-name-herotext
.k-block-container-fieldset-hero-heading:nth-child(odd)
.k-text {
text-align: right;
}
.k-field-name-herotext .k-block-type-heading-input[data-level="h2"] .k-text {
text-align: center;
}

View file

@ -0,0 +1,23 @@
name: field.blocks.heading.name
icon: title
wysiwyg: true
preview: heading
fields:
level:
label: field.blocks.heading.level
type: toggles
empty: false
default: "h2"
labels: false
options:
- value: h2
icon: h2
text: H2
- value: h3
icon: h3
text: H3
text:
label: field.blocks.heading.text
type: writer
inline: true
placeholder: field.blocks.heading.placeholder

View file

@ -0,0 +1,15 @@
name: field.blocks.text.name
icon: text
wysiwyg: true
preview: text
fields:
text:
type: writer
nodes: false
placeholder: field.blocks.text.placeholder
maxlength: 336
marks:
- bold
- italic
- link
- email

View file

@ -20,31 +20,40 @@ tabs:
label: Hero label: Hero
- width: 1/2 - width: 1/2
fields: fields:
heroHeading: heroMode:
label: Titre label: Mode
type: text type: radio
heroSubtitleOne: columns: 2
label: Sous-titre default: nextEvent
type: text options:
help: Première ligne. nextEvent: Prochain événement
width: 1/2 custom: Personnalisé
heroSubtitleTwo:
label: Sous-titre
type: text
help: Deuxième ligne.
width: 1/2
heroText: heroText:
label: Texte label: Text
type: writer type: blocks
max: 500 when:
heroMode: custom
fieldsets:
- hero-heading
- hero-text
heroLinkUrl: heroLinkUrl:
label: Lien label: Lien
type: url type: link
width: 1/2 width: 1/2
options:
- url
- page
- file
- email
help: Optionnel. Laisser vide pour ne pas afficher de lien dans le hero.
when:
heroMode: custom
heroLinkText: heroLinkText:
label: Texte du Lien label: Texte du Lien
type: text type: text
width: 1/2 width: 1/2
when:
heroMode: custom
- width: 1/2 - width: 1/2
fields: fields:
heroImage: heroImage:
@ -63,7 +72,7 @@ tabs:
type: line type: line
calloutHeadline: calloutHeadline:
type: headline type: headline
label: Callout label: Brève
calloutText: calloutText:
label: Texte label: Texte
type: writer type: writer

View file

@ -2,6 +2,9 @@
return [ return [
'debug' => true, 'debug' => true,
'panel' => [
'css' => 'assets/css/panel.css'
],
'routes' => [ 'routes' => [
require_once(__DIR__ . '/routes/mapado-api.php'), require_once(__DIR__ . '/routes/mapado-api.php'),
require_once(__DIR__ . '/routes/month-dates.php') require_once(__DIR__ . '/routes/month-dates.php')