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

              
                <html>
<head>
  <link rel='stylesheet' id='fontawesome' href='https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css' type='text/css' media='all' />
</head>
<body>
  <div class="wrap">
    <div class="header">default</div>
    <div>
      <p>In the textbook,</p>
      <blockquote class="default">
        <p>It is the word of Lincoln.</p>
        <blockquote>
          <p>government of the people, by the people, for the people</p>
          <cite>Lincoln</cite>
        </blockquote>
        <p>And he became a great president. </p>
      </blockquote>
      <p>It is written. For the American people it is still a special president.</p>
    </div>
    </br>
    <div class="header">custom</div>
    <div>
      <p>In the textbook,</p>
      <blockquote class="custom">
        <p>It is the word of Lincoln.</p>
        <blockquote class="custom inner-bq">
          <p>government of the people, by the people, for the people</p>
          <cite>Lincoln</cite>
        </blockquote>
        <p>And he became a great president. </p>
        <cite>textbooks</cite>
      </blockquote>
      <p>It is written. For the American people it is still a special president.</p>
    </div>
    </br>
    <div class="header">Japanease</div>
    <div>
      <p>教科書には、</p>
      <blockquote class="custom">
        <p>リンカーンの言葉です。</p>
        <blockquote class="custom inner-bq">
          <p>人民の、人民による、人民のための政治</p>
          <cite>リンカーン</cite>
        </blockquote>
        <p>そして、リンカーンは偉大な大統領になりました。</p>
        <cite>中学校教科書より</cite>
      </blockquote>
      <p>と書かれています。アメリカ国民にとっては今でも特別な大統領です。</p>
    </div>
  </div>
</body>

</html>
              
            
!

CSS

              
                $color-blue: #82D7FF;
$color-quote-bg: rgba($color-blue, .3);
$color-quote-mk: rgba($color-blue, .8);

.custom {
  quotes: "\f10d" "\f10e" "\f10d" "\f10e";
  background: $color-quote-bg;
  border-radius: 10px;
  padding: 0.5rem 0 2rem 1.5rem;
  margin: 1rem 1.5rem 1rem 0.5rem;
  position: relative;
  &::before, &::after {
    position: absolute;
    font-family: FontAwesome;
    font-size: 1.5rem;
    color: $color-quote-mk;
  }
  &::before {
    content: open-quote;
    left: 0px;
    top: 0px;
  }
  &::after {
    content: close-quote;
    right: 0px;
    bottom: 0px;
  }
  cite {
    font-size: 0.85rem;
    position: absolute;
    right: 30px;
    bottom: 0;
    padding-bottom: 0.5rem;
  }
  .inner-bq {
    border: 1px solid $color-quote-bg;
  }
}

.wrap{
  width: 600px;
}
.header {
  font-weight: bold;
  border-bottom: 1px solid #aaa;
  margin-bottom: 20px;
}
              
            
!

JS

              
                
              
            
!
999px

Console