Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#6736 closed bug (fixed)

Effects: Bugs with dir=rtl and position.right

Reported by: ALLPRO Owned by:
Priority: minor Milestone: 1.8.8
Component: ui.effects.core Version: 1.8.6
Keywords: Cc:
Blocked by: Blocking:

Description

The slide effect - .hide('slide') / .show('slide') - does not work under these conditions:

1) BODY or container-element has: dir="rtl"

2) Effect-element has: position: absolute;

3) Effect-element has: right: 5px; (any value)

In this circumstance: On hide() the element's size fluctuates slightly and then it disappears; The reverse happens on show().

If EITHER the 'rtl' or 'right' values are removed, everything works fine.

This affects ALL versions of jQuery and UI, including jQ 1.4.4 and UI 1.8.6. I tested only in IE7/8 and Chrome - it is identical in both browsers. I assume other browsers will react the same way.

Here is a demo page that shows the issue...

http://layout.jquery-dev.net/test/slide_rtl.html

RECOMMENDED FIX

A 'left' position is assigned when this effect starts. At the same time, the 'right' position should be removed (after saving it). When the animation completes, reset the right position to its previous value.

The demo page simulates this fix. It can be enabled & disabled using the button at the top of the page.

As far as I know, this CSS modification could be applied without problem under ALL conditions, for all animations, since the effects module always calculates everything *from the left*.

Change History (4)

comment:1 Changed 9 years ago by Kevin Dalman

Resolution: fixed
Status: newclosed

Effects: set right/bottom to 'auto' so effects work with dir=rtl. Fixed #6736 - Bug in slide effect when dir=rtl and has position.right.

Changeset: 208454934439482cdbef8ba67a8557a799d44abb

comment:2 Changed 9 years ago by Scott González

Summary: But in slide effect when dir=rtl and has position.rightEffects: Bugs with dir=rtl and position.right

comment:3 Changed 9 years ago by Kevin Dalman

Effects: set right/bottom to 'auto' so effects work with dir=rtl. Fixed #6736 - Bug in slide effect when dir=rtl and has position.right.

Changeset: b475ae74dfc72a46b2ed7e988ffad461e76b2ea2

comment:4 Changed 9 years ago by Scott González

Milestone: 1.91.8.8
Note: See TracTickets for help on using tickets.