Bug Tracker

Opened 12 years ago

Closed 12 years ago

#9336 closed enhancement (wontfix)

:hidden doesn't check for opacity: 0

Reported by: lonesomeday Owned by:
Priority: low Milestone: 1.7
Component: effects Version: 1.6.1
Keywords: needsreview, 1.7-discuss Cc:
Blocked by: Blocking:

Description (last modified by scottgonzalez)

The logical way to prepare an element to be faded in using fadeIn is by setting the opacity style to 0. However, invoking is(':hidden') on an element with opacity 0 returns false, unless hidden by display: none.

jsFiddle example

StackOverflow question

It would be useful if the :hidden filter checked the opacity setting.

Change History (12)

comment:1 Changed 12 years ago by Rick Waldron

Component: unfiledeffects
Keywords: needsreview added
Status: newopen

Technically, this is all correct - but I see the conundrum. Marking "needsreview" for further bike-shedding.

comment:2 Changed 12 years ago by john

Keywords: 1.7-discuss added

Nominating ticket for 1.7 discussion.

comment:3 Changed 12 years ago by Rick Waldron

Description: modified (diff)

+0, This needs discussion

comment:4 Changed 12 years ago by jaubourg

-1, It's exactly as documented. The element takes space and should be considered hidden.

comment:5 Changed 12 years ago by timmywil

-1, It is not "hidden" if visibility: hidden either.

comment:6 Changed 12 years ago by paul.irish

Description: modified (diff)

-1, that'd be more of an :invisible as the element still takes up space, just like with visibility:hidden

The dimensions == 0 check is expected by users nowadays.

comment:7 Changed 12 years ago by dmethvin

-1, If we do opacity:0 then what about top:-10000px;left:-10000px as well? I don't think we can change the standard to visible to human eyeballs and the docs are already clear on this.

Version 0, edited 12 years ago by dmethvin (next)

comment:8 Changed 12 years ago by lonesomeday

I understand the reasoning for not having it as part of the hidden filter. Is there an argument for adding the check to the fadeIn/fadeOut/fadeToggle methods instead? That's the main utility I see this as having.

comment:9 Changed 12 years ago by john

Description: modified (diff)

-1, Different semantics here.

comment:10 Changed 12 years ago by ajpiano

Description: modified (diff)

-1, Unrealistic.

comment:11 Changed 12 years ago by scottgonzalez

Description: modified (diff)

-1

comment:12 Changed 12 years ago by Rick Waldron

Milestone: 1.next1.7
Priority: undecidedlow
Resolution: wontfix
Status: openclosed

Closing per 1.7 roadmap meeting resolution

Note: See TracTickets for help on using tickets.