Added an optional color-highlight[^1] class that can apply ::selection styling based on Windows 98 text highlighting styling.[^1]
💭 Reasoning
Adding this styling can ensure that developers and designers can build a more authentic UI based on Windows 98, down to how text highlighting was styled.
📔 Dev Notes
The decision to make ::selection styling apply thru an optional class was to ensure that a developer would have to consciously choose if they want an area to have W98 selection styling on an element, as there can be significant accessibility impacts^2 if done.
This also has the benefit of allowing a user of 98.css to choose when and where on a window-body element they want the custom highlight styling to occur, as the use of text-shadow with this custom highlight styling could make some highlights look off.
The foreground and background of this selection styling surpasses WCAG AA and AAA with a contrast ratio of 18.07:1^3.
In this PR
color-highlight
[^1] class that can apply::selection
styling based on Windows 98 text highlighting styling.[^1]💭 Reasoning
Adding this styling can ensure that developers and designers can build a more authentic UI based on Windows 98, down to how text highlighting was styled.
📔 Dev Notes
The decision to make
::selection
styling apply thru an optional class was to ensure that a developer would have to consciously choose if they want an area to have W98 selection styling on an element, as there can be significant accessibility impacts^2 if done.This also has the benefit of allowing a user of 98.css to choose when and where on a
window-body
element they want the custom highlight styling to occur, as the use oftext-shadow
with this custom highlight styling could make some highlights look off.The foreground and background of this selection styling surpasses WCAG AA and AAA with a contrast ratio of 18.07:1^3.
[^1]: Name for class and styling sourced from Windows Interface Guidelines, chapter 13 - Visual Design, page 325