File tree 2 files changed +18
-1
lines changed
2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -663,7 +663,8 @@ bot.dom.isShown = function(elem, opt_ignoreOpacity) {
663
663
function hiddenByOverflow ( e ) {
664
664
return bot . dom . getOverflowState ( e ) == bot . dom . OverflowState . HIDDEN &&
665
665
goog . array . every ( e . childNodes , function ( n ) {
666
- return ! bot . dom . isElement ( n ) || hiddenByOverflow ( n ) ;
666
+ return ! bot . dom . isElement ( n ) || hiddenByOverflow ( n ) ||
667
+ ! positiveSize ( n ) ;
667
668
} ) ;
668
669
}
669
670
return ! hiddenByOverflow ( elem ) ;
Original file line number Diff line number Diff line change 338
338
assertFalse ( isShown ( target ) ) ;
339
339
}
340
340
341
+ function testOverflowHiddenWithFixedPositionChild ( ) {
342
+ var target = findElement ( { id : 'overflowHiddenWithFixedPositionChild' } ) ;
343
+ var child = findElement ( { id : 'fixedPositionChild' } ) ;
344
+ child . innerHTML = '' ;
345
+ assertFalse ( isShown ( target ) ) ;
346
+ child . innerHTML = 'some content' ;
347
+ assertTrue ( isShown ( target ) ) ;
348
+ }
349
+
341
350
function testThatElementIsShownWithZIndex ( ) {
342
351
assertTrue ( isShown ( findElement ( { id : 'bug5109' } ) ) ) ;
343
352
}
532
541
This is a zero height/width div and overflow hidden
533
542
</ div >
534
543
544
+ < div style ="overflow:hidden; height:0; width:0; ">
545
+ < div id ="overflowHiddenWithFixedPositionChild ">
546
+ This is a zero height/width div and overflow hidden
547
+ < div id ="fixedPositionChild " style ="position:fixed "> </ div >
548
+ </ div >
549
+ </ div >
550
+
535
551
< div style ="position:relative;
536
552
width:300px;
537
553
height:300px;
You can’t perform that action at this time.
0 commit comments