javascript-time-ago 2.3.13 → 2.5.2
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/CHANGELOG.md +5 -0
- package/README.md +27 -1
- package/bin/create-commonjs-package-json.js +11 -0
- package/bin/generate-load-all-locales.js +38 -6
- package/bin/generate-locale-messages.js +106 -21
- package/bundle/javascript-time-ago.js +1 -1
- package/bundle/javascript-time-ago.js.map +1 -1
- package/bundle/javascript-time-ago.min.js +1 -1
- package/bundle/javascript-time-ago.min.js.map +1 -1
- package/cache/index.cjs +2 -0
- package/cache/index.cjs.js +7 -0
- package/cache/index.js +1 -1
- package/cache/package.json +9 -3
- package/commonjs/LocaleDataStore.js +1 -1
- package/commonjs/LocaleDataStore.js.map +1 -1
- package/commonjs/PropTypes.js +26 -18
- package/commonjs/PropTypes.js.map +1 -1
- package/commonjs/TimeAgo.js +41 -48
- package/commonjs/TimeAgo.js.map +1 -1
- package/commonjs/TimeAgo.test.js +70 -70
- package/commonjs/TimeAgo.test.js.map +1 -1
- package/commonjs/cache.js +10 -14
- package/commonjs/cache.js.map +1 -1
- package/commonjs/cache.test.js +3 -3
- package/commonjs/cache.test.js.map +1 -1
- package/commonjs/isStyleObject.js +2 -2
- package/commonjs/isStyleObject.js.map +1 -1
- package/commonjs/isStyleObject.test.js +11 -11
- package/commonjs/isStyleObject.test.js.map +1 -1
- package/commonjs/locale.js +11 -16
- package/commonjs/locale.js.map +1 -1
- package/commonjs/locale.test.js +8 -4
- package/commonjs/locale.test.js.map +1 -1
- package/commonjs/package.json +5 -0
- package/commonjs/round.js +1 -1
- package/commonjs/round.js.map +1 -1
- package/commonjs/steps/approximate.js +3 -3
- package/commonjs/steps/approximate.js.map +1 -1
- package/commonjs/steps/approximate.test.js +5 -5
- package/commonjs/steps/approximate.test.js.map +1 -1
- package/commonjs/steps/getStep.js +10 -8
- package/commonjs/steps/getStep.js.map +1 -1
- package/commonjs/steps/getStep.test.js +16 -16
- package/commonjs/steps/getStep.test.js.map +1 -1
- package/commonjs/steps/getStepDenominator.js +2 -2
- package/commonjs/steps/getStepDenominator.js.map +1 -1
- package/commonjs/steps/getStepDenominator.test.js +4 -4
- package/commonjs/steps/getStepDenominator.test.js.map +1 -1
- package/commonjs/steps/getStepMinTime.js +5 -5
- package/commonjs/steps/getStepMinTime.js.map +1 -1
- package/commonjs/steps/getStepMinTime.test.js +4 -4
- package/commonjs/steps/getStepMinTime.test.js.map +1 -1
- package/commonjs/steps/getTimeToNextUpdate.js +8 -8
- package/commonjs/steps/getTimeToNextUpdate.js.map +1 -1
- package/commonjs/steps/getTimeToNextUpdate.test.js +18 -14
- package/commonjs/steps/getTimeToNextUpdate.test.js.map +1 -1
- package/commonjs/steps/getTimeToNextUpdateForUnit.js +3 -3
- package/commonjs/steps/getTimeToNextUpdateForUnit.js.map +1 -1
- package/commonjs/steps/getTimeToNextUpdateForUnit.test.js +8 -8
- package/commonjs/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
- package/commonjs/steps/helpers.js.map +1 -1
- package/commonjs/steps/helpers.test.js +1 -1
- package/commonjs/steps/helpers.test.js.map +1 -1
- package/commonjs/steps/index.js +24 -24
- package/commonjs/steps/index.js.map +1 -1
- package/commonjs/steps/renameLegacyProperties.js +8 -8
- package/commonjs/steps/renameLegacyProperties.js.map +1 -1
- package/commonjs/steps/renameLegacyProperties.test.js +6 -6
- package/commonjs/steps/renameLegacyProperties.test.js.map +1 -1
- package/commonjs/steps/round.js +2 -2
- package/commonjs/steps/round.js.map +1 -1
- package/commonjs/steps/round.test.js +6 -6
- package/commonjs/steps/round.test.js.map +1 -1
- package/commonjs/steps/units.js +2 -1
- package/commonjs/steps/units.js.map +1 -1
- package/commonjs/style/approximate.js +5 -5
- package/commonjs/style/approximate.js.map +1 -1
- package/commonjs/style/approximateTime.js +5 -5
- package/commonjs/style/approximateTime.js.map +1 -1
- package/commonjs/style/approximateTime.test.js +13 -18
- package/commonjs/style/approximateTime.test.js.map +1 -1
- package/commonjs/style/getStyleByName.js +29 -29
- package/commonjs/style/getStyleByName.js.map +1 -1
- package/commonjs/style/mini.js +2 -2
- package/commonjs/style/mini.js.map +1 -1
- package/commonjs/style/mini.test.js +62 -60
- package/commonjs/style/mini.test.js.map +1 -1
- package/commonjs/style/miniMinute.js +9 -7
- package/commonjs/style/miniMinute.js.map +1 -1
- package/commonjs/style/miniMinute.test.js +30 -28
- package/commonjs/style/miniMinute.test.js.map +1 -1
- package/commonjs/style/miniMinuteNow.js +9 -7
- package/commonjs/style/miniMinuteNow.js.map +1 -1
- package/commonjs/style/miniMinuteNow.test.js +30 -28
- package/commonjs/style/miniMinuteNow.test.js.map +1 -1
- package/commonjs/style/miniNow.js +9 -7
- package/commonjs/style/miniNow.js.map +1 -1
- package/commonjs/style/miniNow.test.js +30 -28
- package/commonjs/style/miniNow.test.js.map +1 -1
- package/commonjs/style/renameLegacyProperties.js +7 -5
- package/commonjs/style/renameLegacyProperties.js.map +1 -1
- package/commonjs/style/renameLegacyProperties.test.js +5 -5
- package/commonjs/style/renameLegacyProperties.test.js.map +1 -1
- package/commonjs/style/round.js +5 -5
- package/commonjs/style/round.js.map +1 -1
- package/commonjs/style/round.test.js +66 -60
- package/commonjs/style/round.test.js.map +1 -1
- package/commonjs/style/roundMinute.js +9 -7
- package/commonjs/style/roundMinute.js.map +1 -1
- package/commonjs/style/roundMinute.test.js +33 -31
- package/commonjs/style/roundMinute.test.js.map +1 -1
- package/commonjs/style/twitter.js +18 -18
- package/commonjs/style/twitter.js.map +1 -1
- package/commonjs/style/twitter.test.js +76 -74
- package/commonjs/style/twitter.test.js.map +1 -1
- package/commonjs/style/twitterFirstMinute.js +11 -9
- package/commonjs/style/twitterFirstMinute.js.map +1 -1
- package/commonjs/style/twitterFirstMinute.test.js +35 -33
- package/commonjs/style/twitterFirstMinute.test.js.map +1 -1
- package/commonjs/style/twitterMinute.js +9 -7
- package/commonjs/style/twitterMinute.js.map +1 -1
- package/commonjs/style/twitterMinute.test.js +36 -34
- package/commonjs/style/twitterMinute.test.js.map +1 -1
- package/commonjs/style/twitterMinuteNow.js +9 -7
- package/commonjs/style/twitterMinuteNow.js.map +1 -1
- package/commonjs/style/twitterMinuteNow.test.js +36 -34
- package/commonjs/style/twitterMinuteNow.test.js.map +1 -1
- package/commonjs/style/twitterNow.js +9 -7
- package/commonjs/style/twitterNow.js.map +1 -1
- package/commonjs/style/twitterNow.test.js +35 -33
- package/commonjs/style/twitterNow.test.js.map +1 -1
- package/gradation/index.cjs +2 -0
- package/gradation/index.cjs.js +7 -0
- package/gradation/index.js +1 -1
- package/gradation/package.json +9 -3
- package/index.cjs +9 -0
- package/index.cjs.js +14 -0
- package/index.d.ts +6 -0
- package/index.js +2 -2
- package/load-all-locales/index.cjs +281 -0
- package/load-all-locales/index.cjs.js +286 -0
- package/load-all-locales/index.js +563 -0
- package/load-all-locales/package.json +18 -0
- package/locale/af/index.cjs +3 -0
- package/locale/af/index.cjs.js +3 -0
- package/locale/af/index.js +1 -3
- package/locale/af/package.json +14 -0
- package/locale/am/index.cjs +3 -0
- package/locale/am/index.cjs.js +3 -0
- package/locale/am/index.js +1 -3
- package/locale/am/package.json +14 -0
- package/locale/ar/index.cjs +3 -0
- package/locale/ar/index.cjs.js +3 -0
- package/locale/ar/index.js +1 -3
- package/locale/ar/package.json +14 -0
- package/locale/ar-AE/index.cjs +3 -0
- package/locale/ar-AE/index.cjs.js +3 -0
- package/locale/ar-AE/index.js +1 -3
- package/locale/ar-AE/package.json +14 -0
- package/locale/as/index.cjs +3 -0
- package/locale/as/index.cjs.js +3 -0
- package/locale/as/index.js +1 -3
- package/locale/as/package.json +14 -0
- package/locale/ast/index.cjs +3 -0
- package/locale/ast/index.cjs.js +3 -0
- package/locale/ast/index.js +1 -3
- package/locale/ast/package.json +14 -0
- package/locale/az/index.cjs +3 -0
- package/locale/az/index.cjs.js +3 -0
- package/locale/az/index.js +1 -3
- package/locale/az/package.json +14 -0
- package/locale/be/index.cjs +3 -0
- package/locale/be/index.cjs.js +3 -0
- package/locale/be/index.js +1 -3
- package/locale/be/package.json +14 -0
- package/locale/bg/index.cjs +3 -0
- package/locale/bg/index.cjs.js +3 -0
- package/locale/bg/index.js +1 -3
- package/locale/bg/package.json +14 -0
- package/locale/bn/index.cjs +3 -0
- package/locale/bn/index.cjs.js +3 -0
- package/locale/bn/index.js +1 -3
- package/locale/bn/package.json +14 -0
- package/locale/br/index.cjs +3 -0
- package/locale/br/index.cjs.js +3 -0
- package/locale/br/index.js +1 -3
- package/locale/br/package.json +14 -0
- package/locale/brx/index.cjs +3 -0
- package/locale/brx/index.cjs.js +3 -0
- package/locale/brx/index.js +1 -0
- package/locale/brx/package.json +14 -0
- package/locale/brx.json +159 -0
- package/locale/bs/index.cjs +3 -0
- package/locale/bs/index.cjs.js +3 -0
- package/locale/bs/index.js +1 -3
- package/locale/bs/package.json +14 -0
- package/locale/bs-Cyrl/index.cjs +3 -0
- package/locale/bs-Cyrl/index.cjs.js +3 -0
- package/locale/bs-Cyrl/index.js +1 -3
- package/locale/bs-Cyrl/package.json +14 -0
- package/locale/ca/index.cjs +3 -0
- package/locale/ca/index.cjs.js +3 -0
- package/locale/ca/index.js +1 -3
- package/locale/ca/package.json +14 -0
- package/locale/ccp/index.cjs +3 -0
- package/locale/ccp/index.cjs.js +3 -0
- package/locale/ccp/index.js +1 -3
- package/locale/ccp/package.json +14 -0
- package/locale/ce/index.cjs +3 -0
- package/locale/ce/index.cjs.js +3 -0
- package/locale/ce/index.js +1 -3
- package/locale/ce/package.json +14 -0
- package/locale/ceb/index.cjs +3 -0
- package/locale/ceb/index.cjs.js +3 -0
- package/locale/ceb/index.js +1 -3
- package/locale/ceb/package.json +14 -0
- package/locale/chr/index.cjs +3 -0
- package/locale/chr/index.cjs.js +3 -0
- package/locale/chr/index.js +1 -3
- package/locale/chr/package.json +14 -0
- package/locale/cs/index.cjs +3 -0
- package/locale/cs/index.cjs.js +3 -0
- package/locale/cs/index.js +1 -3
- package/locale/cs/package.json +14 -0
- package/locale/cy/index.cjs +3 -0
- package/locale/cy/index.cjs.js +3 -0
- package/locale/cy/index.js +1 -3
- package/locale/cy/package.json +14 -0
- package/locale/da/index.cjs +3 -0
- package/locale/da/index.cjs.js +3 -0
- package/locale/da/index.js +1 -3
- package/locale/da/package.json +14 -0
- package/locale/de/index.cjs +3 -0
- package/locale/de/index.cjs.js +3 -0
- package/locale/de/index.js +1 -3
- package/locale/de/package.json +14 -0
- package/locale/dsb/index.cjs +3 -0
- package/locale/dsb/index.cjs.js +3 -0
- package/locale/dsb/index.js +1 -3
- package/locale/dsb/package.json +14 -0
- package/locale/dz/index.cjs +3 -0
- package/locale/dz/index.cjs.js +3 -0
- package/locale/dz/index.js +1 -3
- package/locale/dz/package.json +14 -0
- package/locale/ee/index.cjs +3 -0
- package/locale/ee/index.cjs.js +3 -0
- package/locale/ee/index.js +1 -3
- package/locale/ee/package.json +14 -0
- package/locale/el/index.cjs +3 -0
- package/locale/el/index.cjs.js +3 -0
- package/locale/el/index.js +1 -3
- package/locale/el/package.json +14 -0
- package/locale/en/index.cjs +3 -0
- package/locale/en/index.cjs.js +3 -0
- package/locale/en/index.js +1 -3
- package/locale/en/package.json +14 -0
- package/locale/en-001/index.cjs +3 -0
- package/locale/en-001/index.cjs.js +3 -0
- package/locale/en-001/index.js +1 -3
- package/locale/en-001/package.json +14 -0
- package/locale/en-150/index.cjs +3 -0
- package/locale/en-150/index.cjs.js +3 -0
- package/locale/en-150/index.js +1 -3
- package/locale/en-150/package.json +14 -0
- package/locale/en-AG/index.cjs +3 -0
- package/locale/en-AG/index.cjs.js +3 -0
- package/locale/en-AG/index.js +1 -3
- package/locale/en-AG/package.json +14 -0
- package/locale/en-AI/index.cjs +3 -0
- package/locale/en-AI/index.cjs.js +3 -0
- package/locale/en-AI/index.js +1 -3
- package/locale/en-AI/package.json +14 -0
- package/locale/en-AT/index.cjs +3 -0
- package/locale/en-AT/index.cjs.js +3 -0
- package/locale/en-AT/index.js +1 -3
- package/locale/en-AT/package.json +14 -0
- package/locale/en-AU/index.cjs +3 -0
- package/locale/en-AU/index.cjs.js +3 -0
- package/locale/en-AU/index.js +1 -3
- package/locale/en-AU/package.json +14 -0
- package/locale/en-BB/index.cjs +3 -0
- package/locale/en-BB/index.cjs.js +3 -0
- package/locale/en-BB/index.js +1 -3
- package/locale/en-BB/package.json +14 -0
- package/locale/en-BE/index.cjs +3 -0
- package/locale/en-BE/index.cjs.js +3 -0
- package/locale/en-BE/index.js +1 -3
- package/locale/en-BE/package.json +14 -0
- package/locale/en-BM/index.cjs +3 -0
- package/locale/en-BM/index.cjs.js +3 -0
- package/locale/en-BM/index.js +1 -3
- package/locale/en-BM/package.json +14 -0
- package/locale/en-BS/index.cjs +3 -0
- package/locale/en-BS/index.cjs.js +3 -0
- package/locale/en-BS/index.js +1 -3
- package/locale/en-BS/package.json +14 -0
- package/locale/en-BW/index.cjs +3 -0
- package/locale/en-BW/index.cjs.js +3 -0
- package/locale/en-BW/index.js +1 -3
- package/locale/en-BW/package.json +14 -0
- package/locale/en-BZ/index.cjs +3 -0
- package/locale/en-BZ/index.cjs.js +3 -0
- package/locale/en-BZ/index.js +1 -3
- package/locale/en-BZ/package.json +14 -0
- package/locale/en-CA/index.cjs +3 -0
- package/locale/en-CA/index.cjs.js +3 -0
- package/locale/en-CA/index.js +1 -3
- package/locale/en-CA/package.json +14 -0
- package/locale/en-CC/index.cjs +3 -0
- package/locale/en-CC/index.cjs.js +3 -0
- package/locale/en-CC/index.js +1 -3
- package/locale/en-CC/package.json +14 -0
- package/locale/en-CH/index.cjs +3 -0
- package/locale/en-CH/index.cjs.js +3 -0
- package/locale/en-CH/index.js +1 -3
- package/locale/en-CH/package.json +14 -0
- package/locale/en-CK/index.cjs +3 -0
- package/locale/en-CK/index.cjs.js +3 -0
- package/locale/en-CK/index.js +1 -3
- package/locale/en-CK/package.json +14 -0
- package/locale/en-CM/index.cjs +3 -0
- package/locale/en-CM/index.cjs.js +3 -0
- package/locale/en-CM/index.js +1 -3
- package/locale/en-CM/package.json +14 -0
- package/locale/en-CX/index.cjs +3 -0
- package/locale/en-CX/index.cjs.js +3 -0
- package/locale/en-CX/index.js +1 -3
- package/locale/en-CX/package.json +14 -0
- package/locale/en-CY/index.cjs +3 -0
- package/locale/en-CY/index.cjs.js +3 -0
- package/locale/en-CY/index.js +1 -3
- package/locale/en-CY/package.json +14 -0
- package/locale/en-DE/index.cjs +3 -0
- package/locale/en-DE/index.cjs.js +3 -0
- package/locale/en-DE/index.js +1 -3
- package/locale/en-DE/package.json +14 -0
- package/locale/en-DG/index.cjs +3 -0
- package/locale/en-DG/index.cjs.js +3 -0
- package/locale/en-DG/index.js +1 -3
- package/locale/en-DG/package.json +14 -0
- package/locale/en-DK/index.cjs +3 -0
- package/locale/en-DK/index.cjs.js +3 -0
- package/locale/en-DK/index.js +1 -3
- package/locale/en-DK/package.json +14 -0
- package/locale/en-DM/index.cjs +3 -0
- package/locale/en-DM/index.cjs.js +3 -0
- package/locale/en-DM/index.js +1 -3
- package/locale/en-DM/package.json +14 -0
- package/locale/en-ER/index.cjs +3 -0
- package/locale/en-ER/index.cjs.js +3 -0
- package/locale/en-ER/index.js +1 -3
- package/locale/en-ER/package.json +14 -0
- package/locale/en-FI/index.cjs +3 -0
- package/locale/en-FI/index.cjs.js +3 -0
- package/locale/en-FI/index.js +1 -3
- package/locale/en-FI/package.json +14 -0
- package/locale/en-FJ/index.cjs +3 -0
- package/locale/en-FJ/index.cjs.js +3 -0
- package/locale/en-FJ/index.js +1 -3
- package/locale/en-FJ/package.json +14 -0
- package/locale/en-FK/index.cjs +3 -0
- package/locale/en-FK/index.cjs.js +3 -0
- package/locale/en-FK/index.js +1 -3
- package/locale/en-FK/package.json +14 -0
- package/locale/en-FM/index.cjs +3 -0
- package/locale/en-FM/index.cjs.js +3 -0
- package/locale/en-FM/index.js +1 -3
- package/locale/en-FM/package.json +14 -0
- package/locale/en-GB/index.cjs +3 -0
- package/locale/en-GB/index.cjs.js +3 -0
- package/locale/en-GB/index.js +1 -3
- package/locale/en-GB/package.json +14 -0
- package/locale/en-GD/index.cjs +3 -0
- package/locale/en-GD/index.cjs.js +3 -0
- package/locale/en-GD/index.js +1 -3
- package/locale/en-GD/package.json +14 -0
- package/locale/en-GG/index.cjs +3 -0
- package/locale/en-GG/index.cjs.js +3 -0
- package/locale/en-GG/index.js +1 -3
- package/locale/en-GG/package.json +14 -0
- package/locale/en-GH/index.cjs +3 -0
- package/locale/en-GH/index.cjs.js +3 -0
- package/locale/en-GH/index.js +1 -3
- package/locale/en-GH/package.json +14 -0
- package/locale/en-GI/index.cjs +3 -0
- package/locale/en-GI/index.cjs.js +3 -0
- package/locale/en-GI/index.js +1 -3
- package/locale/en-GI/package.json +14 -0
- package/locale/en-GM/index.cjs +3 -0
- package/locale/en-GM/index.cjs.js +3 -0
- package/locale/en-GM/index.js +1 -3
- package/locale/en-GM/package.json +14 -0
- package/locale/en-GY/index.cjs +3 -0
- package/locale/en-GY/index.cjs.js +3 -0
- package/locale/en-GY/index.js +1 -3
- package/locale/en-GY/package.json +14 -0
- package/locale/en-HK/index.cjs +3 -0
- package/locale/en-HK/index.cjs.js +3 -0
- package/locale/en-HK/index.js +1 -3
- package/locale/en-HK/package.json +14 -0
- package/locale/en-IE/index.cjs +3 -0
- package/locale/en-IE/index.cjs.js +3 -0
- package/locale/en-IE/index.js +1 -3
- package/locale/en-IE/package.json +14 -0
- package/locale/en-IL/index.cjs +3 -0
- package/locale/en-IL/index.cjs.js +3 -0
- package/locale/en-IL/index.js +1 -3
- package/locale/en-IL/package.json +14 -0
- package/locale/en-IM/index.cjs +3 -0
- package/locale/en-IM/index.cjs.js +3 -0
- package/locale/en-IM/index.js +1 -3
- package/locale/en-IM/package.json +14 -0
- package/locale/en-IN/index.cjs +3 -0
- package/locale/en-IN/index.cjs.js +3 -0
- package/locale/en-IN/index.js +1 -3
- package/locale/en-IN/package.json +14 -0
- package/locale/en-IO/index.cjs +3 -0
- package/locale/en-IO/index.cjs.js +3 -0
- package/locale/en-IO/index.js +1 -3
- package/locale/en-IO/package.json +14 -0
- package/locale/en-JE/index.cjs +3 -0
- package/locale/en-JE/index.cjs.js +3 -0
- package/locale/en-JE/index.js +1 -3
- package/locale/en-JE/package.json +14 -0
- package/locale/en-JM/index.cjs +3 -0
- package/locale/en-JM/index.cjs.js +3 -0
- package/locale/en-JM/index.js +1 -3
- package/locale/en-JM/package.json +14 -0
- package/locale/en-KE/index.cjs +3 -0
- package/locale/en-KE/index.cjs.js +3 -0
- package/locale/en-KE/index.js +1 -3
- package/locale/en-KE/package.json +14 -0
- package/locale/en-KI/index.cjs +3 -0
- package/locale/en-KI/index.cjs.js +3 -0
- package/locale/en-KI/index.js +1 -3
- package/locale/en-KI/package.json +14 -0
- package/locale/en-KN/index.cjs +3 -0
- package/locale/en-KN/index.cjs.js +3 -0
- package/locale/en-KN/index.js +1 -3
- package/locale/en-KN/package.json +14 -0
- package/locale/en-KY/index.cjs +3 -0
- package/locale/en-KY/index.cjs.js +3 -0
- package/locale/en-KY/index.js +1 -3
- package/locale/en-KY/package.json +14 -0
- package/locale/en-LC/index.cjs +3 -0
- package/locale/en-LC/index.cjs.js +3 -0
- package/locale/en-LC/index.js +1 -3
- package/locale/en-LC/package.json +14 -0
- package/locale/en-LR/index.cjs +3 -0
- package/locale/en-LR/index.cjs.js +3 -0
- package/locale/en-LR/index.js +1 -3
- package/locale/en-LR/package.json +14 -0
- package/locale/en-LS/index.cjs +3 -0
- package/locale/en-LS/index.cjs.js +3 -0
- package/locale/en-LS/index.js +1 -3
- package/locale/en-LS/package.json +14 -0
- package/locale/en-MG/index.cjs +3 -0
- package/locale/en-MG/index.cjs.js +3 -0
- package/locale/en-MG/index.js +1 -3
- package/locale/en-MG/package.json +14 -0
- package/locale/en-MO/index.cjs +3 -0
- package/locale/en-MO/index.cjs.js +3 -0
- package/locale/en-MO/index.js +1 -3
- package/locale/en-MO/package.json +14 -0
- package/locale/en-MS/index.cjs +3 -0
- package/locale/en-MS/index.cjs.js +3 -0
- package/locale/en-MS/index.js +1 -3
- package/locale/en-MS/package.json +14 -0
- package/locale/en-MT/index.cjs +3 -0
- package/locale/en-MT/index.cjs.js +3 -0
- package/locale/en-MT/index.js +1 -3
- package/locale/en-MT/package.json +14 -0
- package/locale/en-MU/index.cjs +3 -0
- package/locale/en-MU/index.cjs.js +3 -0
- package/locale/en-MU/index.js +1 -3
- package/locale/en-MU/package.json +14 -0
- package/locale/en-MV/index.cjs +3 -0
- package/locale/en-MV/index.cjs.js +3 -0
- package/locale/en-MV/index.js +1 -0
- package/locale/en-MV/package.json +14 -0
- package/locale/en-MV.json +219 -0
- package/locale/en-MW/index.cjs +3 -0
- package/locale/en-MW/index.cjs.js +3 -0
- package/locale/en-MW/index.js +1 -3
- package/locale/en-MW/package.json +14 -0
- package/locale/en-MY/index.cjs +3 -0
- package/locale/en-MY/index.cjs.js +3 -0
- package/locale/en-MY/index.js +1 -3
- package/locale/en-MY/package.json +14 -0
- package/locale/en-NA/index.cjs +3 -0
- package/locale/en-NA/index.cjs.js +3 -0
- package/locale/en-NA/index.js +1 -3
- package/locale/en-NA/package.json +14 -0
- package/locale/en-NF/index.cjs +3 -0
- package/locale/en-NF/index.cjs.js +3 -0
- package/locale/en-NF/index.js +1 -3
- package/locale/en-NF/package.json +14 -0
- package/locale/en-NG/index.cjs +3 -0
- package/locale/en-NG/index.cjs.js +3 -0
- package/locale/en-NG/index.js +1 -3
- package/locale/en-NG/package.json +14 -0
- package/locale/en-NL/index.cjs +3 -0
- package/locale/en-NL/index.cjs.js +3 -0
- package/locale/en-NL/index.js +1 -3
- package/locale/en-NL/package.json +14 -0
- package/locale/en-NR/index.cjs +3 -0
- package/locale/en-NR/index.cjs.js +3 -0
- package/locale/en-NR/index.js +1 -3
- package/locale/en-NR/package.json +14 -0
- package/locale/en-NU/index.cjs +3 -0
- package/locale/en-NU/index.cjs.js +3 -0
- package/locale/en-NU/index.js +1 -3
- package/locale/en-NU/package.json +14 -0
- package/locale/en-NZ/index.cjs +3 -0
- package/locale/en-NZ/index.cjs.js +3 -0
- package/locale/en-NZ/index.js +1 -3
- package/locale/en-NZ/package.json +14 -0
- package/locale/en-PG/index.cjs +3 -0
- package/locale/en-PG/index.cjs.js +3 -0
- package/locale/en-PG/index.js +1 -3
- package/locale/en-PG/package.json +14 -0
- package/locale/en-PK/index.cjs +3 -0
- package/locale/en-PK/index.cjs.js +3 -0
- package/locale/en-PK/index.js +1 -3
- package/locale/en-PK/package.json +14 -0
- package/locale/en-PN/index.cjs +3 -0
- package/locale/en-PN/index.cjs.js +3 -0
- package/locale/en-PN/index.js +1 -3
- package/locale/en-PN/package.json +14 -0
- package/locale/en-PW/index.cjs +3 -0
- package/locale/en-PW/index.cjs.js +3 -0
- package/locale/en-PW/index.js +1 -3
- package/locale/en-PW/package.json +14 -0
- package/locale/en-RW/index.cjs +3 -0
- package/locale/en-RW/index.cjs.js +3 -0
- package/locale/en-RW/index.js +1 -3
- package/locale/en-RW/package.json +14 -0
- package/locale/en-SB/index.cjs +3 -0
- package/locale/en-SB/index.cjs.js +3 -0
- package/locale/en-SB/index.js +1 -3
- package/locale/en-SB/package.json +14 -0
- package/locale/en-SC/index.cjs +3 -0
- package/locale/en-SC/index.cjs.js +3 -0
- package/locale/en-SC/index.js +1 -3
- package/locale/en-SC/package.json +14 -0
- package/locale/en-SD/index.cjs +3 -0
- package/locale/en-SD/index.cjs.js +3 -0
- package/locale/en-SD/index.js +1 -3
- package/locale/en-SD/package.json +14 -0
- package/locale/en-SE/index.cjs +3 -0
- package/locale/en-SE/index.cjs.js +3 -0
- package/locale/en-SE/index.js +1 -3
- package/locale/en-SE/package.json +14 -0
- package/locale/en-SG/index.cjs +3 -0
- package/locale/en-SG/index.cjs.js +3 -0
- package/locale/en-SG/index.js +1 -3
- package/locale/en-SG/package.json +14 -0
- package/locale/en-SH/index.cjs +3 -0
- package/locale/en-SH/index.cjs.js +3 -0
- package/locale/en-SH/index.js +1 -3
- package/locale/en-SH/package.json +14 -0
- package/locale/en-SI/index.cjs +3 -0
- package/locale/en-SI/index.cjs.js +3 -0
- package/locale/en-SI/index.js +1 -3
- package/locale/en-SI/package.json +14 -0
- package/locale/en-SL/index.cjs +3 -0
- package/locale/en-SL/index.cjs.js +3 -0
- package/locale/en-SL/index.js +1 -3
- package/locale/en-SL/package.json +14 -0
- package/locale/en-SS/index.cjs +3 -0
- package/locale/en-SS/index.cjs.js +3 -0
- package/locale/en-SS/index.js +1 -3
- package/locale/en-SS/package.json +14 -0
- package/locale/en-SX/index.cjs +3 -0
- package/locale/en-SX/index.cjs.js +3 -0
- package/locale/en-SX/index.js +1 -3
- package/locale/en-SX/package.json +14 -0
- package/locale/en-SZ/index.cjs +3 -0
- package/locale/en-SZ/index.cjs.js +3 -0
- package/locale/en-SZ/index.js +1 -3
- package/locale/en-SZ/package.json +14 -0
- package/locale/en-TC/index.cjs +3 -0
- package/locale/en-TC/index.cjs.js +3 -0
- package/locale/en-TC/index.js +1 -3
- package/locale/en-TC/package.json +14 -0
- package/locale/en-TK/index.cjs +3 -0
- package/locale/en-TK/index.cjs.js +3 -0
- package/locale/en-TK/index.js +1 -3
- package/locale/en-TK/package.json +14 -0
- package/locale/en-TO/index.cjs +3 -0
- package/locale/en-TO/index.cjs.js +3 -0
- package/locale/en-TO/index.js +1 -3
- package/locale/en-TO/package.json +14 -0
- package/locale/en-TT/index.cjs +3 -0
- package/locale/en-TT/index.cjs.js +3 -0
- package/locale/en-TT/index.js +1 -3
- package/locale/en-TT/package.json +14 -0
- package/locale/en-TV/index.cjs +3 -0
- package/locale/en-TV/index.cjs.js +3 -0
- package/locale/en-TV/index.js +1 -3
- package/locale/en-TV/package.json +14 -0
- package/locale/en-TZ/index.cjs +3 -0
- package/locale/en-TZ/index.cjs.js +3 -0
- package/locale/en-TZ/index.js +1 -3
- package/locale/en-TZ/package.json +14 -0
- package/locale/en-UG/index.cjs +3 -0
- package/locale/en-UG/index.cjs.js +3 -0
- package/locale/en-UG/index.js +1 -3
- package/locale/en-UG/package.json +14 -0
- package/locale/en-VC/index.cjs +3 -0
- package/locale/en-VC/index.cjs.js +3 -0
- package/locale/en-VC/index.js +1 -3
- package/locale/en-VC/package.json +14 -0
- package/locale/en-VG/index.cjs +3 -0
- package/locale/en-VG/index.cjs.js +3 -0
- package/locale/en-VG/index.js +1 -3
- package/locale/en-VG/package.json +14 -0
- package/locale/en-VU/index.cjs +3 -0
- package/locale/en-VU/index.cjs.js +3 -0
- package/locale/en-VU/index.js +1 -3
- package/locale/en-VU/package.json +14 -0
- package/locale/en-WS/index.cjs +3 -0
- package/locale/en-WS/index.cjs.js +3 -0
- package/locale/en-WS/index.js +1 -3
- package/locale/en-WS/package.json +14 -0
- package/locale/en-ZA/index.cjs +3 -0
- package/locale/en-ZA/index.cjs.js +3 -0
- package/locale/en-ZA/index.js +1 -3
- package/locale/en-ZA/package.json +14 -0
- package/locale/en-ZM/index.cjs +3 -0
- package/locale/en-ZM/index.cjs.js +3 -0
- package/locale/en-ZM/index.js +1 -3
- package/locale/en-ZM/package.json +14 -0
- package/locale/en-ZW/index.cjs +3 -0
- package/locale/en-ZW/index.cjs.js +3 -0
- package/locale/en-ZW/index.js +1 -3
- package/locale/en-ZW/package.json +14 -0
- package/locale/es/index.cjs +3 -0
- package/locale/es/index.cjs.js +3 -0
- package/locale/es/index.js +1 -3
- package/locale/es/package.json +14 -0
- package/locale/es-419/index.cjs +3 -0
- package/locale/es-419/index.cjs.js +3 -0
- package/locale/es-419/index.js +1 -3
- package/locale/es-419/package.json +14 -0
- package/locale/es-AR/index.cjs +3 -0
- package/locale/es-AR/index.cjs.js +3 -0
- package/locale/es-AR/index.js +1 -3
- package/locale/es-AR/package.json +14 -0
- package/locale/es-BO/index.cjs +3 -0
- package/locale/es-BO/index.cjs.js +3 -0
- package/locale/es-BO/index.js +1 -3
- package/locale/es-BO/package.json +14 -0
- package/locale/es-BR/index.cjs +3 -0
- package/locale/es-BR/index.cjs.js +3 -0
- package/locale/es-BR/index.js +1 -3
- package/locale/es-BR/package.json +14 -0
- package/locale/es-BZ/index.cjs +3 -0
- package/locale/es-BZ/index.cjs.js +3 -0
- package/locale/es-BZ/index.js +1 -3
- package/locale/es-BZ/package.json +14 -0
- package/locale/es-CL/index.cjs +3 -0
- package/locale/es-CL/index.cjs.js +3 -0
- package/locale/es-CL/index.js +1 -3
- package/locale/es-CL/package.json +14 -0
- package/locale/es-CO/index.cjs +3 -0
- package/locale/es-CO/index.cjs.js +3 -0
- package/locale/es-CO/index.js +1 -3
- package/locale/es-CO/package.json +14 -0
- package/locale/es-CR/index.cjs +3 -0
- package/locale/es-CR/index.cjs.js +3 -0
- package/locale/es-CR/index.js +1 -3
- package/locale/es-CR/package.json +14 -0
- package/locale/es-CU/index.cjs +3 -0
- package/locale/es-CU/index.cjs.js +3 -0
- package/locale/es-CU/index.js +1 -3
- package/locale/es-CU/package.json +14 -0
- package/locale/es-DO/index.cjs +3 -0
- package/locale/es-DO/index.cjs.js +3 -0
- package/locale/es-DO/index.js +1 -3
- package/locale/es-DO/package.json +14 -0
- package/locale/es-EC/index.cjs +3 -0
- package/locale/es-EC/index.cjs.js +3 -0
- package/locale/es-EC/index.js +1 -3
- package/locale/es-EC/package.json +14 -0
- package/locale/es-GT/index.cjs +3 -0
- package/locale/es-GT/index.cjs.js +3 -0
- package/locale/es-GT/index.js +1 -3
- package/locale/es-GT/package.json +14 -0
- package/locale/es-HN/index.cjs +3 -0
- package/locale/es-HN/index.cjs.js +3 -0
- package/locale/es-HN/index.js +1 -3
- package/locale/es-HN/package.json +14 -0
- package/locale/es-MX/index.cjs +3 -0
- package/locale/es-MX/index.cjs.js +3 -0
- package/locale/es-MX/index.js +1 -3
- package/locale/es-MX/package.json +14 -0
- package/locale/es-NI/index.cjs +3 -0
- package/locale/es-NI/index.cjs.js +3 -0
- package/locale/es-NI/index.js +1 -3
- package/locale/es-NI/package.json +14 -0
- package/locale/es-PA/index.cjs +3 -0
- package/locale/es-PA/index.cjs.js +3 -0
- package/locale/es-PA/index.js +1 -3
- package/locale/es-PA/package.json +14 -0
- package/locale/es-PE/index.cjs +3 -0
- package/locale/es-PE/index.cjs.js +3 -0
- package/locale/es-PE/index.js +1 -3
- package/locale/es-PE/package.json +14 -0
- package/locale/es-PR/index.cjs +3 -0
- package/locale/es-PR/index.cjs.js +3 -0
- package/locale/es-PR/index.js +1 -3
- package/locale/es-PR/package.json +14 -0
- package/locale/es-PY/index.cjs +3 -0
- package/locale/es-PY/index.cjs.js +3 -0
- package/locale/es-PY/index.js +1 -3
- package/locale/es-PY/package.json +14 -0
- package/locale/es-SV/index.cjs +3 -0
- package/locale/es-SV/index.cjs.js +3 -0
- package/locale/es-SV/index.js +1 -3
- package/locale/es-SV/package.json +14 -0
- package/locale/es-US/index.cjs +3 -0
- package/locale/es-US/index.cjs.js +3 -0
- package/locale/es-US/index.js +1 -3
- package/locale/es-US/package.json +14 -0
- package/locale/es-UY/index.cjs +3 -0
- package/locale/es-UY/index.cjs.js +3 -0
- package/locale/es-UY/index.js +1 -3
- package/locale/es-UY/package.json +14 -0
- package/locale/es-VE/index.cjs +3 -0
- package/locale/es-VE/index.cjs.js +3 -0
- package/locale/es-VE/index.js +1 -3
- package/locale/es-VE/package.json +14 -0
- package/locale/et/index.cjs +3 -0
- package/locale/et/index.cjs.js +3 -0
- package/locale/et/index.js +1 -3
- package/locale/et/package.json +14 -0
- package/locale/eu/index.cjs +3 -0
- package/locale/eu/index.cjs.js +3 -0
- package/locale/eu/index.js +1 -3
- package/locale/eu/package.json +14 -0
- package/locale/fa/index.cjs +3 -0
- package/locale/fa/index.cjs.js +3 -0
- package/locale/fa/index.js +1 -3
- package/locale/fa/package.json +14 -0
- package/locale/ff-Adlm/index.cjs +3 -0
- package/locale/ff-Adlm/index.cjs.js +3 -0
- package/locale/ff-Adlm/index.js +1 -3
- package/locale/ff-Adlm/package.json +14 -0
- package/locale/fi/index.cjs +3 -0
- package/locale/fi/index.cjs.js +3 -0
- package/locale/fi/index.js +1 -3
- package/locale/fi/package.json +14 -0
- package/locale/fil/index.cjs +3 -0
- package/locale/fil/index.cjs.js +3 -0
- package/locale/fil/index.js +1 -3
- package/locale/fil/package.json +14 -0
- package/locale/fo/index.cjs +3 -0
- package/locale/fo/index.cjs.js +3 -0
- package/locale/fo/index.js +1 -3
- package/locale/fo/package.json +14 -0
- package/locale/fr/index.cjs +3 -0
- package/locale/fr/index.cjs.js +3 -0
- package/locale/fr/index.js +1 -3
- package/locale/fr/package.json +14 -0
- package/locale/fr-CA/index.cjs +3 -0
- package/locale/fr-CA/index.cjs.js +3 -0
- package/locale/fr-CA/index.js +1 -3
- package/locale/fr-CA/package.json +14 -0
- package/locale/fur/index.cjs +3 -0
- package/locale/fur/index.cjs.js +3 -0
- package/locale/fur/index.js +1 -3
- package/locale/fur/package.json +14 -0
- package/locale/fy/index.cjs +3 -0
- package/locale/fy/index.cjs.js +3 -0
- package/locale/fy/index.js +1 -3
- package/locale/fy/package.json +14 -0
- package/locale/ga/index.cjs +3 -0
- package/locale/ga/index.cjs.js +3 -0
- package/locale/ga/index.js +1 -3
- package/locale/ga/package.json +14 -0
- package/locale/gd/index.cjs +3 -0
- package/locale/gd/index.cjs.js +3 -0
- package/locale/gd/index.js +1 -3
- package/locale/gd/package.json +14 -0
- package/locale/gl/index.cjs +3 -0
- package/locale/gl/index.cjs.js +3 -0
- package/locale/gl/index.js +1 -3
- package/locale/gl/package.json +14 -0
- package/locale/gu/index.cjs +3 -0
- package/locale/gu/index.cjs.js +3 -0
- package/locale/gu/index.js +1 -3
- package/locale/gu/package.json +14 -0
- package/locale/ha/index.cjs +3 -0
- package/locale/ha/index.cjs.js +3 -0
- package/locale/ha/index.js +1 -3
- package/locale/ha/package.json +14 -0
- package/locale/he/index.cjs +3 -0
- package/locale/he/index.cjs.js +3 -0
- package/locale/he/index.js +1 -3
- package/locale/he/package.json +14 -0
- package/locale/hi/index.cjs +3 -0
- package/locale/hi/index.cjs.js +3 -0
- package/locale/hi/index.js +1 -3
- package/locale/hi/package.json +14 -0
- package/locale/hi-Latn/index.cjs +3 -0
- package/locale/hi-Latn/index.cjs.js +3 -0
- package/locale/hi-Latn/index.js +1 -0
- package/locale/hi-Latn/package.json +14 -0
- package/locale/hi-Latn.json +183 -0
- package/locale/hr/index.cjs +3 -0
- package/locale/hr/index.cjs.js +3 -0
- package/locale/hr/index.js +1 -3
- package/locale/hr/package.json +14 -0
- package/locale/hsb/index.cjs +3 -0
- package/locale/hsb/index.cjs.js +3 -0
- package/locale/hsb/index.js +1 -3
- package/locale/hsb/package.json +14 -0
- package/locale/hu/index.cjs +3 -0
- package/locale/hu/index.cjs.js +3 -0
- package/locale/hu/index.js +1 -3
- package/locale/hu/package.json +14 -0
- package/locale/hy/index.cjs +3 -0
- package/locale/hy/index.cjs.js +3 -0
- package/locale/hy/index.js +1 -3
- package/locale/hy/package.json +14 -0
- package/locale/ia/index.cjs +3 -0
- package/locale/ia/index.cjs.js +3 -0
- package/locale/ia/index.js +1 -3
- package/locale/ia/package.json +14 -0
- package/locale/id/index.cjs +3 -0
- package/locale/id/index.cjs.js +3 -0
- package/locale/id/index.js +1 -3
- package/locale/id/package.json +14 -0
- package/locale/ig/index.cjs +3 -0
- package/locale/ig/index.cjs.js +3 -0
- package/locale/ig/index.js +1 -3
- package/locale/ig/package.json +14 -0
- package/locale/is/index.cjs +3 -0
- package/locale/is/index.cjs.js +3 -0
- package/locale/is/index.js +1 -3
- package/locale/is/package.json +14 -0
- package/locale/it/index.cjs +3 -0
- package/locale/it/index.cjs.js +3 -0
- package/locale/it/index.js +1 -3
- package/locale/it/package.json +14 -0
- package/locale/ja/index.cjs +3 -0
- package/locale/ja/index.cjs.js +3 -0
- package/locale/ja/index.js +1 -3
- package/locale/ja/package.json +14 -0
- package/locale/jgo/index.cjs +3 -0
- package/locale/jgo/index.cjs.js +3 -0
- package/locale/jgo/index.js +1 -3
- package/locale/jgo/package.json +14 -0
- package/locale/jv/index.cjs +3 -0
- package/locale/jv/index.cjs.js +3 -0
- package/locale/jv/index.js +1 -3
- package/locale/jv/package.json +14 -0
- package/locale/ka/index.cjs +3 -0
- package/locale/ka/index.cjs.js +3 -0
- package/locale/ka/index.js +1 -3
- package/locale/ka/package.json +14 -0
- package/locale/kea/index.cjs +3 -0
- package/locale/kea/index.cjs.js +3 -0
- package/locale/kea/index.js +1 -3
- package/locale/kea/package.json +14 -0
- package/locale/kgp/index.cjs +3 -0
- package/locale/kgp/index.cjs.js +3 -0
- package/locale/kgp/index.js +1 -3
- package/locale/kgp/package.json +14 -0
- package/locale/kk/index.cjs +3 -0
- package/locale/kk/index.cjs.js +3 -0
- package/locale/kk/index.js +1 -3
- package/locale/kk/package.json +14 -0
- package/locale/kl/index.cjs +3 -0
- package/locale/kl/index.cjs.js +3 -0
- package/locale/kl/index.js +1 -3
- package/locale/kl/package.json +14 -0
- package/locale/km/index.cjs +3 -0
- package/locale/km/index.cjs.js +3 -0
- package/locale/km/index.js +1 -3
- package/locale/km/package.json +14 -0
- package/locale/kn/index.cjs +3 -0
- package/locale/kn/index.cjs.js +3 -0
- package/locale/kn/index.js +1 -3
- package/locale/kn/package.json +14 -0
- package/locale/ko/index.cjs +3 -0
- package/locale/ko/index.cjs.js +3 -0
- package/locale/ko/index.js +1 -3
- package/locale/ko/package.json +14 -0
- package/locale/kok/index.cjs +3 -0
- package/locale/kok/index.cjs.js +3 -0
- package/locale/kok/index.js +1 -3
- package/locale/kok/package.json +14 -0
- package/locale/ksh/index.cjs +3 -0
- package/locale/ksh/index.cjs.js +3 -0
- package/locale/ksh/index.js +1 -3
- package/locale/ksh/package.json +14 -0
- package/locale/ku/index.cjs +3 -0
- package/locale/ku/index.cjs.js +3 -0
- package/locale/ku/index.js +1 -3
- package/locale/ku/package.json +14 -0
- package/locale/ky/index.cjs +3 -0
- package/locale/ky/index.cjs.js +3 -0
- package/locale/ky/index.js +1 -3
- package/locale/ky/package.json +14 -0
- package/locale/lb/index.cjs +3 -0
- package/locale/lb/index.cjs.js +3 -0
- package/locale/lb/index.js +1 -3
- package/locale/lb/package.json +14 -0
- package/locale/lkt/index.cjs +3 -0
- package/locale/lkt/index.cjs.js +3 -0
- package/locale/lkt/index.js +1 -3
- package/locale/lkt/package.json +14 -0
- package/locale/lo/index.cjs +3 -0
- package/locale/lo/index.cjs.js +3 -0
- package/locale/lo/index.js +1 -3
- package/locale/lo/package.json +14 -0
- package/locale/lt/index.cjs +3 -0
- package/locale/lt/index.cjs.js +3 -0
- package/locale/lt/index.js +1 -3
- package/locale/lt/package.json +14 -0
- package/locale/lv/index.cjs +3 -0
- package/locale/lv/index.cjs.js +3 -0
- package/locale/lv/index.js +1 -3
- package/locale/lv/package.json +14 -0
- package/locale/mk/index.cjs +3 -0
- package/locale/mk/index.cjs.js +3 -0
- package/locale/mk/index.js +1 -3
- package/locale/mk/package.json +14 -0
- package/locale/ml/index.cjs +3 -0
- package/locale/ml/index.cjs.js +3 -0
- package/locale/ml/index.js +1 -3
- package/locale/ml/package.json +14 -0
- package/locale/mn/index.cjs +3 -0
- package/locale/mn/index.cjs.js +3 -0
- package/locale/mn/index.js +1 -3
- package/locale/mn/package.json +14 -0
- package/locale/mni/index.cjs +3 -0
- package/locale/mni/index.cjs.js +3 -0
- package/locale/mni/index.js +1 -3
- package/locale/mni/package.json +14 -0
- package/locale/mr/index.cjs +3 -0
- package/locale/mr/index.cjs.js +3 -0
- package/locale/mr/index.js +1 -3
- package/locale/mr/package.json +14 -0
- package/locale/ms/index.cjs +3 -0
- package/locale/ms/index.cjs.js +3 -0
- package/locale/ms/index.js +1 -3
- package/locale/ms/package.json +14 -0
- package/locale/mt/index.cjs +3 -0
- package/locale/mt/index.cjs.js +3 -0
- package/locale/mt/index.js +1 -3
- package/locale/mt/package.json +14 -0
- package/locale/my/index.cjs +3 -0
- package/locale/my/index.cjs.js +3 -0
- package/locale/my/index.js +1 -3
- package/locale/my/package.json +14 -0
- package/locale/mzn/index.cjs +3 -0
- package/locale/mzn/index.cjs.js +3 -0
- package/locale/mzn/index.js +1 -3
- package/locale/mzn/package.json +14 -0
- package/locale/nb/index.cjs +3 -0
- package/locale/nb/index.cjs.js +3 -0
- package/locale/nb/index.js +1 -3
- package/locale/nb/package.json +14 -0
- package/locale/ne/index.cjs +3 -0
- package/locale/ne/index.cjs.js +3 -0
- package/locale/ne/index.js +1 -3
- package/locale/ne/package.json +14 -0
- package/locale/nl/index.cjs +3 -0
- package/locale/nl/index.cjs.js +3 -0
- package/locale/nl/index.js +1 -3
- package/locale/nl/package.json +14 -0
- package/locale/nn/index.cjs +3 -0
- package/locale/nn/index.cjs.js +3 -0
- package/locale/nn/index.js +1 -3
- package/locale/nn/package.json +14 -0
- package/locale/no/index.cjs +3 -0
- package/locale/no/index.cjs.js +3 -0
- package/locale/no/index.js +1 -3
- package/locale/no/package.json +14 -0
- package/locale/or/index.cjs +3 -0
- package/locale/or/index.cjs.js +3 -0
- package/locale/or/index.js +1 -3
- package/locale/or/package.json +14 -0
- package/locale/pa/index.cjs +3 -0
- package/locale/pa/index.cjs.js +3 -0
- package/locale/pa/index.js +1 -3
- package/locale/pa/package.json +14 -0
- package/locale/pcm/index.cjs +3 -0
- package/locale/pcm/index.cjs.js +3 -0
- package/locale/pcm/index.js +1 -3
- package/locale/pcm/package.json +14 -0
- package/locale/pl/index.cjs +3 -0
- package/locale/pl/index.cjs.js +3 -0
- package/locale/pl/index.js +1 -3
- package/locale/pl/package.json +14 -0
- package/locale/ps/index.cjs +3 -0
- package/locale/ps/index.cjs.js +3 -0
- package/locale/ps/index.js +1 -3
- package/locale/ps/package.json +14 -0
- package/locale/ps-PK/index.cjs +3 -0
- package/locale/ps-PK/index.cjs.js +3 -0
- package/locale/ps-PK/index.js +1 -3
- package/locale/ps-PK/package.json +14 -0
- package/locale/pt/index.cjs +3 -0
- package/locale/pt/index.cjs.js +3 -0
- package/locale/pt/index.js +1 -3
- package/locale/pt/package.json +14 -0
- package/locale/pt-AO/index.cjs +3 -0
- package/locale/pt-AO/index.cjs.js +3 -0
- package/locale/pt-AO/index.js +1 -3
- package/locale/pt-AO/package.json +14 -0
- package/locale/pt-CH/index.cjs +3 -0
- package/locale/pt-CH/index.cjs.js +3 -0
- package/locale/pt-CH/index.js +1 -3
- package/locale/pt-CH/package.json +14 -0
- package/locale/pt-CV/index.cjs +3 -0
- package/locale/pt-CV/index.cjs.js +3 -0
- package/locale/pt-CV/index.js +1 -3
- package/locale/pt-CV/package.json +14 -0
- package/locale/pt-GQ/index.cjs +3 -0
- package/locale/pt-GQ/index.cjs.js +3 -0
- package/locale/pt-GQ/index.js +1 -3
- package/locale/pt-GQ/package.json +14 -0
- package/locale/pt-GW/index.cjs +3 -0
- package/locale/pt-GW/index.cjs.js +3 -0
- package/locale/pt-GW/index.js +1 -3
- package/locale/pt-GW/package.json +14 -0
- package/locale/pt-LU/index.cjs +3 -0
- package/locale/pt-LU/index.cjs.js +3 -0
- package/locale/pt-LU/index.js +1 -3
- package/locale/pt-LU/package.json +14 -0
- package/locale/pt-MO/index.cjs +3 -0
- package/locale/pt-MO/index.cjs.js +3 -0
- package/locale/pt-MO/index.js +1 -3
- package/locale/pt-MO/package.json +14 -0
- package/locale/pt-MZ/index.cjs +3 -0
- package/locale/pt-MZ/index.cjs.js +3 -0
- package/locale/pt-MZ/index.js +1 -3
- package/locale/pt-MZ/package.json +14 -0
- package/locale/pt-PT/index.cjs +3 -0
- package/locale/pt-PT/index.cjs.js +3 -0
- package/locale/pt-PT/index.js +1 -3
- package/locale/pt-PT/package.json +14 -0
- package/locale/pt-ST/index.cjs +3 -0
- package/locale/pt-ST/index.cjs.js +3 -0
- package/locale/pt-ST/index.js +1 -3
- package/locale/pt-ST/package.json +14 -0
- package/locale/pt-TL/index.cjs +3 -0
- package/locale/pt-TL/index.cjs.js +3 -0
- package/locale/pt-TL/index.js +1 -3
- package/locale/pt-TL/package.json +14 -0
- package/locale/qu/index.cjs +3 -0
- package/locale/qu/index.cjs.js +3 -0
- package/locale/qu/index.js +1 -3
- package/locale/qu/package.json +14 -0
- package/locale/rm/index.cjs +3 -0
- package/locale/rm/index.cjs.js +3 -0
- package/locale/rm/index.js +1 -3
- package/locale/rm/package.json +14 -0
- package/locale/ro/index.cjs +3 -0
- package/locale/ro/index.cjs.js +3 -0
- package/locale/ro/index.js +1 -3
- package/locale/ro/package.json +14 -0
- package/locale/ru/index.cjs +3 -0
- package/locale/ru/index.cjs.js +3 -0
- package/locale/ru/index.js +1 -3
- package/locale/ru/package.json +14 -0
- package/locale/sah/index.cjs +3 -0
- package/locale/sah/index.cjs.js +3 -0
- package/locale/sah/index.js +1 -3
- package/locale/sah/package.json +14 -0
- package/locale/sc/index.cjs +3 -0
- package/locale/sc/index.cjs.js +3 -0
- package/locale/sc/index.js +1 -3
- package/locale/sc/package.json +14 -0
- package/locale/sd/index.cjs +3 -0
- package/locale/sd/index.cjs.js +3 -0
- package/locale/sd/index.js +1 -3
- package/locale/sd/package.json +14 -0
- package/locale/se/index.cjs +3 -0
- package/locale/se/index.cjs.js +3 -0
- package/locale/se/index.js +1 -3
- package/locale/se/package.json +14 -0
- package/locale/se-FI/index.cjs +3 -0
- package/locale/se-FI/index.cjs.js +3 -0
- package/locale/se-FI/index.js +1 -3
- package/locale/se-FI/package.json +14 -0
- package/locale/si/index.cjs +3 -0
- package/locale/si/index.cjs.js +3 -0
- package/locale/si/index.js +1 -3
- package/locale/si/package.json +14 -0
- package/locale/sk/index.cjs +3 -0
- package/locale/sk/index.cjs.js +3 -0
- package/locale/sk/index.js +1 -3
- package/locale/sk/package.json +14 -0
- package/locale/sl/index.cjs +3 -0
- package/locale/sl/index.cjs.js +3 -0
- package/locale/sl/index.js +1 -3
- package/locale/sl/package.json +14 -0
- package/locale/so/index.cjs +3 -0
- package/locale/so/index.cjs.js +3 -0
- package/locale/so/index.js +1 -3
- package/locale/so/package.json +14 -0
- package/locale/sq/index.cjs +3 -0
- package/locale/sq/index.cjs.js +3 -0
- package/locale/sq/index.js +1 -3
- package/locale/sq/package.json +14 -0
- package/locale/sr/index.cjs +3 -0
- package/locale/sr/index.cjs.js +3 -0
- package/locale/sr/index.js +1 -3
- package/locale/sr/package.json +14 -0
- package/locale/sr-Cyrl-BA/index.cjs +3 -0
- package/locale/sr-Cyrl-BA/index.cjs.js +3 -0
- package/locale/sr-Cyrl-BA/index.js +1 -3
- package/locale/sr-Cyrl-BA/package.json +14 -0
- package/locale/sr-Latn/index.cjs +3 -0
- package/locale/sr-Latn/index.cjs.js +3 -0
- package/locale/sr-Latn/index.js +1 -3
- package/locale/sr-Latn/package.json +14 -0
- package/locale/sr-Latn-BA/index.cjs +3 -0
- package/locale/sr-Latn-BA/index.cjs.js +3 -0
- package/locale/sr-Latn-BA/index.js +1 -3
- package/locale/sr-Latn-BA/package.json +14 -0
- package/locale/su/index.cjs +3 -0
- package/locale/su/index.cjs.js +3 -0
- package/locale/su/index.js +1 -3
- package/locale/su/package.json +14 -0
- package/locale/sv/index.cjs +3 -0
- package/locale/sv/index.cjs.js +3 -0
- package/locale/sv/index.js +1 -3
- package/locale/sv/package.json +14 -0
- package/locale/sw/index.cjs +3 -0
- package/locale/sw/index.cjs.js +3 -0
- package/locale/sw/index.js +1 -3
- package/locale/sw/package.json +14 -0
- package/locale/ta/index.cjs +3 -0
- package/locale/ta/index.cjs.js +3 -0
- package/locale/ta/index.js +1 -3
- package/locale/ta/package.json +14 -0
- package/locale/te/index.cjs +3 -0
- package/locale/te/index.cjs.js +3 -0
- package/locale/te/index.js +1 -3
- package/locale/te/package.json +14 -0
- package/locale/tg/index.cjs +3 -0
- package/locale/tg/index.cjs.js +3 -0
- package/locale/tg/index.js +1 -3
- package/locale/tg/package.json +14 -0
- package/locale/th/index.cjs +3 -0
- package/locale/th/index.cjs.js +3 -0
- package/locale/th/index.js +1 -3
- package/locale/th/package.json +14 -0
- package/locale/ti/index.cjs +3 -0
- package/locale/ti/index.cjs.js +3 -0
- package/locale/ti/index.js +1 -3
- package/locale/ti/package.json +14 -0
- package/locale/tk/index.cjs +3 -0
- package/locale/tk/index.cjs.js +3 -0
- package/locale/tk/index.js +1 -3
- package/locale/tk/package.json +14 -0
- package/locale/to/index.cjs +3 -0
- package/locale/to/index.cjs.js +3 -0
- package/locale/to/index.js +1 -3
- package/locale/to/package.json +14 -0
- package/locale/tr/index.cjs +3 -0
- package/locale/tr/index.cjs.js +3 -0
- package/locale/tr/index.js +1 -3
- package/locale/tr/package.json +14 -0
- package/locale/tt/index.cjs +3 -0
- package/locale/tt/index.cjs.js +3 -0
- package/locale/tt/index.js +1 -3
- package/locale/tt/package.json +14 -0
- package/locale/ug/index.cjs +3 -0
- package/locale/ug/index.cjs.js +3 -0
- package/locale/ug/index.js +1 -3
- package/locale/ug/package.json +14 -0
- package/locale/uk/index.cjs +3 -0
- package/locale/uk/index.cjs.js +3 -0
- package/locale/uk/index.js +1 -3
- package/locale/uk/package.json +14 -0
- package/locale/ur/index.cjs +3 -0
- package/locale/ur/index.cjs.js +3 -0
- package/locale/ur/index.js +1 -3
- package/locale/ur/package.json +14 -0
- package/locale/ur-IN/index.cjs +3 -0
- package/locale/ur-IN/index.cjs.js +3 -0
- package/locale/ur-IN/index.js +1 -3
- package/locale/ur-IN/package.json +14 -0
- package/locale/uz/index.cjs +3 -0
- package/locale/uz/index.cjs.js +3 -0
- package/locale/uz/index.js +1 -3
- package/locale/uz/package.json +14 -0
- package/locale/uz-Cyrl/index.cjs +3 -0
- package/locale/uz-Cyrl/index.cjs.js +3 -0
- package/locale/uz-Cyrl/index.js +1 -3
- package/locale/uz-Cyrl/package.json +14 -0
- package/locale/vi/index.cjs +3 -0
- package/locale/vi/index.cjs.js +3 -0
- package/locale/vi/index.js +1 -3
- package/locale/vi/package.json +14 -0
- package/locale/wae/index.cjs +3 -0
- package/locale/wae/index.cjs.js +3 -0
- package/locale/wae/index.js +1 -3
- package/locale/wae/package.json +14 -0
- package/locale/wo/index.cjs +3 -0
- package/locale/wo/index.cjs.js +3 -0
- package/locale/wo/index.js +1 -3
- package/locale/wo/package.json +14 -0
- package/locale/yi/index.cjs +3 -0
- package/locale/yi/index.cjs.js +3 -0
- package/locale/yi/index.js +1 -3
- package/locale/yi/package.json +14 -0
- package/locale/yo/index.cjs +3 -0
- package/locale/yo/index.cjs.js +3 -0
- package/locale/yo/index.js +1 -3
- package/locale/yo/package.json +14 -0
- package/locale/yo-BJ/index.cjs +3 -0
- package/locale/yo-BJ/index.cjs.js +3 -0
- package/locale/yo-BJ/index.js +1 -3
- package/locale/yo-BJ/package.json +14 -0
- package/locale/yrl/index.cjs +3 -0
- package/locale/yrl/index.cjs.js +3 -0
- package/locale/yrl/index.js +1 -3
- package/locale/yrl/package.json +14 -0
- package/locale/yue/index.cjs +3 -0
- package/locale/yue/index.cjs.js +3 -0
- package/locale/yue/index.js +1 -3
- package/locale/yue/package.json +14 -0
- package/locale/yue-Hans/index.cjs +3 -0
- package/locale/yue-Hans/index.cjs.js +3 -0
- package/locale/yue-Hans/index.js +1 -3
- package/locale/yue-Hans/package.json +14 -0
- package/locale/zh/index.cjs +3 -0
- package/locale/zh/index.cjs.js +3 -0
- package/locale/zh/index.js +1 -3
- package/locale/zh/package.json +14 -0
- package/locale/zh-Hans-HK/index.cjs +3 -0
- package/locale/zh-Hans-HK/index.cjs.js +3 -0
- package/locale/zh-Hans-HK/index.js +1 -3
- package/locale/zh-Hans-HK/package.json +14 -0
- package/locale/zh-Hans-MO/index.cjs +3 -0
- package/locale/zh-Hans-MO/index.cjs.js +3 -0
- package/locale/zh-Hans-MO/index.js +1 -3
- package/locale/zh-Hans-MO/package.json +14 -0
- package/locale/zh-Hans-SG/index.cjs +3 -0
- package/locale/zh-Hans-SG/index.cjs.js +3 -0
- package/locale/zh-Hans-SG/index.js +1 -3
- package/locale/zh-Hans-SG/package.json +14 -0
- package/locale/zh-Hant/index.cjs +3 -0
- package/locale/zh-Hant/index.cjs.js +3 -0
- package/locale/zh-Hant/index.js +1 -3
- package/locale/zh-Hant/package.json +14 -0
- package/locale/zh-Hant-HK/index.cjs +3 -0
- package/locale/zh-Hant-HK/index.cjs.js +3 -0
- package/locale/zh-Hant-HK/index.js +1 -3
- package/locale/zh-Hant-HK/package.json +14 -0
- package/locale/zh-Hant-MO/index.cjs +3 -0
- package/locale/zh-Hant-MO/index.cjs.js +3 -0
- package/locale/zh-Hant-MO/index.js +1 -3
- package/locale/zh-Hant-MO/package.json +14 -0
- package/locale/zu/index.cjs +3 -0
- package/locale/zu/index.cjs.js +3 -0
- package/locale/zu/index.js +1 -3
- package/locale/zu/package.json +14 -0
- package/modules/LocaleDataStore.js.map +1 -1
- package/modules/PropTypes.js +7 -1
- package/modules/PropTypes.js.map +1 -1
- package/modules/TimeAgo.js +25 -32
- package/modules/TimeAgo.js.map +1 -1
- package/modules/TimeAgo.test.js +7 -7
- package/modules/TimeAgo.test.js.map +1 -1
- package/modules/cache.js +8 -12
- package/modules/cache.js.map +1 -1
- package/modules/cache.test.js +1 -1
- package/modules/cache.test.js.map +1 -1
- package/modules/isStyleObject.js +1 -1
- package/modules/isStyleObject.js.map +1 -1
- package/modules/isStyleObject.test.js +1 -1
- package/modules/isStyleObject.test.js.map +1 -1
- package/modules/locale.js +9 -14
- package/modules/locale.js.map +1 -1
- package/modules/locale.test.js +2 -2
- package/modules/locale.test.js.map +1 -1
- package/modules/round.js.map +1 -1
- package/modules/steps/approximate.js +1 -1
- package/modules/steps/approximate.js.map +1 -1
- package/modules/steps/approximate.test.js +2 -2
- package/modules/steps/approximate.test.js.map +1 -1
- package/modules/steps/getStep.js +6 -4
- package/modules/steps/getStep.js.map +1 -1
- package/modules/steps/getStep.test.js +5 -5
- package/modules/steps/getStep.test.js.map +1 -1
- package/modules/steps/getStepDenominator.js +1 -1
- package/modules/steps/getStepDenominator.js.map +1 -1
- package/modules/steps/getStepDenominator.test.js +1 -1
- package/modules/steps/getStepDenominator.test.js.map +1 -1
- package/modules/steps/getStepMinTime.js +4 -4
- package/modules/steps/getStepMinTime.js.map +1 -1
- package/modules/steps/getStepMinTime.test.js +1 -1
- package/modules/steps/getStepMinTime.test.js.map +1 -1
- package/modules/steps/getTimeToNextUpdate.js +3 -3
- package/modules/steps/getTimeToNextUpdate.js.map +1 -1
- package/modules/steps/getTimeToNextUpdate.test.js +1 -1
- package/modules/steps/getTimeToNextUpdate.test.js.map +1 -1
- package/modules/steps/getTimeToNextUpdateForUnit.js +2 -2
- package/modules/steps/getTimeToNextUpdateForUnit.js.map +1 -1
- package/modules/steps/getTimeToNextUpdateForUnit.test.js +1 -1
- package/modules/steps/getTimeToNextUpdateForUnit.test.js.map +1 -1
- package/modules/steps/helpers.js.map +1 -1
- package/modules/steps/helpers.test.js +1 -1
- package/modules/steps/helpers.test.js.map +1 -1
- package/modules/steps/index.js +4 -4
- package/modules/steps/index.js.map +1 -1
- package/modules/steps/renameLegacyProperties.js +7 -7
- package/modules/steps/renameLegacyProperties.js.map +1 -1
- package/modules/steps/renameLegacyProperties.test.js +2 -2
- package/modules/steps/renameLegacyProperties.test.js.map +1 -1
- package/modules/steps/round.js.map +1 -1
- package/modules/steps/round.test.js +2 -2
- package/modules/steps/round.test.js.map +1 -1
- package/modules/steps/units.js.map +1 -1
- package/modules/style/approximate.js +1 -1
- package/modules/style/approximate.js.map +1 -1
- package/modules/style/approximateTime.js +1 -1
- package/modules/style/approximateTime.js.map +1 -1
- package/modules/style/approximateTime.test.js +11 -16
- package/modules/style/approximateTime.test.js.map +1 -1
- package/modules/style/getStyleByName.js +13 -13
- package/modules/style/getStyleByName.js.map +1 -1
- package/modules/style/mini.js.map +1 -1
- package/modules/style/mini.test.js +8 -6
- package/modules/style/mini.test.js.map +1 -1
- package/modules/style/miniMinute.js +5 -3
- package/modules/style/miniMinute.js.map +1 -1
- package/modules/style/miniMinute.test.js +8 -6
- package/modules/style/miniMinute.test.js.map +1 -1
- package/modules/style/miniMinuteNow.js +5 -3
- package/modules/style/miniMinuteNow.js.map +1 -1
- package/modules/style/miniMinuteNow.test.js +8 -6
- package/modules/style/miniMinuteNow.test.js.map +1 -1
- package/modules/style/miniNow.js +5 -3
- package/modules/style/miniNow.js.map +1 -1
- package/modules/style/miniNow.test.js +8 -6
- package/modules/style/miniNow.test.js.map +1 -1
- package/modules/style/renameLegacyProperties.js +4 -2
- package/modules/style/renameLegacyProperties.js.map +1 -1
- package/modules/style/renameLegacyProperties.test.js +2 -2
- package/modules/style/renameLegacyProperties.test.js.map +1 -1
- package/modules/style/round.js +1 -1
- package/modules/style/round.js.map +1 -1
- package/modules/style/round.test.js +17 -11
- package/modules/style/round.test.js.map +1 -1
- package/modules/style/roundMinute.js +5 -3
- package/modules/style/roundMinute.js.map +1 -1
- package/modules/style/roundMinute.test.js +8 -6
- package/modules/style/roundMinute.test.js.map +1 -1
- package/modules/style/twitter.js +13 -13
- package/modules/style/twitter.js.map +1 -1
- package/modules/style/twitter.test.js +9 -7
- package/modules/style/twitter.test.js.map +1 -1
- package/modules/style/twitterFirstMinute.js +7 -5
- package/modules/style/twitterFirstMinute.js.map +1 -1
- package/modules/style/twitterFirstMinute.test.js +10 -8
- package/modules/style/twitterFirstMinute.test.js.map +1 -1
- package/modules/style/twitterMinute.js +5 -3
- package/modules/style/twitterMinute.js.map +1 -1
- package/modules/style/twitterMinute.test.js +10 -8
- package/modules/style/twitterMinute.test.js.map +1 -1
- package/modules/style/twitterMinuteNow.js +5 -3
- package/modules/style/twitterMinuteNow.js.map +1 -1
- package/modules/style/twitterMinuteNow.test.js +10 -8
- package/modules/style/twitterMinuteNow.test.js.map +1 -1
- package/modules/style/twitterNow.js +5 -3
- package/modules/style/twitterNow.js.map +1 -1
- package/modules/style/twitterNow.test.js +10 -8
- package/modules/style/twitterNow.test.js.map +1 -1
- package/package.json +671 -75
- package/prop-types/index.cjs +2 -0
- package/prop-types/index.cjs.js +7 -0
- package/prop-types/index.js +1 -1
- package/prop-types/package.json +9 -3
- package/{rollup.config.js → rollup.config.mjs} +0 -0
- package/steps/index.cjs +1 -0
- package/steps/index.cjs.js +6 -0
- package/steps/index.js +1 -1
- package/steps/package.json +9 -3
- package/cache/index.commonjs.js +0 -2
- package/gradation/index.commonjs.js +0 -2
- package/index.commonjs.js +0 -9
- package/load-all-locales.js +0 -278
- package/prop-types/index.commonjs.js +0 -2
- package/steps/index.commonjs.js +0 -2
package/cache/index.cjs
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
// This file id deprecated.
|
|
2
|
+
// It's the same as `index.cjs`, just with an added `.js` file extension.
|
|
3
|
+
// It only exists for compatibility with the software that doesn't like `*.cjs` file extension.
|
|
4
|
+
// https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/61#note_950728292
|
|
5
|
+
|
|
6
|
+
exports = module.exports = require('../commonjs/cache.js').default
|
|
7
|
+
exports['default'] = require('../commonjs/cache.js').default
|
package/cache/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// I guess this export is deprecated.
|
|
2
|
-
export { default } from '../modules/cache'
|
|
2
|
+
export { default } from '../modules/cache.js'
|
package/cache/package.json
CHANGED
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"private": true,
|
|
3
|
-
"name": "javascript-time-ago
|
|
4
|
-
"
|
|
5
|
-
"main": "index.commonjs.js",
|
|
3
|
+
"name": "javascript-time-ago/cache",
|
|
4
|
+
"main": "index.cjs",
|
|
6
5
|
"module": "index.js",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"import": "./index.js",
|
|
10
|
+
"require": "./index.cjs"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
7
13
|
"sideEffects": false
|
|
8
14
|
}
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.getLocaleData = getLocaleData;
|
|
7
6
|
exports.addLocaleData = addLocaleData;
|
|
7
|
+
exports.getLocaleData = getLocaleData;
|
|
8
8
|
// For all locales added
|
|
9
9
|
// their relative time formatter messages will be stored here.
|
|
10
10
|
var localesData = {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"LocaleDataStore.js","names":["localesData","getLocaleData","locale","addLocaleData","localeData","Error"],"sources":["../source/LocaleDataStore.js"],"sourcesContent":["// For all locales added\r\n// their relative time formatter messages will be stored here.\r\nconst localesData = {}\r\n\r\nexport function getLocaleData(locale) {\r\n\treturn localesData[locale]\r\n}\r\n\r\nexport function addLocaleData(localeData) {\r\n\tif (!localeData) {\r\n\t\tthrow new Error('[javascript-time-ago] No locale data passed.')\r\n\t}\r\n\t// This locale data is stored in a global variable\r\n\t// and later used when calling `.format(time)`.\r\n\tlocalesData[localeData.locale] = localeData\r\n}"],"mappings":";;;;;;;AAAA;AACA;AACA,IAAMA,WAAW,GAAG,EAApB;;AAEO,SAASC,aAAT,CAAuBC,MAAvB,EAA+B;EACrC,OAAOF,WAAW,CAACE,MAAD,CAAlB;AACA;;AAEM,SAASC,aAAT,CAAuBC,UAAvB,EAAmC;EACzC,IAAI,CAACA,UAAL,EAAiB;IAChB,MAAM,IAAIC,KAAJ,CAAU,8CAAV,CAAN;EACA,CAHwC,CAIzC;EACA;;;EACAL,WAAW,CAACI,UAAU,CAACF,MAAZ,CAAX,GAAiCE,UAAjC;AACA"}
|
package/commonjs/PropTypes.js
CHANGED
|
@@ -5,30 +5,38 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.style = void 0;
|
|
7
7
|
|
|
8
|
-
var _propTypes = require("prop-types");
|
|
8
|
+
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
|
+
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
9
11
|
|
|
10
12
|
// Deprecated: Moved to `react-time-ago`.
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
minTime:
|
|
20
|
-
|
|
21
|
-
}),
|
|
22
|
-
test:
|
|
23
|
-
|
|
13
|
+
var oneOfType = _propTypes["default"].oneOfType,
|
|
14
|
+
arrayOf = _propTypes["default"].arrayOf,
|
|
15
|
+
string = _propTypes["default"].string,
|
|
16
|
+
number = _propTypes["default"].number,
|
|
17
|
+
shape = _propTypes["default"].shape,
|
|
18
|
+
func = _propTypes["default"].func; // The first step isn't required to define `minTime` or `test()`.
|
|
19
|
+
|
|
20
|
+
var step = oneOfType([shape({
|
|
21
|
+
minTime: number,
|
|
22
|
+
formatAs: string.isRequired
|
|
23
|
+
}), shape({
|
|
24
|
+
test: func,
|
|
25
|
+
formatAs: string.isRequired
|
|
26
|
+
}), shape({
|
|
27
|
+
minTime: number,
|
|
28
|
+
format: func.isRequired
|
|
29
|
+
}), shape({
|
|
30
|
+
test: func,
|
|
31
|
+
format: func.isRequired
|
|
24
32
|
})]); // Formatting style.
|
|
25
33
|
|
|
26
|
-
var style =
|
|
34
|
+
var style = oneOfType([// Not using `oneOf()` here, because that way
|
|
27
35
|
// this package wouldn't support some hypothetical
|
|
28
36
|
// new styles added to `javascript-time-ago` in some future.
|
|
29
|
-
|
|
30
|
-
steps:
|
|
31
|
-
labels:
|
|
37
|
+
string, shape({
|
|
38
|
+
steps: arrayOf(step).isRequired,
|
|
39
|
+
labels: oneOfType([string, arrayOf(string)]).isRequired
|
|
32
40
|
})]);
|
|
33
41
|
exports.style = style;
|
|
34
42
|
//# sourceMappingURL=PropTypes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"file":"PropTypes.js","names":["oneOfType","PropTypes","arrayOf","string","number","shape","func","step","minTime","formatAs","isRequired","test","format","style","steps","labels"],"sources":["../source/PropTypes.js"],"sourcesContent":["// Deprecated: Moved to `react-time-ago`.\r\n\r\nimport PropTypes from 'prop-types'\r\n\r\nconst {\r\n\toneOfType,\r\n\tarrayOf,\r\n\tstring,\r\n\tnumber,\r\n\tshape,\r\n\tfunc\r\n} = PropTypes\r\n\r\n// The first step isn't required to define `minTime` or `test()`.\r\nconst step = oneOfType([\r\n\tshape({\r\n\t\tminTime: number,\r\n\t\tformatAs: string.isRequired\r\n\t}),\r\n\tshape({\r\n\t\ttest: func,\r\n\t\tformatAs: string.isRequired\r\n\t}),\r\n\tshape({\r\n\t\tminTime: number,\r\n\t\tformat: func.isRequired\r\n\t}),\r\n\tshape({\r\n\t\ttest: func,\r\n\t\tformat: func.isRequired\r\n\t})\r\n])\r\n\r\n// Formatting style.\r\nexport const style = oneOfType([\r\n\t// Not using `oneOf()` here, because that way\r\n\t// this package wouldn't support some hypothetical\r\n\t// new styles added to `javascript-time-ago` in some future.\r\n\tstring,\r\n\tshape({\r\n\t\tsteps: arrayOf(step).isRequired,\r\n\t\tlabels: oneOfType([\r\n\t\t\tstring,\r\n\t\t\tarrayOf(string)\r\n\t\t]).isRequired\r\n\t})\r\n])"],"mappings":";;;;;;;AAEA;;;;AAFA;AAIA,IACCA,SADD,GAOIC,qBAPJ,CACCD,SADD;AAAA,IAECE,OAFD,GAOID,qBAPJ,CAECC,OAFD;AAAA,IAGCC,MAHD,GAOIF,qBAPJ,CAGCE,MAHD;AAAA,IAICC,MAJD,GAOIH,qBAPJ,CAICG,MAJD;AAAA,IAKCC,KALD,GAOIJ,qBAPJ,CAKCI,KALD;AAAA,IAMCC,IAND,GAOIL,qBAPJ,CAMCK,IAND,C,CASA;;AACA,IAAMC,IAAI,GAAGP,SAAS,CAAC,CACtBK,KAAK,CAAC;EACLG,OAAO,EAAEJ,MADJ;EAELK,QAAQ,EAAEN,MAAM,CAACO;AAFZ,CAAD,CADiB,EAKtBL,KAAK,CAAC;EACLM,IAAI,EAAEL,IADD;EAELG,QAAQ,EAAEN,MAAM,CAACO;AAFZ,CAAD,CALiB,EAStBL,KAAK,CAAC;EACLG,OAAO,EAAEJ,MADJ;EAELQ,MAAM,EAAEN,IAAI,CAACI;AAFR,CAAD,CATiB,EAatBL,KAAK,CAAC;EACLM,IAAI,EAAEL,IADD;EAELM,MAAM,EAAEN,IAAI,CAACI;AAFR,CAAD,CAbiB,CAAD,CAAtB,C,CAmBA;;AACO,IAAMG,KAAK,GAAGb,SAAS,CAAC,CAC9B;AACA;AACA;AACAG,MAJ8B,EAK9BE,KAAK,CAAC;EACLS,KAAK,EAAEZ,OAAO,CAACK,IAAD,CAAP,CAAcG,UADhB;EAELK,MAAM,EAAEf,SAAS,CAAC,CACjBG,MADiB,EAEjBD,OAAO,CAACC,MAAD,CAFU,CAAD,CAAT,CAGLO;AALE,CAAD,CALyB,CAAD,CAAvB"}
|
package/commonjs/TimeAgo.js
CHANGED
|
@@ -3,39 +3,45 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports
|
|
6
|
+
exports["default"] = void 0;
|
|
7
7
|
|
|
8
8
|
var _relativeTimeFormat = _interopRequireDefault(require("relative-time-format"));
|
|
9
9
|
|
|
10
|
-
var _cache = _interopRequireDefault(require("./cache"));
|
|
10
|
+
var _cache = _interopRequireDefault(require("./cache.js"));
|
|
11
11
|
|
|
12
|
-
var _locale = _interopRequireDefault(require("./locale"));
|
|
12
|
+
var _locale = _interopRequireDefault(require("./locale.js"));
|
|
13
13
|
|
|
14
|
-
var _isStyleObject = _interopRequireDefault(require("./isStyleObject"));
|
|
14
|
+
var _isStyleObject = _interopRequireDefault(require("./isStyleObject.js"));
|
|
15
15
|
|
|
16
|
-
var _getStep3 = _interopRequireDefault(require("./steps/getStep"));
|
|
16
|
+
var _getStep3 = _interopRequireDefault(require("./steps/getStep.js"));
|
|
17
17
|
|
|
18
|
-
var _getStepDenominator = _interopRequireDefault(require("./steps/getStepDenominator"));
|
|
18
|
+
var _getStepDenominator = _interopRequireDefault(require("./steps/getStepDenominator.js"));
|
|
19
19
|
|
|
20
|
-
var _getTimeToNextUpdate = _interopRequireDefault(require("./steps/getTimeToNextUpdate"));
|
|
20
|
+
var _getTimeToNextUpdate = _interopRequireDefault(require("./steps/getTimeToNextUpdate.js"));
|
|
21
21
|
|
|
22
|
-
var _LocaleDataStore = require("./LocaleDataStore");
|
|
22
|
+
var _LocaleDataStore = require("./LocaleDataStore.js");
|
|
23
23
|
|
|
24
|
-
var _roundMinute = _interopRequireDefault(require("./style/roundMinute"));
|
|
24
|
+
var _roundMinute = _interopRequireDefault(require("./style/roundMinute.js"));
|
|
25
25
|
|
|
26
|
-
var _getStyleByName = _interopRequireDefault(require("./style/getStyleByName"));
|
|
26
|
+
var _getStyleByName = _interopRequireDefault(require("./style/getStyleByName.js"));
|
|
27
27
|
|
|
28
|
-
var _round = require("./round");
|
|
28
|
+
var _round = require("./round.js");
|
|
29
29
|
|
|
30
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
30
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
31
31
|
|
|
32
|
-
function _typeof(obj) {
|
|
32
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
33
33
|
|
|
34
|
-
function
|
|
34
|
+
function _createForOfIteratorHelperLoose(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (it) return (it = it.call(o)).next.bind(it); if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; return function () { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
35
35
|
|
|
36
|
-
function
|
|
36
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
37
37
|
|
|
38
|
-
function
|
|
38
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
39
|
+
|
|
40
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
41
|
+
|
|
42
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
|
|
43
|
+
|
|
44
|
+
function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
|
|
39
45
|
|
|
40
46
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
41
47
|
|
|
@@ -43,15 +49,13 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
|
|
|
43
49
|
|
|
44
50
|
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
45
51
|
|
|
46
|
-
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
|
|
52
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
47
53
|
|
|
48
54
|
// Valid time units.
|
|
49
55
|
var UNITS = ['now', // The rest are the same as in `Intl.RelativeTimeFormat`.
|
|
50
56
|
'second', 'minute', 'hour', 'day', 'week', 'month', 'quarter', 'year'];
|
|
51
57
|
|
|
52
|
-
var TimeAgo =
|
|
53
|
-
/*#__PURE__*/
|
|
54
|
-
function () {
|
|
58
|
+
var TimeAgo = /*#__PURE__*/function () {
|
|
55
59
|
/**
|
|
56
60
|
* @param {(string|string[])} locales=[] - Preferred locales (or locale).
|
|
57
61
|
* @param {boolean} [polyfill] — Pass `false` to use native `Intl.RelativeTimeFormat` and `Intl.PluralRules` instead of the polyfills.
|
|
@@ -72,7 +76,7 @@ function () {
|
|
|
72
76
|
// For example, new TimeAgo("en-US") -> "en".
|
|
73
77
|
|
|
74
78
|
|
|
75
|
-
this.locale = (0, _locale
|
|
79
|
+
this.locale = (0, _locale["default"])(locales.concat(TimeAgo.getDefaultLocale()), _LocaleDataStore.getLocaleData);
|
|
76
80
|
|
|
77
81
|
if (typeof Intl !== 'undefined') {
|
|
78
82
|
// Use `Intl.NumberFormat` for formatting numbers (when available).
|
|
@@ -89,14 +93,14 @@ function () {
|
|
|
89
93
|
this.IntlRelativeTimeFormat = Intl.RelativeTimeFormat;
|
|
90
94
|
this.IntlPluralRules = Intl.PluralRules;
|
|
91
95
|
} else {
|
|
92
|
-
this.IntlRelativeTimeFormat = _relativeTimeFormat
|
|
93
|
-
this.IntlPluralRules = _relativeTimeFormat
|
|
96
|
+
this.IntlRelativeTimeFormat = _relativeTimeFormat["default"];
|
|
97
|
+
this.IntlPluralRules = _relativeTimeFormat["default"].PluralRules;
|
|
94
98
|
} // Cache `Intl.RelativeTimeFormat` instance.
|
|
95
99
|
|
|
96
100
|
|
|
97
|
-
this.relativeTimeFormatCache = new _cache
|
|
101
|
+
this.relativeTimeFormatCache = new _cache["default"](); // Cache `Intl.PluralRules` instance.
|
|
98
102
|
|
|
99
|
-
this.pluralRulesCache = new _cache
|
|
103
|
+
this.pluralRulesCache = new _cache["default"]();
|
|
100
104
|
}
|
|
101
105
|
/**
|
|
102
106
|
* Formats relative date/time.
|
|
@@ -130,11 +134,11 @@ function () {
|
|
|
130
134
|
}
|
|
131
135
|
|
|
132
136
|
if (!style) {
|
|
133
|
-
style = _roundMinute
|
|
137
|
+
style = _roundMinute["default"];
|
|
134
138
|
}
|
|
135
139
|
|
|
136
140
|
if (typeof style === 'string') {
|
|
137
|
-
style = (0, _getStyleByName
|
|
141
|
+
style = (0, _getStyleByName["default"])(style);
|
|
138
142
|
}
|
|
139
143
|
|
|
140
144
|
var timestamp = getTimestamp(input); // Get locale messages for this type of labels.
|
|
@@ -166,7 +170,7 @@ function () {
|
|
|
166
170
|
var secondsPassed = (now - timestamp) / 1000; // in seconds
|
|
167
171
|
|
|
168
172
|
var future = options.future || secondsPassed < 0;
|
|
169
|
-
var nowLabel = getNowLabel(labels, (0, _LocaleDataStore.getLocaleData)(this.locale).now, (0, _LocaleDataStore.getLocaleData)(this.locale)
|
|
173
|
+
var nowLabel = getNowLabel(labels, (0, _LocaleDataStore.getLocaleData)(this.locale).now, (0, _LocaleDataStore.getLocaleData)(this.locale)["long"], future); // `custom` – A function of `{ elapsed, time, date, now, locale }`.
|
|
170
174
|
//
|
|
171
175
|
// Looks like `custom` function is deprecated and will be removed
|
|
172
176
|
// in the next major version.
|
|
@@ -207,10 +211,10 @@ function () {
|
|
|
207
211
|
var round = options.round || style.round; // Choose the appropriate time measurement unit
|
|
208
212
|
// and get the corresponding rounded time amount.
|
|
209
213
|
|
|
210
|
-
var _getStep = (0, _getStep3
|
|
214
|
+
var _getStep = (0, _getStep3["default"])( // "gradation" is a legacy name for "steps".
|
|
211
215
|
// For historical reasons, "approximate" steps are used by default.
|
|
212
216
|
// In the next major version, there'll be no default for `steps`.
|
|
213
|
-
style.gradation || style.steps || _roundMinute
|
|
217
|
+
style.gradation || style.steps || _roundMinute["default"].steps, secondsPassed, {
|
|
214
218
|
now: now,
|
|
215
219
|
units: units,
|
|
216
220
|
round: round,
|
|
@@ -232,7 +236,7 @@ function () {
|
|
|
232
236
|
}) || '';
|
|
233
237
|
|
|
234
238
|
if (options.getTimeToNextUpdate) {
|
|
235
|
-
var timeToNextUpdate = (0, _getTimeToNextUpdate
|
|
239
|
+
var timeToNextUpdate = (0, _getTimeToNextUpdate["default"])(timestamp, step, {
|
|
236
240
|
nextStep: nextStep,
|
|
237
241
|
prevStep: prevStep,
|
|
238
242
|
now: now,
|
|
@@ -289,7 +293,7 @@ function () {
|
|
|
289
293
|
} // Amount in units.
|
|
290
294
|
|
|
291
295
|
|
|
292
|
-
var amount = Math.abs(secondsPassed) / (0, _getStepDenominator
|
|
296
|
+
var amount = Math.abs(secondsPassed) / (0, _getStepDenominator["default"])(step); // Apply granularity to the time amount
|
|
293
297
|
// (and fallback to the previous step
|
|
294
298
|
// if the first level of granularity
|
|
295
299
|
// isn't met by this amount)
|
|
@@ -475,19 +479,8 @@ function () {
|
|
|
475
479
|
|
|
476
480
|
var localeData = (0, _LocaleDataStore.getLocaleData)(this.locale);
|
|
477
481
|
|
|
478
|
-
for (var _iterator = labelsType,
|
|
479
|
-
var
|
|
480
|
-
|
|
481
|
-
if (_isArray) {
|
|
482
|
-
if (_i2 >= _iterator.length) break;
|
|
483
|
-
_ref5 = _iterator[_i2++];
|
|
484
|
-
} else {
|
|
485
|
-
_i2 = _iterator.next();
|
|
486
|
-
if (_i2.done) break;
|
|
487
|
-
_ref5 = _i2.value;
|
|
488
|
-
}
|
|
489
|
-
|
|
490
|
-
var _labelsType = _ref5;
|
|
482
|
+
for (var _iterator = _createForOfIteratorHelperLoose(labelsType), _step; !(_step = _iterator()).done;) {
|
|
483
|
+
var _labelsType = _step.value;
|
|
491
484
|
|
|
492
485
|
if (localeData[_labelsType]) {
|
|
493
486
|
return {
|
|
@@ -506,7 +499,7 @@ function () {
|
|
|
506
499
|
*/
|
|
507
500
|
|
|
508
501
|
|
|
509
|
-
exports
|
|
502
|
+
exports["default"] = TimeAgo;
|
|
510
503
|
var defaultLocale = 'en';
|
|
511
504
|
/**
|
|
512
505
|
* Gets default locale.
|
|
@@ -550,7 +543,7 @@ var defaultLocaleHasBeenSpecified;
|
|
|
550
543
|
TimeAgo.addLocale = function (localeData) {
|
|
551
544
|
(0, _LocaleDataStore.addLocaleData)(localeData);
|
|
552
545
|
|
|
553
|
-
_relativeTimeFormat
|
|
546
|
+
_relativeTimeFormat["default"].addLocale(localeData);
|
|
554
547
|
};
|
|
555
548
|
/**
|
|
556
549
|
* (legacy alias)
|
|
@@ -655,6 +648,6 @@ function getNowLabel(labels, nowLabels, longLabels, future) {
|
|
|
655
648
|
}
|
|
656
649
|
|
|
657
650
|
function isStyle(variable) {
|
|
658
|
-
return typeof variable === 'string' || (0, _isStyleObject
|
|
651
|
+
return typeof variable === 'string' || (0, _isStyleObject["default"])(variable);
|
|
659
652
|
}
|
|
660
653
|
//# sourceMappingURL=TimeAgo.js.map
|
package/commonjs/TimeAgo.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../source/TimeAgo.js"],"names":["UNITS","TimeAgo","locales","polyfill","locale","concat","getDefaultLocale","getLocaleData","Intl","NumberFormat","numberFormat","IntlRelativeTimeFormat","RelativeTimeFormat","IntlPluralRules","PluralRules","RelativeTimeFormatPolyfill","relativeTimeFormatCache","Cache","pluralRulesCache","input","style","options","isStyle","undefined","defaultStyle","timestamp","getTimestamp","getLabels","flavour","labels","labelsType","now","Date","secondsPassed","future","nowLabel","getNowLabel","long","custom","date","time","elapsed","units","getTimeIntervalMeasurementUnits","round","gradation","steps","getNextStep","prevStep","step","nextStep","formattedDate","formatDateForStep","getTimeToNextUpdate","timeToNextUpdate","format","formatAs","unit","value","formatValue","Error","JSON","stringify","amount","Math","abs","granularity","valueForFormatting","sign","getFormatter","getFormattingRule","replace","formatNumber","formattingRules","pastOrFuture","quantifierRules","quantifier","getPluralRules","select","other","number","String","get","put","map","localeData","_labelsType","defaultLocale","setDefaultLocale","addDefaultLocale","defaultLocaleHasBeenSpecified","console","error","addLocale","addLabels","name","constructor","isMockedDate","getTime","object","allowedUnits","Object","keys","push","filter","indexOf","nowLabels","longLabels","past","second","current","variable"],"mappings":";;;;;;;AAAA;;AAEA;;AACA;;AACA;;AAEA;;AACA;;AACA;;AAEA;;AAKA;;AACA;;AAEA;;;;;;;;;;;;;;;;;;;;AAEA;AACA,IAAMA,KAAK,GAAG,CACb,KADa,EAEb;AACA,QAHa,EAIb,QAJa,EAKb,MALa,EAMb,KANa,EAOb,MAPa,EAQb,OARa,EASb,SATa,EAUb,MAVa,CAAd;;IAaqBC,O;;;AACpB;;;;AAIA,qBAA6C;AAAA,QAAjCC,OAAiC,uEAAvB,EAAuB;;AAAA,mFAAJ,EAAI;AAAA,QAAjBC,QAAiB,QAAjBA,QAAiB;;AAAA;;AAC5C;AACA,QAAI,OAAOD,OAAP,KAAmB,QAAvB,EAAiC;AAChCA,MAAAA,OAAO,GAAG,CAACA,OAAD,CAAV;AACA,KAJ2C,CAM5C;AACA;AACA;;;AACA,SAAKE,MAAL,GAAc,qBACbF,OAAO,CAACG,MAAR,CAAeJ,OAAO,CAACK,gBAAR,EAAf,CADa,EAEbC,8BAFa,CAAd;;AAKA,QAAI,OAAOC,IAAP,KAAgB,WAApB,EAAiC;AAChC;AACA,UAAIA,IAAI,CAACC,YAAT,EAAuB;AACtB,aAAKC,YAAL,GAAoB,IAAIF,IAAI,CAACC,YAAT,CAAsB,KAAKL,MAA3B,CAApB;AACA;AACD,KAnB2C,CAqB5C;AACA;AACA;AACA;;;AACA,QAAID,QAAQ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UAAU,CAACE,MAAX,CAAkBC,OAAzD,EAAkE;AACjE,WAAOH,UAAU,CAACE,MAAX,CAAkBC,OAAzB;AACA;AACD;;AAED,SAASxF,OAAT,CAAiByF,QAAjB,EAA2B;AAC1B,SAAO,OAAOA,QAAP,KAAoB,QAApB,IAAgC,4BAAcA,QAAd,CAAvC;AACA","sourcesContent":["import RelativeTimeFormatPolyfill from 'relative-time-format'\r\n\r\nimport Cache from './cache'\r\nimport chooseLocale from './locale'\r\nimport isStyleObject from './isStyleObject'\r\n\r\nimport getStep from './steps/getStep'\r\nimport getStepDenominator from './steps/getStepDenominator'\r\nimport getTimeToNextUpdate from './steps/getTimeToNextUpdate'\r\n\r\nimport {\r\n\taddLocaleData,\r\n\tgetLocaleData\r\n} from './LocaleDataStore'\r\n\r\nimport defaultStyle from './style/roundMinute'\r\nimport getStyleByName from './style/getStyleByName'\r\n\r\nimport { getRoundFunction } from './round'\r\n\r\n// Valid time units.\r\nconst UNITS = [\r\n\t'now',\r\n\t// The rest are the same as in `Intl.RelativeTimeFormat`.\r\n\t'second',\r\n\t'minute',\r\n\t'hour',\r\n\t'day',\r\n\t'week',\r\n\t'month',\r\n\t'quarter',\r\n\t'year'\r\n]\r\n\r\nexport default class TimeAgo {\r\n\t/**\r\n\t * @param {(string|string[])} locales=[] - Preferred locales (or locale).\r\n\t * @param {boolean} [polyfill] — Pass `false` to use native `Intl.RelativeTimeFormat` and `Intl.PluralRules` instead of the polyfills.\r\n\t */\r\n\tconstructor(locales = [], { polyfill } = {}) {\r\n\t\t// Convert `locales` to an array.\r\n\t\tif (typeof locales === 'string') {\r\n\t\t\tlocales = [locales]\r\n\t\t}\r\n\r\n\t\t// Choose the most appropriate locale\r\n\t\t// from the list of `locales` added by the user.\r\n\t\t// For example, new TimeAgo(\"en-US\") -> \"en\".\r\n\t\tthis.locale = chooseLocale(\r\n\t\t\tlocales.concat(TimeAgo.getDefaultLocale()),\r\n\t\t\tgetLocaleData\r\n\t\t)\r\n\r\n\t\tif (typeof Intl !== 'undefined') {\r\n\t\t\t// Use `Intl.NumberFormat` for formatting numbers (when available).\r\n\t\t\tif (Intl.NumberFormat) {\r\n\t\t\t\tthis.numberFormat = new Intl.NumberFormat(this.locale)\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Some people have requested the ability to use native\r\n\t\t// `Intl.RelativeTimeFormat` and `Intl.PluralRules`\r\n\t\t// instead of the polyfills.\r\n\t\t// https://github.com/catamphetamine/javascript-time-ago/issues/21\r\n\t\tif (polyfill === false) {\r\n\t\t\tthis.IntlRelativeTimeFormat = Intl.RelativeTimeFormat\r\n\t\t\tthis.IntlPluralRules = Intl.PluralRules\r\n\t\t} else {\r\n\t\t\tthis.IntlRelativeTimeFormat = RelativeTimeFormatPolyfill\r\n\t\t\tthis.IntlPluralRules = RelativeTimeFormatPolyfill.PluralRules\r\n\t\t}\r\n\r\n\t\t// Cache `Intl.RelativeTimeFormat` instance.\r\n\t\tthis.relativeTimeFormatCache = new Cache()\r\n\r\n\t\t// Cache `Intl.PluralRules` instance.\r\n\t\tthis.pluralRulesCache = new Cache()\r\n\t}\r\n\r\n\t/**\r\n\t * Formats relative date/time.\r\n\t *\r\n\t * @param {number} [options.now] - Sets the current date timestamp.\r\n\t *\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`:\r\n\t * as \"future\" (`true`) or \"past\" (`false`).\r\n\t * Is `false` by default, but should have been `true` actually,\r\n\t * in order to correspond to `Intl.RelativeTimeFormat`\r\n\t * that uses `future` formatting for `0` unless `-0` is passed.\r\n\t *\r\n\t * @param {string} [options.round] — Rounding method. Overrides the style's one.\r\n\t *\r\n\t * @param {boolean} [options.getTimeToNextUpdate] — Pass `true` to return `[formattedDate, timeToNextUpdate]` instead of just `formattedDate`.\r\n\t *\r\n\t * @return {string} The formatted relative date/time. If no eligible `step` is found, then an empty string is returned.\r\n\t */\r\n\tformat(input, style, options) {\r\n\t\tif (!options) {\r\n\t\t\tif (style && !isStyle(style)) {\r\n\t\t\t\toptions = style\r\n\t\t\t\tstyle = undefined\r\n\t\t\t} else {\r\n\t\t\t\toptions = {}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (!style) {\r\n\t\t\tstyle = defaultStyle\r\n\t\t}\r\n\r\n\t\tif (typeof style === 'string') {\r\n\t\t\tstyle = getStyleByName(style)\r\n\t\t}\r\n\r\n\t\tconst timestamp = getTimestamp(input)\r\n\r\n\t\t// Get locale messages for this type of labels.\r\n\t\t// \"flavour\" is a legacy name for \"labels\".\r\n\t\tconst { labels, labelsType } = this.getLabels(style.flavour || style.labels)\r\n\r\n\t\tlet now\r\n\t\t// Can pass a custom `now`, e.g. for testing purposes.\r\n\t\t//\r\n\t\t// Legacy way was passing `now` in `style`.\r\n\t\t// That way is deprecated.\r\n\t\tif (style.now !== undefined) {\r\n\t\t\tnow = style.now\r\n\t\t}\r\n\t\t// The new way is passing `now` option to `.format()`.\r\n\t\tif (now === undefined && options.now !== undefined) {\r\n\t\t\tnow = options.now\r\n\t\t}\r\n\t\tif (now === undefined) {\r\n\t\t\tnow = Date.now()\r\n\t\t}\r\n\r\n\t\t// how much time has passed (in seconds)\r\n\t\tconst secondsPassed = (now - timestamp) / 1000 // in seconds\r\n\r\n\t\tconst future = options.future || secondsPassed < 0\r\n\r\n\t\tconst nowLabel = getNowLabel(\r\n\t\t\tlabels,\r\n\t\t\tgetLocaleData(this.locale).now,\r\n\t\t\tgetLocaleData(this.locale).long,\r\n\t\t\tfuture\r\n\t\t)\r\n\r\n\t\t// `custom` – A function of `{ elapsed, time, date, now, locale }`.\r\n\t\t//\r\n\t\t// Looks like `custom` function is deprecated and will be removed\r\n\t\t// in the next major version.\r\n\t\t//\r\n\t\t// If this function returns a value, then the `.format()` call will return that value.\r\n\t\t// Otherwise the relative date/time is formatted as usual.\r\n\t\t// This feature is currently not used anywhere and is here\r\n\t\t// just for providing the ultimate customization point\r\n\t\t// in case anyone would ever need that. Prefer using\r\n\t\t// `steps[step].format(value, locale)` instead.\r\n\t\t//\r\n\t\tif (style.custom) {\r\n\t\t\tconst custom = style.custom({\r\n\t\t\t\tnow,\r\n\t\t\t\tdate: new Date(timestamp),\r\n\t\t\t\ttime: timestamp,\r\n\t\t\t\telapsed: secondsPassed,\r\n\t\t\t\tlocale: this.locale\r\n\t\t\t})\r\n\t\t\tif (custom !== undefined) {\r\n\t\t\t\t// Won't return `timeToNextUpdate` here\r\n\t\t\t\t// because `custom()` seems deprecated.\r\n\t\t\t\treturn custom\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Get the list of available time interval units.\r\n\t\tconst units = getTimeIntervalMeasurementUnits(\r\n\t\t\t// Controlling `style.steps` through `style.units` seems to be deprecated:\r\n\t\t\t// create a new custom `style` instead.\r\n\t\t\tstyle.units,\r\n\t\t\tlabels,\r\n\t\t\tnowLabel\r\n\t\t)\r\n\r\n\t\t// // If no available time unit is suitable, just output an empty string.\r\n\t\t// if (units.length === 0) {\r\n\t\t// \tconsole.error(`None of the \"${units.join(', ')}\" time units have been found in \"${labelsType}\" labels for \"${this.locale}\" locale.`)\r\n\t\t// \treturn ''\r\n\t\t// }\r\n\r\n\t\tconst round = options.round || style.round\r\n\r\n\t\t// Choose the appropriate time measurement unit\r\n\t\t// and get the corresponding rounded time amount.\r\n\t\tconst [prevStep, step, nextStep] = getStep(\r\n\t\t\t// \"gradation\" is a legacy name for \"steps\".\r\n\t\t\t// For historical reasons, \"approximate\" steps are used by default.\r\n\t\t\t// In the next major version, there'll be no default for `steps`.\r\n\t\t\tstyle.gradation || style.steps || defaultStyle.steps,\r\n\t\t\tsecondsPassed,\r\n\t\t\t{ now, units, round, future, getNextStep: true }\r\n\t\t)\r\n\r\n\t\tconst formattedDate = this.formatDateForStep(timestamp, step, secondsPassed, {\r\n\t\t\tlabels,\r\n\t\t\tlabelsType,\r\n\t\t\tnowLabel,\r\n\t\t\tnow,\r\n\t\t\tfuture,\r\n\t\t\tround\r\n\t\t}) || ''\r\n\r\n\t\tif (options.getTimeToNextUpdate) {\r\n\t\t\tconst timeToNextUpdate = getTimeToNextUpdate(timestamp, step, {\r\n\t\t\t\tnextStep,\r\n\t\t\t\tprevStep,\r\n\t\t\t\tnow,\r\n\t\t\t\tfuture,\r\n\t\t\t\tround\r\n\t\t\t})\r\n\t\t\treturn [formattedDate, timeToNextUpdate]\r\n\t\t}\r\n\r\n\t\treturn formattedDate\r\n\t}\r\n\r\n\tformatDateForStep(timestamp, step, secondsPassed, {\r\n\t\tlabels,\r\n\t\tlabelsType,\r\n\t\tnowLabel,\r\n\t\tnow,\r\n\t\tfuture,\r\n\t\tround\r\n\t}) {\r\n\t\t// If no step matches, then output an empty string.\r\n\t\tif (!step) {\r\n\t\t\treturn\r\n\t\t}\r\n\r\n\t\tif (step.format) {\r\n\t\t\treturn step.format(timestamp, this.locale, {\r\n\t\t\t\tformatAs: (unit, value) => {\r\n\t\t\t\t\t// Mimicks `Intl.RelativeTimeFormat.format()`.\r\n\t\t\t\t\treturn this.formatValue(value, unit, {\r\n\t\t\t\t\t\tlabels,\r\n\t\t\t\t\t\tfuture\r\n\t\t\t\t\t})\r\n\t\t\t\t},\r\n\t\t\t\tnow,\r\n\t\t\t\tfuture\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\t// \"unit\" is now called \"formatAs\".\r\n\t\tconst unit = step.unit || step.formatAs\r\n\r\n\t\tif (!unit) {\r\n\t\t\tthrow new Error(`[javascript-time-ago] Each step must define either \\`formatAs\\` or \\`format()\\`. Step: ${JSON.stringify(step)}`)\r\n\t\t}\r\n\r\n\t\t// `Intl.RelativeTimeFormat` doesn't operate in \"now\" units.\r\n\t\t// Therefore, threat \"now\" as a special case.\r\n\t\tif (unit === 'now') {\r\n\t\t\treturn nowLabel\r\n\t\t}\r\n\r\n\t\t// Amount in units.\r\n\t\tlet amount = Math.abs(secondsPassed) / getStepDenominator(step)\r\n\r\n\t\t// Apply granularity to the time amount\r\n\t\t// (and fallback to the previous step\r\n\t\t// if the first level of granularity\r\n\t\t// isn't met by this amount)\r\n\t\t//\r\n\t\t// `granularity` — (advanced) Time interval value \"granularity\".\r\n\t\t// For example, it could be set to `5` for minutes to allow only 5-minute increments\r\n\t\t// when formatting time intervals: `0 minutes`, `5 minutes`, `10 minutes`, etc.\r\n\t\t// Perhaps this feature will be removed because there seem to be no use cases\r\n\t\t// of it in the real world.\r\n\t\t//\r\n\t\tif (step.granularity) {\r\n\t\t\t// Recalculate the amount of seconds passed based on granularity\r\n\t\t\tamount = getRoundFunction(round)(amount / step.granularity) * step.granularity\r\n\t\t}\r\n\r\n\t\tlet valueForFormatting = -1 * Math.sign(secondsPassed) * getRoundFunction(round)(amount)\r\n\r\n\t\t// By default, this library formats a `0` in \"past\" mode,\r\n\t\t// unless `future: true` option is passed.\r\n\t\t// This is different to `relative-time-format`'s behavior\r\n\t\t// which formats a `0` in \"future\" mode by default, unless it's a `-0`.\r\n\t\t// So, convert `0` to `-0` if `future: true` option wasn't passed.\r\n\t\t// `=== 0` matches both `0` and `-0`.\r\n\t\tif (valueForFormatting === 0) {\r\n\t\t\tif (future) {\r\n\t\t\t\tvalueForFormatting = 0\r\n\t\t\t} else {\r\n\t\t\t\tvalueForFormatting = -0\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tswitch (labelsType) {\r\n\t\t\tcase 'long':\r\n\t\t\tcase 'short':\r\n\t\t\tcase 'narrow':\r\n\t\t\t\t// Format the amount using `Intl.RelativeTimeFormat`.\r\n\t\t\t\treturn this.getFormatter(labelsType).format(valueForFormatting, unit)\r\n\t\t\tdefault:\r\n\t\t\t\t// Format the amount.\r\n\t\t\t\t// (mimicks `Intl.RelativeTimeFormat` behavior for other time label styles)\r\n\t\t\t\treturn this.formatValue(valueForFormatting, unit, {\r\n\t\t\t\t\tlabels,\r\n\t\t\t\t\tfuture\r\n\t\t\t\t})\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Mimicks what `Intl.RelativeTimeFormat` does for additional locale styles.\r\n\t * @param {number} value\r\n\t * @param {string} unit\r\n\t * @param {object} options.labels — Relative time labels.\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`: as \"future\" (`true`) or \"past\" (`false`). Is `false` by default, but should have been `true` actually.\r\n\t * @return {string}\r\n\t */\r\n\tformatValue(value, unit, { labels, future }) {\r\n\t\treturn this.getFormattingRule(labels, unit, value, { future })\r\n\t\t\t.replace('{0}', this.formatNumber(Math.abs(value)))\r\n\t}\r\n\r\n\t/**\r\n\t * Returns formatting rule for `value` in `units` (either in past or in future).\r\n\t * @param {object} formattingRules — Relative time labels for different units.\r\n\t * @param {string} unit - Time interval measurement unit.\r\n\t * @param {number} value - Time interval value.\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`: as \"future\" (`true`) or \"past\" (`false`). Is `false` by default.\r\n\t * @return {string}\r\n\t * @example\r\n\t * // Returns \"{0} days ago\"\r\n\t * getFormattingRule(en.long, \"day\", -2, 'en')\r\n\t */\r\n\tgetFormattingRule(formattingRules, unit, value, { future }) {\r\n\t\t// Passing the language is required in order to\r\n\t\t// be able to correctly classify the `value` as a number.\r\n\t\tconst locale = this.locale\r\n\t\tformattingRules = formattingRules[unit]\r\n\t\t// Check for a special \"compacted\" rules case:\r\n\t\t// if formatting rules are the same for \"past\" and \"future\",\r\n\t\t// and also for all possible `value`s, then those rules are\r\n\t\t// stored as a single string.\r\n\t\tif (typeof formattingRules === 'string') {\r\n\t\t\treturn formattingRules\r\n\t\t}\r\n\t\t// Choose either \"past\" or \"future\" based on time `value` sign.\r\n\t\t// If \"past\" is same as \"future\" then they're stored as \"other\".\r\n\t\t// If there's only \"other\" then it's being collapsed.\r\n\t\tconst pastOrFuture = value === 0 ? (future ? 'future' : 'past') : (value < 0 ? 'past' : 'future')\r\n\t\tconst quantifierRules = formattingRules[pastOrFuture] || formattingRules\r\n\t\t// Bundle size optimization technique.\r\n\t\tif (typeof quantifierRules === 'string') {\r\n\t\t\treturn quantifierRules\r\n\t\t}\r\n\t\t// Quantify `value`.\r\n\t\tconst quantifier = this.getPluralRules().select(Math.abs(value))\r\n\t\t// \"other\" rule is supposed to always be present.\r\n\t\t// If only \"other\" rule is present then \"rules\" is not an object and is a string.\r\n\t\treturn quantifierRules[quantifier] || quantifierRules.other\r\n\t}\r\n\r\n\t/**\r\n\t * Formats a number into a string.\r\n\t * Uses `Intl.NumberFormat` when available.\r\n\t * @param {number} number\r\n\t * @return {string}\r\n\t */\r\n\tformatNumber(number) {\r\n\t\treturn this.numberFormat ? this.numberFormat.format(number) : String(number)\r\n\t}\r\n\r\n\t/**\r\n\t * Returns an `Intl.RelativeTimeFormat` for a given `labelsType`.\r\n\t * @param {string} labelsType\r\n\t * @return {object} `Intl.RelativeTimeFormat` instance\r\n\t */\r\n\tgetFormatter(labelsType) {\r\n\t\t// `Intl.RelativeTimeFormat` instance creation is (hypothetically) assumed\r\n\t\t// a lengthy operation so the instances are cached and reused.\r\n\t\treturn this.relativeTimeFormatCache.get(this.locale, labelsType) ||\r\n\t\t\tthis.relativeTimeFormatCache.put(this.locale, labelsType, new this.IntlRelativeTimeFormat(this.locale, { style: labelsType }))\r\n\t}\r\n\r\n\t/**\r\n\t * Returns an `Intl.PluralRules` instance.\r\n\t * @return {object} `Intl.PluralRules` instance\r\n\t */\r\n\tgetPluralRules() {\r\n\t\t// `Intl.PluralRules` instance creation is (hypothetically) assumed\r\n\t\t// a lengthy operation so the instances are cached and reused.\r\n\t\treturn this.pluralRulesCache.get(this.locale) ||\r\n\t\t\tthis.pluralRulesCache.put(this.locale, new this.IntlPluralRules(this.locale))\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Gets localized labels for this type of labels.\r\n\t *\r\n\t * @param {(string|string[])} labelsType - Relative date/time labels type.\r\n\t * If it's an array then all label types are tried\r\n\t * until a suitable one is found.\r\n\t *\r\n\t * @returns {Object} Returns an object of shape { labelsType, labels }\r\n\t */\r\n\tgetLabels(labelsType = []) {\r\n\t\t// Convert `labels` to an array.\r\n\t\tif (typeof labelsType === 'string') {\r\n\t\t\tlabelsType = [labelsType]\r\n\t\t}\r\n\r\n\t\t// Supports legacy \"tiny\" and \"mini-time\" label styles.\r\n\t\tlabelsType = labelsType.map((labelsType) => {\r\n\t\t\tswitch (labelsType) {\r\n\t\t\t\tcase 'tiny':\r\n\t\t\t\tcase 'mini-time':\r\n\t\t\t\t\treturn 'mini'\r\n\t\t\t\tdefault:\r\n\t\t\t\t\treturn labelsType\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\t// \"long\" labels type is the default one.\r\n\t\t// (it's always present for all languages)\r\n\t\tlabelsType = labelsType.concat('long')\r\n\r\n\t\t// Find a suitable labels type.\r\n\t\tconst localeData = getLocaleData(this.locale)\r\n\t\tfor (const _labelsType of labelsType) {\r\n\t\t\tif (localeData[_labelsType]) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\tlabelsType: _labelsType,\r\n\t\t\t\t\tlabels: localeData[_labelsType]\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}\r\n\r\n/**\r\n * Default locale global variable.\r\n */\r\nlet defaultLocale = 'en'\r\n\r\n/**\r\n * Gets default locale.\r\n * @return {string} locale\r\n */\r\nTimeAgo.getDefaultLocale = () => defaultLocale\r\n\r\n/**\r\n * Sets default locale.\r\n * @param {string} locale\r\n */\r\nTimeAgo.setDefaultLocale = (locale) => defaultLocale = locale\r\n\r\n/**\r\n * Adds locale data for a specific locale and marks the locale as default.\r\n * @param {Object} localeData\r\n */\r\nTimeAgo.addDefaultLocale = function(localeData) {\r\n\tif (defaultLocaleHasBeenSpecified) {\r\n\t\treturn console.error('[javascript-time-ago] `TimeAgo.addDefaultLocale()` can only be called once. To add other locales, use `TimeAgo.addLocale()`.')\r\n\t}\r\n\tdefaultLocaleHasBeenSpecified = true\r\n\tTimeAgo.setDefaultLocale(localeData.locale)\r\n\tTimeAgo.addLocale(localeData)\r\n}\r\n\r\nlet defaultLocaleHasBeenSpecified\r\n\r\n/**\r\n * Adds locale data for a specific locale.\r\n * @param {Object} localeData\r\n */\r\nTimeAgo.addLocale = function(localeData) {\r\n\taddLocaleData(localeData)\r\n\tRelativeTimeFormatPolyfill.addLocale(localeData)\r\n}\r\n\r\n/**\r\n * (legacy alias)\r\n * Adds locale data for a specific locale.\r\n * @param {Object} localeData\r\n * @deprecated\r\n */\r\nTimeAgo.locale = TimeAgo.addLocale\r\n\r\n/**\r\n * Adds custom labels to locale data.\r\n * @param {string} locale\r\n * @param {string} name\r\n * @param {object} labels\r\n */\r\nTimeAgo.addLabels = (locale, name, labels) => {\r\n\tlet localeData = getLocaleData(locale)\r\n\tif (!localeData) {\r\n\t\taddLocaleData({\r\n\t\t\tlocale\r\n\t\t})\r\n\t\tlocaleData = getLocaleData(locale)\r\n\t\t// throw new Error(`[javascript-time-ago] No data for locale \"${locale}\"`)\r\n\t}\r\n\tlocaleData[name] = labels\r\n}\r\n\r\n// Normalizes `.format()` `time` argument.\r\nfunction getTimestamp(input) {\r\n\tif (input.constructor === Date || isMockedDate(input)) {\r\n\t\treturn input.getTime()\r\n\t}\r\n\r\n\tif (typeof input === 'number') {\r\n\t\treturn input\r\n\t}\r\n\r\n\t// For some weird reason istanbul doesn't see this `throw` covered.\r\n\t/* istanbul ignore next */\r\n\tthrow new Error(`Unsupported relative time formatter input: ${typeof input}, ${input}`)\r\n}\r\n\r\n// During testing via some testing libraries `Date`s aren't actually `Date`s.\r\n// https://github.com/catamphetamine/javascript-time-ago/issues/22\r\nfunction isMockedDate(object) {\r\n\treturn typeof object === 'object' && typeof object.getTime === 'function'\r\n}\r\n\r\n// Get available time interval measurement units.\r\nfunction getTimeIntervalMeasurementUnits(allowedUnits, labels, nowLabel) {\r\n\t// Get all time interval measurement units that're available\r\n\t// in locale data for a given time labels style.\r\n\tlet units = Object.keys(labels)\r\n\r\n\t// `now` unit is handled separately and is shipped in its own `now.json` file.\r\n\t// `now.json` isn't present for all locales, so it could be substituted with\r\n\t// \".second.current\".\r\n\t// Add `now` unit if it's available in locale data.\r\n\tif (nowLabel) {\r\n\t\tunits.push('now')\r\n\t}\r\n\r\n\t// If only a specific set of available time measurement units can be used\r\n\t// then only those units are allowed (if they're present in locale data).\r\n\tif (allowedUnits) {\r\n\t\tunits = allowedUnits.filter(unit => unit === 'now' || units.indexOf(unit) >= 0)\r\n\t}\r\n\r\n\treturn units\r\n}\r\n\r\nfunction getNowLabel(labels, nowLabels, longLabels, future) {\r\n\tconst nowLabel = labels.now || (nowLabels && nowLabels.now)\r\n\t// Specific \"now\" message form extended locale data (if present).\r\n\tif (nowLabel) {\r\n\t\t// Bundle size optimization technique.\r\n\t\tif (typeof nowLabel === 'string') {\r\n\t\t\treturn nowLabel\r\n\t\t}\r\n\t\t// Not handling `value === 0` as `localeData.now.current` here\r\n\t\t// because it wouldn't make sense: \"now\" is a moment,\r\n\t\t// so one can't possibly differentiate between a\r\n\t\t// \"previous\" moment, a \"current\" moment and a \"next moment\".\r\n\t\t// It can only be differentiated between \"past\" and \"future\".\r\n\t\tif (future) {\r\n\t\t\treturn nowLabel.future\r\n\t\t} else {\r\n\t\t\treturn nowLabel.past\r\n\t\t}\r\n\t}\r\n\t// Use \".second.current\" as \"now\" message.\r\n\tif (longLabels && longLabels.second && longLabels.second.current) {\r\n\t\treturn longLabels.second.current\r\n\t}\r\n}\r\n\r\nfunction isStyle(variable) {\r\n\treturn typeof variable === 'string' || isStyleObject(variable)\r\n}"],"file":"TimeAgo.js"}
|
|
1
|
+
{"version":3,"file":"TimeAgo.js","names":["UNITS","TimeAgo","locales","polyfill","locale","chooseLocale","concat","getDefaultLocale","getLocaleData","Intl","NumberFormat","numberFormat","IntlRelativeTimeFormat","RelativeTimeFormat","IntlPluralRules","PluralRules","RelativeTimeFormatPolyfill","relativeTimeFormatCache","Cache","pluralRulesCache","input","style","options","isStyle","undefined","defaultStyle","getStyleByName","timestamp","getTimestamp","getLabels","flavour","labels","labelsType","now","Date","secondsPassed","future","nowLabel","getNowLabel","custom","date","time","elapsed","units","getTimeIntervalMeasurementUnits","round","getStep","gradation","steps","getNextStep","prevStep","step","nextStep","formattedDate","formatDateForStep","getTimeToNextUpdate","timeToNextUpdate","format","formatAs","unit","value","formatValue","Error","JSON","stringify","amount","Math","abs","getStepDenominator","granularity","getRoundFunction","valueForFormatting","sign","getFormatter","getFormattingRule","replace","formatNumber","formattingRules","pastOrFuture","quantifierRules","quantifier","getPluralRules","select","other","number","String","get","put","map","localeData","_labelsType","defaultLocale","setDefaultLocale","addDefaultLocale","defaultLocaleHasBeenSpecified","console","error","addLocale","addLocaleData","addLabels","name","constructor","isMockedDate","getTime","object","allowedUnits","Object","keys","push","filter","indexOf","nowLabels","longLabels","past","second","current","variable","isStyleObject"],"sources":["../source/TimeAgo.js"],"sourcesContent":["import RelativeTimeFormatPolyfill from 'relative-time-format'\r\n\r\nimport Cache from './cache.js'\r\nimport chooseLocale from './locale.js'\r\nimport isStyleObject from './isStyleObject.js'\r\n\r\nimport getStep from './steps/getStep.js'\r\nimport getStepDenominator from './steps/getStepDenominator.js'\r\nimport getTimeToNextUpdate from './steps/getTimeToNextUpdate.js'\r\n\r\nimport {\r\n\taddLocaleData,\r\n\tgetLocaleData\r\n} from './LocaleDataStore.js'\r\n\r\nimport defaultStyle from './style/roundMinute.js'\r\nimport getStyleByName from './style/getStyleByName.js'\r\n\r\nimport { getRoundFunction } from './round.js'\r\n\r\n// Valid time units.\r\nconst UNITS = [\r\n\t'now',\r\n\t// The rest are the same as in `Intl.RelativeTimeFormat`.\r\n\t'second',\r\n\t'minute',\r\n\t'hour',\r\n\t'day',\r\n\t'week',\r\n\t'month',\r\n\t'quarter',\r\n\t'year'\r\n]\r\n\r\nexport default class TimeAgo {\r\n\t/**\r\n\t * @param {(string|string[])} locales=[] - Preferred locales (or locale).\r\n\t * @param {boolean} [polyfill] — Pass `false` to use native `Intl.RelativeTimeFormat` and `Intl.PluralRules` instead of the polyfills.\r\n\t */\r\n\tconstructor(locales = [], { polyfill } = {}) {\r\n\t\t// Convert `locales` to an array.\r\n\t\tif (typeof locales === 'string') {\r\n\t\t\tlocales = [locales]\r\n\t\t}\r\n\r\n\t\t// Choose the most appropriate locale\r\n\t\t// from the list of `locales` added by the user.\r\n\t\t// For example, new TimeAgo(\"en-US\") -> \"en\".\r\n\t\tthis.locale = chooseLocale(\r\n\t\t\tlocales.concat(TimeAgo.getDefaultLocale()),\r\n\t\t\tgetLocaleData\r\n\t\t)\r\n\r\n\t\tif (typeof Intl !== 'undefined') {\r\n\t\t\t// Use `Intl.NumberFormat` for formatting numbers (when available).\r\n\t\t\tif (Intl.NumberFormat) {\r\n\t\t\t\tthis.numberFormat = new Intl.NumberFormat(this.locale)\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Some people have requested the ability to use native\r\n\t\t// `Intl.RelativeTimeFormat` and `Intl.PluralRules`\r\n\t\t// instead of the polyfills.\r\n\t\t// https://github.com/catamphetamine/javascript-time-ago/issues/21\r\n\t\tif (polyfill === false) {\r\n\t\t\tthis.IntlRelativeTimeFormat = Intl.RelativeTimeFormat\r\n\t\t\tthis.IntlPluralRules = Intl.PluralRules\r\n\t\t} else {\r\n\t\t\tthis.IntlRelativeTimeFormat = RelativeTimeFormatPolyfill\r\n\t\t\tthis.IntlPluralRules = RelativeTimeFormatPolyfill.PluralRules\r\n\t\t}\r\n\r\n\t\t// Cache `Intl.RelativeTimeFormat` instance.\r\n\t\tthis.relativeTimeFormatCache = new Cache()\r\n\r\n\t\t// Cache `Intl.PluralRules` instance.\r\n\t\tthis.pluralRulesCache = new Cache()\r\n\t}\r\n\r\n\t/**\r\n\t * Formats relative date/time.\r\n\t *\r\n\t * @param {number} [options.now] - Sets the current date timestamp.\r\n\t *\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`:\r\n\t * as \"future\" (`true`) or \"past\" (`false`).\r\n\t * Is `false` by default, but should have been `true` actually,\r\n\t * in order to correspond to `Intl.RelativeTimeFormat`\r\n\t * that uses `future` formatting for `0` unless `-0` is passed.\r\n\t *\r\n\t * @param {string} [options.round] — Rounding method. Overrides the style's one.\r\n\t *\r\n\t * @param {boolean} [options.getTimeToNextUpdate] — Pass `true` to return `[formattedDate, timeToNextUpdate]` instead of just `formattedDate`.\r\n\t *\r\n\t * @return {string} The formatted relative date/time. If no eligible `step` is found, then an empty string is returned.\r\n\t */\r\n\tformat(input, style, options) {\r\n\t\tif (!options) {\r\n\t\t\tif (style && !isStyle(style)) {\r\n\t\t\t\toptions = style\r\n\t\t\t\tstyle = undefined\r\n\t\t\t} else {\r\n\t\t\t\toptions = {}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif (!style) {\r\n\t\t\tstyle = defaultStyle\r\n\t\t}\r\n\r\n\t\tif (typeof style === 'string') {\r\n\t\t\tstyle = getStyleByName(style)\r\n\t\t}\r\n\r\n\t\tconst timestamp = getTimestamp(input)\r\n\r\n\t\t// Get locale messages for this type of labels.\r\n\t\t// \"flavour\" is a legacy name for \"labels\".\r\n\t\tconst { labels, labelsType } = this.getLabels(style.flavour || style.labels)\r\n\r\n\t\tlet now\r\n\t\t// Can pass a custom `now`, e.g. for testing purposes.\r\n\t\t//\r\n\t\t// Legacy way was passing `now` in `style`.\r\n\t\t// That way is deprecated.\r\n\t\tif (style.now !== undefined) {\r\n\t\t\tnow = style.now\r\n\t\t}\r\n\t\t// The new way is passing `now` option to `.format()`.\r\n\t\tif (now === undefined && options.now !== undefined) {\r\n\t\t\tnow = options.now\r\n\t\t}\r\n\t\tif (now === undefined) {\r\n\t\t\tnow = Date.now()\r\n\t\t}\r\n\r\n\t\t// how much time has passed (in seconds)\r\n\t\tconst secondsPassed = (now - timestamp) / 1000 // in seconds\r\n\r\n\t\tconst future = options.future || secondsPassed < 0\r\n\r\n\t\tconst nowLabel = getNowLabel(\r\n\t\t\tlabels,\r\n\t\t\tgetLocaleData(this.locale).now,\r\n\t\t\tgetLocaleData(this.locale).long,\r\n\t\t\tfuture\r\n\t\t)\r\n\r\n\t\t// `custom` – A function of `{ elapsed, time, date, now, locale }`.\r\n\t\t//\r\n\t\t// Looks like `custom` function is deprecated and will be removed\r\n\t\t// in the next major version.\r\n\t\t//\r\n\t\t// If this function returns a value, then the `.format()` call will return that value.\r\n\t\t// Otherwise the relative date/time is formatted as usual.\r\n\t\t// This feature is currently not used anywhere and is here\r\n\t\t// just for providing the ultimate customization point\r\n\t\t// in case anyone would ever need that. Prefer using\r\n\t\t// `steps[step].format(value, locale)` instead.\r\n\t\t//\r\n\t\tif (style.custom) {\r\n\t\t\tconst custom = style.custom({\r\n\t\t\t\tnow,\r\n\t\t\t\tdate: new Date(timestamp),\r\n\t\t\t\ttime: timestamp,\r\n\t\t\t\telapsed: secondsPassed,\r\n\t\t\t\tlocale: this.locale\r\n\t\t\t})\r\n\t\t\tif (custom !== undefined) {\r\n\t\t\t\t// Won't return `timeToNextUpdate` here\r\n\t\t\t\t// because `custom()` seems deprecated.\r\n\t\t\t\treturn custom\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// Get the list of available time interval units.\r\n\t\tconst units = getTimeIntervalMeasurementUnits(\r\n\t\t\t// Controlling `style.steps` through `style.units` seems to be deprecated:\r\n\t\t\t// create a new custom `style` instead.\r\n\t\t\tstyle.units,\r\n\t\t\tlabels,\r\n\t\t\tnowLabel\r\n\t\t)\r\n\r\n\t\t// // If no available time unit is suitable, just output an empty string.\r\n\t\t// if (units.length === 0) {\r\n\t\t// \tconsole.error(`None of the \"${units.join(', ')}\" time units have been found in \"${labelsType}\" labels for \"${this.locale}\" locale.`)\r\n\t\t// \treturn ''\r\n\t\t// }\r\n\r\n\t\tconst round = options.round || style.round\r\n\r\n\t\t// Choose the appropriate time measurement unit\r\n\t\t// and get the corresponding rounded time amount.\r\n\t\tconst [prevStep, step, nextStep] = getStep(\r\n\t\t\t// \"gradation\" is a legacy name for \"steps\".\r\n\t\t\t// For historical reasons, \"approximate\" steps are used by default.\r\n\t\t\t// In the next major version, there'll be no default for `steps`.\r\n\t\t\tstyle.gradation || style.steps || defaultStyle.steps,\r\n\t\t\tsecondsPassed,\r\n\t\t\t{ now, units, round, future, getNextStep: true }\r\n\t\t)\r\n\r\n\t\tconst formattedDate = this.formatDateForStep(timestamp, step, secondsPassed, {\r\n\t\t\tlabels,\r\n\t\t\tlabelsType,\r\n\t\t\tnowLabel,\r\n\t\t\tnow,\r\n\t\t\tfuture,\r\n\t\t\tround\r\n\t\t}) || ''\r\n\r\n\t\tif (options.getTimeToNextUpdate) {\r\n\t\t\tconst timeToNextUpdate = getTimeToNextUpdate(timestamp, step, {\r\n\t\t\t\tnextStep,\r\n\t\t\t\tprevStep,\r\n\t\t\t\tnow,\r\n\t\t\t\tfuture,\r\n\t\t\t\tround\r\n\t\t\t})\r\n\t\t\treturn [formattedDate, timeToNextUpdate]\r\n\t\t}\r\n\r\n\t\treturn formattedDate\r\n\t}\r\n\r\n\tformatDateForStep(timestamp, step, secondsPassed, {\r\n\t\tlabels,\r\n\t\tlabelsType,\r\n\t\tnowLabel,\r\n\t\tnow,\r\n\t\tfuture,\r\n\t\tround\r\n\t}) {\r\n\t\t// If no step matches, then output an empty string.\r\n\t\tif (!step) {\r\n\t\t\treturn\r\n\t\t}\r\n\r\n\t\tif (step.format) {\r\n\t\t\treturn step.format(timestamp, this.locale, {\r\n\t\t\t\tformatAs: (unit, value) => {\r\n\t\t\t\t\t// Mimicks `Intl.RelativeTimeFormat.format()`.\r\n\t\t\t\t\treturn this.formatValue(value, unit, {\r\n\t\t\t\t\t\tlabels,\r\n\t\t\t\t\t\tfuture\r\n\t\t\t\t\t})\r\n\t\t\t\t},\r\n\t\t\t\tnow,\r\n\t\t\t\tfuture\r\n\t\t\t})\r\n\t\t}\r\n\r\n\t\t// \"unit\" is now called \"formatAs\".\r\n\t\tconst unit = step.unit || step.formatAs\r\n\r\n\t\tif (!unit) {\r\n\t\t\tthrow new Error(`[javascript-time-ago] Each step must define either \\`formatAs\\` or \\`format()\\`. Step: ${JSON.stringify(step)}`)\r\n\t\t}\r\n\r\n\t\t// `Intl.RelativeTimeFormat` doesn't operate in \"now\" units.\r\n\t\t// Therefore, threat \"now\" as a special case.\r\n\t\tif (unit === 'now') {\r\n\t\t\treturn nowLabel\r\n\t\t}\r\n\r\n\t\t// Amount in units.\r\n\t\tlet amount = Math.abs(secondsPassed) / getStepDenominator(step)\r\n\r\n\t\t// Apply granularity to the time amount\r\n\t\t// (and fallback to the previous step\r\n\t\t// if the first level of granularity\r\n\t\t// isn't met by this amount)\r\n\t\t//\r\n\t\t// `granularity` — (advanced) Time interval value \"granularity\".\r\n\t\t// For example, it could be set to `5` for minutes to allow only 5-minute increments\r\n\t\t// when formatting time intervals: `0 minutes`, `5 minutes`, `10 minutes`, etc.\r\n\t\t// Perhaps this feature will be removed because there seem to be no use cases\r\n\t\t// of it in the real world.\r\n\t\t//\r\n\t\tif (step.granularity) {\r\n\t\t\t// Recalculate the amount of seconds passed based on granularity\r\n\t\t\tamount = getRoundFunction(round)(amount / step.granularity) * step.granularity\r\n\t\t}\r\n\r\n\t\tlet valueForFormatting = -1 * Math.sign(secondsPassed) * getRoundFunction(round)(amount)\r\n\r\n\t\t// By default, this library formats a `0` in \"past\" mode,\r\n\t\t// unless `future: true` option is passed.\r\n\t\t// This is different to `relative-time-format`'s behavior\r\n\t\t// which formats a `0` in \"future\" mode by default, unless it's a `-0`.\r\n\t\t// So, convert `0` to `-0` if `future: true` option wasn't passed.\r\n\t\t// `=== 0` matches both `0` and `-0`.\r\n\t\tif (valueForFormatting === 0) {\r\n\t\t\tif (future) {\r\n\t\t\t\tvalueForFormatting = 0\r\n\t\t\t} else {\r\n\t\t\t\tvalueForFormatting = -0\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tswitch (labelsType) {\r\n\t\t\tcase 'long':\r\n\t\t\tcase 'short':\r\n\t\t\tcase 'narrow':\r\n\t\t\t\t// Format the amount using `Intl.RelativeTimeFormat`.\r\n\t\t\t\treturn this.getFormatter(labelsType).format(valueForFormatting, unit)\r\n\t\t\tdefault:\r\n\t\t\t\t// Format the amount.\r\n\t\t\t\t// (mimicks `Intl.RelativeTimeFormat` behavior for other time label styles)\r\n\t\t\t\treturn this.formatValue(valueForFormatting, unit, {\r\n\t\t\t\t\tlabels,\r\n\t\t\t\t\tfuture\r\n\t\t\t\t})\r\n\t\t}\r\n\t}\r\n\r\n\t/**\r\n\t * Mimicks what `Intl.RelativeTimeFormat` does for additional locale styles.\r\n\t * @param {number} value\r\n\t * @param {string} unit\r\n\t * @param {object} options.labels — Relative time labels.\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`: as \"future\" (`true`) or \"past\" (`false`). Is `false` by default, but should have been `true` actually.\r\n\t * @return {string}\r\n\t */\r\n\tformatValue(value, unit, { labels, future }) {\r\n\t\treturn this.getFormattingRule(labels, unit, value, { future })\r\n\t\t\t.replace('{0}', this.formatNumber(Math.abs(value)))\r\n\t}\r\n\r\n\t/**\r\n\t * Returns formatting rule for `value` in `units` (either in past or in future).\r\n\t * @param {object} formattingRules — Relative time labels for different units.\r\n\t * @param {string} unit - Time interval measurement unit.\r\n\t * @param {number} value - Time interval value.\r\n\t * @param {boolean} [options.future] — Tells how to format value `0`: as \"future\" (`true`) or \"past\" (`false`). Is `false` by default.\r\n\t * @return {string}\r\n\t * @example\r\n\t * // Returns \"{0} days ago\"\r\n\t * getFormattingRule(en.long, \"day\", -2, 'en')\r\n\t */\r\n\tgetFormattingRule(formattingRules, unit, value, { future }) {\r\n\t\t// Passing the language is required in order to\r\n\t\t// be able to correctly classify the `value` as a number.\r\n\t\tconst locale = this.locale\r\n\t\tformattingRules = formattingRules[unit]\r\n\t\t// Check for a special \"compacted\" rules case:\r\n\t\t// if formatting rules are the same for \"past\" and \"future\",\r\n\t\t// and also for all possible `value`s, then those rules are\r\n\t\t// stored as a single string.\r\n\t\tif (typeof formattingRules === 'string') {\r\n\t\t\treturn formattingRules\r\n\t\t}\r\n\t\t// Choose either \"past\" or \"future\" based on time `value` sign.\r\n\t\t// If \"past\" is same as \"future\" then they're stored as \"other\".\r\n\t\t// If there's only \"other\" then it's being collapsed.\r\n\t\tconst pastOrFuture = value === 0 ? (future ? 'future' : 'past') : (value < 0 ? 'past' : 'future')\r\n\t\tconst quantifierRules = formattingRules[pastOrFuture] || formattingRules\r\n\t\t// Bundle size optimization technique.\r\n\t\tif (typeof quantifierRules === 'string') {\r\n\t\t\treturn quantifierRules\r\n\t\t}\r\n\t\t// Quantify `value`.\r\n\t\tconst quantifier = this.getPluralRules().select(Math.abs(value))\r\n\t\t// \"other\" rule is supposed to always be present.\r\n\t\t// If only \"other\" rule is present then \"rules\" is not an object and is a string.\r\n\t\treturn quantifierRules[quantifier] || quantifierRules.other\r\n\t}\r\n\r\n\t/**\r\n\t * Formats a number into a string.\r\n\t * Uses `Intl.NumberFormat` when available.\r\n\t * @param {number} number\r\n\t * @return {string}\r\n\t */\r\n\tformatNumber(number) {\r\n\t\treturn this.numberFormat ? this.numberFormat.format(number) : String(number)\r\n\t}\r\n\r\n\t/**\r\n\t * Returns an `Intl.RelativeTimeFormat` for a given `labelsType`.\r\n\t * @param {string} labelsType\r\n\t * @return {object} `Intl.RelativeTimeFormat` instance\r\n\t */\r\n\tgetFormatter(labelsType) {\r\n\t\t// `Intl.RelativeTimeFormat` instance creation is (hypothetically) assumed\r\n\t\t// a lengthy operation so the instances are cached and reused.\r\n\t\treturn this.relativeTimeFormatCache.get(this.locale, labelsType) ||\r\n\t\t\tthis.relativeTimeFormatCache.put(this.locale, labelsType, new this.IntlRelativeTimeFormat(this.locale, { style: labelsType }))\r\n\t}\r\n\r\n\t/**\r\n\t * Returns an `Intl.PluralRules` instance.\r\n\t * @return {object} `Intl.PluralRules` instance\r\n\t */\r\n\tgetPluralRules() {\r\n\t\t// `Intl.PluralRules` instance creation is (hypothetically) assumed\r\n\t\t// a lengthy operation so the instances are cached and reused.\r\n\t\treturn this.pluralRulesCache.get(this.locale) ||\r\n\t\t\tthis.pluralRulesCache.put(this.locale, new this.IntlPluralRules(this.locale))\r\n\t}\r\n\r\n\r\n\t/**\r\n\t * Gets localized labels for this type of labels.\r\n\t *\r\n\t * @param {(string|string[])} labelsType - Relative date/time labels type.\r\n\t * If it's an array then all label types are tried\r\n\t * until a suitable one is found.\r\n\t *\r\n\t * @returns {Object} Returns an object of shape { labelsType, labels }\r\n\t */\r\n\tgetLabels(labelsType = []) {\r\n\t\t// Convert `labels` to an array.\r\n\t\tif (typeof labelsType === 'string') {\r\n\t\t\tlabelsType = [labelsType]\r\n\t\t}\r\n\r\n\t\t// Supports legacy \"tiny\" and \"mini-time\" label styles.\r\n\t\tlabelsType = labelsType.map((labelsType) => {\r\n\t\t\tswitch (labelsType) {\r\n\t\t\t\tcase 'tiny':\r\n\t\t\t\tcase 'mini-time':\r\n\t\t\t\t\treturn 'mini'\r\n\t\t\t\tdefault:\r\n\t\t\t\t\treturn labelsType\r\n\t\t\t}\r\n\t\t})\r\n\r\n\t\t// \"long\" labels type is the default one.\r\n\t\t// (it's always present for all languages)\r\n\t\tlabelsType = labelsType.concat('long')\r\n\r\n\t\t// Find a suitable labels type.\r\n\t\tconst localeData = getLocaleData(this.locale)\r\n\t\tfor (const _labelsType of labelsType) {\r\n\t\t\tif (localeData[_labelsType]) {\r\n\t\t\t\treturn {\r\n\t\t\t\t\tlabelsType: _labelsType,\r\n\t\t\t\t\tlabels: localeData[_labelsType]\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}\r\n\r\n/**\r\n * Default locale global variable.\r\n */\r\nlet defaultLocale = 'en'\r\n\r\n/**\r\n * Gets default locale.\r\n * @return {string} locale\r\n */\r\nTimeAgo.getDefaultLocale = () => defaultLocale\r\n\r\n/**\r\n * Sets default locale.\r\n * @param {string} locale\r\n */\r\nTimeAgo.setDefaultLocale = (locale) => defaultLocale = locale\r\n\r\n/**\r\n * Adds locale data for a specific locale and marks the locale as default.\r\n * @param {Object} localeData\r\n */\r\nTimeAgo.addDefaultLocale = function(localeData) {\r\n\tif (defaultLocaleHasBeenSpecified) {\r\n\t\treturn console.error('[javascript-time-ago] `TimeAgo.addDefaultLocale()` can only be called once. To add other locales, use `TimeAgo.addLocale()`.')\r\n\t}\r\n\tdefaultLocaleHasBeenSpecified = true\r\n\tTimeAgo.setDefaultLocale(localeData.locale)\r\n\tTimeAgo.addLocale(localeData)\r\n}\r\n\r\nlet defaultLocaleHasBeenSpecified\r\n\r\n/**\r\n * Adds locale data for a specific locale.\r\n * @param {Object} localeData\r\n */\r\nTimeAgo.addLocale = function(localeData) {\r\n\taddLocaleData(localeData)\r\n\tRelativeTimeFormatPolyfill.addLocale(localeData)\r\n}\r\n\r\n/**\r\n * (legacy alias)\r\n * Adds locale data for a specific locale.\r\n * @param {Object} localeData\r\n * @deprecated\r\n */\r\nTimeAgo.locale = TimeAgo.addLocale\r\n\r\n/**\r\n * Adds custom labels to locale data.\r\n * @param {string} locale\r\n * @param {string} name\r\n * @param {object} labels\r\n */\r\nTimeAgo.addLabels = (locale, name, labels) => {\r\n\tlet localeData = getLocaleData(locale)\r\n\tif (!localeData) {\r\n\t\taddLocaleData({\r\n\t\t\tlocale\r\n\t\t})\r\n\t\tlocaleData = getLocaleData(locale)\r\n\t\t// throw new Error(`[javascript-time-ago] No data for locale \"${locale}\"`)\r\n\t}\r\n\tlocaleData[name] = labels\r\n}\r\n\r\n// Normalizes `.format()` `time` argument.\r\nfunction getTimestamp(input) {\r\n\tif (input.constructor === Date || isMockedDate(input)) {\r\n\t\treturn input.getTime()\r\n\t}\r\n\r\n\tif (typeof input === 'number') {\r\n\t\treturn input\r\n\t}\r\n\r\n\t// For some weird reason istanbul doesn't see this `throw` covered.\r\n\t/* istanbul ignore next */\r\n\tthrow new Error(`Unsupported relative time formatter input: ${typeof input}, ${input}`)\r\n}\r\n\r\n// During testing via some testing libraries `Date`s aren't actually `Date`s.\r\n// https://github.com/catamphetamine/javascript-time-ago/issues/22\r\nfunction isMockedDate(object) {\r\n\treturn typeof object === 'object' && typeof object.getTime === 'function'\r\n}\r\n\r\n// Get available time interval measurement units.\r\nfunction getTimeIntervalMeasurementUnits(allowedUnits, labels, nowLabel) {\r\n\t// Get all time interval measurement units that're available\r\n\t// in locale data for a given time labels style.\r\n\tlet units = Object.keys(labels)\r\n\r\n\t// `now` unit is handled separately and is shipped in its own `now.json` file.\r\n\t// `now.json` isn't present for all locales, so it could be substituted with\r\n\t// \".second.current\".\r\n\t// Add `now` unit if it's available in locale data.\r\n\tif (nowLabel) {\r\n\t\tunits.push('now')\r\n\t}\r\n\r\n\t// If only a specific set of available time measurement units can be used\r\n\t// then only those units are allowed (if they're present in locale data).\r\n\tif (allowedUnits) {\r\n\t\tunits = allowedUnits.filter(unit => unit === 'now' || units.indexOf(unit) >= 0)\r\n\t}\r\n\r\n\treturn units\r\n}\r\n\r\nfunction getNowLabel(labels, nowLabels, longLabels, future) {\r\n\tconst nowLabel = labels.now || (nowLabels && nowLabels.now)\r\n\t// Specific \"now\" message form extended locale data (if present).\r\n\tif (nowLabel) {\r\n\t\t// Bundle size optimization technique.\r\n\t\tif (typeof nowLabel === 'string') {\r\n\t\t\treturn nowLabel\r\n\t\t}\r\n\t\t// Not handling `value === 0` as `localeData.now.current` here\r\n\t\t// because it wouldn't make sense: \"now\" is a moment,\r\n\t\t// so one can't possibly differentiate between a\r\n\t\t// \"previous\" moment, a \"current\" moment and a \"next moment\".\r\n\t\t// It can only be differentiated between \"past\" and \"future\".\r\n\t\tif (future) {\r\n\t\t\treturn nowLabel.future\r\n\t\t} else {\r\n\t\t\treturn nowLabel.past\r\n\t\t}\r\n\t}\r\n\t// Use \".second.current\" as \"now\" message.\r\n\tif (longLabels && longLabels.second && longLabels.second.current) {\r\n\t\treturn longLabels.second.current\r\n\t}\r\n}\r\n\r\nfunction isStyle(variable) {\r\n\treturn typeof variable === 'string' || isStyleObject(variable)\r\n}"],"mappings":";;;;;;;AAAA;;AAEA;;AACA;;AACA;;AAEA;;AACA;;AACA;;AAEA;;AAKA;;AACA;;AAEA;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA;AACA,IAAMA,KAAK,GAAG,CACb,KADa,EAEb;AACA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