@hebcal/core 5.7.4 → 5.7.5
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/dist/bundle.js +84 -219
- package/dist/bundle.js.map +1 -1
- package/dist/bundle.min.js +2 -2
- package/dist/bundle.min.js.map +1 -1
- package/dist/esm/DailyLearning.js +1 -1
- package/dist/esm/HebrewDateEvent.js +1 -1
- package/dist/esm/HolidayEvent.js +1 -1
- package/dist/esm/MevarchimChodeshEvent.js +1 -1
- package/dist/esm/ParshaEvent.js +1 -1
- package/dist/esm/TimedEvent.js +1 -1
- package/dist/esm/YomKippurKatanEvent.js +1 -1
- package/dist/esm/ashkenazi.po.js +1 -1
- package/dist/esm/calendar.js +1 -1
- package/dist/esm/candles.js +1 -1
- package/dist/esm/event.js +1 -1
- package/dist/esm/getStartAndEnd.js +1 -1
- package/dist/esm/hallel.js +1 -1
- package/dist/esm/he.po.js +1 -1
- package/dist/esm/hebcal.js +1 -1
- package/dist/esm/holidays.js +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/locale.js +1 -1
- package/dist/esm/location.js +1 -1
- package/dist/esm/modern.js +1 -1
- package/dist/esm/molad.js +1 -1
- package/dist/esm/omer.js +1 -1
- package/dist/esm/parshaName.js +1 -1
- package/dist/esm/pkgVersion.d.ts +1 -1
- package/dist/esm/pkgVersion.js +2 -2
- package/dist/esm/pkgVersion.js.map +1 -1
- package/dist/esm/reformatTimeStr.js +1 -1
- package/dist/esm/sedra.js +1 -1
- package/dist/esm/staticHolidays.js +1 -1
- package/dist/esm/tachanun.js +1 -1
- package/dist/esm/zmanim.js +1 -1
- package/dist/index.cjs +82 -236
- package/dist/index.cjs.map +1 -1
- package/dist/pkgVersion.d.ts +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @hebcal/core v5.7.
|
|
1
|
+
/*! @hebcal/core v5.7.5 */
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
4
|
var hdate = require('@hebcal/hdate');
|
|
@@ -6,7 +6,7 @@ var noaa = require('@hebcal/noaa');
|
|
|
6
6
|
require('temporal-polyfill/global');
|
|
7
7
|
|
|
8
8
|
/** DO NOT EDIT THIS AUTO-GENERATED FILE! */
|
|
9
|
-
const version = '5.7.
|
|
9
|
+
const version = '5.7.5';
|
|
10
10
|
|
|
11
11
|
var poAshkenazi = { "headers": { "plural-forms": "nplurals=2; plural=(n > 1);" }, "contexts": { "": { "Shabbat": ["Shabbos"], "Achrei Mot": ["Achrei Mos"], "Bechukotai": ["Bechukosai"], "Beha'alotcha": ["Beha’aloscha"], "Bereshit": ["Bereshis"], "Chukat": ["Chukas"], "Erev Shavuot": ["Erev Shavuos"], "Erev Sukkot": ["Erev Sukkos"], "Ki Tavo": ["Ki Savo"], "Ki Teitzei": ["Ki Seitzei"], "Ki Tisa": ["Ki Sisa"], "Matot": ["Matos"], "Purim Katan": ["Purim Koton"], "Shabbat Chazon": ["Shabbos Chazon"], "Shabbat HaChodesh": ["Shabbos HaChodesh"], "Shabbat HaGadol": ["Shabbos HaGadol"], "Shabbat Nachamu": ["Shabbos Nachamu"], "Shabbat Parah": ["Shabbos Parah"], "Shabbat Shekalim": ["Shabbos Shekalim"], "Shabbat Shuva": ["Shabbos Shuvah"], "Shabbat Zachor": ["Shabbos Zachor"], "Shavuot": ["Shavuos"], "Shavuot I": ["Shavuos I"], "Shavuot II": ["Shavuos II"], "Shemot": ["Shemos"], "Shmini Atzeret": ["Shmini Atzeres"], "Simchat Torah": ["Simchas Torah"], "Sukkot": ["Sukkos"], "Sukkot I": ["Sukkos I"], "Sukkot II": ["Sukkos II"], "Sukkot II (CH''M)": ["Sukkos II (CH’’M)"], "Sukkot III (CH''M)": ["Sukkos III (CH’’M)"], "Sukkot IV (CH''M)": ["Sukkos IV (CH’’M)"], "Sukkot V (CH''M)": ["Sukkos V (CH’’M)"], "Sukkot VI (CH''M)": ["Sukkos VI (CH’’M)"], "Sukkot VII (Hoshana Raba)": ["Sukkos VII (Hoshana Raba)"], "Ta'anit Bechorot": ["Ta’anis Bechoros"], "Ta'anit Esther": ["Ta’anis Esther"], "Toldot": ["Toldos"], "Vaetchanan": ["Vaeschanan"], "Yitro": ["Yisro"], "Vezot Haberakhah": ["Vezos Haberakhah"], "Parashat": ["Parshas"], "Leil Selichot": ["Leil Selichos"], "Shabbat Mevarchim Chodesh": ["Shabbos Mevorchim Chodesh"], "Shabbat Shirah": ["Shabbos Shirah"], "Asara B'Tevet": ["Asara B’Teves"], "Alot HaShachar": ["Alos HaShachar"], "Kriat Shema, sof zeman": ["Krias Shema, sof zman"], "Tefilah, sof zeman": ["Tefilah, sof zman"], "Kriat Shema, sof zeman (MGA)": ["Krias Shema, sof zman (MGA)"], "Tefilah, sof zeman (MGA)": ["Tefilah, sof zman (MGA)"], "Chatzot HaLailah": ["Chatzos HaLailah"], "Chatzot hayom": ["Chatzos"], "Tzeit HaKochavim": ["Tzeis HaKochavim"], "Birkat Hachamah": ["Birkas Hachamah"], "Shushan Purim Katan": ["Shushan Purim Koton"] } } };
|
|
12
12
|
|
|
@@ -2496,290 +2496,136 @@ function renderParshaName(parsha, locale) {
|
|
|
2496
2496
|
return str.normalize();
|
|
2497
2497
|
}
|
|
2498
2498
|
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
if (!(options.maxSize && options.maxSize > 0)) {
|
|
2504
|
-
throw new TypeError('`maxSize` must be a number greater than 0');
|
|
2505
|
-
}
|
|
2506
|
-
|
|
2507
|
-
if (typeof options.maxAge === 'number' && options.maxAge === 0) {
|
|
2508
|
-
throw new TypeError('`maxAge` must be a number greater than 0');
|
|
2509
|
-
}
|
|
2510
|
-
|
|
2511
|
-
// TODO: Use private class fields when ESLint supports them.
|
|
2512
|
-
this.maxSize = options.maxSize;
|
|
2513
|
-
this.maxAge = options.maxAge || Number.POSITIVE_INFINITY;
|
|
2514
|
-
this.onEviction = options.onEviction;
|
|
2515
|
-
this.cache = new Map();
|
|
2516
|
-
this.oldCache = new Map();
|
|
2517
|
-
this._size = 0;
|
|
2518
|
-
}
|
|
2499
|
+
function getDefaultExportFromCjs (x) {
|
|
2500
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
2501
|
+
}
|
|
2519
2502
|
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
if (typeof this.onEviction !== 'function') {
|
|
2523
|
-
return;
|
|
2524
|
-
}
|
|
2503
|
+
var quickLru;
|
|
2504
|
+
var hasRequiredQuickLru;
|
|
2525
2505
|
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
}
|
|
2506
|
+
function requireQuickLru () {
|
|
2507
|
+
if (hasRequiredQuickLru) return quickLru;
|
|
2508
|
+
hasRequiredQuickLru = 1;
|
|
2530
2509
|
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
if (
|
|
2534
|
-
|
|
2510
|
+
class QuickLRU {
|
|
2511
|
+
constructor(options = {}) {
|
|
2512
|
+
if (!(options.maxSize && options.maxSize > 0)) {
|
|
2513
|
+
throw new TypeError('`maxSize` must be a number greater than 0');
|
|
2535
2514
|
}
|
|
2536
2515
|
|
|
2537
|
-
|
|
2538
|
-
}
|
|
2539
|
-
|
|
2540
|
-
return false;
|
|
2541
|
-
}
|
|
2542
|
-
|
|
2543
|
-
_getOrDeleteIfExpired(key, item) {
|
|
2544
|
-
const deleted = this._deleteIfExpired(key, item);
|
|
2545
|
-
if (deleted === false) {
|
|
2546
|
-
return item.value;
|
|
2547
|
-
}
|
|
2548
|
-
}
|
|
2549
|
-
|
|
2550
|
-
_getItemValue(key, item) {
|
|
2551
|
-
return item.expiry ? this._getOrDeleteIfExpired(key, item) : item.value;
|
|
2552
|
-
}
|
|
2553
|
-
|
|
2554
|
-
_peek(key, cache) {
|
|
2555
|
-
const item = cache.get(key);
|
|
2556
|
-
|
|
2557
|
-
return this._getItemValue(key, item);
|
|
2558
|
-
}
|
|
2559
|
-
|
|
2560
|
-
_set(key, value) {
|
|
2561
|
-
this.cache.set(key, value);
|
|
2562
|
-
this._size++;
|
|
2563
|
-
|
|
2564
|
-
if (this._size >= this.maxSize) {
|
|
2565
|
-
this._size = 0;
|
|
2566
|
-
this._emitEvictions(this.oldCache);
|
|
2567
|
-
this.oldCache = this.cache;
|
|
2516
|
+
this.maxSize = options.maxSize;
|
|
2568
2517
|
this.cache = new Map();
|
|
2518
|
+
this.oldCache = new Map();
|
|
2519
|
+
this._size = 0;
|
|
2569
2520
|
}
|
|
2570
|
-
}
|
|
2571
2521
|
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
|
|
2575
|
-
}
|
|
2522
|
+
_set(key, value) {
|
|
2523
|
+
this.cache.set(key, value);
|
|
2524
|
+
this._size++;
|
|
2576
2525
|
|
|
2577
|
-
|
|
2578
|
-
|
|
2579
|
-
|
|
2580
|
-
|
|
2581
|
-
const deleted = this._deleteIfExpired(key, value);
|
|
2582
|
-
if (deleted === false) {
|
|
2583
|
-
yield item;
|
|
2584
|
-
}
|
|
2526
|
+
if (this._size >= this.maxSize) {
|
|
2527
|
+
this._size = 0;
|
|
2528
|
+
this.oldCache = this.cache;
|
|
2529
|
+
this.cache = new Map();
|
|
2585
2530
|
}
|
|
2586
2531
|
}
|
|
2587
2532
|
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
if (deleted === false) {
|
|
2592
|
-
yield item;
|
|
2533
|
+
get(key) {
|
|
2534
|
+
if (this.cache.has(key)) {
|
|
2535
|
+
return this.cache.get(key);
|
|
2593
2536
|
}
|
|
2594
|
-
}
|
|
2595
|
-
}
|
|
2596
|
-
|
|
2597
|
-
get(key) {
|
|
2598
|
-
if (this.cache.has(key)) {
|
|
2599
|
-
const item = this.cache.get(key);
|
|
2600
2537
|
|
|
2601
|
-
|
|
2602
|
-
|
|
2603
|
-
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
if (this._deleteIfExpired(key, item) === false) {
|
|
2607
|
-
this._moveToRecent(key, item);
|
|
2608
|
-
return item.value;
|
|
2538
|
+
if (this.oldCache.has(key)) {
|
|
2539
|
+
const value = this.oldCache.get(key);
|
|
2540
|
+
this.oldCache.delete(key);
|
|
2541
|
+
this._set(key, value);
|
|
2542
|
+
return value;
|
|
2609
2543
|
}
|
|
2610
2544
|
}
|
|
2611
|
-
}
|
|
2612
|
-
|
|
2613
|
-
set(key, value, {maxAge = this.maxAge} = {}) {
|
|
2614
|
-
const expiry =
|
|
2615
|
-
typeof maxAge === 'number' && maxAge !== Number.POSITIVE_INFINITY ?
|
|
2616
|
-
Date.now() + maxAge :
|
|
2617
|
-
undefined;
|
|
2618
|
-
if (this.cache.has(key)) {
|
|
2619
|
-
this.cache.set(key, {
|
|
2620
|
-
value,
|
|
2621
|
-
expiry
|
|
2622
|
-
});
|
|
2623
|
-
} else {
|
|
2624
|
-
this._set(key, {value, expiry});
|
|
2625
|
-
}
|
|
2626
|
-
|
|
2627
|
-
return this;
|
|
2628
|
-
}
|
|
2629
|
-
|
|
2630
|
-
has(key) {
|
|
2631
|
-
if (this.cache.has(key)) {
|
|
2632
|
-
return !this._deleteIfExpired(key, this.cache.get(key));
|
|
2633
|
-
}
|
|
2634
|
-
|
|
2635
|
-
if (this.oldCache.has(key)) {
|
|
2636
|
-
return !this._deleteIfExpired(key, this.oldCache.get(key));
|
|
2637
|
-
}
|
|
2638
2545
|
|
|
2639
|
-
|
|
2640
|
-
|
|
2641
|
-
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
}
|
|
2546
|
+
set(key, value) {
|
|
2547
|
+
if (this.cache.has(key)) {
|
|
2548
|
+
this.cache.set(key, value);
|
|
2549
|
+
} else {
|
|
2550
|
+
this._set(key, value);
|
|
2551
|
+
}
|
|
2646
2552
|
|
|
2647
|
-
|
|
2648
|
-
return this._peek(key, this.oldCache);
|
|
2553
|
+
return this;
|
|
2649
2554
|
}
|
|
2650
|
-
}
|
|
2651
2555
|
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
if (deleted) {
|
|
2655
|
-
this._size--;
|
|
2556
|
+
has(key) {
|
|
2557
|
+
return this.cache.has(key) || this.oldCache.has(key);
|
|
2656
2558
|
}
|
|
2657
2559
|
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2661
|
-
clear() {
|
|
2662
|
-
this.cache.clear();
|
|
2663
|
-
this.oldCache.clear();
|
|
2664
|
-
this._size = 0;
|
|
2665
|
-
}
|
|
2666
|
-
|
|
2667
|
-
resize(newSize) {
|
|
2668
|
-
if (!(newSize && newSize > 0)) {
|
|
2669
|
-
throw new TypeError('`maxSize` must be a number greater than 0');
|
|
2670
|
-
}
|
|
2671
|
-
|
|
2672
|
-
const items = [...this._entriesAscending()];
|
|
2673
|
-
const removeCount = items.length - newSize;
|
|
2674
|
-
if (removeCount < 0) {
|
|
2675
|
-
this.cache = new Map(items);
|
|
2676
|
-
this.oldCache = new Map();
|
|
2677
|
-
this._size = items.length;
|
|
2678
|
-
} else {
|
|
2679
|
-
if (removeCount > 0) {
|
|
2680
|
-
this._emitEvictions(items.slice(0, removeCount));
|
|
2560
|
+
peek(key) {
|
|
2561
|
+
if (this.cache.has(key)) {
|
|
2562
|
+
return this.cache.get(key);
|
|
2681
2563
|
}
|
|
2682
2564
|
|
|
2683
|
-
this.oldCache
|
|
2684
|
-
|
|
2685
|
-
|
|
2565
|
+
if (this.oldCache.has(key)) {
|
|
2566
|
+
return this.oldCache.get(key);
|
|
2567
|
+
}
|
|
2686
2568
|
}
|
|
2687
2569
|
|
|
2688
|
-
|
|
2689
|
-
|
|
2570
|
+
delete(key) {
|
|
2571
|
+
const deleted = this.cache.delete(key);
|
|
2572
|
+
if (deleted) {
|
|
2573
|
+
this._size--;
|
|
2574
|
+
}
|
|
2690
2575
|
|
|
2691
|
-
|
|
2692
|
-
for (const [key] of this) {
|
|
2693
|
-
yield key;
|
|
2576
|
+
return this.oldCache.delete(key) || deleted;
|
|
2694
2577
|
}
|
|
2695
|
-
}
|
|
2696
2578
|
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2579
|
+
clear() {
|
|
2580
|
+
this.cache.clear();
|
|
2581
|
+
this.oldCache.clear();
|
|
2582
|
+
this._size = 0;
|
|
2700
2583
|
}
|
|
2701
|
-
}
|
|
2702
2584
|
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
const deleted = this._deleteIfExpired(key, value);
|
|
2707
|
-
if (deleted === false) {
|
|
2708
|
-
yield [key, value.value];
|
|
2585
|
+
* keys() {
|
|
2586
|
+
for (const [key] of this) {
|
|
2587
|
+
yield key;
|
|
2709
2588
|
}
|
|
2710
2589
|
}
|
|
2711
2590
|
|
|
2712
|
-
|
|
2713
|
-
const [
|
|
2714
|
-
|
|
2715
|
-
const deleted = this._deleteIfExpired(key, value);
|
|
2716
|
-
if (deleted === false) {
|
|
2717
|
-
yield [key, value.value];
|
|
2718
|
-
}
|
|
2591
|
+
* values() {
|
|
2592
|
+
for (const [, value] of this) {
|
|
2593
|
+
yield value;
|
|
2719
2594
|
}
|
|
2720
2595
|
}
|
|
2721
|
-
}
|
|
2722
2596
|
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
const item = items[i];
|
|
2727
|
-
const [key, value] = item;
|
|
2728
|
-
const deleted = this._deleteIfExpired(key, value);
|
|
2729
|
-
if (deleted === false) {
|
|
2730
|
-
yield [key, value.value];
|
|
2597
|
+
* [Symbol.iterator]() {
|
|
2598
|
+
for (const item of this.cache) {
|
|
2599
|
+
yield item;
|
|
2731
2600
|
}
|
|
2732
|
-
}
|
|
2733
2601
|
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
if (!this.cache.has(key)) {
|
|
2739
|
-
const deleted = this._deleteIfExpired(key, value);
|
|
2740
|
-
if (deleted === false) {
|
|
2741
|
-
yield [key, value.value];
|
|
2602
|
+
for (const item of this.oldCache) {
|
|
2603
|
+
const [key] = item;
|
|
2604
|
+
if (!this.cache.has(key)) {
|
|
2605
|
+
yield item;
|
|
2742
2606
|
}
|
|
2743
2607
|
}
|
|
2744
2608
|
}
|
|
2745
|
-
}
|
|
2746
|
-
|
|
2747
|
-
* entriesAscending() {
|
|
2748
|
-
for (const [key, value] of this._entriesAscending()) {
|
|
2749
|
-
yield [key, value.value];
|
|
2750
|
-
}
|
|
2751
|
-
}
|
|
2752
2609
|
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
for (const key of this.oldCache.keys()) {
|
|
2760
|
-
if (!this.cache.has(key)) {
|
|
2761
|
-
oldCacheSize++;
|
|
2610
|
+
get size() {
|
|
2611
|
+
let oldCacheSize = 0;
|
|
2612
|
+
for (const key of this.oldCache.keys()) {
|
|
2613
|
+
if (!this.cache.has(key)) {
|
|
2614
|
+
oldCacheSize++;
|
|
2615
|
+
}
|
|
2762
2616
|
}
|
|
2763
|
-
}
|
|
2764
|
-
|
|
2765
|
-
return Math.min(this._size + oldCacheSize, this.maxSize);
|
|
2766
|
-
}
|
|
2767
|
-
|
|
2768
|
-
entries() {
|
|
2769
|
-
return this.entriesAscending();
|
|
2770
|
-
}
|
|
2771
2617
|
|
|
2772
|
-
|
|
2773
|
-
for (const [key, value] of this.entriesAscending()) {
|
|
2774
|
-
callbackFunction.call(thisArgument, value, key, this);
|
|
2618
|
+
return this._size + oldCacheSize;
|
|
2775
2619
|
}
|
|
2776
2620
|
}
|
|
2777
2621
|
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
}
|
|
2622
|
+
quickLru = QuickLRU;
|
|
2623
|
+
return quickLru;
|
|
2781
2624
|
}
|
|
2782
2625
|
|
|
2626
|
+
var quickLruExports = requireQuickLru();
|
|
2627
|
+
var QuickLRU = /*@__PURE__*/getDefaultExportFromCjs(quickLruExports);
|
|
2628
|
+
|
|
2783
2629
|
/*
|
|
2784
2630
|
Hebcal - A Jewish Calendar Generator
|
|
2785
2631
|
Copyright (c) 1994-2020 Danny Sadinoff
|