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.

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

              
                <figure class="snip1449">
  <img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample68.jpg" alt="sample68" />
  <figcaption>
    <h2>Dylan Meringue</h2>
    <p>The only skills I have patience to learn are those that have no real application in life.</p>
  </figcaption>
  <a href="#"></a>
</figure>
<figure class="snip1449 hover"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample73.jpg" alt="sample73" />
  <figcaption>
    <h2>Hans Down</h2>
    <p>I'm learning real skills that I can apply throughout the rest of my life ... Procrastinating and rationalizing.</p>
  </figcaption>
  <a href="#"></a>
</figure>
<figure class="snip1449"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample83.jpg" alt="sample83" />
  <figcaption>
    <h2>Ingredia Nutrisha</h2>
    <p>If something is so complicated that you can't explain it in 10 seconds, then it's probably not worth knowing anyway. </p>
  </figcaption>
  <a href="#"></a>
</figure>
              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Raleway);
@import url(https://fonts.googleapis.com/css?family=Julius+Sans+One);
.snip1449 {
  font-family: 'Raleway', Arial, sans-serif;
  position: relative;
  overflow: hidden;
  margin: 10px;
  min-width: 230px;
  max-width: 315px;
  width: 100%;
  color: #ffffff;
  text-align: left;
  background-color: #ffffff;
  line-height: 1.4em;
  transform: translateZ(0);
}

.snip1449 * {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-transition: all 0.35s ease-out;
  transition: all 0.35s ease-out;
}

.snip1449 img {
  max-width: 100%;
  vertical-align: top;
  -webkit-transition: all 0.8s ease-out;
  transition: all 0.8s ease-out;
}

.snip1449:before {
  background: #000000;
  position: absolute;
  content: '';
  -webkit-transition: all 0.35s ease-out;
  transition: all 0.35s ease-out;
  -webkit-transition-delay: 0.2s;
  transition-delay: 0.2s;
  z-index: 1;
  top: 100%;
  bottom: 0;
  right: 0;
  left: 0;
  box-shadow: 0 0 40px white;
}

.snip1449 figcaption {
  position: absolute;
  top: 0;
  height: 100%;
  left: 0;
  width: 100%;
  z-index: 2;
}

.snip1449 h2,
.snip1449 p {
  margin: 0;
  width: 100%;
  opacity: 0;
  padding: 25px;
}

.snip1449 h2 {
  font-family: 'Julius Sans One', Arial, sans-serif;
}

.snip1449 p {
  position: absolute;
  bottom: 0;
  padding-left: 60px;
  font-size: 0.8em;
  letter-spacing: 1px;
  text-align: right;
}

.snip1449 a {
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  position: absolute;
  z-index: 2;
}

.snip1449:hover img,
.snip1449.hover img {
  opacity: 0.2;
}

.snip1449:hover:before,
.snip1449.hover:before {
  top: 0;
  box-shadow: 0 0 0px white;
  -webkit-transition-delay: 0s;
  transition-delay: 0s;
}

.snip1449:hover figcaption h2,
.snip1449.hover figcaption h2,
.snip1449:hover figcaption p,
.snip1449.hover figcaption p {
  -webkit-transition-delay: 0.25s;
  transition-delay: 0.25s;
}

.snip1449:hover figcaption h2,
.snip1449.hover figcaption h2 {
  -webkit-transform: translateY(0%);
  transform: translateY(0%);
  opacity: 0.5;
}

.snip1449:hover figcaption p,
.snip1449.hover figcaption p {
  opacity: 0.7;
}
              
            
!

JS

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

              
            
!
999px

Console