cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

Quick-add: + add another resource

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.

              <div id="box">Press to toggle</div>
<div id="box2">Press to toggle</div>

<!-- box uses a second, blurred image that matches the initial image and transitions opacity -->

<!-- box2 blurs the image directly, attempting to transition -->
div {
	  border: 1px solid #000;
  text-align: center;
	  position: relative;
	  height: 200px;
  width: 200px;
  margin: 0 auto;
	  background: rgb(245, 248, 250) url(https://danielcwilson.com/demos/ios7blur/back.png) top center no-repeat;
	  -webkit-background-size: 200px 1025px;
	  -moz-background-size: 200px 1025px;
	  background-size: 200px 1025px;
  margin: 0 10px 10px;
  display: inline-block;

#box::after {
		  content: "";
		  opacity: 0;
		  top: 0;
		  left: 0;
		  bottom: 0;
		  right: 0;
		  position: absolute;
		  z-index: 0;   

		  -webkit-transition: opacity .35s ease-in-out;
		  -moz-transition: opacity .35s ease-in-out;
		  transition: opacity .35s ease-in-out;

		  background: rgb(245, 248, 250) url(https://danielcwilson.com/demos/ios7blur/backBlurred.jpg) top center no-repeat;
		  -webkit-background-size: 295px 1025px;
		  -moz-background-size: 295px 1025px;
		  background-size: 295px 1025px;
#box.selected::after {
  opacity: 1;

#box2 {
		  -webkit-transition: -webkit-filter .35s ease-in-out;
		  transition: -webkit-filter .35s ease-in-out;
		  transition: filter .35s ease-in-out;
#box2.selected {
  -webkit-filter: blur(15px);
  filter: blur(15px);

              function toggler(e) {
document.getElementById('box').addEventListener('click', toggler, false);
document.getElementById('box2').addEventListener('click', toggler, false);

Asset uploading is a PRO feature.

As a PRO member, you can drag-and-drop upload files here to use as resources. Images, Libraries, JSON data... anything you want. You can even edit them anytime, like any other code on CodePen.


Loading ..................