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 is required to process package imports. If you need a different preprocessor remove all packages first.

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

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.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

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.

HTML

            
              <figure class="snip1403">
  <img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample68.jpg" alt="sample68" />
  <figcaption>
    <p>That's the whole problem with science. You've got a bunch of empiricists trying to describe things of unimaginable wonder.</p>
    <div class="plus1"></div>
    <div class="plus2"></div>
  </figcaption>
  <a href="#"></a>
</figure>
<figure class="snip1403 hover"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample88.jpg" alt="sample88" />
  <figcaption>
    <p>The inside of my head was exploding with fireworks. Fortunately, my last thought turned out the lights when it left.</p>
    <div class="plus1"></div>
    <div class="plus2"></div>
  </figcaption>
  <a href="#"></a>
</figure>
<figure class="snip1403"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample86.jpg" alt="sample86" />
  <figcaption>
    <p>That's the problem with nature, something's always stinging you or oozing mucous all over you. Let's go and watch TV.</p>
    <div class="plus1"></div>
    <div class="plus2"></div>
  </figcaption>
  <a href="#"></a>
</figure>
            
          
!

CSS

            
              @import url(https://fonts.googleapis.com/css?family=Titillium+Web:200);
@import url(https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css);
.snip1403 {
  font-family: 'Titillium Web', Arial, sans-serif;
  position: relative;
  overflow: hidden;
  margin: 10px;
  min-width: 230px;
  max-width: 315px;
  width: 100%;
  color: #ffffff;
  text-align: left;
  font-size: 16px;
  background-color: #0c1116;
  line-height: 1.6em;
  font-weight: 200;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}
.snip1403 * {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-transition: all 0.35s linear;
  transition: all 0.35s linear;
}
.snip1403 *:before,
.snip1403 *:after {
  -webkit-transition: all 0.35s ease;
  transition: all 0.35s ease;
}
.snip1403 img {
  max-width: 100%;
  backface-visibility: hidden;
  vertical-align: top;
}
.snip1403 figcaption {
  position: absolute;
  top: 50%;
  margin: 0 40px;
  padding: 10px 15px;
  -webkit-transform: translate(0%, -50%);
  transform: translate(0%, -50%);
}
.snip1403 figcaption div {
  -webkit-transform: rotate(-90deg);
  transform: rotate(-90deg);
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  opacity: 0.7;
}
.snip1403 figcaption div:before,
.snip1403 figcaption div:after {
  position: absolute;
  content: '';
  background-color: rgba(255, 255, 255, 0.75);
  left: 50%;
  top: 50%;
}
.snip1403 figcaption div:before {
  width: 1px;
  height: 50px;
  -webkit-transform: translateY(-50%);
  transform: translateY(-50%);
}
.snip1403 figcaption div:after {
  height: 1px;
  width: 50px;
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);
}
.snip1403 p {
  opacity: 0;
  letter-spacing: 1px;
  margin: 0;
}
.snip1403 a {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
}
.snip1403:hover img,
.snip1403.hover img {
  zoom: 1;
  filter: alpha(opacity=15);
  -webkit-opacity: 0.15;
  opacity: 0.15;
}
.snip1403:hover figcaption p,
.snip1403.hover figcaption p {
  -webkit-transition-delay: 0.6s;
  transition-delay: 0.6s;
  opacity: 1;
}
.snip1403:hover figcaption .plus1,
.snip1403.hover figcaption .plus1,
.snip1403:hover figcaption .plus2,
.snip1403.hover figcaption .plus2 {
  -webkit-transform: rotate(0);
  transform: rotate(0);
}
.snip1403:hover figcaption .plus1:before,
.snip1403.hover figcaption .plus1:before,
.snip1403:hover figcaption .plus1:after,
.snip1403.hover figcaption .plus1:after {
  top: 0%;
  left: 0%;
  -webkit-transition-delay: 0.35s;
  transition-delay: 0.35s;
}
.snip1403:hover figcaption .plus2:before,
.snip1403.hover figcaption .plus2:before,
.snip1403:hover figcaption .plus2:after,
.snip1403.hover figcaption .plus2:after {
  top: 100%;
  left: 100%;
  -webkit-transition-delay: 0.35s;
  transition-delay: 0.35s;
}

            
          
!

JS

            
              /* Demo purposes only */
$(".hover").mouseleave(
  function () {
    $(this).removeClass("hover");
  }
);

            
          
!
999px

Console