diff --git a/site/blueprints/pages/project.yml b/site/blueprints/pages/project.yml index b5be544..80d2164 100644 --- a/site/blueprints/pages/project.yml +++ b/site/blueprints/pages/project.yml @@ -103,6 +103,18 @@ columns: 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 diff --git a/site/plugins/world-game-icons/index.js b/site/plugins/world-game-icons/index.js index 84bc7f7..2f90750 100644 --- a/site/plugins/world-game-icons/index.js +++ b/site/plugins/world-game-icons/index.js @@ -5,5 +5,9 @@ panel.plugin("adrienpayet/world-game-icons", { stack: '', blog: '', + "arrow-up-down": + '', + "arrow-left-right": + '', }, }); diff --git a/site/templates/portfolio.json.php b/site/templates/portfolio.json.php index 5ee09a4..9335ccd 100644 --- a/site/templates/portfolio.json.php +++ b/site/templates/portfolio.json.php @@ -17,6 +17,7 @@ $specificData = [ 'mockup' => $project->mockup()->toFile()?->url(), 'mockupSrcset' => $project->mockup()->toFile()?->srcset('mockup'), 'mockupWebp' => $project->mockup()->toFile()?->srcset('mockup-webp'), + 'galleryAnimationMode' => $project->galleryAnimationMode()->value() ?: 'vertical', 'galleryBackgroundColor' => $project->galleryBackgroundColor()->value(), 'galleryBackgroundImage' => $project->galleryBackgroundImage()->isNotEmpty() ? $project->galleryBackgroundImage()->toFile()->url() : null, 'keywords' => $project->keywords()->toStructure()->map(fn($i) => [ diff --git a/src/components/ui/GalleryAnimation.svelte b/src/components/ui/GalleryAnimation.svelte index 46c9b2b..f36605f 100644 --- a/src/components/ui/GalleryAnimation.svelte +++ b/src/components/ui/GalleryAnimation.svelte @@ -1,19 +1,32 @@