I'm working with a glyph font and looking to create a specific visual effect:
Here's the code I have so far:
<div class="ico linkedin">linkedin</div>
.ico {border-radius:10em; background:black; color:white}
.linkedin {visibility:hidden;}
.linkedin:first-letter {
font-family:'JustVector';
font-size:900%;
text-indent:1em;
visibility:visible
}
This approach works in Chrome, but turns out it doesn't work in Firefox or Internet Explorer 9. It also raises accessibility concerns as screen readers like JAWS don’t acknowledge the elements with hidden
or display:none
.
In an attempt to address this issue, I experimented with:
.linkedin {position:absolute; left:-5em}
.linkedin:first-letter {/*etc*/ position:absolute; left:6em}
Unfortunately, this solution didn’t yield the desired result. Is there a proper and accessible way to achieve this effect?