Closed Bug 1533016 Opened 7 months ago Closed 6 months ago

Width for DIV not calculated properly with position:absolute and overflow:auto

Categories

(Core :: Layout: Scrolling and Overflow, defect)

65 Branch
defect
Not set

Tracking

()

RESOLVED DUPLICATE of bug 764076

People

(Reporter: andre.wegmueller, Unassigned)

Details

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

Steps to reproduce:

When a DIV has position:absolute and overflow-y:auto and the content of that DIV requires vertical scrollbars, the size of that DIV is not calculated properly. Instead of increasing the width of the DIV, the scrollbar overlaps the content.

The problem can be easily reproduced with this Fiddle: https://jsfiddle.net/catkrwg8/4/

Actual results:

The size of DIV does not change when overflow-y is set to auto. Instead the scrollbar overlaps the content of the DIV, which should not happen.

Expected results:

The size of the DIV should change, when a scrollbar is required. This works as expected in Chrome and Internet Explorer.

Note 1: when the .outer DIV has the .scrollable class initially the size is wrong too.

Note 2: if the .scrollable class would use overflow-y: scroll instead of overflow-y: auto the size of the DIV is calculated correctly.

Component: Untriaged → Layout: Block and Inline
Product: Firefox → Core

Maybe duplication of Bug 764076(Bug 1335265)

Component: Layout: Block and Inline → Layout: Scrolling and Overflow

(In reply to Alice0775 White from comment #1)

Maybe duplication of Bug 764076(Bug 1335265)

Yep, I believe so.

Status: UNCONFIRMED → RESOLVED
Closed: 6 months ago
Resolution: --- → DUPLICATE
Duplicate of bug: 764076
You need to log in before you can comment on or make changes to this bug.