Skip to content

Commit

Permalink
feat(Seat): change type of label and price props to string
Browse files Browse the repository at this point in the history
BREAKING CHANGE: `label` and `price` props now only accept string.
They no longer accept ReactNode
  • Loading branch information
DSil committed Nov 8, 2024
1 parent 000462e commit ac10505
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/orbit-components/src/Seat/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Table below contains all types of the props available in Seat component.
| size | [`enum`](#modal-enum) | `medium` | Size of Seat component. |
| type | [`enum`](#modal-enum) | `default` | Visual type of Seat. If `unavailable`, the element becomes disabled. |
| price | `string` | | Price of Seat. Displayed as text underneath the svg. |
| label | `string` | | Label text inside of a Seat. Not announced by **screen readers**. |
| label | `string` | | Label text inside of a Seat. Not announced by screen readers. |
| selected | `boolean` | | Displays Seat as selected. |
| onClick | `() => void \| Promise` | | Function for handling onClick event. |
| aria-labelledby | `string` | | Id(s) of elements that announce the component to screen readers. |
Expand Down
4 changes: 2 additions & 2 deletions packages/orbit-components/src/Seat/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ export interface Props extends Common.Globals {
readonly "aria-labelledby"?: string;
readonly onClick?: Common.Callback;
readonly selected?: boolean;
readonly label?: React.ReactNode;
readonly price?: React.ReactNode;
readonly label?: string;
readonly price?: string;
}

0 comments on commit ac10505

Please sign in to comment.