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.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

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.

            
              <div class="container">
  <h1>Quick <i class="qtip tip-top" data-tip="Well, tips, you know. To explain that thing below &darr;">tips</i></h1>
  <p>I am a simple CSS3-powered <i class="qtip tip-top" data-tip="weee!">tooltip</i>.</p>
  <p>I can be on <i class="qtip tip-top" data-tip="Here it comes right on top!">top</i>, on the <i class="qtip tip-right" data-tip="Right, finally">right</i>, <br/><i class="qtip tip-left" data-tip=" Left, that's right">left</i> and, of course, on the
    <i
      class="qtip tip-bottom" data-tip="Yeah, bottom">bottom</i>.</p>
  <p>Add CSS from this pen, the markup will look like this:</p>
  <code>
  <span class="hl">&lt;i class="<span class="qclass">qtip tip-top</span>" data-tip="<span class="qcontent">Tip content</span>"&gt;</span><br/>Any text / image / element<br /><span class="hl">&lt;/i&gt;</span><br/><br/>
    Available options: <span class="qclass">.tip-top</span>, <span class="qclass">.tip-left</span>, <span class="qclass">.tip-right</span> or <span class="qclass">.tip-bottom</span>
  </code>
</div>
            
          
!
            
              @import url('https://fonts.googleapis.com/css?family=Raleway:200,200i,400,400i,500,500i,700,700i');
/*tipped element. should be inline-block or block*/
.qtip {
  display: inline-block;
  position: relative;
  cursor: pointer;
  color: #3bb4e5;
  border-bottom: 0.05em dotted #3bb4e5;
  box-sizing: border-box;
  font-style: normal;
  transition:all .25s ease-in-out
}
.qtip:hover {color:#069;border-bottom:0.05em dotted #069}
/*the tip*/
.qtip:before {
  content: attr(data-tip);
  font-size: 14px;
  position: absolute;
  background: rgba(10, 20, 30, 0.85);
  color: #fff;
  line-height: 1.2em;
  padding: 0.5em;
  font-style: normal;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  min-width: 120px;
  text-align: center;
  opacity: 0;
  visibility: hidden;
  transition: all .3s ease-in-out;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.5);
  font-family: sans-serif;
  letter-spacing: 0;
  font-weight: 600
}
.qtip:after {
  width: 0;
  height: 0;
  border-style: solid;
  content: '';
  position: absolute;
  opacity: 0;
  visibility: hidden;
  transition: all .3s ease-in-out
}
.qtip:hover:before,
.qtip:hover:after {
  visibility: visible;
  opacity: 1
}
/*top*/
.qtip.tip-top:before {
  top: 0;
  left: 50%;
  transform: translate(-50%, calc(-100% - 8px));
  box-sizing: border-box;
  border-radius: 3px;
}
.qtip.tip-top:after {
  border-width: 8px 8px 0 8px;
  border-color: rgba(10, 20, 30, 0.85) transparent transparent transparent;
  top: -8px;
  left: 50%;
  transform: translate(-50%, 0);
}
/*bottom*/
.qtip.tip-bottom:before {
  bottom: 0;
  left: 50%;
  transform: translate(-50%, calc(100% + 8px));
  box-sizing: border-box;
  border-radius: 3px;
}
.qtip.tip-bottom:after {
  border-width: 0 8px 8px 8px;
  border-color: transparent transparent rgba(10, 20, 30, 0.85) transparent;
  bottom: -8px;
  left: 50%;
  transform: translate(-50%, 0);
}
/*left*/
.qtip.tip-left:before {
  left: 0;
  top: 50%;
  transform: translate(calc(-100% - 8px), -50%);
  box-sizing: border-box;
  border-radius: 3px;
}
.qtip.tip-left:after {
  border-width: 8px 0 8px 8px;
  border-color: transparent transparent transparent rgba(10, 20, 30, 0.85);
  left: -8px;
  top: 50%;
  transform: translate(0, -50%);
}
/*right*/
.qtip.tip-right:before {
  right: 0;
  top: 50%;
  transform: translate(calc(100% + 8px), -50%);
  box-sizing: border-box;
  border-radius: 3px;
}
.qtip.tip-right:after {
  border-width: 8px 8px 8px 0;
  border-color: transparent rgba(10, 20, 30, 0.85) transparent transparent;
  right: -8px;
  top: 50%;
  transform: translate(0, -50%);
}
/*some styles for this example*/
body {
  background: #3bb4e5
}
.container {
  padding: 1.5em;
  margin: 3em auto;
  background: #fff;
  position: relative;
  max-width: 720px;
  font-size: calc(2vmin + 12px);
  line-height: 1.5em;
  box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.3);
  font-weight: 500;
  text-align:center;
  font-family:'Raleway', sans-serif
}
.container p {margin:0 auto 0.8em}
.container h1 {
  text-align: center;font-family: monospace, serif;
  line-height:1em;
  color: #d40; 
  margin:0 auto 0.5em;
  font-size: 2.5em;
}
code {
  color: #3bb4e5;
  font-size: 0.8em;
  padding: 1em;
  background: rgb(10,20,30);
  display: block;
  text-align:left;
}
.hl {
  color: #eb1777
}
.qcontent {
  color: #ff0;
  font-weight: bold
}
.qclass {
  color: #dd0;
  font-weight: bold
}
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.
Loading ..................

Console