]>
Commit | Line | Data |
---|---|---|
6198556e DI |
1 | /** |
2 | * @license MIT | |
3 | */ | |
4 | ||
7ac4f1a9 DI |
5 | export type LinkMatcher = { |
6 | id: number, | |
7 | regex: RegExp, | |
8 | handler: LinkMatcherHandler, | |
9 | matchIndex?: number, | |
10 | validationCallback?: LinkMatcherValidationCallback, | |
11 | priority?: number | |
12 | }; | |
1f518b0b | 13 | export type LinkMatcherHandler = (event: MouseEvent, uri: string) => boolean | void; |
b66776a0 | 14 | export type LinkMatcherValidationCallback = (uri: string, element: HTMLElement, callback: (isValid: boolean) => void) => void; |