TEXT-ALIGN.CSS

A small css module for setting text-alignment.

View on Github

Install with npm

npm install --save-dev text-align.css

The Demos

Mobile-first classes

Applies to all breakpoints

left-aligned text

right-aligned text

centered text

Larger than 'mobile'

Applies to breakpoints larger than mobile

This is some left-aligned sample text for screens larger than mobile

This is some right-aligned sample text for screens larger than mobile

This is some centered sample text for screens larger than mobile

Medium breakpoint

Applies to larger than mobile and smaller than desktop only.

This is some left-aligned sample text for the medium breakpoint

This is some right-aligned sample text for the medium breakpoint

This is some centered sample text for medium breakpoint

Large breakpoint

Applies to everything larger than desktop

This is some left-aligned sample text for desktop and larger

This is some right-aligned sample text for desktop and larger

This is some centered sample text for desktop and larger

Multi-class pattern example

This shows a paragraph where the text-align property changes at various breakpoints on a single element.