@next-bricks/ai-portal 0.22.0 → 0.22.2

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 (72) hide show
  1. package/dist/bricks.json +22 -22
  2. package/dist/chunks/1165.9f35625d.js +2 -0
  3. package/dist/chunks/1165.9f35625d.js.map +1 -0
  4. package/dist/chunks/3500.f0c191e3.js +2 -0
  5. package/dist/chunks/3500.f0c191e3.js.map +1 -0
  6. package/dist/chunks/5054.087396dd.js +2 -0
  7. package/dist/chunks/5054.087396dd.js.map +1 -0
  8. package/dist/chunks/7170.69f823b8.js +2 -0
  9. package/dist/chunks/7170.69f823b8.js.map +1 -0
  10. package/dist/chunks/9543.433bae9f.js +3 -0
  11. package/dist/chunks/9543.433bae9f.js.map +1 -0
  12. package/dist/chunks/9828.6afc1a0f.js +3 -0
  13. package/dist/chunks/9828.6afc1a0f.js.map +1 -0
  14. package/dist/chunks/chat-box.2fbc1947.js +2 -0
  15. package/dist/chunks/chat-box.2fbc1947.js.map +1 -0
  16. package/dist/chunks/chat-history.9d100946.js +3 -0
  17. package/dist/chunks/chat-history.9d100946.js.map +1 -0
  18. package/dist/chunks/chat-stream.0b634b54.js +2 -0
  19. package/dist/chunks/chat-stream.0b634b54.js.map +1 -0
  20. package/dist/chunks/cruise-canvas.23852953.js +2 -0
  21. package/dist/chunks/cruise-canvas.23852953.js.map +1 -0
  22. package/dist/chunks/elevo-sidebar.8a4cd6d3.js +3 -0
  23. package/dist/chunks/elevo-sidebar.8a4cd6d3.js.map +1 -0
  24. package/dist/chunks/main.8091b272.js +2 -0
  25. package/dist/chunks/{main.c9b04114.js.map → main.8091b272.js.map} +1 -1
  26. package/dist/examples.json +10 -10
  27. package/dist/images/ddd8ccd2.png +0 -0
  28. package/dist/index.bbf59e6f.js +2 -0
  29. package/dist/index.bbf59e6f.js.map +1 -0
  30. package/dist/manifest.json +120 -115
  31. package/dist/types.json +226 -168
  32. package/dist-types/chat-stream/AssistantMessage/AssistantMessage.d.ts +2 -1
  33. package/dist-types/chat-stream/useChatStream.d.ts +7 -1
  34. package/dist-types/cruise-canvas/NodeLoading/NodeLoading.d.ts +1 -0
  35. package/dist-types/cruise-canvas/NodeRequirement/NodeRequirement.d.ts +1 -2
  36. package/dist-types/cruise-canvas/constants.d.ts +1 -6
  37. package/dist-types/cruise-canvas/getOrderedJobs.d.ts +1 -0
  38. package/dist-types/cruise-canvas/interfaces.d.ts +4 -1
  39. package/dist-types/elevo-sidebar/i18n.d.ts +2 -1
  40. package/dist-types/elevo-sidebar/index.d.ts +8 -0
  41. package/dist-types/shared/ChatBox/ChatBox.d.ts +2 -1
  42. package/dist-types/shared/constants.d.ts +1 -0
  43. package/package.json +2 -2
  44. package/dist/chunks/3506.da6e43af.js +0 -2
  45. package/dist/chunks/3506.da6e43af.js.map +0 -1
  46. package/dist/chunks/5054.45325cac.js +0 -2
  47. package/dist/chunks/5054.45325cac.js.map +0 -1
  48. package/dist/chunks/5527.0fef99d1.js +0 -2
  49. package/dist/chunks/5527.0fef99d1.js.map +0 -1
  50. package/dist/chunks/623.b1b19633.js +0 -3
  51. package/dist/chunks/623.b1b19633.js.map +0 -1
  52. package/dist/chunks/7170.a141f70a.js +0 -2
  53. package/dist/chunks/7170.a141f70a.js.map +0 -1
  54. package/dist/chunks/9543.30d5f113.js +0 -3
  55. package/dist/chunks/9543.30d5f113.js.map +0 -1
  56. package/dist/chunks/chat-box.61919819.js +0 -2
  57. package/dist/chunks/chat-box.61919819.js.map +0 -1
  58. package/dist/chunks/chat-history.720bb746.js +0 -3
  59. package/dist/chunks/chat-history.720bb746.js.map +0 -1
  60. package/dist/chunks/chat-stream.87126af6.js +0 -2
  61. package/dist/chunks/chat-stream.87126af6.js.map +0 -1
  62. package/dist/chunks/cruise-canvas.0afdaaee.js +0 -2
  63. package/dist/chunks/cruise-canvas.0afdaaee.js.map +0 -1
  64. package/dist/chunks/elevo-sidebar.05379cd1.js +0 -3
  65. package/dist/chunks/elevo-sidebar.05379cd1.js.map +0 -1
  66. package/dist/chunks/main.c9b04114.js +0 -2
  67. package/dist/index.f290f747.js +0 -2
  68. package/dist/index.f290f747.js.map +0 -1
  69. /package/dist/chunks/{9543.30d5f113.js.LICENSE.txt → 9543.433bae9f.js.LICENSE.txt} +0 -0
  70. /package/dist/chunks/{623.b1b19633.js.LICENSE.txt → 9828.6afc1a0f.js.LICENSE.txt} +0 -0
  71. /package/dist/chunks/{chat-history.720bb746.js.LICENSE.txt → chat-history.9d100946.js.LICENSE.txt} +0 -0
  72. /package/dist/chunks/{elevo-sidebar.05379cd1.js.LICENSE.txt → elevo-sidebar.8a4cd6d3.js.LICENSE.txt} +0 -0
package/dist/types.json CHANGED
@@ -1,9 +1,4 @@
1
1
  {
2
- "ai-portal.home-container": {
3
- "properties": [],
4
- "events": [],
5
- "methods": []
6
- },
7
2
  "ai-portal.stat-with-mini-chart": {
8
3
  "properties": [
9
4
  {
@@ -176,6 +171,11 @@
176
171
  }
177
172
  ]
178
173
  },
174
+ "ai-portal.home-container": {
175
+ "properties": [],
176
+ "events": [],
177
+ "methods": []
178
+ },
179
179
  "ai-portal.chat-box": {
180
180
  "properties": [
181
181
  {
@@ -265,6 +265,188 @@
265
265
  }
266
266
  ]
267
267
  },
268
+ "ai-portal.chat-history": {
269
+ "properties": [
270
+ {
271
+ "name": "list",
272
+ "annotation": {
273
+ "type": "array",
274
+ "elementType": {
275
+ "type": "reference",
276
+ "typeName": {
277
+ "type": "identifier",
278
+ "name": "HistoryItem"
279
+ }
280
+ }
281
+ }
282
+ },
283
+ {
284
+ "name": "actions",
285
+ "annotation": {
286
+ "type": "array",
287
+ "elementType": {
288
+ "type": "reference",
289
+ "typeName": {
290
+ "type": "identifier",
291
+ "name": "ActionType"
292
+ }
293
+ }
294
+ }
295
+ },
296
+ {
297
+ "name": "nextToken",
298
+ "annotation": {
299
+ "type": "keyword",
300
+ "value": "string"
301
+ }
302
+ }
303
+ ],
304
+ "events": [
305
+ {
306
+ "name": "action.click",
307
+ "detail": {
308
+ "annotation": {
309
+ "type": "reference",
310
+ "typeName": {
311
+ "type": "identifier",
312
+ "name": "ActionClickDetail"
313
+ }
314
+ }
315
+ }
316
+ },
317
+ {
318
+ "name": "load.more",
319
+ "detail": {
320
+ "annotation": {
321
+ "type": "typeLiteral",
322
+ "members": [
323
+ {
324
+ "type": "propertySignature",
325
+ "key": {
326
+ "type": "identifier",
327
+ "name": "nextToken"
328
+ },
329
+ "annotation": {
330
+ "type": "keyword",
331
+ "value": "string"
332
+ },
333
+ "computed": false
334
+ }
335
+ ]
336
+ }
337
+ }
338
+ }
339
+ ],
340
+ "methods": [],
341
+ "types": [
342
+ {
343
+ "type": "interface",
344
+ "name": "HistoryItem",
345
+ "body": [
346
+ {
347
+ "type": "propertySignature",
348
+ "key": {
349
+ "type": "identifier",
350
+ "name": "id"
351
+ },
352
+ "annotation": {
353
+ "type": "keyword",
354
+ "value": "string"
355
+ },
356
+ "computed": false
357
+ },
358
+ {
359
+ "type": "propertySignature",
360
+ "key": {
361
+ "type": "identifier",
362
+ "name": "url"
363
+ },
364
+ "annotation": {
365
+ "type": "keyword",
366
+ "value": "string"
367
+ },
368
+ "computed": false
369
+ },
370
+ {
371
+ "type": "propertySignature",
372
+ "key": {
373
+ "type": "identifier",
374
+ "name": "title"
375
+ },
376
+ "annotation": {
377
+ "type": "keyword",
378
+ "value": "string"
379
+ },
380
+ "computed": false
381
+ },
382
+ {
383
+ "type": "propertySignature",
384
+ "key": {
385
+ "type": "identifier",
386
+ "name": "startTime"
387
+ },
388
+ "annotation": {
389
+ "type": "keyword",
390
+ "value": "number"
391
+ },
392
+ "computed": false
393
+ },
394
+ {
395
+ "type": "propertySignature",
396
+ "key": {
397
+ "type": "identifier",
398
+ "name": "state"
399
+ },
400
+ "annotation": {
401
+ "type": "reference",
402
+ "typeName": {
403
+ "type": "identifier",
404
+ "name": "TaskState"
405
+ }
406
+ },
407
+ "optional": true,
408
+ "computed": false
409
+ }
410
+ ]
411
+ },
412
+ {
413
+ "type": "interface",
414
+ "name": "ActionClickDetail",
415
+ "body": [
416
+ {
417
+ "type": "propertySignature",
418
+ "key": {
419
+ "type": "identifier",
420
+ "name": "action"
421
+ },
422
+ "annotation": {
423
+ "type": "reference",
424
+ "typeName": {
425
+ "type": "identifier",
426
+ "name": "SimpleActionType"
427
+ }
428
+ },
429
+ "computed": false
430
+ },
431
+ {
432
+ "type": "propertySignature",
433
+ "key": {
434
+ "type": "identifier",
435
+ "name": "item"
436
+ },
437
+ "annotation": {
438
+ "type": "reference",
439
+ "typeName": {
440
+ "type": "identifier",
441
+ "name": "HistoryItem"
442
+ }
443
+ },
444
+ "computed": false
445
+ }
446
+ ]
447
+ }
448
+ ]
449
+ },
268
450
  "ai-portal.show-cases": {
269
451
  "properties": [
270
452
  {
@@ -549,6 +731,19 @@
549
731
  }
550
732
  }
551
733
  }
734
+ },
735
+ {
736
+ "name": "links",
737
+ "annotation": {
738
+ "type": "array",
739
+ "elementType": {
740
+ "type": "reference",
741
+ "typeName": {
742
+ "type": "identifier",
743
+ "name": "SidebarLink"
744
+ }
745
+ }
746
+ }
552
747
  }
