# @detachhead/smui-chips

> Svelte Material UI - Chips

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-chips
pnpm add @detachhead/smui-chips
yarn add @detachhead/smui-chips
bun add @detachhead/smui-chips
```

## 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 | 6 |
| Unpacked size | 690.6 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-chips
- 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-chips

## Dependencies (6)

- [svelte2tsx](https://npm.io/package/svelte2tsx.md) ^0.5.12
- [@material/dom](https://npm.io/package/@material/dom.md) ^14.0.0
- [@material/rtl](https://npm.io/package/@material/rtl.md) ^14.0.0
- [@material/chips](https://npm.io/package/@material/chips.md) ^14.0.0
- [@detachhead/smui-common](https://npm.io/package/@detachhead/smui-common.md) ^7.0.0-beta.0
- [@detachhead/smui-ripple](https://npm.io/package/@detachhead/smui-ripple.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 - Chips

Chips are used to show discrete information, filter options, input tags, or actions.

# Installation

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

# Examples and Usage Information

https://sveltematerialui.com/demo/chips

# Exports

## (default)

A chip.

### Props / Defaults

- `use`: `[]` - An array of Svelte actions and/or arrays of an action and its options.
- `class`: `''` - A CSS class string.
- `ripple`: `true` - Whether to implement a ripple for when the component is interacted with.
- `touch`: `false` - Increase the touch target.
- `shouldRemoveOnTrailingIconClick`: `true` - Whether the chip should be removed upon clicking the trailing icon.
- `shouldFocusPrimaryActionOnClick`: `true` - Whether the chip should focus the primary action when it is clicked.

### Events

- `MDCChip:interaction`
- `MDCChip:selection`
- `MDCChip:removal`
- `MDCChip:trailingIconInteraction`
- `MDCChip:navigation`

## Set

A set of chips. Chips should only be added onto the end of the set's chip array.

### Props / Defaults

- `use`: `[]` - An array of Svelte actions and/or arrays of an action and its options.
- `class`: `''` - A CSS class string.
- `chips` `[]` - An array containing the chips.
- `key` `chip => chip` - A function used to get the key of the chip. Chip sets that have removable chips should always provide unique keys.
- `selected` `undefined` - The currently selected chip or chips.
- `choice` `false` - Whether to present the chips as a set of choices, allowing one to be chosen.
- `filter` `false` - Whether to present the chips as a set of options, allowing any number to be chosen.
- `input` `false` - Whether to present the chips as a set of values, allowing them to be removed.

## Text

A text label.

todo...

## LeadingIcon

A graphic icon.

todo...

## TrailingIcon

A graphic icon.

todo...

## TrailingAction

A graphic icon.

todo...

# More Information

See [Chips](https://material.io/components/chips) in the Material design spec.

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

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