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.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

HTML

              
                <!--
Follow me on https://twitter.com/koucik
My stuff: skywalkapps.github.io
-->
<div class="dropdown open">
  <h3>Bootstrap Dropdown - Alternative alignment with big icons</h3>
  <ul class="dropdown-menu dropdown-menu--horizontal">
    <li>
      <a class="dropmenu-item-btn" href="#">
        <i class="glyphicon glyphicon-pencil"></i>
        Edit
      </a>
    </li>
    <li>
      <a class="dropmenu-item-btn" href="#">
        <i class="glyphicon glyphicon-trash"></i>
        Delete
      </a>
    </li>
    <li class="divider"></li>
    <li>
      <a class="dropmenu-item-btn" href="#">
        <i class="glyphicon glyphicon-ok-circle"></i>
        Mark as resolved
      </a>
    </li>
  </ul>
</div><!-- /dropdown -->
              
            
!

CSS

              
                @padding-large-vertical: 10px;
@padding-base-vertical: 6px;
@font-size-h3: 24px;

.dropmenu-item-btn {
  text-align: center;

  // Unfortunate cascade in Bootstrap
  .dropdown-menu > li > & {
    padding: @padding-large-vertical;
    
    &:hover,
    &:focus,
    &:active {
      color: darken(#428bca, 6.5%);
    }
  }

  > .glyphicon {
    display: block;
    font-size: @font-size-h3; // 24px
    margin-bottom: @padding-base-vertical;
  }
}

.open > .dropdown-menu--horizontal {
  display: flex;
  
  > li > a {
    min-width: 80px;
  }
  > .divider {
    width: 1px;
    height: auto;
    margin: 0 9px;
  }
}
/* General styles to improve presentation */
html, body {
  height: 100%;
}
body {
  background: linear-gradient(to bottom, #44a17d 0, #365e81 100%);
  position: relative;
  display:flex;
  justify-content: center;
  align-items:center;
  flex-wrap:wrap;
  padding:0;
  margin:0;
  color: #fff;
}
h3 {
  position: absolute;
  left: -340px;
  top: -25px;
  font-family: 'Open Sans', sans-serif;
  font-weight: bold;
  max-width: 300px;
  text-align: center;
  line-height: 1.3;
  margin-bottom: 2rem;
}
.dropdown {
  margin-top: -100px;
  margin-left: 40px;
}
.dropdown-menu {
  min-width: 80px;
}
              
            
!

JS

              
                
              
            
!
999px

Console