jcal-zmanim 1.5.1 → 1.5.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.
package/dist/index.d.cts CHANGED
@@ -484,7 +484,7 @@ declare class Utils {
484
484
  * @param {number} dayOfOmer The day of the Omer for which to get the nusach for
485
485
  * @param {'ashkenaz'|'sefard'|'sefardi'} nusach Should it be La'Omer ("sefard") or Ba'Omer ("ashkenaz") or "sefardi" (Eidot Hamizrach)?
486
486
  */
487
- static getOmerNusach(dayOfOmer: number, nusach: 'ashkenaz' | 'sefard' | 'sefardi'): string;
487
+ static getOmerNusach(dayOfOmer: number, nusach: "ashkenaz" | "sefard" | "sefardi"): string;
488
488
  /**
489
489
  * Returns the given time in a formatted string.
490
490
  * @param {Time} time An object in the format {hour : 23, minute :42, second: 18 }
@@ -569,10 +569,10 @@ declare class Utils {
569
569
  */
570
570
  static toInt(float: number): number;
571
571
  /***
572
- * Takes either a jDate or a Date and returns both
573
- * @param date {Date |jDate}
574
- * @returns {{ sdate:Date, jdate:jDate }}
575
- */
572
+ * Takes either a jDate or a Date and returns both
573
+ * @param date {Date |jDate}
574
+ * @returns {{ sdate:Date, jdate:jDate }}
575
+ */
576
576
  static bothDates(date: Date | jDate): {
577
577
  sdate: Date;
578
578
  jdate: jDate;
package/dist/index.d.ts CHANGED
@@ -484,7 +484,7 @@ declare class Utils {
484
484
  * @param {number} dayOfOmer The day of the Omer for which to get the nusach for
485
485
  * @param {'ashkenaz'|'sefard'|'sefardi'} nusach Should it be La'Omer ("sefard") or Ba'Omer ("ashkenaz") or "sefardi" (Eidot Hamizrach)?
486
486
  */
487
- static getOmerNusach(dayOfOmer: number, nusach: 'ashkenaz' | 'sefard' | 'sefardi'): string;
487
+ static getOmerNusach(dayOfOmer: number, nusach: "ashkenaz" | "sefard" | "sefardi"): string;
488
488
  /**
489
489
  * Returns the given time in a formatted string.
490
490
  * @param {Time} time An object in the format {hour : 23, minute :42, second: 18 }
@@ -569,10 +569,10 @@ declare class Utils {
569
569
  */
570
570
  static toInt(float: number): number;
571
571
  /***
572
- * Takes either a jDate or a Date and returns both
573
- * @param date {Date |jDate}
574
- * @returns {{ sdate:Date, jdate:jDate }}
575
- */
572
+ * Takes either a jDate or a Date and returns both
573
+ * @param date {Date |jDate}
574
+ * @returns {{ sdate:Date, jdate:jDate }}
575
+ */
576
576
  static bothDates(date: Date | jDate): {
577
577
  sdate: Date;
578
578
  jdate: jDate;
package/dist/index.js CHANGED
@@ -4187,19 +4187,19 @@ var _Utils = /*#__PURE__*/ function() {
4187
4187
  */ function getTimeIntervalTextStringHeb(time) {
4188
4188
  var t = "";
4189
4189
  if (time.hour > 0) {
4190
- t += "".concat(time.hour.toString(), " ").concat(time.hour === 1 ? "\u05E9\u05E2\u05D4" : "\u05E9\u05E2\u05D5\u05EA");
4190
+ t += "".concat(time.hour.toString(), " ").concat(time.hour === 1 ? "\u05E9\u05E2\u05D4" : "\u05E9\u05E2\u05D5\u05EA", "\xad");
4191
4191
  }
4192
4192
  if (time.minute > 0) {
4193
4193
  if (t.length) {
4194
4194
  t += " ";
4195
4195
  }
4196
- t += "".concat(time.minute.toString(), " ").concat(time.minute === 1 ? "\u05D3\u05E7\u05D4" : "\u05D3\u05E7\u05D5\u05EA");
4196
+ t += "".concat(time.minute.toString(), " ").concat(time.minute === 1 ? "\u05D3\u05E7\u05D4" : "\u05D3\u05E7\u05D5\u05EA", "\xad");
4197
4197
  }
4198
4198
  if ((time.second || 0) > 0) {
4199
4199
  if (t.length) {
4200
4200
  t += " ";
4201
4201
  }
4202
- t += "".concat(Math.trunc(time.second || 0).toString(), " ").concat(time.second === 1 ? "\u05E9\u05E0\u05D9\u05D9\u05D4" : "\u05E9\u05E0\u05D9\u05D5\u05EA");
4202
+ t += "".concat(Math.trunc(time.second || 0).toString(), " ").concat(time.second === 1 ? "\u05E9\u05E0\u05D9\u05D9\u05D4" : "\u05E9\u05E0\u05D9\u05D5\u05EA", "\xad");
4203
4203
  }
4204
4204
  return t;
4205
4205
  }
@@ -4212,19 +4212,19 @@ var _Utils = /*#__PURE__*/ function() {
4212
4212
  */ function getTimeIntervalTextString(time) {
4213
4213
  var t = "";
4214
4214
  if (time.hour > 0) {
4215
- t += "".concat(time.hour.toString(), " ").concat(time.hour === 1 ? "hour" : "hours");
4215
+ t += "".concat(time.hour.toString(), " ").concat(time.hour === 1 ? "hour" : "hours", "\xad");
4216
4216
  }
4217
4217
  if (time.minute > 0) {
4218
4218
  if (t.length) {
4219
4219
  t += " ";
4220
4220
  }
4221
- t += "".concat(time.minute.toString(), " ").concat(time.minute === 1 ? "minute" : "minutes");
4221
+ t += "".concat(time.minute.toString(), " ").concat(time.minute === 1 ? "minute" : "minutes", "\xad");
4222
4222
  }
4223
4223
  if ((time.second || 0) > 0) {
4224
4224
  if (t.length) {
4225
4225
  t += " ";
4226
4226
  }
4227
- t += "".concat(Math.trunc(time.second || 0).toString(), " ").concat(time.second === 1 ? "second" : "seconds");
4227
+ t += "".concat(Math.trunc(time.second || 0).toString(), " ").concat(time.second === 1 ? "second" : "seconds", "\xad");
4228
4228
  }
4229
4229
  return t;
4230
4230
  }
@@ -4291,7 +4291,7 @@ var _Utils = /*#__PURE__*/ function() {
4291
4291
  value: /**
4292
4292
  * Returns the given time in a formatted string.
4293
4293
  * @param {Time} time An object in the format {hour : 23, minute :42, second: 18 }
4294
- * @param {1 | -1} [sign]
4294
+ * @param {1 | -1} [sign]
4295
4295
  * @param {Boolean} [army] If falsey, the returned string will be: 11:42:18 PM otherwise it will be 23:42:18
4296
4296
  * @param {Boolean} [roundUp] If falsey, the numbers will converted to a whole number by rounding down, otherwise, up.
4297
4297
  */ function getTimeString(time, sign, army, roundUp) {
@@ -4479,10 +4479,10 @@ var _Utils = /*#__PURE__*/ function() {
4479
4479
  {
4480
4480
  key: "bothDates",
4481
4481
  value: /***
4482
- * Takes either a jDate or a Date and returns both
4483
- * @param date {Date |jDate}
4484
- * @returns {{ sdate:Date, jdate:jDate }}
4485
- */ function bothDates(date) {
4482
+ * Takes either a jDate or a Date and returns both
4483
+ * @param date {Date |jDate}
4484
+ * @returns {{ sdate:Date, jdate:jDate }}
4485
+ */ function bothDates(date) {
4486
4486
  var jdate = _instanceof(date, Date) ? new jDate(date) : date;
4487
4487
  var sdate = _instanceof(date, Date) ? date : jdate.getDate();
4488
4488
  return {
@@ -13454,7 +13454,7 @@ function getNotifications(date, time, location, english, showGaonShir, showDafYo
13454
13454
  var _Utils_bothDates = Utils.bothDates(date), sdate = _Utils_bothDates.sdate, jdate = _Utils_bothDates.jdate;
13455
13455
  dayNotes.length = 0;
13456
13456
  tefillahNotes.length = 0;
13457
- var month = jdate.Month, day = jdate.Day, dow = jdate.DayOfWeek, _ZmanimUtils_getBasicShulZmanim = ZmanimUtils.getBasicShulZmanim(date, location), chatzosHayom = _ZmanimUtils_getBasicShulZmanim.chatzosHayom, chatzosHalayla = _ZmanimUtils_getBasicShulZmanim.chatzosHalayla, alos = _ZmanimUtils_getBasicShulZmanim.alos, shkia = _ZmanimUtils_getBasicShulZmanim.shkia, isAfterChatzosHayom = Utils.isTimeAfter(chatzosHayom, time), isAfterChatzosHalayla = typeof chatzosHalayla !== "undefined" && (Utils.isTimeAfter(chatzosHalayla, time) || chatzosHalayla.hour > 12 && time.hour < 12), isAfterAlos = Utils.isTimeAfter(alos, time), isAfterShkia = Utils.isTimeAfter(shkia, time), isDaytime = isAfterAlos && !isAfterShkia, isNightTime = !isDaytime, isNotBeinHasmashos = !isAfterShkia || Utils.isTimeAfter(Utils.addMinutes(shkia, 18), time), isMorning = isDaytime && !isAfterChatzosHayom, isAfternoon = isDaytime && isAfterChatzosHayom, isYomTov = jdate.isYomTovOrCholHamoed(location.Israel), isLeapYear = jDate.isJdLeapY(jdate.Year), noTachnun = isAfternoon && (dow === DaysOfWeek.FRIDAY || day === 29);
13457
+ var month = jdate.Month, day = jdate.Day, dow = jdate.DayOfWeek, _ZmanimUtils_getBasicShulZmanim = ZmanimUtils.getBasicShulZmanim(date, location), chatzosHayom = _ZmanimUtils_getBasicShulZmanim.chatzosHayom, chatzosHalayla = _ZmanimUtils_getBasicShulZmanim.chatzosHalayla, alos = _ZmanimUtils_getBasicShulZmanim.alos, shkia = _ZmanimUtils_getBasicShulZmanim.shkia, isAfterChatzosHayom = Utils.isTimeAfter(chatzosHayom, time), isAfterChatzosHalayla = typeof chatzosHalayla !== "undefined" && (Utils.isTimeAfter(chatzosHalayla, time) || chatzosHalayla.hour > 12 && time.hour < 12), isAfterAlos = Utils.isTimeAfter(alos, time), isAfterShkia = Utils.isTimeAfter(shkia, time), isDaytime = isAfterAlos && !isAfterShkia, isNightTime = !isDaytime, isNotBeinHasmashos = !isAfterShkia || Utils.isTimeAfter(Utils.addMinutes(shkia, 18), time), isMorning = isDaytime && !isAfterChatzosHayom, isAfternoon = isDaytime && isAfterChatzosHayom && isNotBeinHasmashos, isYomTov = jdate.isYomTovOrCholHamoed(location.Israel), isLeapYear = jDate.isJdLeapY(jdate.Year), noTachnun = isAfternoon && (dow === DaysOfWeek.FRIDAY || day === 29);
13458
13458
  dayInfo = {
13459
13459
  jdate: jdate,
13460
13460
  sdate: sdate,
@@ -13628,6 +13628,9 @@ function getAroundTheYearNotifications() {
13628
13628
  if (dow !== DaysOfWeek.SHABBOS && day > 15 && day !== 21) {
13629
13629
  addTefillahNote("Vesain Bracha", "\u05D5\u05EA\u05DF \u05D1\u05E8\u05DB\u05D4");
13630
13630
  }
13631
+ if (isNightTime && (dow !== DaysOfWeek.FRIDAY && day === 14 || dow === DaysOfWeek.THURSDAY && day === 13)) {
13632
+ addDayNote("Bedikas Chometz", "\u05D1\u05D3\u05D9\u05E7\u05EA \u05D7\u05DE\u05E5");
13633
+ }
13631
13634
  if (isMorning && dow !== DaysOfWeek.SHABBOS && [
13632
13635
  14,
13633
13636
  16,