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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <div class="nicescroll-box demo-box">
	<div class="wrap">
		<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus fermentum risus et aliquam facilisis. In hac habitasse platea dictumst. Donec eget sagittis ligula, nec volutpat orci. Nulla facilisi. Suspendisse eget arcu non velit mollis feugiat eu eu dui. Mauris fermentum purus ac purus maximus convallis. Maecenas sed arcu id orci pretium aliquet ut vel velit. Sed suscipit, mauris ut faucibus volutpat, eros nibh venenatis lectus, ac tempor turpis massa quis velit. Suspendisse potenti. Quisque ullamcorper dolor feugiat suscipit suscipit.
</p>
<p>
Nam tincidunt nisi quis diam condimentum, ac rutrum lacus mattis. Nunc laoreet, arcu nec convallis ultricies, risus felis dignissim lacus, in faucibus enim justo egestas mauris. Nulla eu mattis nisl. Aenean eget imperdiet velit. Nulla facilisi. Nam ultricies tellus quis arcu euismod semper. Nam non lectus tincidunt odio ullamcorper posuere. Nunc aliquam, mi nec malesuada elementum, lorem ante porttitor metus, a dignissim nulla erat quis augue. Praesent rutrum, justo vitae vulputate hendrerit, purus diam convallis erat, in congue dui dui a eros.
</p>
<p>
Etiam ut turpis vel metus dapibus hendrerit. Curabitur dictum fringilla turpis eu feugiat. Proin malesuada dictum arcu, sed mollis mi iaculis ut. Cras ac elit at metus pellentesque euismod. Curabitur aliquam metus imperdiet dui aliquam malesuada. In suscipit quam vel leo rutrum pulvinar. Aenean libero lacus, tincidunt at tellus ut, ultrices pretium eros. Duis vestibulum mi id eros condimentum mattis.
</p>
<p>
In quis dolor at lorem mattis elementum in eu ligula. Aliquam posuere risus a nunc iaculis, eu iaculis lorem consectetur. Etiam vel mi eget purus gravida sodales sed eu nisl. Donec dui sem, auctor ut porta auctor, efficitur a nunc. Ut laoreet neque enim, a porta enim lacinia vitae. Nunc leo ipsum, consectetur eget vehicula vel, tempor id lacus. Curabitur id ipsum id tellus aliquam suscipit vel in felis. Vestibulum varius nibh tincidunt, mattis magna et, egestas augue. Mauris diam ante, iaculis non feugiat malesuada, imperdiet quis augue. Nam imperdiet nunc et condimentum congue. Aliquam bibendum faucibus est, ut egestas nunc accumsan eu. Nam condimentum dignissim metus, in sollicitudin risus ullamcorper eu. In in fringilla leo.
</p>
<p>
Sed in neque arcu. Maecenas vulputate condimentum neque eget hendrerit. Suspendisse id neque id dui sodales cursus vel vel libero. Pellentesque sed dui laoreet, hendrerit urna non, vulputate sapien. Mauris convallis viverra ante et rutrum. Vivamus sagittis pharetra nisi, id ornare nunc mattis nec. In non venenatis sem. Maecenas et pulvinar purus, ac finibus tellus. In vel nulla ut quam dapibus mollis. Etiam id neque libero. Mauris placerat mauris vitae augue volutpat laoreet. In sit amet urna elit. Phasellus tincidunt dolor leo, ac vulputate eros maximus quis. Phasellus efficitur odio id ligula tristique, vel rutrum ante ultricies.
</p>
	</div>
</div>
            
          
!
            
              .nicescroll-rails-vr {
	border: 1px solid #9c27b0;
	.nicescroll-cursors {
		margin: 3px 0;
	}
}

// For Demo Purpose only
.demo-box {
	min-width: 300px;
	max-width: 90%;
	margin: 0 auto;
	p {
		font-size: 1.5rem;
	}
}

            
          
!
            
              $("body").niceScroll({
	cursorcolor: "#9C27B0",
	cursorwidth: "5px", 
	cursorborder: "none",
	cursorborderradius: "5px",
	autohidemode: false,
	railpadding: { top: 0, right: 3, left: 3, bottom: 0 }
});

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

Console