@hebcal/core 6.14.7 → 6.15.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/README.md +25 -0
  2. package/dist/bundle.js +595 -352
  3. package/dist/bundle.js.map +1 -1
  4. package/dist/bundle.min.js +7 -7
  5. package/dist/bundle.min.js.map +1 -1
  6. package/dist/esm/DailyLearning.js +1 -1
  7. package/dist/esm/HebrewDateEvent.js +1 -1
  8. package/dist/esm/HolidayEvent.js +1 -1
  9. package/dist/esm/KiddushLevanaEvent.js +1 -1
  10. package/dist/esm/MevarchimChodeshEvent.js +1 -1
  11. package/dist/esm/ParshaEvent.js +1 -1
  12. package/dist/esm/TimedEvent.js +1 -1
  13. package/dist/esm/YomKippurKatanEvent.js +1 -1
  14. package/dist/esm/ashkenazi.po.js +1 -1
  15. package/dist/esm/calendar.js +1 -1
  16. package/dist/esm/candles.js +1 -1
  17. package/dist/esm/cities.json.js +1 -1
  18. package/dist/esm/event.js +1 -1
  19. package/dist/esm/getStartAndEnd.js +1 -1
  20. package/dist/esm/hallel.js +1 -1
  21. package/dist/esm/he-x-NoNikud.po.js +1 -1
  22. package/dist/esm/he.po.js +1 -1
  23. package/dist/esm/hebcal.js +1 -1
  24. package/dist/esm/holidays.js +1 -1
  25. package/dist/esm/horizon.d.ts +94 -0
  26. package/dist/esm/horizon.js +146 -0
  27. package/dist/esm/horizon.js.map +1 -0
  28. package/dist/esm/index.d.ts +1 -0
  29. package/dist/esm/index.js +1 -1
  30. package/dist/esm/isAssurBemlacha.js +1 -1
  31. package/dist/esm/isAveilut.js +1 -1
  32. package/dist/esm/isFastDay.js +1 -1
  33. package/dist/esm/locale.js +1 -1
  34. package/dist/esm/location.js +1 -1
  35. package/dist/esm/modern.js +1 -1
  36. package/dist/esm/molad.js +1 -1
  37. package/dist/esm/moladBase.js +1 -1
  38. package/dist/esm/moladDate.js +1 -1
  39. package/dist/esm/omer.js +1 -1
  40. package/dist/esm/parshaName.js +1 -1
  41. package/dist/esm/parshaYear.js +1 -1
  42. package/dist/esm/pkgVersion.d.ts +1 -1
  43. package/dist/esm/pkgVersion.js +2 -2
  44. package/dist/esm/pkgVersion.js.map +1 -1
  45. package/dist/esm/reformatTimeStr.js +1 -1
  46. package/dist/esm/sedra.js +1 -1
  47. package/dist/esm/sefira.json.js +1 -1
  48. package/dist/esm/staticHolidays.js +1 -1
  49. package/dist/esm/string.js +1 -1
  50. package/dist/esm/tachanun.js +1 -1
  51. package/dist/esm/zenith.d.ts +2 -1
  52. package/dist/esm/zenith.js +4 -3
  53. package/dist/esm/zenith.js.map +1 -1
  54. package/dist/esm/zmanim.d.ts +117 -5
  55. package/dist/esm/zmanim.js +202 -8
  56. package/dist/esm/zmanim.js.map +1 -1
  57. package/package.json +9 -9
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  const cals = new Map();
3
3
  /**
4
4
  * Plug-in registry for daily learning calendars such as Daf Yomi (Bavli),
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale, gematriya, months } from '@hebcal/hdate';
3
3
  import { Event, flags } from './event.js';
4
4
  import './locale.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { isoDateString, Locale } from '@hebcal/hdate';
3
3
  import { Event, flags } from './event.js';
4
4
  import { holidayDesc } from './staticHolidays.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import 'temporal-polyfill/global';
3
3
  import { HDate } from '@hebcal/hdate';
4
4
  import { flags } from './event.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale, HDate, months } from '@hebcal/hdate';
3
3
  import { Event, flags } from './event.js';
4
4
  import { Molad } from './molad.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Event, flags } from './event.js';
3
3
  import { HDate, isoDateString } from '@hebcal/hdate';
4
4
  import { renderParshaName } from './parshaName.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale } from '@hebcal/hdate';
3
3
  import { Event } from './event.js';
4
4
  import { reformatTimeStr } from './reformatTimeStr.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale } from '@hebcal/hdate';
3
3
  import { flags } from './event.js';
4
4
  import { HolidayEvent } from './HolidayEvent.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  var poAshkenazi = { "headers": { "plural-forms": "nplurals=2; plural=(n > 1);", "language": "und-x-ashkenaz" }, "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"], "Pesach Shabbat Chol ha-Moed": ["Pesach Shabbos Chol ha-Moed"], "Purim Katan": ["Purim Koton"], "Rosh Hashana LaBehemot": ["Rosh Hashana LaBeheimos"], "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)"], "Sukkot Shabbat Chol ha-Moed": ["Sukkos Shabbos Chol ha-Moed"], "Ta'anit Bechorot": ["Ta’anis Bechoros"], "Ta'anit BeHaB": ["Ta’anis BeHaB"], "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"], "Birkat Hachamah": ["Birkas HaChamah"], "Birkat HaChamah": ["Birkas HaChamah"], "Shushan Purim Katan": ["Shushan Purim Koton"], "Alot HaShachar": ["Alos HaShachar"], "Misheyakir": ["Misheyakir"], "Misheyakir Machmir": ["Misheyakir Machmir"], "Sunrise": ["Sunrise"], "Kriat Shema, sof zeman": ["Krias Shema, sof zman"], "Tefilah, sof zeman": ["Tefilah, sof zman"], "Kriat Shema, sof zeman (MGA)": ["Krias Shema, sof zman (MGA)"], "Kriat Shema, sof zeman (GRA)": ["Krias Shema, sof zman (GRA)"], "Tefilah, sof zeman (MGA)": ["Tefilah, sof zman (MGA)"], "Tefilah, sof zeman (GRA)": ["Tefilah, sof zman (GRA)"], "Chatzot HaLailah": ["Chatzos HaLailah"], "Chatzot HaYom": ["Chatzos"], "Chatzot hayom": ["Chatzos"], "Mincha Gedolah": ["Mincha Gedolah"], "Mincha Ketanah": ["Mincha Ketanah"], "Plag HaMincha": ["Plag HaMincha"], "Sunset": ["Sunset"], "Bein HaShemashot": ["Bein HaShemashos"], "Tzeit HaKochavim": ["Tzeis HaKochavim"], "Latest Kiddush Levana": ["Latest Kiddush Levanah"] } } };
3
3
 
4
4
  export { poAshkenazi as default };
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import './locale.js';
3
3
  import { months, Locale, abs2greg, HDate } from '@hebcal/hdate';
4
4
  import { makeCandleEvent, makeFastStartEnd, makeWeekdayChanukahCandleLighting } from './candles.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months } from '@hebcal/hdate';
3
3
  import { flags } from './event.js';
4
4
  import { HolidayEvent, ChanukahEvent } from './HolidayEvent.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  var citiesJson = [
3
3
  "Ashdod|IL|31.79213|34.64966|Asia/Jerusalem|27",
4
4
  "Atlanta|US|33.749|-84.38798|America/New_York|336",
package/dist/esm/event.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { HDate, Locale } from '@hebcal/hdate';
3
3
  import './locale.js';
4
4
 
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months, isDate, greg2abs, HDate, daysInGregMonth } from '@hebcal/hdate';
3
3
 
4
4
  const { TISHREI } = months;
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months } from '@hebcal/hdate';
3
3
  import { holidayDesc } from './staticHolidays.js';
4
4
 
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  var noNikudOverride = { "headers": { "plural-forms": "nplurals=2; plural=(n != 1);", "language": "he-x-NoNikud" }, "contexts": { "": { "Korach": ["קורח"], "Chukat": ["חוקת"], "Erev Yom Kippur": ["ערב יום כיפור"], "Yom Kippur": ["יום כיפור"], "Yom Kippur Katan": ["יום כיפור קטן"], "Pesach Shabbat Chol ha-Moed": ["שבת חול המועד פסח"], "Sukkot Shabbat Chol ha-Moed": ["שבת חול המועד סוכות"], "Erev Sukkot": ["ערב סוכות"], "Sukkot": ["סוכות"], "Sukkot I": ["סוכות א׳"], "Sukkot II": ["סוכות ב׳"], "Sukkot II (CH''M)": ["סוכות ב׳ (חוה״מ)"], "Sukkot III (CH''M)": ["סוכות ג׳ (חוה״מ)"], "Sukkot IV (CH''M)": ["סוכות ד׳ (חוה״מ)"], "Sukkot V (CH''M)": ["סוכות ה׳ (חוה״מ)"], "Sukkot VI (CH''M)": ["סוכות ו׳ (חוה״מ)"], "Sukkot VII (Hoshana Raba)": ["סוכות ז׳ (הושענא רבה)"], "Swords of Iron War Memorial Day": ["יום הזיכרון לחללי מלחמת חרבות ברזל"], "Latest Kiddush Levana": ["סוף זמן קידוש לבנה"] } } };
3
3
 
4
4
  export { noNikudOverride as default };
package/dist/esm/he.po.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  var poHe = { "headers": { "plural-forms": "nplurals=2; plural=(n > 1);", "language": "he_IL" }, "contexts": { "": { "Shabbat": ["שַׁבָּת"], "Parashat": ["פָּרָשַׁת"], "Achrei Mot": ["אַחֲרֵי מוֹת"], "Balak": ["בָּלָק"], "Bamidbar": ["בְּמִדְבַּר"], "Bechukotai": ["בְּחֻקֹּתַי"], "Beha'alotcha": ["בְּהַעֲלֹתְךָ"], "Behar": ["בְּהַר"], "Bereshit": ["בְּרֵאשִׁית"], "Beshalach": ["בְּשַׁלַּח"], "Bo": ["בֹּא"], "Chayei Sara": ["חַיֵּי שָֹרָה"], "Chukat": ["חֻקַּת"], "Devarim": ["דְּבָרִים"], "Eikev": ["עֵקֶב"], "Emor": ["אֱמוֹר"], "Ha'azinu": ["הַאֲזִינוּ"], "Kedoshim": ["קְדֹשִׁים"], "Ki Tavo": ["כִּי־תָבוֹא"], "Ki Teitzei": ["כִּי־תֵצֵא"], "Ki Tisa": ["כִּי תִשָּׂא"], "Korach": ["קֹרַח"], "Lech-Lecha": ["לֶךְ־לְךָ"], "Masei": ["מַסְעֵי"], "Matot": ["מַטּוֹת"], "Metzora": ["מְצֹרָע"], "Miketz": ["מִקֵּץ"], "Mishpatim": ["מִשְׁפָּטִים"], "Nasso": ["נָשׂא"], "Nitzavim": ["נִצָּבִים"], "Noach": ["נֹחַ"], "Pekudei": ["פְקוּדֵי"], "Pinchas": ["פִּינְחָס"], "Re'eh": ["רְאֵה"], "Sh'lach": ["שְׁלַח־לְךָ"], "Shemot": ["שְׁמוֹת"], "Shmini": ["שְּׁמִינִי"], "Shoftim": ["שׁוֹפְטִים"], "Tazria": ["תַזְרִיעַ"], "Terumah": ["תְּרוּמָה"], "Tetzaveh": ["תְּצַוֶּה"], "Toldot": ["תּוֹלְדוֹת"], "Tzav": ["צַו"], "Vaera": ["וָאֵרָא"], "Vaetchanan": ["וָאֶתְחַנַּן"], "Vayakhel": ["וַיַּקְהֵל"], "Vayechi": ["וַיְחִי"], "Vayeilech": ["וַיֵּלֶךְ"], "Vayera": ["וַיֵּרָא"], "Vayeshev": ["וַיֵּשֶׁב"], "Vayetzei": ["וַיֵּצֵא"], "Vayigash": ["וַיִּגַּשׁ"], "Vayikra": ["וַיִּקְרָא"], "Vayishlach": ["וַיִּשְׁלַח"], "Vezot Haberakhah": ["וְזֹאת הַבְּרָכָה"], "Yitro": ["יִתְרוֹ"], "Asara B'Tevet": ["עֲשָׂרָה בְּטֵבֵת"], "Candle lighting": ["הַדְלָקַת נֵרוֹת"], "Chanukah": ["חֲנוּכָּה"], "Chanukah: 1 Candle": ["חֲנוּכָּה: א׳ נֵר"], "Chanukah: 2 Candles": ["חֲנוּכָּה: ב׳ נֵרוֹת"], "Chanukah: 3 Candles": ["חֲנוּכָּה: ג׳ נֵרוֹת"], "Chanukah: 4 Candles": ["חֲנוּכָּה: ד׳ נֵרוֹת"], "Chanukah: 5 Candles": ["חֲנוּכָּה: ה׳ נֵרוֹת"], "Chanukah: 6 Candles": ["חֲנוּכָּה: ו׳ נֵרוֹת"], "Chanukah: 7 Candles": ["חֲנוּכָּה: ז׳ נֵרוֹת"], "Chanukah: 8 Candles": ["חֲנוּכָּה: ח׳ נֵרוֹת"], "Chanukah: 8th Day": ["חֲנוּכָּה: יוֹם ח׳"], "Days of the Omer": ["סְפִירַת הָעוֹמֶר"], "Omer": ["עוֹמֶר"], "day of the Omer": ["בָּעוֹמֶר"], "Erev Pesach": ["עֶרֶב פֶּסַח"], "Erev Purim": ["עֶרֶב פּוּרִים"], "Erev Rosh Hashana": ["עֶרֶב רֹאשׁ הַשָּׁנָה"], "Erev Shavuot": ["עֶרֶב שָׁבוּעוֹת"], "Erev Simchat Torah": ["עֶרֶב שִׂמְחַת תּוֹרָה"], "Erev Sukkot": ["עֶרֶב סֻכּוֹת"], "Erev Tish'a B'Av": ["עֶרֶב תִּשְׁעָה בְּאָב"], "Erev Yom Kippur": ["עֶרֶב יוֹם כִּפּוּר"], "Havdalah": ["הַבְדָּלָה"], "Lag BaOmer": ["ל״ג בָּעוֹמֶר"], "Leil Selichot": ["סְלִיחוֹת"], "Pesach": ["פֶּסַח"], "Pesach I": ["פֶּסַח א׳"], "Pesach II": ["פֶּסַח ב׳"], "Pesach II (CH''M)": ["פֶּסַח ב׳ (חוה״מ)"], "Pesach III (CH''M)": ["פֶּסַח ג׳ (חוה״מ)"], "Pesach IV (CH''M)": ["פֶּסַח ד׳ (חוה״מ)"], "Pesach Sheni": ["פֶּסַח שֵׁנִי"], "Pesach V (CH''M)": ["פֶּסַח ה׳ (חוה״מ)"], "Pesach VI (CH''M)": ["פֶּסַח ו׳ (חוה״מ)"], "Pesach VII": ["פֶּסַח ז׳"], "Pesach VIII": ["פֶּסַח ח׳"], "Pesach Shabbat Chol ha-Moed": ["שַׁבַּת חֹל הַמּוֹעֵד פֶּסַח"], "Purim": ["פּוּרִים"], "Purim Katan": ["פּוּרִים קָטָן"], "Rosh Chodesh": ["רֹאשׁ חוֹדֶשׁ"], "Rosh Hashana": ["רֹאשׁ הַשָּׁנָה"], "Rosh Hashana I": ["רֹאשׁ הַשָּׁנָה א׳"], "Rosh Hashana II": ["רֹאשׁ הַשָּׁנָה ב׳"], "Shabbat Chazon": ["שַׁבַּת חֲזוֹן"], "Shabbat HaChodesh": ["שַׁבַּת הַחֹדֶשׁ"], "Shabbat HaGadol": ["שַׁבַּת הַגָּדוֹל"], "Shabbat Nachamu": ["שַׁבַּת נַחֲמוּ"], "Shabbat Parah": ["שַׁבַּת פָּרָה"], "Shabbat Shekalim": ["שַׁבַּת שְׁקָלִים"], "Shabbat Shuva": ["שַׁבַּת שׁוּבָה"], "Shabbat Zachor": ["שַׁבַּת זָכוֹר"], "Shavuot": ["שָׁבוּעוֹת"], "Shavuot I": ["שָׁבוּעוֹת א׳"], "Shavuot II": ["שָׁבוּעוֹת ב׳"], "Shmini Atzeret": ["שְׁמִינִי עֲצֶרֶת"], "Shushan Purim": ["שׁוּשָׁן פּוּרִים"], "Sigd": ["חַג הַסִּיגְד"], "Simchat Torah": ["שִׂמְחַת תּוֹרָה"], "Sukkot": ["סֻכּוֹת"], "Sukkot I": ["סֻכּוֹת א׳"], "Sukkot II": ["סֻכּוֹת ב׳"], "Sukkot II (CH''M)": ["סֻכּוֹת ב׳ (חוה״מ)"], "Sukkot III (CH''M)": ["סֻכּוֹת ג׳ (חוה״מ)"], "Sukkot IV (CH''M)": ["סֻכּוֹת ד׳ (חוה״מ)"], "Sukkot V (CH''M)": ["סֻכּוֹת ה׳ (חוה״מ)"], "Sukkot VI (CH''M)": ["סֻכּוֹת ו׳ (חוה״מ)"], "Sukkot VII (Hoshana Raba)": ["סֻכּוֹת ז׳ (הוֹשַׁעְנָא רַבָּה)"], "Sukkot Shabbat Chol ha-Moed": ["שַׁבַּת חֹל הַמּוֹעֵד סֻכּוֹת"], "Ta'anit Bechorot": ["תַּעֲנִית בְּכוֹרוֹת"], "Ta'anit BeHaB": ["תַּעֲנִית בה״ב"], "Ta'anit Esther": ["תַּעֲנִית אֶסְתֵּר"], "Tish'a B'Av": ["תִּשְׁעָה בְּאָב"], "Tu B'Av": ["ט״וּ בְּאָב"], "Tu BiShvat": ["ט״וּ בִּשְׁבָט"], "Tu B'Shvat": ["ט״וּ בִּשְׁבָט"], "Tzom Gedaliah": ["צוֹם גְּדַלְיָה"], "Tzom Tammuz": ["צוֹם י״ז בְּתַמּוּז"], "Yom HaAtzma'ut": ["יוֹם הָעַצְמָאוּת"], "Yom HaShoah": ["יוֹם הַשּׁוֹאָה"], "Yom HaZikaron": ["יוֹם הַזִּכָּרוֹן"], "Yom Kippur": ["יוֹם כִּפּוּר"], "Yom Yerushalayim": ["יוֹם יְרוּשָׁלַיִם"], "Yom HaAliyah": ["יוֹם הַעֲלִיָּה"], "Yom HaAliyah School Observance": ["שְׁמִירָת בֵּית הַסֵפֶר לְיוֹם הַעֲלִיָּה"], "Rosh Chodesh Adar": ["רֹאשׁ חוֹדֶשׁ אֲדָר"], "Rosh Chodesh Adar I": ["רֹאשׁ חוֹדֶשׁ אֲדָר א׳"], "Rosh Chodesh Adar II": ["רֹאשׁ חוֹדֶשׁ אֲדָר ב׳"], "Rosh Chodesh Av": ["רֹאשׁ חוֹדֶשׁ אָב"], "Rosh Chodesh Cheshvan": ["רֹאשׁ חוֹדֶשׁ חֶשְׁוָן"], "Rosh Chodesh Elul": ["רֹאשׁ חוֹדֶשׁ אֱלוּל"], "Rosh Chodesh Iyyar": ["רֹאשׁ חוֹדֶשׁ אִיָּיר"], "Rosh Chodesh Kislev": ["רֹאשׁ חוֹדֶשׁ כִּסְלֵו"], "Rosh Chodesh Nisan": ["רֹאשׁ חוֹדֶשׁ נִיסָן"], "Rosh Chodesh Sh'vat": ["רֹאשׁ חוֹדֶשׁ שְׁבָט"], "Rosh Chodesh Sivan": ["רֹאשׁ חוֹדֶשׁ סִיוָן"], "Rosh Chodesh Tamuz": ["רֹאשׁ חוֹדֶשׁ תַּמּוּז"], "Rosh Chodesh Tammuz": ["רֹאשׁ חוֹדֶשׁ תַּמּוּז"], "Rosh Chodesh Tevet": ["רֹאשׁ חוֹדֶשׁ טֵבֵת"], "min": ["דַּקּוֹת"], "Fast begins": ["תְּחִילַּת הַצוֹם"], "Fast ends": ["סִיּוּם הַצוֹם"], "Rosh Hashana LaBehemot": ["רֹאשׁ הַשָּׁנָה לְמַעְשַׂר בְּהֵמָה"], "Tish'a B'Av (observed)": ["(תִּשְׁעָה בְּאָב (נִדְחָה"], "Shabbat Mevarchim Chodesh": ["שַׁבַּת מְבָרְכִים חוֹדֶשׁ"], "Shabbat Shirah": ["שַׁבַּת שִׁירָה"], "Lovingkindness": ["חֶסֶד"], "Might": ["גְּבוּרָה"], "Beauty": ["תִּפְאֶרֶת"], "Eternity": ["נֶּצַח"], "Splendor": ["הוֹד"], "Foundation": ["יְּסוֹד"], "Majesty": ["מַּלְכוּת"], "day": ["יוֹם"], "Yom Kippur Katan": ["יוֹם כִּפּוּר קָטָן"], "Yizkor": ["יִזְכּוֹר"], "Family Day": ["יוֹם הַמִּשׁפָּחָה"], "Yitzhak Rabin Memorial Day": ["יוֹם הַזִּכָּרוֹן לְיִצְחָק רַבִּין"], "Jabotinsky Day": ["יוֹם זַ׳בּוֹטִינְסְקִי"], "Herzl Day": ["יוֹם הֶרְצְל"], "Ben-Gurion Day": ["יוֹם בֶּן־גּוּרִיּוֹן"], "Hebrew Language Day": ["יוֹם הַשָׂפָה הַעִברִית"], "Birkat Hachamah": ["בִּרְכַּת הַחַמָּה"], "Birkat HaChamah": ["בִּרְכַּת הַחַמָּה"], "Shushan Purim Katan": ["שׁוּשָׁן פּוּרִים קָטָן"], "Purim Meshulash": ["פּוּרִים מְשׁוּלָּשׁ"], "Chag HaBanot": ["חַג הַבָּנוֹת"], "Molad": ["מוֹלָד הָלְּבָנָה"], "chalakim": ["חֲלָקִים"], "Alot HaShachar": ["עֲלוֹת הַשַּׁחַר"], "Misheyakir": ["מִשֶּׁיַּכִּיר"], "Misheyakir Machmir": ["מִשֶּׁיַּכִּיר מַחְמִיר"], "Sunrise": ["נֵץ הַחַמָּה"], "Kriat Shema, sof zeman": ["סוֹף זְמַן קְרִיאַת שְׁמַע"], "Tefilah, sof zeman": ["סוֹף זְמַן תְּפִלָּה"], "Kriat Shema, sof zeman (MGA)": ["סוֹף זְמַן קְרִיאַת שְׁמַע (מג״א)"], "Kriat Shema, sof zeman (GRA)": ["סוֹף זְמַן קְרִיאַת שְׁמַע (גְּרָ״א)"], "Tefilah, sof zeman (MGA)": ["סוֹף זְמַן תְּפִלָּה (מג״א)"], "Tefilah, sof zeman (GRA)": ["סוֹף זְמַן תְּפִלָּה (גְּרָ״א)"], "Chatzot HaLailah": ["חֲצוֹת הַלַּיְלָה"], "Chatzot HaYom": ["חֲצוֹת הַיּוֹם"], "Chatzot hayom": ["חֲצוֹת הַיּוֹם"], "Mincha Gedolah": ["מִנְחָה גְּדוֹלָה"], "Mincha Ketanah": ["מִנְחָה קְטַנָּה"], "Plag HaMincha": ["פְּלַג הַמִּנְחָה"], "Sunset": ["שְׁקִיעַת הַחַמָּה"], "Bein HaShemashot": ["בֵּין הַשְּׁמָשׁוֹת"], "Tzeit HaKochavim": ["צֵאת הַכּוֹכָבִים"], "Biur Chametz": ["בִּעוּר חָמֵץ"], "Finish eating chametz": ["סוֹף זְמַן אֲכִילַת חָמֵץ"], "Swords of Iron War Memorial Day": ["יוֹם הַזִּכָּרוֹן לְחַלְלֵי מִלְחֶמֶת חַרְבוֹת בַּרְזֶל"], "Latest Kiddush Levana": ["סוֹף זְמַן קִדּוּשׁ לְבָנָה"] } } };
3
3
 
4
4
  export { poHe as default };
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { birthdayOrAnniversary, yahrzeit, HDate } from '@hebcal/hdate';
3
3
  import './locale.js';
4
4
  import { version } from './pkgVersion.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months, HDate } from '@hebcal/hdate';
3
3
  import QuickLRU from 'quick-lru';
4
4
  import { flags } from './event.js';
@@ -0,0 +1,94 @@
1
+ /**
2
+ * Pure arithmetic for the "visible" sunrise/sunset (_netz ha-nireh_,
3
+ * הנץ הנראה): resolving a caller-supplied terrain horizon profile, atmospheric
4
+ * refraction, and the apparent altitude of the sun's upper limb.
5
+ *
6
+ * The method follows Keller & Hall, _Using a digital terrain model to
7
+ * calculate visual sunrise and sunset times_, Computers & Geosciences 26
8
+ * (2000) 991–1000, https://doi.org/10.1016/S0098-3004(00)00058-3 (a copy is
9
+ * hosted at http://www.chaitables.com/DblHallpaperpub.htm), and their part II,
10
+ * Computers & Geosciences 162 (2022) 105044,
11
+ * https://doi.org/10.1016/j.cageo.2022.105044, which re-examines the
12
+ * refraction model with ray tracing and finds the standard formulas adequate.
13
+ * It matches the conventions of the Chai Tables (https://www.chaitables.com),
14
+ * the authors' public service that computes these times for the printed
15
+ * Israeli calendars; their conventions are described at
16
+ * http://www.chaitables.com/Introduction_to_DTM_calculations.html.
17
+ *
18
+ * Refraction uses the Sinclair model below 15° and the Bennett model at or
19
+ * above 15°, both at standard atmosphere (1010 hPa, 10 °C), matching the Chai
20
+ * Tables. Bennett's formula is from G. G. Bennett, _The calculation of
21
+ * astronomical refraction in marine navigation_, Journal of Navigation 35
22
+ * (1982) 255–259, https://doi.org/10.1017/S0373463300022037; Sinclair's
23
+ * low-altitude formula is the one given in the _Explanatory Supplement to the
24
+ * Astronomical Almanac_ (ed. Seidelmann, 1992), §3.283, and both are
25
+ * reproduced in Keller & Hall (2000). "Visible" means the moment the sun's
26
+ * _upper limb_ (semidiameter 16′), bent up by refraction, first clears
27
+ * (sunrise) or last touches (sunset) the real skyline. No cushion or safety
28
+ * margin is added — the raw computed instant is returned (the Chai Tables add
29
+ * 20 seconds).
30
+ *
31
+ * This module is pure: it depends on nothing from `@hebcal/noaa` and performs
32
+ * no I/O. The horizon profile is always supplied by the caller; building one
33
+ * from terrain / digital-elevation-model data is outside this library.
34
+ */
35
+ /**
36
+ * One measured point of a horizon profile: the apparent angular altitude of
37
+ * the skyline in a single compass direction.
38
+ */
39
+ export interface HorizonSample {
40
+ /**
41
+ * Degrees clockwise from true north: 0 = N, 90 = E, 180 = S, 270 = W.
42
+ */
43
+ azimuth: number;
44
+ /**
45
+ * Apparent angular altitude of the highest obstruction in that direction,
46
+ * in degrees above the observer's astronomical horizon (negative where the
47
+ * horizon dips below it, e.g. the sea seen from a height).
48
+ */
49
+ elevation: number;
50
+ }
51
+ /**
52
+ * The apparent altitude of the skyline as a function of compass azimuth. May
53
+ * be one of:
54
+ *
55
+ * - a constant `number` — the same elevation in every direction;
56
+ * - a non-empty list of {@link HorizonSample}s in any order or spacing, with
57
+ * azimuths in `[0, 360)`, linearly interpolated (wrapping past 360°/0°);
58
+ * - a function `(azimuth: number) => number` returning the elevation in
59
+ * degrees for a given azimuth.
60
+ */
61
+ export type HorizonProfile = number | readonly HorizonSample[] | ((azimuth: number) => number);
62
+ /**
63
+ * The sun's angular semidiameter in degrees (16 arcminutes), matching the
64
+ * value `@hebcal/noaa` folds into its `GEOMETRIC_ZENITH` adjustment.
65
+ */
66
+ export declare const SOLAR_SEMIDIAMETER: number;
67
+ /**
68
+ * Resolves a {@link HorizonProfile} at a single azimuth.
69
+ *
70
+ * A constant returns itself; a function is invoked; a sample list is linearly
71
+ * interpolated between its two neighbouring samples by azimuth, wrapping
72
+ * around 360°/0°. A single sample behaves as a constant.
73
+ * @param profile the horizon profile
74
+ * @param azimuth degrees clockwise from true north
75
+ * @throws {TypeError} for an empty sample array or a non-finite constant
76
+ */
77
+ export declare function horizonElevation(profile: HorizonProfile, azimuth: number): number;
78
+ /**
79
+ * Atmospheric refraction at a given apparent altitude, in degrees, at standard
80
+ * atmosphere (1010 hPa, 10 °C). Sinclair's formula below 15°, Bennett's at or
81
+ * above 15° — the pairing the Chai Tables use.
82
+ * @param apparentAltitude apparent altitude of the body above the horizon, in degrees
83
+ */
84
+ export declare function refractionAtApparentAltitude(apparentAltitude: number): number;
85
+ /**
86
+ * Given the sun's geometric centre altitude, returns the apparent altitude of
87
+ * its upper limb — adding the semidiameter and solving the implicit
88
+ * refraction equation `β = a + SD + R(β)` by fixed-point iteration.
89
+ *
90
+ * `upperLimbApparentAltitude(-0.8333)` is ≈ 0, i.e. the standard sea-level
91
+ * sunrise/sunset definition (upper limb on the astronomical horizon).
92
+ * @param centerGeometricAltitude geometric altitude of the sun's centre, in degrees
93
+ */
94
+ export declare function upperLimbApparentAltitude(centerGeometricAltitude: number): number;
@@ -0,0 +1,146 @@
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
+ /**
3
+ * Pure arithmetic for the "visible" sunrise/sunset (_netz ha-nireh_,
4
+ * הנץ הנראה): resolving a caller-supplied terrain horizon profile, atmospheric
5
+ * refraction, and the apparent altitude of the sun's upper limb.
6
+ *
7
+ * The method follows Keller & Hall, _Using a digital terrain model to
8
+ * calculate visual sunrise and sunset times_, Computers & Geosciences 26
9
+ * (2000) 991–1000, https://doi.org/10.1016/S0098-3004(00)00058-3 (a copy is
10
+ * hosted at http://www.chaitables.com/DblHallpaperpub.htm), and their part II,
11
+ * Computers & Geosciences 162 (2022) 105044,
12
+ * https://doi.org/10.1016/j.cageo.2022.105044, which re-examines the
13
+ * refraction model with ray tracing and finds the standard formulas adequate.
14
+ * It matches the conventions of the Chai Tables (https://www.chaitables.com),
15
+ * the authors' public service that computes these times for the printed
16
+ * Israeli calendars; their conventions are described at
17
+ * http://www.chaitables.com/Introduction_to_DTM_calculations.html.
18
+ *
19
+ * Refraction uses the Sinclair model below 15° and the Bennett model at or
20
+ * above 15°, both at standard atmosphere (1010 hPa, 10 °C), matching the Chai
21
+ * Tables. Bennett's formula is from G. G. Bennett, _The calculation of
22
+ * astronomical refraction in marine navigation_, Journal of Navigation 35
23
+ * (1982) 255–259, https://doi.org/10.1017/S0373463300022037; Sinclair's
24
+ * low-altitude formula is the one given in the _Explanatory Supplement to the
25
+ * Astronomical Almanac_ (ed. Seidelmann, 1992), §3.283, and both are
26
+ * reproduced in Keller & Hall (2000). "Visible" means the moment the sun's
27
+ * _upper limb_ (semidiameter 16′), bent up by refraction, first clears
28
+ * (sunrise) or last touches (sunset) the real skyline. No cushion or safety
29
+ * margin is added — the raw computed instant is returned (the Chai Tables add
30
+ * 20 seconds).
31
+ *
32
+ * This module is pure: it depends on nothing from `@hebcal/noaa` and performs
33
+ * no I/O. The horizon profile is always supplied by the caller; building one
34
+ * from terrain / digital-elevation-model data is outside this library.
35
+ */
36
+ /**
37
+ * The sun's angular semidiameter in degrees (16 arcminutes), matching the
38
+ * value `@hebcal/noaa` folds into its `GEOMETRIC_ZENITH` adjustment.
39
+ */
40
+ const SOLAR_SEMIDIAMETER = 16 / 60;
41
+ /**
42
+ * Resolves a {@link HorizonProfile} at a single azimuth.
43
+ *
44
+ * A constant returns itself; a function is invoked; a sample list is linearly
45
+ * interpolated between its two neighbouring samples by azimuth, wrapping
46
+ * around 360°/0°. A single sample behaves as a constant.
47
+ * @param profile the horizon profile
48
+ * @param azimuth degrees clockwise from true north
49
+ * @throws {TypeError} for an empty sample array or a non-finite constant
50
+ */
51
+ function horizonElevation(profile, azimuth) {
52
+ if (typeof profile === 'number') {
53
+ if (!Number.isFinite(profile)) {
54
+ throw new TypeError(`invalid horizon elevation: ${profile}`);
55
+ }
56
+ return profile;
57
+ }
58
+ if (typeof profile === 'function') {
59
+ return profile(azimuth);
60
+ }
61
+ const n = profile.length;
62
+ if (n === 0) {
63
+ throw new TypeError('horizon profile has no samples');
64
+ }
65
+ if (n === 1) {
66
+ return profile[0].elevation;
67
+ }
68
+ const sorted = [...profile].sort((a, b) => a.azimuth - b.azimuth);
69
+ let az = azimuth % 360;
70
+ if (az < 0) {
71
+ az += 360;
72
+ }
73
+ // Largest sample azimuth that is still <= the query azimuth.
74
+ let loIdx = -1;
75
+ for (let i = 0; i < n; i++) {
76
+ if (sorted[i].azimuth <= az) {
77
+ loIdx = i;
78
+ }
79
+ else {
80
+ break;
81
+ }
82
+ }
83
+ let lo;
84
+ let hi;
85
+ let loAz;
86
+ let hiAz;
87
+ if (loIdx === -1) {
88
+ // Below the smallest azimuth: wrap, previous neighbour is the last sample.
89
+ lo = sorted[n - 1];
90
+ loAz = lo.azimuth - 360;
91
+ hi = sorted[0];
92
+ hiAz = hi.azimuth;
93
+ }
94
+ else if (loIdx === n - 1) {
95
+ // At or above the largest azimuth: wrap, next neighbour is the first.
96
+ lo = sorted[n - 1];
97
+ loAz = lo.azimuth;
98
+ hi = sorted[0];
99
+ hiAz = hi.azimuth + 360;
100
+ }
101
+ else {
102
+ lo = sorted[loIdx];
103
+ loAz = lo.azimuth;
104
+ hi = sorted[loIdx + 1];
105
+ hiAz = hi.azimuth;
106
+ }
107
+ const t = hiAz === loAz ? 0 : (az - loAz) / (hiAz - loAz);
108
+ return lo.elevation + t * (hi.elevation - lo.elevation);
109
+ }
110
+ /**
111
+ * Atmospheric refraction at a given apparent altitude, in degrees, at standard
112
+ * atmosphere (1010 hPa, 10 °C). Sinclair's formula below 15°, Bennett's at or
113
+ * above 15° — the pairing the Chai Tables use.
114
+ * @param apparentAltitude apparent altitude of the body above the horizon, in degrees
115
+ */
116
+ function refractionAtApparentAltitude(apparentAltitude) {
117
+ const P = 1010;
118
+ const T = 10;
119
+ const a = apparentAltitude;
120
+ if (a < 15) {
121
+ return (((P / (T + 273)) * (0.1594 + 0.0196 * a + 0.00002 * a * a)) /
122
+ (1 + 0.505 * a + 0.0845 * a * a));
123
+ }
124
+ return (((1 / 60) * (P / 1010) * (283 / (273 + T))) /
125
+ Math.tan(((a + 7.31 / (a + 4.4)) * Math.PI) / 180));
126
+ }
127
+ /**
128
+ * Given the sun's geometric centre altitude, returns the apparent altitude of
129
+ * its upper limb — adding the semidiameter and solving the implicit
130
+ * refraction equation `β = a + SD + R(β)` by fixed-point iteration.
131
+ *
132
+ * `upperLimbApparentAltitude(-0.8333)` is ≈ 0, i.e. the standard sea-level
133
+ * sunrise/sunset definition (upper limb on the astronomical horizon).
134
+ * @param centerGeometricAltitude geometric altitude of the sun's centre, in degrees
135
+ */
136
+ function upperLimbApparentAltitude(centerGeometricAltitude) {
137
+ const base = centerGeometricAltitude + SOLAR_SEMIDIAMETER;
138
+ let beta = base + refractionAtApparentAltitude(base);
139
+ for (let i = 0; i < 4; i++) {
140
+ beta = base + refractionAtApparentAltitude(beta);
141
+ }
142
+ return beta;
143
+ }
144
+
145
+ export { SOLAR_SEMIDIAMETER, horizonElevation, refractionAtApparentAltitude, upperLimbApparentAltitude };
146
+ //# sourceMappingURL=horizon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"horizon.js","sources":["../../../src/horizon.ts"],"sourcesContent":["/**\n * Pure arithmetic for the \"visible\" sunrise/sunset (_netz ha-nireh_,\n * הנץ הנראה): resolving a caller-supplied terrain horizon profile, atmospheric\n * refraction, and the apparent altitude of the sun's upper limb.\n *\n * The method follows Keller & Hall, _Using a digital terrain model to\n * calculate visual sunrise and sunset times_, Computers & Geosciences 26\n * (2000) 991–1000, https://doi.org/10.1016/S0098-3004(00)00058-3 (a copy is\n * hosted at http://www.chaitables.com/DblHallpaperpub.htm), and their part II,\n * Computers & Geosciences 162 (2022) 105044,\n * https://doi.org/10.1016/j.cageo.2022.105044, which re-examines the\n * refraction model with ray tracing and finds the standard formulas adequate.\n * It matches the conventions of the Chai Tables (https://www.chaitables.com),\n * the authors' public service that computes these times for the printed\n * Israeli calendars; their conventions are described at\n * http://www.chaitables.com/Introduction_to_DTM_calculations.html.\n *\n * Refraction uses the Sinclair model below 15° and the Bennett model at or\n * above 15°, both at standard atmosphere (1010 hPa, 10 °C), matching the Chai\n * Tables. Bennett's formula is from G. G. Bennett, _The calculation of\n * astronomical refraction in marine navigation_, Journal of Navigation 35\n * (1982) 255–259, https://doi.org/10.1017/S0373463300022037; Sinclair's\n * low-altitude formula is the one given in the _Explanatory Supplement to the\n * Astronomical Almanac_ (ed. Seidelmann, 1992), §3.283, and both are\n * reproduced in Keller & Hall (2000). \"Visible\" means the moment the sun's\n * _upper limb_ (semidiameter 16′), bent up by refraction, first clears\n * (sunrise) or last touches (sunset) the real skyline. No cushion or safety\n * margin is added — the raw computed instant is returned (the Chai Tables add\n * 20 seconds).\n *\n * This module is pure: it depends on nothing from `@hebcal/noaa` and performs\n * no I/O. The horizon profile is always supplied by the caller; building one\n * from terrain / digital-elevation-model data is outside this library.\n */\n\n/**\n * One measured point of a horizon profile: the apparent angular altitude of\n * the skyline in a single compass direction.\n */\nexport interface HorizonSample {\n /**\n * Degrees clockwise from true north: 0 = N, 90 = E, 180 = S, 270 = W.\n */\n azimuth: number;\n /**\n * Apparent angular altitude of the highest obstruction in that direction,\n * in degrees above the observer's astronomical horizon (negative where the\n * horizon dips below it, e.g. the sea seen from a height).\n */\n elevation: number;\n}\n\n/**\n * The apparent altitude of the skyline as a function of compass azimuth. May\n * be one of:\n *\n * - a constant `number` — the same elevation in every direction;\n * - a non-empty list of {@link HorizonSample}s in any order or spacing, with\n * azimuths in `[0, 360)`, linearly interpolated (wrapping past 360°/0°);\n * - a function `(azimuth: number) => number` returning the elevation in\n * degrees for a given azimuth.\n */\nexport type HorizonProfile =\n number | readonly HorizonSample[] | ((azimuth: number) => number);\n\n/**\n * The sun's angular semidiameter in degrees (16 arcminutes), matching the\n * value `@hebcal/noaa` folds into its `GEOMETRIC_ZENITH` adjustment.\n */\nexport const SOLAR_SEMIDIAMETER = 16 / 60;\n\n/**\n * Resolves a {@link HorizonProfile} at a single azimuth.\n *\n * A constant returns itself; a function is invoked; a sample list is linearly\n * interpolated between its two neighbouring samples by azimuth, wrapping\n * around 360°/0°. A single sample behaves as a constant.\n * @param profile the horizon profile\n * @param azimuth degrees clockwise from true north\n * @throws {TypeError} for an empty sample array or a non-finite constant\n */\nexport function horizonElevation(profile: HorizonProfile, azimuth: number): number {\n if (typeof profile === 'number') {\n if (!Number.isFinite(profile)) {\n throw new TypeError(`invalid horizon elevation: ${profile}`);\n }\n return profile;\n }\n if (typeof profile === 'function') {\n return profile(azimuth);\n }\n const n = profile.length;\n if (n === 0) {\n throw new TypeError('horizon profile has no samples');\n }\n if (n === 1) {\n return profile[0].elevation;\n }\n const sorted = [...profile].sort((a, b) => a.azimuth - b.azimuth);\n let az = azimuth % 360;\n if (az < 0) {\n az += 360;\n }\n // Largest sample azimuth that is still <= the query azimuth.\n let loIdx = -1;\n for (let i = 0; i < n; i++) {\n if (sorted[i].azimuth <= az) {\n loIdx = i;\n } else {\n break;\n }\n }\n let lo: HorizonSample;\n let hi: HorizonSample;\n let loAz: number;\n let hiAz: number;\n if (loIdx === -1) {\n // Below the smallest azimuth: wrap, previous neighbour is the last sample.\n lo = sorted[n - 1];\n loAz = lo.azimuth - 360;\n hi = sorted[0];\n hiAz = hi.azimuth;\n } else if (loIdx === n - 1) {\n // At or above the largest azimuth: wrap, next neighbour is the first.\n lo = sorted[n - 1];\n loAz = lo.azimuth;\n hi = sorted[0];\n hiAz = hi.azimuth + 360;\n } else {\n lo = sorted[loIdx];\n loAz = lo.azimuth;\n hi = sorted[loIdx + 1];\n hiAz = hi.azimuth;\n }\n const t = hiAz === loAz ? 0 : (az - loAz) / (hiAz - loAz);\n return lo.elevation + t * (hi.elevation - lo.elevation);\n}\n\n/**\n * Atmospheric refraction at a given apparent altitude, in degrees, at standard\n * atmosphere (1010 hPa, 10 °C). Sinclair's formula below 15°, Bennett's at or\n * above 15° — the pairing the Chai Tables use.\n * @param apparentAltitude apparent altitude of the body above the horizon, in degrees\n */\nexport function refractionAtApparentAltitude(apparentAltitude: number): number {\n const P = 1010;\n const T = 10;\n const a = apparentAltitude;\n if (a < 15) {\n return (\n ((P / (T + 273)) * (0.1594 + 0.0196 * a + 0.00002 * a * a)) /\n (1 + 0.505 * a + 0.0845 * a * a)\n );\n }\n return (\n ((1 / 60) * (P / 1010) * (283 / (273 + T))) /\n Math.tan(((a + 7.31 / (a + 4.4)) * Math.PI) / 180)\n );\n}\n\n/**\n * Given the sun's geometric centre altitude, returns the apparent altitude of\n * its upper limb — adding the semidiameter and solving the implicit\n * refraction equation `β = a + SD + R(β)` by fixed-point iteration.\n *\n * `upperLimbApparentAltitude(-0.8333)` is ≈ 0, i.e. the standard sea-level\n * sunrise/sunset definition (upper limb on the astronomical horizon).\n * @param centerGeometricAltitude geometric altitude of the sun's centre, in degrees\n */\nexport function upperLimbApparentAltitude(centerGeometricAltitude: number): number {\n const base = centerGeometricAltitude + SOLAR_SEMIDIAMETER;\n let beta = base + refractionAtApparentAltitude(base);\n for (let i = 0; i < 4; i++) {\n beta = base + refractionAtApparentAltitude(beta);\n }\n return beta;\n}\n"],"names":[],"mappings":"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"}
@@ -3,6 +3,7 @@ export { gematriya, gematriyaStrToNum } from '@hebcal/hdate';
3
3
  export { greg, months, HDate, Locale, type Headers, type StringArrayMap, type LocaleData, type MonthName, } from '@hebcal/hdate';
