• Resolved Ninos

    (@ninos-ego)


    First of all, thx for the clean plugin! Can you may add a css variable for the hover color of the navigation elements, e.g. --wp--custom--carousel-block--navigation-active-color?

    Additionally, is it possible to allow spacing in the block support section (block.json)?

    “spacing”: {
    “margin”: true
    },

    This could may break styling with navigation, but no one is forced to use it 😀 Currently we need to create a wrapping group block around carousel block just for some spacing… :/

Viewing 1 replies (of 1 total)
  • Plugin Author Virgildia

    (@virgildia)

    Thanks for the suggestion @ninos-ego

    I added 2 new CSS variables

    --wp--custom--carousel-block--navigation-color (Arrow color)
    --wp--custom--carousel-block--navigation-hover-color (Arrow hover color)

    They will be available in the next plugin update.

    Default spacing controls were not added to the carousel since they could cause unintended layout issues. However if spacing is something that works with your theme and setup you can extend the block to support it https://developer.wordpress.org/news/2024/08/how-to-extend-a-wordpress-block/

    Also in Gutenberg there’s a fast way to add spacing if needed with the group block. Simply select the carousel block, click the block icon in the toolbar, and choose Group from the dropdown. This wraps the carousel in a Group block where you can then control background, spacing, etc. This is the recommended approach for adjusting spacing or layout for the Carousel Block.

Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.