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

            
              <svg class="oSVG" viewBox="0 0 800 600" xmlns="http://www.w3.org/2000/svg">
 <defs>
  <pattern id="oBg" width="20"  height="20" x="8" y="0" patternUnits="userSpaceOnUse" viewBox="0 0 20 20">

   <rect width="6" height="6" x="10" y="10" fill='#297CBC' fill-opacity='0' />
   <rect width="6" height="6" x="0" y="0" fill='#297CBC' fill-opacity='1' />

   </pattern>
  
  </defs>
 <clipPath id="oMask">
        <path class="bigO" id="bigO" d="M354.54,248.49q0-26.89,2.52-43t7.9-24.2q7.35-11.53,17.55-16.47t26.87-4.94q16.67,0,26.87,4.94t17.66,16.47q5.37,8.34,7.84,24.37t2.47,42.81q0,26.67-2.52,42.75t-7.78,24.42q-7.46,11.53-17.66,16.46t-26.87,4.94q-16.67,0-26.87-4.94T365,315.67q-5.37-8.12-7.9-24.2T354.54,248.49Zm32.16,0q0,41.71,4.87,52.52t18,10.81q12.92,0,17.68-10.59T432,248.49q0-42.15-4.82-52.91t-17.85-10.76q-13,0-17.85,10.76T386.7,248.49Z"/>
</clipPath>
      <g class="OGroup">

        <polyline class="OArmRDown" points="460 200.5 486 173.5 486 128.5" fill="none" stroke="#EBF2FA" stroke-miterlimit="10" stroke-width="3"/>
        <polyline class="OArmLDown" points="358.5 200.54 334.5 169.5 340 128.5" fill="none" stroke="#EBF2FA" stroke-miterlimit="10" stroke-width="3"/>
        <polyline class="OLegL" points="388 333.5 379 373.5 383 415.5 370 430.5" fill="none" stroke="#EBF2FA" stroke-miterlimit="10" stroke-width="3"/>
        <polyline class="OLegR" points="428 333.5 438 374.5 431 416.5 442 432.5" fill="none" stroke="#EBF2FA" stroke-miterlimit="10" stroke-width="3"/>
      
 <rect fill="url(#oBg)" clip-path="url(#oMask)" width="100%" height="100%" />
 <use xlink:href="#bigO" fill="none" stroke="#EBF2FA" stroke-width="6"  stroke-linecap="round" stroke-linejoin="round"  /> 
 <!-- <use xlink:href="#bigO" fill="none" stroke="#00487C" stroke-width="3"  stroke-linecap="round"/>  -->
       </g>
<line id="OBar" x1="300" y1="130" x2="523" y2="130" stroke="#EBF2FA" stroke-width="4"  stroke-linecap="square" stroke-linejoin="square" /> 
 
</svg>
            
          
!
            
              body {
  background-color:#00487C;
  overflow: hidden;
 
}

body,
html {
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
}


svg{
  width:100%;
  height:100%;
  visibility:hidden;
}

polyline{
  stroke-linecap:round;
  stroke-linejoin:round;
}
            
          
!
            
              var xmlns = "http://www.w3.org/2000/svg",
  xlinkns = "http://www.w3.org/1999/xlink",
  select = function(s) {
    return document.querySelector(s);
  },
  selectAll = function(s) {
    return document.querySelectorAll(s);
  },
    OGroup = select('.OGroup'),
    bigO = select('.bigO'),
    OArmLDown = select('.OArmLDown'),
    OArmRDown = select('.OArmRDown'),
    OLegL = select('.OLegL'),
    OLegR = select('.OLegR'),
    OArmLUpArr = "358.5 170.54 324 167.5 340 128.5".split(' ').map(Number),
    OArmRUpArr = "460 170.5 498.5 164.5 486 128.5".split(' ').map(Number),
    OArmLDownArr = OArmLDown.getAttribute('points').split(' ').map(Number),
    OArmRDownArr = OArmRDown.getAttribute('points').split(' ').map(Number),
    OArmLTempArr = OArmLDownArr.slice(0),
    OArmRTempArr = OArmRDownArr.slice(0)
    

/* CustomEase.create("shake", "M0,0 C0.48,0.182 0.451,0.951 0.5,1 0.528,1.028 0.554,0.968 0.57,0.968 0.586,0.968 0.606,1.028 0.626,1.028 0.654,1.028 0.634,0.97 0.664,0.97 0.692,0.97 0.679,1.022 0.708,1.024 0.728,1.024 0.719,0.96 0.736,0.972 0.74,0.974 0.753,1.022 0.79,1.026 0.805,1.027 0.822,0.979 0.839,0.978 0.86,0.986 0.869,1.02 0.896,1.024 0.912,1.026 0.931,0.98 0.948,0.976 0.976,0.968 0.999,1 1,1") */

TweenMax.set('svg', {
  visibility: 'visible'
})
var mainTl = new TimelineMax()

var tl = new TimelineMax({repeat:-1, repeatDelay:3, onUpdate:onUpdate}).timeScale(3);
tl.to(OArmLTempArr, 4, {
 endArray:OArmLUpArr,
 ease:Back.easeOut.config(1.5)
})
.to(OArmRTempArr, 4, {
 endArray:OArmRUpArr,
 ease:Back.easeOut.config(1.5)
},'-=4')
.to(bigO, 4, {
 y:'-=30',
 ease:Back.easeOut.config(1.5)
},'-=4')
.staggerTo([OLegL,OLegR], 4, {
// scaleY:1.2,
 y:-30,
 cycle:{
  rotation:[-6,6],
  transformOrigin:['100% 0%', '0% 0%']
 },
 
 ease:Back.easeOut.config(1.5)
},0,'-=4')
.to('#oBg', 4, {
  attr:{
   x:-7,
   y:16
  },
 ease:Back.easeOut.config(1.5)
 },'-=4')
.to(OGroup, 0.13, {
 y:-2,
 repeat:40,
 yoyo:true,
 ease:Linear.easeNone
},'-=2.3')
.to(bigO, 1, {
 y:0,
 ease:Back.easeOut.config(1.5)
},'+=0')
.to(OArmLTempArr, 1, {
 endArray:OArmLDownArr,
 ease:Back.easeOut.config(1.5)
},'-=1')
.to(OArmRTempArr, 1, {
 endArray:OArmRDownArr,
 ease:Back.easeOut.config(1.5)
},'-=1')
.to('#oBg', 1, {
  attr:{
   x:8,
   y:0
  },
 ease:Back.easeOut.config(1.5)
 },'-=1')
.staggerTo([OLegL,OLegR], 1, {
 y:0,
 ease:Back.easeOut.config(1.5)
},0,'-=1')
.staggerTo([OLegL,OLegR], 4, {
 rotation:0,
 cycle:{
  duration:[4, 7]
 },
 ease:Elastic.easeOut.config(2, .75)
},0,'-=1')



var patternTl = new TimelineMax({repeat:-1,  yoyo:true })
patternTl.staggerTo('#oBg *', 0.4, {
 cycle:{
  fillOpacity:[1, 0]
 }, 
 ease:Linear.easeNone
},0)

//patternTl.duration(tl.duration());

mainTl.add(tl, 0);
mainTl.add(patternTl, 0)

function onUpdate(){
 OArmLDown.setAttribute('points', OArmLTempArr);
 OArmRDown.setAttribute('points', OArmRTempArr);
 //legR.setAttribute('points', legRDownArr);
 
}

//ScrubGSAPTimeline(tl);
            
          
!
999px
🕑 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.
Loading ..................

Console