553
748
  ],
554
749
  "events": [
@@ -592,20 +787,17 @@
592
787
  "types": [
593
788
  {
594
789
  "type": "interface",
595
- "name": "ActionClickDetail",
790
+ "name": "SidebarLink",
596
791
  "body": [
597
792
  {
598
793
  "type": "propertySignature",
599
794
  "key": {
600
795
  "type": "identifier",
601
- "name": "action"
796
+ "name": "title"
602
797
  },
603
798
  "annotation": {
604
- "type": "reference",
605
- "typeName": {
606
- "type": "identifier",
607
- "name": "SimpleActionType"
608
- }
799
+ "type": "keyword",
800
+ "value": "string"
609
801
  },
610
802
  "computed": false
611
803
  },
@@ -613,28 +805,7 @@
613
805
  "type": "propertySignature",
614
806
  "key": {
615
807
  "type": "identifier",
616
- "name": "item"
617
- },
618
- "annotation": {
619
- "type": "reference",
620
- "typeName": {
621
- "type": "identifier",
622
- "name": "HistoryItem"
623
- }
624
- },
625
- "computed": false
626
- }
627
- ]
628
- },
629
- {
630
- "type": "interface",
631
- "name": "HistoryItem",
632
- "body": [
633
- {
634
- "type": "propertySignature",
635
- "key": {
636
- "type": "identifier",
637
- "name": "id"
808
+ "name": "url"
638
809
  },
639
810
  "annotation": {
640
811
  "type": "keyword",
@@ -646,23 +817,35 @@
646
817
  "type": "propertySignature",
647
818
  "key": {
648
819
  "type": "identifier",
649
- "name": "title"
820
+ "name": "icon"
650
821
  },
651
822
  "annotation": {
652
- "type": "keyword",
653
- "value": "string"
823
+ "type": "reference",
824
+ "typeName": {
825
+ "type": "identifier",
826
+ "name": "GeneralIconProps"
827
+ }
654
828
  },
655
829
  "computed": false
656
- },
830
+ }
831
+ ]
832
+ },
833
+ {
834
+ "type": "interface",
835
+ "name": "ActionClickDetail",
836
+ "body": [
657
837
  {
658
838
  "type": "propertySignature",
659
839
  "key": {
660
840
  "type": "identifier",
661
- "name": "startTime"
841
+ "name": "action"
662
842
  },
663
843
  "annotation": {
664
- "type": "keyword",
665
- "value": "number"
844
+ "type": "reference",
845
+ "typeName": {
846
+ "type": "identifier",
847
+ "name": "SimpleActionType"
848
+ }
666
849
  },
667
850
  "computed": false
668
851
  },
@@ -670,96 +853,19 @@
670
853
  "type": "propertySignature",
671
854
  "key": {
672
855
  "type": "identifier",
673
- "name": "state"
856
+ "name": "item"
674
857
  },
675
858
  "annotation": {
676
859
  "type": "reference",
677
860
  "typeName": {
678
861
  "type": "identifier",
679
- "name": "TaskState"
862
+ "name": "HistoryItem"
680
863
  }
681
864
  },
682
- "optional": true,
683
865
  "computed": false
684
866
  }
685
867
  ]
686
- }
687
- ]
688
- },
689
- "ai-portal.chat-history": {
690
- "properties": [
691
- {
692
- "name": "list",
693
- "annotation": {
694
- "type": "array",
695
- "elementType": {
696
- "type": "reference",
697
- "typeName": {
698
- "type": "identifier",
699
- "name": "HistoryItem"
700
- }
701
- }
702
- }
703
868
  },
704
- {
705
- "name": "actions",
706
- "annotation": {
707
- "type": "array",
708
- "elementType": {
709
- "type": "reference",
710
- "typeName": {
711
- "type": "identifier",
712
- "name": "ActionType"
713
- }
714
- }
715
- }
716
- },
717
- {
718
- "name": "nextToken",
719
- "annotation": {
720
- "type": "keyword",
721
- "value": "string"
722
- }
723
- }
724
- ],
725
- "events": [
726
- {
727
- "name": "action.click",
728
- "detail": {
729
- "annotation": {
730
- "type": "reference",
731
- "typeName": {
732
- "type": "identifier",
733
- "name": "ActionClickDetail"
734
- }
735
- }
736
- }
737
- },
738
- {
739
- "name": "load.more",
740
- "detail": {
741
- "annotation": {
742
- "type": "typeLiteral",
743
- "members": [
744
- {
745
- "type": "propertySignature",
746
- "key": {
747
- "type": "identifier",
748
- "name": "nextToken"
749
- },
750
- "annotation": {
751
- "type": "keyword",
752
- "value": "string"
753
- },
754
- "computed": false
755
- }
756
- ]
757
- }
758
- }
759
- }
760
- ],
761
- "methods": [],
762
- "types": [
763
869
  {
764
870
  "type": "interface",
765
871
  "name": "HistoryItem",
@@ -776,18 +882,6 @@
776
882
  },
777
883
  "computed": false
778
884
  },
779
- {
780
- "type": "propertySignature",
781
- "key": {
782
- "type": "identifier",
783
- "name": "url"
784
- },
785
- "annotation": {
786
- "type": "keyword",
787
- "value": "string"
788
- },
789
- "computed": false
790
- },
791
885
  {
792
886
  "type": "propertySignature",
793
887
  "key": {
@@ -829,42 +923,6 @@
829
923
  "computed": false
830
924
  }
831
925
  ]
832
- },
833
- {
834
- "type": "interface",
835
- "name": "ActionClickDetail",
836
- "body": [
837
- {
838
- "type": "propertySignature",
839
- "key": {
840
- "type": "identifier",
841
- "name": "action"
842
- },
843
- "annotation": {
844
- "type": "reference",
845
- "typeName": {
846
- "type": "identifier",
847
- "name": "SimpleActionType"
848
- }
849
- },
850
- "computed": false
851
- },
852
- {
853
- "type": "propertySignature",
854
- "key": {
855
- "type": "identifier",
856
- "name": "item"
857
- },
858
- "annotation": {
859
- "type": "reference",
860
- "typeName": {
861
- "type": "identifier",
862
- "name": "HistoryItem"
863
- }
864
- },
865
- "computed": false
866
- }
867
- ]
868
926
  }
