Pen Settings

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

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation


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.

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.

      each digit, i in [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
        .digit #{digit}
      each digit, i in [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
        .digit #{digit}
      each digit, i in [0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
        .digit #{digit}
              $font: 5rem
$w: 1 * $font
$h: 1.4 * $font
$pd: 2.5rem

@keyframes shuffle
    transform: translate3d(0, 0, 0)
    transform: translate3d(0, #{-$h * 10}, 0)
  color: #fff
  background: MediumAquaMarine
  font-size: 100%

  position: fixed
  top: 50%
  left: 50%
  margin-top: - ($h + $pd * 2) / 2
  margin-left: - ($w * 3 + $pd * 2) / 2
  padding: $pd
  border-radius: 10px
  background: linear-gradient(to bottom, #666, #444)
  box-shadow: 0 2px 10px rgba(#000, 0.4)
    content: ""
    position: absolute
    top: 17%
    left: 10%
    height: 66%
    width: 80%
    border-radius: 10px
    box-shadow: 0 0 5px rgba(#000, 0.1), 0 -1px 0 1px rgba(#fff, 0.1)
    background: linear-gradient(to bottom, #444, #666)
  position: relative
  display: flex
  width: $w * 3
  height: $h
  overflow: hidden
  background: #333
  box-shadow: inset 0 0px 8px #000, 0 1px 0px  1px rgba(#fff, 0.4)
  border-radius: 10px
  text-align: center
  color: #fff
  text-shadow: -2px -2px 0 #aaa
  font: #{$font}/1.4 monaco, monospace

  flex-grow: 1

  display: none
  ~ .wrapper
    > .board
      animation-play-state: paused !important
      @for $i from 1 through 3
          animation: shuffle #{1.5s - $i * 0.2s} steps(10) infinite
    ~ .handle
        transform: rotateX(180deg)
        transform: translateY(140px)
    ~ .wrapper > .board
      animation-play-state: running !important

  position: absolute
  right: 0
  top: 50%
  $transition: transform 0.2s ease
    content: ""
    position: absolute
    bottom: 0
    width: 20px
    height: 60px
    background: linear-gradient(to right, #bbb 0%, #eee 30%, #bbb 100%)
    border-radius: 0 0 10px 0
    transform-origin: bottom center
    transition: $transition
    content: ""
    position: absolute
    bottom: 55px
    left: -5px
    width: 30px
    height: 30px
    border-radius: 50%
    background: radial-gradient(circle farthest-corner at 25% 25%, LightSalmon 0%, tomato 100%)
    transform-origin: bottom center
    transition: $transition
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.