Repository navigation
v3.0.0
[3.0.0] – 2026-03-26
✨ Added
Browser adaptation
-
color-scheme: light darkon:root
Instructs the browser to apply its native light/dark defaults for UI elements (scrollbars, form controls, etc.), even before any CSS is parsed. -
interpolate-size: allow-keywordson:root
Enables CSS transitions to and from intrinsic size keywords (auto,min-content,max-content,fit-content) across the entire document. Unlocks native height animations without JavaScript. -
scrollbar-gutter: stableonhtml
Reserves space for the scrollbar gutter even when no scrollbar is shown, preventing layout shifts between pages with and without overflow. Works alongsideoverflow-y: scrollas a fallback. -
overscroll-behavior: containonhtml
Prevents scroll chaining: when a scrollable area reaches its boundary, the viewport no longer scrolls.containpreserves the native elastic/bounce effect on the element itself.
New media query support
-
@media (prefers-reduced-transparency: reduce)
Reduces transparency for users who prefer it. Thedialog::backdropbecomes near-opaque (rgba(0,0,0,0.9)) and the scrollbar background aligns with the page color. -
@media (forced-colors: active)
Windows High Contrast Mode support. Restores the focus ring using the systemHighlightcolor, adds a visible border on form elements whose border was removed by the reset, and appliesopacity: 0.5on disabled elements.
Element normalization
-
Headings (
h1–h6)
Addedtext-wrap: balancefor improved typographic readability, especially on narrow viewports. -
Horizontal rule (
hr)
Replaces the browser-default 3D border with a clean, theme-consistent separator usingborder-top: 1px solid currentColor. -
Fieldset & Legend (
fieldset,legend)
Removes the default browser border and padding onfieldset, and the internal padding onlegend, providing a clean form grouping container. -
Dialog (
dialog,dialog::backdrop)
Normalizesdialogwith theme variables and adds a native entry animation using@starting-style(fade + slide) wrapped in@media (prefers-reduced-motion: no-preference). Theallow-discretetransition ondisplayandoverlayensures the animation completes before the element is hidden. -
[hidden]semantic fix
Addsdisplay: none !importantto[hidden]so elements marked as hidden are never accidentally revealed by other CSS rules. -
Print styles (
@media print)
Added a dedicated print section that removes backgrounds, box shadows, and decorative colors, and shows full URLs after links.
Form UX
-
field-sizing: contentontextarea
The textarea automatically resizes to fit its content, eliminating the need for JavaScript auto-resize solutions.resize: verticalis kept as a fallback for unsupported browsers. -
caret-color: var(--bux-color-primary)oninput,textarea,[contenteditable]
Applies the theme's primary color to the text insertion cursor for consistent visual theming.
Typography
text-underline-offset: 0.2emona
Moves the underline slightly below the text baseline, reducing collisions with descenders and improving legibility.
Dark mode
- Three missing variable overrides added to
@media (prefers-color-scheme: dark):--bux-valid-bg-color: #0d2e18--bux-invalid-bg-color: #2e0d0d--bux-scrollbar-track: #1a2535
🔧 Changed
-
Smooth theme transition moved into
@media (prefers-reduced-motion: no-preference)
Thebody { transition }rule now only applies when the user has not opted for reduced motion, correctly respecting their preference. -
Field validation states now use
:user-valid/:user-invalidinstead of:valid/:invalid
These pseudo-classes only activate after the user has interacted with the field, preventing premature error styling on page load. -
Disabled elements (
[disabled],[aria-disabled="true"])
Addedcursor: not-allowedto clearly communicate that an element is non-interactive. -
Body now includes
overflow-wrap: break-word
Prevents long words or URLs from overflowing their container, particularly useful on narrow viewports. -
overflow-y: scrollandscrollbar-gutter: stableonhtml
Comments updated to explicitly document their complementary roles:scrollbar-gutter: stableis the modern solution;overflow-y: scrollis kept as a fallback for browsers that do not yet support it. Both are required for full cross-browser coverage. -
::-moz-progress-barnow correctly usesvar(--bux-progress-value-bg)instead ofvar(--bux-progress-bar-bg).
In Firefox,::-moz-progress-bartargets the filled portion of the progress bar (the value), not the track. The wrong variable was applied since v1.0.1. -
Inconsistent indentation fixed throughout
browserux.css.
Several rules were using tabs instead of 2-space indentation, inconsistent with the rest of the file. All properties are now uniformly indented with 2 spaces.
➖ Removed
-
details, summary { accent-color }
accent-colorhas no effect on<details>and<summary>elements in any browser. The rule was a no-op and has been removed. For customsummarymarker styling, usesummary::markeror a::beforepseudo-element. -
ol, ul { list-style: none }
Removing list markers globally is too opinionated for a base stylesheet and can degrade accessibility (VoiceOver removes list semantics whenlist-style: noneis applied withoutrole="list"). Apply this reset selectively in your own stylesheet where needed.
✅ Fixed
@media (prefers-contrast: more)in dark mode
Added a combined@media (prefers-contrast: more) and (prefers-color-scheme: dark)block. The near-black placeholder and disabled-element colors defined in the base contrast block were invisible against the dark background. They are now overridden with near-white values (rgba(239, 239, 239, 0.9)) when both preferences are active simultaneously.