@hebcal/core 3.33.6 → 3.34.1

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/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v3.33.6 */
1
+ /*! @hebcal/core v3.34.1 */
2
2
  /*
3
3
  Hebcal - A Jewish Calendar Generator
4
4
  Copyright (c) 1994-2020 Danny Sadinoff
@@ -2018,18 +2018,12 @@ class HebrewDateEvent extends Event {
2018
2018
 
2019
2019
  }
2020
2020
 
2021
- var sun = {};
2022
-
2023
- Object.defineProperty(sun, "__esModule", {
2024
- value: true
2025
- });
2026
- var Sun_1 = sun.Sun = void 0;
2027
-
2028
2021
  class Sun {
2029
2022
  constructor(date, latitude, longitude) {
2030
2023
  this.date = date;
2031
2024
  this.latitude = latitude;
2032
2025
  this.longitude = longitude;
2026
+
2033
2027
  this.julianDate = getJD(date);
2034
2028
  }
2035
2029
 
@@ -2040,11 +2034,8 @@ class Sun {
2040
2034
  timeAtAngle(angle, rising) {
2041
2035
  return calcSunriseSet(rising, angle, this.julianDate, this.date, this.latitude, this.longitude);
2042
2036
  }
2043
-
2044
2037
  }
2045
2038
 
2046
- Sun_1 = sun.Sun = Sun;
2047
-
2048
2039
  function formatDate(date, minutes) {
2049
2040
  const seconds = (minutes - Math.floor(minutes)) * 60;
2050
2041
  return new Date(Date.UTC(date.getFullYear(), date.getMonth(), date.getDate(), 0, minutes, seconds));
@@ -2056,24 +2047,21 @@ function calcTimeJulianCent(jd) {
2056
2047
  }
2057
2048
 
2058
2049
  function radToDeg(angleRad) {
2059
- return 180.0 * angleRad / Math.PI;
2050
+ return (180.0 * angleRad / Math.PI);
2060
2051
  }
2061
2052
 
2062
2053
  function degToRad(angleDeg) {
2063
- return Math.PI * angleDeg / 180.0;
2054
+ return (Math.PI * angleDeg / 180.0);
2064
2055
  }
2065
2056
 
2066
2057
  function calcGeomMeanLongSun(t) {
2067
- let L0 = 280.46646 + t * (36000.76983 + t * 0.0003032);
2068
-
2058
+ let L0 = 280.46646 + t * (36000.76983 + t * (0.0003032));
2069
2059
  while (L0 > 360.0) {
2070
2060
  L0 -= 360.0;
2071
2061
  }
2072
-
2073
2062
  while (L0 < 0.0) {
2074
2063
  L0 += 360.0;
2075
2064
  }
2076
-
2077
2065
  return L0; // in degrees
2078
2066
  }
2079
2067
 
@@ -2112,8 +2100,8 @@ function calcSunApparentLong(t) {
2112
2100
  }
2113
2101
 
2114
2102
  function calcMeanObliquityOfEcliptic(t) {
2115
- const seconds = 21.448 - t * (46.8150 + t * (0.00059 - t * 0.001813));
2116
- const e0 = 23.0 + (26.0 + seconds / 60.0) / 60.0;
2103
+ const seconds = 21.448 - t * (46.8150 + t * (0.00059 - t * (0.001813)));
2104
+ const e0 = 23.0 + (26.0 + (seconds / 60.0)) / 60.0;
2117
2105
  return e0; // in degrees
2118
2106
  }
2119
2107
 
@@ -2127,6 +2115,7 @@ function calcObliquityCorrection(t) {
2127
2115
  function calcSunDeclination(t) {
2128
2116
  const e = calcObliquityCorrection(t);
2129
2117
  const lambda = calcSunApparentLong(t);
2118
+
2130
2119
  const sint = Math.sin(degToRad(e)) * Math.sin(degToRad(lambda));
2131
2120
  const theta = radToDeg(Math.asin(sint));
2132
2121
  return theta; // in degrees
@@ -2137,13 +2126,16 @@ function calcEquationOfTime(t) {
2137
2126
  const l0 = calcGeomMeanLongSun(t);
2138
2127
  const e = calcEccentricityEarthOrbit(t);
2139
2128
  const m = calcGeomMeanAnomalySun(t);
2129
+
2140
2130
  let y = Math.tan(degToRad(epsilon) / 2.0);
2141
2131
  y *= y;
2132
+
2142
2133
  const sin2l0 = Math.sin(2.0 * degToRad(l0));
2143
2134
  const sinm = Math.sin(degToRad(m));
2144
2135
  const cos2l0 = Math.cos(2.0 * degToRad(l0));
2145
2136
  const sin4l0 = Math.sin(4.0 * degToRad(l0));
2146
2137
  const sin2m = Math.sin(2.0 * degToRad(m));
2138
+
2147
2139
  const Etime = y * sin2l0 - 2.0 * e * sinm + 4.0 * e * y * sinm * cos2l0 - 0.5 * y * y * sin4l0 - 1.25 * e * e * sin2m;
2148
2140
  return radToDeg(Etime) * 4.0; // in minutes of time
2149
2141
  }
@@ -2151,7 +2143,7 @@ function calcEquationOfTime(t) {
2151
2143
  function calcHourAngle(angle, lat, solarDec) {
2152
2144
  const latRad = degToRad(lat);
2153
2145
  const sdRad = degToRad(solarDec);
2154
- const HAarg = Math.cos(degToRad(90 + angle)) / (Math.cos(latRad) * Math.cos(sdRad)) - Math.tan(latRad) * Math.tan(sdRad);
2146
+ const HAarg = (Math.cos(degToRad(90 + angle)) / (Math.cos(latRad) * Math.cos(sdRad)) - Math.tan(latRad) * Math.tan(sdRad));
2155
2147
  const HA = Math.acos(HAarg);
2156
2148
  return HA; // in radians (for sunset, use -HA)
2157
2149
  }
@@ -2159,24 +2151,19 @@ function calcHourAngle(angle, lat, solarDec) {
2159
2151
  function isNumber(inputVal) {
2160
2152
  let oneDecimal = false;
2161
2153
  const inputStr = `${inputVal}`;
2162
-
2163
2154
  for (let i = 0; i < inputStr.length; i++) {
2164
2155
  const oneChar = inputStr.charAt(i);
2165
-
2166
2156
  if (i === 0 && (oneChar === '-' || oneChar === '+')) {
2167
2157
  continue;
2168
2158
  }
2169
-
2170
2159
  if (oneChar === '.' && !oneDecimal) {
2171
2160
  oneDecimal = true;
2172
2161
  continue;
2173
2162
  }
2174
-
2175
2163
  if (oneChar < '0' || oneChar > '9') {
2176
2164
  return false;
2177
2165
  }
2178
2166
  }
2179
-
2180
2167
  return true;
2181
2168
  }
2182
2169
 
@@ -2184,7 +2171,6 @@ function getJD(date) {
2184
2171
  let year = date.getFullYear();
2185
2172
  let month = date.getMonth() + 1;
2186
2173
  const day = date.getDate();
2187
-
2188
2174
  if (month < 3) {
2189
2175
  year--;
2190
2176
  month += 12;
@@ -2199,46 +2185,130 @@ function getJD(date) {
2199
2185
  function calcSolNoon(jd, longitude, date) {
2200
2186
  const tnoon = calcTimeJulianCent(jd - longitude / 360.0);
2201
2187
  let eqTime = calcEquationOfTime(tnoon);
2202
- const solNoonOffset = 720.0 - longitude * 4 - eqTime; // in minutes
2203
-
2188
+ const solNoonOffset = 720.0 - (longitude * 4) - eqTime; // in minutes
2204
2189
  const newt = calcTimeJulianCent(jd + solNoonOffset / 1440.0);
2205
2190
  eqTime = calcEquationOfTime(newt);
2206
- let solNoonLocal = 720 - longitude * 4 - eqTime; // in minutes
2207
-
2191
+ let solNoonLocal = 720 - (longitude * 4) - eqTime; // in minutes
2208
2192
  while (solNoonLocal < 0.0) {
2209
2193
  solNoonLocal += 1440.0;
2210
2194
  }
2211
-
2212
2195
  while (solNoonLocal >= 1440.0) {
2213
2196
  solNoonLocal -= 1440.0;
2214
2197
  }
2215
-
2216
- return formatDate(date, solNoonLocal); // return timeString(solNoonLocal, 3);
2198
+ return formatDate(date, solNoonLocal);
2199
+ // return timeString(solNoonLocal, 3);
2217
2200
  }
2218
2201
 
2219
2202
  function calcSunriseSetUTC(rise, angle, JD, latitude, longitude) {
2220
2203
  const t = calcTimeJulianCent(JD);
2221
2204
  const eqTime = calcEquationOfTime(t);
2222
2205
  const solarDec = calcSunDeclination(t);
2223
- let hourAngle = calcHourAngle(angle, latitude, solarDec); //alert("HA = " + radToDeg(hourAngle));
2224
-
2206
+ let hourAngle = calcHourAngle(angle, latitude, solarDec);
2207
+ //alert("HA = " + radToDeg(hourAngle));
2225
2208
  if (!rise) hourAngle = -hourAngle;
2226
2209
  const delta = longitude + radToDeg(hourAngle);
2227
- const timeUTC = 720 - 4.0 * delta - eqTime; // in minutes
2228
-
2210
+ const timeUTC = 720 - (4.0 * delta) - eqTime; // in minutes
2229
2211
  return timeUTC;
2230
2212
  }
2231
2213
 
2232
- function calcSunriseSet(rise, angle, JD, date, latitude, longitude) // rise = 1 for sunrise, 0 for sunset
2233
- {
2234
- const timeUTC = calcSunriseSetUTC(rise, angle, JD, latitude, longitude);
2235
- const newTimeUTC = calcSunriseSetUTC(rise, angle, JD + timeUTC / 1440.0, latitude, longitude);
2214
+ function calcSunriseSet(rise, angle, JD, date, latitude, longitude)
2215
+ // rise = 1 for sunrise, 0 for sunset
2216
+ {
2217
+ const timeUTC = calcSunriseSetUTC(rise, angle, JD, latitude, longitude);
2218
+ const newTimeUTC = calcSunriseSetUTC(rise, angle, JD + timeUTC / 1440.0, latitude, longitude);
2219
+ if (isNumber(newTimeUTC)) {
2236
2220
 
2237
- if (isNumber(newTimeUTC)) {
2238
- return formatDate(date, newTimeUTC);
2239
- } else {
2240
- // no sunrise/set found
2241
- return new Date(NaN);
2221
+ return formatDate(date, newTimeUTC);
2222
+
2223
+ } else { // no sunrise/set found
2224
+ return new Date(NaN);
2225
+ }
2226
+ }
2227
+
2228
+ const degreesBelowHorizon = {
2229
+ sunrise: 0.833,
2230
+ sunriseEnd: 0.3,
2231
+ twilight: 6,
2232
+ nauticalTwilight: 12,
2233
+ night: 18,
2234
+ goldenHour: -6
2235
+ };
2236
+
2237
+ class SolarCalc {
2238
+ constructor(date, latitude, longitude) {
2239
+ this.date = date;
2240
+ this.lat = latitude;
2241
+ this.longitude = longitude;
2242
+
2243
+ this.sun = new Sun(date, latitude, longitude);
2244
+ }
2245
+
2246
+ get solarNoon() {
2247
+ return this.sun.solarNoon;
2248
+ }
2249
+
2250
+ get sunrise() {
2251
+ return this.sun.timeAtAngle(degreesBelowHorizon.sunrise, true);
2252
+ }
2253
+
2254
+ get sunset() {
2255
+ return this.sun.timeAtAngle(degreesBelowHorizon.sunrise);
2256
+ }
2257
+
2258
+ get sunriseEnd() {
2259
+ return this.sun.timeAtAngle(degreesBelowHorizon.sunriseEnd, true);
2260
+ }
2261
+
2262
+ get sunsetStart() {
2263
+ return this.sun.timeAtAngle(degreesBelowHorizon.sunriseEnd, false);
2264
+ }
2265
+
2266
+ get civilDawn() {
2267
+ return this.sun.timeAtAngle(degreesBelowHorizon.twilight, true);
2268
+ }
2269
+
2270
+ get dawn() {
2271
+ return this.civilDawn;
2272
+ }
2273
+
2274
+ get civilDusk() {
2275
+ return this.sun.timeAtAngle(degreesBelowHorizon.twilight, false);
2276
+ }
2277
+
2278
+ get dusk() {
2279
+ return this.civilDusk;
2280
+ }
2281
+
2282
+ get nauticalDawn() {
2283
+ return this.sun.timeAtAngle(degreesBelowHorizon.nauticalTwilight, true);
2284
+ }
2285
+
2286
+ get nauticalDusk() {
2287
+ return this.sun.timeAtAngle(degreesBelowHorizon.nauticalTwilight, false);
2288
+ }
2289
+
2290
+ get nightStart() {
2291
+ return this.astronomicalDusk;
2292
+ }
2293
+
2294
+ get astronomicalDusk() {
2295
+ return this.sun.timeAtAngle(degreesBelowHorizon.night, false);
2296
+ }
2297
+
2298
+ get astronomicalDawn() {
2299
+ return this.sun.timeAtAngle(degreesBelowHorizon.night, true);
2300
+ }
2301
+
2302
+ get nightEnd() {
2303
+ return this.astronomicalDawn;
2304
+ }
2305
+
2306
+ get goldenHourStart() {
2307
+ return this.sun.timeAtAngle(degreesBelowHorizon.goldenHour, false);
2308
+ }
2309
+
2310
+ get goldenHourEnd() {
2311
+ return this.sun.timeAtAngle(degreesBelowHorizon.goldenHour, true);
2242
2312
  }
2243
2313
  }
2244
2314
 
@@ -2378,7 +2448,8 @@ class Zmanim {
2378
2448
 
2379
2449
  const dt = greg.isDate(date) ? date : HDate.isHDate(date) ? date.greg() : throwTypeError$2(`invalid date: ${date}`);
2380
2450
  this.date = dt;
2381
- this.sun = new Sun_1(this.date, latitude, longitude);
2451
+ this.solarCalc = new SolarCalc(this.date, latitude, longitude);
2452
+ this.sun = this.solarCalc.sun;
2382
2453
  this.latitude = latitude;
2383
2454
  this.longitude = longitude;
2384
2455
  }
@@ -2390,48 +2461,60 @@ class Zmanim {
2390
2461
 
2391
2462
  suntime() {
2392
2463
  return {
2393
- solarNoon: this.sun.solarNoon,
2464
+ solarNoon: this.solarCalc.solarNoon,
2394
2465
  sunrise: this.sunrise(),
2395
2466
  sunset: this.sunset(),
2396
- sunriseEnd: this.sun.timeAtAngle(0.3, true),
2397
- sunsetStart: this.sun.timeAtAngle(0.3, false),
2467
+ sunriseEnd: this.solarCalc.sunriseEnd,
2468
+ sunsetStart: this.solarCalc.sunsetStart,
2398
2469
  dawn: this.dawn(),
2399
2470
  dusk: this.dusk(),
2400
- nauticalDawn: this.sun.timeAtAngle(12, true),
2401
- nauticalDusk: this.sun.timeAtAngle(12, false),
2402
- nightEnd: this.sun.timeAtAngle(18, true),
2403
- night: this.sun.timeAtAngle(18, false),
2404
- goldenHourEnd: this.sun.timeAtAngle(-6, true),
2405
- goldenHour: this.sun.timeAtAngle(-6, false),
2471
+ nauticalDawn: this.solarCalc.nauticalDawn,
2472
+ nauticalDusk: this.solarCalc.nauticalDusk,
2473
+ nightEnd: this.solarCalc.nightEnd,
2474
+ night: this.solarCalc.nightStart,
2475
+ goldenHourEnd: this.solarCalc.goldenHourEnd,
2476
+ goldenHour: this.solarCalc.goldenHourStart,
2406
2477
  alotHaShachar: this.alotHaShachar(),
2407
2478
  misheyakir: this.misheyakir(),
2408
2479
  misheyakirMachmir: this.misheyakirMachmir(),
2409
2480
  tzeit: this.tzeit()
2410
2481
  };
2411
2482
  }
2412
- /** @return {Date} */
2483
+ /**
2484
+ * Upper edge of the Sun appears over the eastern horizon in the morning (0.833° above horizon)
2485
+ * @return {Date}
2486
+ */
2413
2487
 
