Status
Current QuickJS capability auditing says matchMedia() answers false to every query. The API exists, but the returned answer is not connected to MacSurf's real media-query evaluator or viewport state.
Scope
- Parse/evaluate a media query through the same media-feature semantics used by author CSS where possible.
- Return a
MediaQueryList with correct media and matches.
- Support change notification (
change event / listener compatibility) when viewport-relevant state changes.
- Keep JS and CSS media-query answers consistent for width/height/orientation and other features MacSurf actually supports.
Do not fabricate support for media features the CSS engine itself cannot evaluate.
Acceptance
For a known viewport, (min-width: 500px) and (max-width: 500px) return opposite correct values; resizing across the threshold updates matches and fires one change notification; CSS and JS agree on the same query. Focused harness assertions and G3 verification.
Status
Current QuickJS capability auditing says
matchMedia()answers false to every query. The API exists, but the returned answer is not connected to MacSurf's real media-query evaluator or viewport state.Scope
MediaQueryListwith correctmediaandmatches.changeevent / listener compatibility) when viewport-relevant state changes.Do not fabricate support for media features the CSS engine itself cannot evaluate.
Acceptance
For a known viewport,
(min-width: 500px)and(max-width: 500px)return opposite correct values; resizing across the threshold updatesmatchesand fires one change notification; CSS and JS agree on the same query. Focused harness assertions and G3 verification.