fix(radio-button-group): strongly type dispatched change/select events (#1819)

This commit is contained in:
Eric Liu 2023-10-03 11:23:17 -07:00 committed by GitHub
commit 06d81ddbff
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 42 additions and 18 deletions

View file

@ -64,11 +64,11 @@ export interface RadioButtonGroupProps extends RestProps {
export default class RadioButtonGroup extends SvelteComponentTyped<
RadioButtonGroupProps,
{
change: CustomEvent<string>;
click: WindowEventMap["click"];
mouseover: WindowEventMap["mouseover"];
mouseenter: WindowEventMap["mouseenter"];
mouseleave: WindowEventMap["mouseleave"];
change: CustomEvent<any>;
},
{ default: {}; legendText: {} }
> {}

View file

@ -39,6 +39,6 @@ export interface TileGroupProps extends RestProps {
export default class TileGroup extends SvelteComponentTyped<
TileGroupProps,
{ select: CustomEvent<any> },
{ select: CustomEvent<string> },
{ default: {} }
> {}