Pen Settings



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


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


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.


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.


                <div class="grid-demo demo-6">
   <div class="box box-a">
     <h1 class="child-title">A</h1>
  <div class="box box-b">
    <h1 class="child-title">B</h1>
  <div class="box box-c">
    <h1 class="child-title">C</h1>
  <div class="box box-d">
    <h1 class="child-title">D</h1>
  <div class="box track">
    <h1 class="child-title">Track</h1>
  <div class="box overlap">
    <h1 class="child-title">Overlap</h1>

<p class="caption">This demo is also available for tweaking wih the Visual Grid Editor included in the <a href=""> CSS Grid Builder app</a>.</p>


                /*grid setup*/
.grid-demo {
  display: grid;

  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: auto auto 50px auto auto;
  grid-row-gap: 2px;
  grid-column-gap: 2px;

/*placing grid items*/
.box-a {
  grid-column-start: 1;
  grid-row-start: 4; 
  grid-row-end: 6;

.box-b {
  grid-column: 2 / span 2;
  grid-row-start: 4;

.box-c {
  grid-column-start: 2;
  grid-column-end: 4;
  grid-row-start: 1;

.box-d {
  grid-column-start: 1;
  grid-row-end: 2;

.track {
  grid-column: 1 / 4;
  grid-row: 2 / 3;

.overlap {
  grid-column: 3;
  grid-row: 2 / 4;

@media screen and (min-width: 476px) {
.box-e {
grid-column-start: 1;
grid-row-start: 2;

/*styles for the grid-items*/
.box {
 display: -webkit-box;
 display: -webkit-flex;
 display:    -moz-box;
 display: -ms-flexbox;
 display:         flex;
 -webkit-flex-direction: column;
     -ms-flex-direction: column;
         flex-direction: column;
 padding-right: 0;
 padding-left: 0;
 background-color: #e94f1b;

 -webkit-box-orient: vertical;
 -webkit-box-direction: normal;
    -moz-box-orient: vertical;
    -moz-box-direction: normal;

.box.track {
  background-color: #4d9959;

.box.overlap {
 position: relative;
 z-index: 6;
 background-color: rgba(35, 46, 209, .6);  

/*font styles*/
h1 {
 font-family: 'Roboto', Arial, 'Helvetica Neue', Helvetica, sans-serif;

.child-title {
 margin: 0;
 padding-top: 20px;
 padding-bottom: 20px;
 color: #fff;
 text-align: center;
 font-size: 30px;

.caption {
  font-family: helvetica;
  font-size: 18px;
  margin-top: 12px;