File tree Expand file tree Collapse file tree 5 files changed +656
-0
lines changed
Expand file tree Collapse file tree 5 files changed +656
-0
lines changed Original file line number Diff line number Diff line change 1+ *
2+ ! ** /* .d.ts
3+ ! ** /* .d.cts
4+ ! ** /* .d.mts
5+ ! ** /* .d. * .ts
Original file line number Diff line number Diff line change 1+ import * as CronofyElements from "cronofy-elements" ;
2+
3+ const query : CronofyElements . AvailabilityQuery = {
4+ participants : [ ] ,
5+ required_duration : { minutes : 60 } ,
6+ query_periods : [ ] ,
7+ response_format : "slots" ,
8+ buffer : {
9+ before : { minutes : 15 } ,
10+ after : { minutes : 15 } ,
11+ } ,
12+ } ;
13+
14+ const callback : CronofyElements . AvailabilityViewerCallback = ( action : CronofyElements . AvailabilityViewerAction ) => {
15+ if ( action . notification . type === "slot_added" ) {
16+ const timeslots : CronofyElements . Slot [ ] = action . slots ?? [ ] ;
17+ }
18+ } ;
19+
20+ const availabilityOptions : CronofyElements . AvailabilityViewerOptions = {
21+ availability_query : query ,
22+ element_token : "TOKEN" ,
23+ demo : true ,
24+ callback,
25+ target_id : "cronofy-availability-viewer" ,
26+ data_center : "uk" ,
27+ } ;
28+
29+ const AvailabilityViewer = CronofyElements . AvailabilityViewer ( availabilityOptions ) ;
You can’t perform that action at this time.
0 commit comments