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 Tailwind v3 extended color palette for all valid utilities #7

Closed
wants to merge 5 commits into from
Closed

Conversation

NoaVidovic
Copy link

The repository was missing many default colors that were added in Tailwind v3, such as cyan or orange. This pull request simply adds the missing colors.

It is important to note that Tailwind changed the default value of green, purple and yellow colors (these were renamed to emerald, violet and amber respectively, and the old names were repurposed for other color values) - details available here. Therefore, any code that uses this package should be modified to reflect this change. This may be considered a breaking change.

Also, I do not have a utility to automatically sort the functions alphabetically, as is the case in the base repository, so the ordering is sort of all out of whack. Feel free to modify this when merging.

@matheus23
Copy link
Owner

Thank you for doing this! I really appreciate it.

Unfortuantely, the elm-default-tailwind-modules package is already close to its size limits for package.elm-lang.org uploads.
I'm postponing this change until #6 is done.
Once we have #6, I'll re-generate this repo's code with the new abstracted-out colors (see matheus23/elm-tailwind-modules#16) and the generated files will be much smaller, while still making all color/utility combinations possible.

@matheus23 matheus23 closed this Jan 31, 2023
@matheus23
Copy link
Owner

@NoaVidovic I've uploaded a new version, let me know if that works for you: #6 (comment)

@NoaVidovic
Copy link
Author

Thank you so much for the work you put in here! However, I do not see version 3.0.0 on the elm packages website - it still shows 2.0.3 as the latest and there is no bg_color function nor anything else.

@matheus23
Copy link
Owner

@matheus23
Copy link
Owner

You can see the published versions here: https://package.elm-lang.org/packages/matheus23/elm-default-tailwind-modules/

@NoaVidovic
Copy link
Author

Yeah, it's not showing up for me:
screenshot

@matheus23
Copy link
Owner

Wow :D

you must be hitting some kind of cashing issue. For me it's there:
image

@matheus23
Copy link
Owner

@NoaVidovic
Copy link
Author

So, confusingly, while clearing the cache fixed the issue and I can now see version 3.0.0 (and functions such as bg_color and text_color show up), the Tailwind.Theme module doesn't show up (as shown in the attached image)

Updating my elm.json does download the Tailwind.Theme module as it should, but elm make doesn't recognize it when compiling...

image

@matheus23
Copy link
Owner

That one is my bad!
I've published version 3.1.0 to fix this issue:
image

@NoaVidovic
Copy link
Author

Works like a charm now! Thanks a lot!

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