@codesuma/baseline 1.0.12 → 1.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -3
- package/package.json +1 -1
- package/utils/ripple.ts +3 -1
package/README.md
CHANGED
|
@@ -586,11 +586,17 @@ card.style({ ...Y(-10) }) // transform: translateY(-10px);
|
|
|
586
586
|
|
|
587
587
|
### Ripple Effect
|
|
588
588
|
|
|
589
|
+
Enable the ripple effect globally in your main entry file:
|
|
590
|
+
|
|
589
591
|
```typescript
|
|
590
|
-
import {
|
|
592
|
+
import { initRipple, Button } from '@codesuma/baseline'
|
|
593
|
+
|
|
594
|
+
// Initialize once
|
|
595
|
+
initRipple()
|
|
591
596
|
|
|
592
|
-
|
|
593
|
-
|
|
597
|
+
// Usage
|
|
598
|
+
const btn = Button('Click me')
|
|
599
|
+
btn.attr('data-ripple', '') // Add ripple attribute
|
|
594
600
|
```
|
|
595
601
|
|
|
596
602
|
### Device Detection
|
package/package.json
CHANGED
package/utils/ripple.ts
CHANGED