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 support for custom CSS in theme style variations #49970

Open
tellthemachines opened this issue Apr 21, 2023 · 7 comments
Open

Add support for custom CSS in theme style variations #49970

tellthemachines opened this issue Apr 21, 2023 · 7 comments
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. Global Styles Anything related to the broader Global Styles efforts, including Styles Engine and theme.json [Type] Enhancement A suggestion for improvement.

Comments

@tellthemachines
Copy link
Contributor

What problem does this address?

Custom CSS fields were recently added for both themes and blocks, in the global styles UI and in theme.json. But they only work at the main theme.json level; adding a custom CSS field either globally of per-block in a theme style variation file has no effect.

What is your proposed solution?

It would be great if it were possible to add per-variation custom CSS. When setting it from the UI, the custom CSS would apply to the active variation and reset when switching to another variation. This would bring consistency with the other design tools when variations switching.

@tellthemachines tellthemachines added [Type] Enhancement A suggestion for improvement. [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. Global Styles Anything related to the broader Global Styles efforts, including Styles Engine and theme.json [Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi labels Apr 21, 2023
@carolinan

This comment was marked as off-topic.

@carolinan

This comment was marked as off-topic.

@carolinan carolinan added the Needs Design Feedback Needs general design feedback. label Apr 21, 2023
@tellthemachines

This comment was marked as off-topic.

@carolinan carolinan removed the Needs Design Feedback Needs general design feedback. label Apr 24, 2023
@carolinan

This comment was marked as off-topic.

@carolinan
Copy link
Contributor

We need a better way to identify which variation that is active.

@annezazu
Copy link
Contributor

Noting this for @WordPress/block-themers in general!

@mrfoxtalbot
Copy link

mrfoxtalbot commented May 20, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Design Tools Tools that impact the appearance of blocks both to expand the number of tools and improve the experi [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. Global Styles Anything related to the broader Global Styles efforts, including Styles Engine and theme.json [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

4 participants