@ebarooni/capacitor-calendar 8.7.1 → 8.8.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.
Files changed (76) hide show
  1. package/README.md +191 -137
  2. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/CreateEventWithPromptResult.kt +1 -0
  3. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/GetDefaultCalendarResult.kt +1 -0
  4. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/ListCalendarsResult.kt +1 -0
  5. package/dist/docs.json +463 -81
  6. package/dist/esm/index.d.ts +5 -1
  7. package/dist/esm/index.js.map +1 -1
  8. package/dist/esm/schemas/enums/calendar-permission-scope.d.ts +1 -1
  9. package/dist/esm/schemas/enums/calendar-permission-scope.js +1 -1
  10. package/dist/esm/schemas/enums/calendar-permission-scope.js.map +1 -1
  11. package/dist/esm/schemas/interfaces/calendar.d.ts +10 -2
  12. package/dist/esm/schemas/interfaces/calendar.js.map +1 -1
  13. package/dist/esm/schemas/interfaces/create-calendar-options.d.ts +6 -4
  14. package/dist/esm/schemas/interfaces/create-calendar-options.js.map +1 -1
  15. package/dist/esm/schemas/interfaces/create-event-options.d.ts +10 -1
  16. package/dist/esm/schemas/interfaces/create-event-options.js.map +1 -1
  17. package/dist/esm/schemas/interfaces/create-event-result.d.ts +0 -2
  18. package/dist/esm/schemas/interfaces/create-event-result.js.map +1 -1
  19. package/dist/esm/schemas/interfaces/create-event-with-prompt-options.d.ts +36 -10
  20. package/dist/esm/schemas/interfaces/create-event-with-prompt-options.js.map +1 -1
  21. package/dist/esm/schemas/interfaces/create-event-with-prompt-result.d.ts +10 -1
  22. package/dist/esm/schemas/interfaces/create-event-with-prompt-result.js.map +1 -1
  23. package/dist/esm/schemas/interfaces/create-reminder-options.d.ts +2 -0
  24. package/dist/esm/schemas/interfaces/create-reminder-options.js.map +1 -1
  25. package/dist/esm/schemas/interfaces/create-reminders-list-options.d.ts +12 -7
  26. package/dist/esm/schemas/interfaces/create-reminders-list-options.js.map +1 -1
  27. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.d.ts +12 -0
  28. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.js +2 -0
  29. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.js.map +1 -0
  30. package/dist/esm/schemas/interfaces/event-recurrence-rule.d.ts +9 -9
  31. package/dist/esm/schemas/interfaces/event-recurrence-rule.js.map +1 -1
  32. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.d.ts +13 -0
  33. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.js +2 -0
  34. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.js.map +1 -0
  35. package/dist/esm/schemas/interfaces/get-reminders-lists-result.d.ts +13 -0
  36. package/dist/esm/schemas/interfaces/get-reminders-lists-result.js +2 -0
  37. package/dist/esm/schemas/interfaces/get-reminders-lists-result.js.map +1 -0
  38. package/dist/esm/schemas/interfaces/modify-calendar-options.d.ts +6 -2
  39. package/dist/esm/schemas/interfaces/modify-calendar-options.js.map +1 -1
  40. package/dist/esm/schemas/interfaces/modify-event-with-prompt-options.d.ts +77 -2
  41. package/dist/esm/schemas/interfaces/modify-event-with-prompt-options.js.map +1 -1
  42. package/dist/esm/schemas/interfaces/modify-reminder-options.d.ts +3 -0
  43. package/dist/esm/schemas/interfaces/modify-reminder-options.js.map +1 -1
  44. package/dist/esm/schemas/interfaces/reminder.d.ts +2 -0
  45. package/dist/esm/schemas/interfaces/reminder.js.map +1 -1
  46. package/dist/esm/schemas/interfaces/reminders-list.d.ts +6 -0
  47. package/dist/esm/schemas/interfaces/reminders-list.js.map +1 -1
  48. package/dist/esm/schemas/interfaces/update-reminders-list-options.d.ts +8 -5
  49. package/dist/esm/schemas/interfaces/update-reminders-list-options.js.map +1 -1
  50. package/dist/esm/schemas/types/system-color-name.d.ts +6 -0
  51. package/dist/esm/schemas/types/system-color-name.js +2 -0
  52. package/dist/esm/schemas/types/system-color-name.js.map +1 -0
  53. package/dist/esm/sub-definitions/event-operations.d.ts +7 -10
  54. package/dist/esm/sub-definitions/event-operations.js.map +1 -1
  55. package/dist/esm/sub-definitions/reminders-access.d.ts +1 -1
  56. package/dist/esm/sub-definitions/reminders-access.js.map +1 -1
  57. package/dist/esm/sub-definitions/reminders-operations.d.ts +41 -16
  58. package/dist/esm/sub-definitions/reminders-operations.js.map +1 -1
  59. package/dist/esm/web/ics.d.ts +8 -2
  60. package/dist/esm/web/ics.js +64 -22
  61. package/dist/esm/web/ics.js.map +1 -1
  62. package/dist/esm/web.d.ts +8 -15
  63. package/dist/esm/web.js +100 -5
  64. package/dist/esm/web.js.map +1 -1
  65. package/dist/plugin.cjs.js +165 -29
  66. package/dist/plugin.cjs.js.map +1 -1
  67. package/dist/plugin.js +165 -29
  68. package/dist/plugin.js.map +1 -1
  69. package/ios/Plugin/Models/Inputs/CreateCalendarInput.swift +5 -2
  70. package/ios/Plugin/Models/Inputs/CreateRemindersListInput.swift +4 -18
  71. package/ios/Plugin/Models/Inputs/ModifyCalendarInput.swift +2 -2
  72. package/ios/Plugin/Models/Inputs/UpdateRemindersListInput.swift +4 -18
  73. package/ios/Plugin/Models/Results/CreateEventWithPromptResult.swift +1 -0
  74. package/ios/Plugin/Utils/ImplementationHelper.swift +44 -0
  75. package/ios/Plugin/Utils/UIColorFromHexExtension.swift +5 -0
  76. package/package.json +1 -1
@@ -0,0 +1,13 @@
1
+ import type { RemindersList } from './reminders-list';
2
+ /**
3
+ * @since 7.1.0
4
+ */
5
+ export interface GetDefaultRemindersListResult {
6
+ /**
7
+ * The default reminders list, or `null` when none exists.
8
+ *
9
+ * @platform iOS
10
+ * @since 7.1.0
11
+ */
12
+ result: RemindersList | null;
13
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=get-default-reminders-list-result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-default-reminders-list-result.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/get-default-reminders-list-result.ts"],"names":[],"mappings":"","sourcesContent":["import type { RemindersList } from './reminders-list';\n\n/**\n * @since 7.1.0\n */\nexport interface GetDefaultRemindersListResult {\n /**\n * The default reminders list, or `null` when none exists.\n *\n * @platform iOS\n * @since 7.1.0\n */\n result: RemindersList | null;\n}\n"]}
@@ -0,0 +1,13 @@
1
+ import type { RemindersList } from './reminders-list';
2
+ /**
3
+ * @since 7.1.0
4
+ */
5
+ export interface GetRemindersListsResult {
6
+ /**
7
+ * All available reminders lists.
8
+ *
9
+ * @platform iOS
10
+ * @since 7.1.0
11
+ */
12
+ result: RemindersList[];
13
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=get-reminders-lists-result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"get-reminders-lists-result.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/get-reminders-lists-result.ts"],"names":[],"mappings":"","sourcesContent":["import type { RemindersList } from './reminders-list';\n\n/**\n * @since 7.1.0\n */\nexport interface GetRemindersListsResult {\n /**\n * All available reminders lists.\n *\n * @platform iOS\n * @since 7.1.0\n */\n result: RemindersList[];\n}\n"]}
@@ -1,3 +1,4 @@
1
+ import type { SystemColorName } from '../types/system-color-name';
1
2
  /**
2
3
  * @since 7.2.0
3
4
  */