869
927
  ]
870
928
  },
@@ -3,5 +3,6 @@ import type { Job, TaskState } from "../../cruise-canvas/interfaces.js";
3
3
  export interface AssistantMessageProps {
4
4
  jobs: Job[];
5
5
  taskState: TaskState | undefined;
6
+ isLatest?: boolean;
6
7
  }
7
- export declare function AssistantMessage({ jobs, taskState }: AssistantMessageProps): React.JSX.Element;
8
+ export declare function AssistantMessage({ jobs, taskState, isLatest, }: AssistantMessageProps): React.JSX.Element;
@@ -1,3 +1,9 @@
1
1
  import type { Job, TaskBaseDetail } from "../cruise-canvas/interfaces.js";
2
2
  import type { ChatMessage } from "./interfaces.js";
3
- export declare function useChatStream(task: TaskBaseDetail | null | undefined, jobs: Job[] | null | undefined): ChatMessage[] | null;
3
+ export declare function useChatStream(task: TaskBaseDetail | null | undefined, jobs: Job[] | null | undefined): {
4
+ messages?: undefined;
5
+ inputRequiredJobId?: undefined;
6
+ } | {
7
+ messages: ChatMessage[];
8
+ inputRequiredJobId: string | null;
9
+ };
@@ -0,0 +1 @@
1
+ export declare function NodeLoading(): JSX.Element;
@@ -1,7 +1,6 @@
1
1
  export interface NodeRequirementProps {
2
2
  content?: string;
3
3
  startTime?: number;
4
- loading?: boolean;
5
4
  active?: boolean;
6
5
  }
7
- export declare function NodeRequirement({ content, startTime, loading, active, }: NodeRequirementProps): JSX.Element;
6
+ export declare function NodeRequirement({ content, startTime, active, }: NodeRequirementProps): JSX.Element;
@@ -1,11 +1,10 @@
1
- import type { GeneralIconProps } from "@next-bricks/icons/general-icon";
2
- import { type TaskState } from "./interfaces.js";
3
1
  export declare const DEFAULT_SCALE_RANGE_MIN = 0.5;
