generateblocks
generateblocks copied to clipboard
Make possible to use containers as divs for a slider
Hi there,
Today I tried to implement swiper.js with generateblocks just to check if this is possible.
So I created 6 columns inside a container, and gave the neccessary classes that swiper.js needs like a normal HTML template.
- Container = swipper
- Inner container = swiper-wrapper
- and each collumn inside this had the class swiper-slide
I had created previously the slide inside gutenberg with simple HTML and it was working fine, I noticed that inside Generateblocks containers will do nothing.
There is some reason this will not work ? probably because the css of Generateblocks ? or maybe I have made a mistake, have anyone tried this before?
If there is not a possibility it would be fun to make easily something like this in the future.
@FunkyCss it is definitely possible to use GB grid items as a slider as I have done this with Owl Carousel on a site I built recently that needed a custom slider element where the usual gutenberg options like Kadence Blocks were not a good fit.
I seem to recall I too tried swiper initially but I think it was possbly the markup that swiper requires with the extra wrapper that was not suited to the GB grid structure. Owl Carousel markup requirement is simpler and that was quite easy to get going with the GB grid which I even applied some effects to.
Feature request added to GB Pro. Closing here