2414
2488
 
2415
2489
  sunrise() {
2416
2490
  return this.sun.timeAtAngle(0.833333, true);
2417
2491
  }
2418
- /** @return {Date} */
2492
+ /**
2493
+ * When the upper edge of the Sun disappears below the horizon (0.833° below horizon)
2494
+ * @return {Date}
2495
+ */
2419
2496
 
2420
2497
 
2421
2498
  sunset() {
2422
2499
  return this.sun.timeAtAngle(0.833333, false);
2423
2500
  }
2424
- /** @return {Date} */
2501
+ /**
2502
+ * Civil dawn; Sun is 6° below the horizon in the morning
2503
+ * @return {Date}
2504
+ */
2425
2505
 
2426
2506
 
2427
2507
  dawn() {
2428
- return this.sun.timeAtAngle(6, true);
2508
+ return this.solarCalc.dawn;
2429
2509
  }
2430
- /** @return {Date} */
2510
+ /**
2511
+ * Civil dusk; Sun is 6° below the horizon in the evening
2512
+ * @return {Date}
2513
+ */
2431
2514
 
2432
2515
 
2433
2516
  dusk() {
2434
- return this.sun.timeAtAngle(6, false);
2517
+ return this.solarCalc.dusk;
2435
2518
  }
2436
2519
  /** @return {number} */
2437
2520
 
@@ -2477,63 +2560,121 @@ class Zmanim {
2477
2560
  hourOffset(hours) {
2478
2561
  return new Date(this.sunrise().getTime() + this.hour() * hours);
2479
2562
  }
2480
- /** @return {Date} */
2563
+ /**
2564
+ * Midday – Chatzot; Sunrise plus 6 halachic hours
2565
+ * @return {Date}
2566
+ */
2481
2567
 
2482
2568
 
2483
2569
  chatzot() {
2484
2570
  return this.hourOffset(6);
2485
2571
  }
2486
- /** @return {Date} */
2572
+ /**
2573
+ * Midnight – Chatzot; Sunset plus 6 halachic hours
2574
+ * @return {Date}
2575
+ */
2487
2576
 
2488
2577
 
2489
2578
  chatzotNight() {
2490
2579
  return new Date(this.sunrise().getTime() - this.nightHour() * 6);
2491
2580
  }
2492
- /** @return {Date} */
2581
+ /**
2582
+ * Dawn – Alot haShachar; Sun is 16.1° below the horizon in the morning
2583
+ * @return {Date}
2584
+ */
2493
2585
 
2494
2586
 
2495
2587
  alotHaShachar() {
2496
2588
  return this.sun.timeAtAngle(16.1, true);
2497
2589
  }
2498
- /** @return {Date} */
2590
+ /**
2591
+ * Earliest talis & tefillin – Misheyakir; Sun is 11.5° below the horizon in the morning
2592
+ * @return {Date}
2593
+ */
2499
2594
 
2500
2595
 
2501
2596
  misheyakir() {
2502
2597
  return this.sun.timeAtAngle(11.5, true);
2503
2598
  }
2504
- /** @return {Date} */
2599
+ /**
2600
+ * Earliest talis & tefillin – Misheyakir Machmir; Sun is 10.2° below the horizon in the morning
2601
+ * @return {Date}
2602
+ */
2505
2603
 
2506
2604
 
2507
2605
  misheyakirMachmir() {
2508
2606
  return this.sun.timeAtAngle(10.2, true);
2509
2607
  }
2510
- /** @return {Date} */
2608
+ /**
2609
+ * Latest Shema (Gra); Sunrise plus 3 halachic hours, according to the Gra
2610
+ * @return {Date}
2611
+ */
2511
2612
 
2512
2613
 
2513
2614
  sofZmanShma() {
2514
2615
  // Gra
2515
2616
  return this.hourOffset(3);
2516
2617
  }
2517
- /** @return {Date} */
2618
+ /**
2619
+ * Latest Shacharit (Gra); Sunrise plus 4 halachic hours, according to the Gra
2620
+ * @return {Date}
2621
+ */
2518
2622
 
2519
2623
 
2520
2624
  sofZmanTfilla() {
2521
2625
  // Gra
2522
2626
  return this.hourOffset(4);
2523
2627
  }
2524
- /** @return {Date} */
2628
+ /**
2629
+ * Latest Shema (MGA); Sunrise plus 3 halachic hours, according to Magen Avraham
2630
+ * @return {Date}
2631
+ */
2632
+
2633
+
2634
+ sofZmanShmaMGA() {
2635
+ // Magen Avraham
2636
+ const alot72 = this.sunriseOffset(-72);
2637
+ const tzeit72 = this.sunsetOffset(72);
2638
+ const temporalHour = (tzeit72 - alot72) / 12; // ms in hour
2639
+
2640
+ return new Date(alot72.getTime() + 3 * temporalHour);
2641
+ }
2642
+ /**
2643
+ * Latest Shacharit (MGA); Sunrise plus 4 halachic hours, according to Magen Avraham
2644
+ * @return {Date}
2645
+ */
2646
+
2647
+
2648
+ sofZmanTfillaMGA() {
2649
+ // Magen Avraham
2650
+ const alot72 = this.sunriseOffset(-72);
2651
+ const tzeit72 = this.sunsetOffset(72);
2652
+ const temporalHour = (tzeit72 - alot72) / 12; // ms in hour
2653
+
2654
+ return new Date(alot72.getTime() + 4 * temporalHour);
2655
+ }
2656
+ /**
2657
+ * Earliest Mincha – Mincha Gedola; Sunrise plus 6.5 halachic hours
2658
+ * @return {Date}
2659
+ */
2525
2660
 
2526
2661
 
2527
2662
  minchaGedola() {
2528
2663
  return this.hourOffset(6.5);
2529
2664
  }
2530
- /** @return {Date} */
2665
+ /**
2666
+ * Preferable earliest time to recite Minchah – Mincha Ketana; Sunrise plus 9.5 halachic hours
2667
+ * @return {Date}
2668
+ */
2531
2669
 
2532
2670
 
2533
2671
  minchaKetana() {
2534
2672
  return this.hourOffset(9.5);
2535
2673
  }
2536
- /** @return {Date} */
2674
+ /**
2675
+ * Plag haMincha; Sunrise plus 10.75 halachic hours
2676
+ * @return {Date}
2677
+ */
2537
2678
 
2538
2679
 
2539
2680
  plagHaMincha() {
@@ -2549,13 +2690,19 @@ class Zmanim {
2549
2690
  tzeit(angle = 8.5) {
2550
2691
  return this.sun.timeAtAngle(angle, false);
2551
2692
  }
2552
- /** @return {Date} */
2693
+ /**
2694
+ * Alias for sunrise
2695
+ * @return {Date}
2696
+ */
2553
2697
 
2554
2698
 
2555
2699
  neitzHaChama() {
2556
2700
  return this.sunrise();
2557
2701
  }
2558
- /** @return {Date} */
2702
+ /**
2703
+ * Alias for sunset
2704
+ * @return {Date}
2705
+ */
2559
2706
 
2560
2707
 
2561
2708
  shkiah() {
@@ -2636,8 +2783,30 @@ class Zmanim {
2636
2783
  return getPseudoISO(tzid, date).substring(0, 19) + Zmanim.timeZoneOffset(tzid, date);
2637
2784
  }
2638
2785
  /**
2639
- * Returns sunset + offset (either positive or negative).
2640
- * @param {number} offset
2786
+ * Returns sunrise + `offset` minutes (either positive or negative).
2787
+ * @param {number} offset minutes
2788
+ * @return {Date}
2789
+ */
2790
+
2791
+
2792
+ sunriseOffset(offset) {
2793
+ const sunrise = this.sunrise();
2794
+
2795
+ if (isNaN(sunrise.getTime())) {
2796
+ return sunrise;
2797
+ } // For positive offsets only, round up to next minute if needed
2798
+
2799
+
2800
+ if (offset > 0 && sunrise.getSeconds() >= 30) {
2801
+ offset++;
2802
+ }
2803
+
2804
+ sunrise.setSeconds(0);
2805
+ return new Date(sunrise.getTime() + offset * 60 * 1000);
2806
+ }
2807
+ /**
2808
+ * Returns sunset + `offset` minutes (either positive or negative).
2809
+ * @param {number} offset minutes
2641
2810
  * @return {Date}
2642
2811
  */
2643
2812
 
@@ -4557,17 +4726,13 @@ function getHolidaysForYear_(year) {
4557
4726
  add(new RoshHashanaEvent(RH, year, CHAG | LIGHT_CANDLES_TZEIS$1));
4558
4727
  addEvents(year, [[2, TISHREI$1, 'Rosh Hashana II', CHAG | YOM_TOV_ENDS$1, {
4559
4728
  emoji: '🍏🍯'
4560
- }], [3 + (RH.getDay() == THU), TISHREI$1, 'Tzom Gedaliah', MINOR_FAST$1], [9, TISHREI$1, 'Erev Yom Kippur', EREV$1 | LIGHT_CANDLES$1, {
4561
- emoji: '📖✍️'
4562
- }]]); // first SAT after RH
4729
+ }], [3 + (RH.getDay() == THU), TISHREI$1, 'Tzom Gedaliah', MINOR_FAST$1], [9, TISHREI$1, 'Erev Yom Kippur', EREV$1 | LIGHT_CANDLES$1]]); // first SAT after RH
4563
4730
 
4564
4731
  add(new HolidayEvent(new HDate(HDate.dayOnOrBefore(SAT$1, 7 + RH.abs())), 'Shabbat Shuva', SPECIAL_SHABBAT$1));
4565
- addEvents(year, [[10, TISHREI$1, 'Yom Kippur', CHAG | YOM_TOV_ENDS$1 | MAJOR_FAST$1, {
4566
- emoji: '📖✍️'
4567
- }], [14, TISHREI$1, 'Erev Sukkot', EREV$1 | LIGHT_CANDLES$1, {
4732
+ addEvents(year, [[10, TISHREI$1, 'Yom Kippur', CHAG | YOM_TOV_ENDS$1 | MAJOR_FAST$1], // Attributes for Israel and Diaspora are different
4733
+ [14, TISHREI$1, 'Erev Sukkot', EREV$1 | LIGHT_CANDLES$1 | CHUL_ONLY$1, {
4568
4734
  emoji: emojiSukkot
4569
- }], // Attributes for Israel and Diaspora are different
4570
- [15, TISHREI$1, 'Sukkot I', CHAG | LIGHT_CANDLES_TZEIS$1 | CHUL_ONLY$1, {
4735
+ }], [15, TISHREI$1, 'Sukkot I', CHAG | LIGHT_CANDLES_TZEIS$1 | CHUL_ONLY$1, {
4571
4736
  emoji: emojiSukkot
4572
4737
  }], [16, TISHREI$1, 'Sukkot II', CHAG | YOM_TOV_ENDS$1 | CHUL_ONLY$1, {
4573
4738
  emoji: emojiSukkot
@@ -4583,6 +4748,8 @@ function getHolidaysForYear_(year) {
4583
4748
  }], [20, TISHREI$1, 'Sukkot VI (CH\'\'M)', CHUL_ONLY$1 | CHOL_HAMOED$1, {
4584
4749
  cholHaMoedDay: 4,
4585
4750
  emoji: emojiSukkot
4751
+ }], [14, TISHREI$1, 'Erev Sukkot', EREV$1 | LIGHT_CANDLES$1 | IL_ONLY$1, {
4752
+ emoji: emojiSukkot
4586
4753
  }], [15, TISHREI$1, 'Sukkot I', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, {
4587
4754
  emoji: emojiSukkot
4588
4755
  }], [16, TISHREI$1, 'Sukkot II (CH\'\'M)', IL_ONLY$1 | CHOL_HAMOED$1, {
@@ -4636,10 +4803,10 @@ function getHolidaysForYear_(year) {
4636
4803
  emoji: '🎭️📜'
4637
4804
  }), new HolidayEvent(new HDate(HDate.dayOnOrBefore(SAT$1, pesachAbs - 14) - 7), 'Shabbat Parah', SPECIAL_SHABBAT$1), new HolidayEvent(new HDate(HDate.dayOnOrBefore(SAT$1, pesachAbs - 14)), 'Shabbat HaChodesh', SPECIAL_SHABBAT$1), new HolidayEvent(new HDate(HDate.dayOnOrBefore(SAT$1, pesachAbs - 1)), 'Shabbat HaGadol', SPECIAL_SHABBAT$1), new HolidayEvent( // if the fast falls on Shabbat, move to Thursday
4638
4805
  pesach.prev().getDay() == SAT$1 ? pesach.onOrBefore(THU) : new HDate(14, NISAN$2, year), 'Ta\'anit Bechorot', MINOR_FAST$1));
4639
- addEvents(year, [[14, NISAN$2, 'Erev Pesach', EREV$1 | LIGHT_CANDLES$1, {
4806
+ addEvents(year, [// Attributes for Israel and Diaspora are different
4807
+ [14, NISAN$2, 'Erev Pesach', EREV$1 | LIGHT_CANDLES$1 | IL_ONLY$1, {
4640
4808
  emoji: '🫓🍷'
4641
- }], // Attributes for Israel and Diaspora are different
4642
- [15, NISAN$2, 'Pesach I', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, {
4809
+ }], [15, NISAN$2, 'Pesach I', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, {
4643
4810
  emoji: emojiPesach
4644
4811
  }], [16, NISAN$2, 'Pesach II (CH\'\'M)', IL_ONLY$1 | CHOL_HAMOED$1, {
4645
4812
  cholHaMoedDay: 1,
@@ -4658,6 +4825,8 @@ function getHolidaysForYear_(year) {
4658
4825
  emoji: emojiPesach
4659
4826
  }], [21, NISAN$2, 'Pesach VII', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, {
4660
4827
  emoji: emojiPesach
4828
+ }], [14, NISAN$2, 'Erev Pesach', EREV$1 | LIGHT_CANDLES$1 | CHUL_ONLY$1, {
4829
+ emoji: '🫓🍷'
4661
4830
  }], [15, NISAN$2, 'Pesach I', CHAG | LIGHT_CANDLES_TZEIS$1 | CHUL_ONLY$1, {
4662
4831
  emoji: '🫓🍷'
4663
4832
  }], [16, NISAN$2, 'Pesach II', CHAG | YOM_TOV_ENDS$1 | CHUL_ONLY$1, {
@@ -4680,7 +4849,8 @@ function getHolidaysForYear_(year) {
4680
4849
  emoji: emojiPesach
4681
4850
  }], [14, IYYAR, 'Pesach Sheni', MINOR_HOLIDAY$1], [18, IYYAR, 'Lag BaOmer', MINOR_HOLIDAY$1, {
4682
4851
  emoji: '🔥'
4683
- }], [5, SIVAN$1, 'Erev Shavuot', EREV$1 | LIGHT_CANDLES$1, emojiShavuot], [6, SIVAN$1, 'Shavuot', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, emojiShavuot], [6, SIVAN$1, 'Shavuot I', CHAG | LIGHT_CANDLES_TZEIS$1 | CHUL_ONLY$1, emojiShavuot], [7, SIVAN$1, 'Shavuot II', CHAG | YOM_TOV_ENDS$1 | CHUL_ONLY$1, emojiShavuot], [15, AV, 'Tu B\'Av', MINOR_HOLIDAY$1, {
4852
+ }], // Attributes for Israel and Diaspora are different
4853
+ [5, SIVAN$1, 'Erev Shavuot', EREV$1 | LIGHT_CANDLES$1 | IL_ONLY$1, emojiShavuot], [6, SIVAN$1, 'Shavuot', CHAG | YOM_TOV_ENDS$1 | IL_ONLY$1, emojiShavuot], [5, SIVAN$1, 'Erev Shavuot', EREV$1 | LIGHT_CANDLES$1 | CHUL_ONLY$1, emojiShavuot], [6, SIVAN$1, 'Shavuot I', CHAG | LIGHT_CANDLES_TZEIS$1 | CHUL_ONLY$1, emojiShavuot], [7, SIVAN$1, 'Shavuot II', CHAG | YOM_TOV_ENDS$1 | CHUL_ONLY$1, emojiShavuot], [15, AV, 'Tu B\'Av', MINOR_HOLIDAY$1, {
4684
4854
  emoji: '❤️'
4685
4855
  }], [1, ELUL$1, 'Rosh Hashana LaBehemot', MINOR_HOLIDAY$1, {
4686
4856
  emoji: '🐑'
@@ -5054,7 +5224,7 @@ function getBirthdayOrAnniversary_(hyear, gdate) {
5054
5224
  return new HDate(day, month, hyear);
5055
5225
  }
5056
5226
 
5057
- const version="3.33.6";
5227
+ const version="3.34.1";
5058
5228
 
5059
5229
  const headers$1={"plural-forms":"nplurals=2; plural=(n > 1);",language:"en_CA@ashkenazi"};const contexts$1={"":{Berachot:["Berachos"],Shabbat:["Shabbos"],Taanit:["Taanis"],Yevamot:["Yevamos"],Ketubot:["Kesubos"],"Baba Batra":["Baba Basra"],Makkot:["Makkos"],Shevuot:["Shevuos"],Horayot:["Horayos"],Menachot:["Menachos"],Bechorot:["Bechoros"],Keritot:["Kerisos"],Midot:["Midos"],"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"],Tazria:["Sazria"],"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"],Tevet:["Teves"],"Asara B'Tevet":["Asara B'Teves"],Berakhot:["Berakhos"],Sheviit:["Sheviis"],Terumot:["Terumos"],Maasrot:["Maasros"],Eduyot:["Eduyos"],Avot:["Avos"],Bekhorot:["Bekhoros"],Middot:["Middos"],Oholot:["Oholos"],Tahorot:["Tahoros"],Mikvaot:["Mikvaos"]}};var poAshkenazi = {headers:headers$1,contexts:contexts$1};
5060
5230