@ebarooni/capacitor-calendar 7.1.0 → 7.3.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 (268) hide show
  1. package/EbarooniCapacitorCalendar.podspec +1 -1
  2. package/Package.swift +2 -2
  3. package/README.md +949 -452
  4. package/android/src/main/java/dev/barooni/capacitor/calendar/CapacitorCalendarPlugin.kt +74 -7
  5. package/android/src/main/java/dev/barooni/capacitor/calendar/PluginError.kt +36 -18
  6. package/android/src/main/java/dev/barooni/capacitor/calendar/implementation/CapacitorCalendar.kt +325 -83
  7. package/android/src/main/java/dev/barooni/capacitor/calendar/models/data/CalendarEvent.kt +4 -0
  8. package/android/src/main/java/dev/barooni/capacitor/calendar/models/data/EventDeleteInfo.kt +8 -0
  9. package/android/src/main/java/dev/barooni/capacitor/calendar/models/data/EventRecurrenceRule.kt +135 -0
  10. package/android/src/main/java/dev/barooni/capacitor/calendar/models/enums/EventSpan.kt +13 -0
  11. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/CheckPermissionInput.kt +0 -4
  12. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/CreateCalendarInput.kt +3 -1
  13. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/CreateEventInput.kt +1 -0
  14. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/CreateEventWithPromptInput.kt +5 -0
  15. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/DeleteCalendarInput.kt +4 -1
  16. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/DeleteEventInput.kt +4 -1
  17. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/DeleteEventWithPromptInput.kt +4 -1
  18. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/DeleteEventsByIdInput.kt +2 -0
  19. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/GetDefaultCalendarInput.kt +9 -0
  20. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/ModifyCalendarInput.kt +22 -0
  21. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/ModifyEvent.kt +3 -1
  22. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/ModifyEventWithPromptInput.kt +3 -0
  23. package/android/src/main/java/dev/barooni/capacitor/calendar/models/inputs/RequestPermissionInput.kt +3 -5
  24. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/CheckAllPermissionsResult.kt +3 -2
  25. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/CreateEventResult.kt +1 -0
  26. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/CreateEventWithPromptResult.kt +1 -0
  27. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/GetDefaultCalendarResult.kt +1 -0
  28. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/ListCalendarsResult.kt +1 -0
  29. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/ListEventsInRangeResult.kt +4 -0
  30. package/android/src/main/java/dev/barooni/capacitor/calendar/models/results/RequestAllPermissionsResult.kt +1 -1
  31. package/android/src/main/java/dev/barooni/capacitor/calendar/models/templates/PluginCompletion.kt +8 -0
  32. package/android/src/main/java/dev/barooni/capacitor/calendar/utils/ImplementationHelper.kt +468 -39
  33. package/dist/docs.json +3321 -1121
  34. package/dist/esm/definitions.d.ts +5 -5
  35. package/dist/esm/definitions.js.map +1 -1
  36. package/dist/esm/index.d.ts +71 -46
  37. package/dist/esm/index.js +17 -17
  38. package/dist/esm/index.js.map +1 -1
  39. package/dist/esm/schemas/enums/attendee-role.js.map +1 -1
  40. package/dist/esm/schemas/enums/attendee-status.js.map +1 -1
  41. package/dist/esm/schemas/enums/attendee-type.js.map +1 -1
  42. package/dist/esm/schemas/enums/calendar-permission-scope.d.ts +9 -1
  43. package/dist/esm/schemas/enums/calendar-permission-scope.js +9 -1
  44. package/dist/esm/schemas/enums/calendar-permission-scope.js.map +1 -1
  45. package/dist/esm/schemas/enums/event-span.d.ts +4 -0
  46. package/dist/esm/schemas/enums/event-span.js +4 -0
  47. package/dist/esm/schemas/enums/event-span.js.map +1 -1
  48. package/dist/esm/schemas/enums/event-status.js.map +1 -1
  49. package/dist/esm/schemas/enums/reminder-recurrence-frequency.d.ts +5 -5
  50. package/dist/esm/schemas/enums/reminder-recurrence-frequency.js +5 -5
  51. package/dist/esm/schemas/enums/reminder-recurrence-frequency.js.map +1 -1
  52. package/dist/esm/schemas/interfaces/calendar-event.d.ts +145 -70
  53. package/dist/esm/schemas/interfaces/calendar-event.js.map +1 -1
  54. package/dist/esm/schemas/interfaces/calendar-source.d.ts +4 -1
  55. package/dist/esm/schemas/interfaces/calendar-source.js.map +1 -1
  56. package/dist/esm/schemas/interfaces/calendar.d.ts +22 -4
  57. package/dist/esm/schemas/interfaces/calendar.js.map +1 -1
  58. package/dist/esm/schemas/interfaces/check-permission-options.d.ts +19 -0
  59. package/dist/esm/schemas/interfaces/check-permission-options.js +2 -0
  60. package/dist/esm/schemas/interfaces/check-permission-options.js.map +1 -0
  61. package/dist/esm/schemas/interfaces/create-calendar-options.d.ts +19 -6
  62. package/dist/esm/schemas/interfaces/create-calendar-options.js.map +1 -1
  63. package/dist/esm/schemas/interfaces/create-calendar-result.d.ts +12 -0
  64. package/dist/esm/schemas/interfaces/create-calendar-result.js +2 -0
  65. package/dist/esm/schemas/interfaces/create-calendar-result.js.map +1 -0
  66. package/dist/esm/schemas/interfaces/create-event-options.d.ts +86 -51
  67. package/dist/esm/schemas/interfaces/create-event-options.js.map +1 -1
  68. package/dist/esm/schemas/interfaces/create-event-result.d.ts +22 -0
  69. package/dist/esm/schemas/interfaces/create-event-result.js +2 -0
  70. package/dist/esm/schemas/interfaces/create-event-result.js.map +1 -0
  71. package/dist/esm/schemas/interfaces/create-event-with-prompt-options.d.ts +73 -36
  72. package/dist/esm/schemas/interfaces/create-event-with-prompt-options.js.map +1 -1
  73. package/dist/esm/schemas/interfaces/create-event-with-prompt-result.d.ts +23 -0
  74. package/dist/esm/schemas/interfaces/create-event-with-prompt-result.js +2 -0
  75. package/dist/esm/schemas/interfaces/create-event-with-prompt-result.js.map +1 -0
  76. package/dist/esm/schemas/interfaces/create-reminder-options.d.ts +42 -12
  77. package/dist/esm/schemas/interfaces/create-reminder-options.js.map +1 -1
  78. package/dist/esm/schemas/interfaces/create-reminder-result.d.ts +12 -0
  79. package/dist/esm/schemas/interfaces/create-reminder-result.js +2 -0
  80. package/dist/esm/schemas/interfaces/create-reminder-result.js.map +1 -0
  81. package/dist/esm/schemas/interfaces/create-reminders-list-options.d.ts +46 -0
  82. package/dist/esm/schemas/interfaces/create-reminders-list-options.js +2 -0
  83. package/dist/esm/schemas/interfaces/create-reminders-list-options.js.map +1 -0
  84. package/dist/esm/schemas/interfaces/create-reminders-list-result.d.ts +12 -0
  85. package/dist/esm/schemas/interfaces/create-reminders-list-result.js +2 -0
  86. package/dist/esm/schemas/interfaces/create-reminders-list-result.js.map +1 -0
  87. package/dist/esm/schemas/interfaces/delete-calendar-options.d.ts +1 -0
  88. package/dist/esm/schemas/interfaces/delete-calendar-options.js.map +1 -1
  89. package/dist/esm/schemas/interfaces/delete-event-options.d.ts +29 -4
  90. package/dist/esm/schemas/interfaces/delete-event-options.js.map +1 -1
  91. package/dist/esm/schemas/interfaces/delete-event-with-prompt-options.d.ts +39 -14
  92. package/dist/esm/schemas/interfaces/delete-event-with-prompt-options.js.map +1 -1
  93. package/dist/esm/schemas/interfaces/delete-events-by-id-options.d.ts +16 -4
  94. package/dist/esm/schemas/interfaces/delete-events-by-id-options.js.map +1 -1
  95. package/dist/esm/schemas/interfaces/delete-reminder-options.d.ts +10 -0
  96. package/dist/esm/schemas/interfaces/delete-reminder-options.js.map +1 -1
  97. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-options.d.ts +35 -0
  98. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-options.js +2 -0
  99. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-options.js.map +1 -0
  100. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.d.ts +12 -0
  101. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.js +2 -0
  102. package/dist/esm/schemas/interfaces/delete-reminder-with-prompt-result.js.map +1 -0
  103. package/dist/esm/schemas/interfaces/delete-reminders-by-id-result.d.ts +13 -0
  104. package/dist/esm/schemas/interfaces/delete-reminders-by-id-result.js +2 -0
  105. package/dist/esm/schemas/interfaces/delete-reminders-by-id-result.js.map +1 -0
  106. package/dist/esm/schemas/interfaces/delete-reminders-list-options.d.ts +23 -0
  107. package/dist/esm/schemas/interfaces/delete-reminders-list-options.js +2 -0
  108. package/dist/esm/schemas/interfaces/delete-reminders-list-options.js.map +1 -0
  109. package/dist/esm/schemas/interfaces/event-recurrence-rule.d.ts +96 -0
  110. package/dist/esm/schemas/interfaces/event-recurrence-rule.js +2 -0
  111. package/dist/esm/schemas/interfaces/event-recurrence-rule.js.map +1 -0
  112. package/dist/esm/schemas/interfaces/fetch-all-calendar-sources-result.d.ts +13 -0
  113. package/dist/esm/schemas/interfaces/fetch-all-calendar-sources-result.js +2 -0
  114. package/dist/esm/schemas/interfaces/fetch-all-calendar-sources-result.js.map +1 -0
  115. package/dist/esm/schemas/interfaces/get-default-calendar-options.d.ts +13 -0
  116. package/dist/esm/schemas/interfaces/get-default-calendar-options.js +2 -0
  117. package/dist/esm/schemas/interfaces/get-default-calendar-options.js.map +1 -0
  118. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.d.ts +13 -0
  119. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.js +2 -0
  120. package/dist/esm/schemas/interfaces/get-default-reminders-list-result.js.map +1 -0
  121. package/dist/esm/schemas/interfaces/get-reminder-by-id-result.d.ts +13 -0
  122. package/dist/esm/schemas/interfaces/get-reminder-by-id-result.js +2 -0
  123. package/dist/esm/schemas/interfaces/get-reminder-by-id-result.js.map +1 -0
  124. package/dist/esm/schemas/interfaces/get-reminders-from-lists-result.d.ts +13 -0
  125. package/dist/esm/schemas/interfaces/get-reminders-from-lists-result.js +2 -0
  126. package/dist/esm/schemas/interfaces/get-reminders-from-lists-result.js.map +1 -0
  127. package/dist/esm/schemas/interfaces/get-reminders-lists-result.d.ts +13 -0
  128. package/dist/esm/schemas/interfaces/get-reminders-lists-result.js +2 -0
  129. package/dist/esm/schemas/interfaces/get-reminders-lists-result.js.map +1 -0
  130. package/dist/esm/schemas/interfaces/list-calendars-result.d.ts +13 -0
  131. package/dist/esm/schemas/interfaces/list-calendars-result.js +2 -0
  132. package/dist/esm/schemas/interfaces/list-calendars-result.js.map +1 -0
  133. package/dist/esm/schemas/interfaces/list-events-in-range-options.d.ts +7 -2
  134. package/dist/esm/schemas/interfaces/list-events-in-range-options.js.map +1 -1
  135. package/dist/esm/schemas/interfaces/list-events-in-range-result.d.ts +13 -0
  136. package/dist/esm/schemas/interfaces/list-events-in-range-result.js +2 -0
  137. package/dist/esm/schemas/interfaces/list-events-in-range-result.js.map +1 -0
  138. package/dist/esm/schemas/interfaces/modify-calendar-options.d.ts +32 -0
  139. package/dist/esm/schemas/interfaces/modify-calendar-options.js +2 -0
  140. package/dist/esm/schemas/interfaces/modify-calendar-options.js.map +1 -0
  141. package/dist/esm/schemas/interfaces/modify-event-options.d.ts +61 -44
  142. package/dist/esm/schemas/interfaces/modify-event-options.js.map +1 -1
  143. package/dist/esm/schemas/interfaces/modify-event-with-prompt-options.d.ts +77 -2
  144. package/dist/esm/schemas/interfaces/modify-event-with-prompt-options.js.map +1 -1
  145. package/dist/esm/schemas/interfaces/modify-reminder-options.d.ts +77 -13
  146. package/dist/esm/schemas/interfaces/modify-reminder-options.js.map +1 -1
  147. package/dist/esm/schemas/interfaces/open-calendar-options.d.ts +5 -1
  148. package/dist/esm/schemas/interfaces/open-calendar-options.js.map +1 -1
  149. package/dist/esm/schemas/interfaces/recurrence-rule.d.ts +8 -2
  150. package/dist/esm/schemas/interfaces/recurrence-rule.js.map +1 -1
  151. package/dist/esm/schemas/interfaces/reminder-recurrence-rule.d.ts +1 -1
  152. package/dist/esm/schemas/interfaces/reminder-recurrence-rule.js.map +1 -1
  153. package/dist/esm/schemas/interfaces/reminder.d.ts +4 -1
  154. package/dist/esm/schemas/interfaces/reminder.js.map +1 -1
  155. package/dist/esm/schemas/interfaces/reminders-list.d.ts +8 -2
  156. package/dist/esm/schemas/interfaces/reminders-list.js.map +1 -1
  157. package/dist/esm/schemas/interfaces/request-permission-options.d.ts +16 -0
  158. package/dist/esm/schemas/interfaces/request-permission-options.js +2 -0
  159. package/dist/esm/schemas/interfaces/request-permission-options.js.map +1 -0
  160. package/dist/esm/schemas/interfaces/select-calendars-with-prompt-options.d.ts +1 -1
  161. package/dist/esm/schemas/interfaces/select-calendars-with-prompt-options.js.map +1 -1
  162. package/dist/esm/schemas/interfaces/select-calendars-with-prompt-result.d.ts +14 -0
  163. package/dist/esm/schemas/interfaces/select-calendars-with-prompt-result.js +2 -0
  164. package/dist/esm/schemas/interfaces/select-calendars-with-prompt-result.js.map +1 -0
  165. package/dist/esm/schemas/interfaces/update-reminders-list-options.d.ts +43 -0
  166. package/dist/esm/schemas/interfaces/update-reminders-list-options.js +2 -0
  167. package/dist/esm/schemas/interfaces/update-reminders-list-options.js.map +1 -0
  168. package/dist/esm/schemas/interfaces/update-reminders-list-result.d.ts +12 -0
  169. package/dist/esm/schemas/interfaces/update-reminders-list-result.js +2 -0
  170. package/dist/esm/schemas/interfaces/update-reminders-list-result.js.map +1 -0
  171. package/dist/esm/schemas/types/event-edit-action.d.ts +1 -1
  172. package/dist/esm/schemas/types/event-edit-action.js.map +1 -1
  173. package/dist/esm/schemas/types/recurrence-frequency.d.ts +4 -0
  174. package/dist/esm/schemas/types/recurrence-frequency.js +2 -0
  175. package/dist/esm/schemas/types/recurrence-frequency.js.map +1 -0
  176. package/dist/esm/schemas/types/system-color-name.d.ts +6 -0
  177. package/dist/esm/schemas/types/system-color-name.js +2 -0
  178. package/dist/esm/schemas/types/system-color-name.js.map +1 -0
  179. package/dist/esm/sub-definitions/calendar-access.d.ts +26 -14
  180. package/dist/esm/sub-definitions/calendar-access.js.map +1 -1
  181. package/dist/esm/sub-definitions/calendar-operations.d.ts +75 -20
  182. package/dist/esm/sub-definitions/calendar-operations.js.map +1 -1
  183. package/dist/esm/sub-definitions/event-operations.d.ts +46 -25
  184. package/dist/esm/sub-definitions/event-operations.js.map +1 -1
  185. package/dist/esm/sub-definitions/reminders-access.d.ts +6 -2
  186. package/dist/esm/sub-definitions/reminders-access.js.map +1 -1
  187. package/dist/esm/sub-definitions/reminders-operations.d.ts +82 -37
  188. package/dist/esm/sub-definitions/reminders-operations.js.map +1 -1
  189. package/dist/esm/web/download-ics-file.d.ts +18 -0
  190. package/dist/esm/web/download-ics-file.js +33 -0
  191. package/dist/esm/web/download-ics-file.js.map +1 -0
  192. package/dist/esm/web/ics.d.ts +27 -0
  193. package/dist/esm/web/ics.js +294 -0
  194. package/dist/esm/web/ics.js.map +1 -0
  195. package/dist/esm/web.d.ts +71 -77
  196. package/dist/esm/web.js +127 -6
  197. package/dist/esm/web.js.map +1 -1
  198. package/dist/plugin.cjs.js +470 -35
  199. package/dist/plugin.cjs.js.map +1 -1
  200. package/dist/plugin.js +470 -35
  201. package/dist/plugin.js.map +1 -1
  202. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/CapacitorCalendarPlugin.swift +168 -75
  203. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Implementation/CapacitorCalendar.swift +242 -107
  204. package/ios/Plugin/Info.plist +24 -0
  205. package/ios/Plugin/Models/Enums/EventSpan.swift +8 -0
  206. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/CreateCalendarInput.swift +6 -4
  207. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/CreateEventInput.swift +25 -21
  208. package/ios/Plugin/Models/Inputs/CreateEventWithPromptInput.swift +171 -0
  209. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/CreateReminderInput.swift +14 -4
  210. package/ios/Plugin/Models/Inputs/CreateRemindersListInput.swift +43 -0
  211. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteCalendarInput.swift +1 -1
  212. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteEventInput.swift +9 -4
  213. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteEventWithPromptInput.swift +9 -4
  214. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteEventsByIdInput.swift +9 -4
  215. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteReminderInput.swift +7 -1
  216. package/ios/Plugin/Models/Inputs/DeleteReminderWithPromptInput.swift +46 -0
  217. package/ios/Plugin/Models/Inputs/DeleteRemindersListInput.swift +22 -0
  218. package/ios/Plugin/Models/Inputs/GetDefaultCalendarInput.swift +13 -0
  219. package/ios/Plugin/Models/Inputs/ModifyCalendarInput.swift +35 -0
  220. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/ModifyEventInput.swift +63 -41
  221. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/ModifyReminderInput.swift +66 -5
  222. package/ios/Plugin/Models/Inputs/UpdateRemindersListInput.swift +41 -0
  223. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CreateEventResult.swift +1 -0
  224. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CreateEventWithPromptResult.swift +1 -0
  225. package/ios/Plugin/Models/Results/CreateRemindersListResult.swift +15 -0
  226. package/ios/Plugin/Models/Results/ListEventsInRangeResult.swift +29 -0
  227. package/ios/Plugin/Models/Results/UpdateRemindersListResult.swift +15 -0
  228. package/ios/Plugin/Models/Structs/RecurrenceInput.swift +41 -0
  229. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/PluginConfig.swift +30 -25
  230. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/PluginError.swift +74 -56
  231. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Utils/ImplementationHelper.swift +140 -24
  232. package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Utils/UIColorFromHexExtension.swift +5 -0
  233. package/package.json +36 -43
  234. package/dist/esm/schemas/enums/recurrence-frequency.d.ts +0 -21
  235. package/dist/esm/schemas/enums/recurrence-frequency.js +0 -23
  236. package/dist/esm/schemas/enums/recurrence-frequency.js.map +0 -1
  237. package/ios/Sources/CapacitorCalendarPlugin/Models/Inputs/CreateEventWithPromptInput.swift +0 -89
  238. package/ios/Sources/CapacitorCalendarPlugin/Models/Results/ListEventsInRangeResult.swift +0 -16
  239. package/ios/Tests/CapacitorCalendarPluginTests/CapacitorCalendarPluginTests.swift +0 -15
  240. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Enums/CAPPermissionState.swift +0 -0
  241. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Enums/CalendarPermissionScope.swift +0 -0
  242. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Enums/EventEditAction.swift +0 -0
  243. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/CheckPermissionInput.swift +0 -0
  244. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/DeleteRemindersByIdInput.swift +0 -0
  245. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/GetReminderByIdInput.swift +0 -0
  246. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/GetRemindersFromListsInput.swift +0 -0
  247. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/ListEventsInRangeInput.swift +0 -0
  248. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/ModifyEventWithPromptInput.swift +0 -0
  249. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/OpenCalendarInput.swift +0 -0
  250. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/RequestPermissionInput.swift +0 -0
  251. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Inputs/SelectCalendarsWithPromptInput.swift +0 -0
  252. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CheckAllPermissionsResult.swift +0 -0
  253. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CheckPermissionResult.swift +0 -0
  254. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CreateCalendarResult.swift +0 -0
  255. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/CreateReminderResult.swift +0 -0
  256. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/DeleteEventWithPromptResult.swift +0 -0
  257. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/DeleteEventsByIdResult.swift +0 -0
  258. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/DeleteRemindersByIdResult.swift +0 -0
  259. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/FetchAllCalendarSourcesResult.swift +0 -0
  260. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/GetDefaultCalendarResult.swift +0 -0
  261. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/GetReminderByIdResult.swift +0 -0
  262. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/GetRemindersFromListsResult.swift +0 -0
  263. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/ListCalendarsResult.swift +0 -0
  264. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/ModifyEventWithPromptResult.swift +0 -0
  265. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/RequestAllPermissionsResult.swift +0 -0
  266. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/RequestPermissionResult.swift +0 -0
  267. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Results/SelectCalendarsWithPromptResult.swift +0 -0
  268. /package/ios/{Sources/CapacitorCalendarPlugin → Plugin}/Models/Templates/JSResult.swift +0 -0
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=request-permission-options.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"request-permission-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/request-permission-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { CalendarPermissionScope } from '../enums/calendar-permission-scope';\n\n/**\n * Options for {@link CalendarAccess#requestPermission}.\n *\n * @since 7.3.0\n */\nexport interface RequestPermissionOptions {\n /**\n * The permission scope to request.\n *\n * @example CalendarPermissionScope.READ_CALENDAR\n * @platform Android, iOS\n * @since 7.3.0\n */\n scope: CalendarPermissionScope;\n}\n"]}
@@ -1,4 +1,4 @@
1
- import { CalendarChooserDisplayStyle } from "../enums/calendar-chooser-display-style";
1
+ import type { CalendarChooserDisplayStyle } from '../enums/calendar-chooser-display-style';
2
2
  /**
3
3
  * @since 7.1.0
4
4
  */