4
2
  export declare const DEFAULT_SCALE_RANGE_MAX = 2;
5
3
  export declare const START_NODE_ID = "<START>";
6
4
  export declare const END_NODE_ID = "<END>";
7
5
  export declare const FEEDBACK_NODE_ID = "<FEEDBACK>";
8
6
  export declare const REQUIREMENT_NODE_ID = "<REQUIREMENT>";
7
+ export declare const LOADING_NODE_ID = "<LOADING>";
9
8
  export declare const CANVAS_PADDING_TOP = 20;
10
9
  export declare const CANVAS_PADDING_RIGHT = 20;
11
10
  export declare const CANVAS_PADDING_BOTTOM = 122;
@@ -13,8 +12,4 @@ export declare const CANVAS_PADDING_LEFT = 160;
13
12
  export declare const RANK_SEP = 40;
14
13
  export declare const NODE_SEP = 42;
15
14
  export declare const EDGE_SEP = 10;
16
- export declare const DONE_STATES: TaskState[];
17
- export declare const GENERAL_DONE_STATES: TaskState[];
18
15
  export declare const IS_MAC: boolean;
19
- export declare const ICON_CLOSE: GeneralIconProps;
20
- export declare const ICON_LOADING: GeneralIconProps;
@@ -7,4 +7,5 @@ export declare function getOrderedJobs(jobs: Job[] | null | undefined, options?:
7
7
  jobMap: Map<string, Job>;
8
8
  jobLevels: Map<string, number>;
9
9
  downstreamMap: Map<string, string[]>;
10
+ originalDownstreamMap: Map<string, string[]> | undefined;
10
11
  };
@@ -12,11 +12,14 @@ export interface TransformLiteral {
12
12
  x: number;
13
13
  y: number;
14
14
  }
15
- export type GraphNode = RequirementGraphNode | InstructionGraphNode | JobGraphNode | ViewGraphNode | StartGraphNode | EndGraphNode | FeedbackGraphNode;
15
+ export type GraphNode = RequirementGraphNode | LoadingGraphNode | InstructionGraphNode | JobGraphNode | ViewGraphNode | StartGraphNode | EndGraphNode | FeedbackGraphNode;
16
16
  export interface RequirementGraphNode extends BaseGraphNode {
17
17
  type: "requirement";
18
18
  content: string;
19
19
  }
