Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Adds Material style ripple to anything

License

NotificationsYou must be signed in to change notification settings

jakiestfu/Ripple.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Adds Material style ripple to buttons

Installation

<linkhref="stylesheet"type="text/css"href="ripple.min.css"><scripttype="text/javascript"src="jquery.min.js"></script><scripttype="text/javascript"src="ripple.min.js"></script>

or

$ bower install ripplejs

Usage

Include jQuery, the ripple.css, and ripple.js into your page. Then upon initialization, you can activate ripple as follows:

$.ripple(".btn",{debug:false,// Turn Ripple.js logging on/offon:'mousedown',// The event to trigger a ripple effectopacity:0.4,// The opacity of the ripplecolor:"auto",// Set the background color. If set to "auto", it will use the text colormulti:false,// Allow multiple ripples per elementduration:0.7,// The duration of the ripple// Filter function for modifying the speed of the ripplerate:function(pxPerSecond){returnpxPerSecond;},easing:'linear'// The CSS3 easing function of the ripple});

Elements can be overridden with their own default options:

<ahref="#"data-duration="5"data-color="red"data-opacity="1">Slow Red Ripple</a>

Building

$ npm install$ npm run-script build$ npm run-script build-watch# To watch assets

Caveats

  • The element selected to contain a ripple will gain the following CSS properties:
    • position: relative
    • transform: translate3d(0,0,0)

License

MIT

About

Adds Material style ripple to anything

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors2

  •  
  •  

[8]ページ先頭

©2009-2025 Movatter.jp