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 CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

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.

              <ul class="tools">
  <li class="tool-btn">
    <input id="pencil_btn" type="radio" name="toolbar" checked>
    <label for="pencil_btn">
      <i class="fa fa-fw fa-pencil"></i>
  <li class="tool-btn">
    <input id="paint_btn" type="radio" name="toolbar">
    <label for="paint_btn">
      <i class="fa fa-fw fa-paint-brush"></i>
  <li class="tool-btn">
    <input id="erase_btn" type="radio" name="toolbar">
    <label for="erase_btn">
      <i class="fa fa-fw fa-eraser"></i>
  <li class="separator"></li>
  <li class="tool-btn">
    <input id="move_btn" type="radio" name="toolbar">
    <label for="move_btn">
      <i class="fa fa-fw fa-arrows"></i>
  <li class="tool-btn">
    <input id="scale_btn" type="radio" name="toolbar">
    <label for="scale_btn">
      <i class="fa fa-fw fa-expand"></i>
              @color-b: #889;
@color-d1: darken(@color-b, 10%);
@color-d2: darken(@color-b, 25%);
@color-d3: darken(@color-b, 40%);

@color-l1: lighten(@color-b, 10%);
@color-l2: lighten(@color-b, 25%);
@color-l3: lighten(@color-b, 40%);

@unit: 8px;

.pressable(@off, @on) {
  > label {
    position: relative;
    display: inline-block;
    box-sizing: border-box;
    border: 1px solid @color-d2;
    font-size: @unit * 3 / 2;
    border-radius: @unit / 4;
    padding: @unit;
    color: @color-l2;
    background-color: @off;
      1px 1px 3px 1px rgba(0,0,0,0.2),
      inset 1px 1px 1px rgba(255,255,255,0.3), 
      inset -1px -1px 1px rgba(0,0,0,0.3);

    transition: background-color 125ms;
  > input[type=radio] { 
    position: absolute;
    font-size: 0;
    left: -100%;
  > input[type=radio]:checked + label {
    background-color: @on;
      inset 1px 1px 1px rgba(0,0,0,0.3);
  > input[type=radio]:focus + label {
    box-shadow: 0 0 15px 1px #3498db;  

.tools {
  position: absolute;
  top: 10vh;
  left: 0;
  background-color: @color-b;
  border: 1px solid @color-d1;
  border-left: 0;
  > li { 
    margin: @unit @unit;
  > li.separator {
    margin: @unit @unit / 2;
    border-top: 1px solid @color-d1;
    border-bottom: 1px solid @color-l1;

.tool-btn {
  .pressable(@color-b, @color-d2);

Asset uploading is a PRO feature.

As a PRO member, you can drag-and-drop upload files here to use as resources. Images, Libraries, JSON data... anything you want. You can even edit them anytime, like any other code on CodePen.


Loading ..................