Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@hebcal/core

Package Overview
Dependencies
Maintainers
1
Versions
274
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hebcal/core - npm Package Compare versions

Comparing version 5.4.8 to 5.4.9

dist/bundle.js.map

3

dist/CalOptions.d.ts
import { HDate } from '@hebcal/hdate';
import { Location } from './location';
export type DailyLearningValue = boolean | number | string;
/**

@@ -155,4 +156,4 @@ * Options to configure which events are returned

dailyLearning?: {
[x: string]: any;
[x: string]: DailyLearningValue;
};
};

@@ -11,4 +11,2 @@ import { HDate } from '@hebcal/hdate';

* Register a new learning calendar.
* @param {string} name
* @param {Function} calendar
*/

@@ -19,8 +17,7 @@ static addCalendar(name: string, calendar: Function): void;

* is no learning from this calendar on this date.
* @param {string} name
* @param {HDate} hd
* @param {boolean} il
* @return {Event | null}
* @param name
* @param hd
* @param il
*/
static lookup(name: string, hd: HDate, il: boolean): Event | null;
}
import { HDate } from '@hebcal/hdate';
import './locale';
/**
* Holiday flags for Event
* Holiday flags for Event. These flags are typically
* combined using bitwise arithmetic to form a mask.
* @readonly

@@ -64,16 +65,35 @@ * @enum {number}

};
/** Represents an Event with a title, date, and flags */
/**
* Represents an Event with a title, date, and flags.
*
* Events are used to represent holidays, candle-lighting times,
* Torah readings, and more.
*
* To get the title of the event a language other than English
* with Sephardic transliterations, use the `render()` method.
*/
export declare class Event {
/** Hebrew date of this event */
readonly date: HDate;
/**
* Untranslated title of this event. Note that these description
* strings are always in English and will remain stable across releases.
* To get the title of the event in another language, use the
* `render()` method.
*/
readonly desc: string;
/** Bitmask of optional event flags. See {@link flags} */
readonly mask: number;
/** Optional emoji character such as ✡️, 🕯️, 🕎, 🕍, 🌒 */
emoji?: string;
/** Optional longer description or memo text */
memo?: string;
/** Alarms are used by iCalendar feeds */
alarm?: Date | string | boolean;
/**
* Constructs Event
* @param {HDate} date Hebrew date event occurs
* @param {string} desc Description (not translated)
* @param {number} [mask=0] optional bitmask of holiday flags (see {@link flags})
* @param {Object} [attrs={}] optional additional attributes (e.g. `eventTimeStr`, `cholHaMoedDay`)
* @param date Hebrew date event occurs
* @param desc Description (not translated)
* @param [mask=0] optional bitmask of holiday flags (see {@link flags})
* @param [attrs={}] optional additional attributes (e.g. `eventTimeStr`, `cholHaMoedDay`)
*/

@@ -83,8 +103,9 @@ constructor(date: HDate, desc: string, mask?: number, attrs?: object);

* Hebrew date of this event
* @return {HDate}
*/
getDate(): HDate;
/**
* Untranslated description of this event
* @return {string}
* Untranslated title of this event. Note that these description
* strings are always in English and will remain stable across releases.
* To get the title of the event in another language, use the
* `render()` method.
*/

@@ -94,3 +115,2 @@ getDesc(): string;

* Bitmask of optional event flags. See {@link flags}
* @return {number}
*/

@@ -105,4 +125,3 @@ getFlags(): number;

* ev.render('ashkenazi'); // 'Shavuos'
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -114,4 +133,3 @@ render(locale?: string): string;

* a shorter text (e.g. without a time or added description).
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -121,3 +139,2 @@ renderBrief(locale?: string): string;

* Optional holiday-specific Emoji or `null`.
* @return {string | null}
*/

@@ -127,6 +144,5 @@ getEmoji(): string | null;

* Returns a simplified (untranslated) description for this event. For example,
* the {@link HolidayEvent} class supports
* the `HolidayEvent` class supports
* "Erev Pesach" => "Pesach", and "Sukkot III (CH''M)" => "Sukkot".
* For many holidays the basename and the event description are the same.
* @return {string}
*/

@@ -137,3 +153,2 @@ basename(): string;

* Returns `undefined` for events with no detail page.
* @return {string | undefined}
*/

@@ -148,3 +163,2 @@ url(): string | undefined;

* ev2.observedInIsrael(); // true
* @return {boolean}
*/

@@ -159,3 +173,2 @@ observedInIsrael(): boolean;

* ev2.observedInDiaspora(); // true
* @return {boolean}
*/

@@ -172,4 +185,3 @@ observedInDiaspora(): boolean;

* ev2.observedIn(true); // true
* @param {boolean} il
* @return {boolean}
* @param il
*/

@@ -179,3 +191,2 @@ observedIn(il: boolean): boolean;

* Makes a clone of this Event object
* @return {Event}
*/

@@ -185,5 +196,4 @@ clone(): Event;

* Returns a list of event categories
* @return {string[]}
*/
getCategories(): string[];
}

@@ -5,6 +5,3 @@ import { HDate } from '@hebcal/hdate';

* @private
* @param {Event[]} events
* @param {HDate} hdate
* @return {number}
*/
export declare function hallel_(events: Event[], hdate: HDate): number;

@@ -122,4 +122,2 @@ import { HDate } from '@hebcal/hdate';

* }
* @param {CalOptions} [options={}]
* @return {Event[]}
*/

@@ -149,5 +147,5 @@ static calendar(options?: CalOptions): Event[];

* console.log(hd.greg().toLocaleDateString('en-US')); // '3/26/2020'
* @param {number} hyear Hebrew year
* @param {Date|HDate} gdate Gregorian or Hebrew date of event
* @return {HDate | undefined} anniversary occurring in `hyear`
* @param hyear Hebrew year
* @param gdate Gregorian or Hebrew date of event
* @returns anniversary occurring in `hyear`
*/

@@ -185,5 +183,5 @@ static getBirthdayOrAnniversary(hyear: number, gdate: Date | HDate): HDate | undefined;

* console.log(hd.greg().toLocaleDateString('en-US')); // '2/25/2020'
* @param {number} hyear Hebrew year
* @param {Date|HDate} gdate Gregorian or Hebrew date of death
* @return {HDate | undefined} anniversary occurring in hyear
* @param hyear Hebrew year
* @param gdate Gregorian or Hebrew date of death
* @returns anniversary occurring in hyear
*/

@@ -195,5 +193,3 @@ static getYahrzeit(hyear: number, gdate: Date | HDate): HDate | undefined;

* or `flags.CHUL_ONLY` depending on Israel vs. Diaspora holiday scheme.
* @function
* @param {number} year Hebrew year
* @return {HolidayYearMap}
* @param year Hebrew year
*/

@@ -203,5 +199,4 @@ static getHolidaysForYear(year: number): HolidayYearMap;

* Returns an array of holidays for the year
* @param {number} year Hebrew year
* @param {boolean} il use the Israeli schedule for holidays
* @return {HolidayEvent[]}
* @param year Hebrew year
* @param il use the Israeli schedule for holidays
*/

@@ -211,5 +206,4 @@ static getHolidaysForYearArray(year: number, il: boolean): HolidayEvent[];

* Returns an array of Events on this date (or `undefined` if no events)
* @param {HDate|Date|number} date Hebrew Date, Gregorian date, or absolute R.D. day number
* @param {boolean} [il] use the Israeli schedule for holidays
* @return {HolidayEvent[] | undefined}
* @param date Hebrew Date, Gregorian date, or absolute R.D. day number
* @param [il] use the Israeli schedule for holidays
*/

@@ -219,5 +213,2 @@ static getHolidaysOnDate(date: HDate | Date | number, il?: boolean): HolidayEvent[] | undefined;

* Eruv Tavshilin
* @param {Date | HDate} date
* @param {boolean} il
* @return {boolean}
*/

@@ -231,9 +222,7 @@ static eruvTavshilin(date: Date | HDate, il: boolean): boolean;

* If `options.hour12` is `true`, locale is ignored and always returns 12-hour time.
* @param {string} timeStr - original time like "20:30"
* @param {string} suffix - "p" or "pm" or " P.M.". Add leading space if you want it
* @param {CalOptions} options
* @return {string}
* @param timeStr - original time like "20:30"
* @param suffix - "p" or "pm" or " P.M.". Add leading space if you want it
* @param options
*/
static reformatTimeStr(timeStr: string, suffix: string, options: CalOptions): string;
/** @return {string} */
static version(): string;

@@ -243,6 +232,2 @@ /**

* created and cached instance.
* @function
* @param {number} hyear
* @param {boolean} il
* @return {Sedra}
*/

@@ -263,6 +248,2 @@ static getSedra(hyear: number, il: boolean): Sedra;

* 2 - Whole Hallel
*
* @param {HDate} hdate
* @param {boolean} il
* @return {number}
*/

@@ -285,7 +266,4 @@ static hallel(hdate: HDate, il: boolean): number;

* Tachanun is not said at Shacharit on Shabbat, but is at Mincha, usually.
* @param {HDate} hdate
* @param {boolean} il
* @return {TachanunResult}
*/
static tachanun(hdate: HDate, il: boolean): TachanunResult;
}

@@ -7,7 +7,7 @@ import { HDate } from '@hebcal/hdate';

/**
* @param {HDate} date
* @param date
*/
constructor(date: HDate);
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @param [locale] Optional locale name (defaults to active locale).
* @example

@@ -20,3 +20,2 @@ * import {HDate, HebrewDateEvent, months} from '@hebcal/core';

* console.log(ev.render('he')); // 'ט״ו חֶשְׁוָן תשס״ט'
* @return {string}
*/

@@ -26,8 +25,7 @@ render(locale?: string): string;

* @private
* @param {string} locale
* @return {string}
* @param locale
*/
private renderBriefHebrew;
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @param [locale] Optional locale name (defaults to active locale).
* @example

@@ -40,5 +38,4 @@ * import {HDate, HebrewDateEvent, months} from '@hebcal/core';

* console.log(ev.renderBrief('he')); // 'ט״ו חֶשְׁוָן'
* @return {string}
*/
renderBrief(locale?: string): string;
}

@@ -20,16 +20,10 @@ import { HDate } from '@hebcal/hdate';

endEvent?: TimedEvent;
/** @return {string} */
basename(): string;
/** @return {string | undefined} */
url(): string | undefined;
/** @return {string} */
urlDateSuffix(): string;
/** @return {string} */
getEmoji(): string;
/** @return {string[]} */
getCategories(): string[];
/**
* Returns (translated) description of this event
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -41,4 +35,3 @@ render(locale?: string): string;

* a shorter text (e.g. without a time or added description).
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -48,3 +41,2 @@ renderBrief(locale?: string): string;

* Makes a clone of this Event object
* @return {Event}
*/

@@ -58,3 +50,2 @@ clone(): HolidayEvent;

export declare class AsaraBTevetEvent extends HolidayEvent {
/** @return {string} */
urlDateSuffix(): string;

@@ -67,5 +58,5 @@ }

* @private
* @param {HDate} date Hebrew date event occurs
* @param {number} hyear Hebrew year
* @param {number} mask optional holiday flags
* @param date Hebrew date event occurs
* @param hyear Hebrew year
* @param mask optional holiday flags
*/

@@ -75,7 +66,5 @@ constructor(date: HDate, hyear: number, mask: number);

* Returns (translated) description of this event
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
render(locale?: string): string;
/** @return {string} */
getEmoji(): string;

@@ -87,4 +76,4 @@ }

* Constructs Rosh Chodesh event
* @param {HDate} date Hebrew date event occurs
* @param {string} monthName Hebrew month name (not translated)
* @param date Hebrew date event occurs
* @param monthName Hebrew month name (not translated)
*/

@@ -94,10 +83,7 @@ constructor(date: HDate, monthName: string);

* Returns (translated) description of this event
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
render(locale?: string): string;
/** @return {string} */
basename(): string;
/** @return {string} */
getEmoji(): string;
}
export { gematriya, gematriyaStrToNum } from '@hebcal/hdate';
export { greg, months, HDate, Locale, Headers, StringArrayMap, LocaleData } from '@hebcal/hdate';
export { greg, months, HDate, Locale, Headers, StringArrayMap, LocaleData, } from '@hebcal/hdate';
import './locale';
export { CalOptions } from './CalOptions';
export { CalOptions, DailyLearningValue } from './CalOptions';
export { HebrewDateEvent } from './HebrewDateEvent';

@@ -16,3 +16,4 @@ export { Event, flags } from './event';

export { ParshaEvent } from './ParshaEvent';
export { HolidayEvent, AsaraBTevetEvent, RoshChodeshEvent, RoshHashanaEvent } from './HolidayEvent';
export { HolidayEvent, AsaraBTevetEvent, RoshChodeshEvent, RoshHashanaEvent, } from './HolidayEvent';
export { HolidayYearMap } from './holidays';
export { MevarchimChodeshEvent } from './MevarchimChodeshEvent';

@@ -19,0 +20,0 @@ export { holidayDesc } from './staticHolidays';

@@ -9,31 +9,24 @@ import { GeoLocation } from '@hebcal/noaa';

* Initialize a Location instance
* @param {number} latitude - Latitude as a decimal, valid range -90 thru +90 (e.g. 41.85003)
* @param {number} longitude - Longitude as a decimal, valid range -180 thru +180 (e.g. -87.65005)
* @param {boolean} il - in Israel (true) or Diaspora (false)
* @param {string} tzid - Olson timezone ID, e.g. "America/Chicago"
* @param {string} [cityName] - optional descriptive city name
* @param {string} [countryCode] - ISO 3166 alpha-2 country code (e.g. "FR")
* @param {string|number} [geoid] - optional string or numeric geographic ID
* @param {number} [elevation] - in meters (default `0`)
* @param latitude - Latitude as a decimal, valid range -90 thru +90 (e.g. 41.85003)
* @param longitude - Longitude as a decimal, valid range -180 thru +180 (e.g. -87.65005)
* @param il - in Israel (true) or Diaspora (false)
* @param tzid - Olson timezone ID, e.g. "America/Chicago"
* @param [cityName] - optional descriptive city name
* @param [countryCode] - ISO 3166 alpha-2 country code (e.g. "FR")
* @param [geoid] - optional string or numeric geographic ID
* @param [elevation] - in meters (default `0`)
*/
constructor(latitude: number, longitude: number, il: boolean, tzid: string, cityName?: string, countryCode?: string, geoid?: string | number, elevation?: number);
/** @return {boolean} */
getIsrael(): boolean;
/** @return {string | null} */
getName(): string | null;
/**
* Returns the location name, up to the first comma
* @return {string | null}
*/
getShortName(): string | null;
/** @return {string | undefined} */
getCountryCode(): string | undefined;
/** @return {string} */
getTzid(): string;
/**
* Gets a 24-hour time formatter (e.g. 07:41 or 20:03) for this location
* @return {Intl.DateTimeFormat}
*/
getTimeFormatter(): Intl.DateTimeFormat;
/** @return {string | number | undefined} */
getGeoId(): string | number | undefined;

@@ -56,13 +49,10 @@ /**

* 'Washington DC', 'Worcester'
* @param {string} name
* @return {Location|undefined}
* @param name
*/
static lookup(name: string): Location | undefined;
/** @return {string} */
toString(): string;
/**
* Converts legacy Hebcal timezone to a standard Olson tzid.
* @param {number} tz integer, GMT offset in hours
* @param {string} dst 'none', 'eu', 'usa', or 'israel'
* @return {string | undefined}
* @param tz integer, GMT offset in hours
* @param dst 'none', 'eu', 'usa', or 'israel'
*/

@@ -74,6 +64,5 @@ static legacyTzToTzid(tz: number, dst: string): string | undefined;

* Location.getUsaTzid('AZ', 7, 'Y') // 'America/Denver'
* @param {string} state two-letter all-caps US state abbreviation like 'CA'
* @param {number} tz positive number, 5=America/New_York, 8=America/Los_Angeles
* @param {string} dst single char 'Y' or 'N'
* @return {string}
* @param state two-letter all-caps US state abbreviation like 'CA'
* @param tz positive number, 5=America/New_York, 8=America/Los_Angeles
* @param dst single char 'Y' or 'N'
*/

@@ -85,7 +74,4 @@ static getUsaTzid(state: string, tz: number, dst: string): string;

* and `true` if successfully added.
* @param {string} cityName
* @param {Location} location
* @return {boolean}
*/
static addLocation(cityName: string, location: Location): boolean;
}

@@ -9,13 +9,11 @@ import { HDate } from '@hebcal/hdate';

* Constructs Mevarchim haChodesh event
* @param {HDate} date Hebrew date event occurs
* @param {string} monthName Hebrew month name (not translated)
* @param {string} [memo]
* @param date Hebrew date event occurs
* @param monthName Hebrew month name (not translated)
* @param [memo]
*/
constructor(date: HDate, monthName: string, memo: string);
/** @return {string} */
basename(): string;
/**
* Returns (translated) description of this event
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -25,6 +23,5 @@ render(locale?: string): string;

* Returns (translated) description of this event
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
renderBrief(locale?: string): string;
}

@@ -10,4 +10,3 @@ import { HDate } from '@hebcal/hdate';

* @private
* @param {number} year
* @return {HDate|null}
* @param year
*/

@@ -18,5 +17,4 @@ export declare function dateYomHaShoah(year: number): HDate | null;

* @private
* @param {number} year
* @return {HDate|null}
* @param year
*/
export declare function dateYomHaZikaron(year: number): HDate | null;

@@ -12,38 +12,34 @@ import { Event } from './event';

* Calculates the molad for a Hebrew month
* @param {number} year
* @param {number} month
* @param year
* @param month
*/
constructor(year: number, month: number);
/**
* @return {number}
*/
getYear(): number;
/**
* @return {number}
*/
getMonth(): number;
/**
* @return {string}
*/
getMonthName(): string;
/**
* @return {number} Day of Week (0=Sunday, 6=Saturday)
* @returns Day of Week (0=Sunday, 6=Saturday)
*/
getDow(): number;
/**
* @return {number} hour of day (0-23)
* @returns hour of day (0-23)
*/
getHour(): number;
/**
* @return {number} minutes past hour (0-59)
* @returns minutes past hour (0-59)
*/
getMinutes(): number;
/**
* @return {number} parts of a minute (0-17)
* @returns parts of a minute (0-17)
*/
getChalakim(): number;
/**
* @param {string} [locale] Optional locale name (defaults to active locale)
* @param {CalOptions} options
* @return {string}
* @param [locale] Optional locale name (defaults to active locale)
* @param options
*/

@@ -57,13 +53,12 @@ render(locale?: string, options?: CalOptions): string;

/**
* @param {HDate} date Hebrew date event occurs
* @param {number} hyear molad year
* @param {number} hmonth molad month
* @param {CalOptions} options
* @param date Hebrew date event occurs
* @param hyear molad year
* @param hmonth molad month
* @param options
*/
constructor(date: HDate, hyear: number, hmonth: number, options: CalOptions);
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
render(locale?: string): string;
}

@@ -11,9 +11,8 @@ import { HDate } from '@hebcal/hdate';

/**
* @param {HDate} date
* @param {number} omerDay
* @param date
* @param omerDay
*/
constructor(date: HDate, omerDay: number);
/**
* @param {string} lang
* @return {string}
* @param lang
*/

@@ -23,4 +22,3 @@ sefira(lang?: string): string;

* @todo use gettext()
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -30,19 +28,13 @@ render(locale?: string): string;

* Returns translation of "Omer day 22" without ordinal numbers.
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
renderBrief(locale?: string): string;
/** @return {string} */
getEmoji(): string;
/** @return {number} */
getWeeks(): number;
/** @return {number} */
getDaysWithinWeeks(): number;
/**
* @param {string} locale
* @return {string}
* @param locale
*/
getTodayIs(locale: string): string;
/** @return {string} */
url(): string;
}

@@ -12,20 +12,13 @@ import { Event } from './event';

/**
* @param {HDate} date
* @param {string[]} parsha - untranslated name of single or double parsha,
* @param parsha - untranslated name of single or double parsha,
* such as ['Bereshit'] or ['Achrei Mot', 'Kedoshim']
* @param {boolean} [il]
* @param {number|number[]} [num]
*/
constructor(date: HDate, parsha: string[], il?: boolean, num?: number | number[]);
/**
* @param {string} [locale] Optional locale name (i.e: `'he'`, `'fr'`). Defaults to active locale.
* @return {string}
* @param [locale] Optional locale name (i.e: `'he'`, `'fr'`). Defaults to active locale.
*/
render(locale?: string): string;
/** @return {string} */
basename(): string;
/** @return {string | undefined} */
url(): string | undefined;
/** @return {string} */
urlDateSuffix(): string;
}
/** DO NOT EDIT THIS AUTO-GENERATED FILE! */
export declare const version = "5.4.8";
export declare const version = "5.4.9";
import { CalOptions } from './CalOptions';
/**
* @private
* @param {string} timeStr - original time like "20:30"
* @param {string} suffix - "p" or "pm" or " P.M.". Add leading space if you want it
* @param {CalOptions} options
* @return {string}
* @param timeStr - original time like "20:30"
* @param suffix - "p" or "pm" or " P.M.". Add leading space if you want it
* @param options
*/
export declare function reformatTimeStr(timeStr: string, suffix: string, options?: CalOptions): string;

@@ -34,4 +34,4 @@ import { HDate } from '@hebcal/hdate';

* Caculates the Parashah HaShavua for an entire Hebrew year
* @param {number} hyear - Hebrew year (e.g. 5749)
* @param {boolean} il - Use Israel sedra schedule (false for Diaspora)
* @param hyear - Hebrew year (e.g. 5749)
* @param il - Use Israel sedra schedule (false for Diaspora)
*/

@@ -41,4 +41,3 @@ constructor(hyear: number, il: boolean);

* Returns the parsha (or parshiyot) read on Hebrew date
* @param {HDate|number} hd Hebrew date or R.D. days
* @return {string[]}
* @param hd Hebrew date or R.D. days
*/

@@ -48,5 +47,4 @@ get(hd: HDate | number): string[];

* Looks up parsha for the date, then returns a translated or transliterated string
* @param {HDate|number} hd Hebrew date or R.D. days
* @param {string} [locale] Optional locale name (i.e: `'he'`, `'fr'`). Defaults to active locale
* @return {string}
* @param hd Hebrew date or R.D. days
* @param [locale] Optional locale name (i.e: `'he'`, `'fr'`). Defaults to active locale
*/

@@ -57,4 +55,3 @@ getString(hd: HDate | number, locale?: string): string;

* Torah reading or special holiday reading
* @param {HDate|number} hd Hebrew date or R.D. days
* @return {boolean}
* @param hd Hebrew date or R.D. days
*/

@@ -65,4 +62,2 @@ isParsha(hd: HDate | number): boolean;

* or `null` if the parsha doesn't occur this year
* @param {number|string|string[]} parsha
* @return {HDate|null}
*/

@@ -73,3 +68,2 @@ find(parsha: number | string | string[]): HDate | null;

* Used by `@hebcal/triennial`
* @return {NumberOrString[]}
*/

@@ -79,11 +73,8 @@ getSedraArray(): NumberOrString[];

* R.D. date of the first Saturday on or after Rosh Hashana
* @return {number}
*/
getFirstSaturday(): number;
/** @return {number} */
getYear(): number;
/**
* Returns an object describing the parsha on the first Saturday on or after `hd`
* @param {HDate|number} hd Hebrew date or R.D. days
* @return {SedraResult}
* @param hd Hebrew date or R.D. days
*/

@@ -104,7 +95,6 @@ lookup(hd: HDate | number): SedraResult;

* @private
* @param {number} hyear
* @param {boolean} il
* @return {Sedra}
* @param hyear
* @param il
*/
export declare function getSedra_(hyear: number, il: boolean): Sedra;
export {};

@@ -14,8 +14,7 @@ import { HDate } from '@hebcal/hdate';

/**
* @param {string} desc Description (not translated)
* @param desc Description (not translated)
*/
constructor(date: HDate, desc: string, mask: number, eventTime: Date, location: Location, linkedEvent?: Event, options?: CalOptions);
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -25,7 +24,5 @@ render(locale?: string): string;

* Returns translation of "Candle lighting" without the time.
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
renderBrief(locale?: string): string;
/** @return {string[]} */
getCategories(): string[];

@@ -36,3 +33,2 @@ }

constructor(date: HDate, mask: number, eventTime: Date, location: Location, linkedEvent?: Event, options?: CalOptions);
/** @return {string} */
getEmoji(): string;

@@ -45,4 +41,3 @@ }

/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/

@@ -52,8 +47,6 @@ render(locale?: string): string;

* Returns translation of "Havdalah" without the time.
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
renderBrief(locale?: string): string;
/** @return {string} */
getEmoji(): string;
}

@@ -10,20 +10,16 @@ import { HDate } from '@hebcal/hdate';

* @private
* @param {HDate} date Hebrew date event occurs
* @param {string} nextMonthName name of the upcoming month
* @param date Hebrew date event occurs
* @param nextMonthName name of the upcoming month
*/
constructor(date: HDate, nextMonthName: string);
/** @return {string} */
basename(): string;
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
render(locale?: string): string;
/**
* @param {string} [locale] Optional locale name (defaults to active locale).
* @return {string}
* @param [locale] Optional locale name (defaults to active locale).
*/
renderBrief(locale?: string): string;
/** @return {string | undefined} */
url(): string | undefined;
}

@@ -37,6 +37,6 @@ import 'temporal-polyfill/global';

* Initialize a Zmanim instance.
* @param {GeoLocation} gloc GeoLocation including latitude, longitude, and timezone
* @param {Date|HDate} date Regular or Hebrew Date. If `date` is a regular `Date`,
* @param gloc GeoLocation including latitude, longitude, and timezone
* @param date Regular or Hebrew Date. If `date` is a regular `Date`,
* hours, minutes, seconds and milliseconds are ignored.
* @param {boolean} useElevation use elevation for calculations (default `false`).
* @param useElevation use elevation for calculations (default `false`).
* If `true`, use elevation to affect the calculation of all sunrise/sunset based

@@ -51,3 +51,2 @@ * zmanim. Note: there are some zmanim such as degree-based zmanim that are driven

* for zmanim support elevation adjustment
* @return {boolean}
*/

@@ -57,3 +56,3 @@ getUseElevation(): boolean;

* Enables or disables elevation adjustment for zmanim support elevation adjustment
* @param {boolean} useElevation
* @param useElevation
*/

@@ -65,5 +64,4 @@ setUseElevation(useElevation: boolean): void;

* This function does not support elevation adjustment.
* @param {number} angle
* @param {boolean} rising
* @return {Date}
* @param angle
* @param rising
*/

@@ -74,3 +72,2 @@ timeAtAngle(angle: number, rising: boolean): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -81,3 +78,2 @@ sunrise(): Date;

* This function does not support elevation adjustment.
* @return {Date}
*/

@@ -88,3 +84,2 @@ seaLevelSunrise(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -95,3 +90,2 @@ sunset(): Date;

* This function does not support elevation adjustment.
* @return {Date}
*/

@@ -103,3 +97,2 @@ seaLevelSunset(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -111,3 +104,2 @@ dawn(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -118,3 +110,2 @@ dusk(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -124,3 +115,2 @@ gregEve(): Date;

* @private
* @return {number}
*/

@@ -130,3 +120,2 @@ nightHour(): number;

* Midday – Chatzot; Sunrise plus 6 halachic hours
* @return {Date}
*/

@@ -137,3 +126,2 @@ chatzot(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -145,3 +133,2 @@ chatzotNight(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -153,3 +140,2 @@ alotHaShachar(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -161,3 +147,2 @@ misheyakir(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -168,4 +153,3 @@ misheyakirMachmir(): Date;

* @private
* @param {number} hours
* @return {Date}
* @param hours
*/

@@ -176,3 +160,2 @@ getShaahZmanisBasedZman(hours: number): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -189,3 +172,2 @@ sofZmanShma(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -208,3 +190,2 @@ sofZmanTfilla(): Date;

* 72 minutes after sea-level sunset.
* @return {Date}
*/

@@ -216,3 +197,2 @@ sofZmanShmaMGA(): Date;

* dawn to nightfall with both being 16.1° below the horizon.
* @return {Date}
*/

@@ -228,3 +208,2 @@ sofZmanShmaMGA16Point1(): Date;

* https://kosherjava.com/2022/01/12/equinox-vs-equilux-zmanim-calculations/
* @return {Date}
*/

@@ -234,3 +213,2 @@ sofZmanShmaMGA19Point8(): Date;

* Latest Shacharit (MGA); Sunrise plus 4 halachic hours, according to Magen Avraham
* @return {Date}
*/

@@ -242,3 +220,2 @@ sofZmanTfillaMGA(): Date;

* dawn to nightfall with both being 16.1° below the horizon.
* @return {Date}
*/

@@ -254,3 +231,2 @@ sofZmanTfillaMGA16Point1(): Date;

* https://kosherjava.com/2022/01/12/equinox-vs-equilux-zmanim-calculations/
* @return {Date}
*/

@@ -270,3 +246,2 @@ sofZmanTfillaMGA19Point8(): Date;

* opinion that *mincha* can be prayed *lechatchila* starting at *mincha gedola*.
* @return {Date}
*/

@@ -281,3 +256,2 @@ minchaGedola(): Date;

* This is the earliest time to pray *mincha*.
* @return {Date}
*/

@@ -294,3 +268,2 @@ minchaGedolaMGA(): Date;

* to the [GRA](https://en.wikipedia.org/wiki/Vilna_Gaon).
* @return {Date}
*/

@@ -305,3 +278,2 @@ minchaKetana(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/

@@ -312,11 +284,9 @@ minchaKetanaMGA(): Date;

* If elevation is enabled, this function will include elevation in the calculation.
* @return {Date}
*/
plagHaMincha(): Date;
/**
* @param {number} [angle=8.5] optional time for solar depression.
* @param [angle=8.5] optional time for solar depression.
* Default is 8.5 degrees for 3 small stars, use 7.083 degrees for 3 medium-sized stars.
* Because degree-based functions estimate the amount of light in the sky,
* the result is not impacted by elevation.
* @return {Date}
*/

@@ -326,3 +296,2 @@ tzeit(angle?: number): Date;

* Alias for sunrise
* @return {Date}
*/

@@ -332,3 +301,2 @@ neitzHaChama(): Date;

* Alias for sunset
* @return {Date}
*/

@@ -343,3 +311,2 @@ shkiah(): Date;

* the result is not impacted by elevation.
* @return {Date}
*/

@@ -349,5 +316,2 @@ beinHaShmashos(): Date;

* Uses timeFormat to return a date like '20:34'
* @param {Date} dt
* @param {Intl.DateTimeFormat} timeFormat
* @return {string}
*/

@@ -357,4 +321,3 @@ static formatTime(dt: Date, timeFormat: Intl.DateTimeFormat): string;

* Discards seconds, rounding to nearest minute.
* @param {Date} dt
* @return {Date}
* @param dt
*/

@@ -364,5 +327,4 @@ static roundTime(dt: Date): Date;

* Get offset string (like "+05:00" or "-08:00") from tzid (like "Europe/Moscow")
* @param {string} tzid
* @param {Date} date
* @return {string}
* @param tzid
* @param date
*/

@@ -372,5 +334,4 @@ static timeZoneOffset(tzid: string, date: Date): string;

* Returns a string like "2022-04-01T13:06:00-11:00"
* @param {string} tzid
* @param {Date} date
* @return {string}
* @param tzid
* @param date
*/

@@ -382,6 +343,5 @@ static formatISOWithTimeZone(tzid: string, date: Date): string;

* unless `forceSeaLevel` is `true`.
* @param {number} offset minutes
* @param {boolean} roundMinute round time to nearest minute (default true)
* @param {boolean} forceSeaLevel use sea-level sunrise (default false)
* @return {Date}
* @param offset minutes
* @param roundMinute round time to nearest minute (default true)
* @param forceSeaLevel use sea-level sunrise (default false)
*/

@@ -393,8 +353,7 @@ sunriseOffset(offset: number, roundMinute?: boolean, forceSeaLevel?: boolean): Date;

* unless `forceSeaLevel` is `true`.
* @param {number} offset minutes
* @param {boolean} roundMinute round time to nearest minute (default true)
* @param {boolean} forceSeaLevel use sea-level sunset (default false)
* @return {Date}
* @param offset minutes
* @param roundMinute round time to nearest minute (default true)
* @param forceSeaLevel use sea-level sunset (default false)
*/
sunsetOffset(offset: number, roundMinute?: boolean, forceSeaLevel?: boolean): Date;
}
{
"name": "@hebcal/core",
"version": "5.4.8",
"version": "5.4.9",
"author": "Michael J. Radwin (https://github.com/mjradwin)",

@@ -52,7 +52,9 @@ "contributors": [

"po2json": "node ./po2json.cjs po/*.po",
"readme": "cp dist/index.mjs tmp.js && npx -p jsdoc-to-markdown jsdoc2md tmp.js && rm -f tmp.js",
"docs": "typedoc",
"pretest": "npm run build",
"lint": "eslint src",
"lint": "gts lint",
"coverage": "jest --coverage",
"test": "jest"
"test": "jest",
"clean": "gts clean",
"fix": "gts fix"
},

@@ -80,15 +82,14 @@ "license": "GPL-2.0",

"@types/jest": "^29.5.12",
"@types/node": "^20.14.9",
"core-js": "^3.37.1",
"eslint": "<=8.57.0",
"eslint-config-google": "^0.14.0",
"gts": "^5.3.1",
"jest": "^29.7.0",
"jsdoc": "^4.0.3",
"jsdoc-to-markdown": "^8.0.1",
"quick-lru": "<=6.1.2",
"rollup": "^4.18.0",
"ttag-cli": "^1.10.12",
"typedoc": "^0.26.3",
"typescript": "^5.5.3"
},
"dependencies": {
"@hebcal/hdate": "^0.10.1",
"@hebcal/hdate": "^0.11.1",
"@hebcal/noaa": "^0.8.14",

@@ -95,0 +96,0 @@ "tslib": "^2.6.3"

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc