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

              
                
    <link href="https://fonts.googleapis.com/css?family=Playfair+Display+SC|Roboto|Roboto+Slab" rel="stylesheet">

    <nav class="bottom-nav">
        <center>
            <a href="#" class="prev">prev</a>
            <a href="#1" class="fa fa-chevron-up"></a>
            <a href="#" class="next">next</a>
        </center>
    </nav>

    <nav id="slide-nav">
    </nav>

    <nav id="bigNav">
    </nav>

    <main>
        <div id="1" class="content">
              <h1>JQuery Slideshow</h1>
              use →, ↓ , and space bar to go to next slide<br>
              use ← and ↑ to go to previous slide<br>
          <p>Created by <a href="http://hellolittlered.org">Hello Little Red</a></p>
        </div>


        <div id="2" class="content">
            
                    <h1>Perpustakaan Digital Budaya Indonesia</h1>
                    Tingkat diversitas kebudayaan Indonesia adalah yang tertinggi di dunia. Sayangnya, hal ini juga menjadikannya sangat rentan untuk mengalami kepunahan seandainya tidak ada mekanisme yang dapat mendukung dalam konservasi. Belum lagi masalah klaim budaya yang merupakan akibat dari minimnya proteksi terhadap elemen kebudayaan. Proteksi dan konservasi tidak dapat dilaksanakan seandainya tidak ada informasi atau data tentang budaya.

                    <a href="http://budaya-indonesia.org" class="main-link">
                        Ke Budaya Indonesia
                        <span class="fa fa-chevron-right"></span>
                    </a>
        </div>


        <div id="3" class="content">
        
                <h1>Sobat Budaya</h1>
                <p>Mencintai Indonesia, Menginspirasi dunia.</p>
                Yayasan Sobat Budaya Berdiri pada hari Rabu, 02 Juli 2014 di Kota Bandung. Yayasan ini didirikan untuk membangun dan mengembangkan Perpustakaan Digital Budaya Indonesia (PDBI), serta mendorong upaya pelestarian, penelitian, promosi, pendidikan, partisipasi dan apresiasi masyarakat kepada pengembangan budaya Indonesia. 

                <a href="http://sobat-budaya.or.id" class="main-link">
                    Ke Sobat Budaya
                    <span class="fa fa-chevron-right"></span>
                </a>
        </div>



        <div id="4" class="content">
            
                <h1>Info Budaya</h1>
                <p>Merayakan keberagaman budaya Indonesia!</p>
                Portal informasi, kegiatan, dan berita budaya tradisi Indonesia. Merayakan keberagaman budaya Indonesia. Melalui situs ini warga Indonesia dapat memasukan event budaya yang akan terjadi dan juga berkontribusi menambahkan artikel mengenai budaya Indonesia.

                <a href="http://sobat-budaya.or.id" class="main-link">
                    Ke Info Budaya <span class="fa fa-chevron-right"></span>
                </a>
        </div>



        <div id="5" class="content">
         
                <h1>Gerakan Sejuta Data Budaya</h1>
                Gerakan Sejuta Data Budaya (GSDB) adalah sebuah inisiatif untuk mengumpulkan kekayaan data budaya Indonesia yang terdiri dari 14 sektor untuk dibuatkan perpustakaan digital budaya Indonesia. Data yang telah dikumpulkan akan didaftarkan ke World Intellectual Property Organization (WIPO) sebagai bentuk perlindungan budaya dari klaim, serta untuk kepentingan penelitian selanjutnya.
                <a href="http://sobat-budaya.or.id" class="main-link">
                    Ke GSDB <span class="fa fa-chevron-right"></span>
                </a>
        </div>


        <div id="6" class="content">
            
                <h1>Acrobatik</h1>
                <p>acroBatik adalah sebuah brand yang telah mengukuhkan dirinya sebagai produk hasil dari teknologi Batik Fraktal. Penggabungan sains dan seni yang melebur ke dalam sebuah karya fashion.</p>
                <a href="http://sobat-budaya.or.id" class="main-link">
                    Ke Acrobati <span class="fa fa-chevron-right"></span>
                </a>
        </div>


        <div id="7" class="content">
            <div id="social-media" class="right">
                <h1>Akun Media Sosial</h1>
                <br><br>
                <a href="https://twitter.com">
                    <i class="fa fa-twitter"></i>
                    @sobatbudaya
                </a>
                <a href="https://twitter.com">
                    <i class="fa fa-twitter"></i>
                    @kodenusantara
                </a>
                <a href="https://twitter.com">
                    <i class="fa fa-twitter"></i>
                    @infobudaya
                </a>
                <a href="https://twitter.com">
                    <i class="fa fa-instagram"></i>
                    @sobatbudaya
                </a>
                <a href="https://twitter.com">
                    <i class="fa fa-instagram"></i>
                    @kodenusantara
                </a>
                <a href="https://twitter.com">
                    <i class="fa fa-instagram"></i>
                    @infobudaya
                </a>
            </div>
        </div>
</main>
              
            
!

CSS

              
                	html, body {
        background: url(../images/batik.jpg) fixed #444444;
        font-family: 'Roboto', sans-serif;
        margin: 0;
        padding: 0;
        color: #ffffff;
        line-height: 1.6rem;
    }

    a {
        color: #ffffff;
        text-decoration: none;
    }

    h1, h2, h3, h4, h5, h6 {
        font-weight: 300;
        font-family: 'Playfair Display SC', sans-serif;
    }

    main {
        position: fixed;
        top: 2em;
        left: 5em;
        width: calc(100% - 10em);
        height: calc(100% - 4em);
        background: #000000;
        box-shadow: -1px 0px 8px 2px #000000;
        -webkit-box-shadow: -1px 0px 8px 2px #000000;
        -moz-box-shadow: -1px 0px 8px 2px #000000;
        -o-box-shadow: -1px 0px 8px 2px #000000;
        z-index: 1;
        overflow: none;
    }

    main > div {
        display: none;
        opacity: 0;
    }

    .bottom-nav {
        position: fixed;
        width: 100%;
        left: 0;
        bottom: 0;
        z-index: 9;
        line-height: 0rem;
    }

    .bottom-nav a {
        padding: 2.5em;
        display: inline-block;
        z-index: 2;
        text-transform: uppercase;
        font-size: .8em;
        font-weight: bold;
        color: #222222;
        background: #ffffff;
        line-height: 0rem;
        vertical-align: bottom;
    }

    #slide-nav {
        position: fixed;
        left: 0;
        top: 25%;
        width: 3em;
        z-index: 9;
        padding: 1em;
        line-height: .8rem;
    }

    #slide-nav a:not(.menu) {
        display: block;
        border: 2px solid #ffffff;
        color: #ffffff;
        margin: 1em auto;
        border-radius: 100%;
        font-size: .7em;
        width: 1.1em;
        height: 1.1em;
        padding: .5em;
        font-weight: bold;
        position: relative;
    }

    .menu {
        margin-left: -0.9em;
        margin-top: 3em;
        display: block;
        font-size: 1.2em;
        width: 6em;
    }

    .menu span {
        font-size: .8em;
    }

    .hov {
        background: #ffffff;
        color: #222222;
        margin-bottom: 5em!important;
    }

    .hov::after {
        height: 5em;
        width: 2px;
        background: #ffffff;
        content: "";
        position: absolute;
        bottom: -5.2em;
        left: calc(50% - 1px);
    }


    .content {
        width: calc(100% - 10em);
        height: calc(100% - 6em);;
        padding: 2em 6em;
        position: absolute;
    }

    .content > div p {
        font-family: "Georgia", sans-serif;
        font-size: 1.2em;
        font-style: italic;
        line-height: 2.1rem;
    }

    .main-link {
        display: block;
        padding: .5em;
        width: 75%;
        margin: 2em auto;
        border: 2px solid #ffffff;
        color: #ffffff;
    }

    .main-link span {
        float:right;
        margin-top:.3em
    }

    #intro {
        width: 50%;
        margin: 5% 5%;
    }

    .content  h1 {
        font-size: 5em;
        margin-bottom: 0em;
        line-height: 6rem;
    }


    #social-media a {
        background: #222222;
        display: inline-block;
        width: 7em;
        height: 7em;
        padding: 2em;
        color: #ffffff;
        text-align: center;
        margin: 0 1em 1em 0;
        font-size: .8em;
        -webkit-box-shadow: 3px 6px 5px 0px rgba(0,0,0,0.56);
-moz-box-shadow: 3px 6px 5px 0px rgba(0,0,0,0.56);
box-shadow: 3px 6px 5px 0px rgba(0,0,0,0.56);
    }

    #social-media a i {
        font-size: 4em;
        display: block;
        margin-bottom: .3em;
    }

    #bigNav {
        position: fixed;
        top: 0;
        font-size: 1.5em;
        left: 0;
        width: 90%;
        height: 90%;
        background: rgba(0,0,0,.8);
        display: none;
        z-index: 100;
        transition: .6s;
        opacity: 0;
        text-align: center;
        padding: 5%;
    }

    #bigNav a {
        display: block;
        margin-bottom: 1.5em;
    }

    #bigNav:target {
        display: block;
        opacity: 1;
    }

    #bigNav a:hover span {
        border-bottom: 5px solid #ffffff;
    }

@media (min-height: 1024px) {
    body {
        font-size: 1.5em;
        line-height: 2em;
    }

    
    #penari {
        background-size: auto 100%;
        width: 70%;
        right: -5em;
    }
}

@media (max-width: 800px) {
    body {
        font-size: .8em;
        line-height: 1.6em;
    }

    #penari {
        background-size: auto 100%;
        width: 70%;
        right: -5em;
    }

    .content  h1 {
        font-size: 3em;
        margin-bottom: 0em;
        line-height: 3.3rem;
    }
}

