cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

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.

Quick-add: + add another resource

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.

Quick-add: + add another resource

Code Indentation

     

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.

            
              - word = 'Thanks'
%a.h-button.centered{'data-text'=>"Hover me","href"=>"#","aria-label"=>"#{word}"}
  - word.split(//).each do |letter|
    %span #{letter}
            
          
!
            
              @import url('https://fonts.googleapis.com/css?family=Roboto:900')
$letters: 6

body
  background: #111
  
a
  font-family: 'Roboto', sans-serif
  font-weight: 900
  color: black
  text-decoration: none
  
.centered
  position: absolute
  left: 50%
  top: 50%
  transform: translate(-50%, -50%)
  
.h-button
  background: white
  padding: 20px
  width: 250px
  text-align: center
  
  span
    display: inline-block
    min-width: 0.30em
    text-transform: uppercase
    transition: .25s cubic-bezier(0.5,-1, 0.5, 2)
    opacity: 0
    transform: translate(0,-20px)
    
  &:before
    content: attr(data-text)
    position: absolute
    width: 100%
    left: 0
    transition: .25s cubic-bezier(0.5,-1, 0.5, 2)
    text-transform: uppercase
    letter-spacing: 3.5px
    opacity: 1
    transform: translate(0,0px)
    
  &:hover,&:focus
    &:before
      opacity: 0
      transform: translate(0, 20px) 
  
    span
      opacity: 1
      transform: translate(0, 0)
   
    @for $i from 1 through $letters
      span:nth-child(#{$i})
        transition-delay: 0.025s * $i
   
            
          
!
999px
Loading ..................

Console