@helloao/tools 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/dist/cjs/generation/api.cjs +727 -2
  2. package/dist/cjs/generation/api.cjs.map +2 -2
  3. package/dist/cjs/generation/audio.cjs +52 -5
  4. package/dist/cjs/generation/audio.cjs.map +2 -2
  5. package/dist/cjs/generation/book-order.cjs +1 -1
  6. package/dist/cjs/generation/book-order.cjs.map +2 -2
  7. package/dist/cjs/generation/common-types.cjs +651 -0
  8. package/dist/cjs/generation/common-types.cjs.map +2 -2
  9. package/dist/cjs/generation/dataset.cjs +31 -8
  10. package/dist/cjs/generation/dataset.cjs.map +2 -2
  11. package/dist/cjs/index.cjs.map +1 -1
  12. package/dist/cjs/log.cjs.map +1 -1
  13. package/dist/cjs/parser/codex-parser.cjs.map +1 -1
  14. package/dist/cjs/parser/commentary-csv-parser.cjs.map +1 -1
  15. package/dist/cjs/parser/iterators.cjs.map +1 -1
  16. package/dist/cjs/parser/lockman-parser.cjs +334 -0
  17. package/dist/cjs/parser/lockman-parser.cjs.map +7 -0
  18. package/dist/cjs/parser/tyndale-xml-parser.cjs.map +1 -1
  19. package/dist/cjs/parser/types.cjs.map +1 -1
  20. package/dist/cjs/parser/usfm-parser.cjs.map +1 -1
  21. package/dist/cjs/parser/usx-parser.cjs +24 -7
  22. package/dist/cjs/parser/usx-parser.cjs.map +2 -2
  23. package/dist/cjs/utils.cjs +152 -0
  24. package/dist/cjs/utils.cjs.map +3 -3
  25. package/dist/esm/generation/api.js +696 -2
  26. package/dist/esm/generation/api.js.map +2 -2
  27. package/dist/esm/generation/audio.js +46 -3
  28. package/dist/esm/generation/audio.js.map +2 -2
  29. package/dist/esm/generation/book-order.js +1 -1
  30. package/dist/esm/generation/book-order.js.map +2 -2
  31. package/dist/esm/generation/common-types.js +590 -0
  32. package/dist/esm/generation/common-types.js.map +3 -3
  33. package/dist/esm/generation/dataset.js +29 -8
  34. package/dist/esm/generation/dataset.js.map +2 -2
  35. package/dist/esm/index.js.map +1 -1
  36. package/dist/esm/log.js.map +1 -1
  37. package/dist/esm/parser/codex-parser.js.map +1 -1
  38. package/dist/esm/parser/commentary-csv-parser.js.map +1 -1
  39. package/dist/esm/parser/iterators.js.map +1 -1
  40. package/dist/esm/parser/lockman-parser.js +306 -0
  41. package/dist/esm/parser/lockman-parser.js.map +7 -0
  42. package/dist/esm/parser/tyndale-xml-parser.js.map +1 -1
  43. package/dist/esm/parser/usfm-parser.js.map +1 -1
  44. package/dist/esm/parser/usx-parser.js +24 -7
  45. package/dist/esm/parser/usx-parser.js.map +2 -2
  46. package/dist/esm/utils.js +138 -0
  47. package/dist/esm/utils.js.map +2 -2
  48. package/dist/types/generation/api.d.ts +2515 -470
  49. package/dist/types/generation/audio.d.ts +5 -0
  50. package/dist/types/generation/common-types.d.ts +1222 -413
  51. package/dist/types/generation/dataset.d.ts +1 -0
  52. package/dist/types/parser/codex-parser.d.ts +18 -138
  53. package/dist/types/parser/lockman-parser.d.ts +14 -0
  54. package/dist/types/parser/types.d.ts +4 -0
  55. package/dist/types/parser/usx-parser.d.ts +2 -2
  56. package/dist/types/utils.d.ts +223 -18
  57. package/package.json +5 -3
@@ -3,6 +3,10 @@ var __defProp = Object.defineProperty;
3
3
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
4
  var __getOwnPropNames = Object.getOwnPropertyNames;
5
5
  var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
6
10
  var __copyProps = (to, from, except, desc) => {
7
11
  if (from && typeof from === "object" || typeof from === "function") {
8
12
  for (let key of __getOwnPropNames(from))
@@ -13,5 +17,652 @@ var __copyProps = (to, from, except, desc) => {
13
17
  };
14
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
19
  var common_types_exports = {};
20
+ __export(common_types_exports, {
21
+ ChapterContentSchema: () => ChapterContentSchema,
22
+ ChapterDataSchema: () => ChapterDataSchema,
23
+ ChapterFootnoteSchema: () => ChapterFootnoteSchema,
24
+ ChapterHeadingSchema: () => ChapterHeadingSchema,
25
+ ChapterHebrewSubtitleSchema: () => ChapterHebrewSubtitleSchema,
26
+ ChapterLineBreakSchema: () => ChapterLineBreakSchema,
27
+ ChapterVerseSchema: () => ChapterVerseSchema,
28
+ CommentaryBookChapterSchema: () => CommentaryBookChapterSchema,
29
+ CommentaryBookSchema: () => CommentaryBookSchema,
30
+ CommentaryChapterDataSchema: () => CommentaryChapterDataSchema,
31
+ CommentaryProfileSchema: () => CommentaryProfileSchema,
32
+ CommentarySchema: () => CommentarySchema,
33
+ DatasetBookChapterSchema: () => DatasetBookChapterSchema,
34
+ DatasetBookSchema: () => DatasetBookSchema,
35
+ DatasetChapterDataSchema: () => DatasetChapterDataSchema,
36
+ DatasetChapterVerseContentSchema: () => DatasetChapterVerseContentSchema,
37
+ DatasetSchema: () => DatasetSchema,
38
+ FormattedTextSchema: () => FormattedTextSchema,
39
+ InlineHeadingSchema: () => InlineHeadingSchema,
40
+ InlineLineBreakSchema: () => InlineLineBreakSchema,
41
+ ScoredVerseRefSchema: () => ScoredVerseRefSchema,
42
+ TranslationBookChapterAudioLinksSchema: () => TranslationBookChapterAudioLinksSchema,
43
+ TranslationBookChapterSchema: () => TranslationBookChapterSchema,
44
+ TranslationBookSchema: () => TranslationBookSchema,
45
+ TranslationSchema: () => TranslationSchema,
46
+ VerseFootnoteReferenceSchema: () => VerseFootnoteReferenceSchema
47
+ });
16
48
  module.exports = __toCommonJS(common_types_exports);
49
+ var import_zod = require("zod");
50
+ var import_utils = require("../utils.js");
51
+ const TranslationSchema = import_zod.z.object({
52
+ /**
53
+ * The ID of the translation.
54
+ */
55
+ id: import_zod.z.string().meta({
56
+ description: "The ID of the translation."
57
+ }),
58
+ /**
59
+ * The name of the translation.
60
+ */
61
+ name: import_zod.z.string().meta({
62
+ description: "The name of the translation."
63
+ }),
64
+ /**
65
+ * The website for the translation.
66
+ */
67
+ website: import_zod.z.string().meta({
68
+ description: "The website for the translation."
69
+ }),
70
+ /**
71
+ * The URL that the license for the translation can be found.
72
+ */
73
+ licenseUrl: import_zod.z.string().meta({
74
+ description: "The URL that the license for the translation can be found."
75
+ }),
76
+ /**
77
+ * The API-added notes for the license.
78
+ */
79
+ licenseNotes: import_zod.z.string().nullable().optional().meta({
80
+ description: "The API-added notes for the license."
81
+ }),
82
+ /**
83
+ * The notice that should be displayed when displaying content from the translation.
84
+ */
85
+ licenseNotice: import_zod.z.string().nullable().optional().meta({
86
+ description: "The notice that should be displayed when displaying content from the translation."
87
+ }),
88
+ /**
89
+ * The short name for the translation.
90
+ */
91
+ shortName: import_zod.z.string().optional().meta({
92
+ description: "The short name for the translation."
93
+ }),
94
+ /**
95
+ * The English name for the translation.
96
+ */
97
+ englishName: import_zod.z.string().meta({
98
+ description: "The English name for the translation."
99
+ }),
100
+ /**
101
+ * The ISO 639 3-letter language tag that the translation is primarily in.
102
+ */
103
+ language: import_zod.z.string().meta({
104
+ description: "The ISO 639 3-letter language tag that the translation is primarily in."
105
+ }),
106
+ /**
107
+ * The direction that the language is written in.
108
+ * "ltr" indicates that the text is written from the left side of the page to the right.
109
+ * "rtl" indicates that the text is written from the right side of the page to the left.
110
+ */
111
+ textDirection: import_zod.z.enum(["ltr", "rtl"]).meta({
112
+ description: "The direction that the language is written in. `ltr` indicates that the text is written from the left side of the page to the right. `rtl` indicates that the text is written from the right side of the page to the left."
113
+ })
114
+ });
115
+ const CommentarySchema = import_zod.z.object({
116
+ /**
117
+ * The ID of the commentary.
118
+ */
119
+ id: import_zod.z.string().meta({
120
+ description: "The ID of the commentary."
121
+ }),
122
+ /**
123
+ * The name of the commentary.
124
+ */
125
+ name: import_zod.z.string().meta({
126
+ description: "The name of the commentary."
127
+ }),
128
+ /**
129
+ * The website for the commentary.
130
+ */
131
+ website: import_zod.z.string().meta({
132
+ description: "The website for the commentary."
133
+ }),
134
+ /**
135
+ * The URL that the license for the commentary can be found.
136
+ */
137
+ licenseUrl: import_zod.z.string().meta({
138
+ description: "The URL that the license for the commentary can be found."
139
+ }),
140
+ /**
141
+ * The API-added notes for the license.
142
+ */
143
+ licenseNotes: import_zod.z.string().nullable().optional().meta({
144
+ description: "The API-added notes for the license."
145
+ }),
146
+ /**
147
+ * The english name for the commentary.
148
+ */
149
+ englishName: import_zod.z.string().meta({
150
+ description: "The English name for the commentary."
151
+ }),
152
+ /**
153
+ * The ISO 639 3-letter language tag that the translation is primarily in.
154
+ */
155
+ language: import_zod.z.string().meta({
156
+ description: "The ISO 639 3-letter language tag that the translation is primarily in."
157
+ }),
158
+ /**
159
+ * The direction that the language is written in.
160
+ * "ltr" indicates that the text is written from the left side of the page to the right.
161
+ * "rtl" indicates that the text is written from the right side of the page to the left.
162
+ */
163
+ textDirection: import_zod.z.enum(["ltr", "rtl"]).meta({
164
+ description: "The direction that the language is written in. `ltr` indicates that the text is written from the left side of the page to the right. `rtl` indicates that the text is written from the right side of the page to the left."
165
+ })
166
+ });
167
+ const DatasetSchema = import_zod.z.object({
168
+ /**
169
+ * The ID of the dataset.
170
+ */
171
+ id: import_zod.z.string().meta({
172
+ description: "The ID of the dataset."
173
+ }),
174
+ /**
175
+ * The name of the dataset.
176
+ */
177
+ name: import_zod.z.string().meta({
178
+ description: "The name of the dataset."
179
+ }),
180
+ /**
181
+ * The website for the dataset.
182
+ */
183
+ website: import_zod.z.string().meta({
184
+ description: "The website for the dataset."
185
+ }),
186
+ /**
187
+ * The URL that the license for the dataset can be found.
188
+ */
189
+ licenseUrl: import_zod.z.string().meta({
190
+ description: "The URL that the license for the dataset can be found."
191
+ }),
192
+ /**
193
+ * The API-added notes for the license.
194
+ */
195
+ licenseNotes: import_zod.z.string().nullable().optional().meta({
196
+ description: "The API-added notes for the license."
197
+ }),
198
+ /**
199
+ * The English name for the dataset.
200
+ */
201
+ englishName: import_zod.z.string().meta({
202
+ description: "The English name for the dataset."
203
+ }),
204
+ /**
205
+ * The ISO 639 3-letter language tag that the dataset is primarily in.
206
+ */
207
+ language: import_zod.z.string().meta({
208
+ description: "The ISO 639 3-letter language tag that the dataset is primarily in."
209
+ }),
210
+ /**
211
+ * The direction that the language is written in.
212
+ */
213
+ textDirection: import_zod.z.enum(["ltr", "rtl"]).meta({
214
+ description: "The direction that the language is written in."
215
+ })
216
+ });
217
+ const TranslationBookSchema = import_zod.z.object({
218
+ /**
219
+ * The ID of the book. Should match the USFM book ID.
220
+ */
221
+ id: import_utils.BookIdSchema,
222
+ /**
223
+ * The name that the translation provided for the book.
224
+ */
225
+ name: import_zod.z.string().meta({
226
+ description: "The name that the translation provided for the book."
227
+ }),
228
+ /**
229
+ * The common name for the book.
230
+ */
231
+ commonName: import_zod.z.string().meta({
232
+ description: "The common name for the book."
233
+ }),
234
+ /**
235
+ * The title of the book.
236
+ * This is usually a more descriptive version of the book name.
237
+ * If not available, then one was not provided by the translation.
238
+ */
239
+ title: import_zod.z.string().nullable().meta({
240
+ description: "The title of the book. This is usually a more descriptive version of the book name. If not available, then one was not provided by the translation."
241
+ }),
242
+ /**
243
+ * The numerical order of the book in the translation.
244
+ */
245
+ order: import_zod.z.number().meta({
246
+ description: "The numerical order of the book in the translation."
247
+ }),
248
+ /**
249
+ * Whether the book is an apocryphal book.
250
+ */
251
+ isApocryphal: import_zod.z.boolean().optional().meta({
252
+ description: "Whether the book is an apocryphal book."
253
+ })
254
+ }).meta({
255
+ id: "TranslationBook",
256
+ description: "Defines the schema for information about a book."
257
+ });
258
+ const CommentaryBookSchema = import_zod.z.object({
259
+ /**
260
+ * The ID of the book. Should match the USFM book ID.
261
+ */
262
+ id: import_utils.BookIdSchema,
263
+ /**
264
+ * The name that the commentary provided for the book.
265
+ */
266
+ name: import_zod.z.string().meta({
267
+ description: "The name that the commentary provided for the book."
268
+ }),
269
+ /**
270
+ * The common name for the book.
271
+ */
272
+ commonName: import_zod.z.string().meta({
273
+ description: "The common name for the book."
274
+ }),
275
+ /**
276
+ * The commentary's introduction for the book.
277
+ */
278
+ introduction: import_zod.z.string().optional().meta({
279
+ description: "The commentary's introduction for the book. Undefined if the commentary didn't provide an introduction for the book."
280
+ }),
281
+ /**
282
+ * The summary of the commentary's introduction for the book.
283
+ */
284
+ introductionSummary: import_zod.z.string().optional().meta({
285
+ description: "The summary of the commentary's introduction for the book. Undefined if the commentary didn't provide a summary for the book."
286
+ }),
287
+ /**
288
+ * The order of the book in the Bible.
289
+ */
290
+ order: import_zod.z.number().meta({
291
+ description: "The order of the book in the Bible."
292
+ })
293
+ }).meta({
294
+ id: "CommentaryBook",
295
+ description: "Defines the schema for information about a book in a commentary."
296
+ });
297
+ const DatasetBookSchema = import_zod.z.object({
298
+ /**
299
+ * The ID of the book. Should match the USFM book ID.
300
+ */
301
+ id: import_utils.BookIdSchema,
302
+ /**
303
+ * The order of the book in the Bible.
304
+ */
305
+ order: import_zod.z.number().meta({
306
+ description: "The order of the book in the Bible."
307
+ })
308
+ }).meta({
309
+ id: "DatasetBook",
310
+ description: "Defines the schema for information about a book in a dataset."
311
+ });
312
+ const DatasetBookChapterSchema = import_zod.z.object({
313
+ /**
314
+ * The data for the chapter.
315
+ */
316
+ chapter: import_zod.z.lazy(() => DatasetChapterDataSchema).meta({
317
+ description: "The data for the chapter."
318
+ })
319
+ }).meta({
320
+ id: "DatasetBookChapter",
321
+ description: "Defines the schema for information about a chapter in a dataset."
322
+ });
323
+ const DatasetChapterDataSchema = import_zod.z.object({
324
+ /**
325
+ * The number of the chapter.
326
+ */
327
+ number: import_zod.z.number().meta({
328
+ description: "The number of the chapter."
329
+ }),
330
+ /**
331
+ * The content of the chapter.
332
+ */
333
+ content: import_zod.z.array(import_zod.z.lazy(() => DatasetChapterVerseContentSchema)).meta({
334
+ description: "The content of the chapter."
335
+ })
336
+ }).meta({
337
+ id: "DatasetChapterData",
338
+ description: "Defines the schema for information about a chapter in a dataset."
339
+ });
340
+ const DatasetChapterVerseContentSchema = import_zod.z.object({
341
+ /**
342
+ * The number of the verse.
343
+ */
344
+ verse: import_zod.z.number().meta({
345
+ description: "The number of the verse."
346
+ }),
347
+ /**
348
+ * The list of references for the verse.
349
+ */
350
+ references: import_zod.z.array(import_zod.z.lazy(() => ScoredVerseRefSchema)).meta({
351
+ description: "The list of references for the verse."
352
+ })
353
+ }).meta({
354
+ id: "DatasetChapterVerseContent",
355
+ description: "Defines the schema for information about a verse in a dataset chapter."
356
+ });
357
+ const ScoredVerseRefSchema = import_utils.VerseRefSchema.extend({
358
+ score: import_zod.z.number().meta({
359
+ description: "The score for the verse reference. The meaning of the score is arbitrary and is determined by the dataset."
360
+ })
361
+ }).meta({
362
+ id: "ScoredVerseRef",
363
+ description: "Defines the schema for information about a verse reference that has an arbitrary score attached to it."
364
+ });
365
+ const CommentaryProfileSchema = import_zod.z.object({
366
+ /**
367
+ * The ID of the profile.
368
+ */
369
+ id: import_zod.z.string().meta({
370
+ description: "The ID of the profile."
371
+ }),
372
+ /**
373
+ * The subject of the profile.
374
+ */
375
+ subject: import_zod.z.string().meta({
376
+ description: "The subject of the profile."
377
+ }),
378
+ /**
379
+ * The Bible reference that the profile is associated with.
380
+ */
381
+ reference: import_utils.VerseRefSchema.nullable().meta({
382
+ description: "The Bible reference that the profile is associated with. Null if the profile isn't associated with a specific Bible reference."
383
+ })
384
+ });
385
+ const TranslationBookChapterSchema = import_zod.z.object({
386
+ /**
387
+ * The information for the chapter.
388
+ */
389
+ chapter: import_zod.z.lazy(() => ChapterDataSchema).meta({
390
+ description: "The information for the chapter."
391
+ }),
392
+ /**
393
+ * The links to different audio versions for the chapter.
394
+ */
395
+ thisChapterAudioLinks: import_zod.z.lazy(() => TranslationBookChapterAudioLinksSchema).meta({
396
+ description: "The links to different audio versions for the chapter."
397
+ })
398
+ }).meta({
399
+ id: "TranslationBookChapter",
400
+ description: "Defines the schema for information about a book chapter."
401
+ });
402
+ const CommentaryBookChapterSchema = import_zod.z.object({
403
+ /**
404
+ * The information for the chapter.
405
+ */
406
+ chapter: import_zod.z.lazy(() => CommentaryChapterDataSchema).meta({
407
+ description: "The information for the chapter."
408
+ })
409
+ }).meta({
410
+ id: "CommentaryBookChapter",
411
+ description: "Defines the schema for information about a book chapter in a commentary."
412
+ });
413
+ const TranslationBookChapterAudioLinksSchema = import_zod.z.record(import_zod.z.string(), import_zod.z.string()).meta({
414
+ id: "TranslationBookChapterAudioLinks",
415
+ description: "Defines the schema for the audio links for a book chapter."
416
+ });
417
+ const ChapterDataSchema = import_zod.z.object({
418
+ /**
419
+ * The number of the chapter.
420
+ */
421
+ number: import_zod.z.number().meta({
422
+ description: "The number of the chapter."
423
+ }),
424
+ /**
425
+ * The content of the chapter.
426
+ */
427
+ content: import_zod.z.array(import_zod.z.lazy(() => ChapterContentSchema)).meta({
428
+ description: "The content of the chapter."
429
+ }),
430
+ /**
431
+ * The list of footnotes for the chapter.
432
+ */
433
+ footnotes: import_zod.z.array(import_zod.z.lazy(() => ChapterFootnoteSchema)).meta({
434
+ description: "The list of footnotes for the chapter."
435
+ })
436
+ });
437
+ const CommentaryChapterDataSchema = import_zod.z.object({
438
+ /**
439
+ * The number of the chapter.
440
+ */
441
+ number: import_zod.z.number().meta({
442
+ description: "The number of the chapter."
443
+ }),
444
+ /**
445
+ * The introduction that the commentary provided to the chapter.
446
+ * Not all commentaries provide an introduction to a chapter.
447
+ */
448
+ introduction: import_zod.z.string().optional().meta({
449
+ description: "The introduction that the commentary provided to the chapter. Not all commentaries provide an introduction to a chapter."
450
+ }),
451
+ /**
452
+ * The content of the chapter.
453
+ */
454
+ content: import_zod.z.array(import_zod.z.lazy(() => ChapterVerseSchema)).meta({
455
+ description: "The content of the chapter."
456
+ })
457
+ });
458
+ const ChapterHeadingSchema = import_zod.z.object({
459
+ /**
460
+ * Indicates that the content represents a heading.
461
+ */
462
+ type: import_zod.z.literal("heading"),
463
+ /**
464
+ * The content for the heading.
465
+ * If multiple strings are included in the array, they should be concatenated with a space.
466
+ */
467
+ content: import_zod.z.array(import_zod.z.string()).meta({
468
+ description: "The content for the heading. If multiple strings are included in the array, they should be concatenated with a space."
469
+ })
470
+ }).meta({
471
+ id: "ChapterHeading",
472
+ description: "Defines the schema for a heading in a chapter."
473
+ });
474
+ const ChapterLineBreakSchema = import_zod.z.object({
475
+ /**
476
+ * Indicates that the content represents a line break.
477
+ */
478
+ type: import_zod.z.literal("line_break")
479
+ }).meta({
480
+ id: "ChapterLineBreak",
481
+ description: "Defines the schema for a line break in a chapter."
482
+ });
483
+ const ChapterHebrewSubtitleSchema = import_zod.z.object({
484
+ /**
485
+ * Indicates that the content represents a Hebrew Subtitle.
486
+ */
487
+ type: import_zod.z.literal("hebrew_subtitle"),
488
+ /**
489
+ * The list of content that is contained in the subtitle.
490
+ * Each element in the list could be a string, formatted text, or a footnote reference.
491
+ */
492
+ content: import_zod.z.array(import_zod.z.union([
493
+ import_zod.z.string(),
494
+ import_zod.z.lazy(() => FormattedTextSchema),
495
+ import_zod.z.lazy(() => VerseFootnoteReferenceSchema)
496
+ ])).meta({
497
+ description: "The content that is contained in the subtitle. Each element in the list could be a string, formatted text, or a footnote reference."
498
+ })
499
+ }).meta({
500
+ id: "ChapterHebrewSubtitle",
501
+ description: "Defines the schema for a Hebrew Subtitle in a chapter."
502
+ });
503
+ const ChapterVerseSchema = import_zod.z.object({
504
+ /**
505
+ * Indicates that the content is a verse.
506
+ */
507
+ type: import_zod.z.literal("verse"),
508
+ /**
509
+ * The number of the verse.
510
+ */
511
+ number: import_zod.z.number().meta({
512
+ description: "The number of the verse."
513
+ }),
514
+ /**
515
+ * The list of content for the verse.
516
+ * Each element in the list could be a string, formatted text, or a footnote reference.
517
+ */
518
+ content: import_zod.z.array(import_zod.z.union([
519
+ import_zod.z.string(),
520
+ import_zod.z.lazy(() => FormattedTextSchema),
521
+ import_zod.z.lazy(() => InlineHeadingSchema),
522
+ import_zod.z.lazy(() => InlineLineBreakSchema),
523
+ import_zod.z.lazy(() => VerseFootnoteReferenceSchema)
524
+ ])).meta({
525
+ description: "The list of content for the verse. Each element in the list could be a string, formatted text, or a footnote reference."
526
+ })
527
+ }).meta({
528
+ id: "ChapterVerse",
529
+ description: "Defines the schema for a verse in a chapter."
530
+ });
531
+ const ChapterContentSchema = import_zod.z.discriminatedUnion("type", [
532
+ ChapterHeadingSchema,
533
+ ChapterLineBreakSchema,
534
+ ChapterVerseSchema,
535
+ ChapterHebrewSubtitleSchema
536
+ ]).meta({
537
+ id: "ChapterContent",
538
+ description: "Defines a union type that represents a single piece of chapter content. A piece of chapter content can be one of the following things: A heading, a line break, a verse, or a Hebrew Subtitle."
539
+ });
540
+ const FormattedTextSchema = import_zod.z.object({
541
+ /**
542
+ * The text that is formatted.
543
+ */
544
+ text: import_zod.z.string().meta({
545
+ description: "The text that is formatted."
546
+ }),
547
+ /**
548
+ * Whether the text represents a poem.
549
+ * The number indicates the level of indent.
550
+ *
551
+ * Common in Psalms.
552
+ */
553
+ poem: import_zod.z.number().optional().meta({
554
+ description: "Whether the text represents a poem. The number indicates the level of indent. Common in Psalms."
555
+ }),
556
+ /**
557
+ * Whether the text represents the Words of Jesus.
558
+ */
559
+ wordsOfJesus: import_zod.z.boolean().optional().meta({
560
+ description: "Whether the text represents the Words of Jesus."
561
+ })
562
+ }).meta({
563
+ id: "FormattedText",
564
+ description: "Defines the schema for formatted text. That is, text that is formatted in a particular manner."
565
+ });
566
+ const InlineHeadingSchema = import_zod.z.object({
567
+ /**
568
+ * The text of the heading.
569
+ */
570
+ heading: import_zod.z.string().meta({
571
+ description: "The text of the heading."
572
+ })
573
+ }).meta({
574
+ id: "InlineHeading",
575
+ description: "Defines the schema for a heading that is embedded in a verse."
576
+ });
577
+ const InlineLineBreakSchema = import_zod.z.object({
578
+ lineBreak: import_zod.z.literal(true)
579
+ }).meta({
580
+ id: "InlineLineBreak",
581
+ description: "Defines the schema for a line break that is embedded in a verse."
582
+ });
583
+ const VerseFootnoteReferenceSchema = import_zod.z.object({
584
+ /**
585
+ * The ID of the note.
586
+ */
587
+ noteId: import_zod.z.number().meta({
588
+ description: "The ID of the note."
589
+ })
590
+ }).meta({
591
+ id: "VerseFootnoteReference",
592
+ description: "Defines the schema for a footnote reference in a verse or a Hebrew Subtitle."
593
+ });
594
+ const ChapterFootnoteSchema = import_zod.z.object({
595
+ /**
596
+ * The ID of the note that is referenced.
597
+ */
598
+ noteId: import_zod.z.number().meta({
599
+ description: "The ID of the note that is referenced."
600
+ }),
601
+ /**
602
+ * The text of the footnote.
603
+ */
604
+ text: import_zod.z.string().meta({
605
+ description: "The text of the footnote."
606
+ }),
607
+ /**
608
+ * The verse reference for the footnote.
609
+ */
610
+ reference: import_zod.z.object({
611
+ chapter: import_zod.z.number(),
612
+ verse: import_zod.z.number()
613
+ }).optional().meta({
614
+ description: "The verse reference for the footnote. Undefined if the footnote isn't associated with a specific verse."
615
+ }),
616
+ /**
617
+ * The caller that should be used for the footnote.
618
+ * For footnotes, a "caller" is the character that is used in the text to reference to footnote.
619
+ *
620
+ * For example, in the text:
621
+ * Hello (a) World
622
+ *
623
+ * ----
624
+ * (a) This is a footnote.
625
+ *
626
+ * The "(a)" is the caller.
627
+ *
628
+ * If "+", then the caller should be autogenerated.
629
+ * If null, then the caller should be empty.
630
+ * If a string, then the caller should be that string.
631
+ */
632
+ caller: import_zod.z.union([import_zod.z.literal("+"), import_zod.z.string(), import_zod.z.null()]).meta({
633
+ description: 'The caller that should be used for the footnote. For footnotes, a "caller" is the character that is used in the text to reference to footnote. For example, in the text: Hello (a) World ---- (a) This is a footnote. The "(a)" is the caller. If "+", then the caller should be autogenerated. If null, then the caller should be empty. If a string, then the caller should be that string.'
634
+ })
635
+ }).meta({
636
+ id: "ChapterFootnote",
637
+ description: "Defines the schema for information about a footnote."
638
+ });
639
+ // Annotate the CommonJS export names for ESM import in node:
640
+ 0 && (module.exports = {
641
+ ChapterContentSchema,
642
+ ChapterDataSchema,
643
+ ChapterFootnoteSchema,
644
+ ChapterHeadingSchema,
645
+ ChapterHebrewSubtitleSchema,
646
+ ChapterLineBreakSchema,
647
+ ChapterVerseSchema,
648
+ CommentaryBookChapterSchema,
649
+ CommentaryBookSchema,
650
+ CommentaryChapterDataSchema,
651
+ CommentaryProfileSchema,
652
+ CommentarySchema,
653
+ DatasetBookChapterSchema,
654
+ DatasetBookSchema,
655
+ DatasetChapterDataSchema,
656
+ DatasetChapterVerseContentSchema,
657
+ DatasetSchema,
658
+ FormattedTextSchema,
659
+ InlineHeadingSchema,
660
+ InlineLineBreakSchema,
661
+ ScoredVerseRefSchema,
662
+ TranslationBookChapterAudioLinksSchema,
663
+ TranslationBookChapterSchema,
664
+ TranslationBookSchema,
665
+ TranslationSchema,
666
+ VerseFootnoteReferenceSchema
667
+ });
17
668
  //# sourceMappingURL=common-types.cjs.map