cnhis-design-vue 3.1.34-beta.0 → 3.1.34-beta.10

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/es/components/big-table/index.d.ts +1 -0
  2. package/es/components/big-table/src/BigTable.vue.d.ts +1 -0
  3. package/es/components/big-table/src/BigTable.vue2.js +17 -5
  4. package/es/components/big-table/src/components/edit-form/edit-input.js +2 -1
  5. package/es/components/big-table/src/components/edit-form/edit-select.js +26 -1
  6. package/es/components/big-table/src/hooks/useEvent.js +3 -4
  7. package/es/components/fabric-chart/index.d.ts +141 -374
  8. package/es/components/fabric-chart/src/BirthProcessChart.vue.d.ts +2 -2
  9. package/es/components/fabric-chart/src/FabricChart.vue.d.ts +142 -374
  10. package/es/components/fabric-chart/src/FabricChart.vue.js +52 -22
  11. package/es/components/fabric-chart/src/hooks/index.d.ts +1 -0
  12. package/es/components/fabric-chart/src/hooks/index.js +1 -0
  13. package/es/components/fabric-chart/src/hooks/useBirthProcess.js +2 -2
  14. package/es/components/fabric-chart/src/hooks/useBottom.js +1 -6
  15. package/es/components/fabric-chart/src/hooks/useCenter.d.ts +4 -18
  16. package/es/components/fabric-chart/src/hooks/useCenter.js +5 -21
  17. package/es/components/fabric-chart/src/hooks/useCommon.d.ts +1 -1
  18. package/es/components/fabric-chart/src/hooks/useCommon.js +2 -2
  19. package/es/components/fabric-chart/src/hooks/useGrid.js +2 -7
  20. package/es/components/fabric-chart/src/hooks/useLeft.d.ts +2 -1
  21. package/es/components/fabric-chart/src/hooks/useLeft.js +22 -28
  22. package/es/components/fabric-chart/src/hooks/useOther.js +1 -6
  23. package/es/components/fabric-chart/src/hooks/useRight.js +13 -18
  24. package/es/components/fabric-chart/src/hooks/useTemperatureChart.d.ts +25 -0
  25. package/es/components/fabric-chart/src/hooks/useTemperatureChart.js +339 -0
  26. package/es/components/fabric-chart/src/hooks/useTop.js +1 -6
  27. package/es/components/form-render/index.js +1 -1
  28. package/es/components/form-render/src/components/renderer/levelSearchCascader.d.ts +1 -7
  29. package/es/components/form-render/src/components/renderer/levelSearchCascader.js +2 -5
  30. package/es/components/form-render/src/components/renderer/radio.js +2 -2
  31. package/es/components/form-render/src/components/renderer/remoteSearch.d.ts +1 -7
  32. package/es/components/form-render/src/components/renderer/remoteSearch.js +2 -5
  33. package/es/components/form-render/src/components/renderer/searchCascade.js +4 -12
  34. package/es/components/form-render/src/components/renderer/select.d.ts +1 -7
  35. package/es/components/form-render/src/components/renderer/select.js +2 -5
  36. package/es/components/form-render/src/utils/index.js +1 -1
  37. package/es/components/form-render/src/utils/schema.d.ts +1 -1
  38. package/es/components/form-render/src/utils/schema.js +4 -4
  39. package/es/components/iho-table/index.d.ts +6 -0
  40. package/es/components/iho-table/index.js +1 -1
  41. package/es/components/iho-table/src/IhoTable.vue.d.ts +6 -0
  42. package/es/components/iho-table/src/IhoTable.vue.js +12 -1
  43. package/es/components/iho-table/src/components/IhoTableColumn.js +1 -1
  44. package/es/components/iho-table/src/constants/index.d.ts +6 -0
  45. package/es/components/iho-table/src/constants/index.js +9 -7
  46. package/es/components/iho-table/src/hooks/tapHooks/index.d.ts +1 -1
  47. package/es/components/iho-table/src/hooks/tapHooks/index.js +4 -4
  48. package/es/components/iho-table/src/plugins/defaultConfigPlugin/index.js +19 -7
  49. package/es/components/iho-table/src/plugins/filterPlugin/filter.vue.d.ts +12 -0
  50. package/es/components/iho-table/src/plugins/filterPlugin/filter.vue.js +58 -25
  51. package/es/components/iho-table/src/plugins/filterPlugin/index.js +56 -55
  52. package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +13 -8
  53. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +1 -1
  54. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.js +2 -2
  55. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/inputRendererPlugin.js +12 -7
  56. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/numberRendererPlugin.js +3 -3
  57. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +2 -2
  58. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.d.ts +1 -1
  59. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.js +2 -2
  60. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin.js +2 -2
  61. package/es/components/iho-table/src/plugins/virtualTreePlugin/index.js +10 -3
  62. package/es/components/iho-table/src/types/index.d.ts +8 -3
  63. package/es/components/iho-table/src/utils/index.d.ts +10 -2
  64. package/es/components/iho-table/src/utils/index.js +27 -5
  65. package/es/components/iho-table/style/index.css +1 -1
  66. package/es/components/index.css +1 -1
  67. package/es/components/index.js +1 -1
  68. package/es/shared/types/index.d.ts +1 -0
  69. package/package.json +2 -2
  70. package/es/components/fabric-chart/src/BirthProcessChart.vue.js +0 -172
  71. package/es/components/fabric-chart/src/TemperatureChart.vue.d.ts +0 -214
  72. package/es/components/fabric-chart/src/TemperatureChart.vue.js +0 -355
