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

              
                <div class="speaker">  
  
  <img class="speaker__image" src="https://s.gravatar.com/avatar/6daee16a7ee8bcc600e3f655b6e947fb" >
  
  <a href="#" class="speaker__toggle-transform"></a>
  
  <a href="#" class="speaker__link">Open Abstract</a>
  
  
  
  <div class="speaker__abstract abstract">
    <div class="wrapper">
      <h1>Some Abstract Info</h1>
      <p><a href="https://drafts.csswg.org/css-transforms/#issue-fc114988">Link to topical issue/bug report at w3</a></p>
      <p>Try clicking on 'OPEN ABSTRACT' with Transform both on and off. </p>

      <p>It works fine with Transform Off.</p>

      <p>It glitches out and appears to get stuck to container when hover/transform is active with Transform On.</p>

      <p>Click close in abstract or Press 'ESC' to exit abstract.</p>

      <p><a href="#" class="abstract__close">Close</a> or hit ESC key.</p>
      <p>Nam eget dui. In ut quam vitae odio lacinia tincidunt.</p>

      <p>Pellentesque auctor neque nec urna. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos hymenaeos.</p>
      
    </div>
  </div>
  
</div>


<div class="conclusion">
  
  <p>After further research and figuring out the issue this problem has been around for ~ 3.5 years. Does anyone else think this is a weird  inconsistency with how position:fixed is applying to its parents transformed container?</p>
  <p><a href="https://drafts.csswg.org/css-transforms/#issue-fc114988">Link to topical issue/bug report at w3</a></p>

  <p><a href="https://meyerweb.com/eric/thoughts/2011/09/12/un-fixing-fixed-elements-with-css-transforms/">Link to Disucssion on Eric Meyer's blog</a></p>
  <p><a href="https://github.com/w3c/csswg-drafts/issues/913">*New* Github related Issue</a></p>
</div>

              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Trykker|Raleway:400,700);

body {
  background:#333;
  font-family: 'Trykker', serif;
}
.speaker {
  background:rgba(255,255,255,0.2);
  transition:300ms;
  
  &__toggle-transform {
    padding:0.3em 0.5em;
    text-decoration:none;
    color:black;
    background:#FF3457;
    font-family: 'Raleway', sans-serif;
    float:right;
    text-transform:uppercase;
    font-size:0.9em;
    font-weight:700;
    transition:300ms;
    border-radius:4px;
    box-shadow:-5px 1px 30px rgba(0,0,0,0.5);
    &:before {
      content:'Transform Off'
    }
    &.on {
      background:#43FF7E;
      &:before {
        content:'Transform On'
      }
    }
  }
  &.transform-on {
    transform:scale(1);
    &:hover {
    }
  }
  &:hover {
     & .speaker__image {
       transform:rotate(360deg);
     }
  }
  &__image {
    border-radius:50%;
    padding:2px;
    background:rgba(255,255,255,0.5);
    position:relative;
    left:-2em;
    box-shadow:-5px 1px 30px rgba(0,0,0,0.5);
    transition:350ms;
  }
  &__abstract {
    display:none;
    overflow:scroll;
    .wrapper {
      width:1000px;
      margin:0 auto;
      max-width:100%;
      padding:5em;
    }
    &.active {
      position:fixed;
      right:0;
      bottom:0;
      left:0;
      top:0;
      background:#fff;
    }
  }
  &__link {
    color:rgba(255,255,255,0.5);
    text-decoration:none;
    text-transform:uppercase;
    font-family: 'Raleway', sans-serif;
    font-weight:700;
    font-size:1.05em;
    display:block;
    text-align:right;
    transition:250ms;
    &:hover {
      color:rgba(255,255,255,0.8);
    }
  }
}
.conclusion {
  background:rgba(255,255,255,0.8);
  a {
    color:#333;
    text-decoration:none;
    text-transform:uppercase;
    font-family: 'Raleway', sans-serif;
    font-weight:700;
    font-size:1.05em;
    text-align:right;
  }
}
.speaker, .conclusion {
  width:80%;
  float:none;
  margin:5%;
  padding:1em;
  box-shadow:-5px 1px 30px rgba(0,0,0,0.5);
  border-radius:5px;
  border-bottom:5px solid rgba(255,255,255,0.5);
}
              
            
!

JS

              
                

$(function() {
  
  
  $('.speaker').on('click', '.speaker__link', function(e) {
    $('.speaker__abstract').addClass('active').fadeIn();
    e.preventDefault();
  });
  
  $('.speaker').on('click', '.abstract__close', function(e) {
    $('.speaker__abstract').hide().removeClass('active');
    e.preventDefault();
  });
  
  $(document).keyup(function(e) {
    if (e.keyCode == 27) {
      $('.speaker__abstract').hide().removeClass('active');
    }
  });
  
  $('.speaker').on('click', '.speaker__toggle-transform', function(e) {
    $('.speaker').toggleClass('transform-on');
    $(this).toggleClass('on');
    e.preventDefault();
  });
});
              
            
!
999px

Console