@utiliread/primitives 1.0.0-116 → 1.0.0-118

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.
@@ -5,6 +5,7 @@ import { NumberFormatter, invariantDecimalSeparator, localeDecimalSeparator } fr
5
5
  import type { AggregateId } from "./aggregate-id";
6
6
  import type { BreakdownPeriod } from "./breakdown-rule";
7
7
  import { BreakdownRule } from "./breakdown-rule";
8
+ import { Duration } from "luxon";
8
9
  import type { MeasureId } from "./measure-id";
9
10
  import type { Medium } from "./medium";
10
11
  import type { Optional } from "./optional";
@@ -16,4 +17,4 @@ import { RegisterLibrary } from "./register-library";
16
17
  import { Repository } from "./repository";
17
18
  import { TimeOrRule } from "./time-or-rule";
18
19
  import type { UnitId } from "./unit-id";
19
- export { AggregateId, BreakdownPeriod, BreakdownRule, DayOfWeek, invariantDecimalSeparator, localeDecimalSeparator, MeasureId, Medium, NumberFormatter, Optional, PrecisionNumber, RegisterConvention, RegisterDefinition, RegisterId, RegisterLibrary, registers, Repository, Step, TimeOrRule, UnitId, };
20
+ export { AggregateId, BreakdownPeriod, BreakdownRule, DayOfWeek, invariantDecimalSeparator, localeDecimalSeparator, MeasureId, Medium, NumberFormatter, Optional, PrecisionNumber, RegisterConvention, RegisterDefinition, RegisterId, RegisterLibrary, registers, Repository, Step, TimeOrRule, UnitId, Duration as __Duration, };
@@ -0,0 +1 @@
1
+ export { Duration } from "luxon";
@@ -9,6 +9,7 @@ export declare enum DayOfWeek {
9
9
  Saturday = 6,
10
10
  Sunday = 7
11
11
  }
12
+ export { Duration };
12
13
  export declare namespace Step {
13
14
  function startOf(dateTime: DateTime, step: Step, firstDayOfWeek?: DayOfWeek): DateTime;
14
15
  function asDuration(step: Step, amount?: number): Duration;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@utiliread/primitives",
3
- "version": "1.0.0-116",
3
+ "version": "1.0.0-118",
4
4
  "source": "src/index.ts",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
package/src/index.ts CHANGED
@@ -12,6 +12,7 @@ import {
12
12
  import type { AggregateId } from "./aggregate-id";
13
13
  import type { BreakdownPeriod } from "./breakdown-rule";
14
14
  import { BreakdownRule } from "./breakdown-rule";
15
+ import { Duration } from "luxon";
15
16
  import type { MeasureId } from "./measure-id";
16
17
  import type { Medium } from "./medium";
17
18
  import type { Optional } from "./optional";
@@ -45,4 +46,8 @@ export {
45
46
  Step,
46
47
  TimeOrRule,
47
48
  UnitId,
49
+
50
+ // Hack to force parcel to include Duration in typings file
51
+ // Otherwise it seems to only include DateTime in the dist/index.d.ts which causes the file to be invalid
52
+ Duration as __Duration,
48
53
  };
package/src/step.ts CHANGED
@@ -12,6 +12,8 @@ export enum DayOfWeek {
12
12
  Sunday = 7,
13
13
  }
14
14
 
15
+ export { Duration };
16
+
15
17
  export namespace Step {
16
18
  export function startOf(
17
19
  dateTime: DateTime,
package/tsconfig.json CHANGED
@@ -6,6 +6,7 @@
6
6
  "declaration": true,
7
7
  "sourceMap": true,
8
8
  "strict": true,
9
+ "stripInternal": true,
9
10
  "rootDir": "src",
10
11
  "lib": ["ES2018", "DOM"],
11
12
  "types": ["mocha"]