@mx-space/api-client 0.4.1 → 0.4.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.d.ts +15 -12
- package/esm/models/base.d.ts +10 -0
- package/esm/models/note.d.ts +2 -2
- package/esm/models/page.d.ts +2 -6
- package/esm/models/page.js.map +1 -1
- package/esm/models/post.d.ts +3 -5
- package/esm/models/snippet.d.ts +2 -1
- package/esm/models/snippet.js +1 -0
- package/esm/models/snippet.js.map +1 -1
- package/lib/models/base.d.ts +10 -0
- package/lib/models/note.d.ts +2 -2
- package/lib/models/page.d.ts +2 -6
- package/lib/models/page.js.map +1 -1
- package/lib/models/post.d.ts +3 -5
- package/lib/models/snippet.d.ts +2 -1
- package/lib/models/snippet.js +1 -0
- package/lib/models/snippet.js.map +1 -1
- package/package.json +6 -6
package/build/index.d.ts
CHANGED
|
@@ -74,9 +74,18 @@ declare class BaseModel {
|
|
|
74
74
|
created?: Date;
|
|
75
75
|
id?: string;
|
|
76
76
|
}
|
|
77
|
-
export interface
|
|
78
|
-
commentsIndex
|
|
77
|
+
export interface BaseCommentIndexModel {
|
|
78
|
+
commentsIndex?: number;
|
|
79
79
|
allowComment: boolean;
|
|
80
|
+
}
|
|
81
|
+
export interface TextBaseModel extends BaseCommentIndexModel {
|
|
82
|
+
title: string;
|
|
83
|
+
text: string;
|
|
84
|
+
images?: Image[];
|
|
85
|
+
modified: string | null;
|
|
86
|
+
}
|
|
87
|
+
export interface PostModel extends TextBaseModel {
|
|
88
|
+
summary?: string;
|
|
80
89
|
hide: boolean;
|
|
81
90
|
copyright: boolean;
|
|
82
91
|
tags: string[];
|
|
@@ -87,7 +96,6 @@ export interface PostModel {
|
|
|
87
96
|
slug: string;
|
|
88
97
|
categoryId: string;
|
|
89
98
|
images: Image[];
|
|
90
|
-
modified: string;
|
|
91
99
|
created: string;
|
|
92
100
|
category: CategoryModel;
|
|
93
101
|
}
|
|
@@ -111,7 +119,7 @@ export interface TagModel {
|
|
|
111
119
|
count: number;
|
|
112
120
|
name: string;
|
|
113
121
|
}
|
|
114
|
-
export interface NoteModel {
|
|
122
|
+
export interface NoteModel extends TextBaseModel {
|
|
115
123
|
id: string;
|
|
116
124
|
hide: boolean;
|
|
117
125
|
count: {
|
|
@@ -124,7 +132,6 @@ export interface NoteModel {
|
|
|
124
132
|
weather?: string;
|
|
125
133
|
hasMemory?: boolean;
|
|
126
134
|
created: string;
|
|
127
|
-
modified: string;
|
|
128
135
|
secret?: Date;
|
|
129
136
|
password?: string | null;
|
|
130
137
|
nid: number;
|
|
@@ -150,20 +157,15 @@ declare enum EnumPageType {
|
|
|
150
157
|
"html" = "html",
|
|
151
158
|
"frame" = "frame"
|
|
152
159
|
}
|
|
153
|
-
export interface PageModel {
|
|
160
|
+
export interface PageModel extends TextBaseModel {
|
|
154
161
|
created: string;
|
|
155
|
-
modified: string;
|
|
156
162
|
id: string;
|
|
157
163
|
/** Slug */
|
|
158
164
|
slug: string;
|
|
159
|
-
/** Title */
|
|
160
|
-
title: string;
|
|
161
165
|
/** SubTitle */
|
|
162
166
|
subtitle?: string;
|
|
163
167
|
/** Order */
|
|
164
168
|
order?: number;
|
|
165
|
-
/** Text */
|
|
166
|
-
text: string;
|
|
167
169
|
/** Type (MD | html | frame) */
|
|
168
170
|
type?: EnumPageType;
|
|
169
171
|
/** Other Options */
|
|
@@ -733,7 +735,8 @@ export declare class SearchController implements IController {
|
|
|
733
735
|
}
|
|
734
736
|
declare enum SnippetType {
|
|
735
737
|
JSON = "json",
|
|
736
|
-
Text = "text"
|
|
738
|
+
Text = "text",
|
|
739
|
+
YAML = "yaml"
|
|
737
740
|
}
|
|
738
741
|
export interface SnippetModel<T = unknown> extends BaseModel {
|
|
739
742
|
type: SnippetType;
|
package/esm/models/base.d.ts
CHANGED
|
@@ -25,3 +25,13 @@ export declare class BaseModel {
|
|
|
25
25
|
created?: Date;
|
|
26
26
|
id?: string;
|
|
27
27
|
}
|
|
28
|
+
export interface BaseCommentIndexModel {
|
|
29
|
+
commentsIndex?: number;
|
|
30
|
+
allowComment: boolean;
|
|
31
|
+
}
|
|
32
|
+
export interface TextBaseModel extends BaseCommentIndexModel {
|
|
33
|
+
title: string;
|
|
34
|
+
text: string;
|
|
35
|
+
images?: Image[];
|
|
36
|
+
modified: string | null;
|
|
37
|
+
}
|
package/esm/models/note.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { TextBaseModel } from './base';
|
|
2
|
+
export interface NoteModel extends TextBaseModel {
|
|
2
3
|
id: string;
|
|
3
4
|
hide: boolean;
|
|
4
5
|
count: {
|
|
@@ -11,7 +12,6 @@ export interface NoteModel {
|
|
|
11
12
|
weather?: string;
|
|
12
13
|
hasMemory?: boolean;
|
|
13
14
|
created: string;
|
|
14
|
-
modified: string;
|
|
15
15
|
secret?: Date;
|
|
16
16
|
password?: string | null;
|
|
17
17
|
nid: number;
|
package/esm/models/page.d.ts
CHANGED
|
@@ -1,22 +1,18 @@
|
|
|
1
|
+
import { TextBaseModel } from './base';
|
|
1
2
|
export declare enum EnumPageType {
|
|
2
3
|
'md' = "md",
|
|
3
4
|
'html' = "html",
|
|
4
5
|
'frame' = "frame"
|
|
5
6
|
}
|
|
6
|
-
export interface PageModel {
|
|
7
|
+
export interface PageModel extends TextBaseModel {
|
|
7
8
|
created: string;
|
|
8
|
-
modified: string;
|
|
9
9
|
id: string;
|
|
10
10
|
/** Slug */
|
|
11
11
|
slug: string;
|
|
12
|
-
/** Title */
|
|
13
|
-
title: string;
|
|
14
12
|
/** SubTitle */
|
|
15
13
|
subtitle?: string;
|
|
16
14
|
/** Order */
|
|
17
15
|
order?: number;
|
|
18
|
-
/** Text */
|
|
19
|
-
text: string;
|
|
20
16
|
/** Type (MD | html | frame) */
|
|
21
17
|
type?: EnumPageType;
|
|
22
18
|
/** Other Options */
|
package/esm/models/page.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../src/models/page.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../src/models/page.ts"],"names":[],"mappings":"AAEA,MAAM,CAAN,IAAY,YAIX;AAJD,WAAY,YAAY;IACtB,yBAAW,CAAA;IACX,6BAAe,CAAA;IACf,+BAAiB,CAAA;AACnB,CAAC,EAJW,YAAY,KAAZ,YAAY,QAIvB"}
|
package/esm/models/post.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { Count, Image } from './base';
|
|
1
|
+
import { Count, Image, TextBaseModel } from './base';
|
|
2
2
|
import { CategoryModel } from './category';
|
|
3
|
-
export interface PostModel {
|
|
4
|
-
|
|
5
|
-
allowComment: boolean;
|
|
3
|
+
export interface PostModel extends TextBaseModel {
|
|
4
|
+
summary?: string;
|
|
6
5
|
hide: boolean;
|
|
7
6
|
copyright: boolean;
|
|
8
7
|
tags: string[];
|
|
@@ -13,7 +12,6 @@ export interface PostModel {
|
|
|
13
12
|
slug: string;
|
|
14
13
|
categoryId: string;
|
|
15
14
|
images: Image[];
|
|
16
|
-
modified: string;
|
|
17
15
|
created: string;
|
|
18
16
|
category: CategoryModel;
|
|
19
17
|
}
|
package/esm/models/snippet.d.ts
CHANGED
package/esm/models/snippet.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../src/models/snippet.ts"],"names":[],"mappings":"AACA,MAAM,CAAN,IAAY,
|
|
1
|
+
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../src/models/snippet.ts"],"names":[],"mappings":"AACA,MAAM,CAAN,IAAY,WAKX;AALD,WAAY,WAAW;IACrB,4BAAa,CAAA;IACb,yBAAyB;IACzB,4BAAa,CAAA;IACb,4BAAa,CAAA;AACf,CAAC,EALW,WAAW,KAAX,WAAW,QAKtB"}
|
package/lib/models/base.d.ts
CHANGED
|
@@ -25,3 +25,13 @@ export declare class BaseModel {
|
|
|
25
25
|
created?: Date;
|
|
26
26
|
id?: string;
|
|
27
27
|
}
|
|
28
|
+
export interface BaseCommentIndexModel {
|
|
29
|
+
commentsIndex?: number;
|
|
30
|
+
allowComment: boolean;
|
|
31
|
+
}
|
|
32
|
+
export interface TextBaseModel extends BaseCommentIndexModel {
|
|
33
|
+
title: string;
|
|
34
|
+
text: string;
|
|
35
|
+
images?: Image[];
|
|
36
|
+
modified: string | null;
|
|
37
|
+
}
|
package/lib/models/note.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { TextBaseModel } from './base';
|
|
2
|
+
export interface NoteModel extends TextBaseModel {
|
|
2
3
|
id: string;
|
|
3
4
|
hide: boolean;
|
|
4
5
|
count: {
|
|
@@ -11,7 +12,6 @@ export interface NoteModel {
|
|
|
11
12
|
weather?: string;
|
|
12
13
|
hasMemory?: boolean;
|
|
13
14
|
created: string;
|
|
14
|
-
modified: string;
|
|
15
15
|
secret?: Date;
|
|
16
16
|
password?: string | null;
|
|
17
17
|
nid: number;
|
package/lib/models/page.d.ts
CHANGED
|
@@ -1,22 +1,18 @@
|
|
|
1
|
+
import { TextBaseModel } from './base';
|
|
1
2
|
export declare enum EnumPageType {
|
|
2
3
|
'md' = "md",
|
|
3
4
|
'html' = "html",
|
|
4
5
|
'frame' = "frame"
|
|
5
6
|
}
|
|
6
|
-
export interface PageModel {
|
|
7
|
+
export interface PageModel extends TextBaseModel {
|
|
7
8
|
created: string;
|
|
8
|
-
modified: string;
|
|
9
9
|
id: string;
|
|
10
10
|
/** Slug */
|
|
11
11
|
slug: string;
|
|
12
|
-
/** Title */
|
|
13
|
-
title: string;
|
|
14
12
|
/** SubTitle */
|
|
15
13
|
subtitle?: string;
|
|
16
14
|
/** Order */
|
|
17
15
|
order?: number;
|
|
18
|
-
/** Text */
|
|
19
|
-
text: string;
|
|
20
16
|
/** Type (MD | html | frame) */
|
|
21
17
|
type?: EnumPageType;
|
|
22
18
|
/** Other Options */
|
package/lib/models/page.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../src/models/page.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"page.js","sourceRoot":"","sources":["../../src/models/page.ts"],"names":[],"mappings":";;;AAEA,IAAY,YAIX;AAJD,WAAY,YAAY;IACtB,yBAAW,CAAA;IACX,6BAAe,CAAA;IACf,+BAAiB,CAAA;AACnB,CAAC,EAJW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAIvB"}
|
package/lib/models/post.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { Count, Image } from './base';
|
|
1
|
+
import { Count, Image, TextBaseModel } from './base';
|
|
2
2
|
import { CategoryModel } from './category';
|
|
3
|
-
export interface PostModel {
|
|
4
|
-
|
|
5
|
-
allowComment: boolean;
|
|
3
|
+
export interface PostModel extends TextBaseModel {
|
|
4
|
+
summary?: string;
|
|
6
5
|
hide: boolean;
|
|
7
6
|
copyright: boolean;
|
|
8
7
|
tags: string[];
|
|
@@ -13,7 +12,6 @@ export interface PostModel {
|
|
|
13
12
|
slug: string;
|
|
14
13
|
categoryId: string;
|
|
15
14
|
images: Image[];
|
|
16
|
-
modified: string;
|
|
17
15
|
created: string;
|
|
18
16
|
category: CategoryModel;
|
|
19
17
|
}
|
package/lib/models/snippet.d.ts
CHANGED
package/lib/models/snippet.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../src/models/snippet.ts"],"names":[],"mappings":";;;AACA,IAAY,
|
|
1
|
+
{"version":3,"file":"snippet.js","sourceRoot":"","sources":["../../src/models/snippet.ts"],"names":[],"mappings":";;;AACA,IAAY,WAKX;AALD,WAAY,WAAW;IACrB,4BAAa,CAAA;IACb,yBAAyB;IACzB,4BAAa,CAAA;IACb,4BAAa,CAAA;AACf,CAAC,EALW,WAAW,GAAX,mBAAW,KAAX,mBAAW,QAKtB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mx-space/api-client",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.5",
|
|
4
4
|
"description": "A api client for mx-space server@next",
|
|
5
5
|
"author": "Innei",
|
|
6
6
|
"license": "MIT",
|
|
@@ -66,25 +66,25 @@
|
|
|
66
66
|
"@types/express": "4.17.13",
|
|
67
67
|
"@types/jest": "27.0.3",
|
|
68
68
|
"@types/lodash": "4.14.178",
|
|
69
|
-
"@types/node": "16.11.
|
|
70
|
-
"@types/react": "17.0.
|
|
69
|
+
"@types/node": "16.11.17",
|
|
70
|
+
"@types/react": "17.0.38",
|
|
71
71
|
"@types/react-dom": "17.0.11",
|
|
72
72
|
"@zerollup/ts-transform-paths": "1.7.18",
|
|
73
73
|
"axios": "0.24.0",
|
|
74
74
|
"cors": "2.8.5",
|
|
75
75
|
"dts-bundle-generator": "6.2.0",
|
|
76
|
-
"esbuild": "0.14.
|
|
76
|
+
"esbuild": "0.14.8",
|
|
77
77
|
"express": "4.17.2",
|
|
78
78
|
"gh-pages": "3.2.3",
|
|
79
79
|
"husky": "7.0.4",
|
|
80
80
|
"jest": "27.4.5",
|
|
81
|
-
"lint-staged": "12.1.
|
|
81
|
+
"lint-staged": "12.1.4",
|
|
82
82
|
"lodash": "4.17.21",
|
|
83
83
|
"prettier": "2.5.1",
|
|
84
84
|
"react": "18.0.0-rc.0-next-f2a59df48-20211208",
|
|
85
85
|
"react-dom": "18.0.0-rc.0-next-f2a59df48-20211208",
|
|
86
86
|
"react-json-view": "1.21.3",
|
|
87
|
-
"rollup": "2.
|
|
87
|
+
"rollup": "2.62.0",
|
|
88
88
|
"rollup-plugin-peer-deps-external": "2.2.4",
|
|
89
89
|
"rollup-plugin-terser": "7.0.2",
|
|
90
90
|
"ts-jest": "27.1.2",
|