I'm using a UL to display the options for data visualizations on a site. The items are displayed inline and retrieve the image from a sprite png. This works fine in FireFox 3x, but in Chrome and Safari, the first item disappears. If I replace the sprites with the individual images, all of the list items display properly.
Here's the CSS:
ul {margin:5px 0 0;padding:10px 6px 6px;}
li {display:inline;padding:cursor:pointer;padding:11px 2px 2px 5px;}
li.active {border:1px solid #ccc;background-color:#fff;}
li div {display:inline;padding:6px 10px;}
.bttns {background-image:url('../sprites.png');background-repeat:no-repeat;}
.bttns-info {background-position: 0 -726px;height:16px;width:16px;}
.bttns-table {background-position: 0 -330px;height:16px;width:16px;}
.bttns-chart {background-position: 0 0;height:16px;width:16px;}
And the HTML:
<ul>
<li class="active ui-corner-all"><div class="bttns bttns-info"></div></li>
<li><div class="bttns bttns-table"></div></li>
<li><div class="bttns bttns-chart"></div></li>
</ul>
It's loosely based on the CSS from the jQuery UI library. And it's nested in a div using the ui-accordion-header class. None of the tweaks I've tried have made a difference.
Am I missing something? It's pulling down the sprites; the positions are correct; the other items display properly when the active class is applied to them. It's just odd.
Thanks, soren