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

              
                <?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 15.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0)  -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" id="type-writer" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px"
	 y="0px" width="295px" height="380px" viewBox="0 0 295 380" enable-background="new 0 0 295 380" xml:space="preserve">
<path fill="#353535" d="M26.676,97.369c0,0,2.745,2.421,2.745,10.317h-2.745V97.369z"/>
<path fill="#353535" d="M268.324,97.369c0,0-2.745,2.421-2.745,10.317h2.745V97.369z"/>
<rect id="bg2" x="26.676" y="107.686" fill="#444444" width="252.344" height="30.691"/>
<g id="paper">
	<g>
		<linearGradient id="paper_1_" gradientUnits="userSpaceOnUse" x1="146.4551" y1="217.3887" x2="146.4551" y2="122.72">
			<stop  offset="0" style="stop-color:#FFFFFF"/>
			<stop  offset="1" style="stop-color:#ebebeb"/>
		</linearGradient>
		<path fill="url(#paper_1_)" d="M254.817,119.055H37.79c-7.496,16.316-10.967,45.144-12.506,72.279v66.098h242.342
			V197.16C266.265,168.412,262.854,136.546,254.817,119.055z"/>
	</g>
	<g>
	<path id="heart" fill="#F3987F" d="M157.646,156.068c-4.483,0-8.496,2.011-11.191,5.179c-2.694-3.167-6.707-5.179-11.191-5.179
		c-8.113,0-14.689,6.577-14.689,14.689c0,1.063,0.116,2.099,0.33,3.097c2.258,12.333,25.551,33.041,25.551,33.041
		s23.293-20.708,25.551-33.041c0.215-0.999,0.33-2.034,0.33-3.097C172.336,162.645,165.759,156.068,157.646,156.068z"/>
	</g>
</g>
<g id="print-bar">
	<polygon fill="#DCDBD3" points="57.741,123.571 57.741,140.477 59.796,140.477 59.796,129.482 63.908,129.482 63.908,140.477 
		65.964,140.477 65.964,123.571 	"/>
	<rect x="43.184" y="116.021" fill="#222223" width="37.339" height="12.002"/>
	<polygon fill="#E5E5D8" points="56.519,121.355 56.519,140.692 59.185,140.692 59.185,129.023 64.52,129.023 64.52,140.692 
		67.187,140.692 67.187,121.355 	"/>
	<polygon fill="#353535" points="80.523,116.021 43.184,116.021 44.184,113.688 79.523,113.688 	"/>
