fix(radio-button): allow value type to be a number

This commit is contained in:
Eric Liu 2023-12-17 09:26:44 -08:00
commit 97b716dae8
6 changed files with 21 additions and 18 deletions

View file

@ -8,7 +8,7 @@ export interface RadioButtonGroupProps extends RestProps {
* Set the selected radio button value
* @default undefined
*/
selected?: string;
selected?: string | number;
/**
* Set to `true` to disable the radio buttons
@ -64,7 +64,7 @@ export interface RadioButtonGroupProps extends RestProps {
export default class RadioButtonGroup extends SvelteComponentTyped<
RadioButtonGroupProps,
{
change: CustomEvent<string>;
change: CustomEvent<string | number>;
click: WindowEventMap["click"];
mouseover: WindowEventMap["mouseover"];
mouseenter: WindowEventMap["mouseenter"];