Skip to content

Commit 664a7a7

Browse files
committed
Remove height from audio:not([controls]) in iOS5
A bug in iOS5 means that `audio` elements without controls are not entirely hidden. They retain some height, as demonstrated in this test case: http://jsbin.com/ios-audio-bug/3 The fix is to add `height: 0` to the rule. Fix #69
1 parent 5e5496c commit 664a7a7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

normalize.css

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! normalize.css 2012-02-07T12:37 UTC - http://github.com/necolas/normalize.css */
1+
/*! normalize.css 2012-03-06T10:21 UTC - http://github.com/necolas/normalize.css */
22

33
/* =============================================================================
44
HTML5 display definitions
@@ -36,10 +36,12 @@ video {
3636

3737
/*
3838
* Prevents modern browsers from displaying 'audio' without controls
39+
* Remove excess height in iOS5 devices
3940
*/
4041

4142
audio:not([controls]) {
4243
display: none;
44+
height: 0;
4345
}
4446

4547
/*
@@ -369,7 +371,7 @@ fieldset {
369371

370372
/*
371373
* 1. Corrects color not being inherited in IE6/7/8/9
372-
* 2. Corrects text not wrapping in FF3
374+
* 2. Corrects text not wrapping in FF3
373375
* 3. Corrects alignment displayed oddly in IE6/7
374376
*/
375377

0 commit comments

Comments
 (0)