This is a mirror of https://github.com/janrg/badiDate. No files have been altered, and no change in license or ownership is implied. Please note that the original license is the "MIT License."
|
|
3 месяцев назад | |
|---|---|---|
| dist | 3 месяцев назад | |
| res | 3 месяцев назад | |
| src | 3 месяцев назад | |
| test | 3 месяцев назад | |
| .eslintignore | 3 месяцев назад | |
| .eslintrc.json | 3 месяцев назад | |
| .gitignore | 3 месяцев назад | |
| .npmignore | 3 месяцев назад | |
| .npmrc | 3 месяцев назад | |
| DOCUMENTATION.md | 3 месяцев назад | |
| LICENSE | 3 месяцев назад | |
| README.md | 3 месяцев назад | |
| dist-rename.js | 3 месяцев назад | |
| jest.config.js | 3 месяцев назад | |
| package-lock.json | 3 месяцев назад | |
| package.json | 3 месяцев назад | |
| rollup.config.js | 3 месяцев назад | |
| tsconfig.json | 3 месяцев назад |
A JavaScript module for dates in the Badí' calendar. Badí' date objects can be created from Gregorian or Badí' dates in
a variety of input formats. The currently handled range of dates is from 1 Bahá 1 BE (21 March 1844) to 19 'Alá' 556 BE
(19 Mach 2400). Badí' dates are treated as if corresponding exactly to Gregorian dates (i.e. starting at midnight), but
with the provided LocalBadiDate class, local information can be generated incl. the start and end date
and time of the Badí' date, the times for sunrise and solar noon, as well as - if applicable - the time for a Holy Day
commemoration.
badiDate requires Luxon. In order to use the LocalBadiDate class,
MeeusSunMoon (v3.0.0+) is also required. Versions that bundle MeeusSunMoon are
included.
Accuracies of solar and lunar calculations are given by MeeusSunMoon.
The accuracy of the calculation of the date of Naw-Rúz and the dates of the Twin Birthdays depend on those as well as that of the equinox calculations, which are immensely complex. Equinox dates until 2200 are calculated with an algorithm using the JPL DE405 Ephemeris, and from 2200 onwards with an algorithm using the VSOP87 Ephemeris, which is slightly less accurate, but only on the order of a few seconds.
The main source of uncertainty for far future dates comes from the uncertainty on ΔT. A detailed analysis of uncertainties is included in the code. The range of dates is limited to until 20 March 2351, as the uncertainty in ΔT means the date of Naw-Rúz 2352 AD produced by the algorithm may not be correct.
main path in `package.jsonpreviousDayget() attributesinvalidReason, nextDay, nextMonth, previousDay, previousMonth to the BadiDate classequals() method to the BadiDate classclockLocation, latitude, longitude, nextDay, nextMonth, previousDay, previousMonth,
timezoneId to the LocalBadiDate classget() attributesBadiDate.format()Refactored into ES6 modules and distributed via node. This version is incompatible with previous versions of the module.
Fixed some output formatting, added uncertainty analysis for far future dates and based on this reduced the range of dates slightly (now ends in 507 BE), added Persian localization (thanks to arminhaghi).
Initial release
badiDate is freely distributable under the terms of the MIT license.