-
-
Notifications
You must be signed in to change notification settings - Fork 416
Description
Description of problem
In the WoT documents, we use special highlighting for assertions.
See for example https://w3c.github.io/wot-thing-description/#class-definitions the gray background for the MUST statement.
It is done with CSS
.rfc2119-assertion {
background-color: rgb(230, 230, 230);
}
The code above does not take into account dark/light mode, and we wanted to fix it with something simple like the following
.rfc2119-assertion {
background-color: light-dark(#e6e6e6, #223a2c);
}
Anyhow, the above statement somewhat conflicts with the manual selection in the sidebar and the magic that happens in https://www.w3.org/scripts/TR/2021/fixup.js.
That's why we had to fix it differently, see https://github.com/w3c/wot-binding-registry/pull/32/files
This a bit prone to errors since we base on the CSS added by the fixup.js.
Hence, I think the fixup.js script needs some update... I think.
The manual selection via W3C sidebar should not conflict with the browser/OS settings.
see the complete discussion here