[csswg-drafts] [css-ui] Changing UA styles based on the computed value of the appearance property (#10028)

josepharhar has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-ui] Changing UA styles based on the computed value of the appearance property ==
I'm working on improvements to the `<select>` element ([whatwg thread here](https://github.com/whatwg/html/issues/9799)), and I came across an issue while implementing a prototype of the Apple-supported behavior of switching to a new rendering mode based on the value of the appearance property.

The select element has several UA style rules which we don't want in the new rendering mode, such as [white-space:pre](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/html/resources/html.css;l=919;drc=c96c313ac1e6c9b64abc5ee2d50315995770e2c2), which makes all of the options in the popup have a bunch of line breaks rendered in my examples.

I tried adding an internal pseudo-selector which matches when the element has the new appearance value, but I found that it took two style updates to get the final style, which @andruud [described as a "non-starter"](https://chromium-review.googlesource.com/c/chromium/src/+/5315083/comment/ab7d1c7c_dd14d5aa/).

@annevk suggested that I should ask here to see if there is a way that we can make this work.

Also, if there are any previous discussions about the appearance property that are related to this, I would appreciate links to them.

cc @nt1m

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10028 using your GitHub account


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

Received on Monday, 4 March 2024 20:35:45 UTC