chrono-node 2.4.1 → 2.5.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.
- package/.idea/chrono.iml +13 -0
- package/.idea/compiler.xml +7 -0
- package/.idea/dictionaries/wanasit.xml +8 -0
- package/.idea/inspectionProfiles/Project_Default.xml +6 -0
- package/.idea/jsLibraryMappings.xml +6 -0
- package/.idea/jsLinters/eslint.xml +6 -0
- package/.idea/misc.xml +6 -0
- package/.idea/modules.xml +8 -0
- package/.idea/prettier.xml +6 -0
- package/.idea/vcs.xml +6 -0
- package/.idea/workspace.xml +327 -0
- package/README.md +1 -1
- package/benchmark/results/chrono.chart.html +111 -0
- package/coverage/clover.xml +4771 -0
- package/coverage/coverage-final.json +147 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +686 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/results.ts.html +701 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +196 -0
- package/coverage/lcov-report/src/calculation/index.html +131 -0
- package/coverage/lcov-report/src/calculation/mergingCalculation.ts.html +319 -0
- package/coverage/lcov-report/src/calculation/weeks.ts.html +199 -0
- package/coverage/lcov-report/src/calculation/yearCalculation.ts.html +194 -0
- package/coverage/lcov-report/src/calculation/years.ts.html +199 -0
- package/coverage/lcov-report/src/chrono.js.html +368 -0
- package/coverage/lcov-report/src/chrono.ts.html +649 -0
- package/coverage/lcov-report/src/common/abstractRefiners.ts.html +286 -0
- package/coverage/lcov-report/src/common/calculation/index.html +116 -0
- package/coverage/lcov-report/src/common/calculation/weekdays.ts.html +352 -0
- package/coverage/lcov-report/src/common/casualReferences.ts.html +499 -0
- package/coverage/lcov-report/src/common/index.html +131 -0
- package/coverage/lcov-report/src/common/parsers/AbstractParserWithWordBoundary.ts.html +214 -0
- package/coverage/lcov-report/src/common/parsers/AbstractTimeExpressionParser.ts.html +1384 -0
- package/coverage/lcov-report/src/common/parsers/ISOFormatParser.ts.html +340 -0
- package/coverage/lcov-report/src/common/parsers/SlashDateFormatParser.ts.html +385 -0
- package/coverage/lcov-report/src/common/parsers/index.html +161 -0
- package/coverage/lcov-report/src/common/refiners/AbstractMergeDateRangeRefiner.ts.html +268 -0
- package/coverage/lcov-report/src/common/refiners/AbstractMergeDateTimeRefiner.ts.html +172 -0
- package/coverage/lcov-report/src/common/refiners/ExtractTimezoneAbbrRefiner.ts.html +883 -0
- package/coverage/lcov-report/src/common/refiners/ExtractTimezoneOffsetRefiner.ts.html +226 -0
- package/coverage/lcov-report/src/common/refiners/ForwardDateRefiner.ts.html +334 -0
- package/coverage/lcov-report/src/common/refiners/MergeWeekdayComponentRefiner.ts.html +187 -0
- package/coverage/lcov-report/src/common/refiners/OverlapRemovalRefiner.ts.html +199 -0
- package/coverage/lcov-report/src/common/refiners/UnlikelyFormatFilter.ts.html +265 -0
- package/coverage/lcov-report/src/common/refiners/index.html +221 -0
- package/coverage/lcov-report/src/configurations.ts.html +154 -0
- package/coverage/lcov-report/src/debugging.ts.html +154 -0
- package/coverage/lcov-report/src/index.html +191 -0
- package/coverage/lcov-report/src/index.ts.html +520 -0
- package/coverage/lcov-report/src/locales/de/constants.ts.html +664 -0
- package/coverage/lcov-report/src/locales/de/index.html +131 -0
- package/coverage/lcov-report/src/locales/de/index.ts.html +238 -0
- package/coverage/lcov-report/src/locales/de/parsers/DECasualDateParser.ts.html +325 -0
- package/coverage/lcov-report/src/locales/de/parsers/DECasualTimeParser.ts.html +325 -0
- package/coverage/lcov-report/src/locales/de/parsers/DEMonthNameLittleEndianParser.ts.html +268 -0
- package/coverage/lcov-report/src/locales/de/parsers/DESpecificTimeExpressionParser.ts.html +535 -0
- package/coverage/lcov-report/src/locales/de/parsers/DETimeExpressionParser.ts.html +151 -0
- package/coverage/lcov-report/src/locales/de/parsers/DETimeUnitRelativeFormatParser.ts.html +211 -0
- package/coverage/lcov-report/src/locales/de/parsers/DEWeekdayParser.ts.html +232 -0
- package/coverage/lcov-report/src/locales/de/parsers/index.html +206 -0
- package/coverage/lcov-report/src/locales/de/refiners/DEMergeDateRangeRefiner.ts.html +130 -0
- package/coverage/lcov-report/src/locales/de/refiners/DEMergeDateTimeRefiner.ts.html +115 -0
- package/coverage/lcov-report/src/locales/de/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/en/constants.ts.html +859 -0
- package/coverage/lcov-report/src/locales/en/index.html +131 -0
- package/coverage/lcov-report/src/locales/en/index.ts.html +382 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENCasualDateParser.ts.html +244 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENCasualTimeParser.ts.html +169 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENCasualYearMonthDayParser.ts.html +232 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENDeadlineFormatParser.ts.html +311 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENISOFormatParser.ts.html +317 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENMonthNameLittleEndianParser.ts.html +292 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENMonthNameMiddleEndianParser.ts.html +319 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENMonthNameParser.ts.html +271 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENRelativeDateFormatParser.ts.html +292 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENSlashDateFormatParser.ts.html +443 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENSlashDateFormatStartWithYearParser.ts.html +221 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENSlashMonthFormatParser.ts.html +163 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeExpressionParser.ts.html +250 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeUnitAgoFormatParser.ts.html +160 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeUnitCasualRelativeFormatParser.ts.html +166 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeUnitDeadlineFormatParser.ts.html +149 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeUnitLaterFormatParser.ts.html +166 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENTimeUnitWithinFormatParser.ts.html +163 -0
- package/coverage/lcov-report/src/locales/en/parsers/ENWeekdayParser.ts.html +229 -0
- package/coverage/lcov-report/src/locales/en/parsers/index.html +311 -0
- package/coverage/lcov-report/src/locales/en/refiners/ENMergeDateRangeRefiner.ts.html +136 -0
- package/coverage/lcov-report/src/locales/en/refiners/ENMergeDateTimeRefiner.ts.html +124 -0
- package/coverage/lcov-report/src/locales/en/refiners/ENMergeRelativeDateRefiner.ts.html +259 -0
- package/coverage/lcov-report/src/locales/en/refiners/index.html +146 -0
- package/coverage/lcov-report/src/locales/es/constants.ts.html +340 -0
- package/coverage/lcov-report/src/locales/es/index.html +131 -0
- package/coverage/lcov-report/src/locales/es/index.ts.html +256 -0
- package/coverage/lcov-report/src/locales/es/parsers/ESCasualDateParser.ts.html +178 -0
- package/coverage/lcov-report/src/locales/es/parsers/ESCasualTimeParser.ts.html +226 -0
- package/coverage/lcov-report/src/locales/es/parsers/ESMonthNameLittleEndianParser.ts.html +265 -0
- package/coverage/lcov-report/src/locales/es/parsers/ESTimeExpressionParser.ts.html +145 -0
- package/coverage/lcov-report/src/locales/es/parsers/ESWeekdayParser.ts.html +235 -0
- package/coverage/lcov-report/src/locales/es/parsers/index.html +176 -0
- package/coverage/lcov-report/src/locales/es/refiners/ESMergeDateRangeRefiner.ts.html +130 -0
- package/coverage/lcov-report/src/locales/es/refiners/ESMergeDateTimeRefiner.ts.html +115 -0
- package/coverage/lcov-report/src/locales/es/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/fr/constants.ts.html +637 -0
- package/coverage/lcov-report/src/locales/fr/index.html +131 -0
- package/coverage/lcov-report/src/locales/fr/index.ts.html +280 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRCasualDateParser.ts.html +223 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRCasualTimeParser.ts.html +232 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRMonthNameLittleEndianParser.ts.html +277 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRSpecificTimeExpressionParser.ts.html +484 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRTimeExpressionParser.ts.html +151 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRTimeUnitAgoFormatParser.ts.html +151 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRTimeUnitRelativeFormatParser.ts.html +214 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRTimeUnitWithinFormatParser.ts.html +130 -0
- package/coverage/lcov-report/src/locales/fr/parsers/FRWeekdayParser.ts.html +223 -0
- package/coverage/lcov-report/src/locales/fr/parsers/index.html +236 -0
- package/coverage/lcov-report/src/locales/fr/refiners/FRMergeDateRangeRefiner.ts.html +130 -0
- package/coverage/lcov-report/src/locales/fr/refiners/FRMergeDateTimeRefiner.ts.html +115 -0
- package/coverage/lcov-report/src/locales/fr/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/ja/constants.ts.html +157 -0
- package/coverage/lcov-report/src/locales/ja/index.html +131 -0
- package/coverage/lcov-report/src/locales/ja/index.ts.html +214 -0
- package/coverage/lcov-report/src/locales/ja/parsers/JPCasualDateParser.ts.html +217 -0
- package/coverage/lcov-report/src/locales/ja/parsers/JPStandardParser.ts.html +247 -0
- package/coverage/lcov-report/src/locales/ja/parsers/index.html +131 -0
- package/coverage/lcov-report/src/locales/ja/refiners/JPMergeDateRangeRefiner.ts.html +124 -0
- package/coverage/lcov-report/src/locales/ja/refiners/index.html +116 -0
- package/coverage/lcov-report/src/locales/nl/constants.ts.html +796 -0
- package/coverage/lcov-report/src/locales/nl/index.html +131 -0
- package/coverage/lcov-report/src/locales/nl/index.ts.html +304 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLCasualDateParser.ts.html +181 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLCasualDateTimeParser.ts.html +310 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLCasualTimeParser.ts.html +265 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLCasualYearMonthDayParser.ts.html +232 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLMonthNameMiddleEndianParser.ts.html +349 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLMonthNameParser.ts.html +235 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLRelativeDateFormatParser.ts.html +295 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLSlashMonthFormatParser.ts.html +163 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLTimeExpressionParser.ts.html +163 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLTimeUnitAgoFormatParser.ts.html +163 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLTimeUnitCasualRelativeFormatParser.ts.html +166 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLTimeUnitLaterFormatParser.ts.html +166 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLTimeUnitWithinFormatParser.ts.html +130 -0
- package/coverage/lcov-report/src/locales/nl/parsers/NLWeekdayParser.ts.html +223 -0
- package/coverage/lcov-report/src/locales/nl/parsers/index.html +311 -0
- package/coverage/lcov-report/src/locales/nl/refiners/NLMergeDateRangeRefiner.ts.html +136 -0
- package/coverage/lcov-report/src/locales/nl/refiners/NLMergeDateTimeRefiner.ts.html +124 -0
- package/coverage/lcov-report/src/locales/nl/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/pt/constants.ts.html +343 -0
- package/coverage/lcov-report/src/locales/pt/index.html +131 -0
- package/coverage/lcov-report/src/locales/pt/index.ts.html +256 -0
- package/coverage/lcov-report/src/locales/pt/parsers/PTCasualDateParser.ts.html +181 -0
- package/coverage/lcov-report/src/locales/pt/parsers/PTCasualTimeParser.ts.html +226 -0
- package/coverage/lcov-report/src/locales/pt/parsers/PTMonthNameLittleEndianParser.ts.html +265 -0
- package/coverage/lcov-report/src/locales/pt/parsers/PTTimeExpressionParser.ts.html +145 -0
- package/coverage/lcov-report/src/locales/pt/parsers/PTWeekdayParser.ts.html +235 -0
- package/coverage/lcov-report/src/locales/pt/parsers/index.html +176 -0
- package/coverage/lcov-report/src/locales/pt/refiners/PTMergeDateRangeRefiner.ts.html +130 -0
- package/coverage/lcov-report/src/locales/pt/refiners/PTMergeDateTimeRefiner.ts.html +115 -0
- package/coverage/lcov-report/src/locales/pt/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/ru/constants.ts.html +1111 -0
- package/coverage/lcov-report/src/locales/ru/index.html +131 -0
- package/coverage/lcov-report/src/locales/ru/index.ts.html +337 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUCasualDateParser.ts.html +217 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUCasualTimeParser.ts.html +253 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUMonthNameLittleEndianParser.ts.html +301 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUMonthNameParser.ts.html +268 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RURelativeDateFormatParser.ts.html +310 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUTimeExpressionParser.ts.html +277 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUTimeUnitAgoFormatParser.ts.html +157 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUTimeUnitCasualRelativeFormatParser.ts.html +187 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUTimeUnitWithinFormatParser.ts.html +157 -0
- package/coverage/lcov-report/src/locales/ru/parsers/RUWeekdayParser.ts.html +256 -0
- package/coverage/lcov-report/src/locales/ru/parsers/index.html +251 -0
- package/coverage/lcov-report/src/locales/ru/refiners/RUMergeDateRangeRefiner.ts.html +124 -0
- package/coverage/lcov-report/src/locales/ru/refiners/RUMergeDateTimeRefiner.ts.html +124 -0
- package/coverage/lcov-report/src/locales/ru/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/zh/hans/constants.ts.html +241 -0
- package/coverage/lcov-report/src/locales/zh/hans/index.html +131 -0
- package/coverage/lcov-report/src/locales/zh/hans/index.ts.html +271 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansCasualDateParser.ts.html +469 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansDateParser.ts.html +310 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansDeadlineFormatParser.ts.html +328 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansRelationWeekdayParser.ts.html +292 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansTimeExpressionParser.ts.html +1357 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/ZHHansWeekdayParser.ts.html +223 -0
- package/coverage/lcov-report/src/locales/zh/hans/parsers/index.html +191 -0
- package/coverage/lcov-report/src/locales/zh/hans/refiners/ZHHansMergeDateRangeRefiner.ts.html +106 -0
- package/coverage/lcov-report/src/locales/zh/hans/refiners/ZHHansMergeDateTimeRefiner.ts.html +106 -0
- package/coverage/lcov-report/src/locales/zh/hans/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/zh/hant/constants.ts.html +244 -0
- package/coverage/lcov-report/src/locales/zh/hant/index.html +131 -0
- package/coverage/lcov-report/src/locales/zh/hant/index.ts.html +274 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantCasualDateParser.ts.html +469 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantDateParser.ts.html +289 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantDeadlineFormatParser.ts.html +328 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantRelationWeekdayParser.ts.html +292 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantTimeExpressionParser.ts.html +1357 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/ZHHantWeekdayParser.ts.html +223 -0
- package/coverage/lcov-report/src/locales/zh/hant/parsers/index.html +191 -0
- package/coverage/lcov-report/src/locales/zh/hant/refiners/ZHHantMergeDateRangeRefiner.ts.html +106 -0
- package/coverage/lcov-report/src/locales/zh/hant/refiners/ZHHantMergeDateTimeRefiner.ts.html +106 -0
- package/coverage/lcov-report/src/locales/zh/hant/refiners/index.html +131 -0
- package/coverage/lcov-report/src/locales/zh/index.html +116 -0
- package/coverage/lcov-report/src/locales/zh/index.ts.html +91 -0
- package/coverage/lcov-report/src/options.js.html +1085 -0
- package/coverage/lcov-report/src/parsers/de/DECasualDateParser.js.html +368 -0
- package/coverage/lcov-report/src/parsers/de/DEDeadlineFormatParser.js.html +374 -0
- package/coverage/lcov-report/src/parsers/de/DEMonthNameLittleEndianParser.js.html +347 -0
- package/coverage/lcov-report/src/parsers/de/DEMonthNameParser.js.html +329 -0
- package/coverage/lcov-report/src/parsers/de/DESlashDateFormatParser.js.html +398 -0
- package/coverage/lcov-report/src/parsers/de/DETimeAgoFormatParser.js.html +401 -0
- package/coverage/lcov-report/src/parsers/de/DETimeExpressionParser.js.html +836 -0
- package/coverage/lcov-report/src/parsers/de/DEWeekdayParser.js.html +338 -0
- package/coverage/lcov-report/src/parsers/de/index.html +216 -0
- package/coverage/lcov-report/src/parsers/en/ENCasualDateParser.js.html +275 -0
- package/coverage/lcov-report/src/parsers/en/ENCasualTimeParser.js.html +242 -0
- package/coverage/lcov-report/src/parsers/en/ENDeadlineFormatParser.js.html +359 -0
- package/coverage/lcov-report/src/parsers/en/ENISOFormatParser.js.html +389 -0
- package/coverage/lcov-report/src/parsers/en/ENMonthNameLittleEndianParser.js.html +416 -0
- package/coverage/lcov-report/src/parsers/en/ENMonthNameMiddleEndianParser.js.html +437 -0
- package/coverage/lcov-report/src/parsers/en/ENMonthNameParser.js.html +320 -0
- package/coverage/lcov-report/src/parsers/en/ENRelativeDateFormatParser.js.html +518 -0
- package/coverage/lcov-report/src/parsers/en/ENSlashDateFormatParser.js.html +479 -0
- package/coverage/lcov-report/src/parsers/en/ENSlashDateFormatStartWithYearParser.js.html +245 -0
- package/coverage/lcov-report/src/parsers/en/ENSlashMonthFormatParser.js.html +221 -0
- package/coverage/lcov-report/src/parsers/en/ENTimeAgoFormatParser.js.html +287 -0
- package/coverage/lcov-report/src/parsers/en/ENTimeExpressionParser.js.html +869 -0
- package/coverage/lcov-report/src/parsers/en/ENTimeLaterFormatParser.js.html +305 -0
- package/coverage/lcov-report/src/parsers/en/ENWeekdayParser.js.html +356 -0
- package/coverage/lcov-report/src/parsers/en/index.html +321 -0
- package/coverage/lcov-report/src/parsers/es/ESCasualDateParser.js.html +452 -0
- package/coverage/lcov-report/src/parsers/es/ESDeadlineFormatParser.js.html +260 -0
- package/coverage/lcov-report/src/parsers/es/ESMonthNameLittleEndianParser.js.html +338 -0
- package/coverage/lcov-report/src/parsers/es/ESSlashDateFormatParser.js.html +419 -0
- package/coverage/lcov-report/src/parsers/es/ESTimeAgoFormatParser.js.html +341 -0
- package/coverage/lcov-report/src/parsers/es/ESTimeExpressionParser.js.html +782 -0
- package/coverage/lcov-report/src/parsers/es/ESWeekdayParser.js.html +260 -0
- package/coverage/lcov-report/src/parsers/es/index.html +201 -0
- package/coverage/lcov-report/src/parsers/fr/FRCasualDateParser.js.html +311 -0
- package/coverage/lcov-report/src/parsers/fr/FRDeadlineFormatParser.js.html +359 -0
- package/coverage/lcov-report/src/parsers/fr/FRMonthNameLittleEndianParser.js.html +338 -0
- package/coverage/lcov-report/src/parsers/fr/FRRelativeDateFormatParser.js.html +545 -0
- package/coverage/lcov-report/src/parsers/fr/FRSlashDateFormatParser.js.html +437 -0
- package/coverage/lcov-report/src/parsers/fr/FRTimeAgoFormatParser.js.html +341 -0
- package/coverage/lcov-report/src/parsers/fr/FRTimeExpressionParser.js.html +803 -0
- package/coverage/lcov-report/src/parsers/fr/FRWeekdayParser.js.html +257 -0
- package/coverage/lcov-report/src/parsers/fr/index.html +216 -0
- package/coverage/lcov-report/src/parsers/index.html +111 -0
- package/coverage/lcov-report/src/parsers/ja/JPCasualDateParser.js.html +245 -0
- package/coverage/lcov-report/src/parsers/ja/JPStandardParser.js.html +293 -0
- package/coverage/lcov-report/src/parsers/ja/index.html +126 -0
- package/coverage/lcov-report/src/parsers/nl/NLCasualDateParser.js.html +395 -0
- package/coverage/lcov-report/src/parsers/nl/NLCasualTimeParser.js.html +278 -0
- package/coverage/lcov-report/src/parsers/nl/NLMonthNameLittleEndianParser.js.html +383 -0
- package/coverage/lcov-report/src/parsers/nl/NLMonthNameParser.js.html +320 -0
- package/coverage/lcov-report/src/parsers/nl/NLSlashDateFormatParser.js.html +389 -0
- package/coverage/lcov-report/src/parsers/nl/NLTimeExpressionParser.js.html +836 -0
- package/coverage/lcov-report/src/parsers/nl/NLWeekdayParser.js.html +377 -0
- package/coverage/lcov-report/src/parsers/nl/index.html +201 -0
- package/coverage/lcov-report/src/parsers/parser.js.html +500 -0
- package/coverage/lcov-report/src/parsers/pt/PTCasualDateParser.js.html +449 -0
- package/coverage/lcov-report/src/parsers/pt/PTDeadlineFormatParser.js.html +263 -0
- package/coverage/lcov-report/src/parsers/pt/PTMonthNameLittleEndianParser.js.html +338 -0
- package/coverage/lcov-report/src/parsers/pt/PTSlashDateFormatParser.js.html +419 -0
- package/coverage/lcov-report/src/parsers/pt/PTTimeAgoFormatParser.js.html +341 -0
- package/coverage/lcov-report/src/parsers/pt/PTTimeExpressionParser.js.html +782 -0
- package/coverage/lcov-report/src/parsers/pt/PTWeekdayParser.js.html +260 -0
- package/coverage/lcov-report/src/parsers/pt/index.html +201 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/ZHHantCasualDateParser.js.html +494 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/ZHHantDateParser.js.html +281 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/ZHHantDeadlineFormatParser.js.html +353 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/ZHHantTimeExpressionParser.js.html +1346 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/ZHHantWeekdayParser.js.html +239 -0
- package/coverage/lcov-report/src/parsers/zh-Hant/index.html +171 -0
- package/coverage/lcov-report/src/refiners/ExtractTimezoneAbbrRefiner.js.html +245 -0
- package/coverage/lcov-report/src/refiners/ExtractTimezoneOffsetRefiner.js.html +218 -0
- package/coverage/lcov-report/src/refiners/ForwardDateRefiner.js.html +239 -0
- package/coverage/lcov-report/src/refiners/OverlapRemovalRefiner.js.html +200 -0
- package/coverage/lcov-report/src/refiners/UnlikelyFormatFilter.js.html +131 -0
- package/coverage/lcov-report/src/refiners/de/DEMergeDateRangeRefiner.js.html +116 -0
- package/coverage/lcov-report/src/refiners/de/DEMergeDateTimeRefiner.js.html +377 -0
- package/coverage/lcov-report/src/refiners/de/index.html +126 -0
- package/coverage/lcov-report/src/refiners/en/ENMergeDateRangeRefiner.js.html +416 -0
- package/coverage/lcov-report/src/refiners/en/ENMergeDateTimeRefiner.js.html +533 -0
- package/coverage/lcov-report/src/refiners/en/ENPrioritizeSpecificDateRefiner.js.html +422 -0
- package/coverage/lcov-report/src/refiners/en/index.html +141 -0
- package/coverage/lcov-report/src/refiners/fr/FRMergeDateRangeRefiner.js.html +374 -0
- package/coverage/lcov-report/src/refiners/fr/FRMergeDateTimeRefiner.js.html +395 -0
- package/coverage/lcov-report/src/refiners/fr/index.html +126 -0
- package/coverage/lcov-report/src/refiners/index.html +186 -0
- package/coverage/lcov-report/src/refiners/ja/JPMergeDateRangeRefiner.js.html +113 -0
- package/coverage/lcov-report/src/refiners/ja/index.html +111 -0
- package/coverage/lcov-report/src/refiners/nl/NLMergeDateRangeRefiner.js.html +116 -0
- package/coverage/lcov-report/src/refiners/nl/NLMergeDateTimeRefiner.js.html +362 -0
- package/coverage/lcov-report/src/refiners/nl/index.html +126 -0
- package/coverage/lcov-report/src/refiners/refiner.js.html +239 -0
- package/coverage/lcov-report/src/result.js.html +545 -0
- package/coverage/lcov-report/src/results.ts.html +916 -0
- package/coverage/lcov-report/src/timezone.ts.html +700 -0
- package/coverage/lcov-report/src/utils/DE.js.html +308 -0
- package/coverage/lcov-report/src/utils/EN.js.html +596 -0
- package/coverage/lcov-report/src/utils/ES.js.html +254 -0
- package/coverage/lcov-report/src/utils/FR.js.html +302 -0
- package/coverage/lcov-report/src/utils/JP.js.html +215 -0
- package/coverage/lcov-report/src/utils/NL.js.html +620 -0
- package/coverage/lcov-report/src/utils/PT.js.html +263 -0
- package/coverage/lcov-report/src/utils/ParserWithWordEndingDetection.ts.html +176 -0
- package/coverage/lcov-report/src/utils/ZH-Hant.js.html +236 -0
- package/coverage/lcov-report/src/utils/dayjs.ts.html +223 -0
- package/coverage/lcov-report/src/utils/index.html +146 -0
- package/coverage/lcov-report/src/utils/pattern.ts.html +175 -0
- package/coverage/lcov-report/src/utils/timeunits.ts.html +199 -0
- package/coverage/lcov-report/test/index.html +116 -0
- package/coverage/lcov-report/test/test_util.js.html +299 -0
- package/coverage/lcov-report/test/test_util.ts.html +490 -0
- package/coverage/lcov.info +8049 -0
- package/dist/common/casualReferences.d.ts +1 -0
- package/dist/common/casualReferences.js +23 -2
- package/dist/common/casualReferences.js.map +1 -1
- package/dist/common/parsers/SlashDateFormatParser.js +5 -3
- package/dist/common/parsers/SlashDateFormatParser.js.map +1 -1
- package/dist/common/refiners/AbstractMergeDateTimeRefiner.d.ts +1 -1
- package/dist/common/refiners/AbstractMergeDateTimeRefiner.js +2 -2
- package/dist/common/refiners/AbstractMergeDateTimeRefiner.js.map +1 -1
- package/dist/common/refiners/ForwardDateRefiner.js +12 -0
- package/dist/common/refiners/ForwardDateRefiner.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/locales/en/constants.js +6 -0
- package/dist/locales/en/constants.js.map +1 -1
- package/dist/locales/en/parsers/ENCasualTimeParser.js +27 -26
- package/dist/locales/en/parsers/ENCasualTimeParser.js.map +1 -1
- package/dist/locales/es/constants.d.ts +8 -0
- package/dist/locales/es/constants.js +84 -0
- package/dist/locales/es/constants.js.map +1 -0
- package/dist/locales/es/index.d.ts +8 -0
- package/dist/locales/es/index.js +46 -0
- package/dist/locales/es/index.js.map +1 -0
- package/dist/locales/es/parsers/ESCasualDateParser.d.ts +7 -0
- package/dist/locales/es/parsers/ESCasualDateParser.js +45 -0
- package/dist/locales/es/parsers/ESCasualDateParser.js.map +1 -0
- package/dist/locales/es/parsers/ESCasualTimeParser.d.ts +6 -0
- package/dist/locales/es/parsers/ESCasualTimeParser.js +46 -0
- package/dist/locales/es/parsers/ESCasualTimeParser.js.map +1 -0
- package/dist/locales/es/parsers/ESMonthNameLittleEndianParser.d.ts +7 -0
- package/dist/locales/es/parsers/ESMonthNameLittleEndianParser.js +49 -0
- package/dist/locales/es/parsers/ESMonthNameLittleEndianParser.js.map +1 -0
- package/dist/locales/es/parsers/ESTimeExpressionParser.d.ts +5 -0
- package/dist/locales/es/parsers/ESTimeExpressionParser.js +13 -0
- package/dist/locales/es/parsers/ESTimeExpressionParser.js.map +1 -0
- package/dist/locales/es/parsers/ESWeekdayParser.d.ts +7 -0
- package/dist/locales/es/parsers/ESWeekdayParser.js +44 -0
- package/dist/locales/es/parsers/ESWeekdayParser.js.map +1 -0
- package/dist/locales/es/refiners/ESMergeDateRangeRefiner.d.ts +4 -0
- package/dist/locales/es/refiners/ESMergeDateRangeRefiner.js +13 -0
- package/dist/locales/es/refiners/ESMergeDateRangeRefiner.js.map +1 -0
- package/dist/locales/es/refiners/ESMergeDateTimeRefiner.d.ts +4 -0
- package/dist/locales/es/refiners/ESMergeDateTimeRefiner.js +13 -0
- package/dist/locales/es/refiners/ESMergeDateTimeRefiner.js.map +1 -0
- package/dist/locales/ru/parsers/RUTimeUnitCasualRelativeFormatParser.js +1 -1
- package/dist/locales/ru/parsers/RUTimeUnitCasualRelativeFormatParser.js.map +1 -1
- package/dist/locales/zh/hans/parsers/ZHHansTimeExpressionParser.js +26 -26
- package/dist/locales/zh/hans/parsers/ZHHansTimeExpressionParser.js.map +1 -1
- package/dist/locales/zh/hant/parsers/ZHHantTimeExpressionParser.js +26 -26
- package/dist/locales/zh/hant/parsers/ZHHantTimeExpressionParser.js.map +1 -1
- package/dist/utils/dayjs.d.ts +2 -0
- package/dist/utils/dayjs.js +13 -1
- package/dist/utils/dayjs.js.map +1 -1
- package/docs/assets/css/main.css +2660 -0
- package/docs/assets/images/icons.png +0 -0
- package/docs/assets/images/icons@2x.png +0 -0
- package/docs/assets/images/widgets.png +0 -0
- package/docs/assets/images/widgets@2x.png +0 -0
- package/docs/assets/js/main.js +248 -0
- package/docs/assets/js/search.js +1 -0
- package/docs/classes/chrono.html +377 -0
- package/docs/enums/meridiem.html +191 -0
- package/docs/index.html +329 -0
- package/docs/interfaces/parsedcomponents.html +270 -0
- package/docs/interfaces/parsedresult.html +283 -0
- package/docs/interfaces/parser.html +240 -0
- package/docs/interfaces/parsingoption.html +218 -0
- package/docs/interfaces/refiner.html +218 -0
- package/docs/modules/de.html +298 -0
- package/docs/modules/en.html +361 -0
- package/docs/modules/fr.html +248 -0
- package/docs/modules/ja.html +248 -0
- package/docs/modules/nl.html +275 -0
- package/docs/modules/pt.html +248 -0
- package/package.json +1 -1
- package/src/common/casualReferences.ts +31 -2
- package/src/common/parsers/SlashDateFormatParser.ts +7 -6
- package/src/common/refiners/AbstractMergeDateTimeRefiner.ts +1 -1
- package/src/common/refiners/ForwardDateRefiner.ts +13 -0
- package/src/index.ts +2 -1
- package/src/locales/en/constants.ts +6 -0
- package/src/locales/en/parsers/ENCasualTimeParser.ts +9 -31
- package/src/locales/es/constants.ts +85 -0
- package/src/locales/es/index.ts +57 -0
- package/src/locales/es/parsers/ESCasualDateParser.ts +31 -0
- package/src/locales/es/parsers/ESCasualTimeParser.ts +47 -0
- package/src/locales/es/parsers/ESMonthNameLittleEndianParser.ts +60 -0
- package/src/locales/es/parsers/ESTimeExpressionParser.ts +20 -0
- package/src/locales/es/parsers/ESWeekdayParser.ts +50 -0
- package/src/locales/es/refiners/ESMergeDateRangeRefiner.ts +15 -0
- package/src/locales/es/refiners/ESMergeDateTimeRefiner.ts +10 -0
- package/src/locales/ru/parsers/RUTimeUnitCasualRelativeFormatParser.ts +1 -1
- package/src/locales/ru/refiners/RUMergeDateTimeRefiner.ts +1 -1
- package/src/locales/zh/hans/parsers/ZHHansTimeExpressionParser.ts +26 -26
- package/src/locales/zh/hant/parsers/ZHHantTimeExpressionParser.ts +26 -26
- package/src/utils/dayjs.ts +12 -0
- package/test/en/en_casual.test.ts +34 -4
- package/test/en/en_slash.test.ts +12 -11
- package/test/en/en_time_exp.test.ts +53 -0
- package/test/en/en_time_units_ago.test.ts +17 -0
- package/test/en/en_time_units_later.test.ts +30 -0
- package/test/en/negative_cases.test.ts +11 -0
- package/test/es/es_casual.test.ts +175 -0
- package/test/es/es_month_name_little_endian.test.ts +217 -0
- package/test/es/es_slash.test.ts +26 -0
- package/test/es/es_time_exp.test.ts +175 -0
- package/test/ru/ru_time_units_casual_relative.test.ts +12 -0
- package/test/zh/zh_hans_time_exp.test.ts +15 -0
- package/test/zh/zh_hant_time_exp.test.ts +14 -0
package/.idea/chrono.iml
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<module type="WEB_MODULE" version="4">
|
|
3
|
+
<component name="NewModuleRootManager">
|
|
4
|
+
<content url="file://$MODULE_DIR$">
|
|
5
|
+
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
|
|
6
|
+
<excludeFolder url="file://$MODULE_DIR$/coverage" />
|
|
7
|
+
<excludeFolder url="file://$MODULE_DIR$/dist" />
|
|
8
|
+
</content>
|
|
9
|
+
<orderEntry type="inheritedJdk" />
|
|
10
|
+
<orderEntry type="sourceFolder" forTests="false" />
|
|
11
|
+
<orderEntry type="library" name="@types/jest" level="application" />
|
|
12
|
+
</component>
|
|
13
|
+
</module>
|
package/.idea/misc.xml
ADDED
package/.idea/vcs.xml
ADDED
|
@@ -0,0 +1,327 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="AnalysisUIOptions">
|
|
4
|
+
<option name="ANALYZE_TEST_SOURCES" value="false" />
|
|
5
|
+
<option name="CUSTOM_SCOPE_NAME" value="Project Production Files" />
|
|
6
|
+
</component>
|
|
7
|
+
<component name="AutoImportSettings">
|
|
8
|
+
<option name="autoReloadType" value="SELECTIVE" />
|
|
9
|
+
</component>
|
|
10
|
+
<component name="ChangeListManager">
|
|
11
|
+
<list default="true" id="2e0b76bb-7462-4a34-aa1d-16a9ba3798d7" name="Default Changelist" comment="">
|
|
12
|
+
<change beforePath="$PROJECT_DIR$/test/en/en_weekday.test.ts" beforeDir="false" afterPath="$PROJECT_DIR$/test/en/en_weekday.test.ts" afterDir="false" />
|
|
13
|
+
</list>
|
|
14
|
+
<option name="SHOW_DIALOG" value="false" />
|
|
15
|
+
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
|
16
|
+
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
|
17
|
+
<option name="LAST_RESOLUTION" value="IGNORE" />
|
|
18
|
+
</component>
|
|
19
|
+
<component name="FileTemplateManagerImpl">
|
|
20
|
+
<option name="RECENT_TEMPLATES">
|
|
21
|
+
<list>
|
|
22
|
+
<option value="HTML File" />
|
|
23
|
+
<option value="TypeScript File" />
|
|
24
|
+
<option value="JavaScript File" />
|
|
25
|
+
</list>
|
|
26
|
+
</option>
|
|
27
|
+
</component>
|
|
28
|
+
<component name="Git.Settings">
|
|
29
|
+
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
|
30
|
+
</component>
|
|
31
|
+
<component name="GitSEFilterConfiguration">
|
|
32
|
+
<file-type-list>
|
|
33
|
+
<filtered-out-file-type name="LOCAL_BRANCH" />
|
|
34
|
+
<filtered-out-file-type name="REMOTE_BRANCH" />
|
|
35
|
+
<filtered-out-file-type name="TAG" />
|
|
36
|
+
<filtered-out-file-type name="COMMIT_BY_MESSAGE" />
|
|
37
|
+
</file-type-list>
|
|
38
|
+
</component>
|
|
39
|
+
<component name="ProjectId" id="1ZTXLSSDQzWU7y8yHAVTj77ZXsw" />
|
|
40
|
+
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
|
|
41
|
+
<component name="ProjectViewState">
|
|
42
|
+
<option name="hideEmptyMiddlePackages" value="true" />
|
|
43
|
+
<option name="showLibraryContents" value="true" />
|
|
44
|
+
</component>
|
|
45
|
+
<component name="PropertiesComponent">
|
|
46
|
+
<property name="DefaultHtmlFileTemplate" value="HTML File" />
|
|
47
|
+
<property name="RunOnceActivity.OpenProjectViewOnStart" value="true" />
|
|
48
|
+
<property name="RunOnceActivity.ShowReadmeOnStart" value="true" />
|
|
49
|
+
<property name="WebServerToolWindowFactoryState" value="false" />
|
|
50
|
+
<property name="last_opened_file_path" value="$PROJECT_DIR$/test/zh-hant" />
|
|
51
|
+
<property name="node.js.detected.package.eslint" value="true" />
|
|
52
|
+
<property name="node.js.detected.package.standard" value="true" />
|
|
53
|
+
<property name="node.js.detected.package.tslint" value="true" />
|
|
54
|
+
<property name="node.js.path.for.package.eslint" value="project" />
|
|
55
|
+
<property name="node.js.path.for.package.standard" value="project" />
|
|
56
|
+
<property name="node.js.path.for.package.tslint" value="project" />
|
|
57
|
+
<property name="node.js.selected.package.eslint" value="(autodetect)" />
|
|
58
|
+
<property name="node.js.selected.package.standard" value="" />
|
|
59
|
+
<property name="node.js.selected.package.tslint" value="(autodetect)" />
|
|
60
|
+
<property name="nodejs.jest.jest_package" value="$PROJECT_DIR$/node_modules/jest" />
|
|
61
|
+
<property name="nodejs_package_manager_path" value="npm" />
|
|
62
|
+
<property name="prettierjs.PrettierConfiguration.Package" value="$PROJECT_DIR$/node_modules/prettier" />
|
|
63
|
+
<property name="run.code.analysis.last.selected.profile" value="pProject Default" />
|
|
64
|
+
<property name="settings.editor.selected.configurable" value="settings.javascript.linters.eslint" />
|
|
65
|
+
<property name="ts.external.directory.path" value="$PROJECT_DIR$/node_modules/typescript/lib" />
|
|
66
|
+
<property name="vue.rearranger.settings.migration" value="true" />
|
|
67
|
+
</component>
|
|
68
|
+
<component name="RecentsManager">
|
|
69
|
+
<key name="CopyFile.RECENT_KEYS">
|
|
70
|
+
<recent name="$PROJECT_DIR$/test/zh-hant" />
|
|
71
|
+
<recent name="$PROJECT_DIR$/benchmark" />
|
|
72
|
+
<recent name="$PROJECT_DIR$/test" />
|
|
73
|
+
<recent name="$PROJECT_DIR$/test/en" />
|
|
74
|
+
<recent name="$PROJECT_DIR$/src/utils" />
|
|
75
|
+
</key>
|
|
76
|
+
<key name="MoveFile.RECENT_KEYS">
|
|
77
|
+
<recent name="$PROJECT_DIR$" />
|
|
78
|
+
<recent name="$PROJECT_DIR$/examples/example_nodejs" />
|
|
79
|
+
<recent name="$PROJECT_DIR$/src/common/calculation" />
|
|
80
|
+
<recent name="$PROJECT_DIR$/src/calculation" />
|
|
81
|
+
<recent name="$PROJECT_DIR$/src/locales/zh-hant/hant" />
|
|
82
|
+
</key>
|
|
83
|
+
</component>
|
|
84
|
+
<component name="RunManager" selected="Jest.Test - forward dates only option">
|
|
85
|
+
<configuration name="All Tests" type="JavaScriptTestRunnerJest" nameIsGenerated="true">
|
|
86
|
+
<node-interpreter value="project" />
|
|
87
|
+
<node-options value="" />
|
|
88
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
89
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
90
|
+
<envs />
|
|
91
|
+
<scope-kind value="ALL" />
|
|
92
|
+
<method v="2" />
|
|
93
|
+
</configuration>
|
|
94
|
+
<configuration name="Test - Later Expression" type="JavaScriptTestRunnerJest" temporary="true" nameIsGenerated="true">
|
|
95
|
+
<node-interpreter value="project" />
|
|
96
|
+
<node-options value="" />
|
|
97
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
98
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
99
|
+
<envs />
|
|
100
|
+
<scope-kind value="TEST" />
|
|
101
|
+
<test-file value="$PROJECT_DIR$/test/en/en_time_units_later.test.ts" />
|
|
102
|
+
<test-names>
|
|
103
|
+
<test-name value="Test - Later Expression" />
|
|
104
|
+
</test-names>
|
|
105
|
+
<method v="2" />
|
|
106
|
+
</configuration>
|
|
107
|
+
<configuration name="Test - Nested time ago" type="JavaScriptTestRunnerJest" temporary="true" nameIsGenerated="true">
|
|
108
|
+
<node-interpreter value="project" />
|
|
109
|
+
<node-options value="" />
|
|
110
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
111
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
112
|
+
<envs />
|
|
113
|
+
<scope-kind value="TEST" />
|
|
114
|
+
<test-file value="$PROJECT_DIR$/test/en/en_time_units_ago.test.ts" />
|
|
115
|
+
<test-names>
|
|
116
|
+
<test-name value="Test - Nested time ago" />
|
|
117
|
+
</test-names>
|
|
118
|
+
<method v="2" />
|
|
119
|
+
</configuration>
|
|
120
|
+
<configuration name="Test - Single Expression" type="JavaScriptTestRunnerJest" temporary="true" nameIsGenerated="true">
|
|
121
|
+
<node-interpreter value="project" />
|
|
122
|
+
<node-options value="" />
|
|
123
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
124
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
125
|
+
<envs />
|
|
126
|
+
<scope-kind value="TEST" />
|
|
127
|
+
<test-file value="$PROJECT_DIR$/test/ru/ru_casual.test.ts" />
|
|
128
|
+
<test-names>
|
|
129
|
+
<test-name value="Test - Single Expression" />
|
|
130
|
+
</test-names>
|
|
131
|
+
<method v="2" />
|
|
132
|
+
</configuration>
|
|
133
|
+
<configuration name="Test - Skip impossible dates/times" type="JavaScriptTestRunnerJest" temporary="true" nameIsGenerated="true">
|
|
134
|
+
<node-interpreter value="project" />
|
|
135
|
+
<node-options value="" />
|
|
136
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
137
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
138
|
+
<envs />
|
|
139
|
+
<scope-kind value="TEST" />
|
|
140
|
+
<test-file value="$PROJECT_DIR$/test/en/negative_cases.test.ts" />
|
|
141
|
+
<test-names>
|
|
142
|
+
<test-name value="Test - Skip impossible dates/times" />
|
|
143
|
+
</test-names>
|
|
144
|
+
<method v="2" />
|
|
145
|
+
</configuration>
|
|
146
|
+
<configuration name="Test - forward dates only option" type="JavaScriptTestRunnerJest" temporary="true" nameIsGenerated="true">
|
|
147
|
+
<node-interpreter value="project" />
|
|
148
|
+
<node-options value="" />
|
|
149
|
+
<jest-package value="$PROJECT_DIR$/node_modules/jest" />
|
|
150
|
+
<working-dir value="$PROJECT_DIR$" />
|
|
151
|
+
<envs />
|
|
152
|
+
<scope-kind value="TEST" />
|
|
153
|
+
<test-file value="$PROJECT_DIR$/test/en/en_weekday.test.ts" />
|
|
154
|
+
<test-names>
|
|
155
|
+
<test-name value="Test - forward dates only option" />
|
|
156
|
+
</test-names>
|
|
157
|
+
<method v="2" />
|
|
158
|
+
</configuration>
|
|
159
|
+
<configuration name="benchmark.js" type="NodeJSConfigurationType" nameIsGenerated="true" path-to-js-file="benchmark/benchmark.js" working-dir="$PROJECT_DIR$/">
|
|
160
|
+
<EXTENSION ID="com.jetbrains.nodejs.run.NodeJSProfilingRunConfigurationExtension">
|
|
161
|
+
<profiling do-profile="true" />
|
|
162
|
+
</EXTENSION>
|
|
163
|
+
<method v="2" />
|
|
164
|
+
</configuration>
|
|
165
|
+
<list>
|
|
166
|
+
<item itemvalue="Jest.All Tests" />
|
|
167
|
+
<item itemvalue="Jest.Test - Skip impossible dates/times" />
|
|
168
|
+
<item itemvalue="Jest.Test - Single Expression" />
|
|
169
|
+
<item itemvalue="Node.js.benchmark.js" />
|
|
170
|
+
<item itemvalue="Jest.Test - Nested time ago" />
|
|
171
|
+
<item itemvalue="Jest.Test - Later Expression" />
|
|
172
|
+
<item itemvalue="Jest.Test - forward dates only option" />
|
|
173
|
+
</list>
|
|
174
|
+
<recent_temporary>
|
|
175
|
+
<list>
|
|
176
|
+
<item itemvalue="Jest.Test - forward dates only option" />
|
|
177
|
+
<item itemvalue="Jest.Test - Later Expression" />
|
|
178
|
+
<item itemvalue="Jest.Test - Nested time ago" />
|
|
179
|
+
<item itemvalue="Jest.Test - Single Expression" />
|
|
180
|
+
<item itemvalue="Jest.Test - Skip impossible dates/times" />
|
|
181
|
+
</list>
|
|
182
|
+
</recent_temporary>
|
|
183
|
+
</component>
|
|
184
|
+
<component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="project-level" UseSingleDictionary="true" transferred="true" />
|
|
185
|
+
<component name="SvnConfiguration">
|
|
186
|
+
<configuration />
|
|
187
|
+
</component>
|
|
188
|
+
<component name="TaskManager">
|
|
189
|
+
<task active="true" id="Default" summary="Default task">
|
|
190
|
+
<changelist id="2e0b76bb-7462-4a34-aa1d-16a9ba3798d7" name="Default Changelist" comment="" />
|
|
191
|
+
<created>1584864001474</created>
|
|
192
|
+
<option name="number" value="Default" />
|
|
193
|
+
<option name="presentableId" value="Default" />
|
|
194
|
+
<updated>1584864001474</updated>
|
|
195
|
+
<workItem from="1584864004406" duration="10296000" />
|
|
196
|
+
<workItem from="1586590876923" duration="16521000" />
|
|
197
|
+
<workItem from="1586678890563" duration="340000" />
|
|
198
|
+
<workItem from="1587261444799" duration="13911000" />
|
|
199
|
+
<workItem from="1587805847324" duration="2000" />
|
|
200
|
+
<workItem from="1587900049567" duration="1213000" />
|
|
201
|
+
<workItem from="1588416203732" duration="1205000" />
|
|
202
|
+
<workItem from="1588670797903" duration="1734000" />
|
|
203
|
+
<workItem from="1588737079248" duration="6300000" />
|
|
204
|
+
<workItem from="1588743424264" duration="28139000" />
|
|
205
|
+
<workItem from="1588991231647" duration="748000" />
|
|
206
|
+
<workItem from="1589018893048" duration="2937000" />
|
|
207
|
+
<workItem from="1589021927567" duration="35000" />
|
|
208
|
+
<workItem from="1589080919089" duration="13979000" />
|
|
209
|
+
<workItem from="1589099045969" duration="228000" />
|
|
210
|
+
<workItem from="1589615343519" duration="12354000" />
|
|
211
|
+
<workItem from="1589629763000" duration="10191000" />
|
|
212
|
+
<workItem from="1590139236557" duration="8704000" />
|
|
213
|
+
<workItem from="1590199845386" duration="12571000" />
|
|
214
|
+
<workItem from="1590249289717" duration="3000" />
|
|
215
|
+
<workItem from="1590831896250" duration="5471000" />
|
|
216
|
+
<workItem from="1590837392179" duration="4990000" />
|
|
217
|
+
<workItem from="1590893460812" duration="7531000" />
|
|
218
|
+
<workItem from="1593944519226" duration="16650000" />
|
|
219
|
+
<workItem from="1594121850421" duration="416000" />
|
|
220
|
+
<workItem from="1594362015482" duration="28796000" />
|
|
221
|
+
<workItem from="1594543371109" duration="19000" />
|
|
222
|
+
<workItem from="1594544186706" duration="2225000" />
|
|
223
|
+
<workItem from="1595048867095" duration="16182000" />
|
|
224
|
+
<workItem from="1595490023617" duration="19193000" />
|
|
225
|
+
<workItem from="1595565198233" duration="474000" />
|
|
226
|
+
<workItem from="1596259117912" duration="22985000" />
|
|
227
|
+
<workItem from="1596869803400" duration="798000" />
|
|
228
|
+
<workItem from="1598085605288" duration="7117000" />
|
|
229
|
+
<workItem from="1598241616578" duration="7225000" />
|
|
230
|
+
<workItem from="1603610870568" duration="5404000" />
|
|
231
|
+
<workItem from="1604122792936" duration="548000" />
|
|
232
|
+
<workItem from="1606022143412" duration="1662000" />
|
|
233
|
+
<workItem from="1606032031148" duration="5902000" />
|
|
234
|
+
<workItem from="1606619917293" duration="5718000" />
|
|
235
|
+
<workItem from="1610170003553" duration="6607000" />
|
|
236
|
+
<workItem from="1612685442329" duration="2803000" />
|
|
237
|
+
<workItem from="1613371340458" duration="3766000" />
|
|
238
|
+
<workItem from="1614500734227" duration="2558000" />
|
|
239
|
+
<workItem from="1615085500400" duration="10094000" />
|
|
240
|
+
<workItem from="1615165022342" duration="387000" />
|
|
241
|
+
<workItem from="1615544273183" duration="12692000" />
|
|
242
|
+
<workItem from="1615627570866" duration="907000" />
|
|
243
|
+
<workItem from="1615629335332" duration="74000" />
|
|
244
|
+
<workItem from="1616301213092" duration="11004000" />
|
|
245
|
+
<workItem from="1616920954993" duration="574000" />
|
|
246
|
+
<workItem from="1617521501324" duration="7933000" />
|
|
247
|
+
<workItem from="1622344986754" duration="8255000" />
|
|
248
|
+
<workItem from="1622968839524" duration="13219000" />
|
|
249
|
+
<workItem from="1623576937164" duration="8147000" />
|
|
250
|
+
<workItem from="1625989077137" duration="5717000" />
|
|
251
|
+
<workItem from="1626543794449" duration="6000" />
|
|
252
|
+
<workItem from="1626593458665" duration="6616000" />
|
|
253
|
+
<workItem from="1626672980241" duration="6000" />
|
|
254
|
+
<workItem from="1630208464301" duration="544000" />
|
|
255
|
+
<workItem from="1631533875464" duration="281000" />
|
|
256
|
+
<workItem from="1632531735320" duration="3625000" />
|
|
257
|
+
<workItem from="1637229673963" duration="1266000" />
|
|
258
|
+
<workItem from="1637710870764" duration="6721000" />
|
|
259
|
+
<workItem from="1639892469511" duration="80000" />
|
|
260
|
+
<workItem from="1640348646059" duration="648000" />
|
|
261
|
+
<workItem from="1640658908184" duration="2721000" />
|
|
262
|
+
<workItem from="1643514102921" duration="3246000" />
|
|
263
|
+
<workItem from="1644112037723" duration="1885000" />
|
|
264
|
+
<workItem from="1644720908329" duration="2495000" />
|
|
265
|
+
<workItem from="1645347872353" duration="572000" />
|
|
266
|
+
<workItem from="1645412195905" duration="2639000" />
|
|
267
|
+
<workItem from="1645701427989" duration="4944000" />
|
|
268
|
+
<workItem from="1648857250464" duration="295000" />
|
|
269
|
+
<workItem from="1650076301870" duration="4251000" />
|
|
270
|
+
<workItem from="1650767240207" duration="1157000" />
|
|
271
|
+
<workItem from="1650859815963" duration="571000" />
|
|
272
|
+
<workItem from="1654400026155" duration="2746000" />
|
|
273
|
+
<workItem from="1656415028772" duration="601000" />
|
|
274
|
+
<workItem from="1657944532366" duration="20000" />
|
|
275
|
+
<workItem from="1659841125069" duration="1762000" />
|
|
276
|
+
<workItem from="1659862420701" duration="1519000" />
|
|
277
|
+
<workItem from="1660381175625" duration="10059000" />
|
|
278
|
+
<workItem from="1661009343306" duration="2431000" />
|
|
279
|
+
<workItem from="1661048879110" duration="10416000" />
|
|
280
|
+
<workItem from="1665279226374" duration="1041000" />
|
|
281
|
+
<workItem from="1665884284050" duration="2795000" />
|
|
282
|
+
<workItem from="1668829159659" duration="6824000" />
|
|
283
|
+
<workItem from="1670116434256" duration="4043000" />
|
|
284
|
+
<workItem from="1671942898708" duration="1557000" />
|
|
285
|
+
</task>
|
|
286
|
+
<servers />
|
|
287
|
+
</component>
|
|
288
|
+
<component name="TypeScriptGeneratedFilesManager">
|
|
289
|
+
<option name="version" value="3" />
|
|
290
|
+
</component>
|
|
291
|
+
<component name="XDebuggerManager">
|
|
292
|
+
<breakpoint-manager>
|
|
293
|
+
<breakpoints>
|
|
294
|
+
<line-breakpoint enabled="true" type="javascript">
|
|
295
|
+
<url>file://$PROJECT_DIR$/test/es/es_little_endian.test.js</url>
|
|
296
|
+
<line>221</line>
|
|
297
|
+
<option name="timeStamp" value="4" />
|
|
298
|
+
</line-breakpoint>
|
|
299
|
+
<line-breakpoint enabled="true" type="javascript">
|
|
300
|
+
<url>file://$PROJECT_DIR$/test/es/es_little_endian.test.js</url>
|
|
301
|
+
<line>228</line>
|
|
302
|
+
<option name="timeStamp" value="5" />
|
|
303
|
+
</line-breakpoint>
|
|
304
|
+
<line-breakpoint enabled="true" type="javascript">
|
|
305
|
+
<url>file://$PROJECT_DIR$/src/common/refiners/UnlikelyFormatFilter.ts</url>
|
|
306
|
+
<line>18</line>
|
|
307
|
+
<option name="timeStamp" value="6" />
|
|
308
|
+
</line-breakpoint>
|
|
309
|
+
<line-breakpoint enabled="true" type="javascript">
|
|
310
|
+
<url>file://$PROJECT_DIR$/test/en/en_relative.test.ts</url>
|
|
311
|
+
<line>6</line>
|
|
312
|
+
<option name="timeStamp" value="8" />
|
|
313
|
+
</line-breakpoint>
|
|
314
|
+
<line-breakpoint enabled="true" type="javascript">
|
|
315
|
+
<url>file://$PROJECT_DIR$/test/en/en_casual.test.ts</url>
|
|
316
|
+
<line>370</line>
|
|
317
|
+
<option name="timeStamp" value="9" />
|
|
318
|
+
</line-breakpoint>
|
|
319
|
+
</breakpoints>
|
|
320
|
+
</breakpoint-manager>
|
|
321
|
+
</component>
|
|
322
|
+
<component name="com.intellij.coverage.CoverageDataManagerImpl">
|
|
323
|
+
<SUITE FILE_PATH="coverage/chrono$en_time_exp_test_ts.info" NAME="en_time_exp.test.ts Coverage Results" MODIFIED="1595503470724" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="JestJavaScriptTestRunnerCoverage" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false" />
|
|
324
|
+
<SUITE FILE_PATH="coverage/chrono$All_Tests.info" NAME="All Tests Coverage Results" MODIFIED="1665279297997" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="JestJavaScriptTestRunnerCoverage" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false" />
|
|
325
|
+
<SUITE FILE_PATH="coverage/chrono$Test___Single_expression.info" NAME="Test - Single expression Coverage Results" MODIFIED="1595504124499" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="JestJavaScriptTestRunnerCoverage" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false" />
|
|
326
|
+
</component>
|
|
327
|
+
</project>
|
package/README.md
CHANGED
|
@@ -180,7 +180,7 @@ chrono.en.parseDate('6/10/2018');
|
|
|
180
180
|
chrono.ja.parseDate('昭和64年1月7日');
|
|
181
181
|
```
|
|
182
182
|
|
|
183
|
-
Current supported locale options are: `en`, `ja`
|
|
183
|
+
Current supported locale options are: `en`, `ja`, `fr`, `nl` and `ru` (`de`, `pt`, and `zh.hant` are partially supported).
|
|
184
184
|
|
|
185
185
|
## Customize Chrono
|
|
186
186
|
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<meta http-equiv="X-UA-Compatible" />
|
|
7
|
+
<script src="https://cdn.jsdelivr.net/npm/chart.js@2.8.0/dist/Chart.min.js"></script>
|
|
8
|
+
<style>
|
|
9
|
+
.wrapper {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex: wrap;
|
|
12
|
+
order: row;
|
|
13
|
+
}
|
|
14
|
+
</style>
|
|
15
|
+
<title>Basic parsing benchmark</title>
|
|
16
|
+
</head>
|
|
17
|
+
<body>
|
|
18
|
+
<div style="max-width: 800px">
|
|
19
|
+
<canvas id="chart1626605789860" width="16" height="9"></canvas>
|
|
20
|
+
</div>
|
|
21
|
+
<script>
|
|
22
|
+
const format = (num) => {
|
|
23
|
+
const chunked = [];
|
|
24
|
+
String(num)
|
|
25
|
+
.split("")
|
|
26
|
+
.reverse()
|
|
27
|
+
.forEach((char, index) => {
|
|
28
|
+
if (index % 3 === 0) {
|
|
29
|
+
chunked.unshift([char]);
|
|
30
|
+
} else {
|
|
31
|
+
chunked[0].unshift(char);
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
return chunked.map((chunk) => chunk.join("")).join(" ");
|
|
36
|
+
};
|
|
37
|
+
const ctx1626605789860 = document
|
|
38
|
+
.getElementById("chart1626605789860")
|
|
39
|
+
.getContext("2d");
|
|
40
|
+
const chart1626605789860 = new Chart(ctx1626605789860, {
|
|
41
|
+
type: "bar",
|
|
42
|
+
data: {
|
|
43
|
+
labels: [
|
|
44
|
+
"Parsing empty string",
|
|
45
|
+
"Parsing slash date - 11/12/2021",
|
|
46
|
+
"Parsing a long repeated space",
|
|
47
|
+
],
|
|
48
|
+
datasets: [
|
|
49
|
+
{
|
|
50
|
+
data: [284717, 63846, 11764],
|
|
51
|
+
backgroundColor: [
|
|
52
|
+
"rgba(63, 142, 252, 0.8)",
|
|
53
|
+
"rgba(116, 165, 127, 0.8)",
|
|
54
|
+
"rgba(158, 206, 154, 0.8)",
|
|
55
|
+
],
|
|
56
|
+
borderColor: [
|
|
57
|
+
"rgba(63, 142, 252, 1)",
|
|
58
|
+
"rgba(116, 165, 127, 1)",
|
|
59
|
+
"rgba(158, 206, 154, 1)",
|
|
60
|
+
],
|
|
61
|
+
borderWidth: 1,
|
|
62
|
+
},
|
|
63
|
+
],
|
|
64
|
+
},
|
|
65
|
+
options: {
|
|
66
|
+
legend: {
|
|
67
|
+
display: false,
|
|
68
|
+
},
|
|
69
|
+
title: {
|
|
70
|
+
display: true,
|
|
71
|
+
text: "Basic parsing benchmark",
|
|
72
|
+
fontSize: 16,
|
|
73
|
+
padding: 20,
|
|
74
|
+
},
|
|
75
|
+
tooltips: {
|
|
76
|
+
callbacks: {
|
|
77
|
+
label: (tooltipItem) => {
|
|
78
|
+
return format(tooltipItem.yLabel) + " ops/s";
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
},
|
|
82
|
+
scales: {
|
|
83
|
+
yAxes: [
|
|
84
|
+
{
|
|
85
|
+
gridLines: {
|
|
86
|
+
color: "rgba(127, 127, 127, 0.2)",
|
|
87
|
+
},
|
|
88
|
+
scaleLabel: {
|
|
89
|
+
display: true,
|
|
90
|
+
labelString: "Operations per second",
|
|
91
|
+
},
|
|
92
|
+
ticks: {
|
|
93
|
+
beginAtZero: true,
|
|
94
|
+
callback: format,
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
],
|
|
98
|
+
xAxes: [
|
|
99
|
+
{
|
|
100
|
+
gridLines: {
|
|
101
|
+
color: "rgba(127, 127, 127, 0.2)",
|
|
102
|
+
},
|
|
103
|
+
maxBarThickness: 150,
|
|
104
|
+
},
|
|
105
|
+
],
|
|
106
|
+
},
|
|
107
|
+
},
|
|
108
|
+
});
|
|
109
|
+
</script>
|
|
110
|
+
</body>
|
|
111
|
+
</html>
|