Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                `<!--
  This is a demo of how to add basic custom colors to Font Awesome's Duotone icons.

  1. We're calling all Font Awesome Pro styling and icons via a Font Awesome Kit. See the <head> section of this HTML for the exact syntax. Read more about kits at https://blog.fontawesome.com/introducing-font-awesome-kits-7134d1d59959

  2. The general layout and decorative styling are being handled by the CSS included in the "demo styling" portion of this pen's CSS - anything that starts with "demo-*" is demo styling and not needed for core functionality of the demo to work.

  3. We're using HTML color names to keep things simple. Check them all out at https://htmlcolorcodes.com/color-names.

  4. Remember to check out our full documentation at _____.
-->

<html>
  <head>
    <title>Font Awesome Duotone Icons: Basic Coloring</title>
    
    <script src="https://kit-pro.fontawesome.com/releases/v5.10.1/js/pro.min.js" data-auto-fetch-svg></script>
  </head>

  <body>
    <main class="demo-frame">
      
      <section class="demo">
        <article class="demo-example">
          <i class="fad fa-apple-alt fa-fw" style="color: red;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-acorn fa-fw" style="color: sienna;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-award fa-fw" style="color: dodgerblue;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-bacon fa-fw" style="color: lightcoral;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-camera-retro fa-fw" style="color: slategray;"></i>
        </article>
      </section>

      <section class="demo">
        <article class="demo-example">
          <i class="fad fa-biohazard fa-fw" style="color: darkorange;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-sticky-note fa-fw" style="color: gold;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-disease fa-fw" style="color: darkseagreen;"></i>
        </article>
        
        <article class="demo-example">
          <i class="fad fa-draw-polygon fa-fw" style="color: lightskyblue;"></i>
        </article>

        <article class="demo-example">
          <i class="fad fa-dragon fa-fw" style="color: olivedrab;"></i>
        </article>
      </section>

    </main>
  </body>
</html>
              
            
!

CSS

              
                /* demo styling - just frosting + presentation - no need to copy this into your project. */
* {
  box-sizing: border-box;
}

 /* making a nice frame/layout for examples */
.demo-frame {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: -1rem;
  padding: 3rem;
  min-height: 100vh;
  color: rgb(52, 58, 64);
}

/* individual demo styling */
.demo {
  margin-right: -1.5rem;
  margin-bottom: -1.5rem;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  padding: 0;
}

/* individual example */
.demo-example {
  font-size: 5rem;
  padding: 1.5rem;
}
              
            
!

JS

              
                
              
            
!
999px

Console