@@ -1 +1 @@
1
- {"version":3,"file":"select-calendars-with-prompt-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/select-calendars-with-prompt-options.ts"],"names":[],"mappings":"","sourcesContent":["import { CalendarChooserDisplayStyle } from \"../enums/calendar-chooser-display-style\";\n\n/**\n * @since 7.1.0\n */\nexport interface SelectCalendarsWithPromptOptions {\n /**\n * @default CalendarChooserDisplayStyle.ALL_CALENDARS\n * @since 7.1.0\n */\n displayStyle?: CalendarChooserDisplayStyle;\n /**\n * Allow multiple selections.\n *\n * @default false\n * @since 7.1.0\n */\n multiple?: boolean;\n}\n"]}
1
+ {"version":3,"file":"select-calendars-with-prompt-options.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/select-calendars-with-prompt-options.ts"],"names":[],"mappings":"","sourcesContent":["import type { CalendarChooserDisplayStyle } from '../enums/calendar-chooser-display-style';\n\n/**\n * @since 7.1.0\n */\nexport interface SelectCalendarsWithPromptOptions {\n /**\n * @default CalendarChooserDisplayStyle.ALL_CALENDARS\n * @since 7.1.0\n */\n displayStyle?: CalendarChooserDisplayStyle;\n /**\n * Allow multiple selections.\n *\n * @default false\n * @since 7.1.0\n */\n multiple?: boolean;\n}\n"]}
@@ -0,0 +1,14 @@
1
+ import type { Calendar } from './calendar';
2
+ /**
3
+ * @since 7.3.0
4
+ */
5
+ export interface SelectCalendarsWithPromptResult {
6
+ /**
7
+ * Calendars the user confirmed in the chooser.
8
+ * Empty when the user cancels.
9
+ *
10
+ * @platform iOS
11
+ * @since 7.3.0
12
+ */
13
+ result: Calendar[];
14
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=select-calendars-with-prompt-result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"select-calendars-with-prompt-result.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/select-calendars-with-prompt-result.ts"],"names":[],"mappings":"","sourcesContent":["import type { Calendar } from './calendar';\n\n/**\n * @since 7.3.0\n */\nexport interface SelectCalendarsWithPromptResult {\n /**\n * Calendars the user confirmed in the chooser.\n * Empty when the user cancels.\n *\n * @platform iOS\n * @since 7.3.0\n */\n result: Calendar[];\n}\n"]}
@@ -0,0 +1,43 @@
1
+ import type { SystemColorName } from '../types/system-color-name';
2
+ /**
3
+ * @since 7.3.0
4
+ */
5
+ export interface UpdateRemindersListOptions {
6
+ /**
7
+ * Named color (`blue`, …) or hex `#RRGGBB` / `#RRGGBBAA`.
8
+ * If omitted, the color is left unchanged.
9
+ *
10
+ * @example 'indigo'
11
+ * @example #007AFF
12
+ * @platform iOS
13
+ * @since 7.3.0
14
+ */
15
+ color?: SystemColorName | `#${string}`;
16
+ /**
17
+ * Whether to save the update immediately.
18
+ * Pass `false` to batch changes and commit them with `CapacitorCalendar.commit()`.
19
+ *
20
+ * @default true
21
+ * @platform iOS
22
+ * @see {@link CalendarOperations#commit}
23
+ * @since 7.3.0
24
+ */
25
+ commit?: boolean;
26
+ /**
27
+ * The identifier of the list to update.
28
+ *
29
+ * @example 'A1234567-ABCD-EFGH-IJKL-MNOPQRSTUVWX'
30
+ * @platform iOS
31
+ * @since 7.3.0
32
+ */
33
+ id: string;
34
+ /**
35
+ * The new title of the list.
36
+ * If omitted, the title is left unchanged.
37
+ *
38
+ * @example 'Groceries'
39
+ * @platform iOS
40
+ * @since 7.3.0
41
+ */
42
+ title?: string;
43
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=update-reminders-list-options.js.map
@@ -0,0 +1 @@
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 7.3.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 7.3.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 7.3.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 7.3.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 7.3.0\n */\n title?: string;\n}\n"]}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @since 7.3.0
3
+ */
4
+ export interface UpdateRemindersListResult {
5
+ /**
6
+ * Identifier of the updated reminders list.
7
+ *
8
+ * @platform iOS
9
+ * @since 7.3.0
10
+ */
11
+ id: string;
12
+ }
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=update-reminders-list-result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-reminders-list-result.js","sourceRoot":"","sources":["../../../../src/schemas/interfaces/update-reminders-list-result.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 7.3.0\n */\nexport interface UpdateRemindersListResult {\n /**\n * Identifier of the updated reminders list.\n *\n * @platform iOS\n * @since 7.3.0\n */\n id: string;\n}\n"]}
@@ -1,4 +1,4 @@
1
1
  /**
2
2
  * @since 7.1.0
3
3
  */
