Comments on: A Nerd’s Guide to Color on the Web https://css-tricks.com/nerds-guide-color-web/ Tips, Tricks, and Techniques on using Cascading Style Sheets. Tue, 20 Sep 2022 17:11:42 +0000 hourly 1 https://wordpress.org/?v=6.1.1 By: Sphism https://css-tricks.com/nerds-guide-color-web/#comment-1604311 Tue, 27 Sep 2016 22:05:32 +0000 http://css-tricks.com/?p=245208#comment-1604311 In reply to Alan Hardman.

Really great article. Thanks correct about rgb being 24-bit and rgba being 32-bit.

This is in response to Gary Armstrong’s comment about max colors in hsl, I just did some tests.

Just thought you’d like to know that your comment about rgb being higher fidelity than hsl is incorrect because you can use decimal percentages for saturation and lightness. But you can’t use decimal values for rgb.

eg. (on mac chrome)

hsl(290,60%,70%) = #D185E1
hsl(290,60.5%,70%) = #D284E1

It looks like you can’t have decimal hue values though.

I’m not sure if the hsl values are converted to hex or rgb. You might be maxed out at all possible hex or rgb colors if the hsl value gets rounded to one of those before getting displayed.

But i think it’s fair to say hsl has at least as many colors as rgb, if not more.

]]>
By: wishmaster2310 https://css-tricks.com/nerds-guide-color-web/#comment-1604208 Tue, 20 Sep 2016 04:30:25 +0000 http://css-tricks.com/?p=245208#comment-1604208 Great job! Thank you.

Example: rbga(150, 150, 150, 0.5);

rbga =)

]]>
By: Beau Lebens https://css-tricks.com/nerds-guide-color-web/#comment-1604197 Mon, 19 Sep 2016 13:47:42 +0000 http://css-tricks.com/?p=245208#comment-1604197 Love the awesome blend modes demo in the article. Besides that, there’s a useful read on improving your color workflow and creating a color palette for web developers on Smashing:

https://www.smashingmagazine.com/2016/04/web-developer-guide-color/

Thanks!

— Bo

]]>
By: goose https://css-tricks.com/nerds-guide-color-web/#comment-1604161 Fri, 16 Sep 2016 19:26:20 +0000 http://css-tricks.com/?p=245208#comment-1604161 Why am I just now finding out about console colors?!

]]>
By: TGJ Gilmore https://css-tricks.com/nerds-guide-color-web/#comment-1604153 Fri, 16 Sep 2016 13:24:26 +0000 http://css-tricks.com/?p=245208#comment-1604153 The RGB function can also be used with 3 percentage values to represent the proportion of red, green and blue to apply, 0% = 0 (or 00 hex), 100% = 255 (or FF hex). All three values have to be percentages, they can go down to 2 decimal places (12.34%) but do not appear to work with the RGBA function.

]]>
By: Mark https://css-tricks.com/nerds-guide-color-web/#comment-1604127 Thu, 15 Sep 2016 14:49:24 +0000 http://css-tricks.com/?p=245208#comment-1604127 Great article,
I go this virus infection warning when I went to the demo mentioned early in the HSL section. I am not sure if it is legit or maybe the demo code confused my virus software, but thought I would mention it……
Infection detected!
http://www.workwithcolor.com/hsl-color-picker-01.htm

The requested URL contains malicious code that can damage your computer. If you want to access the URL anyway, turn off the Avast web shield and try it again.

Infection type: JS:Redirector-BNI [Trj]

]]>
By: Jan Zumwalt https://css-tricks.com/nerds-guide-color-web/#comment-1604115 Wed, 14 Sep 2016 20:39:21 +0000 http://css-tricks.com/?p=245208#comment-1604115 I use to dabble with oil paints and would just add black or grey to the sky color for shadows. I could always tell there was something wrong but could not figure it out; now I know. Great tips, thanks!

]]>
By: Catalin Rosu https://css-tricks.com/nerds-guide-color-web/#comment-1604114 Wed, 14 Sep 2016 20:38:28 +0000 http://css-tricks.com/?p=245208#comment-1604114 That’s an impressive read.

