Bug Tracker

Modify

Ticket #11955 (closed bug: invalid)

Opened 11 months ago

Last modified 11 months ago

Delay, Animate, CSS Bug

Reported by: tom@… Owned by: tom@…
Priority: low Milestone: None
Component: effects Version: 1.7.2
Keywords: Cc:
Blocking: Blocked by:

Description

Inspect the element .block as it goes to make the black box smaller... you will notice overflow: hidden ends up getting set instead (default jquery feature)... but on the other animation (expanding) there is no delay and the override for setting .css('overflow', 'visible') works.

Example:  http://jsfiddle.net/8TdzP/

End result should make overflow: visible set while animation is happening instead of letting jQuery set it to hidden.

Change History

comment:1 follow-up: ↓ 2 Changed 11 months ago by rwaldron

  • Owner set to tom@…
  • Status changed from new to pending

Are you trying to set the "overflow" property _after_ the animation is complete? If so, then you'll need to use the animate complete callback.

 http://jsfiddle.net/rwaldron/hFbpF/2/

comment:2 in reply to: ↑ 1 Changed 11 months ago by tom@…

  • Status changed from pending to new

Replying to rwaldron:

Are you trying to set the "overflow" property _after_ the animation is complete? If so, then you'll need to use the animate complete callback.

 http://jsfiddle.net/rwaldron/hFbpF/2/

I am trying to set the overflow to visible instead of it automatically changing to hidden when it performs the animation.

I found a solution, which is to make a class:

.overflowForce {
     overflow: visible !important;
}

and to call it like such:

$('.block').addClass('overflowForce').animate({width: 150}, {
    complete: function() {
        $(this).removeClass('overflowForce');
    }
});

 http://jsfiddle.net/hFbpF/3/

comment:3 Changed 11 months ago by mikesherov

  • Priority changed from undecided to low
  • Resolution set to invalid
  • Status changed from new to closed
  • Component changed from unfiled to effects

lots of animations need overflow: hidden to display properly. This is a feature, not a bug. It sounds like you have found a workaround yourself that you like. If you need more help, please use the forum or stackoverflow.com

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.