20
+ export interface LoadingGraphNode extends BaseGraphNode {
21
+ type: "loading";
22
+ }
20
23
  export interface InstructionGraphNode extends BaseGraphNode {
21
24
  type: "instruction";
22
25
  job: Job;
@@ -4,7 +4,8 @@ export declare enum K {
4
4
  TODAY = "TODAY",
5
5
  YESTERDAY = "YESTERDAY",
6
6
  PREVIOUS_7_DAYS = "PREVIOUS_7_DAYS",
7
- PREVIOUS_30_DAYS = "PREVIOUS_30_DAYS"
7
+ PREVIOUS_30_DAYS = "PREVIOUS_30_DAYS",
8
+ SWITCH_LANGUAGE = "SWITCH_LANGUAGE"
8
9
  }
9
10
  export declare const NS = "bricks/ai-portal/elevo-sidebar";
10
11
  export declare const locales: {
@@ -2,6 +2,7 @@ import React from "react";
2
2
  import { ReactNextElement } from "@next-core/react-element";
3
3
  import "@next-core/theme";
4
4
  import type { ActionType } from "@next-bricks/basic/mini-actions";
5
+ import type { GeneralIconProps } from "@next-bricks/icons/general-icon";
5
6
  export interface ElevoSidebarProps {
6
7
  userInstanceId?: string;
7
8
  behavior?: "default" | "drawer";
@@ -10,6 +11,12 @@ export interface ElevoSidebarProps {
10
11
  historyActiveId?: string;
11
12
  historyUrlTemplate?: string;
12
13
  historyActions?: ActionType[];
14
+ links?: SidebarLink[];
15
+ }
16
+ export interface SidebarLink {
17
+ title: string;
18
+ url: string;
19
+ icon: GeneralIconProps;
13
20
  }
14
21
  /**
15
22
  * 构件 `ai-portal.elevo-sidebar`
@@ -23,6 +30,7 @@ export declare class ElevoSidebar extends ReactNextElement implements ElevoSideb
23
30
  accessor historyActiveId: string | undefined;
24
31
  accessor historyUrlTemplate: string | undefined;
25
32
  accessor historyActions: ActionType[] | undefined;
33
+ accessor links: SidebarLink[] | undefined;
26
34
  /**
27
35
  * @param delay Delay in milliseconds before pulling the latest chat history.
28
36
  */
@@ -2,5 +2,6 @@ import type { TaskState } from "../../cruise-canvas/interfaces";
2
2
  export interface ChatBoxProps {
3
3
  taskState: TaskState | undefined;
4
4
  taskDone: boolean;
5
+ inputRequiredJobId?: string | null;
5
6
  }
6
- export declare function ChatBox({ taskState, taskDone }: ChatBoxProps): JSX.Element;
7
+ export declare function ChatBox({ taskState, taskDone, inputRequiredJobId, }: ChatBoxProps): JSX.Element;
@@ -2,5 +2,6 @@ import type { GeneralIconProps } from "@next-bricks/icons/general-icon";
2
2
  import type { TaskState } from "../cruise-canvas/interfaces.js";
3
3
  export declare const DONE_STATES: TaskState[];
4
4
  export declare const GENERAL_DONE_STATES: TaskState[];
5
+ export declare const NON_WORKING_STATES: string[];
5
6
  export declare const ICON_CLOSE: GeneralIconProps;
6
7
  export declare const ICON_LOADING: GeneralIconProps;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/ai-portal",
3
- "version": "0.22.0",
3
+ "version": "0.22.2",
4
4
  "homepage": "https://github.com/easyops-cn/next-advanced-bricks/tree/master/bricks/ai-portal",
5
5
  "repository": {
6
6
  "type": "git",
@@ -45,5 +45,5 @@
45
45
  "@next-bricks/mini-chart": "*",
46
46
  "@next-bricks/presentational": "*"
47
47
  },
48
- "gitHead": "7d60acec18c3ae561318d5612a3dbee1841140ff"
48
+ "gitHead": "8fd38337841d5adf918103aca1ce770ca951286d"
49
49
  }
@@ -1,2 +0,0 @@
1
- "use strict";(globalThis.webpackChunk_next_bricks_ai_portal=globalThis.webpackChunk_next_bricks_ai_portal||[]).push([[2052,3506],{5536:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(12559);function i(t,e,n){return n((0,r.A)(t,e))}},11369:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(17545);function i(t){var e=function(t){if("object"!=(0,r.A)(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=(0,r.A)(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==(0,r.A)(e)?e:e+""}},12559:(t,e,n)=>{function r(t,e,n){if("function"==typeof t?t===e:t.has(e))return arguments.length<3?e:n;throw new TypeError("Private element is not present on this object")}n.d(e,{A:()=>r})},17545:(t,e,n)=>{function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}n.d(e,{A:()=>r})},26902:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(17545);function i(t){if(Object(t)!==t)throw TypeError("right-hand side of 'in' should be an object, got "+(null!==t?(0,r.A)(t):"null"));return t}},36758:t=>{t.exports=function(t){return t[1]}},40935:t=>{t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var n="",r=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),r&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),r&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n})).join("")},e.i=function(t,n,r,i,o){"string"==typeof t&&(t=[[null,t,void 0]]);var s={};if(r)for(var c=0;c<this.length;c++){var a=this[c][0];null!=a&&(s[a]=!0)}for(var u=0;u<t.length;u++){var h=[].concat(t[u]);r&&s[h[0]]||(void 0!==o&&(void 0===h[5]||(h[1]="@layer".concat(h[5].length>0?" ".concat(h[5]):""," {").concat(h[1],"}")),h[5]=o),n&&(h[2]?(h[1]="@media ".concat(h[2]," {").concat(h[1],"}"),h[2]=n):h[2]=n),i&&(h[4]?(h[1]="@supports (".concat(h[4],") {").concat(h[1],"}"),h[4]=i):h[4]="".concat(i)),e.push(h))}},e}},62740:(t,e,n)=>{n.d(e,{A:()=>c});var r=n(17545),i=n(26902);function o(t,e,n){"symbol"==(0,r.A)(e)&&(e=(e=e.description)?"["+e+"]":"");try{Object.defineProperty(t,"name",{configurable:!0,value:n?n+" "+e:e})}catch(t){}return t}var s=n(11369);function c(t,e,n,c,a,u){var h,f,d,l,p,v,b,_=Symbol.metadata||Symbol.for("Symbol.metadata"),m=Object.defineProperty,y=Object.create,g=[y(null),y(null)],w=e.length;function A(e,n,r){return function(i,o){n&&(o=i,i=t);for(var s=0;s<e.length;s++)o=e[s].apply(i,r?[o]:[]);return r?o:i}}function O(t,e,n,r){if("function"!=typeof t&&(r||void 0!==t))throw new TypeError(e+" must "+(n||"be")+" a function"+(r?"":" or undefined"));return t}function E(t,e,n,i,s,c,a,u,d,l,p){function v(t){if(!p(t))throw new TypeError("Attempted to access private element on non-instance")}var b=[].concat(e[0]),_=e[3],y=!a,w=1===s,E=3===s,M=4===s,T=2===s;function j(e,n,r){return function(i,o){return n&&(o=i,i=t),r&&r(i),S[e].call(i,o)}}if(!y){var S={},x=[],k=E?"get":M||w?"set":"value";if(d?(l||w?S={get:o((function(){return _(this)}),i,"get"),set:function(t){e[4](this,t)}}:S[k]=_,l||o(S[k],i,T?"":k)):l||(S=Object.getOwnPropertyDescriptor(t,i)),!l&&!d){if((f=g[+u][i])&&7!=(f^s))throw Error("Decorating two elements with the same name ("+S[k].name+") is not supported yet");g[+u][i]=s<3?1:s}}for(var z=t,R=b.length-1;R>=0;R-=n?2:1){var D=O(b[R],"A decorator","be",!0),P=n?b[R-1]:void 0,C={},L={kind:["field","accessor","method","getter","setter","class"][s],name:i,metadata:h,addInitializer:function(t,e){if(t.v)throw Error("attempted to call addInitializer after decoration was finished");O(e,"An initializer","be",!0),c.push(e)}.bind(null,C)};if(y)f=D.call(P,z,L),C.v=1,O(f,"class decorators","return")&&(z=f);else if(L.static=u,L.private=d,f=L.access={has:d?p.bind():function(t){return i in t}},M||(f.get=d?T?function(t){return v(t),S.value}:j("get",0,v):function(t){return t[i]}),T||E||(f.set=d?j("set",0,v):function(t,e){t[i]=e}),z=D.call(P,w?{get:S.get,set:S.set}:S[k],L),C.v=1,w){if("object"==(0,r.A)(z)&&z)(f=O(z.get,"accessor.get"))&&(S.get=f),(f=O(z.set,"accessor.set"))&&(S.set=f),(f=O(z.init,"accessor.init"))&&x.unshift(f);else if(void 0!==z)throw new TypeError("accessor decorators must return an object with get, set, or init properties or undefined")}else O(z,(l?"field":"method")+" decorators","return")&&(l?x.unshift(z):S[k]=z)}return s<2&&a.push(A(x,u,1),A(c,u,0)),l||y||(d?w?a.splice(-1,0,j("get",u),j("set",u)):a.push(T?S[k]:O.call.bind(S[k])):m(t,i,S)),z}function M(t){return m(t,_,{configurable:!0,enumerable:!0,value:h})}return void 0!==u&&(h=u[_]),h=y(null==h?null:h),p=[],v=function(t){t&&p.push(A(t))},b=function(e,r){for(var o=0;o<n.length;o++){var c=n[o],u=c[1],h=7&u;if((8&u)==e&&!h==r){var f=c[2],v=!!c[3],b=16&u;E(e?t:t.prototype,c,b,v?"#"+f:(0,s.A)(f),h,h<2?[]:e?l=l||[]:d=d||[],p,!!e,v,r,e&&v?function(e){return(0,i.A)(e)===t}:a)}}},b(8,0),b(0,0),b(8,1),b(0,1),v(d),v(l),f=p,w||M(t),{e:f,get c(){var n=[];return w&&[M(t=E(t,[e],c,t.name,5,n)),A(n,1)]}}}},70829:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(12559);function i(t,e){return t.get((0,r.A)(t,e))}},70918:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(72016);function i(t,e,n){(0,r.A)(t,e),e.set(t,n)}},72016:(t,e,n)=>{function r(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}n.d(e,{A:()=>r})},74635:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(72016);function i(t,e){(0,r.A)(t,e),e.add(t)}},86121:(t,e,n)=>{n.d(e,{A:()=>i});var r=n(12559);function i(t,e,n){return t.set((0,r.A)(t,e),n),n}},89575:(t,e,n)=>{function r(){return r=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},r.apply(this,arguments)}n.d(e,{A:()=>r})},99126:(t,e,n)=>{n.d(e,{A:()=>O});var r=function(){if("undefined"!=typeof Map)return Map;function t(t,e){var n=-1;return t.some((function(t,r){return t[0]===e&&(n=r,!0)})),n}return function(){function e(){this.__entries__=[]}return Object.defineProperty(e.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),e.prototype.get=function(e){var n=t(this.__entries__,e),r=this.__entries__[n];return r&&r[1]},e.prototype.set=function(e,n){var r=t(this.__entries__,e);~r?this.__entries__[r][1]=n:this.__entries__.push([e,n])},e.prototype.delete=function(e){var n=this.__entries__,r=t(n,e);~r&&n.splice(r,1)},e.prototype.has=function(e){return!!~t(this.__entries__,e)},e.prototype.clear=function(){this.__entries__.splice(0)},e.prototype.forEach=function(t,e){void 0===e&&(e=null);for(var n=0,r=this.__entries__;n<r.length;n++){var i=r[n];t.call(e,i[1],i[0])}},e}()}(),i="undefined"!=typeof window&&"undefined"!=typeof document&&window.document===document,o=void 0!==n.g&&n.g.Math===Math?n.g:"undefined"!=typeof self&&self.Math===Math?self:"undefined"!=typeof window&&window.Math===Math?window:Function("return this")(),s="function"==typeof requestAnimationFrame?requestAnimationFrame.bind(o):function(t){return setTimeout((function(){return t(Date.now())}),1e3/60)},c=["top","right","bottom","left","width","height","size","weight"],a="undefined"!=typeof MutationObserver,u=function(){function t(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=function(t){var e=!1,n=!1,r=0;function i(){e&&(e=!1,t()),n&&c()}function o(){s(i)}function c(){var t=Date.now();if(e){if(t-r<2)return;n=!0}else e=!0,n=!1,setTimeout(o,20);r=t}return c}(this.refresh.bind(this))}return t.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},t.prototype.removeObserver=function(t){var e=this.observers_,n=e.indexOf(t);~n&&e.splice(n,1),!e.length&&this.connected_&&this.disconnect_()},t.prototype.refresh=function(){this.updateObservers_()&&this.refresh()},t.prototype.updateObservers_=function(){var t=this.observers_.filter((function(t){return t.gatherActive(),t.hasActive()}));return t.forEach((function(t){return t.broadcastActive()})),t.length>0},t.prototype.connect_=function(){i&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),a?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},t.prototype.disconnect_=function(){i&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},t.prototype.onTransitionEnd_=function(t){var e=t.propertyName,n=void 0===e?"":e;c.some((function(t){return!!~n.indexOf(t)}))&&this.refresh()},t.getInstance=function(){return this.instance_||(this.instance_=new t),this.instance_},t.instance_=null,t}(),h=function(t,e){for(var n=0,r=Object.keys(e);n<r.length;n++){var i=r[n];Object.defineProperty(t,i,{value:e[i],enumerable:!1,writable:!1,configurable:!0})}return t},f=function(t){return t&&t.ownerDocument&&t.ownerDocument.defaultView||o},d=_(0,0,0,0);function l(t){return parseFloat(t)||0}function p(t){for(var e=[],n=1;n<arguments.length;n++)e[n-1]=arguments[n];return e.reduce((function(e,n){return e+l(t["border-"+n+"-width"])}),0)}var v="undefined"!=typeof SVGGraphicsElement?function(t){return t instanceof f(t).SVGGraphicsElement}:function(t){return t instanceof f(t).SVGElement&&"function"==typeof t.getBBox};function b(t){return i?v(t)?function(t){var e=t.getBBox();return _(0,0,e.width,e.height)}(t):function(t){var e=t.clientWidth,n=t.clientHeight;if(!e&&!n)return d;var r=f(t).getComputedStyle(t),i=function(t){for(var e={},n=0,r=["top","right","bottom","left"];n<r.length;n++){var i=r[n],o=t["padding-"+i];e[i]=l(o)}return e}(r),o=i.left+i.right,s=i.top+i.bottom,c=l(r.width),a=l(r.height);if("border-box"===r.boxSizing&&(Math.round(c+o)!==e&&(c-=p(r,"left","right")+o),Math.round(a+s)!==n&&(a-=p(r,"top","bottom")+s)),!function(t){return t===f(t).document.documentElement}(t)){var u=Math.round(c+o)-e,h=Math.round(a+s)-n;1!==Math.abs(u)&&(c-=u),1!==Math.abs(h)&&(a-=h)}return _(i.left,i.top,c,a)}(t):d}function _(t,e,n,r){return{x:t,y:e,width:n,height:r}}var m=function(){function t(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=_(0,0,0,0),this.target=t}return t.prototype.isActive=function(){var t=b(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},t.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t},t}(),y=function(t,e){var n,r,i,o,s,c,a,u=(r=(n=e).x,i=n.y,o=n.width,s=n.height,c="undefined"!=typeof DOMRectReadOnly?DOMRectReadOnly:Object,a=Object.create(c.prototype),h(a,{x:r,y:i,width:o,height:s,top:i,right:r+o,bottom:s+i,left:r}),a);h(this,{target:t,contentRect:u})},g=function(){function t(t,e,n){if(this.activeObservations_=[],this.observations_=new r,"function"!=typeof t)throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=e,this.callbackCtx_=n}return t.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof f(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)||(e.set(t,new m(t)),this.controller_.addObserver(this),this.controller_.refresh())}},t.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if("undefined"!=typeof Element&&Element instanceof Object){if(!(t instanceof f(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var e=this.observations_;e.has(t)&&(e.delete(t),e.size||this.controller_.removeObserver(this))}},t.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},t.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach((function(e){e.isActive()&&t.activeObservations_.push(e)}))},t.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,e=this.activeObservations_.map((function(t){return new y(t.target,t.broadcastRect())}));this.callback_.call(t,e,t),this.clearActive()}},t.prototype.clearActive=function(){this.activeObservations_.splice(0)},t.prototype.hasActive=function(){return this.activeObservations_.length>0},t}(),w="undefined"!=typeof WeakMap?new WeakMap:new r,A=function t(e){if(!(this instanceof t))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=u.getInstance(),r=new g(e,n,this);w.set(this,r)};["observe","unobserve","disconnect"].forEach((function(t){A.prototype[t]=function(){var e;return(e=w.get(this))[t].apply(e,arguments)}}));const O=void 0!==o.ResizeObserver?o.ResizeObserver:A}}]);
2
- //# sourceMappingURL=3506.da6e43af.js.map