-
-
Notifications
You must be signed in to change notification settings - Fork 336
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Ability to Add New Colors #1800
Comments
For those who want to add new colors now, you can use https://stackoverflow.com/questions/13300137/how-to-edit-a-node-module-installed-via-npm |
All Skeleton does to inject colors is follow the instruction Tailwind provides here. The colors are provided to the Tailwind config through our plugin, but you're able to do the same directly: https://tailwindcss.com/docs/customizing-colors#using-custom-colors In our case, we specifically use CSS properties and the RGB format so we can support transparency: https://tailwindcss.com/docs/customizing-colors#using-css-variables You're right though - this won't expand our utility or token classes, because these are canned styles created before our build process and distribution of the package. But you can always review how we generate these classes and expand your project yourself as you wish. Just drop the extra classes into It's never recommended to modify a That said, we do have some major changes coming to our Tailwind plugin in Skeleton v2: @AdrianGonz97 might have some insight onto how we could potentially expand the utility classes via this. But off the top of my head it wouldn't be something added in the near future. |
Yeah, I have already done everything I could in Tailwind. While I know modifying node modules is a bad idea, a single addition of a string to an array is unlikely to cause issues unless you delete |
Sorry, but hard disagree here. Node modules are not intended to be modified. "Can" and "should" are two different things. You're welcome to do this in your own project as you wish, but we'll never condone this for users. If Adrian can supply some ideas for providing support for this through the new plugin, we'll consider this feature. Otherwise we will not move forward with this request. |
I think we've done everything we can now for this ticket. If Adrian gets some free time and wishes to review my proposed ideas in the future then I would welcome that. But as it stands your best means for expanding the color palette is via the standard Tailwind configuration methods. |
Describe the feature in detail (code, mocks, or screenshots encouraged)
I have created a custom
interact
color palette to substitute the primary theme when it comes to interactable text, as it was too dark and I wanted it be a different color anyway.I was able to go most of the way until the
token
utility classes. I have found that all you need to do is to add the new color name to thecolorNames
array in settings.cjs.All that is needed really, is the ability to modify those settings in the skeleton config, as far as I have seen.
What type of pull request would this be?
New Feature
Provide relevant links or additional information.
No response
The text was updated successfully, but these errors were encountered: