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="snip1323"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample28.jpg" alt="sample28"/>
  <figcaption>
    <h2>Abraham Pigeon</h2>
    <div class="icons"><a href="#"><i class="ion-social-reddit-outline"></i></a><a href="#"> <i class="ion-social-twitter-outline"></i></a><a href="#"> <i class="ion-social-vimeo-outline"></i></a></div>
  </figcaption><a href="#"></a>
</figure>
<figure class="snip1323 hover"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample87.jpg" alt="sample87"/>
  <figcaption>
    <h2>Pelican Steve</h2>
    <div class="icons"><a href="#"><i class="ion-social-reddit-outline"></i></a><a href="#"> <i class="ion-social-twitter-outline"></i></a><a href="#"> <i class="ion-social-vimeo-outline"></i></a></div>
  </figcaption><a href="#"></a>
</figure>
<figure class="snip1323"><img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sample77.jpg" alt="sample77"/>
  <figcaption>
    <h2>Fleece Marigold</h2>
    <div class="icons"><a href="#"><i class="ion-social-reddit-outline"></i></a><a href="#"> <i class="ion-social-twitter-outline"></i></a><a href="#"> <i class="ion-social-vimeo-outline"></i></a></div>
  </figcaption><a href="#"></a>
</figure>
              
            
!

CSS

              
                /* Icon set - http://ionicons.com */
@import url(https://fonts.googleapis.com/css?family=Raleway:300,400,500);
.snip1323 {
  font-family: 'Raleway', Arial, sans-serif;
  position: relative;
  overflow: hidden;
  margin: 10px;
  min-width: 230px;
  max-width: 315px;
  width: 100%;
  color: #ffffff;
  text-align: center;
  background-color: #000000;
}
.snip1323 * {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-transition: all 0.35s 0.5s ease;
  transition: all 0.35s 0.5s ease;
}
.snip1323 img {
  max-width: 100%;
  vertical-align: top;
}
.snip1323 figcaption {
  position: absolute;
  height: 100%;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 1;
}
.snip1323 h2 {
  position: absolute;
  margin: 0;
  width: 100%;
  -webkit-transform: translate(-25%, -50%);
  transform: translate(-25%, -50%);
  left: 0;
  top: 50%;
  opacity: 0;
  padding: 0 20px;
  font-weight: 300;
  text-transform: uppercase;
}
.snip1323 .icons {
  position: absolute;
  bottom: 0;
  left: 50%;
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);
  opacity: 0;
}
.snip1323 i {
  padding: 10px 5px;
  display: inline-block;
  font-size: 24px;
  color: #ffffff;
  text-align: center;
  opacity: 0.7;
}
.snip1323 i:hover {
  opacity: 1;
  -webkit-transition: all 0.35s ease;
  transition: all 0.35s ease;
}
.snip1323:before {
  position: absolute;
  bottom: 0;
  right: 100%;
  top: 0;
  left: 0;
  content: '';
  background-color: #9b5212;
  z-index: 1;
  opacity: 0.4;
  -webkit-transition: all 0.35s 0.3s ease-in;
  transition: all 0.35s 0.3s ease-in;
}
.snip1323:after {
  content: '';
  position: absolute;
  top: 50%;
  left: 100%;
  -webkit-transform: translateY(-50%);
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 200px 200px 200px 0;
  border-color: transparent #9b5212 transparent transparent;
  opacity: 0.9;
  -webkit-transition: all 0.35s 0s ease-out;
  transition: all 0.35s 0s ease-out;
}
.snip1323:hover img,
.snip1323.hover img {
  opacity: 0.4;
}
.snip1323:hover h2,
.snip1323.hover h2,
.snip1323:hover .icons,
.snip1323.hover .icons {
  opacity: 1;
}
.snip1323:hover h2,
.snip1323.hover h2 {
  -webkit-transform: translate(0, -50%);
  transform: translate(0, -50%);
}
.snip1323:hover:before,
.snip1323.hover:before {
  right: 0;
  -webkit-transition: all 0.35s 0s ease-out;
  transition: all 0.35s 0s ease-out;
}
.snip1323:hover:after,
.snip1323.hover:after {
  left: 50%;
  -webkit-transition: all 0.35s 0.2s ease-in;
  transition: all 0.35s 0.2s ease-in;
}

              
            
!

JS

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

              
            
!
999px

Console