waha-shared 1.0.1 → 1.0.2

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 (293) hide show
  1. package/README.md +2 -2
  2. package/dist/data/bibleAudios.d.ts +8 -0
  3. package/dist/data/bibleAudios.js +8 -0
  4. package/dist/data/bibleAudios.json +394 -0
  5. package/dist/data/bibleResources/bibleBooks.d.ts +3 -0
  6. package/dist/data/bibleResources/bibleBooks.js +7 -0
  7. package/dist/data/bibleResources/bibleBooks.json +6071 -0
  8. package/dist/data/bibleResources/bibleChaptersList.d.ts +2 -0
  9. package/dist/data/bibleResources/bibleChaptersList.js +8 -0
  10. package/dist/data/bibleResources/bibleChaptersList.json +1191 -0
  11. package/dist/data/bibleStatuses.d.ts +7 -0
  12. package/dist/data/bibleStatuses.js +8 -0
  13. package/dist/data/bibleStatuses.json +9196 -0
  14. package/dist/data/bibleTexts.d.ts +16 -0
  15. package/dist/data/bibleTexts.js +8 -0
  16. package/dist/data/bibleTexts.json +527 -0
  17. package/dist/data/countryResources/areas.d.ts +3 -0
  18. package/dist/data/countryResources/areas.js +7 -0
  19. package/dist/data/countryResources/areas.json +74 -0
  20. package/dist/data/countryResources/countries.d.ts +3 -0
  21. package/dist/data/countryResources/countries.js +7 -0
  22. package/dist/data/countryResources/countries.json +3362 -0
  23. package/dist/data/foundationsCurriculums.d.ts +5 -0
  24. package/dist/data/foundationsCurriculums.js +8 -0
  25. package/dist/data/foundationsCurriculums.json +130 -0
  26. package/dist/data/languageResources/countriesAndLanguages.d.ts +13 -0
  27. package/dist/data/languageResources/countriesAndLanguages.js +7 -0
  28. package/dist/data/languageResources/countriesAndLanguages.json +11718 -0
  29. package/dist/data/languageResources/phoneLanguages.d.ts +11 -0
  30. package/dist/data/languageResources/phoneLanguages.js +7 -0
  31. package/dist/data/languageResources/phoneLanguages.json +1532 -0
  32. package/dist/data/languages.d.ts +45 -0
  33. package/dist/data/languages.js +8 -0
  34. package/dist/data/languages.json +7045 -0
  35. package/dist/data/mediaDurations.d.ts +6 -0
  36. package/dist/data/mediaDurations.js +8 -0
  37. package/dist/data/mediaDurations.json +32364 -0
  38. package/dist/data/notification.d.ts +16 -0
  39. package/dist/data/notification.js +8 -0
  40. package/dist/data/notification.json +69 -0
  41. package/dist/data/numeralMaps.d.ts +13 -0
  42. package/dist/data/numeralMaps.js +8 -0
  43. package/dist/data/numeralMaps.json +26 -0
  44. package/dist/data/questions.d.ts +8 -0
  45. package/dist/data/questions.js +8 -0
  46. package/dist/data/questions.json +317 -0
  47. package/dist/data/questionsCurriculums.d.ts +8 -0
  48. package/dist/data/questionsCurriculums.js +8 -0
  49. package/dist/data/questionsCurriculums.json +753 -0
  50. package/dist/data/releaseNotes.d.ts +6 -0
  51. package/dist/data/releaseNotes.js +8 -0
  52. package/dist/data/releaseNotes.json +2381 -0
  53. package/dist/data/screenshots.d.ts +5 -0
  54. package/dist/data/screenshots.js +8 -0
  55. package/dist/data/screenshots.json +17 -0
  56. package/dist/data/sets.d.ts +14 -0
  57. package/dist/data/sets.js +8 -0
  58. package/dist/data/sets.json +12258 -0
  59. package/dist/data/specialIds.d.ts +18 -0
  60. package/dist/data/specialIds.js +7 -0
  61. package/dist/data/specialIds.json +72 -0
  62. package/dist/data/topicsCurriculums.d.ts +5 -0
  63. package/dist/data/topicsCurriculums.js +8 -0
  64. package/dist/data/topicsCurriculums.json +131 -0
  65. package/dist/data/typescript/appTranslations.d.ts +915 -0
  66. package/dist/data/typescript/appTranslations.js +315 -0
  67. package/dist/data/typescript/areas.d.ts +18 -0
  68. package/dist/data/typescript/areas.js +42 -0
  69. package/dist/data/typescript/aslTimestamps.d.ts +43 -0
  70. package/dist/data/typescript/aslTimestamps.js +31 -0
  71. package/dist/data/typescript/bibleAudioAvailableChapters.d.ts +3 -0
  72. package/dist/data/typescript/bibleAudioAvailableChapters.js +36 -0
  73. package/dist/data/typescript/bibleAudios.d.ts +21 -0
  74. package/dist/data/typescript/bibleAudios.js +23 -0
  75. package/dist/data/typescript/bibleBookNames.d.ts +3 -0
  76. package/dist/data/typescript/bibleBookNames.js +98 -0
  77. package/dist/data/typescript/bibleBooks.d.ts +69 -0
  78. package/dist/data/typescript/bibleBooks.js +56 -0
  79. package/dist/data/typescript/bibleChapters.d.ts +49 -0
  80. package/dist/data/typescript/bibleChapters.js +29 -0
  81. package/dist/data/typescript/bibleStatuses.d.ts +28 -0
  82. package/dist/data/typescript/bibleStatuses.js +39 -0
  83. package/dist/data/typescript/bibleTextAvailableChapters.d.ts +3 -0
  84. package/dist/data/typescript/bibleTextAvailableChapters.js +36 -0
  85. package/dist/data/typescript/bibleTexts.d.ts +53 -0
  86. package/dist/data/typescript/bibleTexts.js +54 -0
  87. package/dist/data/typescript/clones.d.ts +36 -0
  88. package/dist/data/typescript/clones.js +28 -0
  89. package/dist/data/typescript/countries.d.ts +98 -0
  90. package/dist/data/typescript/countries.js +149 -0
  91. package/dist/data/typescript/foundationsCurriculums.d.ts +12 -0
  92. package/dist/data/typescript/foundationsCurriculums.js +12 -0
  93. package/dist/data/typescript/introductionTranslations.d.ts +202 -0
  94. package/dist/data/typescript/introductionTranslations.js +53 -0
  95. package/dist/data/typescript/languages.d.ts +148 -0
  96. package/dist/data/typescript/languages.js +302 -0
  97. package/dist/data/typescript/mediaDurations.d.ts +23 -0
  98. package/dist/data/typescript/mediaDurations.js +72 -0
  99. package/dist/data/typescript/notification.d.ts +45 -0
  100. package/dist/data/typescript/notification.js +176 -0
  101. package/dist/data/typescript/numeralMaps.d.ts +58 -0
  102. package/dist/data/typescript/numeralMaps.js +71 -0
  103. package/dist/data/typescript/questionTranslations.d.ts +3 -0
  104. package/dist/data/typescript/questionTranslations.js +5 -0
  105. package/dist/data/typescript/questions.d.ts +21 -0
  106. package/dist/data/typescript/questions.js +18 -0
  107. package/dist/data/typescript/questionsCurriculums.d.ts +27 -0
  108. package/dist/data/typescript/questionsCurriculums.js +19 -0
  109. package/dist/data/typescript/releaseNotes.d.ts +15 -0
  110. package/dist/data/typescript/releaseNotes.js +9 -0
  111. package/dist/data/typescript/screenshots.d.ts +12 -0
  112. package/dist/data/typescript/screenshots.js +49 -0
  113. package/dist/data/typescript/setTranslations.d.ts +27 -0
  114. package/dist/data/typescript/setTranslations.js +32 -0
  115. package/dist/data/typescript/sets.d.ts +49 -0
  116. package/dist/data/typescript/sets.js +88 -0
  117. package/dist/data/typescript/topicsCurriculums.d.ts +12 -0
  118. package/dist/data/typescript/topicsCurriculums.js +12 -0
  119. package/dist/data/youtube/videos.d.ts +2 -0
  120. package/dist/data/youtube/videos.js +7 -0
  121. package/dist/data/youtube/videos.json +262 -0
  122. package/dist/functions/activeCampaign.d.ts +8 -0
  123. package/dist/functions/activeCampaign.js +97 -0
  124. package/dist/functions/bibleChapterUtils.d.ts +15 -0
  125. package/dist/functions/bibleChapterUtils.js +231 -0
  126. package/dist/functions/crowdin.d.ts +24 -0
  127. package/dist/functions/crowdin.js +34 -0
  128. package/dist/functions/languages.d.ts +24 -0
  129. package/dist/functions/languages.js +212 -0
  130. package/dist/functions/scripturePassages.d.ts +47 -0
  131. package/dist/functions/scripturePassages.js +261 -0
  132. package/dist/functions/sets.d.ts +30 -0
  133. package/dist/functions/sets.js +371 -0
  134. package/dist/translations/appTranslations.d.ts +306 -0
  135. package/dist/translations/appTranslations.js +8 -0
  136. package/dist/translations/appTranslations.json +10239 -0
  137. package/dist/translations/introductionTranslations.d.ts +43 -0
  138. package/dist/translations/introductionTranslations.js +8 -0
  139. package/dist/translations/introductionTranslations.json +422 -0
  140. package/dist/translations/questionTranslations.d.ts +2 -0
  141. package/dist/translations/questionTranslations.js +8 -0
  142. package/dist/translations/questionTranslations.json +1472 -0
  143. package/dist/translations/setTranslations.d.ts +10 -0
  144. package/dist/translations/setTranslations.js +8 -0
  145. package/dist/translations/setTranslations.json +30257 -0
  146. package/dist/types/analytics.d.ts +119 -0
  147. package/dist/types/analytics.js +2 -0
  148. package/dist/types/completions.d.ts +8 -0
  149. package/dist/types/completions.js +2 -0
  150. package/dist/types/feedback.d.ts +60 -0
  151. package/dist/types/feedback.js +27 -0
  152. package/dist/types/languages.d.ts +31 -0
  153. package/dist/types/languages.js +2 -0
  154. package/dist/types/notifications.d.ts +128 -0
  155. package/dist/types/notifications.js +30 -0
  156. package/dist/types/sets.d.ts +70 -0
  157. package/dist/types/sets.js +10 -0
  158. package/dist/types/users.d.ts +765 -0
  159. package/dist/types/users.js +137 -0
  160. package/package.json +2 -2
  161. package/.DS_Store +0 -0
  162. package/__init__.py +0 -0
  163. package/copy.ts +0 -37
  164. package/data/README.md +0 -45
  165. package/data/__init__.py +0 -0
  166. package/data/aslTimestamps.json +0 -192788
  167. package/data/bibleAudios.json +0 -394
  168. package/data/bibleAudios.ts +0 -4
  169. package/data/bibleResources/audioBibleLicenses.json +0 -6235
  170. package/data/bibleResources/bibleBooks.json +0 -6071
  171. package/data/bibleResources/bibleBooks.ts +0 -4
  172. package/data/bibleResources/bibleChaptersList.json +0 -1191
  173. package/data/bibleResources/bibleChaptersList.ts +0 -4
  174. package/data/bibleResources/textBibleLicenses.json +0 -14603
  175. package/data/bibleStatuses.json +0 -9196
  176. package/data/bibleStatuses.ts +0 -4
  177. package/data/bibleTexts.json +0 -527
  178. package/data/bibleTexts.ts +0 -4
  179. package/data/clones.json +0 -13
  180. package/data/countryResources/areas.json +0 -74
  181. package/data/countryResources/areas.ts +0 -4
  182. package/data/countryResources/countries.json +0 -3362
  183. package/data/countryResources/countries.ts +0 -4
  184. package/data/foundationsCurriculums.json +0 -130
  185. package/data/foundationsCurriculums.ts +0 -4
  186. package/data/languageResources/countriesAndLanguages.json +0 -11718
  187. package/data/languageResources/countriesAndLanguages.ts +0 -16
  188. package/data/languageResources/crowdinLanguages.json +0 -2172
  189. package/data/languageResources/iosVoiceOverLanguages.json +0 -64
  190. package/data/languageResources/iso6933LanguageCodes.json +0 -7927
  191. package/data/languageResources/mmsLanguages.json +0 -28164
  192. package/data/languageResources/phoneLanguages.json +0 -1532
  193. package/data/languageResources/phoneLanguages.ts +0 -14
  194. package/data/languages.json +0 -7045
  195. package/data/languages.ts +0 -4
  196. package/data/mediaDurations.json +0 -32364
  197. package/data/mediaDurations.ts +0 -4
  198. package/data/notification.json +0 -69
  199. package/data/notification.ts +0 -4
  200. package/data/numeralMaps.json +0 -26
  201. package/data/numeralMaps.ts +0 -4
  202. package/data/orphanedBibleTexts.json +0 -2747
  203. package/data/questions.json +0 -317
  204. package/data/questions.ts +0 -4
  205. package/data/questionsCurriculums.json +0 -753
  206. package/data/questionsCurriculums.ts +0 -4
  207. package/data/releaseNotes.json +0 -2381
  208. package/data/releaseNotes.ts +0 -4
  209. package/data/schemas/appTranslations.schema.json +0 -802
  210. package/data/schemas/areas.schema.json +0 -76
  211. package/data/schemas/aslTimestamps.schema.json +0 -59
  212. package/data/schemas/bibleAudios.schema.json +0 -37
  213. package/data/schemas/bibleBooks.schema.json +0 -112
  214. package/data/schemas/bibleChapters.schema.json +0 -61
  215. package/data/schemas/bibleStatuses.schema.json +0 -41
  216. package/data/schemas/bibleTexts.schema.json +0 -60
  217. package/data/schemas/clones.schema.json +0 -63
  218. package/data/schemas/countries.schema.json +0 -84
  219. package/data/schemas/foundationsCurriculums.schema.json +0 -20
  220. package/data/schemas/introductionTranslations.schema.json +0 -101
  221. package/data/schemas/languages.schema.json +0 -365
  222. package/data/schemas/mediaDurations.schema.json +0 -41
  223. package/data/schemas/notification.schema.json +0 -111
  224. package/data/schemas/numeralMaps.schema.json +0 -57
  225. package/data/schemas/questionTranslations.schema.json +0 -20
  226. package/data/schemas/questions.schema.json +0 -29
  227. package/data/schemas/questionsCurriculums.schema.json +0 -34
  228. package/data/schemas/releaseNotes.schema.json +0 -21
  229. package/data/schemas/screenshots.schema.json +0 -23
  230. package/data/schemas/setTranslations.schema.json +0 -70
  231. package/data/schemas/sets.schema.json +0 -109
  232. package/data/schemas/topicsCurriculums.schema.json +0 -20
  233. package/data/screenshots.json +0 -17
  234. package/data/screenshots.ts +0 -4
  235. package/data/sets.json +0 -12258
  236. package/data/sets.ts +0 -4
  237. package/data/specialIds.json +0 -72
  238. package/data/specialIds.ts +0 -19
  239. package/data/timings/som.json +0 -9150
  240. package/data/topicsCurriculums.json +0 -131
  241. package/data/topicsCurriculums.ts +0 -4
  242. package/data/typescript/appTranslations.ts +0 -322
  243. package/data/typescript/areas.ts +0 -45
  244. package/data/typescript/aslTimestamps.ts +0 -36
  245. package/data/typescript/bibleAudioAvailableChapters.ts +0 -35
  246. package/data/typescript/bibleAudios.ts +0 -32
  247. package/data/typescript/bibleBookNames.ts +0 -97
  248. package/data/typescript/bibleBooks.ts +0 -63
  249. package/data/typescript/bibleChapters.ts +0 -40
  250. package/data/typescript/bibleStatuses.ts +0 -54
  251. package/data/typescript/bibleTextAvailableChapters.ts +0 -35
  252. package/data/typescript/bibleTexts.ts +0 -63
  253. package/data/typescript/clones.ts +0 -35
  254. package/data/typescript/countries.ts +0 -152
  255. package/data/typescript/foundationsCurriculums.ts +0 -15
  256. package/data/typescript/introductionTranslations.ts +0 -60
  257. package/data/typescript/languages.ts +0 -369
  258. package/data/typescript/mediaDurations.ts +0 -89
  259. package/data/typescript/notification.ts +0 -189
  260. package/data/typescript/numeralMaps.ts +0 -74
  261. package/data/typescript/questionTranslations.ts +0 -6
  262. package/data/typescript/questions.ts +0 -25
  263. package/data/typescript/questionsCurriculums.ts +0 -26
  264. package/data/typescript/releaseNotes.ts +0 -10
  265. package/data/typescript/screenshots.ts +0 -52
  266. package/data/typescript/setTranslations.ts +0 -39
  267. package/data/typescript/sets.ts +0 -105
  268. package/data/typescript/topicsCurriculums.ts +0 -15
  269. package/data/youtube/playlists.json +0 -28
  270. package/data/youtube/videos.json +0 -262
  271. package/data/youtube/videos.ts +0 -2
  272. package/functions/activeCampaign.ts +0 -127
  273. package/functions/bibleChapterUtils.ts +0 -241
  274. package/functions/crowdin.ts +0 -51
  275. package/functions/languages.ts +0 -284
  276. package/functions/scripturePassages.ts +0 -368
  277. package/functions/sets.ts +0 -495
  278. package/translations/appTranslations.json +0 -10239
  279. package/translations/appTranslations.ts +0 -4
  280. package/translations/introductionTranslations.json +0 -422
  281. package/translations/introductionTranslations.ts +0 -4
  282. package/translations/questionTranslations.json +0 -1472
  283. package/translations/questionTranslations.ts +0 -4
  284. package/translations/setTranslations.json +0 -30257
  285. package/translations/setTranslations.ts +0 -4
  286. package/translations/spokenQuestionTranslations.json +0 -1472
  287. package/types/analytics.ts +0 -147
  288. package/types/completions.ts +0 -9
  289. package/types/feedback.ts +0 -27
  290. package/types/languages.ts +0 -37
  291. package/types/notifications.ts +0 -37
  292. package/types/sets.ts +0 -84
  293. package/types/users.ts +0 -162
@@ -1,97 +0,0 @@
1
- import { z } from "zod"
2
-
3
- export const bibleBookNames = z.record(z.union([z.record(z.string()), z.record(z.union([z.string().describe("Localized name for the book ID (e.g., 'GEN' -> 'Génesis')"), z.string().describe("Localized name of the bible book")])).superRefine((value, ctx) => {
4
- for (const key in value) {
5
- let evaluated = false
6
- if (key.match(new RegExp("^[A-Z0-9]{3}$"))) {
7
- evaluated = true
8
- const result = z.string().describe("Localized name for the book ID (e.g., 'GEN' -> 'Génesis')").safeParse(value[key])
9
- if (!result.success) {
10
- ctx.addIssue({
11
- path: [...ctx.path, key],
12
- code: 'custom',
13
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
14
- params: {
15
- issues: result.error.issues
16
- }
17
- })
18
- }
19
- }
20
- if (!evaluated) {
21
- const result = z.string().describe("Localized name of the bible book").safeParse(value[key])
22
- if (!result.success) {
23
- ctx.addIssue({
24
- path: [...ctx.path, key],
25
- code: 'custom',
26
- message: `Invalid input: must match catchall schema`,
27
- params: {
28
- issues: result.error.issues
29
- }
30
- })
31
- }
32
- }
33
- }
34
- }).describe("A mapping of Bible book IDs to their localized names for this translation")])).superRefine((value, ctx) => {
35
- for (const key in value) {
36
- let evaluated = false
37
- if (key.match(new RegExp("^[A-Z0-9]+$"))) {
38
- evaluated = true
39
- const result = z.record(z.string()).safeParse(value[key])
40
- if (!result.success) {
41
- ctx.addIssue({
42
- path: [...ctx.path, key],
43
- code: 'custom',
44
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
45
- params: {
46
- issues: result.error.issues
47
- }
48
- })
49
- }
50
- }
51
- if (!evaluated) {
52
- const result = z.record(z.union([z.string().describe("Localized name for the book ID (e.g., 'GEN' -> 'Génesis')"), z.string().describe("Localized name of the bible book")])).superRefine((value, ctx) => {
53
- for (const key in value) {
54
- let evaluated = false
55
- if (key.match(new RegExp("^[A-Z0-9]{3}$"))) {
56
- evaluated = true
57
- const result = z.string().describe("Localized name for the book ID (e.g., 'GEN' -> 'Génesis')").safeParse(value[key])
58
- if (!result.success) {
59
- ctx.addIssue({
60
- path: [...ctx.path, key],
61
- code: 'custom',
62
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
63
- params: {
64
- issues: result.error.issues
65
- }
66
- })
67
- }
68
- }
69
- if (!evaluated) {
70
- const result = z.string().describe("Localized name of the bible book").safeParse(value[key])
71
- if (!result.success) {
72
- ctx.addIssue({
73
- path: [...ctx.path, key],
74
- code: 'custom',
75
- message: `Invalid input: must match catchall schema`,
76
- params: {
77
- issues: result.error.issues
78
- }
79
- })
80
- }
81
- }
82
- }
83
- }).describe("A mapping of Bible book IDs to their localized names for this translation").safeParse(value[key])
84
- if (!result.success) {
85
- ctx.addIssue({
86
- path: [...ctx.path, key],
87
- code: 'custom',
88
- message: `Invalid input: must match catchall schema`,
89
- params: {
90
- issues: result.error.issues
91
- }
92
- })
93
- }
94
- }
95
- }
96
- }).describe("A mapping of bible translation IDs to their localized book names")
97
- export type BibleBookNames = z.infer<typeof bibleBookNames>
@@ -1,63 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const bibleBooks = z.array(
4
- z.object({
5
- name: z.string().describe('The name of the book.'),
6
- title: z.string().describe('The title of the book.'),
7
- bookId: z
8
- .string()
9
- .describe('The book identifier from the second JSON file.'),
10
- chapters: z
11
- .array(z.object({ id: z.string(), verses: z.number() }))
12
- .describe('An array of chapter identifiers for the book.'),
13
- englishDivision: z
14
- .string()
15
- .describe(
16
- "The English division of the book (e.g., 'Pentateuch', 'Wisdom')."
17
- ),
18
- hebrewDivision: z
19
- .union([
20
- z
21
- .string()
22
- .describe(
23
- "The Hebrew division of the book (e.g., 'Torah', 'Ketuvim')."
24
- ),
25
- z
26
- .null()
27
- .describe(
28
- "The Hebrew division of the book (e.g., 'Torah', 'Ketuvim')."
29
- ),
30
- ])
31
- .describe("The Hebrew division of the book (e.g., 'Torah', 'Ketuvim').")
32
- .optional(),
33
- hebrewOrder: z
34
- .union([
35
- z.number().int().describe('The order of the book in the Hebrew Bible.'),
36
- z.null().describe('The order of the book in the Hebrew Bible.'),
37
- ])
38
- .describe('The order of the book in the Hebrew Bible.')
39
- .optional(),
40
- isNt: z
41
- .boolean()
42
- .describe('Indicates if the book is in the New Testament.'),
43
- lowercase: z.string().describe('The lowercase title of the book.'),
44
- lowercase_dashes: z
45
- .string()
46
- .describe('The lowercase title of the book with dashes.'),
47
- number: z
48
- .number()
49
- .int()
50
- .describe('The numeric order of the book in the Bible.'),
51
- order: z.number().int().describe('The order of the book in the Bible.'),
52
- testament: z
53
- .string()
54
- .describe("The testament of the book ('old' or 'new')."),
55
- title_dashes: z.string().describe('The title of the book with dashes.'),
56
- usfm: z.string().describe('The USFM code for the book.'),
57
- nameAlternates: z
58
- .array(z.string())
59
- .describe('Alternative names for the book.')
60
- .optional(),
61
- })
62
- )
63
- export type BibleBooks = z.infer<typeof bibleBooks>
@@ -1,40 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const bibleChapters = z.array(
4
- z
5
- .object({
6
- bookName: z.string(),
7
- chapterId: z
8
- .string()
9
- .regex(
10
- new RegExp(
11
- '^(GEN|EXO|LEV|NUM|DEU|JOS|JDG|RUT|1SA|2SA|1KI|2KI|1CH|2CH|EZR|NEH|EST|JOB|PSA|PRO|ECC|SNG|ISA|JER|LAM|EZK|DAN|HOS|JOL|AMO|OBA|JON|MIC|NAM|HAB|ZEP|HAG|ZEC|MAL|MAT|MRK|LUK|JHN|ACT|ROM|1CO|2CO|GAL|EPH|PHP|COL|1TH|2TH|1TI|2TI|TIT|PHM|HEB|JAS|1PE|2PE|1JN|2JN|3JN|JUD|REV)\\.[0-9]+$'
12
- )
13
- ),
14
- reference: z.string().optional(),
15
- titles: z.union([z.record(z.string()), z.null()]).optional(),
16
- translationId: z.string(),
17
- verses: z
18
- .array(
19
- z
20
- .object({
21
- text: z.string(),
22
- timings: z
23
- .union([z.tuple([z.number(), z.number()]), z.null()])
24
- .optional(),
25
- uroman: z.union([z.string(), z.null()]).optional(),
26
- verseId: z
27
- .string()
28
- .regex(
29
- new RegExp(
30
- '^(GEN|EXO|LEV|NUM|DEU|JOS|JDG|RUT|1SA|2SA|1KI|2KI|1CH|2CH|EZR|NEH|EST|JOB|PSA|PRO|ECC|SNG|ISA|JER|LAM|EZK|DAN|HOS|JOL|AMO|OBA|JON|MIC|NAM|HAB|ZEP|HAG|ZEC|MAL|MAT|MRK|LUK|JHN|ACT|ROM|1CO|2CO|GAL|EPH|PHP|COL|1TH|2TH|1TI|2TI|TIT|PHM|HEB|JAS|1PE|2PE|1JN|2JN|3JN|JUD|REV)\\.[0-9]+\\.[0-9]+(-[0-9]+)?$'
31
- )
32
- ),
33
- })
34
- .strict()
35
- )
36
- .min(1),
37
- })
38
- .strict()
39
- )
40
- export type BibleChapters = z.infer<typeof bibleChapters>
@@ -1,54 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const bibleStatuses = z
4
- .record(
5
- z
6
- .object({
7
- text: z.array(
8
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
9
- ),
10
- audio: z.array(
11
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
12
- ),
13
- timings: z.array(
14
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
15
- ),
16
- bookNames: z.record(z.string()),
17
- })
18
- .strict()
19
- )
20
- .superRefine((value, ctx) => {
21
- for (const key in value) {
22
- if (key.match(new RegExp('^[A-Z0-9]+$'))) {
23
- const result = z
24
- .object({
25
- text: z.array(
26
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
27
- ),
28
- audio: z.array(
29
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
30
- ),
31
- timings: z.array(
32
- z.string().regex(new RegExp('^([A-Z0-9]{3}(\\.[0-9]+)?|OT|NT)$'))
33
- ),
34
- bookNames: z.record(z.string()),
35
- })
36
- .strict()
37
- .safeParse(value[key])
38
- if (!result.success) {
39
- ctx.addIssue({
40
- path: [...ctx.path, key],
41
- code: 'custom',
42
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
43
- params: {
44
- issues: result.error.issues,
45
- },
46
- })
47
- }
48
- }
49
- }
50
- })
51
- .describe(
52
- "Consolidated bible data containing text chapters, audio chapters, timings, and book names for each translation. Entries can be testament IDs ('OT', 'NT'), book IDs (e.g., 'GEN') for complete books, or chapter IDs (e.g., 'GEN.1') for individual chapters."
53
- )
54
- export type BibleStatuses = z.infer<typeof bibleStatuses>
@@ -1,35 +0,0 @@
1
- import { z } from "zod"
2
-
3
- export const bibleTextAvailableChapters = z.record(z.union([z.array(z.string().regex(new RegExp("^[A-Z0-9]{3}\\.[0-9]+$"))), z.array(z.string().regex(new RegExp("^[A-Z0-9]{3}\\.[0-9]+$")).describe("Chapter identifier in the format 'BOOK.CHAPTER' (e.g., 'GEN.1', 'REV.22')")).describe("Array of available text chapter identifiers for this translation")])).superRefine((value, ctx) => {
4
- for (const key in value) {
5
- let evaluated = false
6
- if (key.match(new RegExp("^[A-Z0-9]+$"))) {
7
- evaluated = true
8
- const result = z.array(z.string().regex(new RegExp("^[A-Z0-9]{3}\\.[0-9]+$"))).safeParse(value[key])
9
- if (!result.success) {
10
- ctx.addIssue({
11
- path: [...ctx.path, key],
12
- code: 'custom',
13
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
14
- params: {
15
- issues: result.error.issues
16
- }
17
- })
18
- }
19
- }
20
- if (!evaluated) {
21
- const result = z.array(z.string().regex(new RegExp("^[A-Z0-9]{3}\\.[0-9]+$")).describe("Chapter identifier in the format 'BOOK.CHAPTER' (e.g., 'GEN.1', 'REV.22')")).describe("Array of available text chapter identifiers for this translation").safeParse(value[key])
22
- if (!result.success) {
23
- ctx.addIssue({
24
- path: [...ctx.path, key],
25
- code: 'custom',
26
- message: `Invalid input: must match catchall schema`,
27
- params: {
28
- issues: result.error.issues
29
- }
30
- })
31
- }
32
- }
33
- }
34
- }).describe("A mapping of bible translation IDs to their available text chapters")
35
- export type BibleTextAvailableChapters = z.infer<typeof bibleTextAvailableChapters>
@@ -1,63 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const bibleTexts = z.array(
4
- z
5
- .object({
6
- bibleTextId: z.string(),
7
- name: z
8
- .string()
9
- .describe('The name of the bible translation in its own language.'),
10
- alternativeFull: z
11
- .string()
12
- .describe(
13
- "If a bible isn't available for the full Bible due to licensing restrictions, define an alternative Bible that does support full Bible here."
14
- )
15
- .optional(),
16
- audioId: z
17
- .string()
18
- .describe(
19
- 'The bibleAudioId of the corresponding audio bible translation, if available.'
20
- )
21
- .optional(),
22
- copyright: z
23
- .string()
24
- .describe(
25
- 'The copyright attribution text required to be shown in-app for this translation.'
26
- )
27
- .optional(),
28
- copyrightImage: z
29
- .string()
30
- .describe('The image to display with the copyright.')
31
- .optional(),
32
- language: z
33
- .string()
34
- .regex(new RegExp('^[a-z]{3}$'))
35
- .describe('The language of the translation.'),
36
- nameEnglish: z
37
- .string()
38
- .describe('The name of the bible translation in English.')
39
- .optional(),
40
- textSource: z
41
- .object({
42
- includeSectionTitles: z
43
- .boolean()
44
- .describe('Whether or not to include section titles in the text.')
45
- .optional(),
46
- source: z.enum([
47
- 'dbl',
48
- 'bibleBrain',
49
- 'usfm',
50
- 'usfx',
51
- 'yvp',
52
- 'custom',
53
- ]),
54
- sourceId: z.string().optional(),
55
- })
56
- .strict()
57
- .describe(
58
- "Information about how to retrieve the text. Ideally, text is available on the DBL via API.Bible when the license is granted, but there are a few other options. We have access to translations available on BibleBrain as well as being able to parse USFX files. Some translations may be available on the YouVersion Platform (yvp). If none of these work, 'custom' can be used and some custom code added to leviathan to retrieve and parse the text."
59
- ),
60
- })
61
- .strict()
62
- )
63
- export type BibleTexts = z.infer<typeof bibleTexts>
@@ -1,35 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const clones = z.array(
4
- z
5
- .object({
6
- appId: z.string().regex(new RegExp('^[a-z]*$')),
7
- appIdCaps: z.string().regex(new RegExp('^[A-Z]*$')),
8
- appName: z.string(),
9
- color: z.string().regex(new RegExp('^#[0-9A-Fa-f]{6}$')),
10
- icon: z
11
- .string()
12
- .regex(new RegExp('^src\\/assets\\/clones/[A-Za-z\\-\\_]*\\.png$')),
13
- iconNoBg: z
14
- .string()
15
- .regex(new RegExp('^src\\/assets\\/clones/[A-Za-z\\-\\_]*\\.png$')),
16
- languages: z.any().optional(),
17
- linkAndroid: z
18
- .string()
19
- .describe(
20
- 'URL to the app in the Google Play Store. Just `https://play.google.com/store/apps/details?id=com.kingdomstrategies.` + the clone appId.'
21
- ),
22
- linkIos: z
23
- .string()
24
- .describe(
25
- 'URL to the app in the Apple App Store. After creating app on ASC, go to App Store Connect > App Information > Additional Information > App Store ID.'
26
- ),
27
- removeTraining: z
28
- .boolean()
29
- .describe(
30
- 'If true, the training section and content will be removed from the clone.'
31
- ),
32
- })
33
- .strict()
34
- )
35
- export type Clones = z.infer<typeof clones>
@@ -1,152 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const countries = z
4
- .record(
5
- z.union([
6
- z
7
- .object({
8
- name: z.string().describe('The display name of the country'),
9
- areaId: z
10
- .enum([
11
- 'north-america',
12
- 'latin-america-caribbean',
13
- 'sub-saharan-africa',
14
- 'middle-east-north-africa',
15
- 'western-asia',
16
- 'western-europe',
17
- 'eastern-europe',
18
- 'southern-asia',
19
- 'central-asia',
20
- 'eastern-asia',
21
- 'southeast-asia',
22
- 'oceania',
23
- ])
24
- .describe('The geographical area identifier'),
25
- boundingBox: z
26
- .object({
27
- ne: z
28
- .object({
29
- lat: z
30
- .number()
31
- .gte(-90)
32
- .lte(90)
33
- .describe('Northeast latitude coordinate'),
34
- lon: z
35
- .number()
36
- .gte(-180)
37
- .lte(180)
38
- .describe('Northeast longitude coordinate'),
39
- })
40
- .strict(),
41
- sw: z
42
- .object({
43
- lat: z
44
- .number()
45
- .gte(-90)
46
- .lte(90)
47
- .describe('Southwest latitude coordinate'),
48
- lon: z
49
- .number()
50
- .gte(-180)
51
- .lte(180)
52
- .describe('Southwest longitude coordinate'),
53
- })
54
- .strict(),
55
- })
56
- .strict()
57
- .describe('Bounding box coordinates for the country'),
58
- })
59
- .strict(),
60
- z.never(),
61
- ])
62
- )
63
- .superRefine((value, ctx) => {
64
- for (const key in value) {
65
- let evaluated = false
66
- if (key.match(new RegExp('^[A-Z]{2}$'))) {
67
- evaluated = true
68
- const result = z
69
- .object({
70
- name: z.string().describe('The display name of the country'),
71
- areaId: z
72
- .enum([
73
- 'north-america',
74
- 'latin-america-caribbean',
75
- 'sub-saharan-africa',
76
- 'middle-east-north-africa',
77
- 'western-asia',
78
- 'western-europe',
79
- 'eastern-europe',
80
- 'southern-asia',
81
- 'central-asia',
82
- 'eastern-asia',
83
- 'southeast-asia',
84
- 'oceania',
85
- ])
86
- .describe('The geographical area identifier'),
87
- boundingBox: z
88
- .object({
89
- ne: z
90
- .object({
91
- lat: z
92
- .number()
93
- .gte(-90)
94
- .lte(90)
95
- .describe('Northeast latitude coordinate'),
96
- lon: z
97
- .number()
98
- .gte(-180)
99
- .lte(180)
100
- .describe('Northeast longitude coordinate'),
101
- })
102
- .strict(),
103
- sw: z
104
- .object({
105
- lat: z
106
- .number()
107
- .gte(-90)
108
- .lte(90)
109
- .describe('Southwest latitude coordinate'),
110
- lon: z
111
- .number()
112
- .gte(-180)
113
- .lte(180)
114
- .describe('Southwest longitude coordinate'),
115
- })
116
- .strict(),
117
- })
118
- .strict()
119
- .describe('Bounding box coordinates for the country'),
120
- })
121
- .strict()
122
- .safeParse(value[key])
123
- if (!result.success) {
124
- ctx.addIssue({
125
- path: [...ctx.path, key],
126
- code: 'custom',
127
- message: `Invalid input: Key matching regex /${key}/ must match schema`,
128
- params: {
129
- issues: result.error.issues,
130
- },
131
- })
132
- }
133
- }
134
- if (!evaluated) {
135
- const result = z.never().safeParse(value[key])
136
- if (!result.success) {
137
- ctx.addIssue({
138
- path: [...ctx.path, key],
139
- code: 'custom',
140
- message: `Invalid input: must match catchall schema`,
141
- params: {
142
- issues: result.error.issues,
143
- },
144
- })
145
- }
146
- }
147
- }
148
- })
149
- .describe(
150
- 'A mapping of country codes to country information including name, area, and bounding box coordinates'
151
- )
152
- export type Countries = z.infer<typeof countries>
@@ -1,15 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const foundationsCurriculums = z.array(
4
- z
5
- .object({
6
- curriculumId: z.string(),
7
- sets: z
8
- .array(z.string())
9
- .describe(
10
- 'An array of set ids that make up this foundations curriculum. Set ids must be linked to valid sets present in data/sets.json.'
11
- ),
12
- })
13
- .strict()
14
- )
15
- export type FoundationsCurriculums = z.infer<typeof foundationsCurriculums>
@@ -1,60 +0,0 @@
1
- import { z } from 'zod'
2
-
3
- export const introductionTranslations = z
4
- .record(
5
- z
6
- .object({
7
- introduction: z.string(),
8
- introductions: z
9
- .object({
10
- '03.005.001': z.string().min(1),
11
- '03.005.002': z.string().min(1),
12
- '03.005.003': z.string().min(1),
13
- '03.005.004': z.string().min(1),
14
- '03.005.005': z.string().min(1),
15
- '03.005.006': z.string().min(1),
16
- '03.005.007': z.string().min(1),
17
- '03.005.008': z.string().min(1),
18
- '03.005.009': z.string().min(1),
19
- '03.005.010': z.string().min(1),
20
- '03.005.011': z.string().min(1),
21
- '03.005.012': z.string().min(1),
22
- '03.006.001': z.string().min(1),
23
- '03.006.002': z.string().min(1),
24
- '03.006.003': z.string().min(1),
25
- '03.006.004': z.string().min(1),
26
- '03.006.005': z.string().min(1),
27
- '03.006.006': z.string().min(1),
28
- '03.006.007': z.string().min(1),
29
- '03.006.008': z.string().min(1),
30
- '03.006.009': z.string().min(1),
31
- '03.006.010': z.string().min(1),
32
- '03.006.011': z.string().min(1),
33
- '03.006.012': z.string().min(1),
34
- '03.007.001': z.string().min(1),
35
- '03.007.002': z.string().min(1),
36
- '03.007.003': z.string().min(1),
37
- '03.007.004': z.string().min(1),
38
- '03.007.005': z.string().min(1),
39
- '03.007.006': z.string().min(1),
40
- '03.007.007': z.string().min(1),
41
- '03.007.008': z.string().min(1),
42
- '03.007.009': z.string().min(1),
43
- '03.007.010': z.string().min(1),
44
- '03.007.011': z.string().min(1),
45
- '03.007.012': z.string().min(1),
46
- eq: z.string().min(1),
47
- })
48
- .describe(
49
- "Mapping of lesson identifiers (NN.NNN.NNN) or 'eq' to translated strings."
50
- ),
51
- })
52
- .strict()
53
- .describe(
54
- 'Translations for a single language (identified by a 3-letter code).'
55
- )
56
- )
57
- .describe(
58
- "Schema for introductionTranslations_json. Root keys are 3-letter language identifiers (ISO-639 style). Each language object contains an 'introduction' string and an 'introductions' object mapping lesson identifiers (e.g. 03.005.001) or the key 'eq' to localized string content."
59
- )
60
- export type IntroductionTranslations = z.infer<typeof introductionTranslations>