@@ -18,11 +19,14 @@ export interface ModifyCalendarOptions {
18
19
  */
19
20
  title?: string;
20
21
  /**
21
- * The color of the calendar as `#RRGGBB` or `#RRGGBBAA`.
22
+ * Named color (`blue`, …) or hex `#RRGGBB` / `#RRGGBBAA`.
23
+ * If omitted, the color is left unchanged.
24
+ * On Android, only hex is accepted; named colors reject with `Invalid color format.`
22
25
  *
23
26
  * @platform Android, iOS
27
+ * @example 'indigo'
24
28
  * @example #007AFF
25
29
  * @since 7.2.0
26
30
  */
27
- color?: string;
31
+ color?: SystemColorName | `#${string}`;
28
32
  }
@@ -1 +1 @@
1
- {"version":3,"file":"modify-calendar-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-calendar-options.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 7.2.0\n */\nexport interface ModifyCalendarOptions {\n /**\n * @platform Android, iOS\n * @since 7.2.0\n */\n id: string;\n /**\n * Display title of the calendar.\n *\n * On Android this updates both `CALENDAR_DISPLAY_NAME` (`title`) and\n * `Calendars.NAME` (`internalTitle`).\n *\n * @platform Android, iOS\n * @since 7.2.0\n */\n title?: string;\n /**\n * The color of the calendar as `#RRGGBB` or `#RRGGBBAA`.\n *\n * @platform Android, iOS\n * @example #007AFF\n * @since 7.2.0\n */\n color?: string;\n}\n"]}
1
+ {"version":3,"file":"modify-calendar-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-calendar-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { SystemColorName } from '../types/system-color-name';\n\n/**\n * @since 7.2.0\n */\nexport interface ModifyCalendarOptions {\n /**\n * @platform Android, iOS\n * @since 7.2.0\n */\n id: string;\n /**\n * Display title of the calendar.\n *\n * On Android this updates both `CALENDAR_DISPLAY_NAME` (`title`) and\n * `Calendars.NAME` (`internalTitle`).\n *\n * @platform Android, iOS\n * @since 7.2.0\n */\n title?: string;\n /**\n * Named color (`blue`, …) or hex `#RRGGBB` / `#RRGGBBAA`.\n * If omitted, the color is left unchanged.\n * On Android, only hex is accepted; named colors reject with `Invalid color format.`\n *\n * @platform Android, iOS\n * @example 'indigo'\n * @example #007AFF\n * @since 7.2.0\n */\n color?: SystemColorName | `#${string}`;\n}\n"]}
@@ -1,8 +1,44 @@
1
- import type { CreateEventWithPromptOptions } from './create-event-with-prompt-options';
1
+ import type { EventAvailability } from '../enums/event-availability';
2
+ import type { EventRecurrenceRule } from './event-recurrence-rule';
2
3
  /**
3
4
  * @since 7.1.0
4
5
  */
5
- export interface ModifyEventWithPromptOptions extends CreateEventWithPromptOptions {
6
+ export interface ModifyEventWithPromptOptions {
7
+ /**
8
+ * Alert times in minutes relative to the event start.
9
+ * Use negative numbers for reminders before the start, and positive numbers for reminders after the start.
10
+ * On iOS only 2 alerts are supported.
11
+ *
12
+ * @example
13
+ * // -1440 -> 1 day before
14
+ * // -60 -> 1 hour before
15
+ * // 30 -> 30 minutes after
16
+ * [-1440, -60, 30]
17
+ *
18
+ * @platform iOS
19
+ * @since 7.1.0
20
+ */
21
+ alerts?: number[];
22
+ /**
23
+ * @platform Android, iOS
24
+ * @since 7.1.0
25
+ */
26
+ availability?: EventAvailability;
27
+ /**
28
+ * @platform iOS
29
+ * @since 0.1.0
30
+ */
31
+ calendarId?: string;
32
+ /**
33
+ * @platform Android, iOS
34
+ * @since 7.1.0
35
+ */
36
+ description?: string;
37
+ /**
38
+ * @platform Android, iOS
39
+ * @since 0.1.0
40
+ */
41
+ endDate?: number;
6
42
  /**
7
43
  * The ID of the event to be modified.
8
44
  *
@@ -10,4 +46,43 @@ export interface ModifyEventWithPromptOptions extends CreateEventWithPromptOptio
10
46
  * @since 7.1.0
11
47
  */
12
48
  id: string;
49
+ /**
50
+ * An array of emails to invite.
51
+ *
52
+ * @platform Android
53
+ * @since 7.1.0
54
+ */
55
+ invitees?: string[];
56
+ /**
57
+ * @platform Android, iOS
58
+ * @since 0.1.0
59
+ */
60
+ isAllDay?: boolean;
61
+ /**
62
+ * @platform Android, iOS
63
+ * @since 0.1.0
64
+ */
65
+ location?: string;
66
+ /**
67
+ * Rules for creating a recurring event.
68
+ *
69
+ * @platform Android, iOS
70
+ * @since 7.3.0
71
+ */
72
+ recurrence?: EventRecurrenceRule;
73
+ /**
74
+ * @platform Android, iOS
75
+ * @since 0.1.0
76
+ */
77
+ startDate?: number;
78
+ /**
79
+ * @platform Android, iOS
80
+ * @since 0.1.0
81
+ */
82
+ title?: string;
83
+ /**
84
+ * @platform iOS
85
+ * @since 0.1.0
86
+ */
87
+ url?: string;
13
88
  }
@@ -1 +1 @@
1
- {"version":3,"file":"modify-event-with-prompt-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-event-with-prompt-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { CreateEventWithPromptOptions } from './create-event-with-prompt-options';\n\n/**\n * @since 7.1.0\n */\nexport interface ModifyEventWithPromptOptions extends CreateEventWithPromptOptions {\n /**\n * The ID of the event to be modified.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n id: string;\n}\n"]}
1
+ {"version":3,"file":"modify-event-with-prompt-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-event-with-prompt-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { EventAvailability } from '../enums/event-availability';\n\nimport type { EventRecurrenceRule } from './event-recurrence-rule';\n\n/**\n * @since 7.1.0\n */\nexport interface ModifyEventWithPromptOptions {\n /**\n * Alert times in minutes relative to the event start.\n * Use negative numbers for reminders before the start, and positive numbers for reminders after the start.\n * On iOS only 2 alerts are supported.\n *\n * @example\n * // -1440 -> 1 day before\n * // -60 -> 1 hour before\n * // 30 -> 30 minutes after\n * [-1440, -60, 30]\n *\n * @platform iOS\n * @since 7.1.0\n */\n alerts?: number[];\n /**\n * @platform Android, iOS\n * @since 7.1.0\n */\n availability?: EventAvailability;\n /**\n * @platform iOS\n * @since 0.1.0\n */\n calendarId?: string;\n /**\n * @platform Android, iOS\n * @since 7.1.0\n */\n description?: string;\n /**\n * @platform Android, iOS\n * @since 0.1.0\n */\n endDate?: number;\n /**\n * The ID of the event to be modified.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n id: string;\n /**\n * An array of emails to invite.\n *\n * @platform Android\n * @since 7.1.0\n */\n invitees?: string[];\n /**\n * @platform Android, iOS\n * @since 0.1.0\n */\n isAllDay?: boolean;\n /**\n * @platform Android, iOS\n * @since 0.1.0\n */\n location?: string;\n /**\n * Rules for creating a recurring event.\n *\n * @platform Android, iOS\n * @since 7.3.0\n */\n recurrence?: EventRecurrenceRule;\n /**\n * @platform Android, iOS\n * @since 0.1.0\n */\n startDate?: number;\n /**\n * @platform Android, iOS\n * @since 0.1.0\n */\n title?: string;\n /**\n * @platform iOS\n * @since 0.1.0\n */\n url?: string;\n}\n"]}
@@ -81,6 +81,9 @@ export interface ModifyReminderOptions {
81
81
  */
82
82
  notes?: string | null;
83
83
  /**
84
+ * Priority: `0` none, `1` highest through `9` lowest.
85
+ * Omit to leave the existing value unchanged.
86
+ *
84
87
  * @since 7.1.0
85
88
  */
86
89
  priority?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"modify-reminder-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-reminder-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { RecurrenceRule } from './recurrence-rule';\n\n/**\n * @since 7.1.0\n */\nexport interface ModifyReminderOptions {\n /**\n * Alert times in minutes relative to the reminder start.\n * Use negative numbers for alerts before the start, and positive numbers for alerts after the start.\n * Omit or pass `undefined` to leave existing alerts unchanged.\n * Pass `null` or an empty array `[]` to clear alerts.\n * On iOS, when both `startDate` and `dueDate` are cleared in the same call, alerts are cleared even if `alerts` is set.\n * When clearing dates across separate batched calls, pass `alerts: null` or `[]` explicitly.\n *\n * On iOS only 2 alerts are supported.\n *\n * @example\n * // -1440 -> 1 day before\n * // -60 -> 1 hour before\n * // 30 -> 30 minutes after\n * [-1440, -60, 30]\n *\n * @since 7.1.0\n */\n alerts?: number[] | null;\n /**\n * Whether to save immediately (`true`) or batch changes for later (`false`).\n * Pass `false` to batch multiple changes and commit them together using `CapacitorCalendar.commit()`, which is more efficient than committing each save individually.\n *\n * @default true\n * @platform iOS\n * @see {@link CalendarOperations#commit}\n * @since 8.7.0\n */\n commit?: boolean;\n /**\n * When the reminder was completed, in milliseconds since the epoch.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * Clearing this date does not mark the reminder incomplete; set `isCompleted` to `false` for that.\n *\n * @since 7.1.0\n */\n completionDate?: number | null;\n /**\n * When the reminder is due, in milliseconds since the epoch.\n * On iOS, if `startDate` is omitted and the reminder has no start, it is set to this value.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * Clearing only `dueDate` leaves an existing start unchanged (including a start previously copied from due).\n * Pass `startDate: null` together with `dueDate: null` to remove scheduling.\n *\n * @since 7.1.0\n */\n dueDate?: number | null;\n /**\n * @since 7.1.0\n */\n id: string;\n /**\n * @since 7.1.0\n */\n isCompleted?: boolean;\n /**\n * @since 7.1.0\n */\n listId?: string;\n /**\n * Location for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n location?: string | null;\n /**\n * Notes for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n notes?: string | null;\n /**\n * @since 7.1.0\n */\n priority?: number;\n /**\n * Recurrence rule for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @platform iOS\n * @since 7.1.0\n */\n recurrence?: RecurrenceRule | null;\n /**\n * When the reminder starts, in milliseconds since the epoch.\n * Relative `alerts` use this date.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * If a due date remains, clearing start sets start to the due date (it does not keep the previous start).\n * Pass `dueDate: null` as well to remove scheduling.\n *\n * @since 7.1.0\n */\n startDate?: number | null;\n /**\n * @since 7.1.0\n */\n title?: string;\n /**\n * URL associated with the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n url?: string | null;\n}\n"]}
