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

Add more colour options to the Table block #594

Closed
thetwopct opened this issue Oct 22, 2020 · 7 comments
Closed

Add more colour options to the Table block #594

thetwopct opened this issue Oct 22, 2020 · 7 comments
Labels

Comments

@thetwopct
Copy link
Collaborator

thetwopct commented Oct 22, 2020

Megan has requested a broader range of colours used on the Table block.

I thought this would be straightforward, but it seems that the pale colours are built-in to the block and not editable. They sync with the "striped" table style and provide high contrast for accessibility (we don't use the striped style as it clashes with the default table styling). The issue is replicated on CNCF.

2020-10-22-162052@2x

Seems this is a known issue, but no progress is happening with solutions:

WordPress/gutenberg#19659
WordPress/gutenberg#16478

Solutions for us:

  • Apply more colours via Block Styles (perhaps we have 2 event-colour generated styles, plus a couple more generic pastel colours?)
  • Fork the block and add in the full colour palette
@cjyabraham
Copy link
Collaborator

What's the use-case @meganelizabethphillips is needing a broader range of colors for? Is there an alternate path to meeting that use-case that doesn't require additional colors?

@thetwopct
Copy link
Collaborator Author

The objective is to have colours for table backgrounds that are more inline with the colours used for a particular event or colours more suited to LF style.

A use case could be the Slack channel tables. If 6 tables are used, there are only 4 colours to choose.

@cjyabraham
Copy link
Collaborator

In that case I'd just go with adding extra styles for now. I assume sooner or later this will get fixed in core.

@cjyabraham
Copy link
Collaborator

In terms of changing the table background color, can't the table just be put inside of a Group block with the background color set?

@meganelizabethphillips
Copy link

meganelizabethphillips commented Nov 10, 2020 via email

@cjyabraham
Copy link
Collaborator

The Group block is almost equivalent to the Stackable Container block. You can set text and background colors etc. Here are several examples of how we can use it going forward.

@thetwopct
Copy link
Collaborator Author

Closing this issue, as since WordPress 5.8, tables can now have any color set as the background

@cjyabraham cjyabraham moved this to Done in lfevents Jun 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

No branches or pull requests

3 participants