How to add spacing size presets to my theme?

i have tried to add spacingSizes for me theme.json, but it just doesn’t work. I only get the custom margin input field, my presets don’t appear. What am I doing wrong?

{
    "settings": {
        "spacing": {
            "margin": true,
            "padding": false,
            "customSpacingSize": false,
            "spacingScale": {
                "steps": 0
            },
            "spacingSizes": [
                {
                    "size": "1em",
                    "slug": "small",
                    "name": "Small"
                },
                {
                    "size": "2em",
                    "slug": "large",
                    "name": "Large"
                }
            ]
        }
    }
}

Leave a Comment