Open Bug 1640166 Opened 5 years ago Updated 2 years ago

@media (max-width) bug

Categories

(Core :: CSS Parsing and Computation, defect)

76 Branch
x86_64
Windows 10
defect

Tracking

()

UNCONFIRMED

People

(Reporter: max.frontdev, Unassigned)

Details

Attachments

(1 obsolete file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/76.0

Steps to reproduce:

I used @media (max-width: 767px) { display: none; } in my css file.

Actual results:

Last value in max-width dont work. For 766px is working, but for 767px is dont work anymore.
And so for any last value in max-width.

(In reply to Sendoo from comment #0)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/76.0

Steps to reproduce:

I used @media (max-width: 767px) { display: none; } in my css file.

Actual results:

Last value in max-width dont work.
For 766px is working, but for 767px is dont work anymore.
And so for any last value in max-width.

OS: Unspecified → Windows 10
Hardware: Unspecified → x86_64

Bugbug thinks this bug should belong to this component, but please revert this change in case of error.

Component: Untriaged → Audio/Video: Playback
Product: Firefox → Core

Could you attach a minimal test case to help make sure we're reproducing the same issue?

Moving to CSS component based on the description.

Component: Audio/Video: Playback → CSS Parsing and Computation
Flags: needinfo?(max.frontdev)

This is probably due to subpixels. max-width: 767px is equivalent to width <= 767px, if the width happens to be 767.1px or such then it won't match as expected.

In Firefox you can actually use operators to guarantee that the media queries have continuity (so @media (width <= 677px) and @media (width > 677px).

But yeah, please attach a test-case that demonstrates the issue so that we can take a closer look. Thanks!

Still waiting for the feedback from the reporter. I mark this S3 for now.

Severity: -- → S3

This looks like a duplicate of bug 1588766

Clear a needinfo that is pending on an inactive user.

Inactive users most likely will not respond; if the missing information is essential and cannot be collected another way, the bug maybe should be closed as INCOMPLETE.

For more information, please visit auto_nag documentation.

Flags: needinfo?(max.frontdev)
Attachment #9386106 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: