@hebcal/leyning 4.18.0 → 4.19.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.
package/README.md CHANGED
@@ -106,10 +106,17 @@ of full kriyah aliyot, special Maftir, special Haftarah</p>
106
106
  <dd><p>Looks up regular leyning for a weekly parsha with no special readings</p>
107
107
  </dd>
108
108
  <dt><a href="#getLeyningForParshaHaShavua">getLeyningForParshaHaShavua(ev, [il])</a> ⇒ <code><a href="#Leyning">Leyning</a></code></dt>
109
- <dd><p>Looks up leyning for a regular Shabbat parsha.</p>
109
+ <dd><p>Looks up leyning for a regular Shabbat parsha, including any special
110
+ maftir or Haftara.</p>
110
111
  </dd>
111
112
  <dt><a href="#getLeyningOnDate">getLeyningOnDate(hdate, il)</a> ⇒ <code><a href="#Leyning">Leyning</a></code></dt>
112
- <dd><p>Looks up leyning for a regular Shabbat or holiday</p>
113
+ <dd><p>Looks up leyning for a regular Shabbat, Monday/Thursday weekday or holiday.</p>
114
+ <p>If <code>hdate</code> coincides with a holiday that has Torah reading, returns the
115
+ reading for that day (see <a href="#getLeyningForHoliday">getLeyningForHoliday</a>)</p>
116
+ <p>Otherwise, if <code>hdate</code> is a Saturday, returns <a href="#getLeyningForParshaHaShavua">getLeyningForParshaHaShavua</a></p>
117
+ <p>Otherwise, if <code>hdate</code> is a Monday or Thursday, returns <a href="#Leyning">Leyning</a> for the
118
+ Parashat haShavua, containing only the <code>weekday</code> aliyot (no <code>fullkriyah</code>).</p>
119
+ <p>Otherwise, returns <code>undefined</code>.</p>
113
120
  </dd>
114
121
  <dt><a href="#getTriennial">getTriennial(year)</a> ⇒ <code><a href="#Triennial">Triennial</a></code></dt>
115
122
  <dd><p>Calculates the 3-year readings for a given year</p>
@@ -128,6 +135,9 @@ of full kriyah aliyot, special Maftir, special Haftarah</p>
128
135
  <dt><a href="#Aliyah">Aliyah</a> : <code>Object</code></dt>
129
136
  <dd><p>Represents an aliyah</p>
130
137
  </dd>
138
+ <dt><a href="#LeyningNames">LeyningNames</a> : <code>Object</code></dt>
139
+ <dd><p>Name of the parsha hashavua or holiday</p>
140
+ </dd>
131
141
  <dt><a href="#Leyning">Leyning</a> : <code>Object</code></dt>
132
142
  <dd><p>Leyning for a parsha hashavua or holiday</p>
133
143
  </dd>
@@ -320,7 +330,8 @@ Looks up regular leyning for a weekly parsha with no special readings
320
330
  <a name="getLeyningForParshaHaShavua"></a>
321
331
 
322
332
  ## getLeyningForParshaHaShavua(ev, [il]) ⇒ [<code>Leyning</code>](#Leyning)
323
- Looks up leyning for a regular Shabbat parsha.
333
+ Looks up leyning for a regular Shabbat parsha, including any special
334
+ maftir or Haftara.
324
335
 
325
336
  **Kind**: global function
326
337
  **Returns**: [<code>Leyning</code>](#Leyning) - map of aliyot
@@ -333,7 +344,17 @@ Looks up leyning for a regular Shabbat parsha.
333
344
  <a name="getLeyningOnDate"></a>
334
345
 
335
346
  ## getLeyningOnDate(hdate, il) ⇒ [<code>Leyning</code>](#Leyning)
336
- Looks up leyning for a regular Shabbat or holiday
347
+ Looks up leyning for a regular Shabbat, Monday/Thursday weekday or holiday.
348
+
349
+ If `hdate` coincides with a holiday that has Torah reading, returns the
350
+ reading for that day (see [getLeyningForHoliday](#getLeyningForHoliday))
351
+
352
+ Otherwise, if `hdate` is a Saturday, returns [getLeyningForParshaHaShavua](#getLeyningForParshaHaShavua)
353
+
354
+ Otherwise, if `hdate` is a Monday or Thursday, returns [Leyning](#Leyning) for the
355
+ Parashat haShavua, containing only the `weekday` aliyot (no `fullkriyah`).
356
+
357
+ Otherwise, returns `undefined`.
337
358
 
338
359
  **Kind**: global function
339
360
  **Returns**: [<code>Leyning</code>](#Leyning) - map of aliyot
@@ -395,6 +416,19 @@ Represents an aliyah
395
416
  | [v] | <code>number</code> | number of verses |
396
417
  | [p] | <code>number</code> | parsha number (1=Bereshit, 54=Vezot HaBracha) |
397
418
 
419
+ <a name="LeyningNames"></a>
420
+
421
+ ## LeyningNames : <code>Object</code>
422
+ Name of the parsha hashavua or holiday
423
+
424
+ **Kind**: global typedef
425
+ **Properties**
426
+
427
+ | Name | Type | Description |
428
+ | --- | --- | --- |
429
+ | en | <code>string</code> | English |
430
+ | he | <code>string</code> | Hebrew (with nikud) |
431
+
398
432
  <a name="Leyning"></a>
399
433
 
400
434
  ## Leyning : <code>Object</code>
@@ -405,16 +439,19 @@ Leyning for a parsha hashavua or holiday
405
439
 
406
440
  | Name | Type | Description |
407
441
  | --- | --- | --- |
408
- | summary | <code>string</code> | |
409
- | haft | [<code>Aliyah</code>](#Aliyah) | Haftarah |
410
- | haftara | <code>string</code> | Haftarah |
411
- | [haftaraNumV] | <code>number</code> | |
412
- | [seph] | [<code>Aliyah</code>](#Aliyah) | Haftarah for Sephardic |
413
- | [sephardic] | <code>string</code> | Haftarah for Sephardic |
414
- | [sephardicNumV] | <code>number</code> | |
415
- | fullkriyah | <code>Object.&lt;string, Aliyah&gt;</code> | |
416
- | [weekday] | <code>Object.&lt;string, Aliyah&gt;</code> | |
417
- | [reason] | <code>Object</code> | |
442
+ | name | [<code>LeyningNames</code>](#LeyningNames) | |
443
+ | [parsha] | <code>Array.&lt;string&gt;</code> | An array of either 1 (regular) or 2 (doubled parsha). `undefined` for holiday readings |
444
+ | [parshaNum] | <code>num</code> | 1 for Bereshit, 2 for Noach, etc. `undefined` for holiday readings |
445
+ | summary | <code>string</code> | Such as `Genesis 1:1 - 6:8` |
446
+ | haft | [<code>Aliyah</code>](#Aliyah) \| [<code>Array.&lt;Aliyah&gt;</code>](#Aliyah) | Haftarah object(s) |
447
+ | haftara | <code>string</code> | Haftarah, such as `Isaiah 42:5 – 43:11` |
448
+ | [haftaraNumV] | <code>number</code> | Number of verses in the Haftarah |
449
+ | [seph] | [<code>Aliyah</code>](#Aliyah) \| [<code>Array.&lt;Aliyah&gt;</code>](#Aliyah) | Haftarah object(s) for Sephardim |
450
+ | [sephardic] | <code>string</code> | Haftarah for Sephardim, such as `Isaiah 42:5 - 42:21` |
451
+ | [sephardicNumV] | <code>number</code> | Number of verses in the Haftarah for Sephardim |
452
+ | fullkriyah | <code>Object.&lt;string, Aliyah&gt;</code> | Map of aliyot `1` through `7` plus `M` for maftir |
453
+ | [weekday] | <code>Object.&lt;string, Aliyah&gt;</code> | Optional map of weekday Torah Readings aliyot `1` through `3` for Monday and Thursday |
454
+ | [reason] | <code>Object</code> | Explanations for special readings, keyed by aliyah number, `M` for maftir or `haftara` for Haftarah |
418
455
 
419
456
  <a name="TriennialAliyot"></a>
420
457