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 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

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.

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

              
                <!-- swap the .loading class with .loaded using JavaScript-->
<div class="loading" id="load-state">
  <!-- Full animation/game: https://codepen.io/rachelnabors/pen/lqswg-->

  <div id="loader">
    <div class="ir dolly"></div>
  </div>

</div>
  
  
  
  
  
 <!--ignore--> 
<div class="credits">
  <a href="http://xamag.deviantart.com/" class="xamag ir" target="blank">
    art, idea &amp; story by Xamag
  </a>
  <a class="logo ir" href="http://xamag.deviantart.com/gallery/41762760" target="blank">
    The Black Brick Road of O.Z. #11 (read the rest)
  </a>
  <a href="http://rachelnabors.com/" class="rtg ir" target="blank">
    CSS, HTML &amp; JavaScript by Rachel </a><del>the Great</del> Nabors
</div>
              
            
!

CSS

              
                /* A cute little animation will happen when #load-state gets the .loaded class. Nothing needed here. 

================================
Necessary Code Below-- plz ignore */

body { 
  background: #000; 
}

#loader {
  background: url(//stash.rachelnabors.com/oz/loading/bg_loading.jpg?3) 0 0 no-repeat;
  animation: down-the-hole .5s steps(2) infinite;
}

@keyframes down-the-hole {
  0% {background-position: 0 -450px;}
  100% {background-position: 0 -1350px;}
}

#loader .dolly { transition: opacity .01ms linear -.01ms;
opacity: 0;}

.loaded #loader .dolly {
  background: url(//stash.rachelnabors.com/oz/loading/dolly.png) 0 0 no-repeat;
  opacity: 1;
  top: -151px; left: 213px;
  width: 218px; height: 463px;
  animation: dolly-fall 2.5s ease-in 1;
  animation-fill-mode: forwards;
}

.loaded #loader { 
  background: url(//stash.rachelnabors.com/oz/loading/bg_loading.jpg?3) 0 0 no-repeat;
  animation: none;
}

@keyframes dolly-fall {
  0% {top: -151px;}
  35% { top: -250px; }
  100% {top: 1500px;}
}

#loader {
  width: 650px; height: 450px;
  position: absolute;
  top: 50%; left: 50%;
  margin-top: -225px; margin-left: -325px;
  overflow: hidden;
}

/* Image replacement */
.ir {
  text-indent: 100%;
  white-space: nowrap;
  overflow: hidden;
  position: absolute;
}
.ir br { display: none; }

/* Thank you for reading :) */
.credits {
  background: url("//stash.rachelnabors.com/oz/sprite_frame.png");
  left: 50%; top: 50%; 
  margin-left: -325px; margin-top: 235px;
  position: absolute;
  width: 650px; height: 214px;
}

.xamag {
  background: url("//stash.rachelnabors.com/oz/sprite_frame.png?2");
  position: absolute; left: 0; top: 0;
  width: 217px; height: 155px;
}

.logo {
  background: url("//stash.rachelnabors.com/oz/sprite_frame.png?2") -244px 0;
  position: absolute; left: 244px; top: 0;
  width: 168px; height: 214px;
}

.rtg {
  background: url("//stash.rachelnabors.com/oz/sprite_frame.png?2") -412px 0;
  position: absolute; left: 412px; top: 0;
  width: 238px; height: 179px;
}
              
            
!

JS

              
                // Use jQuery to...
// Detect full screen paint with $(window).load(function(){});

  // When window is loaded, swap #load-state's .loading with .loaded

//Bonus points: wrap the class swap in a setTimeout(function(){}, 3500); to make sure people can see it w/ assets cached. For funnzies.
              
            
!
999px

Console