@mx-space/api-client 0.3.4 → 0.3.5
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/build/index.cjs.js.map +1 -1
- package/build/index.cjs.min.js.map +1 -1
- package/build/index.d.ts +23 -29
- package/build/index.esm.js.map +1 -1
- package/build/index.esm.min.js.map +1 -1
- package/build/index.umd.js.map +1 -1
- package/build/index.umd.min.js.map +1 -1
- package/esm/core/controllers/comment.d.ts +5 -8
- package/esm/core/controllers/note.d.ts +6 -9
- package/esm/core/controllers/page.d.ts +4 -4
- package/esm/core/controllers/page.js.map +1 -1
- package/esm/core/controllers/post.js.map +1 -1
- package/esm/core/controllers/recently.d.ts +4 -4
- package/esm/core/controllers/recently.js.map +1 -1
- package/esm/core/controllers/say.d.ts +2 -2
- package/esm/core/controllers/say.js.map +1 -1
- package/esm/core/controllers/snippet.d.ts +3 -3
- package/esm/core/controllers/snippet.js.map +1 -1
- package/esm/core/controllers/user.d.ts +4 -4
- package/esm/core/controllers/user.js.map +1 -1
- package/lib/core/controllers/comment.d.ts +5 -8
- package/lib/core/controllers/note.d.ts +6 -9
- package/lib/core/controllers/page.d.ts +4 -4
- package/lib/core/controllers/page.js.map +1 -1
- package/lib/core/controllers/post.js.map +1 -1
- package/lib/core/controllers/recently.d.ts +4 -4
- package/lib/core/controllers/recently.js.map +1 -1
- package/lib/core/controllers/say.d.ts +2 -2
- package/lib/core/controllers/say.js.map +1 -1
- package/lib/core/controllers/snippet.d.ts +3 -3
- package/lib/core/controllers/snippet.js.map +1 -1
- package/lib/core/controllers/user.d.ts +4 -4
- package/lib/core/controllers/user.js.map +1 -1
- package/package.json +3 -3
- package/esm/types/helper.d.ts +0 -2
- package/esm/types/helper.js +0 -2
- package/esm/types/helper.js.map +0 -1
- package/lib/types/helper.d.ts +0 -2
- package/lib/types/helper.js +0 -3
- package/lib/types/helper.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IController } from "../../interfaces/controller";
|
|
2
|
-
import { IRequestHandler } from "../../interfaces/request";
|
|
2
|
+
import { IRequestHandler, RequestProxyResult } from "../../interfaces/request";
|
|
3
3
|
import { SnippetModel } from "../../models/snippet";
|
|
4
4
|
import { HTTPClient } from '..';
|
|
5
5
|
export declare class SnippetController implements IController {
|
|
@@ -8,11 +8,11 @@ export declare class SnippetController implements IController {
|
|
|
8
8
|
name: string;
|
|
9
9
|
constructor(client: HTTPClient);
|
|
10
10
|
get proxy(): IRequestHandler;
|
|
11
|
-
getById(id: string):
|
|
11
|
+
getById(id: string): RequestProxyResult<SnippetModel, {
|
|
12
12
|
[key: string]: any;
|
|
13
13
|
data: SnippetModel;
|
|
14
14
|
}>;
|
|
15
|
-
getByReferenceAndName(reference: string, name: string):
|
|
15
|
+
getByReferenceAndName(reference: string, name: string): RequestProxyResult<SnippetModel, {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
data: SnippetModel;
|
|
18
18
|
}>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../../src/core/controllers/snippet.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../../src/core/controllers/snippet.ts"],"names":[],"mappings":";;;AAMA,MAAa,iBAAiB;IAI5B,YAAsB,MAAkB;QAAlB,WAAM,GAAN,MAAM,CAAY;QAHxC,SAAI,GAAG,UAAU,CAAA;QACjB,SAAI,GAAG,SAAS,CAAA;IAE2B,CAAC;IAE5C,IAAI,KAAK;QACP,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IACrC,CAAC;IAED,OAAO,CAAC,EAAU;QAChB,OAAO,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,GAAG,EAAgB,CAAA;IAC3C,CAAC;IAED,qBAAqB,CAAC,SAAiB,EAAE,IAAY;QACnD,OAAO,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,IAAI,CAAC,CAAC,GAAG,EAAgB,CAAA;IACxD,CAAC;CACF;AAjBD,8CAiBC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IController } from "../../interfaces/controller";
|
|
2
|
-
import { IRequestHandler } from "../../interfaces/request";
|
|
2
|
+
import { IRequestHandler, RequestProxyResult } from "../../interfaces/request";
|
|
3
3
|
import { TLogin, UserModel } from "../../models/user";
|
|
4
4
|
import { HTTPClient } from '..';
|
|
5
5
|
export declare class UserController implements IController {
|
|
@@ -8,15 +8,15 @@ export declare class UserController implements IController {
|
|
|
8
8
|
base: string;
|
|
9
9
|
name: string;
|
|
10
10
|
protected get proxy(): IRequestHandler;
|
|
11
|
-
getMasterInfo():
|
|
11
|
+
getMasterInfo(): RequestProxyResult<UserModel, {
|
|
12
12
|
[key: string]: any;
|
|
13
13
|
data: UserModel;
|
|
14
14
|
}>;
|
|
15
|
-
login(username: string, password: string):
|
|
15
|
+
login(username: string, password: string): RequestProxyResult<TLogin, {
|
|
16
16
|
[key: string]: any;
|
|
17
17
|
data: TLogin;
|
|
18
18
|
}>;
|
|
19
|
-
checkTokenValid(token: string):
|
|
19
|
+
checkTokenValid(token: string): RequestProxyResult<{
|
|
20
20
|
ok: number;
|
|
21
21
|
isGuest: boolean;
|
|
22
22
|
}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user.js","sourceRoot":"","sources":["../../../src/core/controllers/user.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"user.js","sourceRoot":"","sources":["../../../src/core/controllers/user.ts"],"names":[],"mappings":";;;AAMA,MAAa,cAAc;IACzB,YAA6B,MAAkB;QAAlB,WAAM,GAAN,MAAM,CAAY;QAE/C,SAAI,GAAG,QAAQ,CAAA;QAEf,SAAI,GAAG,MAAM,CAAA;IAJqC,CAAC;IAMnD,IAAc,KAAK;QACjB,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IACrC,CAAC;IAED,aAAa;QACX,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,EAAa,CAAA;IACpC,CAAC;IAED,KAAK,CAAC,QAAgB,EAAE,QAAgB;QACtC,OAAO,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAS;YACnC,IAAI,EAAE;gBACJ,QAAQ;gBACR,QAAQ;aACT;SACF,CAAC,CAAA;IACJ,CAAC;IAED,eAAe,CAAC,KAAa;QAC3B,OAAO,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,GAAG,CAAmC;YACnE,MAAM,EAAE;gBACN,KAAK;aACN;SACF,CAAC,CAAA;IACJ,CAAC;CACF;AA/BD,wCA+BC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mx-space/api-client",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5",
|
|
4
4
|
"description": "A api client for mx-space server@next",
|
|
5
5
|
"author": "Innei",
|
|
6
6
|
"license": "MIT",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"@rollup/plugin-typescript": "8.3.0",
|
|
66
66
|
"@types/jest": "27.0.3",
|
|
67
67
|
"@types/lodash": "4.14.177",
|
|
68
|
-
"@types/node": "16.11.
|
|
68
|
+
"@types/node": "16.11.11",
|
|
69
69
|
"@types/react": "17.0.37",
|
|
70
70
|
"@types/react-dom": "17.0.11",
|
|
71
71
|
"@zerollup/ts-transform-paths": "1.7.18",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"esbuild": "0.14.0",
|
|
75
75
|
"gh-pages": "3.2.3",
|
|
76
76
|
"husky": "7.0.4",
|
|
77
|
-
"jest": "27.
|
|
77
|
+
"jest": "27.4.0",
|
|
78
78
|
"lint-staged": "12.1.2",
|
|
79
79
|
"lodash": "4.17.21",
|
|
80
80
|
"prettier": "2.5.0",
|
package/esm/types/helper.d.ts
DELETED
package/esm/types/helper.js
DELETED
package/esm/types/helper.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"helper.js","sourceRoot":"","sources":["../../src/types/helper.ts"],"names":[],"mappings":""}
|
package/lib/types/helper.d.ts
DELETED
package/lib/types/helper.js
DELETED
package/lib/types/helper.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"helper.js","sourceRoot":"","sources":["../../src/types/helper.ts"],"names":[],"mappings":""}
|