@checkdigit/time 3.0.0-PR.17-58cd → 3.0.0-PR.17-5aaf

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.
@@ -19,4 +19,4 @@ function buildLocalizeFn(args) {
19
19
  export {
20
20
  buildLocalizeFn as default
21
21
  };
22
- //# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vLi4vLi4vc3JjL2RhdGUtZm5zL2xvY2FsZS9fbGliL2J1aWxkTG9jYWxpemVGbi9pbmRleC50cyJdLAogICJtYXBwaW5ncyI6ICI7QUFxRWUsU0FBUixnQkFHTCxNQUFpRjtBQUNqRixTQUFPLENBQUMsWUFBWSxZQUFZO0FBQzlCLFVBQU0sVUFBVSxTQUFTLFVBQVUsT0FBTyxRQUFRLE9BQU8sSUFBSTtBQUU3RCxRQUFJO0FBQ0osUUFBSSxZQUFZLGdCQUFnQixLQUFLLGtCQUFrQjtBQUNyRCxZQUFNLGVBQWUsS0FBSywwQkFBMEIsS0FBSztBQUN6RCxZQUFNLFFBQVMsU0FBUyxRQUFRLE9BQU8sUUFBUSxLQUFLLElBQUk7QUFDeEQsb0JBQWUsS0FBSyxpQkFBaUIsS0FBSyxLQUFLLEtBQUssaUJBQWlCLFlBQVk7QUFBQSxJQUNuRixPQUFPO0FBQ0wsWUFBTSxlQUFlLEtBQUs7QUFDMUIsWUFBTSxRQUFTLFNBQVMsUUFBUSxPQUFPLFFBQVEsS0FBSyxJQUFJLEtBQUs7QUFDN0Qsb0JBQWUsS0FBSyxPQUFPLEtBQUssS0FBSyxLQUFLLE9BQU8sWUFBWTtBQUFBLElBQy9EO0FBQ0EsVUFBTSxRQUNKLEtBQUssbUJBQ0QsS0FBSyxpQkFBaUIsVUFBb0IsSUFDekM7QUFHUCxXQUFPLFlBQVksS0FBSztBQUFBLEVBQzFCO0FBQ0Y7IiwKICAibmFtZXMiOiBbXQp9Cg==
22
+ //# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vLi4vLi4vLi4vc3JjL2RhdGUtZm5zL2xvY2FsZS9fbGliL2J1aWxkTG9jYWxpemVGbi9pbmRleC50cyJdLAogICJtYXBwaW5ncyI6ICI7QUF1RWUsU0FBUixnQkFHTCxNQUFpRjtBQUNqRixTQUFPLENBQUMsWUFBWSxZQUFZO0FBQzlCLFVBQU0sVUFBVSxTQUFTLFVBQVUsT0FBTyxRQUFRLE9BQU8sSUFBSTtBQUU3RCxRQUFJO0FBQ0osUUFBSSxZQUFZLGdCQUFnQixLQUFLLGtCQUFrQjtBQUNyRCxZQUFNLGVBQWUsS0FBSywwQkFBMEIsS0FBSztBQUN6RCxZQUFNLFFBQVMsU0FBUyxRQUFRLE9BQU8sUUFBUSxLQUFLLElBQUk7QUFDeEQsb0JBQWUsS0FBSyxpQkFBaUIsS0FBSyxLQUFLLEtBQUssaUJBQWlCLFlBQVk7QUFBQSxJQUNuRixPQUFPO0FBQ0wsWUFBTSxlQUFlLEtBQUs7QUFDMUIsWUFBTSxRQUFTLFNBQVMsUUFBUSxPQUFPLFFBQVEsS0FBSyxJQUFJLEtBQUs7QUFDN0Qsb0JBQWUsS0FBSyxPQUFPLEtBQUssS0FBSyxLQUFLLE9BQU8sWUFBWTtBQUFBLElBQy9EO0FBQ0EsVUFBTSxRQUNKLEtBQUssbUJBQ0QsS0FBSyxpQkFBaUIsVUFBb0IsSUFDekM7QUFHUCxXQUFPLFlBQVksS0FBSztBQUFBLEVBQzFCO0FBQ0Y7IiwKICAibmFtZXMiOiBbXQp9Cg==
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"@checkdigit/time","version":"3.0.0-PR.17-58cd","description":"Standard time handling","author":"Check Digit, LLC","license":"MIT","bugs":{"url":"https://github.com/checkdigit/time/issues"},"homepage":"https://github.com/checkdigit/time#readme","repository":{"type":"git","url":"git+https://github.com/checkdigit/time.git"},"engines":{"node":">=20.11"},"type":"module","sideEffects":false,"exports":{".":{"types":"./dist-types/index.d.ts","import":"./dist-mjs/index.mjs","default":"./dist-mjs/index.mjs"}},"files":["src","dist-types","dist-mjs","!src/**/*.test.ts","!src/**/*.spec.ts","!dist-types/**/*.test.d.ts","!dist-types/**/*.spec.d.ts","!dist-mjs/**/*.test.mjs","!dist-mjs/**/*.spec.mjs","SECURITY.md"],"devDependencies":{"@checkdigit/eslint-config":"^9.2.0","@checkdigit/jest-config":"^6.0.0","@checkdigit/prettier-config":"^5.3.0","@checkdigit/typescript-config":"^7.0.0","@js-temporal/polyfill":"^0.4.4","rimraf":"^5.0.5"},"scripts":{"prepublishOnly":"npm run build:dist-types && npm run build:dist-mjs","build:dist-types":"rimraf dist-types && npx builder --type=types --outDir=dist-types","build:dist-mjs":"rimraf dist-mjs && npx builder --type=module --sourceMap --outDir=dist-mjs && node dist-mjs/index.mjs","lint":"eslint --max-warnings 0 --ignore-path .gitignore .","lint:fix":"eslint --ignore-path .gitignore . --fix","prettier":"prettier --ignore-path .gitignore --list-different .","prettier:fix":"prettier --ignore-path .gitignore --write .","test":"npm run ci:compile && npm run ci:test && npm run ci:lint && npm run ci:style","ci:compile":"tsc --noEmit","ci:test":"NODE_OPTIONS=\"--disable-warning ExperimentalWarning --experimental-vm-modules\" jest --coverage=false","ci:coverage":"NODE_OPTIONS=\"--disable-warning ExperimentalWarning --experimental-vm-modules\" jest --coverage=true","ci:lint":"npm run lint","ci:style":"npm run prettier"},"jest":{"preset":"@checkdigit/jest-config"},"eslintConfig":{"extends":["@checkdigit/eslint-config"],"ignorePatterns":["src/date-fns/**","src/date-fns-tz/**"]},"prettier":"@checkdigit/prettier-config"}
1
+ {"name":"@checkdigit/time","version":"3.0.0-PR.17-5aaf","description":"Standard time handling","author":"Check Digit, LLC","license":"MIT","bugs":{"url":"https://github.com/checkdigit/time/issues"},"homepage":"https://github.com/checkdigit/time#readme","repository":{"type":"git","url":"git+https://github.com/checkdigit/time.git"},"engines":{"node":">=20.11"},"type":"module","sideEffects":false,"exports":{".":{"types":"./dist-types/index.d.ts","import":"./dist-mjs/index.mjs","default":"./dist-mjs/index.mjs"}},"files":["src","dist-types","dist-mjs","!src/**/*.test.ts","!src/**/*.spec.ts","!dist-types/**/*.test.d.ts","!dist-types/**/*.spec.d.ts","!dist-mjs/**/*.test.mjs","!dist-mjs/**/*.spec.mjs","SECURITY.md"],"devDependencies":{"@checkdigit/eslint-config":"^9.2.0","@checkdigit/jest-config":"^6.0.0","@checkdigit/prettier-config":"^5.3.0","@checkdigit/typescript-config":"^7.0.0","@js-temporal/polyfill":"^0.4.4","rimraf":"^5.0.5"},"scripts":{"prepublishOnly":"npm run build:dist-types && npm run build:dist-mjs","build:dist-types":"rimraf dist-types && npx builder --type=types --outDir=dist-types","build:dist-mjs":"rimraf dist-mjs && npx builder --type=module --sourceMap --outDir=dist-mjs && node dist-mjs/index.mjs","lint":"eslint --max-warnings 0 --ignore-path .gitignore .","lint:fix":"eslint --ignore-path .gitignore . --fix","prettier":"prettier --ignore-path .gitignore --ignore-path .prettierignore --list-different .","prettier:fix":"prettier --ignore-path .gitignore --ignore-path .prettierignore --write .","test":"npm run ci:compile && npm run ci:test && npm run ci:lint && npm run ci:style","ci:compile":"tsc --noEmit","ci:test":"NODE_OPTIONS=\"--disable-warning ExperimentalWarning --experimental-vm-modules\" jest --coverage=false","ci:coverage":"NODE_OPTIONS=\"--disable-warning ExperimentalWarning --experimental-vm-modules\" jest --coverage=true","ci:lint":"npm run lint","ci:style":"npm run prettier"},"jest":{"preset":"@checkdigit/jest-config"},"eslintConfig":{"extends":["@checkdigit/eslint-config"],"ignorePatterns":["src/date-fns/**","src/date-fns-tz/**"]},"prettier":"@checkdigit/prettier-config"}
@@ -23,7 +23,7 @@ import type { IntlOptionsUnit } from '../types';
23
23
  */
