Open In App

Spectre Text Colors

Spectre colors are one of the most useful utilities, there are two types of things where we can use colors. Like we can set colors for the text and we can set colors for the background.

In this article, we will learn about the text color, along with understanding, how we can set the colors of the text in Spectre by using these classes.



Spectre Text Colors Class:

Syntax:



<element class = "text-colorName"> Content </element>

Below example illustrates the Spectre Text Colors.

Example:




<!DOCTYPE html>
<html>
  
<head>
    <title>SPECTRE Text Colors Class</title>
    <link rel="stylesheet"
          href=
    <link rel="stylesheet"
          href=
    <link rel="stylesheet"
          href=
</head>
  
<body>
    <center>
        <h1>GeeksforGeeks</h1>
        <strong>SPECTRE Text Colors Class</strong>
        <br><br>
        <p class="text-primary">
            Primary Text Color
        </p>
  
        <p class="text-secondary">
            Secondary Text Color
        </p>
  
        <p class="text-dark">
            Dark Text Color
        </p>
  
        <p class="text-gray">
            Gray Text Color
        </p>
  
        <p class="text-light">
            Light Color Text
        </p>
  
        <p class="text-success">
            Success Text Color
        </p>
  
        <p class="text-warning">
            Warning Text Color
        </p>
  
        <p class="text-error">
            Error Text Color
        </p>
    </center>
</body>
  
</html>

Output:

Spectre Text Colors

Reference: https://picturepan2.github.io/spectre/utilities/colors.html#colors-text


Article Tags :