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.

              <link href=",300, 900,900i" rel="stylesheet">

<div id="nav">
  <ul class="clearfix">
    <li><a href="#section1">Intro</a></li>
    <li><a href="#section2">SKill</a></li>
    <li><a href="#section3">Coding</a></li>
    <li><a href="#section4">Design</a></li>
    <li><a href="#section5">About</a></li>
    <li><a href="#section6">Contact</a></li>

<div id="contants">
  <div id="section1">What good is <strong>love</strong> and peace on earth?</div>
  <div id="section2">When it's <strong>exclusive?</strong></div>
  <div id="section3">Where's the <strong>truth</strong> in the written word?</div>
  <div id="section4">If no one  <strong>reads</strong> it</div>
  <div id="section5">A new <strong>day</strong> dawning</div>
  <div id="section6">Comes without <strong>warning</strong></div>
              body{ position: relative; overflow: hidden;}
.clearfix:before, clearfix:after{
  display: block; content:''; line-height:0;
.claerfix:after {clear:both; text-align:center;  }

/* nav */
#nav { width: 100%; position: fixed; text-align:center;  }
#nav h2 { background-color: rgba(255,255,255, 0.5); font-size: 30px; color:#000; padding: 10px 0;  }
#nav ul li a {
  padding: 5px 0; display: block;
  color:#fff; text-decoration:none;}
#nav ul li:nth-child(odd){ 
background-color: rgba(255,255,255,0.1);
#nav ul li.on {
  background-color: rgba(0,0,0,0.5);

/* contants */
#contants {text-align: center; color:#fff; font-size: 60px;}
#contants>div {height: 100vh;line-height: 100vh; font-family: 'Lato', sans-serif; font-weight:100;}
#contants strong {font-weight:900i; font-style:Italic; font-size:70px;}
#section1 {background: radial-gradient(ellipse farthest-corner at center top, #f8bfa4 0%, #f33b4e 100%);}
#section2 {background: radial-gradient(ellipse farthest-corner at left top, #FDA3BD 0%, #D5D9E5 100%)}
#section3 {background: radial-gradient(ellipse farthest-corner at right top, #00A8C5 0%, #FFFF7E 100%)}
#section4 {background: radial-gradient(ellipse farthest-corner at bottom left, #E3ADD1 0%, #B4ADE2 100%)}
#section5 {background: radial-gradient(ellipse farthest-corner at bottom center, #1D7FBF 0%, #DEC2CE 100%)}
#section6 {background: radial-gradient(ellipse farthest-corner at bottom right, #363975 0%, #688FB3 100%);}

              var contents = $ ("#contants > div");
var body=$("body");

  var wWidth=$(window).width();
  var wHeight=$(window).height();
  var wPosX =(wWidth/2)-($("#nav").width()/2);
  var wPosY =wHeight-$("#nav h2").innerHeight();

    $("#nav").css({left:wPosX, top:wPosY});

  $(this).stop().animate({top:wHeight- $("#nav").innerHeight()},300);
$("#nav ul li").mouseover(function(){
🕑 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.