@@ -7,6 +7,7 @@ import type {
7
7
HTMLThAttributes
8
8
} from "svelte/elements" ;
9
9
import type * as I from "./_types.js" ;
10
+ import type { CustomEventHandler } from "$lib" ;
10
11
11
12
type Props < Multiple extends boolean = false > = I . Props < Multiple > &
12
13
Omit < HTMLDivAttributes , "placeholder" > ;
@@ -33,6 +34,26 @@ type CellProps = I.CellProps & HTMLTdAttributes;
33
34
34
35
type DateProps = I . DateProps & HTMLDivAttributes ;
35
36
37
+ /**
38
+ * Events
39
+ */
40
+
41
+ type ButtonEvents = {
42
+ click : CustomEventHandler < MouseEvent , HTMLButtonElement > ;
43
+ } ;
44
+
45
+ type PrevButtonEvents = ButtonEvents ;
46
+
47
+ type NextButtonEvents = ButtonEvents ;
48
+
49
+ type DateEvents = {
50
+ click : CustomEventHandler < MouseEvent , HTMLDivElement > ;
51
+ } ;
52
+
53
+ type Events = {
54
+ keydown : CustomEventHandler < KeyboardEvent , HTMLDivElement > ;
55
+ } ;
56
+
36
57
export type {
37
58
Props ,
38
59
PrevButtonProps ,
@@ -58,5 +79,17 @@ export type {
58
79
GridBodyProps as CalendarGridBodyProps ,
59
80
CellProps as CalendarCellProps ,
60
81
GridRowProps as CalendarGridRowProps ,
61
- DateProps as CalendarDateProps
82
+ DateProps as CalendarDateProps ,
83
+ //
84
+ // Events
85
+ //
86
+ Events ,
87
+ PrevButtonEvents ,
88
+ NextButtonEvents ,
89
+ DateEvents ,
90
+ //
91
+ Events as CalendarEvents ,
92
+ PrevButtonEvents as CalendarPrevButtonEvents ,
93
+ NextButtonEvents as CalendarNextButtonEvents ,
94
+ DateEvents as CalendarDateEvents
62
95
} ;
0 commit comments