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

            
              <div class="content">
  <div class="intro">
    <h1>Fullscreen Modal</h1>
    <a href="replaceMe" class="btn trigger">Clicking me triggers the modal</a>
  </div>
  <hr />
  <p>Bacon ipsum dolor sit amet swine meatloaf sausage shoulder.  T-bone tri-tip chuck, venison flank leberkas cow sirloin pork chop biltong andouille beef.  Tri-tip pig shoulder swine kielbasa rump pork belly.  Brisket kielbasa turkey pastrami prosciutto.  Pastrami venison sausage shoulder.  Pastrami bacon andouille, turkey sausage jowl salami filet mignon ham.  Drumstick boudin pork chop capicola, tri-tip jerky salami rump turducken ground round meatball.</p><p>Chuck salami beef biltong beef ribs jerky doner boudin ham tail rump brisket.  Sausage frankfurter porchetta tri-tip.  Doner pancetta tri-tip prosciutto cow bresaola corned beef capicola tail frankfurter brisket.  Chuck sirloin pork pancetta chicken pig prosciutto strip steak tenderloin shoulder tri-tip pastrami rump.  Chicken salami shoulder short ribs pork belly.  Ball tip venison porchetta corned beef sausage.</p><p>Meatloaf beef drumstick shank salami porchetta short ribs hamburger.  Doner beef drumstick, swine tri-tip bacon fatback pork chop.  Ball tip fatback hamburger jerky tongue, pastrami biltong chicken ribeye.  Andouille flank pig filet mignon corned beef, spare ribs chicken frankfurter turkey.  Drumstick strip steak flank tenderloin spare ribs sausage meatloaf ball tip venison prosciutto salami turkey short loin leberkas.  Turkey rump tri-tip ribeye venison doner.  Sausage tenderloin sirloin prosciutto, brisket swine landjaeger biltong ham rump.</p><p>Ball tip ham hock t-bone, frankfurter short loin jowl brisket shankle shank sausage ribeye.  Ham beef filet mignon rump, jowl prosciutto ribeye flank brisket shoulder cow shank pancetta.  Brisket shankle pancetta salami pork frankfurter capicola doner venison shank short loin ham bacon rump.  Drumstick short ribs sausage pork chop andouille strip steak venison.  Turducken ribeye filet mignon kielbasa.  Rump ham hock venison kevin.  Filet mignon drumstick boudin, capicola kielbasa doner brisket kevin bresaola prosciutto shoulder.</p><p>Pork flank cow shank ham.  Rump boudin cow doner pancetta frankfurter beef ribs chuck shoulder venison.  Porchetta beef ribs drumstick flank.  Pork loin sirloin pork chop kevin landjaeger biltong salami swine.  Tail turkey ribeye bacon jerky andouille venison meatball jowl kielbasa sausage short loin leberkas meatloaf pork chop.  Pig fatback meatloaf turducken meatball turkey spare ribs, drumstick pork chop.</p>
  <p>Bacon ipsum dolor sit amet swine meatloaf sausage shoulder.  T-bone tri-tip chuck, venison flank leberkas cow sirloin pork chop biltong andouille beef.  Tri-tip pig shoulder swine kielbasa rump pork belly.  Brisket kielbasa turkey pastrami prosciutto.  Pastrami venison sausage shoulder.  Pastrami bacon andouille, turkey sausage jowl salami filet mignon ham.  Drumstick boudin pork chop capicola, tri-tip jerky salami rump turducken ground round meatball.</p><p>Chuck salami beef biltong beef ribs jerky doner boudin ham tail rump brisket.  Sausage frankfurter porchetta tri-tip.  Doner pancetta tri-tip prosciutto cow bresaola corned beef capicola tail frankfurter brisket.  Chuck sirloin pork pancetta chicken pig prosciutto strip steak tenderloin shoulder tri-tip pastrami rump.  Chicken salami shoulder short ribs pork belly.  Ball tip venison porchetta corned beef sausage.</p><p>Meatloaf beef drumstick shank salami porchetta short ribs hamburger.  Doner beef drumstick, swine tri-tip bacon fatback pork chop.  Ball tip fatback hamburger jerky tongue, pastrami biltong chicken ribeye.  Andouille flank pig filet mignon corned beef, spare ribs chicken frankfurter turkey.  Drumstick strip steak flank tenderloin spare ribs sausage meatloaf ball tip venison prosciutto salami turkey short loin leberkas.  Turkey rump tri-tip ribeye venison doner.  Sausage tenderloin sirloin prosciutto, brisket swine landjaeger biltong ham rump.</p><p>Ball tip ham hock t-bone, frankfurter short loin jowl brisket shankle shank sausage ribeye.  Ham beef filet mignon rump, jowl prosciutto ribeye flank brisket shoulder cow shank pancetta.  Brisket shankle pancetta salami pork frankfurter capicola doner venison shank short loin ham bacon rump.  Drumstick short ribs sausage pork chop andouille strip steak venison.  Turducken ribeye filet mignon kielbasa.  Rump ham hock venison kevin.  Filet mignon drumstick boudin, capicola kielbasa doner brisket kevin bresaola prosciutto shoulder.</p><p>Pork flank cow shank ham.  Rump boudin cow doner pancetta frankfurter beef ribs chuck shoulder venison.  Porchetta beef ribs drumstick flank.  Pork loin sirloin pork chop kevin landjaeger biltong salami swine.  Tail turkey ribeye bacon jerky andouille venison meatball jowl kielbasa sausage short loin leberkas meatloaf pork chop.  Pig fatback meatloaf turducken meatball turkey spare ribs, drumstick pork chop.</p>
  <p>Bacon ipsum dolor sit amet swine meatloaf sausage shoulder.  T-bone tri-tip chuck, venison flank leberkas cow sirloin pork chop biltong andouille beef.  Tri-tip pig shoulder swine kielbasa rump pork belly.  Brisket kielbasa turkey pastrami prosciutto.  Pastrami venison sausage shoulder.  Pastrami bacon andouille, turkey sausage jowl salami filet mignon ham.  Drumstick boudin pork chop capicola, tri-tip jerky salami rump turducken ground round meatball.</p><p>Chuck salami beef biltong beef ribs jerky doner boudin ham tail rump brisket.  Sausage frankfurter porchetta tri-tip.  Doner pancetta tri-tip prosciutto cow bresaola corned beef capicola tail frankfurter brisket.  Chuck sirloin pork pancetta chicken pig prosciutto strip steak tenderloin shoulder tri-tip pastrami rump.  Chicken salami shoulder short ribs pork belly.  Ball tip venison porchetta corned beef sausage.</p><p>Meatloaf beef drumstick shank salami porchetta short ribs hamburger.  Doner beef drumstick, swine tri-tip bacon fatback pork chop.  Ball tip fatback hamburger jerky tongue, pastrami biltong chicken ribeye.  Andouille flank pig filet mignon corned beef, spare ribs chicken frankfurter turkey.  Drumstick strip steak flank tenderloin spare ribs sausage meatloaf ball tip venison prosciutto salami turkey short loin leberkas.  Turkey rump tri-tip ribeye venison doner.  Sausage tenderloin sirloin prosciutto, brisket swine landjaeger biltong ham rump.</p><p>Ball tip ham hock t-bone, frankfurter short loin jowl brisket shankle shank sausage ribeye.  Ham beef filet mignon rump, jowl prosciutto ribeye flank brisket shoulder cow shank pancetta.  Brisket shankle pancetta salami pork frankfurter capicola doner venison shank short loin ham bacon rump.  Drumstick short ribs sausage pork chop andouille strip steak venison.  Turducken ribeye filet mignon kielbasa.  Rump ham hock venison kevin.  Filet mignon drumstick boudin, capicola kielbasa doner brisket kevin bresaola prosciutto shoulder.</p><p>Pork flank cow shank ham.  Rump boudin cow doner pancetta frankfurter beef ribs chuck shoulder venison.  Porchetta beef ribs drumstick flank.  Pork loin sirloin pork chop kevin landjaeger biltong salami swine.  Tail turkey ribeye bacon jerky andouille venison meatball jowl kielbasa sausage short loin leberkas meatloaf pork chop.  Pig fatback meatloaf turducken meatball turkey spare ribs, drumstick pork chop.</p>
