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

              
                <div class="news blue">
	<span>Square Wallet</span>
	<ul>
		<li><a href="#">Need to accept payments on the go</li>
		<li><a href="#">Square wallet to accept payments</a></li>
		<li><a href="#">Take your business anywhere</a></li>
		<li><a href="#">What are you waiting for?</a></li>
	</ul>
</div>
              
            
!

CSS

              
                @import url(https://fonts.googleapis.com/css?family=Lato);

@keyframes ticker {
	0%   {margin-top: 0}
	25%  {margin-top: -30px}
	50%  {margin-top: -60px}
	75%  {margin-top: -90px}
	100% {margin-top: 0}
}



.news {
	background: #222;
  box-shadow: inset 0 -15px 30px rgba(0,0,0,0.4),
                    0 5px 10px rgba(0,0,0,0.5);
	width: 320px;
	height: 30px;
  /* PRESENTATIONAL PURPOSES */
  position: absolute; 
  left: 0; right: 0;
  top: 0; bottom: 190px; 
  margin: auto;
  /**/
	overflow: hidden;
	border-radius: 4px;
	padding: 3px
} 

.news span {
	float: left;
	color: #fff;
	padding: 6px;
	position: relative;
  top: 4%;
	border-radius: 4px;
  box-shadow: inset 0 -15px 30px rgba(0,0,0,0.4);
  font: 13px 'Lato', Helvetica, Arial, sans-serif;
	background: #333;
  cursor: pointer
}

.news ul {
	float: left;
	padding-left: 100px;
  animation: ticker 6s ease infinite;
}

.news ul li {line-height: 30px}

.news ul li a {
	color: #fff;
	text-decoration: none;
  font: 14px 'Lato', Helvetica, Arial, sans-serif;
}

.news ul:hover { animation-play-state: paused }
.news span:hover+ul { animation-play-state: paused }

/* OTHER COLORS */
.blue { background: #347fd0 }
.blue span { background: #2c66be }
.red { background: #d23435 }
.red span { background: #c22b2c }
              
            
!

JS

              
                //PURE CSS3 NEWS TICKER - ONLY 63 LINES CSS

/* BROWSER COMPATILITY
--INTERNET EXPLORER 10+
--GOOGLE CHROME
--MOZILLA FIREFOX
--OPERA [NOT TESTED - SHOULD WORK]
--SAFARI
*/

/* SOME OF MY OTHER STUFF
Animations and Effects - https://codepen.io/collection/HduGy
Tabs and Sliders - https://codepen.io/collection/uJmDh
*/
              
            
!
999px

Console