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 CSS variables for customization #326

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft

Conversation

vdawg-git
Copy link

@vdawg-git vdawg-git commented Mar 20, 2024

Adds CSS overridable CSS variables to customize the colors of the text (neutrals), background and the primary.

It works, but I set it as a draft as this is a breaking change as with this users need to provide a whole palette to customize the primary color.
Im not sure about the best way to handle that. Probably allowing both would work the best.

@vdawg-git vdawg-git marked this pull request as draft March 20, 2024 15:03
Copy link

netlify bot commented Mar 20, 2024

Deploy Preview for hugo-hextra ready!

Name Link
🔨 Latest commit 63d6870
🔍 Latest deploy log https://app.netlify.com/sites/hugo-hextra/deploys/65fafabce5f3800008143d80
😎 Deploy Preview https://deploy-preview-326--hugo-hextra.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@vdawg-git vdawg-git changed the title made it work Add CSS variables for customization Mar 20, 2024
@vdawg-git
Copy link
Author

What are your thoughts on this?

@imfing
Copy link
Owner

imfing commented Apr 1, 2024

It works, but I set it as a draft as this is a breaking change as with this users need to provide a whole palette to customize the primary color.

@Visual-Dawg thanks, like you said, asking users to provide a whole color palette which might be too much work. it also increases the complexity for maintaining.

i think what we can do is adding several custom utility classes in tailwind config to allow overriding at least backgrounds plus some other visual elements via CSS variables first.

@vdawg-git
Copy link
Author

Sorry for answering so late.
I think waiting for Tailwind v4 might make sense, as this will ship with variables for the purpose of themeing.

Which should be much easier

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants