Closed Bug 1126725 Opened 10 years ago Closed 10 years ago

flex item larger than expected with long line of text & white-space: nowrap (and overflow: hidden; on child of flex item)

Categories

(Core :: Layout, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: flash.vkv, Unassigned)

References

Details

Attachments

(2 files)

Attached file bug.html (deleted) —
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:35.0) Gecko/20100101 Firefox/35.0
Build ID: 20150122214805

Steps to reproduce:

создаю две колонки. так чтоб правая была вся а левая сколько останеться места


Actual results:

контент расперае левую колонку


Expected results:

аналогично работе Chrome
You need to add:
  min-width:0;
to your "a" class, to allow it to shrink below its intrinsic width. Otherwise, the flexbox spec requires it to be wide enough as the longest unbreakable line of text. (which is really wide, given your "white-space: nowrap")

Chrome's behavior is a bug -- they haven't updated to match the current flexbox spec. See https://github.com/philipwalton/flexbugs and https://bugzilla.mozilla.org/show_bug.cgi?id=1043520 for more info.  The chrome bug is https://code.google.com/p/chromium/issues/detail?id=426898
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → INVALID
Attachment #8556770 - Attachment description: fixed testcase → fixed testcase (added min-width:0 to .a rule)
Summary: flex size block → flex item larger than expected with long line of text & white-space: nowrap (and overflow: hidden; on child of flex item)
Component: Untriaged → Layout
OS: Windows 7 → All
Product: Firefox → Core
Hardware: x86_64 → All
Version: 35 Branch → Trunk
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: