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

              
                <section>
  <div class="inner" id="image1"></div>
  <div class="inner" id="image2"></div>
  <div id="title">
    <h1 contenteditable="true">Docu Lab Title can be edited</h1>
    <h2 contenteditable="true">20 juni 2017</h2>
  </div>
  <div class="alloy-logo">
    <svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 150 150" style="enable-background:new 0 0 150 150;" xml:space="preserve">
<style type="text/css">
	.st0{fill:none;stroke:#FED82F;stroke-width:4;}
	.st1{fill:#FFFFFF;}
	.st2{fill:#FED82F;}
</style>
<g id="text">
	<path d="M95.2,129.6l-1.8-10.4h-9.5l-1.7,10.4h-6.5l8-45.1h9.4l8.6,45.1H95.2z M84.7,113.9h7.8l-4.1-23.8L84.7,113.9z"/>
	<path d="M105.8,84.5l14.5,0c4.5,0,6.8,2.1,6.8,6.3l0,11.4c0,2.5-1,4-2.9,4.5c1.9,0.5,2.9,1.9,2.9,4.2l0,12.3c0,4.2-2.2,6.3-6.8,6.3
		l-14.6,0V84.5z M120.6,102l0-10.3c0-0.9-0.1-1.4-0.4-1.7c-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,0.1,1.7,0.4c0.3,0.3,0.4,0.8,0.4,1.7v11.1h6.6V26.7C99.7,22.5,97.4,20.4,92.9,20.4z"/>
	<path d="M127.6,59.2V20.4H121v37.7c0,0.9-0.1,1.4-0.4,1.7c-0.3,0.3-0.9,0.4-1.8,0.4h-4.1c-0.9,0-1.4-0.1-1.7-0.4
		c-0.3-0.3-0.4-0.8-0.4-1.7V20.4h-6.6v38.7c0,4.2,2.3,6.3,6.8,6.3h8C125.3,65.5,127.6,63.4,127.6,59.2z"/>
	<path d="M61.1,124.3h10.7v5.3H54.3V84.5h6.8V124.3z"/>
</g>
<g id="eye-base">
	<path class="st0" d="M75,51.1c-28.8,0-52.2,20.5-52.2,23.9c0,3.4,23.4,23.9,52.2,23.9s52.2-20.6,52.2-23.9
		C127.2,71.7,103.8,51.1,75,51.1L75,51.1z"/>
	<path class="st1" d="M75,51.1c-28.8,0-52.2,20.5-52.2,23.9c0,3.4,23.4,23.9,52.2,23.9s52.2-20.6,52.2-23.9
		C127.2,71.7,103.8,51.1,75,51.1L75,51.1z"/>
</g>
<g id="pupil">
	<path class="st2" d="M80.8,59.4c0,0-1.4-0.2-5.6-0.2c-4.3,0-5.6,0.2-5.6,0.2c-6.3,0-9.5,3-9.5,8.9c0,0-0.2,3.7-0.2,5.9
		c0,2.2,0.2,5.9,0.2,5.9c0,5.9,3.2,8.9,9.5,8.9c0,0,2.7,0.2,5.6,0.2c2.8,0,5.6-0.2,5.6-0.2c6.2,0,9.4-3,9.4-8.9
		c0,0,0.1-3.4,0.1-5.9c0-2.5-0.1-5.9-0.1-5.9C90.2,62.4,87.1,59.4,80.8,59.4z"/>
	<path d="M79.7,62.4c0,0-1.1-0.1-4.5-0.1s-4.4,0.1-4.4,0.1c-5.1,0-7.6,2.4-7.6,7.1c0,0-0.1,2.9-0.1,4.7c0,1.8,0.1,4.7,0.1,4.7
		c0,4.7,2.5,7.1,7.6,7.1c0,0,2.2,0.1,4.4,0.1s4.5-0.1,4.5-0.1c5,0,7.5-2.4,7.5-7.1c0,0,0.1-2.7,0.1-4.7c0-2-0.1-4.7-0.1-4.7
		C87.2,64.7,84.7,62.4,79.7,62.4z"/>
	<path class="st1" d="M67.5,59.3h-3.7c-2.1,0-3.1,1.1-3.1,3.3V66c0,2.2,1,3.3,3.1,3.3h3.7c2.1,0,3.1-1.1,3.1-3.3v-3.4
		C70.6,60.4,69.6,59.3,67.5,59.3z"/>
</g>
<g id="eye">
	<path d="M75,56.1c22.2,0,40.3,13.5,45.6,18.9c-5.4,5.4-23.4,18.9-45.6,18.9c-22.5,0-40.4-13.5-45.7-18.9
		C34.6,69.6,52.5,56.1,75,56.1 M75,51.1c-28.8,0-52.2,20.5-52.2,23.9c0,3.4,23.4,23.9,52.2,23.9s52.2-20.6,52.2-23.9
		C127.2,71.7,103.8,51.1,75,51.1L75,51.1z"/>
</g>
</svg>

  </div>
  <svg id="pletterij" xmlns="http://www.w3.org/2000/svg" width="354" height="95" viewBox="0 0 354 95">
    <g fill="none" fill-rule="evenodd">
      <path fill="#fff" d="M285.5106,0.0004 L285.5106,7.4304 L295.4946,7.4304 L295.4946,21.7104 L285.5106,21.7104 L285.5106,29.1394 L295.4946,39.1224 L295.4946,49.4644 L302.9236,49.4644 L302.9236,39.7974 L302.9236,36.5714 L295.4946,29.1394 L302.9236,21.7104 L302.9246,21.7104 L302.9236,21.7104 L302.9236,7.4304 L295.4946,0.0004 L285.5106,0.0004 Z M302.9236,7.4304 L302.9246,7.4304 L302.9236,7.4304 Z"/>
      <polygon fill="#fff" points="267.01 0 267.01 7.43 267.01 21.71 267.01 29.137 267.01 49.464 274.44 49.464 274.44 29.137 284.423 29.137 284.423 21.71 274.44 21.71 274.44 7.43 284.423 7.43 284.423 0"/>
      <polygon fill="#fff" points="46.543 0 46.543 42.034 46.543 49.464 53.973 49.464 63.957 49.464 63.957 42.034 53.973 42.034 53.973 0"/>
      <polygon fill="#fff" points="65.044 42.034 65.044 49.464 75.025 49.464 78.109 49.464 78.109 42.034"/>
      <polygon fill="#fff" points="0 0 0 7.43 0 21.71 0 29.137 0 49.464 7.43 49.464 7.43 29.137 17.413 29.137 17.413 21.71 7.43 21.71 7.43 7.43 17.413 7.43 17.413 0"/>
      <polygon fill="#fff" points="18.5 0 18.5 7.43 28.484 7.43 28.484 21.71 18.5 21.71 18.5 29.137 28.483 29.137 35.911 21.71 35.911 7.43 28.484 0"/>
      <polygon fill="#fff" points="317.946 21.71 325.376 21.71 325.376 0 317.946 0"/>
      <polygon fill="#fff" points="317.946 29.14 317.946 42.034 317.944 42.034 325.376 49.464 335.359 49.464 335.359 42.034 325.376 42.034 325.376 29.14"/>
      <polygon fill="#fff" points="346.428 0 346.428 42.034 336.445 42.034 336.445 49.464 346.683 49.464 353.858 42.034 353.858 0"/>
      <polygon fill="#fff" points="105.455 42.034 105.455 49.464 116.523 49.464 119.606 49.464 119.606 42.034"/>
      <polygon fill="#fff" points="105.455 0 105.455 7.43 116.523 7.43 119.607 7.43 119.607 0"/>
      <polygon fill="#fff" points="86.954 0 86.954 7.43 86.954 21.018 86.954 28.445 86.954 42.034 86.954 49.464 94.383 49.464 104.365 49.464 104.365 42.034 94.383 42.034 94.383 28.445 100.763 28.445 104.365 28.445 104.366 28.445 104.366 21.018 104.365 21.018 94.383 21.018 94.383 7.43 104.365 7.43 104.365 0"/>
      <polygon fill="#fff" points="240.887 42.034 240.887 49.464 246.521 49.464 255.039 49.464 255.039 42.034"/>
      <polygon fill="#fff" points="240.887 0 240.887 7.43 246.521 7.43 255.039 7.43 255.039 0"/>
      <polygon fill="#fff" points="222.387 0 222.387 7.43 222.387 21.018 222.387 28.445 222.387 42.034 222.387 49.464 229.816 49.464 239.798 49.464 239.798 42.034 229.816 42.034 229.816 28.445 236.197 28.445 239.798 28.445 239.801 28.445 239.801 21.018 239.798 21.018 229.816 21.018 229.816 7.43 239.798 7.43 239.798 0"/>
      <polygon fill="#fff" points="130.49 0 130.49 7.43 144.732 7.43 144.732 49.464 147.904 49.464 148.991 49.464 152.163 49.464 152.163 7.43 158.973 7.43 166.404 7.43 166.404 0"/>
      <polygon fill="#fff" points="176.457 0 176.457 7.43 190.7 7.43 190.7 49.464 193.871 49.464 194.958 49.464 198.13 49.464 198.13 7.43 202.836 7.43 211.769 7.43 212.14 7.43 212.372 7.43 212.372 .373 212.372 0"/>
    </g>
  </svg>
</section>
<nav>
  <div class="input-group">
    <label for="draggable">Enable drag</label>
    <input type="checkbox" id="draggable"/>
  </div>
  <div class="input-group">
    <input type="file" id="file">
    <input type="file" id="file2">
  </div>
  <input type="button" id="clear" value="CLEAR!">
</nav>
              
            
!

CSS

              
                *:focus {
  outline: none;
}

body {
  font-family: 'Teko', sans-serif;
  font-weight: 400;
}
.input-group {
  align-items: center;
}
h1, h2, h3, h4, h5, h6 {
  font-weight: 400;
  text-transform: uppercase;
  background-color: #FED82F;
  padding: 15px;
  line-height: .8em;
  display: inline-block;
  padding: 23px 30px 15px 60px;
  margin: 0;
  font-size: 50px;
  font-size: 5vw;
}
@media (max-width: 700px) {
  h1, h2, h3, h4, h5, h6 {
    font-size: 35px;
  }
}
@media (min-width: 3000px) {
  h1, h2, h3, h4, h5, h6 {
    font-size: 150px;
  }
}

h2, h3, h4, h5, h6 {
  background-color: #000;
  color: #fff;
  font-size: 50px;
  font-size: 3.5vw;
}
@media (max-width: 1000px) {
  h2, h3, h4, h5, h6 {
    font-size: 35px;
  }
}
@media (min-width: 2285.71429px) {
  h2, h3, h4, h5, h6 {
    font-size: 80px;
  }
}

label {
  font-family: sans-serif;
  color: #000;
  margin-right: 15px;
}

::-webkit-scrollbar {
  display: none;
}

nav {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 30px;
  text-align: center;
  background-color: #FED82F;
}

section {
  position: relative;
  height: 100vh;
  width: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #ED423A;
  overflow: hidden;
  display: flex;
  .inner {
    background-image: url(https://images.unsplash.com/photo-1486693128850-a77436e7ba3c?dpr=1&auto=format&fit=crop&w=1500&h=1000&q=80&cs=tinysrgb&crop=&bg=);
    height: 100vh;
    width: 50%;
    background-size: cover;
    background-position: center;
  }
}

#title {
  padding: 45px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  height: 100vh;
  position: absolute;
  top: 0;
  left: 0;
  flex-direction: column;
}
#pletterij,
.alloy-logo,
#title.enable {
  cursor: move;
  z-index: 9999999;
}

.alloy-slide-nav,
.alloy-main-nav,
footer,
header {
  display: none !important;
}
iframe#cp_embed_zwXPjX {
  transform: translateY(-50px);
  height: calc(100vh + 50px);
  border: 0;
}
#pletterij,
.alloy-logo {
  position: absolute;
  z-index: 999;
  left: 0;
  top: 0;
}
.alloy-logo svg {
  width: 80px;
  background-color: #fff;
  top: 0;
  left: 60px;
}
#pletterij {
  bottom: 30px;
  right: 30px;
  max-width: 200px;
  left: auto;
  top: auto;
}
              
            
!

JS

              
                $("#file").change(function() {
  var file = this.files[0];
  var reader = new FileReader();
  reader.onloadend = function() {
    $("#image1").css("background-image", 'url("' + reader.result + '")');
  };
  if (file) {
    reader.readAsDataURL(file);
  } else {
  }
});
$("#file2").change(function() {
  var file = this.files[0];
  var reader = new FileReader();
  reader.onloadend = function() {
    $("#image2").css("background-image", 'url("' + reader.result + '")');
  };
  if (file) {
    reader.readAsDataURL(file);
  } else {
  }
});
$("#title").draggable({ disabled: true });
$("#pletterij").draggable();
$(".alloy-logo").draggable();
// if ($("#draggable").is(":checked")) {
//   alert("banaan");
//   $("#title").draggable("enable");
// }
$("#draggable").change(function() {
  if ($(this).is(":checked")) {
    $("#title").addClass("enable");
    $("#title").draggable("enable");
  } else {
    $("#title").removeClass("enable");
    $("#title").draggable("disable");
  }
});
              
            
!
999px

Console