Hey all,
I have a simple search box that it hidden until hover(over) and hides again on hover(out). In Firefox all is normal, but in Safari there is a tiny flash after the hide animation where the full bar is visible. You can see what is happening (in Safari only) on the homepage of my site: stormink.net. (the search button is in the top-right corner)
Here is the HTML:
<form id="searchForm"> <label id="searchButton" for="searchBox" value="Search"></label>
<input id="searchBox" type="text" value="Search...">
</form>
The CSS:
#searchForm { float: right; background-color: #333333 }
#searchButton {
display: block; float: left;
height: 24px; width: 32px;
background: url(/images/STORMINKsprite.png) no-repeat;
background-color: transparent;
background-position: -325px 0;
}
#searchBox {
display: none; float: left;
margin: 5px 5px 0 0;
padding: 0 3px;
border: none;
background-color: transparent;
color: #ffffff;
height: 15px;
}
And the jQuery:
$(document).ready(function() {
$('#searchForm').hover(
function(){
$('#searchBox').show('slow');
},
function(){
$('#searchBox').hide('slow');
}
);
});
Is there any way to get rid of this, or is it just standard jQuery? It would be quite distracting. Luckily its in Safari and not Firefox, but still not very fun...
Thanks all!