@robot-admin/naive-ui-components 0.20.0 → 0.21.1

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 (179) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +5 -5
  3. package/README_EN.md +5 -5
  4. package/SECURITY.md +39 -0
  5. package/dist/C_AntV.css +31 -31
  6. package/dist/C_AntV2.cjs +1 -1
  7. package/dist/C_AntV2.js +1 -1
  8. package/dist/C_Chat.css +90 -90
  9. package/dist/C_Chat2.cjs +1 -1
  10. package/dist/C_Chat2.js +1 -1
  11. package/dist/C_CollapsePanel2.cjs +1 -1
  12. package/dist/C_CollapsePanel2.js +1 -1
  13. package/dist/C_Draggable.css +53 -53
  14. package/dist/C_Draggable2.cjs +1 -1
  15. package/dist/C_Draggable2.js +1 -1
  16. package/dist/C_FilePreview.css +98 -98
  17. package/dist/C_FilePreview.d.cts +2 -2
  18. package/dist/C_FilePreview.d.ts +2 -2
  19. package/dist/C_FilePreview2.cjs +1 -1
  20. package/dist/C_FilePreview2.js +1 -1
  21. package/dist/C_Form.base.css +9 -9
  22. package/dist/C_Form.css +9 -9
  23. package/dist/C_FormSearch.css +52 -52
  24. package/dist/C_FormSearch2.cjs +1 -1
  25. package/dist/C_FormSearch2.js +1 -1
  26. package/dist/C_Language.css +2 -2
  27. package/dist/C_Language2.cjs +1 -1
  28. package/dist/C_Language2.js +1 -1
  29. package/dist/C_Login.css +79 -79
  30. package/dist/C_Login2.cjs +1 -1
  31. package/dist/C_Login2.js +1 -1
  32. package/dist/C_Markdown.css +1 -2
  33. package/dist/C_Menu.css +1 -1
  34. package/dist/C_Menu.d.cts +2 -2
  35. package/dist/C_Menu.d.ts +2 -2
  36. package/dist/C_Menu2.cjs +1 -1
  37. package/dist/C_Menu2.js +1 -1
  38. package/dist/C_NotificationCenter.css +124 -124
  39. package/dist/C_NotificationCenter.d.cts +2 -2
  40. package/dist/C_NotificationCenter.d.ts +2 -2
  41. package/dist/C_NotificationCenter2.cjs +1 -1
  42. package/dist/C_NotificationCenter2.js +1 -1
  43. package/dist/C_Skeleton.css +2 -2
  44. package/dist/C_Skeleton2.cjs +1 -1
  45. package/dist/C_Skeleton2.js +1 -1
  46. package/dist/C_SplitPane.css +66 -66
  47. package/dist/C_SplitPane2.cjs +1 -1
  48. package/dist/C_SplitPane2.js +1 -1
  49. package/dist/C_Table.base.css +9 -9
  50. package/dist/C_Table.css +9 -9
  51. package/dist/C_Table.d.ts +1 -0
  52. package/dist/C_Theme2.cjs +1 -1
  53. package/dist/C_Theme2.js +1 -1
  54. package/dist/C_Timeline.css +46 -46
  55. package/dist/C_Timeline2.cjs +1 -1
  56. package/dist/C_Timeline2.js +1 -1
  57. package/dist/C_Transfer.css +26 -26
  58. package/dist/C_Transfer2.cjs +1 -1
  59. package/dist/C_Transfer2.js +1 -1
  60. package/dist/C_Tree.css +23 -23
  61. package/dist/C_Tree.d.ts +1 -0
  62. package/dist/C_Tree2.cjs +1 -1
  63. package/dist/C_Tree2.js +1 -1
  64. package/dist/C_Upload2.cjs +1 -1
  65. package/dist/C_Upload2.js +1 -1
  66. package/dist/C_VideoPlayer.d.cts +2 -2
  67. package/dist/C_VideoPlayer.d.ts +2 -2
  68. package/dist/C_VideoPlayer2.cjs +2 -2
  69. package/dist/C_VideoPlayer2.js +2 -2
  70. package/dist/C_WaterFall.css +31 -29
  71. package/dist/C_WaterFall2.cjs +1 -1
  72. package/dist/C_WaterFall2.js +1 -1
  73. package/dist/C_WorkFlow.css +112 -111
  74. package/dist/C_WorkFlow2.cjs +1 -1
  75. package/dist/C_WorkFlow2.js +1 -1
  76. package/dist/config.cjs +1 -0
  77. package/dist/config.d.cts +8 -0
  78. package/dist/config.d.ts +8 -0
  79. package/dist/config.js +1 -0
  80. package/dist/constants.d.cts +1 -1
  81. package/dist/constants.d.ts +1 -1
  82. package/dist/constants2.d.cts +1 -1
  83. package/dist/constants2.d.ts +1 -1
  84. package/dist/constants3.d.cts +32 -9
  85. package/dist/constants3.d.ts +32 -9
  86. package/dist/constants4.d.cts +16 -5
  87. package/dist/constants4.d.ts +16 -5
  88. package/dist/constants5.d.cts +22 -18
  89. package/dist/constants5.d.ts +22 -18
  90. package/dist/data.d.cts +6 -6
  91. package/dist/data.d.ts +6 -6
  92. package/dist/dateRange.d.cts +2 -0
  93. package/dist/dateRange.d.ts +2 -0
  94. package/dist/feedback.cjs +1 -1
  95. package/dist/feedback.js +1 -1
  96. package/dist/helpers.cjs +1 -1
  97. package/dist/helpers.js +1 -1
  98. package/dist/index.cjs +1 -1
  99. package/dist/index.d.cts +7 -6
  100. package/dist/index.d.ts +8 -6
  101. package/dist/index.js +1 -1
  102. package/dist/index.vue.d.cts +5 -5
  103. package/dist/index.vue.d.ts +5 -5
  104. package/dist/index10.vue.d.cts +3 -3
  105. package/dist/index10.vue.d.ts +2 -2
  106. package/dist/index11.vue.d.cts +2 -2
  107. package/dist/index11.vue.d.ts +2 -2
  108. package/dist/index12.vue.d.cts +2 -2
  109. package/dist/index12.vue.d.ts +3 -3
  110. package/dist/index13.vue.d.cts +3 -3
  111. package/dist/index13.vue.d.ts +8 -8
  112. package/dist/index14.vue.d.cts +8 -8
  113. package/dist/index14.vue.d.ts +0 -1
  114. package/dist/index15.vue.d.cts +0 -1
  115. package/dist/index15.vue.d.ts +1 -1
  116. package/dist/index16.vue.d.cts +1 -1
  117. package/dist/index16.vue.d.ts +1 -1
  118. package/dist/index17.vue.d.cts +1 -1
  119. package/dist/index17.vue.d.ts +2 -2
  120. package/dist/index18.vue.d.cts +2 -2
  121. package/dist/index18.vue.d.ts +44 -40
  122. package/dist/index19.vue.d.cts +3 -3
  123. package/dist/index19.vue.d.ts +3 -3
  124. package/dist/index20.vue.d.cts +3 -3
  125. package/dist/index20.vue.d.ts +3 -3
  126. package/dist/index21.vue.d.cts +2 -2
  127. package/dist/index21.vue.d.ts +2 -2
  128. package/dist/index25.vue.d.cts +0 -1
  129. package/dist/index25.vue.d.ts +0 -1
  130. package/dist/index26.vue.d.cts +3 -3
  131. package/dist/index26.vue.d.ts +3 -3
  132. package/dist/index3.vue.d.cts +3 -3
  133. package/dist/index3.vue.d.ts +3 -3
  134. package/dist/index4.vue.d.cts +44 -40
  135. package/dist/index6.vue.d.ts +0 -2
  136. package/dist/index7.vue.d.cts +0 -2
  137. package/dist/index8.vue.d.ts +3 -3
  138. package/dist/index9.vue.d.cts +3 -3
  139. package/dist/index9.vue.d.ts +3 -3
  140. package/dist/mapUtils.d.cts +2 -2
  141. package/dist/mapUtils.d.ts +2 -2
  142. package/dist/style.css +848 -846
  143. package/dist/useCalendarEvents.d.cts +1 -1
  144. package/dist/useCalendarEvents.d.ts +1 -1
  145. package/dist/useCollapsePanel.d.cts +3 -3
  146. package/dist/useCollapsePanel.d.ts +3 -3
  147. package/dist/useComponentLocale.cjs +1 -1
  148. package/dist/useComponentLocale.js +1 -1
  149. package/dist/useCropperCore.d.cts +8 -8
  150. package/dist/useCropperCore.d.ts +8 -8
  151. package/dist/useDraggableLayout.d.cts +1 -0
  152. package/dist/useDraggableLayout.d.ts +1 -0
  153. package/dist/useEdgeInteraction.d.cts +3 -3
  154. package/dist/useEdgeInteraction.d.ts +3 -3
  155. package/dist/useFullscreen.d.cts +41 -23
  156. package/dist/useFullscreen.d.ts +41 -23
  157. package/dist/useInfiniteScroll.d.cts +7 -5
  158. package/dist/useInfiniteScroll.d.ts +7 -5
  159. package/dist/useQRCode.d.cts +4 -4
  160. package/dist/useQRCode.d.ts +4 -4
  161. package/dist/useSignatureHistory.d.cts +4 -4
  162. package/dist/useSignatureHistory.d.ts +4 -4
  163. package/dist/useSplitResize.d.cts +3 -4
  164. package/dist/useSplitResize.d.ts +3 -4
  165. package/dist/useTableQuery.cjs +1 -1
  166. package/dist/useTableQuery.d.cts +8 -12
  167. package/dist/useTableQuery.d.ts +8 -12
  168. package/dist/useTableQuery.js +1 -1
  169. package/dist/useWorkflowValidation.d.cts +105 -97
  170. package/dist/useWorkflowValidation.d.ts +105 -97
  171. package/dist/verification.d.cts +6 -6
  172. package/dist/verification.d.ts +6 -6
  173. package/docs/architecture.en.md +3 -1
  174. package/docs/architecture.md +3 -1
  175. package/docs/guides/usage.en.md +16 -0
  176. package/docs/guides/usage.md +56 -0
  177. package/package.json +27 -10
  178. package/dist/context.cjs +0 -1
  179. package/dist/context.js +0 -1
@@ -1,5 +1,6 @@
1
1
  import * as vue from "vue";
2
2
  import { Component, Ref } from "vue";
3
+ import { Connection, EdgeChange, EdgeUpdateEvent, NodeChange } from "@vue-flow/core";
3
4
 
4
5
  //#region src/components/C_WorkFlow/types.d.ts
5
6
  /**
@@ -272,8 +273,8 @@ declare const __VLS_export: vue.DefineComponent<WorkflowProps, {
272
273
  "onNode-click"?: ((node: WorkflowNode<NodeType>) => any) | undefined;
273
274
  "onEdge-click"?: ((edge: WorkflowEdge) => any) | undefined;
274
275
  }>, {
275
- readonly: boolean;
276
276
  theme: "light" | "dark";
277
+ readonly: boolean;
277
278
  users: User[];
278
279
  roles: Role[];
279
280
  departments: Department[];
@@ -303,19 +304,10 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
303
304
  zIndex?: number | undefined;
304
305
  extent?: "parent" | [[number, number], [number, number]] | undefined;
305
306
  expandParent?: boolean | undefined;
306
- type: "copy";
307
+ type: "start";
307
308
  data: {
308
- copyUsers?: {
309
- id: string;
310
- name: string;
311
- avatar?: string | undefined;
312
- department: string;
313
- role: string;
314
- email?: string | undefined;
315
- phone?: string | undefined;
316
- }[] | undefined;
317
309
  title: string;
318
- status?: NodeStatus | undefined;
310
+ status: "active";
319
311
  config?: Record<string, unknown> | undefined;
320
312
  initiators?: {
321
313
  id: string;
@@ -345,10 +337,20 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
345
337
  zIndex?: number | undefined;
346
338
  extent?: "parent" | [[number, number], [number, number]] | undefined;
347
339
  expandParent?: boolean | undefined;
348
- type: "start";
340
+ type: "approval";
349
341
  data: {
342
+ approvers?: {
343
+ id: string;
344
+ name: string;
345
+ avatar?: string | undefined;
346
+ department: string;
347
+ role: string;
348
+ email?: string | undefined;
349
+ phone?: string | undefined;
350
+ }[] | undefined;
351
+ approvalMode?: ApprovalMode | undefined;
350
352
  title: string;
351
- status: "active";
353
+ status?: NodeStatus | undefined;
352
354
  config?: Record<string, unknown> | undefined;
353
355
  initiators?: {
354
356
  id: string;
@@ -378,9 +380,9 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
378
380
  zIndex?: number | undefined;
379
381
  extent?: "parent" | [[number, number], [number, number]] | undefined;
380
382
  expandParent?: boolean | undefined;
381
- type: "approval";
383
+ type: "copy";
382
384
  data: {
383
- approvers?: {
385
+ copyUsers?: {
384
386
  id: string;
385
387
  name: string;
386
388
  avatar?: string | undefined;
@@ -389,7 +391,6 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
389
391
  email?: string | undefined;
390
392
  phone?: string | undefined;
391
393
  }[] | undefined;
392
- approvalMode?: ApprovalMode | undefined;
393
394
  title: string;
394
395
  status?: NodeStatus | undefined;
395
396
  config?: Record<string, unknown> | undefined;
@@ -461,19 +462,10 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
461
462
  zIndex?: number | undefined;
462
463
  extent?: "parent" | [[number, number], [number, number]] | undefined;
463
464
  expandParent?: boolean | undefined;
464
- type: "copy";
465
+ type: "start";
465
466
  data: {
466
- copyUsers?: {
467
- id: string;
468
- name: string;
469
- avatar?: string | undefined;
470
- department: string;
471
- role: string;
472
- email?: string | undefined;
473
- phone?: string | undefined;
474
- }[] | undefined;
475
467
  title: string;
476
- status?: NodeStatus | undefined;
468
+ status: "active";
477
469
  config?: Record<string, unknown> | undefined;
478
470
  initiators?: {
479
471
  id: string;
@@ -503,10 +495,20 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
503
495
  zIndex?: number | undefined;
504
496
  extent?: "parent" | [[number, number], [number, number]] | undefined;
505
497
  expandParent?: boolean | undefined;
506
- type: "start";
498
+ type: "approval";
507
499
  data: {
500
+ approvers?: {
501
+ id: string;
502
+ name: string;
503
+ avatar?: string | undefined;
504
+ department: string;
505
+ role: string;
506
+ email?: string | undefined;
507
+ phone?: string | undefined;
508
+ }[] | undefined;
509
+ approvalMode?: ApprovalMode | undefined;
508
510
  title: string;
509
- status: "active";
511
+ status?: NodeStatus | undefined;
510
512
  config?: Record<string, unknown> | undefined;
511
513
  initiators?: {
512
514
  id: string;
@@ -536,9 +538,9 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
536
538
  zIndex?: number | undefined;
537
539
  extent?: "parent" | [[number, number], [number, number]] | undefined;
538
540
  expandParent?: boolean | undefined;
539
- type: "approval";
541
+ type: "copy";
540
542
  data: {
541
- approvers?: {
543
+ copyUsers?: {
542
544
  id: string;
543
545
  name: string;
544
546
  avatar?: string | undefined;
@@ -547,7 +549,6 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
547
549
  email?: string | undefined;
548
550
  phone?: string | undefined;
549
551
  }[] | undefined;
550
- approvalMode?: ApprovalMode | undefined;
551
552
  title: string;
552
553
  status?: NodeStatus | undefined;
553
554
  config?: Record<string, unknown> | undefined;
@@ -672,19 +673,10 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
672
673
  zIndex?: number | undefined;
673
674
  extent?: "parent" | [[number, number], [number, number]] | undefined;
674
675
  expandParent?: boolean | undefined;
675
- type: "copy";
676
+ type: "start";
676
677
  data: {
677
- copyUsers?: {
678
- id: string;
679
- name: string;
680
- avatar?: string | undefined;
681
- department: string;
682
- role: string;
683
- email?: string | undefined;
684
- phone?: string | undefined;
685
- }[] | undefined;
686
678
  title: string;
687
- status?: NodeStatus | undefined;
679
+ status: "active";
688
680
  config?: Record<string, unknown> | undefined;
689
681
  initiators?: {
690
682
  id: string;
@@ -714,10 +706,20 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
714
706
  zIndex?: number | undefined;
715
707
  extent?: "parent" | [[number, number], [number, number]] | undefined;
716
708
  expandParent?: boolean | undefined;
717
- type: "start";
709
+ type: "approval";
718
710
  data: {
711
+ approvers?: {
712
+ id: string;
713
+ name: string;
714
+ avatar?: string | undefined;
715
+ department: string;
716
+ role: string;
717
+ email?: string | undefined;
718
+ phone?: string | undefined;
719
+ }[] | undefined;
720
+ approvalMode?: ApprovalMode | undefined;
719
721
  title: string;
720
- status: "active";
722
+ status?: NodeStatus | undefined;
721
723
  config?: Record<string, unknown> | undefined;
722
724
  initiators?: {
723
725
  id: string;
@@ -747,9 +749,9 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
747
749
  zIndex?: number | undefined;
748
750
  extent?: "parent" | [[number, number], [number, number]] | undefined;
749
751
  expandParent?: boolean | undefined;
750
- type: "approval";
752
+ type: "copy";
751
753
  data: {
752
- approvers?: {
754
+ copyUsers?: {
753
755
  id: string;
754
756
  name: string;
755
757
  avatar?: string | undefined;
@@ -758,7 +760,6 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
758
760
  email?: string | undefined;
759
761
  phone?: string | undefined;
760
762
  }[] | undefined;
761
- approvalMode?: ApprovalMode | undefined;
762
763
  title: string;
763
764
  status?: NodeStatus | undefined;
764
765
  config?: Record<string, unknown> | undefined;
@@ -830,19 +831,10 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
830
831
  zIndex?: number | undefined;
831
832
  extent?: "parent" | [[number, number], [number, number]] | undefined;
832
833
  expandParent?: boolean | undefined;
833
- type: "copy";
834
+ type: "start";
834
835
  data: {
835
- copyUsers?: {
836
- id: string;
837
- name: string;
838
- avatar?: string | undefined;
839
- department: string;
840
- role: string;
841
- email?: string | undefined;
842
- phone?: string | undefined;
843
- }[] | undefined;
844
836
  title: string;
845
- status?: NodeStatus | undefined;
837
+ status: "active";
846
838
  config?: Record<string, unknown> | undefined;
847
839
  initiators?: {
848
840
  id: string;
@@ -872,10 +864,20 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
872
864
  zIndex?: number | undefined;
873
865
  extent?: "parent" | [[number, number], [number, number]] | undefined;
874
866
  expandParent?: boolean | undefined;
875
- type: "start";
867
+ type: "approval";
876
868
  data: {
869
+ approvers?: {
870
+ id: string;
871
+ name: string;
872
+ avatar?: string | undefined;
873
+ department: string;
874
+ role: string;
875
+ email?: string | undefined;
876
+ phone?: string | undefined;
877
+ }[] | undefined;
878
+ approvalMode?: ApprovalMode | undefined;
877
879
  title: string;
878
- status: "active";
880
+ status?: NodeStatus | undefined;
879
881
  config?: Record<string, unknown> | undefined;
880
882
  initiators?: {
881
883
  id: string;
@@ -905,9 +907,9 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
905
907
  zIndex?: number | undefined;
906
908
  extent?: "parent" | [[number, number], [number, number]] | undefined;
907
909
  expandParent?: boolean | undefined;
908
- type: "approval";
910
+ type: "copy";
909
911
  data: {
910
- approvers?: {
912
+ copyUsers?: {
911
913
  id: string;
912
914
  name: string;
913
915
  avatar?: string | undefined;
@@ -916,7 +918,6 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
916
918
  email?: string | undefined;
917
919
  phone?: string | undefined;
918
920
  }[] | undefined;
919
- approvalMode?: ApprovalMode | undefined;
920
921
  title: string;
921
922
  status?: NodeStatus | undefined;
922
923
  config?: Record<string, unknown> | undefined;
@@ -978,6 +979,13 @@ declare function useWorkflowNodes(props: WorkflowProps, emit: EmitFn$1, vueFlowR
978
979
  copyNodes: number;
979
980
  conditionNodes: number;
980
981
  }>;
982
+ commitCanvasChange: () => void;
983
+ handleCanvasChanges: (changes: NodeChange[] | EdgeChange[]) => void;
984
+ connectNodes: (connection: Connection) => void;
985
+ updateConnection: ({
986
+ edge,
987
+ connection
988
+ }: EdgeUpdateEvent) => void;
981
989
  addNode: (type: NodeType) => void;
982
990
  onNodeClick: (event: {
983
991
  node: {
@@ -1047,19 +1055,10 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1047
1055
  zIndex?: number | undefined;
1048
1056
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1049
1057
  expandParent?: boolean | undefined;
1050
- type: "copy";
1058
+ type: "start";
1051
1059
  data: {
1052
- copyUsers?: {
1053
- id: string;
1054
- name: string;
1055
- avatar?: string | undefined;
1056
- department: string;
1057
- role: string;
1058
- email?: string | undefined;
1059
- phone?: string | undefined;
1060
- }[] | undefined;
1061
1060
  title: string;
1062
- status?: NodeStatus | undefined;
1061
+ status: "active";
1063
1062
  config?: Record<string, unknown> | undefined;
1064
1063
  initiators?: {
1065
1064
  id: string;
@@ -1089,10 +1088,20 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1089
1088
  zIndex?: number | undefined;
1090
1089
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1091
1090
  expandParent?: boolean | undefined;
1092
- type: "start";
1091
+ type: "approval";
1093
1092
  data: {
1093
+ approvers?: {
1094
+ id: string;
1095
+ name: string;
1096
+ avatar?: string | undefined;
1097
+ department: string;
1098
+ role: string;
1099
+ email?: string | undefined;
1100
+ phone?: string | undefined;
1101
+ }[] | undefined;
1102
+ approvalMode?: ApprovalMode | undefined;
1094
1103
  title: string;
1095
- status: "active";
1104
+ status?: NodeStatus | undefined;
1096
1105
  config?: Record<string, unknown> | undefined;
1097
1106
  initiators?: {
1098
1107
  id: string;
@@ -1122,9 +1131,9 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1122
1131
  zIndex?: number | undefined;
1123
1132
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1124
1133
  expandParent?: boolean | undefined;
1125
- type: "approval";
1134
+ type: "copy";
1126
1135
  data: {
1127
- approvers?: {
1136
+ copyUsers?: {
1128
1137
  id: string;
1129
1138
  name: string;
1130
1139
  avatar?: string | undefined;
@@ -1133,7 +1142,6 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1133
1142
  email?: string | undefined;
1134
1143
  phone?: string | undefined;
1135
1144
  }[] | undefined;
1136
- approvalMode?: ApprovalMode | undefined;
1137
1145
  title: string;
1138
1146
  status?: NodeStatus | undefined;
1139
1147
  config?: Record<string, unknown> | undefined;
@@ -1222,19 +1230,10 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1222
1230
  zIndex?: number | undefined;
1223
1231
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1224
1232
  expandParent?: boolean | undefined;
1225
- type: "copy";
1233
+ type: "start";
1226
1234
  data: {
1227
- copyUsers?: {
1228
- id: string;
1229
- name: string;
1230
- avatar?: string | undefined;
1231
- department: string;
1232
- role: string;
1233
- email?: string | undefined;
1234
- phone?: string | undefined;
1235
- }[] | undefined;
1236
1235
  title: string;
1237
- status?: NodeStatus | undefined;
1236
+ status: "active";
1238
1237
  config?: Record<string, unknown> | undefined;
1239
1238
  initiators?: {
1240
1239
  id: string;
@@ -1264,10 +1263,20 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1264
1263
  zIndex?: number | undefined;
1265
1264
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1266
1265
  expandParent?: boolean | undefined;
1267
- type: "start";
1266
+ type: "approval";
1268
1267
  data: {
1268
+ approvers?: {
1269
+ id: string;
1270
+ name: string;
1271
+ avatar?: string | undefined;
1272
+ department: string;
1273
+ role: string;
1274
+ email?: string | undefined;
1275
+ phone?: string | undefined;
1276
+ }[] | undefined;
1277
+ approvalMode?: ApprovalMode | undefined;
1269
1278
  title: string;
1270
- status: "active";
1279
+ status?: NodeStatus | undefined;
1271
1280
  config?: Record<string, unknown> | undefined;
1272
1281
  initiators?: {
1273
1282
  id: string;
@@ -1297,9 +1306,9 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1297
1306
  zIndex?: number | undefined;
1298
1307
  extent?: "parent" | [[number, number], [number, number]] | undefined;
1299
1308
  expandParent?: boolean | undefined;
1300
- type: "approval";
1309
+ type: "copy";
1301
1310
  data: {
1302
- approvers?: {
1311
+ copyUsers?: {
1303
1312
  id: string;
1304
1313
  name: string;
1305
1314
  avatar?: string | undefined;
@@ -1308,7 +1317,6 @@ declare function useWorkflowPreview(nodes: Ref<WorkflowNode[]>, edges: Ref<Workf
1308
1317
  email?: string | undefined;
1309
1318
  phone?: string | undefined;
1310
1319
  }[] | undefined;
1311
- approvalMode?: ApprovalMode | undefined;
1312
1320
  title: string;
1313
1321
  status?: NodeStatus | undefined;
1314
1322
  config?: Record<string, unknown> | undefined;
@@ -76,20 +76,20 @@ declare const __VLS_export: vue.DefineComponent<CaptchaProps, {
76
76
  reset: () => void;
77
77
  show: () => void;
78
78
  }, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
79
- change: (valid: boolean) => any;
80
- reset: () => any;
81
79
  success: (data: CaptchaSuccessPayload) => any;
82
- "load-error": (error: unknown) => any;
80
+ reset: () => any;
81
+ change: (valid: boolean) => any;
83
82
  fail: (error: string) => any;
84
83
  "verify-error": (error: unknown) => any;
84
+ "load-error": (error: unknown) => any;
85
85
  "visible-change": (visible: boolean) => any;
86
86
  }, string, vue.PublicProps, Readonly<CaptchaProps> & Readonly<{
87
- onChange?: ((valid: boolean) => any) | undefined;
88
- onReset?: (() => any) | undefined;
89
87
  onSuccess?: ((data: CaptchaSuccessPayload) => any) | undefined;
90
- "onLoad-error"?: ((error: unknown) => any) | undefined;
88
+ onReset?: (() => any) | undefined;
89
+ onChange?: ((valid: boolean) => any) | undefined;
91
90
  onFail?: ((error: string) => any) | undefined;
92
91
  "onVerify-error"?: ((error: unknown) => any) | undefined;
92
+ "onLoad-error"?: ((error: unknown) => any) | undefined;
93
93
  "onVisible-change"?: ((visible: boolean) => any) | undefined;
94
94
  }>, {
95
95
  theme: "light" | "dark";
@@ -76,20 +76,20 @@ declare const __VLS_export: vue.DefineComponent<CaptchaProps, {
76
76
  reset: () => void;
77
77
  show: () => void;
78
78
  }, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
79
- change: (valid: boolean) => any;
80
- reset: () => any;
81
79
  success: (data: CaptchaSuccessPayload) => any;
82
- "load-error": (error: unknown) => any;
80
+ reset: () => any;
81
+ change: (valid: boolean) => any;
83
82
  fail: (error: string) => any;
84
83
  "verify-error": (error: unknown) => any;
84
+ "load-error": (error: unknown) => any;
85
85
  "visible-change": (visible: boolean) => any;
86
86
  }, string, vue.PublicProps, Readonly<CaptchaProps> & Readonly<{
87
- onChange?: ((valid: boolean) => any) | undefined;
88
- onReset?: (() => any) | undefined;
89
87
  onSuccess?: ((data: CaptchaSuccessPayload) => any) | undefined;
90
- "onLoad-error"?: ((error: unknown) => any) | undefined;
88
+ onReset?: (() => any) | undefined;
89
+ onChange?: ((valid: boolean) => any) | undefined;
91
90
  onFail?: ((error: string) => any) | undefined;
92
91
  "onVerify-error"?: ((error: unknown) => any) | undefined;
92
+ "onLoad-error"?: ((error: unknown) => any) | undefined;
93
93
  "onVisible-change"?: ((visible: boolean) => any) | undefined;
94
94
  }>, {
95
95
  theme: "light" | "dark";
@@ -25,7 +25,7 @@ The core is currently an internal boundary, not a separately published package.
25
25
  - ESM resolves `.d.ts`; CJS resolves `.d.cts`. Each declaration condition matches its JavaScript format.
26
26
  - All public reachable declarations are checked for `naive-ui/es/*` and `naive-ui/lib/*` internal imports, in both formats.
27
27
 
28
- The consumer contract check unpacks a real tarball into a temporary directory and attaches the repository's resolved dependencies. It covers Node16/NodeNext ESM/CJS types and subpath runtime imports without optional peers. It does not reinstall online, so it does not replace minimum/latest dependency matrices or application acceptance.
28
+ The default consumer contract check unpacks a real tarball into a temporary directory and attaches the repository's resolved dependencies. It covers Node16/NodeNext ESM/CJS types and subpath runtime imports without optional peers. The `minimum` and `latest` profiles instead install fresh dependencies from the registry and also render representative components. CI runs both profiles; application acceptance remains a separate check.
29
29
 
30
30
  ## Highlight instances
31
31
 
@@ -81,3 +81,5 @@ Running both UI libraries in one application is outside this iteration. That wou
81
81
  Verify behavior through published consumers, public types, multiple applications, dynamic registration, unmount and host-state restoration. Source-level dependency guards complement runtime verification.
82
82
 
83
83
  `bun run verify` is the local quality gate. `bun run check:audit` remains a separate check and CI gate. Record actual advisory results; do not hide them by disabling checks or forcing unverified major versions.
84
+
85
+ Fresh consumer compatibility is checked with `bun run check:consumer-contracts minimum` and `latest`. Each profile installs the real tarball in an isolated temporary directory, checks ESM/CJS types and renders representative components. CI runs both profiles. `/config` exports shared injection keys and protocol types without loading the presentation layer.
@@ -25,7 +25,9 @@
25
25
  - ESM 使用 `.d.ts`,CJS 使用 `.d.cts`;条件类型入口与相应 JavaScript 格式对应。
26
26
  - 公共可达声明同时检查 ESM / CJS,不能引用 `naive-ui/es/*` 或 `naive-ui/lib/*` 内部路径。
27
27
 
28
- 新增消费者契约验证使用真实 tarball,在临时目录解包并接入仓库已解析的依赖;覆盖 Node16 / NodeNext 的 ESM / CJS 类型与缺失可选 peer 的子路径运行行为。它不联网重新安装依赖,因此不能代替最低/最新依赖版本矩阵或真实应用验收。
28
+ 消费者契约验证使用真实 tarball,覆盖 Node16 / NodeNext 的 ESM / CJS 类型、轻量配置入口的注入键一致性和缺失可选 peer 的子路径运行行为。默认检查复用本地安装;`bun run check:consumer-contracts minimum` / `latest` 在临时目录联网全新安装依赖并渲染表单、表格、原生数字键菜单。CI 分别运行两种组合。类型检查保留 `skipLibCheck`,不将第三方声明内部检查冒充业务消费验证。
29
+
30
+ `/config` 是独立公共配置入口,只包含注入键和协议类型,不引入呈现层。组件注册、样式与反馈适配仍由各自入口负责。
29
31
 
30
32
  ## 高亮实例
31
33
 
@@ -677,3 +677,19 @@ For a concrete business model, enable dynamic insertion with the existing `dynam
677
677
  `C_Breadcrumb` keeps automatic route and manual `items` modes. Optional `menus` accepts the host's authorized menu tree directly (`path/key`, `label/meta.title`, `children`); the component emits `select(path)` and leaves authorization and navigation to the application. Supplying an empty menu explicitly exposes no route-derived shortcuts. Hidden entries and unresolved parameterized leaves are omitted from shortcuts, while the active detail page remains visible unless explicitly excluded with `meta.breadcrumb: false`.
678
678
 
679
679
  Parent buttons open a themed directory panel with page counts and current-page feedback. Narrow containers collapse intermediate path segments. Arrow keys, Home/End, Enter/Space and Escape are supported. Readonly inputs remain unchanged, disabled directories disable their descendants, and route/query/menu/size changes close stale panels. Generic text uses the existing component locale service. Existing `items`, `showIcon`, `iconSize`, `labelFormatter` and `select` remain available; manual labels are not translated again.
680
+
681
+ ## Configuration and behavior contracts (0.21)
682
+
683
+ Use `@robot-admin/naive-ui-components/config` to import `COMPONENT_LOCALE_KEY`, `COMPONENT_FEEDBACK_KEY` and their protocol types. This entry shares injection identities with the root entry without importing components, router or the Naive feedback adapter. Provide a reactive configuration or locale getter for language changes. Built-in `zh-CN`/`en-US` text now also covers Tree, Transfer, SplitPane, Chat, NotificationCenter, Theme, Language, Skeleton and Timeline. Explicit labels remain application-owned.
684
+
685
+ Form action slots receive the current model, including a normal business field named `value`. Collapsed search fields remain mounted and validated; errors expand the form. `show: false` excludes a field. Table expansion discards stale completions after dataset changes, and nested selection honors eligibility, parent limits and consistent events. Native Menu options preserve string/number keys; route-mode callbacks remain string paths. Chat drafts belong to the contact and retain at most 50 nonempty inactive drafts. ER and Workflow emit user-completed canvas edits without echoing parent updates. Human verification gates password login; SMS uses its own validation.
686
+
687
+ Upload `concurrency` applies across normal and chunk upload requests. Cancellation stops subsequent hash reads; a Blob read already in progress is discarded on completion. Application-provided check/merge callbacks retain responsibility for their own network lifecycle.
688
+
689
+ Excel previews preserve raw values, cell types and workbook display formatting. Sheets expand on demand. Defaults are 32 MiB per file and 100000 cells per sheet; `previewLimits: { maxBytes, maxCells }` accepts finite safe positive integers. Over-budget previews report an error and retain download access. These limits do not guarantee a bound on decompressed archive memory.
690
+
691
+ WaterFall fills a visible sentinel for at most five consecutive pages, then exposes a manual continuation. Custom `footer` slots receive `paused` and `loadMore`. Continue updating `loading` and `noMore` in the host. Draggable instances sort independently by default; cross-list transfers require an explicitly shared `group`.
692
+
693
+ Video supports MP4/HLS by default. DASH/FLV require a `sourceAdapters` loader returning a compatible xgplayer constructor; missing adapters enter the error state and emit `error`. Protocol SDK installation remains opt-in.
694
+
695
+ Notification `categoryOptions` customizes labels/order of existing `all/system/business/alarm` categories. It does not add domain enums. The `filters` slot receives `{ controller }`; `item` and `item-actions` receive `{ message, index, busy, select, read, remove }`. Use supplied callbacks to retain busy/error handling. Approval commands, tenancy, authorization and backend contracts remain application-owned; Robot_Admin's enterprise notification store is not bundled into this preview component.
@@ -64,6 +64,25 @@ app.mount('#app')
64
64
 
65
65
  > 子路径导入提供完整的 TypeScript 类型支持(`.d.ts`),IDE 可自动补全 props / emits / slots。组件相关工具函数(如 `createMenuOptions`)也从对应组件子路径导出,避免为了单个工具加载组件库根入口。
66
66
 
67
+ ### 按需配置语言与反馈
68
+
69
+ 独立 `/config` 入口只导出注入键和协议类型,不加载组件、路由或 Naive UI 适配器。与根入口使用相同的注入键,可以直接配置按需使用的组件:
70
+
71
+ ```ts
72
+ import {
73
+ COMPONENT_LOCALE_KEY,
74
+ COMPONENT_FEEDBACK_KEY,
75
+ } from '@robot-admin/naive-ui-components/config'
76
+
77
+ app.provide(COMPONENT_LOCALE_KEY, { locale: 'en-US' })
78
+ app.provide(COMPONENT_FEEDBACK_KEY, {
79
+ success: message.success,
80
+ error: text => message.error(text),
81
+ })
82
+ ```
83
+
84
+ 默认中文,内置支持 `zh-CN` / `en-US`,自定义 `messages` 或 `t` 沿用现有协议。需要动态切换时提供响应式对象或 `locale` getter。Tree、Transfer、SplitPane、Chat、NotificationCenter、Theme、Language、Skeleton、Timeline 的内置文案与已有 Form/Table/Search/Breadcrumb 一起使用该上下文;业务标题、菜单名称和显式传入的文案由宿主管理。
85
+
67
86
  ### Composables 单独使用
68
87
 
69
88
  ```typescript
@@ -771,3 +790,40 @@ CRUD 控制器只需满足结构契约;`@robot-admin/request-core` 0.6.3 起
771
790
  组件只发出 `select(path)`,不执行路由跳转或权限请求。传入 `menus`(包括空数组)后,目录仅使用这份数据;隐藏项、无标题占位和不可直接跳转的动态参数叶页不进入快捷导航。隐藏详情页仍保留当前路径,显式 `meta.breadcrumb: false` 可隐藏对应层级。未传 `menus` 时继续使用路由子项;原生路由表并非权限边界,业务项目应传入与侧栏同源的授权菜单。
772
791
 
773
792
  已有 `items` 手动路径继续优先,标签沿用传入值并接受只读嵌套数据,`disabled` 对目录整支生效。完整路径在窄容器中自动收拢,保留当前页;目录支持方向键、Home/End、Enter/Space 和 Escape。颜色跟随 Naive 主题,浮层中的通用文案使用既有组件国际化服务。组件不保存菜单快照、不读取应用 Store,也不改写传入数据。
793
+
794
+ ## 状态一致性与资源边界(0.21)
795
+
796
+ - 表单 `action` / `action-extra` 插槽直接提供当前业务模型,字段名 `value` 没有特殊含义。
797
+ - 搜索折叠仅隐藏字段,字段保持挂载及校验;失败自动展开。`show: false` 才移除该字段的渲染与校验注册。大型自定义控件会在折叠状态初始化,应按业务配置实际需要的字段。
798
+ - 表格全部展开在换数据或卸载后失效;子表禁选、父级数量上限、strict 联动与选择事件保持同一约束。
799
+ - Menu 的路由模式事件仍为字符串路径;原生 `options` 支持字符串和数字 key,`0` 有效,`1` 与 `'1'` 不合并。
800
+ - Chat 按会话保留草稿,发送后清空当前草稿;移除联系人清理旧草稿,最多缓存最近 50 个非空会话。
801
+ - ER 的节点拖动与 Workflow 的拖动、连接、删除会同步外部快照;父级回填不再次触发用户变更事件。
802
+ - Login 的人机验证门禁适用于密码模式;短信模式使用自己的字段规则及验证码提交事件。
803
+
804
+ ### 上传、文档和长列表
805
+
806
+ `C_Upload.concurrency` 统一限制普通上传与分片上传请求。取消、移除和卸载会停止后续哈希读取并释放排队任务;已经开始的单次 Blob 读取完成后不再处理结果。业务自行提供的校验、合并回调仍由业务负责其网络生命周期。
807
+
808
+ Excel 保留原始值、单元格类型和工作簿格式,不把文本编号转换为数值,也不自行舍入小数。工作表数据在首次打开时展开,默认文件预算 32 MiB、每表 100000 格;超限明确提示下载原文件,不静默截断。可使用一个配置调整预算:
809
+
810
+ ```vue
811
+ <C_FilePreview
812
+ :file="file"
813
+ :preview-limits="{ maxBytes: 64 * 1024 * 1024, maxCells: 200000 }"
814
+ />
815
+ ```
816
+
817
+ 预算必须是有限安全正整数;这是预览资源限制,不是压缩文件解压后内存的绝对保证。
818
+
819
+ WaterFall 会在哨兵持续可见时继续补页,每轮最多自动请求 5 页,避免空响应循环。达到上限后可点击“继续加载”;自定义 `footer` 插槽获得 `paused` 和 `loadMore`。使用侧继续维护 `loading` 和 `noMore`。
820
+
821
+ Draggable 默认只在自身排序。需要跨列表拖动时,在相关实例上显式设置相同 `group`;此前依赖隐式 `default` 分组的页面应补上该属性。
822
+
823
+ ### 视频协议与通知预览
824
+
825
+ 视频默认支持 MP4/HLS。DASH/FLV 需要通过 `sourceAdapters` 提供按需加载、兼容 xgplayer 接口的播放器构造器;缺少适配器会进入错误状态并发出 `error`,不再尝试当作普通 MP4 播放。协议 SDK 的依赖与授权由使用该协议的项目管理。
826
+
827
+ `C_NotificationCenter.categoryOptions` 只定制已有 `all/system/business/alarm` 分类的标签和顺序,不扩展消息领域协议。`filters` 插槽提供 `{ controller }`,`item` / `item-actions` 提供 `{ message, index, busy, select, read, remove }`,可组合独立筛选和业务操作。异步操作应沿用提供的回调以保留 busy/错误处理。
828
+
829
+ 审批命令、租户、权限和后端协议由宿主管理。Robot_Admin 的企业消息使用领域 Store 与自己的通知铃铛;本包提供可复用的通知展示与交互,二者的能力边界不同。