Closed Bug 1892314 Opened 2 years ago Closed 2 years ago

Flex-wrap sometimes causes blocks wrapping when it shouldn't.

Categories

(Core :: Layout: Flexbox, defect)

Firefox 125
defect

Tracking

()

RESOLVED DUPLICATE of bug 1893127

People

(Reporter: leeroyjenkins176, Unassigned)

Details

Attachments

(2 files)

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:125.0) Gecko/20100101 Firefox/125.0

Steps to reproduce:

The flexbox container has the property flex-wrap: wrap; and contains two elements. The child elements have a left margin of 75px, and their width is calc(50% - 75px). In theory, there should be enough space for the elements to always fit on one line without wrapping.
https://codepen.io/coyibe2003/pen/vYMVvrR?editors=1100
https://drive.google.com/file/d/1lAYwFSBnMR5I4u2maF9n4lbnv1NqLMSC/view?usp=sharing

Actual results:

At a certain screen width, the elements are displayed one below the other.

Expected results:

The elements are displayed in a row without wrapping.

Component: Untriaged → Layout: Flexbox
Product: Firefox → Core

Can reproduce on Nightly 127 on Ubuntu 22.04.

Curiously, as you shrink the width of the browser window, well before it ends up in the incorrect position, the rightmost item rapidly oscillates between the correct position and the incorrect position.

Severity: -- → S3
Status: UNCONFIRMED → NEW
Ever confirmed: true

A new problem for the same reason, now in the grid layout.
https://codepen.io/coyibe2003/pen/dyEPJWX

This is fixed on currently Nightly. Mozregression finds this is a dup of bug 1893127.

Status: NEW → RESOLVED
Closed: 2 years ago
Duplicate of bug: 1893127
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: