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

              
                <link href='https://fonts.googleapis.com/css?family=Ubuntu+Mono:400,700' rel='stylesheet' type='text/css'>
<section class="flight-tracker">
  <header>
    <h1 class="aa-logo">American Airlines</h1>
    <span class="flight-number">AA289</span>
  </header>
  <div class="flight-details">
    <table>
      <thead>
        <tr>
          <th>Date</th>
          <th>Status</th>
          <th>Term</th>
          <th>Gate</th>
        </tr>
      </thead>
      <tbody>
        <tr>
          <td>3-14-2014</td>
          <td>Departed</td>
          <td>T3</td>
          <td>K12</td>
        </tr>
      </tbody>
    </table>
    <div class="flight-duration">
      <span class="flight-start">11:35</span>
      <span class="flight-end">15:05</span>
    </div>
  </div>
  <footer>
    <span class="flight-from"><strong>ORD</strong> <span class="city">Chicago</span></span>
    <span class="flight-to"><strong>PVG</strong> <span class="city">Shanghai</span></span>
    <span class="flight-progress"></span>
    <span class="airplaine">✈</span>
  </footer>
</section>
              
            
!

CSS

              
                @import "bourbon";

html, body {
  height: 100%;
  @include linear-gradient(#0d1944, #49aae7);
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

.flight-tracker {
  @include position(absolute, 50% null null 50%);
  @include transform(translate(-50%, -50%));
  @include size(290px auto);
  font-family: 'Ubuntu Mono';
  font-weight: 400;
  color: #4e4e4e;
  border-radius: 32px / 28px;
  @include perspective(320px);
  @include transform-style(preserve-3d);
  @include transform-origin(50% 48px);

  header {
    background: white;
    border-radius: 32px 32px 0 0 / 28px 28px 0 0;
    padding: 7px 15px;
    @include transform-origin(50% 50%);
    @include transform(translate3d(0px, 28px, 0px) rotateX(0deg));
    @include transform-style(preserve-3d);
    @include animation(fold-header 12s $ease-out-quart infinite);

    h1.aa-logo {
      display: block;
      margin: 0;
      @include hide-text;
      @include size(130px 20px);
      background-repeat: no-repeat;
      background-image: url(data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAABkAAD/4QMsaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjUtYzAyMSA3OS4xNTQ5MTEsIDIwMTMvMTAvMjktMTE6NDc6MTYgICAgICAgICI+IDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy53My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+IDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiIHhtbG5zOnhtcD0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bXA6Q3JlYXRvclRvb2w9IkFkb2JlIFBob3Rvc2hvcCBDQyAoTWFjaW50b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CQjwwFyzPaRY0tVwUUfu0JnXFeZWOpcgg2l2nMcY8qmTFGF7iVVuiYqHg9S75ZfqFSU1ukaPowCMZIhXiiWpZvmE+66+4vxRrdld6DvPpYyssMZ1qMBs7GgAXJ/yMH+x+4XVpVpLkudk/ct+3fI/b93s7p3SJJ8z27znPk6ZlyK5/LVXYuQ75fVYyhsiI2VhZOxrGyctm2fbmVeb6pTTSmmmmlNNPLT+GmnhppsUUrd3T2dNPHTd008/Hy8PPYoquxRWCn9N5b8p5HlOOZ16fy/LczzAnOfdvdcfmt/i/S4mu9467SVXXeoCcKztoqaag+ickDwuldO5y3gcPlOS6h1Cu5wd33HOdV8t32+Y+vtbzLxVKr5U0RKddq1arfZ3vo7+7XTy3t3Wmv8APd12KKVd3W3Xd3vHd1018vHd18fLz02KKu2KKWxRS2KKZf070f8AwvQPD+x6P95pp+C++fa/W2t5ruN341AtTRLaetq1Na8+6p8rfyG5A/OFznwY9K+/6Dynrn1nzQPoL4ac37HxC9U8v03X3O/vcz/Scxtxvu78n+38j88/6Fuu11y+SxdL7kTh4+Va7k9gf1C/VnpH6Yr91c8ot3K5Np9R6i3X0/Ku5nFEs+pZXCL2pfmY/wDRCD/ko9deqvVYXqr1N0bpny1+oET4rfHDpP6e9I9E4OvC9713p3TPzTlduguzed9zQ/b/ADedd5lRORcL+ZwtTx1uts+pbX1N/cD+Xfo11T9V/R/lPI+lbfd+Zct/pPRXfU599ycORzuf/T8yvob/APZf/TP3l+H/AGL/AMg+y29Xf0P8234/6V8Qf67+Sv/Z);
    }

    .flight-number {
      @include position(absolute, 7px 15px null null);
      font-size: 18px;
    }
  }

  .flight-details {
    margin: -1px 0 0;

    table {
      border: 0 none;
      width: 100%;
      thead {
        background: #bfbfbf;
        @include backface-visibility(hidden);
        @include transform(translate3d(0px, 28px, 0px) rotateX(-90deg));
        @include transform-origin(50% 0%);
        @include animation(fold-top 12s $ease-out-quart infinite);
        th {
          text-align: left;
          font-size: 11px;
          height: 28px;
          font-weight: 400;
          color: #289dd7;
          vertical-align: bottom;
          padding: 0 15px;

          &:last-child {
            text-align: right;
          }
        }
      }

      tbody {
        background: #ebebeb;
        @include backface-visibility(hidden);
        @include transform(translate3d(0px, -28px, 0px) rotateX(90deg));
        @include transform-origin(50% 100%);
        @include animation(fold-bottom 12s $ease-out-quart infinite);
        td {
          font-size: 11px;
          height: 28px;
          vertical-align: top;
          padding: 0 15px;

          &:last-child {
            text-align: right;
          }
        }
      }
    }
  }

  .flight-duration {
    padding: 7px 15px;
    background: white;
    @include transform-origin(50% 50%);
    @include transform(translate3d(0px, -28px, 0px) rotateX(0deg));
    @include transform-style(preserve-3d);
    @include animation(fold-footer 12s $ease-out-quart infinite);

    .flight-end {
      float: right;
    }
  }

  footer {
    @include linear-gradient(#289dd7, #0e8acf);
    border-radius: 0 0 32px 32px / 0 0 28px 28px;
    height: 53px;
    color: white;
    font-size: 11px;
    text-shadow: 1px 1px 2px rgba(#0d1944, .4);
    box-shadow: 0 10px 24px rgba(#0d1944, .7);
    overflow: hidden;
    @include transform(translate3d(0px, -28px, 0px) rotateX(0deg));
    @include transform-style(preserve-3d);
    @include animation(fold-footer 12s $ease-out-quart infinite);

    strong {
      display: block;
      font-weight: 400;
      font-size: 24px;
    }

    .flight-from {
      @include position(absolute, null null 12px 15px);
    }

    .flight-to {
      text-align: right;
      @include position(absolute, null 15px 12px null);
    }

    .flight-progress {
      @include position(absolute, 50% null null 50%);
      @include transform(translate3d(-50%, -50%, 0));
      @include size(100px 2px);
      background: #015683;
      border-radius: 1px;
      box-shadow: 0 0 2px rgba(#0d1944, .4);
      @include animation(progress-bar 12s $ease-out-quart infinite);

      &::before {
        content: '\20';
        display: block;
        @include size(0% 2px);
        background: white;
        border-radius: 1px;
        box-shadow: inset 0 0 1px rgba(#0d1944, .4);
        @include animation(progress 12s linear infinite);
      }

      &::after {
        content: '\20';
        display: block;
        @include position(absolute, 0px null null 0px);
        @include size(2px);
        background: white;
        border-radius: 1px;
        box-shadow: 0 0 1px 1px white;
        @include animation(progress-track 12s linear infinite);
      }
    }
  }

  .airplaine {
    @include position(absolute, 50% null null 50%);
    @include transform(translate3d(-50%, -50%, 0));
    font-size: 48px;
    text-shadow: 1px 1px 2px rgba(#0d1944, .4);
    @include animation(airplaine 12s infinite);
  }
}

@include keyframes(fold-header) {
  0%, 19% {
    @include transform(translate3d(0px, 28px, 0px) rotateX(0deg));
  }
  23%, 42% {
    @include transform(translate3d(0px, 0px, 0px) rotateX(0deg));
  }
  45%, 100% {
    @include transform(translate3d(0px, 28px, 0px) rotateX(0deg));
  }
}

@include keyframes(fold-top) {
  0%, 19% {
    background: #bfbfbf;
    @include transform(translate3d(0px, 28px, 0px) rotateX(-90deg));
  }
  23%, 42% {
    background: white;
    @include transform(translate3d(0px, 0px, 0px) rotateX(0deg));
  }
  45%, 100% {
    background: #bfbfbf;
    @include transform(translate3d(0px, 28px, 0px) rotateX(-90deg));
  }
}

@include keyframes(fold-bottom) {
  0%, 19% {
    background: #ebebeb;
    @include transform(translate3d(0px, -28px, 0px) rotateX(90deg));
  }
  23%, 42% {
    background: white;
    @include transform(translate3d(0px, 0px, 0px) rotateX(0deg));
  }
  45%, 100% {
    background: #ebebeb;
    @include transform(translate3d(0px, -28px, 0px) rotateX(90deg));
  }
}

@include keyframes(fold-footer) {
  0%, 19% {
    @include transform(translate3d(0px, -28px, 0px) rotateX(0deg));
  }
  24%, 42% {
    @include transform(translate3d(0px, 0px, 0px) rotateX(0deg));
  }
  45%, 100% {
    @include transform(translate3d(0px, -28px, 0px) rotateX(0deg));
  }
}

@include keyframes(progress-bar) {
  0%, 7% {
    opacity: 0;
  }
  10%, 42% {
    opacity: 1;
  }
  45%, 100% {
    opacity: 0;
  }
}

@include keyframes(progress) {
  0%, 10% {
    width: 0%;
  }
  40%, 100% {
    width: 100%;
  }
}

@include keyframes(progress-track) {
  0%, 10% {
    left: 0%;
  }
  40%, 100% {
    left: 100%;
  }
}

@include keyframes(airplaine) {
  0%, 50% {
    left: -20%;
    text-shadow: 20px 20px 8px rgba(#0d1944, .4);
  }
  65%, 85% {
    left: 50%;
    text-shadow: 1px 1px 2px rgba(#0d1944, .4);
  }
  100% {
    left: 120%;
    text-shadow: 20px 20px 8px rgba(#0d1944, .4);
  }
}
              
            
!

JS

              
                // IN PROGRESS - Inspired from http://dribbble.com/shots/1475032-FlightTracker by Chuan²
              
            
!
999px

Console