# @detachhead/smui-ripple

> Svelte Material UI - Ripple

Latest version **7.0.0-beta.0-7aa154b58dd17d39757ade237397a003da4f0bdc** (published 2022-11-25) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @detachhead/smui-ripple
pnpm add @detachhead/smui-ripple
yarn add @detachhead/smui-ripple
bun add @detachhead/smui-ripple
```

## Health

**Score 40/100 (D)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 7.0.0-beta.0-7aa154b58dd17d39757ade237397a003da4f0bdc |
| Published | 2022-11-25 |
| First published | 2022-11-23 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 4 |
| Unpacked size | 64.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3444 |
| Author | Hunter Perrin |
| Maintainers | detachhead |
| Keywords | svelte, svelte3, material-ui, material-design, material, svelte-components, sveltejs |

## Links

- npm: https://www.npmjs.com/package/@detachhead/smui-ripple
- Repository: https://github.com/hperrin/svelte-material-ui
- Homepage: https://github.com/hperrin/svelte-material-ui#readme
- Issues: https://github.com/hperrin/svelte-material-ui/issues
- npm.io page: https://npm.io/package/@detachhead/smui-ripple

## Dependencies (4)

- [svelte2tsx](https://npm.io/package/svelte2tsx.md) ^0.5.12
- [@material/dom](https://npm.io/package/@material/dom.md) ^14.0.0
- [@material/ripple](https://npm.io/package/@material/ripple.md) ^14.0.0
- [@detachhead/smui-common](https://npm.io/package/@detachhead/smui-common.md) ^7.0.0-beta.0

## Alternatives

- [@progress/kendo-ooxml](https://npm.io/package/@progress/kendo-ooxml.md) — 152.1K weekly downloads
- [@progress/kendo-react-ripple](https://npm.io/package/@progress/kendo-react-ripple.md) — 8.0K weekly downloads
- [@progress/kendo-react-orgchart](https://npm.io/package/@progress/kendo-react-orgchart.md) — 4.3K weekly downloads
- [@praxisui/dynamic-fields](https://npm.io/package/@praxisui/dynamic-fields.md) — 2.4K weekly downloads
- [@progress/kendo-vue-listbox](https://npm.io/package/@progress/kendo-vue-listbox.md) — 932 weekly downloads

## Recent versions

- 7.0.0-beta.0-7aa154b58dd17d39757ade237397a003da4f0bdc (latest) — 2022-11-25
- 7.0.0-alpha.0 (canary) — 2022-11-23
- 7.0.0-beta.0-bde6dbb20b13d0f01bfbfb6daf901b112a786afe — 2022-11-23
- 7.0.0-beta.0-da72427f50f3b64dca46e0a9d9504524848cfb0e — 2022-11-23

## README

# Svelte Material UI - Ripple

Ripples are an interaction feedback mechanism.

# Installation

```sh
npm install --save-dev @smui/ripple
```

# Examples and Usage Information

https://sveltematerialui.com/demo/ripple

# Exports

## (default)

A ripple Svelte action.

### Props / Defaults

The action accepts an array, with two entries. The first is a boolean, whether the ripple is enabled. The second is an object with the props:

- `ripple`: `true` - Whether to enable the ripple.
- `surface`: `false` - Whether the ripple surface classes should be added.
- `unbounded`: `false` - Whether the ripple is unbounded.
- `disabled`: `false` - Whether the node is disabled.
- `color`: `undefined` - The ripple color. ('surface', 'primary', or 'secondary')
- `active`: `undefined` - Used to determine active status of the ripple. If it's undefined, the ":active" pseudo class will be checked on `activeTarget` or the node.
- `eventTarget`: `undefined` - An alternate element where ripple triggering event listeners will be added.
- `activeTarget`: `undefined` - An alternate element where active status will be checked.
- `addClass`: `(className) => node.classList.add(className)` - A function to add a class to the node.
- `removeClass`: `(className) => node.classList.remove(className)` - A function to remove a class from the node.
- `addStyle`: `(name, value) => node.style.setProperty(name, value)` - A function to add a style property to the node. If given a value of `''` or `null`, it should remove the property.
- `initPromise`: `Promise.resolve()` - A promise to wait for before initializing the ripple.

# More Information

See [Ripple](https://github.com/material-components/material-components-web/tree/v14.0.0/packages/mdc-ripple) in MDC-Web for information about the upstream library's architecture.

---
_Source: https://npm.io/package/@detachhead/smui-ripple · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
