prisma-generator-express 1.16.6 → 1.18.0
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 +9 -8
- package/dist/generator.js +8 -129
- package/dist/generator.js.map +1 -1
- package/dist/helpers/generateImportPrismaStatement.js +1 -2
- package/dist/helpers/generateImportPrismaStatement.js.map +1 -1
- package/dist/helpers/generateOperation.js +471 -0
- package/dist/helpers/generateOperation.js.map +1 -0
- package/dist/helpers/generateRouteFile.js +19 -2
- package/dist/helpers/generateRouteFile.js.map +1 -1
- package/dist/utils/strings.js +2 -2
- package/dist/utils/strings.js.map +1 -1
- package/package.json +19 -21
- package/src/copy/createOutputValidatorMiddleware.ts +1 -1
- package/src/copy/createValidatorMiddleware.ts +1 -1
- package/src/copy/misc.ts +1 -1
- package/src/copy/parseQueryParams.ts +1 -1
- package/src/copy/routeConfig.ts +5 -3
- package/src/copy/transformZod.ts +15 -16
- package/src/generator.ts +9 -143
- package/src/helpers/generateOperation.ts +515 -0
- package/src/helpers/generateRouteFile.ts +19 -1
- package/dist/helpers/generateAggregate.js +0 -51
- package/dist/helpers/generateAggregate.js.map +0 -1
- package/dist/helpers/generateCount.js +0 -50
- package/dist/helpers/generateCount.js.map +0 -1
- package/dist/helpers/generateCreate.js +0 -49
- package/dist/helpers/generateCreate.js.map +0 -1
- package/dist/helpers/generateCreateMany.js +0 -49
- package/dist/helpers/generateCreateMany.js.map +0 -1
- package/dist/helpers/generateDelete.js +0 -49
- package/dist/helpers/generateDelete.js.map +0 -1
- package/dist/helpers/generateDeleteMany.js +0 -49
- package/dist/helpers/generateDeleteMany.js.map +0 -1
- package/dist/helpers/generateFindFirst.js +0 -56
- package/dist/helpers/generateFindFirst.js.map +0 -1
- package/dist/helpers/generateFindMany.js +0 -56
- package/dist/helpers/generateFindMany.js.map +0 -1
- package/dist/helpers/generateFindUnique.js +0 -56
- package/dist/helpers/generateFindUnique.js.map +0 -1
- package/dist/helpers/generateGroupBy.js +0 -51
- package/dist/helpers/generateGroupBy.js.map +0 -1
- package/dist/helpers/generateUpdate.js +0 -49
- package/dist/helpers/generateUpdate.js.map +0 -1
- package/dist/helpers/generateUpdateMany.js +0 -49
- package/dist/helpers/generateUpdateMany.js.map +0 -1
- package/dist/helpers/generateUpsert.js +0 -49
- package/dist/helpers/generateUpsert.js.map +0 -1
- package/src/helpers/generateAggregate.ts +0 -59
- package/src/helpers/generateCount.ts +0 -58
- package/src/helpers/generateCreate.ts +0 -56
- package/src/helpers/generateCreateMany.ts +0 -55
- package/src/helpers/generateDelete.ts +0 -57
- package/src/helpers/generateDeleteMany.ts +0 -57
- package/src/helpers/generateFindFirst.ts +0 -62
- package/src/helpers/generateFindMany.ts +0 -62
- package/src/helpers/generateFindUnique.ts +0 -62
- package/src/helpers/generateGroupBy.ts +0 -60
- package/src/helpers/generateUpdate.ts +0 -56
- package/src/helpers/generateUpdateMany.ts +0 -56
- package/src/helpers/generateUpsert.ts +0 -57
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateCreateFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateCreateFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}Create`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}CreateArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core'
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface CreateRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type CreateMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: CreateRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.create(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(201).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(201).json(data);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateCreateFunction = generateCreateFunction;
|
|
49
|
-
//# sourceMappingURL=generateCreate.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateCreate.js","sourceRoot":"","sources":["../../src/helpers/generateCreate.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAQxC,MAAM,sBAAsB,GAAG,CAAC,OAGtC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,QAAQ,CAAA;IACzC,MAAM,YAAY,GAAG,UAAU,SAAS,YAAY,CAAA;IAEpD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;uEAOiD,YAAY;;wBAE3D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,sBAAsB,0BA8ClC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateCreateManyFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateCreateManyFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}CreateMany`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}CreateManyArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface CreateManyRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type CreateManyMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: CreateManyRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.createMany(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(201).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(201).json(data);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateCreateManyFunction = generateCreateManyFunction;
|
|
49
|
-
//# sourceMappingURL=generateCreateMany.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateCreateMany.js","sourceRoot":"","sources":["../../src/helpers/generateCreateMany.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAOxC,MAAM,0BAA0B,GAAG,CAAC,OAG1C,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,YAAY,CAAA;IAC7C,MAAM,YAAY,GAAG,UAAU,SAAS,gBAAgB,CAAA;IAExD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;2EAOqD,YAAY;;wBAE/D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,0BAA0B,8BA8CtC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateDeleteFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateDeleteFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}Delete`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}DeleteArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface DeleteRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type DeleteMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: DeleteRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.delete(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(200).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(200).json(data);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateDeleteFunction = generateDeleteFunction;
|
|
49
|
-
//# sourceMappingURL=generateDelete.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateDelete.js","sourceRoot":"","sources":["../../src/helpers/generateDelete.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AASxC,MAAM,sBAAsB,GAAG,CAAC,OAGtC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,QAAQ,CAAA;IACzC,MAAM,YAAY,GAAG,UAAU,SAAS,YAAY,CAAA;IAEpD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;uEAOiD,YAAY;;wBAE3D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,sBAAsB,0BA8ClC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateDeleteManyFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateDeleteManyFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}DeleteMany`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}DeleteManyArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface DeleteManyRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type DeleteManyMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>;
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: DeleteManyRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const result = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.deleteMany(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(result);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(200).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(200).json(result);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateDeleteManyFunction = generateDeleteManyFunction;
|
|
49
|
-
//# sourceMappingURL=generateDeleteMany.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateDeleteMany.js","sourceRoot":"","sources":["../../src/helpers/generateDeleteMany.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AASxC,MAAM,0BAA0B,GAAG,CAAC,OAG1C,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,YAAY,CAAA;IAC7C,MAAM,YAAY,GAAG,UAAU,SAAS,gBAAgB,CAAA;IAExD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;2EAOqD,YAAY;;wBAE/D,YAAY;;;;sCAIE,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAe3D,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,0BAA0B,8BA8CtC"}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateFindFirstFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateFindFirstFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}FindFirst`;
|
|
9
|
-
const queryTypeName = `Prisma.${modelName}FindFirstArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement.replace('{ Prisma }', `{ Prisma, ${modelName} }`)}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express'
|
|
13
|
-
import {
|
|
14
|
-
RequestHandler,
|
|
15
|
-
ParamsDictionary,
|
|
16
|
-
} from 'express-serve-static-core'
|
|
17
|
-
import { ParsedQs } from 'qs';
|
|
18
|
-
import { ZodTypeAny } from 'zod';
|
|
19
|
-
|
|
20
|
-
export interface FindFirstRequest extends Request {
|
|
21
|
-
prisma: PrismaClient;
|
|
22
|
-
query: ${queryTypeName} & ParsedQs;
|
|
23
|
-
outputValidation?: ZodTypeAny;
|
|
24
|
-
passToNext?: boolean;
|
|
25
|
-
locals?: {
|
|
26
|
-
data?: ${modelName} | null
|
|
27
|
-
outputValidator?: ZodTypeAny;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
export type FindFirstMiddleware = RequestHandler<ParamsDictionary, any, any, ${queryTypeName} & ParsedQs, Record<string, any>>
|
|
31
|
-
|
|
32
|
-
export async function ${functionName}(req: FindFirstRequest, res: Response, next: NextFunction) {
|
|
33
|
-
try {
|
|
34
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
35
|
-
|
|
36
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.findFirst(req.query as ${queryTypeName});
|
|
37
|
-
if (req.passToNext) {
|
|
38
|
-
if (req.locals) req.locals.data = data;
|
|
39
|
-
next();
|
|
40
|
-
} else if (outputValidator) {
|
|
41
|
-
const validationResult = outputValidator.safeParse(data);
|
|
42
|
-
if (validationResult.success) {
|
|
43
|
-
return res.status(200).json(validationResult.data);
|
|
44
|
-
} else {
|
|
45
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
46
|
-
}
|
|
47
|
-
} else {
|
|
48
|
-
return res.status(200).json(data);
|
|
49
|
-
}
|
|
50
|
-
} catch(error: unknown) {
|
|
51
|
-
next(error)
|
|
52
|
-
}
|
|
53
|
-
}`;
|
|
54
|
-
};
|
|
55
|
-
exports.generateFindFirstFunction = generateFindFirstFunction;
|
|
56
|
-
//# sourceMappingURL=generateFindFirst.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateFindFirst.js","sourceRoot":"","sources":["../../src/helpers/generateFindFirst.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAOxC,MAAM,yBAAyB,GAAG,CAAC,OAGzC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,WAAW,CAAA;IAC5C,MAAM,aAAa,GAAG,UAAU,SAAS,eAAe,CAAA;IAExD,OAAO;EACP,qBAAqB,CAAC,OAAO,CAAC,YAAY,EAAE,aAAa,SAAS,IAAI,CAAC;;;;;;;;;;;WAW9D,aAAa;;;;aAIX,SAAS;;;;+EAIyD,aAAa;;wBAEpE,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC,2BAA2B,aAAa;;;;;;;;;;;;;;;;;EAiBjG,CAAA;AACF,CAAC,CAAA;AArDY,QAAA,yBAAyB,6BAqDrC"}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateFindManyFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateFindManyFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}FindMany`;
|
|
9
|
-
const queryTypeName = `Prisma.${modelName}FindManyArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement.replace('{ Prisma }', `{ Prisma, ${modelName} }`)}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express'
|
|
13
|
-
import {
|
|
14
|
-
RequestHandler,
|
|
15
|
-
ParamsDictionary,
|
|
16
|
-
} from 'express-serve-static-core'
|
|
17
|
-
import { ParsedQs } from 'qs';
|
|
18
|
-
import { ZodTypeAny } from 'zod';
|
|
19
|
-
|
|
20
|
-
export interface FindManyRequest extends Request {
|
|
21
|
-
prisma: PrismaClient;
|
|
22
|
-
query: ${queryTypeName} & ParsedQs;
|
|
23
|
-
outputValidation?: ZodTypeAny;
|
|
24
|
-
passToNext?: boolean;
|
|
25
|
-
locals?: {
|
|
26
|
-
data?: ${modelName}[]
|
|
27
|
-
outputValidator?: ZodTypeAny;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
export type FindManyMiddleware = RequestHandler<ParamsDictionary, any, any, ${queryTypeName} & ParsedQs, Record<string, any>>
|
|
31
|
-
|
|
32
|
-
export async function ${functionName}(req: FindManyRequest, res: Response, next: NextFunction) {
|
|
33
|
-
try {
|
|
34
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
35
|
-
|
|
36
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.findMany(req.query as ${queryTypeName});
|
|
37
|
-
if (req.passToNext) {
|
|
38
|
-
if (req.locals) req.locals.data = data;
|
|
39
|
-
next();
|
|
40
|
-
} else if (outputValidator) {
|
|
41
|
-
const validationResult = outputValidator.safeParse(data);
|
|
42
|
-
if (validationResult.success) {
|
|
43
|
-
return res.status(200).json(validationResult.data);
|
|
44
|
-
} else {
|
|
45
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
46
|
-
}
|
|
47
|
-
} else {
|
|
48
|
-
return res.status(200).json(data);
|
|
49
|
-
}
|
|
50
|
-
} catch(error: unknown) {
|
|
51
|
-
next(error)
|
|
52
|
-
}
|
|
53
|
-
}`;
|
|
54
|
-
};
|
|
55
|
-
exports.generateFindManyFunction = generateFindManyFunction;
|
|
56
|
-
//# sourceMappingURL=generateFindMany.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateFindMany.js","sourceRoot":"","sources":["../../src/helpers/generateFindMany.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAOxC,MAAM,wBAAwB,GAAG,CAAC,OAGxC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,UAAU,CAAA;IAC3C,MAAM,aAAa,GAAG,UAAU,SAAS,cAAc,CAAA;IAEvD,OAAO;EACP,qBAAqB,CAAC,OAAO,CAAC,YAAY,EAAE,aAAa,SAAS,IAAI,CAAC;;;;;;;;;;;WAW9D,aAAa;;;;aAIX,SAAS;;;;8EAIwD,aAAa;;wBAEnE,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC,0BAA0B,aAAa;;;;;;;;;;;;;;;;;EAiBhG,CAAA;AACF,CAAC,CAAA;AArDY,QAAA,wBAAwB,4BAqDpC"}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateFindUniqueFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateFindUniqueFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}FindUnique`;
|
|
9
|
-
const queryTypeName = `Prisma.${modelName}FindUniqueArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement.replace('{ Prisma }', `{ Prisma, ${modelName} }`)}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express'
|
|
13
|
-
import {
|
|
14
|
-
RequestHandler,
|
|
15
|
-
ParamsDictionary,
|
|
16
|
-
} from 'express-serve-static-core'
|
|
17
|
-
import { ParsedQs } from 'qs';
|
|
18
|
-
import { ZodTypeAny } from 'zod';
|
|
19
|
-
|
|
20
|
-
export interface FindUniqueRequest extends Request {
|
|
21
|
-
prisma: PrismaClient;
|
|
22
|
-
query: ${queryTypeName} & ParsedQs;
|
|
23
|
-
outputValidation?: ZodTypeAny;
|
|
24
|
-
passToNext?: boolean;
|
|
25
|
-
locals?: {
|
|
26
|
-
data?: ${modelName} | null
|
|
27
|
-
outputValidator?: ZodTypeAny;
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
export type FindUniqueMiddleware = RequestHandler<ParamsDictionary, any, any, ${queryTypeName} & ParsedQs, Record<string, any>>
|
|
31
|
-
|
|
32
|
-
export async function ${functionName}(req: FindUniqueRequest, res: Response, next: NextFunction) {
|
|
33
|
-
try {
|
|
34
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
35
|
-
|
|
36
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.findUnique(req.query as ${queryTypeName});
|
|
37
|
-
if (req.passToNext) {
|
|
38
|
-
if (req.locals) req.locals.data = data;
|
|
39
|
-
next();
|
|
40
|
-
} else if (outputValidator) {
|
|
41
|
-
const validationResult = outputValidator.safeParse(data);
|
|
42
|
-
if (validationResult.success) {
|
|
43
|
-
return res.status(200).json(validationResult.data);
|
|
44
|
-
} else {
|
|
45
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
46
|
-
}
|
|
47
|
-
} else {
|
|
48
|
-
return res.status(200).json(data);
|
|
49
|
-
}
|
|
50
|
-
} catch(error: unknown) {
|
|
51
|
-
next(error)
|
|
52
|
-
}
|
|
53
|
-
}`;
|
|
54
|
-
};
|
|
55
|
-
exports.generateFindUniqueFunction = generateFindUniqueFunction;
|
|
56
|
-
//# sourceMappingURL=generateFindUnique.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateFindUnique.js","sourceRoot":"","sources":["../../src/helpers/generateFindUnique.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAOxC,MAAM,0BAA0B,GAAG,CAAC,OAG1C,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,YAAY,CAAA;IAC7C,MAAM,aAAa,GAAG,UAAU,SAAS,gBAAgB,CAAA;IAEzD,OAAO;EACP,qBAAqB,CAAC,OAAO,CAAC,YAAY,EAAE,aAAa,SAAS,IAAI,CAAC;;;;;;;;;;;WAW9D,aAAa;;;;aAIX,SAAS;;;;gFAI0D,aAAa;;wBAErE,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC,4BAA4B,aAAa;;;;;;;;;;;;;;;;;EAiBlG,CAAA;AACF,CAAC,CAAA;AArDY,QAAA,0BAA0B,8BAqDtC"}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateGroupByFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateGroupByFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}GroupBy`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}GroupByArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ParsedQs } from 'qs';
|
|
15
|
-
import { ZodTypeAny } from 'zod';
|
|
16
|
-
|
|
17
|
-
interface GroupByRequest extends Request {
|
|
18
|
-
prisma: PrismaClient;
|
|
19
|
-
query: Partial<${argsTypeName}> & ParsedQs;
|
|
20
|
-
outputValidation?: ZodTypeAny;
|
|
21
|
-
locals?: {
|
|
22
|
-
outputValidator?: ZodTypeAny;
|
|
23
|
-
};
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
export type GroupByMiddleware = RequestHandler<ParamsDictionary, any, {}, ParsedQs>;
|
|
27
|
-
|
|
28
|
-
export async function ${functionName}(req: GroupByRequest, res: Response, next: NextFunction) {
|
|
29
|
-
try {
|
|
30
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
31
|
-
|
|
32
|
-
// @ts-ignore
|
|
33
|
-
const result = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.groupBy(req.query);
|
|
34
|
-
|
|
35
|
-
if (outputValidator) {
|
|
36
|
-
const validationResult = outputValidator.safeParse(result);
|
|
37
|
-
if (validationResult.success) {
|
|
38
|
-
return res.status(200).json(validationResult.data);
|
|
39
|
-
} else {
|
|
40
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
41
|
-
}
|
|
42
|
-
} else {
|
|
43
|
-
return res.status(200).json(result);
|
|
44
|
-
}
|
|
45
|
-
} catch(error: unknown) {
|
|
46
|
-
next(error)
|
|
47
|
-
}
|
|
48
|
-
}`;
|
|
49
|
-
};
|
|
50
|
-
exports.generateGroupByFunction = generateGroupByFunction;
|
|
51
|
-
//# sourceMappingURL=generateGroupBy.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateGroupBy.js","sourceRoot":"","sources":["../../src/helpers/generateGroupBy.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAUxC,MAAM,uBAAuB,GAAG,CAAC,OAGvC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,SAAS,CAAA;IAC1C,MAAM,YAAY,GAAG,UAAU,SAAS,aAAa,CAAA;IAErD,OAAO;EACP,qBAAqB;;;;;;;;mBAQJ,YAAY;;;;;;;;;wBASP,YAAY;;;;;sCAKE,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAe3D,CAAA;AACF,CAAC,CAAA;AAhDY,QAAA,uBAAuB,2BAgDnC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateUpdateFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateUpdateFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}Update`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}UpdateArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface UpdateRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type UpdateMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: UpdateRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.update(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(200).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(200).json(data);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateUpdateFunction = generateUpdateFunction;
|
|
49
|
-
//# sourceMappingURL=generateUpdate.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateUpdate.js","sourceRoot":"","sources":["../../src/helpers/generateUpdate.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAQxC,MAAM,sBAAsB,GAAG,CAAC,OAGtC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,QAAQ,CAAA;IACzC,MAAM,YAAY,GAAG,UAAU,SAAS,YAAY,CAAA;IAEpD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;uEAOiD,YAAY;;wBAE3D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,sBAAsB,0BA8ClC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateUpdateManyFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateUpdateManyFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}UpdateMany`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}UpdateManyArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface UpdateManyRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type UpdateManyMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: UpdateManyRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.updateMany(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(200).json({ count: validationResult.data.count });
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(200).json({ count: data.count });
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateUpdateManyFunction = generateUpdateManyFunction;
|
|
49
|
-
//# sourceMappingURL=generateUpdateMany.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateUpdateMany.js","sourceRoot":"","sources":["../../src/helpers/generateUpdateMany.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AAQxC,MAAM,0BAA0B,GAAG,CAAC,OAG1C,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,YAAY,CAAA;IAC7C,MAAM,YAAY,GAAG,UAAU,SAAS,gBAAgB,CAAA;IAExD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;2EAOqD,YAAY;;wBAE/D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,0BAA0B,8BA8CtC"}
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.generateUpsertFunction = void 0;
|
|
4
|
-
const strings_1 = require("../utils/strings");
|
|
5
|
-
const generateUpsertFunction = (options) => {
|
|
6
|
-
const { model, prismaImportStatement } = options;
|
|
7
|
-
const modelName = model.name;
|
|
8
|
-
const functionName = `${modelName}Upsert`;
|
|
9
|
-
const argsTypeName = `Prisma.${modelName}UpsertArgs`;
|
|
10
|
-
return `
|
|
11
|
-
${prismaImportStatement}
|
|
12
|
-
import { Request, Response, NextFunction } from 'express';
|
|
13
|
-
import { RequestHandler, ParamsDictionary } from 'express-serve-static-core';
|
|
14
|
-
import { ZodTypeAny } from 'zod';
|
|
15
|
-
|
|
16
|
-
interface UpsertRequest extends Request {
|
|
17
|
-
prisma: PrismaClient;
|
|
18
|
-
body: ${argsTypeName};
|
|
19
|
-
outputValidation?: ZodTypeAny;
|
|
20
|
-
locals?: {
|
|
21
|
-
outputValidator?: ZodTypeAny;
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export type UpsertMiddleware = RequestHandler<ParamsDictionary, any, ${argsTypeName}, Record<string, any>>
|
|
26
|
-
|
|
27
|
-
export async function ${functionName}(req: UpsertRequest, res: Response, next: NextFunction) {
|
|
28
|
-
try {
|
|
29
|
-
const outputValidator = req.locals?.outputValidator || req.outputValidation;
|
|
30
|
-
|
|
31
|
-
const data = await req.prisma.${(0, strings_1.toPascalCase)(modelName)}.upsert(req.body);
|
|
32
|
-
|
|
33
|
-
if (outputValidator) {
|
|
34
|
-
const validationResult = outputValidator.safeParse(data);
|
|
35
|
-
if (validationResult.success) {
|
|
36
|
-
return res.status(200).json(validationResult.data);
|
|
37
|
-
} else {
|
|
38
|
-
return res.status(400).json({ error: 'Invalid data format', details: validationResult.error });
|
|
39
|
-
}
|
|
40
|
-
} else {
|
|
41
|
-
return res.status(200).json(data);
|
|
42
|
-
}
|
|
43
|
-
} catch(error: unknown) {
|
|
44
|
-
next(error)
|
|
45
|
-
}
|
|
46
|
-
}`;
|
|
47
|
-
};
|
|
48
|
-
exports.generateUpsertFunction = generateUpsertFunction;
|
|
49
|
-
//# sourceMappingURL=generateUpsert.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"generateUpsert.js","sourceRoot":"","sources":["../../src/helpers/generateUpsert.ts"],"names":[],"mappings":";;;AACA,8CAA+C;AASxC,MAAM,sBAAsB,GAAG,CAAC,OAGtC,EAAU,EAAE;IACX,MAAM,EAAE,KAAK,EAAE,qBAAqB,EAAE,GAAG,OAAO,CAAA;IAChD,MAAM,SAAS,GAAG,KAAK,CAAC,IAAI,CAAA;IAC5B,MAAM,YAAY,GAAG,GAAG,SAAS,QAAQ,CAAA;IACzC,MAAM,YAAY,GAAG,UAAU,SAAS,YAAY,CAAA;IAEpD,OAAO;EACP,qBAAqB;;;;;;;UAOb,YAAY;;;;;;;uEAOiD,YAAY;;wBAE3D,YAAY;;;;oCAIA,IAAA,sBAAY,EAAC,SAAS,CAAC;;;;;;;;;;;;;;;EAezD,CAAA;AACF,CAAC,CAAA;AA9CY,QAAA,sBAAsB,0BA8ClC"}
|