mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-11-08 07:41:51 +08:00
feat(all): add CustomEvents types to components that emit events (#23956)
resolves #22925 BREAKING CHANGE: The `RadioChangeEventDetail` interface has been removed in favor of `RadioGroupChangeEventDetail`.
This commit is contained in:
@ -2,3 +2,8 @@ export interface BreadcrumbCollapsedClickEventDetail {
|
||||
ionShadowTarget?: HTMLElement;
|
||||
collapsedBreadcrumbs?: HTMLIonBreadcrumbElement[];
|
||||
}
|
||||
|
||||
export interface BreadcrumbCustomEvent extends CustomEvent {
|
||||
detail: BreadcrumbCollapsedClickEventDetail;
|
||||
target: HTMLIonBreadcrumbElement;
|
||||
}
|
||||
|
||||
@ -2,6 +2,27 @@
|
||||
|
||||
A Breadcrumb is a single navigation item that is a child of the Breadcrumbs component. A breadcrumb can link elsewhere in an app or it can be plain text. Each breadcrumb has a separator between it and the next breadcrumb and can optionally contain an icon.
|
||||
|
||||
## Interfaces
|
||||
|
||||
### BreadcrumbCollapsedClickEventDetail
|
||||
|
||||
```typescript
|
||||
interface BreadcrumbCollapsedClickEventDetail {
|
||||
collapsedBreadcrumbs?: HTMLIonBreadcrumbElement[];
|
||||
}
|
||||
```
|
||||
|
||||
### BreadcrumbCustomEvent
|
||||
|
||||
While not required, this interface can be used in place of the `CustomEvent` interface for stronger typing .
|
||||
|
||||
```typescript
|
||||
interface BreadcrumbCustomEvent extends CustomEvent {
|
||||
detail: BreadcrumbCollapsedClickEventDetail;
|
||||
target: HTMLIonBreadcrumbElement;
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
<!-- Auto Generated Below -->
|
||||
|
||||
|
||||
Reference in New Issue
Block a user