I have a Responsive Header I have created that half works.
In Google Chrome it adds extra spacing when the window is shrunk and in FireFox is doesn’t allow grayscale effects. I would like to remove that spacing and allow grayscale hover.
This is the difference between the two.
URL is http://www.bradlyspicer.net
#header {
min-height: 310px;
margin: 0px;
padding: 0px;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
width: 100%;
}
.home-header {
min-height: 310px;
background-image: url('http://hdwallpapercollection.com/wp-content/uploads/2013/08/roma-city-wallpaper.jpg');
background-repeat: no-repeat;
background-position: 0% -150;
-webkit-filter: grayscale(100%);
-moz-filter: grayscale(100%);
-o-filter: grayscale(100%);
-ms-filter: grayscale(100%);
filter: grayscale(100%);
-o-transition:.5s;
-ms-transition:.5s;
-moz-transition:.5s;
-webkit-transition:.5s;
/* ...and now for the proper property */
transition:.5s;
}
.home-header:hover {
-webkit-filter: grayscale(0%);
-moz-filter: grayscale(0%);
-o-filter: grayscale(0%);
-ms-filter: grayscale(0%);
filter: grayscale(0%);
}
Solution for spacing
Reason : It’s because initially your
background-position
was set to0% -150
so it was making space between it.Solution for grayscale in Firefox
Reason : It’s because now firefox grayscale their images using svg inside filter.
You should center your background and add a filter for FF.