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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ 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

              
                <div class="toolbar-font active">
  <form action="">
    <header>
      <h4>Font Settings</h4>
      <button>
        <span class="icon-remove"></span>
      </button>
    </header>

    <p class="description">Choose your font scheme and colours. Don't forget to include fallback fonts. </p>

    <fieldset>
      <h5>Font Family</h5>
      <label for="">header <span class="icon-question-sign" data-tooltip="The header font is only used for the title of each widget. "></span></label>
      <input type="text" value="helvetica neue, helvetica, arial, sans-serif">
      <label for="">body <span class="icon-question-sign" data-tooltip="The body font is used in form elements and the table. "></span></label>
      <input type="text" value="helvetica neue, helvetica, arial, sans-serif">
    </fieldset>

    <fieldset>
      <h5>Font Colour</h5>
      <label for="">text-light</label>
      <input type="text" value="c8c8c8">
      
      <label for="">text-light:hover
        <span class="icon-question-sign" data-tooltip="Change the colour of text when users hover their mouse over the element. "></span>
      </label>
      <input type="text" value="e0e0e0">
      
      <label for="">text-dark</label>
      <input type="text" value="333333">
      
      <label for="">text-dark:hover
        <span class="icon-question-sign" data-tooltip="Change the colour of text when users hover their mouse over the element. "></span>
      </label>
      <input type="text" value="474747">
    </fieldset>
    
    <button class="reset">Reset</button>
  </form>
</div>
              
            
!

CSS

              
                // excerpt from a recent web app.
@import 'https://methodik.co.uk/extra/font-awesome.min.css';

// include open sans
@font-face {
  font-family: 'open sans';
  src: url('https://methodik.co.uk/extra/opensans-regular-webfont.eot');
  src: url('https://methodik.co.uk/extra/opensans-regular-webfont.eot?#iefix') format('embedded-opentype'),
         url('https://methodik.co.uk/extra/opensans-regular-webfont.woff') format('woff'),
         url('https://methodik.co.uk/extra/opensans-regular-webfont.ttf') format('truetype'),
         url('https://methodik.co.uk/extra/opensans-regular-webfont.svg#open_sansregular') format('svg');
  font-weight: normal;
  font-style: normal;
}


body {
  font: .75em/1 open sans;
  background: whitesmoke;
  color: #292929;
}

div[class^="toolbar-"] {
  position: relative;
  margin: 1rem auto;
  width: 14rem;
  background: #333333;
  box-shadow: 0 0 13px rgba(0, 0, 0, 0.4);
  padding-bottom: 1.25rem;
  z-index: 1000;
}

div[class^="toolbar-"] header {
  height: 2rem;
  line-height: 1rem;
}

div[class^="toolbar-"] header h4 {
  color: white;
  display: block;
  vertical-align: middle;
  height: 2rem;
  font-size: 1.25em;
  padding-top: .5rem;
  padding-left: .75rem;
}

div[class^="toolbar-"] header button {
  position: absolute;
  top: 0;
  right: 0;
  width: 2rem;
  height: 2rem;
  margin-right: 0;
  padding: 0;
  border-radius: 0;
}

div[class^="toolbar-"] header button span {
  color: #333333;
}

div[class^="toolbar-"] header button span:hover {
  color: #333333 !important;
}

div[class^="toolbar-"] p {
  background: #1f1f1f;
  color: #ececec;
  padding: .75rem;
  line-height: 1rem;
}

div[class^="toolbar-"] fieldset {
  margin-top: 1.25rem;
  color: #ececec;
  padding-left: .7rem;
  border: none;
}

div[class^="toolbar-"] fieldset h5 {
  font-size: .875rem;
  margin: .25rem 0 .5rem 0;
}

div[class^="toolbar-"] fieldset label {
  display: block;
  margin-top: .5rem;
  width: 93%;
  position: relative;
}

div[class^="toolbar-"] fieldset label span[class^="icon-"] {
  position: absolute;
  top: 0;
  right: 0;
  font-size: .875rem;
  cursor: help;
}

div[class^="toolbar-"] fieldset input[type=text] {
  margin-left: 0;
  width: 90%;
  margin-top: .25rem;
}

div[class^="toolbar-"] fieldset input[type=checkbox],
div[class^="toolbar-"] fieldset input[type=radio],
div[class^="toolbar-"] fieldset select {
  margin-left: 0 !important;
}

div[class^="toolbar-"] button.reset {
  margin: 1rem auto 0 .75rem;
  display: block;
}

// icons


[class^="icon-question"].active {
  color: white;
}

[class^="icon-question"]:hover:after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 0rem;
  right: -14.25rem;
  width: 10rem;
  height: auto;
  padding: 1.25rem;
  color: #ececec;
  text-shadow: none !important;
  background: rgba(51, 51, 51, 1);
  border-radius: 4px;
  -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
  -moz-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
  box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.3);
  cursor: default;
}

button {
  background: #ececec;
  padding: .25em 3em;
  border: none;
  -webkit-border-radius: 3px;
  -moz-border-radius: 3px;
  border-radius: 3px;
  -webkit-background-clip: padding-box;
  -moz-background-clip: padding;
  background-clip: padding-box;
  border-bottom: 2px #bec2c7;
  margin-right: 1rem;
  vertical-align: middle;
  line-height: 1.5em;
  cursor: pointer;
  -webkit-transition: background 0.3s ease;
  -moz-transition: background 0.3s ease;
  -o-transition: background 0.3s ease;
  transition: background 0.3s ease;
}

button:hover {
  background: white;
}

              
            
!

JS

              
                /*[class^="icon-question"]:hover:before {
  content: '';
  display: block; 
  position: absolute;
  bottom: -.25rem;
  right: -3rem;
  background: rgba(51, 51, 51, 1);
  height: 1rem; width: 1rem;
  -webkit-transform: rotate(55deg);
}*/
              
            
!
999px

Console