@symbiote-native/calendar 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +189 -0
- package/build/angular/index.d.ts +3 -0
- package/build/angular/index.js +3 -0
- package/build/angular/services/calendar-permissions.service/index.d.ts +5 -0
- package/build/angular/services/calendar-permissions.service/index.js +60 -0
- package/build/angular/services/reminders-permissions.service/index.d.ts +5 -0
- package/build/angular/services/reminders-permissions.service/index.js +60 -0
- package/build/core/attendee.d.ts +9 -0
- package/build/core/attendee.js +28 -0
- package/build/core/calendar-permission-api.d.ts +9 -0
- package/build/core/calendar-permission-api.js +9 -0
- package/build/core/calendar.d.ts +34 -0
- package/build/core/calendar.js +118 -0
- package/build/core/enums.d.ts +141 -0
- package/build/core/enums.js +157 -0
- package/build/core/event.d.ts +14 -0
- package/build/core/event.js +40 -0
- package/build/core/index.d.ts +6 -0
- package/build/core/index.js +6 -0
- package/build/core/native-module.d.ts +154 -0
- package/build/core/native-module.js +3 -0
- package/build/core/reminder.d.ts +10 -0
- package/build/core/reminder.js +34 -0
- package/build/core/types.d.ts +184 -0
- package/build/core/types.js +1 -0
- package/build/core/utils.d.ts +7 -0
- package/build/core/utils.js +29 -0
- package/build/legacy/calendar.d.ts +23 -0
- package/build/legacy/calendar.js +261 -0
- package/build/legacy/enums.d.ts +1 -0
- package/build/legacy/enums.js +2 -0
- package/build/legacy/index.d.ts +5 -0
- package/build/legacy/index.js +5 -0
- package/build/legacy/native-module.d.ts +39 -0
- package/build/legacy/native-module.js +3 -0
- package/build/legacy/permissions.d.ts +9 -0
- package/build/legacy/permissions.js +33 -0
- package/build/legacy/reminders.d.ts +6 -0
- package/build/legacy/reminders.js +56 -0
- package/build/legacy/types.d.ts +147 -0
- package/build/legacy/types.js +1 -0
- package/build/react/index.d.ts +3 -0
- package/build/react/index.js +3 -0
- package/build/react/use-calendar-permissions.d.ts +10 -0
- package/build/react/use-calendar-permissions.js +7 -0
- package/build/react/use-reminders-permissions.d.ts +8 -0
- package/build/react/use-reminders-permissions.js +10 -0
- package/build/solid/index.d.ts +3 -0
- package/build/solid/index.js +3 -0
- package/build/solid/use-calendar-permissions.d.ts +11 -0
- package/build/solid/use-calendar-permissions.js +7 -0
- package/build/solid/use-reminders-permissions.d.ts +9 -0
- package/build/solid/use-reminders-permissions.js +10 -0
- package/build/svelte/index.d.ts +3 -0
- package/build/svelte/index.js +3 -0
- package/build/svelte/use-calendar-permissions.svelte.d.ts +10 -0
- package/build/svelte/use-calendar-permissions.svelte.js +7 -0
- package/build/svelte/use-reminders-permissions.svelte.d.ts +8 -0
- package/build/svelte/use-reminders-permissions.svelte.js +10 -0
- package/build/vue/index.d.ts +3 -0
- package/build/vue/index.js +3 -0
- package/build/vue/use-calendar-permissions.d.ts +11 -0
- package/build/vue/use-calendar-permissions.js +7 -0
- package/build/vue/use-reminders-permissions.d.ts +9 -0
- package/build/vue/use-reminders-permissions.js +10 -0
- package/build-ngc/angular/index.d.ts +3 -0
- package/build-ngc/angular/index.js +4 -0
- package/build-ngc/angular/index.js.map +1 -0
- package/build-ngc/angular/services/calendar-permissions.service/index.d.ts +8 -0
- package/build-ngc/angular/services/calendar-permissions.service/index.js +17 -0
- package/build-ngc/angular/services/calendar-permissions.service/index.js.map +1 -0
- package/build-ngc/angular/services/reminders-permissions.service/index.d.ts +8 -0
- package/build-ngc/angular/services/reminders-permissions.service/index.js +17 -0
- package/build-ngc/angular/services/reminders-permissions.service/index.js.map +1 -0
- package/build-ngc/core/attendee.d.ts +9 -0
- package/build-ngc/core/attendee.js +29 -0
- package/build-ngc/core/attendee.js.map +1 -0
- package/build-ngc/core/calendar-permission-api.d.ts +9 -0
- package/build-ngc/core/calendar-permission-api.js +10 -0
- package/build-ngc/core/calendar-permission-api.js.map +1 -0
- package/build-ngc/core/calendar.d.ts +34 -0
- package/build-ngc/core/calendar.js +119 -0
- package/build-ngc/core/calendar.js.map +1 -0
- package/build-ngc/core/enums.d.ts +141 -0
- package/build-ngc/core/enums.js +158 -0
- package/build-ngc/core/enums.js.map +1 -0
- package/build-ngc/core/event.d.ts +14 -0
- package/build-ngc/core/event.js +41 -0
- package/build-ngc/core/event.js.map +1 -0
- package/build-ngc/core/index.d.ts +6 -0
- package/build-ngc/core/index.js +7 -0
- package/build-ngc/core/index.js.map +1 -0
- package/build-ngc/core/native-module.d.ts +154 -0
- package/build-ngc/core/native-module.js +4 -0
- package/build-ngc/core/native-module.js.map +1 -0
- package/build-ngc/core/reminder.d.ts +10 -0
- package/build-ngc/core/reminder.js +35 -0
- package/build-ngc/core/reminder.js.map +1 -0
- package/build-ngc/core/types.d.ts +184 -0
- package/build-ngc/core/types.js +2 -0
- package/build-ngc/core/types.js.map +1 -0
- package/build-ngc/core/utils.d.ts +7 -0
- package/build-ngc/core/utils.js +30 -0
- package/build-ngc/core/utils.js.map +1 -0
- package/native-link.json +29 -0
- package/package.json +155 -0
- package/src/angular/index.ts +3 -0
- package/src/angular/services/calendar-permissions.service/index.ts +19 -0
- package/src/angular/services/reminders-permissions.service/index.ts +16 -0
- package/src/core/attendee.ts +43 -0
- package/src/core/calendar-permission-api.ts +16 -0
- package/src/core/calendar.ts +197 -0
- package/src/core/enums.ts +156 -0
- package/src/core/event.ts +70 -0
- package/src/core/index.ts +18 -0
- package/src/core/native-module.ts +212 -0
- package/src/core/reminder.ts +52 -0
- package/src/core/types.ts +209 -0
- package/src/core/utils.ts +39 -0
- package/src/legacy/calendar.ts +401 -0
- package/src/legacy/enums.ts +2 -0
- package/src/legacy/index.ts +5 -0
- package/src/legacy/native-module.ts +77 -0
- package/src/legacy/permissions.ts +47 -0
- package/src/legacy/reminders.ts +98 -0
- package/src/legacy/types.ts +183 -0
- package/src/react/index.ts +3 -0
- package/src/react/use-calendar-permissions.ts +25 -0
- package/src/react/use-reminders-permissions.ts +25 -0
- package/src/solid/index.ts +3 -0
- package/src/solid/use-calendar-permissions.ts +26 -0
- package/src/solid/use-reminders-permissions.ts +26 -0
- package/src/svelte/index.ts +3 -0
- package/src/svelte/svelte-ambient.d.ts +3 -0
- package/src/svelte/svelte-compile.test-helper.ts +7 -0
- package/src/svelte/use-calendar-permissions.svelte.ts +25 -0
- package/src/svelte/use-reminders-permissions.svelte.ts +25 -0
- package/src/vue/index.ts +3 -0
- package/src/vue/use-calendar-permissions.ts +26 -0
- package/src/vue/use-reminders-permissions.ts +26 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { UnavailabilityError } from 'expo-modules-core';
|
|
2
|
+
import { expoCalendar } from './native-module.js';
|
|
3
|
+
import { stringifyDateValues, stringifyIfDate } from '../core/utils.js';
|
|
4
|
+
export async function getRemindersAsync(calendarIds, status, startDate, endDate) {
|
|
5
|
+
if (!expoCalendar.getRemindersAsync) {
|
|
6
|
+
throw new UnavailabilityError('Calendar', 'getRemindersAsync');
|
|
7
|
+
}
|
|
8
|
+
if (status && !startDate) {
|
|
9
|
+
throw new Error('getRemindersAsync must be called with a startDate (date) to search for reminders');
|
|
10
|
+
}
|
|
11
|
+
if (status && !endDate) {
|
|
12
|
+
throw new Error('getRemindersAsync must be called with an endDate (date) to search for reminders');
|
|
13
|
+
}
|
|
14
|
+
if (!calendarIds || !calendarIds.length) {
|
|
15
|
+
throw new Error('getRemindersAsync must be called with a non-empty array of calendarIds to search');
|
|
16
|
+
}
|
|
17
|
+
return expoCalendar.getRemindersAsync(startDate ? stringifyIfDate(startDate) : null, endDate ? stringifyIfDate(endDate) : null, calendarIds, status);
|
|
18
|
+
}
|
|
19
|
+
export async function getReminderAsync(id) {
|
|
20
|
+
if (!expoCalendar.getReminderByIdAsync) {
|
|
21
|
+
throw new UnavailabilityError('Calendar', 'getReminderAsync');
|
|
22
|
+
}
|
|
23
|
+
if (!id) {
|
|
24
|
+
throw new Error('getReminderAsync must be called with an id (string) of the target reminder');
|
|
25
|
+
}
|
|
26
|
+
return expoCalendar.getReminderByIdAsync(id);
|
|
27
|
+
}
|
|
28
|
+
export async function createReminderAsync(calendarId, reminder = {}) {
|
|
29
|
+
if (!expoCalendar.saveReminderAsync) {
|
|
30
|
+
throw new UnavailabilityError('Calendar', 'createReminderAsync');
|
|
31
|
+
}
|
|
32
|
+
const { id: _id, ...details } = reminder;
|
|
33
|
+
return expoCalendar.saveReminderAsync(stringifyDateValues({ ...details, calendarId: calendarId ?? undefined }));
|
|
34
|
+
}
|
|
35
|
+
export async function updateReminderAsync(id, details = {}) {
|
|
36
|
+
if (!expoCalendar.saveReminderAsync) {
|
|
37
|
+
throw new UnavailabilityError('Calendar', 'updateReminderAsync');
|
|
38
|
+
}
|
|
39
|
+
if (!id) {
|
|
40
|
+
throw new Error('updateReminderAsync must be called with an id (string) of the target reminder');
|
|
41
|
+
}
|
|
42
|
+
if (Object.hasOwn(details, 'creationDate') ||
|
|
43
|
+
Object.hasOwn(details, 'lastModifiedDate')) {
|
|
44
|
+
console.warn('updateReminderAsync was called with one or more read-only properties, which will not be updated');
|
|
45
|
+
}
|
|
46
|
+
return expoCalendar.saveReminderAsync(stringifyDateValues({ ...details, id }));
|
|
47
|
+
}
|
|
48
|
+
export async function deleteReminderAsync(id) {
|
|
49
|
+
if (!expoCalendar.deleteReminderAsync) {
|
|
50
|
+
throw new UnavailabilityError('Calendar', 'deleteReminderAsync');
|
|
51
|
+
}
|
|
52
|
+
if (!id) {
|
|
53
|
+
throw new Error('deleteReminderAsync must be called with an id (string) of the target reminder');
|
|
54
|
+
}
|
|
55
|
+
return expoCalendar.deleteReminderAsync(id);
|
|
56
|
+
}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import type { AlarmMethod, AttendeeRole, AttendeeStatus, AttendeeType, CalendarAccessLevel, CalendarDialogResultActions, CalendarType, DayOfTheWeek, EntityTypes, EventAccessLevel, EventStatus, Frequency, MonthOfTheYear, SourceType, Availability } from './enums';
|
|
3
|
+
export type { PermissionResponse };
|
|
4
|
+
export type IRecurringEventOptions = {
|
|
5
|
+
futureEvents?: boolean;
|
|
6
|
+
instanceStartDate?: string | Date;
|
|
7
|
+
};
|
|
8
|
+
export type IOrganizer = {
|
|
9
|
+
isCurrentUser: boolean;
|
|
10
|
+
name?: string;
|
|
11
|
+
role: string;
|
|
12
|
+
status: string;
|
|
13
|
+
type: string;
|
|
14
|
+
url?: string;
|
|
15
|
+
};
|
|
16
|
+
export type ISource = {
|
|
17
|
+
id?: string;
|
|
18
|
+
type: string | SourceType;
|
|
19
|
+
name: string;
|
|
20
|
+
isLocalAccount?: boolean;
|
|
21
|
+
};
|
|
22
|
+
export type ICalendar = {
|
|
23
|
+
id: string;
|
|
24
|
+
title: string;
|
|
25
|
+
sourceId?: string;
|
|
26
|
+
source: ISource;
|
|
27
|
+
type?: CalendarType;
|
|
28
|
+
color: string;
|
|
29
|
+
entityType?: EntityTypes;
|
|
30
|
+
allowsModifications: boolean;
|
|
31
|
+
allowedAvailabilities: Availability[];
|
|
32
|
+
isPrimary?: boolean;
|
|
33
|
+
name?: string | null;
|
|
34
|
+
ownerAccount?: string;
|
|
35
|
+
timeZone?: string;
|
|
36
|
+
allowedReminders?: AlarmMethod[];
|
|
37
|
+
allowedAttendeeTypes?: AttendeeType[];
|
|
38
|
+
isVisible?: boolean;
|
|
39
|
+
isSynced?: boolean;
|
|
40
|
+
accessLevel?: CalendarAccessLevel;
|
|
41
|
+
};
|
|
42
|
+
export type IEvent = {
|
|
43
|
+
id: string;
|
|
44
|
+
calendarId: string;
|
|
45
|
+
title: string;
|
|
46
|
+
location: string | null;
|
|
47
|
+
creationDate?: string | Date;
|
|
48
|
+
lastModifiedDate?: string | Date;
|
|
49
|
+
timeZone: string;
|
|
50
|
+
endTimeZone?: string;
|
|
51
|
+
url?: string;
|
|
52
|
+
notes: string;
|
|
53
|
+
alarms: IAlarm[];
|
|
54
|
+
recurrenceRule: IRecurrenceRule | null;
|
|
55
|
+
startDate: string | Date;
|
|
56
|
+
endDate: string | Date;
|
|
57
|
+
originalStartDate?: string | Date;
|
|
58
|
+
isDetached?: boolean;
|
|
59
|
+
allDay: boolean;
|
|
60
|
+
availability: Availability;
|
|
61
|
+
status: EventStatus;
|
|
62
|
+
organizer?: IOrganizer;
|
|
63
|
+
organizerEmail?: string;
|
|
64
|
+
accessLevel?: EventAccessLevel;
|
|
65
|
+
guestsCanModify?: boolean;
|
|
66
|
+
guestsCanInviteOthers?: boolean;
|
|
67
|
+
guestsCanSeeGuests?: boolean;
|
|
68
|
+
originalId?: string;
|
|
69
|
+
instanceId?: string;
|
|
70
|
+
};
|
|
71
|
+
export type IReminder = {
|
|
72
|
+
id?: string;
|
|
73
|
+
calendarId?: string;
|
|
74
|
+
title?: string;
|
|
75
|
+
location?: string;
|
|
76
|
+
creationDate?: string | Date;
|
|
77
|
+
lastModifiedDate?: string | Date;
|
|
78
|
+
timeZone?: string;
|
|
79
|
+
url?: string;
|
|
80
|
+
notes?: string;
|
|
81
|
+
alarms?: IAlarm[];
|
|
82
|
+
recurrenceRule?: IRecurrenceRule | null;
|
|
83
|
+
startDate?: string | Date;
|
|
84
|
+
dueDate?: string | Date;
|
|
85
|
+
allDay?: boolean;
|
|
86
|
+
completed?: boolean;
|
|
87
|
+
completionDate?: string | Date;
|
|
88
|
+
};
|
|
89
|
+
export type IAttendee = {
|
|
90
|
+
id?: string;
|
|
91
|
+
isCurrentUser?: boolean;
|
|
92
|
+
name: string;
|
|
93
|
+
role: AttendeeRole;
|
|
94
|
+
status: AttendeeStatus;
|
|
95
|
+
type: AttendeeType;
|
|
96
|
+
url?: string;
|
|
97
|
+
email?: string;
|
|
98
|
+
};
|
|
99
|
+
export type IAlarmLocation = {
|
|
100
|
+
title?: string;
|
|
101
|
+
proximity?: string;
|
|
102
|
+
radius?: number;
|
|
103
|
+
coords?: {
|
|
104
|
+
latitude?: number;
|
|
105
|
+
longitude?: number;
|
|
106
|
+
};
|
|
107
|
+
};
|
|
108
|
+
export type IAlarm = {
|
|
109
|
+
absoluteDate?: string;
|
|
110
|
+
relativeOffset?: number;
|
|
111
|
+
structuredLocation?: IAlarmLocation;
|
|
112
|
+
method?: AlarmMethod;
|
|
113
|
+
};
|
|
114
|
+
export type IDaysOfTheWeek = {
|
|
115
|
+
dayOfTheWeek: DayOfTheWeek;
|
|
116
|
+
weekNumber?: number;
|
|
117
|
+
};
|
|
118
|
+
export type IRecurrenceRule = {
|
|
119
|
+
frequency: Frequency;
|
|
120
|
+
interval?: number;
|
|
121
|
+
endDate?: string | Date;
|
|
122
|
+
occurrence?: number;
|
|
123
|
+
daysOfTheWeek?: IDaysOfTheWeek[];
|
|
124
|
+
daysOfTheMonth?: number[];
|
|
125
|
+
monthsOfTheYear?: MonthOfTheYear[];
|
|
126
|
+
weeksOfTheYear?: number[];
|
|
127
|
+
daysOfTheYear?: number[];
|
|
128
|
+
setPositions?: number[];
|
|
129
|
+
};
|
|
130
|
+
export type IOpenEventDialogResult = {
|
|
131
|
+
action: Extract<CalendarDialogResultActions, 'done' | 'canceled' | 'deleted' | 'responded'>;
|
|
132
|
+
};
|
|
133
|
+
export type IDialogEventResult = {
|
|
134
|
+
action: Extract<CalendarDialogResultActions, 'done' | 'saved' | 'canceled' | 'deleted'>;
|
|
135
|
+
id: string | null;
|
|
136
|
+
};
|
|
137
|
+
export type IPresentationOptions = {
|
|
138
|
+
startNewActivityTask?: boolean;
|
|
139
|
+
};
|
|
140
|
+
export type IOpenEventPresentationOptions = IPresentationOptions & {
|
|
141
|
+
allowsEditing?: boolean;
|
|
142
|
+
allowsCalendarPreview?: boolean;
|
|
143
|
+
};
|
|
144
|
+
export type ICalendarDialogParams = {
|
|
145
|
+
id: string;
|
|
146
|
+
instanceStartDate?: string | Date;
|
|
147
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type ICalendarPermissionMethodOptions } from '../core/calendar-permission-api';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import type { IPermissionHookOptions } from '@symbiote-native/engine';
|
|
4
|
+
export type IUseCalendarPermissionsOptions = ICalendarPermissionMethodOptions;
|
|
5
|
+
export type IUseCalendarPermissionsResult = [
|
|
6
|
+
PermissionResponse | null,
|
|
7
|
+
() => Promise<PermissionResponse>,
|
|
8
|
+
() => Promise<PermissionResponse>
|
|
9
|
+
];
|
|
10
|
+
export declare function useCalendarPermissions(options?: IPermissionHookOptions<IUseCalendarPermissionsOptions>): IUseCalendarPermissionsResult;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/react';
|
|
2
|
+
import { calendarPermissionMethods, splitCalendarPermissionOptions, } from '../core/calendar-permission-api.js';
|
|
3
|
+
const usePermission = createPermissionHook(calendarPermissionMethods);
|
|
4
|
+
// React twin of `expo-calendar`'s `useCalendarPermissions`
|
|
5
|
+
export function useCalendarPermissions(options) {
|
|
6
|
+
return usePermission(...splitCalendarPermissionOptions(options));
|
|
7
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import type { IPermissionHookBehavior } from '@symbiote-native/engine';
|
|
3
|
+
export type IUseRemindersPermissionsResult = [
|
|
4
|
+
PermissionResponse | null,
|
|
5
|
+
() => Promise<PermissionResponse>,
|
|
6
|
+
() => Promise<PermissionResponse>
|
|
7
|
+
];
|
|
8
|
+
export declare function useRemindersPermissions(options?: IPermissionHookBehavior): IUseRemindersPermissionsResult;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/react';
|
|
2
|
+
import { getRemindersPermissions, requestRemindersPermissions, } from '../core/calendar.js';
|
|
3
|
+
const usePermission = createPermissionHook({
|
|
4
|
+
getMethod: getRemindersPermissions,
|
|
5
|
+
requestMethod: requestRemindersPermissions,
|
|
6
|
+
});
|
|
7
|
+
// React twin of `expo-calendar`'s `useRemindersPermissions`
|
|
8
|
+
export function useRemindersPermissions(options) {
|
|
9
|
+
return usePermission(options);
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ICalendarPermissionMethodOptions } from '../core/calendar-permission-api';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import type { IPermissionHookOptions } from '@symbiote-native/engine';
|
|
4
|
+
import type { Accessor } from 'solid-js';
|
|
5
|
+
export type IUseCalendarPermissionsOptions = ICalendarPermissionMethodOptions;
|
|
6
|
+
export type IUseCalendarPermissionsResult = [
|
|
7
|
+
Accessor<PermissionResponse | null>,
|
|
8
|
+
() => Promise<PermissionResponse>,
|
|
9
|
+
() => Promise<PermissionResponse>
|
|
10
|
+
];
|
|
11
|
+
export declare function useCalendarPermissions(options?: IPermissionHookOptions<IUseCalendarPermissionsOptions>): IUseCalendarPermissionsResult;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/solid';
|
|
2
|
+
import { calendarPermissionMethods, splitCalendarPermissionOptions, } from '../core/calendar-permission-api.js';
|
|
3
|
+
const usePermission = createPermissionHook(calendarPermissionMethods);
|
|
4
|
+
// Solid twin of `../react`'s `useCalendarPermissions`
|
|
5
|
+
export function useCalendarPermissions(options) {
|
|
6
|
+
return usePermission(...splitCalendarPermissionOptions(options));
|
|
7
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import type { IPermissionHookBehavior } from '@symbiote-native/engine';
|
|
3
|
+
import type { Accessor } from 'solid-js';
|
|
4
|
+
export type IUseRemindersPermissionsResult = [
|
|
5
|
+
Accessor<PermissionResponse | null>,
|
|
6
|
+
() => Promise<PermissionResponse>,
|
|
7
|
+
() => Promise<PermissionResponse>
|
|
8
|
+
];
|
|
9
|
+
export declare function useRemindersPermissions(options?: IPermissionHookBehavior): IUseRemindersPermissionsResult;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/solid';
|
|
2
|
+
import { getRemindersPermissions, requestRemindersPermissions, } from '../core/calendar.js';
|
|
3
|
+
const usePermission = createPermissionHook({
|
|
4
|
+
getMethod: getRemindersPermissions,
|
|
5
|
+
requestMethod: requestRemindersPermissions,
|
|
6
|
+
});
|
|
7
|
+
// Solid twin of `../react`'s `useRemindersPermissions`
|
|
8
|
+
export function useRemindersPermissions(options) {
|
|
9
|
+
return usePermission(options);
|
|
10
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type ICalendarPermissionMethodOptions } from '../core/calendar-permission-api';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import type { IPermissionHookOptions } from '@symbiote-native/engine';
|
|
4
|
+
export type IUseCalendarPermissionsOptions = ICalendarPermissionMethodOptions;
|
|
5
|
+
export type IUseCalendarPermissionsResult = {
|
|
6
|
+
readonly status: PermissionResponse | null;
|
|
7
|
+
requestPermission: () => Promise<PermissionResponse>;
|
|
8
|
+
getPermission: () => Promise<PermissionResponse>;
|
|
9
|
+
};
|
|
10
|
+
export declare function useCalendarPermissions(options?: IPermissionHookOptions<IUseCalendarPermissionsOptions>): IUseCalendarPermissionsResult;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/svelte/runes/create-permission-hook';
|
|
2
|
+
import { calendarPermissionMethods, splitCalendarPermissionOptions, } from '../core/calendar-permission-api.js';
|
|
3
|
+
const usePermission = createPermissionHook(calendarPermissionMethods);
|
|
4
|
+
// Svelte twin of `../react`'s `useCalendarPermissions`
|
|
5
|
+
export function useCalendarPermissions(options) {
|
|
6
|
+
return usePermission(...splitCalendarPermissionOptions(options));
|
|
7
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import type { IPermissionHookBehavior } from '@symbiote-native/engine';
|
|
3
|
+
export type IUseRemindersPermissionsResult = {
|
|
4
|
+
readonly status: PermissionResponse | null;
|
|
5
|
+
requestPermission: () => Promise<PermissionResponse>;
|
|
6
|
+
getPermission: () => Promise<PermissionResponse>;
|
|
7
|
+
};
|
|
8
|
+
export declare function useRemindersPermissions(behavior?: IPermissionHookBehavior): IUseRemindersPermissionsResult;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/svelte/runes/create-permission-hook';
|
|
2
|
+
import { getRemindersPermissions, requestRemindersPermissions, } from '../core/calendar.js';
|
|
3
|
+
const usePermission = createPermissionHook({
|
|
4
|
+
getMethod: getRemindersPermissions,
|
|
5
|
+
requestMethod: requestRemindersPermissions,
|
|
6
|
+
});
|
|
7
|
+
// Svelte twin of `../react`'s `useRemindersPermissions`
|
|
8
|
+
export function useRemindersPermissions(behavior) {
|
|
9
|
+
return usePermission(behavior);
|
|
10
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ICalendarPermissionMethodOptions } from '../core/calendar-permission-api';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import type { IPermissionHookOptions } from '@symbiote-native/engine';
|
|
4
|
+
import type { Ref } from '@vue/runtime-core';
|
|
5
|
+
export type IUseCalendarPermissionsOptions = ICalendarPermissionMethodOptions;
|
|
6
|
+
export type IUseCalendarPermissionsResult = [
|
|
7
|
+
Ref<PermissionResponse | null>,
|
|
8
|
+
() => Promise<PermissionResponse>,
|
|
9
|
+
() => Promise<PermissionResponse>
|
|
10
|
+
];
|
|
11
|
+
export declare function useCalendarPermissions(options?: IPermissionHookOptions<IUseCalendarPermissionsOptions>): IUseCalendarPermissionsResult;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/vue';
|
|
2
|
+
import { calendarPermissionMethods, splitCalendarPermissionOptions, } from '../core/calendar-permission-api.js';
|
|
3
|
+
const usePermission = createPermissionHook(calendarPermissionMethods);
|
|
4
|
+
// Vue twin of `../react`'s `useCalendarPermissions`
|
|
5
|
+
export function useCalendarPermissions(options) {
|
|
6
|
+
return usePermission(...splitCalendarPermissionOptions(options));
|
|
7
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import type { IPermissionHookBehavior } from '@symbiote-native/engine';
|
|
3
|
+
import type { Ref } from '@vue/runtime-core';
|
|
4
|
+
export type IUseRemindersPermissionsResult = [
|
|
5
|
+
Ref<PermissionResponse | null>,
|
|
6
|
+
() => Promise<PermissionResponse>,
|
|
7
|
+
() => Promise<PermissionResponse>
|
|
8
|
+
];
|
|
9
|
+
export declare function useRemindersPermissions(options?: IPermissionHookBehavior): IUseRemindersPermissionsResult;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { createPermissionHook } from '@symbiote-native/vue';
|
|
2
|
+
import { getRemindersPermissions, requestRemindersPermissions, } from '../core/calendar.js';
|
|
3
|
+
const usePermission = createPermissionHook({
|
|
4
|
+
getMethod: getRemindersPermissions,
|
|
5
|
+
requestMethod: requestRemindersPermissions,
|
|
6
|
+
});
|
|
7
|
+
// Vue twin of `../react`'s `useRemindersPermissions`
|
|
8
|
+
export function useRemindersPermissions(options) {
|
|
9
|
+
return usePermission(options);
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/angular/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,OAAO,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AACrF,OAAO,EAAE,2BAA2B,EAAE,MAAM,0CAA0C,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PermissionsServiceBase } from '@symbiote-native/angular';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class CalendarPermissionsService extends PermissionsServiceBase<PermissionResponse, boolean> {
|
|
5
|
+
constructor();
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<CalendarPermissionsService, never>;
|
|
7
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<CalendarPermissionsService>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// Angular twin of `../../react`'s `useCalendarPermissions`, `get`/`request` take `writeOnly`
|
|
2
|
+
import { Injectable } from '@angular/core';
|
|
3
|
+
import { PermissionsServiceBase } from '@symbiote-native/angular';
|
|
4
|
+
import { getCalendarPermissions, requestCalendarPermissions, } from '../../../core/calendar';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export class CalendarPermissionsService extends PermissionsServiceBase {
|
|
7
|
+
constructor() {
|
|
8
|
+
super(getCalendarPermissions, requestCalendarPermissions);
|
|
9
|
+
}
|
|
10
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: CalendarPermissionsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
11
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: CalendarPermissionsService, providedIn: 'root' });
|
|
12
|
+
}
|
|
13
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: CalendarPermissionsService, decorators: [{
|
|
14
|
+
type: Injectable,
|
|
15
|
+
args: [{ providedIn: 'root' }]
|
|
16
|
+
}], ctorParameters: () => [] });
|
|
17
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/angular/services/calendar-permissions.service/index.ts"],"names":[],"mappings":"AAAA,6FAA6F;AAE7F,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EACL,sBAAsB,EACtB,0BAA0B,GAC3B,MAAM,wBAAwB,CAAC;;AAIhC,MAAM,OAAO,0BAA2B,SAAQ,sBAG/C;IACC;QACE,KAAK,CAAC,sBAAsB,EAAE,0BAA0B,CAAC,CAAC;IAC5D,CAAC;uGANU,0BAA0B;2GAA1B,0BAA0B,cADb,MAAM;;2FACnB,0BAA0B;kBADtC,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PermissionsServiceBase } from '@symbiote-native/angular';
|
|
2
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class RemindersPermissionsService extends PermissionsServiceBase<PermissionResponse> {
|
|
5
|
+
constructor();
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<RemindersPermissionsService, never>;
|
|
7
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<RemindersPermissionsService>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// Angular twin of `../../react`'s `useRemindersPermissions`
|
|
2
|
+
import { Injectable } from '@angular/core';
|
|
3
|
+
import { PermissionsServiceBase } from '@symbiote-native/angular';
|
|
4
|
+
import { getRemindersPermissions, requestRemindersPermissions, } from '../../../core/calendar';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export class RemindersPermissionsService extends PermissionsServiceBase {
|
|
7
|
+
constructor() {
|
|
8
|
+
super(getRemindersPermissions, requestRemindersPermissions);
|
|
9
|
+
}
|
|
10
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RemindersPermissionsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
11
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RemindersPermissionsService, providedIn: 'root' });
|
|
12
|
+
}
|
|
13
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: RemindersPermissionsService, decorators: [{
|
|
14
|
+
type: Injectable,
|
|
15
|
+
args: [{ providedIn: 'root' }]
|
|
16
|
+
}], ctorParameters: () => [] });
|
|
17
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/angular/services/reminders-permissions.service/index.ts"],"names":[],"mappings":"AAAA,4DAA4D;AAE5D,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAClE,OAAO,EACL,uBAAuB,EACvB,2BAA2B,GAC5B,MAAM,wBAAwB,CAAC;;AAIhC,MAAM,OAAO,2BAA4B,SAAQ,sBAA0C;IACzF;QACE,KAAK,CAAC,uBAAuB,EAAE,2BAA2B,CAAC,CAAC;IAC9D,CAAC;uGAHU,2BAA2B;2GAA3B,2BAA2B,cADd,MAAM;;2FACnB,2BAA2B;kBADvC,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { expoCalendarNext } from './native-module';
|
|
2
|
+
import type { NativeExpoCalendarAttendee } from './native-module';
|
|
3
|
+
import type { IAttendeePatch } from './types';
|
|
4
|
+
/** @platform android - iOS registers this class with no properties or methods. */
|
|
5
|
+
export declare class ExpoCalendarAttendee extends expoCalendarNext.ExpoCalendarAttendee {
|
|
6
|
+
update(details: IAttendeePatch): Promise<void>;
|
|
7
|
+
delete(): Promise<void>;
|
|
8
|
+
}
|
|
9
|
+
export declare function upgradeToExpoCalendarAttendee(native: NativeExpoCalendarAttendee): ExpoCalendarAttendee;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { UnavailabilityError } from 'expo-modules-core';
|
|
2
|
+
import { expoCalendarNext } from './native-module';
|
|
3
|
+
import { getNullableDetailsFields, stringifyDateValues } from './utils';
|
|
4
|
+
/** @platform android - iOS registers this class with no properties or methods. */
|
|
5
|
+
export class ExpoCalendarAttendee extends expoCalendarNext.ExpoCalendarAttendee {
|
|
6
|
+
async update(details) {
|
|
7
|
+
if (!super.update) {
|
|
8
|
+
throw new UnavailabilityError('ExpoCalendarAttendee', 'update');
|
|
9
|
+
}
|
|
10
|
+
return super.update(stringifyDateValues(details), getNullableDetailsFields(details));
|
|
11
|
+
}
|
|
12
|
+
async delete() {
|
|
13
|
+
if (!super.delete) {
|
|
14
|
+
throw new UnavailabilityError('ExpoCalendarAttendee', 'delete');
|
|
15
|
+
}
|
|
16
|
+
return super.delete();
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
function isExpoCalendarAttendee(value) {
|
|
20
|
+
return value instanceof ExpoCalendarAttendee;
|
|
21
|
+
}
|
|
22
|
+
export function upgradeToExpoCalendarAttendee(native) {
|
|
23
|
+
Object.setPrototypeOf(native, ExpoCalendarAttendee.prototype);
|
|
24
|
+
if (!isExpoCalendarAttendee(native)) {
|
|
25
|
+
throw new Error('unreachable - just reassigned the prototype to ExpoCalendarAttendee');
|
|
26
|
+
}
|
|
27
|
+
return native;
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=attendee.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attendee.js","sourceRoot":"","sources":["../../src/core/attendee.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAGnD,OAAO,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAExE,kFAAkF;AAClF,MAAM,OAAO,oBACX,SAAQ,gBAAgB,CAAC,oBAAoB;IAEpC,KAAK,CAAC,MAAM,CAAC,OAAuB;QAC3C,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;YAClB,MAAM,IAAI,mBAAmB,CAAC,sBAAsB,EAAE,QAAQ,CAAC,CAAC;QAClE,CAAC;QACD,OAAO,KAAK,CAAC,MAAM,CACjB,mBAAmB,CAAC,OAAO,CAAC,EAC5B,wBAAwB,CAAC,OAAO,CAAC,CAClC,CAAC;IACJ,CAAC;IAEQ,KAAK,CAAC,MAAM;QACnB,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;YAClB,MAAM,IAAI,mBAAmB,CAAC,sBAAsB,EAAE,QAAQ,CAAC,CAAC;QAClE,CAAC;QACD,OAAO,KAAK,CAAC,MAAM,EAAE,CAAC;IACxB,CAAC;CACF;AAED,SAAS,sBAAsB,CAAC,KAAc;IAC5C,OAAO,KAAK,YAAY,oBAAoB,CAAC;AAC/C,CAAC;AAED,MAAM,UAAU,6BAA6B,CAC3C,MAAkC;IAElC,MAAM,CAAC,cAAc,CAAC,MAAM,EAAE,oBAAoB,CAAC,SAAS,CAAC,CAAC;IAC9D,IAAI,CAAC,sBAAsB,CAAC,MAAM,CAAC,EAAE,CAAC;QACpC,MAAM,IAAI,KAAK,CACb,qEAAqE,CACtE,CAAC;IACJ,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { splitWriteOnlyPermissionOptions } from '@symbiote-native/engine';
|
|
2
|
+
export type ICalendarPermissionMethodOptions = {
|
|
3
|
+
writeOnly?: boolean;
|
|
4
|
+
};
|
|
5
|
+
export declare const calendarPermissionMethods: {
|
|
6
|
+
getMethod: (options?: ICalendarPermissionMethodOptions) => Promise<import("expo-modules-core").PermissionResponse>;
|
|
7
|
+
requestMethod: (options?: ICalendarPermissionMethodOptions) => Promise<import("expo-modules-core").PermissionResponse>;
|
|
8
|
+
};
|
|
9
|
+
export declare const splitCalendarPermissionOptions: typeof splitWriteOnlyPermissionOptions;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// `methods` every adapter's `useCalendarPermissions` binds to the shared
|
|
2
|
+
// `@symbiote-native/{react,vue,solid,svelte}` `createPermissionHook` factory
|
|
3
|
+
import { getCalendarPermissions, requestCalendarPermissions } from './calendar';
|
|
4
|
+
import { splitWriteOnlyPermissionOptions } from '@symbiote-native/engine';
|
|
5
|
+
export const calendarPermissionMethods = {
|
|
6
|
+
getMethod: (options) => getCalendarPermissions(options?.writeOnly),
|
|
7
|
+
requestMethod: (options) => requestCalendarPermissions(options?.writeOnly),
|
|
8
|
+
};
|
|
9
|
+
export const splitCalendarPermissionOptions = splitWriteOnlyPermissionOptions;
|
|
10
|
+
//# sourceMappingURL=calendar-permission-api.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-permission-api.js","sourceRoot":"","sources":["../../src/core/calendar-permission-api.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,6EAA6E;AAE7E,OAAO,EAAE,sBAAsB,EAAE,0BAA0B,EAAE,MAAM,YAAY,CAAC;AAChF,OAAO,EAAE,+BAA+B,EAAE,MAAM,yBAAyB,CAAC;AAI1E,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACvC,SAAS,EAAE,CAAC,OAA0C,EAAE,EAAE,CACxD,sBAAsB,CAAC,OAAO,EAAE,SAAS,CAAC;IAC5C,aAAa,EAAE,CAAC,OAA0C,EAAE,EAAE,CAC5D,0BAA0B,CAAC,OAAO,EAAE,SAAS,CAAC;CACjD,CAAC;AAEF,MAAM,CAAC,MAAM,8BAA8B,GAAG,+BAA+B,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { PermissionResponse } from 'expo-modules-core';
|
|
2
|
+
import { expoCalendarNext } from './native-module';
|
|
3
|
+
import type { IAddEventWithFormOptions, ICalendarInput, ICalendarPatch, IDialogEventResult, IEventInput, IReminderInput, ISource } from './types';
|
|
4
|
+
import type { EntityTypes } from './enums';
|
|
5
|
+
import { ExpoCalendarEvent } from './event';
|
|
6
|
+
import { ExpoCalendarReminder } from './reminder';
|
|
7
|
+
export declare class ExpoCalendar extends expoCalendarNext.ExpoCalendar {
|
|
8
|
+
createEvent(details: IEventInput): Promise<ExpoCalendarEvent>;
|
|
9
|
+
/** @platform ios */
|
|
10
|
+
createReminder(details: IReminderInput): Promise<ExpoCalendarReminder>;
|
|
11
|
+
listEvents(startDate: Date, endDate: Date): Promise<ExpoCalendarEvent[]>;
|
|
12
|
+
/** @platform ios */
|
|
13
|
+
listReminders(startDate?: string | Date | null, endDate?: string | Date | null, status?: string | null): Promise<ExpoCalendarReminder[]>;
|
|
14
|
+
update(details: ICalendarPatch): Promise<void>;
|
|
15
|
+
addEventWithForm(options?: IAddEventWithFormOptions): Promise<IDialogEventResult>;
|
|
16
|
+
delete(): Promise<void>;
|
|
17
|
+
static get(calendarId: string): Promise<ExpoCalendar>;
|
|
18
|
+
}
|
|
19
|
+
/** @platform ios - Android has no single system-managed default calendar. */
|
|
20
|
+
export declare function getDefaultCalendarSync(): ExpoCalendar;
|
|
21
|
+
export declare function getCalendars(entityType?: EntityTypes): Promise<ExpoCalendar[]>;
|
|
22
|
+
export declare function createCalendar(details?: ICalendarInput): Promise<ExpoCalendar>;
|
|
23
|
+
/** @platform ios */
|
|
24
|
+
export declare function presentPicker(): Promise<ExpoCalendar | null>;
|
|
25
|
+
/** Searches events across several calendars at once - use `calendar.listEvents()` for one. */
|
|
26
|
+
export declare function listEvents(calendars: (string | ExpoCalendar)[], startDate: Date, endDate: Date): Promise<ExpoCalendarEvent[]>;
|
|
27
|
+
export declare function requestCalendarPermissions(writeOnly?: boolean): Promise<PermissionResponse>;
|
|
28
|
+
export declare function getCalendarPermissions(writeOnly?: boolean): Promise<PermissionResponse>;
|
|
29
|
+
/** @platform ios */
|
|
30
|
+
export declare function requestRemindersPermissions(): Promise<PermissionResponse>;
|
|
31
|
+
/** @platform ios */
|
|
32
|
+
export declare function getRemindersPermissions(): Promise<PermissionResponse>;
|
|
33
|
+
/** @platform ios - Android has no first-class calendar-sources API. */
|
|
34
|
+
export declare function getSourcesSync(): ISource[];
|