Skip to content

Commit abec688

Browse files
committed
Restore matchMedia comment
1 parent ebae472 commit abec688

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

experimental/tests.mjs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,9 @@ export const ExperimentalSuites = freezeSuites([
194194
const widths = [768, 704, 640, 560, 480];
195195
const MATCH_MEDIA_QUERY_BREAKPOINT = 640;
196196

197+
// The matchMedia query is "(max-width: 640px)"
198+
// Starting from a width > 640px, we'll only get 1 event when crossing to <= 640px
199+
// This happens when the width changes from 704px to 640px
197200
const resizeWorkPromise = new Promise((resolve) => {
198201
page.addEventListener("resize-work-complete", resolve, { once: true });
199202
});

0 commit comments

Comments
 (0)