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 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

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="snip1183 blue">
  <img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sq-sample33.jpg" alt="sq-sample33"/><i class="ion-ios-navigate-outline"></i>
  <figcaption>
    <h3>Keith<span> Green</span></h3>
    <p>
      I suppose if we couldn't laugh at things that don't make sense, we couldn't react to a lot of life.
    </p>
  </figcaption>
  <a href="#"></a>
</figure>
<figure class="snip1183 red hover">
  <img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sq-sample32.jpg" alt="sq-sample32"/><i class="ion-ios-bolt-outline"></i>
  <figcaption>
    <h3>Stella<span> Reeves</span></h3>
    <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="snip1183 yellow">
  <img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/331810/sq-sample31.jpg" alt="sq-sample31"/><i class="ion-ios-star-outline"></i>
  <figcaption>
    <h3>Josh<span> Briggs</span></h3>
    <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>
  </figcaption>
  <a href="#"></a>
</figure>
              
            
!

CSS

              
                /* Included color classes.. 
	.red 
	.blue 
	.yellow
*/
@import url(https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css);
@import url(https://fonts.googleapis.com/css?family=Raleway:400,800);
figure.snip1183 {
  font-family: 'Raleway', Arial, sans-serif;
  position: relative;
  overflow: hidden;
  margin: 10px;
  min-width: 220px;
  max-width: 310px;
  width: 100%;
  background: #000000;
  text-align: left;
  color: #000000;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
}
figure.snip1183 * {
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  -webkit-transition: all 0.35s ease-in-out;
  transition: all 0.35s ease-in-out;
}
figure.snip1183 img {
  vertical-align: top;
  max-width: 100%;
  -webkit-transition: all 0.5s ease-in-out;
  transition: all 0.5s ease-in-out;
}
figure.snip1183 figcaption {
  position: absolute;
  top: 18px;
  left: 18px;
  bottom: 18px;
  right: 18px;
  display: block;
  padding: 75px 20px 20px;
}
figure.snip1183 figcaption::before {
  position: absolute;
  min-width: 64px;
  min-height: 64px;
  top: 0%;
  left: 0%;
  bottom: 90%;
  right: 90%;
  content: '';
  display: block;
  background: rgba(255, 255, 255, 0.7);
  -webkit-transition: all 0.35s ease-in-out;
  transition: all 0.35s ease-in-out;
  -webkit-transition-delay: 0.35s;
  transition-delay: 0.35s;
}
figure.snip1183 h3,
figure.snip1183 p {
  opacity: 0;
  -webkit-transition-delay: 0s;
  transition-delay: 0s;
}
figure.snip1183 h3 {
  text-transform: uppercase;
  margin: 0 0 5px;
  font-weight: 400;
  -webkit-transform: translateX(10px);
  transform: translateX(10px);
}
figure.snip1183 h3 span {
  font-weight: 800;
}
figure.snip1183 p {
  text-align: left;
  margin: 0;
}
figure.snip1183 i {
  position: absolute;
  top: 25px;
  left: 25px;
  font-size: 34px;
  color: #000000;
  width: 50px;
  height: 50px;
  line-height: 50px;
  text-align: center;
  background: rgba(255, 255, 255, 0.5);
  z-index: 1;
}
figure.snip1183 a {
  left: 0;
  right: 0;
  top: 0;
  bottom: 0;
  position: absolute;
}
figure.snip1183.blue {
  background-color: #2472a4;
  color: #164666;
}
figure.snip1183.blue i {
  color: #20638f;
}
figure.snip1183.red {
  background-color: #ab3326;
  color: #6d2018;
}
figure.snip1183.red i {
  color: #962d22;
}
figure.snip1183.yellow {
  background-color: #e08e0b;
  color: #976008;
}
figure.snip1183.yellow i {
  color: #c87f0a;
}
figure.snip1183:hover img,
figure.snip1183.hover img {
  opacity: 0.3;
  -webkit-filter: grayscale(100%);
  filter: grayscale(100%);
}
figure.snip1183:hover figcaption:before,
figure.snip1183.hover figcaption:before {
  right: 0%;
  bottom: 0%;
  -webkit-transition-delay: 0s;
  transition-delay: 0s;
}
figure.snip1183:hover h3,
figure.snip1183.hover h3,
figure.snip1183:hover p,
figure.snip1183.hover p {
  opacity: 1;
  -webkit-transform: translateY(0);
  transform: translateY(0);
  -webkit-transition-delay: 0.35s;
  transition-delay: 0.35s;
}
figure.snip1183:hover i,
figure.snip1183.hover i {
  background: rgba(255, 255, 255, 0.8);
}

              
            
!

JS

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

Console