-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use CSS range syntax in media queries #1833
Changes from 14 commits
604c5e5
069d2f3
cec835b
355e1b3
9c335f2
02a9cd4
5aecbfa
a69bc0e
2af2547
a9bf3d1
d76c16d
bec17cf
46d4ba2
ea7b2bc
4c01373
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<html lang="en"> | ||
<head> | ||
<meta charset="utf-8"> | ||
<title>...</title> | ||
</head> | ||
<body> | ||
<div class="wp-site-blocks"> | ||
<figure class="wp-block-embed is-type-rich is-provider-twitter wp-block-embed-twitter"> | ||
<div class="wp-block-embed__wrapper"> | ||
<blockquote class="twitter-tweet" data-width="550" data-dnt="true"><p lang="en" dir="ltr">We want your feedback for the Privacy Sandbox 📨<br><br>Learn why your feedback is critical through real examples and learn how to provide it ↓ <a href="https://t.co/anGk6gWkbc">https://t.co/anGk6gWkbc</a></p>— Chrome for Developers (@ChromiumDev) <a href="https://twitter.com/ChromiumDev/status/1636796541368139777?ref_src=twsrc%5Etfw">March 17, 2023</a></blockquote> | ||
<script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script> | ||
</div> | ||
</figure> | ||
</div> | ||
</body> | ||
</html> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
return static function ( Test_Embed_Optimizer_Optimization_Detective $test_case ): void { | ||
add_filter( 'od_breakpoint_max_widths', '__return_empty_array' ); | ||
|
||
$test_case->populate_url_metrics( | ||
array( | ||
array( | ||
'xpath' => '/HTML/BODY/DIV[@class=\'wp-site-blocks\']/*[1][self::FIGURE]/*[1][self::DIV]', | ||
'isLCP' => true, | ||
'intersectionRatio' => 1, | ||
'resizedBoundingClientRect' => array_merge( $test_case->get_sample_dom_rect(), array( 'height' => 500 ) ), | ||
), | ||
) | ||
); | ||
}; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change fixes a bug I noticed which can happen when a site is configured to have zero breakpoints (which is very unlikely). In this case, the return value of
od_generate_media_query()
isnull
since the minimum is0
and the maximum isnull
.