We need a custom gutenberg block that builds a gallery, but one that shows a single row of images and has scrollbars to move it.
It's important the interface for this looks like a native WordPress block.
Inputs
Gallery of images (should work same as regular gallery block with ordering etc...).
Output
Images: Array of MediaItems in WP-GQL-Gutenberg.
Design:
On the frontend, we will style it to look like this (You do not have to build frontend Vue component):
So the idea is a long row of images, that are sized 70vw and height auto, and then a "overflow-x: auto" container. Our frontend component will then have a "click and drag" style scroll in place on desktop, or swipe to scroll on mobile. We will use this: https://components.funkhaus.us/?path=/story/ui-scrollers-drag--default
We need a custom gutenberg block that builds a gallery, but one that shows a single row of images and has scrollbars to move it.
It's important the interface for this looks like a native WordPress block.
Inputs
Output
Design:
On the frontend, we will style it to look like this (You do not have to build frontend Vue component):
So the idea is a long row of images, that are sized 70vw and height auto, and then a "overflow-x: auto" container. Our frontend component will then have a "click and drag" style scroll in place on desktop, or swipe to scroll on mobile. We will use this: https://components.funkhaus.us/?path=/story/ui-scrollers-drag--default
Notes:
I tried getting this working with ACF Blocks here: https://github.com/funkhaus/fuxt-backend/tree/master/blocks
But it didn't work in WP-GQL-Gutenberg and also the interface looks a little ad-hock. This native block request will replace this block.