@8ms/helpers 2.3.44 → 2.3.45
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.
|
@@ -13,7 +13,7 @@ declare const logLevel: {
|
|
|
13
13
|
type LogLevel = typeof logLevel[keyof typeof logLevel];
|
|
14
14
|
type LogEvent = {
|
|
15
15
|
timestamp: InputDate;
|
|
16
|
-
|
|
16
|
+
data: string | object;
|
|
17
17
|
};
|
|
18
18
|
//#endregion
|
|
19
19
|
//#region src/aws/cloudWatchLog/server/AwsCloudWatchLogNamespace.d.ts
|
|
@@ -70,7 +70,7 @@ var AwsCloudWatchLogNamespace = class extends BaseNamespace {
|
|
|
70
70
|
logStreamName,
|
|
71
71
|
logEvents: logEvents.map((event) => ({
|
|
72
72
|
timestamp: getLuxonDate(event.timestamp).toMillis(),
|
|
73
|
-
message: typeof event === "string" ? event : JSON.stringify(event)
|
|
73
|
+
message: typeof event.data === "string" ? event.data : JSON.stringify(event.data)
|
|
74
74
|
}))
|
|
75
75
|
}));
|
|
76
76
|
};
|
package/dist/number/index.mjs
CHANGED
|
@@ -9,8 +9,8 @@ const formatCompact = (input, maxDp, minDp) => {
|
|
|
9
9
|
const maximumDp = maxDp ?? 2;
|
|
10
10
|
const minimumDp = minDp ?? maxDp;
|
|
11
11
|
return Intl.NumberFormat(void 0, {
|
|
12
|
-
minimumFractionDigits:
|
|
13
|
-
maximumFractionDigits:
|
|
12
|
+
minimumFractionDigits: minimumDp,
|
|
13
|
+
maximumFractionDigits: maximumDp,
|
|
14
14
|
notation: "compact"
|
|
15
15
|
}).format(inputValue);
|
|
16
16
|
};
|
|
@@ -29,8 +29,8 @@ const formatCurrency = (input, currency = "GBP", maxDp, minDp) => {
|
|
|
29
29
|
let formatted = new Intl.NumberFormat(void 0, {
|
|
30
30
|
style: "currency",
|
|
31
31
|
currency: currencyClean,
|
|
32
|
-
minimumFractionDigits:
|
|
33
|
-
maximumFractionDigits:
|
|
32
|
+
minimumFractionDigits: minimumDp,
|
|
33
|
+
maximumFractionDigits: maximumDp
|
|
34
34
|
}).format(value);
|
|
35
35
|
if ("USD" === currencyClean) formatted = formatted.replace("US$", "$");
|
|
36
36
|
return formatted;
|
|
@@ -46,8 +46,8 @@ const formatStandard = (input, maxDp, minDp) => {
|
|
|
46
46
|
const maximumDp = maxDp ?? 0;
|
|
47
47
|
const minimumDp = minDp ?? maxDp;
|
|
48
48
|
return Intl.NumberFormat(void 0, {
|
|
49
|
-
minimumFractionDigits:
|
|
50
|
-
maximumFractionDigits:
|
|
49
|
+
minimumFractionDigits: minimumDp,
|
|
50
|
+
maximumFractionDigits: maximumDp,
|
|
51
51
|
notation: "standard"
|
|
52
52
|
}).format(inputValue);
|
|
53
53
|
};
|