Die Chip-Komponente ist ein kompaktes UI-Element, das zur Darstellung von ausgewählten Werten innerhalb eines Form-Fieldes dient. Jeder Chip repräsentiert eine Auswahl und kann bei Bedarf wieder entfernt werden.

| Nummer | Typ | Beschreibung | Optional | Hinweis |
|---|---|---|---|---|
| 1 | Text | Label | Nein | |
| 2 | Button | Close-Action | Nein |
The sbb-chip is a component meant to be used in combination with the sbb-chip-group to display a list of string user inputs.
<sbb-chip-group>
<sbb-chip value="Value 1"></sbb-chip>
...
</sbb-chip-group>
It is possible to provide a label via the unnamed slot. If not present, the value will be used.
The disabled/readOnly properties are controlled by the sbb-chip-group.
Use the accessibility-label property to add info on the chip content.
| Name | Attribute | Privacy | Type | Default | Description |
|---|---|---|---|---|---|
disabled | disabled | public | boolean | false | Whether the component is disabled. |
negative | negative | public | boolean | false | Negative coloring variant flag. |
readOnly | readonly | public | boolean | false | Whether the component is readonly. |
value | value | public | (T = string) | null | null | The value of chip. Will be used as label if nothing is slotted. |
| Name | Description |
|---|---|
| Use the unnamed slot to add the display value. If not provided, the 'value' will be used. |