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.

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

            
              #loading
  .outer-shadow
  .inner-shadow
  .timer
    .dot
      %span
    #left.hold
      .pie
    #right.hold
      .pie
            
          
!

CSS

            
              @import compass

// VALUE /////////////////

$bg: #dde6f0

// loading color -------------
$lc: #f50

$fix: 100%

// shadow ---------------------
$bs: 0 1px 0 rgba(0, 0, 0, .2)

// circle diameter ------------
$w: 100px

// highlight thickness --------
$low: 10px

// timer -----------------------
$tm: 8s

//  mixin- --------------------
=keyframes($name)
  @-webkit-keyframes #{$name}
    @content


// LOADING /////////////////

html
  background-color: $bg

#loading
  width: $w
  height: $w
  margin: 30px auto
  position: relative


.outer-shadow
  z-index: 6
  position: absolute
  width: $fix
  height: $fix
  border-radius: $fix
  box-shadow: inset $bs


.inner-shadow
  @extend .outer-shadow
  top: 50%
  left: 50%
  width: $w - ($low*2)
  height: $w - ($low*2)
  margin-left: -($w - ($low*2))/2
  margin-top: -($w - ($low*2))/2
  border-radius: $fix
  background-color: $bg
  box-shadow: $bs


#timer
  @extend .outer-shadow
  z-index: 1
  box-shadow: none


.hold
  position: absolute
  width: $fix
  height: $fix
  clip: rect(0px, $w, $w, $w/2)
  -webkit-border-radius: $fix
  background-color: #fff


.pie, .dot span
  background-color: $lc

.pie
  position: absolute
  width: $fix
  height: $fix
  -webkit-border-radius: $fix
  clip: rect(0px, $w/2, $w, 0px)


#left .pie
  z-index: 1
  -webkit-animation: left $tm/2 linear both

+keyframes(left)
  0%
    -webkit-transform: rotate(0deg)
  100%
    -webkit-transform: rotate(180deg)


#right
  z-index: 3
  -webkit-transform: rotate(180deg)


#right .pie
  -webkit-animation: right $tm/2 linear both
  -webkit-animation-delay: $tm/2


+keyframes(right)
  0%
    -webkit-transform: rotate(0deg)
  100%
    -webkit-transform: rotate(180deg)

.dot
  z-index: 2
  position: absolute
  left: 50%
  top: 50%
  width: 50%
  height: $low
  margin-top: -($low/2)
  -webkit-animation: dot $tm linear both
  -webkit-transform-origin: 0% 50%


.dot span
  position: absolute
  right: 0
  width: $low
  height: $low
  border-radius: $fix


+keyframes(dot)
  0%
    -webkit-transform: rotate(-90deg)
  50%
    -webkit-transform: rotate(90deg)
    z-index: 4
  100%
    -webkit-transform: rotate(270deg)
    z-index: 4
            
          
!

JS

            
              
            
          
!
999px

Console