@@ -647,6 +647,7 @@ declare const BigTable: SFCWithInstall<import("vue").DefineComponent<{
647
647
  sysImageSize: unknown[];
648
648
  }>;
649
649
  treeConfig: import("vue").ComputedRef<any>;
650
+ keyboardConfig: import("vue").ComputedRef<any>;
650
651
  hideAllWrap: (e: any) => void;
651
652
  bindDocumentClick: () => void;
652
653
  unBindDocumentClick: () => void;
@@ -646,6 +646,7 @@ declare const _default: import("vue").DefineComponent<{
646
646
  sysImageSize: unknown[];
647
647
  }>;
648
648
  treeConfig: import("vue").ComputedRef<any>;
649
+ keyboardConfig: import("vue").ComputedRef<any>;
649
650
  hideAllWrap: (e: any) => void;
650
651
  bindDocumentClick: () => void;
651
652
  unBindDocumentClick: () => void;
@@ -143,11 +143,11 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
143
143
  } = props.tableParams;
144
144
  let statusNumber = Number(state.isTree);
145
145
  if ([1, 3].includes(statusNumber)) {
146
- result = {
146
+ result = Object.assign({}, {
147
147
  children: "childrenList",
148
148
  accordion: state.openOnly > 0,
149
149
  reserve: true
150
- };
150
+ }, result);
151
151
  if (isTransform) {
152
152
  Reflect.deleteProperty(result, "children");
153
153
  Object.assign(result, {
@@ -157,17 +157,29 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
157
157
  });
158
158
  }
159
159
  } else if (statusNumber == 2) {
160
- result = {
160
+ result = Object.assign({}, {
161
161
  lazy: true,
162
162
  reserve: true,
163
163
  children: "childrenList",
164
164
  hasChild: "hasChildren",
165
165
  loadMethod: loadChildrenMethod,
166
166
  accordion: state.openOnly > 0
167
- };
167
+ }, result);
168
168
  }
169
169
  return result;
170
170
  });
171
+ const keyboardConfig = computed(() => {
172
+ return {
173
+ editMethod({
174
+ row,
175
+ column
176
+ }) {
177
+ const $table = xGrid.value;
178
+ $table.setEditCell(row, column);
179
+ },
180
+ ...props.columnConfig.keyboardConfig || {}
181
+ };
182
+ });
171
183
  const hideAllWrap = (e) => {
172
184
  const path = e.path || e.composedPath && e.composedPath();
173
185
  const noWrap = (className) => {
@@ -2361,7 +2373,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
2361
2373
  iconClose: "iconfont icon-a-xitongtubiaotianjia",
2362
2374
  ...unref(getAttr)("expand-config")
2363
2375
  },
2364
- "keyboard-config": _ctx.columnConfig.keyboardConfig || {},
2376
+ "keyboard-config": unref(keyboardConfig),
2365
2377
  "edit-rules": _ctx.columnConfig.editRules || {},
2366
2378
  "menu-config": _ctx.menuConfig,
2367
2379
  onCellDblclick: rowdblclick,
@@ -32,10 +32,11 @@ var EditInput = defineComponent({
32
32
  attrs,
33
33
  emit
34
34
  }) {
35
+ var _a;
35
36
  const {
36
37
  formRef
37
38
  } = useCommon(props, attrs);
38
- const __value = ref(props.type === "number" ? attrs.value || void 0 : attrs.value);
39
+ const __value = ref(props.type === "number" ? (_a = attrs.value) != null ? _a : void 0 : attrs.value);
39
40
  const commData = {
40
41
  row: props.row,
41
42
  column: props.col,
@@ -35,6 +35,7 @@ var EditSelect = defineComponent({
35
35
  isShow
36
36
  } = useCommon(props, attrs, true);
37
37
  const state = reactive({
38
+ keyupValue: attrs.value,
38
39
  options: [],
39
40
  loading: false,
40
41
  keyword: "",
@@ -46,6 +47,9 @@ var EditSelect = defineComponent({
46
47
  const setOptions = async () => {
47
48
  if (props.col.options) {
48
49
  state.options = JSON.parse(JSON.stringify(props.col.options));
50
+ if (!state.keyupValue && state.options.length) {
51
+ state.keyupValue = state.options[0].value;
52
+ }
49
53
  } else {
50
54
  `${props.col.columnName}_options`;
51
55
  const obj = {
@@ -66,6 +70,7 @@ var EditSelect = defineComponent({
66
70
  };
67
71
  selectSearch = XEUtils.debounce(selectSearch, 800);
68
72
  const onUpdateValue = (value) => {
73
+ state.keyupValue = value;
69
74
  emit("formChange", {
70
75
  value,
71
76
  row: props.row,
@@ -82,6 +87,25 @@ var EditSelect = defineComponent({
82
87
  selectSearch("");
83
88
  }
84
89
  };
90
+ function onKeyup(event) {
91
+ const {
92
+ key
93
+ } = event;
94
+ if (state.config.multiple || !["ArrowUp", "ArrowDown"].includes(key))
95
+ return;
96
+ if (!state.keyupValue)
97
+ state.keyupValue = state.options[0].value;
98
+ let index = state.options.findIndex((item) => item.value === state.keyupValue);
99
+ const length = state.options.length;
100
+ if (key === "ArrowUp") {
101
+ index = index - 1 === -1 ? length - 1 : index - 1;
102
+ }
103
+ if (key === "ArrowDown") {
104
+ index = index + 1 === length ? 0 : index + 1;
105
+ }
106
+ state.keyupValue = state.options[index].value;
107
+ onUpdateValue(state.keyupValue);
108
+ }
85
109
  init();
86
110
  return () => createVNode(NSelect, mergeProps({
87
111
  "ref": formRef,
@@ -94,7 +118,8 @@ var EditSelect = defineComponent({
94
118
  "filterable": true,
95
119
  "placeholder": props.col.placeholder || "\u8BF7\u9009\u62E9",
96
120
  "loading": state.loading,
97
- "onUpdateValue": onUpdateValue
121
+ "onUpdateValue": onUpdateValue,
122
+ "onKeyup": onKeyup
98
123
  }), null);
99
124
  }
100
125
  });
@@ -17,12 +17,11 @@ const useEvent = (props, state, emit, xGrid, anchorEvent) => {
17
17
  if (!activeRow && !isEdit)
18
18
  return;
19
19
  if (isEdit) {
20
- const { row, $rowIndex, rowIndex, column } = xGridRef.getEditRecord() || {};
20
+ const data = xGridRef.getEditRecord() || xGridRef.getSelectedCell() || {};
21
21
  emit("keyboard", {
22
22
  key: $event.key,
23
- index: $rowIndex != null ? $rowIndex : rowIndex,
24
- row,
25
- column
23
+ ...data,
24
+ index: data.rowIndex
26
25
  });
27
26
  return;
28
27
  }