Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

button-animation

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

button-animation - npm Package Compare versions

Comparing version 1.0.4 to 1.0.5

4

btnAnimation.js

@@ -1,2 +0,2 @@

export function buttonAnimation (e) {
export function buttonAnimation (e,color='#fff') {
const style = document.createElement('style')

@@ -7,3 +7,3 @@ style.innerHTML = '.buttonAnimation {' +

' width: 400px;' +
' background: #fff;' +
` background:${color};` +
' top: 0;' +

@@ -10,0 +10,0 @@ ' left: 0;' +

{
"name": "button-animation",
"version": "1.0.4",
"version": "1.0.5",
"description": "一个b站上学习到的按钮点击动画",

@@ -5,0 +5,0 @@ "main": "btnAnimation.js",

@@ -27,2 +27,12 @@ # 演示效果

4.波纹颜色默认为#333,接收第二个参数修改波纹颜色
```js
clickBtn(e) {
buttonAnimation(e, 'red')
//buttonAnimation(e,'#4e94fd');
//buttonAnimation(e,'linear-gradient(90deg, #025ce3, #4e94fd)');
},
```
# 示例 demo

@@ -29,0 +39,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc