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

              
                <div class="container">
  <div class="css-gradients orangetopink"></div>
  <div class="css-gradients tealtopink"></div>
</div>
              
            
!

CSS

              
                @import compass

$bg: #111
$teal: #72ccbf
$brightorange: #e36103
$pink: #f0accf

$width: 200px
$height: 200px
$threewidth: 3 * $width

body
    background: $bg
.container
    position: relative
    overflow: hidden
    height: 100%
    width: 100%
    margin: 3em auto
    max-width: $width
    min-height: $height
    background: $bg
.css-gradients
    position: absolute
    top: 0
    left: 0
    width: 100%
    height: 100%
    +border-radius(50%)
    +backface-visibility(hidden)
    &.orangetopink
        +background-image(radial-gradient(center $threewidth, rgba($brightorange, .9) $width/10, rgba($pink, .6) $threewidth/4))
        -webkit-animation: rotate-neg-360 3s linear infinite, reverse-pulse-opacity 3s linear infinite
        -moz-animation: rotate-neg-360 3s linear infinite, reverse-pulse-opacity 3s linear infinite
        -o-animation: rotate-neg-360 3s linear infinite, reverse-pulse-opacity 3s linear infinite
        animation: rotate-neg-360 3s linear infinite, reverse-pulse-opacity 3s linear infinite

    &.tealtopink
        +background-image(linear-gradient(top left, rgba($teal, .8), rgba($pink, .3)))
        -webkit-animation: rotate-360 3s linear infinite, pulse-opacity 3s linear infinite
        -moz-animation: rotate-360 3s linear infinite, pulse-opacity 3s linear infinite
        -o-animation: rotate-360 3s linear infinite, pulse-opacity 3s linear infinite
        animation: rotate-360 3s linear infinite, pulse-opacity 3s linear infinite
@-webkit-keyframes pulse-opacity
    0%
        +opacity(.2)
    50%
        +opacity(.8)
    100%
        +opacity(.2)
@-moz-keyframes pulse-opacity
    0%
        +opacity(.2)
    50%
        +opacity(.8)
    100%
        +opacity(.2)
@-o-keyframes pulse-opacity
    0%
        +opacity(.2)
    50%
        +opacity(.8)
    100%
        +opacity(.2)
@keyframes pulse-opacity
    0%
        +opacity(.2)
    50%
        +opacity(.8)
    100%
        +opacity(.2)

@-webkit-keyframes reverse-pulse-opacity
    0%
        +opacity(.8)
    50%
        +opacity(.2)
    100%
        +opacity(.8)
@-moz-keyframes reverse-pulse-opacity
    0%
        +opacity(.8)
    50%
        +opacity(.2)
    100%
        +opacity(.8)
@-o-keyframes reverse-pulse-opacity
    0%
        +opacity(.8)
    50%
        +opacity(.2)
    100%
        +opacity(.8)
@keyframes reverse-pulse-opacity
    0%
        +opacity(.8)
    50%
        +opacity(.2)
    100%
        +opacity(.8)       



@-webkit-keyframes rotate-360
    from
        +transform-origin(center center)
        +rotate(0deg)
    to
        +transform-origin(center center)
        +rotate(360deg)
@-moz-keyframes rotate-360
    from
        +transform-origin(center center)
        +rotate(0deg)
    to
        +transform-origin(center center)
        +rotate(360deg)
@-o-keyframes rotate-360
    from
        +transform-origin(center center)
        +rotate(0deg)
    to
        +transform-origin(center center)
        +rotate(360deg)
@keyframes rotate-360
    from
        +transform-origin(center center)
        +rotate(0deg)
    to
        +transform-origin(center center)
        +rotate(360deg)


@-webkit-keyframes rotate-neg-360
    from
        +transform-origin(center top)
        +rotate(0deg)
    to
        +transform-origin(center top)
        +rotate(-360deg)
@-moz-keyframes rotate-neg-360
    from
        +transform-origin(center top)
        +rotate(0deg)
    to
        +transform-origin(center top)
        +rotate(-360deg)
@-o-keyframes rotate-neg-360
    from
        +transform-origin(center top)
        +rotate(0deg)
    to
        +transform-origin(center top)
        +rotate(-360deg)
@keyframes rotate-neg-360
    from
        +transform-origin(center top)
        +rotate(0deg)
    to
        +transform-origin(center top)
        +rotate(-360deg)
              
            
!

JS

              
                # Naw naw
              
            
!
999px

Console