@intlayer/backend 5.3.8 → 5.3.10
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/dist/cjs/controllers/dictionary.controller.cjs +6 -3
- package/dist/cjs/controllers/dictionary.controller.cjs.map +1 -1
- package/dist/cjs/controllers/project.controller.cjs +1 -8
- package/dist/cjs/controllers/project.controller.cjs.map +1 -1
- package/dist/cjs/utils/AI/askDocQuestion/embeddings.json +3070 -0
- package/dist/cjs/utils/filtersAndPagination/getDictionaryFiltersAndPagination.cjs +59 -1
- package/dist/cjs/utils/filtersAndPagination/getDictionaryFiltersAndPagination.cjs.map +1 -1
- package/dist/esm/controllers/dictionary.controller.mjs +6 -3
- package/dist/esm/controllers/dictionary.controller.mjs.map +1 -1
- package/dist/esm/controllers/project.controller.mjs +1 -8
- package/dist/esm/controllers/project.controller.mjs.map +1 -1
- package/dist/esm/utils/AI/askDocQuestion/embeddings.json +3070 -0
- package/dist/esm/utils/filtersAndPagination/getDictionaryFiltersAndPagination.mjs +59 -1
- package/dist/esm/utils/filtersAndPagination/getDictionaryFiltersAndPagination.mjs.map +1 -1
- package/dist/types/controllers/dictionary.controller.d.ts +2 -2
- package/dist/types/controllers/dictionary.controller.d.ts.map +1 -1
- package/dist/types/controllers/project.controller.d.ts +2 -2
- package/dist/types/controllers/project.controller.d.ts.map +1 -1
- package/dist/types/utils/filtersAndPagination/getDictionaryFiltersAndPagination.d.ts +11 -1
- package/dist/types/utils/filtersAndPagination/getDictionaryFiltersAndPagination.d.ts.map +1 -1
- package/package.json +31 -31
|
@@ -6,11 +6,69 @@ const getDictionaryFiltersAndPagination = (req) => {
|
|
|
6
6
|
const { filters: filtersRequest, ...pagination } = getFiltersAndPaginationFromBody(req);
|
|
7
7
|
let filters = {};
|
|
8
8
|
if (Object.keys(filtersRequest).length > 0) {
|
|
9
|
-
const {
|
|
9
|
+
const {
|
|
10
|
+
key,
|
|
11
|
+
keys,
|
|
12
|
+
tags,
|
|
13
|
+
ids,
|
|
14
|
+
projectId,
|
|
15
|
+
projectIds,
|
|
16
|
+
organizationId,
|
|
17
|
+
organizationIds,
|
|
18
|
+
userId,
|
|
19
|
+
userIds,
|
|
20
|
+
creatorId,
|
|
21
|
+
creatorIds,
|
|
22
|
+
title,
|
|
23
|
+
description,
|
|
24
|
+
version
|
|
25
|
+
} = filtersRequest;
|
|
10
26
|
filters = {};
|
|
11
27
|
if (ids) {
|
|
12
28
|
filters = { ...filters, _id: { $in: ensureArrayQueryFilter(ids) } };
|
|
13
29
|
}
|
|
30
|
+
if (projectId) {
|
|
31
|
+
filters = { ...filters, projectIds: projectId };
|
|
32
|
+
}
|
|
33
|
+
if (projectIds) {
|
|
34
|
+
filters = {
|
|
35
|
+
...filters,
|
|
36
|
+
projectIds: { $in: ensureArrayQueryFilter(projectIds) }
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
if (organizationId) {
|
|
40
|
+
filters = { ...filters, organizationIds: organizationId };
|
|
41
|
+
}
|
|
42
|
+
if (organizationIds) {
|
|
43
|
+
filters = {
|
|
44
|
+
...filters,
|
|
45
|
+
organizationIds: { $in: ensureArrayQueryFilter(organizationIds) }
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
if (userId) {
|
|
49
|
+
filters = { ...filters, creatorId: userId };
|
|
50
|
+
}
|
|
51
|
+
if (userIds) {
|
|
52
|
+
filters = {
|
|
53
|
+
...filters,
|
|
54
|
+
creatorId: { $in: ensureArrayQueryFilter(userIds) }
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
if (creatorId) {
|
|
58
|
+
filters = { ...filters, creatorId };
|
|
59
|
+
}
|
|
60
|
+
if (creatorIds) {
|
|
61
|
+
filters = {
|
|
62
|
+
...filters,
|
|
63
|
+
creatorId: { $in: ensureArrayQueryFilter(creatorIds) }
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
if (title) {
|
|
67
|
+
filters = { ...filters, title: new RegExp(title, "i") };
|
|
68
|
+
}
|
|
69
|
+
if (description) {
|
|
70
|
+
filters = { ...filters, description: new RegExp(description, "i") };
|
|
71
|
+
}
|
|
14
72
|
if (key) {
|
|
15
73
|
filters = { ...filters, key: new RegExp(key, "i") };
|
|
16
74
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/utils/filtersAndPagination/getDictionaryFiltersAndPagination.ts"],"sourcesContent":["import { ensureArrayQueryFilter } from '@utils/ensureArrayQueryFilter';\nimport type { Request } from 'express';\nimport type { RootFilterQuery } from 'mongoose';\nimport {\n type FiltersAndPagination,\n getFiltersAndPaginationFromBody,\n} from './getFiltersAndPaginationFromBody';\
|
|
1
|
+
{"version":3,"sources":["../../../../src/utils/filtersAndPagination/getDictionaryFiltersAndPagination.ts"],"sourcesContent":["import type { Dictionary } from '@/types/dictionary.types';\nimport { ensureArrayQueryFilter } from '@utils/ensureArrayQueryFilter';\nimport type { Request } from 'express';\nimport type { RootFilterQuery } from 'mongoose';\nimport {\n type FiltersAndPagination,\n getFiltersAndPaginationFromBody,\n} from './getFiltersAndPaginationFromBody';\n\nexport type DictionaryFiltersParams = {\n ids?: string | string[];\n projectId?: string;\n projectIds?: string[];\n organizationId?: string;\n organizationIds?: string[];\n userId?: string;\n userIds?: string[];\n creatorId?: string;\n creatorIds?: string[];\n title?: string;\n description?: string;\n key?: string;\n keys?: string[];\n tags?: string | string[];\n version?: string;\n};\nexport type DictionaryFilters = RootFilterQuery<Dictionary>;\n\n/**\n * Extracts filters and pagination information from the request body.\n * @param req - Express request object.\n * @returns Object containing filters, page, pageSize, and getNumberOfPages functions.\n */\nexport const getDictionaryFiltersAndPagination = (\n req: Request<FiltersAndPagination<DictionaryFiltersParams>>\n) => {\n const { filters: filtersRequest, ...pagination } =\n getFiltersAndPaginationFromBody<DictionaryFiltersParams>(req);\n\n let filters: DictionaryFilters = {};\n\n if (Object.keys(filtersRequest).length > 0) {\n const {\n key,\n keys,\n tags,\n ids,\n projectId,\n projectIds,\n organizationId,\n organizationIds,\n userId,\n userIds,\n creatorId,\n creatorIds,\n title,\n description,\n version,\n } = filtersRequest;\n\n filters = {};\n\n if (ids) {\n filters = { ...filters, _id: { $in: ensureArrayQueryFilter(ids) } };\n }\n\n if (projectId) {\n filters = { ...filters, projectIds: projectId };\n }\n\n if (projectIds) {\n filters = {\n ...filters,\n projectIds: { $in: ensureArrayQueryFilter(projectIds) },\n };\n }\n\n if (organizationId) {\n filters = { ...filters, organizationIds: organizationId };\n }\n\n if (organizationIds) {\n filters = {\n ...filters,\n organizationIds: { $in: ensureArrayQueryFilter(organizationIds) },\n };\n }\n\n if (userId) {\n filters = { ...filters, creatorId: userId };\n }\n\n if (userIds) {\n filters = {\n ...filters,\n creatorId: { $in: ensureArrayQueryFilter(userIds) },\n };\n }\n\n if (creatorId) {\n filters = { ...filters, creatorId: creatorId };\n }\n\n if (creatorIds) {\n filters = {\n ...filters,\n creatorId: { $in: ensureArrayQueryFilter(creatorIds) },\n };\n }\n\n if (title) {\n filters = { ...filters, title: new RegExp(title, 'i') };\n }\n\n if (description) {\n filters = { ...filters, description: new RegExp(description, 'i') };\n }\n\n if (key) {\n filters = { ...filters, key: new RegExp(key, 'i') };\n }\n\n if (keys) {\n filters = { ...filters, key: { $in: ensureArrayQueryFilter(keys) } };\n }\n\n if (tags) {\n filters = { ...filters, tags: { $in: ensureArrayQueryFilter(tags) } };\n }\n\n if (version) {\n filters = { ...filters, content: { [version]: `$content.${version}` } };\n }\n }\n\n return { filters, ...pagination };\n};\n"],"mappings":"AACA,SAAS,8BAA8B;AAGvC;AAAA,EAEE;AAAA,OACK;AA0BA,MAAM,oCAAoC,CAC/C,QACG;AACH,QAAM,EAAE,SAAS,gBAAgB,GAAG,WAAW,IAC7C,gCAAyD,GAAG;AAE9D,MAAI,UAA6B,CAAC;AAElC,MAAI,OAAO,KAAK,cAAc,EAAE,SAAS,GAAG;AAC1C,UAAM;AAAA,MACJ;AAAA,MACA;AAAA,MACA;AAA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ACpE;AAEA,QAAI,KAAK;AACP,gBAAU,EAAE,GAAG,SAAS,KAAK,IAAI,OAAO,KAAK,GAAG,EAAE;AAAA,IACpD;AAEA,QAAI,MAAM;AACR,gBAAU,EAAE,GAAG,SAAS,KAAK,EAAE,KAAK,uBAAuB,IAAI,EAAE,EAAE;AAAA,IACrE;AAEA,QAAI,MAAM;AACR,gBAAU,EAAE,GAAG,SAAS,MAAM,EAAE,KAAK,uBAAuB,IAAI,EAAE,EAAE;AAAA,IACtE;AAEA,QAAI,SAAS;AACX,gBAAU,EAAE,GAAG,SAAS,SAAS,EAAE,CAAC,OAAO,GAAG,YAAY,OAAO,GAAG,EAAE;AAAA,IACxE;AAAA,EACF;AAEA,SAAO,EAAE,SAAS,GAAG,WAAW;AAClC;","names":[]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import type { Dictionary, DictionaryAPI, DictionaryCreationData } from '../types/dictionary.types';
|
|
1
2
|
import type { Dictionary as LocalDictionary } from '@intlayer/core';
|
|
2
3
|
import type { ResponseWithInformation } from '../middlewares/sessionAuth.middleware';
|
|
3
4
|
import { type DictionaryFiltersParams } from '../utils/filtersAndPagination/getDictionaryFiltersAndPagination';
|
|
4
5
|
import type { FiltersAndPagination } from '../utils/filtersAndPagination/getFiltersAndPaginationFromBody';
|
|
5
|
-
import { type
|
|
6
|
+
import { type PaginatedResponse, type ResponseData } from '../utils/responseData';
|
|
6
7
|
import type { NextFunction, Request } from 'express';
|
|
7
|
-
import type { Dictionary, DictionaryAPI, DictionaryCreationData } from '../types/dictionary.types';
|
|
8
8
|
export type GetDictionariesParams = FiltersAndPagination<DictionaryFiltersParams>;
|
|
9
9
|
export type GetDictionariesResult = PaginatedResponse<DictionaryAPI>;
|
|
10
10
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dictionary.controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/dictionary.controller.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,UAAU,IAAI,eAAe,EAC9B,MAAM,gBAAgB,CAAC;AAExB,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAInF,OAAO,EACL,KAAK,uBAAuB,EAE7B,MAAM,+DAA+D,CAAC;AACvE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6DAA6D,CAAC;AAExG,OAAO,
|
|
1
|
+
{"version":3,"file":"dictionary.controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/dictionary.controller.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,aAAa,EACb,sBAAsB,EAGvB,MAAM,0BAA0B,CAAC;AAElC,OAAO,KAAK,EAEV,UAAU,IAAI,eAAe,EAC9B,MAAM,gBAAgB,CAAC;AAExB,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAInF,OAAO,EACL,KAAK,uBAAuB,EAE7B,MAAM,+DAA+D,CAAC;AACvE,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6DAA6D,CAAC;AAExG,OAAO,EAGL,KAAK,iBAAiB,EACtB,KAAK,YAAY,EAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAGrD,MAAM,MAAM,qBAAqB,GAC/B,oBAAoB,CAAC,uBAAuB,CAAC,CAAC;AAChD,MAAM,MAAM,qBAAqB,GAAG,iBAAiB,CAAC,aAAa,CAAC,CAAC;AAErE;;GAEG;AACH,eAAO,MAAM,eAAe,GAC1B,KAAK,OAAO,CAAC,qBAAqB,CAAC,EACnC,KAAK,uBAAuB,CAAC,qBAAqB,CAAC,EACnD,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CA+Cd,CAAC;AAEF,MAAM,MAAM,yBAAyB,GAAG,YAAY,CAAC,MAAM,EAAE,CAAC,CAAC;AAE/D;;GAEG;AACH,eAAO,MAAM,mBAAmB,GAC9B,MAAM,OAAO,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AM,gBAAgB,GAC3B,KAAK,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,oBAAoB,CAAC,EAC5C,KAAK,uBAAuB,CAAC,sBAAsB,CAAC,EACpD,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAkMd,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAAE,YAAY,EAAE,MAAM,CAAA;CAAE,CAAC;AAC7D,MAAM,MAAM,oBAAoB,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;AACvD,MAAM,MAAM,sBAAsB,GAAG,YAAY,CAAC,aAAa,CAAC,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,gBAAgB,GAC3B,KAAK,OAAO,CAAC,qBAAqB,EAAE,GAAG,EAAE,oBAAoB,CAAC,EAC9D,KAAK,uBAAuB,CAAC,sBAAsB,CAAC,EACpD,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAiEd,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAAE,YAAY,EAAE,MAAM,CAAA;CAAE,CAAC;AAC7D,MAAM,MAAM,sBAAsB,GAAG,YAAY,CAAC,aAAa,CAAC,CAAC;AAEjE;;GAEG;AACH,eAAO,MAAM,gBAAgB,GAC3B,KAAK,OAAO,CAAC,qBAAqB,CAAC,EACnC,KAAK,uBAAuB,CAAC,sBAAsB,CAAC,EACpD,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAyEd,CAAC"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import type { Project, ProjectAPI, ProjectConfiguration, ProjectCreationData } from '../types/project.types';
|
|
1
2
|
import type { ResponseWithInformation } from '../middlewares/sessionAuth.middleware';
|
|
2
3
|
import type { FiltersAndPagination } from '../utils/filtersAndPagination/getFiltersAndPaginationFromBody';
|
|
3
4
|
import { type ProjectFiltersParams } from '../utils/filtersAndPagination/getProjectFiltersAndPagination';
|
|
4
|
-
import { type
|
|
5
|
+
import { type PaginatedResponse, type ResponseData } from '../utils/responseData';
|
|
5
6
|
import type { NextFunction, Request } from 'express';
|
|
6
7
|
import type { ObjectId } from 'mongoose';
|
|
7
|
-
import type { Project, ProjectAPI, ProjectCreationData, ProjectConfiguration } from '../types/project.types';
|
|
8
8
|
export type GetProjectsParams = FiltersAndPagination<ProjectFiltersParams>;
|
|
9
9
|
export type GetProjectsResult = PaginatedResponse<ProjectAPI>;
|
|
10
10
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/project.controller.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"project.controller.d.ts","sourceRoot":"","sources":["../../../src/controllers/project.controller.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,OAAO,EACP,UAAU,EACV,oBAAoB,EACpB,mBAAmB,EAEpB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAC;AAKnF,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,6DAA6D,CAAC;AACxG,OAAO,EAGL,KAAK,oBAAoB,EAC1B,MAAM,4DAA4D,CAAC;AAGpE,OAAO,EAGL,KAAK,iBAAiB,EACtB,KAAK,YAAY,EAClB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAErD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,UAAU,CAAC;AAGzC,MAAM,MAAM,iBAAiB,GAAG,oBAAoB,CAAC,oBAAoB,CAAC,CAAC;AAC3E,MAAM,MAAM,iBAAiB,GAAG,iBAAiB,CAAC,UAAU,CAAC,CAAC;AAE9D;;GAEG;AACH,eAAO,MAAM,WAAW,GACtB,KAAK,OAAO,CAAC,iBAAiB,CAAC,EAC/B,KAAK,uBAAuB,CAAC,iBAAiB,CAAC,EAC/C,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CAsDd,CAAC;AA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GAKG;AACH,eAAO,MAAM,wBAAwB,GACnC,KAAK,OAAO,CAAC,GAAG,EAAE,GAAG,EAAE,4BAA4B,CAAC,EACpD,KAAK,uBAAuB,CAAC,8BAA8B,CAAC,EAC5D,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CA+Cd,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG,YAAY,CAAC,UAAU,CAAC,CAAC;AAE3D;;;;;GAKG;AACH,eAAO,MAAM,aAAa,GACxB,MAAM,OAAO,EACb,KAAK,uBAAuB,CAAC,mBAAmB,CAAC,EACjD,OAAO,YAAY,KAClB,OAAO,CAAC,IAAI,CA2Ed,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAAE,SAAS,EAAE,QAAQ,GAAG,MAAM,CAAA;CAAE,CAAC;AAClE,MAAM,MAAM,mBAAmB,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;AAExD;;GAEG;AACH,eAAO,MAAM,aAAa,GACxB,KAAK,OAAO,CAAC,kBAAkB,CAAC,EAChC,KAAK,uBAAuB,CAAC,mBAAmB,CAAC,EACjD,OAAO,YAAY,kBAkCpB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,YAAY,CAAC,IAAI,CAAC,CAAC;AAEvD;;GAEG;AACH,eAAO,MAAM,eAAe,GAC1B,MAAM,OAAO,EACb,KAAK,uBAAuB,CAAC,qBAAqB,CAAC,EACnD,OAAO,YAAY,SAyBpB,CAAC"}
|
|
@@ -1,9 +1,19 @@
|
|
|
1
|
+
import type { Dictionary } from '../../types/dictionary.types';
|
|
1
2
|
import type { Request } from 'express';
|
|
2
3
|
import type { RootFilterQuery } from 'mongoose';
|
|
3
4
|
import { type FiltersAndPagination } from './getFiltersAndPaginationFromBody';
|
|
4
|
-
import type { Dictionary } from '../../types/dictionary.types';
|
|
5
5
|
export type DictionaryFiltersParams = {
|
|
6
6
|
ids?: string | string[];
|
|
7
|
+
projectId?: string;
|
|
8
|
+
projectIds?: string[];
|
|
9
|
+
organizationId?: string;
|
|
10
|
+
organizationIds?: string[];
|
|
11
|
+
userId?: string;
|
|
12
|
+
userIds?: string[];
|
|
13
|
+
creatorId?: string;
|
|
14
|
+
creatorIds?: string[];
|
|
15
|
+
title?: string;
|
|
16
|
+
description?: string;
|
|
7
17
|
key?: string;
|
|
8
18
|
keys?: string[];
|
|
9
19
|
tags?: string | string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getDictionaryFiltersAndPagination.d.ts","sourceRoot":"","sources":["../../../../src/utils/filtersAndPagination/getDictionaryFiltersAndPagination.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getDictionaryFiltersAndPagination.d.ts","sourceRoot":"","sources":["../../../../src/utils/filtersAndPagination/getDictionaryFiltersAndPagination.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAE3D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAChD,OAAO,EACL,KAAK,oBAAoB,EAE1B,MAAM,mCAAmC,CAAC;AAE3C,MAAM,MAAM,uBAAuB,GAAG;IACpC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AACF,MAAM,MAAM,iBAAiB,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;AAE5D;;;;GAIG;AACH,eAAO,MAAM,iCAAiC,GAC5C,KAAK,OAAO,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,CAAC;;;;;;CAsG5D,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intlayer/backend",
|
|
3
|
-
"version": "5.3.
|
|
3
|
+
"version": "5.3.10",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Intlayer Backend is a an application that allow you to manage your Intlayer content and interact with the intlayer editor.",
|
|
6
6
|
"keywords": [
|
|
@@ -50,10 +50,10 @@
|
|
|
50
50
|
"./package.json"
|
|
51
51
|
],
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@react-email/components": "^0.0.
|
|
54
|
-
"@types/node": "^22.10
|
|
53
|
+
"@react-email/components": "^0.0.34",
|
|
54
|
+
"@types/node": "^22.13.10",
|
|
55
55
|
"bcrypt": "^5.1.1",
|
|
56
|
-
"compression": "^1.
|
|
56
|
+
"compression": "^1.8.0",
|
|
57
57
|
"cookie-parser": "^1.4.7",
|
|
58
58
|
"cors": "^2.8.5",
|
|
59
59
|
"crypto-js": "^4.2.0",
|
|
@@ -61,20 +61,20 @@
|
|
|
61
61
|
"csrf-csrf": "^3.1.0",
|
|
62
62
|
"dotenv": "^16.4.7",
|
|
63
63
|
"express": "^5.0.1",
|
|
64
|
-
"helmet": "^8.
|
|
64
|
+
"helmet": "^8.1.0",
|
|
65
65
|
"jsonwebtoken": "^9.0.2",
|
|
66
|
-
"mongodb": "^6.
|
|
67
|
-
"mongoose": "^8.
|
|
66
|
+
"mongodb": "^6.15.0",
|
|
67
|
+
"mongoose": "^8.12.1",
|
|
68
68
|
"oauth2-server": "^3.1.1",
|
|
69
|
-
"openai": "^4.
|
|
69
|
+
"openai": "^4.89.0",
|
|
70
70
|
"react": "^19.0.0",
|
|
71
|
-
"react-email": "^3.0.
|
|
72
|
-
"resend": "^4.1.
|
|
73
|
-
"stripe": "^17.
|
|
74
|
-
"uuid": "^11.0
|
|
71
|
+
"react-email": "^3.0.7",
|
|
72
|
+
"resend": "^4.1.2",
|
|
73
|
+
"stripe": "^17.7.0",
|
|
74
|
+
"uuid": "^11.1.0",
|
|
75
75
|
"validator": "^13.12.0",
|
|
76
76
|
"winston": "^3.17.0",
|
|
77
|
-
"express-intlayer": "5.3.
|
|
77
|
+
"express-intlayer": "5.3.10"
|
|
78
78
|
},
|
|
79
79
|
"devDependencies": {
|
|
80
80
|
"@types/bcrypt": "^5.0.2",
|
|
@@ -84,30 +84,30 @@
|
|
|
84
84
|
"@types/cors": "^2.8.17",
|
|
85
85
|
"@types/crypto-js": "^4.2.2",
|
|
86
86
|
"@types/csurf": "^1.11.5",
|
|
87
|
-
"@types/express": "^5.0.
|
|
88
|
-
"@types/jsonwebtoken": "^9.0.
|
|
89
|
-
"@types/node": "^22.10
|
|
87
|
+
"@types/express": "^5.0.1",
|
|
88
|
+
"@types/jsonwebtoken": "^9.0.9",
|
|
89
|
+
"@types/node": "^22.13.10",
|
|
90
90
|
"@types/oauth2-server": "^3.0.18",
|
|
91
|
-
"@types/react": "^19.0.
|
|
91
|
+
"@types/react": "^19.0.12",
|
|
92
92
|
"@types/uuid": "^10.0.0",
|
|
93
93
|
"@types/validator": "^13.12.2",
|
|
94
|
-
"esbuild-fix-imports-plugin": "^1.0.
|
|
95
|
-
"eslint": "^9.
|
|
94
|
+
"esbuild-fix-imports-plugin": "^1.0.19",
|
|
95
|
+
"eslint": "^9.22.0",
|
|
96
96
|
"prettier": "^3.5.0",
|
|
97
97
|
"rimraf": "^6.0.1",
|
|
98
|
-
"tsc-alias": "^1.8.
|
|
99
|
-
"tsup": "^8.
|
|
100
|
-
"tsx": "^4.19.
|
|
101
|
-
"typescript": "^5.
|
|
102
|
-
"@intlayer/
|
|
103
|
-
"@intlayer/
|
|
104
|
-
"@
|
|
105
|
-
"@intlayer/docs": "5.3.
|
|
106
|
-
"@utils/ts-config-types": "1.0.4",
|
|
107
|
-
"@utils/tsup-config": "1.0.4",
|
|
108
|
-
"intlayer": "5.3.8",
|
|
98
|
+
"tsc-alias": "^1.8.11",
|
|
99
|
+
"tsup": "^8.4.0",
|
|
100
|
+
"tsx": "^4.19.3",
|
|
101
|
+
"typescript": "^5.8.2",
|
|
102
|
+
"@intlayer/config": "5.3.10",
|
|
103
|
+
"@intlayer/core": "5.3.10",
|
|
104
|
+
"@utils/eslint-config": "1.0.4",
|
|
105
|
+
"@intlayer/docs": "5.3.10",
|
|
109
106
|
"@utils/ts-config": "1.0.4",
|
|
110
|
-
"@utils/
|
|
107
|
+
"@utils/tsup-config": "1.0.4",
|
|
108
|
+
"@utils/ts-config-types": "1.0.4",
|
|
109
|
+
"intlayer": "5.3.10",
|
|
110
|
+
"@intlayer/blog": "5.3.10"
|
|
111
111
|
},
|
|
112
112
|
"scripts": {
|
|
113
113
|
"build": "pnpm build:package & pnpm build:types",
|