You are reading...

January 4th

The styling of the miniblog navigation between the main nav and the search bar turned out to be more complicated than I thought. So here’s how I pulled it off.

The markup is simple enough

<ul id="miniblog">
<li class="miniblog"><a href="#bottom"></a></li>
<li><a href="#bottom">twitter</a> /</li>
<li><a href="#bottom">tumblr</a> /</li>
<li><a href="#bottom">flickr</a> /</li>
<li><a href="#bottom">my profile...r</a></li>
</ul>

The CSS is a bit more complicated, but easily explainable

#miniblog {
position:absolute;
right:20px;
top:96px;
padding:0;
margin:0;
}

#miniblog .miniblog {
display:block;
position:absolute;
top:0;
left:-28px;
background:url(images/miniblog.png) no-repeat 100% -32px;
height:32px;
width:95px;
}

#miniblog .miniblog:hover {
background-position:100% 0;
}

#miniblog .miniblog a {
height:19px;
width:95px;
margin:0 10px 0 0;
display:block;
}

#miniblog li {
display:inline-block;
font-size:15px;
line-height:21px;
position:relative;
top:15px;
}

#miniblog li a {
font-size:11px;
font-style:italic;
}

The two keys is to make the set the “miniblog” link as an absolute positioned element. Then the rest of the link will overlay on top of it and be clickable. Then I do a bit of positioning and inline-blocking to make it the way it looks right now.

I consider this part one because I will be doing a bit of jQuery on it to make it the navigation more dynamic. A web developer’s personal site is never finished…

Go home
blog comments powered by Disqus

This is my Twitter status linked to my Facebook status. Annoying, huh?

Tumblr : the other white short format blog.

Japanese Scientist + Poop
Friday, 2 October 2009, 1:27 pm

New Jersey Netski?
Thursday, 17 September 2009, 6:00 pm

All hail Federbot!
Monday, 14 September 2009, 6:17 am

Bill Bavasi is to the M's Fox is to Firefly
Wednesday, 9 September 2009, 9:11 pm

Your Mets starting LF...
Wednesday, 19 August 2009, 5:33 pm

I'd disagree, but then my blog design is essentially a bachelor pad
Tuesday, 18 August 2009, 10:39 pm

Officer, there's an old lady peering into our house
Saturday, 15 August 2009, 7:06 am