1
+ {"version":3,"file":"modify-reminder-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/modify-reminder-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { RecurrenceRule } from './recurrence-rule';\n\n/**\n * @since 7.1.0\n */\nexport interface ModifyReminderOptions {\n /**\n * Alert times in minutes relative to the reminder start.\n * Use negative numbers for alerts before the start, and positive numbers for alerts after the start.\n * Omit or pass `undefined` to leave existing alerts unchanged.\n * Pass `null` or an empty array `[]` to clear alerts.\n * On iOS, when both `startDate` and `dueDate` are cleared in the same call, alerts are cleared even if `alerts` is set.\n * When clearing dates across separate batched calls, pass `alerts: null` or `[]` explicitly.\n *\n * On iOS only 2 alerts are supported.\n *\n * @example\n * // -1440 -> 1 day before\n * // -60 -> 1 hour before\n * // 30 -> 30 minutes after\n * [-1440, -60, 30]\n *\n * @since 7.1.0\n */\n alerts?: number[] | null;\n /**\n * Whether to save immediately (`true`) or batch changes for later (`false`).\n * Pass `false` to batch multiple changes and commit them together using `CapacitorCalendar.commit()`, which is more efficient than committing each save individually.\n *\n * @default true\n * @platform iOS\n * @see {@link CalendarOperations#commit}\n * @since 8.7.0\n */\n commit?: boolean;\n /**\n * When the reminder was completed, in milliseconds since the epoch.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * Clearing this date does not mark the reminder incomplete; set `isCompleted` to `false` for that.\n *\n * @since 7.1.0\n */\n completionDate?: number | null;\n /**\n * When the reminder is due, in milliseconds since the epoch.\n * On iOS, if `startDate` is omitted and the reminder has no start, it is set to this value.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * Clearing only `dueDate` leaves an existing start unchanged (including a start previously copied from due).\n * Pass `startDate: null` together with `dueDate: null` to remove scheduling.\n *\n * @since 7.1.0\n */\n dueDate?: number | null;\n /**\n * @since 7.1.0\n */\n id: string;\n /**\n * @since 7.1.0\n */\n isCompleted?: boolean;\n /**\n * @since 7.1.0\n */\n listId?: string;\n /**\n * Location for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n location?: string | null;\n /**\n * Notes for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n notes?: string | null;\n /**\n * Priority: `0` none, `1` highest through `9` lowest.\n * Omit to leave the existing value unchanged.\n *\n * @since 7.1.0\n */\n priority?: number;\n /**\n * Recurrence rule for the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @platform iOS\n * @since 7.1.0\n */\n recurrence?: RecurrenceRule | null;\n /**\n * When the reminder starts, in milliseconds since the epoch.\n * Relative `alerts` use this date.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n * If a due date remains, clearing start sets start to the due date (it does not keep the previous start).\n * Pass `dueDate: null` as well to remove scheduling.\n *\n * @since 7.1.0\n */\n startDate?: number | null;\n /**\n * @since 7.1.0\n */\n title?: string;\n /**\n * URL associated with the reminder.\n * Omit or pass `undefined` to leave the existing value unchanged.\n * Since 8.7.0, pass `null` to clear.\n *\n * @since 7.1.0\n */\n url?: string | null;\n}\n"]}
@@ -20,6 +20,8 @@ export interface Reminder {
20
20
  */
21
21
  isCompleted: boolean;
22
22
  /**
23
+ * Priority: `0` none, `1` highest through `9` lowest.
24
+ *
23
25
  * @since 7.1.0
24
26
  */
25
27
  priority: number | null;
@@ -1 +1 @@
1
- {"version":3,"file":"reminder.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/reminder.ts"],"names":[],"mappings":"","sourcesContent":["import type { RecurrenceRule } from './recurrence-rule';\n\n/**\n * @since 7.1.0\n */\nexport interface Reminder {\n /**\n * @since 7.1.0\n */\n id: string;\n /**\n * @since 7.1.0\n */\n title: string | null;\n /**\n * @since 7.1.0\n */\n listId: string | null;\n /**\n * @since 7.1.0\n */\n isCompleted: boolean;\n /**\n * @since 7.1.0\n */\n priority: number | null;\n /**\n * @since 7.1.0\n */\n notes: string | null;\n /**\n * @since 7.1.0\n */\n location: string | null;\n /**\n * @since 7.1.0\n */\n url: string | null;\n /**\n * @since 7.1.0\n */\n startDate: number | null;\n /**\n * @since 7.1.0\n */\n dueDate: number | null;\n /**\n * @since 7.1.0\n */\n completionDate: number | null;\n /**\n * @platform iOS\n * @since 7.1.0\n */\n recurrence: RecurrenceRule[];\n /**\n * @since 7.1.0\n */\n alerts: number[];\n}\n"]}
1
+ {"version":3,"file":"reminder.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/reminder.ts"],"names":[],"mappings":"","sourcesContent":["import type { RecurrenceRule } from './recurrence-rule';\n\n/**\n * @since 7.1.0\n */\nexport interface Reminder {\n /**\n * @since 7.1.0\n */\n id: string;\n /**\n * @since 7.1.0\n */\n title: string | null;\n /**\n * @since 7.1.0\n */\n listId: string | null;\n /**\n * @since 7.1.0\n */\n isCompleted: boolean;\n /**\n * Priority: `0` none, `1` highest through `9` lowest.\n *\n * @since 7.1.0\n */\n priority: number | null;\n /**\n * @since 7.1.0\n */\n notes: string | null;\n /**\n * @since 7.1.0\n */\n location: string | null;\n /**\n * @since 7.1.0\n */\n url: string | null;\n /**\n * @since 7.1.0\n */\n startDate: number | null;\n /**\n * @since 7.1.0\n */\n dueDate: number | null;\n /**\n * @since 7.1.0\n */\n completionDate: number | null;\n /**\n * @platform iOS\n * @since 7.1.0\n */\n recurrence: RecurrenceRule[];\n /**\n * @since 7.1.0\n */\n alerts: number[];\n}\n"]}
@@ -1,5 +1,11 @@
1
1
  import type { Calendar } from './calendar';
2
2
  /**
3
+ * A reminders list on iOS.
4
+ *
5
+ * Same shape as {@link Calendar} today. Android-only calendar fields
6
+ * (`visible`, `accountName`, `ownerAccount`, `maxReminders`, `internalTitle`,
7
+ * `location`) are always `null` on reminder list payloads.
8
+ *
3
9
  * @since 7.1.0
4
10
  */
5
11
  export type RemindersList = Calendar;
@@ -1 +1 @@
1
- {"version":3,"file":"reminders-list.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/reminders-list.ts"],"names":[],"mappings":"","sourcesContent":["import type { Calendar } from './calendar';\n\n/**\n * @since 7.1.0\n */\nexport type RemindersList = Calendar;\n"]}
1
+ {"version":3,"file":"reminders-list.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/reminders-list.ts"],"names":[],"mappings":"","sourcesContent":["import type { Calendar } from './calendar';\n\n/**\n * A reminders list on iOS.\n *\n * Same shape as {@link Calendar} today. Android-only calendar fields\n * (`visible`, `accountName`, `ownerAccount`, `maxReminders`, `internalTitle`,\n * `location`) are always `null` on reminder list payloads.\n *\n * @since 7.1.0\n */\nexport type RemindersList = Calendar;\n"]}
@@ -1,22 +1,25 @@
1
+ import type { SystemColorName } from '../types/system-color-name';
1
2
  /**
2
3
  * @since 8.2.0
3
4
  */
4
5
  export interface UpdateRemindersListOptions {
5
6
  /**
6
- * The new color of the list.
7
+ * Named color (`blue`, …) or hex `#RRGGBB` / `#RRGGBBAA`.
7
8
  * If omitted, the color is left unchanged.
8
9
  *
9
10
  * @example 'indigo'
11
+ * @example #007AFF
10
12
  * @platform iOS
11
- * @since 8.1.0
13
+ * @since 8.2.0
12
14
  */
13
- color?: 'blue' | 'brown' | 'gray' | 'green' | 'indigo' | 'orange' | 'pink' | 'purple' | 'red' | 'teal' | 'yellow';
15
+ color?: SystemColorName | `#${string}`;
14
16
  /**
15
- * Whether to save the update to the event store immediately.
16
- * Pass `false` to batch multiple changes and commit them together using `eventStore.commit()`, which is more efficient than committing each save individually.
17
+ * Whether to save the update immediately.
18
+ * Pass `false` to batch changes and commit them with `CapacitorCalendar.commit()`.
17
19
  *
18
20
  * @default true
19
21
  * @platform iOS
22
+ * @see {@link CalendarOperations#commit}
20
23
  * @since 8.2.0
21
24
  */
22
25
  commit?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"update-reminders-list-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/update-reminders-list-options.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 8.2.0\n */\nexport interface UpdateRemindersListOptions {\n /**\n * The new color of the list.\n * If omitted, the color is left unchanged.\n *\n * @example 'indigo'\n * @platform iOS\n * @since 8.1.0\n */\n color?: 'blue' | 'brown' | 'gray' | 'green' | 'indigo' | 'orange' | 'pink' | 'purple' | 'red' | 'teal' | 'yellow';\n /**\n * Whether to save the update to the event store immediately.\n * Pass `false` to batch multiple changes and commit them together using `eventStore.commit()`, which is more efficient than committing each save individually.\n *\n * @default true\n * @platform iOS\n * @since 8.2.0\n */\n commit?: boolean;\n /**\n * The identifier of the list to update.\n *\n * @example 'A1234567-ABCD-EFGH-IJKL-MNOPQRSTUVWX'\n * @platform iOS\n * @since 8.2.0\n */\n id: string;\n /**\n * The new title of the list.\n * If omitted, the title is left unchanged.\n *\n * @example 'Groceries'\n * @platform iOS\n * @since 8.2.0\n */\n title?: string;\n}\n"]}
1
+ {"version":3,"file":"update-reminders-list-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/update-reminders-list-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { SystemColorName } from '../types/system-color-name';\n\n/**\n * @since 8.2.0\n */\nexport interface UpdateRemindersListOptions {\n /**\n * Named color (`blue`, …) or hex `#RRGGBB` / `#RRGGBBAA`.\n * If omitted, the color is left unchanged.\n *\n * @example 'indigo'\n * @example #007AFF\n * @platform iOS\n * @since 8.2.0\n */\n color?: SystemColorName | `#${string}`;\n /**\n * Whether to save the update immediately.\n * Pass `false` to batch changes and commit them with `CapacitorCalendar.commit()`.\n *\n * @default true\n * @platform iOS\n * @see {@link CalendarOperations#commit}\n * @since 8.2.0\n */\n commit?: boolean;\n /**\n * The identifier of the list to update.\n *\n * @example 'A1234567-ABCD-EFGH-IJKL-MNOPQRSTUVWX'\n * @platform iOS\n * @since 8.2.0\n */\n id: string;\n /**\n * The new title of the list.\n * If omitted, the title is left unchanged.\n *\n * @example 'Groceries'\n * @platform iOS\n * @since 8.2.0\n */\n title?: string;\n}\n"]}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Named iOS system color.
3
+ *
4
+ * @since 8.8.0
5
+ */
6
+ export type SystemColorName = 'blue' | 'brown' | 'gray' | 'green' | 'indigo' | 'orange' | 'pink' | 'purple' | 'red' | 'teal' | 'yellow';
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=system-color-name.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"system-color-name.js","sourceRoot":"","sources":["../../../../src/schemas/types/system-color-name.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Named iOS system color.\n *\n * @since 8.8.0\n */\nexport type SystemColorName =\n | 'blue'\n | 'brown'\n | 'gray'\n | 'green'\n | 'indigo'\n | 'orange'\n | 'pink'\n | 'purple'\n | 'red'\n | 'teal'\n | 'yellow';\n"]}
@@ -12,9 +12,10 @@ import type { ModifyEventWithPromptOptions } from '../schemas/interfaces/modify-
12
12
  import type { EventEditAction } from '../schemas/types/event-edit-action';
