Hides text in an element so you can see the background, but still leaves it visible to screen readers.
This is based on Scott Kellum's Image Replacement technique but uses 110% for better coverage.
Note: This only works on
blockorinline-blockelements and works best when a width is set.
@include hide-text($direction);Default:
right
Takes a value of either right or left to apply different types of text replacement. See the source for the different techniques.
.element {
@include hide-text();
}.element {
text-indent: 110%;
white-space: nowrap;
overflow: hidden;
}