Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ 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

Auto Save

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

              
                <header>
</header>
<main>
   <h1>Customer Testimonials</h1>
   <div class="blurb">

      <h3>What people are saying about us</h3>
      <hr />
      <p>
         Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin sem nulla, pretium ut convallis non, mollis vel erat. Proin vel nibh arcu. Vivamus a augue at quam lacinia maximus.
      </p>
      <p>
         <strong>Vestibulum dapibus ex dictum felis facilisis, id fermentum magna semper.</strong> Phasellus ac eleifend lectus, nec tristique mi. In suscipit dolor quis neque ultricies efficitur ut quis eros. Nullam hendrerit arcu et nisl hendrerit finibus. Vivamus a dolor suscipit, interdum sapien non, posuere lorem. Maecenas id nulla ut turpis faucibus feugiat accumsan sit amet neque.
      </p>
      <p>
         In hac habitasse platea dictumst. Praesent finibus cursus ipsum vel commodo. Pellentesque bibendum dictum nulla, quis vehicula arcu convallis quis. Etiam mi ex, aliquam ut ante sit amet, convallis luctus augue. Quisque sodales, sapien congue aliquam volutpat, urna erat volutpat nisi, vitae tempus tellus odio id arcu. <strong>Cras sollicitudin eget neque dictum blandit.</strong>
      </p>
   </div>
   <ul class="testimonials clearfix">
      <li>
         <figure>
            <blockquote>
               <p>
                  Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin sem nulla, pretium ut convallis non, mollis vel erat. Proin vel nibh arcu. Vivamus a augue at quam lacinia maximus.
               </p>
            </blockquote>
            <figcaption>
               <span>John D.</span><span>ACME INC</span>
            </figcaption>
         </figure>
      </li>
      <li>
         <figure>
            <blockquote>
               <p>
                  Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin sem nulla, pretium ut convallis non, mollis vel erat. Proin vel nibh arcu. Vivamus a augue at quam lacinia maximus.
               </p>
            </blockquote>
            <figcaption>
               <span>John D.</span><span>ACME INC</span>
            </figcaption>
         </figure>
      </li>
      <li>
         <figure>
            <blockquote>
               <p>
                  Lorem ipsum dolor sit amet, consectetur adipiscing elit. Proin sem nulla, pretium ut convallis non, mollis vel erat. Proin vel nibh arcu. Vivamus a augue at quam lacinia maximus.
               </p>
            </blockquote>
            <figcaption>
               <span>John D.</span><span>ACME INC</span>
            </figcaption>
         </figure>
      </li>
   </ul>
</main>
<footer></footer>
              
            
!

CSS

              
                $headerColor: #ff6600;
$footerColor: #333;
$testimonialQuoteColor: #a3c8db;
$testimonialCustomerColor: #d9d9d9;
$testimonialQuoteSymbolColor: whitesmoke;
$testimonialLightenPercent: 10%;
$primaryTextColor: #333;

* {
   color: #333;
}

.clearfix::after {
   content: "";
   display: table;
   clear: both;
} // end clearfix

header {
   background-color: $headerColor;
   height: 80px;
} // end header

footer {
   background: $footerColor;
   height: 300px;
}

main {
   max-width: 64em;
   margin: 0 auto;
   padding: 0 2%;

   h1 {
      margin-bottom: 10px;
   }
   h3 {
      margin-top: 0;
   }

   .blurb {
      margin-bottom: 25px;
   }

   ul.testimonials {
      list-style: none;
      padding: 0;
      margin: 0 0 35px 0;

      figure,
      blockquote {
         margin: 0;
      }

      blockquote,
      figcaption {
         border-radius: 8px;
         padding: 10px;
      }

      blockquote {
         background: $testimonialQuoteColor;
         position: relative;

         &::after {
            content: "";
            position: absolute;
            bottom: -15px;
            right: 25px;
            border-width: 15px 15px 0;
            border-style: solid;
            border-color: $testimonialQuoteColor transparent;
            display: block;
            width: 0;
         }

         p {
            margin: 0;
            padding: 10px 20px;

            &::before,
            &::after {
               font-size: 3em;
               display: block;
               height: 0.5em;
               color: $testimonialQuoteSymbolColor;
               position: absolute;
            }

            &::before {
               content: "\201C\FE0E";
               top: 0;
               left: 10px;
            }
            &::after {
               content: "\201D\FE0E";
               bottom: 10px;
               right: 10px;
            }
         }
      }

      figcaption {
         float: right;
         background: $testimonialCustomerColor;
         margin-top: 20px;
         width: max-content;
         min-width: 150px;
         text-align: center;

         span {
            display: block;
         }

         span:first-child {
            font-weight: bold;
         }
      }

      li {
         max-width: 80%;
         margin: 10px 0;
         float: right;

         &:nth-child(odd) {
            float: left;

            blockquote {
               background: lighten(
                  $testimonialQuoteColor,
                  $testimonialLightenPercent
               );
               &::after {
                  border-color: lighten(
                        $testimonialQuoteColor,
                        $testimonialLightenPercent
                     )
                     transparent;
                  right: unset;
                  left: 25px;
               }
            }
            figcaption {
               float: left;
            }
         }
      }
   }
}

              
            
!

JS

              
                
              
            
!
999px

Console