Skip to content

Conversation

kborchers
Copy link
Member

Popup: Added show/hide animations and a demo

@jzaefferer
Copy link
Member

Good start, but really needs to use the _show and _hide methods from $.Widget, see Tooltip for reference. The todo on the wiki page was a bit misleading: The feature got finalized a few months ago...

@kborchers
Copy link
Member Author

Ok. I started doing it that way but wasn't sure if that was right so went this route. I should trust my instincts. I'll fix it when I get into work.

@kborchers
Copy link
Member Author

OK, couldn't wait until I got into work. How does that look? I still left the default as null and checked for that because as I understood the wiki, we want slideDown and fadeOut as the defaults and this allows for that without requiring effects.

@jzaefferer
Copy link
Member

The default looks okay, though it should be possible to just set that as the default, instead of having to use the custom code.

The animation.html demo is, well, less optimal. Need to find something that isn't ridiculously annoying. Also please add new demos to their index.html.

@kborchers
Copy link
Member Author

Heh, I was just trying to make it obvious that effects were being used but I can make it less annoying. I will clean up the default, change the effects in the demo and add the demo to index.

@kborchers
Copy link
Member Author

This should look better. Also, I wasn't sure if I should use hide: true or hide: "fadeOut" for the default hide since true implies the default for _show which is fadeOut. I went with fadeOut since it seemed more self documenting than true but I can easily change that if necessary.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apart from hiding the popup, close() also sets aria attributes. That part is actually useful on init, the animation and positioning isn't. Let's refactor that.

@kborchers
Copy link
Member Author

Try, try again.

@jzaefferer jzaefferer merged commit 2196b74 into jquery:master Sep 21, 2011
@jzaefferer
Copy link
Member

Okay, landed this, along with some additional cleanup: 6d430e4...cb372b7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants