cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

Quick-add: + add another resource

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.

              body {
  background: #fff;

.clicky {
    position: relative;
    width: 310px;
    cursor: pointer;
    background: #E8EAF6;
    top: 20px;
    position: relative;
    font-family: arial;
    margin: 0 auto;
    text-align: center;
    padding: 20px 0;
    box-shadow: 0px 0px 20px -3px #5C6BC0;
              // https://github.com/Ardethian/yet-another-ripple-plugin

$.fn.yarp = function(options) {
    var options = options || {};

    this.options = {
        colors: ['gray'],       // Array. Colors to be used randomly
        duration: 750           // Integer. Duration of the ripple animation

    this.options = $.extend({}, this.options, options);

    $(this).each(function(i, e) {

        // No overflow for the selected set of elements
            overflow: 'hidden'

        $(e).on('click', function(ev) {
            // Create the ripple element
            var ripple = $('<div></div>').appendTo($(e));

            // Set some initial CSS
                width: 1,
                height: 1,
                borderRadius: '50%',
                opacity: 1,
                background: this.options.colors[Math.floor(Math.random() * this.options.colors.length) + 0],
                top: ev.clientY - ($(e).offset().top - $(window).scrollTop()),
                left: ev.clientX - ($(e).offset().left - $(window).scrollLeft()),
                position: 'absolute'

            // Additional CSS to be set at the end of the browser's execution queue
            setTimeout(function() {
                    transform: 'scale(1000)',
                    opacity: 0,
                    transition: 'all ' + this.options.duration + 'ms linear'
            }.bind(this), 0);

            // Remove ripple after it finished animating
            setTimeout(function() {
            }, this.options.duration);


  colors: ['#5C6BC0'],
  duration: 750
Loading ..................