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

              
                <svg class="filter" version="1.1">
  <defs>
    <filter id="gooeyness">
      <feGaussianBlur in="SourceGraphic" stdDeviation="8" result="blur" />
      <feColorMatrix in="blur" mode="matrix" values="1 0 0 0 0  0 1 0 0 0  0 0 1 0 0  0 0 0 20 -10" result="gooey" />
      <feComposite in="SourceGraphic" in2="gooey" operator="atop" />
    </filter>
  </defs>
</svg>
<div class="logos">
  <div class="logo-gooey">
    <!-- <img width="200px" height="200px" src="cp-gooey.svg" alt=""> -->
    <svg width="200" height="200" viewBox="0 0 100 100">
      <ellipse
               style="fill:none;stroke:#ffffff;stroke-width:9;"
               cx="50"
               cy="50"
               rx="43.969463"
               ry="43.969467" />
      <path
            style="fill:none;stroke:#ffffff;stroke-width:4.0999999;"
            d="m 23.159542,59.058185 27.0369,17.917516 27.036899,-18.124098 -27.200153,-17.960845 z" />
      <path
            d="m 40.339795,52.10704 3.097422,2.206536 6.759225,4.479379 6.759225,-4.531024 2.339808,-1.626837 m 8.081219,-5.3033 3.097422,-2.131912 6.759225,-4.531025 -27.200153,-17.960845 -26.873646,18.167427 6.759225,4.479379 2.718615,1.827729"
            style="fill:none;stroke:#ffffff;stroke-width:4.0999999;" />
      <path
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:5;"
            d="m 50.002551,29.163053 0,11.743024" />
      <path
            d="m 50.002551,57.826132 0,13.258252"
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:5;" />
      <path
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:2;"
            d="m 22.223357,40.779808 0,17.930208" />
      <path
            d="m 78.160554,40.906077 0,17.930208"
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:2;" />
      <path
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;"
            d="m 28.41054,34.213816 13.384521,-8.965104" />
      <path
            d="m 72.478445,34.340085 -13.384521,-8.965104"
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;" />
      <path
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;"
            d="m 41.163716,74.114841 -13.384521,-8.965104" />
      <path
            d="m 59.346462,74.367379 14.268404,-9.722718"
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;" />
      <path
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:2;"
            d="m 80.05459,44.062804 0,11.869292" />
      <path
            d="m 20.3,44.694149 0,11.364217"
            style="fill:#009100;fill-opacity:1;stroke:#ffffff;stroke-width:2;" />
      <path
            d="m 36.870568,47.345799 8.08122,-5.934646"
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;" />
      <path
            style="fill:#009100;stroke:#ffffff;stroke-width:2.5;"
            d="m 62.37692,46.840723 -7.828682,-5.303301" />
      <div class="ball"></div>
      </div>
    <div class="logo">
      <svg width="200" height="200" viewBox="0 0 100 100">
        <ellipse
                 cx="50"
                 cy="50"
                 rx="43.969463"
                 ry="43.969467" />
        <path
              d="m 23.159542,59.058185 27.0369,17.917516 27.036899,-18.124098 -27.200153,-17.960845 z" />
        <path
              d="m 23.159542,40.875439 27.0369,17.917516 27.036899,-18.124098 -27.200153,-17.960845 z" />
        <path
              d="m 50.002551,22.975869 0,17.930208" />
        <path
              d="m 50.002551,57.826132 0,17.930208" />
        <path
              d="m 22.980971,41.663691 0,17.930208" />
        <path
              d="m 77.024132,41.663691 0,17.930208" />
      </svg>
    </div>
  </div>

              
            
!

CSS

              
                body {
  align-items: center;
  background: #708fd4;
  display: flex;
  font-family: 'Inconsolata', monospace;
  height: 100%;
  justify-content: center;
  margin: 0;
  position: absolute;
  width: 100%;
}

.filter {
  position: absolute;
  left: -9999px;
}

.logos {
  border: 2px dashed white;
  height: 300px;
  position: relative;
  width: 300px;
}

.logo {
  fill: none;
  stroke: white;
  stroke-width: 5;
  stroke-linejoin:round;
  padding: 50px;
  position: absolute;
}

.logo-gooey {
  display: flex;
  filter: url('#gooeyness');
  flex-direction: column;
  overflow: hidden;
  padding: 50px;
  position: absolute;
}

.ball {
  background: white;
  border-radius: 50%;
  height: 100px;
  position: absolute;
  width: 100px;
}

              
            
!

JS

              
                let lg = document.querySelector('.logos');
let ball = document.querySelector('.ball');
lg.addEventListener('mousemove', function(e) {
  console.dir(e);
  ball.style.left = e.layerX - 50 + 'px';
  ball.style.top = e.layerY - 50 + 'px';
});
              
            
!
999px

Console