question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

CSS Color 4 RGB/RGBA syntax - Whitespace syntax and RGB alpha value

See original GitHub issue

Please read and fill out this template by replacing the instructions with appropriate information. If the template is not followed, the issue will be marked Invalid and closed.

Before submitting an issue search past issues and read the area of the documentation related to your specific question, issue, or request.


Description

… what is the issue / request ? Add support for CSS Color 4 RGB/RGBA syntax

Vague issues/requests will be marked with Insufficient Details for about a week. If not corrected, they will be marked Stale for about a week and then closed.

For feature requests or proposals: CSS Color 4 RGB/RGBA syntax

Suggestion to support

/* Functional syntax with alpha value */ rgb(255, 0, 153, 1) rgb(255, 0, 153, 100%)

/* Whitespace syntax */ rgb(255 0 153 / 1) rgb(255 0 153 / 100%)

/* Functional syntax */ rgba(51, 170, 51, 1) rgba(51, 170, 51, 100%)

/* Whitespace syntax */ rgba(51 170 51 / 0.4)
rgba(51 170 51 / 40%)

😀 https://www.chromestatus.com/feature/5124205561511936

  • Clearly define in as much detail as possible how you imagine the feature to work.
  • Examples are also appreciated.

For bugs and support questions:

  • Describe the bug/question in as much detail as possible to make it clear what is wrong or what you do not > understand.
  • Provide errors from console (if available).
  • Pictures or screencasts can also be used to clarify what the issue is or what the question is.
  • Provide links to 3rd party syntax highlighting package you are using if applicable.

Support Info

Run the following command from the menu: Preferences->Package Settings->ColorHelper->Support Info. Post the result here.

Steps to Reproduce Issue

  1. First step…
  2. Second step…
  3. Third step…

Provide steps to reproduce the issue. Pictures are fine, but also provide code/text I can copy and paste in order to reproduce. Omit for feature requests and feature proposals.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:11 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
facelessusercommented, Oct 2, 2020

I know I still haven’t pushed out a release in like a month, but just an FYI, there should hopefully be a beta out sometime soon-ish (hoping within the week). There were many areas that were re-written and such. The aim was to allow more flexible input and output, more configurability, and improve color scanning behavior.

Currently, all this work is on the feature/next branch info here #159. We have a new color library that ColorHelper uses and can handle not just sRGB, HSL, HWB, but it can handle LCH, LAB, and others.

Because of this, we’ve reworked color previews as now we have to handle colors that are out of gamut, so some simple gamut mapping is now available or the option to not show the color at all. We’ve added some new color tools as well. Anyways, a lot of work went into this next release which is why the holdup.

1reaction
facelessusercommented, Aug 28, 2020

Getting close. There’s a number of places in which we need to make some adjustments, but detection seems to be working:

Screen Shot 2020-08-27 at 9 35 50 PM
Read more comments on GitHub >

github_iconTop Results From Across the Web

<color> - CSS: Cascading Style Sheets - MDN Web Docs
RGB color model​​ An optional alpha component represents the color's transparency. RGB colors can be expressed through both hexadecimal (prefixed ...
Read more >
CSS Color 4 RGB/RGBA syntax - Chrome Platform Status
Feature: CSS Color 4 RGB/RGBA syntax. Update parsing of RGB() and RGBA() to the syntax described in CSS Color 4.
Read more >
CSS Legal Color Values - W3Schools
RGBA color values are an extension of RGB color values with an alpha ... RGBA color is specified with the rgba() function, which...
Read more >
CSS Color Module Level 4 - W3C
Opacity in CSS is typically represented using the <alpha-value> syntax, for example in the opacity property or as the alpha component in a...
Read more >
Check if string matches a valid CSS color (hex, rgb, rgba ... - regex101
CSS RGB Color Regex for JS Supports RGB and RGBA syntax (identical in CSS Color ... alpha value (4 and 8 character hex...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found