One thing, regarding the currentColor snippet:

.div-external { color: orange; }
.div-internal { border: 1px solid currentColor; }

The above might not be the best example that shows the power of currentColorbecause in this case currentColor is already the default value for the border-color.

]]>
By: Gary Armstrong https://css-tricks.com/nerds-guide-color-web/#comment-1604113 Wed, 14 Sep 2016 19:51:35 +0000 http://css-tricks.com/?p=245208#comment-1604113 In reply to Alan Hardman.

Which is why HSL is a subset of 24-bit RGB color. HSL can actually only address 3,492,722 different colors (360 × 99 × 98 + 2). Technically, RGB has better fidelity, with multiple RGB values mapping to the same HSL.

I was actually in the middle of writing an article on HSL vs. RGB (http://blog.armstrongest.com/why-i-love-hsl-more-than-rgb/) when I noticed this article, but decided to publish anyhow.

]]>
By: Ivan Boothe https://css-tricks.com/nerds-guide-color-web/#comment-1604101 Tue, 13 Sep 2016 23:34:22 +0000 http://css-tricks.com/?p=245208#comment-1604101 Fantastic article!

One short note. You write:

“Back in the old days, chucknorris was a blood red color (it’s only supported in HTML now as far as I can tell), but that was my favorite.”

It’s actually more interesting than you let on. chucknorris isn’t a named color — the full list is here and was originally based on X11 colors.

But then why does chucknorris turn out red? The StackOverflow answer you link to explains it in detail.

Browsers are trained to ignore invalid data. Missing digits and invalid hexadecimal digits are treated as 0. So CHUCKNORRIS is converted to C00C0000000. The number of hexadecimal colors’ digits has to be a multiple of three; since this has 11 we get an additional padding digit of 0 at the end.

Browsers then divide the code into three equal chunks for RGB, so we get C00C 0000 0000. And finally, they truncate each chunk to two characters: C0 00 00, aka #C00000, aka dark red.

Commenters point out that other random strings also produce colors, including strangely appropriate ones, including grass (green) and crap (brown). You can use this fun tool to type random strings and discover the interpreted color.

Anyway, great article!

]]>
By: Brandon https://css-tricks.com/nerds-guide-color-web/#comment-1604100 Tue, 13 Sep 2016 18:14:59 +0000 http://css-tricks.com/?p=245208#comment-1604100 Awesome article!! This should win an award or something :)

]]>
By: David https://css-tricks.com/nerds-guide-color-web/#comment-1604082 Tue, 13 Sep 2016 10:58:32 +0000 http://css-tricks.com/?p=245208#comment-1604082 WOW! Excellent piece and well written and expertly structured indeed.

Your passion for this topic certain comes through.

Indeed deserves a bookmark

]]>
By: Luke https://css-tricks.com/nerds-guide-color-web/#comment-1604077 Tue, 13 Sep 2016 03:49:57 +0000 http://css-tricks.com/?p=245208#comment-1604077 Wow! This has to be up there with one of my favourite articles.

I love the depth you go into each sub-topic; Some enough depth to really understand how and why, and others just enough to know WHY you should be interested in reading more.

I didn’t need any breaks while reading, didn’t find myself skipping ahead. Even when you were explaining something I already have a firm grasp of, I was still interested in your overview of it.

Now that I look back through other articles written by Sarah I am noticing they are often ones I have bookmarked or committed to memory.

Thanks Sarah. Looking forward to your next article with bated breath.

]]>
By: Jan https://css-tricks.com/nerds-guide-color-web/#comment-1604075 Mon, 12 Sep 2016 21:18:17 +0000 http://css-tricks.com/?p=245208#comment-1604075 background-clip: text a.k.a. Gradient Text is soon coming to Firefox (already supported on Beta).

]]>
By: Mustafa Enes https://css-tricks.com/nerds-guide-color-web/#comment-1604067 Mon, 12 Sep 2016 17:20:01 +0000 http://css-tricks.com/?p=245208#comment-1604067

#00000 being black

Missing a zero.

]]>