4
- export declare type EventEditAction = "canceled" | "saved" | "deleted";
4
+ export type EventEditAction = 'canceled' | 'saved' | 'deleted';
@@ -1 +1 @@
1
- {"version":3,"file":"event-edit-action.js","sourceRoot":"","sources":["../../../../src/schemas/types/event-edit-action.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 7.1.0\n */\nexport type EventEditAction = \"canceled\" | \"saved\" | \"deleted\";\n"]}
1
+ {"version":3,"file":"event-edit-action.js","sourceRoot":"","sources":["../../../../src/schemas/types/event-edit-action.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 7.1.0\n */\nexport type EventEditAction = 'canceled' | 'saved' | 'deleted';\n"]}
@@ -0,0 +1,4 @@
1
+ /**
2
+ * @since 7.3.0
3
+ */
4
+ export type RecurrenceFrequency = 'daily' | 'weekly' | 'monthly' | 'yearly';
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=recurrence-frequency.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"recurrence-frequency.js","sourceRoot":"","sources":["../../../../src/schemas/types/recurrence-frequency.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * @since 7.3.0\n */\nexport type RecurrenceFrequency = 'daily' | 'weekly' | 'monthly' | 'yearly';\n"]}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Named iOS system color.
3
+ *
4
+ * @since 7.3.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 7.3.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"]}
@@ -1,26 +1,33 @@
1
- import { CalendarPermissionScope } from "../schemas/enums/calendar-permission-scope";
2
- import type { PermissionState } from "@capacitor/core";
1
+ import type { PermissionState } from '@capacitor/core';
2
+ import type { CalendarPermissionScope } from '../schemas/enums/calendar-permission-scope';
3
+ import type { CheckPermissionOptions } from '../schemas/interfaces/check-permission-options';
4
+ import type { RequestPermissionOptions } from '../schemas/interfaces/request-permission-options';
3
5
  /**
4
6
  * @since 7.1.0
5
7
  */
6
8
  export interface CalendarAccess {
7
9
  /**
8
10
  * Retrieves the current permission state for a given scope.
11
+ * On Android, `readReminders` and `writeReminders` resolve to `"prompt"`.
9
12
  *
10
13
  * @example
11
14
  * CapacitorCalendar.checkPermission({ scope: CalendarPermissionScope.READ_CALENDAR });
12
15
  *
16
+ * @throws {Error} `Scope must be provided.` — when `scope` is missing.
17
+ * @throws {Error} `Invalid scope.` — when `scope` is invalid.
18
+ * @throws {Error} `Unhandled permission state.` — when the native status cannot be mapped.
19
+ *
13
20
  * @platform Android, iOS
14
21
  * @since 0.1.0
15
- *
16
22
  */
17
- checkPermission(options: {
18
- scope: CalendarPermissionScope;
19
- }): Promise<{
23
+ checkPermission(options: CheckPermissionOptions): Promise<{
20
24
  result: PermissionState;
21
25
  }>;
22
26
  /**
23
27
  * Retrieves the current state of all permissions.
28
+ * On Android, reminder keys always resolve to `"prompt"`.
29
+ *
30
+ * @throws {Error} `Unhandled permission state.` — when a native status cannot be mapped.
24
31
  *
25
32
  * @platform Android, iOS
26
33
  * @since 0.1.0
@@ -30,23 +37,28 @@ export interface CalendarAccess {
30
37
  }>;
31
38
  /**
32
39
  * Requests permission for a given scope.
40
+ * On Android, `readReminders` and `writeReminders` reject with `Invalid scope.`
33
41
  *
34
42
  * @example
35
- * this.requestPermission({ scope: CalendarPermissionScope.READ_CALENDAR });
43
+ * CapacitorCalendar.requestPermission({ scope: CalendarPermissionScope.READ_CALENDAR });
44
+ *
45
+ * @throws {Error} `Scope must be provided.` — when `scope` is missing.
46
+ * @throws {Error} `Invalid scope.` — when `scope` is invalid, or a reminders scope on Android.
36
47
  *
37
- * @deprecated Use {@link requestWriteOnlyCalendarAccess}, {@link requestReadOnlyCalendarAccess},
38
- * {@link requestFullCalendarAccess} or {@link requestFullRemindersAccess} instead.
48
+ * @deprecated Use {@link requestWriteOnlyCalendarAccess},
49
+ * {@link requestReadOnlyCalendarAccess} (Android),
50
+ * {@link requestFullCalendarAccess} (also for read on iOS),
51
+ * or {@link requestFullRemindersAccess} instead.
39
52
  *
40
53
  * @platform Android, iOS
41
54
  * @since 0.1.0
42
55
  */
43
- requestPermission(options: {
44
- scope: CalendarPermissionScope;
45
- }): Promise<{
56
+ requestPermission(options: RequestPermissionOptions): Promise<{
46
57
  result: PermissionState;
47
58
  }>;
48
59
  /**
49
60
  * Requests permission for all calendar and reminder permissions.
61
+ * On Android, only calendar permissions are requested; reminder keys stay `"prompt"`.
50
62
  *
51
63
  * @deprecated Use {@link requestFullCalendarAccess} or {@link requestFullRemindersAccess} instead.
52
64
  * @platform Android, iOS
@@ -106,9 +118,9 @@ export interface CalendarAccess {
106
118
  * @platform Android, iOS
107
119
  * @since 7.1.0
108
120
  */
109
- export declare type CheckAllPermissionsResult = Record<CalendarPermissionScope, PermissionState>;
121
+ export type CheckAllPermissionsResult = Record<CalendarPermissionScope, PermissionState>;
110
122
  /**
111
123
  * @platform Android, iOS
112
124
  * @since 7.1.0
113
125
  */
114
- export declare type RequestAllPermissionsResult = CheckAllPermissionsResult;
126
+ export type RequestAllPermissionsResult = CheckAllPermissionsResult;
@@ -1 +1 @@
1
- {"version":3,"file":"calendar-access.js","sourceRoot":"","sources":["../../../src/sub-definitions/calendar-access.ts"],"names":[],"mappings":"","sourcesContent":["import { CalendarPermissionScope } from \"../schemas/enums/calendar-permission-scope\";\nimport type { PermissionState } from \"@capacitor/core\";\n\n/**\n * @since 7.1.0\n */\nexport interface CalendarAccess {\n /**\n * Retrieves the current permission state for a given scope.\n *\n * @example\n * CapacitorCalendar.checkPermission({ scope: CalendarPermissionScope.READ_CALENDAR });\n *\n * @platform Android, iOS\n * @since 0.1.0\n *\n */\n checkPermission(options: {\n scope: CalendarPermissionScope;\n }): Promise<{ result: PermissionState }>;\n\n /**\n * Retrieves the current state of all permissions.\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n checkAllPermissions(): Promise<{ result: CheckAllPermissionsResult }>;\n\n /**\n * Requests permission for a given scope.\n *\n * @example\n * this.requestPermission({ scope: CalendarPermissionScope.READ_CALENDAR });\n *\n * @deprecated Use {@link requestWriteOnlyCalendarAccess}, {@link requestReadOnlyCalendarAccess},\n * {@link requestFullCalendarAccess} or {@link requestFullRemindersAccess} instead.\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n requestPermission(options: {\n scope: CalendarPermissionScope;\n }): Promise<{ result: PermissionState }>;\n\n /**\n * Requests permission for all calendar and reminder permissions.\n *\n * @deprecated Use {@link requestFullCalendarAccess} or {@link requestFullRemindersAccess} instead.\n * @platform Android, iOS\n * @since 0.1.0\n */\n requestAllPermissions(): Promise<{ result: RequestAllPermissionsResult }>;\n\n /**\n * Requests write access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSCalendarsWriteOnlyAccessUsageDescription` |\n * | iOS 13-16 | `NSCalendarsUsageDescription` |\n * | Android | `android.permission.WRITE_CALENDAR` |\n *\n * @platform Android, iOS\n * @since 5.4.0\n */\n requestWriteOnlyCalendarAccess(): Promise<{ result: PermissionState }>;\n\n /**\n * Requests read access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | Android | `android.permission.READ_CALENDAR` |\n *\n * @platform Android\n * @since 5.4.0\n */\n requestReadOnlyCalendarAccess(): Promise<{ result: PermissionState }>;\n\n /**\n * Requests read and write access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSCalendarsFullAccessUsageDescription` |\n * | iOS 13-16 | `NSCalendarsUsageDescription` |\n * | Android | `android.permission.READ_CALENDAR` & `android.permission.WRITE_CALENDAR` |\n *\n * @platform Android, iOS\n * @since 5.4.0\n */\n requestFullCalendarAccess(): Promise<{ result: PermissionState }>;\n}\n\n/**\n * @platform Android, iOS\n * @since 7.1.0\n */\nexport type CheckAllPermissionsResult = Record<\n CalendarPermissionScope,\n PermissionState\n>;\n\n/**\n * @platform Android, iOS\n * @since 7.1.0\n */\nexport type RequestAllPermissionsResult = CheckAllPermissionsResult;\n"]}
1
+ {"version":3,"file":"calendar-access.js","sourceRoot":"","sources":["../../../src/sub-definitions/calendar-access.ts"],"names":[],"mappings":"","sourcesContent":["import type { PermissionState } from '@capacitor/core';\n\nimport type { CalendarPermissionScope } from '../schemas/enums/calendar-permission-scope';\nimport type { CheckPermissionOptions } from '../schemas/interfaces/check-permission-options';\nimport type { RequestPermissionOptions } from '../schemas/interfaces/request-permission-options';\n\n/**\n * @since 7.1.0\n */\nexport interface CalendarAccess {\n /**\n * Retrieves the current permission state for a given scope.\n * On Android, `readReminders` and `writeReminders` resolve to `\"prompt\"`.\n *\n * @example\n * CapacitorCalendar.checkPermission({ scope: CalendarPermissionScope.READ_CALENDAR });\n *\n * @throws {Error} `Scope must be provided.` — when `scope` is missing.\n * @throws {Error} `Invalid scope.` — when `scope` is invalid.\n * @throws {Error} `Unhandled permission state.` — when the native status cannot be mapped.\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n checkPermission(options: CheckPermissionOptions): Promise<{ result: PermissionState }>;\n\n /**\n * Retrieves the current state of all permissions.\n * On Android, reminder keys always resolve to `\"prompt\"`.\n *\n * @throws {Error} `Unhandled permission state.` — when a native status cannot be mapped.\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n checkAllPermissions(): Promise<{ result: CheckAllPermissionsResult }>;\n\n /**\n * Requests permission for a given scope.\n * On Android, `readReminders` and `writeReminders` reject with `Invalid scope.`\n *\n * @example\n * CapacitorCalendar.requestPermission({ scope: CalendarPermissionScope.READ_CALENDAR });\n *\n * @throws {Error} `Scope must be provided.` — when `scope` is missing.\n * @throws {Error} `Invalid scope.` — when `scope` is invalid, or a reminders scope on Android.\n *\n * @deprecated Use {@link requestWriteOnlyCalendarAccess},\n * {@link requestReadOnlyCalendarAccess} (Android),\n * {@link requestFullCalendarAccess} (also for read on iOS),\n * or {@link requestFullRemindersAccess} instead.\n *\n * @platform Android, iOS\n * @since 0.1.0\n */\n requestPermission(options: RequestPermissionOptions): Promise<{ result: PermissionState }>;\n\n /**\n * Requests permission for all calendar and reminder permissions.\n * On Android, only calendar permissions are requested; reminder keys stay `\"prompt\"`.\n *\n * @deprecated Use {@link requestFullCalendarAccess} or {@link requestFullRemindersAccess} instead.\n * @platform Android, iOS\n * @since 0.1.0\n */\n requestAllPermissions(): Promise<{ result: RequestAllPermissionsResult }>;\n\n /**\n * Requests write access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSCalendarsWriteOnlyAccessUsageDescription` |\n * | iOS 13-16 | `NSCalendarsUsageDescription` |\n * | Android | `android.permission.WRITE_CALENDAR` |\n *\n * @platform Android, iOS\n * @since 5.4.0\n */\n requestWriteOnlyCalendarAccess(): Promise<{ result: PermissionState }>;\n\n /**\n * Requests read access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | Android | `android.permission.READ_CALENDAR` |\n *\n * @platform Android\n * @since 5.4.0\n */\n requestReadOnlyCalendarAccess(): Promise<{ result: PermissionState }>;\n\n /**\n * Requests read and write access to the calendar.\n *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSCalendarsFullAccessUsageDescription` |\n * | iOS 13-16 | `NSCalendarsUsageDescription` |\n * | Android | `android.permission.READ_CALENDAR` & `android.permission.WRITE_CALENDAR` |\n *\n * @platform Android, iOS\n * @since 5.4.0\n */\n requestFullCalendarAccess(): Promise<{ result: PermissionState }>;\n}\n\n/**\n * @platform Android, iOS\n * @since 7.1.0\n */\nexport type CheckAllPermissionsResult = Record<CalendarPermissionScope, PermissionState>;\n\n/**\n * @platform Android, iOS\n * @since 7.1.0\n */\nexport type RequestAllPermissionsResult = CheckAllPermissionsResult;\n"]}
@@ -1,12 +1,17 @@
1
- import type { Calendar } from "../schemas/interfaces/calendar";
2
- import type { CalendarSource } from "../schemas/interfaces/calendar-source";
3
- import type { CreateCalendarOptions } from "../schemas/interfaces/create-calendar-options";
4
- import type { DeleteCalendarOptions } from "../schemas/interfaces/delete-calendar-options";
5
- import type { OpenCalendarOptions } from "../schemas/interfaces/open-calendar-options";
6
- import type { SelectCalendarsWithPromptOptions } from "../schemas/interfaces/select-calendars-with-prompt-options";
1
+ import type { Calendar } from '../schemas/interfaces/calendar';
2
+ import type { CreateCalendarOptions } from '../schemas/interfaces/create-calendar-options';
3
+ import type { CreateCalendarResult } from '../schemas/interfaces/create-calendar-result';
4
+ import type { DeleteCalendarOptions } from '../schemas/interfaces/delete-calendar-options';
5
+ import type { FetchAllCalendarSourcesResult } from '../schemas/interfaces/fetch-all-calendar-sources-result';
6
+ import type { GetDefaultCalendarOptions } from '../schemas/interfaces/get-default-calendar-options';
7
+ import type { ListCalendarsResult } from '../schemas/interfaces/list-calendars-result';
8
+ import type { ModifyCalendarOptions } from '../schemas/interfaces/modify-calendar-options';
9
+ import type { OpenCalendarOptions } from '../schemas/interfaces/open-calendar-options';
10
+ import type { SelectCalendarsWithPromptOptions } from '../schemas/interfaces/select-calendars-with-prompt-options';
11
+ import type { SelectCalendarsWithPromptResult } from '../schemas/interfaces/select-calendars-with-prompt-result';
7
12
  export interface CalendarOperations {
8
13
  /**
9
- * Save the changes to the calendar.
14
+ * Saves pending calendar changes.
10
15
  *
11
16
  * @platform iOS
12
17
  * @since 7.1.0
@@ -15,37 +20,54 @@ export interface CalendarOperations {
15
20
  /**
16
21
  * Opens a system interface to choose one or multiple calendars.
17
22
  *
23
+ * Calendar access is expected. Call `requestFullCalendarAccess()` first.
24
+ * Without authorization the chooser can look empty.
25
+ *
26
+ * On confirm, `result` contains the calendars the user selected.
27
+ * On cancel, `result` is an empty array.
28
+ *
29
+ * If a chooser is already presented, a new call is rejected; the in-flight
30
+ * call continues until the user confirms or cancels.
31
+ *
18
32
  * @platform iOS
19
33
  * @since 0.2.0
20
34
  */
21
- selectCalendarsWithPrompt(options?: SelectCalendarsWithPromptOptions): Promise<{
22
- result: Calendar[];
23
- }>;
35
+ selectCalendarsWithPrompt(options?: SelectCalendarsWithPromptOptions): Promise<SelectCalendarsWithPromptResult>;
24
36
  /**
25
37
  * Retrieves a list of calendar sources.
26
38
  *
39
+ * Requires calendar access. Without authorization, `result` is typically
40
+ * an empty array. This method does not reject solely for missing permission.
41
+ *
27
42
  * @platform iOS
28
43
  * @since 6.6.0
29
44
  */
30
- fetchAllCalendarSources(): Promise<{
31
- result: CalendarSource[];
32
- }>;
45
+ fetchAllCalendarSources(): Promise<FetchAllCalendarSourcesResult>;
33
46
  /**
34
47
  * Retrieves a list of all available calendars.
35
48
  *
49
+ * Requires calendar read access. On Android, missing permission typically
50
+ * rejects. On iOS, missing authorization typically returns an empty `result`.
51
+ *
36
52
  * @platform Android, iOS
37
53
  * @since 7.1.0
38
54
  */
39
- listCalendars(): Promise<{
40
- result: Calendar[];
41
- }>;
55
+ listCalendars(): Promise<ListCalendarsResult>;
42
56
  /**
43
57
  * Retrieves the default calendar.
44
58
  *
59
+ * Requires calendar read access. On Android, missing permission typically
60
+ * rejects. On iOS, missing authorization typically yields `result: null`.
61
+ *
62
+ * The system default is the primary calendar on Android and
63
+ * `defaultCalendarForNewEvents` on iOS. When neither exists and
64
+ * `useFallbackCalendar` is true, the first available calendar is returned.
65
+ * Otherwise the method returns `null` when there is no system default.
66
+ *
45
67
  * @platform Android, iOS
46
68
  * @since 0.3.0
47
69
  */
48
- getDefaultCalendar(): Promise<{
70
+ getDefaultCalendar(options?: GetDefaultCalendarOptions): Promise<{
49
71
  result: Calendar | null;
50
72
  }>;
51
73
  /**
@@ -61,17 +83,50 @@ export interface CalendarOperations {
61
83
  /**
62
84
  * Creates a calendar.
63
85
  *
86
+ * `title` is required. `color` is optional and defaults to `#007AFF`.
87
+ * On Android, `accountName` and `ownerAccount` are required at runtime.
88
+ *
89
+ * @example
90
+ * CapacitorCalendar.createCalendar({
91
+ * title: 'Work',
92
+ * accountName: 'plugin@example.com',
93
+ * ownerAccount: 'plugin@example.com',
94
+ * });
95
+ *
96
+ * @throws {Error} `Title must be provided.` — when `title` is missing.
97
+ * @throws {Error} `Invalid color format.` — when `color` is present but invalid.
98
+ * @throws {Error} `Account name must be provided.` — when `accountName` is missing on Android.
99
+ * @throws {Error} `Owner account must be provided.` — when `ownerAccount` is missing on Android.
100
+ * @throws {Error} `Calendar source not found.` — when `sourceId` is set and no EventKit source matches (iOS).
101
+ * @throws {Error} `Failed to retrieve calendar ID.` — when the calendar is created but no id is returned.
102
+ *
64
103
  * @platform Android, iOS
65
104
  * @since 5.2.0
66
105
  */
67
- createCalendar(options: CreateCalendarOptions): Promise<{
68
- id: string;
69
- }>;
106
+ createCalendar(options: CreateCalendarOptions): Promise<CreateCalendarResult>;
70
107
  /**
71
108
  * Deletes a calendar by id.
72
109
  *
110
+ * @throws {Error} `Calendar ID must be provided.` — when `id` is missing.
111
+ * @throws {Error} `Invalid calendar ID.` — when `id` is not a numeric Android calendar id.
112
+ * @throws {Error} `Calendar not found.` — when no calendar exists for `id`.
113
+ *
73
114
  * @platform Android, iOS
74
115
  * @since 5.2.0
75
116
  */
76
117
  deleteCalendar(options: DeleteCalendarOptions): Promise<void>;
118
+ /**
119
+ * Modifies a calendar with options.
120
+ *
121
+ * @throws {Error} `Calendar ID must be provided.` — when `id` is missing.
122
+ * @throws {Error} `Invalid calendar ID.` — when `id` is not a numeric Android calendar id.
123
+ * @throws {Error} `At least one of title or color must be provided.` — when both are omitted.
124
+ * @throws {Error} `Invalid color format.` — when `color` is present but invalid.
125
+ * @throws {Error} `Calendar not found.` — when no calendar exists for `id`.
126
+ * @throws {Error} `Calendar is not modifiable.` — when the calendar cannot be modified (iOS).
127
+ *
128
+ * @platform Android, iOS
129
+ * @since 7.2.0
130
+ */
131
+ modifyCalendar(options: ModifyCalendarOptions): Promise<void>;
77
132
  }
@@ -1 +1 @@
1
- {"version":3,"file":"calendar-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/calendar-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { Calendar } from \"../schemas/interfaces/calendar\";\nimport type { CalendarSource } from \"../schemas/interfaces/calendar-source\";\nimport type { CreateCalendarOptions } from \"../schemas/interfaces/create-calendar-options\";\nimport type { DeleteCalendarOptions } from \"../schemas/interfaces/delete-calendar-options\";\nimport type { OpenCalendarOptions } from \"../schemas/interfaces/open-calendar-options\";\nimport type { SelectCalendarsWithPromptOptions } from \"../schemas/interfaces/select-calendars-with-prompt-options\";\n\nexport interface CalendarOperations {\n /**\n * Save the changes to the calendar.\n *\n * @platform iOS\n * @since 7.1.0\n */\n commit(): Promise<void>;\n /**\n * Opens a system interface to choose one or multiple calendars.\n *\n * @platform iOS\n * @since 0.2.0\n */\n selectCalendarsWithPrompt(\n options?: SelectCalendarsWithPromptOptions,\n ): Promise<{ result: Calendar[] }>;\n /**\n * Retrieves a list of calendar sources.\n *\n * @platform iOS\n * @since 6.6.0\n */\n fetchAllCalendarSources(): Promise<{ result: CalendarSource[] }>;\n /**\n * Retrieves a list of all available calendars.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n listCalendars(): Promise<{ result: Calendar[] }>;\n /**\n * Retrieves the default calendar.\n *\n * @platform Android, iOS\n * @since 0.3.0\n */\n getDefaultCalendar(): Promise<{ result: Calendar | null }>;\n /**\n * Opens the calendar app.\n *\n * @example\n * CapacitorCalendar.openCalendar({ date: Date.now() });\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n openCalendar(options?: OpenCalendarOptions): Promise<void>;\n /**\n * Creates a calendar.\n *\n * @platform Android, iOS\n * @since 5.2.0\n */\n createCalendar(options: CreateCalendarOptions): Promise<{ id: string }>;\n /**\n * Deletes a calendar by id.\n *\n * @platform Android, iOS\n * @since 5.2.0\n */\n deleteCalendar(options: DeleteCalendarOptions): Promise<void>;\n}\n"]}
1
+ {"version":3,"file":"calendar-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/calendar-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { Calendar } from '../schemas/interfaces/calendar';\nimport type { CreateCalendarOptions } from '../schemas/interfaces/create-calendar-options';\nimport type { CreateCalendarResult } from '../schemas/interfaces/create-calendar-result';\nimport type { DeleteCalendarOptions } from '../schemas/interfaces/delete-calendar-options';\nimport type { FetchAllCalendarSourcesResult } from '../schemas/interfaces/fetch-all-calendar-sources-result';\nimport type { GetDefaultCalendarOptions } from '../schemas/interfaces/get-default-calendar-options';\nimport type { ListCalendarsResult } from '../schemas/interfaces/list-calendars-result';\nimport type { ModifyCalendarOptions } from '../schemas/interfaces/modify-calendar-options';\nimport type { OpenCalendarOptions } from '../schemas/interfaces/open-calendar-options';\nimport type { SelectCalendarsWithPromptOptions } from '../schemas/interfaces/select-calendars-with-prompt-options';\nimport type { SelectCalendarsWithPromptResult } from '../schemas/interfaces/select-calendars-with-prompt-result';\n\nexport interface CalendarOperations {\n /**\n * Saves pending calendar changes.\n *\n * @platform iOS\n * @since 7.1.0\n */\n commit(): Promise<void>;\n /**\n * Opens a system interface to choose one or multiple calendars.\n *\n * Calendar access is expected. Call `requestFullCalendarAccess()` first.\n * Without authorization the chooser can look empty.\n *\n * On confirm, `result` contains the calendars the user selected.\n * On cancel, `result` is an empty array.\n *\n * If a chooser is already presented, a new call is rejected; the in-flight\n * call continues until the user confirms or cancels.\n *\n * @platform iOS\n * @since 0.2.0\n */\n selectCalendarsWithPrompt(options?: SelectCalendarsWithPromptOptions): Promise<SelectCalendarsWithPromptResult>;\n /**\n * Retrieves a list of calendar sources.\n *\n * Requires calendar access. Without authorization, `result` is typically\n * an empty array. This method does not reject solely for missing permission.\n *\n * @platform iOS\n * @since 6.6.0\n */\n fetchAllCalendarSources(): Promise<FetchAllCalendarSourcesResult>;\n /**\n * Retrieves a list of all available calendars.\n *\n * Requires calendar read access. On Android, missing permission typically\n * rejects. On iOS, missing authorization typically returns an empty `result`.\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n listCalendars(): Promise<ListCalendarsResult>;\n /**\n * Retrieves the default calendar.\n *\n * Requires calendar read access. On Android, missing permission typically\n * rejects. On iOS, missing authorization typically yields `result: null`.\n *\n * The system default is the primary calendar on Android and\n * `defaultCalendarForNewEvents` on iOS. When neither exists and\n * `useFallbackCalendar` is true, the first available calendar is returned.\n * Otherwise the method returns `null` when there is no system default.\n *\n * @platform Android, iOS\n * @since 0.3.0\n */\n getDefaultCalendar(options?: GetDefaultCalendarOptions): Promise<{ result: Calendar | null }>;\n /**\n * Opens the calendar app.\n *\n * @example\n * CapacitorCalendar.openCalendar({ date: Date.now() });\n *\n * @platform Android, iOS\n * @since 7.1.0\n */\n openCalendar(options?: OpenCalendarOptions): Promise<void>;\n /**\n * Creates a calendar.\n *\n * `title` is required. `color` is optional and defaults to `#007AFF`.\n * On Android, `accountName` and `ownerAccount` are required at runtime.\n *\n * @example\n * CapacitorCalendar.createCalendar({\n * title: 'Work',\n * accountName: 'plugin@example.com',\n * ownerAccount: 'plugin@example.com',\n * });\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 * @throws {Error} `Account name must be provided.` — when `accountName` is missing on Android.\n * @throws {Error} `Owner account must be provided.` — when `ownerAccount` is missing on Android.\n * @throws {Error} `Calendar source not found.` — when `sourceId` is set and no EventKit source matches (iOS).\n * @throws {Error} `Failed to retrieve calendar ID.` — when the calendar is created but no id is returned.\n *\n * @platform Android, iOS\n * @since 5.2.0\n */\n createCalendar(options: CreateCalendarOptions): Promise<CreateCalendarResult>;\n /**\n * Deletes a calendar by id.\n *\n * @throws {Error} `Calendar ID must be provided.` — when `id` is missing.\n * @throws {Error} `Invalid calendar ID.` — when `id` is not a numeric Android calendar id.\n * @throws {Error} `Calendar not found.` — when no calendar exists for `id`.\n *\n * @platform Android, iOS\n * @since 5.2.0\n */\n deleteCalendar(options: DeleteCalendarOptions): Promise<void>;\n /**\n * Modifies a calendar with options.\n *\n * @throws {Error} `Calendar ID must be provided.` — when `id` is missing.\n * @throws {Error} `Invalid calendar ID.` — when `id` is not a numeric Android calendar id.\n * @throws {Error} `At least one of title or color must be provided.` — when both are omitted.\n * @throws {Error} `Invalid color format.` — when `color` is present but invalid.\n * @throws {Error} `Calendar not found.` — when no calendar exists for `id`.\n * @throws {Error} `Calendar is not modifiable.` — when the calendar cannot be modified (iOS).\n *\n * @platform Android, iOS\n * @since 7.2.0\n */\n modifyCalendar(options: ModifyCalendarOptions): Promise<void>;\n}\n"]}
@@ -1,18 +1,21 @@
1
- import type { CalendarEvent } from "../schemas/interfaces/calendar-event";
2
- import type { CreateEventOptions } from "../schemas/interfaces/create-event-options";
3
- import type { CreateEventWithPromptOptions } from "../schemas/interfaces/create-event-with-prompt-options";
4
- import type { DeleteEventOptions } from "../schemas/interfaces/delete-event-options";
5
- import type { DeleteEventWithPromptOptions } from "../schemas/interfaces/delete-event-with-prompt-options";
6
- import type { DeleteEventsByIdOptions } from "../schemas/interfaces/delete-events-by-id-options";
7
- import type { EventEditAction } from "../schemas/types/event-edit-action";
8
- import type { ListEventsInRangeOptions } from "../schemas/interfaces/list-events-in-range-options";
9
- import type { ModifyEventOptions } from "../schemas/interfaces/modify-event-options";
10
- import type { ModifyEventWithPromptOptions } from "../schemas/interfaces/modify-event-with-prompt-options";
1
+ import type { CreateEventOptions } from '../schemas/interfaces/create-event-options';
2
+ import type { CreateEventResult } from '../schemas/interfaces/create-event-result';
3
+ import type { CreateEventWithPromptOptions } from '../schemas/interfaces/create-event-with-prompt-options';
4
+ import type { CreateEventWithPromptResult } from '../schemas/interfaces/create-event-with-prompt-result';
5
+ import type { DeleteEventOptions } from '../schemas/interfaces/delete-event-options';
6
+ import type { DeleteEventWithPromptOptions } from '../schemas/interfaces/delete-event-with-prompt-options';
7
+ import type { DeleteEventsByIdOptions } from '../schemas/interfaces/delete-events-by-id-options';
8
+ import type { ListEventsInRangeOptions } from '../schemas/interfaces/list-events-in-range-options';
9
+ import type { ListEventsInRangeResult } from '../schemas/interfaces/list-events-in-range-result';
10
+ import type { ModifyEventOptions } from '../schemas/interfaces/modify-event-options';
11
+ import type { ModifyEventWithPromptOptions } from '../schemas/interfaces/modify-event-with-prompt-options';
12
+ import type { EventEditAction } from '../schemas/types/event-edit-action';
11
13
  export interface EventOperations {
12
14
  /**
13
- * Opens the system calendar interface to create a new event.
14
- * On Android always returns `null`.
15
- * 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.
16
19
  *
17
20
  * @example
18
21
  * const options = {
@@ -21,12 +24,10 @@ export interface EventOperations {
21
24
  * }
22
25
  * await CapacitorCalendar.createEventWithPrompt(options)
23
26
  *
24
- * @platform Android, iOS
27
+ * @platform Android, iOS, Web
25
28
  * @since 0.1.0
26
29
  */
27
- createEventWithPrompt(options?: CreateEventWithPromptOptions): Promise<{
28
- id: string | null;
29
- }>;
30
+ createEventWithPrompt(options?: CreateEventWithPromptOptions): Promise<CreateEventWithPromptResult>;
30
31
  /**
31
32
  * Opens a system calendar interface to modify an event.
32
33
  * On Android always returns `null`.
@@ -46,13 +47,21 @@ export interface EventOperations {
46
47
  }>;
47
48
  /**
48
49
  * Creates an event in the calendar.
50
+ * On Android and iOS, inserts into the system calendar and returns its `id`.
51
+ * On Web, builds an `.ics` `File` as `ics` (no calendar store). See MCP `docs://web-behavior`.
52
+ *
53
+ * @example
54
+ * const { id, ics } = await CapacitorCalendar.createEvent({
55
+ * title: 'Team standup',
56
+ * startDate: Date.now(),
57
+ * icsFileName: 'team-standup.ics',
58
+ * autoDownloadIcsFile: true,
59
+ * });
49
60
  *
50
- * @platform iOS, Android
61
+ * @platform Android, iOS, Web
51
62
  * @since 0.4.0
52
63
  */
53
- createEvent(options: CreateEventOptions): Promise<{
54
- id: string;
55
- }>;
64
+ createEvent(options: CreateEventOptions): Promise<CreateEventResult>;
56
65
  /**
57
66
  * Modifies an event.
58
67
  *
@@ -87,14 +96,26 @@ export interface EventOperations {
87
96
  deleted: boolean;
88
97
  }>;
89
98
  /**
90
- * Retrieves the events within a date range.
99
+ * Retrieves events that overlap a date range.
100
+ *
101
+ * An event is included when its time interval intersects `[from, to]`, including
102
+ * multi-day events that span the range without starting or ending inside it.
103
+ *
104
+ * @example
105
+ * const startOfDay = new Date();
106
+ * startOfDay.setHours(0, 0, 0, 0);
107
+ * const startOfNextDay = new Date(startOfDay);
108
+ * startOfNextDay.setDate(startOfNextDay.getDate() + 1);
109
+ *
110
+ * const { result } = await CapacitorCalendar.listEventsInRange({
111
+ * from: startOfDay.getTime(),
112
+ * to: startOfNextDay.getTime(),
113
+ * });
91
114
  *
92
115
  * @platform Android, iOS
93
116
  * @since 0.10.0
94
117
  */
95
- listEventsInRange(options: ListEventsInRangeOptions): Promise<{
96
- result: CalendarEvent[];
97
- }>;
118
+ listEventsInRange(options: ListEventsInRangeOptions): Promise<ListEventsInRangeResult>;
98
119
  }
99
120
  /**
100
121
  * @since 7.1.0
@@ -1 +1 @@
1
- {"version":3,"file":"event-operations.js","sourceRoot":"","sources":["../../../src/sub-definitions/event-operations.ts"],"names":[],"mappings":"","sourcesContent":["import type { CalendarEvent } from \"../schemas/interfaces/calendar-event\";\nimport type { CreateEventOptions } from \"../schemas/interfaces/create-event-options\";\nimport type { CreateEventWithPromptOptions } from \"../schemas/interfaces/create-event-with-prompt-options\";\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 { EventEditAction } from \"../schemas/types/event-edit-action\";\nimport type { ListEventsInRangeOptions } from \"../schemas/interfaces/list-events-in-range-options\";\nimport type { ModifyEventOptions } from \"../schemas/interfaces/modify-event-options\";\nimport type { ModifyEventWithPromptOptions } from \"../schemas/interfaces/modify-event-with-prompt-options\";\n\nexport interface EventOperations {\n /**\n * Opens the system calendar interface to create a new event.\n * On Android always returns `null`.\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(\n options?: CreateEventWithPromptOptions,\n ): Promise<{ id: string | null }>;\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(\n options: ModifyEventWithPromptOptions,\n ): Promise<{ result: EventEditAction | null }>;\n /**\n * Creates an event in the calendar.\n *\n * @platform iOS, Android\n * @since 0.4.0\n */\n createEvent(options: CreateEventOptions): Promise<{ id: string }>;\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(\n options: DeleteEventsByIdOptions,\n ): 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(\n options: DeleteEventWithPromptOptions,\n ): Promise<{ deleted: boolean }>;\n /**\n * Retrieves the events within a date range.\n *\n * @platform Android, iOS\n * @since 0.10.0\n */\n listEventsInRange(\n options: ListEventsInRangeOptions,\n ): Promise<{ result: CalendarEvent[] }>;\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"]}
@@ -1,16 +1,20 @@
1
- import type { PermissionState } from "@capacitor/core";
1
+ import type { PermissionState } from '@capacitor/core';
2
2
  /**
3
3
  * @since 7.1.0
4
4
  */
5
5
  export interface RemindersAccess {
6
6
  /**
7
7
  * Requests read and write access to the reminders.
8
+ * Resolves with `"granted"` or `"denied"` (never `"prompt"`).
9
+ * A grant covers both `readReminders` and `writeReminders`.
8
10
  *
9
11
  * @permissions
10
12
  * | Platform | Required |
11
13
  * |-----------|---------------------|
12
14
  * | iOS 17+ | `NSRemindersFullAccessUsageDescription` |
13
- * | iOS 10-16 | `NSRemindersUsageDescription` |
15
+ * | iOS 13-16 | `NSRemindersUsageDescription` |
16
+ *
17
+ * @throws {Error} when EventKit fails or required Info.plist keys are missing.
14
18
  *
15
19
  * @platform iOS
16
20
  * @see {@link CalendarPermissionScope}
@@ -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 *\n * @permissions\n * | Platform | Required |\n * |-----------|---------------------|\n * | iOS 17+ | `NSRemindersFullAccessUsageDescription` |\n * | iOS 10-16 | `NSRemindersUsageDescription` |\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"]}