diff --git a/site/blueprints/pages/project.yml b/site/blueprints/pages/project.yml index a060a6e..e0ae6db 100644 --- a/site/blueprints/pages/project.yml +++ b/site/blueprints/pages/project.yml @@ -52,24 +52,43 @@ tabs: - link maxlength: 500 help: Description complète du projet + test: + type: fields + fields: + keywords: + label: Mots clés + type: structure + fields: + label: + label: Label + required: true + type: text + width: 1/2 + placeholder: "Ex: Impact, Catégorie..." + text: + label: Texte + required: true + type: text + width: 1/2 + externalLinks: + label: Liens externes + type: structure + fields: + label: + label: Nom du bouton + required: true + type: text + width: 1/2 + placeholder: "Ex: App Store, Site web..." + url: + label: URL + required: true + type: url + width: 1/2 images: type: fields fields: - imagesGallery: - width: 2/3 - label: Galerie d'images - type: files - layout: cards - size: small - min: 6 - accept: image/* - translate: false - image: - back: #ffffff - uploads: - template: image - help: "Une animation sera générée à partir des images de ce champ. Minimum optimal d'images : 6" mockup: width: 1/3 label: Image de mise en situation @@ -107,60 +126,56 @@ tabs: uploads: template: image help: Petite image carrée représentant le jeu - galleryAnimationMode: - label: Mode d'animation de la galerie - type: toggles - default: vertical - options: - - value: vertical - text: Vertical - icon: arrow-up-down - - value: horizontal - text: Horizontal - icon: arrow-left-right - help: "Direction du défilement des images dans la galerie animée" - galleryBackgroundColor: - label: Couleur d'arrière-plan de la galerie animée - type: color - alpha: false - galleryBackgroundImage: - label: Image d'arrière-plan - type: files - multiple: false - keywords: - label: Mots clés - type: structure - fields: - label: - label: Label - required: true - type: text - width: 1/2 - placeholder: "Ex: Impact, Catégorie..." - text: - label: Texte - required: true - type: text - width: 1/2 - - # Liens externes - links: - type: fields - fields: - externalLinks: - label: Liens externes - type: structure - fields: - label: - label: Nom du bouton - required: true - type: text - width: 1/2 - placeholder: "Ex: App Store, Site web..." - url: - label: URL - required: true - type: url - width: 1/2 - + animation: + icon: video + columns: + - width: 1/2 + fields: + imagesGallery: + label: Galerie d'images + type: files + layout: cards + size: small + min: 6 + accept: image/* + translate: false + image: + back: #ffffff + uploads: + template: image + help: | + Minimum 6 images + - width: 1/2 + fields: + galleryAnimationMode: + label: Mode d'animation de la galerie + type: toggles + default: vertical + options: + - value: vertical + text: Vertical + icon: arrow-up-down + - value: horizontal + text: Horizontal + icon: arrow-left-right + help: "Direction du défilement des images dans la galerie animée" + secondsPerImage: + label: Durée de l'animation + type: range + default: 8 + min: 3 + max: 12 + after: secondes + help: | + Temps qu'une image mets pour traverser le conteneur de l'animation. + **Augmenter la valeur ralentira l'animation, et inversement.** + galleryBackgroundColor: + label: Couleur d'arrière-plan de la galerie animée + type: color + alpha: false + galleryBackgroundImage: + label: Image d'arrière-plan + type: files + layout: cards + multiple: false seo: seo/page diff --git a/site/templates/portfolio.json.php b/site/templates/portfolio.json.php index 9335ccd..ae874d5 100644 --- a/site/templates/portfolio.json.php +++ b/site/templates/portfolio.json.php @@ -18,6 +18,7 @@ $specificData = [ 'mockupSrcset' => $project->mockup()->toFile()?->srcset('mockup'), 'mockupWebp' => $project->mockup()->toFile()?->srcset('mockup-webp'), 'galleryAnimationMode' => $project->galleryAnimationMode()->value() ?: 'vertical', + 'secondsPerImage' => $project->secondsPerImage()->isNotEmpty() ? (int) $project->secondsPerImage()->value() : 8, 'galleryBackgroundColor' => $project->galleryBackgroundColor()->value(), 'galleryBackgroundImage' => $project->galleryBackgroundImage()->isNotEmpty() ? $project->galleryBackgroundImage()->toFile()->url() : null, 'keywords' => $project->keywords()->toStructure()->map(fn($i) => [ diff --git a/src/views/Portfolio.svelte b/src/views/Portfolio.svelte index e493657..c673b57 100644 --- a/src/views/Portfolio.svelte +++ b/src/views/Portfolio.svelte @@ -147,7 +147,7 @@