@royalschedule/maps 4.0.15 → 4.0.17

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 (346) hide show
  1. package/dist/Additio/from/courses.js.map +1 -1
  2. package/dist/Additio/from/events.js.map +1 -1
  3. package/dist/Additio/from/groups.js.map +1 -1
  4. package/dist/Additio/from/index.js.map +1 -1
  5. package/dist/Additio/from/locations.js.map +1 -1
  6. package/dist/Additio/from/persons.js.map +1 -1
  7. package/dist/Additio/from/schedules.d.ts +7 -6
  8. package/dist/Additio/from/schedules.js +2 -4
  9. package/dist/Additio/from/schedules.js.map +1 -1
  10. package/dist/Additio/from/teachers.js.map +1 -1
  11. package/dist/Additio/to/index.d.ts +13 -11
  12. package/dist/Additio/to/schedules.js +2 -4
  13. package/dist/Additio/to/schedules.js.map +1 -1
  14. package/dist/Admentum/from/courses.js.map +1 -1
  15. package/dist/Admentum/from/events.js.map +1 -1
  16. package/dist/Admentum/from/groups.js.map +1 -1
  17. package/dist/Admentum/from/index.js.map +1 -1
  18. package/dist/Admentum/from/locations.js.map +1 -1
  19. package/dist/Admentum/from/persons.js.map +1 -1
  20. package/dist/Admentum/from/schedules.d.ts +7 -6
  21. package/dist/Admentum/from/schedules.js +2 -4
  22. package/dist/Admentum/from/schedules.js.map +1 -1
  23. package/dist/Admentum/from/teachers.js.map +1 -1
  24. package/dist/Admentum/to/index.d.ts +9 -8
  25. package/dist/Admentum/to/schedules.js +4 -7
  26. package/dist/Admentum/to/schedules.js.map +1 -1
  27. package/dist/Excel/index.d.ts +263 -26
  28. package/dist/Excel/v1/from/index.js +2 -1
  29. package/dist/Excel/v1/from/index.js.map +1 -1
  30. package/dist/Excel/v1/index.d.ts +218 -20
  31. package/dist/Excel/v2/from/index.js +99 -94
  32. package/dist/Excel/v2/from/index.js.map +1 -1
  33. package/dist/Excel/v2/index.d.ts +263 -26
  34. package/dist/IdunSoft/from/courses.js.map +1 -1
  35. package/dist/IdunSoft/from/events.js +1 -2
  36. package/dist/IdunSoft/from/events.js.map +1 -1
  37. package/dist/IdunSoft/from/groups.js.map +1 -1
  38. package/dist/IdunSoft/from/index.js.map +1 -1
  39. package/dist/IdunSoft/from/locations.js.map +1 -1
  40. package/dist/IdunSoft/from/schedules.d.ts +6 -5
  41. package/dist/IdunSoft/from/schedules.js.map +1 -1
  42. package/dist/IdunSoft/from/teachers.js.map +1 -1
  43. package/dist/IdunSoft/to/index.d.ts +2 -1
  44. package/dist/IdunSoft/to/schedules.js +5 -8
  45. package/dist/IdunSoft/to/schedules.js.map +1 -1
  46. package/dist/InfoMentor/to/index.d.ts +2 -1
  47. package/dist/InfoMentor/to/schedules.js +3 -4
  48. package/dist/InfoMentor/to/schedules.js.map +1 -1
  49. package/dist/PlanDigital/from/index.js.map +1 -1
  50. package/dist/PlanDigital/from/schedules.js +9 -11
  51. package/dist/PlanDigital/from/schedules.js.map +1 -1
  52. package/dist/PlanDigital/index.d.ts +73 -58
  53. package/dist/Quiculum/file/to/index.d.ts +10 -9
  54. package/dist/Quiculum/file/to/schedules.js +5 -9
  55. package/dist/Quiculum/file/to/schedules.js.map +1 -1
  56. package/dist/RS/from/division.d.ts +2 -1
  57. package/dist/RS/from/division.js +9 -6
  58. package/dist/RS/from/division.js.map +1 -1
  59. package/dist/RS/from/index.js.map +1 -1
  60. package/dist/RS/from/schedules.d.ts +2 -1
  61. package/dist/RS/from/schedules.js.map +1 -1
  62. package/dist/RS/make-connected.d.ts +17 -16
  63. package/dist/RS/make-connected.js +63 -96
  64. package/dist/RS/make-connected.js.map +1 -1
  65. package/dist/RS/to/index.js.map +1 -1
  66. package/dist/RS/to/initial-configuration.js +4 -6
  67. package/dist/RS/to/initial-configuration.js.map +1 -1
  68. package/dist/RS/to/input/collections.js.map +1 -1
  69. package/dist/RS/to/input/default.js +1 -2
  70. package/dist/RS/to/input/default.js.map +1 -1
  71. package/dist/RS/to/input/dependencies.js +1 -3
  72. package/dist/RS/to/input/dependencies.js.map +1 -1
  73. package/dist/RS/to/input/dynamic-locked-times.js +1 -2
  74. package/dist/RS/to/input/dynamic-locked-times.js.map +1 -1
  75. package/dist/RS/to/input/events.js +5 -3
  76. package/dist/RS/to/input/events.js.map +1 -1
  77. package/dist/RS/to/input/groups.js.map +1 -1
  78. package/dist/RS/to/input/individuals.js +2 -3
  79. package/dist/RS/to/input/individuals.js.map +1 -1
  80. package/dist/RS/to/input/input.js +1 -3
  81. package/dist/RS/to/input/input.js.map +1 -1
  82. package/dist/RS/to/input/intervals.js +2 -4
  83. package/dist/RS/to/input/intervals.js.map +1 -1
  84. package/dist/RS/to/input/periods.js +6 -8
  85. package/dist/RS/to/input/periods.js.map +1 -1
  86. package/dist/RS/to/input/settings.js.map +1 -1
  87. package/dist/RS/to/input/teachers.js.map +1 -1
  88. package/dist/RS/to/input/util/attach-locked-times.js.map +1 -1
  89. package/dist/RS/to/input/util/parse-days.js.map +1 -1
  90. package/dist/RS/to/input/util/parse-group-references.js.map +1 -1
  91. package/dist/RS/to/input/util/parse-intervals.js +2 -4
  92. package/dist/RS/to/input/util/parse-intervals.js.map +1 -1
  93. package/dist/RS/to/input/util/parse-location-references.js +1 -2
  94. package/dist/RS/to/input/util/parse-location-references.js.map +1 -1
  95. package/dist/RS/to/input/util/parse-max-working-hours.js.map +1 -1
  96. package/dist/RS/to/input/util/parse-minimum-break-length.js.map +1 -1
  97. package/dist/RS/to/input/util/util.js +1 -2
  98. package/dist/RS/to/input/util/util.js.map +1 -1
  99. package/dist/RS/to/schedules.js +1 -1
  100. package/dist/RS/to/schedules.js.map +1 -1
  101. package/dist/RS/types/to.d.ts +15 -5
  102. package/dist/RS/types/to.js +1 -1
  103. package/dist/RS/types/to.js.map +1 -1
  104. package/dist/SS12000/from/activities.js +1 -2
  105. package/dist/SS12000/from/activities.js.map +1 -1
  106. package/dist/SS12000/from/calendar-events.js.map +1 -1
  107. package/dist/SS12000/from/duties.js.map +1 -1
  108. package/dist/SS12000/from/groups.js.map +1 -1
  109. package/dist/SS12000/from/index.js.map +1 -1
  110. package/dist/SS12000/from/persons.js.map +1 -1
  111. package/dist/SS12000/from/resources.js.map +1 -1
  112. package/dist/SS12000/from/rooms.js.map +1 -1
  113. package/dist/SS12000/from/syllabuses.js.map +1 -1
  114. package/dist/SS12000/index.d.ts +12567 -9
  115. package/dist/SS12000/to/activities.js.map +1 -1
  116. package/dist/SS12000/to/calendar-events.js.map +1 -1
  117. package/dist/SS12000/to/common.js.map +1 -1
  118. package/dist/SS12000/to/duties.js.map +1 -1
  119. package/dist/SS12000/to/groups.js.map +1 -1
  120. package/dist/SS12000/to/index.d.ts +17 -16
  121. package/dist/SS12000/to/persons.js.map +1 -1
  122. package/dist/SS12000/to/resources.js.map +1 -1
  123. package/dist/SS12000/to/rooms.js.map +1 -1
  124. package/dist/SS12000/to/syllabuses.js.map +1 -1
  125. package/dist/SchoolSoft/api/from/index.js.map +1 -1
  126. package/dist/SchoolSoft/api/from/schedules.js +8 -12
  127. package/dist/SchoolSoft/api/from/schedules.js.map +1 -1
  128. package/dist/SchoolSoft/api/index.d.ts +444 -9
  129. package/dist/SchoolSoft/file/from/index.js.map +1 -1
  130. package/dist/SchoolSoft/file/from/schedules.js +83 -87
  131. package/dist/SchoolSoft/file/from/schedules.js.map +1 -1
  132. package/dist/SchoolSoft/file/index.d.ts +2 -1
  133. package/dist/SchoolSoft/file/to/index.d.ts +5 -4
  134. package/dist/SchoolSoft/file/to/schedules.js +1 -2
  135. package/dist/SchoolSoft/file/to/schedules.js.map +1 -1
  136. package/dist/SchoolSoft/index.d.ts +2 -1
  137. package/dist/Schoolity/txt/to/index.d.ts +2 -1
  138. package/dist/Schoolity/txt/to/schedules.js +5 -12
  139. package/dist/Schoolity/txt/to/schedules.js.map +1 -1
  140. package/dist/Skola24/mdb/from/course-and-events.js +3 -5
  141. package/dist/Skola24/mdb/from/course-and-events.js.map +1 -1
  142. package/dist/Skola24/mdb/from/groups.js.map +1 -1
  143. package/dist/Skola24/mdb/from/index.js.map +1 -1
  144. package/dist/Skola24/mdb/from/locations.js.map +1 -1
  145. package/dist/Skola24/mdb/from/schedule.d.ts +6 -5
  146. package/dist/Skola24/mdb/from/schedule.js.map +1 -1
  147. package/dist/Skola24/mdb/from/teachers.js.map +1 -1
  148. package/dist/Skola24/txt/from/calendar-exceptions.js +1 -2
  149. package/dist/Skola24/txt/from/calendar-exceptions.js.map +1 -1
  150. package/dist/Skola24/txt/from/division.js.map +1 -1
  151. package/dist/Skola24/txt/from/index.js.map +1 -1
  152. package/dist/Skola24/txt/from/period.js +31 -34
  153. package/dist/Skola24/txt/from/period.js.map +1 -1
  154. package/dist/Skola24/txt/from/schedules.d.ts +9 -8
  155. package/dist/Skola24/txt/from/schedules.js +10 -12
  156. package/dist/Skola24/txt/from/schedules.js.map +1 -1
  157. package/dist/Skola24/txt/from/util.js.map +1 -1
  158. package/dist/Skola24/txt/index.d.ts +2 -1
  159. package/dist/Skola24/txt/to/index.d.ts +2 -1
  160. package/dist/Skola24/txt/to/schedules.js +5 -12
  161. package/dist/Skola24/txt/to/schedules.js.map +1 -1
  162. package/dist/common/constants.js.map +1 -1
  163. package/dist/common/functions.js +46 -10
  164. package/dist/common/functions.js.map +1 -1
  165. package/dist/common/get-date.js.map +1 -1
  166. package/dist/common/make-chainable/index.js.map +1 -1
  167. package/dist/common/types.d.ts +3 -6
  168. package/dist/core/from/configurations.js.map +1 -1
  169. package/dist/core/from/courses.js.map +1 -1
  170. package/dist/core/from/events.js +1 -1
  171. package/dist/core/from/events.js.map +1 -1
  172. package/dist/core/from/exceptions.js.map +1 -1
  173. package/dist/core/from/groups.js.map +1 -1
  174. package/dist/core/from/index.js +9 -6
  175. package/dist/core/from/index.js.map +1 -1
  176. package/dist/core/from/locations.js.map +1 -1
  177. package/dist/core/from/locked-times.js.map +1 -1
  178. package/dist/core/from/overlap-groups.js.map +1 -1
  179. package/dist/core/from/periods.js.map +1 -1
  180. package/dist/core/from/persons.js.map +1 -1
  181. package/dist/core/from/root-intervals.js.map +1 -1
  182. package/dist/core/from/schedules.js.map +1 -1
  183. package/dist/core/from/syllabuses.js.map +1 -1
  184. package/dist/core/from/teachers.js.map +1 -1
  185. package/dist/core/index.d.ts +24 -1
  186. package/dist/core/index.js +4 -0
  187. package/dist/core/index.js.map +1 -1
  188. package/dist/core/interfaces/index.d.ts +23 -0
  189. package/dist/core/interfaces/index.js +6 -0
  190. package/dist/core/interfaces/other/companies.d.ts +132 -0
  191. package/dist/core/interfaces/other/companies.js +9 -0
  192. package/dist/core/interfaces/other/companies.js.map +1 -0
  193. package/dist/core/interfaces/other/etc.d.ts +19 -0
  194. package/dist/core/interfaces/other/index.d.ts +6 -0
  195. package/dist/core/interfaces/other/integrations.d.ts +17 -0
  196. package/dist/core/interfaces/other/operations.d.ts +36 -0
  197. package/dist/core/interfaces/other/policies.d.ts +31 -0
  198. package/dist/core/interfaces/other/sync-logs.d.ts +21 -0
  199. package/dist/core/interfaces/other/users.d.ts +35 -0
  200. package/dist/core/interfaces/vertices/companies.d.ts +8 -0
  201. package/dist/core/interfaces/vertices/configurations.d.ts +58 -0
  202. package/dist/core/interfaces/vertices/courses.d.ts +68 -0
  203. package/dist/core/{types → interfaces/vertices}/division-settings.d.ts +31 -29
  204. package/dist/core/interfaces/vertices/divisions.d.ts +31 -0
  205. package/dist/core/interfaces/vertices/events.d.ts +100 -0
  206. package/dist/core/interfaces/vertices/exceptions.d.ts +74 -0
  207. package/dist/core/interfaces/vertices/generations.d.ts +23 -0
  208. package/dist/core/interfaces/vertices/groups.d.ts +53 -0
  209. package/dist/core/interfaces/vertices/index.d.ts +209 -0
  210. package/dist/core/interfaces/vertices/index.js +3 -0
  211. package/dist/core/interfaces/vertices/locations.d.ts +22 -0
  212. package/dist/core/interfaces/vertices/locked-times.d.ts +37 -0
  213. package/dist/core/interfaces/vertices/overlap-groups.d.ts +17 -0
  214. package/dist/core/interfaces/vertices/periods.d.ts +15 -0
  215. package/dist/core/interfaces/vertices/persons.d.ts +32 -0
  216. package/dist/core/interfaces/vertices/properties/belongs-to.d.ts +11 -0
  217. package/dist/core/interfaces/vertices/properties/coalesced.d.ts +8 -0
  218. package/dist/core/interfaces/vertices/properties/days.d.ts +9 -0
  219. package/dist/core/interfaces/vertices/properties/index.d.ts +15 -0
  220. package/dist/core/interfaces/vertices/properties/intervals.d.ts +10 -0
  221. package/dist/core/{types/common → interfaces/vertices/properties}/maximum-schedule-span.d.ts +1 -1
  222. package/dist/core/interfaces/vertices/properties/min-break-length.d.ts +5 -0
  223. package/dist/core/{types/common/planned-schedule-duration.d.ts → interfaces/vertices/properties/planned-scheduled-duration.d.ts} +2 -2
  224. package/dist/core/interfaces/vertices/properties/species.d.ts +9 -0
  225. package/dist/core/interfaces/vertices/properties/tags.d.ts +9 -0
  226. package/dist/core/interfaces/vertices/properties/week.d.ts +22 -0
  227. package/dist/core/interfaces/vertices/properties/week.js +6 -0
  228. package/dist/core/interfaces/vertices/properties/week.js.map +1 -0
  229. package/dist/core/interfaces/vertices/root-intervals.d.ts +14 -0
  230. package/dist/core/interfaces/vertices/syllabuses.d.ts +18 -0
  231. package/dist/core/interfaces/vertices/teachers.d.ts +43 -0
  232. package/dist/core/interfaces/vertices/users.d.ts +8 -0
  233. package/dist/core/interfaces/vertices/util/common.d.ts +28 -0
  234. package/dist/core/interfaces/vertices/util/custom-vertex-export/index.d.ts +31 -0
  235. package/dist/core/interfaces/vertices/util/custom-vertex-export/util.d.ts +51 -0
  236. package/dist/core/interfaces/vertices/util/deep-vertex-export/index.d.ts +64 -0
  237. package/dist/core/interfaces/vertices/util/edges.d.ts +105 -0
  238. package/dist/core/interfaces/vertices/util/index.d.ts +5 -0
  239. package/dist/core/interfaces/vertices/util/keys-of.d.ts +27 -0
  240. package/dist/core/interfaces/vertices/util/serialized-vertex-export.d.ts +12 -0
  241. package/dist/core/interfaces/vertices/util/util.d.ts +76 -0
  242. package/dist/core/interfaces/vertices/util/vertex-query/index.d.ts +44 -0
  243. package/dist/core/interfaces/vertices/util/vertex-query/util.d.ts +13 -0
  244. package/dist/core/interfaces/vertices/util/vertex.d.ts +70 -0
  245. package/dist/core/interfaces/vertices/vertex-query.d.ts +102 -0
  246. package/dist/core/interfaces/vertices/vertex-query.js +94 -0
  247. package/dist/core/interfaces/vertices/vertex-query.js.map +1 -0
  248. package/dist/core/to/configurations.js +2 -3
  249. package/dist/core/to/configurations.js.map +1 -1
  250. package/dist/core/to/courses.js +2 -3
  251. package/dist/core/to/courses.js.map +1 -1
  252. package/dist/core/to/division.js.map +1 -1
  253. package/dist/core/to/events.js +2 -3
  254. package/dist/core/to/events.js.map +1 -1
  255. package/dist/core/to/exceptions.js +4 -4
  256. package/dist/core/to/exceptions.js.map +1 -1
  257. package/dist/core/to/groups.js +2 -3
  258. package/dist/core/to/groups.js.map +1 -1
  259. package/dist/core/to/locations.js +2 -3
  260. package/dist/core/to/locations.js.map +1 -1
  261. package/dist/core/to/locked-times.js +2 -3
  262. package/dist/core/to/locked-times.js.map +1 -1
  263. package/dist/core/to/overlap-groups.js +2 -3
  264. package/dist/core/to/overlap-groups.js.map +1 -1
  265. package/dist/core/to/periods.js +2 -3
  266. package/dist/core/to/periods.js.map +1 -1
  267. package/dist/core/to/persons.js +3 -9
  268. package/dist/core/to/persons.js.map +1 -1
  269. package/dist/core/to/root-intervals.js +2 -3
  270. package/dist/core/to/root-intervals.js.map +1 -1
  271. package/dist/core/to/schedules.d.ts +17 -18
  272. package/dist/core/to/schedules.js.map +1 -1
  273. package/dist/core/to/settings.js +2 -3
  274. package/dist/core/to/settings.js.map +1 -1
  275. package/dist/core/to/syllabuses.js +2 -3
  276. package/dist/core/to/syllabuses.js.map +1 -1
  277. package/dist/core/to/teachers.js +4 -4
  278. package/dist/core/to/teachers.js.map +1 -1
  279. package/dist/core/to/util.d.ts +4 -8
  280. package/dist/core/to/util.js +7 -5
  281. package/dist/core/to/util.js.map +1 -1
  282. package/dist/core/types/common/index.d.ts +4 -41
  283. package/dist/core/types/index.d.ts +108 -112
  284. package/dist/core/util.js +4 -5
  285. package/dist/core/util.js.map +1 -1
  286. package/dist/identify/constants/index.d.ts +1 -1
  287. package/dist/identify/constants/index.js.map +1 -1
  288. package/dist/identify/index.js +1 -2
  289. package/dist/identify/index.js.map +1 -1
  290. package/dist/index.d.ts +23 -1
  291. package/dist/index.js +4 -1
  292. package/dist/sdui/from/classes.js.map +1 -1
  293. package/dist/sdui/from/courses.js.map +1 -1
  294. package/dist/sdui/from/holidays.js.map +1 -1
  295. package/dist/sdui/from/index.js.map +1 -1
  296. package/dist/sdui/from/lessons.js +4 -0
  297. package/dist/sdui/from/lessons.js.map +1 -1
  298. package/dist/sdui/from/rooms.js.map +1 -1
  299. package/dist/sdui/from/schedules.d.ts +10 -8
  300. package/dist/sdui/from/schedules.js.map +1 -1
  301. package/dist/sdui/from/school-years.js +0 -1
  302. package/dist/sdui/from/school-years.js.map +1 -1
  303. package/dist/sdui/from/substitution-plans.js.map +1 -1
  304. package/dist/sdui/from/teachers.js.map +1 -1
  305. package/dist/sdui/index.d.ts +1 -1
  306. package/dist/sdui/to/classes.js.map +1 -1
  307. package/dist/sdui/to/courses.js.map +1 -1
  308. package/dist/sdui/to/holidays.js.map +1 -1
  309. package/dist/sdui/to/hours.js.map +1 -1
  310. package/dist/sdui/to/index.d.ts +12 -10
  311. package/dist/sdui/to/lessons.js.map +1 -1
  312. package/dist/sdui/to/rooms.js.map +1 -1
  313. package/dist/sdui/to/schedules.js.map +1 -1
  314. package/dist/sdui/to/school-years.js.map +1 -1
  315. package/dist/sdui/to/substitution-plans.js +3 -6
  316. package/dist/sdui/to/substitution-plans.js.map +1 -1
  317. package/dist/sdui/to/teachers.js.map +1 -1
  318. package/dist/vKlass/from/index.js.map +1 -1
  319. package/dist/vKlass/from/schedule.d.ts +4 -3
  320. package/dist/vKlass/from/schedule.js +2 -2
  321. package/dist/vKlass/from/schedule.js.map +1 -1
  322. package/dist/vKlass/to/schedules.d.ts +4 -4
  323. package/dist/vKlass/to/schedules.js +6 -17
  324. package/dist/vKlass/to/schedules.js.map +1 -1
  325. package/package.json +24 -22
  326. package/dist/core/types/areas.d.ts +0 -10
  327. package/dist/core/types/common/break-lengths.d.ts +0 -5
  328. package/dist/core/types/common/days.d.ts +0 -8
  329. package/dist/core/types/common/intervals.d.ts +0 -20
  330. package/dist/core/types/common/tag.d.ts +0 -9
  331. package/dist/core/types/configurations.d.ts +0 -31
  332. package/dist/core/types/courses.d.ts +0 -60
  333. package/dist/core/types/divisions.d.ts +0 -24
  334. package/dist/core/types/events.d.ts +0 -56
  335. package/dist/core/types/exceptions.d.ts +0 -35
  336. package/dist/core/types/groups.d.ts +0 -44
  337. package/dist/core/types/locations.d.ts +0 -27
  338. package/dist/core/types/locked-times.d.ts +0 -33
  339. package/dist/core/types/overlap-groups.d.ts +0 -14
  340. package/dist/core/types/periods.d.ts +0 -14
  341. package/dist/core/types/persons.d.ts +0 -38
  342. package/dist/core/types/root-intervals.d.ts +0 -13
  343. package/dist/core/types/schedules.d.ts +0 -44
  344. package/dist/core/types/syllabus.d.ts +0 -18
  345. package/dist/core/types/teachers.d.ts +0 -44
  346. package/dist/core/vertex-mapping.d.ts +0 -69
@@ -0,0 +1,94 @@
1
+ import { expectType } from "ts-expect";
2
+
3
+ //#region src/core/interfaces/vertices/vertex-query.ts
4
+ expectType(true);
5
+ /**
6
+ * See {@link createVertexQuery}
7
+ */
8
+ var VertexQuery = class {
9
+ constructor(_collection, _query) {
10
+ this._collection = _collection;
11
+ this._query = _query;
12
+ }
13
+ get collection() {
14
+ return this._collection;
15
+ }
16
+ get query() {
17
+ return this._query;
18
+ }
19
+ };
20
+ let createVertexQuery;
21
+ (function(_createVertexQuery) {
22
+ function division(query) {
23
+ return new VertexQuery("divisions", query);
24
+ }
25
+ _createVertexQuery.division = division;
26
+ function settings(query) {
27
+ return new VertexQuery("settings", query);
28
+ }
29
+ _createVertexQuery.settings = settings;
30
+ function exception(query) {
31
+ return new VertexQuery("exceptions", query);
32
+ }
33
+ _createVertexQuery.exception = exception;
34
+ function event(query) {
35
+ return new VertexQuery("events", query);
36
+ }
37
+ _createVertexQuery.event = event;
38
+ function scheduleEvent(query) {
39
+ return new VertexQuery("scheduleEvents", query);
40
+ }
41
+ _createVertexQuery.scheduleEvent = scheduleEvent;
42
+ function calendarEvent(query) {
43
+ return new VertexQuery("calendarEvents", query);
44
+ }
45
+ _createVertexQuery.calendarEvent = calendarEvent;
46
+ function course(query) {
47
+ return new VertexQuery("courses", query);
48
+ }
49
+ _createVertexQuery.course = course;
50
+ function generation(query) {
51
+ return new VertexQuery("generations", query);
52
+ }
53
+ _createVertexQuery.generation = generation;
54
+ function location(query) {
55
+ return new VertexQuery("locations", query);
56
+ }
57
+ _createVertexQuery.location = location;
58
+ function lockedTime(query) {
59
+ return new VertexQuery("lockedTimes", query);
60
+ }
61
+ _createVertexQuery.lockedTime = lockedTime;
62
+ function overlapGroup(query) {
63
+ return new VertexQuery("overlapGroups", query);
64
+ }
65
+ _createVertexQuery.overlapGroup = overlapGroup;
66
+ function period(query) {
67
+ return new VertexQuery("periods", query);
68
+ }
69
+ _createVertexQuery.period = period;
70
+ function person(query) {
71
+ return new VertexQuery("persons", query);
72
+ }
73
+ _createVertexQuery.person = person;
74
+ function rootInterval(query) {
75
+ return new VertexQuery("rootIntervals", query);
76
+ }
77
+ _createVertexQuery.rootInterval = rootInterval;
78
+ function syllabus(query) {
79
+ return new VertexQuery("syllabuses", query);
80
+ }
81
+ _createVertexQuery.syllabus = syllabus;
82
+ function group(query) {
83
+ return new VertexQuery("groups", query);
84
+ }
85
+ _createVertexQuery.group = group;
86
+ function teacher(query) {
87
+ return new VertexQuery("teachers", query);
88
+ }
89
+ _createVertexQuery.teacher = teacher;
90
+ })(createVertexQuery || (createVertexQuery = {}));
91
+
92
+ //#endregion
93
+ export { createVertexQuery };
94
+ //# sourceMappingURL=vertex-query.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"vertex-query.js","names":["_collection: C","_query: Q"],"sources":["../../../../src/core/interfaces/vertices/vertex-query.ts"],"sourcesContent":["import type { Collection, CustomVertexExport } from './util';\nimport type { TeacherVertex } from './teachers';\nimport type { ExceptionVertex } from './exceptions';\nimport type { EventVertex, ScheduleEventVertex, CalendarEventVertex } from './events';\nimport type { CourseVertex } from './courses';\nimport type { DivisionSettingsVertex } from './division-settings';\nimport type { DivisionVertex } from './divisions';\nimport type { GenerationVertex } from './generations';\nimport type { GroupVertex } from './groups';\nimport type { LocationVertex } from './locations';\nimport type { LockedTimeVertex } from './locked-times';\nimport type { OverlapGroupVertex } from './overlap-groups';\nimport type { PeriodVertex } from './periods';\nimport type { PersonVertex } from './persons';\nimport type { RootIntervalVertex } from './root-intervals';\nimport type { SyllabusVertex } from './syllabuses';\nimport type { ConfigurationVertex } from './configurations';\nimport type { CompanyVertex } from './companies';\nimport type { UserVertex } from './users';\nimport type { VertexQuery as Query } from './util/vertex-query';\nimport type { TypeEqual } from 'ts-expect';\nimport { expectType } from 'ts-expect';\n\n\ntype VertexRecord = {\n divisions: DivisionVertex;\n divisionSettings: DivisionSettingsVertex;\n settings: DivisionSettingsVertex;\n teachers: TeacherVertex;\n exceptions: ExceptionVertex;\n events: EventVertex;\n scheduleEvents: ScheduleEventVertex;\n calendarEvents: CalendarEventVertex;\n courses: CourseVertex;\n generations: GenerationVertex;\n groups: GroupVertex;\n locations: LocationVertex;\n lockedTimes: LockedTimeVertex;\n overlapGroups: OverlapGroupVertex;\n periods: PeriodVertex;\n persons: PersonVertex;\n students: PersonVertex;\n rootIntervals: RootIntervalVertex;\n syllabuses: SyllabusVertex;\n configurations: ConfigurationVertex;\n companies: CompanyVertex;\n users: UserVertex;\n};\nexport type BaseQueryRecord<C extends keyof VertexRecord> = Query<VertexRecord[C]>;\n{\n // the keys must all be a collection\n type Mismatches = keyof {\n [K in keyof VertexRecord as K extends Collection ? never : K]: true\n };\n expectType<TypeEqual<Mismatches, never>>(true);\n}\n\n/**\n * See {@link createVertexQuery}\n */\nexport class VertexQuery <\n C extends keyof VertexRecord,\n Q extends BaseQueryRecord<C>\n> {\n constructor (\n private readonly _collection: C,\n private readonly _query: Q\n ) {}\n\n get collection () { return this._collection }\n get query () { return this._query }\n}\n\n\n/**\n * Infers the result type for a query created via createVertexQuery.\n *\n * @example\n * const personQuery = createVertexQuery('persons', { select: ['id', 'firstName'] });\n * type PersonType = Infer<typeof personQuery>;\n */\nexport type Infer<T extends VertexQuery<any, any>> =\n T extends VertexQuery<infer C, infer Q>\n ? CustomVertexExport<VertexRecord[C], Q>\n : never;\n\n\n/**\n * Builds a typed vertex query for a given vertex type using a select/expand shape.\n *\n * Use together with Infer<T> to obtain the serialized result type.\n *\n * @typeParam Q - The select/expand query shape for that vertex.\n *\n * @example\n * const groupQuery = createVertexQuery.group({\n * select: ['id', 'displayName'],\n * expand: { members: { select: ['id'] } }\n * });\n * type GroupType = Infer<typeof groupQuery>;\n */\nexport namespace createVertexQuery {\n //\n // The following did not work: it seems we need to define Q as an completely independent type parameter (?)\n //\n // export function createVertexQuery <\n // C extends keyof VertexRecord,\n // const Q extends Query<VertexRecord[C]>\n // > (\n // collection: C,\n // query: Q\n // ) {\n // return new VertexQuery(collection, query);\n // }\n\n export function division <Q extends Query<DivisionVertex >> (query: Q) { return new VertexQuery('divisions', query) }\n export function settings <Q extends Query<DivisionSettingsVertex>> (query: Q) { return new VertexQuery('settings', query) }\n export function exception <Q extends Query<ExceptionVertex >> (query: Q) { return new VertexQuery('exceptions', query) }\n export function event <Q extends Query<EventVertex >> (query: Q) { return new VertexQuery('events', query) }\n export function scheduleEvent<Q extends Query<ScheduleEventVertex >> (query: Q) { return new VertexQuery('scheduleEvents', query) }\n export function calendarEvent<Q extends Query<CalendarEventVertex >> (query: Q) { return new VertexQuery('calendarEvents', query) }\n export function course <Q extends Query<CourseVertex >> (query: Q) { return new VertexQuery('courses', query) }\n export function generation <Q extends Query<GenerationVertex >> (query: Q) { return new VertexQuery('generations', query) }\n export function location <Q extends Query<LocationVertex >> (query: Q) { return new VertexQuery('locations', query) }\n export function lockedTime <Q extends Query<LockedTimeVertex >> (query: Q) { return new VertexQuery('lockedTimes', query) }\n export function overlapGroup <Q extends Query<OverlapGroupVertex >> (query: Q) { return new VertexQuery('overlapGroups', query) }\n export function period <Q extends Query<PeriodVertex >> (query: Q) { return new VertexQuery('periods', query) }\n export function person <Q extends Query<PersonVertex >> (query: Q) { return new VertexQuery('persons', query) }\n export function rootInterval <Q extends Query<RootIntervalVertex >> (query: Q) { return new VertexQuery('rootIntervals', query) }\n export function syllabus <Q extends Query<SyllabusVertex >> (query: Q) { return new VertexQuery('syllabuses', query) }\n export function group <Q extends Query<GroupVertex >> (query: Q) { return new VertexQuery('groups', query) }\n export function teacher <Q extends Query<TeacherVertex >> (query: Q) { return new VertexQuery('teachers', query) }\n}"],"mappings":";;;AAsDE,WAAyC,KAAK;;;;AAMhD,IAAa,cAAb,MAGE;CACA,YACE,AAAiBA,aACjB,AAAiBC,QACjB;EAFiB;EACA;;CAGnB,IAAI,aAAc;AAAE,SAAO,KAAK;;CAChC,IAAI,QAAc;AAAE,SAAO,KAAK;;;;;CA6CzB,SAAS,SAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,aAAoB,MAAM;;;CAC9H,SAAS,SAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,YAAoB,MAAM;;;CAC9H,SAAS,UAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,cAAoB,MAAM;;;CAC9H,SAAS,MAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,UAAoB,MAAM;;;CAC9H,SAAS,cAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,kBAAoB,MAAM;;;CAC9H,SAAS,cAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,kBAAoB,MAAM;;;CAC9H,SAAS,OAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,WAAoB,MAAM;;;CAC9H,SAAS,WAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,eAAoB,MAAM;;;CAC9H,SAAS,SAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,aAAoB,MAAM;;;CAC9H,SAAS,WAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,eAAoB,MAAM;;;CAC9H,SAAS,aAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,iBAAoB,MAAM;;;CAC9H,SAAS,OAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,WAAoB,MAAM;;;CAC9H,SAAS,OAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,WAAoB,MAAM;;;CAC9H,SAAS,aAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,iBAAoB,MAAM;;;CAC9H,SAAS,SAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,cAAoB,MAAM;;;CAC9H,SAAS,MAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,UAAoB,MAAM;;;CAC9H,SAAS,QAAwD,OAAU;AAAE,SAAO,IAAI,YAAY,YAAoB,MAAM"}
@@ -1,12 +1,11 @@
1
- import { internalKeysOmitted } from "./util.js";
1
+ import { omitEdgesAndInternalProperties } from "./util.js";
2
2
 
3
3
  //#region src/core/to/configurations.ts
4
4
  var configurations_default = (configurations, _options) => {
5
5
  return configurations.map((x) => {
6
6
  const edges = {};
7
- const nonEdges = internalKeysOmitted(x, edges);
8
7
  return {
9
- ...nonEdges,
8
+ ...omitEdgesAndInternalProperties(x, edges),
10
9
  ...edges
11
10
  };
12
11
  });
@@ -1 +1 @@
1
- {"version":3,"file":"configurations.js","names":["edges: SerializedEdges<Types.period>"],"sources":["../../../src/core/to/configurations.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n configurations: Types.mixed.configuration[],\n _options: BaseOptions\n): OutTypes.configuration[] => {\n return configurations\n .map(x => {\n const edges: SerializedEdges<Types.period> = {\n } satisfies SerializedEdgesShape<Types.period>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,8BACE,gBACA,aAC6B;AAC7B,QAAO,eACJ,KAAI,MAAK;EACR,MAAMA,QAAuC;EAE7C,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"configurations.js","names":["edges: SerializedEdgesOnlyVertexExport<ConfigurationVertex>"],"sources":["../../../src/core/to/configurations.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport type { BaseOptions } from '../../common/types';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { ConfigurationVertex } from '../interfaces/vertices/configurations';\n\nexport default (\n configurations: Types.Mixed.Configuration[],\n _options: BaseOptions\n): OutTypes.configuration[] => {\n return configurations\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<ConfigurationVertex> = {\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<ConfigurationVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,8BACE,gBACA,aAC6B;AAC7B,QAAO,eACJ,KAAI,MAAK;EACR,MAAMA,QAA8D,EACnE;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/courses.ts
5
5
  var courses_default = (courses, options) => {
@@ -29,9 +29,8 @@ var courses_default = (courses, options) => {
29
29
  locations: [getVertexId(x$1.locations[0], options)]
30
30
  }))
31
31
  };
32
- const nonEdges = internalKeysOmitted(x, edges);
33
32
  return {
34
- ...nonEdges,
33
+ ...omitEdgesAndInternalProperties(x, edges),
35
34
  ...edges
36
35
  };
37
36
  });
@@ -1 +1 @@
1
- {"version":3,"file":"courses.js","names":["edges: SerializedEdges<Types.course>","x"],"sources":["../../../src/core/to/courses.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\n\nexport default (\n courses: Types.mixed.course[],\n options: BaseOptions\n): OutTypes.course[] => {\n return courses\n .map(x => {\n const edges: SerializedEdges<Types.course> = {\n period: x.period ? getVertexId(x.period, options) : undefined,\n overlapGroup: x.overlapGroup ? getVertexId(x.overlapGroup, options) : undefined,\n // overlapSpecies: x.overlapSpecies ? getVertexId(x.overlapSpecies, options) : undefined,\n syllabus: x.syllabus ? getVertexId(x.syllabus, options) : undefined,\n events: x.events ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n teachers: x.teachers ?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n participants: x.participants?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n groups: x.groups ?.map(x => ({ ...x, to: getVertexId(x.to, options), exclude: x.exclude?.map(y => getVertexId(y, options)) })),\n locations: x.locations ?.map(x => ({ ...x, locations: [getVertexId(x.locations[0], options)] as [string] })),\n } satisfies SerializedEdgesShape<Types.course>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAQA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuC;GAC3C,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,WAAW;GAC5E,cAAgB,EAAE,eAAiB,YAAY,EAAE,cAAgB,WAAW;GAE5E,UAAgB,EAAE,WAAiB,YAAY,EAAE,UAAgB,WAAW;GAC5E,QAAgB,EAAE,QAAc,KAAI,QAAK,YAAYC,KAAG;GACxD,aAAgB,EAAE,aAAc,KAAI,QAAK,YAAYA,KAAG;GACxD,YAAgB,EAAE,YAAc,KAAI,QAAK,YAAYA,KAAG;GACxD,UAAgB,EAAE,UAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;;GACxE,cAAgB,EAAE,cAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;;GACxE,QAAgB,EAAE,QAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;IAAU,SAASA,IAAE,SAAS,KAAI,MAAK,YAAY,GAAG;;GAC9H,WAAgB,EAAE,WAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,WAAW,CAAC,YAAYA,IAAE,UAAU,IAAI;;;EAE5F,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"courses.js","names":["edges: SerializedEdgesOnlyVertexExport<CourseVertex>","x"],"sources":["../../../src/core/to/courses.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { CourseVertex } from '../interfaces/vertices/courses';\n\n\nexport default (\n courses: Types.Mixed.Course[],\n options: BaseOptions\n): OutTypes.course[] => {\n return courses\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<CourseVertex> = {\n period: x.period ? getVertexId(x.period, options) : undefined,\n overlapGroup: x.overlapGroup ? getVertexId(x.overlapGroup, options) : undefined,\n // overlapSpecies: x.overlapSpecies ? getVertexId(x.overlapSpecies, options) : undefined,\n syllabus: x.syllabus ? getVertexId(x.syllabus, options) : undefined,\n events: x.events ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n teachers: x.teachers ?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n participants: x.participants?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n groups: x.groups ?.map(x => ({ ...x, to: getVertexId(x.to, options), exclude: x.exclude?.map(y => getVertexId(y, options)) })),\n locations: x.locations ?.map(x => ({ ...x, locations: [getVertexId(x.locations[0], options)] as [string] })),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<CourseVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAQA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuD;GAC3D,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,QAAQ,GAAG;GAC5E,cAAgB,EAAE,eAAiB,YAAY,EAAE,cAAgB,QAAQ,GAAG;GAE5E,UAAgB,EAAE,WAAiB,YAAY,EAAE,UAAgB,QAAQ,GAAG;GAC5E,QAAgB,EAAE,QAAc,KAAI,QAAK,YAAYC,KAAG,QAAQ,CAAC;GACjE,aAAgB,EAAE,aAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GACjE,YAAgB,EAAE,YAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GACjE,UAAgB,EAAE,UAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACpF,cAAgB,EAAE,cAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACpF,QAAgB,EAAE,QAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,SAASA,IAAE,SAAS,KAAI,MAAK,YAAY,GAAG,QAAQ,CAAC;IAAE,EAAE;GAC3I,WAAgB,EAAE,WAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,WAAW,CAAC,YAAYA,IAAE,UAAU,IAAI,QAAQ,CAAC;IAAc,EAAE;GACpH;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1 +1 @@
1
- {"version":3,"file":"division.js","names":[],"sources":["../../../src/core/to/division.ts"],"sourcesContent":["import { pick } from 'lodash-es';\nimport type { Types } from '../types';\nimport type { BaseOptions } from '../../common/types';\nimport type { OutTypes } from './schedules';\n\nexport default (\n division: Types.mixed.division,\n options: BaseOptions\n): Pick<OutTypes.division, 'displayName' | 'start' | 'end'> => {\n return pick(division, 'displayName', 'start', 'end');\n};\n"],"mappings":";;;AAKA,wBACE,UACA,YAC6D;AAC7D,QAAO,KAAK,UAAU,eAAe,SAAS"}
1
+ {"version":3,"file":"division.js","names":[],"sources":["../../../src/core/to/division.ts"],"sourcesContent":["import { pick } from 'lodash-es';\nimport type { Types } from '../types';\nimport type { BaseOptions } from '../../common/types';\nimport type { OutTypes } from './schedules';\n\nexport default (\n division: Types.Mixed.Division,\n options: BaseOptions\n): Pick<OutTypes.division, 'displayName' | 'start' | 'end'> => {\n return pick(division, 'displayName', 'start', 'end');\n};\n"],"mappings":";;;AAKA,wBACE,UACA,YAC6D;AAC7D,QAAO,KAAK,UAAU,eAAe,SAAS,MAAM"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/events.ts
5
5
  var events_default = (events, options) => {
@@ -29,9 +29,8 @@ var events_default = (events, options) => {
29
29
  })),
30
30
  inLocations: x.inLocations?.map((x$1) => x$1 ? getVertexId(x$1, options) : null)
31
31
  };
32
- const nonEdges = internalKeysOmitted(x, edges);
33
32
  return {
34
- ...nonEdges,
33
+ ...omitEdgesAndInternalProperties(x, edges),
35
34
  ...edges
36
35
  };
37
36
  });
@@ -1 +1 @@
1
- {"version":3,"file":"events.js","names":["edges: SerializedEdges<Types.event>","x"],"sources":["../../../src/core/to/events.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport { internalKeysOmitted } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n events: Types.mixed.event[],\n options: BaseOptions\n): OutTypes.event[] => {\n return events\n .map(x => {\n const edges: SerializedEdges<Types.event> = {\n period: x.period ? getVertexId(x.period, options) : undefined,\n // overlapGroup: x.overlapGroup ? getVertexId(x.overlapGroup, options) : undefined,\n overlapSpecies: x.overlapSpecies ? getVertexId(x.overlapSpecies, options) : undefined,\n course: x.course ? getVertexId(x.course, options) : undefined,\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n teachers: x.teachers ?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n participants: x.participants?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n groups: x.groups ?.map(x => ({ ...x, to: getVertexId(x.to, options), exclude: x.exclude?.map(y => getVertexId(y, options)) })),\n locations: x.locations ?.map(x => ({ ...x, locations: [getVertexId(x.locations[0], options)] as [string] })),\n inLocations: x.inLocations ?.map(x => x ? getVertexId(x, options) : null)\n } satisfies SerializedEdgesShape<Types.event>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n\n"],"mappings":";;;;AAOA,sBACE,QACA,YACqB;AACrB,QAAO,OACJ,KAAI,MAAK;EACR,MAAMA,QAAsC;GAC1C,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,WAAW;GAE5E,gBAAgB,EAAE,iBAAiB,YAAY,EAAE,gBAAgB,WAAW;GAC5E,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,WAAW;GAC5E,aAAgB,EAAE,aAAc,KAAI,QAAK,YAAYC,KAAG;GACxD,YAAgB,EAAE,YAAc,KAAI,QAAK,YAAYA,KAAG;GACxD,UAAgB,EAAE,UAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;;GACxE,cAAgB,EAAE,cAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;;GACxE,QAAgB,EAAE,QAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI;IAAU,SAASA,IAAE,SAAS,KAAI,MAAK,YAAY,GAAG;;GAC9H,WAAgB,EAAE,WAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,WAAW,CAAC,YAAYA,IAAE,UAAU,IAAI;;GAC1F,aAAgB,EAAE,aAAc,KAAI,QAAKA,MAAI,YAAYA,KAAG,WAAW;;EAEzE,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"events.js","names":["edges: SerializedEdgesOnlyVertexExport<EventVertex>","x"],"sources":["../../../src/core/to/events.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { EventVertex } from '../interfaces/vertices/events';\n\n\n\n\nexport default (\n events: Types.Mixed.Event[],\n options: BaseOptions\n): OutTypes.event[] => {\n return events\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<EventVertex> = {\n period: x.period ? getVertexId(x.period, options) : undefined,\n // overlapGroup: x.overlapGroup ? getVertexId(x.overlapGroup, options) : undefined,\n overlapSpecies: x.overlapSpecies ? getVertexId(x.overlapSpecies, options) : undefined,\n course: x.course ? getVertexId(x.course, options) : undefined,\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n teachers: x.teachers ?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n participants: x.participants?.map(x => ({ ...x, to: getVertexId(x.to, options) })),\n groups: x.groups ?.map(x => ({ ...x, to: getVertexId(x.to, options), exclude: x.exclude?.map(y => getVertexId(y, options)) })),\n locations: x.locations ?.map(x => ({ ...x, locations: [getVertexId(x.locations[0], options)] as [string] })),\n inLocations: x.inLocations ?.map(x => x ? getVertexId(x, options) : null)\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<EventVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n\n"],"mappings":";;;;AAUA,sBACE,QACA,YACqB;AACrB,QAAO,OACJ,KAAI,MAAK;EACR,MAAMA,QAAsD;GAC1D,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,QAAQ,GAAG;GAE5E,gBAAgB,EAAE,iBAAiB,YAAY,EAAE,gBAAgB,QAAQ,GAAG;GAC5E,QAAgB,EAAE,SAAiB,YAAY,EAAE,QAAgB,QAAQ,GAAG;GAC5E,aAAgB,EAAE,aAAc,KAAI,QAAK,YAAYC,KAAG,QAAQ,CAAC;GACjE,YAAgB,EAAE,YAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GACjE,UAAgB,EAAE,UAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACpF,cAAgB,EAAE,cAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACpF,QAAgB,EAAE,QAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,SAASA,IAAE,SAAS,KAAI,MAAK,YAAY,GAAG,QAAQ,CAAC;IAAE,EAAE;GAC3I,WAAgB,EAAE,WAAc,KAAI,SAAM;IAAE,GAAGA;IAAG,WAAW,CAAC,YAAYA,IAAE,UAAU,IAAI,QAAQ,CAAC;IAAc,EAAE;GACnH,aAAgB,EAAE,aAAc,KAAI,QAAKA,MAAI,YAAYA,KAAG,QAAQ,GAAG,KAAK;GAC7E;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,12 +1,13 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
+ import { omit } from "lodash-es";
3
4
 
4
5
  //#region src/core/to/exceptions.ts
5
6
  var exceptions_default = (exceptions, options) => {
6
7
  return exceptions.map((x) => {
7
8
  const edges = {
8
9
  exception: x.exception ? {
9
- ...x.exception,
10
+ ...omit(x.exception, "to"),
10
11
  ...x.exception.to && { to: getVertexId(x.exception.to, options) }
11
12
  } : void 0,
12
13
  sources: x.sources?.map((x$1) => ({
@@ -16,9 +17,8 @@ var exceptions_default = (exceptions, options) => {
16
17
  exceptions: x.exceptions?.map((x$1) => getVertexId(x$1, options)),
17
18
  parentExceptions: x.parentExceptions?.map((x$1) => getVertexId(x$1, options))
18
19
  };
19
- const nonEdges = internalKeysOmitted(x, edges);
20
20
  return {
21
- ...nonEdges,
21
+ ...omitEdgesAndInternalProperties(x, edges),
22
22
  ...edges
23
23
  };
24
24
  });
@@ -1 +1 @@
1
- {"version":3,"file":"exceptions.js","names":["edges: SerializedEdges<Types.exception>","x"],"sources":["../../../src/core/to/exceptions.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { Collection } from '../types/common';\n\nexport default (\n exceptions: Types.mixed.exception[],\n options: BaseOptions\n): OutTypes.exception[] => {\n return exceptions\n .map(x => {\n const edges: SerializedEdges<Types.exception> = {\n exception: x.exception\n ? {\n ...x.exception, // typing is not correct, need to be fixed!\n ...x.exception.to && {\n to: getVertexId(x.exception.to, options),\n }\n // SerializedEdges assumes every edge is required, but here it's optional\n } as unknown as { toModel: Collection; to: string }\n : undefined,\n sources: x.sources ?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n parentExceptions: x.parentExceptions?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<Types.exception>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAQA,0BACE,YACA,YACyB;AACzB,QAAO,WACJ,KAAI,MAAK;EACR,MAAMA,QAA0C;GAC9C,WAAW,EAAE,YACT;IACA,GAAG,EAAE;IACL,GAAG,EAAE,UAAU,MAAM,EACnB,IAAI,YAAY,EAAE,UAAU,IAAI;OAIlC;GACJ,SAAkB,EAAE,SAAkB,KAAI,SAAM;IAAE,SAASC,IAAE;IAAS,IAAI,YAAYA,IAAE,IAAI;;GAC5F,YAAkB,EAAE,YAAkB,KAAI,QAAK,YAAYA,KAAG;GAC9D,kBAAkB,EAAE,kBAAkB,KAAI,QAAK,YAAYA,KAAG;;EAEhE,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"exceptions.js","names":["edges: SerializedEdgesOnlyVertexExport<ExceptionVertex>","x"],"sources":["../../../src/core/to/exceptions.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { ExceptionVertex } from '../interfaces/vertices/exceptions';\nimport { omit } from 'lodash-es';\n\n\nexport default (\n exceptions: Types.Mixed.Exception[],\n options: BaseOptions\n): OutTypes.exception[] => {\n return exceptions\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<ExceptionVertex> = {\n exception: x.exception\n ? {\n ...omit(x.exception, 'to'),\n ...x.exception.to && { to: getVertexId(x.exception.to, options) }\n }\n : undefined,\n sources: x.sources ?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n parentExceptions: x.parentExceptions?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<ExceptionVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;;AASA,0BACE,YACA,YACyB;AACzB,QAAO,WACJ,KAAI,MAAK;EACR,MAAMA,QAA0D;GAC9D,WAAW,EAAE,YACT;IACA,GAAG,KAAK,EAAE,WAAW,KAAK;IAC1B,GAAG,EAAE,UAAU,MAAM,EAAE,IAAI,YAAY,EAAE,UAAU,IAAI,QAAQ,EAAE;IAClE,GACC;GACJ,SAAkB,EAAE,SAAkB,KAAI,SAAM;IAAE,SAASC,IAAE;IAAS,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACxG,YAAkB,EAAE,YAAkB,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GACvE,kBAAkB,EAAE,kBAAkB,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GACxE;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/groups.ts
5
5
  var groups_default = (groups, options) => {
@@ -13,9 +13,8 @@ var groups_default = (groups, options) => {
13
13
  parentGroups: x.parentGroups?.map((x$1) => getVertexId(x$1, options)),
14
14
  subGroups: x.subGroups?.map((x$1) => getVertexId(x$1, options))
15
15
  };
16
- const nonEdges = internalKeysOmitted(x, edges);
17
16
  return {
18
- ...nonEdges,
17
+ ...omitEdgesAndInternalProperties(x, edges),
19
18
  ...edges
20
19
  };
21
20
  });
@@ -1 +1 @@
1
- {"version":3,"file":"groups.js","names":["edges: SerializedEdges<Types.group>","x"],"sources":["../../../src/core/to/groups.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n groups: Types.mixed.group[],\n options: BaseOptions\n): OutTypes.group[] => {\n return groups\n .map(x => {\n const edges: SerializedEdges<Types.group> = {\n rootInterval: x.rootInterval ? getVertexId(x.rootInterval, options) : undefined,\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n lunch: x.lunch ?.map(x => getVertexId(x, options)),\n members: x.members ?.map(x => getVertexId(x, options)),\n parentGroups: x.parentGroups?.map(x => getVertexId(x, options)),\n subGroups: x.subGroups ?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<Types.group>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,sBACE,QACA,YACqB;AACrB,QAAO,OACJ,KAAI,MAAK;EACR,MAAMA,QAAsC;GAC1C,cAAc,EAAE,eAAe,YAAY,EAAE,cAAc,WAAW;GACtE,YAAc,EAAE,YAAc,KAAI,QAAK,YAAYC,KAAG;GACtD,aAAc,EAAE,aAAc,KAAI,QAAK,YAAYA,KAAG;GACtD,OAAc,EAAE,OAAc,KAAI,QAAK,YAAYA,KAAG;GACtD,SAAc,EAAE,SAAc,KAAI,QAAK,YAAYA,KAAG;GACtD,cAAc,EAAE,cAAc,KAAI,QAAK,YAAYA,KAAG;GACtD,WAAc,EAAE,WAAc,KAAI,QAAK,YAAYA,KAAG;;EAExD,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"groups.js","names":["edges: SerializedEdgesOnlyVertexExport<GroupVertex>","x"],"sources":["../../../src/core/to/groups.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { GroupVertex } from '../interfaces/vertices/groups';\n\nexport default (\n groups: Types.Mixed.Group[],\n options: BaseOptions\n): OutTypes.group[] => {\n return groups\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<GroupVertex> = {\n rootInterval: x.rootInterval ? getVertexId(x.rootInterval, options) : undefined,\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n lunch: x.lunch ?.map(x => getVertexId(x, options)),\n members: x.members ?.map(x => getVertexId(x, options)),\n parentGroups: x.parentGroups?.map(x => getVertexId(x, options)),\n subGroups: x.subGroups ?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<GroupVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,sBACE,QACA,YACqB;AACrB,QAAO,OACJ,KAAI,MAAK;EACR,MAAMA,QAAsD;GAC1D,cAAc,EAAE,eAAe,YAAY,EAAE,cAAc,QAAQ,GAAG;GACtE,YAAc,EAAE,YAAc,KAAI,QAAK,YAAYC,KAAG,QAAQ,CAAC;GAC/D,aAAc,EAAE,aAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC/D,OAAc,EAAE,OAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC/D,SAAc,EAAE,SAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC/D,cAAc,EAAE,cAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC/D,WAAc,EAAE,WAAc,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAChE;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/locations.ts
5
5
  var locations_default = (locations, options) => {
@@ -9,9 +9,8 @@ var locations_default = (locations, options) => {
9
9
  lockedTimes: x.lockedTimes?.map((x$1) => getVertexId(x$1, options)),
10
10
  lunch: x.lunch?.map((x$1) => getVertexId(x$1, options))
11
11
  };
12
- const nonEdges = internalKeysOmitted(x, edges);
13
12
  return {
14
- ...nonEdges,
13
+ ...omitEdgesAndInternalProperties(x, edges),
15
14
  ...edges
16
15
  };
17
16
  });
@@ -1 +1 @@
1
- {"version":3,"file":"locations.js","names":["edges: SerializedEdges<Types.location>","x"],"sources":["../../../src/core/to/locations.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n locations: Types.mixed.location[],\n options: BaseOptions\n): OutTypes.location[] => {\n return locations\n .map(x => {\n const edges: SerializedEdges<Types.location> = {\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes?.map(x => getVertexId(x, options)),\n lunch: x.lunch ?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<Types.location>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,yBACE,WACA,YACwB;AACxB,QAAO,UACJ,KAAI,MAAK;EACR,MAAMA,QAAyC;GAC7C,YAAa,EAAE,YAAa,KAAI,QAAK,YAAYC,KAAG;GACpD,aAAa,EAAE,aAAa,KAAI,QAAK,YAAYA,KAAG;GACpD,OAAa,EAAE,OAAa,KAAI,QAAK,YAAYA,KAAG;;EAEtD,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"locations.js","names":["edges: SerializedEdgesOnlyVertexExport<LocationVertex>","x"],"sources":["../../../src/core/to/locations.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { LocationVertex } from '../interfaces/vertices/locations';\n\nexport default (\n locations: Types.Mixed.Location[],\n options: BaseOptions\n): OutTypes.location[] => {\n return locations\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<LocationVertex> = {\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes?.map(x => getVertexId(x, options)),\n lunch: x.lunch ?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<LocationVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,yBACE,WACA,YACwB;AACxB,QAAO,UACJ,KAAI,MAAK;EACR,MAAMA,QAAyD;GAC7D,YAAa,EAAE,YAAa,KAAI,QAAK,YAAYC,KAAG,QAAQ,CAAC;GAC7D,aAAa,EAAE,aAAa,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC7D,OAAa,EAAE,OAAa,KAAI,QAAK,YAAYA,KAAG,QAAQ,CAAC;GAC9D;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/locked-times.ts
5
5
  var locked_times_default = (lockedTimes, options) => {
@@ -8,9 +8,8 @@ var locked_times_default = (lockedTimes, options) => {
8
8
  toModel: x$1.toModel,
9
9
  to: getVertexId(x$1.to, options)
10
10
  })) };
11
- const nonEdges = internalKeysOmitted(x, edges);
12
11
  return {
13
- ...nonEdges,
12
+ ...omitEdgesAndInternalProperties(x, edges),
14
13
  ...edges
15
14
  };
16
15
  });
@@ -1 +1 @@
1
- {"version":3,"file":"locked-times.js","names":["edges: SerializedEdges<Types.lockedTime>","x"],"sources":["../../../src/core/to/locked-times.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n lockedTimes: Types.mixed.lockedTime[],\n options: BaseOptions\n): OutTypes.lockedTime[] => {\n return lockedTimes\n .map(x => {\n const edges: SerializedEdges<Types.lockedTime> = {\n coalesced: x.coalesced?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n } satisfies SerializedEdgesShape<Types.lockedTime>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,4BACE,aACA,YAC0B;AAC1B,QAAO,YACJ,KAAI,MAAK;EACR,MAAMA,QAA2C,EAC/C,WAAW,EAAE,WAAW,KAAI,SAAM;GAAE,SAASC,IAAE;GAAS,IAAI,YAAYA,IAAE,IAAI;;EAEhF,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"locked-times.js","names":["edges: SerializedEdgesOnlyVertexExport<LockedTimeVertex>","x"],"sources":["../../../src/core/to/locked-times.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { LockedTimeVertex } from '../interfaces/vertices/locked-times';\n\nexport default (\n lockedTimes: Types.Mixed.LockedTime[],\n options: BaseOptions\n): OutTypes.lockedTime[] => {\n return lockedTimes\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<LockedTimeVertex> = {\n coalesced: x.coalesced?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<LockedTimeVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,4BACE,aACA,YAC0B;AAC1B,QAAO,YACJ,KAAI,MAAK;EACR,MAAMA,QAA2D,EAC/D,WAAW,EAAE,WAAW,KAAI,SAAM;GAAE,SAASC,IAAE;GAAS,IAAI,YAAYA,IAAE,IAAI,QAAQ;GAAE,EAAE,EAC3F;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/overlap-groups.ts
5
5
  var overlap_groups_default = (overlapGroups, options) => {
@@ -15,9 +15,8 @@ var overlap_groups_default = (overlapGroups, options) => {
15
15
  to: getVertexId(x$1.to, options)
16
16
  }))
17
17
  };
18
- const nonEdges = internalKeysOmitted(x, edges);
19
18
  return {
20
- ...nonEdges,
19
+ ...omitEdgesAndInternalProperties(x, edges),
21
20
  ...edges
22
21
  };
23
22
  });
@@ -1 +1 @@
1
- {"version":3,"file":"overlap-groups.js","names":["edges: SerializedEdges<Types.overlapGroup>","x"],"sources":["../../../src/core/to/overlap-groups.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n overlapGroups: Types.mixed.overlapGroup[],\n options: BaseOptions\n): OutTypes.overlapGroup[] => {\n return overlapGroups\n .map(x => {\n const edges: SerializedEdges<Types.overlapGroup> = {\n coalesced: x.coalesced?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n species: x.species ?.map(x => ({ toModel: x.toModel, id: x.id, to: getVertexId(x.to, options) })),\n } satisfies SerializedEdgesShape<Types.overlapGroup>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,8BACE,eACA,YAC4B;AAC5B,QAAO,cACJ,KAAI,MAAK;EACR,MAAMA,QAA6C;GACjD,WAAW,EAAE,WAAW,KAAI,SAAM;IAAE,SAASC,IAAE;IAAmB,IAAI,YAAYA,IAAE,IAAI;;GACxF,SAAW,EAAE,SAAW,KAAI,SAAM;IAAE,SAASA,IAAE;IAAS,IAAIA,IAAE;IAAI,IAAI,YAAYA,IAAE,IAAI;;;EAE1F,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"overlap-groups.js","names":["edges: SerializedEdgesOnlyVertexExport<OverlapGroupVertex>","x"],"sources":["../../../src/core/to/overlap-groups.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { OverlapGroupVertex } from '../interfaces/vertices/overlap-groups';\n\nexport default (\n overlapGroups: Types.Mixed.OverlapGroup[],\n options: BaseOptions\n): OutTypes.overlapGroup[] => {\n return overlapGroups\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<OverlapGroupVertex> = {\n coalesced: x.coalesced?.map(x => ({ toModel: x.toModel, to: getVertexId(x.to, options) })),\n species: x.species ?.map(x => ({ toModel: x.toModel, id: x.id, to: getVertexId(x.to, options) })),\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<OverlapGroupVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,8BACE,eACA,YAC4B;AAC5B,QAAO,cACJ,KAAI,MAAK;EACR,MAAMA,QAA6D;GACjE,WAAW,EAAE,WAAW,KAAI,SAAM;IAAE,SAASC,IAAE;IAAmB,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACpG,SAAW,EAAE,SAAW,KAAI,SAAM;IAAE,SAASA,IAAE;IAAS,IAAIA,IAAE;IAAI,IAAI,YAAYA,IAAE,IAAI,QAAQ;IAAE,EAAE;GACrG;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,12 +1,11 @@
1
- import { internalKeysOmitted } from "./util.js";
1
+ import { omitEdgesAndInternalProperties } from "./util.js";
2
2
 
3
3
  //#region src/core/to/periods.ts
4
4
  var periods_default = (periods, options) => {
5
5
  return periods.map((x) => {
6
6
  const edges = {};
7
- const nonEdges = internalKeysOmitted(x, edges);
8
7
  return {
9
- ...nonEdges,
8
+ ...omitEdgesAndInternalProperties(x, edges),
10
9
  ...edges
11
10
  };
12
11
  });
@@ -1 +1 @@
1
- {"version":3,"file":"periods.js","names":["edges: SerializedEdges<Types.period>"],"sources":["../../../src/core/to/periods.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n periods: Types.mixed.period[],\n options: BaseOptions\n): OutTypes.period[] => {\n return periods\n .map(x => {\n const edges: SerializedEdges<Types.period> = {\n } satisfies SerializedEdgesShape<Types.period>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuC;EAE7C,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"periods.js","names":["edges: SerializedEdgesOnlyVertexExport<PeriodVertex>"],"sources":["../../../src/core/to/periods.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { PeriodVertex } from '../interfaces/vertices/periods';\n\nexport default (\n periods: Types.Mixed.Period[],\n options: BaseOptions\n): OutTypes.period[] => {\n return periods\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<PeriodVertex> = {\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<PeriodVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuD,EAC5D;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,18 +1,12 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/persons.ts
5
5
  var persons_default = (persons, options) => {
6
6
  return persons.map((x) => {
7
- const edges = {
8
- group: x.group ? getVertexId(x.group, options) : void 0,
9
- exceptions: x.exceptions?.map((x$1) => getVertexId(x$1, options)),
10
- lockedTimes: x.lockedTimes?.map((x$1) => getVertexId(x$1, options)),
11
- lunch: x.lunch?.map((x$1) => getVertexId(x$1, options))
12
- };
13
- const nonEdges = internalKeysOmitted(x, edges);
7
+ const edges = { group: x.group ? getVertexId(x.group, options) : void 0 };
14
8
  return {
15
- ...nonEdges,
9
+ ...omitEdgesAndInternalProperties(x, edges),
16
10
  ...edges
17
11
  };
18
12
  });
@@ -1 +1 @@
1
- {"version":3,"file":"persons.js","names":["edges: SerializedEdges<Types.person>","x"],"sources":["../../../src/core/to/persons.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n persons: Types.mixed.person[],\n options: BaseOptions\n): OutTypes.person[] => {\n return persons\n .map(x => {\n const edges: SerializedEdges<Types.person> = {\n group: x.group ? getVertexId(x.group, options) : undefined,\n exceptions: x.exceptions ?.map(x => getVertexId(x, options)),\n lockedTimes: x.lockedTimes ?.map(x => getVertexId(x, options)),\n lunch: x.lunch ?.map(x => getVertexId(x, options)),\n } satisfies SerializedEdgesShape<Types.person>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuC;GAC3C,OAAa,EAAE,QAAQ,YAAY,EAAE,OAAO,WAAW;GACvD,YAAa,EAAE,YAAc,KAAI,QAAK,YAAYC,KAAG;GACrD,aAAa,EAAE,aAAc,KAAI,QAAK,YAAYA,KAAG;GACrD,OAAa,EAAE,OAAc,KAAI,QAAK,YAAYA,KAAG;;EAEvD,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"persons.js","names":["edges: SerializedEdgesOnlyVertexExport<PersonVertex>"],"sources":["../../../src/core/to/persons.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { getVertexId } from '../util';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { PersonVertex } from '../interfaces/vertices/persons';\n\nexport default (\n persons: Types.Mixed.Person[],\n options: BaseOptions\n): OutTypes.person[] => {\n return persons\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<PersonVertex> = {\n group: x.group ? getVertexId(x.group, options) : undefined,\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<PersonVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;;AAOA,uBACE,SACA,YACsB;AACtB,QAAO,QACJ,KAAI,MAAK;EACR,MAAMA,QAAuD,EAC3D,OAAO,EAAE,QAAQ,YAAY,EAAE,OAAO,QAAQ,GAAG,QAClD;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,12 +1,11 @@
1
- import { internalKeysOmitted } from "./util.js";
1
+ import { omitEdgesAndInternalProperties } from "./util.js";
2
2
 
3
3
  //#region src/core/to/root-intervals.ts
4
4
  var root_intervals_default = (rootIntervals, options) => {
5
5
  return rootIntervals.map((x) => {
6
6
  const edges = {};
7
- const nonEdges = internalKeysOmitted(x, edges);
8
7
  return {
9
- ...nonEdges,
8
+ ...omitEdgesAndInternalProperties(x, edges),
10
9
  ...edges
11
10
  };
12
11
  });
@@ -1 +1 @@
1
- {"version":3,"file":"root-intervals.js","names":["edges: SerializedEdges<Types.rootInterval>"],"sources":["../../../src/core/to/root-intervals.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { internalKeysOmitted } from './util';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport default (\n rootIntervals: Types.mixed.rootInterval[],\n options: BaseOptions\n): OutTypes.rootInterval[] => {\n return rootIntervals\n .map(x => {\n const edges: SerializedEdges<Types.rootInterval> = {\n } satisfies SerializedEdgesShape<Types.rootInterval>;\n const nonEdges = internalKeysOmitted(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,8BACE,eACA,YAC4B;AAC5B,QAAO,cACJ,KAAI,MAAK;EACR,MAAMA,QAA6C;EAEnD,MAAM,WAAW,oBAAoB,GAAG;AAExC,SAAO;GAAE,GAAG;GAAU,GAAG"}
1
+ {"version":3,"file":"root-intervals.js","names":["edges: SerializedEdgesOnlyVertexExport<RootIntervalVertex>"],"sources":["../../../src/core/to/root-intervals.ts"],"sourcesContent":["import type { Types } from '../types';\nimport type { OutTypes } from './schedules';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\nimport type { BaseOptions } from '../../common/types';\nimport type { RootIntervalVertex } from '../interfaces/vertices/root-intervals';\n\nexport default (\n rootIntervals: Types.Mixed.RootInterval[],\n options: BaseOptions\n): OutTypes.rootInterval[] => {\n return rootIntervals\n .map(x => {\n const edges: SerializedEdgesOnlyVertexExport<RootIntervalVertex> = {\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<RootIntervalVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(x, edges);\n\n return { ...nonEdges, ...edges };\n });\n};\n"],"mappings":";;;AAMA,8BACE,eACA,YAC4B;AAC5B,QAAO,cACJ,KAAI,MAAK;EACR,MAAMA,QAA6D,EAClE;AAGD,SAAO;GAAE,GAFQ,+BAA+B,GAAG,MAAM;GAEnC,GAAG;GAAO;GAChC"}
@@ -1,24 +1,25 @@
1
1
  import { InternalIdKey } from "../types/common/index.js";
2
2
  import { InternalKeysOmitted } from "./util.js";
3
3
  import { Types } from "../types/index.js";
4
+ import "../index.js";
4
5
 
5
6
  //#region src/core/to/schedules.d.ts
6
7
  declare namespace OutTypes {
7
- type division = Omit<InternalKeysOmitted<Types.serialized.division>, InternalIdKey>;
8
- type settings = InternalKeysOmitted<Types.serialized.divisionSettings>;
9
- type configuration = InternalKeysOmitted<Types.serialized.configuration>;
10
- type exception = InternalKeysOmitted<Types.serialized.exception>;
11
- type period = InternalKeysOmitted<Types.serialized.period>;
12
- type location = InternalKeysOmitted<Types.serialized.location>;
13
- type teacher = InternalKeysOmitted<Types.serialized.teacher>;
14
- type group = InternalKeysOmitted<Types.serialized.group>;
15
- type person = InternalKeysOmitted<Types.serialized.person>;
16
- type course = InternalKeysOmitted<Types.serialized.course>;
17
- type event = InternalKeysOmitted<Types.serialized.event>;
18
- type lockedTime = InternalKeysOmitted<Types.serialized.lockedTime>;
19
- type overlapGroup = InternalKeysOmitted<Types.serialized.overlapGroup>;
20
- type rootInterval = InternalKeysOmitted<Types.serialized.rootInterval>;
21
- type syllabus = InternalKeysOmitted<Types.serialized.syllabus>;
8
+ type division = Omit<InternalKeysOmitted<Types.Serialized.Division>, InternalIdKey>;
9
+ type settings = InternalKeysOmitted<Types.Serialized.Settings>;
10
+ type configuration = InternalKeysOmitted<Types.Serialized.Configuration>;
11
+ type exception = InternalKeysOmitted<Types.Serialized.Exception>;
12
+ type period = InternalKeysOmitted<Types.Serialized.Period>;
13
+ type location = InternalKeysOmitted<Types.Serialized.Location>;
14
+ type teacher = InternalKeysOmitted<Types.Serialized.Teacher>;
15
+ type group = InternalKeysOmitted<Types.Serialized.Group>;
16
+ type person = InternalKeysOmitted<Types.Serialized.Person>;
17
+ type course = InternalKeysOmitted<Types.Serialized.Course>;
18
+ type event = InternalKeysOmitted<Types.Serialized.Event>;
19
+ type lockedTime = InternalKeysOmitted<Types.Serialized.LockedTime>;
20
+ type overlapGroup = InternalKeysOmitted<Types.Serialized.OverlapGroup>;
21
+ type rootInterval = InternalKeysOmitted<Types.Serialized.RootInterval>;
22
+ type syllabus = InternalKeysOmitted<Types.Serialized.Syllabus>;
22
23
  }
23
24
  type Out = {
24
25
  division?: OutTypes.division;
@@ -40,9 +41,7 @@ type Out = {
40
41
  structure: string;
41
42
  };
42
43
  };
43
- declare function export_default(schedule: Partial<Types.mixed.schedule> & {
44
- configurations?: Types.mixed.configuration[];
45
- }): Out;
44
+ declare function export_default(schedule: Partial<Types.Mixed.Schedule>): Out;
46
45
  //#endregion
47
46
  export { export_default };
48
47
  //# sourceMappingURL=schedules.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"schedules.js","names":["options: BaseOptions","_division","_settings","_exceptions","_periods","_locations","_teachers","_groups","_persons","_courses","_events","_lockedTimes","_overlapGroups","_rootIntervals","_syllabuses","_configurations"],"sources":["../../../src/core/to/schedules.ts"],"sourcesContent":["import type { CoreTypes } from '../';\nimport _exceptions from './exceptions';\nimport _periods from './periods';\nimport _locations from './locations';\nimport _teachers from './teachers';\nimport _groups from './groups';\nimport _persons from './persons';\nimport _courses from './courses';\nimport _events from './events';\nimport _lockedTimes from './locked-times';\nimport _overlapGroups from './overlap-groups';\nimport _rootIntervals from './root-intervals';\nimport _settings from './settings';\nimport _division from './division';\nimport _syllabuses from './syllabuses';\nimport _configurations from './configurations';\nimport type { InternalIdKey } from '../types/common';\nimport type { InternalKeysOmitted } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport namespace OutTypes {\n export type division = Omit<InternalKeysOmitted<CoreTypes.serialized.division>, InternalIdKey>;\n export type settings = InternalKeysOmitted<CoreTypes.serialized.divisionSettings>;\n export type configuration = InternalKeysOmitted<CoreTypes.serialized.configuration >;\n export type exception = InternalKeysOmitted<CoreTypes.serialized.exception >;\n export type period = InternalKeysOmitted<CoreTypes.serialized.period >;\n export type location = InternalKeysOmitted<CoreTypes.serialized.location >;\n export type teacher = InternalKeysOmitted<CoreTypes.serialized.teacher >;\n export type group = InternalKeysOmitted<CoreTypes.serialized.group >;\n export type person = InternalKeysOmitted<CoreTypes.serialized.person >;\n export type course = InternalKeysOmitted<CoreTypes.serialized.course >;\n export type event = InternalKeysOmitted<CoreTypes.serialized.event >;\n export type lockedTime = InternalKeysOmitted<CoreTypes.serialized.lockedTime >;\n export type overlapGroup = InternalKeysOmitted<CoreTypes.serialized.overlapGroup >;\n export type rootInterval = InternalKeysOmitted<CoreTypes.serialized.rootInterval >;\n export type syllabus = InternalKeysOmitted<CoreTypes.serialized.syllabus >;\n}\n\ntype Out = {\n division?: OutTypes.division;\n settings?: OutTypes.settings;\n exceptions?: OutTypes.exception[];\n periods?: OutTypes.period[];\n locations?: OutTypes.location[];\n teachers?: OutTypes.teacher[];\n groups?: OutTypes.group[];\n persons?: OutTypes.person[];\n courses?: OutTypes.course[];\n events?: OutTypes.event[];\n lockedTimes?: OutTypes.lockedTime[];\n overlapGroups?: OutTypes.overlapGroup[];\n rootIntervals?: OutTypes.rootInterval[];\n syllabuses?: OutTypes.syllabus[];\n configurations?: OutTypes.configuration[];\n\n meta: { structure: string };\n};\n\nexport default function (\n schedule: Partial<CoreTypes.mixed.schedule> & { configurations?: CoreTypes.mixed.configuration[] },\n): Out {\n const options: BaseOptions = {};\n\n return {\n meta: { structure: 'RS/core-2.0.0' },\n ...schedule.divisions && { division: _division (schedule.divisions, options) },\n ...schedule.settings && { settings: _settings (schedule.settings, options) },\n ...schedule.exceptions && { exceptions: _exceptions (schedule.exceptions, options) },\n ...schedule.periods && { periods: _periods (schedule.periods, options) },\n ...schedule.locations && { locations: _locations (schedule.locations, options) },\n ...schedule.teachers && { teachers: _teachers (schedule.teachers, options) },\n ...schedule.groups && { groups: _groups (schedule.groups, options) },\n ...schedule.persons && { persons: _persons (schedule.persons, options) },\n ...schedule.courses && { courses: _courses (schedule.courses, options) },\n ...schedule.events && { events: _events (schedule.events, options) },\n ...schedule.lockedTimes && { lockedTimes: _lockedTimes (schedule.lockedTimes, options) },\n ...schedule.overlapGroups && { overlapGroups: _overlapGroups (schedule.overlapGroups, options) },\n ...schedule.rootIntervals && { rootIntervals: _rootIntervals (schedule.rootIntervals, options) },\n ...schedule.syllabuses && { syllabuses: _syllabuses (schedule.syllabuses, options) },\n ...schedule.configurations && { configurations: _configurations(schedule.configurations, options) },\n };\n}"],"mappings":";;;;;;;;;;;;;;;;;AA0DA,2BACE,UACK;CACL,MAAMA,UAAuB;AAE7B,QAAO;EACL,MAAM,EAAE,WAAW;EACnB,GAAG,SAAS,aAAkB,EAAE,UAAgBC,iBAAgB,SAAS,WAAgB;EACzF,GAAG,SAAS,YAAkB,EAAE,UAAgBC,iBAAgB,SAAS,UAAgB;EACzF,GAAG,SAAS,cAAkB,EAAE,YAAgBC,mBAAgB,SAAS,YAAgB;EACzF,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB;EACzF,GAAG,SAAS,aAAkB,EAAE,WAAgBC,kBAAgB,SAAS,WAAgB;EACzF,GAAG,SAAS,YAAkB,EAAE,UAAgBC,iBAAgB,SAAS,UAAgB;EACzF,GAAG,SAAS,UAAkB,EAAE,QAAgBC,eAAgB,SAAS,QAAgB;EACzF,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB;EACzF,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB;EACzF,GAAG,SAAS,UAAkB,EAAE,QAAgBC,eAAgB,SAAS,QAAgB;EACzF,GAAG,SAAS,eAAkB,EAAE,aAAgBC,qBAAgB,SAAS,aAAgB;EACzF,GAAG,SAAS,iBAAkB,EAAE,eAAgBC,uBAAgB,SAAS,eAAgB;EACzF,GAAG,SAAS,iBAAkB,EAAE,eAAgBC,uBAAgB,SAAS,eAAgB;EACzF,GAAG,SAAS,cAAkB,EAAE,YAAgBC,mBAAgB,SAAS,YAAgB;EACzF,GAAG,SAAS,kBAAkB,EAAE,gBAAgBC,uBAAgB,SAAS,gBAAgB"}
1
+ {"version":3,"file":"schedules.js","names":["options: BaseOptions","_division","_settings","_exceptions","_periods","_locations","_teachers","_groups","_persons","_courses","_events","_lockedTimes","_overlapGroups","_rootIntervals","_syllabuses","_configurations"],"sources":["../../../src/core/to/schedules.ts"],"sourcesContent":["import type { CoreTypes } from '../';\nimport _exceptions from './exceptions';\nimport _periods from './periods';\nimport _locations from './locations';\nimport _teachers from './teachers';\nimport _groups from './groups';\nimport _persons from './persons';\nimport _courses from './courses';\nimport _events from './events';\nimport _lockedTimes from './locked-times';\nimport _overlapGroups from './overlap-groups';\nimport _rootIntervals from './root-intervals';\nimport _settings from './settings';\nimport _division from './division';\nimport _syllabuses from './syllabuses';\nimport _configurations from './configurations';\nimport type { InternalIdKey } from '../types/common';\nimport type { InternalKeysOmitted } from './util';\nimport type { BaseOptions } from '../../common/types';\n\nexport namespace OutTypes {\n export type division = Omit<InternalKeysOmitted<CoreTypes.Serialized.Division>, InternalIdKey>;\n export type settings = InternalKeysOmitted<CoreTypes.Serialized.Settings>;\n export type configuration = InternalKeysOmitted<CoreTypes.Serialized.Configuration>;\n export type exception = InternalKeysOmitted<CoreTypes.Serialized.Exception>;\n export type period = InternalKeysOmitted<CoreTypes.Serialized.Period>;\n export type location = InternalKeysOmitted<CoreTypes.Serialized.Location>;\n export type teacher = InternalKeysOmitted<CoreTypes.Serialized.Teacher>;\n export type group = InternalKeysOmitted<CoreTypes.Serialized.Group>;\n export type person = InternalKeysOmitted<CoreTypes.Serialized.Person>;\n export type course = InternalKeysOmitted<CoreTypes.Serialized.Course>;\n export type event = InternalKeysOmitted<CoreTypes.Serialized.Event>;\n export type lockedTime = InternalKeysOmitted<CoreTypes.Serialized.LockedTime>;\n export type overlapGroup = InternalKeysOmitted<CoreTypes.Serialized.OverlapGroup>;\n export type rootInterval = InternalKeysOmitted<CoreTypes.Serialized.RootInterval>;\n export type syllabus = InternalKeysOmitted<CoreTypes.Serialized.Syllabus>;\n}\n\ntype Out = {\n division?: OutTypes.division;\n settings?: OutTypes.settings;\n exceptions?: OutTypes.exception[];\n periods?: OutTypes.period[];\n locations?: OutTypes.location[];\n teachers?: OutTypes.teacher[];\n groups?: OutTypes.group[];\n persons?: OutTypes.person[];\n courses?: OutTypes.course[];\n events?: OutTypes.event[];\n lockedTimes?: OutTypes.lockedTime[];\n overlapGroups?: OutTypes.overlapGroup[];\n rootIntervals?: OutTypes.rootInterval[];\n syllabuses?: OutTypes.syllabus[];\n configurations?: OutTypes.configuration[];\n\n meta: { structure: string };\n};\n\nexport default function (\n schedule: Partial<CoreTypes.Mixed.Schedule>\n): Out {\n const options: BaseOptions = {};\n\n return {\n meta: { structure: 'RS/core-2.0.0' },\n ...schedule.divisions && { division: _division (schedule.divisions, options) },\n ...schedule.settings && { settings: _settings (schedule.settings, options) },\n ...schedule.exceptions && { exceptions: _exceptions (schedule.exceptions, options) },\n ...schedule.periods && { periods: _periods (schedule.periods, options) },\n ...schedule.locations && { locations: _locations (schedule.locations, options) },\n ...schedule.teachers && { teachers: _teachers (schedule.teachers, options) },\n ...schedule.groups && { groups: _groups (schedule.groups, options) },\n ...schedule.persons && { persons: _persons (schedule.persons, options) },\n ...schedule.courses && { courses: _courses (schedule.courses, options) },\n ...schedule.events && { events: _events (schedule.events, options) },\n ...schedule.lockedTimes && { lockedTimes: _lockedTimes (schedule.lockedTimes, options) },\n ...schedule.overlapGroups && { overlapGroups: _overlapGroups (schedule.overlapGroups, options) },\n ...schedule.rootIntervals && { rootIntervals: _rootIntervals (schedule.rootIntervals, options) },\n ...schedule.syllabuses && { syllabuses: _syllabuses (schedule.syllabuses, options) },\n ...schedule.configurations && { configurations: _configurations(schedule.configurations, options) },\n };\n}"],"mappings":";;;;;;;;;;;;;;;;;AA0DA,2BACE,UACK;CACL,MAAMA,UAAuB,EAAE;AAE/B,QAAO;EACL,MAAM,EAAE,WAAW,iBAAiB;EACpC,GAAG,SAAS,aAAkB,EAAE,UAAgBC,iBAAgB,SAAS,WAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,YAAkB,EAAE,UAAgBC,iBAAgB,SAAS,UAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,cAAkB,EAAE,YAAgBC,mBAAgB,SAAS,YAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,aAAkB,EAAE,WAAgBC,kBAAgB,SAAS,WAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,YAAkB,EAAE,UAAgBC,iBAAgB,SAAS,UAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,UAAkB,EAAE,QAAgBC,eAAgB,SAAS,QAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,WAAkB,EAAE,SAAgBC,gBAAgB,SAAS,SAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,UAAkB,EAAE,QAAgBC,eAAgB,SAAS,QAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,eAAkB,EAAE,aAAgBC,qBAAgB,SAAS,aAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,iBAAkB,EAAE,eAAgBC,uBAAgB,SAAS,eAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,iBAAkB,EAAE,eAAgBC,uBAAgB,SAAS,eAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,cAAkB,EAAE,YAAgBC,mBAAgB,SAAS,YAAgB,QAAQ,EAAE;EACnG,GAAG,SAAS,kBAAkB,EAAE,gBAAgBC,uBAAgB,SAAS,gBAAgB,QAAQ,EAAE;EACpG"}
@@ -1,5 +1,5 @@
1
1
  import { getVertexId } from "../util.js";
2
- import { internalKeysOmitted } from "./util.js";
2
+ import { omitEdgesAndInternalProperties } from "./util.js";
3
3
 
4
4
  //#region src/core/to/settings.ts
5
5
  var settings_default = (settings, options) => {
@@ -7,9 +7,8 @@ var settings_default = (settings, options) => {
7
7
  period: settings.period ? getVertexId(settings.period, options) : void 0,
8
8
  defaultRootInterval: settings.defaultRootInterval ? getVertexId(settings.defaultRootInterval, options) : void 0
9
9
  };
10
- const nonEdges = internalKeysOmitted(settings, edges);
11
10
  return {
12
- ...nonEdges,
11
+ ...omitEdgesAndInternalProperties(settings, edges),
13
12
  ...edges
14
13
  };
15
14
  };
@@ -1 +1 @@
1
- {"version":3,"file":"settings.js","names":["edges: SerializedEdges<Types.divisionSettings>"],"sources":["../../../src/core/to/settings.ts"],"sourcesContent":["import type { BaseOptions } from '../../common/types';\nimport type { Types } from '../types';\nimport { getVertexId } from '../util';\nimport type { OutTypes } from './schedules';\nimport type { SerializedEdges, SerializedEdgesShape } from './util';\nimport { internalKeysOmitted } from './util';\n\nexport default (\n settings: Types.mixed.divisionSettings,\n options: BaseOptions\n): OutTypes.settings => {\n const edges: SerializedEdges<Types.divisionSettings> = {\n period: settings.period ? getVertexId(settings.period, options) : undefined,\n defaultRootInterval: settings.defaultRootInterval ? getVertexId(settings.defaultRootInterval, options) : undefined,\n } satisfies SerializedEdgesShape<Types.divisionSettings>;\n const nonEdges = internalKeysOmitted(settings, edges);\n\n return { ...nonEdges, ...edges };\n};\n"],"mappings":";;;;AAOA,wBACE,UACA,YACsB;CACtB,MAAMA,QAAiD;EACrD,QAAqB,SAAS,SAAsB,YAAY,SAAS,QAAqB,WAAW;EACzG,qBAAqB,SAAS,sBAAsB,YAAY,SAAS,qBAAqB,WAAW;;CAE3G,MAAM,WAAW,oBAAoB,UAAU;AAE/C,QAAO;EAAE,GAAG;EAAU,GAAG"}
1
+ {"version":3,"file":"settings.js","names":["edges: SerializedEdgesOnlyVertexExport<DivisionSettingsVertex>"],"sources":["../../../src/core/to/settings.ts"],"sourcesContent":["import type { BaseOptions } from '../../common/types';\nimport type { DivisionSettingsVertex } from '../interfaces/vertices/division-settings';\nimport type { Types } from '../types';\nimport { getVertexId } from '../util';\nimport type { OutTypes } from './schedules';\nimport { omitEdgesAndInternalProperties, type SerializedEdgesOnlyVertexExport, type SerializedEdgesShape } from './util';\n\nexport default (\n settings: Types.Mixed.Settings,\n options: BaseOptions\n): OutTypes.settings => {\n const edges: SerializedEdgesOnlyVertexExport<DivisionSettingsVertex> = {\n period: settings.period ? getVertexId(settings.period, options) : undefined,\n defaultRootInterval: settings.defaultRootInterval ? getVertexId(settings.defaultRootInterval, options) : undefined,\n } satisfies SerializedEdgesShape<SerializedEdgesOnlyVertexExport<DivisionSettingsVertex>>;\n const nonEdges = omitEdgesAndInternalProperties(settings, edges);\n\n return { ...nonEdges, ...edges };\n};\n"],"mappings":";;;;AAOA,wBACE,UACA,YACsB;CACtB,MAAMA,QAAiE;EACrE,QAAqB,SAAS,SAAsB,YAAY,SAAS,QAAqB,QAAQ,GAAG;EACzG,qBAAqB,SAAS,sBAAsB,YAAY,SAAS,qBAAqB,QAAQ,GAAG;EAC1G;AAGD,QAAO;EAAE,GAFQ,+BAA+B,UAAU,MAAM;EAE1C,GAAG;EAAO"}
@@ -1,12 +1,11 @@
1
- import { internalKeysOmitted } from "./util.js";
1
+ import { omitEdgesAndInternalProperties } from "./util.js";
2
2
 
3
3
  //#region src/core/to/syllabuses.ts
4
4
  var syllabuses_default = (syllabuses, options) => {
5
5
  return syllabuses.map((x) => {
6
6
  const edges = {};
7
- const nonEdges = internalKeysOmitted(x, edges);
8
7
  return {
9
- ...nonEdges,
8
+ ...omitEdgesAndInternalProperties(x, edges),
10
9
  ...edges
11
10
  };
12
11
  });