Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

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

              
                <link href="https://fonts.googleapis.com/css?family=Work+Sans:500,700" rel="stylesheet">
<div class="row">
<div class="container">
<svg id="Dermira_tricks_svg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 1460 625">
	
<rect id="stage" width="1460" height="625" fill="none" opacity="0"/>
<image id="ribbon" width="1353" height="277" transform="translate(36 154)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/ribbon4.png"/>
<image id="drop1" width="29" height="34" transform="translate(1299.26 275) scale(0.71)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/splash1.png"/>
<image id="drop2" width="42" height="52" transform="translate(1323.46 278.57) scale(0.69)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/splash2.png"/>
<image id="drop3" width="24" height="26" transform="translate(1342.77 266) scale(0.77)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/splash3.png"/>
<image id="drop4" width="61" height="55" transform="translate(1354 251.1) scale(0.69)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/splash4.png"/>
<image id="drop5" width="47" height="39" transform="translate(1357 214) scale(0.68)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/splash5.png"/>
<image id="theBlackout_guy" width="425" height="550" transform="translate(321 37.65) scale(0.9)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/blackout_guy3.png"/>
<image id="theLockdown_girl" width="329" height="600" transform="translate(396.31 41.63) rotate(-1.06) scale(0.85)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/lockdown_girl2.png"/>
<image id="theUnderHug_couple" width="308" height="500" transform="translate(369.92 73.3) rotate(-0.51) scale(0.94)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/underhug_couple2.png"/>
<image id="theBlackout_txt" width="554" height="108" transform="translate(782 189)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/the_Blackout_txt.png"/>
<image id="theLockdown_txt" width="566" height="109" transform="translate(779 190)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/the_Lockdown_txt.png"/>
<image id="theUnderhug_txt" width="567" height="108" transform="translate(776 189)" xlink:href="https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/the_Underhug_txt.png"/>
</svg>
</div>
</div>



              
            
!

CSS

              
                .row {
  width: 100%;
}

.container {
  margin: 0px auto;
  max-width: 1200px;
  width: 100%;
  padding: 0px 0px;
  text-align: center;
  background-color:#C8C8C8;
/*   background-image:url("https://s3-us-west-2.amazonaws.com/s.cdpn.io/259100/fpo_underhug.jpg");
  background-size:1460px 625px; */
  
}

#theLockdown_txt, #theBlackout_txt, #theUnderhug_txt, #theUnderHug_couple, #theLockdown_girl, #theBlackout_guy {
  visibility:hidden;
}


              
            
!

JS

              
                TweenLite.set(theLockdown_txt, {scale:.67, y:350, x:800, transformOrigin:"50% 50%"});
TweenLite.set(theBlackout_txt, {scale:.67, y:52, x:800, transformOrigin:"50% 50%"});
TweenLite.set(theUnderhug_txt, {scale:.67, y:350, x:800, transformOrigin:"50% 50%"});
TweenLite.set(ribbon, {y:154, x:36});

