8000 [css-color-4] Add `<alpha-value>` parameter to `<named-color>` and `<hex-color>` · Issue #10678 · w3c/csswg-drafts · GitHub
[go: up one dir, main page]

Skip to content

[css-color-4] Add <alpha-value> parameter to <named-color> and <hex-color> #10678

@francescorn

Description

@francescorn

Problem
Currently, you have to specify the alpha-value separately in <named-color> and <hex-color> as opacity. It affects all elements if there are multiple.

.element {
  background-color: #aaaaaa;
  color: black;
  opacity: 0.5;
}

Proposed Solution
Add an alpha-value to <named-color> and <hex-color> in the same line:

.element {
  background-color: #aaaaaa 0.5;
  color: black 0.7;
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0