<!-- AUTO-GENERATED from the @riverty/web-components custom elements manifest. Do not edit by hand. -->

# r-icon

Renders an SVG icon from the icon set (default Riverty) by name, or from a custom URL source.

Example:
```
<r-icon name="check" size="m"></r-icon>
<r-icon name="arrow-right" size="l" color="var(--r-color-action-primary)"></r-icon>
<r-icon src="https://example.com/custom-icon.svg" icon-aria-label="Custom icon"></r-icon>
```

## class: `RIcon`, `r-icon`

### Fields

| Name            | Privacy | Type                  | Default       | Description                                                           | Inherited From |
| --------------- | ------- | --------------------- | ------------- | --------------------------------------------------------------------- | -------------- |
| `color`         |         | `string`              | `null`        | Quick way to set display color to one of the<br>Riverty color tokens |                |
| `iconAriaLabel` |         | `string`              |               | Defines an accessible name for the icon.                              |                |
| `kit`           |         | `"riverty" \| "test"` | `'riverty'`   | Select kit                                                            |                |
| `name`          |         | `string`              |               | Name of icon to select from the set                                   |                |
| `size`          |         | `"l" \| "m" \| "s"`   | `"m"`         | Select one of pre-set sizes (width and height automatically selected) |                |
| `src`           |         | `string`              |               | Source of an icon to fetch from                                       |                |
| `variant`       |         | `"button"`            |               | Defines UI deviations for the icon.                                   |                |
| `viewBox`       |         | `string`              | `'0 0 24 24'` | Customize `viewBox` of rendered icon SVG element                      |                |

### Attributes

| Name              | Field         | Inherited From |
| ----------------- | ------------- | -------------- |
| `color`           | color         |                |
| `icon-aria-label` | iconAriaLabel |                |
| `kit`             | kit           |                |
| `name`            | name          |                |
| `size`            | size          |                |
| `src`             | src           |                |
| `variant`         | variant       |                |
| `view-box`        | viewBox       |                |

### Slots

| Name | Description                                              |
| ---- | -------------------------------------------------------- |
|      | Fallback content rendered when the icon is not available |

<hr/>

## Exports

| Kind                        | Name     | Declaration | Module | Package |
| --------------------------- | -------- | ----------- | ------ | ------- |
| `js`                        | `RIcon`  | RIcon       |        |         |
| `custom-element-definition` | `r-icon` | RIcon       |        |         |