TweenLite.set([theUnderHug_couple, theLockdown_girl, theBlackout_guy, theUnderhug_txt], {visibility:'visible'});
// 
tlintro = new TimelineMax({});
tlintro
.to(theUnderhug_txt, 1, {scale:1.1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "intro")
.from(theUnderhug_txt, .3, {opacity:0, transformOrigin:"50% 50%", ease:Power0.easeNone}, "intro")
.to(theUnderhug_txt, 1, {y:190, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "intro+=.2")
.to(theUnderhug_txt, .5, {x:778, scale:.98, transformOrigin:"50% 50%", onComplete:function () {tlsplash.play(0);}, ease:Power1.easeOut}, "intro+=1")
.to(theUnderhug_txt, .5, {scale:1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "intro+=1.5")
.to(ribbon, .4, {scale:.98, ease:Sine.easeInOut, transformOrigin:"70% 50%", yoyo:true, repeat:1}, "intro+=1.2")
.from([theLockdown_txt, theBlackout_txt], .5, {autoAlpha:0, onStart:function () {tlcouple.play(0);}, ease:Power0.easeNone}, "intro+=.5")
//
.from([drop1, drop2, drop3, drop4, drop5], .2, {autoAlpha:0, ease:Power0.easeNone}, "intro")
.from(drop1, 1, {x:"+=5", y:"-=60", rotation:-40, transformOrigin:"80% 0%", ease:Sine.easeOut}, "intro")
.from(drop2, .7, {x:"-=1", y:"-=45", rotation:2, scale:.2, transformOrigin:"40% 0%", ease:Sine.easeOut}, "intro")
.from(drop3, .5, {x:"-=4", y:"-=15", scale:0, transformOrigin:"15% 0%", ease:Sine.easeOut}, "intro")
.from(drop4, .8, {x:"-=15", y:"-=10", rotation:8, scale:.3, transformOrigin:"15% 0%", ease:Sine.easeOut}, "intro")
.from(drop5, .6, {x:"-=4", rotation:45, scale:0, transformOrigin:"0% 90%", ease:Sine.easeOut}, "intro")
; 
// tlintro.timeScale(1.1);
//
tlcouple = new TimelineMax({paused:true});
tlcouple
// couple in
.from(theUnderHug_couple, 1, {y:550, transformOrigin:"center", ease:Expo.easeOut}, "couple")
.from(theUnderHug_couple, .3, {opacity:0, transformOrigin:"center", ease:Power0.easeNone}, "couple")
// couple out
.to(theUnderHug_couple, .3, {y:50, ease:Sine.easeIn}, "couple+=3.4")
.to(theUnderHug_couple, .3, {opacity:0, ease:Power0.easeNone}, "couple+=3.4")
; 
tlgirl = new TimelineMax({paused:true});
tlgirl
// girls in
.from(theLockdown_girl, 1, {y:550, transformOrigin:"center", ease:Expo.easeOut}, "girl")
.from(theLockdown_girl, .3, {opacity:0, transformOrigin:"center", ease:Power0.easeNone}, "girl")
// // girls out
.to(theLockdown_girl, .3, {y:0, ease:Sine.easeIn}, "girl+=3.6")
.to(theLockdown_girl, .3, {opacity:0, ease:Power0.easeNone}, "girl+=3.6")
; 
tlguy = new TimelineMax({paused:true});
tlguy
// // guy in
.from(theBlackout_guy, 1, {y:580, transformOrigin:"center", ease:Expo.easeOut}, "guy")
.from(theBlackout_guy, .3, {opacity:0, transformOrigin:"center", ease:Power0.easeNone}, "guy")
// // guy out
.to(theBlackout_guy, .3, {y:20, ease:Sine.easeIn}, "guy+=3.6")
.to(theBlackout_guy, .3, {opacity:0, ease:Power0.easeNone}, "guy+=3.6")
; 
//
tlwords = new TimelineMax({repeat:-1, repeatDelay:3});
tlwords
// Underhug_txt to top position
.to(theUnderhug_txt, .5, {scale:.67, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=.2")
.to(theUnderhug_txt, .5, {y:52, transformOrigin:"50% 50%", ease:Power2.easeOut}, "words")
.to(theUnderhug_txt, .5, {x:800, transformOrigin:"50% 50%", ease:Sine.easeOut}, "words")
// Blackout_txt to bottom position
.to(theBlackout_txt, .2, {opacity:0, scale:.6, ease:Power0.easeNone}, "words")
.to(theBlackout_txt, .6, {y:350, ease:Expo.easeInOut}, "words")
.to(theBlackout_txt, .4, {opacity:1, scale:.67, ease:Power1.easeOut, onStart:function () {
      tlgirl.play(0);}, ease:Power0.easeNone}, "words+=.3")
// Lockdown_txt to middle position
.to(theLockdown_txt, .6, {scale:1.1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words")
.to(theLockdown_txt, .6, {y:190, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=.2")
.to(theLockdown_txt, .5, {x:778, scale:.98, transformOrigin:"50% 50%", onComplete:function () {
      tlsplash.play(0);}}, "words+=.6")
.to(theLockdown_txt, .5, {scale:1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=1.1")
.to(ribbon, .4, {scale:.98, ease:Sine.easeInOut, transformOrigin:"70% 50%", yoyo:true, repeat:1}, "words+=.8")
// Lockdown_txt to top position
.to(theLockdown_txt, .5, {scale:.67, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=5.2")
.to(theLockdown_txt, .5, {y:52, transformOrigin:"50% 50%", ease:Power2.easeOut}, "words+=5")
.to(theLockdown_txt, .5, {x:800, transformOrigin:"50% 50%", ease:Sine.easeOut}, "words+=5")
// Underhug_txt to bottom position
.to(theUnderhug_txt, .2, {opacity:0, scale:.6, ease:Power0.easeNone}, "words+=5")
.to(theUnderhug_txt, .6, {y:350, ease:Expo.easeInOut}, "words+=5")
.to(theUnderhug_txt, .4, {opacity:1, scale:.67, onStart:function () {
      tlguy.play(0);}, ease:Power0.easeNone}, "words+=5.3")
// to middle position
.to(theBlackout_txt, .6, {scale:1.1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=5")
.to(theBlackout_txt, .6, {y:190, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=5.2")
.to(theBlackout_txt, .5, {x:778, scale:.98, transformOrigin:"50% 50%", onComplete:function () {
      tlsplash.play(0);}, ease:Power1.easeOut}, "words+=5.6")
.to(theBlackout_txt, .5, {scale:1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=6.1")
.to(ribbon, .4, {scale:.98, ease:Sine.easeInOut, transformOrigin:"70% 50%", yoyo:true, repeat:1}, "words+=5.8")
// to middle position
.to(theUnderhug_txt, .6, {scale:1.1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=10")
.to(theUnderhug_txt, .6, {y:190, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=10.2")
.to(theUnderhug_txt, .5, {x:778, scale:.98, transformOrigin:"50% 50%", onComplete:function () {
      tlsplash.play(0);}, ease:Power1.easeOut}, "words+=10.6")
.to(theUnderhug_txt, .5, {scale:1, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=11.1")
.to(ribbon, .4, {scale:.98, ease:Sine.easeInOut, transformOrigin:"70% 50%", yoyo:true, repeat:1}, "words+=10.8")
// theBlackout to top position
.to(theBlackout_txt, .5, {scale:.67, transformOrigin:"50% 50%", ease:Sine.easeInOut}, "words+=10.2")
.to(theBlackout_txt, .5, {y:52, transformOrigin:"50% 50%", ease:Power2.easeOut}, "words+=10")
.to(theBlackout_txt, .5, {x:800, transformOrigin:"50% 50%", ease:Sine.easeOut}, "words+=10")
// theLockdown_txt to bottom position
.to(theLockdown_txt, .2, {opacity:0, scale:.6, ease:Power0.easeNone}, "words+=10")
.to(theLockdown_txt, .6, {y:350, ease:Expo.easeInOut}, "words+=10")
.to(theLockdown_txt, .4, {opacity:1, scale:.67, onStart:function () {
        tlcouple.play(0);}, ease:Power0.easeNone}, "words+=10.3")

;
//
tlsplash = new TimelineMax({paused:true});
tlsplash
.to(drop1, .4, {x:"-=3", y:"+=3", rotation:-10, transformOrigin:"80% 0%", ease:Power1.easeOut, yoyo:true, repeat:1}, "splash")
.to(drop2, .3, {y:"+=3", rotation:2, transformOrigin:"40% 0%", ease:Power1.easeOut, yoyo:true, repeat:1}, "splash+=.2")
.to(drop3, .5, {x:"+=1", y:"+=5", rotation:-15, transformOrigin:"15% 0%", ease:Power1.easeOut, yoyo:true, repeat:1}, "splash+=.2")
.to(drop4, .3, {x:"+=2", y:"+=1", transformOrigin:"15% 0%", ease:Power1.easeOut, yoyo:true, repeat:1}, "splash")
.to(drop5, .4, {x:"+=4", rotation:5, transformOrigin:"0% 90%", ease:Sine.easeOut, yoyo:true, repeat:1}, "splash")
; 
// //SUPREME TIMELINE delays
			var supremeTL = new TimelineMax({paused:false});
			    supremeTL.add(tlintro, .3) .add(tlwords, 5.2);  
supremeTL.timeScale(1.3);


              
            
!
999px

Console