Skip to content

Commit 07d2b24

Browse files
markcaronzeroedin
andauthored
Update elements/pf-v6-label/README.md
Co-authored-by: Steven Spriggs <steven.spriggs@gmail.com>
1 parent 746e768 commit 07d2b24

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

‎elements/pf-v6-label/README.md‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ Labels provide a visual way to describe or tag items using keywords.
4040

4141
| React prop | Web component | Difference |
4242
|---|---|---|
43-
| `isCompact` | `compact` attribute | Boolean attribute; no `is-` prefix per web component conventions |
44-
| `isDisabled` | `disabled` attribute | Boolean attribute; no `is-` prefix |
45-
| `isClickable` | `clickable` attribute | Boolean attribute; no `is-` prefix |
46-
| `isTruncated` | `truncated` attribute | Boolean attribute; no `is-` prefix |
47-
| `onClose` | `close` event | DOM event (`LabelCloseEvent`) instead of callback prop. `preventDefault()` stops removal. |
43+
| `isCompact` | `compact` attribute | Dropped `is-` prefix per web component convention |
44+
| `isDisabled` | `disabled` attribute | Dropped `is-` prefix per web component convention |
45+
| `isClickable` | `clickable` attribute | Dropped `is-` prefix per web component convention |
46+
| `isTruncated` | `truncated` attribute | Dropped `is-` prefix per web component convention |
47+
| `onClose` | `removable` attribute + `close` event | In React, providing `onClose` shows the close button and handles the event. Set `removable` to show the button; listen for the `close` event (`LabelCloseEvent`) to handle it. `preventDefault()` stops removal. |
4848
| `onClick` | native `click` event | Use standard `click` event listener on the element |
4949
| `icon` (ReactNode) | `icon` slot | Slot a `<svg>` or icon element instead of passing a React node |
5050
| `closeBtnAriaLabel` | `close-button-label` attribute | Renamed to match web component dash-case conventions |

0 commit comments

Comments
 (0)