24
24
  export interface IntlFormatDistanceOptions {
25
25
  unit?: IntlOptionsUnit;
26
- locale?: string; // original type is Intl.BCP47LanguageTag, changeed to string due to compilation error Namespace 'Intl' has no exported member 'BCP47LanguageTag'.;
26
+ locale?: string; // [TODO:} the original type is Intl.BCP47LanguageTag, it's changed to string due to compilation error (Namespace 'Intl' has no exported member 'BCP47LanguageTag'.). hopefully this workaround won't be necessary once https://github.com/checkdigit/time/issues/15 is addressed
27
27
  localeMatcher?: Intl.RelativeTimeFormatLocaleMatcher;
28
28
  numeric?: Intl.RelativeTimeFormatNumeric;
29
29
  style?: Intl.RelativeTimeFormatStyle;
@@ -22,30 +22,32 @@ type LocalizeMonthValues = readonly [
22
22
  string,
23
23
  ];
24
24
 
25
- export type LocalizeUnitValuesIndex<Values extends LocalizeUnitValues<any>> =
26
- Values extends Record<LocaleDayPeriod, string>
27
- ? string
28
- : Values extends LocalizeEraValues
29
- ? Era
30
- : Values extends LocalizeQuarterValues
31
- ? Quarter
32
- : Values extends LocalizeDayValues
33
- ? Day
34
- : Values extends LocalizeMonthValues
35
- ? Month
36
- : never;
25
+ export type LocalizeUnitValuesIndex<Values extends LocalizeUnitValues<any>> = Values extends Record<
26
+ LocaleDayPeriod,
27
+ string
28
+ >
29
+ ? string
30
+ : Values extends LocalizeEraValues
31
+ ? Era
32
+ : Values extends LocalizeQuarterValues
33
+ ? Quarter
34
+ : Values extends LocalizeDayValues
35
+ ? Day
36
+ : Values extends LocalizeMonthValues
37
+ ? Month
38
+ : never;
37
39
 
38
40
  export type LocalizeUnitValues<Unit extends LocaleUnit> = Unit extends LocaleDayPeriod
39
41
  ? Record<LocaleDayPeriod, string>
40
42
  : Unit extends Era
41
- ? LocalizeEraValues
42
- : Unit extends Quarter
43
- ? LocalizeQuarterValues
44
- : Unit extends Day
45
- ? LocalizeDayValues
46
- : Unit extends Month
47
- ? LocalizeMonthValues
48
- : never;
43
+ ? LocalizeEraValues
44
+ : Unit extends Quarter
45
+ ? LocalizeQuarterValues
46
+ : Unit extends Day
47
+ ? LocalizeDayValues
48
+ : Unit extends Month
49
+ ? LocalizeMonthValues
50
+ : never;
49
51
 
50
52
  export type LocalizePeriodValuesMap<Unit extends LocaleUnit> = {
51
53
  [pattern in LocalePatternWidth]?: LocalizeUnitValues<Unit>;