Ticket #3328 (closed bug: fixed)

Opened 7 years ago

Last modified 6 years ago

Containment (resizable and draggable) not working when container has overflow:hidden

Reported by: c_t Owned by: paul
Priority: major Milestone: 1.6rc2
Component: ui.draggable Version: 1.6b
Keywords: containment, overflow Cc:
Blocking: Blocked by:


Assume you have a resizable and/or draggable inside a container with the containment-option specified to constrain the resize- and drag-operations to that container. If the container has the css-property overflow:hidden assigned and if it's content is larger than the container itself (i.e. without overflow:hidden the content would overlap) then the restriction does not work.

This is due to the fact, that jquery ui thinks the container is scrollable while it isn't due to the css-property.

I have appended a fix that makes the containment-option work for both resizables and draggables. I would really appreaciate it to see the patch included in 1.6 .


containment_in_overflow_hidden.diff Download (2.2 KB) - added by c_t 7 years ago.
Make containment-restriction work for containers with overflow:hidden

Change History

Changed 7 years ago by c_t

Make containment-restriction work for containers with overflow:hidden

comment:1 Changed 7 years ago by paul

  • Status changed from new to closed
  • Resolution set to fixed

Looks good, thanks! Fixed in r680.

comment:2 Changed 7 years ago by rdworth

  • Milestone changed from 1.6 to 1.6rc2

comment:3 Changed 6 years ago by paul

  • Component changed from ui.core to ui.draggable
Note: See TracTickets for help on using tickets.