@media (max-width: 425px) {


    main {
        top:2em;
        left: 2em;
        width: calc(100% - 4em);
        height: calc(100% - 4em);
        overflow: auto;
    }

    .content {
        padding: 3em;
        width: calc(100% - 6em)
    }

    #pdbi {
        width: 70%;
    }

    .content h1 {
        font-size: 2em;
    }

    #penari {
        display: none;
    }

    #intro {
        margin: 1em;
        width: 100%;
    }

    #social {
        width: auto;
        top:3em;
        left: 3em;
        text-align: left;
    }

    #social a {
        display:inline-block;
        margin: 0 .5em 0 0;
    }

    #lang-switch {
        top: 3em;
        right: 3em;
    }

    #slide-nav a:not(.menu) {
        display: none;
    }

    #content-one, #content-two {
        float: none;
        width: 100%;
    }

    #content-one {
        margin: 2em auto;
        height: auto;
    }



    #content-one img {
        width: 100%;
        margin: 0 auto;

    }

    #content-two {
        margin: 0;
    }

    #social-media {
        padding: .5em;
        width: 3em;
        height: 3em;
    }

    .bottom-nav a {
        padding: 2em;
    }

    #slide-nav {
        top: 40%;
    }

    #bigNav {
        padding: 3em;
        width: calc(100% - 6em);
        height: calc(100% - 6em);
    }

    #bigNav a {
        font-size: 1em;
        margin-bottom: 1em;
    }

}
              
            
!

JS

              
                jQuery(document).scroll(function(event){


  var y = $(this).scrollTop();
  if (y > 100) {
    $('#mobile-menu').fadeIn();
  } else {
    $('#mobile-menu').fadeOut();
  }

});

jQuery(document).ready(function(event){
  var newloc;
  var val = 1;

  var amount = $('.content').length;
  var i;
  for (i = 1; i <= amount; i++) {
    var append = "<a href='#" + i + "'>0" + i + "</a>";
    var title = $("#" + i + " h1").text();
    var append2 = "<a href='#" + i + "'><span>" + title + "</span></a>";
    $("#slide-nav").append(append);
    $("#bigNav").append(append2);
  }

  $("#slide-nav").append('<a href="#bigNav" class="menu"><span class="fa fa-bars"></span> slides list</a>');
  $("#bigNav").append('<a href="#' + val + '"><span>Tutup Menu</span></a>');

  
  if(window.location.hash) {
    $(window.location.hash).css("display", "block");
    $(window.location.hash).animate({ opacity: "1" }, 500, "linear");
    $(window.location.hash + " .left").animate({ marginLeft: "0px" }, 500, "linear");
    $(window.location.hash + " .right").animate({ marginRight: "0px" }, 500, "linear");
    $("#slide-nav a[href='" + window.location.hash + "']").addClass("hov");
  } else {
    $("#1").css("display", "block");
    $("#1").animate({ opacity: "1" }, 500, "linear");
    $("#1 .left").animate({ marginLeft: "0px" }, 500, "linear");
    $("#1 .right").animate({ marginRight: "0px" }, 500, "linear");
    $("#slide-nav a[href='#1']").addClass("hov");
  }

  $(".prev").attr("href","#" + amount);
  $(".next").attr("href","#2");

  $(document).keydown(function(e) {
    if (e.keyCode == '32' || e.keyCode == '39' || e.keyCode == '40') {
      $('.next').trigger('click');
    }
    else if (e.keyCode == '37' || e.keyCode == '38') {
      $('.prev').trigger('click');
    }
  });


  $('html').on('click', 'a[href^="#"]', function(event){

    var data_id = $(this).attr('href');
    val = parseInt(data_id.replace('#', ''));
    var prev = parseInt(val - 1);
    var next = parseInt(val + 1);

    if (data_id != "#bigNav") {

      $("#slide-nav a").css("background", "transparent");
      $("#slide-nav a").removeClass("hov");


      if(val != amount)  $("#slide-nav a[href='#" + val + "']").addClass("hov");
      else if(val == amount)  $("#slide-nav a[href='#" + prev + "']").addClass("hov");

      if(prev <= 0) prev = amount;
      if(next > amount) next = 1;

      $(".prev").attr("href","#" + prev);
      $(".next").attr("href","#" + next);

      $(".left").animate({ marginLeft: "-100px" }, 500, "linear");
      $(".right").animate({ marginRight: "-100px" }, 500, "linear");
      $( "main > div" ).animate( {opacity: "0" }, 500, "linear", function() {
        $( "main > div" ).css("display", "none");
        $(data_id).css("display", "block");
        $(data_id).animate({ opacity: "1" }, 500);
        $(data_id + " .left").animate({ marginLeft: "0" }, 500, "linear");
        $(data_id + " .right").animate({ marginRight: "0" }, 500, "linear");
      });
    } 
  });


  $('html').on('click', '.close', function(event){
    $( "#bigNav" ).animate({opacity: 0}, 500, function() {
      $( "#bigNav" ).css("display", "none");
    } );
  });



});
              
            
!
999px

Console