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

Trouble with custom pallette #93

Open
ncc-swann opened this issue Jun 15, 2023 · 5 comments
Open

Trouble with custom pallette #93

ncc-swann opened this issue Jun 15, 2023 · 5 comments

Comments

@ncc-swann
Copy link

Hi

I am using elm-ui-widgets and generally find it awesome and very useful, so thank you!

I am currently trying to change the default pallette to something custom, but colors do not seem to be represented correctly on screen. I am only changing the primary color of the default pallette for now, leaving the rest alone, but I am experiencing jade represented as light brownish, a shade of blue being represented as green etc.

Do you have any insight into what might be going on?

Best regards
Nicolai

@Orasund
Copy link
Owner

Orasund commented Jun 15, 2023 via email

@ncc-swann
Copy link
Author

ncc-swann commented Jun 15, 2023

Of course.
!! Now with updated link to the Ellie !!

Here is a link to the Ellie: https://ellie-app.com/n62jNwkctCHa1
And here is a link to how the CIELCH color used as primary color should look like: https://convertingcolors.com/cielch-color-42_62.639_291.077.html?search=CIELCH(42,%2062.639,%20291.077)#00ABAB

@Orasund
Copy link
Owner

Orasund commented Jun 21, 2023

I'm not sure why this happens. I'm actually relying on noahzgordon/elm-color-extra to convert from LAB to RGB. The conversion from LCH to LAB should be correct (it's just one line, that I double-checked just now).

Also, I never had any problems with that function – I have actually been using it a lot. However, I never tried to directly create a CIELCH color, like you are doing. So my guess is that some factor is wrong somewhere. Maybe the range of my implementation is different to the range used by convertingcolors.com?

I am considering this a niche-problem, and I currently don't have time to fix this. So I will leave it as is.

If you need a fix, please try to find a solution and open a PR.

@ncc-swann
Copy link
Author

Thank you for looking into it.
People at my company don't like the default purple look, so I will have to come up with a solution eventually.

@Orasund
Copy link
Owner

Orasund commented Jun 21, 2023

Use avh4/elm-color to define colors. You can use any rgb value.

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

No branches or pull requests

2 participants