</div>
<div class="overlay">
  <i class="close">Close</i>
  <div class="message">
    <img src="http://placekitten.com/768/1024" />
  </div>
</div>
            
          
!

CSS

            
              @import "bourbon";

@import url('https://fonts.googleapis.com/css?family=Oleo+Script');

$linkColor: rgb(39, 75, 106);

*{ box-sizing: border-box; }

body{
  color: #222;
  font-family: $helvetica;
  background: url(http://subtlepatterns.subtlepatterns.netdna-cdn.com/patterns/bedge_grunge.png) repeat;
}

.intro{
  text-align: center;
  display: block;
  padding-bottom: .5em;
  margin: 0 auto;

  h1{
    font-family: 'Oleo Script';
    text-shadow: white 1px 1px 0;
    color: rgb(39, 75, 106);
  }
}

.btn{
  background: $linkColor;
  color: #fff;
  font-size: 1.2em;
  text-decoration: none;
  margin-bottom: .5em;
  display: inline-block;
  padding: .5em .75em;
  border-radius: .15em;
  transition: all .25s;

  &:hover{
    background: darken($linkColor, 10%);
  }
}

.content{
  width: 90%;
  margin: 0 auto;
  transition: all .5s;

  &.overlayActive{
    transform: scale(.9);
    -webkit-filter: blur(2px);
  }
}

.overlay{
  color: #fff;
  background: rgba(0,0,0,.5);
  position: fixed;
  height: 100%;
  width: 100%;
  z-index: 100;
  left: 0;
  top: 0;
  opacity: 0;
  transform: scale(0);
  transition: all .5s;


  &.overlayOpen{
    opacity: 1;
    transform: scale(1);
  }
  
  .close{
    font-size: 1.25em;
    font-style: normal;
    float: right;
    margin-top: 1em;
    margin-right: 1em;
    cursor: pointer;
    &:before{
      padding-right: .25em;
      font-family: FontAwesome;
      content: "\f05c";
    }
  }
}

.message{
  font-size: 3em;
  font-weight: 100;
  width: 90%;
  height: 60%;
  text-align: center;
  margin: 1em auto;
  
  img{
    max-width: 100%;
  }
}
            
          
!

JS

            
              var fsOverlay = function(){
  var body = $('body'),
      overlay = $('.overlay'),
      trigger = $('.trigger'),
      close = $('.close'),
      content = $('.content');
  
  openModal = function(e){
    e.preventDefault();
    content.addClass('overlayActive');
    overlay.addClass('overlayOpen');
  }
  
  closeModal = function(e){
    e.preventDefault();
    content.removeClass('overlayActive');
    overlay.removeClass('overlayOpen');
    
  }
  
  trigger.on("click", openModal);
  
  close.on("click", closeModal);
  
  body.on("keyup", function(e){
    if(e.keyCode == 27){
      close.trigger("click");
    }
  });
}

$(fsOverlay);

            
          
!
999px

Console