@voltagent/internal 0.0.4 → 0.0.6
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/README.md +6 -4
- package/dist/main/index.d.mts +138 -105
- package/dist/main/index.d.ts +138 -105
- package/dist/main/index.js +24 -88
- package/dist/main/index.js.map +1 -1
- package/dist/main/index.mjs +23 -86
- package/dist/main/index.mjs.map +1 -1
- package/dist/utils/index.d.mts +76 -3
- package/dist/utils/index.d.ts +76 -3
- package/dist/utils/index.js +44 -84
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/index.mjs +41 -82
- package/dist/utils/index.mjs.map +1 -1
- package/package.json +1 -6
- package/dist/dev/index.d.mts +0 -103
- package/dist/dev/index.d.ts +0 -103
- package/dist/dev/index.js +0 -115
- package/dist/dev/index.js.map +0 -1
- package/dist/dev/index.mjs +0 -89
- package/dist/dev/index.mjs.map +0 -1
package/dist/utils/index.mjs
CHANGED
|
@@ -15,88 +15,26 @@ var __spreadValues = (a, b) => {
|
|
|
15
15
|
return a;
|
|
16
16
|
};
|
|
17
17
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
return {
|
|
26
|
-
/**
|
|
27
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
28
|
-
*
|
|
29
|
-
* @example
|
|
30
|
-
* ```typescript
|
|
31
|
-
* devLogger.info("Hello, world!");
|
|
32
|
-
*
|
|
33
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
34
|
-
* ```
|
|
35
|
-
*
|
|
36
|
-
* @param message - The message to log.
|
|
37
|
-
* @param args - The arguments to log.
|
|
38
|
-
*/
|
|
39
|
-
info: /* @__PURE__ */ __name((message, ...args) => {
|
|
40
|
-
if (isDev()) {
|
|
41
|
-
console.info(formatLogPrefix("INFO"), message, ...args);
|
|
18
|
+
var __async = (__this, __arguments, generator) => {
|
|
19
|
+
return new Promise((resolve, reject) => {
|
|
20
|
+
var fulfilled = (value) => {
|
|
21
|
+
try {
|
|
22
|
+
step(generator.next(value));
|
|
23
|
+
} catch (e) {
|
|
24
|
+
reject(e);
|
|
42
25
|
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
* devLogger.warn("Hello, world!");
|
|
50
|
-
*
|
|
51
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
52
|
-
* ```
|
|
53
|
-
*
|
|
54
|
-
* @param message - The message to log.
|
|
55
|
-
* @param args - The arguments to log.
|
|
56
|
-
*/
|
|
57
|
-
warn: /* @__PURE__ */ __name((message, ...args) => {
|
|
58
|
-
if (isDev()) {
|
|
59
|
-
console.warn(formatLogPrefix("WARN"), message, ...args);
|
|
26
|
+
};
|
|
27
|
+
var rejected = (value) => {
|
|
28
|
+
try {
|
|
29
|
+
step(generator.throw(value));
|
|
30
|
+
} catch (e) {
|
|
31
|
+
reject(e);
|
|
60
32
|
}
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
* ```typescript
|
|
67
|
-
* devLogger.error("Hello, world!");
|
|
68
|
-
*
|
|
69
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
70
|
-
* ```
|
|
71
|
-
*
|
|
72
|
-
* @param message - The message to log.
|
|
73
|
-
* @param args - The arguments to log.
|
|
74
|
-
*/
|
|
75
|
-
error: /* @__PURE__ */ __name((message, ...args) => {
|
|
76
|
-
if (isDev()) {
|
|
77
|
-
console.error(formatLogPrefix("ERROR"), message, ...args);
|
|
78
|
-
}
|
|
79
|
-
}, "error"),
|
|
80
|
-
debug: /* @__PURE__ */ __name((_message, ..._args) => {
|
|
81
|
-
return;
|
|
82
|
-
}, "debug")
|
|
83
|
-
};
|
|
84
|
-
}
|
|
85
|
-
__name(createDevLogger, "createDevLogger");
|
|
86
|
-
var logger_default = createDevLogger();
|
|
87
|
-
function isDevNodeEnv() {
|
|
88
|
-
const nodeEnv = process.env.NODE_ENV;
|
|
89
|
-
return nodeEnv !== "production" && nodeEnv !== "test" && nodeEnv !== "ci";
|
|
90
|
-
}
|
|
91
|
-
__name(isDevNodeEnv, "isDevNodeEnv");
|
|
92
|
-
function formatLogPrefix(level) {
|
|
93
|
-
return `[VoltAgent] [${timestamp()}] ${level}: `;
|
|
94
|
-
}
|
|
95
|
-
__name(formatLogPrefix, "formatLogPrefix");
|
|
96
|
-
function timestamp() {
|
|
97
|
-
return (/* @__PURE__ */ new Date()).toISOString().replace("T", " ").slice(0, -1);
|
|
98
|
-
}
|
|
99
|
-
__name(timestamp, "timestamp");
|
|
33
|
+
};
|
|
34
|
+
var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
|
|
35
|
+
step((generator = generator.apply(__this, __arguments)).next());
|
|
36
|
+
});
|
|
37
|
+
};
|
|
100
38
|
|
|
101
39
|
// src/utils/lang.ts
|
|
102
40
|
function isNil(obj) {
|
|
@@ -131,11 +69,13 @@ function isEmptyObject(obj) {
|
|
|
131
69
|
__name(isEmptyObject, "isEmptyObject");
|
|
132
70
|
|
|
133
71
|
// src/utils/objects.ts
|
|
134
|
-
function deepClone(obj) {
|
|
72
|
+
function deepClone(obj, logger) {
|
|
135
73
|
try {
|
|
136
74
|
return JSON.parse(JSON.stringify(obj));
|
|
137
75
|
} catch (error) {
|
|
138
|
-
|
|
76
|
+
if (logger) {
|
|
77
|
+
logger.warn("Failed to deep clone object, using shallow clone", { error });
|
|
78
|
+
}
|
|
139
79
|
if (obj === null || typeof obj !== "object") {
|
|
140
80
|
return obj;
|
|
141
81
|
}
|
|
@@ -147,7 +87,26 @@ function hasKey(obj, key) {
|
|
|
147
87
|
return isObject(obj) && key in obj;
|
|
148
88
|
}
|
|
149
89
|
__name(hasKey, "hasKey");
|
|
90
|
+
|
|
91
|
+
// src/utils/async-iterable-stream.ts
|
|
92
|
+
function createAsyncIterableStream(source) {
|
|
93
|
+
const stream = source.pipeThrough(new TransformStream());
|
|
94
|
+
stream[Symbol.asyncIterator] = () => {
|
|
95
|
+
const reader = stream.getReader();
|
|
96
|
+
return {
|
|
97
|
+
next() {
|
|
98
|
+
return __async(this, null, function* () {
|
|
99
|
+
const { done, value } = yield reader.read();
|
|
100
|
+
return done ? { done: true, value: void 0 } : { done: false, value };
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
return stream;
|
|
106
|
+
}
|
|
107
|
+
__name(createAsyncIterableStream, "createAsyncIterableStream");
|
|
150
108
|
export {
|
|
109
|
+
createAsyncIterableStream,
|
|
151
110
|
deepClone,
|
|
152
111
|
hasKey,
|
|
153
112
|
isEmptyObject,
|
package/dist/utils/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/
|
|
1
|
+
{"version":3,"sources":["../../src/utils/lang.ts","../../src/utils/objects.ts","../../src/utils/async-iterable-stream.ts"],"sourcesContent":["import type { EmptyObject } from \"type-fest\";\nimport type { AnyFunction, Nil, PlainObject } from \"../types\";\n\n/**\n * Check if a value is nil\n *\n * @param obj - The value to check\n * @returns True if the value is nil, false otherwise\n */\nexport function isNil(obj: unknown): obj is Nil {\n return obj === null || obj === undefined;\n}\n\n/**\n * Check if an object is a JS object\n *\n * @param obj - The object to check\n * @returns True if the object is a JS object}\n */\nexport function isObject<T extends object>(obj: unknown): obj is T {\n return (typeof obj === \"object\" || typeof obj === \"function\") && !isNil(obj);\n}\n\n/**\n * Check if a value is a function\n *\n * @param obj - The value to check\n * @returns True if the value is a function, false otherwise\n */\nexport function isFunction<T extends AnyFunction>(obj: unknown): obj is T {\n return typeof obj === \"function\";\n}\n\n/**\n * Check if an object is a plain object (i.e. a JS object but not including arrays or functions)\n *\n * @param obj - The object to check\n * @returns True if the object is a plain object, false otherwise.\n */\nexport function isPlainObject<T extends PlainObject>(obj: unknown): obj is T {\n if (!isObject(obj)) {\n return false;\n }\n\n const prototype = Object.getPrototypeOf(obj);\n return prototype === Object.prototype || prototype === null;\n}\n\n/**\n * Check if an object is an empty object\n *\n * @param obj - The object to check\n * @returns True if the object is an empty object, false otherwise\n */\nexport function isEmptyObject(obj: unknown): obj is EmptyObject {\n if (!isObject(obj)) {\n return false;\n }\n\n // Check for own string and symbol properties (enumerable or not)\n if (Object.getOwnPropertyNames(obj).length > 0 || Object.getOwnPropertySymbols(obj).length > 0) {\n return false;\n }\n\n return true;\n}\n","import type { SetRequired } from \"type-fest\";\nimport type { PlainObject } from \"../types\";\nimport { isObject } from \"./lang\";\nimport type { Logger } from \"../logger/types\";\n\n/**\n * Deep clone an object using JSON serialization with fallback to shallow clone\n *\n * @param obj - The object to clone\n * @param logger - Optional logger for warnings\n * @returns A deep copy of the object, or shallow copy if JSON serialization fails\n */\nexport function deepClone<T>(obj: T, logger?: Logger): T {\n try {\n return JSON.parse(JSON.stringify(obj));\n } catch (error) {\n if (logger) {\n logger.warn(\"Failed to deep clone object, using shallow clone\", { error });\n }\n // Fallback to shallow clone for primitive types and simple objects\n if (obj === null || typeof obj !== \"object\") {\n return obj;\n }\n return { ...obj } as T;\n }\n}\n\n/**\n * Check if an object has a key\n *\n * @param obj - The object to check\n * @param key - The key to check\n * @returns True if the object has the key, false otherwise\n */\nexport function hasKey<T extends PlainObject, K extends string>(\n obj: T,\n key: K,\n): obj is T & SetRequired<T, K> {\n return isObject(obj) && key in obj;\n}\n","import type { Merge } from \"type-fest\";\n\n/**\n * An async iterable stream that can be read from.\n * @example\n * ```typescript\n * const stream: AsyncIterableStream<string> = getStream();\n * for await (const chunk of stream) {\n * console.log(chunk);\n * }\n * ```\n */\nexport type AsyncIterableStream<T> = Merge<AsyncIterable<T>, ReadableStream<T>>;\n\n/**\n * Create an async iterable stream from a readable stream.\n *\n * This is useful for creating an async iterable stream from a readable stream.\n *\n * @example\n * ```typescript\n * const stream: AsyncIterableStream<string> = createAsyncIterableStream(new ReadableStream({\n * start(controller) {\n * controller.enqueue(\"Hello\");\n * controller.close();\n * },\n * }));\n * ```\n * @param source The readable stream to create an async iterable stream from.\n * @returns The async iterable stream.\n */\nexport function createAsyncIterableStream<T>(source: ReadableStream<T>): AsyncIterableStream<T> {\n const stream = source.pipeThrough(new TransformStream<T, T>());\n\n (stream as AsyncIterableStream<T>)[Symbol.asyncIterator] = () => {\n const reader = stream.getReader();\n return {\n async next(): Promise<IteratorResult<T>> {\n const { done, value } = await reader.read();\n return done ? { done: true, value: undefined } : { done: false, value };\n },\n };\n };\n\n return stream as AsyncIterableStream<T>;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AASO,SAAS,MAAM,KAA0B;AAC9C,SAAO,QAAQ,QAAQ,QAAQ;AACjC;AAFgB;AAUT,SAAS,SAA2B,KAAwB;AACjE,UAAQ,OAAO,QAAQ,YAAY,OAAO,QAAQ,eAAe,CAAC,MAAM,GAAG;AAC7E;AAFgB;AAUT,SAAS,WAAkC,KAAwB;AACxE,SAAO,OAAO,QAAQ;AACxB;AAFgB;AAUT,SAAS,cAAqC,KAAwB;AAC3E,MAAI,CAAC,SAAS,GAAG,GAAG;AAClB,WAAO;AAAA,EACT;AAEA,QAAM,YAAY,OAAO,eAAe,GAAG;AAC3C,SAAO,cAAc,OAAO,aAAa,cAAc;AACzD;AAPgB;AAeT,SAAS,cAAc,KAAkC;AAC9D,MAAI,CAAC,SAAS,GAAG,GAAG;AAClB,WAAO;AAAA,EACT;AAGA,MAAI,OAAO,oBAAoB,GAAG,EAAE,SAAS,KAAK,OAAO,sBAAsB,GAAG,EAAE,SAAS,GAAG;AAC9F,WAAO;AAAA,EACT;AAEA,SAAO;AACT;AAXgB;;;AC1CT,SAAS,UAAa,KAAQ,QAAoB;AACvD,MAAI;AACF,WAAO,KAAK,MAAM,KAAK,UAAU,GAAG,CAAC;AAAA,EACvC,SAAS,OAAO;AACd,QAAI,QAAQ;AACV,aAAO,KAAK,oDAAoD,EAAE,MAAM,CAAC;AAAA,IAC3E;AAEA,QAAI,QAAQ,QAAQ,OAAO,QAAQ,UAAU;AAC3C,aAAO;AAAA,IACT;AACA,WAAO,mBAAK;AAAA,EACd;AACF;AAbgB;AAsBT,SAAS,OACd,KACA,KAC8B;AAC9B,SAAO,SAAS,GAAG,KAAK,OAAO;AACjC;AALgB;;;ACHT,SAAS,0BAA6B,QAAmD;AAC9F,QAAM,SAAS,OAAO,YAAY,IAAI,gBAAsB,CAAC;AAE7D,EAAC,OAAkC,OAAO,aAAa,IAAI,MAAM;AAC/D,UAAM,SAAS,OAAO,UAAU;AAChC,WAAO;AAAA,MACC,OAAmC;AAAA;AACvC,gBAAM,EAAE,MAAM,MAAM,IAAI,MAAM,OAAO,KAAK;AAC1C,iBAAO,OAAO,EAAE,MAAM,MAAM,OAAO,OAAU,IAAI,EAAE,MAAM,OAAO,MAAM;AAAA,QACxE;AAAA;AAAA,IACF;AAAA,EACF;AAEA,SAAO;AACT;AAdgB;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voltagent/internal",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.6",
|
|
4
4
|
"description": "VoltAgent internal - an internal set of tools for the VoltAgent packages",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"exports": {
|
|
@@ -9,11 +9,6 @@
|
|
|
9
9
|
"import": "./dist/main/index.mjs",
|
|
10
10
|
"require": "./dist/main/index.js"
|
|
11
11
|
},
|
|
12
|
-
"./dev": {
|
|
13
|
-
"types": "./dist/dev/index.d.ts",
|
|
14
|
-
"import": "./dist/dev/index.mjs",
|
|
15
|
-
"require": "./dist/dev/index.js"
|
|
16
|
-
},
|
|
17
12
|
"./test": {
|
|
18
13
|
"types": "./dist/test/index.d.ts",
|
|
19
14
|
"import": "./dist/test/index.mjs",
|
package/dist/dev/index.d.mts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
interface DevLoggerOptions {
|
|
2
|
-
dev: boolean | (() => boolean);
|
|
3
|
-
}
|
|
4
|
-
/**
|
|
5
|
-
* A logger for development purposes, that will not pollute the production logs (aka if process.env.NODE_ENV is not "development").
|
|
6
|
-
*
|
|
7
|
-
* @example
|
|
8
|
-
* ```typescript
|
|
9
|
-
* devLogger.info("Hello, world!");
|
|
10
|
-
* ```
|
|
11
|
-
*/
|
|
12
|
-
declare function createDevLogger(options?: DevLoggerOptions): {
|
|
13
|
-
/**
|
|
14
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
* ```typescript
|
|
18
|
-
* devLogger.info("Hello, world!");
|
|
19
|
-
*
|
|
20
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
21
|
-
* ```
|
|
22
|
-
*
|
|
23
|
-
* @param message - The message to log.
|
|
24
|
-
* @param args - The arguments to log.
|
|
25
|
-
*/
|
|
26
|
-
info: (message?: any, ...args: any[]) => void;
|
|
27
|
-
/**
|
|
28
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
29
|
-
*
|
|
30
|
-
* @example
|
|
31
|
-
* ```typescript
|
|
32
|
-
* devLogger.warn("Hello, world!");
|
|
33
|
-
*
|
|
34
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
35
|
-
* ```
|
|
36
|
-
*
|
|
37
|
-
* @param message - The message to log.
|
|
38
|
-
* @param args - The arguments to log.
|
|
39
|
-
*/
|
|
40
|
-
warn: (message?: any, ...args: any[]) => void;
|
|
41
|
-
/**
|
|
42
|
-
* Log a warning message to the console if the environment is development.
|
|
43
|
-
*
|
|
44
|
-
* @example
|
|
45
|
-
* ```typescript
|
|
46
|
-
* devLogger.error("Hello, world!");
|
|
47
|
-
*
|
|
48
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
49
|
-
* ```
|
|
50
|
-
*
|
|
51
|
-
* @param message - The message to log.
|
|
52
|
-
* @param args - The arguments to log.
|
|
53
|
-
*/
|
|
54
|
-
error: (message?: any, ...args: any[]) => void;
|
|
55
|
-
debug: (_message?: any, ..._args: any[]) => void;
|
|
56
|
-
};
|
|
57
|
-
declare const _default: {
|
|
58
|
-
/**
|
|
59
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
60
|
-
*
|
|
61
|
-
* @example
|
|
62
|
-
* ```typescript
|
|
63
|
-
* devLogger.info("Hello, world!");
|
|
64
|
-
*
|
|
65
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
66
|
-
* ```
|
|
67
|
-
*
|
|
68
|
-
* @param message - The message to log.
|
|
69
|
-
* @param args - The arguments to log.
|
|
70
|
-
*/
|
|
71
|
-
info: (message?: any, ...args: any[]) => void;
|
|
72
|
-
/**
|
|
73
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
74
|
-
*
|
|
75
|
-
* @example
|
|
76
|
-
* ```typescript
|
|
77
|
-
* devLogger.warn("Hello, world!");
|
|
78
|
-
*
|
|
79
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
80
|
-
* ```
|
|
81
|
-
*
|
|
82
|
-
* @param message - The message to log.
|
|
83
|
-
* @param args - The arguments to log.
|
|
84
|
-
*/
|
|
85
|
-
warn: (message?: any, ...args: any[]) => void;
|
|
86
|
-
/**
|
|
87
|
-
* Log a warning message to the console if the environment is development.
|
|
88
|
-
*
|
|
89
|
-
* @example
|
|
90
|
-
* ```typescript
|
|
91
|
-
* devLogger.error("Hello, world!");
|
|
92
|
-
*
|
|
93
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
94
|
-
* ```
|
|
95
|
-
*
|
|
96
|
-
* @param message - The message to log.
|
|
97
|
-
* @param args - The arguments to log.
|
|
98
|
-
*/
|
|
99
|
-
error: (message?: any, ...args: any[]) => void;
|
|
100
|
-
debug: (_message?: any, ..._args: any[]) => void;
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
export { type DevLoggerOptions, createDevLogger, _default as devLogger };
|
package/dist/dev/index.d.ts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
interface DevLoggerOptions {
|
|
2
|
-
dev: boolean | (() => boolean);
|
|
3
|
-
}
|
|
4
|
-
/**
|
|
5
|
-
* A logger for development purposes, that will not pollute the production logs (aka if process.env.NODE_ENV is not "development").
|
|
6
|
-
*
|
|
7
|
-
* @example
|
|
8
|
-
* ```typescript
|
|
9
|
-
* devLogger.info("Hello, world!");
|
|
10
|
-
* ```
|
|
11
|
-
*/
|
|
12
|
-
declare function createDevLogger(options?: DevLoggerOptions): {
|
|
13
|
-
/**
|
|
14
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
* ```typescript
|
|
18
|
-
* devLogger.info("Hello, world!");
|
|
19
|
-
*
|
|
20
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
21
|
-
* ```
|
|
22
|
-
*
|
|
23
|
-
* @param message - The message to log.
|
|
24
|
-
* @param args - The arguments to log.
|
|
25
|
-
*/
|
|
26
|
-
info: (message?: any, ...args: any[]) => void;
|
|
27
|
-
/**
|
|
28
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
29
|
-
*
|
|
30
|
-
* @example
|
|
31
|
-
* ```typescript
|
|
32
|
-
* devLogger.warn("Hello, world!");
|
|
33
|
-
*
|
|
34
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
35
|
-
* ```
|
|
36
|
-
*
|
|
37
|
-
* @param message - The message to log.
|
|
38
|
-
* @param args - The arguments to log.
|
|
39
|
-
*/
|
|
40
|
-
warn: (message?: any, ...args: any[]) => void;
|
|
41
|
-
/**
|
|
42
|
-
* Log a warning message to the console if the environment is development.
|
|
43
|
-
*
|
|
44
|
-
* @example
|
|
45
|
-
* ```typescript
|
|
46
|
-
* devLogger.error("Hello, world!");
|
|
47
|
-
*
|
|
48
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
49
|
-
* ```
|
|
50
|
-
*
|
|
51
|
-
* @param message - The message to log.
|
|
52
|
-
* @param args - The arguments to log.
|
|
53
|
-
*/
|
|
54
|
-
error: (message?: any, ...args: any[]) => void;
|
|
55
|
-
debug: (_message?: any, ..._args: any[]) => void;
|
|
56
|
-
};
|
|
57
|
-
declare const _default: {
|
|
58
|
-
/**
|
|
59
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
60
|
-
*
|
|
61
|
-
* @example
|
|
62
|
-
* ```typescript
|
|
63
|
-
* devLogger.info("Hello, world!");
|
|
64
|
-
*
|
|
65
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
66
|
-
* ```
|
|
67
|
-
*
|
|
68
|
-
* @param message - The message to log.
|
|
69
|
-
* @param args - The arguments to log.
|
|
70
|
-
*/
|
|
71
|
-
info: (message?: any, ...args: any[]) => void;
|
|
72
|
-
/**
|
|
73
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
74
|
-
*
|
|
75
|
-
* @example
|
|
76
|
-
* ```typescript
|
|
77
|
-
* devLogger.warn("Hello, world!");
|
|
78
|
-
*
|
|
79
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
80
|
-
* ```
|
|
81
|
-
*
|
|
82
|
-
* @param message - The message to log.
|
|
83
|
-
* @param args - The arguments to log.
|
|
84
|
-
*/
|
|
85
|
-
warn: (message?: any, ...args: any[]) => void;
|
|
86
|
-
/**
|
|
87
|
-
* Log a warning message to the console if the environment is development.
|
|
88
|
-
*
|
|
89
|
-
* @example
|
|
90
|
-
* ```typescript
|
|
91
|
-
* devLogger.error("Hello, world!");
|
|
92
|
-
*
|
|
93
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
94
|
-
* ```
|
|
95
|
-
*
|
|
96
|
-
* @param message - The message to log.
|
|
97
|
-
* @param args - The arguments to log.
|
|
98
|
-
*/
|
|
99
|
-
error: (message?: any, ...args: any[]) => void;
|
|
100
|
-
debug: (_message?: any, ..._args: any[]) => void;
|
|
101
|
-
};
|
|
102
|
-
|
|
103
|
-
export { type DevLoggerOptions, createDevLogger, _default as devLogger };
|
package/dist/dev/index.js
DELETED
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __defProp = Object.defineProperty;
|
|
3
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
7
|
-
var __export = (target, all) => {
|
|
8
|
-
for (var name in all)
|
|
9
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
-
};
|
|
11
|
-
var __copyProps = (to, from, except, desc) => {
|
|
12
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
-
for (let key of __getOwnPropNames(from))
|
|
14
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
-
}
|
|
17
|
-
return to;
|
|
18
|
-
};
|
|
19
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
20
|
-
|
|
21
|
-
// src/dev/index.ts
|
|
22
|
-
var index_exports = {};
|
|
23
|
-
__export(index_exports, {
|
|
24
|
-
createDevLogger: () => createDevLogger,
|
|
25
|
-
devLogger: () => logger_default
|
|
26
|
-
});
|
|
27
|
-
module.exports = __toCommonJS(index_exports);
|
|
28
|
-
|
|
29
|
-
// src/dev/logger.ts
|
|
30
|
-
function createDevLogger(options) {
|
|
31
|
-
const isDev = typeof (options == null ? void 0 : options.dev) === "function" ? options.dev : () => {
|
|
32
|
-
var _a;
|
|
33
|
-
return (_a = options == null ? void 0 : options.dev) != null ? _a : isDevNodeEnv();
|
|
34
|
-
};
|
|
35
|
-
return {
|
|
36
|
-
/**
|
|
37
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
38
|
-
*
|
|
39
|
-
* @example
|
|
40
|
-
* ```typescript
|
|
41
|
-
* devLogger.info("Hello, world!");
|
|
42
|
-
*
|
|
43
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
44
|
-
* ```
|
|
45
|
-
*
|
|
46
|
-
* @param message - The message to log.
|
|
47
|
-
* @param args - The arguments to log.
|
|
48
|
-
*/
|
|
49
|
-
info: /* @__PURE__ */ __name((message, ...args) => {
|
|
50
|
-
if (isDev()) {
|
|
51
|
-
console.info(formatLogPrefix("INFO"), message, ...args);
|
|
52
|
-
}
|
|
53
|
-
}, "info"),
|
|
54
|
-
/**
|
|
55
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
56
|
-
*
|
|
57
|
-
* @example
|
|
58
|
-
* ```typescript
|
|
59
|
-
* devLogger.warn("Hello, world!");
|
|
60
|
-
*
|
|
61
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
62
|
-
* ```
|
|
63
|
-
*
|
|
64
|
-
* @param message - The message to log.
|
|
65
|
-
* @param args - The arguments to log.
|
|
66
|
-
*/
|
|
67
|
-
warn: /* @__PURE__ */ __name((message, ...args) => {
|
|
68
|
-
if (isDev()) {
|
|
69
|
-
console.warn(formatLogPrefix("WARN"), message, ...args);
|
|
70
|
-
}
|
|
71
|
-
}, "warn"),
|
|
72
|
-
/**
|
|
73
|
-
* Log a warning message to the console if the environment is development.
|
|
74
|
-
*
|
|
75
|
-
* @example
|
|
76
|
-
* ```typescript
|
|
77
|
-
* devLogger.error("Hello, world!");
|
|
78
|
-
*
|
|
79
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
80
|
-
* ```
|
|
81
|
-
*
|
|
82
|
-
* @param message - The message to log.
|
|
83
|
-
* @param args - The arguments to log.
|
|
84
|
-
*/
|
|
85
|
-
error: /* @__PURE__ */ __name((message, ...args) => {
|
|
86
|
-
if (isDev()) {
|
|
87
|
-
console.error(formatLogPrefix("ERROR"), message, ...args);
|
|
88
|
-
}
|
|
89
|
-
}, "error"),
|
|
90
|
-
debug: /* @__PURE__ */ __name((_message, ..._args) => {
|
|
91
|
-
return;
|
|
92
|
-
}, "debug")
|
|
93
|
-
};
|
|
94
|
-
}
|
|
95
|
-
__name(createDevLogger, "createDevLogger");
|
|
96
|
-
var logger_default = createDevLogger();
|
|
97
|
-
function isDevNodeEnv() {
|
|
98
|
-
const nodeEnv = process.env.NODE_ENV;
|
|
99
|
-
return nodeEnv !== "production" && nodeEnv !== "test" && nodeEnv !== "ci";
|
|
100
|
-
}
|
|
101
|
-
__name(isDevNodeEnv, "isDevNodeEnv");
|
|
102
|
-
function formatLogPrefix(level) {
|
|
103
|
-
return `[VoltAgent] [${timestamp()}] ${level}: `;
|
|
104
|
-
}
|
|
105
|
-
__name(formatLogPrefix, "formatLogPrefix");
|
|
106
|
-
function timestamp() {
|
|
107
|
-
return (/* @__PURE__ */ new Date()).toISOString().replace("T", " ").slice(0, -1);
|
|
108
|
-
}
|
|
109
|
-
__name(timestamp, "timestamp");
|
|
110
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
111
|
-
0 && (module.exports = {
|
|
112
|
-
createDevLogger,
|
|
113
|
-
devLogger
|
|
114
|
-
});
|
|
115
|
-
//# sourceMappingURL=index.js.map
|
package/dist/dev/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/dev/index.ts","../../src/dev/logger.ts"],"sourcesContent":["export { createDevLogger, default as devLogger } from \"./logger\";\nexport type { DevLoggerOptions } from \"./logger\";\n","export interface DevLoggerOptions {\n dev: boolean | (() => boolean);\n}\n\n/**\n * A logger for development purposes, that will not pollute the production logs (aka if process.env.NODE_ENV is not \"development\").\n *\n * @example\n * ```typescript\n * devLogger.info(\"Hello, world!\");\n * ```\n */\nexport function createDevLogger(options?: DevLoggerOptions) {\n const isDev =\n typeof options?.dev === \"function\" ? options.dev : () => options?.dev ?? isDevNodeEnv();\n\n return {\n /**\n * Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not \"development\".\n *\n * @example\n * ```typescript\n * devLogger.info(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n info: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.info(formatLogPrefix(\"INFO\"), message, ...args);\n }\n },\n /**\n * Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not \"development\".\n *\n * @example\n * ```typescript\n * devLogger.warn(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n warn: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.warn(formatLogPrefix(\"WARN\"), message, ...args);\n }\n },\n /**\n * Log a warning message to the console if the environment is development.\n *\n * @example\n * ```typescript\n * devLogger.error(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n error: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.error(formatLogPrefix(\"ERROR\"), message, ...args);\n }\n },\n\n debug: (_message?: any, ..._args: any[]) => {\n // todo: implement debug logging with pino\n return;\n },\n };\n}\n\nexport default createDevLogger();\n\nfunction isDevNodeEnv() {\n const nodeEnv = process.env.NODE_ENV;\n return nodeEnv !== \"production\" && nodeEnv !== \"test\" && nodeEnv !== \"ci\";\n}\n\nfunction formatLogPrefix(level: \"INFO\" | \"WARN\" | \"ERROR\" | \"DEBUG\"): string {\n return `[VoltAgent] [${timestamp()}] ${level}: `;\n}\n\nfunction timestamp(): string {\n return new Date().toISOString().replace(\"T\", \" \").slice(0, -1);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACYO,SAAS,gBAAgB,SAA4B;AAC1D,QAAM,QACJ,QAAO,mCAAS,SAAQ,aAAa,QAAQ,MAAM,MAAG;AAd1D;AAc6D,oDAAS,QAAT,YAAgB,aAAa;AAAA;AAExF,SAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAcL,MAAM,wBAAC,YAAkB,SAAgB;AACvC,UAAI,MAAM,GAAG;AACX,gBAAQ,KAAK,gBAAgB,MAAM,GAAG,SAAS,GAAG,IAAI;AAAA,MACxD;AAAA,IACF,GAJM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAkBN,MAAM,wBAAC,YAAkB,SAAgB;AACvC,UAAI,MAAM,GAAG;AACX,gBAAQ,KAAK,gBAAgB,MAAM,GAAG,SAAS,GAAG,IAAI;AAAA,MACxD;AAAA,IACF,GAJM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAkBN,OAAO,wBAAC,YAAkB,SAAgB;AACxC,UAAI,MAAM,GAAG;AACX,gBAAQ,MAAM,gBAAgB,OAAO,GAAG,SAAS,GAAG,IAAI;AAAA,MAC1D;AAAA,IACF,GAJO;AAAA,IAMP,OAAO,wBAAC,aAAmB,UAAiB;AAE1C;AAAA,IACF,GAHO;AAAA,EAIT;AACF;AAjEgB;AAmEhB,IAAO,iBAAQ,gBAAgB;AAE/B,SAAS,eAAe;AACtB,QAAM,UAAU,QAAQ,IAAI;AAC5B,SAAO,YAAY,gBAAgB,YAAY,UAAU,YAAY;AACvE;AAHS;AAKT,SAAS,gBAAgB,OAAoD;AAC3E,SAAO,gBAAgB,UAAU,CAAC,KAAK,KAAK;AAC9C;AAFS;AAIT,SAAS,YAAoB;AAC3B,UAAO,oBAAI,KAAK,GAAE,YAAY,EAAE,QAAQ,KAAK,GAAG,EAAE,MAAM,GAAG,EAAE;AAC/D;AAFS;","names":[]}
|
package/dist/dev/index.mjs
DELETED
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
3
|
-
|
|
4
|
-
// src/dev/logger.ts
|
|
5
|
-
function createDevLogger(options) {
|
|
6
|
-
const isDev = typeof (options == null ? void 0 : options.dev) === "function" ? options.dev : () => {
|
|
7
|
-
var _a;
|
|
8
|
-
return (_a = options == null ? void 0 : options.dev) != null ? _a : isDevNodeEnv();
|
|
9
|
-
};
|
|
10
|
-
return {
|
|
11
|
-
/**
|
|
12
|
-
* Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
13
|
-
*
|
|
14
|
-
* @example
|
|
15
|
-
* ```typescript
|
|
16
|
-
* devLogger.info("Hello, world!");
|
|
17
|
-
*
|
|
18
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!
|
|
19
|
-
* ```
|
|
20
|
-
*
|
|
21
|
-
* @param message - The message to log.
|
|
22
|
-
* @param args - The arguments to log.
|
|
23
|
-
*/
|
|
24
|
-
info: /* @__PURE__ */ __name((message, ...args) => {
|
|
25
|
-
if (isDev()) {
|
|
26
|
-
console.info(formatLogPrefix("INFO"), message, ...args);
|
|
27
|
-
}
|
|
28
|
-
}, "info"),
|
|
29
|
-
/**
|
|
30
|
-
* Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not "development".
|
|
31
|
-
*
|
|
32
|
-
* @example
|
|
33
|
-
* ```typescript
|
|
34
|
-
* devLogger.warn("Hello, world!");
|
|
35
|
-
*
|
|
36
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!
|
|
37
|
-
* ```
|
|
38
|
-
*
|
|
39
|
-
* @param message - The message to log.
|
|
40
|
-
* @param args - The arguments to log.
|
|
41
|
-
*/
|
|
42
|
-
warn: /* @__PURE__ */ __name((message, ...args) => {
|
|
43
|
-
if (isDev()) {
|
|
44
|
-
console.warn(formatLogPrefix("WARN"), message, ...args);
|
|
45
|
-
}
|
|
46
|
-
}, "warn"),
|
|
47
|
-
/**
|
|
48
|
-
* Log a warning message to the console if the environment is development.
|
|
49
|
-
*
|
|
50
|
-
* @example
|
|
51
|
-
* ```typescript
|
|
52
|
-
* devLogger.error("Hello, world!");
|
|
53
|
-
*
|
|
54
|
-
* // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!
|
|
55
|
-
* ```
|
|
56
|
-
*
|
|
57
|
-
* @param message - The message to log.
|
|
58
|
-
* @param args - The arguments to log.
|
|
59
|
-
*/
|
|
60
|
-
error: /* @__PURE__ */ __name((message, ...args) => {
|
|
61
|
-
if (isDev()) {
|
|
62
|
-
console.error(formatLogPrefix("ERROR"), message, ...args);
|
|
63
|
-
}
|
|
64
|
-
}, "error"),
|
|
65
|
-
debug: /* @__PURE__ */ __name((_message, ..._args) => {
|
|
66
|
-
return;
|
|
67
|
-
}, "debug")
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
__name(createDevLogger, "createDevLogger");
|
|
71
|
-
var logger_default = createDevLogger();
|
|
72
|
-
function isDevNodeEnv() {
|
|
73
|
-
const nodeEnv = process.env.NODE_ENV;
|
|
74
|
-
return nodeEnv !== "production" && nodeEnv !== "test" && nodeEnv !== "ci";
|
|
75
|
-
}
|
|
76
|
-
__name(isDevNodeEnv, "isDevNodeEnv");
|
|
77
|
-
function formatLogPrefix(level) {
|
|
78
|
-
return `[VoltAgent] [${timestamp()}] ${level}: `;
|
|
79
|
-
}
|
|
80
|
-
__name(formatLogPrefix, "formatLogPrefix");
|
|
81
|
-
function timestamp() {
|
|
82
|
-
return (/* @__PURE__ */ new Date()).toISOString().replace("T", " ").slice(0, -1);
|
|
83
|
-
}
|
|
84
|
-
__name(timestamp, "timestamp");
|
|
85
|
-
export {
|
|
86
|
-
createDevLogger,
|
|
87
|
-
logger_default as devLogger
|
|
88
|
-
};
|
|
89
|
-
//# sourceMappingURL=index.mjs.map
|
package/dist/dev/index.mjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/dev/logger.ts"],"sourcesContent":["export interface DevLoggerOptions {\n dev: boolean | (() => boolean);\n}\n\n/**\n * A logger for development purposes, that will not pollute the production logs (aka if process.env.NODE_ENV is not \"development\").\n *\n * @example\n * ```typescript\n * devLogger.info(\"Hello, world!\");\n * ```\n */\nexport function createDevLogger(options?: DevLoggerOptions) {\n const isDev =\n typeof options?.dev === \"function\" ? options.dev : () => options?.dev ?? isDevNodeEnv();\n\n return {\n /**\n * Log a message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not \"development\".\n *\n * @example\n * ```typescript\n * devLogger.info(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] INFO: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n info: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.info(formatLogPrefix(\"INFO\"), message, ...args);\n }\n },\n /**\n * Log a warning message to the console if the environment is development. This will NOT be logged if process.env.NODE_ENV is not \"development\".\n *\n * @example\n * ```typescript\n * devLogger.warn(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] WARN: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n warn: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.warn(formatLogPrefix(\"WARN\"), message, ...args);\n }\n },\n /**\n * Log a warning message to the console if the environment is development.\n *\n * @example\n * ```typescript\n * devLogger.error(\"Hello, world!\");\n *\n * // output: [VoltAgent] [2021-01-01T00:00:00.000Z] ERROR: Hello, world!\n * ```\n *\n * @param message - The message to log.\n * @param args - The arguments to log.\n */\n error: (message?: any, ...args: any[]) => {\n if (isDev()) {\n console.error(formatLogPrefix(\"ERROR\"), message, ...args);\n }\n },\n\n debug: (_message?: any, ..._args: any[]) => {\n // todo: implement debug logging with pino\n return;\n },\n };\n}\n\nexport default createDevLogger();\n\nfunction isDevNodeEnv() {\n const nodeEnv = process.env.NODE_ENV;\n return nodeEnv !== \"production\" && nodeEnv !== \"test\" && nodeEnv !== \"ci\";\n}\n\nfunction formatLogPrefix(level: \"INFO\" | \"WARN\" | \"ERROR\" | \"DEBUG\"): string {\n return `[VoltAgent] [${timestamp()}] ${level}: `;\n}\n\nfunction timestamp(): string {\n return new Date().toISOString().replace(\"T\", \" \").slice(0, -1);\n}\n"],"mappings":";;;;AAYO,SAAS,gBAAgB,SAA4B;AAC1D,QAAM,QACJ,QAAO,mCAAS,SAAQ,aAAa,QAAQ,MAAM,MAAG;AAd1D;AAc6D,oDAAS,QAAT,YAAgB,aAAa;AAAA;AAExF,SAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAcL,MAAM,wBAAC,YAAkB,SAAgB;AACvC,UAAI,MAAM,GAAG;AACX,gBAAQ,KAAK,gBAAgB,MAAM,GAAG,SAAS,GAAG,IAAI;AAAA,MACxD;AAAA,IACF,GAJM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAkBN,MAAM,wBAAC,YAAkB,SAAgB;AACvC,UAAI,MAAM,GAAG;AACX,gBAAQ,KAAK,gBAAgB,MAAM,GAAG,SAAS,GAAG,IAAI;AAAA,MACxD;AAAA,IACF,GAJM;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAkBN,OAAO,wBAAC,YAAkB,SAAgB;AACxC,UAAI,MAAM,GAAG;AACX,gBAAQ,MAAM,gBAAgB,OAAO,GAAG,SAAS,GAAG,IAAI;AAAA,MAC1D;AAAA,IACF,GAJO;AAAA,IAMP,OAAO,wBAAC,aAAmB,UAAiB;AAE1C;AAAA,IACF,GAHO;AAAA,EAIT;AACF;AAjEgB;AAmEhB,IAAO,iBAAQ,gBAAgB;AAE/B,SAAS,eAAe;AACtB,QAAM,UAAU,QAAQ,IAAI;AAC5B,SAAO,YAAY,gBAAgB,YAAY,UAAU,YAAY;AACvE;AAHS;AAKT,SAAS,gBAAgB,OAAoD;AAC3E,SAAO,gBAAgB,UAAU,CAAC,KAAK,KAAK;AAC9C;AAFS;AAIT,SAAS,YAAoB;AAC3B,UAAO,oBAAI,KAAK,GAAE,YAAY,EAAE,QAAQ,KAAK,GAAG,EAAE,MAAM,GAAG,EAAE;AAC/D;AAFS;","names":[]}
|