Skip to content

Commit

Permalink
Add brief information about blockGap to the theme.json how-to guide (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
carolinan authored Nov 23, 2021
1 parent 7f95c42 commit 85a6b87
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions docs/how-to-guides/themes/theme-json.md
Original file line number Diff line number Diff line change
Expand Up @@ -1086,3 +1086,27 @@ A few notes about this process:
}
}
```

### What is blockGap and how can I use it?

blockGap adjusts the vertical margin, or gap, between blocks.
It is also used for margins between inner blocks in columns, buttons, and social icons.
In the editor, the control for the blockGap is called Block spacing, located in the Dimensions panel.

The value you define for the blockGap style uses a CSS property, a preset, named `--wp--style--block-gap`.
The default value is 2em.

```json
{
"version": 1,
"settings": {
"spacing": {
"blockGap": true,
}
},
"styles": {
"spacing": {
"blockGap": "1.5rem"
}
}
}

0 comments on commit 85a6b87

Please sign in to comment.