@hebcal/core 5.10.1 → 6.0.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 (67) hide show
  1. package/README.md +2 -2
  2. package/dist/HolidayEvent.d.ts +5 -6
  3. package/dist/ParshaEvent.d.ts +3 -9
  4. package/dist/bundle.js +4416 -6366
  5. package/dist/bundle.js.map +1 -1
  6. package/dist/bundle.min.js +20 -20
  7. package/dist/bundle.min.js.map +1 -1
  8. package/dist/candles.d.ts +2 -2
  9. package/dist/esm/DailyLearning.js +1 -1
  10. package/dist/esm/HebrewDateEvent.js +3 -3
  11. package/dist/esm/HebrewDateEvent.js.map +1 -1
  12. package/dist/esm/HolidayEvent.d.ts +5 -6
  13. package/dist/esm/HolidayEvent.js +30 -15
  14. package/dist/esm/HolidayEvent.js.map +1 -1
  15. package/dist/esm/MevarchimChodeshEvent.js +1 -1
  16. package/dist/esm/ParshaEvent.d.ts +3 -9
  17. package/dist/esm/ParshaEvent.js +10 -19
  18. package/dist/esm/ParshaEvent.js.map +1 -1
  19. package/dist/esm/TimedEvent.js +1 -1
  20. package/dist/esm/YomKippurKatanEvent.js +1 -1
  21. package/dist/esm/ashkenazi.po.js +1 -1
  22. package/dist/esm/calendar.js +23 -14
  23. package/dist/esm/calendar.js.map +1 -1
  24. package/dist/esm/candles.d.ts +2 -2
  25. package/dist/esm/candles.js +7 -8
  26. package/dist/esm/candles.js.map +1 -1
  27. package/dist/esm/event.d.ts +4 -5
  28. package/dist/esm/event.js +7 -11
  29. package/dist/esm/event.js.map +1 -1
  30. package/dist/esm/getStartAndEnd.js +1 -1
  31. package/dist/esm/hallel.js +1 -1
  32. package/dist/esm/he-x-NoNikud.po.js +1 -1
  33. package/dist/esm/he.po.js +1 -1
  34. package/dist/esm/hebcal.js +1 -1
  35. package/dist/esm/holidays.js +6 -34
  36. package/dist/esm/holidays.js.map +1 -1
  37. package/dist/esm/index.js +1 -1
  38. package/dist/esm/isAssurBemlacha.js +1 -1
  39. package/dist/esm/locale.js +2 -12
  40. package/dist/esm/locale.js.map +1 -1
  41. package/dist/esm/location.js +1 -1
  42. package/dist/esm/modern.js +1 -1
  43. package/dist/esm/molad.js +2 -2
  44. package/dist/esm/molad.js.map +1 -1
  45. package/dist/esm/omer.js +4 -4
  46. package/dist/esm/omer.js.map +1 -1
  47. package/dist/esm/parshaName.js +2 -2
  48. package/dist/esm/parshaName.js.map +1 -1
  49. package/dist/esm/parshaYear.js +2 -2
  50. package/dist/esm/parshaYear.js.map +1 -1
  51. package/dist/esm/pkgVersion.d.ts +1 -1
  52. package/dist/esm/pkgVersion.js +2 -2
  53. package/dist/esm/pkgVersion.js.map +1 -1
  54. package/dist/esm/reformatTimeStr.js +1 -1
  55. package/dist/esm/sedra.d.ts +2 -20
  56. package/dist/esm/sedra.js +10 -31
  57. package/dist/esm/sedra.js.map +1 -1
  58. package/dist/esm/staticHolidays.js +2 -9
  59. package/dist/esm/staticHolidays.js.map +1 -1
  60. package/dist/esm/tachanun.js +1 -1
  61. package/dist/esm/zmanim.js +1 -1
  62. package/dist/event.d.ts +4 -5
  63. package/dist/pkgVersion.d.ts +1 -1
  64. package/dist/sedra.d.ts +2 -20
  65. package/package.json +16 -26
  66. package/dist/index.cjs +0 -8378
  67. package/dist/index.cjs.map +0 -1
