@next-bricks/ai-portal 0.13.2 → 0.13.4

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.
Files changed (30) hide show
  1. package/dist/bricks.json +8 -8
  2. package/dist/chunks/{1607.a450fbae.js → 1607.fa035c7c.js} +2 -2
  3. package/dist/chunks/1607.fa035c7c.js.map +1 -0
  4. package/dist/chunks/903.a19b4616.js +2 -0
  5. package/dist/chunks/903.a19b4616.js.map +1 -0
  6. package/dist/chunks/{chat-history.2cc80218.js → chat-history.869d77b4.js} +3 -3
  7. package/dist/chunks/chat-history.869d77b4.js.map +1 -0
  8. package/dist/chunks/{main.7b1c203a.js → main.98001644.js} +2 -2
  9. package/dist/chunks/{main.7b1c203a.js.map → main.98001644.js.map} +1 -1
  10. package/dist/examples.json +5 -5
  11. package/dist/images/98d93242.png +0 -0
  12. package/dist/index.eeeefd5d.js +2 -0
  13. package/dist/{index.9a81eba9.js.map → index.eeeefd5d.js.map} +1 -1
  14. package/dist/manifest.json +78 -78
  15. package/dist/types.json +93 -93
  16. package/dist-types/cruise-canvas/utils/converters/convertDashboard.d.ts +2 -2
  17. package/dist-types/cruise-canvas/utils/converters/convertDescriptions.d.ts +2 -2
  18. package/dist-types/cruise-canvas/utils/converters/convertEvents.d.ts +2 -2
  19. package/dist-types/cruise-canvas/utils/converters/convertTable.d.ts +1 -1
  20. package/dist-types/cruise-canvas/utils/converters/convertView.d.ts +1 -1
  21. package/dist-types/cruise-canvas/utils/converters/interfaces.d.ts +1 -0
  22. package/dist-types/cruise-canvas/utils/createPortal.d.ts +1 -0
  23. package/package.json +2 -2
  24. package/dist/chunks/1607.a450fbae.js.map +0 -1
  25. package/dist/chunks/903.a9b530b3.js +0 -2
  26. package/dist/chunks/903.a9b530b3.js.map +0 -1
  27. package/dist/chunks/chat-history.2cc80218.js.map +0 -1
  28. package/dist/images/3083fab4.png +0 -0
  29. package/dist/index.9a81eba9.js +0 -2
  30. /package/dist/chunks/{chat-history.2cc80218.js.LICENSE.txt → chat-history.869d77b4.js.LICENSE.txt} +0 -0
@@ -3,67 +3,6 @@
3
3
  "package": "@next-bricks/ai-portal",
4
4
  "name": "ai-portal",
5
5
  "bricks": [
6
- {
7
- "name": "ai-portal.stat-with-mini-chart",
8
- "properties": [
9
- {
10
- "name": "label",
11
- "type": "string"
12
- },
13
- {
14
- "name": "value",
15
- "type": "string"
16
- },
17
- {
18
- "name": "size",
19
- "description": "",
20
- "default": "\"medium\"",
21
- "type": "\"medium\" | \"small\""
22
- },
23
- {
24
- "name": "lineColor",
25
- "description": "",
26
- "default": "\"var(--color-brand)\"",
27
- "type": "string"
28
- },
29
- {
30
- "name": "showArea",
31
- "type": "boolean"
32
- },
33
- {
34
- "name": "min",
35
- "description": "Specify the minimum value of the y-axis.\nIf not specified, the minimum value will be calculated from the data.",
36
- "type": "number"
37
- },
38
- {
39
- "name": "max",
40
- "description": "Specify the maximum value of the y-axis.\nIf not specified, the maximum value will be calculated from the data.",
41
- "type": "number"
42
- },
43
- {
44
- "name": "xField",
45
- "description": "",
46
- "default": "\"0\"",
47
- "type": "string"
48
- },
49
- {
50
- "name": "yField",
51
- "description": "",
52
- "default": "\"1\"",
53
- "type": "string"
54
- },
55
- {
56
- "name": "data",
57
- "attribute": false,
58
- "type": "Record<string, number>[]"
59
- }
60
- ],
61
- "events": [],
62
- "slots": [],
63
- "methods": [],
64
- "parts": [],
65
- "description": "构件 `ai-portal.stat-with-mini-chart`"
66
- },
67
6
  {
68
7
  "name": "ai-portal.cruise-canvas",
69
8
  "properties": [
@@ -131,6 +70,44 @@
131
70
  "parts": [],
132
71
  "description": "构件 `ai-portal.home-container`"
133
72
  },
73
+ {
74
+ "name": "ai-portal.chat-box",
75
+ "properties": [
76
+ {
77
+ "name": "disabled",
78
+ "type": "boolean"
79
+ },
80
+ {
81
+ "name": "placeholder",
82
+ "type": "string"
83
+ },
84
+ {
85
+ "name": "autoFocus",
86
+ "type": "boolean"
87
+ },
88
+ {
89
+ "name": "suggestions",
90
+ "attribute": false,
91
+ "type": "Suggestion[]"
92
+ },
93
+ {
94
+ "name": "suggestionsLabel",
95
+ "type": "string"
96
+ }
97
+ ],
98
+ "events": [
99
+ {
100
+ "name": "message.submit",
101
+ "detail": {
102
+ "type": "string"
103
+ }
104
+ }
105
+ ],
106
+ "slots": [],
107
+ "methods": [],
108
+ "parts": [],
109
+ "description": "构件 `ai-portal.chat-box`"
110
+ },
134
111
  {
135
112
  "name": "ai-portal.chat-history",
136
113
  "properties": [
@@ -169,42 +146,65 @@
169
146
  "description": "构件 `ai-portal.chat-history`"
170
147
  },
171
148
  {
172
- "name": "ai-portal.chat-box",
149
+ "name": "ai-portal.stat-with-mini-chart",
173
150
  "properties": [
174
151
  {
175
- "name": "disabled",
176
- "type": "boolean"
152
+ "name": "label",
153
+ "type": "string"
177
154
  },
178
155
  {
179
- "name": "placeholder",
156
+ "name": "value",
180
157
  "type": "string"
181
158
  },
182
159
  {
183
- "name": "autoFocus",
160
+ "name": "size",
161
+ "description": "",
162
+ "default": "\"medium\"",
163
+ "type": "\"medium\" | \"small\""
164
+ },
165
+ {
166
+ "name": "lineColor",
167
+ "description": "",
168
+ "default": "\"var(--color-brand)\"",
169
+ "type": "string"
170
+ },
171
+ {
172
+ "name": "showArea",
184
173
  "type": "boolean"
185
174
  },
186
175
  {
187
- "name": "suggestions",
188
- "attribute": false,
189
- "type": "Suggestion[]"
176
+ "name": "min",
177
+ "description": "Specify the minimum value of the y-axis.\nIf not specified, the minimum value will be calculated from the data.",
178
+ "type": "number"
190
179
  },
191
180
  {
192
- "name": "suggestionsLabel",
181
+ "name": "max",
182
+ "description": "Specify the maximum value of the y-axis.\nIf not specified, the maximum value will be calculated from the data.",
183
+ "type": "number"
184
+ },
185
+ {
186
+ "name": "xField",
187
+ "description": "",
188
+ "default": "\"0\"",
193
189
  "type": "string"
194
- }
195
- ],
196
- "events": [
190
+ },
197
191
  {
198
- "name": "message.submit",
199
- "detail": {
200
- "type": "string"
201
- }
192
+ "name": "yField",
193
+ "description": "",
194
+ "default": "\"1\"",
195
+ "type": "string"
196
+ },
197
+ {
198
+ "name": "data",
199
+ "attribute": false,
200
+ "type": "Record<string, number>[]"
202
201
  }
203
202
  ],
203
+ "events": [],
204
204
  "slots": [],
205
205
  "methods": [],
206
206
  "parts": [],
207
- "description": "构件 `ai-portal.chat-box`"
207
+ "description": "构件 `ai-portal.stat-with-mini-chart`"
208
208
  }
209
209
  ],
210
210
  "providers": []
package/dist/types.json CHANGED
@@ -1,4 +1,9 @@
1
1
  {
2
+ "ai-portal.home-container": {
3
+ "properties": [],
4
+ "events": [],
5
+ "methods": []
6
+ },
2
7
  "ai-portal.stat-with-mini-chart": {
3
8
  "properties": [
4
9
  {
@@ -103,10 +108,94 @@
103
108
  "events": [],
104
109
  "methods": []
105
110
  },
106
- "ai-portal.home-container": {
107
- "properties": [],
108
- "events": [],
109
- "methods": []
111
+ "ai-portal.chat-box": {
112
+ "properties": [
113
+ {
114
+ "name": "disabled",
115
+ "annotation": {
116
+ "type": "keyword",
117
+ "value": "boolean"
118
+ }
119
+ },
120
+ {
121
+ "name": "placeholder",
122
+ "annotation": {
123
+ "type": "keyword",
124
+ "value": "string"
125
+ }
126
+ },
127
+ {
128
+ "name": "autoFocus",
129
+ "annotation": {
130
+ "type": "keyword",
131
+ "value": "boolean"
132
+ }
133
+ },
134
+ {
135
+ "name": "suggestions",
136
+ "annotation": {
137
+ "type": "array",
138
+ "elementType": {
139
+ "type": "reference",
140
+ "typeName": {
141
+ "type": "identifier",
142
+ "name": "Suggestion"
143
+ }
144
+ }
145
+ }
146
+ },
147
+ {
148
+ "name": "suggestionsLabel",
149
+ "annotation": {
150
+ "type": "keyword",
151
+ "value": "string"
152
+ }
153
+ }
154
+ ],
155
+ "events": [
156
+ {
157
+ "name": "message.submit",
158
+ "detail": {
159
+ "annotation": {
160
+ "type": "keyword",
161
+ "value": "string"
162
+ }
163
+ }
164
+ }
165
+ ],
166
+ "methods": [],
167
+ "types": [
168
+ {
169
+ "type": "interface",
170
+ "name": "Suggestion",
171
+ "body": [
172
+ {
173
+ "type": "propertySignature",
174
+ "key": {
175
+ "type": "identifier",
176
+ "name": "title"
177
+ },
178
+ "annotation": {
179
+ "type": "keyword",
180
+ "value": "string"
181
+ },
182
+ "computed": false
183
+ },
184
+ {
185
+ "type": "propertySignature",
186
+ "key": {
187
+ "type": "identifier",
188
+ "name": "content"
189
+ },
190
+ "annotation": {
191
+ "type": "keyword",
192
+ "value": "string"
193
+ },
194
+ "computed": false
195
+ }
196
+ ]
197
+ }
198
+ ]
110
199
  },
111
200
  "ai-portal.chat-history": {
112
201
  "properties": [
@@ -290,95 +379,6 @@
290
379
  }
291
380
  ]
292
381
  },
293
- "ai-portal.chat-box": {
294
- "properties": [
295
- {
296
- "name": "disabled",
297
- "annotation": {
298
- "type": "keyword",
299
- "value": "boolean"
300
- }
301
- },
302
- {
303
- "name": "placeholder",
304
- "annotation": {
305
- "type": "keyword",
306
- "value": "string"
307
- }
308
- },
309
- {
310
- "name": "autoFocus",
311
- "annotation": {
312
- "type": "keyword",
313
- "value": "boolean"
314
- }
315
- },
316
- {
317
- "name": "suggestions",
318
- "annotation": {
319
- "type": "array",
320
- "elementType": {
321
- "type": "reference",
322
- "typeName": {
323
- "type": "identifier",
324
- "name": "Suggestion"
325
- }
326
- }
327
- }
328
- },
329
- {
330
- "name": "suggestionsLabel",
331
- "annotation": {
332
- "type": "keyword",
333
- "value": "string"
334
- }
335
- }
336
- ],
337
- "events": [
338
- {
339
- "name": "message.submit",
340
- "detail": {
341
- "annotation": {
342
- "type": "keyword",
343
- "value": "string"
344
- }
345
- }
346
- }
347
- ],
348
- "methods": [],
349
- "types": [
350
- {
351
- "type": "interface",
352
- "name": "Suggestion",
353
- "body": [
354
- {
355
- "type": "propertySignature",
356
- "key": {
357
- "type": "identifier",
358
- "name": "title"
359
- },
360
- "annotation": {
361
- "type": "keyword",
362
- "value": "string"
363
- },
364
- "computed": false
365
- },
366
- {
367
- "type": "propertySignature",
368
- "key": {
369
- "type": "identifier",
370
- "name": "content"
371
- },
372
- "annotation": {
373
- "type": "keyword",
374
- "value": "string"
375
- },
376
- "computed": false
377
- }
378
- ]
379
- }
380
- ]
381
- },
382
382
  "ai-portal.cruise-canvas": {
383
383
  "properties": [
384
384
  {
@@ -1,3 +1,3 @@
1
1
  import type { BrickConf } from "@next-core/types";
2
- import type { Component } from "./interfaces.js";
3
- export default function convertDashboard({ properties }: Component): BrickConf;
2
+ import type { Component, ConvertViewOptions, ViewWithInfo } from "./interfaces.js";
3
+ export default function convertDashboard({ properties }: Component, view: ViewWithInfo, options: ConvertViewOptions): BrickConf;
@@ -1,3 +1,3 @@
1
1
  import type { BrickConf } from "@next-core/types";
2
- import type { Component, ViewWithInfo } from "./interfaces.js";
3
- export default function convertDescriptions({ properties }: Component, _view: ViewWithInfo): Promise<BrickConf>;
2
+ import type { Component, ConvertViewOptions, ViewWithInfo } from "./interfaces.js";
3
+ export default function convertDescriptions({ properties }: Component, view: ViewWithInfo, options: ConvertViewOptions): Promise<BrickConf>;
@@ -1,3 +1,3 @@
1
- import type { Component, ViewWithInfo } from "./interfaces.js";
1
+ import type { Component, ConvertViewOptions, ViewWithInfo } from "./interfaces.js";
2
2
  import type { BrickEventsMap } from "@next-core/types";
3
- export declare function convertEvents(component: Component, view: ViewWithInfo): BrickEventsMap | undefined;
3
+ export declare function convertEvents(component: Component, view: ViewWithInfo, options: ConvertViewOptions): BrickEventsMap | undefined;
@@ -1,3 +1,3 @@
1
1
  import type { BrickConf } from "@next-core/types";
2
2
  import type { Component, ConvertViewOptions, ViewWithInfo } from "./interfaces.js";
3
- export default function convertTable(component: Component, view: ViewWithInfo, options?: ConvertViewOptions): Promise<BrickConf>;
3
+ export default function convertTable(component: Component, view: ViewWithInfo, options: ConvertViewOptions): Promise<BrickConf>;
@@ -3,4 +3,4 @@ import type { BrickConf, ContextConf } from "@next-core/types";
3
3
  export interface BrickConfWithContext extends BrickConf {
4
4
  context?: ContextConf[];
5
5
  }
6
- export declare function convertView(view: ViewWithInfo | null | undefined, options?: ConvertViewOptions): Promise<BrickConfWithContext | null>;
6
+ export declare function convertView(view: ViewWithInfo | null | undefined, options: ConvertViewOptions): Promise<BrickConfWithContext | null>;
@@ -65,5 +65,6 @@ export interface ObjectMetric {
65
65
  unit: string;
66
66
  }
67
67
  export interface ConvertViewOptions {
68
+ rootId: string;
68
69
  expanded?: boolean;
69
70
  }
@@ -0,0 +1 @@
1
+ export declare function createPortal(rootId: string): HTMLDivElement;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/ai-portal",
3
- "version": "0.13.2",
3
+ "version": "0.13.4",
4
4
  "homepage": "https://github.com/easyops-cn/next-advanced-bricks/tree/master/bricks/ai-portal",
5
5
  "repository": {
6
6
  "type": "git",
@@ -44,5 +44,5 @@
44
44
  "@next-bricks/diagram": "*",
45
45
  "@next-bricks/mini-chart": "*"
46
46
  },
47
- "gitHead": "d80c873dd49822d5ff5ddd88e0f36d035059a421"
47
+ "gitHead": "ddc58b3d85a9dc3749dd69071ceaac98f410b8d6"
48
48
  }