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

              
                
  <div class="wrapper">
    <div class="content">
      <p class="heading">Source Serif Pro <a href="https://codepen.io/mosne/pen/qOxoxa" target="_blank">advanced demo with grids</a></p>
      <h1>Grumpy wizards make toxic brew for the evil Queen and Jack.</h1>
      <p class="intro">One morning, when Gregor Samsa woke from troubled* dreams, he found himself transformed *in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections. </p>
      <p class="pullquote">"The bedding was hardly able to cover it and seemed ready to slide off any moment. His many legs, pitifully thin compared with the size of the rest of him, waved about helplessly as he looked."</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p class="pullquote">"The bedding was hardly able to cover it and seemed ready to slide off any moment. His many legs, pitifully thin compared with the size of the rest of him, waved about helplessly as he looked."</p>
 <div class="content">
      <p class="heading">Source Serif Pro</p>
      <h1>Grumpy wizards make toxic brew for the evil Queen and Jack.</h1>
      <p class="intro">One morning, when Gregor Samsa woke from troubled* dreams, he found himself transformed *in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections. </p>
      <p class="pullquote">"The bedding was hardly able to cover it and seemed ready to slide off any moment. His many legs, pitifully thin compared with the size of the rest of him, waved about helplessly as he looked."</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p>One morning, when Gregor Samsa woke from troubled dreams, he found himself transformed in his bed into a horrible vermin. He lay on his armour-like back, and if he lifted his head a little he could see his brown belly, slightly domed and divided by arches into stiff sections.</p>
      <p class="pullquote">"The bedding was hardly able to cover it and seemed ready to slide off any moment. His many legs, pitifully thin compared with the size of the rest of him, waved about helplessly as he looked."</p>
 
    </div>
    </div>
  </div>
              
            
!

CSS

              
                body {
  font-size: calc(.7vw + 14px);
  line-height: 1.5;
  font-family: 'Source Serif Pro', serif;
  font-style: normal;
  font-weight: 400;
}

* {
  box-sizing: border-box;
}

.content{
  font-size:100%;
}



.wrapper {
  margin: 0 auto;
  padding: 2em 1em;
  max-width: 45em;
}

h1 {
  font-size: calc(4em - 1rem);
  line-height: 1;
  margin-bottom: 2rem;
}

p {
  margin: 0;
  margin-bottom: 1em;
}

p.pullquote {
  font-size: 1.3em;
  margin-bottom: 1em;
  padding-left: 1.5em;
  border-width: 0px 0px 0px 3px;
  border-style: solid;
  font-weight: 700;
  margin-left: -1.5em;
}

.content .content{
  font-size:66%;
  width:66%;
  background:yellow;
  padding:1em;
}
              
            
!

JS

              
                
              
            
!
999px

Console