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 is required to process package imports. If you need a different preprocessor remove all packages first.

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

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 Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

HTML

              
                <div class="wrapper container">
  <h1>Example page</h1>
  
  <p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Cumque, voluptate corrupti nam adipisci ad enim accusantium iusto distinctio non fugiat esse. Fugiat neque enim pariatur voluptas numquam nemo dolorum doloribus.</p>
  
  <p>Lorem ipsum dolor, sit amet consectetur adipisicing elit. Nisi itaque aut inventore ratione quasi explicabo consequatur laboriosam temporibus, illo architecto reiciendis dignissimos pariatur facilis, neque officiis doloremque doloribus. Minima, blanditiis!</p>
  <p>Laborum molestias aspernatur quibusdam ex officia ad eos a soluta et assumenda, odit sequi ipsa, maiores provident fugit similique animi harum aut minima. Ut autem pariatur facilis eligendi veritatis sequi!</p>
  <p>Eos nemo nisi facere quisquam nostrum commodi ab illo labore atque sed, neque quidem molestias facilis accusantium doloribus doloremque temporibus. Autem natus, libero minima vero quod quaerat voluptatum accusamus quasi?</p>
  <p>Quasi, in rerum omnis fugit ducimus commodi error quia hic harum obcaecati repudiandae totam asperiores, accusamus sapiente laboriosam veniam odio soluta ea quis distinctio. Libero illum repellendus ratione placeat odio!</p>
  <p>In voluptates quos quas delectus, voluptatibus itaque a tenetur magni fuga vero maxime sint eveniet rem, quis eaque optio eius repudiandae ratione dicta totam? Id consequatur quaerat suscipit a rerum.</p>
  <p>Facere aliquam ea tenetur earum molestiae! Earum quod sunt est rerum ipsa ut? Autem quas obcaecati porro ipsum eum quibusdam, cupiditate doloribus omnis, cum corporis itaque, ex ut iusto modi.</p>
</div>

<div class="modal">
  <div class="modal-inner container">
    <h3>Modal</h3>
    
    <p>After a 1s delay, <code>.modal</code> (and contents) fade-in using a basic CSS animation. This uses no JS or jQuery.</p>
  </div>
</div>
              
            
!

CSS

              
                html {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  background: #F6D0BF;
  font-size: 18px;
  line-height: 1.4;
}

.wrapper {
  max-width: 820px;
  margin: auto;
}
.container {
  padding: 1em;
}

.block {
  display: inline-block;
  margin: 1em 10%;
  width: 30%;
  height: 100px;
}

// Modal animation
@keyframes fadein {
  from { opacity: 0; }
  to { opacity: 1; }
}

// Modal styling
.modal {
  background: rgba(225, 239, 202, 0.7);
  display: flex;
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  z-index: 20;
  opacity: 0;
  
  // Animation trigger  
  animation: fadein 1s;
  animation-delay: 1s;
  animation-fill-mode: forwards;
}
.modal-inner {
  background: rgb(225, 239, 202);
  color: black;
  border: 2px dashed white;
  margin: auto; // Centres the element vertically & horizontally due
  max-width: 320px;
  text-align: center;
  font-size: 16px;
}
              
            
!

JS

              
                
              
            
!
999px

Console