I'm building a full-screen carousel where the Site Title and menu switch between white and black text depending on the slide behind them, plus a floating preview of the next/previous slide that follows the cursor. Both work using Custom CSS & HTML and classes on the Carousel element.
The gap: there's no way to attach anything to an individual slide. To let editors set the header colour per slide, I have to match settings to slides by order, which breaks when slides are reordered.
Could you add one of these to the per-slide settings in the Carousel dialog?
- A "Classes" field per slide, output on the .lay-carousel-slide element.
- Or a "Header text colour" option per slide (Default / Light / Dark), output as a class or data attribute on the slide.
Also useful for anyone extending the carousel with custom code:
- A documented JS event when the active slide changes (e.g. via window.laytheme.on), rather than watching for the is-selected class.
- A public API to go to the next/previous slide programmatically.
Lay Theme 11.7.9, Carousel 3.2.5.