diff options
author | Richard Gibson <richard.gibson@gmail.com> | 2016-01-14 15:27:17 -0500 |
---|---|---|
committer | Timmy Willison <timmywillisn@gmail.com> | 2016-01-14 17:53:39 -0500 |
commit | fe05cf37ffd4795988f9b2343df2182e108728ca (patch) | |
tree | 5d3aa6ec816e00573cb3c1ccec7ada49e28fe575 /src | |
parent | dbc4608ed10bd1347649e6f1514f459957cda003 (diff) | |
download | jquery-fe05cf37ffd4795988f9b2343df2182e108728ca.tar.gz jquery-fe05cf37ffd4795988f9b2343df2182e108728ca.zip |
CSS: Stop Firefox from treating disconnected elements as cascade-hidden
Fixes gh-2833
Ref dba93f79c405373ec3a492fd0a4bf89b3136a6e6
Close gh-2835
Diffstat (limited to 'src')
-rw-r--r-- | src/css/showHide.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/css/showHide.js b/src/css/showHide.js index 9c62d5564..9e2cb1ea4 100644 --- a/src/css/showHide.js +++ b/src/css/showHide.js @@ -54,7 +54,12 @@ function showHide( elements, show ) { elem.style.display = ""; } } - if ( elem.style.display === "" && jQuery.css( elem, "display" ) === "none" ) { + if ( elem.style.display === "" && jQuery.css( elem, "display" ) === "none" && + + // Support: Firefox <=42 - 43 + // Don't set inline display on disconnected elements with computed display: none + jQuery.contains( elem.ownerDocument, elem ) ) { + values[ index ] = getDefaultDisplay( elem ); } } else { |