Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spacer Block: Allow background color choice #29420

Closed
jasmussen opened this issue Mar 1, 2021 · 3 comments
Closed

Spacer Block: Allow background color choice #29420

jasmussen opened this issue Mar 1, 2021 · 3 comments
Labels
[Block] Spacer Affects the Spacer Block

Comments

@jasmussen
Copy link
Contributor

What problem does this address?

The Spacer block is currently a primary layout tool, there to space out elements on a page. Aspects of this utility are likely to be augmented by, or taken over, by the addition of margin controls to more blocks.

But the spacer can still serve a purpose on its own, by allowing easily editable editorial spacing inside content.

An additional utility could be to allow a background color, so you could create empty colored areas. Many patterns do this already by adding an empty Cover block with a dummy spacer block inside. By enabling colors on the spacer block directly, this would simply that flow.

What is your proposed solution?

Add a color swatch tool to the Spacer toolbar:

Spacer empty

Spacer with color

@mtias
Copy link
Member

mtias commented Jul 14, 2021

I'm not sure this makes much sense, especially if we end up transforming the spacer into adjacent margins in the future.

@jasmussen
Copy link
Contributor Author

Excellent point. I created this ticket inspired by a personal use case, behold:

punch

Since then I haven't had much use for changing the color, though, which suggests that even if there was a use case for it, it might be better handled through extensibility or other blocks, like the separator.

@sunildevbang
Copy link

Hey How can we add custom background color

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Spacer Affects the Spacer Block
Projects
None yet
Development

No branches or pull requests

3 participants