Foundation CSS Typography Helpers Text Alignment
Foundation CSS is an open-source & responsive front-end framework built by ZURB foundation in September 2011, that makes it easy to design beautiful responsive websites, apps, and emails to look amazing & can be accessible to any device. It is used by many companies such as Facebook, eBay, Mozilla, Adobe, and even Disney. The framework is built on Saas-like bootstrap. It is more sophisticated, flexible, and easily customizable. It also comes with CLI, so it’s easy to use it with module bundlers. It offers the Fastclick.js tool for faster rendering on mobile devices.
The Foundation CSS helper classes allow us to scaffold certain typographic styles faster. Foundation CSS has multiple typography helpers such as Text Alignment, Subheader, Lead Paragraph, Unbulleted List, and Typescale. In this article, we will learn about the Text Alignment Typographic helper.
The Foundation CSS Text Alignment typographic helper changes the text alignment of a block of text. To change the text alignment of a block of text in Foundation CSS, we use the .text-left, .text-right, .text-center or .text-justify classes. These classes can be applied to any tag with a text block content i.e. <div>, <span> or <h1> tags.
Foundation CSS Text Alignment Typographic Helper Classes:
- text-left: This class aligns the text to the left margin.
- text-right: This class aligns the text to the right margin.
- text-center: This class aligns the text to the center of the block.
- text-justify: This class justifies the block of text.
Example 1: The following example demonstrates all the Text Alignment typographic helper classes.
Example 2:The following example demonstrates all the Text Alignment typographic helper classes in a card element.
Please Login to comment...