13
13
  export interface EventOperations {
14
14
  /**
15
- * Opens the system calendar interface to create a new event.
16
- * On Android always returns `null` for `id`.
17
- * Fetch the events to find the ID of the newly created event.
15
+ * Opens a calendar UI to create an event.
16
+ * On Android and iOS, opens the system editor. On Android, `id` is always `null`.
17
+ * On Web, shows a confirm dialog, then builds an `.ics` `File` when the user confirms.
18
+ * See MCP `docs://web-behavior` for Web details.
18
19
  *
19
20
  * @example
20
21
  * const options = {
@@ -23,7 +24,7 @@ export interface EventOperations {
23
24
  * }
24
25
  * await CapacitorCalendar.createEventWithPrompt(options)
25
26
  *
26
- * @platform Android, iOS
27
+ * @platform Android, iOS, Web
27
28
  * @since 0.1.0
28
29
  */
29
30
  createEventWithPrompt(options?: CreateEventWithPromptOptions): Promise<CreateEventWithPromptResult>;
@@ -47,19 +48,15 @@ export interface EventOperations {
47
48
  /**
48
49
  * Creates an event in the calendar.
49
50
  * On Android and iOS, inserts into the system calendar and returns its `id`.
50
- * On Web, there is no system calendar store: builds an `.ics` `File` as `ics`.
51
- * The app must download or open that file (for example with `downloadIcsFile(...)`);
52
- * this method does not trigger a download.
51
+ * On Web, builds an `.ics` `File` as `ics` (no calendar store). See MCP `docs://web-behavior`.
53
52
  *
54
53
  * @example
55
54
  * const { id, ics } = await CapacitorCalendar.createEvent({
56
55
  * title: 'Team standup',
57
56
  * startDate: Date.now(),
58
57
  * icsFileName: 'team-standup.ics',
58
+ * autoDownloadIcsFile: true,
59
59
  * });
60
- * if (ics) {
61
- * await downloadIcsFile(ics);
62
- * }
63
60
  *
64
61
  * @platform Android, iOS, Web
65
62
  * @since 0.4.0
@@ -1 +1 @@
1
- {"version":3,"file":"event-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/event-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { CreateEventOptions } from '../schemas/interfaces/create-event-options';\nimport type { CreateEventResult } from '../schemas/interfaces/create-event-result';\nimport type { CreateEventWithPromptOptions } from '../schemas/interfaces/create-event-with-prompt-options';\nimport type { CreateEventWithPromptResult } from '../schemas/interfaces/create-event-with-prompt-result';\nimport type { DeleteEventOptions } from '../schemas/interfaces/delete-event-options';\nimport type { DeleteEventWithPromptOptions } from '../schemas/interfaces/delete-event-with-prompt-options';\nimport type { DeleteEventsByIdOptions } from '../schemas/interfaces/delete-events-by-id-options';\nimport type { ListEventsInRangeOptions } from '../schemas/interfaces/list-events-in-range-options';\nimport type { ListEventsInRangeResult } from '../schemas/interfaces/list-events-in-range-result';\nimport type { ModifyEventOptions } from '../schemas/interfaces/modify-event-options';\nimport type { ModifyEventWithPromptOptions } from '../schemas/interfaces/modify-event-with-prompt-options';\nimport type { EventEditAction } from '../schemas/types/event-edit-action';\n\nexport interface EventOperations {\n /**\n * Opens the system calendar interface to create a new event.\n * On Android always returns `null` for `id`.\n * Fetch the events to find the ID of the newly created event.\n *\n * @example\n * const options = {\n * title: 'Test event',\n * startDate: Date.now(),\n * }\n * await CapacitorCalendar.createEventWithPrompt(options)\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n createEventWithPrompt(options?: CreateEventWithPromptOptions): Promise<CreateEventWithPromptResult>;\n /**\n * Opens a system calendar interface to modify an event.\n * On Android always returns `null`.\n *\n * @example\n * const options = {\n * id: 'EVENT_ID',\n * title: 'New title',\n * }\n * await CapacitorCalendar.modifyEventWithPrompt(options);\n *\n * @platform Android, iOS\n * @since 6.6.0\n */\n modifyEventWithPrompt(options: ModifyEventWithPromptOptions): Promise<{ result: EventEditAction | null }>;\n /**\n * Creates an event in the calendar.\n * On Android and iOS, inserts into the system calendar and returns its `id`.\n * On Web, there is no system calendar store: builds an `.ics` `File` as `ics`.\n * The app must download or open that file (for example with `downloadIcsFile(...)`);\n * this method does not trigger a download.\n *\n * @example\n * const { id, ics } = await CapacitorCalendar.createEvent({\n * title: 'Team standup',\n * startDate: Date.now(),\n * icsFileName: 'team-standup.ics',\n * });\n * if (ics) {\n * await downloadIcsFile(ics);\n * }\n *\n * @platform Android, iOS, Web\n * @since 0.4.0\n */\n createEvent(options: CreateEventOptions): Promise<CreateEventResult>;\n /**\n * Modifies an event.\n *\n * @platform Android, iOS\n * @since 6.6.0\n */\n modifyEvent(options: ModifyEventOptions): Promise<void>;\n /**\n * Deletes multiple events.\n *\n * @deprecated Use `deleteEvent(...)`.\n * @platform Android, iOS\n * @since 0.11.0\n */\n deleteEventsById(options: DeleteEventsByIdOptions): Promise<{ result: DeleteEventsByIdResult }>;\n /**\n * Deletes an event.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n deleteEvent(options: DeleteEventOptions): Promise<void>;\n /**\n * Opens a dialog to delete an event.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n deleteEventWithPrompt(options: DeleteEventWithPromptOptions): Promise<{ deleted: boolean }>;\n /**\n * Retrieves events that overlap a date range.\n *\n * An event is included when its time interval intersects `[from, to]`, including\n * multi-day events that span the range without starting or ending inside it.\n *\n * @example\n * const startOfDay = new Date();\n * startOfDay.setHours(0, 0, 0, 0);\n * const startOfNextDay = new Date(startOfDay);\n * startOfNextDay.setDate(startOfNextDay.getDate() + 1);\n *\n * const { result } = await CapacitorCalendar.listEventsInRange({\n * from: startOfDay.getTime(),\n * to: startOfNextDay.getTime(),\n * });\n *\n * @platform Android, iOS\n * @since 0.10.0\n */\n listEventsInRange(options: ListEventsInRangeOptions): Promise<ListEventsInRangeResult>;\n}\n\n/**\n * @since 7.1.0\n */\nexport interface DeleteEventsByIdResult {\n /**\n * @since 7.1.0\n */\n deleted: string[];\n /**\n * @since 7.1.0\n */\n failed: string[];\n}\n"]}
1
+ {"version":3,"file":"event-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/event-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { CreateEventOptions } from '../schemas/interfaces/create-event-options';\nimport type { CreateEventResult } from '../schemas/interfaces/create-event-result';\nimport type { CreateEventWithPromptOptions } from '../schemas/interfaces/create-event-with-prompt-options';\nimport type { CreateEventWithPromptResult } from '../schemas/interfaces/create-event-with-prompt-result';\nimport type { DeleteEventOptions } from '../schemas/interfaces/delete-event-options';\nimport type { DeleteEventWithPromptOptions } from '../schemas/interfaces/delete-event-with-prompt-options';\nimport type { DeleteEventsByIdOptions } from '../schemas/interfaces/delete-events-by-id-options';\nimport type { ListEventsInRangeOptions } from '../schemas/interfaces/list-events-in-range-options';\nimport type { ListEventsInRangeResult } from '../schemas/interfaces/list-events-in-range-result';\nimport type { ModifyEventOptions } from '../schemas/interfaces/modify-event-options';\nimport type { ModifyEventWithPromptOptions } from '../schemas/interfaces/modify-event-with-prompt-options';\nimport type { EventEditAction } from '../schemas/types/event-edit-action';\n\nexport interface EventOperations {\n /**\n * Opens a calendar UI to create an event.\n * On Android and iOS, opens the system editor. On Android, `id` is always `null`.\n * On Web, shows a confirm dialog, then builds an `.ics` `File` when the user confirms.\n * See MCP `docs://web-behavior` for Web details.\n *\n * @example\n * const options = {\n * title: 'Test event',\n * startDate: Date.now(),\n * }\n * await CapacitorCalendar.createEventWithPrompt(options)\n *\n * @platform Android, iOS, Web\n * @since 0.1.0\n */\n createEventWithPrompt(options?: CreateEventWithPromptOptions): Promise<CreateEventWithPromptResult>;\n /**\n * Opens a system calendar interface to modify an event.\n * On Android always returns `null`.\n *\n * @example\n * const options = {\n * id: 'EVENT_ID',\n * title: 'New title',\n * }\n * await CapacitorCalendar.modifyEventWithPrompt(options);\n *\n * @platform Android, iOS\n * @since 6.6.0\n */\n modifyEventWithPrompt(options: ModifyEventWithPromptOptions): Promise<{ result: EventEditAction | null }>;\n /**\n * Creates an event in the calendar.\n * On Android and iOS, inserts into the system calendar and returns its `id`.\n * On Web, builds an `.ics` `File` as `ics` (no calendar store). See MCP `docs://web-behavior`.\n *\n * @example\n * const { id, ics } = await CapacitorCalendar.createEvent({\n * title: 'Team standup',\n * startDate: Date.now(),\n * icsFileName: 'team-standup.ics',\n * autoDownloadIcsFile: true,\n * });\n *\n * @platform Android, iOS, Web\n * @since 0.4.0\n */\n createEvent(options: CreateEventOptions): Promise<CreateEventResult>;\n /**\n * Modifies an event.\n *\n * @platform Android, iOS\n * @since 6.6.0\n */\n modifyEvent(options: ModifyEventOptions): Promise<void>;\n /**\n * Deletes multiple events.\n *\n * @deprecated Use `deleteEvent(...)`.\n * @platform Android, iOS\n * @since 0.11.0\n */\n deleteEventsById(options: DeleteEventsByIdOptions): Promise<{ result: DeleteEventsByIdResult }>;\n /**\n * Deletes an event.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n deleteEvent(options: DeleteEventOptions): Promise<void>;\n /**\n * Opens a dialog to delete an event.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n deleteEventWithPrompt(options: DeleteEventWithPromptOptions): Promise<{ deleted: boolean }>;\n /**\n * Retrieves events that overlap a date range.\n *\n * An event is included when its time interval intersects `[from, to]`, including\n * multi-day events that span the range without starting or ending inside it.\n *\n * @example\n * const startOfDay = new Date();\n * startOfDay.setHours(0, 0, 0, 0);\n * const startOfNextDay = new Date(startOfDay);\n * startOfNextDay.setDate(startOfNextDay.getDate() + 1);\n *\n * const { result } = await CapacitorCalendar.listEventsInRange({\n * from: startOfDay.getTime(),\n * to: startOfNextDay.getTime(),\n * });\n *\n * @platform Android, iOS\n * @since 0.10.0\n */\n listEventsInRange(options: ListEventsInRangeOptions): Promise<ListEventsInRangeResult>;\n}\n\n/**\n * @since 7.1.0\n */\nexport interface DeleteEventsByIdResult {\n /**\n * @since 7.1.0\n */\n deleted: string[];\n /**\n * @since 7.1.0\n */\n failed: string[];\n}\n"]}
@@ -12,7 +12,7 @@ export interface RemindersAccess {
12
12
  * | Platform | Required |
13
13
  * |-----------|---------------------|
14
14
  * | iOS 17+ | `NSRemindersFullAccessUsageDescription` |
15
- * | iOS 10-16 | `NSRemindersUsageDescription` |
15
+ * | iOS 13-16 | `NSRemindersUsageDescription` |
16
16
  *
17
17
  * @throws {Error} when EventKit fails or required Info.plist keys are missing.
18
18
  *
@@ -1 +1 @@
1
- {"version":3,"file":"reminders-access.js","sourceRoot":"","sources":["../../../src/sub-definitions/reminders-access.ts"],"names":[],"mappings":"","sourcesContent":["import type { PermissionState } from '@capacitor/core';\n\n/**\n * @since 7.1.0\n */\nexport interface RemindersAccess {\n /**\n * Requests read and write access to the reminders.\n * Resolves with `\"granted\"` or `\"denied\"` (never `\"prompt\"`).\n * A grant covers both `readReminders` and `writeReminders`.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSRemindersFullAccessUsageDescription` |\n * | iOS 10-16 | `NSRemindersUsageDescription` |\n *\n * @throws {Error} when EventKit fails or required Info.plist keys are missing.\n *\n * @platform iOS\n * @see {@link CalendarPermissionScope}\n * @since 5.4.0\n */\n requestFullRemindersAccess(): Promise<{ result: PermissionState }>;\n}\n"]}
1
+ {"version":3,"file":"reminders-access.js","sourceRoot":"","sources":["../../../src/sub-definitions/reminders-access.ts"],"names":[],"mappings":"","sourcesContent":["import type { PermissionState } from '@capacitor/core';\n\n/**\n * @since 7.1.0\n */\nexport interface RemindersAccess {\n /**\n * Requests read and write access to the reminders.\n * Resolves with `\"granted\"` or `\"denied\"` (never `\"prompt\"`).\n * A grant covers both `readReminders` and `writeReminders`.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSRemindersFullAccessUsageDescription` |\n * | iOS 13-16 | `NSRemindersUsageDescription` |\n *\n * @throws {Error} when EventKit fails or required Info.plist keys are missing.\n *\n * @platform iOS\n * @see {@link CalendarPermissionScope}\n * @since 5.4.0\n */\n requestFullRemindersAccess(): Promise<{ result: PermissionState }>;\n}\n"]}
@@ -1,25 +1,30 @@
1
- import type { CalendarSource } from '../schemas/interfaces/calendar-source';
2
1
  import type { CreateReminderOptions } from '../schemas/interfaces/create-reminder-options';
3
2
  import type { CreateReminderResult } from '../schemas/interfaces/create-reminder-result';
4
3
  import type { CreateRemindersListOptions } from '../schemas/interfaces/create-reminders-list-options';
5
4
  import type { CreateRemindersListResult } from '../schemas/interfaces/create-reminders-list-result';
6
5
  import type { DeleteReminderOptions } from '../schemas/interfaces/delete-reminder-options';
7
6
  import type { DeleteReminderWithPromptOptions } from '../schemas/interfaces/delete-reminder-with-prompt-options';
7
+ import type { DeleteReminderWithPromptResult } from '../schemas/interfaces/delete-reminder-with-prompt-result';
8
8
  import type { DeleteRemindersByIdOptions } from '../schemas/interfaces/delete-reminders-by-id-options';
9
9
  import type { DeleteRemindersByIdResult } from '../schemas/interfaces/delete-reminders-by-id-result';
10
10
  import type { DeleteRemindersListOptions } from '../schemas/interfaces/delete-reminders-list-options';
11
+ import type { FetchAllCalendarSourcesResult } from '../schemas/interfaces/fetch-all-calendar-sources-result';
12
+ import type { GetDefaultRemindersListResult } from '../schemas/interfaces/get-default-reminders-list-result';
11
13
  import type { GetReminderByIdOptions } from '../schemas/interfaces/get-reminder-by-id-options';
12
14
  import type { GetReminderByIdResult } from '../schemas/interfaces/get-reminder-by-id-result';
13
15
  import type { GetRemindersFromListsOptions } from '../schemas/interfaces/get-reminders-from-lists-options';
14
16
  import type { GetRemindersFromListsResult } from '../schemas/interfaces/get-reminders-from-lists-result';
17
+ import type { GetRemindersListsResult } from '../schemas/interfaces/get-reminders-lists-result';
15
18
  import type { ModifyReminderOptions } from '../schemas/interfaces/modify-reminder-options';
16
- import type { RemindersList } from '../schemas/interfaces/reminders-list';
17
19
  import type { UpdateRemindersListOptions } from '../schemas/interfaces/update-reminders-list-options';
18
20
  import type { UpdateRemindersListResult } from '../schemas/interfaces/update-reminders-list-result';
19
21
  export interface RemindersOperations {
20
22
  /**
21
23
  * Creates a new reminders list.
22
24
  *
25
+ * @throws {Error} `Title must be provided.` — when `title` is missing.
26
+ * @throws {Error} `Invalid color format.` — when `color` is present but invalid.
27
+ *
23
28
  * @platform iOS
24
29
  * @since 8.1.0
25
30
  */
@@ -27,6 +32,8 @@ export interface RemindersOperations {
27
32
  /**
28
33
  * Deletes a reminders list.
29
34
  *
35
+ * @throws {Error} `List not found.` — when no list exists for `id`.
36
+ *
30
37
  * @platform iOS
31
38
  * @since 8.2.0
32
39
  */
@@ -38,12 +45,12 @@ export interface RemindersOperations {
38
45
  * @platform iOS
39
46
  * @since 6.6.0
40
47
  */
41
- fetchAllRemindersSources(): Promise<{
42
- result: CalendarSource[];
43
- }>;
48
+ fetchAllRemindersSources(): Promise<FetchAllCalendarSourcesResult>;
44
49
  /**
45
50
  * Opens the reminders app.
46
51
  *
52
+ * @throws {Error} `Failed to launch reminders app.` — when the system cannot open Reminders.
53
+ *
47
54
  * @platform iOS
48
55
  * @since 7.1.0
49
56
  */
@@ -54,21 +61,23 @@ export interface RemindersOperations {
54
61
  * @platform iOS
55
62
  * @since 7.1.0
56
63
  */
57
- getDefaultRemindersList(): Promise<{
58
- result: RemindersList | null;
59
- }>;
64
+ getDefaultRemindersList(): Promise<GetDefaultRemindersListResult>;
60
65
  /**
61
66
  * Retrieves all available reminders lists.
62
67
  *
63
68
  * @platform iOS
64
69
  * @since 7.1.0
65
70
  */
66
- getRemindersLists(): Promise<{
67
- result: RemindersList[];
68
- }>;
71
+ getRemindersLists(): Promise<GetRemindersListsResult>;
69
72
  /**
70
73
  * Creates a reminder.
71
74
  *
75
+ * @throws {Error} `Title must be provided.` — when `title` is missing.
76
+ * @throws {Error} `List not found.` — when `listId` is set and no list matches.
77
+ * @throws {Error} `Invalid frequency.` — when `recurrence.frequency` is present but invalid.
78
+ * @throws {Error} `Frequency must be provided.` — when recurrence is set without `frequency`.
79
+ * @throws {Error} `Interval must be provided.` — when recurrence is set without `interval`.
80
+ *
72
81
  * @platform iOS
73
82
  * @since 0.5.0
74
83
  */
@@ -86,6 +95,8 @@ export interface RemindersOperations {
86
95
  /**
87
96
  * Deletes a reminder.
88
97
  *
98
+ * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.
99
+ *
89
100
  * @platform iOS
90
101
  * @since 7.1.0
91
102
  */
@@ -93,12 +104,18 @@ export interface RemindersOperations {
93
104
  /**
94
105
  * Modifies a reminder.
95
106
  *
107
+ * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.
108
+ * @throws {Error} `List not found.` — when `listId` is set and no list matches.
109
+ * @throws {Error} `Invalid frequency.` — when `recurrence.frequency` is present but invalid.
110
+ * @throws {Error} `Frequency must be provided.` — when recurrence is set without `frequency`.
111
+ * @throws {Error} `Interval must be provided.` — when recurrence is set without `interval`.
112
+ *
96
113
  * @platform iOS
97
114
  * @since 6.7.0
98
115
  */
99
116
  modifyReminder(options: ModifyReminderOptions): Promise<void>;
100
117
  /**
101
- * Retrieve a reminder by ID.
118
+ * Retrieves a reminder by id.
102
119
  *
103
120
  * @platform iOS
104
121
  * @since 7.1.0
@@ -107,6 +124,8 @@ export interface RemindersOperations {
107
124
  /**
108
125
  * Retrieves reminders from multiple lists.
109
126
  *
127
+ * @throws {Error} `List not found.` — when a requested list id does not exist.
128
+ *
110
129
  * @platform iOS
111
130
  * @since 5.3.0
112
131
  */
@@ -114,14 +133,20 @@ export interface RemindersOperations {
114
133
  /**
115
134
  * Opens a dialog to delete a reminder.
116
135
  *
136
+ * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.
137
+ * @throws {Error} `Missing view controller.` — when the plugin cannot present the dialog.
138
+ *
117
139
  * @platform iOS
118
140
  * @since 7.2.0
119
141
  */
120
- deleteReminderWithPrompt(options: DeleteReminderWithPromptOptions): Promise<{
121
- deleted: boolean;
122
- }>;
142
+ deleteReminderWithPrompt(options: DeleteReminderWithPromptOptions): Promise<DeleteReminderWithPromptResult>;
123
143
  /**
124
- * Update a reminders list with options.
144
+ * Updates a reminders list.
145
+ *
146
+ * @throws {Error} `Event ID must be provided.` — when `id` is missing.
147
+ * @throws {Error} `List not found.` — when no list exists for `id`.
148
+ * @throws {Error} `List is not modifiable.` — when the list does not allow edits.
149
+ * @throws {Error} `Invalid color format.` — when `color` is present but invalid.
125
150
  *
126
151
  * @platform iOS
127
152
  * @since 8.2.0
@@ -1 +1 @@
1
- {"version":3,"file":"reminders-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/reminders-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { CalendarSource } from '../schemas/interfaces/calendar-source';\nimport type { CreateReminderOptions } from '../schemas/interfaces/create-reminder-options';\nimport type { CreateReminderResult } from '../schemas/interfaces/create-reminder-result';\nimport type { CreateRemindersListOptions } from '../schemas/interfaces/create-reminders-list-options';\nimport type { CreateRemindersListResult } from '../schemas/interfaces/create-reminders-list-result';\nimport type { DeleteReminderOptions } from '../schemas/interfaces/delete-reminder-options';\nimport type { DeleteReminderWithPromptOptions } from '../schemas/interfaces/delete-reminder-with-prompt-options';\nimport type { DeleteRemindersByIdOptions } from '../schemas/interfaces/delete-reminders-by-id-options';\nimport type { DeleteRemindersByIdResult } from '../schemas/interfaces/delete-reminders-by-id-result';\nimport type { DeleteRemindersListOptions } from '../schemas/interfaces/delete-reminders-list-options';\nimport type { GetReminderByIdOptions } from '../schemas/interfaces/get-reminder-by-id-options';\nimport type { GetReminderByIdResult } from '../schemas/interfaces/get-reminder-by-id-result';\nimport type { GetRemindersFromListsOptions } from '../schemas/interfaces/get-reminders-from-lists-options';\nimport type { GetRemindersFromListsResult } from '../schemas/interfaces/get-reminders-from-lists-result';\nimport type { ModifyReminderOptions } from '../schemas/interfaces/modify-reminder-options';\nimport type { RemindersList } from '../schemas/interfaces/reminders-list';\nimport type { UpdateRemindersListOptions } from '../schemas/interfaces/update-reminders-list-options';\nimport type { UpdateRemindersListResult } from '../schemas/interfaces/update-reminders-list-result';\n\nexport interface RemindersOperations {\n /**\n * Creates a new reminders list.\n *\n * @platform iOS\n * @since 8.1.0\n */\n createRemindersList(options: CreateRemindersListOptions): Promise<CreateRemindersListResult>;\n /**\n * Deletes a reminders list.\n *\n * @platform iOS\n * @since 8.2.0\n */\n deleteRemindersList(options: DeleteRemindersListOptions): Promise<void>;\n /**\n * Retrieves a list of calendar sources.\n *\n * @deprecated Duplicates {@link CalendarOperations#fetchAllCalendarSources}\n * @platform iOS\n * @since 6.6.0\n */\n fetchAllRemindersSources(): Promise<{ result: CalendarSource[] }>;\n /**\n * Opens the reminders app.\n *\n * @platform iOS\n * @since 7.1.0\n */\n openReminders(): Promise<void>;\n /**\n * Retrieves the default reminders list.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getDefaultRemindersList(): Promise<{ result: RemindersList | null }>;\n /**\n * Retrieves all available reminders lists.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getRemindersLists(): Promise<{ result: RemindersList[] }>;\n /**\n * Creates a reminder.\n *\n * @platform iOS\n * @since 0.5.0\n */\n createReminder(options: CreateReminderOptions): Promise<CreateReminderResult>;\n /**\n * Deletes multiple reminders.\n *\n * @deprecated Use `deleteReminder(...)`.\n * @platform iOS\n * @since 5.3.0\n */\n deleteRemindersById(options: DeleteRemindersByIdOptions): Promise<{ result: DeleteRemindersByIdResult }>;\n /**\n * Deletes a reminder.\n *\n * @platform iOS\n * @since 7.1.0\n */\n deleteReminder(options: DeleteReminderOptions): Promise<void>;\n /**\n * Modifies a reminder.\n *\n * @platform iOS\n * @since 6.7.0\n */\n modifyReminder(options: ModifyReminderOptions): Promise<void>;\n /**\n * Retrieve a reminder by ID.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getReminderById(options: GetReminderByIdOptions): Promise<GetReminderByIdResult>;\n /**\n * Retrieves reminders from multiple lists.\n *\n * @platform iOS\n * @since 5.3.0\n */\n getRemindersFromLists(options: GetRemindersFromListsOptions): Promise<GetRemindersFromListsResult>;\n /**\n * Opens a dialog to delete a reminder.\n *\n * @platform iOS\n * @since 7.2.0\n */\n deleteReminderWithPrompt(options: DeleteReminderWithPromptOptions): Promise<{ deleted: boolean }>;\n /**\n * Update a reminders list with options.\n *\n * @platform iOS\n * @since 8.2.0\n */\n updateRemindersList(options: UpdateRemindersListOptions): Promise<UpdateRemindersListResult>;\n}\n"]}
1
+ {"version":3,"file":"reminders-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/reminders-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { CreateReminderOptions } from '../schemas/interfaces/create-reminder-options';\nimport type { CreateReminderResult } from '../schemas/interfaces/create-reminder-result';\nimport type { CreateRemindersListOptions } from '../schemas/interfaces/create-reminders-list-options';\nimport type { CreateRemindersListResult } from '../schemas/interfaces/create-reminders-list-result';\nimport type { DeleteReminderOptions } from '../schemas/interfaces/delete-reminder-options';\nimport type { DeleteReminderWithPromptOptions } from '../schemas/interfaces/delete-reminder-with-prompt-options';\nimport type { DeleteReminderWithPromptResult } from '../schemas/interfaces/delete-reminder-with-prompt-result';\nimport type { DeleteRemindersByIdOptions } from '../schemas/interfaces/delete-reminders-by-id-options';\nimport type { DeleteRemindersByIdResult } from '../schemas/interfaces/delete-reminders-by-id-result';\nimport type { DeleteRemindersListOptions } from '../schemas/interfaces/delete-reminders-list-options';\nimport type { FetchAllCalendarSourcesResult } from '../schemas/interfaces/fetch-all-calendar-sources-result';\nimport type { GetDefaultRemindersListResult } from '../schemas/interfaces/get-default-reminders-list-result';\nimport type { GetReminderByIdOptions } from '../schemas/interfaces/get-reminder-by-id-options';\nimport type { GetReminderByIdResult } from '../schemas/interfaces/get-reminder-by-id-result';\nimport type { GetRemindersFromListsOptions } from '../schemas/interfaces/get-reminders-from-lists-options';\nimport type { GetRemindersFromListsResult } from '../schemas/interfaces/get-reminders-from-lists-result';\nimport type { GetRemindersListsResult } from '../schemas/interfaces/get-reminders-lists-result';\nimport type { ModifyReminderOptions } from '../schemas/interfaces/modify-reminder-options';\nimport type { UpdateRemindersListOptions } from '../schemas/interfaces/update-reminders-list-options';\nimport type { UpdateRemindersListResult } from '../schemas/interfaces/update-reminders-list-result';\n\nexport interface RemindersOperations {\n /**\n * Creates a new reminders list.\n *\n * @throws {Error} `Title must be provided.` — when `title` is missing.\n * @throws {Error} `Invalid color format.` — when `color` is present but invalid.\n *\n * @platform iOS\n * @since 8.1.0\n */\n createRemindersList(options: CreateRemindersListOptions): Promise<CreateRemindersListResult>;\n /**\n * Deletes a reminders list.\n *\n * @throws {Error} `List not found.` — when no list exists for `id`.\n *\n * @platform iOS\n * @since 8.2.0\n */\n deleteRemindersList(options: DeleteRemindersListOptions): Promise<void>;\n /**\n * Retrieves a list of calendar sources.\n *\n * @deprecated Duplicates {@link CalendarOperations#fetchAllCalendarSources}\n * @platform iOS\n * @since 6.6.0\n */\n fetchAllRemindersSources(): Promise<FetchAllCalendarSourcesResult>;\n /**\n * Opens the reminders app.\n *\n * @throws {Error} `Failed to launch reminders app.` — when the system cannot open Reminders.\n *\n * @platform iOS\n * @since 7.1.0\n */\n openReminders(): Promise<void>;\n /**\n * Retrieves the default reminders list.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getDefaultRemindersList(): Promise<GetDefaultRemindersListResult>;\n /**\n * Retrieves all available reminders lists.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getRemindersLists(): Promise<GetRemindersListsResult>;\n /**\n * Creates a reminder.\n *\n * @throws {Error} `Title must be provided.` — when `title` is missing.\n * @throws {Error} `List not found.` — when `listId` is set and no list matches.\n * @throws {Error} `Invalid frequency.` — when `recurrence.frequency` is present but invalid.\n * @throws {Error} `Frequency must be provided.` — when recurrence is set without `frequency`.\n * @throws {Error} `Interval must be provided.` — when recurrence is set without `interval`.\n *\n * @platform iOS\n * @since 0.5.0\n */\n createReminder(options: CreateReminderOptions): Promise<CreateReminderResult>;\n /**\n * Deletes multiple reminders.\n *\n * @deprecated Use `deleteReminder(...)`.\n * @platform iOS\n * @since 5.3.0\n */\n deleteRemindersById(options: DeleteRemindersByIdOptions): Promise<{ result: DeleteRemindersByIdResult }>;\n /**\n * Deletes a reminder.\n *\n * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.\n *\n * @platform iOS\n * @since 7.1.0\n */\n deleteReminder(options: DeleteReminderOptions): Promise<void>;\n /**\n * Modifies a reminder.\n *\n * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.\n * @throws {Error} `List not found.` — when `listId` is set and no list matches.\n * @throws {Error} `Invalid frequency.` — when `recurrence.frequency` is present but invalid.\n * @throws {Error} `Frequency must be provided.` — when recurrence is set without `frequency`.\n * @throws {Error} `Interval must be provided.` — when recurrence is set without `interval`.\n *\n * @platform iOS\n * @since 6.7.0\n */\n modifyReminder(options: ModifyReminderOptions): Promise<void>;\n /**\n * Retrieves a reminder by id.\n *\n * @platform iOS\n * @since 7.1.0\n */\n getReminderById(options: GetReminderByIdOptions): Promise<GetReminderByIdResult>;\n /**\n * Retrieves reminders from multiple lists.\n *\n * @throws {Error} `List not found.` — when a requested list id does not exist.\n *\n * @platform iOS\n * @since 5.3.0\n */\n getRemindersFromLists(options: GetRemindersFromListsOptions): Promise<GetRemindersFromListsResult>;\n /**\n * Opens a dialog to delete a reminder.\n *\n * @throws {Error} `Reminder not found.` — when no reminder exists for `id`.\n * @throws {Error} `Missing view controller.` — when the plugin cannot present the dialog.\n *\n * @platform iOS\n * @since 7.2.0\n */\n deleteReminderWithPrompt(options: DeleteReminderWithPromptOptions): Promise<DeleteReminderWithPromptResult>;\n /**\n * Updates a reminders list.\n *\n * @throws {Error} `Event ID must be provided.` — when `id` is missing.\n * @throws {Error} `List not found.` — when no list exists for `id`.\n * @throws {Error} `List is not modifiable.` — when the list does not allow edits.\n * @throws {Error} `Invalid color format.` — when `color` is present but invalid.\n *\n * @platform iOS\n * @since 8.2.0\n */\n updateRemindersList(options: UpdateRemindersListOptions): Promise<UpdateRemindersListResult>;\n}\n"]}
@@ -1,8 +1,8 @@
1
1
  import type { CreateEventOptions } from '../schemas/interfaces/create-event-options';
2
2
  /**
3
3
  * Builds an RFC 5545 `VCALENDAR` document with one `VEVENT` from CreateEventOptions.
4
- * When `startDate` is omitted, uses the current time. When `endDate` is omitted, uses
5
- * one hour after the start (or the next day for all-day events).
4
+ * End comes from `endDate`, else `duration` (RFC 2445), else one hour (or next day if all-day).
5
+ * All-day ends that fall on the start's local day bump to the next day (exclusive `DTEND`).
6
6
  */
7
7
  export declare function buildEventIcs(options: CreateEventOptions): string;
8
8
  /**
@@ -11,6 +11,12 @@ export declare function buildEventIcs(options: CreateEventOptions): string;
11
11
  * Appends `.ics` when the chosen name has no such extension.
12
12
  */
13
13
  export declare function resolveIcsFileName(options: Pick<CreateEventOptions, 'icsFileName' | 'title'>): string;
14
+ /**
15
+ * Resolves event end milliseconds the same way ICS export does.
16
+ * Prefers `endDate`, else `duration` (RFC 2445), else one hour (or next day if all-day).
17
+ * All-day ends that fall on the start's local day bump to the next day (exclusive `DTEND`).
18
+ */
19
+ export declare function resolveEndDate(startDate: number, endDate: number | undefined, duration: string | undefined, isAllDay: boolean): number;
14
20
  /**
15
21
  * Escapes TEXT values per RFC 5545 §3.3.11.
16
22
  */