</g>
<g id="bg1">
	<path fill="#2D2D2D" d="M26.676,138.376c-2.9,0-5.251-9.18-5.251-20.504s2.351-20.503,5.251-20.503V138.376z"/>
	<g>
		<path fill="#2D2D2D" d="M268.324,97.369c2.9,0,5.252,9.18,5.252,20.503s-2.352,20.504-5.252,20.504V97.369z"/>
		<path fill="#444444" d="M273.576,117.872c0-11.324-2.352-20.503-5.252-20.503h21.705v0.232c2.543,1.425,4.5,9.945,4.5,20.271
			c0,10.325-1.957,18.844-4.5,20.271v0.232h-21.705C271.225,138.375,273.576,129.195,273.576,117.872z"/>
	</g>
	<path fill="#444444" d="M21.425,117.872c0-11.324,2.351-20.503,5.251-20.503H4.971v0.232c-2.543,1.426-4.5,9.946-4.5,20.271
		c0,10.325,1.957,18.844,4.5,20.271v0.233h21.706C23.776,138.376,21.425,129.195,21.425,117.872z"/>
	<g>
		<g>
			<g>
				<g>
					<path fill="#324D63" d="M71.854,376.998c-4.137,0-7.501-3.365-7.501-7.501v-11.223c0-5.986-2.354-14.732-5.359-19.907
						l-47.818-82.368c-0.44-0.759-0.712-1.475-0.808-2.104l273.712,0.001c-0.099,0.628-0.369,1.346-0.81,2.104l-47.819,82.368
						c-3.007,5.18-5.359,13.923-5.359,19.905v11.224c0,4.136-3.365,7.501-7.502,7.501L71.854,376.998L71.854,376.998z"/>
					<polygon fill="#324D63" points="289.371,138.376 4.971,138.376 7.971,226.451 286.371,226.451 					"/>
					<path fill="#273D51" d="M286.371,250.895c0,0-2.086-1.523-2.086-12.223c0-10.697,2.086-12.223,2.086-12.223H7.971
						c0,0,2.084,1.523,2.084,12.223c0,10.697-2.084,12.223-2.084,12.223H286.371z"/>
					<path fill="#324D63" d="M107.013,135.375c0,16.718,17.363,30.271,38.782,30.271c21.42,0,38.783-13.552,38.783-30.271"/>
					<path fill="#273D51" d="M192.956,138.376c0,20.609-21.407,37.319-47.815,37.319c-26.407,0-47.814-16.709-47.814-37.319
						l9.687-3.001c0,16.718,17.363,30.271,38.782,30.271c21.42,0,38.783-13.552,38.783-30.271L192.956,138.376z"/>
				</g>
				<circle fill="#273D51" cx="61.279" cy="182.413" r="34.602"/>
				<circle fill="#273D51" cx="227.559" cy="182.413" r="34.602"/>
			</g>
			<path fill="#262626" d="M230.486,143.81l0.799,4.012c16.018,0.458,28.915,14.634,28.915,31.995
				c0,10.048-4.256,19.32-11.675,25.434c-0.194,0.162-17.853,14.639-41.223,14.639c-20.461,0-39.135-10.838-55.521-32.217h-0.002
				c-1.557-2.066-4.324-3.445-7.493-3.445l-0.019,4.301l-0.02-4.301c-3.167,0-5.937,1.379-7.494,3.445h-0.001
				c-16.388,21.379-35.061,32.217-55.522,32.217c-23.37,0-41.028-14.477-41.222-14.639c-7.419-6.112-11.675-15.385-11.675-25.434
				c0-17.36,12.898-31.537,28.916-31.995l0.799-4.012c-18.461,0-33.429,16.121-33.429,36.007c0,11.664,5.149,22.033,13.132,28.613
				c0,0,18.459,15.459,43.479,15.459c16.594,0,36.071-6.809,54.974-29.419c0.989-1.169,3.669-5.835,8.062-5.836
				c4.391,0.001,7.071,4.667,8.061,5.836c18.904,22.61,38.381,29.419,54.975,29.419c25.021,0,43.479-15.459,43.479-15.459
				c7.982-6.58,13.134-16.949,13.134-28.613C263.914,159.931,248.948,143.81,230.486,143.81z"/>
			<circle fill="#E5E5D8" cx="144.268" cy="194.135" r="5.292"/>
		</g>
		<path fill="#355170" d="M7.971,250.895c-1.036,1.801-0.82,4.146,0.609,6.608l47.819,82.369c2.731,4.706,4.954,12.961,4.954,18.4
			v11.224c0,5.79,4.711,10.502,10.502,10.502H222.59c5.791,0,10.502-4.71,10.502-10.502v-11.222c0-5.439,2.225-13.692,4.955-18.399
			l47.818-82.37c1.43-2.462,1.646-4.81,0.609-6.608L7.971,250.895z"/>
	</g>
</g>
<g id="ink-tape-left">
	<circle fill="#E5E5D8" cx="61.279" cy="178.412" r="34.602"/>
	<g>
		<path fill="#ADD4A4" d="M61.279,151.378c-13.21,0-24.202,9.479-26.56,22.004l-5.076,1v7.03l4.898,1
			c1.933,13.033,13.166,23.033,26.737,23.033c14.931,0,27.035-12.103,27.035-27.033S76.209,151.378,61.279,151.378z"/>
		<circle fill="#97B790" cx="61.277" cy="178.412" r="7.031"/>
	</g>
</g>
<g id="ink-tape-right">
	<circle fill="#E5E5D8" cx="227.559" cy="178.412" r="34.602"/>
	<g>
		<path fill="#ADD4A4" d="M227.869,151.378c-13.209,0-24.2,9.479-26.56,22.004l-5.075,1v7.03l4.897,1
			c1.935,13.033,13.166,23.033,26.736,23.033c14.932,0,27.034-12.103,27.034-27.033
			C254.906,163.481,242.803,151.378,227.869,151.378z"/>
		<circle fill="#97B790" cx="227.557" cy="178.412" r="7.031"/>
	</g>
</g>
<circle id="key_1" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="45.591" cy="272.039" r="9.17"/>
<circle id="key_2" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="71.023" cy="272.039" r="9.17"/>
<circle id="key_3" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="96.455" cy="272.039" r="9.17"/>
<circle id="key_4" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="121.887" cy="272.039" r="9.17"/>
<circle id="key_5" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="146.854" cy="272.039" r="9.17"/>
<circle id="key_6" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="171.762" cy="272.039" r="9.17"/>
<circle id="key_7" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="197.193" cy="272.039" r="9.17"/>
<circle id="key_8" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="222.627" cy="272.039" r="9.17"/>
<circle id="key_9" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="248.059" cy="272.039" r="9.168"/>
<circle id="key_10" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="58.278" cy="294.06" r="9.169"/>
<circle id="key_11" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="83.709" cy="294.06" r="9.169"/>
<circle id="key_12" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="109.142" cy="294.06" r="9.169"/>
<circle id="key_13" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="134.167" cy="294.06" r="9.169"/>
<circle id="key_14" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="159.6" cy="294.06" r="9.169"/>
<circle id="key_15" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="184.449" cy="294.06" r="9.169"/>
<circle id="key_16" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="209.883" cy="294.06" r="9.169"/>
<circle id="key_17" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="235.314" cy="294.06" r="9.169"/>
<circle id="key_18" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="70.965" cy="316.082" r="9.169"/>
<circle id="key_19" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="96.398" cy="316.082" r="9.169"/>
<circle id="key_20" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="121.421" cy="316.082" r="9.169"/>
<circle id="key_21" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="146.854" cy="316.082" r="9.169"/>
<circle id="key_22" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="172.287" cy="316.082" r="9.169"/>
<circle id="key_23" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="197.136" cy="316.082" r="9.169"/>
<circle id="key_24" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="222.57" cy="316.082" r="9.169"/>
<circle id="key_25" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="83.709" cy="338.102" r="9.17"/>
<circle id="key_26" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="108.676" cy="338.103" r="9.17"/>
<circle id="key_27" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="134.108" cy="338.103" r="9.17"/>
<circle id="key_28" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="159.541" cy="338.103" r="9.17"/>
<circle id="key_29" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="184.974" cy="338.103" r="9.17"/>
<circle id="key_30" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" cx="209.883" cy="338.102" r="9.17"/>
<path id="key_0" fill="#F2F0D7" stroke="#92928D" stroke-miterlimit="10" d="M219.052,368.128c0,1.655-1.343,3-3.001,3H77.541
	c-1.657,0-3-1.345-3-3v-9.438c0-1.658,1.343-3.001,3-3.001h138.51c1.658,0,3.001,1.343,3.001,3.001V368.128L219.052,368.128z"/>
</svg>


































































<!--# Credits--><a style="font-size:1px!important; pointer-events:none; visibility: hidden; display:block; width:0; overflow:hidden; position:absolute; bottom:0; left:0; z-index:-9999; color:rgba(255,255,255,0)!important;" title="Acro Design (Acronamy) Performing magic tricks with Websites, S.E.O and Graphics for Local businesses in Bristol, Bath and the surrounding areas." href="https://www.facebook.com/Acronamy.design/">Acro Design (Acronamy) Facebook</a><a style="font-size:1px!important; pointer-events:none; visibility: hidden; display:block; width:0; overflow:hidden; position:absolute; bottom:0; left:0; z-index:-9999; color:rgba(255,255,255,0)!important;" title="Acro Design (Acronamy) Performing magic tricks with Websites, S.E.O and Graphics for Local businesses in Bristol, Bath and the surrounding areas." href="https://twitter.com/Acronamy_design">Acro Design (Acronamy) Twitter</a><a style="font-size:1px!important; pointer-events:none; visibility: hidden; display:block; width:0; overflow:hidden; position:absolute; bottom:0; left:0; z-index:-9999; color:rgba(255,255,255,0)!important;" title="Acro Design (Acronamy) Performing magic tricks with Websites, S.E.O and Graphics for Local businesses in Bristol, Bath and the surrounding areas." href="http://www.acronamy.com">Acro Design (Acronamy) Performing magic tricks with Websites, S.E.O and Graphics for Local businesses in Bristol, Bath and the surrounding areas.</a>
              
            
!

CSS

              
                body
  background lighten(red, 20)

#type-writer
  width 100%

#heart
  opacity 0
              
            
!

JS

              
                el = {
  svg: "#type-writer",
  inkR: "#ink-tape-right",
  inkL: "#ink-tape-left",
  keys: "[id^='key_']",
  paper: "#paper",
  printBar: "#print-bar",
  spaceBar: "#key_0",
  heart: "#heart",
}

//printBar
TweenMax.to(el.printBar, 1, {
	x:70,
});
//ink wheel
TweenMax.to(el.inkR +","+ el.inkL, 1.1, {
	transformOrigin:"center",
	rotation:360,
  repeat:1,
  onRepeat:paperFull,
});
//keys
TweenMax.to(el.spaceBar, 1, {
	scale:.96,
  transformOrigin:"center",
});
//paper
TweenMax.to(el.paper, 1, {
	y:-50,
});

function paperFull(){
 TweenMax.to(el.paper, 1, {
  	y:-100,
	});
  TweenMax.to(el.printBar, .5, {
		x:70,
    scale:-3
	});
  TweenMax.to(el.heart, .5, {
		opacity:1
	});
  TweenMax.to(el.printBar, .5, {
    scale:1
	});
  TweenMax.to(el.printBar, 1, {
		x:160,
	});
}
              
            
!
999px

Console