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.

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.

  input#circular-menu.circular-menu__button(type='checkbox' href='javascript: void 0' checked)
  a.circular-menu__item(href='#'): i.fa.fa-chrome
  a.circular-menu__item(href='#'): i.fa.fa-firefox
  a.circular-menu__item(href='#'): i.fa.fa-edge
  a.circular-menu__item(href='#'): i.fa.fa-safari
  a.circular-menu__item(href='#'): i.fa.fa-opera

              *, *::before, *::after
  box-sizing border-box

  background #fce4ec
  position absolute
  left 50%
  top 40%

/* ------------------------- Separate line ------------------------- */

$shape-color = #fff
$shape-background = #dc143c
$shape-color-hover = #dc143c
$shape-background-hover = #f08080
$shape-color-active-focus = #8b0000
$menu-items = 5
$hamburger-spacing = 8px
$delay-init = 0.08s
$delay-interval = 0.1s
$open-distance = 105px

  background $shape-background
  border-radius 100%
  box-shadow 0 2px 5px rgba(0, 0, 0, 0.25)
  color $shape-color
  height 80px
  line-height 80px
  margin-left -40px
  position absolute
  text-align center
  top 20px
  transform translate3d(0, 0, 0)
  transition transform ease-out 0.2s
  width 80px

  font-size 20px
  width 400px
  height 250px
  margin-left -(@width / 2)
  margin-top 5rem
  padding-left (@width / 2)
  padding-top @font-size

    display none

    &:checked + ^[0]__icon
      transform scale(0.8, 0.8) translate3d(0, 0, 0)
      transition-duration 0.2s
      transition-timing-function linear

      & > .hamburger
          transform translate3d(0, 0, 0) rotate(45deg)

          transform translate3d(0, 0, 0) scale(0.1, 1)

          transform translate3d(0, 0, 0) rotate(-45deg)

    &:checked ~ ^[0]__item
      transition-timing-function cubic-bezier(0.935, 0, 0.34, 1.33)

      for i in 1..($menu-items)
        $pi = PI
        $opening-angle = $pi * 2
        $angle = ($pi - $opening-angle) / 2 + $opening-angle / ($menu-items) * (i - 1)

          transition-duration ($delay-init + $delay-interval * i)
          transform translate3d(cos($angle) * $open-distance, sin($angle) * $open-distance, 0)


    cursor pointer
    transform scale(1.1, 1.1) translate3d(0, 0, 0)
    transition-duration 0.4s
    transition-timing-function cubic-bezier(0.175, 0.885, 0.32, 1.275)
    z-index 2

      transform scale(1.2, 1.2) translate3d(0, 0, 0)

    & > .hamburger
      background $shape-color
      display block
      width 25px
      height 3px
      left 50%
      margin-left -(@width / 2)
      margin-top -(@height / 2)
      position absolute
      top 50%
      transition transform 0.2s

        transform translate3d(0, -($hamburger-spacing), 0)

        transform translate3d(0, 0, 0)

        transform translate3d(0, $hamburger-spacing, 0)

    font-size 32px

    for i in 1..($menu-items)
        transition-duration 0.18s

      color $shape-color-hover
      background $shape-background-hover

      color $shape-color-active-focus

🕑 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.