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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ 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

              
                <svg version="1.1"
	 id="svg2" inkscape:version="0.91 r13725" sodipodi:docname="Domestic_Dromedary_silhouette.svg" xmlns:svg="http://www.w3.org/2000/svg" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
	 xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" 
	 viewBox="0 0 1578 1184"  xml:space="preserve">
<style type="text/css">
	.st0{stroke:#000000;stroke-miterlimit:10;}
	.st1{stroke:#CCCCCC; fill:none;}
</style>

<path id="circle-1" class="st1 path" d="M1202.67111,575.383626 C1220.43488,533.961303 1225.24704,492.57539 1219.11972,453.349798 C1213.14392,415.058726 1196.73773,378.788403 1171.73753,346.365392 C1147.27674,314.63417 1114.49467,286.49539 1074.94285,263.569293 C1036.05164,241.025501 990.390677,223.415249 939.184221,212.285958 C888.480798,201.271965 836.60767,197.546019 785.946672,200.1736 C735.334159,202.795112 685.49741,211.782287 638.903111,226.340177 C591.969414,241.013364 547.956953,261.475724 509.526352,287.023333 C470.51999,312.965383 436.980337,344.350712 411.85287,380.554283 C386.155701,417.577077 371.555588,456.323272 367.434344,494.84494 C363.210069,534.295061 369.979819,573.520653 387.119345,610.288578 C404.646753,647.899998 432.986367,682.835292 471.283632,712.545765 C510.320298,742.82666 559.472193,767.5065 617.509006,783.866679 C676.218551,800.421044 737.928119,806.738161 798.83162,803.867848 C859.801789,801.003603 919.329522,788.957996 973.742064,769.084262 C1027.66975,749.374373 1076.08225,722.14584 1115.62195,688.855061 C1154.48286,656.146839 1184.47097,617.825426 1202.67111,575.383626"/>
<path id="circle-1-active" class="st1" d="M1202.7,575.4c17.8-41.4,22.6-82.8,16.4-122c-6-38.3-22.4-74.6-47.4-107
						c-24.5-31.7-57.2-59.9-96.8-82.8c-38.9-22.5-95.9-93-147.1-104.1c-50.7-11-91.3,38.1-141.9,40.7c-50.6,2.6-100.4,11.6-147,26.2
						C592,241,548,261.5,509.5,287c-39,25.9-72.5,57.3-97.7,93.5c-25.7,37-40.3,75.8-44.4,114.3c-4.2,39.5,2.5,78.7,19.7,115.4
						c17.5,37.6,45.9,72.5,84.2,102.3c39,30.3,88.2,55,146.2,71.3c58.7,16.6,120.4,22.9,181.3,20c61-2.9,120.5-14.9,174.9-34.8
						c53.9-19.7,102.3-46.9,141.9-80.2C1154.5,656.1,1184.5,617.8,1202.7,575.4"/>
  
<path id="circle-2" class="st1 path" d="M1518,652.7c24.6-73.9,26.1-146.4,9.1-213.9c-16.4-64.8-49.9-125.1-96.8-178.2
						C1385,209.4,1327,164.7,1259,128.7c-66.1-35-153.5-114.8-237.7-131.5c-82.8-16.5-155.6,31-237.5,35.4
						C702,36.9,621.3,51,545.4,73.6c-76.8,22.9-149.8,54.8-214.6,94.9c-66.5,41.1-125.2,91.4-171.5,150.1
						c-48,60.9-78.3,125.7-91.2,191.1c-13.5,68.2-8.3,137.2,15.5,203c24.8,68.5,69.5,133.3,133.6,189.4
						c66.3,58,152.5,106.1,256.7,138.6c106.5,33.2,219.9,46.4,332.3,41.3c112.6-5,222.2-28.3,321.2-66.9
						c97.5-38,183.2-90.2,251.1-153.4C1444.3,800.5,1492.4,729.7,1518,652.7"/>
  
  <path id="circle-2-active" class="st1" d="M1518,652.7c24.6-73.9,26.1-146.4,9.1-213.9c-16.4-64.8-49.9-125.1-96.8-178.2
						C1385,209.4,1327,164.7,1259,128.7c-66.1-35-143.3-63-227.5-79.7c-82.8-16.5-165.8-20.8-247.7-16.4
						C702,36.9,621.3,51,545.4,73.6c-76.8,22.9-149.8,54.8-214.6,94.9c-66.5,41.1-125.2,91.4-171.5,150.1
						c-48,60.9-78.3,125.7-91.2,191.1c-13.5,68.2-8.3,137.2,15.5,203c24.8,68.5,69.5,133.3,133.6,189.4
						c66.3,58,152.5,106.1,256.7,138.6c106.5,33.2,219.9,46.4,332.3,41.3c112.6-5,222.2-28.3,321.2-66.9
						c97.5-38,183.2-90.2,251.1-153.4C1444.3,800.5,1492.4,729.7,1518,652.7"/>

</svg>

              
            
!

CSS

              
                body {
 margin:0;
 background: #333;
}
svg {
  display: block;
  margin: 20px auto;
  width:500px;
}

#circle-1-active, #circle-2-active, #star{
  visibility:hidden;
}

#slider {
  width:420px;
  margin:20px auto;
}
              
            
!

JS

              
                
var tl = new TimelineMax({onComplete:completeH}),
    circle1 = document.getElementById("circle-1"),
    circle2 = document.getElementById("circle-2"),
    outline = $(".path");

tl.fromTo(outline, 3, {drawSVG:"0%"}, {drawSVG:"100%"})
  .to(circle1, 0.5, {morphSVG:"#circle-1-active"}, 'start')
  .to(circle2, 0.5, {morphSVG:"#circle-2-active"}, 0)

  .add("back", 3.5)
  
  .to(circle1, 0.5, {morphSVG:"#circle-1", repeat:1, yoyo:true}, "back")
  .to(circle2, 0.5, {morphSVG:"#circle-2", repeat:1, yoyo:true}, "back")
  

function completeH(){
  tl.play("back")
}

              
            
!
999px

Console