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.

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

              
                <div class="container">

  <div class="printerbase">
    <svg class="path" viewBox="0 0 100 100">
  <path class="test" d="m55.102 70.199c-8.8008 0-16-2.3008-19.102-6.1016-2.5 1.8008-5.1016 3.1016-7.1992 3.1992-2.1992 0.10156-4-1-5.1016-3-2.1016-3.8984-1.5-11.5 4.5-19.801 1-1.3008 9.5-12.602 14.602-10.898 2.1016 0.69922 3.1992 3.3008 3.1992 8.3008h-1c0-4-0.89844-6.8984-2.5-7.3984-3.1016-1-9.1992 4.8008-13.5 10.602-5.8008 7.8984-6.3984 15-4.3984 18.699 0.89844 1.6992 2.3984 2.6016 4.1992 2.5 1.8984-0.10156 4.3008-1.3984 6.6016-3.1016-0.39844-0.60156-0.60156-1.1016-0.80078-1.8008-1.1992-4 1.6992-8.3984 8.1016-11.898 7.3008-4 14.898-6.3984 20.5-6.6992 0.5-0.80078 0.89844-1.5 1.3984-2.1992 5.6992-9.1992 6-9.5 6.6016-9.1016 0.60156 0.30078 0.80078 0.39844-3.3008 9.6992-0.30078 0.60156-0.5 1.1992-0.80078 1.8008 1.8984 0.30078 3.3008 0.89844 4.1992 2 1.3984 1.6992 2 5.1016-3.5 11.898-6.3984 7.8984-8 9-9 8.3984s-1.3008-2.8008 6.8984-21.398h-1.8984c-9.1016 14.602-14.199 21.801-16.5 20.898-1.3008-0.5-2.1016-1.1992-2.3984-2-0.39844-1.1016 0.10156-2.3008 0.69922-3.5 0.39844-0.89844 0.89844-1.8984 0.80078-2.6992v-0.10156c-0.60156 0-3 2-5 3.5-1.3984 1.1016-2.8984 2.3984-4.5 3.5 3.1992 3.8008 11.5 6.6016 23.5 5.3984 22.297-2.1953 33.598-22.094 33.699-22.293l0.89844 0.5c-0.10156 0.19922-11.699 20.602-34.5 22.801-1.8984 0.19922-3.6992 0.29688-5.3984 0.29688zm11.598-26.5c-7.3008 16.5-7.8008 20.301-7.3984 20.301 0.5 0 2.1992-1.1992 7.6992-8 4-4.8984 5.1016-8.6016 3.5-10.602-0.69922-0.89844-2.1016-1.3984-3.8008-1.6992zm-20.301 11.801c0.10156 0 0.30078 0 0.39844 0.10156 0.19922 0.10156 0.5 0.30078 0.60156 0.89844 0.10156 1.1016-0.39844 2.1992-0.89844 3.1992s-0.89844 1.8984-0.60156 2.6992c0.19922 0.5 0.80078 1 1.8984 1.3984 1.8984 0.69922 9.8008-11.602 14.898-19.898-5.3984 0.5-12.5 2.8008-19.398 6.6016-6 3.3008-8.8008 7.1992-7.6992 10.699 0.19922 0.5 0.39844 1 0.69922 1.5 1.6016-1.1016 3.1016-2.3984 4.5-3.5 2.9023-2.3984 4.5039-3.6992 5.6016-3.6992zm18.301-12.602c0.5 0 1 0 1.3984 0.10156 0.30078-0.69922 0.60156-1.3008 0.89844-2 1.3984-3.1992 2.3008-5.3008 2.8984-6.6016-1.1016 1.6992-2.8008 4.3984-4.3984 7-0.30078 0.60156-0.69922 1.1016-1 1.6016 0.003906-0.10156 0.10547-0.10156 0.20312-0.10156z"/>
  <path d="m11.699 69.398c-2.1016 0-4.1016-1-5.6992-2.8008-1-1.1016-1.1992-2.3984-0.69922-3.8008 1.3008-3.8008 8.3984-8.3984 18-12.398 1.5-6.3008 1.8008-11.102 0.30078-20l1-0.19922c1.5 8.8008 1.1992 13.699-0.10156 19.699 8.3008-3.3984 18.199-6.3008 27.898-7.8984l0.19922 1c-9.8984 1.6016-20.102 4.6016-28.301 8-0.5 2.1016-1.1992 4.3984-1.8984 7.1016-1.6992 6.1992-5 10.199-8.8984 11.102-0.69922 0.19531-1.3008 0.19531-1.8008 0.19531zm11.199-17.898c-9 3.8008-15.5 8.1016-16.699 11.602-0.39844 1.1016-0.19922 2 0.5 2.8008 1.8008 2 4 2.8008 6.3008 2.3008 3.5-0.80078 6.6016-4.6992 8.1016-10.301 0.79688-2.3008 1.3984-4.4023 1.7969-6.4023z"/>
</svg>
  </div>

  <div id="circle"></div>

</div>
              
            
!

CSS

              
                body {
  background: #e2e2e2;
  
  &:after {
    content: "";
    display: block;
    background: url("https://ismanfromes.be/projets/codepen/if.svg") no-repeat;
    width: 25px;
    height: 25px;
    position: absolute;
    bottom: 15px;
    right: 15px;
    opacity: 0.2;
  }
}

.container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.printerbase {
  width: 360px;
  height: 280px;
  background-image: linear-gradient(30deg, #ececec 0%, #f0f0fb 100%);
  transform: rotate(-40deg) skew(30deg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: -20px 20px 50px -20px rgba(0, 0, 0, 0.3);

  svg {
    background: none;
    position: absolute;
    left: 150px;
    top: 80px;
    width: 200px;
    height: 200px;
    transform: translate(-50%, -50%);
    overflow: visible;
    filter: drop-shadow(-5px 2px 1px rgba(0, 0, 0, 0.1));

    path {
      fill: none;
      stroke: #707070;
      stroke-width: 1px;
      stroke-dashoffset: 0;
      opacity: 0;
    }

    @iterations: 10;

    .loop (@i) when (@i > 0) {
      &:nth-child(@{i}) {
        left: 200px + @i*2;
        top: 125px - @i*2;
      }
      .loop(@i - 1);
    }
    .loop(@iterations);
  }
}

              
            
!

JS

              
                var $printerbase = $(".printerbase");
var svg = $printerbase.html();

for (i = 2; i < 10; i++) {
  $(svg)
    .addClass("path" + i)
    .appendTo($printerbase);
}

TweenMax.to(".path path", 0.2, { opacity: 1, ease: Power1.ease });
TweenMax.staggerFrom(".path path", 1, { drawSVG: 0, ease: Power4.ease }, 1);

              
            
!
999px

Console