Monday, 19 August 2013

adding line break on pseudo element

adding line break on pseudo element

After each h2 I want to append and style a dash and after that a line break.
I tried the following:
h2:after {
content: '\A\2014';
white-space: pre;
font-size: 70px;
}
It does work in general, but when I in- or decrease the font-size, the
space both over and under the dash change, instead of just the dash-size.
I also tried adding a line-height: 0.6em; but it seems to move everything
around.
At the moment I'm getting this:

I want to get this, being able to change the space:

Here is the FIDDLE

No comments:

Post a Comment