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

              
                <div class="listing">
  <div class="box-title">
    <h1>This is a title</h1>

    <p>This is the introductory text for this section of the site.</p>

  </div>
  <div class="box-feature">
    <img class="box-image" src="http://placehold.it/900x450" alt="placeholder">

    <h2 class="box-feature-title">Featured Item</h2>
    <div class="box-content">
      <p>The first, therefore usually the latest but could be flagged as a feature, item is the feature. This item gets a big spot up next to the title of this section.</p>
      <p>It might have an image too. It's special like that.</p>
    </div>
  </div>
  <div class="box-newer">
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-newer">
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-newer">
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-newer box-talk box-media">
    <img src="http://placehold.it/500x350" alt="placeholder" />
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-newer">
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-newer">
    <h3>New Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a larger box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>
  <div class="box-older">
    <h3>Older Item</h3>
    <p>The newer items or next in priority after the feature are displayed in a smaller box. We can show additional content for these items.</p>

  </div>

</div>
              
            
!

CSS

              
                .box-feature {
  grid-column: 4 / -1;
  grid-row: 1 / 2;
  display: grid;
  grid-gap: 20px;
  grid-template-columns: repeat(6, 1fr);
}

.box-feature .box-image {
  align-self: stretch;
  justify-self: stretch;
  grid-column: 1 / -1;
  grid-row: 1 / 4;
}

.box-feature .box-feature-title {
  grid-column: 3 / -1;
  grid-row: 1;
  background-color: rgba(0, 0, 0, 0.7);
  color: #fff;
  align-self: start;
  padding: 20px;
}

.box-feature .box-content {
  grid-column: 2 / -1;
  grid-row: 2;
  background-color: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 20px;
}

.box-newer {
  padding: 20px;
  grid-column: auto / span 4;
}

.box-newer.box-media {
  grid-row-end: span 2;
  border: 1px dotted #7fdeff;
  background-color: transparent;
}

.box-newer.box-media,
.box-newer.box-media:nth-child(2n+1) {
  border: 1px dotted #7fdeff;
  background-color: transparent;
}

.box-newer:nth-child(2n+1) {
  background-color: #7fdeff;
}

.box-older {
  padding: 20px;
  font-size: 0.75rem;
  grid-column: auto / span 3;
}

.box-title {
  background-color: #694486;
  color: #fff;
  padding: 20px;
  align-self: start;
  grid-column: 1 / 4;
  grid-row: 1 / 2;
}

.listing {
  margin: 0 20px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-gap: 20px;
}


              
            
!

JS

              
                
              
            
!
999px

Console