The text-transform CSS property changes how an element's text is capitalized. It can be used to make text appear in title case, all-uppercase or all-lowercase, or with each word capitalized.
Developers can utilize CSS properties to change a text font's case while authoring and creating a website. In this article, we'll cover two approaches: utilizing text-transform and using font-variant.
The text-transform changes the casing style for a section of text.
p-none {
text-transform: none;
}
p-caps {
text-transform: capitalize;
}
p-upper {
text-transform: uppercase;
}
p-lower {
text-transform: lowercase;
}
Style | Display |
---|---|
<span class="p-caps">coding tools for all</span> | coding tools for all |
<span class="p-upper">coding TOOLS for All</span> | coding TOOLS for All |
<span class="p-lower">coding TOOLS for All</span> | coding TOOLS for All |
…
…