package/README.md CHANGED
@@ -32,12 +32,12 @@ This package exports 3 categories of output:
32
32
 
33
33
  - `dist/bundle.min.js`: This includes all dependencies in a single JS file. It's quite large (174KB minified), and should only be used if you aren't using a bundler.
34
34
  - `dist/index.cjs`: This includes all of this package's code in a single bundle.
35
- - `dist/es/`: This directory contains ES modules for each source file in the package. If you're using Rollup, Vite, or another bundler, you should import from here to reduce output sizes.
35
+ - `dist/esm/`: This directory contains ES modules for each source file in the package. If you're using Rollup, Vite, or another bundler, you should import from here to reduce output sizes.
36
36
  - These files do not include polyfills; if you want to support older browsers, use <https://github.com/rollup/plugins/tree/master/packages/babel#babelhelpers>
37
37
  - To make tree-shaking work better, import from the most specific file possible; avoid importing from `index` or `hebcal`. Some APIs may still need to be moved to specific files. For example:
38
38
 
39
39
  ```ts
40
- import {getHolidaysOnDate} from '@hebcal/core/dist/es/holidays';
40
+ import {getHolidaysOnDate} from '@hebcal/core/dist/esm/holidays';
41
41
  ```
42
42
 
43
43
  - This can save hundreds of kilobytes by dropping Zmanim dependencies if your code doesn't use them.
@@ -5,7 +5,6 @@ import './locale';
5
5
  export declare class HolidayEvent extends Event {
6
6
  /** During Sukkot or Pesach */
7
7
  cholHaMoedDay?: number;
8
- chanukahDay?: number;
9
8
  /**
10
9
  * `true` if the fast day was postponed a day to avoid Shabbat.
11
10
  * - Tish'a B'Av postponed from the 9th to the 10th
@@ -29,11 +28,6 @@ export declare class HolidayEvent extends Event {
29
28
  * @param [locale] Optional locale name (defaults to active locale).
30
29
  */
31
30
  renderBrief(locale?: string): string;
32
- /**
33
- * Makes a clone of this Event object
34
- * @deprecated
35
- */
36
- clone(): HolidayEvent;
37
31
  }
38
32
  /**
39
33
  * Because Asara B'Tevet often occurs twice in the same Gregorian year,
@@ -47,6 +41,11 @@ export declare class AsaraBTevetEvent extends HolidayEvent {
47
41
  * we subclass HolidayEvent to generate the correct URL.
48
42
  */
49
43
  export declare class ChanukahEvent extends HolidayEvent {
44
+ readonly chanukahDay?: number;
45
+ /**
46
+ * @param chanukahDay should be undefined for 1st night of Chanukah
47
+ */
48
+ constructor(date: HDate, desc: string, mask: number, chanukahDay?: number);
50
49
  urlDateSuffix(): string;
51
50
  }
52
51
  /** Represents Rosh Hashana, the Jewish New Year */
@@ -1,18 +1,12 @@
1
1
  import { Event } from './event';
2
- import { HDate } from '@hebcal/hdate';
2
+ import { SedraResult } from './sedra';
3
3
  import './locale';
4
4
  /**
5
5
  * Represents one of 54 weekly Torah portions, always on a Saturday
6
6
  */
7
7
  export declare class ParshaEvent extends Event {
8
- readonly parsha: string[];
9
- readonly il: boolean;
10
- readonly num: number | number[];
11
- /**
12
- * @param parsha - untranslated name of single or double parsha,
13
- * such as ['Bereshit'] or ['Achrei Mot', 'Kedoshim']
14
- */
15
- constructor(date: HDate, parsha: string[], il?: boolean, num?: number | number[]);
8
+ readonly p: SedraResult;
9
+ constructor(parsha: SedraResult);
16
10
  /**
17
11
  * @param [locale] Optional locale name (i.e: `'he'`, `'fr'`). Defaults to active locale.
18
12
  */