@ldsg/application 0.3.24 → 0.3.26
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/LICENSE +1 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +1 -3
- package/dist/resource.js +2 -2
- package/dist/types/specific-resource-settings.d.ts +8 -7
- package/dist/types/specific-resource-settings.d.ts.map +1 -1
- package/dist/types/specific-resource-settings.js +11 -0
- package/package.json +7 -6
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2014-present
|
|
3
|
+
Copyright (c) 2014-present Wanxger and other contributors
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining
|
|
6
6
|
a copy of this software and associated documentation files (the
|
package/dist/constants.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,+BAA+B,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,EAAE,0CAA0C,EAAE,MAAM,2BAA2B,CAAC;AACvF,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAEtD;;;GAGG;AACH,eAAO,MAAM,sDAAsD,EAAE,uBAGpE,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,uDAAuD,EAAE,+BAOrE,CAAC;AAEF,eAAO,MAAM,6CAA6C,EAAE,uBAG3D,CAAC;AAEF,eAAO,MAAM,8CAA8C,EAAE,0CAE5D,CAAC"}
|
package/dist/constants.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.RESOURCE_DEFINITION_SPECIFIC_RESOURCE_SETTINGS = exports.RESOURCE_DEFINITION_GENERAL_RESOURCE_SETTINGS = exports.INSTANTIATE_RESOURCE_HANDLER_SPECIFIC_RESOURCE_SETTINGS = exports.INSTANTIATE_RESOURCE_HANDLER_GENERAL_RESOURCE_SETTINGS = void 0;
|
|
4
|
-
const constants_1 = require("@ldsg/constants");
|
|
5
4
|
/**
|
|
6
5
|
* Instantiate Resource Handler General Resource Settings
|
|
7
6
|
* 实例化资源处理程序普通资源配置
|
|
@@ -28,6 +27,5 @@ exports.RESOURCE_DEFINITION_GENERAL_RESOURCE_SETTINGS = {
|
|
|
28
27
|
description: ''
|
|
29
28
|
};
|
|
30
29
|
exports.RESOURCE_DEFINITION_SPECIFIC_RESOURCE_SETTINGS = {
|
|
31
|
-
kind: 'application'
|
|
32
|
-
parentKind: constants_1.ROOT_RESOURCE_KIND
|
|
30
|
+
kind: 'application'
|
|
33
31
|
};
|
package/dist/resource.js
CHANGED
|
@@ -12,9 +12,9 @@ class ApplicationResource extends resource_1.Resource {
|
|
|
12
12
|
this.createExpressApp = () => {
|
|
13
13
|
const app = (0, express_1.default)();
|
|
14
14
|
// 中间件:解析 application/x-www-form-urlencoded
|
|
15
|
-
app.use(express_1.default.urlencoded({ extended: true }));
|
|
15
|
+
app.use(express_1.default.urlencoded({ extended: true, limit: '50mb' }));
|
|
16
16
|
// 中间件:解析 application/json
|
|
17
|
-
app.use(express_1.default.json());
|
|
17
|
+
app.use(express_1.default.json({ limit: '50mb' }));
|
|
18
18
|
this.extendExpressApp({
|
|
19
19
|
app
|
|
20
20
|
});
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
name
|
|
7
|
-
}
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const ApplicationSpecificResourceSettingsSchema: z.ZodObject<{
|
|
3
|
+
name: z.ZodOptional<z.ZodString>;
|
|
4
|
+
}, z.core.$catchall<z.ZodAny>>;
|
|
5
|
+
export declare const SpecificResourceSettingsSchema: z.ZodObject<{
|
|
6
|
+
name: z.ZodOptional<z.ZodString>;
|
|
7
|
+
}, z.core.$catchall<z.ZodAny>>;
|
|
8
|
+
export type ApplicationSpecificResourceSettings = z.infer<typeof ApplicationSpecificResourceSettingsSchema>;
|
|
8
9
|
//# sourceMappingURL=specific-resource-settings.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"specific-resource-settings.d.ts","sourceRoot":"","sources":["../../src/types/specific-resource-settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"specific-resource-settings.d.ts","sourceRoot":"","sources":["../../src/types/specific-resource-settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,yCAAyC;;8BAOlC,CAAC;AAErB,eAAO,MAAM,8BAA8B;;8BAA4C,CAAC;AACxF,MAAM,MAAM,mCAAmC,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yCAAyC,CAAC,CAAC"}
|
|
@@ -1,2 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SpecificResourceSettingsSchema = exports.ApplicationSpecificResourceSettingsSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
exports.ApplicationSpecificResourceSettingsSchema = zod_1.z
|
|
6
|
+
.object({
|
|
7
|
+
/**
|
|
8
|
+
* Application Name
|
|
9
|
+
*/
|
|
10
|
+
name: zod_1.z.string().optional()
|
|
11
|
+
})
|
|
12
|
+
.catchall(zod_1.z.any());
|
|
13
|
+
exports.SpecificResourceSettingsSchema = exports.ApplicationSpecificResourceSettingsSchema;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ldsg/application",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.26",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -12,11 +12,12 @@
|
|
|
12
12
|
],
|
|
13
13
|
"dependencies": {
|
|
14
14
|
"express": "^4.18.2",
|
|
15
|
-
"
|
|
16
|
-
"@ldsg/
|
|
17
|
-
"@ldsg/
|
|
18
|
-
"@ldsg/resource-definition": "0.3.
|
|
19
|
-
"@ldsg/
|
|
15
|
+
"zod": "^4.1.11",
|
|
16
|
+
"@ldsg/constants": "0.3.26",
|
|
17
|
+
"@ldsg/handler": "0.3.26",
|
|
18
|
+
"@ldsg/resource-definition": "0.3.26",
|
|
19
|
+
"@ldsg/resource": "0.3.26",
|
|
20
|
+
"@ldsg/types": "0.3.26"
|
|
20
21
|
},
|
|
21
22
|
"devDependencies": {
|
|
22
23
|
"@types/express": "^4.17.17",
|