4
4
  import './locale.js';
5
5
  export { type CalOptions, type DailyLearningValue } from './CalOptions.js';
6
+ export { type HorizonProfile, type HorizonSample } from './horizon.js';
6
7
  export { HebrewDateEvent } from './HebrewDateEvent.js';
7
8
  export { Event, type FlagName, flags } from './event.js';
8
9
  export { GeoLocation, NOAACalculator } from '@hebcal/noaa';
package/dist/esm/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  export { version } from './pkgVersion.js';
3
3
  export { HDate, Locale, gematriya, gematriyaStrToNum, greg, months } from '@hebcal/hdate';
4
4
  import './locale.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { getPseudoISO, HDate } from '@hebcal/hdate';
3
3
  import { Zmanim } from './zmanim.js';
4
4
  import { getHolidaysOnDate } from './holidays.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months, HDate } from '@hebcal/hdate';
3
3
 
4
4
  const { NISAN, SIVAN, TAMUZ, AV } = months;
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { getHolidaysOnDate } from './holidays.js';
3
3
 
4
4
  /**
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale } from '@hebcal/hdate';
3
3
  export { Locale } from '@hebcal/hdate';
4
4
  import poAshkenazi from './ashkenazi.po.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { GeoLocation } from '@hebcal/noaa';
3
3
  import citiesJson from './cities.json.js';
4
4
  import QuickLRU from 'quick-lru';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months, HDate } from '@hebcal/hdate';
3
3
  import { flags } from './event.js';
4
4
  import { HolidayEvent } from './HolidayEvent.js';
package/dist/esm/molad.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import 'temporal-polyfill/global';
3
3
  import { Event, flags } from './event.js';
4
4
  import { HDate, Locale, pad2 } from '@hebcal/hdate';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { HDate, isLeapYear } from '@hebcal/hdate';
3
3
 
4
4
  /*
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import 'temporal-polyfill/global';
3
3
  import QuickLRU from 'quick-lru';
4
4
 
package/dist/esm/omer.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { Locale, gematriya } from '@hebcal/hdate';
3
3
  import { Event, flags } from './event.js';
4
4
  import './locale.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import './locale.js';
3
3
  import { smartApostrophe } from './string.js';
4
4
  import { Locale } from '@hebcal/hdate';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { HDate, months } from '@hebcal/hdate';
3
3
  import { ParshaEvent } from './ParshaEvent.js';
4
4
  import { getSedra } from './sedra.js';
@@ -1,2 +1,2 @@
1
1
  /** DO NOT EDIT THIS AUTO-GENERATED FILE! */
2
- export declare const version = "6.14.7";
2
+ export declare const version = "6.15.0";
@@ -1,6 +1,6 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  /** DO NOT EDIT THIS AUTO-GENERATED FILE! */
3
- const version = '6.14.7';
3
+ const version = '6.15.0';
4
4
 
5
5
  export { version };
6
6
  //# sourceMappingURL=pkgVersion.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pkgVersion.js","sources":["../../../src/pkgVersion.ts"],"sourcesContent":["/** DO NOT EDIT THIS AUTO-GENERATED FILE! */\nexport const version = '6.14.7';\n"],"names":[],"mappings":";AAAA;AACO,MAAM,OAAO,GAAG;;"}
1
+ {"version":3,"file":"pkgVersion.js","sources":["../../../src/pkgVersion.ts"],"sourcesContent":["/** DO NOT EDIT THIS AUTO-GENERATED FILE! */\nexport const version = '6.15.0';\n"],"names":[],"mappings":";AAAA;AACO,MAAM,OAAO,GAAG;;"}
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  /** Countries that conventionally use a 12-hour clock */
3
3
  const hour12cc = new Set([
4
4
  'US',
package/dist/esm/sedra.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { HDate, months } from '@hebcal/hdate';
3
3
  import QuickLRU from 'quick-lru';
4
4
  import './locale.js';
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  var sefira = {
3
3
  "ps67lines": [
4
4
  "אֱלֹהִים יְחָנֵּנוּ וִיבָרְכֵנוּ יָאֵר־פָּנָיו אִתָּנוּ סֶלָה",
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  import { months } from '@hebcal/hdate';
3
3
  import { flags } from './event.js';
4
4
 
@@ -1,4 +1,4 @@
1
- /*! @hebcal/core v6.14.7, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
1
+ /*! @hebcal/core v6.15.0, distributed under GPLv2 or later https://www.gnu.org/licenses/gpl-2.0.txt */
2
2
  function smartApostrophe(str) {
3
3
  return str.replaceAll("'", '’');
4
4
  }