Re: [csswg-drafts] [css-values][css-namespaces] Vendor prefix in <dashed-ident> (#6099)

An alternative use of prefixes within custom properties could be explicitly accessing cascade layers defined by [`@layer`](https://w3c.github.io/csswg-drafts/css-cascade-5/#layering) at-rules. 

~~~~ css
@layer bar, foo;
@layer foo {
  :root {
    --value: green;
  }
}
@layer bar {
  :root {
    --value: red;
  }
}

 
a {
  color: var(--value); /* green */
  background: var(-foo-value); /* green */
  border-color: var(-bar-value); /* red */
}

@layer bar {

b {
  color: var(--value); /* red!? */
  background: var(-foo-value); /* green */
  border-color: var(-bar-value); /* red */
}

}
~~~~


-- 
GitHub Notification of comment by Crissov
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6099#issuecomment-1404587818 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Thursday, 26 January 2023 05:50:14 UTC